diff --git a/.browserslistrc b/.browserslistrc new file mode 100644 index 0000000000..0152f61ef0 --- /dev/null +++ b/.browserslistrc @@ -0,0 +1 @@ +extends @wordpress/browserslist-config diff --git a/.eslintignore b/.eslintignore index e919e75fd9..b505f64e4b 100644 --- a/.eslintignore +++ b/.eslintignore @@ -1,11 +1,18 @@ # Exclude auto generated files. **/*.min.js **/*.js.map -**/formidable_blocks.js -**/formidable_overlay.js -**/formidable_dashboard.js -**/formidable-templates.js -**/formidable_styles.js +js/formidable_blocks.js +js/formidable_overlay.js +js/form-templates.js +js/formidable_dashboard.js +js/onboarding-wizard.js +js/addons-page.js +js/formidable_styles.js +js/formidable_admin.js +js/bootstrap-multiselect.js + +# Config files +*.config.js **/node_modules/** **/vendor/** diff --git a/.eslintrc.json b/.eslintrc.json index 391958cbbc..861d81ed76 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -38,7 +38,7 @@ "settings": { "import/resolver": { "webpack": { - "config": "webpack.config.js" + "config": "./webpack.config.js" } }, "react": { @@ -48,7 +48,24 @@ "rules": { "cypress/unsafe-to-chain-command": "off", "cypress/no-assigning-return-values": "off", - "camelcase": ["error", { "properties": "never" }], + "camelcase": [ + "error", + { + "properties": "never", + "allow": [ + "frm_admin_js", + "frm_stripe_vars", + "frm_trans_vars", + "formidable_form_selector", + "frm_js", + "frm_password_checks", + "formidable_block_calculator", + "formidable_view_selector", + "frmdates_admin_js", + "frm_abdn" + ] + } + ], "lines-around-comment": "off", "react/display-name": "off", "react/jsx-curly-spacing": [ @@ -128,6 +145,9 @@ "no-jquery/no-trim": "error", "no-jquery/no-type": "error", "no-jquery/no-unique": "error", - "no-jquery/no-when": "error" + "no-jquery/no-when": "error", + "react/jsx-no-target-blank": "off", + "comma-dangle": "off", + "arrow-parens": ["error", "as-needed"] } } diff --git a/.github/workflows/cypress.yml b/.github/workflows/cypress.yml index 9c891aa858..e41b129d1f 100644 --- a/.github/workflows/cypress.yml +++ b/.github/workflows/cypress.yml @@ -27,7 +27,7 @@ jobs: node-version: 20 - name: Install dependencies - run: npm ci --include=dev + run: npm ci --legacy-peer-deps --include=dev - name: Set up WP environment run: npm run env start diff --git a/.github/workflows/jscs.yml b/.github/workflows/jscs.yml index b497c348e6..ee6b147527 100644 --- a/.github/workflows/jscs.yml +++ b/.github/workflows/jscs.yml @@ -5,12 +5,12 @@ on: branches: - master pull_request: - branches: - - master + types: [ opened, labeled, synchronize ] name: Inspections jobs: runPHPCSInspection: + if: contains(github.event.pull_request.labels.*.name, 'run analysis') name: Run ESLint runs-on: ubuntu-latest steps: @@ -18,7 +18,5 @@ jobs: uses: actions/checkout@master - name: Analyze js code style run: | - npm install eslint - wget https://develop.svn.wordpress.org/trunk/.jshintrc - ./node_modules/.bin/eslint ./js/formidable* - ./node_modules/.bin/eslint ./tests/cypress/e2e/* + npm ci --legacy-peer-deps --include=dev + ./node_modules/.bin/eslint . diff --git a/classes/controllers/FrmEntriesController.php b/classes/controllers/FrmEntriesController.php index 95ee8f2429..55603eec64 100644 --- a/classes/controllers/FrmEntriesController.php +++ b/classes/controllers/FrmEntriesController.php @@ -393,6 +393,8 @@ private static function field_supports_sorting( $field ) { * @return array */ public static function hidden_columns( $result ) { + global $frm_vars; + if ( ! is_array( $result ) ) { // Force an unexpected value to be an array. // Since $result is a filtered option and gets saved to the database, it's possible it could be a string. @@ -400,13 +402,9 @@ public static function hidden_columns( $result ) { $result = array(); } - $form_id = FrmForm::get_current_form_id(); - - $hidden = self::user_hidden_columns_for_form( $form_id, $result ); - - global $frm_vars; - $i = isset( $frm_vars['cols'] ) ? count( $frm_vars['cols'] ) : 0; - + $form_id = FrmForm::get_current_form_id(); + $hidden = self::user_hidden_columns_for_form( $form_id, $result ); + $i = isset( $frm_vars['cols'] ) ? count( $frm_vars['cols'] ) : 0; $max_columns = 11; if ( ! empty( $hidden ) ) { @@ -447,6 +445,10 @@ private static function user_hidden_columns_for_form( $form_id, $result ) { * Remove some columns by default when there are too many * * @since 2.05.07 + * + * @param array $atts + * @param array $result + * @return void */ private static function remove_excess_cols( $atts, &$result ) { global $frm_vars; diff --git a/js/addons-page.js b/js/addons-page.js index db4e2548c8..01189001d5 100644 --- a/js/addons-page.js +++ b/js/addons-page.js @@ -1 +1 @@ -!function(){var t={616:function(t){t.exports=function(t,e){var n,r,o=0;function i(){var i,a,c=n,l=arguments.length;t:for(;c;){if(c.args.length===arguments.length){for(a=0;a=0),c.type){case"b":n=parseInt(n,10).toString(2);break;case"c":n=String.fromCharCode(parseInt(n,10));break;case"d":case"i":n=parseInt(n,10);break;case"j":n=JSON.stringify(n,null,c.width?parseInt(c.width):0);break;case"e":n=c.precision?parseFloat(n).toExponential(c.precision):parseFloat(n).toExponential();break;case"f":n=c.precision?parseFloat(n).toFixed(c.precision):parseFloat(n);break;case"g":n=c.precision?String(Number(n.toPrecision(c.precision))):parseFloat(n);break;case"o":n=(parseInt(n,10)>>>0).toString(8);break;case"s":n=String(n),n=c.precision?n.substring(0,c.precision):n;break;case"t":n=String(!!n),n=c.precision?n.substring(0,c.precision):n;break;case"T":n=Object.prototype.toString.call(n).slice(8,-1).toLowerCase(),n=c.precision?n.substring(0,c.precision):n;break;case"u":n=parseInt(n,10)>>>0;break;case"v":n=n.valueOf(),n=c.precision?n.substring(0,c.precision):n;break;case"x":n=(parseInt(n,10)>>>0).toString(16);break;case"X":n=(parseInt(n,10)>>>0).toString(16).toUpperCase()}o.json.test(c.type)?m+=n:(!o.number.test(c.type)||f&&!c.sign?d="":(d=f?"+":"-",n=n.toString().replace(o.sign,"")),s=c.pad_char?"0"===c.pad_char?"0":c.pad_char.charAt(1):" ",u=c.width-(d+n).length,l=c.width&&u>0?s.repeat(u):"",m+=c.align?d+n+l:"0"===s?d+l+n:l+d+n)}return m}(function(t){if(c[t])return c[t];for(var e,n=t,r=[],i=0;n;){if(null!==(e=o.text.exec(n)))r.push(e[0]);else if(null!==(e=o.modulo.exec(n)))r.push("%");else{if(null===(e=o.placeholder.exec(n)))throw new SyntaxError("[sprintf] unexpected placeholder");if(e[2]){i|=1;var a=[],l=e[2],s=[];if(null===(s=o.key.exec(l)))throw new SyntaxError("[sprintf] failed to parse named argument key");for(a.push(s[1]);""!==(l=l.substring(s[0].length));)if(null!==(s=o.key_access.exec(l)))a.push(s[1]);else{if(null===(s=o.index_access.exec(l)))throw new SyntaxError("[sprintf] failed to parse named argument key");a.push(s[1])}e[2]=a}else i|=2;if(3===i)throw new Error("[sprintf] mixing positional and named placeholders is not (yet) supported");r.push({placeholder:e[0],param_no:e[1],keys:e[2],sign:e[3],pad_char:e[4],align:e[5],width:e[6],precision:e[7],type:e[8]})}n=n.substring(e[0].length)}return c[t]=r}(t),arguments)}function a(t,e){return i.apply(null,[t].concat(e||[]))}var c=Object.create(null);"undefined"!=typeof window&&(window.sprintf=i,window.vsprintf=a,void 0===(r=function(){return{sprintf:i,vsprintf:a}}.call(e,n,e,t))||(t.exports=r))}()}},e={};function n(r){var o=e[r];if(void 0!==o)return o.exports;var i=e[r]={exports:{}};return t[r](i,i.exports,n),i.exports}n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,{a:e}),e},n.d=function(t,e){for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},function(){"use strict";var t=window.frmGlobal,e=t.url,r=(t.nonce,"frm_hidden"),o="frm-hide-js",i="frm-current";function a(t){return a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},a(t)}function c(t,e){for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:"default";!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.elements=e,this.type=n,this.prepareElements()},e=[{key:"fadeIn",value:function(){var t=this;this.applyStyleToElements((function(e){e.classList.add("frm-fadein-up"),e.addEventListener("animationend",(function(){t.resetOpacity(),e.classList.remove("frm-fadein-up")}),{once:!0})}))}},{key:"cascadeFadeIn",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.03;setTimeout((function(){t.applyStyleToElements((function(t,n){t.classList.remove("frm-animate"),t.style.transitionDelay=(n+1)*e+"s"}))}),200)}},{key:"prepareElements",value:function(){var t=this;this.applyStyleToElements((function(e){"default"===t.type&&(e.style.opacity="0.0"),"cascade"===t.type&&e.classList.add("frm-init-cascade-animation"),"cascade-3d"===t.type&&e.classList.add("frm-init-fadein-3d"),e.classList.add("frm-animate")}))}},{key:"resetOpacity",value:function(){this.applyStyleToElements((function(t){return t.style.opacity="1.0"}))}},{key:"applyStyleToElements",value:function(t){this.elements instanceof Element?t(this.elements,0):0":5,">=":5,"==":4,"!=":4,"&&":3,"||":2,"?":1,"?:":1},x=["(","?"],O={")":["("],":":["?","?:"]},_=/<=|>=|==|!=|&&|\|\||\?:|\(|!|\*|\/|%|\+|-|<|>|\?|\)|:/;var A={"!":function(t){return!t},"*":function(t,e){return t*e},"/":function(t,e){return t/e},"%":function(t,e){return t%e},"+":function(t,e){return t+e},"-":function(t,e){return t-e},"<":function(t,e){return t":function(t,e){return t>e},">=":function(t,e){return t>=e},"==":function(t,e){return t===e},"!=":function(t,e){return t!==e},"&&":function(t,e){return t&&e},"||":function(t,e){return t||e},"?:":function(t,e,n){if(t)throw e;return n}};var C={contextDelimiter:"",onMissingKey:null};function T(t,e){var n;for(n in this.data=t,this.pluralForms={},this.options={},C)this.options[n]=void 0!==e&&n in e?e[n]:C[n]}function F(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function I(t){for(var e=1;e=0||w[o]3&&void 0!==arguments[3]?arguments[3]:10,a=t[e];if(R(n)&&q(r))if("function"==typeof o)if("number"==typeof i){var c={callback:o,priority:i,namespace:r};if(a[n]){var l,s=a[n].handlers;for(l=s.length;l>0&&!(i>=s[l-1].priority);l--);l===s.length?s[l]=c:s.splice(l,0,c),a.__current.forEach((function(t){t.name===n&&t.currentIndex>=l&&t.currentIndex++}))}else a[n]={handlers:[c],runs:0};"hookAdded"!==n&&t.doAction("hookAdded",n,r,o,i)}else console.error("If specified, the hook priority must be a number.");else console.error("The hook callback must be a function.")}},z=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(r,o){var i=t[e];if(R(r)&&(n||q(o))){if(!i[r])return 0;var a=0;if(n)a=i[r].handlers.length,i[r]={runs:i[r].runs,handlers:[]};else for(var c=i[r].handlers,l=function(t){c[t].namespace===o&&(c.splice(t,1),a++,i.__current.forEach((function(e){e.name===r&&e.currentIndex>=t&&e.currentIndex--})))},s=c.length-1;s>=0;s--)l(s);return"hookRemoved"!==r&&t.doAction("hookRemoved",r,o),a}}},B=function(t,e){return function(n,r){var o=t[e];return void 0!==r?n in o&&o[n].handlers.some((function(t){return t.namespace===r})):n in o}},M=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(r){var o=t[e];o[r]||(o[r]={handlers:[],runs:0}),o[r].runs++;for(var i=o[r].handlers,a=arguments.length,c=new Array(a>1?a-1:0),l=1;l1&&void 0!==arguments[1]?arguments[1]:"default";r.data[e]=I(I(I({},D),r.data[e]),t),r.data[e][""]=I(I({},D[""]),r.data[e][""])},c=function(t,e){a(t,e),i()},l=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default",e=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,i=arguments.length>4?arguments[4]:void 0;return r.data[t]||a(void 0,t),r.dcnpgettext(t,e,n,o,i)},s=function(){return arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default"},u=function(t,e,r){var o=l(r,e,t);return n?(o=n.applyFilters("i18n.gettext_with_context",o,t,e,r),n.applyFilters("i18n.gettext_with_context_"+s(r),o,t,e,r)):o};if(n){var f=function(t){L.test(t)&&i()};n.addAction("hookAdded","core/i18n",f),n.addAction("hookRemoved","core/i18n",f)}return{getLocaleData:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default";return r.data[t]},setLocaleData:c,resetLocaleData:function(t,e){r.data={},r.pluralForms={},c(t,e)},subscribe:function(t){return o.add(t),function(){return o.delete(t)}},__:function(t,e){var r=l(e,void 0,t);return n?(r=n.applyFilters("i18n.gettext",r,t,e),n.applyFilters("i18n.gettext_"+s(e),r,t,e)):r},_x:u,_n:function(t,e,r,o){var i=l(o,void 0,t,e,r);return n?(i=n.applyFilters("i18n.ngettext",i,t,e,r,o),n.applyFilters("i18n.ngettext_"+s(o),i,t,e,r,o)):i},_nx:function(t,e,r,o,i){var a=l(i,o,t,e,r);return n?(a=n.applyFilters("i18n.ngettext_with_context",a,t,e,r,o,i),n.applyFilters("i18n.ngettext_with_context_"+s(i),a,t,e,r,o,i)):a},isRTL:function(){return"rtl"===u("ltr","text direction")},hasTranslation:function(t,e,o){var i,a,c=e?e+""+t:t,l=!(null===(i=r.data)||void 0===i||null===(a=i[null!=o?o:"default"])||void 0===a||!a[c]);return n&&(l=n.applyFilters("i18n.has_translation",l,t,e,o),l=n.applyFilters("i18n.has_translation_"+s(o),l,t,e,o)),l}}}(0,0,X)),G=(V.getLocaleData.bind(V),V.setLocaleData.bind(V),V.resetLocaleData.bind(V),V.subscribe.bind(V),V.__.bind(V)),J=(V._x.bind(V),V._n.bind(V),V._nx.bind(V),V.isRTL.bind(V),V.hasTranslation.bind(V),window.frmDom),H=J.tag,Q=J.div,W=J.a,Y=J.img;function tt(t){return tt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},tt(t)}function et(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function nt(t,e,n){return(e=function(t){var e=function(t){if("object"!=tt(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=tt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==tt(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var rt,ot=document.getElementById("post-body-content"),it=document.getElementById("".concat(m,"-sidebar")),at=((rt=W({className:"button button-primary frm-button-primary"})).setAttribute("role","button"),Q({id:"".concat(m,"-empty-state"),className:"frm-flex-col frm-flex-center frm-gap-md ".concat(r),children:[Y({src:"".concat(e,"/images/page-skeleton/empty-state.svg"),alt:G("Empty State","formidable")}),Q({className:"frmcenter",children:[H("h2",{className:"".concat(m,"-title frm-mb-0")}),H("p",{className:"".concat(m,"-text frm-mb-0")})]}),rt]}));null==ot||ot.appendChild(at);var ct=function(){var t=document.querySelector("#".concat(m,"-empty-state"));return{emptyState:t,emptyStateTitle:null==t?void 0:t.querySelector(".".concat(m,"-title")),emptyStateText:null==t?void 0:t.querySelector(".".concat(m,"-text")),emptyStateButton:null==t?void 0:t.querySelector(".button")}}(),lt=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if("object"!==S(t)||null===t)throw new Error("createPageElements: initialElements must be a non-null object");var e=t;return{getElements:function(){return e},addElements:function(t){if("object"!==S(t)||null===t)throw new Error("addElements: newElements must be a non-null object");e=h(h({},e),t)}}}(function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:{};if("object"!==yt(t)||null===t)throw new Error("createPageState: initialState must be a non-null object");var e=t;return{getState:function(){return e},getSingleState:function(t){var n=Reflect.get(e,t);return void 0===n?null:n},setState:function(t){if("object"!==yt(t)||null===t)throw new Error("setState: newState must be a non-null object");e=dt(dt({},e),t)},setSingleState:function(t,n){Reflect.has(e,t)&&Reflect.set(e,t,n)}}}({notEmptySearchText:!1,selectedCategory:v,selectedCategoryEl:mt}),bt=vt.getState,ht=vt.getSingleState,gt=vt.setState,St=vt.setSingleState,wt=function(t){var e,n=t.currentTarget,r=n.getAttribute("data-category"),o=bt(),a=o.selectedCategory,c=o.selectedCategoryEl,l=o.notEmptySearchText;if(a!==r){a=wp.hooks.applyFilters("frmPage.selectedCategory",r),c.classList.remove(i),(c=n).classList.add(i),gt({selectedCategory:a,selectedCategoryEl:c}),l&&((e=st().searchInput).value="",e.dispatchEvent(new Event("input",{bubbles:!0}))),wp.hooks.doAction("frmPage.onCategoryClick",a);var u=st().bodyContent;new s(u).fadeIn()}};function xt(t){"Enter"!==t.key&&" "!==t.key||(t.preventDefault(),wt(t))}var Ot=window.frmAddonsVars.addonRequestURL,_t="frm-addons",jt="available-addons",Et="active-addons",Pt="basic",kt="plus",At="business",Ct="elite",Tt=st(),Ft=Tt.bodyContent,It=Tt.sidebar;Ft.querySelectorAll(".frm-card-item:not(.plugin-card-formidable-pro)").forEach((function(t){var e=t.dataset.categories;switch(!0){case e.includes(At):t.setAttribute("data-categories","".concat(e,",").concat(Ct));break;case e.includes(kt):t.setAttribute("data-categories","".concat(e,",").concat(At,",").concat(Ct));break;case e.includes(Pt):t.setAttribute("data-categories","".concat(e,",").concat(kt,",").concat(At,",").concat(Ct))}})),ut({upgradeBanner:document.getElementById("frm-upgrade-banner"),availableCategory:It.querySelector(".".concat(m,'-cat[data-category="').concat(jt,'"]')),activeCategory:It.querySelector(".".concat(m,'-cat[data-category="').concat(Et,'"]')),categoriesTopDivider:It.querySelector(".".concat(m,"-divider")),basicPlanCategory:It.querySelector(".".concat(m,'-cat[data-category="').concat(Pt,'"]')),plusPlanCategory:It.querySelector(".".concat(m,'-cat[data-category="').concat(kt,'"]')),businessPlanCategory:It.querySelector(".".concat(m,'-cat[data-category="').concat(At,'"]')),elitePlanCategory:It.querySelector(".".concat(m,'-cat[data-category="').concat(Ct,'"]')),addonsList:document.getElementById("".concat(_t,"-list")),addons:Ft.querySelectorAll(".frm-card-item"),availableAddons:Ft.querySelectorAll(".frm-card-item:not(.frm-locked-item)"),addonsToggle:Ft.querySelectorAll(".frm_toggle_block"),bodyContentChildren:null==Ft?void 0:Ft.children});var Dt={};Dt[jt]=[],Dt[Et]=[];var Lt,qt=".".concat(m,"-cat-count");function Rt(){var t=st(),e=t.activeCategory,n=t.availableCategory,r=t.categoriesTopDivider,o=document.querySelectorAll(".frm-addon-active:not(.frm-locked-item)");0!==o.length?(Dt[Et]=o,e.querySelector(qt).textContent=o.length):d([e,n,r])}function Nt(){var t=bt().selectedCategory,e=st(),n=e.emptyState,r=e.emptyStateButton,o=e.emptyStateTitle,i=e.emptyStateText;n.setAttribute("data-view",t),o.textContent=G("No add-ons found","formidable"),i.textContent=G("Sorry, we didn't find any add-ons that match your criteria.","formidable"),r.textContent=G("Request Add-On","formidable"),r.href=Ot,r.setAttribute("target","_blank"),f([n,r])}function zt(t,e){if(t){if("string"==typeof t)return Bt(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Bt(t,e):void 0}}function Bt(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,i=!0,a=!1;return{s:function(){e=e.call(t)},n:function(){var t=e.next();return i=t.done,t},e:function(t){a=!0,o=t},f:function(){try{i||null==e.return||e.return()}finally{if(a)throw o}}}}(new Map([["frm-addon-not-installed",".frm-install-addon"],["frm-addon-installed",".frm-activate-addon"],["frm-addon-active",".frm-deactivate-addon"]]).entries());try{for(a.s();!(o=a.n()).done;){var c=(n=o.value,r=2,function(t){if(Array.isArray(t))return t}(n)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,o,i,a,c=[],l=!0,s=!1;try{if(i=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(c.push(r.value),c.length!==e);l=!0);}catch(t){s=!0,o=t}finally{try{if(!l&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(s)throw o}}return c}}(n,r)||zt(n,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),l=c[0],s=c[1];if(i.classList.contains(l)){(Lt=i.querySelector(s)).click();break}}}catch(t){a.e(t)}finally{a.f()}}},$t=window.frmDom.search.init;function Ut(t,e){var n=t.foundSomething,r=t.notEmptySearchText;if(!e||"search"!==e.type||""!==e.target.value){var o=bt(),a=st().allItemsCategory;St("notEmptySearchText",r),o.notEmptySearchText||o.selectedCategory?(o.selectedCategory&&(function(t){var e=st(),n=e.bodyContent,r=e.bodyContentChildren,o=e.addonsList;t&&ht("selectedCategoryEl").classList.remove(i),d(r),p(o),new s(n).fadeIn()}(r),r&&St("selectedCategory","")),function(t){if(t){var e,n=st().emptyState;e=n,"none"!==window.getComputedStyle(e).getPropertyValue("display")&&y(n)}else Nt()}(n)):a.dispatchEvent(new Event("click",{bubbles:!0}))}}var Zt;function Kt(){var t;st().categoryItems.forEach((function(t){u(t,wt),t.addEventListener("keydown",xt)})),wp.hooks.addAction("frmPage.onCategoryClick","frmAddonsPage",(function(t){!function(t){var e=st(),n=e.bodyContent,r=e.addons,o=e.emptyState,i=e.upgradeBanner;y(o),p(i),n.dataset.category=t,v!==t?(d(r),0===Dt[t].length?(Nt(),y(i)):f(Dt[t])):f(r)}(t)})),st().addonsToggle.forEach((function(t){return t.addEventListener("click",Mt)})),wp.hooks.addAction("frm_update_addon_state","frmAddonPage",(function(){Rt()})),t=st().searchInput,$t(t,"frm-card-item",{handleSearchResult:Ut})}Zt=function(){(function(){var t,e,n,r,i,a,c,l,u,f,d=st(),y=d.sidebar,m=d.searchInput,v=d.bodyContent,b=new s(v);m.value="",Rt(),function(){var t=st(),e=t.bodyContent,n=t.availableCategory,r=t.availableAddons;if(Dt[jt]=r,n){n.querySelector(qt).textContent=r.length;var o=e.querySelector(".".concat(_t,"-available-count"));o&&(o.textContent=r.length)}}(),function(){var t=st(),e=t.allItemsCategory,n=t.addons;e.querySelector(qt).textContent=n.length}(),e=(t=st()).basicPlanCategory,n=t.plusPlanCategory,r=t.businessPlanCategory,i=t.elitePlanCategory,c=(a=function(t){return parseInt(t.querySelector(qt).textContent,10)||0})(e),l=a(n)-1,u=a(r)-1,f=a(i)-1,n.querySelector(qt).textContent=c+l,r.querySelector(qt).textContent=c+l+u,i.querySelector(qt).textContent=c+l+u+f,v.classList.remove(o),y.classList.remove(o),b.fadeIn(),p(y)})(),st().addons.forEach((function(t){var e=t.getAttribute("data-categories");e&&e.split(",").forEach((function(e){Dt[e]||(Dt[e]=[]),Dt[e].push(t)}))})),Kt()},"undefined"!=typeof document&&("complete"!==document.readyState&&"interactive"!==document.readyState?document.addEventListener("DOMContentLoaded",Zt):Zt())}()}(); \ No newline at end of file +(()=>{var t={616:t=>{t.exports=function(t,e){var n,r,o=0;function i(){var i,a,c=n,l=arguments.length;t:for(;c;){if(c.args.length===arguments.length){for(a=0;a{var r;!function(){"use strict";var o={not_string:/[^s]/,not_bool:/[^t]/,not_type:/[^T]/,not_primitive:/[^v]/,number:/[diefg]/,numeric_arg:/[bcdiefguxX]/,json:/[j]/,not_json:/[^j]/,text:/^[^\x25]+/,modulo:/^\x25{2}/,placeholder:/^\x25(?:([1-9]\d*)\$|\(([^)]+)\))?(\+)?(0|'[^$])?(-)?(\d+)?(?:\.(\d+))?([b-gijostTuvxX])/,key:/^([a-z_][a-z_\d]*)/i,key_access:/^\.([a-z_][a-z_\d]*)/i,index_access:/^\[(\d+)\]/,sign:/^[+-]/};function i(t){return function(t,e){var n,r,a,c,l,s,u,f,d,p=1,y=t.length,m="";for(r=0;r=0),c.type){case"b":n=parseInt(n,10).toString(2);break;case"c":n=String.fromCharCode(parseInt(n,10));break;case"d":case"i":n=parseInt(n,10);break;case"j":n=JSON.stringify(n,null,c.width?parseInt(c.width):0);break;case"e":n=c.precision?parseFloat(n).toExponential(c.precision):parseFloat(n).toExponential();break;case"f":n=c.precision?parseFloat(n).toFixed(c.precision):parseFloat(n);break;case"g":n=c.precision?String(Number(n.toPrecision(c.precision))):parseFloat(n);break;case"o":n=(parseInt(n,10)>>>0).toString(8);break;case"s":n=String(n),n=c.precision?n.substring(0,c.precision):n;break;case"t":n=String(!!n),n=c.precision?n.substring(0,c.precision):n;break;case"T":n=Object.prototype.toString.call(n).slice(8,-1).toLowerCase(),n=c.precision?n.substring(0,c.precision):n;break;case"u":n=parseInt(n,10)>>>0;break;case"v":n=n.valueOf(),n=c.precision?n.substring(0,c.precision):n;break;case"x":n=(parseInt(n,10)>>>0).toString(16);break;case"X":n=(parseInt(n,10)>>>0).toString(16).toUpperCase()}o.json.test(c.type)?m+=n:(!o.number.test(c.type)||f&&!c.sign?d="":(d=f?"+":"-",n=n.toString().replace(o.sign,"")),s=c.pad_char?"0"===c.pad_char?"0":c.pad_char.charAt(1):" ",u=c.width-(d+n).length,l=c.width&&u>0?s.repeat(u):"",m+=c.align?d+n+l:"0"===s?d+l+n:l+d+n)}return m}(function(t){if(c[t])return c[t];for(var e,n=t,r=[],i=0;n;){if(null!==(e=o.text.exec(n)))r.push(e[0]);else if(null!==(e=o.modulo.exec(n)))r.push("%");else{if(null===(e=o.placeholder.exec(n)))throw new SyntaxError("[sprintf] unexpected placeholder");if(e[2]){i|=1;var a=[],l=e[2],s=[];if(null===(s=o.key.exec(l)))throw new SyntaxError("[sprintf] failed to parse named argument key");for(a.push(s[1]);""!==(l=l.substring(s[0].length));)if(null!==(s=o.key_access.exec(l)))a.push(s[1]);else{if(null===(s=o.index_access.exec(l)))throw new SyntaxError("[sprintf] failed to parse named argument key");a.push(s[1])}e[2]=a}else i|=2;if(3===i)throw new Error("[sprintf] mixing positional and named placeholders is not (yet) supported");r.push({placeholder:e[0],param_no:e[1],keys:e[2],sign:e[3],pad_char:e[4],align:e[5],width:e[6],precision:e[7],type:e[8]})}n=n.substring(e[0].length)}return c[t]=r}(t),arguments)}function a(t,e){return i.apply(null,[t].concat(e||[]))}var c=Object.create(null);"undefined"!=typeof window&&(window.sprintf=i,window.vsprintf=a,void 0===(r=function(){return{sprintf:i,vsprintf:a}}.call(e,n,e,t))||(t.exports=r))}()}},e={};function n(r){var o=e[r];if(void 0!==o)return o.exports;var i=e[r]={exports:{}};return t[r](i,i.exports,n),i.exports}n.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return n.d(e,{a:e}),e},n.d=(t,e)=>{for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),(()=>{"use strict";var t=window.frmGlobal,e=t.url,r=(t.nonce,"frm_hidden"),o="frm-hide-js",i="frm-current";function a(t){return a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},a(t)}function c(t,e){for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:"default";!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.elements=e,this.type=n,this.prepareElements()},e=[{key:"fadeIn",value:function(){var t=this;this.applyStyleToElements((function(e){e.classList.add("frm-fadein-up"),e.addEventListener("animationend",(function(){t.resetOpacity(),e.classList.remove("frm-fadein-up")}),{once:!0})}))}},{key:"cascadeFadeIn",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.03;setTimeout((function(){t.applyStyleToElements((function(t,n){t.classList.remove("frm-animate"),t.style.transitionDelay=(n+1)*e+"s"}))}),200)}},{key:"prepareElements",value:function(){var t=this;this.applyStyleToElements((function(e){"default"===t.type&&(e.style.opacity="0.0"),"cascade"===t.type&&e.classList.add("frm-init-cascade-animation"),"cascade-3d"===t.type&&e.classList.add("frm-init-fadein-3d"),e.classList.add("frm-animate")}))}},{key:"resetOpacity",value:function(){this.applyStyleToElements((function(t){return t.style.opacity="1.0"}))}},{key:"applyStyleToElements",value:function(t){this.elements instanceof Element?t(this.elements,0):0":5,">=":5,"==":4,"!=":4,"&&":3,"||":2,"?":1,"?:":1},x=["(","?"],O={")":["("],":":["?","?:"]},_=/<=|>=|==|!=|&&|\|\||\?:|\(|!|\*|\/|%|\+|-|<|>|\?|\)|:/;var A={"!":function(t){return!t},"*":function(t,e){return t*e},"/":function(t,e){return t/e},"%":function(t,e){return t%e},"+":function(t,e){return t+e},"-":function(t,e){return t-e},"<":function(t,e){return t":function(t,e){return t>e},">=":function(t,e){return t>=e},"==":function(t,e){return t===e},"!=":function(t,e){return t!==e},"&&":function(t,e){return t&&e},"||":function(t,e){return t||e},"?:":function(t,e,n){if(t)throw e;return n}};var C={contextDelimiter:"",onMissingKey:null};function T(t,e){var n;for(n in this.data=t,this.pluralForms={},this.options={},C)this.options[n]=void 0!==e&&n in e?e[n]:C[n]}function F(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function I(t){for(var e=1;e=0||w[o]3&&void 0!==arguments[3]?arguments[3]:10,a=t[e];if(R(n)&&q(r))if("function"==typeof o)if("number"==typeof i){var c={callback:o,priority:i,namespace:r};if(a[n]){var l,s=a[n].handlers;for(l=s.length;l>0&&!(i>=s[l-1].priority);l--);l===s.length?s[l]=c:s.splice(l,0,c),a.__current.forEach((function(t){t.name===n&&t.currentIndex>=l&&t.currentIndex++}))}else a[n]={handlers:[c],runs:0};"hookAdded"!==n&&t.doAction("hookAdded",n,r,o,i)}else console.error("If specified, the hook priority must be a number.");else console.error("The hook callback must be a function.")}},z=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(r,o){var i=t[e];if(R(r)&&(n||q(o))){if(!i[r])return 0;var a=0;if(n)a=i[r].handlers.length,i[r]={runs:i[r].runs,handlers:[]};else for(var c=i[r].handlers,l=function(t){c[t].namespace===o&&(c.splice(t,1),a++,i.__current.forEach((function(e){e.name===r&&e.currentIndex>=t&&e.currentIndex--})))},s=c.length-1;s>=0;s--)l(s);return"hookRemoved"!==r&&t.doAction("hookRemoved",r,o),a}}},B=function(t,e){return function(n,r){var o=t[e];return void 0!==r?n in o&&o[n].handlers.some((function(t){return t.namespace===r})):n in o}},M=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(r){var o=t[e];o[r]||(o[r]={handlers:[],runs:0}),o[r].runs++;for(var i=o[r].handlers,a=arguments.length,c=new Array(a>1?a-1:0),l=1;l1&&void 0!==arguments[1]?arguments[1]:"default";r.data[e]=I(I(I({},D),r.data[e]),t),r.data[e][""]=I(I({},D[""]),r.data[e][""])},c=function(t,e){a(t,e),i()},l=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default",e=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,i=arguments.length>4?arguments[4]:void 0;return r.data[t]||a(void 0,t),r.dcnpgettext(t,e,n,o,i)},s=function(){return arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default"},u=function(t,e,r){var o=l(r,e,t);return n?(o=n.applyFilters("i18n.gettext_with_context",o,t,e,r),n.applyFilters("i18n.gettext_with_context_"+s(r),o,t,e,r)):o};if(n){var f=function(t){L.test(t)&&i()};n.addAction("hookAdded","core/i18n",f),n.addAction("hookRemoved","core/i18n",f)}return{getLocaleData:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default";return r.data[t]},setLocaleData:c,resetLocaleData:function(t,e){r.data={},r.pluralForms={},c(t,e)},subscribe:function(t){return o.add(t),function(){return o.delete(t)}},__:function(t,e){var r=l(e,void 0,t);return n?(r=n.applyFilters("i18n.gettext",r,t,e),n.applyFilters("i18n.gettext_"+s(e),r,t,e)):r},_x:u,_n:function(t,e,r,o){var i=l(o,void 0,t,e,r);return n?(i=n.applyFilters("i18n.ngettext",i,t,e,r,o),n.applyFilters("i18n.ngettext_"+s(o),i,t,e,r,o)):i},_nx:function(t,e,r,o,i){var a=l(i,o,t,e,r);return n?(a=n.applyFilters("i18n.ngettext_with_context",a,t,e,r,o,i),n.applyFilters("i18n.ngettext_with_context_"+s(i),a,t,e,r,o,i)):a},isRTL:function(){return"rtl"===u("ltr","text direction")},hasTranslation:function(t,e,o){var i,a,c=e?e+""+t:t,l=!(null===(i=r.data)||void 0===i||null===(a=i[null!=o?o:"default"])||void 0===a||!a[c]);return n&&(l=n.applyFilters("i18n.has_translation",l,t,e,o),l=n.applyFilters("i18n.has_translation_"+s(o),l,t,e,o)),l}}}(0,0,X));V.getLocaleData.bind(V),V.setLocaleData.bind(V),V.resetLocaleData.bind(V),V.subscribe.bind(V);var G=V.__.bind(V),J=(V._x.bind(V),V._n.bind(V),V._nx.bind(V),V.isRTL.bind(V),V.hasTranslation.bind(V),window.frmDom),H=J.tag,Q=J.div,W=J.a,Y=J.img;function tt(t){return tt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},tt(t)}function et(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function nt(t,e,n){return(e=function(t){var e=function(t){if("object"!=tt(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=tt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==tt(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var rt,ot=document.getElementById("post-body-content"),it=document.getElementById("".concat(m,"-sidebar")),at=((rt=W({className:"button button-primary frm-button-primary"})).setAttribute("role","button"),Q({id:"".concat(m,"-empty-state"),className:"frm-flex-col frm-flex-center frm-gap-md ".concat(r),children:[Y({src:"".concat(e,"/images/page-skeleton/empty-state.svg"),alt:G("Empty State","formidable")}),Q({className:"frmcenter",children:[H("h2",{className:"".concat(m,"-title frm-mb-0")}),H("p",{className:"".concat(m,"-text frm-mb-0")})]}),rt]}));null==ot||ot.appendChild(at);var ct=function(){var t=document.querySelector("#".concat(m,"-empty-state"));return{emptyState:t,emptyStateTitle:null==t?void 0:t.querySelector(".".concat(m,"-title")),emptyStateText:null==t?void 0:t.querySelector(".".concat(m,"-text")),emptyStateButton:null==t?void 0:t.querySelector(".button")}}(),lt=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if("object"!==S(t)||null===t)throw new Error("createPageElements: initialElements must be a non-null object");var e=t;return{getElements:function(){return e},addElements:function(t){if("object"!==S(t)||null===t)throw new Error("addElements: newElements must be a non-null object");e=h(h({},e),t)}}}(function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:{};if("object"!==yt(t)||null===t)throw new Error("createPageState: initialState must be a non-null object");var e=t;return{getState:function(){return e},getSingleState:function(t){var n=Reflect.get(e,t);return void 0===n?null:n},setState:function(t){if("object"!==yt(t)||null===t)throw new Error("setState: newState must be a non-null object");e=dt(dt({},e),t)},setSingleState:function(t,n){Reflect.has(e,t)&&Reflect.set(e,t,n)}}}({notEmptySearchText:!1,selectedCategory:v,selectedCategoryEl:mt}),bt=vt.getState,ht=vt.getSingleState,gt=vt.setState,St=vt.setSingleState,wt=function(t){var e,n=t.currentTarget,r=n.getAttribute("data-category"),o=bt(),a=o.selectedCategory,c=o.selectedCategoryEl,l=o.notEmptySearchText;if(a!==r){a=wp.hooks.applyFilters("frmPage.selectedCategory",r),c.classList.remove(i),(c=n).classList.add(i),gt({selectedCategory:a,selectedCategoryEl:c}),l&&((e=st().searchInput).value="",e.dispatchEvent(new Event("input",{bubbles:!0}))),wp.hooks.doAction("frmPage.onCategoryClick",a);var u=st().bodyContent;new s(u).fadeIn()}};function xt(t){"Enter"!==t.key&&" "!==t.key||(t.preventDefault(),wt(t))}var Ot=window.frmAddonsVars.addonRequestURL,_t="frm-addons",jt="available-addons",Et="active-addons",Pt="basic",kt="plus",At="business",Ct="elite",Tt=st(),Ft=Tt.bodyContent,It=Tt.sidebar;Ft.querySelectorAll(".frm-card-item:not(.plugin-card-formidable-pro)").forEach((function(t){var e=t.dataset.categories;switch(!0){case e.includes(At):t.setAttribute("data-categories","".concat(e,",").concat(Ct));break;case e.includes(kt):t.setAttribute("data-categories","".concat(e,",").concat(At,",").concat(Ct));break;case e.includes(Pt):t.setAttribute("data-categories","".concat(e,",").concat(kt,",").concat(At,",").concat(Ct))}})),ut({upgradeBanner:document.getElementById("frm-upgrade-banner"),availableCategory:It.querySelector(".".concat(m,'-cat[data-category="').concat(jt,'"]')),activeCategory:It.querySelector(".".concat(m,'-cat[data-category="').concat(Et,'"]')),categoriesTopDivider:It.querySelector(".".concat(m,"-divider")),basicPlanCategory:It.querySelector(".".concat(m,'-cat[data-category="').concat(Pt,'"]')),plusPlanCategory:It.querySelector(".".concat(m,'-cat[data-category="').concat(kt,'"]')),businessPlanCategory:It.querySelector(".".concat(m,'-cat[data-category="').concat(At,'"]')),elitePlanCategory:It.querySelector(".".concat(m,'-cat[data-category="').concat(Ct,'"]')),addonsList:document.getElementById("".concat(_t,"-list")),addons:Ft.querySelectorAll(".frm-card-item"),availableAddons:Ft.querySelectorAll(".frm-card-item:not(.frm-locked-item)"),addonsToggle:Ft.querySelectorAll(".frm_toggle_block"),bodyContentChildren:null==Ft?void 0:Ft.children});var Dt={};Dt[jt]=[],Dt[Et]=[];var Lt,qt=".".concat(m,"-cat-count");function Rt(){var t=st(),e=t.activeCategory,n=t.availableCategory,r=t.categoriesTopDivider,o=document.querySelectorAll(".frm-addon-active:not(.frm-locked-item)");0!==o.length?(Dt[Et]=o,e.querySelector(qt).textContent=o.length):d([e,n,r])}function Nt(){var t=bt().selectedCategory,e=st(),n=e.emptyState,r=e.emptyStateButton,o=e.emptyStateTitle,i=e.emptyStateText;n.setAttribute("data-view",t),o.textContent=G("No add-ons found","formidable"),i.textContent=G("Sorry, we didn't find any add-ons that match your criteria.","formidable"),r.textContent=G("Request Add-On","formidable"),r.href=Ot,r.setAttribute("target","_blank"),f([n,r])}function zt(t,e){if(t){if("string"==typeof t)return Bt(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Bt(t,e):void 0}}function Bt(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,i=!0,a=!1;return{s:function(){e=e.call(t)},n:function(){var t=e.next();return i=t.done,t},e:function(t){a=!0,o=t},f:function(){try{i||null==e.return||e.return()}finally{if(a)throw o}}}}(new Map([["frm-addon-not-installed",".frm-install-addon"],["frm-addon-installed",".frm-activate-addon"],["frm-addon-active",".frm-deactivate-addon"]]).entries());try{for(a.s();!(o=a.n()).done;){var c=(n=o.value,r=2,function(t){if(Array.isArray(t))return t}(n)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,o,i,a,c=[],l=!0,s=!1;try{if(i=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(c.push(r.value),c.length!==e);l=!0);}catch(t){s=!0,o=t}finally{try{if(!l&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(s)throw o}}return c}}(n,r)||zt(n,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),l=c[0],s=c[1];if(i.classList.contains(l)){(Lt=i.querySelector(s)).click();break}}}catch(t){a.e(t)}finally{a.f()}}};var $t=window.frmDom.search.init;function Ut(t,e){var n=t.foundSomething,r=t.notEmptySearchText;if(!e||"search"!==e.type||""!==e.target.value){var o=bt(),a=st().allItemsCategory;St("notEmptySearchText",r),o.notEmptySearchText||o.selectedCategory?(o.selectedCategory&&(function(t){var e=st(),n=e.bodyContent,r=e.bodyContentChildren,o=e.addonsList;t&&ht("selectedCategoryEl").classList.remove(i),d(r),p(o),new s(n).fadeIn()}(r),r&&St("selectedCategory","")),function(t){if(t){var e,n=st().emptyState;e=n,"none"!==window.getComputedStyle(e).getPropertyValue("display")&&y(n)}else Nt()}(n)):a.dispatchEvent(new Event("click",{bubbles:!0}))}}function Zt(){var t;st().categoryItems.forEach((function(t){u(t,wt),t.addEventListener("keydown",xt)})),wp.hooks.addAction("frmPage.onCategoryClick","frmAddonsPage",(function(t){!function(t){var e=st(),n=e.bodyContent,r=e.addons,o=e.emptyState,i=e.upgradeBanner;y(o),p(i),n.dataset.category=t,v!==t?(d(r),0===Dt[t].length?(Nt(),y(i)):f(Dt[t])):f(r)}(t)})),st().addonsToggle.forEach((function(t){return t.addEventListener("click",Mt)})),wp.hooks.addAction("frm_update_addon_state","frmAddonPage",(function(){Rt()})),t=st().searchInput,$t(t,"frm-card-item",{handleSearchResult:Ut})}var Kt;Kt=function(){(function(){var t,e,n,r,i,a,c,l,u,f,d=st(),y=d.sidebar,m=d.searchInput,v=d.bodyContent,b=new s(v);m.value="",Rt(),function(){var t=st(),e=t.bodyContent,n=t.availableCategory,r=t.availableAddons;if(Dt[jt]=r,n){n.querySelector(qt).textContent=r.length;var o=e.querySelector(".".concat(_t,"-available-count"));o&&(o.textContent=r.length)}}(),function(){var t=st(),e=t.allItemsCategory,n=t.addons;e.querySelector(qt).textContent=n.length}(),e=(t=st()).basicPlanCategory,n=t.plusPlanCategory,r=t.businessPlanCategory,i=t.elitePlanCategory,c=(a=function(t){return parseInt(t.querySelector(qt).textContent,10)||0})(e),l=a(n)-1,u=a(r)-1,f=a(i)-1,n.querySelector(qt).textContent=c+l,r.querySelector(qt).textContent=c+l+u,i.querySelector(qt).textContent=c+l+u+f,v.classList.remove(o),y.classList.remove(o),b.fadeIn(),p(y)})(),st().addons.forEach((function(t){var e=t.getAttribute("data-categories");e&&e.split(",").forEach((function(e){Dt[e]||(Dt[e]=[]),Dt[e].push(t)}))})),Zt()},"undefined"!=typeof document&&("complete"!==document.readyState&&"interactive"!==document.readyState?document.addEventListener("DOMContentLoaded",Kt):Kt())})()})(); \ No newline at end of file diff --git a/js/admin/addons.js b/js/admin/addons.js index 7087f836f2..0d9efe4266 100644 --- a/js/admin/addons.js +++ b/js/admin/addons.js @@ -5,13 +5,12 @@ */ wp.domReady( () => { - /** * Internal dependencies */ const { toggleAddonState } = window.frmAdminBuild; - document.addEventListener( 'click', ( event ) => { + document.addEventListener( 'click', event => { if ( event.target.matches( '.frm-uninstall-addon' ) ) { event.preventDefault(); toggleAddonState( event.target, 'frm_uninstall_addon' ); @@ -19,5 +18,5 @@ wp.domReady( () => { event.preventDefault(); toggleAddonState( event.target, 'frm_deactivate_addon' ); } - }); -}); + } ); +} ); diff --git a/js/admin/applications.js b/js/admin/applications.js index 055daed078..42935a02f7 100644 --- a/js/admin/applications.js +++ b/js/admin/applications.js @@ -39,8 +39,8 @@ getApplicationDataAndLoadPage(); } - function getUrlParamsAndMaybeOpenTemplateModal( _, { data } = {}) { - const url = new URL( window.location.href ); + function getUrlParamsAndMaybeOpenTemplateModal( _, { data } = {} ) { + const url = new URL( window.location.href ); const urlParams = url.searchParams; if ( ! urlParams.get( 'triggerViewApplicationModal' ) ) { return; @@ -67,7 +67,7 @@ container.innerHTML = ''; - const contentWrapper = div({ className: 'frm-applications-index-content' }); + const contentWrapper = div( { className: 'frm-applications-index-content' } ); container.appendChild( contentWrapper ); const customTemplatesNav = getCustomTemplatesNav(); @@ -85,7 +85,7 @@ } function getCustomTemplatesNav() { - return div({ + return div( { className: 'frm-application-templates-nav wrap', children: [ tag( @@ -96,35 +96,35 @@ } ) ] - }); + } ); } function addCustomApplicationsPlaceholder( customTemplatesNav ) { - const placeholder = div({ + const placeholder = div( { id: 'frm_custom_applications_placeholder', className: 'frm_placeholder_block', - child: div({ + child: div( { className: 'frm_grid_container', children: [ - div({ + div( { className: 'frm10 frm_clearfix', children: [ - img({ src: getUrlToApplicationsImages() + 'folder.svg' }), + img( { src: getUrlToApplicationsImages() + 'folder.svg' } ), tag( 'h3', __( 'Improve your workflow with applications', 'formidable' ) ), div( __( 'Applications help to organize your workspace by combining forms, Views, and pages into a full solution.', 'formidable' ) ), ] - }), - div({ + } ), + div( { className: 'frm2', - child: a({ + child: a( { className: 'frm-button-primary frm-gradient', text: __( 'Upgrade to Pro', 'formidable' ), href: frmApplicationsVars.proUpgradeUrl - }) - }) + } ) + } ) ] - }) - }); + } ) + } ); customTemplatesNav.parentNode.insertBefore( placeholder, customTemplatesNav.nextElementSibling ); } @@ -133,10 +133,10 @@ } function renderFormidableTemplates( contentWrapper, templates ) { - elements.templatesGrid = div({ + elements.templatesGrid = div( { id: 'frm_application_templates_grid', className: 'frm_grid_container frm-application-cards-grid' - }); + } ); addTemplatesToGrid( templates ); contentWrapper.appendChild( getTemplatesNav() ); contentWrapper.appendChild( elements.templatesGrid ); @@ -159,7 +159,7 @@ } function getTemplatesNav() { - return div({ + return div( { className: 'frm-application-templates-nav wrap', children: [ tag( @@ -172,7 +172,7 @@ getCategoryOptions(), getTemplateSearch() ] - }); + } ); } function getCategoryOptions() { @@ -182,7 +182,7 @@ } const categories = [ getAllItemsCategory() ].concat( state.categories ); - const wrapper = div({ id: 'frm_application_category_filter', className: 'subsubsub' }); + const wrapper = div( { id: 'frm_application_category_filter', className: 'subsubsub' } ); categories.forEach( addCategoryToWrapper ); function addCategoryToWrapper( category, index ) { @@ -241,11 +241,10 @@ const placeholder = __( 'Search Templates', 'formidable' ); const targetClassName = 'frm-application-template-card'; const args = { handleSearchResult: handleTemplateSearch }; - const wrappedInput = newSearchInput( id, placeholder, targetClassName, args ); - return wrappedInput; + return newSearchInput( id, placeholder, targetClassName, args ); } - function handleTemplateSearch({ foundSomething, notEmptySearchText }) { + function handleTemplateSearch( { foundSomething, notEmptySearchText } ) { if ( false === elements.noTemplateSearchResultsPlaceholder ) { elements.noTemplateSearchResultsPlaceholder = getNoResultsPlaceholder(); elements.templatesGrid.appendChild( elements.noTemplateSearchResultsPlaceholder ); @@ -263,13 +262,13 @@ function createApplicationCard( data ) { const isTemplate = ! data.termId; - const card = div({ + const card = div( { className: 'frm-application-card frm-card-item', children: [ getCardHeader(), - div({ className: 'frm-flex' }) + div( { className: 'frm-flex' } ) ] - }); + } ); if ( isTemplate ) { card.classList.add( 'frm-application-template-card' ); @@ -284,7 +283,7 @@ } const hookName = 'frm_application_index_card'; - const args = { data }; + const args = { data }; wp.hooks.doAction( hookName, card, args ); function getCardHeader() { @@ -292,25 +291,25 @@ 'h3', { children: [ - svg({ href: '#frm_lock_icon' }), - span({ className: 'frm-inner-text', text: data.name }) + svg( { href: '#frm_lock_icon' } ), + span( { className: 'frm-inner-text', text: data.name } ) ] } ); - const header = div({ + const header = div( { children: [ titleWrapper ] - }); + } ); const templateControl = getUseThisTemplateControl( data ); - if ( templateControl.classList.contains('frm-delete-application-trigger' ) ) { + if ( templateControl.classList.contains( 'frm-delete-application-trigger' ) ) { header.appendChild( templateControl ); } else { titleWrapper.appendChild( templateControl ); } if ( data.isNew ) { - titleWrapper.appendChild( span({ className: 'frm-new-pill frm-meta-tag frm-fadein', text: __( 'NEW', 'formidable' ) }) ); + titleWrapper.appendChild( span( { className: 'frm-new-pill frm-meta-tag frm-fadein', text: __( 'NEW', 'formidable' ) } ) ); } const counter = getItemCounter(); @@ -329,17 +328,17 @@ function getCardContent() { const thumbnailFolderUrl = getUrlToApplicationsImages() + 'thumbnails/'; - const filenameToUse = data.hasLiteThumbnail ? data.key + ( data.isWebp ? '.webp' : '.png' ) : 'placeholder.svg'; - return div({ + const filenameToUse = data.hasLiteThumbnail ? data.key + ( data.isWebp ? '.webp' : '.png' ) : 'placeholder.svg'; + return div( { className: 'frm-application-card-image-wrapper', - child: img({ src: thumbnailFolderUrl + filenameToUse }) - }); + child: img( { src: thumbnailFolderUrl + filenameToUse } ) + } ); } return card; } - function filterItemCount( counter, { data }) { + function filterItemCount( counter, { data } ) { const hasForms = 'undefined' !== typeof data.formCount && '0' !== data.formCount; const hasViews = 'undefined' !== typeof data.viewCount && '0' !== data.viewCount; const hasPages = 'undefined' !== typeof data.pageCount && '0' !== data.pageCount; @@ -348,7 +347,7 @@ return counter; } - counter = div({ className: 'frm-application-item-count' }); + counter = div( { className: 'frm-application-item-count' } ); if ( hasForms ) { addCount( data.formCount, __( 'Forms', 'formidable' ), __( 'Form', 'formidable' ) ); @@ -377,10 +376,10 @@ } function getUseThisTemplateControl( data ) { - let control = a({ + let control = a( { className: 'button frm-button-secondary frm-button-sm frm-fadein', text: __( 'Learn More', 'formidable' ) - }); + } ); control.setAttribute( 'role', 'button' ); /* translators: %s: Application Template Name */ const ariaDescription = sprintf( __( '%s Template', 'formidable' ), data.name ); @@ -423,24 +422,24 @@ if ( data.upgradeUrl ) { children.push( - div({ + div( { className: 'frm_note_style2', children: [ span( /* translators: %s: The required license type (ie. Plus, Business, or Elite) */ sprintf( __( 'Access to this application requires the %s plan.', 'formidable' ), data.requires ) ), - a({ + a( { className: 'frm-gradient frm-button-primary frm-button-sm', text: getUpgradeNowText(), href: data.upgradeUrl - }) + } ) ] - }) + } ) ); } - const placeholderImage = img({ src: getUrlToApplicationsImages() + 'placeholder.png' }); + const placeholderImage = img( { src: getUrlToApplicationsImages() + 'placeholder.png' } ); if ( placeholderImage.complete ) { setTimeout( maybeCenterViewApplicationModal, 0 ); } else { @@ -448,38 +447,38 @@ } const detailsChildren = [ - div({ + div( { className: 'frm-application-modal-label', text: __( 'Description', 'formidable' ) - }), + } ), div( data.description ) ]; if ( data.usedAddons && data.usedAddons.length ) { detailsChildren.push( - div({ + div( { className: 'frm-application-modal-label', text: __( 'Required Add-ons', 'formidable-pro' ) - }), + } ), getBasicList( data.usedAddons ) ); } children.push( - div({ + div( { className: 'frm-application-image-wrapper', child: placeholderImage - }), - div({ + } ), + div( { className: 'frm-application-modal-details', children: detailsChildren - }) + } ) ); - const output = div({ children }); + const output = div( { children } ); const hookName = 'frm_view_application_modal_content'; - const args = { data }; + const args = { data }; wp.hooks.doAction( hookName, output, args ); return output; @@ -507,21 +506,21 @@ at: 'center', of: window }; - jQuery( modal ).dialog({ position }); + jQuery( modal ).dialog( { position } ); } function getViewApplicationModalFooter( data ) { - const viewDemoSiteButton = footerButton({ + const viewDemoSiteButton = footerButton( { text: __( 'Learn More', 'formidable' ), buttonType: 'secondary' - }); + } ); viewDemoSiteButton.href = data.link; viewDemoSiteButton.target = '_blank'; - let primaryActionButton = footerButton({ + let primaryActionButton = footerButton( { text: getUpgradeNowText(), buttonType: 'primary' - }); + } ); if ( data.upgradeUrl ) { primaryActionButton.classList.remove( 'dismiss' ); @@ -529,11 +528,11 @@ } const hookName = 'frm_view_application_modal_primary_action_button'; - const args = { data }; + const args = { data }; primaryActionButton = wp.hooks.applyFilters( hookName, primaryActionButton, args ); - return div({ + return div( { children: [ viewDemoSiteButton, primaryActionButton ] - }); + } ); } }() ); diff --git a/js/admin/deactivation-feedback.js b/js/admin/deactivation-feedback.js index 5c99b8c74e..0318a4a0d0 100644 --- a/js/admin/deactivation-feedback.js +++ b/js/admin/deactivation-feedback.js @@ -8,7 +8,7 @@ const Modal = { init: function( id, width ) { const $info = jQuery( id ); - const self = this; + const self = this; if ( ! $info.length ) { return false; @@ -64,7 +64,7 @@ text: FrmDeactivationFeedbackI18n.skip_text, href: deactivationUrl, className: 'frm-skip-link' - }); + } ); formEl.querySelector( '.frm_submit' ).prepend( btn ); }; @@ -87,22 +87,22 @@ const response = fetch( url, { method: 'GET' - }); + } ); response .then( response => response.json() ) .then( response => { const wrapper = document.getElementById( 'frm-deactivation-form-wrapper' ); - const form = response.renderedHtml.replace( /]*(formidableforms.css|action=frmpro_css)[^>]*>/gi, '' ); + const form = response.renderedHtml.replace( /]*(formidableforms.css|action=frmpro_css)[^>]*>/gi, '' ); jQuery( wrapper ).html( form ); wrapper.setAttribute( 'data-slug', pluginSlug ); addSkipBtn( wrapper ); deactivationModal.dialog( 'open' ); - }) + } ) .catch( error => { console.error( error ); - }); + } ); }; frmDom.util.documentOn( 'click', selectors, onClickDeactivate ); @@ -110,5 +110,5 @@ document.addEventListener( 'frmFormCompleteBeforeReplace', function( event ) { document.getElementById( 'frm-deactivation-modal-icon' ).remove(); window.location.href = deactivationUrl; - }); + } ); }() ); diff --git a/js/admin/dom.js b/js/admin/dom.js index 0444a25455..e9264fa7e7 100644 --- a/js/admin/dom.js +++ b/js/admin/dom.js @@ -10,15 +10,15 @@ } const modal = { - maybeCreateModal: ( id, { title, content, footer, width } = {}) => { + maybeCreateModal: ( id, { title, content, footer, width } = {} ) => { let modal = document.getElementById( id ); if ( ! modal ) { modal = createEmptyModal( id ); - const titleElement = div({ + const titleElement = div( { className: 'frm-modal-title' - }); + } ); if ( 'string' === typeof title ) { titleElement.textContent = title; @@ -27,28 +27,28 @@ const a = tag( 'a', { - child: svg({ href: '#frm_close_icon' }), + child: svg( { href: '#frm_close_icon' } ), className: 'dismiss' } ); const postbox = modal.querySelector( '.postbox' ); postbox.appendChild( - div({ + div( { className: 'frm_modal_top', children: [ titleElement, - div({ child: a }) + div( { child: a } ) ] - }) + } ) ); postbox.appendChild( - div({ className: 'frm_modal_content' }) + div( { className: 'frm_modal_content' } ) ); if ( footer ) { postbox.appendChild( - div({ className: 'frm_modal_footer' }) + div( { className: 'frm_modal_footer' } ) ); } } else if ( 'string' === typeof title ) { @@ -57,7 +57,7 @@ } if ( ! content && ! footer ) { - makeModalIntoADialogAndOpen( modal, { width }); + makeModalIntoADialogAndOpen( modal, { width } ); return modal; } @@ -121,7 +121,7 @@ } return Promise.resolve( json.data ); }, - doJsonPost: async function( action, formData, { signal } = {}) { + doJsonPost: async function( action, formData, { signal } = {} ) { formData.append( 'nonce', frmGlobal.nonce ); const init = { method: 'POST', @@ -131,7 +131,7 @@ init.signal = signal; } const response = await fetch( ajaxurl + '?action=frm_' + action, init ); - const json = await response.json(); + const json = await response.json(); if ( ! json.success ) { return Promise.reject( json.data || 'JSON result is not successful' ); } @@ -145,11 +145,11 @@ const id = $select.is( '[id]' ) ? $select.attr( 'id' ).replace( '[]', '' ) : false; let labelledBy = id ? jQuery( '#for_' + id ) : false; - labelledBy = id && labelledBy.length ? 'aria-labelledby="' + labelledBy.attr( 'id' ) + '"' : ''; + labelledBy = id && labelledBy.length ? 'aria-labelledby="' + labelledBy.attr( 'id' ) + '"' : ''; // Set empty title attributes so that none of the dropdown options include title attributes. $select.find( 'option' ).attr( 'title', ' ' ); - $select.multiselect({ + $select.multiselect( { templates: { popupContainer: '
', option: '', @@ -171,14 +171,14 @@ if ( jQuery( '.multiselect-container.frm-dropdown-menu' ).is( ':visible' ) ) { jQuery( event.currentTarget ).removeClass( 'open' ); } - }); + } ); } const $dropdown = $select.next( '.frm-btn-group.dropdown' ); $dropdown.find( '.dropdown-item' ).each( function() { - const option = this; - const dropdownInput = option.querySelector( 'input[type="checkbox"], input[type="radio"]' ); + const option = this; + const dropdownInput = option.querySelector( 'input[type="checkbox"], input[type="radio"]' ); if ( dropdownInput ) { option.setAttribute( 'role', 'checkbox' ); option.setAttribute( 'aria-checked', dropdownInput.checked ? 'true' : 'false' ); @@ -189,8 +189,8 @@ onChange: function( $option, checked ) { $select.trigger( 'frm-multiselect-changed', $option, checked ); - const $dropdown = $select.next( '.frm-btn-group.dropdown' ); - const optionValue = $option.val(); + const $dropdown = $select.next( '.frm-btn-group.dropdown' ); + const optionValue = $option.val(); const $dropdownItem = $dropdown.find( 'input[value="' + optionValue + '"]' ).closest( 'button.dropdown-item' ); if ( $dropdownItem.length ) { $dropdownItem.attr( 'aria-checked', checked ? 'true' : 'false' ); @@ -200,7 +200,7 @@ setTimeout( () => $dropdownItem.get( 0 ).focus(), 0 ); } } - }); + } ); } }; @@ -261,12 +261,12 @@ * * @since 4.10.01 Add container param to init autocomplete elements inside an element. * - * @param {String} type Type of data. Accepts `page` or `user`. - * @param {String|Object} container Container class or element. Default is null. + * @param {string} type Type of data. Accepts `page` or `user`. + * @param {string|Object} container Container class or element. Default is null. */ initAutocomplete: function( type, container ) { const basedUrlParams = '?action=frm_' + type + '_search&nonce=' + frmGlobal.nonce; - const elements = ! container ? jQuery( '.frm-' + type + '-search' ) : jQuery( container ).find( '.frm-' + type + '-search' ); + const elements = ! container ? jQuery( '.frm-' + type + '-search' ) : jQuery( container ).find( '.frm-' + type + '-search' ); elements.each( initAutocompleteForElement ); @@ -288,7 +288,7 @@ } } - element.autocomplete({ + element.autocomplete( { delay: 100, minLength: 0, source: source, @@ -318,19 +318,19 @@ jQuery( this ).autocomplete( 'option', 'appendTo', $container ); } - }) - .on( 'focus', function() { + } ) + .on( 'focus', function() { // Show options on click to make it work more like a dropdown. - if ( this.value === '' || this.nextElementSibling.value < 1 ) { - jQuery( this ).autocomplete( 'search', this.value ); - } - }) - .data( 'ui-autocomplete' )._renderItem = function( ul, item ) { - return jQuery( '
  • ' ) - .attr( 'aria-label', item.label ) - .append( jQuery( '
    ' ).text( item.label ) ) - .appendTo( ul ); - }; + if ( this.value === '' || this.nextElementSibling.value < 1 ) { + jQuery( this ).autocomplete( 'search', this.value ); + } + } ) + .data( 'ui-autocomplete' )._renderItem = function( ul, item ) { + return jQuery( '
  • ' ) + .attr( 'aria-label', item.label ) + .append( jQuery( '
    ' ).text( item.label ) ) + .appendTo( ul ); + }; } }, @@ -377,13 +377,13 @@ className: 'frm-search', children: [ label, - span({ className: 'frmfont frm_search_icon' }), + span( { className: 'frmfont frm_search_icon' } ), searchInput ] } ); }, - newSearchInput: ( id, placeholder, targetClassName, args = {}) => { + newSearchInput: ( id, placeholder, targetClassName, args = {} ) => { const input = getAutoSearchInput( id, placeholder ); const wrappedSearch = search.wrapInput( input, placeholder ); search.init( input, targetClassName, args ); @@ -398,7 +398,7 @@ return wrappedSearch; }, - init: ( input, targetClassName, { handleSearchResult } = {}) => { + init: ( input, targetClassName, { handleSearchResult } = {} ) => { input.setAttribute( 'type', 'search' ); input.setAttribute( 'autocomplete', 'off' ); @@ -414,7 +414,7 @@ let foundSomething = false; items.forEach( toggleSearchClassesForItem ); if ( 'function' === typeof handleSearchResult ) { - handleSearchResult({ foundSomething, notEmptySearchText }, event ); + handleSearchResult( { foundSomething, notEmptySearchText }, event ); } function toggleSearchClassesForItem( item ) { @@ -464,10 +464,10 @@ * * @since 6.0 * - * @param {String} event Event name. - * @param {String} selector Selector. + * @param {string} event Event name. + * @param {string} selector Selector. * @param {Function} handler Handler. - * @param {Boolean|Object} options Options to be added to `addEventListener()` method. Default is `false`. + * @param {boolean|Object} options Options to be added to `addEventListener()` method. Default is `false`. */ documentOn: ( event, selector, handler, options ) => { if ( 'undefined' === typeof options ) { @@ -493,11 +493,11 @@ * @param {string} name - The name of the cookie. * @return {string|null} The value of the cookie, or undefined if the cookie does not exist. */ - getCookie: ( name ) => { - const cookie = document.cookie.split('; ').find( cookie => cookie.startsWith( `${name}=` ) ); + getCookie: name => { + const cookie = document.cookie.split( '; ' ).find( cookie => cookie.startsWith( `${ name }=` ) ); if ( cookie ) { - return cookie.split( '=' )[1]; + return cookie.split( '=' )[ 1 ]; } return null; }, @@ -512,12 +512,12 @@ setCookie: ( name, value, minutes ) => { const expires = new Date(); expires.setTime( expires.getTime() + ( minutes * 60 * 1000 ) ); - document.cookie = `${name}=${value};expires=${expires.toUTCString()};path=/`; + document.cookie = `${ name }=${ value };expires=${ expires.toUTCString() };path=/`; } }; const wysiwyg = { - init( editor, { setupCallback, height, addFocusEvents } = {}) { + init( editor, { setupCallback, height, addFocusEvents } = {} ) { if ( isTinyMceActive() ) { setTimeout( resetTinyMce, 0 ); } else { @@ -533,18 +533,18 @@ } const id = editor.id; - window.quicktags({ + window.quicktags( { name: 'qt_' + id, id: id, canvas: editor, settings: { id }, toolbar: document.getElementById( 'qt_' + id + '_toolbar' ), theButtons: {} - }); + } ); } function initRichText() { - const key = Object.keys( tinyMCEPreInit.mceInit )[0]; + const key = Object.keys( tinyMCEPreInit.mceInit )[ 0 ]; const orgSettings = tinyMCEPreInit.mceInit[ key ]; const settings = Object.assign( @@ -567,7 +567,7 @@ editor.on( 'focusout', function() { editor.on( 'focusin', focusInCallback ); - }); + } ); } if ( setupCallback ) { setupCallback( editor ); @@ -628,10 +628,10 @@ return function( child, uniqueClassName ) { let element = modal.querySelector( '.' + uniqueClassName ); if ( null === element ) { - element = div({ + element = div( { child: child, className: uniqueClassName - }); + } ); appendTo.appendChild( element ); } else { redraw( element, child ); @@ -640,20 +640,20 @@ } function createEmptyModal( id ) { - const modal = div({ id, className: 'frm-modal' }); - const postbox = div({ className: 'postbox' }); - const metaboxHolder = div({ className: 'metabox-holder', child: postbox }); + const modal = div( { id, className: 'frm-modal' } ); + const postbox = div( { className: 'postbox' } ); + const metaboxHolder = div( { className: 'metabox-holder', child: postbox } ); modal.appendChild( metaboxHolder ); document.body.appendChild( modal ); return modal; } - function makeModalIntoADialogAndOpen( modal, { width } = {}) { + function makeModalIntoADialogAndOpen( modal, { width } = {} ) { const bodyWithModalClassName = 'frm-body-with-open-modal'; const $modal = jQuery( modal ); if ( ! $modal.hasClass( 'frm-dialog' ) ) { - $modal.dialog({ + $modal.dialog( { dialogClass: 'frm-dialog', modal: true, autoOpen: false, @@ -671,7 +671,7 @@ $modal.on( 'click', 'a.dismiss', function( event ) { event.preventDefault(); $modal.dialog( 'close' ); - }); + } ); const overlay = document.querySelector( '.ui-widget-overlay' ); if ( overlay ) { @@ -689,7 +689,7 @@ jQuery( '#wpwrap' ).removeClass( 'frm_overlay' ); jQuery( '.spinner' ).css( 'visibility', 'hidden' ); } - }); + } ); } document.body.classList.add( bodyWithModalClassName ); @@ -706,7 +706,7 @@ return tag( 'span', args ); } - function a( args = {}) { + function a( args = {} ) { const anchor = tag( 'a', args ); anchor.setAttribute( 'href', 'string' === typeof args.href ? args.href : '#' ); if ( 'string' === typeof args.target ) { @@ -715,7 +715,7 @@ return anchor; } - function img( args = {}) { + function img( args = {} ) { const output = tag( 'img', args ); if ( 'string' === typeof args.src ) { output.setAttribute( 'src', args.src ); @@ -731,10 +731,10 @@ * * @since 6.0 * - * @param {String} inputId - * @param {String} labelText - * @param {String} inputName - * @returns {Element} + * @param {string} inputId + * @param {string} labelText + * @param {string} inputName + * @return {Element} The div element containing the label and input. */ function labelledTextInput( inputId, labelText, inputName ) { const label = tag( 'label', labelText ); @@ -750,7 +750,7 @@ input.type = 'text'; input.setAttribute( 'name', inputName ); - return div({ children: [ label, input ] }); + return div( { children: [ label, input ] } ); } /** @@ -758,11 +758,11 @@ * * @since 6.4.1 Accept a string as one of `children` to append a text node inside the element. * - * @param {String} type Element tag name. + * @param {string} type Element tag name. * @param {Object} args The args. - * @return {Object} + * @return {Object} The created DOM element. */ - function tag( type, args = {}) { + function tag( type, args = {} ) { const output = document.createElement( type ); if ( 'string' === typeof args ) { @@ -784,7 +784,7 @@ if ( 'string' === typeof child ) { output.appendChild( document.createTextNode( child ) ); } else { - output.appendChild( child ) + output.appendChild( child ); } } ); } else if ( child ) { @@ -794,13 +794,13 @@ } if ( data ) { Object.keys( data ).forEach( function( dataKey ) { - output.setAttribute( 'data-' + dataKey, data[dataKey] ); - }); + output.setAttribute( 'data-' + dataKey, data[ dataKey ] ); + } ); } return output; } - function svg({ href, classList } = {}) { + function svg( { href, classList } = {} ) { const namespace = 'http://www.w3.org/2000/svg'; const output = document.createElementNS( namespace, 'svg' ); if ( classList ) { @@ -820,18 +820,18 @@ * Pop up a success message in the lower right corner. * It then fades out and gets deleted automatically. * - * @param {HTMLElement|String} content - * @returns {void} + * @param {HTMLElement|string} content + * @return {void} */ function success( content ) { - const container = document.getElementById( 'wpbody' ); - const notice = div({ + const container = document.getElementById( 'wpbody' ); + const notice = div( { className: 'frm_updated_message frm-floating-success-message', - child: div({ + child: div( { className: 'frm-satisfied', child: 'string' === typeof content ? document.createTextNode( content ) : content - }) - }); + } ) + } ); container.appendChild( notice ); setTimeout( @@ -842,7 +842,7 @@ function setAttributes( element, attrs ) { Object.entries( attrs ).forEach( - ([ key, value ]) => element.setAttribute( key, value ) + ( [ key, value ] ) => element.setAttribute( key, value ) ); } @@ -887,13 +887,13 @@ return svg( svgArgs ); } - const newNode = document.createElement( tagType ); - - if ( 'undefined' === typeof allowedHtml[ tagType ]) { + if ( 'undefined' === typeof allowedHtml[ tagType ] ) { // Tag type is not allowed. return document.createTextNode( '' ); } + const newNode = document.createElement( tagType ); + allowedHtml[ tagType ].forEach( allowedTag => { if ( node.hasAttribute( allowedTag ) ) { diff --git a/js/admin/embed.js b/js/admin/embed.js index 92175f41d9..3f1472c1a8 100644 --- a/js/admin/embed.js +++ b/js/admin/embed.js @@ -93,15 +93,15 @@ } function getModalFooter() { - const doneButton = footerButton({ + const doneButton = footerButton( { text: __( 'Done', 'formidable' ), buttonType: 'primary' - }); + } ); - const cancelButton = footerButton({ + const cancelButton = footerButton( { text: __( 'Back', 'formidable' ), buttonType: 'cancel' - }); + } ); cancelButton.addEventListener( 'click', function( event ) { @@ -110,9 +110,9 @@ } ); - return div({ + return div( { children: [ doneButton, cancelButton ] - }); + } ); } function offsetModalY( $modal, amount ) { @@ -125,7 +125,7 @@ } function getModalOptions() { - const content = div({ className: 'frm-embed-modal-content frm_wrap' }); + const content = div( { className: 'frm-embed-modal-content frm_wrap' } ); const typeDescription = getTypeDescription(); /* translators: %s type: ie form, view. */ @@ -156,7 +156,7 @@ content.classList.add( 'frm-loading-page-options' ); - jQuery.ajax({ + jQuery.ajax( { type: 'POST', url: ajaxurl, data: { @@ -165,7 +165,7 @@ }, dataType: 'json', success: addExistingPageDropdown - }); + } ); function addExistingPageDropdown( response ) { if ( 'object' !== typeof response || 'string' !== typeof response.html ) { @@ -222,7 +222,7 @@ const pageId = pageDropdown.value; if ( '0' === pageId || '' === pageId ) { - const error = div({ className: 'frm_error_style' }); + const error = div( { className: 'frm_error_style' } ); error.setAttribute( 'role', 'alert' ); error.textContent = __( 'Please select a page', 'formidable' ); content.insertBefore( error, title.nextElementSibling ); @@ -241,7 +241,7 @@ callback: () => { content.innerHTML = ''; - const wrapper = div({ className: 'field-group' }); + const wrapper = div( { className: 'field-group' } ); const form = tag( 'form' ); const createPageWithShortcode = () => { @@ -256,7 +256,7 @@ nonce: frmGlobal.nonce } ); - jQuery.ajax({ + jQuery.ajax( { type: 'POST', url: ajaxurl, data, @@ -266,7 +266,7 @@ window.location.href = response.redirect; } } - }); + } ); }; form.addEventListener( @@ -346,7 +346,7 @@ } } - function getModalOption({ icon, label, description, callback }) { + function getModalOption( { icon, label, description, callback } ) { const output = div(); output.appendChild( wrapModalOptionIcon( icon ) ); output.className = 'frm-embed-modal-option'; @@ -358,7 +358,7 @@ textWrapper.appendChild( div( description ) ); output.appendChild( textWrapper ); - output.appendChild( div({ className: 'caret' }) ); + output.appendChild( div( { className: 'caret' } ) ); output.addEventListener( 'click', @@ -371,10 +371,10 @@ } function wrapModalOptionIcon( iconHref ) { - return div({ + return div( { className: 'frm-icon-wrapper', - child: svg({ href: iconHref }) - }); + child: svg( { href: iconHref } ) + } ); } function getEmbedFormManualExamples() { @@ -400,16 +400,16 @@ return examples; } - function getEmbedExample({ label, example, link, linkLabel }) { - let unique, element, labelElement, exampleElement, linkElement; + function getEmbedExample( { label, example, link, linkLabel } ) { + const unique = getAutoId(); - unique = getAutoId(); - element = div(); - - labelElement = getLabel( label ); + const labelElement = getLabel( label ); labelElement.id = 'frm_embed_example_label_' + unique; + + const element = div(); element.appendChild( labelElement ); + let exampleElement; if ( example.length > 80 ) { exampleElement = tag( 'textarea' ); } else { @@ -424,7 +424,7 @@ exampleElement.setAttribute( 'tabindex', -1 ); if ( 'undefined' !== typeof link && 'undefined' !== typeof linkLabel ) { - linkElement = tag( 'a' ); + const linkElement = tag( 'a' ); linkElement.href = link; linkElement.textContent = linkLabel; linkElement.setAttribute( 'target', '_blank' ); @@ -443,7 +443,7 @@ } function getCopyIcon( label ) { - const icon = svg({ href: '#frm_clone_icon' }); + const icon = svg( { href: '#frm_clone_icon' } ); icon.id = 'frm_copy_embed_' + getAutoId(); icon.setAttribute( 'tabindex', 0 ); icon.setAttribute( 'role', 'button' ); @@ -503,7 +503,7 @@ * Can be used for any UI that requires a unique id. * Not to be used in data. * - * @returns {integer} + * @return {integer} The unique id. */ function getAutoId() { return ++autoId; diff --git a/js/admin/entries.js b/js/admin/entries.js index 2d173bb132..cb5556e9d2 100644 --- a/js/admin/entries.js +++ b/js/admin/entries.js @@ -5,7 +5,6 @@ */ wp.domReady( () => { - /** * Internal dependencies */ @@ -46,6 +45,6 @@ wp.domReady( () => { setTimeout( () => { applyZebraStriping( '.frm-alt-table', newShowState === 'true' ? '' : 'frm-empty-row' ); }, newShowState === 'true' ? 0 : 200 ); - }); + } ); } -}); +} ); diff --git a/js/admin/legacy-views.js b/js/admin/legacy-views.js index ac624cbecb..e818d4a989 100644 --- a/js/admin/legacy-views.js +++ b/js/admin/legacy-views.js @@ -15,13 +15,11 @@ document.addEventListener( 'frm_legacy_views_handle_field_focus', function( event ) { const { idAttrValue } = event.frmData; toggleAllowedShortcodes( idAttrValue ); - }); - }); + } ); + } ); function viewInit() { - let $addRemove, - $advInfo = jQuery( document.getElementById( 'frm_adv_info' ) ); - + const $advInfo = jQuery( document.getElementById( 'frm_adv_info' ) ); $advInfo.before( '
    ' ); setupMenuOffset(); @@ -31,7 +29,7 @@ // Show loading indicator. jQuery( '#publish' ).on( 'mousedown', function() { this.classList.add( 'frm_loading_button' ); - }); + } ); // move content tabs jQuery( '#frm_dyncontent .handlediv' ).before( jQuery( '#frm_dyncontent .nav-menus-php' ) ); @@ -49,7 +47,7 @@ jQuery( document.getElementById( 'form_id' ) ).on( 'change', displayFormSelected ); - $addRemove = jQuery( '.frm_repeat_rows' ); + const $addRemove = jQuery( '.frm_repeat_rows' ); $addRemove.on( 'click', '.frm_add_order_row', addOrderRow ); $addRemove.on( 'click', '.frm_add_where_row', addWhereRow ); $addRemove.on( 'change', '.frm_insert_where_options', insertWhereOptions ); @@ -67,24 +65,24 @@ slug = slug.trim().toLowerCase(); if ( Array.isArray( frmAdminJs.unsafe_params ) && frmAdminJs.unsafe_params.includes( slug ) ) { msg = frmAdminJs.slug_is_reserved; - msg = msg.replace( '****', addHtmlTags( slug, 'strong' ) ); + msg = msg.replace( '****', addHtmlTags( slug, 'strong' ) ); msg += '

    '; msg += addHtmlTags( '' + frmAdminJs.reserved_words + '', 'div' ); infoModal( msg ); } } - + /** * Checks View filter value for params named with reserved words and displays a message if any are found. */ function checkFilterParamNames() { - let regEx = /\[\s*get\s*param\s*=\s*['"]?([a-zA-Z-_]+)['"]?/ig, - filterValue = jQuery( this ).val(), - match = regEx.exec( filterValue ), - unsafeParams = ''; + const regEx = /\[\s*get\s*param\s*=\s*['"]?([a-zA-Z-_]+)['"]?/ig; + const filterValue = jQuery( this ).val(); + let match = regEx.exec( filterValue ); + let unsafeParams = ''; while ( match !== null ) { - if ( Array.isArray( frmAdminJs.unsafe_params ) && frmAdminJs.unsafe_params.includes( match[1]) ) { + if ( Array.isArray( frmAdminJs.unsafe_params ) && frmAdminJs.unsafe_params.includes( match[ 1 ] ) ) { if ( unsafeParams !== '' ) { unsafeParams += '", "' + match[ 1 ]; } else { @@ -95,8 +93,8 @@ } if ( unsafeParams !== '' ) { - let msg = frmAdminJs.param_is_reserved; - msg = msg.replace( '****', addHtmlTags( unsafeParams, 'strong' ) ); + let msg = frmAdminJs.param_is_reserved; + msg = msg.replace( '****', addHtmlTags( unsafeParams, 'strong' ) ); msg += '

    '; msg += ' ' + frmAdminJs.reserved_words + ''; @@ -123,7 +121,7 @@ if ( this.id ) { toggleAllowedShortcodes( this.id.slice( 3, -5 ) ); } - }); + } ); DOM.events.add( DOM.select( '.wp-editor-wrap' ), 'mouseout', function() { if ( jQuery( '*:focus' ).length > 0 ) { return; @@ -131,7 +129,7 @@ if ( this.id ) { toggleAllowedShortcodes( this.id.slice( 3, -5 ) ); } - }); + } ); } else { jQuery( '#frm_dyncontent' ).on( 'mouseover mouseout', '.wp-editor-wrap', function() { if ( jQuery( '*:focus' ).length > 0 ) { @@ -140,7 +138,7 @@ if ( this.id ) { toggleAllowedShortcodes( this.id.slice( 3, -5 ) ); } - }); + } ); } } @@ -148,8 +146,8 @@ const urlQuery = window.location.search.substring( 1 ); if ( urlQuery.indexOf( 'action=edit' ) === -1 ) { document.getElementById( 'post-visibility-display' ).textContent = frmAdminJs.private_label; - document.getElementById( 'hidden-post-visibility' ).value = 'private'; - document.getElementById( 'visibility-radio-private' ).checked = true; + document.getElementById( 'hidden-post-visibility' ).value = 'private'; + document.getElementById( 'visibility-radio-private' ).checked = true; } } @@ -234,7 +232,7 @@ return; } - jQuery.ajax({ + jQuery.ajax( { type: 'POST', url: ajaxurl, data: { @@ -245,9 +243,9 @@ success: function( html ) { jQuery( '#frm_adv_info .categorydiv' ).html( html ); } - }); + } ); - jQuery.ajax({ + jQuery.ajax( { type: 'POST', url: ajaxurl, data: { @@ -258,7 +256,7 @@ success: function( html ) { jQuery( document.getElementById( 'date_select_container' ) ).html( html ); } - }); + } ); } function clickTabsAfterAjax() { @@ -288,7 +286,7 @@ function addOrderRow() { const logicRows = document.getElementById( 'frm_order_options' ).querySelectorAll( '.frm_logic_rows div' ); - jQuery.ajax({ + jQuery.ajax( { type: 'POST', url: ajaxurl, data: { @@ -300,12 +298,12 @@ success: function( html ) { jQuery( '#frm_order_options .frm_logic_rows' ).append( html ).show().prev( '.frm_add_order_row' ).hide(); } - }); + } ); } function addWhereRow() { const rowDivs = document.getElementById( 'frm_where_options' ).querySelectorAll( '.frm_logic_rows div' ); - jQuery.ajax({ + jQuery.ajax( { type: 'POST', url: ajaxurl, data: { @@ -317,7 +315,7 @@ success: function( html ) { jQuery( '#frm_where_options .frm_logic_rows' ).append( html ).show().prev( '.frm_add_where_row' ).hide(); } - }); + } ); } function insertWhereOptions() { @@ -325,7 +323,7 @@ const value = this.value, whereKey = jQuery( this ).closest( '.frm_where_row' ).attr( 'id' ).replace( 'frm_where_field_', '' ); - jQuery.ajax({ + jQuery.ajax( { type: 'POST', url: ajaxurl, data: { @@ -337,7 +335,7 @@ success: function( html ) { jQuery( document.getElementById( 'where_field_options_' + whereKey ) ).html( html ); } - }); + } ); } function hideWhereOptions() { @@ -373,7 +371,7 @@ if ( id !== '' ) { const $ele = jQuery( document.getElementById( id ) ); if ( $ele.attr( 'class' ) && id !== 'wpbody-content' && id !== 'content' && id !== 'dyncontent' && id !== 'success_msg' ) { - let d = $ele.attr( 'class' ).split( ' ' )[0]; + let d = $ele.attr( 'class' ).split( ' ' )[ 0 ]; if ( d === 'frm_long_input' || d === 'frm_98_width' || typeof d === 'undefined' ) { d = ''; } else { @@ -413,4 +411,4 @@ jQuery( '#' + clickedID.replace( /_/g, '-' ) + ' .frm_show_active' ).removeClass( 'frm_hidden' ); } } -}() ); \ No newline at end of file +}() ); diff --git a/js/admin/settings.js b/js/admin/settings.js index e7d1aec25d..3299c4a89a 100644 --- a/js/admin/settings.js +++ b/js/admin/settings.js @@ -9,13 +9,13 @@ handleToggleChangeEvent( e ); } - if ( 'frm_currency' === e.target.id) { + if ( 'frm_currency' === e.target.id ) { syncCurrencyOptions( e.target ); } } function handleKeyDownEvent( e ) { - switch ( e.key ) { + switch ( e.key ) { // eslint-disable-line sonarjs/no-small-switch case ' ': handleSpaceDownEvent( e ); break; diff --git a/js/admin/style.js b/js/admin/style.js index 423668ba52..f9496d7de2 100644 --- a/js/admin/style.js +++ b/js/admin/style.js @@ -3,15 +3,15 @@ * Pro-specific features are in the style-settings.js file in Pro. */ ( function() { - /* globals wp, frmDom, frmAdminBuild */ + /* globals frmDom, frmAdminBuild */ 'use strict'; if ( ! document.getElementById( 'frm_active_style_form' ) ) { return; } - const { __, sprintf } = wp.i18n; - const state = { + const { __, sprintf } = wp.i18n; + const state = { showingSampleForm: document.getElementById( 'frm_active_style_form' ).classList.contains( 'frm_hidden' ), // boolean unsavedChanges: false, // boolean autoId: 0, // Number @@ -21,9 +21,9 @@ initialSelectedStyleValue: false // String|false }; const { div, span, a, labelledTextInput, tag, svg, success } = frmDom; - const { onClickPreventDefault } = frmDom.util; - const { maybeCreateModal, footerButton } = frmDom.modal; - const { doJsonPost } = frmDom.ajax; + const { onClickPreventDefault } = frmDom.util; + const { maybeCreateModal, footerButton } = frmDom.modal; + const { doJsonPost } = frmDom.ajax; const isListPage = document.getElementsByClassName( 'frm-style-card' ).length > 0; if ( isListPage ) { @@ -38,7 +38,7 @@ * These are shared events for both the edit/list views like the sample form toggle. * This includes preview events, but also the update button click event handling for both views. * - * @returns {void} + * @return {void} */ function initCommonEventListeners() { document.addEventListener( 'click', handleCommonClickEvents ); @@ -49,7 +49,7 @@ /** * Initialize common functions required for the preview in both the edit and list views. * - * @returns {void} + * @return {void} */ function initPreview() { initFloatingLabels(); @@ -62,14 +62,13 @@ document.getElementById( 'frm_style_sidebar' ).classList.add( 'wp-core-ui' ); jQuery( document ).on( 'input change', 'input[data-frmrange]', initSliderPreview ); - } /** * Initialize the slider functionality in the style preview. * * @param {HTMLElement} event - * @returns {void} + * @return {void} */ function initSliderPreview( event ) { const wrapper = event.target.closest( '.frm_range_container' ); @@ -83,7 +82,7 @@ * Add the wp-core-ui class to the #wp-auth-check-wrap element. * As this style isn't included on the body for the styler, the close button on the auth modal wasn't getting styled properly. * - * @returns {void} + * @return {void} */ function fixWpAuthModal() { const authWrap = document.getElementById( 'wp-auth-check-wrap' ); @@ -93,7 +92,7 @@ } /** - * @returns {void} + * @return {void} */ function initListPage() { document.addEventListener( 'click', handleClickEventsForListPage ); @@ -102,8 +101,8 @@ setTimeout( addHamburgerMenusToCards, 1 ); initDatepickerSample(); - const enableToggle = document.getElementById( 'frm_enable_styling' ); - const styleIdInput = getStyleIdInput(); + const enableToggle = document.getElementById( 'frm_enable_styling' ); + const styleIdInput = getStyleIdInput(); state.initialSelectedStyleValue = styleIdInput.value; enableToggle.addEventListener( 'change', handleEnableStylingToggleChange ); @@ -126,14 +125,14 @@ /** * Handle pagination click events. * - * @returns {void} + * @return {void} */ function initStyleCardPagination() { document.querySelectorAll( '.frm-style-card-pagination' ).forEach( pagination => { - const wrapper = pagination.closest( '.frm-style-card-wrapper' ); + const wrapper = pagination.closest( '.frm-style-card-wrapper' ); const showAllAnchor = pagination.querySelector( '.frm-show-all-styles' ); - let showingAll = false; + let showingAll = false; onClickPreventDefault( showAllAnchor, @@ -151,7 +150,7 @@ wrapper.querySelectorAll( '.frm-style-card:nth-child(3) ~ .frm-style-card' ).forEach( card => card.classList.add( 'frm_hidden' ) ); - const hiddenCount = wrapper.querySelectorAll( '.frm-style-card.frm_hidden' ).length; + const hiddenCount = wrapper.querySelectorAll( '.frm-style-card.frm_hidden' ).length; /* translators: %d: The number of hidden items to show. */ showAllAnchor.textContent = sprintf( __( 'Show all (%d)', 'formidable' ), hiddenCount ); } @@ -161,8 +160,8 @@ } /** - * @param {String} labelPosition - * @returns {void} + * @param {string} labelPosition + * @return {void} */ function changeLabelPositionsInPreview( labelPosition ) { const input = tag( 'input' ); @@ -171,7 +170,7 @@ } /** - * @returns {HTMLElement} + * @return {HTMLElement} The active style card. */ function getActiveCard() { return document.querySelector( '.frm-active-style-card' ); @@ -183,7 +182,7 @@ * This is because disabling styles is linked to the custom_style option as well. * * @param {Event} event - * @returns {void} + * @return {void} */ function handleEnableStylingToggleChange( event ) { const stylesEnabled = event.target.checked; @@ -217,19 +216,19 @@ * We track the value on load with state.initialSelectedStyleValue. * Only consider unsaved changes on the page when this variable is no longer set to the original value. * - * @returns {void} + * @return {void} */ function trackListPageChange() { - const styleIdInput = getStyleIdInput(); + const styleIdInput = getStyleIdInput(); state.unsavedChanges = styleIdInput.value !== state.initialSelectedStyleValue; } /** * @param {boolean} on - * @returns {void} + * @return {void} */ function toggleFormidableStylingInPreviewForms( on ) { - const preview = document.getElementById( 'frm_style_preview' ); + const preview = document.getElementById( 'frm_style_preview' ); const activeCard = getActiveCard(); let selector = '.frm_forms'; @@ -246,7 +245,7 @@ } /** - * @returns {HTMLElement} + * @return {HTMLElement} The style ID input element. */ function getStyleIdInput() { return document.getElementById( 'frm_style_list_form' ).querySelector( '[name="style_id"]' ); @@ -254,7 +253,7 @@ /** * @param {Event} event - * @returns {void} + * @return {void} */ function handleCommonClickEvents( event ) { const target = event.target; @@ -272,7 +271,7 @@ if ( target.classList.contains( 'frm-edit-style' ) || null !== target.closest( '.frm-edit-style' ) || 'frm_edit_style' === target.id ) { modifyStylerUrl( target ); - return; + return; // eslint-disable-line } } @@ -296,7 +295,7 @@ } /** - * @returns {void} + * @return {void} */ function disablePreviewSubmitButtons() { const preview = document.getElementById( 'frm_style_preview' ); @@ -307,7 +306,7 @@ * Prevent form submit event. * * @param {Event} event - * @returns {false} + * @return {false} Prevents the default action and stops the event from bubbling. */ event => { event.preventDefault(); @@ -320,14 +319,14 @@ /** * @param {Event} event - * @returns {void} + * @return {void} */ function handleClickEventsForListPage( event ) { const target = event.target; if ( target.classList.contains( 'frm-style-card' ) || target.closest( '.frm-style-card' ) ) { handleStyleCardClick( event ); - return; + return; // eslint-disable-line } } @@ -336,7 +335,7 @@ * If the Update button is clicked after selecting a style card, the active card will be saved as the target form's style. * * @param {Event} event - * @returns {void} + * @return {void} */ function handleStyleCardClick( event ) { const target = event.target; @@ -346,7 +345,7 @@ return; } - const card = target.classList.contains( 'frm-style-card' ) ? target : target.closest( '.frm-style-card' ); + const card = target.classList.contains( 'frm-style-card' ) ? target : target.closest( '.frm-style-card' ); const cardIsLocked = card.classList.contains( 'frm-locked-style' ); if ( cardIsLocked ) { @@ -354,9 +353,9 @@ return; // Exit early as we're not actually selecting a locked template for preview. } - const previewArea = document.getElementById( 'frm_style_preview' ); - const activeCard = document.querySelector( '.frm-active-style-card' ); - const sampleForm = document.getElementById( 'frm_sample_form' ).querySelector( '.frm_forms' ); + const previewArea = document.getElementById( 'frm_style_preview' ); + const activeCard = document.querySelector( '.frm-active-style-card' ); + const sampleForm = document.getElementById( 'frm_sample_form' ).querySelector( '.frm_forms' ); const styleIdInput = getStyleIdInput(); disableLabelTransitions(); @@ -383,26 +382,26 @@ setTimeout( enableLabelTransitions, 1 ); // We want to toggle the edit button so you can only leave the page to edit the style if it's active (to avoid unsaved changes). - const editButton = document.getElementById( 'frm_edit_style' ); + const editButton = document.getElementById( 'frm_edit_style' ); const showEditButton = null !== card.querySelector( '.frm-style-card-info' ); // Only the "Applied style" has card info. editButton.classList.toggle( 'frm_hidden', ! showEditButton ); changeLabelPositionsInPreview( card.dataset.labelPosition ); // Trigger an action here so Pro can handle template preview updates on card click. - const hookName = 'frm_style_card_click'; - const hookArgs = { card, styleIdInput }; + const hookName = 'frm_style_card_click'; + const hookArgs = { card, styleIdInput }; wp.hooks.doAction( hookName, hookArgs ); } /** * @param {HTMLElement} card - * @returns {HTMLElement} + * @return {HTMLElement} The modal element. */ function maybeCreateStyleTemplateModal( card ) { - const titleElement = card.querySelector( '.frm-style-card-title' ); + const titleElement = card.querySelector( '.frm-style-card-title' ); const templateTitle = titleElement.textContent; - const modal = maybeCreateModal( + const modal = maybeCreateModal( 'frm_style_template_modal', { content: getStyleTemplateModalContent( card ), @@ -415,59 +414,59 @@ /** * @param {HTMLElement} card - * @returns {HTMLElement} + * @return {HTMLElement} The modal content element. */ function getStyleTemplateModalContent( card ) { const children = []; children.push( - div({ + div( { className: 'frm_warning_style', children: [ span( /* translators: %s: The required license type (ie. Plus, Business, or Elite) */ sprintf( __( 'Access to this style requires the %s plan.', 'formidable' ), card.dataset.requires ) ), - a({ + a( { text: getUpgradeNowText(), href: card.dataset.upgradeUrl, target: '_blank' - }) + } ) ] - }) + } ) ); - return div({ children }); + return div( { children } ); } /** * @param {HTMLElement} card - * @returns {HTMLElement} + * @return {HTMLElement} The modal footer element. */ function getStyleTemplateModalFooter( card ) { - const viewDemoSiteButton = footerButton({ + const viewDemoSiteButton = footerButton( { text: __( 'Learn More', 'formidable' ), buttonType: 'secondary' - }); + } ); viewDemoSiteButton.href = card.dataset.upgradeUrl; viewDemoSiteButton.target = '_blank'; - let primaryActionButton = footerButton({ + const primaryActionButton = footerButton( { text: getUpgradeNowText(), buttonType: 'primary' - }); + } ); primaryActionButton.classList.remove( 'dismiss' ); primaryActionButton.setAttribute( 'href', card.dataset.upgradeUrl ); primaryActionButton.target = '_blank'; - return div({ + return div( { children: [ viewDemoSiteButton, primaryActionButton ] - }); + } ); } /** - * @returns {String} + * @return {string} The upgrade now text. */ function getUpgradeNowText() { return __( 'Upgrade Now', 'formidable' ); @@ -477,7 +476,7 @@ * Track an unsaved change on the edit page. * This is included in the frmStylerFunctions global so unsaved changes can be tracked in Pro as well. * - * @returns {void} + * @return {void} */ function trackUnsavedChange() { state.unsavedChanges = true; @@ -487,7 +486,7 @@ * Possibly prevent leaving the page if there are unsaved changes. * * @param {Event} event - * @returns {void} + * @return {void} */ function maybeConfirmExit( event ) { if ( ! state.unsavedChanges ) { @@ -501,22 +500,22 @@ /** * Floating labels have a transition style. Turn it off temporarily when switching between cards to avoid a transition between two different style classes. * - * @returns {void} + * @return {void} */ function disableLabelTransitions() { setLabelTransitionStyle( 'none' ); } /** - * @returns {void} + * @return {void} */ function enableLabelTransitions() { setLabelTransitionStyle( '' ); } /** - * @param {String} value - * @returns {void} + * @param {string} value + * @return {void} */ function setLabelTransitionStyle( value ) { document.getElementById( 'frm_style_preview' ).querySelectorAll( '.frm_inside_container' ).forEach( @@ -525,7 +524,7 @@ } /** - * @returns {void} + * @return {void} */ function toggleSampleForm() { state.showingSampleForm = ! state.showingSampleForm; @@ -534,7 +533,7 @@ } /** - * @returns {void} + * @return {void} */ function handleUpdateClick() { state.unsavedChanges = false; // Prevent the saved changes pop up from triggering when submitting the form. @@ -557,7 +556,7 @@ * If the sample form toggle is active, we want to pass that as a query parameter so we know to default to the sample form on load. * * @param {HTMLElement} clickTarget - * @returns {void} + * @return {void} */ function modifyStylerUrl( clickTarget ) { if ( ! state.showingSampleForm ) { @@ -572,7 +571,7 @@ /** * Add menu dropdowns to style cards dynamically on load. * - * @returns {void} + * @return {void} */ function addHamburgerMenusToCards() { const cards = Array.from( document.getElementsByClassName( 'frm-style-card' ) ); @@ -581,7 +580,7 @@ /** * @param {HTMLlement} card - * @returns {void} + * @return {void} */ function maybeAddMenuToCard( card ) { if ( ! shouldAddMenuToCard( card ) ) { @@ -594,15 +593,15 @@ /** * Avoid adding a menu to an upsell card or a template card. * - * @param {HTMLlement} card - * @returns {boolean} + * @param {HTMLElement} card + * @return {boolean} Whether to add a menu to the card. */ function shouldAddMenuToCard( card ) { return 'frm_template_style_cards_wrapper' !== card.parentNode.id || ! card.classList.contains( 'frm-locked-style' ); } /** - * @returns {void} + * @return {void} */ function addHamburgerMenuForEditPage() { const styleName = document.getElementById( 'frm_style_name' ); @@ -612,7 +611,7 @@ const styleId = document.getElementById( 'frm_styling_form' ).querySelector( 'input[name="ID"]' ).value; - const hamburgerMenu = getHamburgerMenu({ styleId }); + const hamburgerMenu = getHamburgerMenu( { styleId } ); hamburgerMenu.classList.add( 'alignright' ); styleName.parentNode.insertBefore( hamburgerMenu, styleName ); } @@ -621,49 +620,49 @@ * Get a dropdown and the "hamburger" stacked dot menu trigger for a single style card. * * @param {DOMStringMap} data { - * @type {String} editUrl - * @type {String} styleId - * @type {String} labelPosition - * @type {String} classname + * @type {string} editUrl + * @type {string} styleId + * @type {string} labelPosition + * @type {string} classname * } - * @returns {HTMLElement} + * @return {HTMLElement} The hamburger menu element. */ function getHamburgerMenu( data ) { - const hamburgerMenu = a({ + const hamburgerMenu = a( { className: 'frm-dropdown-toggle dropdown-toggle', - child: svg({ href: '#frm_thick_more_vert_icon' }) - }); + child: svg( { href: '#frm_thick_more_vert_icon' } ) + } ); hamburgerMenu.setAttribute( 'data-toggle', 'dropdown' ); hamburgerMenu.setAttribute( 'data-container', 'body' ); hamburgerMenu.setAttribute( 'role', 'button' ); hamburgerMenu.setAttribute( 'tabindex', 0 ); - const isTemplate = 'undefined' !== typeof data.templateKey; + const isTemplate = 'undefined' !== typeof data.templateKey; let dropdownMenuOptions = []; if ( isListPage ) { - const applyOption = a({ + const applyOption = a( { text: isTemplate ? __( 'Install and apply', 'formidable' ) : __( 'Apply', 'formidable' ) - }); + } ); addIconToOption( applyOption, 'frm_save_icon' ); - dropdownMenuOptions.push({ anchor: applyOption, type: 'apply' }); + dropdownMenuOptions.push( { anchor: applyOption, type: 'apply' } ); onClickPreventDefault( applyOption, handleApplyOptionClick ); } if ( ! isTemplate ) { if ( 'string' === typeof data.editUrl ) { // The Edit option is not included on the Edit page. - const editOption = a({ + const editOption = a( { text: __( 'Edit', 'formidable' ), href: data.editUrl - }); + } ); addIconToOption( editOption, 'frm_pencil_icon' ); - dropdownMenuOptions.push({ anchor: editOption, type: 'edit' }); + dropdownMenuOptions.push( { anchor: editOption, type: 'edit' } ); } - const resetOption = a({ + const resetOption = a( { text: __( 'Reset to Defaults', 'formidable' ) - }); + } ); addIconToOption( resetOption, 'frm_repeater_icon' ); onClickPreventDefault( resetOption, () => confirmResetStyle( data.styleId ) ); @@ -673,39 +672,39 @@ ); } - const hookName = 'frm_style_card_dropdown_options'; - const hookArgs = { data, addIconToOption, isTemplate }; + const hookName = 'frm_style_card_dropdown_options'; + const hookArgs = { data, addIconToOption, isTemplate }; dropdownMenuOptions = wp.hooks.applyFilters( hookName, dropdownMenuOptions, hookArgs ); if ( isListPage && ! isTemplate ) { maybeAddDuplicateUpsell( dropdownMenuOptions ); } - const dropdownMenu = div({ + const dropdownMenu = div( { // Use dropdown-menu-right to avoid an overlapping issue with the card to the right (where the # of forms would appear above the menu). className: 'frm-dropdown-menu frm-style-options-menu frm-p-1', children: dropdownMenuOptions.map( wrapDropdownItem ) - }); + } ); const isRtl = document.body.classList.contains( 'rtl' ); dropdownMenu.classList.add( 'dropdown-menu-' + ( isRtl ? 'left' : 'right' ) ); dropdownMenu.setAttribute( 'role', 'menu' ); - return div({ + return div( { className: 'dropdown frm_wrap', // The .frm_wrap class prevents a blue outline on the active dropdown trigger. children: [ hamburgerMenu, dropdownMenu ] - }); + } ); } /** * @param {Array} dropdownMenuOptions - * @returns {void} + * @return {void} */ function maybeAddDuplicateUpsell( dropdownMenuOptions ) { let duplicateOptionExists = false; for ( let i = 0; i < dropdownMenuOptions.length; ++i ) { - if ( dropdownMenuOptions[i].type === 'duplicate' ) { + if ( dropdownMenuOptions[ i ].type === 'duplicate' ) { duplicateOptionExists = true; break; } @@ -715,10 +714,10 @@ return; } - const duplicateUpsell = a({ + const duplicateUpsell = a( { text: __( 'Duplicate', 'formidable' ), className: 'frm_noallow' - }); + } ); addIconToOption( duplicateUpsell, 'frm_clone_icon' ); onClickPreventDefault( duplicateUpsell, () => document.getElementById( 'frm_new_style_trigger' ).click() ); const upsellOption = { anchor: duplicateUpsell, type: 'duplicate' }; @@ -727,11 +726,11 @@ /** * @param {Event} event - * @returns {void} + * @return {void} */ function handleApplyOptionClick( event ) { const option = event.target; - const card = option.closest( '.frm-style-card' ); + const card = option.closest( '.frm-style-card' ); if ( ! card ) { return; } @@ -741,8 +740,8 @@ } /** - * @param {String} styleId - * @returns {HTMLElement} + * @param {string} styleId + * @return {HTMLElement} The rename option element. */ function getRenameOption( styleId ) { const renameOption = a( __( 'Rename', 'formidable' ) ); @@ -776,9 +775,9 @@ } /** - * @param {String} id + * @param {string} id * @param {Object} args - * @returns {HTMLElement} + * @return {HTMLElement} The modal element. */ function stylerModal( id, args ) { const modal = maybeCreateModal( id, args ); @@ -793,9 +792,9 @@ * Get modal content with just a "Style Name" input. * This is used for New style, Duplicate style, and for Rename style. * - * @param {String} context - * @param {String|undefined} value - * @returns {HTMLElement} + * @param {string} context + * @param {string|undefined} value + * @return {HTMLElement} The modal content element. */ function getStyleInputNameModalContent( context, value ) { // Create a form so we can listen to Enter key presses that trigger a form submit event. @@ -809,7 +808,7 @@ 'submit', /** * @param {Event} event - * @returns {false} + * @return {false} Prevents the default action and stops the event from bubbling. */ event => { // Prevent the form in the modal from submitting and trigger the click button in the modal footer instead. @@ -821,7 +820,7 @@ return false; } ); - const content = div({ child: form }); + const content = div( { child: form } ); content.style.padding = '20px'; content.querySelector( 'label' ).style.lineHeight = 1.5; @@ -848,30 +847,30 @@ } /** - * @param {String} styleId - * @returns {HTMLELement} + * @param {string} styleId + * @return {HTMLElement} The modal footer element. */ - function getRenameStyleModalFooter( styleId ) { - const cancelButton = footerButton({ text: __( 'Cancel', 'formidable' ), buttonType: 'cancel' }); + function getRenameStyleModalFooter( styleId ) { + const cancelButton = footerButton( { text: __( 'Cancel', 'formidable' ), buttonType: 'cancel' } ); cancelButton.classList.add( 'dismiss' ); - const renameButton = footerButton({ text: __( 'Rename style', 'formidable' ), buttonType: 'primary' }); + const renameButton = footerButton( { text: __( 'Rename style', 'formidable' ), buttonType: 'primary' } ); onClickPreventDefault( renameButton, () => renameStyle( styleId ) ); - return div({ + return div( { children: [ cancelButton, renameButton ] - }); + } ); } /** * Call frm_rename_style action when the rename style button is clicked in rename modal. * - * @param {String} styleId - * @returns {void} + * @param {string} styleId + * @return {void} */ function renameStyle( styleId ) { const styleNameInput = document.getElementById( 'frm_rename_style_name_input' ); - const newStyleName = styleNameInput.value; + const newStyleName = styleNameInput.value; if ( '' === newStyleName ) { // Avoid setting an empty name. @@ -879,7 +878,7 @@ return; } - const formData = new FormData(); + const formData = new FormData(); formData.append( 'style_id', styleId ); formData.append( 'style_name', newStyleName ); doJsonPost( 'rename_style', formData ).then( @@ -889,7 +888,7 @@ * If on the list page, update the style card after renaming a style. * On the edit page, update the style name element instead. * - * @returns {void} + * @return {void} */ () => { success( __( 'Style has been renamed successfully', 'formidable' ) ); @@ -906,28 +905,27 @@ } /** - * @param {String} styleId - * @param {String} newStyleName - * @returns {void} + * @param {string} styleId + * @param {string} newStyleName + * @return {void} */ function updateStyleNameInCard( styleId, newStyleName ) { - const card = getCardByStyleId( styleId ); + const card = getCardByStyleId( styleId ); const titleElement = card.querySelector( '.frm-style-card-title' ); titleElement.textContent = newStyleName; } /** - * @param {String} templateKey - * @returns {HTMLElement} + * @param {string} templateKey + * @return {HTMLElement} The template card element. */ function getTemplateCard( templateKey ) { - const templateCard = document.getElementById( 'frm_template_style_cards_wrapper' ).querySelector( '.frm-style-card[data-template-key="' + templateKey + '"]' ); - return templateCard; + return document.getElementById( 'frm_template_style_cards_wrapper' ).querySelector( '.frm-style-card[data-template-key="' + templateKey + '"]' ); } /** - * @param {String} styleId - * @returns {HTMLElement} + * @param {string} styleId + * @return {HTMLElement} The card element. */ function getCardByStyleId( styleId ) { const defaultCard = document.querySelector( '#frm_default_style_cards_wrapper > div[data-style-id="' + styleId + '"]' ); @@ -939,17 +937,17 @@ /** * @param {HTMLElement} option - * @param {String} iconId - * @returns {void} + * @param {string} iconId + * @return {void} */ function addIconToOption( option, iconId ) { - const icon = frmDom.svg({ href: '#' + iconId }); + const icon = frmDom.svg( { href: '#' + iconId } ); option.insertBefore( icon, option.firstChild ); } /** - * @param {String} styleId - * @returns {void} + * @param {string} styleId + * @return {void} */ function confirmResetStyle( styleId ) { stylerModal( @@ -963,7 +961,7 @@ } /** - * @returns {HTMLElement} + * @return {HTMLElement} The modal content element. */ function getResetStyleModalContent() { const content = div( __( 'Reset this style back to the default?', 'formidable' ) ); @@ -972,29 +970,29 @@ } /** - * @param {String} styleId - * @returns {HTMLElement} + * @param {string} styleId + * @return {HTMLElement} The modal footer element. */ function getResetStyleModalFooter( styleId ) { - const cancelButton = footerButton({ + const cancelButton = footerButton( { text: __( 'Cancel', 'formidable' ), buttonType: 'cancel' - }); + } ); cancelButton.classList.add( 'dismiss' ); - const resetButton = footerButton({ + const resetButton = footerButton( { text: __( 'Reset style', 'formidable' ), buttonType: 'primary' - }); + } ); onClickPreventDefault( resetButton, () => resetStyle( styleId ) ); - return div({ children: [ cancelButton, resetButton ] }); + return div( { children: [ cancelButton, resetButton ] } ); } /** * Handle reset dropdown action. * This function handles the front end routing for the reset action as reset works differently for edit and list views. * - * @param {String} styleId - * @returns {void} + * @param {string} styleId + * @return {void} */ function resetStyle( styleId ) { if ( isListPage ) { @@ -1007,8 +1005,8 @@ /** * Make a POST request to reset the style then reload the CSS and reset the card styles. * - * @param {String} styleId - * @returns {void} + * @param {string} styleId + * @return {void} */ function resetStyleOnListPage( styleId ) { const formData = new FormData(); @@ -1033,10 +1031,10 @@ /** * Reset the style in-page (without actually updating it). * - * @returns {void} + * @return {void} */ function resetStyleOnEditPage() { - jQuery.ajax({ + jQuery.ajax( { type: 'POST', url: ajaxurl, data: { @@ -1044,7 +1042,7 @@ nonce: frmGlobal.nonce }, success: syncEditPageAfterResetAction - }); + } ); } /** @@ -1054,7 +1052,7 @@ * @todo Stop triggering change events with jQuery. And remove the other jQuery as well. * * @param {Object} response - * @returns {void} + * @return {void} */ function syncEditPageAfterResetAction( response ) { let defaultValues = response.replace( /^\s+|\s+$/g, '' ); @@ -1094,7 +1092,7 @@ /** * Reload Formidable CSS after a style is reset so the preview updates immediately without needing to reload the page. * - * @returns {void} + * @return {void} */ function reloadCSSAfterStyleReset() { const style = document.getElementById( 'frm-custom-theme-css' ); @@ -1103,9 +1101,9 @@ } const newStyle = document.createElement( 'link' ); - newStyle.rel = 'stylesheet'; - newStyle.type = 'text/css'; - newStyle.href = style.href + '&key=' + getAutoId(); // Make the URL unique so the old stylesheet doesn't get picked up by cache. + newStyle.rel = 'stylesheet'; + newStyle.type = 'text/css'; + newStyle.href = style.href + '&key=' + getAutoId(); // Make the URL unique so the old stylesheet doesn't get picked up by cache. // Listen for the new style to load before removing the old style to avoid having no styles while the new style is loading. newStyle.addEventListener( @@ -1116,40 +1114,39 @@ } ); - const head = document.getElementsByTagName( 'HEAD' )[0]; + const head = document.getElementsByTagName( 'HEAD' )[ 0 ]; head.appendChild( newStyle ); } /** - * @returns {Number} + * @return {number} The auto ID. */ function getAutoId() { return ++state.autoId; } /** - * @param {Object} data { - * @type {Element} anchor - * @type {String} type - * } - * @returns {Element} + * @param {Object} data + * @param {HTMLElement} data.anchor + * @param {string} data.type + * @return {HTMLElement} The dropdown item element. */ - function wrapDropdownItem({ anchor, type }) { - return div({ + function wrapDropdownItem( { anchor, type } ) { + return div( { className: 'dropdown-item frm-' + type + '-style', child: anchor - }); + } ); } /** * This gets triggered through a hook called in frmAdminBuild.styleInit() from formidable_admin.js. * - * @returns {void} + * @return {void} */ function initEditPage() { - const { debounce } = frmDom.util; + const { debounce } = frmDom.util; const debouncedPreviewUpdate = debounce( () => changeStyling(), 100 ); - const debouncedColorChange = debounce(( event, value ) => { + const debouncedColorChange = debounce( ( event, value ) => { /** * Fires on style colorpicker change. * @@ -1162,11 +1159,11 @@ const debouncedTextSquishCheck = debounce( textSquishCheck, 300 ); initPosClass(); // It's important that this gets called before we add event listeners because it triggers change events. - ['frm_field_height', 'frm_field_font_size', 'frm_field_pad'].forEach( selector => { + [ 'frm_field_height', 'frm_field_font_size', 'frm_field_pad' ].forEach( selector => { document.getElementById( selector ).addEventListener( 'change', debouncedTextSquishCheck ); - }); + } ); - jQuery( 'input.hex' ).wpColorPicker({ + jQuery( 'input.hex' ).wpColorPicker( { change: function( event, ui ) { let color = jQuery( this ).wpColorPicker( 'color' ); trackUnsavedChange(); @@ -1183,14 +1180,14 @@ jQuery( event.target ).val( color ).trigger( 'change' ); } - }); + } ); jQuery( '.wp-color-result-text' ).text( function( _, oldText ) { const container = jQuery( this ).closest( '.wp-picker-container' ); - if ( 'undefined' !== typeof container && container[0].parentElement.classList.contains( 'frm-colorpicker' ) ) { - return container[0].querySelector( '.wp-color-picker' ).value; + if ( 'undefined' !== typeof container && container[ 0 ].parentElement.classList.contains( 'frm-colorpicker' ) ) { + return container[ 0 ].querySelector( '.wp-color-picker' ).value; } return oldText === 'Select Color' ? 'Select' : oldText; - }); + } ); jQuery( '#frm_styling_form .styling_settings, #frm_styling_form .frm-field-shape, #frm_styling_form input[name="frm_style_setting[post_content][base_font_size]"]' ).on( 'change', debouncedPreviewUpdate ); // This is really only necessary for Pro. But if Pro is not up to date to initialize the datepicker in the sample form, it should still work because it's initialized here. @@ -1206,15 +1203,15 @@ * Sends an AJAX POST request for new CSS to use for the preview. * This is called whenever a style setting is changed, generally using debouncedPreviewUpdate to avoid simultaneous requests. * - * @returns {void} + * @return {void} */ function changeStyling() { const styleInputs = Array.from( document.getElementById( 'frm_style_sidebar' ).querySelectorAll( 'input, select, textarea' ) ).filter( input => 'style_name' === input.name || 0 === input.name.indexOf( 'frm_style_setting[post_content]' ) ); - const locStr = JSON.stringify( jQuery( styleInputs ).serializeArray() ); + const locStr = JSON.stringify( jQuery( styleInputs ).serializeArray() ); - jQuery.ajax({ + jQuery.ajax( { type: 'POST', url: ajaxurl, data: { @@ -1222,18 +1219,18 @@ nonce: frmGlobal.nonce, frm_style_setting: locStr }, - success: ( css ) => { + success: css => { handleChangeStylingSuccess( css ); setSelectPlaceholderColor(); } - }); + } ); } /** * Update the CSS used for the preview on the edit page when a styling input has been updated. * - * @param {String} css The response from the frm_change_styling request. - * @returns {void} + * @param {string} css The response from the frm_change_styling request. + * @return {void} */ function handleChangeStylingSuccess( css ) { // Validate the string response. A valid output will include rules with .with_frm_style @@ -1249,15 +1246,15 @@ * Possibly pop up with a warning that "text will not display correctly if the field height is too small relative to the field padding and text size". * This can be triggered when modifying font size, height, and padding. * - * @returns {void} + * @return {void} */ function textSquishCheck() { if ( null !== frmDom.util.getCookie( 'frm-style-text-squish-check' ) ) { return; } - const height = document.getElementById( 'frm_field_height' ).value.replace( /\D/g, '' ); + const height = document.getElementById( 'frm_field_height' ).value.replace( /\D/g, '' ); const paddingEntered = document.getElementById( 'frm_field_pad' ).value.split( ' ' ); - const paddingCount = paddingEntered.length; + const paddingCount = paddingEntered.length; frmDom.util.setCookie( 'frm-style-text-squish-check', 1, 30 ); @@ -1268,10 +1265,10 @@ const size = document.getElementById( 'frm_field_font_size' ).value.replace( /\D/g, '' ); // Get the top and bottom padding from entered values - const paddingTop = paddingEntered[0].replace( /\D/g, '' ); - let paddingBottom = paddingTop; + const paddingTop = paddingEntered[ 0 ].replace( /\D/g, '' ); + let paddingBottom = paddingTop; if ( paddingCount >= 3 ) { - paddingBottom = paddingEntered[2].replace( /\D/g, '' ); + paddingBottom = paddingEntered[ 2 ].replace( /\D/g, '' ); } // Check if there is enough space for text @@ -1285,14 +1282,14 @@ * When the Collapse icons are updated, sync the dropdown. * Otherwise the previously selected value will still appear as the selected value. * - * @returns {void} + * @return {void} */ jQuery( document ).on( 'change', '.frm-dropdown-menu input[type="radio"]', function() { trackUnsavedChange(); - const radio = this; + const radio = this; const btnGrp = radio.closest( '.btn-group' ); - const btnId = btnGrp.getAttribute( 'id' ); + const btnId = btnGrp.getAttribute( 'id' ); const select = document.getElementById( btnId.replace( '_select', '' ) ); if ( select ) { @@ -1307,7 +1304,7 @@ } radio.closest( '.dropdown-item' ).classList.add( 'active' ); - }); + } ); if ( frm_admin_js.requireAccordionTitleClickListener ) { document.querySelectorAll( '.styling_settings h3.accordion-section-title' ).forEach( el => { @@ -1315,8 +1312,8 @@ if ( ! event.target.closest( 'button' ) ) { el.querySelector( 'button' ).click(); } - }); - }); + } ); + } ); } } @@ -1339,7 +1336,7 @@ /** * @param {HTMLElement} input * @param {HTMLElement} container - * @returns {void} + * @return {void} */ function checkFloatingLabelsForStyles( input, container ) { if ( ! container ) { @@ -1361,16 +1358,14 @@ firstOpt.textContent = firstOpt.getAttribute( 'data-label' ); firstOpt.removeAttribute( 'data-label' ); } - } else { - if ( firstOpt.textContent ) { - firstOpt.setAttribute( 'data-label', firstOpt.textContent ); - firstOpt.textContent = ''; - } + } else if ( firstOpt.textContent ) { + firstOpt.setAttribute( 'data-label', firstOpt.textContent ); + firstOpt.textContent = ''; } } /** - * @returns {void} + * @return {void} */ function initPosClass() { const positionSetting = document.getElementById( 'frm_position' ); @@ -1386,7 +1381,7 @@ /** * Update label container classes when the label "Position" setting is changed. * - * @returns {void} + * @return {void} */ function setPosClass() { /*jshint validthis:true */ @@ -1398,9 +1393,9 @@ } document.getElementById( 'frm_style_preview' ).querySelectorAll( '.frm_form_field.frm-default-label-position, #frm_sample_form .frm_form_field' ).forEach( container => { - const input = container.querySelector( ':scope > input, :scope > select, :scope > textarea' ); // Fields that support floating label should have a directly child input/textarea/select. + const input = container.querySelector( ':scope > input, :scope > select, :scope > textarea' ); // Fields that support floating label should have a directly child input/textarea/select. const shouldForceTopStyling = 'inside' === value && ( ! input || 'hidden' === input.type ); // We do not want file upload to use floating labels, or inline datepickers, which both use hidden inputs. - const currentValue = shouldForceTopStyling ? 'top' : value; + const currentValue = shouldForceTopStyling ? 'top' : value; container.classList.remove( 'frm_top_container', 'frm_left_container', 'frm_right_container', 'frm_none_container', 'frm_inside_container' ); container.classList.add( 'frm_' + currentValue + '_container' ); @@ -1408,11 +1403,11 @@ if ( 'inside' === currentValue ) { checkFloatingLabelsForStyles( input, container ); } - }); + } ); } /** - * @returns {void} + * @return {void} */ function initFloatingLabels() { [ 'focus', 'blur', 'change' ].forEach( @@ -1430,7 +1425,7 @@ * Without this, drawing in a signature field triggers a "Uncaught ReferenceError: frmFrontForm is not defined" error. * We don't want the validation to actually triggr, so just fill in an empty function. * - * @returns {void} + * @return {void} */ function fillMissingSignatureValidationFunction() { if ( 'undefined' === typeof window.__FRMSIG || 'undefined' !== typeof window.frmFrontForm ) { @@ -1443,7 +1438,7 @@ /** * Enable the datepicker in the sample form preview. * - * @returns {void} + * @return {void} */ function initDatepickerSample() { // If flatpickr is defined, then is a recent version of Pro which handles the datepicker preview as it's a PRO feature. @@ -1453,7 +1448,7 @@ const $sample = jQuery( '#datepicker_sample' ); if ( $sample.length && 'function' === typeof $sample.datepicker ) { - $sample.datepicker({ changeMonth: true, changeYear: true }); + $sample.datepicker( { changeMonth: true, changeYear: true } ); } } @@ -1473,8 +1468,8 @@ } // Function to change the color of a select element - const changeSelectColor = ( select ) => { - if ( select.options[select.selectedIndex] && select.options[select.selectedIndex].classList.contains( 'frm-select-placeholder' ) ) { + const changeSelectColor = select => { + if ( select.options[ select.selectedIndex ] && select.options[ select.selectedIndex ].classList.contains( 'frm-select-placeholder' ) ) { select.style.setProperty( 'color', textColorDisabled, 'important' ); } else { select.style.color = ''; @@ -1482,13 +1477,13 @@ }; // Use a loop to iterate through each select element - selects.forEach( ( select ) => { + selects.forEach( select => { // Apply the color change to each select element changeSelectColor( select ); // Add an event listener for future changes select.addEventListener( 'change', () => changeSelectColor( select ) ); - }); + } ); } // Hook into the styleInit function in formidable_admin.js diff --git a/js/admin/usage-tracking.js b/js/admin/usage-tracking.js index 52f80fe690..cf1286fee7 100644 --- a/js/admin/usage-tracking.js +++ b/js/admin/usage-tracking.js @@ -4,12 +4,12 @@ // Track edit form clicked link. frmDom.util.documentOn( 'click', '.toplevel_page_formidable #the-list .column-primary .row-actions a', function( event ) { sendData( 'edit_form_clicked_link', event.target.parentNode.className ); - }); + } ); // Track form templates. frmDom.util.documentOn( 'click', '.frm-form-templates-use-template-button', function( event ) { sendData( 'form_templates', event.target.closest( 'li' ).dataset.slug ); - }); + } ); const sendData = ( key, value ) => { const formData = new FormData(); diff --git a/js/form-templates.js b/js/form-templates.js index 1e30cde456..47b8dfed15 100644 --- a/js/form-templates.js +++ b/js/form-templates.js @@ -1,2 +1,2 @@ /*! For license information please see form-templates.js.LICENSE.txt */ -!function(){var t={616:function(t){t.exports=function(t,e){var r,n,o=0;function a(){var a,i,c=r,l=arguments.length;t:for(;c;){if(c.args.length===arguments.length){for(i=0;i=0),c.type){case"b":r=parseInt(r,10).toString(2);break;case"c":r=String.fromCharCode(parseInt(r,10));break;case"d":case"i":r=parseInt(r,10);break;case"j":r=JSON.stringify(r,null,c.width?parseInt(c.width):0);break;case"e":r=c.precision?parseFloat(r).toExponential(c.precision):parseFloat(r).toExponential();break;case"f":r=c.precision?parseFloat(r).toFixed(c.precision):parseFloat(r);break;case"g":r=c.precision?String(Number(r.toPrecision(c.precision))):parseFloat(r);break;case"o":r=(parseInt(r,10)>>>0).toString(8);break;case"s":r=String(r),r=c.precision?r.substring(0,c.precision):r;break;case"t":r=String(!!r),r=c.precision?r.substring(0,c.precision):r;break;case"T":r=Object.prototype.toString.call(r).slice(8,-1).toLowerCase(),r=c.precision?r.substring(0,c.precision):r;break;case"u":r=parseInt(r,10)>>>0;break;case"v":r=r.valueOf(),r=c.precision?r.substring(0,c.precision):r;break;case"x":r=(parseInt(r,10)>>>0).toString(16);break;case"X":r=(parseInt(r,10)>>>0).toString(16).toUpperCase()}o.json.test(c.type)?h+=r:(!o.number.test(c.type)||f&&!c.sign?p="":(p=f?"+":"-",r=r.toString().replace(o.sign,"")),u=c.pad_char?"0"===c.pad_char?"0":c.pad_char.charAt(1):" ",s=c.width-(p+r).length,l=c.width&&s>0?u.repeat(s):"",h+=c.align?p+r+l:"0"===u?p+l+r:l+p+r)}return h}(function(t){if(c[t])return c[t];for(var e,r=t,n=[],a=0;r;){if(null!==(e=o.text.exec(r)))n.push(e[0]);else if(null!==(e=o.modulo.exec(r)))n.push("%");else{if(null===(e=o.placeholder.exec(r)))throw new SyntaxError("[sprintf] unexpected placeholder");if(e[2]){a|=1;var i=[],l=e[2],u=[];if(null===(u=o.key.exec(l)))throw new SyntaxError("[sprintf] failed to parse named argument key");for(i.push(u[1]);""!==(l=l.substring(u[0].length));)if(null!==(u=o.key_access.exec(l)))i.push(u[1]);else{if(null===(u=o.index_access.exec(l)))throw new SyntaxError("[sprintf] failed to parse named argument key");i.push(u[1])}e[2]=i}else a|=2;if(3===a)throw new Error("[sprintf] mixing positional and named placeholders is not (yet) supported");n.push({placeholder:e[0],param_no:e[1],keys:e[2],sign:e[3],pad_char:e[4],align:e[5],width:e[6],precision:e[7],type:e[8]})}r=r.substring(e[0].length)}return c[t]=n}(t),arguments)}function i(t,e){return a.apply(null,[t].concat(e||[]))}var c=Object.create(null);e.sprintf=a,e.vsprintf=i,"undefined"!=typeof window&&(window.sprintf=a,window.vsprintf=i,void 0===(n=function(){return{sprintf:a,vsprintf:i}}.call(e,r,e,t))||(t.exports=n))}()}},e={};function r(n){var o=e[n];if(void 0!==o)return o.exports;var a=e[n]={exports:{}};return t[n](a,a.exports,r),a.exports}r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,{a:e}),e},r.d=function(t,e){for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},function(){"use strict";var t=window.frmGlobal,e=t.canAccessApplicationDashboard,n=t.applicationsUrl,o=window.frmFormTemplatesVars,a=o.FEATURED_TEMPLATES_KEYS,i=o.upgradeLink,c="frm-form-templates",l="available-templates",u="favorites",s="custom",f="search",p="440px",m="550px",d="frm-page-skeleton",h="all-items";function y(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function v(t){for(var e=1;e":5,">=":5,"==":4,"!=":4,"&&":3,"||":2,"?":1,"?:":1},x=["(","?"],S={")":["("],":":["?","?:"]},T=/<=|>=|==|!=|&&|\|\||\?:|\(|!|\*|\/|%|\+|-|<|>|\?|\)|:/;var C={"!":function(t){return!t},"*":function(t,e){return t*e},"/":function(t,e){return t/e},"%":function(t,e){return t%e},"+":function(t,e){return t+e},"-":function(t,e){return t-e},"<":function(t,e){return t":function(t,e){return t>e},">=":function(t,e){return t>=e},"==":function(t,e){return t===e},"!=":function(t,e){return t!==e},"&&":function(t,e){return t&&e},"||":function(t,e){return t||e},"?:":function(t,e,r){if(t)throw e;return r}};var A={contextDelimiter:"",onMissingKey:null};function P(t,e){var r;for(r in this.data=t,this.pluralForms={},this.options={},A)this.options[r]=void 0!==e&&r in e?e[r]:A[r]}function F(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function B(t){for(var e=1;e=0||w[o]3&&void 0!==arguments[3]?arguments[3]:10,i=t[e];if(M(r)&&q(n))if("function"==typeof o)if("number"==typeof a){var c={callback:o,priority:a,namespace:n};if(i[r]){var l,u=i[r].handlers;for(l=u.length;l>0&&!(a>=u[l-1].priority);l--);l===u.length?u[l]=c:u.splice(l,0,c),i.__current.forEach((function(t){t.name===r&&t.currentIndex>=l&&t.currentIndex++}))}else i[r]={handlers:[c],runs:0};"hookAdded"!==r&&t.doAction("hookAdded",r,n,o,a)}else console.error("If specified, the hook priority must be a number.");else console.error("The hook callback must be a function.")}},R=function(t,e){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(n,o){var a=t[e];if(M(n)&&(r||q(o))){if(!a[n])return 0;var i=0;if(r)i=a[n].handlers.length,a[n]={runs:a[n].runs,handlers:[]};else for(var c=a[n].handlers,l=function(t){c[t].namespace===o&&(c.splice(t,1),i++,a.__current.forEach((function(e){e.name===n&&e.currentIndex>=t&&e.currentIndex--})))},u=c.length-1;u>=0;u--)l(u);return"hookRemoved"!==n&&t.doAction("hookRemoved",n,o),i}}},z=function(t,e){return function(r,n){var o=t[e];return void 0!==n?r in o&&o[r].handlers.some((function(t){return t.namespace===n})):r in o}},Y=function(t,e){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(n){var o=t[e];o[n]||(o[n]={handlers:[],runs:0}),o[n].runs++;for(var a=o[n].handlers,i=arguments.length,c=new Array(i>1?i-1:0),l=1;l1&&void 0!==arguments[1]?arguments[1]:"default";n.data[e]=B(B(B({},D),n.data[e]),t),n.data[e][""]=B(B({},D[""]),n.data[e][""])},c=function(t,e){i(t,e),a()},l=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default",e=arguments.length>1?arguments[1]:void 0,r=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,a=arguments.length>4?arguments[4]:void 0;return n.data[t]||i(void 0,t),n.dcnpgettext(t,e,r,o,a)},u=function(){return arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default"},s=function(t,e,n){var o=l(n,e,t);return r?(o=r.applyFilters("i18n.gettext_with_context",o,t,e,n),r.applyFilters("i18n.gettext_with_context_"+u(n),o,t,e,n)):o};if(r){var f=function(t){N.test(t)&&a()};r.addAction("hookAdded","core/i18n",f),r.addAction("hookRemoved","core/i18n",f)}return{getLocaleData:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default";return n.data[t]},setLocaleData:c,resetLocaleData:function(t,e){n.data={},n.pluralForms={},c(t,e)},subscribe:function(t){return o.add(t),function(){return o.delete(t)}},__:function(t,e){var n=l(e,void 0,t);return r?(n=r.applyFilters("i18n.gettext",n,t,e),r.applyFilters("i18n.gettext_"+u(e),n,t,e)):n},_x:s,_n:function(t,e,n,o){var a=l(o,void 0,t,e,n);return r?(a=r.applyFilters("i18n.ngettext",a,t,e,n,o),r.applyFilters("i18n.ngettext_"+u(o),a,t,e,n,o)):a},_nx:function(t,e,n,o,a){var i=l(a,o,t,e,n);return r?(i=r.applyFilters("i18n.ngettext_with_context",i,t,e,n,o,a),r.applyFilters("i18n.ngettext_with_context_"+u(a),i,t,e,n,o,a)):i},isRTL:function(){return"rtl"===s("ltr","text direction")},hasTranslation:function(t,e,o){var a,i,c=e?e+""+t:t,l=!(null===(a=n.data)||void 0===a||null===(i=a[null!=o?o:"default"])||void 0===i||!i[c]);return r&&(l=r.applyFilters("i18n.has_translation",l,t,e,o),l=r.applyFilters("i18n.has_translation_"+u(o),l,t,e,o)),l}}}(0,0,V)),J=(Z.getLocaleData.bind(Z),Z.setLocaleData.bind(Z),Z.resetLocaleData.bind(Z),Z.subscribe.bind(Z),Z.__.bind(Z)),X=(Z._x.bind(Z),Z._n.bind(Z),Z._nx.bind(Z),Z.isRTL.bind(Z),Z.hasTranslation.bind(Z),window.frmGlobal),W=X.url,Q=(X.nonce,"frm_hidden"),tt="frm-hide-js",et="frm-current",rt=window.frmDom,nt=rt.tag,ot=rt.div,at=rt.a,it=rt.img;function ct(t){return ct="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ct(t)}function lt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function ut(t,e,r){return(e=function(t){var e=function(t){if("object"!=ct(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=ct(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==ct(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var st,ft=document.getElementById("post-body-content"),pt=document.getElementById("".concat(d,"-sidebar")),mt=((st=at({className:"button button-primary frm-button-primary"})).setAttribute("role","button"),ot({id:"".concat(d,"-empty-state"),className:"frm-flex-col frm-flex-center frm-gap-md ".concat(Q),children:[it({src:"".concat(W,"/images/page-skeleton/empty-state.svg"),alt:J("Empty State","formidable")}),ot({className:"frmcenter",children:[nt("h2",{className:"".concat(d,"-title frm-mb-0")}),nt("p",{className:"".concat(d,"-text frm-mb-0")})]}),st]}));null==ft||ft.appendChild(mt);var dt=function(){var t=document.querySelector("#".concat(d,"-empty-state"));return{emptyState:t,emptyStateTitle:null==t?void 0:t.querySelector(".".concat(d,"-title")),emptyStateText:null==t?void 0:t.querySelector(".".concat(d,"-text")),emptyStateButton:null==t?void 0:t.querySelector(".button")}}(),ht=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if("object"!==b(t)||null===t)throw new Error("createPageElements: initialElements must be a non-null object");var e=t;return{getElements:function(){return e},addElements:function(t){if("object"!==b(t)||null===t)throw new Error("addElements: newElements must be a non-null object");e=v(v({},e),t)}}}(function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:{};if("object"!==xt(t)||null===t)throw new Error("createPageState: initialState must be a non-null object");var e=t;return{getState:function(){return e},getSingleState:function(t){var r=Reflect.get(e,t);return void 0===r?null:r},setState:function(t){if("object"!==xt(t)||null===t)throw new Error("setState: newState must be a non-null object");e=bt(bt({},e),t)},setSingleState:function(t,r){Reflect.has(e,t)&&Reflect.set(e,t,r)}}}({notEmptySearchText:!1,selectedCategory:h,selectedCategoryEl:St}),Et=Tt.getState,_t=Tt.getSingleState,Ot=Tt.setState,Lt=Tt.setSingleState;function jt(t){return jt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},jt(t)}function kt(t,e){for(var r=0;r1&&void 0!==arguments[1]?arguments[1]:"default";!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.elements=e,this.type=r,this.prepareElements()},e=[{key:"fadeIn",value:function(){var t=this;this.applyStyleToElements((function(e){e.classList.add("frm-fadein-up"),e.addEventListener("animationend",(function(){t.resetOpacity(),e.classList.remove("frm-fadein-up")}),{once:!0})}))}},{key:"cascadeFadeIn",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.03;setTimeout((function(){t.applyStyleToElements((function(t,r){t.classList.remove("frm-animate"),t.style.transitionDelay=(r+1)*e+"s"}))}),200)}},{key:"prepareElements",value:function(){var t=this;this.applyStyleToElements((function(e){"default"===t.type&&(e.style.opacity="0.0"),"cascade"===t.type&&e.classList.add("frm-init-cascade-animation"),"cascade-3d"===t.type&&e.classList.add("frm-init-fadein-3d"),e.classList.add("frm-animate")}))}},{key:"resetOpacity",value:function(){this.applyStyleToElements((function(t){return t.style.opacity="1.0"}))}},{key:"applyStyleToElements",value:function(t){this.elements instanceof Element?t(this.elements,0):0=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var l=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(l&&u){if(this.prev=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),k(r),y}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;k(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:C(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),y}},e}function se(t,e,r,n,o,a,i){try{var c=t[a](i),l=c.value}catch(t){return void r(t)}c.done?e(l):Promise.resolve(l).then(n,o)}var fe=null;function pe(){var t;return t=ue().mark((function t(){var e,r,n;return ue().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e=window.frmAdminBuild,r=e.initModal,n=e.offsetModalY,(fe=r("#frm-form-templates-modal",p))&&n(fe,"103px"),wp.hooks.addAction("frmAdmin.beforeOpenConfirmModal","frmFormTemplates",(function(t){var e=t.$info;e.dialog("option","width",m),n(e,"103px")}));case 4:case"end":return t.stop()}}),t)})),pe=function(){var e=this,r=arguments;return new Promise((function(n,o){var a=t.apply(e,r);function i(t){se(a,n,o,i,c,"next",t)}function c(t){se(a,n,o,i,c,"throw",t)}i(void 0)}))},pe.apply(this,arguments)}function me(){return fe}function de(t){var e=yt().pageTitleText,r=t||_t("selectedCategoryEl").querySelector(".".concat(d,"-cat-text")).textContent;e.textContent=r}var he=function(t){return!!Dt(t)&&t.classList.contains("".concat(c,"-favorite-item"))},ye=function(t){return!!Dt(t)&&t.classList.contains("".concat(c,"-custom-item"))},ve={},ge=function(){var t=yt(),e=t.createFormButton,r=t.newTemplateForm,n=t.newTemplateNameInput,o=t.newTemplateActionInput,a=window.frmAdminBuild.installNewForm;n.value="",o.value="frm_install_form",a(r,"frm_install_form",e)},be=".".concat(c,"-item-favorite-button"),we="".concat(be," use"),xe="#frm_heart_solid_icon",Se="#frm_heart_icon",Te=function(t){var e,r=t.currentTarget,n=yt(),o=n.templatesList,i=n.featuredTemplatesList,l=n.favoritesCategoryCountEl,s=n.customTemplatesTitle,f=r.closest(".frm-card-item"),p=f.dataset.id,m=he(f),d=ye(f),h=function(t){return!!Dt(t)&&a.includes(Number(t.dataset.id))}(f),y=null;if(f.classList.toggle("".concat(c,"-favorite-item"),!m),h){var v=f.closest("#".concat(c,"-list"))?i:o;v&&(y=v.querySelector('.frm-card-item[data-id="'.concat(p,'"]'))).classList.toggle("".concat(c,"-favorite-item"),!m)}var g,b=Et(),w=b.selectedCategory,x=b.favoritesCount,S=m?"remove":"add",T=f.querySelector(we),E=null===(e=y)||void 0===e?void 0:e.querySelector(we);"add"===S?(++x.total,d?++x.custom:++x.default,T.setAttribute("xlink:href",xe),null==E||E.setAttribute("xlink:href",xe)):(--x.total,d?--x.custom:--x.default,T.setAttribute("xlink:href",Se),null==E||E.setAttribute("xlink:href",Se)),l.textContent=x.total,Lt("favoritesCount",x),u===w&&(0===x.total&&Ne(),Gt(f),0===x.default&&Gt(o),0!==x.custom&&0!==x.default||Gt(s)),g=function(){return t=p,e=S,r=d,n=new FormData,o=frmDom.ajax.doJsonPost,n.append("template_id",t),n.append("operation",e),n.append("is_custom_template",r),o("add_or_remove_favorite_template",n);var t,e,r,n,o},Pt=Pt.then(g).catch(g)},Ee=function(t){var e=t.currentTarget,r=e.closest(".frm-card-item"),n=function(t){return!!Dt(t)&&t.classList.contains("".concat(c,"-locked-item"))}(r),o=ye(r);if(n||!o)if(t.preventDefault(),Lt("selectedTemplate",r),n)!function(t){var e=t.dataset.requiredPlan;switch(e){case"basic":case"plus":case"business":case"elite":Ue(e,t);break;case"renew":He()}}(r);else{var a=yt(),i=a.newTemplateForm,l=a.newTemplateNameInput,u=a.newTemplateDescriptionInput,s=a.newTemplateLinkInput,f=a.newTemplateActionInput,p=window.frmAdminBuild.installNewForm,m=r.querySelector(".frm-form-template-name").textContent.trim(),d=r.querySelector(".frm-form-templates-item-description").textContent.trim(),h="frm_install_template";l.value=m,u.value=d,f.value=h,s.value=e.href,p(i,h,e)}},_e=window.frmDom.search.init;function Oe(t,e){var r=t.foundSomething,n=t.notEmptySearchText;if(!e||"search"!==e.type||""!==e.target.value){var o=Et(),a=yt().allItemsCategory;Lt("notEmptySearchText",n),o.notEmptySearchText||o.selectedCategory?(o.selectedCategory&&(function(t){var e=yt(),r=e.bodyContent,n=e.bodyContentChildren,o=e.pageTitle,a=e.templatesList,i=e.applicationTemplates,c=new At(r);t&&_t("selectedCategoryEl").classList.remove(et),qt(n),de(J("Search Result","formidable")),Nt([o,a,i]),c.fadeIn()}(n),n&&Lt("selectedCategory","")),function(t){if(t){var e,r=yt().emptyState;if(e=r,"none"!==window.getComputedStyle(e).getPropertyValue("display")){var n=yt().pageTitle;Gt(r),Mt(n)}var o=yt(),a=o.templatesList,i=o.applicationTemplates,c=o.applicationTemplatesTitle,l=o.applicationTemplatesList;Nt([a,i,c]),0===a.offsetHeight&&qt([a,c]),0===(null==l?void 0:l.offsetHeight)&&Gt(i)}else!function(){var t,e=Et().notEmptySearchText,r=yt(),n=r.pageTitle,o=r.emptyState,a=r.emptyStateButton,i=r.applicationTemplates;if(f!==(null===(t=o.dataset)||void 0===t?void 0:t.view)){o.setAttribute("data-view",f);var c=yt(),l=c.emptyStateTitle,u=c.emptyStateText;l.textContent=J("No templates found","formidable"),u.textContent=J("Sorry, we didn't find any templates that match your criteria.","formidable"),a.textContent=J("Start from Scratch","formidable"),qt([n,i]),Nt([o,a])}else e?(Mt(o),qt([n,i])):(Gt(o),o.removeAttribute("data-view"))}()}(r)):a.dispatchEvent(new Event("click",{bubbles:!0}))}}var Le=function(){var t,e=yt().emptyState;f===(null===(t=e.dataset)||void 0===t?void 0:t.view)&&(Lt("selectedCategory",""),Yt(),yt().searchInput.focus())},je=function(){var t=Et().selectedCategory;s===t&&Ke()},ke=function(){var t=yt().createTemplateFormsDropdown,e=t.value;if(e&&"no-forms"!==e){Ie(!1);var r=t.options[t.selectedIndex],n=r.dataset.description.trim(),o=r.dataset.name.trim(),a=" ".concat(J("Template","formidable"));o.endsWith(a)||(o+=a);var i=yt(),c=i.createTemplateName,l=i.createTemplateDescription;c.value=o,l.value=n}else Ie(!0)},Ie=function(t){var e=yt(),r=e.createTemplateName,n=e.createTemplateDescription,o=e.createTemplateButton;[r,n].forEach((function(e){e.disabled=t,t&&(e.value="")})),o.classList.toggle("disabled",t)},Ce=function(){var t=window.frmAdminBuild.installNewForm,e="frm_create_template",r=yt(),n=r.newTemplateForm,o=r.newTemplateActionInput,a=r.newTemplateNameInput,i=r.newTemplateDescriptionInput,c=r.newTemplateLinkInput,l=r.createTemplateName,u=r.createTemplateDescription,s=r.createTemplateFormsDropdown,f=r.createTemplateButton;o.value=e,a.value=l.value.trim(),i.value=u.value.trim(),c.value=s.value,t(n,e,f)},Ae=function(t){if(!t.target.closest("a")){var e=t.currentTarget;window.location.href=e.dataset.href}};function Pe(){var t,e,r,n;yt().categoryItems.forEach((function(t){Ft(t,Rt),t.addEventListener("keydown",zt)})),wp.hooks.addAction("frmPage.onCategoryClick","frmFormTemplates",(function(t){!function(t){var e=yt(),r=e.bodyContentChildren,n=e.pageTitle,o=e.showCreateTemplateModalButton,a=e.templatesList,i=e.templateItems;switch(h!==t&&qt(r),de(),Gt(o),Mt(n),t){case h:!function(){var t=yt(),e=t.bodyContentChildren,r=t.pageTitleDivider,n=t.templateItems,o=t.twinFeaturedTemplateItems,a=t.customTemplatesSection,i=t.emptyState,c=t.applicationTemplates;Nt([].concat(Be(e),Be(n))),qt([r].concat(Be(o),[a,i,c]))}();break;case l:!function(){if(0!==Et().availableTemplatesCount){var t=yt(),e=t.templatesList,r=t.templateItems,n=t.availableTemplateItems;qt(r),Nt([e].concat(Be(n)))}else!function(){var t=yt(),e=t.pageTitle,r=t.emptyState,n=t.emptyStateButton;r.setAttribute("data-view",l);var o=yt(),a=o.emptyStateTitle,i=o.emptyStateText,c=Et().extraTemplatesCount;a.textContent=J("No Templates Available","formidable"),i.textContent=function(t){try{for(var e=arguments.length,r=new Array(e>1?e-1:0),n=1;n0&&s.push(n),t.custom>0){var p=Array.from(u).filter((function(t){return!he(t)}));qt(p),s.push(a),s.push(l),0===t.default?Gt(i):s.push(i)}Nt(s)}else Ne()}();break;case s:!function(){if(0!==Et().customCount){var t=yt(),e=t.showCreateTemplateModalButton,r=t.pageTitleDivider,n=t.customTemplatesSection,o=t.customTemplatesList,a=t.customTemplatesTitle,i=t.customTemplateItems;Gt(a),Nt([e,r,n,o].concat(Be(i)))}else!function(){var t=yt(),e=t.pageTitle,r=t.emptyState,n=t.emptyStateButton;r.setAttribute("data-view",s);var o=yt(),a=o.emptyStateTitle,i=o.emptyStateText;a.textContent=J("You currently have no templates.","formidable"),i.textContent=J("You haven't created any form templates. Begin now to simplify your workflow and save time.","formidable"),n.textContent=J("Create Template","formidable"),Gt(e),Nt([r,n])}()}();break;default:qt(i),Nt([a].concat(Be(ve[t])))}}(t)})),n=yt().createFormButton,Ft(n,ge),document.querySelectorAll(be).forEach((function(t){return Ft(t,Te)})),document.querySelectorAll(".".concat(c,"-use-template-button")).forEach((function(t){return t.addEventListener("click",Ee)})),t=yt(),e=t.searchInput,r=t.emptyStateButton,_e(e,"frm-card-item",{handleSearchResult:Oe}),Ft(r,Le),function(){var t=yt(),e=t.createTemplateFormsDropdown,r=t.createTemplateButton,n=t.showCreateTemplateModalButton,o=t.emptyStateButton;Ft(n,je),Ft(o,je),e.addEventListener("change",ke),Ft(r,Ce)}()}function Fe(t){var e,r;(function(t){if(t&&t.length){var e=t.map((function(t){return function(t){var e=t.name,r=t.key,o=t.hasLiteThumbnail,a=t.isWebp,i=o?a?"".concat(re,"/").concat(r,".webp"):"".concat(re,"/").concat(r,".png"):"".concat(re,"/placeholder.svg");return Xt("li",{className:"frm-card-item",data:{href:"".concat(n,"&triggerViewApplicationModal=1&template=").concat(r),"frm-search-text":e.toLowerCase()},children:[Wt({className:"".concat(c,"-item-icon"),child:ee({src:i})}),Wt({className:"".concat(c,"-item-body"),children:[Qt({text:J("Ready Made Solution","formidable"),className:"frm-meta-tag frm-orange-tag frm-text-xs"}),Xt("h3",{text:e,className:"frm-text-sm frm-font-medium frm-m-0"}),te({text:J("See all applications","formidable"),className:"frm-text-xs frm-font-semibold",href:n})]})]})}(t)}));Zt=Wt({id:"".concat(c,"-applications"),className:Q,children:[Xt("h2",{text:J("Application Templates"),className:"frm-text-sm frm-mb-sm"}),Xt("ul",{className:"".concat(c,"-list frm-list-grid-layout"),children:e})]})}})(t.templates),(e=yt()).applicationTemplates||void 0===Zt||(e.bodyContent.appendChild(Zt),vt({applicationTemplates:Zt,applicationTemplatesTitle:Zt.querySelector("h2"),applicationTemplatesList:Zt.querySelector(".".concat(c,"-list")),applicationTemplateItems:Zt.querySelectorAll(".frm-card-item")})),void 0!==(r=yt().applicationTemplateItems)&&r.forEach((function(t){t.addEventListener("click",Ae)}))}function Be(t){return function(t){if(Array.isArray(t))return De(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return De(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?De(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function De(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var l=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(l&&u){if(this.prev=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),k(r),y}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;k(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:C(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),y}},e}function Ge(t,e,r,n,o,a,i){try{var c=t[a](i),l=c.value}catch(t){return void r(t)}c.done?e(l):Promise.resolve(l).then(n,o)}function Re(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var a=t.apply(e,r);function i(t){Ge(a,n,o,i,c,"next",t)}function c(t){Ge(a,n,o,i,c,"throw",t)}i(void 0)}))}}var ze,Ye=function(t){return Re(Me().mark((function e(){var r,n,o,a,i,c,l=arguments;return Me().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(r=me()){e.next=3;break}return e.abrupt("return");case 3:for(n=yt(),o=n.modalItems,qt(o),r.dialog("option","width",p),a=l.length,i=new Array(a),c=0;c use").setAttribute("xlink:href",n?"#frm_checkmark_icon":"#frm_close_icon")}));var u=e.dataset.slug?"-".concat(e.dataset.slug):"";l.href=i+u,Mt(o)})),He=Ye((function(){var t=yt().renewAccountModal;Mt(t)})),Ke=Ye((function(){me().dialog("option","width",m);var t=yt().createTemplateModal;Mt(t)})),Ve=function(){e&&(0,frmDom.ajax.doJsonFetch)("get_applications_data&view=templates").then(Fe),function(){pe.apply(this,arguments)}(),yt().templateItems.forEach((function(t){t.getAttribute("data-categories").split(",").forEach((function(e){ve[e]||(ve[e]=[]),ve[e].push(t)}))})),function(){var t=yt(),e=t.sidebar,r=t.searchInput,n=t.bodyContent,o=t.twinFeaturedTemplateItems,a=t.availableTemplatesCategory,i=new At(n);if(r.value="",qt(o),a){var c=Et().availableTemplatesCount;a.querySelector(".".concat(d,"-cat-count")).textContent=c}var l,u=yt().extraTemplateCountElements,s=Et().extraTemplatesCount;u.forEach((function(t){return t.textContent=s})),n.classList.remove(tt),e.classList.remove(tt),i.fadeIn(),Mt(e),Bt.has("return_page")&&(l=yt().headerCancelButton,new At(l).fadeIn())}(),Pe()};ze=function(){wp.hooks.doAction("frmFormTemplates.beforeInitialize",{getState:Et,setState:Ot}),Ve(),wp.hooks.doAction("frmFormTemplates.afterInitialize",{getState:Et,setState:Ot}),wp.hooks.doAction("frm_new_form_modal_form",jQuery("#frm-new-template"))},"undefined"!=typeof document&&("complete"!==document.readyState&&"interactive"!==document.readyState?document.addEventListener("DOMContentLoaded",ze):ze())}()}(); \ No newline at end of file +(()=>{var t={616:t=>{t.exports=function(t,e){var r,n,o=0;function a(){var a,i,c=r,l=arguments.length;t:for(;c;){if(c.args.length===arguments.length){for(i=0;i{var n;!function(){"use strict";var o={not_string:/[^s]/,not_bool:/[^t]/,not_type:/[^T]/,not_primitive:/[^v]/,number:/[diefg]/,numeric_arg:/[bcdiefguxX]/,json:/[j]/,not_json:/[^j]/,text:/^[^\x25]+/,modulo:/^\x25{2}/,placeholder:/^\x25(?:([1-9]\d*)\$|\(([^)]+)\))?(\+)?(0|'[^$])?(-)?(\d+)?(?:\.(\d+))?([b-gijostTuvxX])/,key:/^([a-z_][a-z_\d]*)/i,key_access:/^\.([a-z_][a-z_\d]*)/i,index_access:/^\[(\d+)\]/,sign:/^[+-]/};function a(t){return function(t,e){var r,n,i,c,l,u,s,f,p,m=1,d=t.length,h="";for(n=0;n=0),c.type){case"b":r=parseInt(r,10).toString(2);break;case"c":r=String.fromCharCode(parseInt(r,10));break;case"d":case"i":r=parseInt(r,10);break;case"j":r=JSON.stringify(r,null,c.width?parseInt(c.width):0);break;case"e":r=c.precision?parseFloat(r).toExponential(c.precision):parseFloat(r).toExponential();break;case"f":r=c.precision?parseFloat(r).toFixed(c.precision):parseFloat(r);break;case"g":r=c.precision?String(Number(r.toPrecision(c.precision))):parseFloat(r);break;case"o":r=(parseInt(r,10)>>>0).toString(8);break;case"s":r=String(r),r=c.precision?r.substring(0,c.precision):r;break;case"t":r=String(!!r),r=c.precision?r.substring(0,c.precision):r;break;case"T":r=Object.prototype.toString.call(r).slice(8,-1).toLowerCase(),r=c.precision?r.substring(0,c.precision):r;break;case"u":r=parseInt(r,10)>>>0;break;case"v":r=r.valueOf(),r=c.precision?r.substring(0,c.precision):r;break;case"x":r=(parseInt(r,10)>>>0).toString(16);break;case"X":r=(parseInt(r,10)>>>0).toString(16).toUpperCase()}o.json.test(c.type)?h+=r:(!o.number.test(c.type)||f&&!c.sign?p="":(p=f?"+":"-",r=r.toString().replace(o.sign,"")),u=c.pad_char?"0"===c.pad_char?"0":c.pad_char.charAt(1):" ",s=c.width-(p+r).length,l=c.width&&s>0?u.repeat(s):"",h+=c.align?p+r+l:"0"===u?p+l+r:l+p+r)}return h}(function(t){if(c[t])return c[t];for(var e,r=t,n=[],a=0;r;){if(null!==(e=o.text.exec(r)))n.push(e[0]);else if(null!==(e=o.modulo.exec(r)))n.push("%");else{if(null===(e=o.placeholder.exec(r)))throw new SyntaxError("[sprintf] unexpected placeholder");if(e[2]){a|=1;var i=[],l=e[2],u=[];if(null===(u=o.key.exec(l)))throw new SyntaxError("[sprintf] failed to parse named argument key");for(i.push(u[1]);""!==(l=l.substring(u[0].length));)if(null!==(u=o.key_access.exec(l)))i.push(u[1]);else{if(null===(u=o.index_access.exec(l)))throw new SyntaxError("[sprintf] failed to parse named argument key");i.push(u[1])}e[2]=i}else a|=2;if(3===a)throw new Error("[sprintf] mixing positional and named placeholders is not (yet) supported");n.push({placeholder:e[0],param_no:e[1],keys:e[2],sign:e[3],pad_char:e[4],align:e[5],width:e[6],precision:e[7],type:e[8]})}r=r.substring(e[0].length)}return c[t]=n}(t),arguments)}function i(t,e){return a.apply(null,[t].concat(e||[]))}var c=Object.create(null);e.sprintf=a,e.vsprintf=i,"undefined"!=typeof window&&(window.sprintf=a,window.vsprintf=i,void 0===(n=function(){return{sprintf:a,vsprintf:i}}.call(e,r,e,t))||(t.exports=n))}()}},e={};function r(n){var o=e[n];if(void 0!==o)return o.exports;var a=e[n]={exports:{}};return t[n](a,a.exports,r),a.exports}r.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return r.d(e,{a:e}),e},r.d=(t,e)=>{for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},r.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),(()=>{"use strict";var t=window.frmGlobal,e=t.canAccessApplicationDashboard,n=t.applicationsUrl,o=window.frmFormTemplatesVars,a=o.FEATURED_TEMPLATES_KEYS,i=o.upgradeLink,c="frm-form-templates",l="available-templates",u="favorites",s="custom",f="search",p="440px",m="550px",d="frm-page-skeleton",h="all-items";function y(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function v(t){for(var e=1;e":5,">=":5,"==":4,"!=":4,"&&":3,"||":2,"?":1,"?:":1},x=["(","?"],S={")":["("],":":["?","?:"]},T=/<=|>=|==|!=|&&|\|\||\?:|\(|!|\*|\/|%|\+|-|<|>|\?|\)|:/;var C={"!":function(t){return!t},"*":function(t,e){return t*e},"/":function(t,e){return t/e},"%":function(t,e){return t%e},"+":function(t,e){return t+e},"-":function(t,e){return t-e},"<":function(t,e){return t":function(t,e){return t>e},">=":function(t,e){return t>=e},"==":function(t,e){return t===e},"!=":function(t,e){return t!==e},"&&":function(t,e){return t&&e},"||":function(t,e){return t||e},"?:":function(t,e,r){if(t)throw e;return r}};var A={contextDelimiter:"",onMissingKey:null};function P(t,e){var r;for(r in this.data=t,this.pluralForms={},this.options={},A)this.options[r]=void 0!==e&&r in e?e[r]:A[r]}function F(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function B(t){for(var e=1;e=0||w[o]3&&void 0!==arguments[3]?arguments[3]:10,i=t[e];if(M(r)&&q(n))if("function"==typeof o)if("number"==typeof a){var c={callback:o,priority:a,namespace:n};if(i[r]){var l,u=i[r].handlers;for(l=u.length;l>0&&!(a>=u[l-1].priority);l--);l===u.length?u[l]=c:u.splice(l,0,c),i.__current.forEach((function(t){t.name===r&&t.currentIndex>=l&&t.currentIndex++}))}else i[r]={handlers:[c],runs:0};"hookAdded"!==r&&t.doAction("hookAdded",r,n,o,a)}else console.error("If specified, the hook priority must be a number.");else console.error("The hook callback must be a function.")}},R=function(t,e){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(n,o){var a=t[e];if(M(n)&&(r||q(o))){if(!a[n])return 0;var i=0;if(r)i=a[n].handlers.length,a[n]={runs:a[n].runs,handlers:[]};else for(var c=a[n].handlers,l=function(t){c[t].namespace===o&&(c.splice(t,1),i++,a.__current.forEach((function(e){e.name===n&&e.currentIndex>=t&&e.currentIndex--})))},u=c.length-1;u>=0;u--)l(u);return"hookRemoved"!==n&&t.doAction("hookRemoved",n,o),i}}},z=function(t,e){return function(r,n){var o=t[e];return void 0!==n?r in o&&o[r].handlers.some((function(t){return t.namespace===n})):r in o}},Y=function(t,e){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(n){var o=t[e];o[n]||(o[n]={handlers:[],runs:0}),o[n].runs++;for(var a=o[n].handlers,i=arguments.length,c=new Array(i>1?i-1:0),l=1;l1&&void 0!==arguments[1]?arguments[1]:"default";n.data[e]=B(B(B({},D),n.data[e]),t),n.data[e][""]=B(B({},D[""]),n.data[e][""])},c=function(t,e){i(t,e),a()},l=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default",e=arguments.length>1?arguments[1]:void 0,r=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,a=arguments.length>4?arguments[4]:void 0;return n.data[t]||i(void 0,t),n.dcnpgettext(t,e,r,o,a)},u=function(){return arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default"},s=function(t,e,n){var o=l(n,e,t);return r?(o=r.applyFilters("i18n.gettext_with_context",o,t,e,n),r.applyFilters("i18n.gettext_with_context_"+u(n),o,t,e,n)):o};if(r){var f=function(t){N.test(t)&&a()};r.addAction("hookAdded","core/i18n",f),r.addAction("hookRemoved","core/i18n",f)}return{getLocaleData:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default";return n.data[t]},setLocaleData:c,resetLocaleData:function(t,e){n.data={},n.pluralForms={},c(t,e)},subscribe:function(t){return o.add(t),function(){return o.delete(t)}},__:function(t,e){var n=l(e,void 0,t);return r?(n=r.applyFilters("i18n.gettext",n,t,e),r.applyFilters("i18n.gettext_"+u(e),n,t,e)):n},_x:s,_n:function(t,e,n,o){var a=l(o,void 0,t,e,n);return r?(a=r.applyFilters("i18n.ngettext",a,t,e,n,o),r.applyFilters("i18n.ngettext_"+u(o),a,t,e,n,o)):a},_nx:function(t,e,n,o,a){var i=l(a,o,t,e,n);return r?(i=r.applyFilters("i18n.ngettext_with_context",i,t,e,n,o,a),r.applyFilters("i18n.ngettext_with_context_"+u(a),i,t,e,n,o,a)):i},isRTL:function(){return"rtl"===s("ltr","text direction")},hasTranslation:function(t,e,o){var a,i,c=e?e+""+t:t,l=!(null===(a=n.data)||void 0===a||null===(i=a[null!=o?o:"default"])||void 0===i||!i[c]);return r&&(l=r.applyFilters("i18n.has_translation",l,t,e,o),l=r.applyFilters("i18n.has_translation_"+u(o),l,t,e,o)),l}}}(0,0,V));Z.getLocaleData.bind(Z),Z.setLocaleData.bind(Z),Z.resetLocaleData.bind(Z),Z.subscribe.bind(Z);var J=Z.__.bind(Z),X=(Z._x.bind(Z),Z._n.bind(Z),Z._nx.bind(Z),Z.isRTL.bind(Z),Z.hasTranslation.bind(Z),window.frmGlobal),W=X.url,Q=(X.nonce,"frm_hidden"),tt="frm-hide-js",et="frm-current",rt=window.frmDom,nt=rt.tag,ot=rt.div,at=rt.a,it=rt.img;function ct(t){return ct="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ct(t)}function lt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function ut(t,e,r){return(e=function(t){var e=function(t){if("object"!=ct(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=ct(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==ct(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var st,ft=document.getElementById("post-body-content"),pt=document.getElementById("".concat(d,"-sidebar")),mt=((st=at({className:"button button-primary frm-button-primary"})).setAttribute("role","button"),ot({id:"".concat(d,"-empty-state"),className:"frm-flex-col frm-flex-center frm-gap-md ".concat(Q),children:[it({src:"".concat(W,"/images/page-skeleton/empty-state.svg"),alt:J("Empty State","formidable")}),ot({className:"frmcenter",children:[nt("h2",{className:"".concat(d,"-title frm-mb-0")}),nt("p",{className:"".concat(d,"-text frm-mb-0")})]}),st]}));null==ft||ft.appendChild(mt);var dt=function(){var t=document.querySelector("#".concat(d,"-empty-state"));return{emptyState:t,emptyStateTitle:null==t?void 0:t.querySelector(".".concat(d,"-title")),emptyStateText:null==t?void 0:t.querySelector(".".concat(d,"-text")),emptyStateButton:null==t?void 0:t.querySelector(".button")}}(),ht=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if("object"!==b(t)||null===t)throw new Error("createPageElements: initialElements must be a non-null object");var e=t;return{getElements:function(){return e},addElements:function(t){if("object"!==b(t)||null===t)throw new Error("addElements: newElements must be a non-null object");e=v(v({},e),t)}}}(function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:{};if("object"!==xt(t)||null===t)throw new Error("createPageState: initialState must be a non-null object");var e=t;return{getState:function(){return e},getSingleState:function(t){var r=Reflect.get(e,t);return void 0===r?null:r},setState:function(t){if("object"!==xt(t)||null===t)throw new Error("setState: newState must be a non-null object");e=bt(bt({},e),t)},setSingleState:function(t,r){Reflect.has(e,t)&&Reflect.set(e,t,r)}}}({notEmptySearchText:!1,selectedCategory:h,selectedCategoryEl:St}),Et=Tt.getState,_t=Tt.getSingleState,Ot=Tt.setState,Lt=Tt.setSingleState;function jt(t){return jt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},jt(t)}function kt(t,e){for(var r=0;r1&&void 0!==arguments[1]?arguments[1]:"default";!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.elements=e,this.type=r,this.prepareElements()},e=[{key:"fadeIn",value:function(){var t=this;this.applyStyleToElements((function(e){e.classList.add("frm-fadein-up"),e.addEventListener("animationend",(function(){t.resetOpacity(),e.classList.remove("frm-fadein-up")}),{once:!0})}))}},{key:"cascadeFadeIn",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.03;setTimeout((function(){t.applyStyleToElements((function(t,r){t.classList.remove("frm-animate"),t.style.transitionDelay=(r+1)*e+"s"}))}),200)}},{key:"prepareElements",value:function(){var t=this;this.applyStyleToElements((function(e){"default"===t.type&&(e.style.opacity="0.0"),"cascade"===t.type&&e.classList.add("frm-init-cascade-animation"),"cascade-3d"===t.type&&e.classList.add("frm-init-fadein-3d"),e.classList.add("frm-animate")}))}},{key:"resetOpacity",value:function(){this.applyStyleToElements((function(t){return t.style.opacity="1.0"}))}},{key:"applyStyleToElements",value:function(t){this.elements instanceof Element?t(this.elements,0):0=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var l=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(l&&u){if(this.prev=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),k(r),y}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;k(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:C(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),y}},e}function se(t,e,r,n,o,a,i){try{var c=t[a](i),l=c.value}catch(t){return void r(t)}c.done?e(l):Promise.resolve(l).then(n,o)}var fe=null;function pe(){var t;return t=ue().mark((function t(){var e,r,n;return ue().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e=window.frmAdminBuild,r=e.initModal,n=e.offsetModalY,(fe=r("#frm-form-templates-modal",p))&&n(fe,"103px"),wp.hooks.addAction("frmAdmin.beforeOpenConfirmModal","frmFormTemplates",(function(t){var e=t.$info;e.dialog("option","width",m),n(e,"103px")}));case 4:case"end":return t.stop()}}),t)})),pe=function(){var e=this,r=arguments;return new Promise((function(n,o){var a=t.apply(e,r);function i(t){se(a,n,o,i,c,"next",t)}function c(t){se(a,n,o,i,c,"throw",t)}i(void 0)}))},pe.apply(this,arguments)}function me(){return fe}function de(t){var e=yt().pageTitleText,r=t||_t("selectedCategoryEl").querySelector(".".concat(d,"-cat-text")).textContent;e.textContent=r}var he=function(t){return!!Dt(t)&&t.classList.contains("".concat(c,"-favorite-item"))},ye=function(t){return!!Dt(t)&&t.classList.contains("".concat(c,"-custom-item"))},ve={},ge=function(){var t=yt(),e=t.createFormButton,r=t.newTemplateForm,n=t.newTemplateNameInput,o=t.newTemplateActionInput,a=window.frmAdminBuild.installNewForm;n.value="",o.value="frm_install_form",a(r,"frm_install_form",e)};var be=".".concat(c,"-item-favorite-button"),we="".concat(be," use"),xe="#frm_heart_solid_icon",Se="#frm_heart_icon",Te=function(t){var e,r=t.currentTarget,n=yt(),o=n.templatesList,i=n.featuredTemplatesList,l=n.favoritesCategoryCountEl,s=n.customTemplatesTitle,f=r.closest(".frm-card-item"),p=f.dataset.id,m=he(f),d=ye(f),h=function(t){return!!Dt(t)&&a.includes(Number(t.dataset.id))}(f),y=null;if(f.classList.toggle("".concat(c,"-favorite-item"),!m),h){var v=f.closest("#".concat(c,"-list"))?i:o;v&&(y=v.querySelector('.frm-card-item[data-id="'.concat(p,'"]'))).classList.toggle("".concat(c,"-favorite-item"),!m)}var g,b=Et(),w=b.selectedCategory,x=b.favoritesCount,S=m?"remove":"add",T=f.querySelector(we),E=null===(e=y)||void 0===e?void 0:e.querySelector(we);"add"===S?(++x.total,d?++x.custom:++x.default,T.setAttribute("xlink:href",xe),null==E||E.setAttribute("xlink:href",xe)):(--x.total,d?--x.custom:--x.default,T.setAttribute("xlink:href",Se),null==E||E.setAttribute("xlink:href",Se)),l.textContent=x.total,Lt("favoritesCount",x),u===w&&(0===x.total&&Ne(),Gt(f),0===x.default&&Gt(o),0!==x.custom&&0!==x.default||Gt(s)),g=function(){return t=p,e=S,r=d,n=new FormData,o=frmDom.ajax.doJsonPost,n.append("template_id",t),n.append("operation",e),n.append("is_custom_template",r),o("add_or_remove_favorite_template",n);var t,e,r,n,o},Pt=Pt.then(g).catch(g)};var Ee=function(t){var e=t.currentTarget,r=e.closest(".frm-card-item"),n=function(t){return!!Dt(t)&&t.classList.contains("".concat(c,"-locked-item"))}(r),o=ye(r);if(n||!o)if(t.preventDefault(),Lt("selectedTemplate",r),n)!function(t){var e=t.dataset.requiredPlan;switch(e){case"basic":case"plus":case"business":case"elite":$e(e,t);break;case"renew":Ue()}}(r);else{var a=yt(),i=a.newTemplateForm,l=a.newTemplateNameInput,u=a.newTemplateDescriptionInput,s=a.newTemplateLinkInput,f=a.newTemplateActionInput,p=window.frmAdminBuild.installNewForm,m=r.querySelector(".frm-form-template-name").textContent.trim(),d=r.querySelector(".frm-form-templates-item-description").textContent.trim(),h="frm_install_template";l.value=m,u.value=d,f.value=h,s.value=e.href,p(i,h,e)}};var _e=window.frmDom.search.init;function Oe(t,e){var r=t.foundSomething,n=t.notEmptySearchText;if(!e||"search"!==e.type||""!==e.target.value){var o=Et(),a=yt().allItemsCategory;Lt("notEmptySearchText",n),o.notEmptySearchText||o.selectedCategory?(o.selectedCategory&&(function(t){var e=yt(),r=e.bodyContent,n=e.bodyContentChildren,o=e.pageTitle,a=e.templatesList,i=e.applicationTemplates,c=new At(r);t&&_t("selectedCategoryEl").classList.remove(et),qt(n),de(J("Search Result","formidable")),Nt([o,a,i]),c.fadeIn()}(n),n&&Lt("selectedCategory","")),function(t){if(t){var e,r=yt().emptyState;if(e=r,"none"!==window.getComputedStyle(e).getPropertyValue("display")){var n=yt().pageTitle;Gt(r),Mt(n)}var o=yt(),a=o.templatesList,i=o.applicationTemplates,c=o.applicationTemplatesTitle,l=o.applicationTemplatesList;Nt([a,i,c]),0===a.offsetHeight&&qt([a,c]),0===(null==l?void 0:l.offsetHeight)&&Gt(i)}else!function(){var t,e=Et().notEmptySearchText,r=yt(),n=r.pageTitle,o=r.emptyState,a=r.emptyStateButton,i=r.applicationTemplates;if(f!==(null===(t=o.dataset)||void 0===t?void 0:t.view)){o.setAttribute("data-view",f);var c=yt(),l=c.emptyStateTitle,u=c.emptyStateText;l.textContent=J("No templates found","formidable"),u.textContent=J("Sorry, we didn't find any templates that match your criteria.","formidable"),a.textContent=J("Start from Scratch","formidable"),qt([n,i]),Nt([o,a])}else e?(Mt(o),qt([n,i])):(Gt(o),o.removeAttribute("data-view"))}()}(r)):a.dispatchEvent(new Event("click",{bubbles:!0}))}}var Le=function(){var t,e=yt().emptyState;f===(null===(t=e.dataset)||void 0===t?void 0:t.view)&&(Lt("selectedCategory",""),Yt(),yt().searchInput.focus())};var je=function(){var t=Et().selectedCategory;s===t&&He()},ke=function(){var t=yt().createTemplateFormsDropdown,e=t.value;if(e&&"no-forms"!==e){Ie(!1);var r=t.options[t.selectedIndex],n=r.dataset.description.trim(),o=r.dataset.name.trim(),a=" ".concat(J("Template","formidable"));o.endsWith(a)||(o+=a);var i=yt(),c=i.createTemplateName,l=i.createTemplateDescription;c.value=o,l.value=n}else Ie(!0)},Ie=function(t){var e=yt(),r=e.createTemplateName,n=e.createTemplateDescription,o=e.createTemplateButton;[r,n].forEach((function(e){e.disabled=t,t&&(e.value="")})),o.classList.toggle("disabled",t)},Ce=function(){var t=window.frmAdminBuild.installNewForm,e="frm_create_template",r=yt(),n=r.newTemplateForm,o=r.newTemplateActionInput,a=r.newTemplateNameInput,i=r.newTemplateDescriptionInput,c=r.newTemplateLinkInput,l=r.createTemplateName,u=r.createTemplateDescription,s=r.createTemplateFormsDropdown,f=r.createTemplateButton;o.value=e,a.value=l.value.trim(),i.value=u.value.trim(),c.value=s.value,t(n,e,f)};var Ae=function(t){if(!t.target.closest("a")){var e=t.currentTarget;window.location.href=e.dataset.href}};function Pe(){var t,e,r,n;yt().categoryItems.forEach((function(t){Ft(t,Rt),t.addEventListener("keydown",zt)})),wp.hooks.addAction("frmPage.onCategoryClick","frmFormTemplates",(function(t){!function(t){var e=yt(),r=e.bodyContentChildren,n=e.pageTitle,o=e.showCreateTemplateModalButton,a=e.templatesList,i=e.templateItems;switch(h!==t&&qt(r),de(),Gt(o),Mt(n),t){case h:!function(){var t=yt(),e=t.bodyContentChildren,r=t.pageTitleDivider,n=t.templateItems,o=t.twinFeaturedTemplateItems,a=t.customTemplatesSection,i=t.emptyState,c=t.applicationTemplates;Nt([].concat(Be(e),Be(n))),qt([r].concat(Be(o),[a,i,c]))}();break;case l:!function(){if(0!==Et().availableTemplatesCount){var t=yt(),e=t.templatesList,r=t.templateItems,n=t.availableTemplateItems;qt(r),Nt([e].concat(Be(n)))}else!function(){var t=yt(),e=t.pageTitle,r=t.emptyState,n=t.emptyStateButton;r.setAttribute("data-view",l);var o=yt(),a=o.emptyStateTitle,i=o.emptyStateText,c=Et().extraTemplatesCount;a.textContent=J("No Templates Available","formidable"),i.textContent=function(t){try{for(var e=arguments.length,r=new Array(e>1?e-1:0),n=1;n0&&s.push(n),t.custom>0){var p=Array.from(u).filter((function(t){return!he(t)}));qt(p),s.push(a),s.push(l),0===t.default?Gt(i):s.push(i)}Nt(s)}else Ne()}();break;case s:!function(){if(0!==Et().customCount){var t=yt(),e=t.showCreateTemplateModalButton,r=t.pageTitleDivider,n=t.customTemplatesSection,o=t.customTemplatesList,a=t.customTemplatesTitle,i=t.customTemplateItems;Gt(a),Nt([e,r,n,o].concat(Be(i)))}else!function(){var t=yt(),e=t.pageTitle,r=t.emptyState,n=t.emptyStateButton;r.setAttribute("data-view",s);var o=yt(),a=o.emptyStateTitle,i=o.emptyStateText;a.textContent=J("You currently have no templates.","formidable"),i.textContent=J("You haven't created any form templates. Begin now to simplify your workflow and save time.","formidable"),n.textContent=J("Create Template","formidable"),Gt(e),Nt([r,n])}()}();break;default:qt(i),Nt([a].concat(Be(ve[t])))}}(t)})),n=yt().createFormButton,Ft(n,ge),document.querySelectorAll(be).forEach((function(t){return Ft(t,Te)})),document.querySelectorAll(".".concat(c,"-use-template-button")).forEach((function(t){return t.addEventListener("click",Ee)})),t=yt(),e=t.searchInput,r=t.emptyStateButton,_e(e,"frm-card-item",{handleSearchResult:Oe}),Ft(r,Le),function(){var t=yt(),e=t.createTemplateFormsDropdown,r=t.createTemplateButton,n=t.showCreateTemplateModalButton,o=t.emptyStateButton;Ft(n,je),Ft(o,je),e.addEventListener("change",ke),Ft(r,Ce)}()}function Fe(t){var e,r;(function(t){if(t&&t.length){var e=t.map((function(t){return function(t){var e=t.name,r=t.key,o=t.hasLiteThumbnail,a=t.isWebp,i=o?a?"".concat(re,"/").concat(r,".webp"):"".concat(re,"/").concat(r,".png"):"".concat(re,"/placeholder.svg");return Xt("li",{className:"frm-card-item",data:{href:"".concat(n,"&triggerViewApplicationModal=1&template=").concat(r),"frm-search-text":e.toLowerCase()},children:[Wt({className:"".concat(c,"-item-icon"),child:ee({src:i})}),Wt({className:"".concat(c,"-item-body"),children:[Qt({text:J("Ready Made Solution","formidable"),className:"frm-meta-tag frm-orange-tag frm-text-xs"}),Xt("h3",{text:e,className:"frm-text-sm frm-font-medium frm-m-0"}),te({text:J("See all applications","formidable"),className:"frm-text-xs frm-font-semibold",href:n})]})]})}(t)}));Zt=Wt({id:"".concat(c,"-applications"),className:Q,children:[Xt("h2",{text:J("Application Templates"),className:"frm-text-sm frm-mb-sm"}),Xt("ul",{className:"".concat(c,"-list frm-list-grid-layout"),children:e})]})}})(t.templates),(e=yt()).applicationTemplates||void 0===Zt||(e.bodyContent.appendChild(Zt),vt({applicationTemplates:Zt,applicationTemplatesTitle:Zt.querySelector("h2"),applicationTemplatesList:Zt.querySelector(".".concat(c,"-list")),applicationTemplateItems:Zt.querySelectorAll(".frm-card-item")})),void 0!==(r=yt().applicationTemplateItems)&&r.forEach((function(t){t.addEventListener("click",Ae)}))}function Be(t){return function(t){if(Array.isArray(t))return De(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return De(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?De(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function De(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var l=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(l&&u){if(this.prev=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),k(r),y}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;k(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:C(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),y}},e}function Ge(t,e,r,n,o,a,i){try{var c=t[a](i),l=c.value}catch(t){return void r(t)}c.done?e(l):Promise.resolve(l).then(n,o)}function Re(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var a=t.apply(e,r);function i(t){Ge(a,n,o,i,c,"next",t)}function c(t){Ge(a,n,o,i,c,"throw",t)}i(void 0)}))}}var ze=function(t){return Re(Me().mark((function e(){var r,n,o,a,i,c,l=arguments;return Me().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(r=me()){e.next=3;break}return e.abrupt("return");case 3:for(n=yt(),o=n.modalItems,qt(o),r.dialog("option","width",p),a=l.length,i=new Array(a),c=0;c use").setAttribute("xlink:href",n?"#frm_checkmark_icon":"#frm_close_icon")}));var u=e.dataset.slug?"-".concat(e.dataset.slug):"";l.href=i+u,Mt(o)})),Ue=ze((function(){var t=yt().renewAccountModal;Mt(t)})),He=ze((function(){me().dialog("option","width",m);var t=yt().createTemplateModal;Mt(t)}));const Ke=function(){e&&(0,frmDom.ajax.doJsonFetch)("get_applications_data&view=templates").then(Fe),function(){pe.apply(this,arguments)}(),yt().templateItems.forEach((function(t){t.getAttribute("data-categories").split(",").forEach((function(e){ve[e]||(ve[e]=[]),ve[e].push(t)}))})),function(){var t=yt(),e=t.sidebar,r=t.searchInput,n=t.bodyContent,o=t.twinFeaturedTemplateItems,a=t.availableTemplatesCategory,i=new At(n);if(r.value="",qt(o),a){var c=Et().availableTemplatesCount;a.querySelector(".".concat(d,"-cat-count")).textContent=c}var l,u=yt().extraTemplateCountElements,s=Et().extraTemplatesCount;u.forEach((function(t){return t.textContent=s})),n.classList.remove(tt),e.classList.remove(tt),i.fadeIn(),Mt(e),Bt.has("return_page")&&(l=yt().headerCancelButton,new At(l).fadeIn())}(),Pe()};var Ve;Ve=function(){wp.hooks.doAction("frmFormTemplates.beforeInitialize",{getState:Et,setState:Ot}),Ke(),wp.hooks.doAction("frmFormTemplates.afterInitialize",{getState:Et,setState:Ot}),wp.hooks.doAction("frm_new_form_modal_form",jQuery("#frm-new-template"))},"undefined"!=typeof document&&("complete"!==document.readyState&&"interactive"!==document.readyState?document.addEventListener("DOMContentLoaded",Ve):Ve())})()})(); \ No newline at end of file diff --git a/js/formidable.js b/js/formidable.js index bf7ebe4522..f7db67a258 100644 --- a/js/formidable.js +++ b/js/formidable.js @@ -74,23 +74,22 @@ function frmFrontFormJS() { } nameParts = nameParts.filter( function( n ) { return n !== ''; - }); + } ); - fieldId = nameParts[0]; + fieldId = nameParts[ 0 ]; if ( nameParts.length === 1 ) { return fieldId; } - if ( nameParts[1] === '[form' || nameParts[1] === '[row_ids' ) { + if ( nameParts[ 1 ] === '[form' || nameParts[ 1 ] === '[row_ids' ) { return 0; } // Check if 'this' is in a repeating section if ( document.querySelector( 'input[name="item_meta[' + fieldId + '][form]"]' ) ) { - // this is a repeatable section with name: item_meta[repeating-section-id][row-id][field-id] - fieldId = nameParts[2].replace( '[', '' ); + fieldId = nameParts[ 2 ].replace( '[', '' ); isRepeating = true; } @@ -98,19 +97,19 @@ function frmFrontFormJS() { if ( 'other' === fieldId ) { if ( isRepeating ) { // name for other fields: item_meta[370][0][other][414] - fieldId = nameParts[3].replace( '[', '' ); + fieldId = nameParts[ 3 ].replace( '[', '' ); } else { // Other field name: item_meta[other][370] - fieldId = nameParts[1].replace( '[', '' ); + fieldId = nameParts[ 1 ].replace( '[', '' ); } } if ( fullID === true ) { // For use in the container div id - if ( fieldId === nameParts[0]) { - fieldId = fieldId + '-' + nameParts[1].replace( '[', '' ); + if ( fieldId === nameParts[ 0 ] ) { + fieldId = fieldId + '-' + nameParts[ 1 ].replace( '[', '' ); } else { - fieldId = fieldId + '-' + nameParts[0] + '-' + nameParts[1].replace( '[', '' ); + fieldId = fieldId + '-' + nameParts[ 0 ] + '-' + nameParts[ 1 ].replace( '[', '' ); } } @@ -161,10 +160,10 @@ function frmFrontFormJS() { if ( ! $form.length ) { return; } - $form[0].querySelectorAll( '.frm_save_draft' ).forEach( saveDraftButton => { - saveDraftButton.disabled = false; + $form[ 0 ].querySelectorAll( '.frm_save_draft' ).forEach( saveDraftButton => { + saveDraftButton.disabled = false; saveDraftButton.style.pointerEvents = ''; - }); + } ); } /** @@ -244,7 +243,7 @@ function frmFrontFormJS() { } fieldID = getFieldId( field, true ); - if ( 'undefined' === typeof errors[ fieldID ]) { + if ( 'undefined' === typeof errors[ fieldID ] ) { errors[ fieldID ] = getFieldValidationMessage( field, 'data-invmsg' ); } @@ -299,7 +298,7 @@ function frmFrontFormJS() { function validateField( field ) { let errors, key; - errors = []; + errors = []; const fieldContainer = field.closest( '.frm_form_field' ); if ( ! fieldContainer ) { @@ -355,7 +354,7 @@ function frmFrontFormJS() { field: field, errors: errors, onSubmit: onSubmit - }); + } ); } /** @@ -408,8 +407,8 @@ function frmFrontFormJS() { tempVal = val; val = ''; for ( i = 0; i < tempVal.length; i++ ) { - if ( tempVal[i] !== '' ) { - val = tempVal[i]; + if ( tempVal[ i ] !== '' ) { + val = tempVal[ i ]; } } } @@ -495,7 +494,7 @@ function frmFrontFormJS() { if ( val === '' ) { val = this.value; } - }); + } ); return val; } @@ -667,7 +666,7 @@ function frmFrontFormJS() { // Function to change the color of a select element changeSelectColor = function( select ) { - if ( select.options[select.selectedIndex] && hasClass( select.options[select.selectedIndex], 'frm-select-placeholder' ) ) { + if ( select.options[ select.selectedIndex ] && hasClass( select.options[ select.selectedIndex ], 'frm-select-placeholder' ) ) { select.style.setProperty( 'color', textColorDisabled, 'important' ); } else { select.style.color = ''; @@ -682,8 +681,8 @@ function frmFrontFormJS() { // Add an event listener for future changes select.addEventListener( 'change', function() { changeSelectColor( select ); - }); - }); + } ); + } ); } /** @@ -738,7 +737,7 @@ function frmFrontFormJS() { if ( response.length === 0 ) { const fieldContainer = $recaptcha.closest( '.frm_form_field' ); - const fieldID = fieldContainer.attr( 'id' ).replace( 'frm_field_', '' ).replace( '_container', '' ); + const fieldID = fieldContainer.attr( 'id' ).replace( 'frm_field_', '' ).replace( '_container', '' ); errors[ fieldID ] = ''; } @@ -774,13 +773,13 @@ function frmFrontFormJS() { return msg; } - errorHtml = errorHtml.replace( /\+/g, '%20' ); - msg = decodeURIComponent( errorHtml ).replace( '[error]', msg ); - const fieldId = getFieldId( field, false ); - const split = fieldId.split( '-' ); + errorHtml = errorHtml.replace( /\+/g, '%20' ); + msg = decodeURIComponent( errorHtml ).replace( '[error]', msg ); + const fieldId = getFieldId( field, false ); + const split = fieldId.split( '-' ); const fieldIdParts = field.id.split( '_' ); fieldIdParts.shift(); // Drop the "field" value from the front. - split[0] = fieldIdParts.join( '_' ); + split[ 0 ] = fieldIdParts.join( '_' ); const errorKey = split.join( '-' ); return msg.replace( '[key]', errorKey ); } @@ -819,11 +818,11 @@ function frmFrontFormJS() { fieldset = jQuery( object ).find( '.frm_form_field' ); fieldset.addClass( 'frm_doing_ajax' ); - data = jQuery( object ).serialize() + '&action=frm_entries_' + action + '&nonce=' + frm_js.nonce; // eslint-disable-line camelcase + data = jQuery( object ).serialize() + '&action=frm_entries_' + action + '&nonce=' + frm_js.nonce; // eslint-disable-line camelcase shouldTriggerEvent = object.classList.contains( 'frm_trigger_event_on_submit' ); const doRedirect = response => { - jQuery( document ).trigger( 'frmBeforeFormRedirect', [ object, response ]); + jQuery( document ).trigger( 'frmBeforeFormRedirect', [ object, response ] ); if ( ! response.openInNewTab ) { // We return here because we're redirecting there is no need to update content. @@ -879,7 +878,7 @@ function frmFrontFormJS() { // the form or success message was returned if ( shouldTriggerEvent ) { - triggerCustomEvent( object, 'frmSubmitEvent', { content: response.content }); + triggerCustomEvent( object, 'frmSubmitEvent', { content: response.content } ); return; } @@ -960,7 +959,7 @@ function frmFrontFormJS() { } jQuery( object ).find( '.frm-g-recaptcha, .g-recaptcha, .h-captcha' ).each( function() { - const $recaptcha = jQuery( this ), + const $recaptcha = jQuery( this ), recaptchaID = $recaptcha.data( 'rid' ); if ( typeof grecaptcha !== 'undefined' && grecaptcha ) { @@ -973,7 +972,7 @@ function frmFrontFormJS() { if ( typeof hcaptcha !== 'undefined' && hcaptcha ) { hcaptcha.reset(); } - }); + } ); if ( window.turnstile ) { object.querySelectorAll( '.cf-turnstile' ).forEach( @@ -981,7 +980,7 @@ function frmFrontFormJS() { ); } - jQuery( document ).trigger( 'frmFormErrors', [ object, response ]); + jQuery( document ).trigger( 'frmFormErrors', [ object, response ] ); fieldset.removeClass( 'frm_doing_ajax' ); scrollToFirstField( object ); @@ -1016,7 +1015,7 @@ function frmFrontFormJS() { action = form.getAttribute( 'action' ); if ( 'string' === typeof action && -1 !== action.indexOf( '?action=frm_forms_preview' ) ) { - ajaxUrl = action.split( '?action=frm_forms_preview' )[0]; + ajaxUrl = action.split( '?action=frm_forms_preview' )[ 0 ]; } ajaxParams = { @@ -1036,9 +1035,9 @@ function frmFrontFormJS() { function afterFormSubmitted( object, response ) { const formCompleted = jQuery( response.content ).find( '.frm_message' ); if ( formCompleted.length ) { - jQuery( document ).trigger( 'frmFormComplete', [ object, response ]); + jQuery( document ).trigger( 'frmFormComplete', [ object, response ] ); } else { - jQuery( document ).trigger( 'frmPageChanged', [ object, response ]); + jQuery( document ).trigger( 'frmPageChanged', [ object, response ] ); } } @@ -1054,7 +1053,7 @@ function frmFrontFormJS() { function afterFormSubmittedBeforeReplace( object, response ) { const formCompleted = jQuery( response.content ).find( '.frm_message' ); if ( formCompleted.length ) { - triggerCustomEvent( document, 'frmFormCompleteBeforeReplace', { object, response }); + triggerCustomEvent( document, 'frmFormCompleteBeforeReplace', { object, response } ); } } @@ -1085,7 +1084,7 @@ function frmFrontFormJS() { let url; if ( history.pushState && typeof response.page !== 'undefined' ) { url = addQueryVar( 'frm_page', response.page ); - window.history.pushState({ 'html': response.html }, '', '?' + url ); + window.history.pushState( { html: response.html }, '', '?' + url ); } } @@ -1099,11 +1098,11 @@ function frmFrontFormJS() { i = kvp.length; while ( i-- ) { - x = kvp[i].split( '=' ); + x = kvp[ i ].split( '=' ); - if ( x[0] == key ) { - x[1] = value; - kvp[i] = x.join( '=' ); + if ( x[ 0 ] == key ) { + x[ 1 ] = value; + kvp[ i ] = x.join( '=' ); break; } } @@ -1127,13 +1126,13 @@ function frmFrontFormJS() { if ( typeof frmThemeOverride_frmPlaceError === 'function' ) { // eslint-disable-line camelcase frmThemeOverride_frmPlaceError( key, jsErrors ); } else { - if ( -1 !== jsErrors[key].indexOf( '' + jsErrors[key] + '
    ' ); + $fieldCont.append( '
    ' + jsErrors[ key ] + '
    ' ); } if ( typeof describedBy === 'undefined' ) { @@ -1150,7 +1149,7 @@ function frmFrontFormJS() { } input.attr( 'aria-invalid', true ); - jQuery( document ).trigger( 'frmAddFieldError', [ $fieldCont, key, jsErrors ]); + jQuery( document ).trigger( 'frmAddFieldError', [ $fieldCont, key, jsErrors ] ); } } @@ -1178,9 +1177,9 @@ function frmFrontFormJS() { */ function removeFieldError( $fieldCont ) { const errorMessage = $fieldCont.find( '.frm_error' ); - const errorId = errorMessage.attr( 'id' ); - const input = $fieldCont.find( 'input, select, textarea' ); - let describedBy = input.attr( 'aria-describedby' ); + const errorId = errorMessage.attr( 'id' ); + const input = $fieldCont.find( 'input, select, textarea' ); + let describedBy = input.attr( 'aria-describedby' ); const fieldContainer = $fieldCont.get( 0 ); if ( fieldContainer && fieldContainer.classList ) { @@ -1316,8 +1315,8 @@ function frmFrontFormJS() { label.addEventListener( 'click', function() { inputsContainer.querySelector( '.frm_form_field:first-child input, .frm_form_field:first-child select, .frm_form_field:first-child textarea' ).focus(); - }); - }); + } ); + } ); } /** @@ -1355,7 +1354,7 @@ function frmFrontFormJS() { return; } - element = errors[0]; + element = errors[ 0 ]; do { element = element.previousSibling; if ( -1 !== [ 'input', 'select', 'textarea' ].indexOf( element.nodeName.toLowerCase() ) ) { @@ -1407,7 +1406,7 @@ function frmFrontFormJS() { if ( input.offsetParent !== null ) { input.focus(); } else { - triggerCustomEvent( document, 'frmMaybeDelayFocus', { input }); + triggerCustomEvent( document, 'frmMaybeDelayFocus', { input } ); } } @@ -1442,7 +1441,7 @@ function frmFrontFormJS() { function initFloatingLabels() { let checkFloatLabel, checkDropdownLabel, runOnLoad, selector, floatClass; - selector = '.frm-show-form .frm_inside_container input, .frm-show-form .frm_inside_container select, .frm-show-form .frm_inside_container textarea'; + selector = '.frm-show-form .frm_inside_container input, .frm-show-form .frm_inside_container select, .frm-show-form .frm_inside_container textarea'; floatClass = 'frm_label_float_top'; checkFloatLabel = function( input ) { @@ -1480,7 +1479,7 @@ function frmFrontFormJS() { firstOpt.setAttribute( 'data-label', firstOpt.textContent ); firstOpt.textContent = ''; } - }); + } ); }; [ 'focus', 'blur', 'change' ].forEach( function( eventName ) { @@ -1492,11 +1491,11 @@ function frmFrontFormJS() { }, true ); - }); + } ); jQuery( document ).on( 'change', selector, function( event ) { checkFloatLabel( event.target ); - }); + } ); runOnLoad = function( firstLoad ) { if ( firstLoad && document.activeElement && -1 !== [ 'INPUT', 'SELECT', 'TEXTAREA' ].indexOf( document.activeElement.tagName ) ) { @@ -1519,11 +1518,11 @@ function frmFrontFormJS() { jQuery( document ).on( 'frmPageChanged', function( event ) { runOnLoad(); - }); + } ); document.addEventListener( 'frm_after_start_over', function( event ) { runOnLoad(); - }); + } ); } function shouldUpdateValidityMessage( target ) { @@ -1562,7 +1561,7 @@ function frmFrontFormJS() { isInvalid = true; break; } - }; + } if ( ! isInvalid ) { field.setCustomValidity( '' ); @@ -1587,7 +1586,7 @@ function frmFrontFormJS() { function setCustomValidityMessage() { let forms, length, index; - forms = document.getElementsByClassName( 'frm-show-form' ); + forms = document.getElementsByClassName( 'frm-show-form' ); length = forms.length; for ( index = 0; index < length; ++index ) { @@ -1615,7 +1614,7 @@ function frmFrontFormJS() { ); removeSubmitLoading(); } - }); + } ); } /** @@ -1659,9 +1658,9 @@ function frmFrontFormJS() { /* eslint-disable compat/compat */ const startTime = performance.now(); - const step = ( currentTime ) => { + const step = currentTime => { const progress = Math.min( ( currentTime - startTime ) / duration, 1 ); - document.documentElement.scrollTop = start + ( end - start ) * progress; + document.documentElement.scrollTop = start + ( ( end - start ) * progress ); if ( progress < 1 ) { requestAnimationFrame( step ); } @@ -1679,7 +1678,7 @@ function frmFrontFormJS() { if ( jQuery( this ).val() === '' ) { jQuery( this ).trigger( 'blur' ); } - }); + } ); jQuery( document ).on( 'change', '.frm-show-form input[name^="item_meta"], .frm-show-form select[name^="item_meta"], .frm-show-form textarea[name^="item_meta"]', frmFrontForm.fieldValueChanged ); @@ -1726,7 +1725,7 @@ function frmFrontFormJS() { return; } - const size = captcha.getAttribute( 'data-size' ); + const size = captcha.getAttribute( 'data-size' ); const params = { sitekey: captcha.getAttribute( 'data-sitekey' ), size: size, @@ -1746,20 +1745,20 @@ function frmFrontFormJS() { }; } - const activeCaptcha = getSelectedCaptcha( captchaSelector ); + const activeCaptcha = getSelectedCaptcha( captchaSelector ); const captchaContainer = typeof turnstile !== 'undefined' && turnstile === activeCaptcha ? '#' + captcha.id : captcha.id; - const captchaID = activeCaptcha.render( captchaContainer, params ); + const captchaID = activeCaptcha.render( captchaContainer, params ); captcha.setAttribute( 'data-rid', captchaID ); }, afterSingleRecaptcha: function() { - const object = jQuery( '.frm-show-form .g-recaptcha' ).closest( 'form' )[0]; + const object = jQuery( '.frm-show-form .g-recaptcha' ).closest( 'form' )[ 0 ]; frmFrontForm.submitFormNow( object ); }, afterRecaptcha: function( _, formID ) { - const object = jQuery( '#frm_form_' + formID + '_container form' )[0]; + const object = jQuery( '#frm_form_' + formID + '_container form' )[ 0 ]; frmFrontForm.submitFormNow( object ); }, @@ -1803,7 +1802,6 @@ function frmFrontFormJS() { showLoadingIndicator( jQuery( object ) ); executeInvisibleRecaptcha( invisibleRecaptcha ); } else { - showSubmitLoading( jQuery( object ) ); frmFrontForm.submitFormNow( object ); @@ -1825,15 +1823,15 @@ function frmFrontFormJS() { // Add a unique ID, used for duplicate checks. const uniqueIDInput = document.createElement( 'input' ); - uniqueIDInput.type = 'hidden'; - uniqueIDInput.name = 'unique_id'; + uniqueIDInput.type = 'hidden'; + uniqueIDInput.name = 'unique_id'; uniqueIDInput.value = getUniqueKey(); object.appendChild( uniqueIDInput ); if ( classList.indexOf( 'frm_ajax_submit' ) > -1 ) { hasFileFields = jQuery( object ).find( 'input[type="file"]' ).filter( function() { return !! this.value; - }).length; + } ).length; if ( hasFileFields < 1 ) { const action = jQuery( object ).find( 'input[name="frm_action"]' ).val(); frmFrontForm.checkFormErrors( object, action ); @@ -1879,7 +1877,7 @@ function frmFrontFormJS() { if ( typeof frmThemeOverride_jsErrors === 'function' ) { // eslint-disable-line camelcase const action = jQuery( object ).find( 'input[name="frm_action"]' ).val(); customErrors = frmThemeOverride_jsErrors( action, object ); - if ( Object.keys( customErrors ).length ) { + if ( Object.keys( customErrors ).length ) { for ( key in customErrors ) { jsErrors[ key ] = customErrors[ key ]; } @@ -1889,7 +1887,7 @@ function frmFrontFormJS() { triggerCustomEvent( document, 'frm_get_ajax_form_errors', { formEl: object, errors: jsErrors - }); + } ); return jsErrors; }, @@ -1982,7 +1980,7 @@ function frmFrontFormJS() { return; } - jQuery( document ).trigger( 'frmFieldChanged', [ this, fieldId, e ]); + jQuery( document ).trigger( 'frmFieldChanged', [ this, fieldId, e ] ); if ( e.selfTriggered !== true ) { maybeValidateChange( this ); @@ -2030,7 +2028,7 @@ window.frmFrontForm = frmFrontFormJS(); jQuery( document ).ready( function() { frmFrontForm.init(); -}); +} ); function frmRecaptcha() { frmCaptcha( '.frm-g-recaptcha' ); @@ -2043,11 +2041,11 @@ function frmTurnstile() { function frmCaptcha( captchaSelector ) { let c; const captchas = document.querySelectorAll( captchaSelector ); - const cl = captchas.length; + const cl = captchas.length; for ( c = 0; c < cl; c++ ) { - const closestForm = captchas[c].closest( 'form' ); + const closestForm = captchas[ c ].closest( 'form' ); const formIsVisible = closestForm && closestForm.offsetParent !== null; - const captcha = captchas[c]; + const captcha = captchas[ c ]; if ( ! formIsVisible ) { // If the form is not visible, try again later in 400ms. // This fixes issues where the form fades visible on page load. diff --git a/js/formidable_admin.js b/js/formidable_admin.js index c24709330c..4efb352ccf 100644 --- a/js/formidable_admin.js +++ b/js/formidable_admin.js @@ -1,11286 +1 @@ -/* exported frm_add_logic_row, frm_remove_tag, frm_show_div, frmCheckAll, frmCheckAllLevel */ -/* eslint-disable jsdoc/require-param, prefer-const, no-redeclare, @wordpress/no-unused-vars-before-return, jsdoc/check-types, jsdoc/check-tag-names, @wordpress/i18n-translator-comments, @wordpress/valid-sprintf, jsdoc/require-returns-description, jsdoc/require-param-type, no-unused-expressions, compat/compat */ - -window.FrmFormsConnect = window.FrmFormsConnect || ( function( document, window, $ ) { - - /*global jQuery:false, frm_admin_js, frmGlobal, ajaxurl */ - - const el = { - messageBox: null, - reset: null, - - setElements: function() { - el.messageBox = document.querySelector( '.frm_pro_license_msg' ); - el.reset = document.getElementById( 'frm_reconnect_link' ); - } - }; - - /** - * Public functions and properties. - * - * @since 4.03 - * - * @type {Object} - */ - const app = { - - /** - * Register connect button event. - * - * @since 4.03 - */ - init: function() { - el.setElements(); - - $( document.getElementById( 'frm_deauthorize_link' ) ).on( 'click', app.deauthorize ); - $( '.frm_authorize_link' ).on( 'click', app.authorize ); - // Handles FF dashboard Authorize & Reauthorize events. - // Attach click event to parent as #frm_deauthorize_link & #frm_reconnect_link dynamically recreated by bootstrap.setupBootstrapDropdowns in dom.js - $( '.frm-dashboard-license-options' ).on( 'click', '#frm_deauthorize_link', app.deauthorize ); - $( '.frm-dashboard-license-options' ).on( 'click', '#frm_reconnect_link', app.reauthorize ); - - if ( el.reset !== null ) { - $( el.reset ).on( 'click', app.reauthorize ); - } - }, - - /* Manual license authorization */ - authorize: function() { - /*jshint validthis:true */ - const button = this; - const pluginSlug = this.getAttribute( 'data-plugin' ); - const input = document.getElementById( 'edd_' + pluginSlug + '_license_key' ); - const license = input.value; - let wpmu = document.getElementById( 'proplug-wpmu' ); - this.classList.add( 'frm_loading_button' ); - if ( wpmu === null ) { - wpmu = 0; - } else if ( wpmu.checked ) { - wpmu = 1; - } else { - wpmu = 0; - } - - $.ajax({ - type: 'POST', url: ajaxurl, dataType: 'json', - data: { - action: 'frm_addon_activate', - license: license, - plugin: pluginSlug, - wpmu: wpmu, - nonce: frmGlobal.nonce - }, - success: function( msg ) { - app.afterAuthorize( msg, input ); - button.classList.remove( 'frm_loading_button' ); - } - }); - }, - - afterAuthorize: function( msg, input ) { - if ( msg.success === true ) { - input.value = '•••••••••••••••••••'; - } - - wp.hooks.doAction( 'frm_after_authorize', msg ); - app.showMessage( msg ); - }, - - showProgress: function( msg ) { - if ( el.messageBox === null ) { - // In case the message box was added after page load. - el.setElements(); - } - - const messageBox = el.messageBox; - if ( messageBox === null ) { - return; - } - - if ( msg.success === true ) { - messageBox.classList.remove( 'frm_error_style' ); - messageBox.classList.add( 'frm_message', 'frm_updated_message' ); - } else { - messageBox.classList.add( 'frm_error_style' ); - messageBox.classList.remove( 'frm_message', 'frm_updated_message' ); - } - messageBox.classList.remove( 'frm_hidden' ); - messageBox.innerHTML = msg.message; - }, - - showMessage: function( msg ) { - if ( el.messageBox === null ) { - // In case the message box was added after page load. - el.setElements(); - } - const messageBox = el.messageBox; - - if ( msg.success === true ) { - app.showAuthorized( true ); - app.showInlineSuccess(); - - /** - * Triggers the after license is authorized action for a confirmation/success modal. - * @param {Object} msg An object containing message data received from Authorize request. - */ - wp.hooks.doAction( 'frmAdmin.afterLicenseAuthorizeSuccess', { msg }); - } - app.showProgress( msg ); - - if ( msg.message !== '' ) { - setTimeout( function() { - messageBox.innerHTML = ''; - messageBox.classList.add( 'frm_hidden' ); - messageBox.classList.remove( 'frm_error_style', 'frm_message', 'frm_updated_message' ); - }, 10000 ); - const refreshPage = document.querySelector( '.frm-admin-page-dashboard' ); - if ( refreshPage ) { - setTimeout( function() { - window.location.reload(); - }, 1000 ); - } - } - }, - - showAuthorized: function( show ) { - const from = show ? 'unauthorized' : 'authorized'; - const to = show ? 'authorized' : 'unauthorized'; - const container = document.querySelectorAll( '.frm_' + from + '_box' ); - if ( container.length ) { - // Replace all authorized boxes with unauthorized boxes. - container.forEach( function( box ) { - box.className = box.className.replace( 'frm_' + from + '_box', 'frm_' + to + '_box' ); - }); - } - }, - - /** - * Use the data-success element to replace the element content. - */ - showInlineSuccess: function() { - const successElement = document.querySelectorAll( '.frm-confirm-msg [data-success]' ); - if ( successElement.length ) { - successElement.forEach( function( element ) { - element.innerHTML = frmAdminBuild.purifyHtml( element.getAttribute( 'data-success' ) ); - }); - } - }, - - /* Clear the site license cache */ - reauthorize: function() { - /*jshint validthis:true */ - this.innerHTML = ''; - - $.ajax({ - type: 'POST', - url: ajaxurl, - dataType: 'json', - data: { - action: 'frm_reset_cache', - plugin: 'formidable_pro', - nonce: frmGlobal.nonce - }, - success: function( msg ) { - el.reset.textContent = msg.message; - if ( el.reset.getAttribute( 'data-refresh' ) === '1' ) { - window.location.reload(); - } - } - }); - return false; - }, - - deauthorize: function() { - /*jshint validthis:true */ - if ( ! confirm( frmGlobal.deauthorize ) ) { - return false; - } - const pluginSlug = this.getAttribute( 'data-plugin' ), - input = document.getElementById( 'edd_' + pluginSlug + '_license_key' ), - license = input.value, - link = this; - - this.innerHTML = ''; - - $.ajax({ - type: 'POST', - url: ajaxurl, - data: { - action: 'frm_addon_deactivate', - license: license, - plugin: pluginSlug, - nonce: frmGlobal.nonce - }, - success: function() { - app.showAuthorized( false ); - input.value = ''; - link.replaceWith( 'Disconnected' ); - - /** - * Triggers the after license is deauthorized sruccess action. - */ - wp.hooks.doAction( 'frmAdmin.afterLicenseDeauthorizeSuccess', {}); - - } - }); - return false; - } - }; - - // Provide access to public functions/properties. - return app; - -}( document, window, jQuery ) ); - -function frmAdminBuildJS() { - //'use strict'; - - /*global jQuery:false, frm_admin_js, frmGlobal, ajaxurl, fromDom */ - - const frmAdminJs = frm_admin_js; // eslint-disable-line camelcase - const { tag, div, span, a, svg, img } = frmDom; - const { onClickPreventDefault } = frmDom.util; - const { doJsonFetch, doJsonPost } = frmDom.ajax; - frmAdminJs.contextualShortcodes = getContextualShortcodes(); - const icons = { - save: svg({ href: '#frm_save_icon' }), - drag: svg({ href: '#frm_drag_icon', classList: [ 'frm_drag_icon', 'frm-drag' ] }) - }; - - let $newFields = jQuery( document.getElementById( 'frm-show-fields' ) ), - builderForm = document.getElementById( 'new_fields' ), - thisForm = document.getElementById( 'form_id' ), - copyHelper = false, - fieldsUpdated = 0, - thisFormId = 0, - autoId = 0, - optionMap = {}, - lastNewActionIdReturned = 0; - - const { __, sprintf } = wp.i18n; - let debouncedSyncAfterDragAndDrop, postBodyContent, $postBodyContent; - - const dragState = { - dragging: false - }; - - if ( thisForm !== null ) { - thisFormId = thisForm.value; - } - - const currentURL = new URL( window.location.href ); - const urlParams = currentURL.searchParams; - const builderPage = document.getElementById( 'frm_builder_page' ); - - // Global settings - let s; - - function showElement( element ) { - if ( ! element[0]) { - return; - } - element[0].style.display = ''; - } - - function empty( $obj ) { - if ( $obj !== null ) { - while ( $obj.firstChild ) { - $obj.removeChild( $obj.firstChild ); - } - } - } - - function addClass( $obj, className ) { - if ( $obj.classList ) { - $obj.classList.add( className ); - } else { - $obj.className += ' ' + className; - } - } - - function confirmClick( e ) { - /*jshint validthis:true */ - e.stopPropagation(); - e.preventDefault(); - confirmLinkClick( this ); - } - - function confirmLinkClick( link ) { - const message = link.getAttribute( 'data-frmverify' ), - loadedFrom = link.getAttribute( 'data-loaded-from' ) ; - - if ( message === null || link.id === 'frm-confirmed-click' ) { - return true; - } - - if ( 'entries-list' === loadedFrom ) { - return wp.hooks.applyFilters( 'frm_on_multiple_entries_delete', { link, initModal }); - } - - return confirmModal( link ); - } - - function confirmModal( link ) { - let verify, $confirmMessage, i, dataAtts, btnClass, - $info = initModal( '#frm_confirm_modal', '400px' ), - continueButton = document.getElementById( 'frm-confirmed-click' ); - - if ( $info === false ) { - return false; - } - - verify = link.getAttribute( 'data-frmverify' ); - btnClass = verify ? link.getAttribute( 'data-frmverify-btn' ) : ''; - $confirmMessage = jQuery( '.frm-confirm-msg' ); - $confirmMessage.empty(); - - if ( verify ) { - $confirmMessage.append( document.createTextNode( verify ) ); - if ( btnClass ) { - continueButton.classList.add( btnClass ); - } - } - - removeAtts = continueButton.dataset; - for ( i in dataAtts ) { - continueButton.removeAttribute( 'data-' + i ); - } - - dataAtts = link.dataset; - for ( i in dataAtts ) { - if ( i !== 'frmverify' ) { - continueButton.setAttribute( 'data-' + i, dataAtts[i]); - } - } - - /** - * Triggers the pre-open action for a confirmation modal. This action passes - * relevant modal information and associated link to any listening hooks. - * - * @param {Object} options An object containing modal elements and data. - * @param {HTMLElement} options.$info The HTML element containing modal information. - * @param {string} options.link The link associated with the modal action. - */ - wp.hooks.doAction( 'frmAdmin.beforeOpenConfirmModal', { $info, link }); - - $info.dialog( 'open' ); - continueButton.setAttribute( 'href', link.getAttribute( 'href' ) || link.getAttribute( 'data-href' ) ); - return false; - } - - function infoModal( msg ) { - const $info = initModal( '#frm_info_modal', '400px' ); - - if ( $info === false ) { - return false; - } - - jQuery( '.frm-info-msg' ).html( msg ); - - $info.dialog( 'open' ); - return false; - } - - function toggleItem( e ) { - /*jshint validthis:true */ - const toggle = this.getAttribute( 'data-frmtoggle' ); - const text = this.getAttribute( 'data-toggletext' ); - const $items = jQuery( toggle ); - - e.preventDefault(); - - $items.toggle(); - - if ( text !== null && text !== '' ) { - this.setAttribute( 'data-toggletext', this.innerHTML ); - this.textContent = text; - } - - return false; - } - - /** - * Toggle a class on target elements when an anchor is clicked, or when a radio or checkbox has been selected. - * - * @param {Event} e Event with either the change or click type. - * @returns {false} - */ - function hideShowItem( e ) { - /*jshint validthis:true */ - let hide = this.getAttribute( 'data-frmhide' ); - let show = this.getAttribute( 'data-frmshow' ); - let uncheckList = this.getAttribute( 'data-frmuncheck' ); - let uncheckListArray = uncheckList ? uncheckList.split( ',' ) : []; - - // Flip unchecked checkboxes so an off value undoes the on value. - if ( isUncheckedCheckbox( this ) ) { - if ( hide !== null ) { - show = hide; - hide = null; - } else if ( show !== null ) { - hide = show; - show = null; - } - } - - e.preventDefault(); - - const toggleClass = this.getAttribute( 'data-toggleclass' ) || 'frm_hidden'; - - if ( hide !== null ) { - jQuery( hide ).addClass( toggleClass ); - } - - if ( show !== null ) { - jQuery( show ).removeClass( toggleClass ); - } - - const current = this.parentNode.querySelectorAll( 'a.current' ); - if ( current !== null ) { - for ( let i = 0; i < current.length; i++ ) { - current[ i ].classList.remove( 'current' ); - } - this.classList.add( 'current' ); - } - - if ( uncheckListArray.length ) { - uncheckListArray.forEach( function( uncheckItem ) { - const uncheckItemElement = document.querySelector( uncheckItem ); - if ( uncheckItemElement ) { - uncheckItemElement.checked = false; - } - }); - } - - return false; - } - - function isUncheckedCheckbox( element ) { - return 'INPUT' === element.nodeName && 'checkbox' === element.type && ! element.checked; - } - - function loadTooltips() { - let wrapClass = jQuery( '.wrap, .frm_wrap' ), - confirmModal = document.getElementById( 'frm_confirm_modal' ), - doAction = false, - confirmedBulkDelete = false; - - jQuery( confirmModal ).on( 'click', '[data-deletefield]', deleteFieldConfirmed ); - jQuery( confirmModal ).on( 'click', '[data-removeid]', removeThisTag ); - jQuery( confirmModal ).on( 'click', '[data-trashtemplate]', trashTemplate ); - - wrapClass.on( 'click', '.frm_remove_tag, .frm_remove_form_action', removeThisTag ); - wrapClass.on( 'click', 'a[data-frmverify]', confirmClick ); - wrapClass.on( 'click', 'a[data-frmtoggle]', toggleItem ); - wrapClass.on( 'click', 'a[data-frmhide], a[data-frmshow]', hideShowItem ); - wrapClass.on( 'change', 'input[data-frmhide], input[data-frmshow]', hideShowItem ); - wrapClass.on( 'click', '.widget-top,a.widget-action', clickWidget ); - - wrapClass.on( 'mouseenter.frm', '.frm_bstooltip, .frm_help', function() { - jQuery( this ).off( 'mouseenter.frm' ); - - jQuery( '.frm_bstooltip, .frm_help' ).tooltip(); - jQuery( this ).tooltip( 'show' ); - }); - - jQuery( '.frm_bstooltip, .frm_help' ).tooltip( ); - - jQuery( document ).on( 'click', '#doaction, #doaction2', function( event ) { - const isTop = this.id === 'doaction', - suffix = isTop ? 'top' : 'bottom', - bulkActionSelector = document.getElementById( 'bulk-action-selector-' + suffix ), - confirmBulkDelete = document.getElementById( 'confirm-bulk-delete-' + suffix ); - - if ( bulkActionSelector !== null && confirmBulkDelete !== null ) { - doAction = this; - - if ( ! confirmedBulkDelete && bulkActionSelector.value === 'bulk_delete' ) { - event.preventDefault(); - confirmLinkClick( confirmBulkDelete ); - return false; - } - } else { - doAction = false; - } - }); - - jQuery( document ).on( 'click', '#frm-confirmed-click', function( event ) { - if ( doAction === false || event.target.classList.contains( 'frm-btn-inactive' ) ) { - return; - } - - if ( this.getAttribute( 'href' ) === 'confirm-bulk-delete' ) { - event.preventDefault(); - confirmedBulkDelete = true; - doAction.click(); - return false; - } - }); - } - - function deleteTooltips() { - document.querySelectorAll( '.tooltip' ).forEach( - function( tooltip ) { - tooltip.remove(); - } - ); - } - - function removeThisTag() { - /*jshint validthis:true */ - let show, hide, removeMore; - - if ( parseInt( this.getAttribute( 'data-skip-frm-js' ) ) || confirmLinkClick( this ) === false ) { - return; - } - - const deleteButton = jQuery( this ); - const id = deleteButton.attr( 'data-removeid' ); - - show = deleteButton.attr( 'data-showlast' ); - if ( typeof show === 'undefined' ) { - show = ''; - } - - hide = deleteButton.attr( 'data-hidelast' ); - if ( typeof hide === 'undefined' ) { - hide = ''; - } - - removeMore = deleteButton.attr( 'data-removemore' ); - - if ( show !== '' ) { - if ( deleteButton.closest( '.frm_add_remove' ).find( '.frm_remove_tag:visible' ).length > 1 ) { - show = ''; - hide = ''; - } - } else if ( id.indexOf( 'frm_postmeta_' ) === 0 ) { - if ( jQuery( '#frm_postmeta_rows .frm_postmeta_row' ).length < 2 ) { - show = '.frm_add_postmeta_row.button'; - } - if ( jQuery( '.frm_toggle_cf_opts' ).length && jQuery( '#frm_postmeta_rows .frm_postmeta_row:not(#' + id + ')' ).last().length ) { - if ( show !== '' ) { - show += ','; - } - show += '#' + jQuery( '#frm_postmeta_rows .frm_postmeta_row:not(#' + id + ')' ).last().attr( 'id' ) + ' .frm_toggle_cf_opts'; - } - } - - const $fadeEle = jQuery( document.getElementById( id ) ); - $fadeEle.fadeOut( 400, function() { - $fadeEle.remove(); - fieldUpdated(); - - if ( hide !== '' ) { - jQuery( hide ).hide(); - } - - if ( show !== '' ) { - jQuery( show + ' a,' + show ).removeClass( 'frm_hidden' ).fadeIn( 'slow' ); - } - - if ( this.closest( '.frm_form_action_settings' ) ) { - const type = this.closest( '.frm_form_action_settings' ).querySelector( '.frm_action_name' ).value; - afterActionRemoved( type ); - } - document.querySelector( '.tooltip' )?.remove(); - }); - - if ( typeof removeMore !== 'undefined' ) { - removeMore = jQuery( removeMore ); - removeMore.fadeOut( 400, function() { - removeMore.remove(); - }); - } - - if ( show !== '' ) { - jQuery( this ).closest( '.frm_logic_rows' ).fadeOut( 'slow' ); - } - - return false; - } - - function afterActionRemoved( type ) { - checkActiveAction( type ); - - const hookName = 'frm_after_action_removed'; - const hookArgs = { type }; - wp.hooks.doAction( hookName, hookArgs ); - } - - function clickWidget( event, b ) { - /*jshint validthis:true */ - if ( typeof b === 'undefined' ) { - b = this; - } - - popCalcFields( b, false ); - - const cont = jQuery( b ).closest( '.frm_form_action_settings' ); - const target = event.target; - - if ( cont.length && typeof target !== 'undefined' ) { - const className = target.parentElement.className; - if ( 'string' === typeof className ) { - if ( className.indexOf( 'frm_email_icons' ) > -1 || className.indexOf( 'frm_toggle' ) > -1 ) { - // clicking on delete icon shouldn't open it - event.stopPropagation(); - return; - } - } - } - - let inside = cont.children( '.widget-inside' ); - - if ( cont.length && inside.find( 'p, div, table' ).length < 1 ) { - const actionId = cont.find( 'input[name$="[ID]"]' ).val(); - const actionType = cont.find( 'input[name$="[post_excerpt]"]' ).val(); - if ( actionType ) { - inside.html( '' ); - cont.find( '.spinner' ).fadeIn( 'slow' ); - jQuery.ajax({ - type: 'POST', - url: ajaxurl, - data: { - action: 'frm_form_action_fill', - action_id: actionId, - action_type: actionType, - nonce: frmGlobal.nonce - }, - success: function( html ) { - inside.html( html ); - initiateMultiselect(); - showInputIcon( '#' + cont.attr( 'id' ) ); - initAutocomplete( inside ); - jQuery( b ).trigger( 'frm-action-loaded' ); - - /** - * Fires after filling form action content when opening. - * - * @since 5.5.4 - * - * @param {Object} insideElement JQuery object of form action inside element. - */ - wp.hooks.doAction( 'frm_filled_form_action', inside ); - } - }); - } - } - - jQuery( b ).closest( '.frm_field_box' ).siblings().find( '.widget-inside' ).slideUp( 'fast' ); - if ( ( typeof b.className !== 'undefined' && b.className.indexOf( 'widget-action' ) !== -1 ) || jQuery( b ).closest( '.start_divider' ).length < 1 ) { - return; - } - - inside = jQuery( b ).closest( 'div.widget' ).children( '.widget-inside' ); - if ( inside.is( ':hidden' ) ) { - inside.slideDown( 'fast' ); - } else { - inside.slideUp( 'fast' ); - } - } - - function clickNewTab() { - /*jshint validthis:true */ - const t = this.getAttribute( 'href' ); - if ( typeof t === 'undefined' ) { - return false; - } - - const c = t.replace( '#', '.' ); - const $link = jQuery( this ); - - $link.closest( 'li' ).addClass( 'frm-tabs active' ).siblings( 'li' ).removeClass( 'frm-tabs active starttab' ); - $link.closest( 'div' ).children( '.tabs-panel' ).not( t ).not( c ).hide(); - - const tabContent = document.getElementById( t.replace( '#', '' ) ); - if ( tabContent ) { - tabContent.style.display = 'block'; - } - - // clearSettingsBox would hide field settings when opening the fields modal and we want to skip it there. - if ( this.id === 'frm_insert_fields_tab' && ! this.closest( '#frm_adv_info' ) ) { - clearSettingsBox(); - } - return false; - } - - function clickTab( link, auto ) { - link = jQuery( link ); - const t = link.attr( 'href' ); - if ( typeof t === 'undefined' ) { - return; - } - - const c = t.replace( '#', '.' ); - - link.closest( 'li' ).addClass( 'frm-tabs active' ).siblings( 'li' ).removeClass( 'frm-tabs active starttab' ); - if ( link.closest( 'div' ).find( '.tabs-panel' ).length ) { - link.closest( 'div' ).children( '.tabs-panel' ).not( t ).not( c ).hide(); - } else if ( document.getElementById( 'form_global_settings' ) !== null ) { - /* global settings */ - const ajax = link.data( 'frmajax' ); - link.closest( '.frm_wrap' ).find( '.tabs-panel, .hide_with_tabs' ).hide(); - if ( typeof ajax !== 'undefined' && ajax == '1' ) { - loadSettingsTab( t ); - } - } else { - /* form settings page */ - jQuery( '#frm-categorydiv .tabs-panel, .hide_with_tabs' ).hide(); - } - jQuery( t ).show(); - jQuery( c ).show(); - - hideShortcodes(); - - if ( auto !== 'auto' ) { - // Hide success message on tab change. - jQuery( '.frm_updated_message' ).hide(); - jQuery( '.frm_warning_style' ).hide(); - } - - if ( jQuery( link ).closest( '#frm_adv_info' ).length ) { - return; - } - - if ( jQuery( '.frm_form_settings' ).length ) { - jQuery( '.frm_form_settings' ).attr( 'action', '?page=formidable&frm_action=settings&id=' + jQuery( '.frm_form_settings input[name="id"]' ).val() + '&t=' + t.replace( '#', '' ) ); - } else { - jQuery( '.frm_settings_form' ).attr( 'action', '?page=formidable-settings&t=' + t.replace( '#', '' ) ); - } - } - - function setupSortable( sortableSelector ) { - document.querySelectorAll( sortableSelector ).forEach( - list => { - makeDroppable( list ); - Array.from( list.children ).forEach( child => makeDraggable( child, '.frm-move' ) ); - - const $sectionTitle = jQuery( list ).children( '[data-type="divider"]' ).children( '.divider_section_only' ); - if ( $sectionTitle.length ) { - makeDroppable( $sectionTitle ); - } - } - ); - setupFieldOptionSorting( jQuery( '#frm_builder_page' ) ); - } - - function makeDroppable( list ) { - jQuery( list ).droppable({ - accept: '.frmbutton, li.frm_field_box', - deactivate: handleFieldDrop, - over: onDragOverDroppable, - out: onDraggableLeavesDroppable, - tolerance: 'pointer' - }); - } - - function onDragOverDroppable( event, ui ) { - const droppable = getDroppableForOnDragOver( event.target ); - const draggable = ui.draggable[0]; - - if ( ! allowDrop( draggable, droppable, event ) ) { - droppable.classList.remove( 'frm-over-droppable' ); - jQuery( droppable ).parents( 'ul.frm_sorting' ).addClass( 'frm-over-droppable' ); - return; - } - - document.querySelectorAll( '.frm-over-droppable' ).forEach( droppable => droppable.classList.remove( 'frm-over-droppable' ) ); - droppable.classList.add( 'frm-over-droppable' ); - jQuery( droppable ).parents( 'ul.frm_sorting' ).addClass( 'frm-over-droppable' ); - } - - /** - * Maybe change the droppable. - * Section titles are made droppable, but are not a list, so we need to change the droppable to the section's list instead. - * - * @param {Element} droppable - * @returns {Element} - */ - function getDroppableForOnDragOver( droppable ) { - if ( droppable.classList.contains( 'divider_section_only' ) ) { - droppable = jQuery( droppable ).nextAll( '.start_divider.frm_sorting' ).get( 0 ); - } - return droppable; - } - - function onDraggableLeavesDroppable( event ) { - const droppable = event.target; - droppable.classList.remove( 'frm-over-droppable' ); - } - - function makeDraggable( draggable, handle ) { - const settings = { - helper: getDraggableHelper, - revert: 'invalid', - delay: 10, - start: handleDragStart, - stop: handleDragStop, - drag: handleDrag, - cursor: 'grabbing', - refreshPositions: true, - cursorAt: { - top: 0, - left: 90 // The width of draggable button is 180. 90 should center the draggable on the cursor. - } - }; - if ( 'string' === typeof handle ) { - settings.handle = handle; - } - jQuery( draggable ).draggable( settings ); - } - - function getDraggableHelper( event ) { - const draggable = event.delegateTarget; - - if ( isFieldGroup( draggable ) ) { - const newTextFieldClone = document.getElementById( 'frm-insert-fields' ).querySelector( '.frm_ttext' ).cloneNode( true ); - newTextFieldClone.querySelector( 'use' ).setAttributeNS( 'http://www.w3.org/1999/xlink', 'href', '#frm_field_group_layout_icon' ); - newTextFieldClone.querySelector( 'span' ).textContent = __( 'Field Group', 'formidable' ); - newTextFieldClone.classList.add( 'frm_field_box' ); - newTextFieldClone.classList.add( 'ui-sortable-helper' ); - return newTextFieldClone; - } - - let copyTarget; - const isNewField = draggable.classList.contains( 'frmbutton' ); - if ( isNewField ) { - copyTarget = draggable.cloneNode( true ); - copyTarget.classList.add( 'ui-sortable-helper' ); - draggable.classList.add( 'frm-new-field' ); - return copyTarget; - } - - if ( draggable.hasAttribute( 'data-ftype' ) ) { - const fieldType = draggable.getAttribute( 'data-ftype' ); - copyTarget = document.getElementById( 'frm-insert-fields' ).querySelector( '.frm_t' + fieldType ); - copyTarget = copyTarget.cloneNode( true ); - copyTarget.classList.add( 'form-field' ); - - copyTarget.classList.add( 'ui-sortable-helper' ); - - if ( copyTarget ) { - return copyTarget.cloneNode( true ); - } - } - - return div({ className: 'frmbutton' }); - } - - function handleDragStart( event, ui ) { - dragState.dragging = true; - - const container = postBodyContent; - container.classList.add( 'frm-dragging-field' ); - - document.body.classList.add( 'frm-dragging' ); - ui.helper.addClass( 'frm-sortable-helper' ); - ui.helper.initialOffset = container.scrollTop; - - event.target.classList.add( 'frm-drag-fade' ); - - unselectFieldGroups(); - deleteEmptyDividerWrappers(); - maybeRemoveGroupHoverTarget(); - closeOpenFieldDropdowns(); - deleteTooltips(); - } - - function handleDragStop() { - const container = postBodyContent; - container.classList.remove( 'frm-dragging-field' ); - document.body.classList.remove( 'frm-dragging' ); - - const fade = document.querySelector( '.frm-drag-fade' ); - if ( fade ) { - fade.classList.remove( 'frm-drag-fade' ); - } - } - - function handleDrag( event, ui ) { - maybeScrollBuilder( event ); - const draggable = event.target; - const droppable = getDroppableTarget(); - - let placeholder = document.getElementById( 'frm_drag_placeholder' ); - if ( ! allowDrop( draggable, droppable, event ) ) { - if ( placeholder ) { - placeholder.remove(); - } - return; - } - - if ( ! placeholder ) { - placeholder = tag( 'li', { - id: 'frm_drag_placeholder', - className: 'sortable-placeholder' - }); - } - const frmSortableHelper = ui.helper.get( 0 ); - if ( frmSortableHelper.classList.contains( 'form-field' ) || frmSortableHelper.classList.contains( 'frm_field_box' ) ) { - // Sync the y position of the draggable so it still follows the cursor after scrolling up and down the field list. - frmSortableHelper.style.transform = 'translateY(' + getDragOffset( ui.helper ) + 'px)'; - } - - if ( 'frm-show-fields' === droppable.id || droppable.classList.contains( 'start_divider' ) ) { - placeholder.style.left = 0; - handleDragOverYAxis({ droppable, y: event.clientY, placeholder }); - return; - } - - placeholder.style.top = ''; - handleDragOverFieldGroup({ droppable, x: event.clientX, placeholder }); - } - - function maybeScrollBuilder( event ) { - $postBodyContent.scrollTop( - ( _, v ) => { - const moved = event.clientY; - const h = postBodyContent.offsetHeight; - const relativePos = event.clientY - postBodyContent.offsetTop; - const y = relativePos - h / 2; - - if ( relativePos > ( h - 50 ) && moved > 5 ) { - // Scrolling down. - return v + y * 0.1; - } - - if ( relativePos < 70 && moved < 130 ) { - // Scrolling up. - return v - Math.abs( y * 0.1 ); - } - - return v; - } - ); - } - - function getDragOffset( $helper ) { - return postBodyContent.scrollTop - $helper.initialOffset; - } - - function getDroppableTarget() { - let droppable = document.getElementById( 'frm-show-fields' ); - while ( droppable.querySelector( '.frm-over-droppable' ) ) { - droppable = droppable.querySelector( '.frm-over-droppable' ); - } - if ( 'frm-show-fields' === droppable.id && ! droppable.classList.contains( 'frm-over-droppable' ) ) { - droppable = false; - } - return droppable; - } - - function handleFieldDrop( _, ui ) { - if ( ! dragState.dragging ) { - // dragState.dragging is set to true on drag start. - // The deactivate event gets called for every droppable. This check to make sure it happens once. - return; - } - - dragState.dragging = false; - - const draggable = ui.draggable[0]; - const placeholder = document.getElementById( 'frm_drag_placeholder' ); - - if ( ! placeholder ) { - ui.helper.remove(); - debouncedSyncAfterDragAndDrop(); - return; - } - - maybeOpenCollapsedPage( placeholder ); - - const $previousFieldContainer = ui.helper.parent(); - const previousSection = ui.helper.get( 0 ).closest( 'ul.start_divider' ); - const newSection = placeholder.closest( 'ul.frm_sorting' ); - - if ( draggable.classList.contains( 'frm-new-field' ) ) { - insertNewFieldByDragging( draggable.id ); - } else { - moveFieldThatAlreadyExists( draggable, placeholder ); - } - - const previousSectionId = previousSection ? parseInt( previousSection.closest( '.edit_field_type_divider' ).getAttribute( 'data-fid' ) ) : 0; - const newSectionId = newSection.classList.contains( 'start_divider' ) ? parseInt( newSection.closest( '.edit_field_type_divider' ).getAttribute( 'data-fid' ) ) : 0; - - placeholder.remove(); - ui.helper.remove(); - - const $previousContainerFields = $previousFieldContainer.length ? getFieldsInRow( $previousFieldContainer ) : []; - maybeUpdatePreviousFieldContainerAfterDrop( $previousFieldContainer, $previousContainerFields ); - maybeUpdateDraggableClassAfterDrop( draggable, $previousContainerFields ); - - if ( previousSectionId !== newSectionId ) { - updateFieldAfterMovingBetweenSections( jQuery( draggable ), previousSection ); - } - - debouncedSyncAfterDragAndDrop(); - } - - /** - * If a page if collapsed, expand it before dragging since only the page break will move. - * - * @param {Element} placeholder - * @returns {void} - */ - function maybeOpenCollapsedPage( placeholder ) { - if ( ! placeholder.previousElementSibling || ! placeholder.previousElementSibling.classList.contains( 'frm-is-collapsed' ) ) { - return; - } - - const $pageBreakField = jQuery( placeholder ).prevUntil( '[data-type="break"]' ); - if ( ! $pageBreakField.length ) { - return; - } - - const collapseButton = $pageBreakField.find( '.frm-collapse-page' ).get( 0 ); - if ( collapseButton ) { - collapseButton.click(); - } - } - - function maybeUpdatePreviousFieldContainerAfterDrop( $previousFieldContainer, $previousContainerFields ) { - if ( ! $previousFieldContainer.length ) { - return; - } - - if ( $previousContainerFields.length ) { - syncLayoutClasses( $previousContainerFields.first() ); - } else { - maybeDeleteAnEmptyFieldGroup( $previousFieldContainer.get( 0 ) ); - } - } - - function maybeUpdateDraggableClassAfterDrop( draggable, $previousContainerFields ) { - if ( 0 !== $previousContainerFields.length || 1 !== getFieldsInRow( jQuery( draggable.parentNode ) ).length ) { - syncLayoutClasses( jQuery( draggable ) ); - } - } - - /** - * Remove an empty field group, but don't remove an empty section. - * - * @param {Element} previousFieldContainer - * @returns {void} - */ - function maybeDeleteAnEmptyFieldGroup( previousFieldContainer ) { - const closestFieldBox = previousFieldContainer.closest( 'li.frm_field_box' ); - if ( closestFieldBox && ! closestFieldBox.classList.contains( 'edit_field_type_divider' ) ) { - closestFieldBox.remove(); - } - } - - function handleDragOverYAxis({ droppable, y, placeholder }) { - const $list = jQuery( droppable ); - - let top; - - $children = $list.children().not( '.edit_field_type_end_divider' ); - if ( 0 === $children.length ) { - $list.prepend( placeholder ); - top = 0; - } else { - const insertAtIndex = determineIndexBasedOffOfMousePositionInList( $list, y ); - - if ( insertAtIndex === $children.length ) { - const $lastChild = jQuery( $children.get( insertAtIndex - 1 ) ); - top = $lastChild.offset().top + $lastChild.outerHeight(); - $list.append( placeholder ); - - // Make sure nothing gets inserted after the end divider. - const $endDivider = $list.children( '.edit_field_type_end_divider' ); - if ( $endDivider.length ) { - $list.append( $endDivider ); - } - } else { - top = jQuery( $children.get( insertAtIndex ) ).offset().top; - jQuery( $children.get( insertAtIndex ) ).before( placeholder ); - } - } - - top -= $list.offset().top; - placeholder.style.top = top + 'px'; - } - - function determineIndexBasedOffOfMousePositionInList( $list, y ) { - const $items = $list.children().not( '.edit_field_type_end_divider' ); - const length = $items.length; - - let index, item, itemTop, returnIndex; - - if ( ! document.querySelector( '.frm-has-fields .frm_no_fields' ) ) { - // Always return 0 when there are no fields. - return 0; - } - - returnIndex = 0; - for ( index = length - 1; index >= 0; --index ) { - item = $items.get( index ); - itemTop = jQuery( item ).offset().top; - if ( y > itemTop ) { - returnIndex = index; - if ( y > itemTop + ( jQuery( item ).outerHeight() / 2 ) ) { - returnIndex = index + 1; - } - break; - } - } - - return returnIndex; - } - - function handleDragOverFieldGroup({ droppable, x, placeholder }) { - const $row = jQuery( droppable ); - const $children = getFieldsInRow( $row ); - - if ( ! $children.length ) { - return; - } - - let left; - const insertAtIndex = determineIndexBasedOffOfMousePositionInRow( $row, x ); - - if ( insertAtIndex === $children.length ) { - const $lastChild = jQuery( $children.get( insertAtIndex - 1 ) ); - left = $lastChild.offset().left + $lastChild.outerWidth(); - $row.append( placeholder ); - } else { - left = jQuery( $children.get( insertAtIndex ) ).offset().left; - jQuery( $children.get( insertAtIndex ) ).before( placeholder ); - - const amountToOffsetLeftBy = 0 === insertAtIndex ? 4 : 8; // Offset by 8 in between rows, but only 4 for the first item in a group. - left -= amountToOffsetLeftBy; // Offset the placeholder slightly so it appears between two fields. - } - - left -= $row.offset().left; - - placeholder.style.left = left + 'px'; - } - - function syncAfterDragAndDrop() { - fixUnwrappedListItems(); - toggleSectionHolder(); - maybeFixEndDividers(); - maybeDeleteEmptyFieldGroups(); - updateFieldOrder(); - - const event = new Event( 'frm_sync_after_drag_and_drop', { bubbles: false }); - document.dispatchEvent( event ); - } - - function maybeFixEndDividers() { - document.querySelectorAll( '.edit_field_type_end_divider' ).forEach( - endDivider => endDivider.parentNode.appendChild( endDivider ) - ); - } - - function maybeDeleteEmptyFieldGroups() { - document.querySelectorAll( 'li.form_field_box:not(.form-field)' ).forEach( - fieldGroup => ! fieldGroup.children.length && fieldGroup.remove() - ); - } - - function fixUnwrappedListItems() { - const lists = document.querySelectorAll( 'ul#frm-show-fields, ul.start_divider' ); - lists.forEach( - list => { - list.childNodes.forEach( - child => { - if ( 'undefined' === typeof child.classList ) { - return; - } - - if ( child.classList.contains( 'edit_field_type_end_divider' ) ) { - // Never wrap end divider in place. - return; - } - - if ( 'undefined' !== typeof child.classList && child.classList.contains( 'form-field' ) ) { - wrapFieldLiInPlace( child ); - } - } - ); - } - ); - } - - function deleteEmptyDividerWrappers() { - const dividers = document.querySelectorAll( 'ul.start_divider' ); - if ( ! dividers.length ) { - return; - } - dividers.forEach( - function( divider ) { - const children = [].slice.call( divider.children ); - children.forEach( - function( child ) { - if ( 0 === child.children.length ) { - child.remove(); - } else if ( 1 === child.children.length && 'ul' === child.firstElementChild.nodeName.toLowerCase() && 0 === child.firstElementChild.children.length ) { - child.remove(); - } - } - ); - } - ); - } - - function getFieldsInRow( $row ) { - let $fields = jQuery(); - - const row = $row.get( 0 ); - if ( ! row.children ) { - return $fields; - } - - Array.from( row.children ).forEach( - child => { - if ( 'none' === child.style.display ) { - return; - } - - const classes = child.classList; - if ( ! classes.contains( 'form-field' ) || classes.contains( 'edit_field_type_end_divider' ) || classes.contains( 'frm-sortable-helper' ) ) { - return; - } - - $fields = $fields.add( child ); - } - ); - return $fields; - } - - function determineIndexBasedOffOfMousePositionInRow( $row, x ) { - let $inputs = getFieldsInRow( $row ), - length = $inputs.length, - index, input, inputLeft, returnIndex; - - returnIndex = 0; - for ( index = length - 1; index >= 0; --index ) { - input = $inputs.get( index ); - inputLeft = jQuery( input ).offset().left; - if ( x > inputLeft ) { - returnIndex = index; - if ( x > inputLeft + ( jQuery( input ).outerWidth() / 2 ) ) { - returnIndex = index + 1; - } - break; - } - } - - return returnIndex; - } - - function syncLayoutClasses( $item, type ) { - let $fields, size, layoutClasses, classToAddFunction; - - if ( 'undefined' === typeof type ) { - type = 'even'; - } - - $fields = $item.parent().children( 'li.form-field, li.frmbutton_loadingnow' ).not( '.edit_field_type_end_divider' ); - size = $fields.length; - layoutClasses = getLayoutClasses(); - - if ( 'even' === type && 5 !== size ) { - $fields.each( getSyncLayoutClass( layoutClasses, getEvenClassForSize( size ) ) ); - } else if ( 'clear' === type ) { - $fields.each( getSyncLayoutClass( layoutClasses, '' ) ); - } else { - if ( -1 !== [ 'left', 'right', 'middle', 'even' ].indexOf( type ) ) { - classToAddFunction = function( index ) { - return getClassForBlock( size, type, index ); - }; - } else { - classToAddFunction = function( index ) { - const size = type[ index ]; - return getLayoutClassForSize( size ); - }; - } - - $fields.each( getSyncLayoutClass( layoutClasses, classToAddFunction ) ); - } - - updateFieldGroupControls( $item.parent(), $fields.length ); - } - - function updateFieldGroupControls( $row, count ) { - let rowOffset, shouldShowControls, controls; - - rowOffset = $row.offset(); - - if ( 'undefined' === typeof rowOffset ) { - return; - } - - shouldShowControls = count >= 2; - - controls = document.getElementById( 'frm_field_group_controls' ); - if ( null === controls ) { - if ( ! shouldShowControls ) { - // exit early. if we do not need controls and they do not exist, do nothing. - return; - } - - controls = div(); - controls.id = 'frm_field_group_controls'; - controls.setAttribute( 'role', 'group' ); - controls.setAttribute( 'tabindex', 0 ); - setFieldControlsHtml( controls ); - builderPage.appendChild( controls ); - } - - $row.append( controls ); - controls.style.display = shouldShowControls ? 'block' : 'none'; - } - - function setFieldControlsHtml( controls ) { - let layoutOption, moveOption; - - layoutOption = document.createElement( 'span' ); - layoutOption.innerHTML = ''; - const layoutOptionLabel = __( 'Set Row Layout', 'formidable' ); - addTooltip( layoutOption, layoutOptionLabel ); - makeTabbable( layoutOption, layoutOptionLabel ); - - moveOption = document.createElement( 'span' ); - moveOption.innerHTML = ''; - moveOption.classList.add( 'frm-move' ); - const moveOptionLabel = __( 'Move Field Group', 'formidable' ); - addTooltip( moveOption, moveOptionLabel ); - makeTabbable( moveOption, moveOptionLabel ); - - controls.innerHTML = ''; - controls.appendChild( layoutOption ); - controls.appendChild( moveOption ); - controls.appendChild( getFieldControlsDropdown() ); - } - - function addTooltip( element, title ) { - element.setAttribute( 'data-toggle', 'tooltip' ); - element.setAttribute( 'data-container', 'body' ); - element.setAttribute( 'title', title ); - element.addEventListener( - 'mouseover', - function() { - if ( null === element.getAttribute( 'data-original-title' ) ) { - jQuery( element ).tooltip(); - } - } - ); - } - - function getFieldControlsDropdown() { - const dropdown = span({ className: 'dropdown' }); - const trigger = a({ - className: 'frm_bstooltip frm-hover-icon frm-dropdown-toggle dropdown-toggle', - children: [ - span({ - child: svg({ href: '#frm_thick_more_vert_icon' }) - }), - span({ - className: 'screen-reader-text', - text: __( 'Toggle More Options Dropdown', 'formidable' ) - }) - ] - }); - - frmDom.setAttributes( - trigger, - { - 'title': __( 'More Options', 'formidable' ), - 'data-toggle': 'dropdown', - 'data-container': 'body' - } - ); - makeTabbable( trigger, __( 'More Options', 'formidable' ) ); - dropdown.appendChild( trigger ); - - const ul = div({ - className: 'frm-dropdown-menu dropdown-menu dropdown-menu-right' - }); - ul.setAttribute( 'role', 'menu' ); - dropdown.appendChild( ul ); - - return dropdown; - } - - function getSyncLayoutClass( layoutClasses, classToAdd ) { - return function( itemIndex ) { - let currentClassToAdd, length, layoutClassIndex, currentClass, activeLayoutClass, fieldId, layoutClassesInput; - - currentClassToAdd = 'function' === typeof classToAdd ? classToAdd( itemIndex ) : classToAdd; - length = layoutClasses.length; - activeLayoutClass = false; - for ( layoutClassIndex = 0; layoutClassIndex < length; ++layoutClassIndex ) { - currentClass = layoutClasses[ layoutClassIndex ]; - if ( this.classList.contains( currentClass ) ) { - activeLayoutClass = currentClass; - break; - } - } - - fieldId = this.dataset.fid; - - if ( 'undefined' === typeof fieldId ) { - // we are syncing the drag/drop placeholder before the actual field has loaded. - // this will get called again afterward and the input will exist then. - this.classList.add( currentClassToAdd ); - return; - } - - moveFieldSettings( document.getElementById( 'frm-single-settings-' + fieldId ) ); - layoutClassesInput = document.getElementById( 'frm_classes_' + fieldId ); - - if ( null === layoutClassesInput ) { - // not every field type has a layout class input. - return; - } - - if ( false === activeLayoutClass ) { - if ( '' !== currentClassToAdd ) { - layoutClassesInput.value = layoutClassesInput.value.concat( ' ' + currentClassToAdd ); - } - } else { - this.classList.remove( activeLayoutClass ); - layoutClassesInput.value = layoutClassesInput.value.replace( activeLayoutClass, currentClassToAdd ); - } - - if ( this.classList.contains( 'frm_first' ) ) { - this.classList.remove( 'frm_first' ); - layoutClassesInput.value = layoutClassesInput.value.replace( 'frm_first', '' ).trim(); - } - - if ( 0 === itemIndex ) { - this.classList.add( 'frm_first' ); - layoutClassesInput.value = layoutClassesInput.value.concat( ' frm_first' ); - } - - jQuery( layoutClassesInput ).trigger( 'change' ); - }; - } - - function getLayoutClasses() { - return [ 'frm_full', 'frm_half', 'frm_third', 'frm_fourth', 'frm_sixth', 'frm_two_thirds', 'frm_three_fourths', 'frm1', 'frm2', 'frm3', 'frm4', 'frm5', 'frm6', 'frm7', 'frm8', 'frm9', 'frm10', 'frm11', 'frm12' ]; - } - - function setupFieldOptionSorting( sort ) { - const opts = { - items: '.frm_sortable_field_opts li', - axis: 'y', - opacity: 0.65, - forcePlaceholderSize: false, - handle: '.frm-drag', - helper: function( e, li ) { - copyHelper = li.clone().insertAfter( li ); - return li.clone(); - }, - stop: function( e, ui ) { - copyHelper && copyHelper.remove(); - const fieldId = ui.item.attr( 'id' ).replace( 'frm_delete_field_', '' ).replace( '-' + ui.item.data( 'optkey' ) + '_container', '' ); - resetDisplayedOpts( fieldId ); - fieldUpdated(); - } - }; - jQuery( sort ).sortable( opts ); - } - - // Get the section where a field is dropped - function getSectionForFieldPlacement( currentItem ) { - let section = ''; - if ( typeof currentItem !== 'undefined' && ! currentItem.hasClass( 'edit_field_type_divider' ) ) { - section = currentItem.closest( '.edit_field_type_divider' ); - } - return section; - } - - // Get the form ID where a field is dropped - function getFormIdForFieldPlacement( section ) { - let formId = ''; - - if ( typeof section[0] !== 'undefined' ) { - const sDivide = section.children( '.start_divider' ); - sDivide.children( '.edit_field_type_end_divider' ).appendTo( sDivide ); - if ( typeof section.attr( 'data-formid' ) !== 'undefined' ) { - const fieldId = section.attr( 'data-fid' ); - formId = jQuery( 'input[name="field_options[form_select_' + fieldId + ']"]' ).val(); - } - } - - if ( typeof formId === 'undefined' || formId === '' ) { - formId = thisFormId; - } - - return formId; - } - - // Get the section ID where a field is dropped - function getSectionIdForFieldPlacement( section ) { - let sectionId = 0; - if ( typeof section[0] !== 'undefined' ) { - sectionId = section.attr( 'id' ).replace( 'frm_field_id_', '' ); - } - - return sectionId; - } - - /** - * Update a field after it is dragged and dropped into, out of, or between sections - * - * @param {Object} currentItem - * @param {Object} previousSection - * @returns {void} - */ - function updateFieldAfterMovingBetweenSections( currentItem, previousSection ) { - if ( ! currentItem.hasClass( 'form-field' ) ) { - // currentItem is a field group. Call for children recursively. - getFieldsInRow( jQuery( currentItem.get( 0 ).firstChild ) ).each( - function() { - updateFieldAfterMovingBetweenSections( jQuery( this ), previousSection ); - } - ); - return; - } - - const fieldId = currentItem.attr( 'id' ).replace( 'frm_field_id_', '' ); - const section = getSectionForFieldPlacement( currentItem ); - const formId = getFormIdForFieldPlacement( section ); - const sectionId = getSectionIdForFieldPlacement( section ); - const previousFormId = previousSection ? getFormIdForFieldPlacement( jQuery( previousSection.parentNode ) ) : 0; - - jQuery.ajax({ - type: 'POST', - url: ajaxurl, - data: { - action: 'frm_update_field_after_move', - form_id: formId, - field: fieldId, - section_id: sectionId, - previous_form_id: previousFormId, - nonce: frmGlobal.nonce - }, - success: function() { - toggleSectionHolder(); - updateInSectionValue( fieldId, sectionId ); - } - }); - } - - // Update the in_section field value - function updateInSectionValue( fieldId, sectionId ) { - document.getElementById( 'frm_in_section_' + fieldId ).value = sectionId; - } - - /** - * Get the arguments for inserting a new field. - * - * @since 6.23 - * - * @param {string} fieldType - * @param {string} sectionId - * @param {string} formId - * @param {Number} hasBreak - * - * @returns {Object} - */ - function getInsertNewFieldArgs( fieldType, sectionId, formId, hasBreak ) { - return { - action: 'frm_insert_field', - form_id: formId, - field_type: fieldType, - section_id: sectionId, - nonce: frmGlobal.nonce, - has_break: hasBreak, - last_row_field_ids: getFieldIdsInSubmitRow() - }; - } - - /** - * Returns true if it's a range field type and slider type is not selected. - * - * @since 6.23 - * - * @param {string} fieldType - * @returns {boolean} - */ - function shouldStopInsertingField( fieldType ) { - return wp.hooks.applyFilters( 'frm_should_stop_inserting_field', false, fieldType ); - } - - /** - * Add a new field by dragging and dropping it from the Fields sidebar - * - * @param {string} fieldType - */ - function insertNewFieldByDragging( fieldType ) { - if ( shouldStopInsertingField( fieldType ) ) { - wp.hooks.doAction( 'frm_stopped_inserting_by_dragging', fieldType ); - return; - } - - const placeholder = document.getElementById( 'frm_drag_placeholder' ); - const loadingID = fieldType.replace( '|', '-' ) + '_' + getAutoId(); - const loading = tag( - 'li', - { - id: loadingID, - className: 'frm-wait frmbutton_loadingnow' - } - ); - const $placeholder = jQuery( loading ); - const currentItem = jQuery( placeholder ); - const section = getSectionForFieldPlacement( currentItem ); - const formId = getFormIdForFieldPlacement( section ); - const sectionId = getSectionIdForFieldPlacement( section ); - - placeholder.parentNode.insertBefore( loading, placeholder ); - placeholder.remove(); - syncLayoutClasses( $placeholder ); - - let hasBreak = 0; - if ( 'summary' === fieldType ) { - // see if we need to insert a page break before this newly-added summary field. Check for at least 1 page break - hasBreak = jQuery( '.frmbutton_loadingnow#' + loadingID ).prevAll( 'li[data-type="break"]' ).length ? 1 : 0; - } - - jQuery.ajax({ - type: 'POST', - url: ajaxurl, - data: getInsertNewFieldArgs( fieldType, sectionId, formId, hasBreak ), - success: function( msg ) { - handleInsertFieldByDraggingResponse( msg, $placeholder ); - - const fieldId = checkMsgForFieldId( msg ); - if ( fieldId ) { - /** - * Fires after a field is added. - * - * @since 6.23 - * - * @param {Object} fieldData The field data. - * @param {String} fieldData.field The field HTML. - * @param {String} fieldData.field_type The field type. - * @param {String} fieldData.form_id The form ID. - */ - wp.hooks.doAction( 'frm_after_field_added_in_form_builder', { - field: msg, - fieldId, - fieldType, - form_id: formId, - }); - } - }, - error: handleInsertFieldError - }); - } - - /** - * @param {String} msg - * @param {Object} $placeholder jQuery object. - */ - function handleInsertFieldByDraggingResponse( msg, $placeholder ) { - let replaceWith; - document.getElementById( 'frm_form_editor_container' ).classList.add( 'frm-has-fields' ); - const $siblings = $placeholder.siblings( 'li.form-field' ).not( '.edit_field_type_end_divider' ); - - if ( ! $siblings.length ) { - // if dragging into a new row, we need to wrap the li first. - replaceWith = wrapFieldLi( msg ); - } else { - replaceWith = msgAsjQueryObject( msg ); - if ( ! $placeholder.get( 0 ).parentNode.parentNode.classList.contains( 'ui-draggable' ) ) { - // If a field group wasn't draggable because it only had a single field, make it draggable. - makeDraggable( $placeholder.get( 0 ).parentNode.parentNode, '.frm-move' ); - } - } - $placeholder.replaceWith( replaceWith ); - updateFieldOrder(); - afterAddField( msg, false ); - if ( $siblings.length ) { - syncLayoutClasses( $siblings.first() ); - } - toggleSectionHolder(); - - if ( ! $siblings.length ) { - makeDroppable( replaceWith.get( 0 ).querySelector( 'ul.frm_sorting' ) ); - makeDraggable( replaceWith.get( 0 ).querySelector( 'li.form-field' ), '.frm-move' ); - } else { - makeDraggable( replaceWith.get( 0 ), '.frm-move' ); - } - } - - /** - * Get the field ID from the response message. - * - * @since 6.23 - * - * @param {String} msg - * @return {Number} - */ - function checkMsgForFieldId( msg ) { - const result = msg.match( /data-fid="(\d+)"/ ); - return result ? parseInt( result[1] ) : 0; - } - - function getFieldIdsInSubmitRow() { - const submitField = document.querySelector( '.edit_field_type_submit' ); - if ( ! submitField ) { - return []; - } - - const lastRowFields = submitField.parentNode.children; - const ids = []; - for ( let i = 0; i < lastRowFields.length; i++ ) { - ids.push( lastRowFields[ i ].dataset.fid ); - } - - return ids; - } - - function moveFieldThatAlreadyExists( draggable, placeholder ) { - placeholder.parentNode.insertBefore( draggable, placeholder ); - } - - function msgAsjQueryObject( msg ) { - const element = div(); - element.innerHTML = msg; - return jQuery( element.firstChild ); - } - - function handleInsertFieldError( jqXHR, _, errorThrown ) { - maybeShowInsertFieldError( errorThrown, jqXHR ); - } - - function maybeShowInsertFieldError( errorThrown, jqXHR ) { - if ( ! jqXHRAborted( jqXHR ) ) { - infoModal( errorThrown + '. Please try again.' ); - } - } - - function jqXHRAborted( jqXHR ) { - return jqXHR.status === 0 || jqXHR.readyState === 0; - } - - /** - * Get a unique id that automatically increments with every function call. - * Can be used for any UI that requires a unique id. - * Not to be used in data. - * - * @returns {integer} - */ - function getAutoId() { - return ++autoId; - } - - /** - * Determine if a draggable element can be droppable into a droppable element. - * - * Don't allow page break, embed form, or section inside section field - * Don't allow page breaks inside of field groups. - * Don't allow field groups with sections inside of sections. - * Don't allow field groups in field groups. - * Don't allow hidden fields inside of field groups but allow them in sections. - * Don't allow any fields below the submit button field. - * Don't allow submit button field above any fields. - * Don't allow GDPR fields in repeaters. - * - * @param {HTMLElement} draggable - * @param {HTMLElement} droppable - * @param {Event} event - * @returns {Boolean} - */ - function allowDrop( draggable, droppable, event ) { - if ( false === droppable ) { - // Don't show drop placeholder if dragging somewhere off of the droppable area. - return false; - } - - if ( droppable.closest( '.frm-sortable-helper' ) ) { - // Do not allow drop into draggable. - return false; - } - - const isSubmitBtn = draggable.classList.contains( 'edit_field_type_submit' ); - const containSubmitBtn = ! draggable.classList.contains( 'form_field' ) && !! draggable.querySelector( '.edit_field_type_submit' ); - - if ( 'frm-show-fields' === droppable.id ) { - const draggableIndex = determineIndexBasedOffOfMousePositionInList( jQuery( droppable ), event.clientY ); - - if ( isSubmitBtn || containSubmitBtn ) { - // Do not allow dropping submit button to above position. - const lastRowIndex = droppable.childElementCount - 1; - return draggableIndex > lastRowIndex; - } - - // Do not allow dropping other fields to below submit button. - const submitButtonIndex = jQuery( droppable.querySelector( '.edit_field_type_submit' ).closest( '#frm-show-fields > li' ) ).index(); - return draggableIndex <= submitButtonIndex; - } - - if ( isSubmitBtn ) { - if ( droppable.classList.contains( 'start_divider' ) ) { - // Don't allow dropping submit button into a repeater. - return false; - } - - if ( isLastRow( droppable.parentElement ) ) { - // Allow dropping submit button into the last row. - return true; - } - - if ( ! isLastRow( droppable.parentElement.nextElementSibling ) ) { - // Don't a dropping submit button into the row that isn't the second one from bottom. - return false; - } - - // Allow dropping submit button into the second row from bottom if there is only submit button in the last row. - return ! draggable.parentElement.querySelector( 'li.frm_field_box:not(.edit_field_type_submit)' ); - } - - if ( droppable.classList.contains( 'start_divider' ) && ( draggable.classList.contains( 'edit_field_type_gdpr' ) || draggable.id === 'gdpr' ) && droppable.closest( '.repeat_section' ) ) { - // Don't allow GDPR fields in repeaters. - return false; - } - - if ( ! droppable.classList.contains( 'start_divider' ) ) { - const $fieldsInRow = getFieldsInRow( jQuery( droppable ) ); - if ( ! groupCanFitAnotherField( $fieldsInRow, jQuery( draggable ) ) ) { - // Field group is full and cannot accept another field. - return false; - } - - if ( draggable.id === 'divider' && droppable.closest( '.start_divider' ) ) { - return false; - } - } - - const isNewField = draggable.classList.contains( 'frm-new-field' ); - if ( isNewField ) { - return allowNewFieldDrop( draggable, droppable ); - } - - return allowMoveField( draggable, droppable ); - } - - /** - * Checks if given element is the last row in form builder. - * - * @param {HTMLElement} element Element. - * @return {Boolean} - */ - function isLastRow( element ) { - return element && element.matches( '#frm-show-fields > li:last-child' ); - } - - // Don't allow a new page break or hidden field in a field group. - // Don't allow a new field into a field group that includes a page break or hidden field. - // Don't allow a new section inside of a section. - // Don't allow an embedded form in a section. - function allowNewFieldDrop( draggable, droppable ) { - const classes = draggable.classList; - const newPageBreakField = classes.contains( 'frm_tbreak' ); - const newHiddenField = classes.contains( 'frm_thidden' ); - const newSectionField = classes.contains( 'frm_tdivider' ); - const newEmbedField = classes.contains( 'frm_tform' ); - const newUserIdField = classes.contains( 'frm_tuser_id' ); - - const newFieldWillBeAddedToAGroup = ! ( 'frm-show-fields' === droppable.id || droppable.classList.contains( 'start_divider' ) ); - if ( newFieldWillBeAddedToAGroup ) { - if ( groupIncludesBreakOrHiddenOrUserId( droppable ) ) { - // Never allow any field beside a page break or a hidden field. - return false; - } - - return ! newHiddenField && ! newPageBreakField && ! newUserIdField; - } - - const fieldTypeIsAlwaysAllowed = ! newPageBreakField && ! newHiddenField && ! newSectionField && ! newEmbedField; - if ( fieldTypeIsAlwaysAllowed ) { - return true; - } - - const newFieldWillBeAddedToASection = droppable.classList.contains( 'start_divider' ) || null !== droppable.closest( '.start_divider' ); - if ( newFieldWillBeAddedToASection ) { - // Don't allow a section or an embedded form in a section. - return ! newEmbedField && ! newSectionField; - } - - return true; - } - - function allowMoveField( draggable, droppable ) { - if ( isFieldGroup( draggable ) ) { - return allowMoveFieldGroup( draggable, droppable ); - } - - const isPageBreak = draggable.classList.contains( 'edit_field_type_break' ); - if ( isPageBreak ) { - // Page breaks are only allowed in the main list of fields, not in sections or in field groups. - return false; - } - - if ( droppable.classList.contains( 'start_divider' ) ) { - return allowMoveFieldToSection( draggable ); - } - - const isHiddenField = draggable.classList.contains( 'edit_field_type_hidden' ); - const isUserIdField = draggable.classList.contains( 'edit_field_type_user_id' ); - if ( isHiddenField || isUserIdField ) { - // Hidden fields and user id fields should not be added to field groups since they're not shown - // and don't make sense with the grid distribution. - return false; - } - - return allowMoveFieldToGroup( draggable, droppable ); - } - - function isFieldGroup( draggable ) { - return draggable.classList.contains( 'frm_field_box' ) && ! draggable.classList.contains( 'form-field' ); - } - - function allowMoveFieldGroup( fieldGroup, droppable ) { - if ( droppable.classList.contains( 'start_divider' ) && null === fieldGroup.querySelector( '.start_divider' ) ) { - // Allow a field group with no section inside of a section. - return true; - } - return false; - } - - function allowMoveFieldToSection( draggable ) { - const draggableIncludeEmbedForm = draggable.classList.contains( 'edit_field_type_form' ) || draggable.querySelector( '.edit_field_type_form' ); - if ( draggableIncludeEmbedForm ) { - // Do not allow an embedded form inside of a section. - return false; - } - - const draggableIncludesSection = draggable.classList.contains( 'edit_field_type_divider' ) || draggable.querySelector( '.edit_field_type_divider' ); - if ( draggableIncludesSection ) { - // Do not allow a section inside of a section. - return false; - } - - return true; - } - - function allowMoveFieldToGroup( draggable, group ) { - if ( groupIncludesBreakOrHiddenOrUserId( group ) ) { - // Never allow any field beside a page break or a hidden field. - return false; - } - - const isFieldGroup = jQuery( draggable ).children( 'ul.frm_sorting' ).not( '.start_divider' ).length > 0; - if ( isFieldGroup ) { - // Do not allow a field group directly inside of a field group unless it's in a section. - return false; - } - - const draggableIncludesASection = draggable.classList.contains( 'edit_field_type_divider' ) || draggable.querySelector( '.edit_field_type_divider' ); - const draggableIsEmbedField = draggable.classList.contains( 'edit_field_type_form' ); - const groupIsInASection = null !== group.closest( '.start_divider' ); - if ( groupIsInASection && ( draggableIncludesASection || draggableIsEmbedField ) ) { - // Do not allow a section or an embed field inside of a section. - return false; - } - - return true; - } - - function groupIncludesBreakOrHiddenOrUserId( group ) { - return null !== group.querySelector( '.edit_field_type_break, .edit_field_type_hidden, .edit_field_type_user_id' ); - } - - function groupCanFitAnotherField( fieldsInRow, $field ) { - let fieldId; - if ( fieldsInRow.length < 6 ) { - return true; - } - if ( fieldsInRow.length > 6 ) { - return false; - } - fieldId = $field.attr( 'data-fid' ); - // allow 6 if we're not changing field groups. - return 1 === jQuery( fieldsInRow ).filter( '[data-fid="' + fieldId + '"]' ).length; - } - - function loadFields( fieldId ) { - const thisField = document.getElementById( fieldId ); - const $thisField = jQuery( thisField ); - const field = []; - const addHtmlToField = element => { - const frmHiddenFdata = element.querySelector( '.frm_hidden_fdata' ); - element.classList.add( 'frm_load_now' ); - if ( frmHiddenFdata !== null ) { - field.push( frmHiddenFdata.innerHTML ); - } - }; - - let nextElement = thisField; - addHtmlToField( nextElement ); - - let nextField = getNextField( nextElement ); - while ( nextField && field.length < 15 ) { - addHtmlToField( nextField ); - nextElement = nextField; - nextField = getNextField( nextField ); - } - - jQuery.ajax({ - type: 'POST', - url: ajaxurl, - data: { - action: 'frm_load_field', - field: field, - form_id: thisFormId, - nonce: frmGlobal.nonce - }, - success: html => handleAjaxLoadFieldSuccess( html, $thisField, field ) - }); - } - - function getNextField( field ) { - if ( field.nextElementSibling ) { - return field.nextElementSibling; - } - return field.parentNode?.closest( '.frm_field_box' )?.nextElementSibling?.querySelector( '.form-field' ); - } - - function handleAjaxLoadFieldSuccess( html, $thisField, field ) { - let key, $nextSet; - - html = html.replace( /^\s+|\s+$/g, '' ); - if ( html.indexOf( '{' ) !== 0 ) { - jQuery( '.frm_load_now' ).removeClass( '.frm_load_now' ).html( 'Error' ); - return; - } - - html = JSON.parse( html ); - for ( key in html ) { - jQuery( '#frm_field_id_' + key ).replaceWith( html[key]); - setupSortable( '#frm_field_id_' + key + '.edit_field_type_divider ul.frm_sorting' ); - makeDraggable( document.getElementById( 'frm_field_id_' + key ) ); - } - - $nextSet = $thisField.nextAll( '.frm_field_loading:not(.frm_load_now)' ); - if ( $nextSet.length ) { - loadFields( $nextSet.attr( 'id' ) ); - } else { - // go up a level - $nextSet = jQuery( document.getElementById( 'frm-show-fields' ) ).find( '.frm_field_loading:not(.frm_load_now)' ); - if ( $nextSet.length ) { - loadFields( $nextSet.attr( 'id' ) ); - } - } - - initiateMultiselect(); - renumberPageBreaks(); - maybeHideQuantityProductFieldOption(); - - const loadedEvent = new Event( 'frm_ajax_loaded_field', { bubbles: false }); - loadedEvent.frmFields = field.map( f => JSON.parse( f ) ); - document.dispatchEvent( loadedEvent ); - } - - function addFieldClick() { - /*jshint validthis:true */ - const $thisObj = jQuery( this ); - // there is no real way to disable a (with a valid href attribute) in HTML - https://css-tricks.com/how-to-disable-links/ - if ( $thisObj.hasClass( 'disabled' ) ) { - return false; - } - - const $button = $thisObj.closest( '.frmbutton' ); - const fieldType = $button.attr( 'id' ); - - if ( shouldStopInsertingField( fieldType ) ) { - return; - } - - let hasBreak = 0; - if ( 'summary' === fieldType ) { - hasBreak = $newFields.children( 'li[data-type="break"]' ).length > 0 ? 1 : 0; - } - - const formId = thisFormId; - jQuery.ajax({ - type: 'POST', - url: ajaxurl, - data: getInsertNewFieldArgs( fieldType, 0, formId, hasBreak ), - success: function( msg ) { - handleAddFieldClickResponse( msg ); - - const fieldId = checkMsgForFieldId( msg ); - if ( fieldId ) { - /** - * Fires after a field is added. - * - * @since 6.23 - * - * @param {Object} fieldData The field data. - * @param {String} fieldData.field The field HTML. - * @param {String} fieldData.field_type The field type. - * @param {String} fieldData.form_id The form ID. - */ - wp.hooks.doAction( 'frm_after_field_added_in_form_builder', { - field: msg, - fieldId, - fieldType, - form_id: formId, - }); - } - }, - error: handleInsertFieldError - }); - return false; - } - - function handleAddFieldClickResponse( msg ) { - document.getElementById( 'frm_form_editor_container' ).classList.add( 'frm-has-fields' ); - const replaceWith = wrapFieldLi( msg ); - const submitField = $newFields[0].querySelector( '.edit_field_type_submit' ); - - if ( ! submitField ) { - $newFields.append( replaceWith ); - } else { - jQuery( submitField.closest( '.frm_field_box:not(.form-field)' ) ).before( replaceWith ); - } - - afterAddField( msg, true ); - - replaceWith.each( - function() { - makeDroppable( this.querySelector( 'ul.frm_sorting' ) ); - makeDraggable( this.querySelector( '.form-field' ), '.frm-move' ); - } - ); - } - - function insertFormField( fieldType, fieldOptions = {} ) { - - return new Promise( ( resolve ) => { - const formId = thisFormId; - let hasBreak = 0; - - if ( 'summary' === fieldType ) { - hasBreak = $newFields.children( 'li[data-type="break"]' ).length > 0 ? 1 : 0; - } - - jQuery.ajax({ - type: 'POST', - url: ajaxurl, - data: Object.assign( getInsertNewFieldArgs( fieldType, 0, formId, hasBreak ), { field_options: fieldOptions } ), - success: function( msg ) { - resolve( msg ); - - setTimeout( () => { - updateFieldOrder(); - afterAddField( msg, true ); - - const fieldId = checkMsgForFieldId( msg ); - if ( fieldId ) { - /** - * Fires after a field is added. - * - * @since 6.23 - * - * @param {Object} fieldData The field data. - * @param {String} fieldData.field The field HTML. - * @param {String} fieldData.field_type The field type. - * @param {String} fieldData.form_id The form ID. - */ - wp.hooks.doAction( 'frm_after_field_added_in_form_builder', { - field: msg, - fieldId, - fieldType, - form_id: formId, - }); - } - }, 10 ); - }, - error: handleInsertFieldError - }); - } ); - } - - function maybeHideQuantityProductFieldOption() { - let hide = true, - opts = document.querySelectorAll( '.frmjs_prod_field_opt_cont' ); - - if ( $newFields.find( 'li.edit_field_type_product' ).length > 1 ) { - hide = false; - } - - for ( let i = 0; i < opts.length; i++ ) { - if ( hide ) { - opts[ i ].classList.add( 'frm_hidden' ); - } else { - opts[ i ].classList.remove( 'frm_hidden' ); - } - } - } - - /** - * Returns true if a field can be duplicated. - * - * @since 6.19 - * - * @param {HTMLElement} field - * @param {number} maxFieldsInGroup - * - * @returns {Boolean} - */ - function canDuplicateField( field, maxFieldsInGroup ) { - if ( field.classList.contains( 'frm-page-collapsed' ) ) { - return false; - } - const fieldGroup = field.closest( 'li.frm_field_box:not(.form-field)' ); - if ( ! fieldGroup ) { - return true; - } - const fieldsInGroup = getFieldsInRow( jQuery( fieldGroup.querySelector( 'ul' ) ) ).length; - return fieldsInGroup < maxFieldsInGroup; - } - - function duplicateField() { - let $field, fieldId, children, newRowId, fieldOrder; - const maxFieldsInGroup = 6; - - $field = jQuery( this ).closest( 'li.form-field' ); - newRowId = this.getAttribute( 'frm-target-row-id' ); - - if ( ! ( newRowId && newRowId.startsWith( 'frm_field_group_' ) ) && ! canDuplicateField( $field.get( 0 ), maxFieldsInGroup ) ) { - /* translators: %1$d: Maximum number of fields allowed in a field group. */ - infoModal( sprintf( __( 'You can only have a maximum of %1$d fields in a field group. Delete or move out a field from the group and try again.', 'formidable' ), maxFieldsInGroup ) ); - return; - } - - closeOpenFieldDropdowns(); - fieldId = $field.data( 'fid' ); - children = fieldsInSection( fieldId ); - - if ( null !== newRowId ) { - fieldOrder = this.getAttribute( 'frm-field-order' ); - } - - jQuery.ajax({ - type: 'POST', - url: ajaxurl, - data: { - action: 'frm_duplicate_field', - field_id: fieldId, - form_id: thisFormId, - children: children, - nonce: frmGlobal.nonce - }, - success: function( msg ) { - let newRow; - - let replaceWith; - - if ( null !== newRowId ) { - newRow = document.getElementById( newRowId ); - if ( null !== newRow ) { - replaceWith = msgAsjQueryObject( msg ); - jQuery( newRow ).append( replaceWith ); - makeDraggable( replaceWith.get( 0 ), '.frm-move' ); - if ( null !== fieldOrder ) { - newRow.lastElementChild.setAttribute( 'frm-field-order', fieldOrder ); - } - jQuery( newRow ).trigger( - 'frm_added_duplicated_field_to_row', - { - duplicatedFieldHtml: msg, - originalFieldId: fieldId - } - ); - afterAddField( msg, false ); - setLayoutClassesForDuplicatedFieldInGroup( $field.get( 0 ), replaceWith.get( 0 ) ); - return; - } - } - - if ( $field.siblings( 'li.form-field' ).length ) { - replaceWith = msgAsjQueryObject( msg ); - $field.after( replaceWith ); - syncLayoutClasses( $field ); - makeDraggable( replaceWith.get( 0 ), '.frm-move' ); - } else { - replaceWith = wrapFieldLi( msg ); - $field.parent().parent().after( replaceWith ); - makeDroppable( replaceWith.get( 0 ).querySelector( 'ul.frm_sorting' ) ); - makeDraggable( replaceWith.get( 0 ).querySelector( 'li.form-field' ), '.frm-move' ); - } - - updateFieldOrder(); - afterAddField( msg, false ); - maybeDuplicateUnsavedSettings( fieldId, msg ); - toggleOneSectionHolder( replaceWith.find( '.start_divider' ) ); - $field[0].querySelector( '.frm-dropdown-menu.dropdown-menu-right' )?.classList.remove( 'show' ); - setLayoutClassesForDuplicatedFieldInGroup( $field.get( 0 ), replaceWith.get( 0 ) ); - } - }); - return false; - } - - /** - * Sets the layout classes for a duplicated field in a field group from the layout classes of the original field. - * - * @param {HTMLElement} field The original field. - * @param {HTMLElement} newField The duplicated field. - * - * @returns {void} - */ - function setLayoutClassesForDuplicatedFieldInGroup( field, newField ) { - const hoverTarget = field.closest( '.frm-field-group-hover-target' ); - if ( ! hoverTarget || ! isFieldGroup( hoverTarget.parentElement ) ) { - return; - } - const fieldId = field.dataset.fid; - let fieldClasses = document.getElementById( 'frm_classes_' + fieldId )?.value; - if ( ! fieldClasses ) { - return; - } - fieldClasses = fieldClasses.replace( 'frm_first', '' ); - if ( ! newField.className.includes( fieldClasses ) ) { - newField.className += ' ' + fieldClasses; - - const classesInput = document.getElementById( 'frm_classes_' + newField.dataset.fid ); - if ( classesInput ) { - classesInput.value = fieldClasses; - } - } - } - - function maybeDuplicateUnsavedSettings( originalFieldId, newFieldHtml ) { - let originalSettings, newFieldId, copySettings, fieldOptionKeys, originalDefault, copyDefault; - - originalSettings = document.getElementById( 'frm-single-settings-' + originalFieldId ); - if ( null === originalSettings ) { - return; - } - - newFieldId = jQuery( newFieldHtml ).attr( 'data-fid' ); - if ( 'undefined' === typeof newFieldId ) { - return; - } - - copySettings = document.getElementById( 'frm-single-settings-' + newFieldId ); - if ( null === copySettings ) { - return; - } - - fieldOptionKeys = [ - 'name', 'required', 'unique', 'read_only', 'placeholder', 'description', 'size', 'max', 'format', 'prepend', 'append', 'separate_value' - ]; - - originalSettings.querySelectorAll( 'input[name^="field_options["], textarea[name^="field_options["]' ).forEach( - function( originalSetting ) { - let key, tagType, copySetting; - - key = getKeyFromSettingInput( originalSetting ); - - if ( 'options' === key ) { - copyOption( originalSetting, copySettings, originalFieldId, newFieldId ); - return; - } - - if ( -1 === fieldOptionKeys.indexOf( key ) ) { - return; - } - - tagType = originalSetting.matches( 'input' ) ? 'input' : 'textarea'; - copySetting = copySettings.querySelector( tagType + '[name="field_options[' + key + '_' + newFieldId + ']"]' ); - if ( null === copySetting ) { - return; - } - - if ( 'checkbox' === originalSetting.type ) { - if ( originalSetting.checked !== copySetting.checked ) { - jQuery( copySetting ).trigger( 'click' ); - } - } else if ( 'text' === originalSetting.type || 'textarea' === tagType ) { - if ( originalSetting.value !== copySetting.value ) { - copySetting.value = originalSetting.value; - jQuery( copySetting ).trigger( 'change' ); - } - } - } - ); - - originalDefault = originalSettings.querySelector( 'input[name="default_value_' + originalFieldId + '"]' ); - if ( null !== originalDefault ) { - copyDefault = copySettings.querySelector( 'input[name="default_value_' + newFieldId + '"]' ); - if ( null !== copyDefault && originalDefault.value !== copyDefault.value ) { - copyDefault.value = originalDefault.value; - jQuery( copyDefault ).trigger( 'change' ); - } - } - } - - function copyOption( originalSetting, copySettings, originalFieldId, newFieldId ) { - let remainingKeyDetails, copyKey, copySetting; - remainingKeyDetails = originalSetting.name.substr( 23 + ( '' + originalFieldId ).length ); - copyKey = 'field_options[options_' + newFieldId + ']' + remainingKeyDetails; - copySetting = copySettings.querySelector( 'input[name="' + copyKey + '"]' ); - if ( null !== copySetting && copySetting.value !== originalSetting.value ) { - copySetting.value = originalSetting.value; - jQuery( copySetting ).trigger( 'change' ); - } - } - - function getKeyFromSettingInput( input ) { - let nameWithoutPrefix, nameSplit; - nameWithoutPrefix = input.name.substr( 14 ); - nameSplit = nameWithoutPrefix.split( '_' ); - nameSplit.pop(); - return nameSplit.join( '_' ); - } - - function closeOpenFieldDropdowns() { - const openSettings = document.querySelector( '.frm-field-settings-open' ); - if ( null !== openSettings ) { - openSettings.classList.remove( 'frm-field-settings-open' ); - jQuery( document ).off( 'click', '#frm_builder_page', handleClickOutsideOfFieldSettings ); - jQuery( '.frm-field-action-icons .dropdown.open' ).removeClass( 'open' ); - } - } - - function handleClickOutsideOfFieldSettings( event ) { - if ( ! jQuery( event.originalEvent.target ).closest( '.frm-field-action-icons' ).length ) { - closeOpenFieldDropdowns(); - } - } - - function checkForMultiselectKeysOnMouseMove( event ) { - const keyIsDown = ! ! ( event.ctrlKey || event.metaKey || event.shiftKey ); - jQuery( builderPage ).toggleClass( 'frm-multiselect-key-is-down', keyIsDown ); - checkForActiveHoverTarget( event ); - } - - function checkForActiveHoverTarget( event ) { - let container, elementFromPoint, list, previousHoverTarget; - - container = postBodyContent; - if ( container.classList.contains( 'frm-dragging-field' ) ) { - return; - } - - if ( null !== document.querySelector( '.frm-field-group-hover-target .frm-field-settings-open' ) ) { - // do not set a hover target if a dropdown is open for the current hover target. - return; - } - - elementFromPoint = document.elementFromPoint( event.clientX, event.clientY ); - if ( null !== elementFromPoint && ! elementFromPoint.classList.contains( 'edit_field_type_divider' ) ) { - - list = elementFromPoint.closest( 'ul.frm_sorting' ); - - if ( null !== list && ! list.classList.contains( 'start_divider' ) && 'frm-show-fields' !== list.id ) { - previousHoverTarget = maybeRemoveGroupHoverTarget(); - if ( false !== previousHoverTarget && ! jQuery( previousHoverTarget ).is( list ) ) { - destroyFieldGroupPopup(); - } - updateFieldGroupControls( jQuery( list ), getFieldsInRow( jQuery( list ) ).length ); - list.classList.add( 'frm-field-group-hover-target' ); - jQuery( '#wpbody-content' ).on( 'mousemove', maybeRemoveHoverTargetOnMouseMove ); - } - } - } - - function maybeRemoveGroupHoverTarget() { - let controls, previousHoverTarget; - - controls = document.getElementById( 'frm_field_group_controls' ); - if ( null !== controls ) { - controls.style.display = 'none'; - } - - previousHoverTarget = document.querySelector( '.frm-field-group-hover-target' ); - if ( null === previousHoverTarget ) { - return false; - } - - jQuery( '#wpbody-content' ).off( 'mousemove', maybeRemoveHoverTargetOnMouseMove ); - previousHoverTarget.classList.remove( 'frm-field-group-hover-target' ); - return previousHoverTarget; - } - - function maybeRemoveHoverTargetOnMouseMove( event ) { - const elementFromPoint = document.elementFromPoint( event.clientX, event.clientY ); - if ( null !== elementFromPoint && null !== elementFromPoint.closest( '#frm-show-fields' ) ) { - return; - } - maybeRemoveGroupHoverTarget(); - } - - function onFieldActionDropdownShow( isFieldGroup ) { - unselectFieldGroups(); - // maybe offset the dropdown if it goes off of the right of the screen. - setTimeout( - function() { - let ul, $ul; - ul = document.querySelector( '.dropdown.show .frm-dropdown-menu' ); - if ( null === ul ) { - return; - } - if ( null === ul.getAttribute( 'aria-label' ) ) { - ul.setAttribute( 'aria-label', __( 'More Options', 'formidable' ) ); - } - if ( 0 === ul.children.length ) { - fillFieldActionDropdown( ul, true === isFieldGroup ); - } - $ul = jQuery( ul ); - if ( $ul.offset().left > jQuery( window ).width() - $ul.outerWidth() ) { - ul.style.left = ( -$ul.outerWidth() ) + 'px'; - } - const firstAnchor = ul.firstElementChild.querySelector( 'a' ); - if ( firstAnchor ) { - firstAnchor.focus(); - } - }, - 0 - ); - } - - function onFieldGroupActionDropdownShow() { - onFieldActionDropdownShow( true ); - } - - function changeSectionStyle( e ) { - const collapsedSection = e.target.closest( '.frm-section-collapsed' ); - if ( ! collapsedSection ) { - return; - } - - if ( e.type === 'show' ) { - collapsedSection.style.zIndex = 3; - } else { - collapsedSection.style.zIndex = 1; - } - } - - function fillFieldActionDropdown( ul, isFieldGroup ) { - let classSuffix, options; - classSuffix = isFieldGroup ? '_field_group' : '_field'; - options = [ getDeleteActionOption( isFieldGroup ), getDuplicateActionOption( isFieldGroup ) ]; - if ( ! isFieldGroup ) { - options.push( - { class: 'frm_select', icon: 'frm_settings_icon', label: __( 'Field Settings', 'formidable' ) } - ); - } - options.forEach( - function( option ) { - let li, anchor, span; - li = document.createElement( 'div' ); - li.classList.add( 'frm_more_options_li', 'dropdown-item' ); - - anchor = document.createElement( 'a' ); - anchor.classList.add( option.class + classSuffix ); - anchor.setAttribute( 'href', '#' ); - makeTabbable( anchor ); - - span = document.createElement( 'span' ); - span.textContent = option.label; - anchor.innerHTML = ''; - anchor.appendChild( document.createTextNode( ' ' ) ); - anchor.appendChild( span ); - - li.appendChild( anchor ); - ul.appendChild( li ); - } - ); - } - - function getDeleteActionOption( isFieldGroup ) { - const option = { class: 'frm_delete', icon: 'frm_delete_icon' }; - option.label = isFieldGroup ? __( 'Delete Group', 'formidable' ) : __( 'Delete', 'formidable' ); - return option; - } - - function getDuplicateActionOption( isFieldGroup ) { - const option = { class: 'frm_clone', icon: 'frm_clone_icon' }; - option.label = isFieldGroup ? __( 'Duplicate Group', 'formidable' ) : __( 'Duplicate', 'formidable' ); - return option; - } - - function wrapFieldLi( field ) { - const wrapper = div(); - - if ( 'string' === typeof field ) { - wrapper.innerHTML = field; - } else { - wrapper.appendChild( field ); - } - - let result = jQuery(); - Array.from( wrapper.children ).forEach( - li => { - result = result.add( - jQuery( '
  • ' ) - .addClass( 'frm_field_box' ) - .html( - jQuery( '
      ' ).addClass( 'frm_grid_container frm_sorting' ).append( li ) - ) - ); - } - ); - - return result; - } - - function wrapFieldLiInPlace( li ) { - const ul = tag( - 'ul', - { - className: 'frm_grid_container frm_sorting' - } - ); - const wrapper = tag( - 'li', - { - className: 'frm_field_box', - child: ul - } - ); - - li.replaceWith( wrapper ); - ul.appendChild( li ); - - makeDroppable( ul ); - makeDraggable( wrapper, '.frm-move' ); - } - - function afterAddField( msg, addFocus ) { - const regex = /id="(\S+)"/; - const match = regex.exec( msg ); - const field = document.getElementById( match[1]); - const section = '#' + match[1] + '.edit_field_type_divider ul.frm_sorting.start_divider'; - const $thisSection = jQuery( section ); - const type = field.getAttribute( 'data-type' ); - - checkHtmlForNewFields( msg ); - - let toggled = false; - - fieldUpdated(); - setupSortable( section ); - - if ( 'quantity' === type ) { - // try to automatically attach a product field - maybeSetProductField( field ); - } - - if ( 'product' === type || 'quantity' === type ) { - // quantity too needs to be a part of the if stmt especially cos of the very - // 1st quantity field (or even if it's just one quantity field in the form). - maybeHideQuantityProductFieldOption(); - } - - if ( $thisSection.length ) { - $thisSection.parent( '.frm_field_box' ).children( '.frm_no_section_fields' ).addClass( 'frm_block' ); - } else { - const $parentSection = jQuery( field ).closest( 'ul.frm_sorting.start_divider' ); - if ( $parentSection.length ) { - toggleOneSectionHolder( $parentSection ); - toggled = true; - } - } - - if ( msg.indexOf( 'frm-collapse-page' ) !== -1 ) { - renumberPageBreaks(); - } - - addClass( field, 'frm-newly-added' ); - setTimeout( function() { - field.classList.remove( 'frm-newly-added' ); - }, 1000 ); - - if ( addFocus ) { - const bounding = field.getBoundingClientRect(), - container = document.getElementById( 'post-body-content' ), - inView = ( bounding.top >= 0 && - bounding.left >= 0 && - bounding.right <= ( window.innerWidth || document.documentElement.clientWidth ) && - bounding.bottom <= ( window.innerHeight || document.documentElement.clientHeight ) - ); - - if ( ! inView ) { - container.scroll({ - top: container.scrollHeight, - left: 0, - behavior: 'smooth' - }); - } - - if ( toggled === false ) { - toggleOneSectionHolder( $thisSection ); - } - } - - deselectFields(); - initiateMultiselect(); - - document.getElementById( 'frm-show-fields' ).classList.remove( 'frm-over-droppable' ); - - const addedEvent = new Event( 'frm_added_field', { bubbles: false }); - addedEvent.frmField = field; - addedEvent.frmSection = section; - addedEvent.frmType = type; - addedEvent.frmToggles = toggled; - document.dispatchEvent( addedEvent ); - } - - /** - * Since multiple new fields may get added when a new field is inserted, check the HTML. - * - * @param {string} html - * @returns {void} - */ - function checkHtmlForNewFields( html ) { - const element = div(); - element.innerHTML = html; - element.querySelectorAll( '.form-field' ).forEach( addFieldIdToDraftFieldsInput ); - } - - /** - * @param {HTMLElement} field - * @returns {void} - */ - function addFieldIdToDraftFieldsInput( field ) { - if ( ! field.dataset.fid ) { - return; - } - - const draftInput = document.getElementById( 'draft_fields' ); - if ( ! draftInput ) { - return; - } - - if ( '' === draftInput.value ) { - draftInput.value = field.dataset.fid; - } else { - const split = draftInput.value.split( ',' ); - if ( ! split.includes( field.dataset.fid ) ) { - draftInput.value += ',' + field.dataset.fid; - } - } - } - - function clearSettingsBox( preventFieldGroups ) { - jQuery( '#new_fields .frm-single-settings' ).addClass( 'frm_hidden' ); - jQuery( '#frm-options-panel > .frm-single-settings' ).removeClass( 'frm_hidden' ); - deselectFields( preventFieldGroups ); - } - - function deselectFields( preventFieldGroups ) { - jQuery( 'li.ui-state-default.selected' ).removeClass( 'selected' ); - jQuery( '.frm-show-field-settings.selected' ).removeClass( 'selected' ); - if ( ! preventFieldGroups ) { - unselectFieldGroups(); - } - } - - function scrollToField( field ) { - const newPos = field.getBoundingClientRect().top, - container = document.getElementById( 'post-body-content' ); - - if ( typeof animate === 'undefined' ) { - jQuery( container ).scrollTop( newPos ); - } else { - // TODO: smooth scroll - jQuery( container ).animate({ scrollTop: newPos }, 500 ); - } - } - - function checkCalculationCreatedByUser() { - const calculation = this.value; - let warningMessage = checkMatchingParens( calculation ); - warningMessage += checkShortcodes( calculation, this ); - - if ( warningMessage !== '' ) { - infoModal( calculation + '\n\n' + warningMessage ); - } - } - - /** - * Checks a string for parens, brackets, and curly braces and returns a message if any unmatched are found. - * @param formula - * @returns {string} - */ - function checkMatchingParens( formula ) { - - let stack = [], - formulaArray = formula.split( '' ), - length = formulaArray.length, - opening = [ '{', '[', '(' ], - closing = { - '}': '{', - ')': '(', - ']': '[' - }, - unmatchedClosing = [], - msg = '', - i, top; - - for ( i = 0; i < length; i++ ) { - if ( opening.includes( formulaArray[i]) ) { - stack.push( formulaArray[i]); - continue; - } - if ( closing.hasOwnProperty( formulaArray[i]) ) { - top = stack.pop(); - if ( top !== closing[formulaArray[i]]) { - unmatchedClosing.push( formulaArray[i]); - } - } - } - - if ( stack.length > 0 || unmatchedClosing.length > 0 ) { - msg = frmAdminJs.unmatched_parens + '\n\n'; - return msg; - } - - return ''; - } - - /** - * Checks a calculation for shortcodes that shouldn't be in it and returns a message if found. - * @param calculation - * @param inputElement - * @returns {string} - */ - function checkShortcodes( calculation, inputElement ) { - let msg = checkNonNumericShortcodes( calculation, inputElement ); - msg += checkNonFormShortcodes( calculation ); - - return msg; - } - - /** - * Checks if a numeric calculation has shortcodes that output non-numeric strings and returns a message if found. - * @param calculation - * - * @param inputElement - * @returns {string} - */ - function checkNonNumericShortcodes( calculation, inputElement ) { - - let msg = ''; - - if ( isTextCalculation( inputElement ) ) { - return msg; - } - - const nonNumericShortcodes = getNonNumericShortcodes(); - - if ( nonNumericShortcodes.test( calculation ) ) { - msg = frmAdminJs.text_shortcodes + '\n\n'; - } - - return msg; - } - - /** - * Determines if the calculation input is from a text calculation. - * - * @param inputElement - */ - function isTextCalculation( inputElement ) { - return jQuery( inputElement ).siblings( 'label[for^="calc_type"]' ).children( 'input' ).prop( 'checked' ); - } - - /** - * Returns a regular expression of shortcodes that can't be used in numeric calculations. - * @returns {RegExp} - */ - function getNonNumericShortcodes() { - return /\[(date|time|email|ip)\]/; - } - - /** - * Checks if a string has any shortcodes that do not belong in forms and returns a message if any are found. - * @param formula - * @returns {string} - */ - function checkNonFormShortcodes( formula ) { - let nonFormShortcodes = getNonFormShortcodes(), - msg = ''; - - if ( nonFormShortcodes.test( formula ) ) { - msg += frmAdminJs.view_shortcodes + '\n\n'; - } - - return msg; - } - - /** - * Returns a regular expression of shortcodes that can't be used in forms but can be used in Views, Email - * Notifications, and other Formidable areas. - * - * @returns {RegExp} - */ - function getNonFormShortcodes() { - return /\[id\]|\[key\]|\[if\s\w+\]|\[foreach\s\w+\]|\[created-at(\s*)?/g; - } - - function isCalcBoxType( box, listClass ) { - const list = jQuery( box ).find( '.frm_code_list' ); - return 1 === list.length && list.hasClass( listClass ); - } - - function extractExcludedOptions( exclude ) { - const opts = []; - if ( ! Array.isArray( exclude ) ) { - return opts; - } - - for ( let i = 0; i < exclude.length; i++ ) { - if ( exclude[ i ].startsWith( '[' ) ) { - opts.push( exclude[ i ]); - // remove it - exclude.splice( i, 1 ); - // https://love2dev.com/blog/javascript-remove-from-array/#remove-from-array-splice-value - i--; - } - } - - return opts; - } - - function hasExcludedOption( field, excludedOpts ) { - let hasOption = false; - for ( let i = 0; i < excludedOpts.length; i++ ) { - const inputs = document.getElementsByName( getFieldOptionInputName( excludedOpts[ i ], field.fieldId ) ); - // 2nd condition checks that there's at least one non-empty value - if ( inputs.length && jQuery( inputs[0]).val() ) { - hasOption = true; - break; - } - } - return hasOption; - } - - function getFieldOptionInputName( opt, fieldId ) { - const at = opt.indexOf( ']' ); - return 'field_options' + opt.substring( 0, at ) + '_' + fieldId + opt.substring( at ); - } - - function popCalcFields( v, force ) { - let box, exclude, fields, i, list, - p = jQuery( v ).closest( '.frm-single-settings' ), - calc = p.find( '.frm-calc-field' ); - - if ( ! force && ( ! calc.length || calc.val() === '' || calc.is( ':hidden' ) ) ) { - return; - } - - const isSummary = isCalcBoxType( v, 'frm_js_summary_list' ); - - const fieldId = p.find( 'input[name="frm_fields_submitted[]"]' ).val(); - - if ( force ) { - box = v; - } else { - box = document.getElementById( 'frm-calc-box-' + fieldId ); - } - - exclude = getExcludeArray( box, isSummary ); - const excludedOpts = extractExcludedOptions( exclude ); - - fields = getFieldList(); - list = document.getElementById( 'frm-calc-list-' + fieldId ); - list.innerHTML = ''; - - for ( i = 0; i < fields.length; i++ ) { - if ( ( exclude && exclude.includes( fields[ i ].fieldType ) ) || - ( excludedOpts.length && hasExcludedOption( fields[ i ], excludedOpts ) ) ) { - continue; - } - - const span = document.createElement( 'span' ); - span.appendChild( document.createTextNode( '[' + fields[i].fieldId + ']' ) ); - - const a = document.createElement( 'a' ); - a.setAttribute( 'href', '#' ); - a.setAttribute( 'data-code', fields[i].fieldId ); - a.classList.add( 'frm_insert_code' ); - a.appendChild( span ); - a.appendChild( document.createTextNode( fields[i].fieldName ) ); - - const li = document.createElement( 'li' ); - li.classList.add( 'frm-field-list-' + fieldId ); - li.classList.add( 'frm-field-list-' + fields[i].fieldType ); - li.appendChild( a ); - list.appendChild( li ); - } - } - - function getExcludeArray( calcBox, isSummary ) { - const exclude = JSON.parse( calcBox.getElementsByClassName( 'frm_code_list' )[0].getAttribute( 'data-exclude' ) ); - - if ( isSummary ) { - // includedExtras are those that are normally excluded from the summary but the form owner can choose to include, - // when they have been chosen to be included, then they can now be manually excluded in the calc box. - const includedExtras = getIncludedExtras(); - if ( includedExtras.length ) { - for ( let i = 0; i < exclude.length; i++ ) { - if ( includedExtras.includes( exclude[ i ]) ) { - // remove it - exclude.splice( i, 1 ); - // https://love2dev.com/blog/javascript-remove-from-array/#remove-from-array-splice-value - i--; - } - } - } - } - - return exclude; - } - - function getIncludedExtras() { - const checked = []; - const checkboxes = document.getElementsByClassName( 'frm_include_extras_field' ); - - for ( let i = 0; i < checkboxes.length; i++ ) { - if ( checkboxes[i].checked ) { - checked.push( checkboxes[i].value ); - } - } - - return checked; - } - - function rePopCalcFieldsForSummary() { - popCalcFields( jQuery( '.frm-inline-modal.postbox:has(.frm_js_summary_list)' )[0], true ); - } - - function getFieldList( fieldType ) { - let i, - fields = [], - allFields = document.querySelectorAll( 'li.frm_field_box' ), - checkType = 'undefined' !== typeof fieldType; - - for ( i = 0; i < allFields.length; i++ ) { - // data-ftype is better (than data-type) cos of fields loaded by AJAX - which might not be ready yet - if ( checkType && allFields[ i ].getAttribute( 'data-ftype' ) !== fieldType ) { - continue; - } - - const fieldId = allFields[ i ].getAttribute( 'data-fid' ); - if ( typeof fieldId !== 'undefined' && fieldId ) { - fields.push({ - 'fieldId': fieldId, - 'fieldName': getPossibleValue( 'frm_name_' + fieldId ), - 'fieldType': getPossibleValue( 'field_options_type_' + fieldId ), - 'fieldKey': getPossibleValue( 'field_options_field_key_' + fieldId ) - }); - } - } - - return wp.hooks.applyFilters( 'frm_admin_get_field_list', fields, fieldType, allFields ); - } - - function popProductFields( field ) { - let i, checked, id, - options = [], - current = getCurrentProductFields( field ), - fName = field.getAttribute( 'data-frmfname' ), - products = getFieldList( 'product' ), - quantities = getFieldList( 'quantity' ), - isSelect = field.tagName === 'SELECT', // for reverse compatibility. - // whether we have just 1 product and 1 quantity field & should therefore attach the latter to the former - auto = 1 === quantities.length && 1 === products.length; - - if ( isSelect ) { - // This fallback can be removed after 4.05. - current = field.getAttribute( 'data-frmcurrent' ); - } - - for ( i = 0 ; i < products.length ; i++ ) { - // let's be double sure it's string, else indexOf will fail - id = products[ i ].fieldId.toString(); - checked = auto || -1 !== current.indexOf( id ); - if ( isSelect ) { - // This fallback can be removed after 4.05. - checked = checked ? ' selected' : ''; - options.push( '' ); - } else { - checked = checked ? ' checked' : ''; - options.push( '' ); - } - } - - field.innerHTML = options.join( '' ); - } - - function getCurrentProductFields( prodFieldOpt ) { - const products = prodFieldOpt.querySelectorAll( '[type="checkbox"]:checked' ), - idsArray = []; - - for ( let i = 0; i < products.length; i++ ) { - idsArray.push( products[ i ].value ); - } - - return idsArray; - } - - function popAllProductFields() { - const opts = document.querySelectorAll( '.frmjs_prod_field_opt' ); - for ( let i = 0; i < opts.length; i++ ) { - popProductFields( opts[ i ]); - } - } - - function maybeSetProductField( field ) { - const fieldId = field.getAttribute( 'data-fid' ), - productFieldOpt = document.getElementById( 'field_options[product_field_' + fieldId + ']' ); - - if ( null === productFieldOpt ) { - return; - } - - popProductFields( productFieldOpt ); - // in order to move its settings to that LHS panel where - // the update form resides, else it'll lose this setting - moveFieldSettings( document.getElementById( 'frm-single-settings-' + fieldId ) ); - } - - /** - * If the element doesn't exist, use a blank value. - */ - function getPossibleValue( id ) { - const field = document.getElementById( id ); - if ( field !== null ) { - return field.value; - } - return ''; - } - - function liveChanges() { - /*jshint validthis:true */ - let option, - newValue = this.value, - changes = document.getElementById( this.getAttribute( 'data-changeme' ) ), - att = this.getAttribute( 'data-changeatt' ); - - if ( changes === null ) { - return; - } - - if ( att !== null ) { - if ( changes.tagName === 'SELECT' && att === 'placeholder' ) { - option = changes.options[0]; - if ( option.value === '' ) { - option.innerHTML = newValue; - } else { - // Create a placeholder option if there are no blank values. - addBlankSelectOption( changes, newValue ); - } - } else if ( att === 'class' ) { - changeFieldClass( changes, this ); - } else if ( isSliderField( changes ) ) { - updateSliderFieldPreview( changes, att, newValue ); - } else { - changes.setAttribute( att, newValue ); - } - } else if ( changes.id.indexOf( 'setup-message' ) === 0 ) { - if ( newValue !== '' ) { - changes.innerHTML = ''; - } - } else { - changes.innerHTML = purifyHtml( newValue ); - if ( 'TEXTAREA' === changes.nodeName && changes.classList.contains( 'wp-editor-area' ) ) { - // Trigger change events on wysiwyg textareas so we can also sync default values in the visual tab. - jQuery( changes ).trigger( 'change' ); - } - - if ( changes.classList.contains( 'frm_primary_label' ) && 'break' === changes.nextElementSibling.getAttribute( 'data-ftype' ) ) { - changes.nextElementSibling.querySelector( '.frm_button_submit' ).textContent = newValue; - } - } - } - - function updateSliderFieldPreview( field, att, newValue ) { - if ( frmGlobal.proIncludesSliderJs ) { - const hookName = 'frm_update_slider_field_preview'; - const hookArgs = { field, att, newValue }; - wp.hooks.doAction( hookName, hookArgs ); - return; - } - - // This functionality has been moved to pro since v5.4.3. This code should be removed eventually. - if ( 'value' === att ) { - if ( '' === newValue ) { - newValue = getSliderMidpoint( field ); - } - field.value = newValue; - } else { - field.setAttribute( att, newValue ); - } - - if ( -1 === [ 'value', 'min', 'max' ].indexOf( att ) ) { - return; - } - - if ( ( 'max' === att || 'min' === att ) && '' === getSliderDefaultValueInput( field.id ) ) { - field.value = getSliderMidpoint( field ); - } - - field.parentNode.querySelector( '.frm_range_value' ).textContent = field.value; - } - - function getSliderDefaultValueInput( previewInputId ) { - return document.querySelector( 'input[data-changeme="' + previewInputId + '"][data-changeatt="value"]' ).value; - } - - function getSliderMidpoint( sliderInput ) { - const max = parseFloat( sliderInput.getAttribute( 'max' ) ); - const min = parseFloat( sliderInput.getAttribute( 'min' ) ); - return ( max - min ) / 2 + min; - } - - function isSliderField( previewInput ) { - return 'range' === previewInput.type && previewInput.parentNode.classList.contains( 'frm_range_container' ); - } - - function toggleInvalidMsg() { - /*jshint validthis:true */ - let typeDropdown, fieldType, - fieldId = this.getAttribute( 'data-fid' ), - value = ''; - - [ 'field_options_max_', 'frm_format_' ].forEach( function( id ) { - const input = document.getElementById( id + fieldId ); - if ( ! input ) { - return; - } - - value += input.value; - }); - - typeDropdown = document.getElementsByName( 'field_options[type_' + fieldId + ']' )[0]; - fieldType = typeDropdown.options[typeDropdown.selectedIndex].value; - - if ( fieldType === 'text' ) { - toggleValidationBox( '' !== value, '.frm_invalid_msg' + fieldId ); - } - } - - function markRequired() { - /*jshint validthis:true */ - const thisid = this.id.replace( 'frm_', '' ), - fieldId = thisid.replace( 'req_field_', '' ), - checked = this.checked, - label = jQuery( '#field_label_' + fieldId + ' .frm_required' ); - - toggleValidationBox( checked, '.frm_required_details' + fieldId ); - - if ( checked ) { - const $reqBox = jQuery( 'input[name="field_options[required_indicator_' + fieldId + ']"]' ); - if ( $reqBox.val() === '' ) { - $reqBox.val( '*' ); - } - label.removeClass( 'frm_hidden' ); - } else { - label.addClass( 'frm_hidden' ); - } - } - - function toggleValidationBox( hasValue, messageClass ) { - $msg = jQuery( messageClass ); - if ( hasValue ) { - $msg.fadeIn( 'fast' ).closest( '.frm_validation_msg' ).fadeIn( 'fast' ); - } else { - //Fade out validation options - const v = $msg.fadeOut( 'fast' ).closest( '.frm_validation_box' ).children( ':not(' + messageClass + '):visible' ).length; - if ( v === 0 ) { - $msg.closest( '.frm_validation_msg' ).fadeOut( 'fast' ); - } - } - } - - function markUnique() { - /*jshint validthis:true */ - const fieldId = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ); - const $thisField = jQuery( '.frm_unique_details' + fieldId ); - if ( this.checked ) { - $thisField.fadeIn( 'fast' ).closest( '.frm_validation_msg' ).fadeIn( 'fast' ); - $unqDetail = jQuery( '.frm_unique_details' + fieldId + ' input' ); - if ( $unqDetail.val() === '' ) { - $unqDetail.val( frmAdminJs.default_unique ); - } - } else { - const v = $thisField.fadeOut( 'fast' ).closest( '.frm_validation_box' ).children( ':not(.frm_unique_details' + fieldId + '):visible' ).length; - if ( v === 0 ) { - $thisField.closest( '.frm_validation_msg' ).fadeOut( 'fast' ); - } - } - } - - //Fade confirmation field and validation option in or out - function addConf() { - /*jshint validthis:true */ - const fieldId = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ); - const val = jQuery( this ).val(); - const $thisField = jQuery( document.getElementById( 'frm_field_id_' + fieldId ) ); - - toggleValidationBox( val !== '', '.frm_conf_details' + fieldId ); - - if ( val !== '' ) { - //Add default validation message if empty - const valMsg = jQuery( '.frm_validation_box .frm_conf_details' + fieldId + ' input' ); - if ( valMsg.val() === '' ) { - valMsg.val( frmAdminJs.default_conf ); - } - - setConfirmationFieldDescriptions( fieldId ); - - //Add or remove class for confirmation field styling - if ( val === 'inline' ) { - $thisField.removeClass( 'frm_conf_below' ).addClass( 'frm_conf_inline' ); - } else if ( val === 'below' ) { - $thisField.removeClass( 'frm_conf_inline' ).addClass( 'frm_conf_below' ); - } - jQuery( '.frm-conf-box-' + fieldId ).removeClass( 'frm_hidden' ); - } else { - jQuery( '.frm-conf-box-' + fieldId ).addClass( 'frm_hidden' ); - setTimeout( function() { - $thisField.removeClass( 'frm_conf_inline frm_conf_below' ); - }, 200 ); - } - } - - function setConfirmationFieldDescriptions( fieldId ) { - const fieldType = document.getElementsByName( 'field_options[type_' + fieldId + ']' )[0].value; - - const fieldDescription = document.getElementById( 'field_description_' + fieldId ); - const hiddenDescName = 'field_options[description_' + fieldId + ']'; - const newValue = frmAdminJs['enter_' + fieldType]; - maybeSetNewDescription( fieldDescription, hiddenDescName, newValue ); - - const confFieldDescription = document.getElementById( 'conf_field_description_' + fieldId ); - const hiddenConfName = 'field_options[conf_desc_' + fieldId + ']'; - const newConfValue = frmAdminJs['confirm_' + fieldType]; - maybeSetNewDescription( confFieldDescription, hiddenConfName, newConfValue ); - } - - function maybeSetNewDescription( descriptionDiv, hiddenName, newValue ) { - if ( descriptionDiv.innerHTML === frmAdminJs.desc ) { - - // Set the visible description value and the hidden description value - descriptionDiv.innerHTML = newValue; - document.getElementsByName( hiddenName )[0].value = newValue; - } - } - - function initBulkOptionsOverlay() { - /*jshint validthis:true */ - const $info = initModal( '#frm-bulk-modal', '700px' ); - if ( $info === false ) { - return; - } - - jQuery( '.frm-insert-preset' ).on( 'click', insertBulkPreset ); - - jQuery( builderForm ).on( 'click', 'a.frm-bulk-edit-link', function( event ) { - event.preventDefault(); - let i, key, label, - content = '', - optList, - opts, - fieldId = jQuery( this ).closest( '[data-fid]' ).data( 'fid' ), - separate = usingSeparateValues( fieldId ), - product = isProductField( fieldId ); - - optList = document.getElementById( 'frm_field_' + fieldId + '_opts' ); - if ( ! optList ) { - return; - } - - opts = optList.getElementsByTagName( 'li' ); - - document.getElementById( 'bulk-field-id' ).value = fieldId; - - for ( i = 0; i < opts.length; i++ ) { - key = opts[i].getAttribute( 'data-optkey' ); - if ( key !== '000' ) { - label = document.getElementsByName( 'field_options[options_' + fieldId + '][' + key + '][label]' )[0]; - if ( typeof label !== 'undefined' ) { - content += label.value; - if ( separate ) { - content += '|' + document.getElementsByName( 'field_options[options_' + fieldId + '][' + key + '][value]' )[0].value; - } - if ( product ) { - content += '|' + document.getElementsByName( 'field_options[options_' + fieldId + '][' + key + '][price]' )[0].value; - } - content += '\r\n'; - } - } - - if ( i >= opts.length - 1 ) { - document.getElementById( 'frm_bulk_options' ).value = content; - } - } - - $info.dialog( 'open' ); - - return false; - }); - - jQuery( '#frm-update-bulk-opts' ).on( 'click', function() { - const fieldId = document.getElementById( 'bulk-field-id' ).value; - const optionType = document.getElementById( 'bulk-option-type' ).value; - - if ( optionType ) { - // Use custom handler for custom option type. - return; - } - - this.classList.add( 'frm_loading_button' ); - frmAdminBuild.updateOpts( fieldId, document.getElementById( 'frm_bulk_options' ).value, $info ); - fieldUpdated(); - }); - } - - function insertBulkPreset( event ) { - /*jshint validthis:true */ - const opts = JSON.parse( this.getAttribute( 'data-opts' ) ); - event.preventDefault(); - document.getElementById( 'frm_bulk_options' ).value = opts.join( '\n' ); - return false; - } - - //Add new option or "Other" option to radio/checkbox/dropdown - function addFieldOption() { - /*jshint validthis:true */ - let fieldId = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ), - newOption = jQuery( '#frm_field_' + fieldId + '_opts .frm_option_template' ).prop( 'outerHTML' ), - optType = jQuery( this ).data( 'opttype' ), - optKey = 0, - oldKey = '000', - lastKey = getHighestOptKey( fieldId ); - - if ( lastKey !== oldKey ) { - optKey = lastKey + 1; - } - - //Update hidden field - if ( optType === 'other' ) { - document.getElementById( 'other_input_' + fieldId ).value = 1; - - //Hide "Add Other" option now if this is radio field - const ftype = jQuery( this ).data( 'ftype' ); - if ( ftype === 'radio' || ftype === 'select' ) { - jQuery( this ).fadeOut( 'slow' ); - } - - const data = { - action: 'frm_add_field_option', - field_id: fieldId, - opt_key: optKey, - opt_type: optType, - nonce: frmGlobal.nonce - }; - jQuery.post( ajaxurl, data, function( msg ) { - jQuery( document.getElementById( 'frm_field_' + fieldId + '_opts' ) ).append( msg ); - resetDisplayedOpts( fieldId ); - }); - } else { - newOption = newOption.replace( new RegExp( 'optkey="' + oldKey + '"', 'g' ), 'optkey="' + optKey + '"' ); - newOption = newOption.replace( new RegExp( '-' + oldKey + '_', 'g' ), '-' + optKey + '_' ); - newOption = newOption.replace( new RegExp( '-' + oldKey + '"', 'g' ), '-' + optKey + '"' ); - newOption = newOption.replace( new RegExp( '\\[' + oldKey + '\\]', 'g' ), '[' + optKey + ']' ); - newOption = newOption.replace( 'frm_hidden frm_option_template', '' ); - newOption = { newOption }; - addSaveAndDragIconsToOption( fieldId, newOption ); - jQuery( document.getElementById( 'frm_field_' + fieldId + '_opts' ) ).append( newOption.newOption ); - resetDisplayedOpts( fieldId ); - } - fieldUpdated(); - } - - function getHighestOptKey( fieldId ) { - let i = 0, - optKey = 0, - opts = jQuery( '#frm_field_' + fieldId + '_opts li' ), - lastKey = 0; - - for ( i; i < opts.length; i++ ) { - optKey = opts[i].getAttribute( 'data-optkey' ); - if ( opts.length === 1 ) { - return optKey; - } - if ( optKey !== '000' ) { - optKey = optKey.replace( 'other_', '' ); - optKey = parseInt( optKey, 10 ); - } - - if ( ! isNaN( lastKey ) && ( optKey > lastKey || lastKey === '000' ) ) { - lastKey = optKey; - } - } - - return lastKey; - } - - function toggleMultSel() { - /*jshint validthis:true */ - const fieldId = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ); - toggleMultiSelect( fieldId, this.value ); - } - - function toggleMultiSelect( fieldId, value ) { - const setting = jQuery( '.frm_multiple_cont_' + fieldId ); - if ( value === 'select' ) { - setting.fadeIn( 'fast' ); - } else { - setting.fadeOut( 'fast' ); - } - } - - function toggleSepValues() { - /*jshint validthis:true */ - const fieldId = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ); - toggle( jQuery( '.field_' + fieldId + '_option_key' ) ); - jQuery( '.field_' + fieldId + '_option' ).toggleClass( 'frm_with_key' ); - } - - function toggleImageOptions() { - /*jshint validthis:true */ - let hasImageOptions, imageSize, - $field = jQuery( this ).closest( '.frm-single-settings' ), - fieldId = $field.data( 'fid' ), - displayField = document.getElementById( 'frm_field_id_' + fieldId ); - - refreshOptionDisplayNow( jQuery( this ) ); - - toggle( jQuery( '.field_' + fieldId + '_image_id' ) ); - toggle( jQuery( '.frm_toggle_image_options_' + fieldId ) ); - toggle( jQuery( '.frm_image_size_' + fieldId ) ); - toggle( jQuery( '.frm_alignment_' + fieldId ) ); - toggle( jQuery( '.frm-add-other#frm_add_field_' + fieldId ) ); - - hasImageOptions = imagesAsOptions( fieldId ); - - if ( hasImageOptions ) { - setAlignment( fieldId, 'inline' ); - removeImageSizeClasses( displayField ); - imageSize = getImageOptionSize( fieldId ); - displayField.classList.add( 'frm_image_options' ); - displayField.classList.add( 'frm_image_size_' + imageSize ); - $field.find( '.frm-bulk-edit-link' ).hide(); - } else { - displayField.classList.remove( 'frm_image_options' ); - removeImageSizeClasses( displayField ); - setAlignment( fieldId, 'block' ); - $field.find( '.frm-bulk-edit-link' ).show(); - } - } - - function removeImageSizeClasses( field ) { - field.classList.remove( 'frm_image_size_', 'frm_image_size_small', 'frm_image_size_medium', 'frm_image_size_large', 'frm_image_size_xlarge' ); - } - - function setAlignment( fieldId, alignment ) { - jQuery( '#field_options_align_' + fieldId ).val( alignment ).trigger( 'change' ); - } - - function setImageSize() { - const $field = jQuery( this ).closest( '.frm-single-settings' ), - fieldId = $field.data( 'fid' ), - displayField = document.getElementById( 'frm_field_id_' + fieldId ); - - refreshOptionDisplay(); - - if ( imagesAsOptions( fieldId ) ) { - removeImageSizeClasses( displayField ); - displayField.classList.add( 'frm_image_options' ); - displayField.classList.add( 'frm_image_size_' + getImageOptionSize( fieldId ) ); - } - } - - function refreshOptionDisplayNow( object ) { - const $field = object.closest( '.frm-single-settings' ), - fieldID = $field.data( 'fid' ); - jQuery( '.field_' + fieldID + '_option' ).trigger( 'change' ); - } - - function refreshOptionDisplay() { - /*jshint validthis:true */ - refreshOptionDisplayNow( jQuery( this ) ); - } - - function addImageToOption( event ) { - const imagePreview = event.target.closest( '.frm_image_preview_wrapper' ); - - event.preventDefault(); - - wp.media.model.settings.post.id = 0; - - const fileFrame = wp.media.frames.file_frame = wp.media({ - multiple: false, - library: { - type: [ 'image' ] - } - }); - - fileFrame.on( 'select', function() { - const attachment = fileFrame.state().get( 'selection' ).first().toJSON(); - const img = imagePreview.querySelector( 'img' ); - - img.setAttribute( 'src', attachment.url ); - img.classList.remove( 'frm_hidden' ); - img.removeAttribute( 'srcset' ); // Prevent the old image from sticking around. - - imagePreview.querySelector( '.frm_image_preview_frame' ).style.display = 'block'; - imagePreview.querySelector( '.frm_image_preview_title' ).textContent = attachment.filename; - imagePreview.querySelector( '.frm_choose_image_box' ).style.display = 'none'; - - const $imagePreview = jQuery( imagePreview ); - $imagePreview.siblings( 'input[name*="[label]"]' ).data( 'frmimgurl', attachment.url ); - $imagePreview.find( 'input.frm_image_id' ).val( attachment.id ).trigger( 'change' ); - wp.media.model.settings.post.id = 0; - }); - - fileFrame.open(); - } - - function removeImageFromOption( event ) { - const $this = jQuery( this ), - previewWrapper = $this.closest( '.frm_image_preview_wrapper' ); - - event.preventDefault(); - event.stopPropagation(); - - previewWrapper.find( 'img' ).attr( 'src', '' ); - previewWrapper.find( '.frm_image_preview_frame' ).hide(); - previewWrapper.find( '.frm_choose_image_box' ).show(); - previewWrapper.find( 'input.frm_image_id' ).val( 0 ).trigger( 'change' ); - } - - function toggleMultiselect() { - /*jshint validthis:true */ - const dropdown = jQuery( this ).closest( 'li' ).find( '.frm_form_fields select' ); - if ( this.checked ) { - dropdown.attr( 'multiple', 'multiple' ); - } else { - dropdown.removeAttr( 'multiple' ); - } - } - - /** - * Allow typing on form switcher click without an extra click to search. - */ - function focusSearchBox() { - const searchBox = document.getElementById( 'dropform-search-input' ); - if ( searchBox !== null ) { - setTimeout( function() { - searchBox.focus(); - }, 100 ); - } - } - - /** - * Dismiss a warning message and send an AJAX request to update the dismissal state. - * - * @since 6.3 - * - * @param {Event} event The event object associated with the click on the dismiss icon. - */ - function dismissWarningMessage( event ) { - const target = event.target; - - const warningEl = target.closest( '.frm_warning_style' ); - jQuery( warningEl ).fadeOut( 400, () => warningEl.remove() ); - - const action = target.dataset.action; - const formData = new FormData(); - doJsonPost( action, formData ); - } - - /** - * If a field is clicked in the builder, prevent inputs from changing. - */ - function stopFieldFocus( e ) { - e.preventDefault(); - } - - function deleteFieldOption() { - /*jshint validthis:true */ - let otherInput, - parentLi = this.parentNode, - parentUl = parentLi.parentNode, - fieldId = this.getAttribute( 'data-fid' ); - - jQuery( parentLi ).fadeOut( 'slow', function() { - wp.hooks.doAction( 'frm_before_delete_field_option', this ); - jQuery( parentLi ).remove(); - - const hasOther = jQuery( parentUl ).find( '.frm_other_option' ); - if ( hasOther.length < 1 ) { - otherInput = document.getElementById( 'other_input_' + fieldId ); - if ( otherInput !== null ) { - otherInput.value = 0; - } - jQuery( '#other_button_' + fieldId ).fadeIn( 'slow' ); - } - }); - fieldUpdated(); - } - - /** - * If a radio button is set as default, allow a click to - * deselect it. - */ - function maybeUncheckRadio() { - let $self, uncheck, unbind, up; - - /*jshint validthis:true */ - $self = jQuery( this ); - if ( $self.is( ':checked' ) ) { - uncheck = function() { - setTimeout( function() { - $self.prop( 'checked', false ); - }, 0 ); - }; - unbind = function() { - $self.off( 'mouseup', up ); - }; - up = function() { - uncheck(); - unbind(); - }; - $self.on( 'mouseup', up ); - $self.one( 'mouseout', unbind ); - } - } - - /** - * If the field option has the default text, clear it out on click. - */ - function maybeClearOptText() { - /*jshint validthis:true */ - if ( this.value === frmAdminJs.new_option ) { - this.setAttribute( 'data-value-on-focus', this.value ); - this.value = ''; - } - } - - function confirmFieldsDeleteMessage( numberOfFields ) { - /* translators: %1$s: Number of fields that are selected to be deleted. */ - return sprintf( __( 'Are you sure you want to delete these %1$s selected field(s)?', 'formidable' ), numberOfFields ); - } - - function clickDeleteField() { - /*jshint validthis:true */ - let confirmMsg = frmAdminJs.conf_delete, - maybeDivider = this.parentNode.parentNode.parentNode.parentNode.parentNode, - li = maybeDivider.parentNode, - field = jQuery( this ).closest( 'li.form-field' ), - fieldId = field.data( 'fid' ); - - if ( field.data( 'ftype' ) === 'divider' ) { - const fieldBoxes = document.querySelectorAll( '.frm-field-group-hover-target .start_divider .frm_field_box' ); - let fieldIdsToDelete = 0; - fieldBoxes.forEach( fieldBox => { - const fieldsInsideFieldBox = fieldBox.querySelectorAll( 'li.form-field' ); - if ( fieldsInsideFieldBox ) { - fieldIdsToDelete += fieldsInsideFieldBox.length; - } - }); - if ( fieldIdsToDelete ) { - confirmMsg = confirmFieldsDeleteMessage( ++fieldIdsToDelete ); - } - } - - if ( li.classList.contains( 'frm-section-collapsed' ) || li.classList.contains( 'frm-page-collapsed' ) ) { - return false; - } - - // If deleting a section, use a special message. - if ( maybeDivider.className === 'divider_section_only' ) { - confirmMsg = frmAdminJs.conf_delete_sec; - } - - this.setAttribute( 'data-frmverify', confirmMsg ); - this.setAttribute( 'data-frmverify-btn', 'frm-button-red' ); - this.setAttribute( 'data-deletefield', fieldId ); - - closeOpenFieldDropdowns(); - - confirmLinkClick( this ); - return false; - } - - function clickSelectField() { - this.closest( 'li.form-field' ).click(); - } - - function clickDeleteFieldGroup() { - let hoverTarget, decoy; - - hoverTarget = document.querySelector( '.frm-field-group-hover-target' ); - if ( null === hoverTarget ) { - return; - } - - hoverTarget.classList.add( 'frm-selected-field-group' ); - - decoy = document.createElement( 'div' ); - decoy.classList.add( 'frm-delete-field-groups', 'frm_hidden' ); - document.body.appendChild( decoy ); - decoy.click(); - } - - function duplicateFieldGroup() { - const hoverTarget = document.querySelector( '.frm-field-group-hover-target' ); - if ( null === hoverTarget ) { - return; - } - - const newRowId = 'frm_field_group_' + getAutoId(); - const placeholderUlChild = document.createTextNode( '' ); - wrapFieldLiInPlace( placeholderUlChild ); - - const newRow = jQuery( placeholderUlChild ).closest( 'li' ).get( 0 ); - newRow.classList.add( 'frm_hidden' ); - - const newRowUl = newRow.querySelector( 'ul' ); - newRowUl.id = newRowId; - - jQuery( hoverTarget.closest( 'li.frm_field_box' ) ).after( newRow ); - - const $fields = getFieldsInRow( jQuery( hoverTarget ) ); - const syncDetails = []; - const injectedCloneOptions = []; - - const expectedLength = $fields.length; - const originalFieldIdByDuplicatedFieldId = {}; - - let duplicatedCount = 0; - - jQuery( newRow ).on( - 'frm_added_duplicated_field_to_row', - function( _, args ) { - originalFieldIdByDuplicatedFieldId[ jQuery( args.duplicatedFieldHtml ).attr( 'data-fid' ) ] = args.originalFieldId; - - if ( expectedLength > ++duplicatedCount ) { - return; - } - - const $newRowUl = jQuery( newRowUl ); - const $duplicatedFields = getFieldsInRow( $newRowUl ); - - injectedCloneOptions.forEach( - function( cloneOption ) { - cloneOption.remove(); - } - ); - - for ( let index = 0; index < expectedLength; ++index ) { - $newRowUl.append( $newRowUl.children( 'li.form-field[frm-field-order="' + index + '"]' ) ); - } - - syncLayoutClasses( $duplicatedFields.first(), syncDetails ); - newRow.classList.remove( 'frm_hidden' ); - updateFieldOrder(); - - getFieldsInRow( $newRowUl ).each( - function() { - maybeDuplicateUnsavedSettings( originalFieldIdByDuplicatedFieldId[ this.getAttribute( 'data-fid' ) ], jQuery( this ).prop( 'outerHTML' ) ); - } - ); - } - ); - - $fields.each( - function( index ) { - let cloneOption; - cloneOption = document.createElement( 'li' ); - cloneOption.classList.add( 'frm_clone_field' ); - cloneOption.setAttribute( 'frm-target-row-id', newRowId ); - cloneOption.setAttribute( 'frm-field-order', index ); - this.appendChild( cloneOption ); - cloneOption.click(); - injectedCloneOptions.push( cloneOption ); - syncDetails.push( getSizeOfLayoutClass( getLayoutClassName( this.classList ) ) ); - } - ); - } - - function clickFieldGroupLayout() { - let hoverTarget, sizeOfFieldGroup, popupWrapper; - - hoverTarget = document.querySelector( '.frm-field-group-hover-target' ); - - if ( null === hoverTarget ) { - return; - } - - deselectFields(); - - sizeOfFieldGroup = getSizeOfFieldGroupFromChildElement( hoverTarget.querySelector( 'li.form-field' ) ); - - hoverTarget.classList.add( 'frm-has-open-field-group-popup' ); - jQuery( document ).on( 'click', '#frm_builder_page', destroyFieldGroupPopupOnOutsideClick ); - - popupWrapper = div(); - popupWrapper.style.position = 'relative'; - popupWrapper.appendChild( getFieldGroupPopup( sizeOfFieldGroup, this ) ); - this.parentNode.appendChild( popupWrapper ); - - const firstLayoutOption = popupWrapper.querySelector( '.frm-row-layout-option' ); - if ( firstLayoutOption ) { - firstLayoutOption.focus(); - } - } - - function destroyFieldGroupPopupOnOutsideClick( event ) { - if ( event.target.classList.contains( 'frm-custom-field-group-layout' ) || event.target.classList.contains( 'frm-cancel-custom-field-group-layout' ) ) { - return; - } - if ( ! jQuery( event.target ).closest( '#frm_field_group_controls' ).length && ! jQuery( event.target ).closest( '#frm_field_group_popup' ).length ) { - destroyFieldGroupPopup(); - } - } - - function getSizeOfFieldGroupFromChildElement( element ) { - const $ul = jQuery( element ).closest( 'ul' ); - if ( $ul.length ) { - return getFieldsInRow( $ul ).length; - } - return getSelectedFieldCount(); - } - - function getFieldGroupPopup( sizeOfFieldGroup, childElement ) { - let popup, wrapper, rowLayoutOptions, ul; - - popup = document.getElementById( 'frm_field_group_popup' ); - if ( null === popup ) { - popup = div(); - } else { - popup.innerHTML = ''; - } - - popup.id = 'frm_field_group_popup'; - - wrapper = div(); - wrapper.style.padding = '0 24px 12px'; - wrapper.appendChild( getRowLayoutTitle() ); - - rowLayoutOptions = getRowLayoutOptions( sizeOfFieldGroup ); - - ul = childElement.closest( 'ul.frm_sorting' ); - if ( null !== ul ) { - maybeMarkRowLayoutAsActive( ul, rowLayoutOptions ); - } - - wrapper.appendChild( rowLayoutOptions ); - - popup.appendChild( wrapper ); - popup.appendChild( separator() ); - - popup.appendChild( getCustomLayoutOption() ); - popup.appendChild( getBreakIntoDifferentRowsOption() ); - - return popup; - } - - function maybeMarkRowLayoutAsActive( activeRow, options ) { - let length, index, currentRow; - - length = options.children.length; - for ( index = 0; index < length; ++index ) { - currentRow = options.children[ index ]; - if ( rowLayoutsMatch( currentRow, activeRow ) ) { - currentRow.classList.add( 'frm-active-row-layout' ); - return; - } - } - } - - function separator() { - return document.createElement( 'hr' ); - } - - function getCustomLayoutOption() { - const option = div(); - option.textContent = __( 'Custom layout', 'formidable' ); - jQuery( option ).prepend( getIconClone( 'frm_gear_svg' ) ); - option.classList.add( 'frm-custom-field-group-layout' ); - makeTabbable( option ); - return option; - } - - function makeTabbable( element, ariaLabel ) { - element.setAttribute( 'tabindex', 0 ); - element.setAttribute( 'role', 'button' ); - if ( 'undefined' !== typeof ariaLabel ) { - element.setAttribute( 'aria-label', ariaLabel ); - } - } - - function getIconClone( iconId ) { - const clone = document.getElementById( iconId ).cloneNode( true ); - clone.id = ''; - return clone; - } - - function getBreakIntoDifferentRowsOption() { - const option = div(); - option.textContent = __( 'Break into rows', 'formidable' ); - jQuery( option ).prepend( getIconClone( 'frm_break_field_group_svg' ) ); - option.classList.add( 'frm-break-field-group' ); - makeTabbable( option ); - return option; - } - - function getRowLayoutTitle() { - const rowLayoutTitle = div(); - rowLayoutTitle.classList.add( 'frm-row-layout-title' ); - rowLayoutTitle.textContent = __( 'Row Layout', 'formidable' ); - return rowLayoutTitle; - } - - function getRowLayoutOptions( size ) { - let wrapper, padding; - - wrapper = getEmptyGridContainer(); - if ( 5 !== size ) { - wrapper.appendChild( getRowLayoutOption( size, 'even' ) ); - } - if ( size % 2 === 1 ) { - // only include the middle option for odd numbers because even doesn't make a lot of sense. - wrapper.appendChild( getRowLayoutOption( size, 'middle' ) ); - } - if ( size < 6 ) { - wrapper.appendChild( getRowLayoutOption( size, 'left' ) ); - wrapper.appendChild( getRowLayoutOption( size, 'right' ) ); - } else { - padding = div(); - padding.classList.add( 'frm_fourth' ); - wrapper.prepend( padding ); - } - - return wrapper; - } - - function getRowLayoutOption( size, type ) { - let option, useClass; - - option = div(); - option.classList.add( 'frm-row-layout-option' ); - makeTabbable( option, type ); - - switch ( size ) { - case 6: - useClass = 'frm_half'; - break; - case 5: - useClass = 'frm_third'; - break; - default: - useClass = size % 2 === 1 ? 'frm_fourth' : 'frm_third'; - break; - } - - option.classList.add( useClass ); - option.setAttribute( 'layout-type', type ); - - option.appendChild( getRowForSizeAndType( size, type ) ); - return option; - } - - function rowLayoutsMatch( row1, row2 ) { - return getRowLayoutAsKey( row1 ) === getRowLayoutAsKey( row2 ); - } - - function getRowLayoutAsKey( row ) { - let $fields, sizes; - if ( row.classList.contains( 'frm-row-layout-option' ) ) { - $fields = jQuery( row ).find( '.frm_grid_container' ).children(); - } else { - $fields = getFieldsInRow( jQuery( row ) ); - } - sizes = []; - $fields.each( - function() { - sizes.push( getSizeOfLayoutClass( getLayoutClassName( this.classList ) ) ); - } - ); - return sizes.join( '-' ); - } - - function getRowForSizeAndType( size, type ) { - let row, index, block; - - row = getEmptyGridContainer(); - for ( index = 0; index < size; ++index ) { - block = div(); - block.classList.add( getClassForBlock( size, type, index ) ); - block.style.height = '16px'; - block.style.background = '#9EA9B8'; - block.style.borderRadius = '1px'; - row.appendChild( block ); - } - - return row; - } - - /** - * @param {int} size 2-6. - * @param {string} type even, middle, left, or right. - * @param {int} index 0-5. - * @returns string - */ - function getClassForBlock( size, type, index ) { - if ( 'even' === type ) { - return getEvenClassForSize( size, index ); - } else if ( 'middle' === type ) { - if ( 3 === size ) { - return 1 === index ? 'frm6' : 'frm3'; - } - if ( 5 === size ) { - return 2 === index ? 'frm4' : 'frm2'; - } - } else if ( 'left' === type ) { - return 0 === index ? getLargeClassForSize( size ) : getSmallClassForSize( size ); - } else if ( 'right' === type ) { - return index === size - 1 ? getLargeClassForSize( size ) : getSmallClassForSize( size ); - } - return 'frm12'; - } - - function getEvenClassForSize( size, index ) { - if ( -1 !== [ 2, 3, 4, 6 ].indexOf( size ) ) { - return getLayoutClassForSize( 12 / size ); - } - if ( 5 === size && 'undefined' !== typeof index ) { - return 0 === index ? 'frm4' : 'frm2'; - } - return 'frm12'; - } - - function getSmallClassForSize( size ) { - switch ( size ) { - case 2: case 3: - return 'frm3'; - case 4: - return 'frm2'; - case 5: - return 'frm2'; - case 6: - return 'frm1'; - } - return 'frm12'; - } - - function getLargeClassForSize( size ) { - switch ( size ) { - case 2: - return 'frm9'; - case 3: case 4: - return 'frm6'; - case 5: - return 'frm4'; - case 6: - return 'frm7'; - } - return 'frm12'; - } - - function getEmptyGridContainer() { - const wrapper = div(); - wrapper.classList.add( 'frm_grid_container' ); - return wrapper; - } - - /** - * Handle when a field group layout option (that sets grid classes/column sizing) is selected in the "Row Layout" popup. - * - * @returns {void} - */ - function handleFieldGroupLayoutOptionClick() { - const row = document.querySelector( '.frm-field-group-hover-target' ); - if ( ! row ) { - // The field group layout options also get clicked when merging multiple rows. - // The following code isn't required for multiple rows though so just exit early. - return; - } - - const type = this.getAttribute( 'layout-type' ); - syncLayoutClasses( getFieldsInRow( jQuery( row ) ).first(), type ); - destroyFieldGroupPopup(); - } - - function handleFieldGroupLayoutOptionInsideMergeClick() { - let $ul, type; - $ul = mergeSelectedFieldGroups(); - type = this.getAttribute( 'layout-type' ); - syncLayoutClasses( getFieldsInRow( $ul ).first(), type ); - unselectFieldGroups(); - } - - function mergeSelectedFieldGroups() { - const $selectedFieldGroups = jQuery( '.frm-selected-field-group' ), - $firstGroupUl = $selectedFieldGroups.first(); - $selectedFieldGroups.not( $firstGroupUl ).each( - function() { - getFieldsInRow( jQuery( this ) ).each( - function() { - const previousParent = this.parentNode; - getFieldsInRow( $firstGroupUl ).last().after( this ); - if ( ! jQuery( previousParent ).children( 'li.form-field' ).length ) { - // clean up the previous field group if we've removed all of its fields. - previousParent.closest( 'li.frm_field_box' ).remove(); - } - } - ); - } - ); - updateFieldOrder(); - syncLayoutClasses( getFieldsInRow( $firstGroupUl ).first() ); - return $firstGroupUl; - } - - function customFieldGroupLayoutClick() { - let $fields; - if ( null !== this.closest( '.frm-merge-fields-into-row' ) ) { - return; - } - $fields = getFieldsInRow( jQuery( '.frm-field-group-hover-target' ) ); - setupCustomLayoutOptions( $fields ); - } - - function setupCustomLayoutOptions( $fields ) { - let size, popup, wrapper, layoutClass, inputRow, paddingElement, inputValueOverride, index, inputField, heading, label, buttonsWrapper, cancelButton, saveButton; - - size = $fields.length; - - popup = document.getElementById( 'frm_field_group_popup' ); - popup.innerHTML = ''; - - wrapper = div(); - wrapper.style.padding = '0 24px'; - - layoutClass = getEvenClassForSize( 5 === size ? 6 : size ); - - inputRow = div(); - inputRow.style.padding = '20px 0'; - inputRow.classList.add( 'frm_grid_container' ); - - if ( 5 === size ) { - // add a span to pad the inputs by 1 column, to account for the missing 2 columns. - paddingElement = document.createElement( 'span' ); - paddingElement.classList.add( 'frm1' ); - inputRow.appendChild( paddingElement ); - } - - inputValueOverride = getSelectedFieldCount() > 0 ? getSizeOfLayoutClass( getEvenClassForSize( size ) ) : false; - if ( false !== inputValueOverride && inputValueOverride >= 12 ) { - inputValueOverride = Math.floor( 12 / size ); - } - - for ( index = 0; index < size; ++index ) { - inputField = document.createElement( 'input' ); - inputField.type = 'text'; - inputField.classList.add( layoutClass ); - inputField.classList.add( 'frm-custom-grid-size-input' ); - inputField.value = false !== inputValueOverride ? inputValueOverride : getSizeOfLayoutClass( getLayoutClassName( $fields.get( index ).classList ) ); - inputRow.appendChild( inputField ); - } - - heading = div(); - heading.classList.add( 'frm-builder-popup-heading' ); - heading.textContent = __( 'Enter number of columns for each field', 'formidable' ); - - label = div(); - label.classList.add( 'frm-builder-popup-subheading' ); - label.textContent = __( 'Layouts are based on a 12-column grid system', 'formidable' ); - - wrapper.appendChild( heading ); - wrapper.appendChild( label ); - - wrapper.appendChild( inputRow ); - - buttonsWrapper = div(); - buttonsWrapper.style.textAlign = 'right'; - - cancelButton = getSecondaryButton(); - cancelButton.textContent = __( 'Cancel', 'formidable' ); - cancelButton.classList.add( 'frm-cancel-custom-field-group-layout' ); - cancelButton.style.marginRight = '10px'; - - saveButton = getPrimaryButton(); - saveButton.textContent = __( 'Save', 'formidable' ); - saveButton.classList.add( 'frm-save-custom-field-group-layout' ); - - buttonsWrapper.appendChild( cancelButton ); - buttonsWrapper.appendChild( saveButton ); - - wrapper.appendChild( buttonsWrapper ); - - popup.appendChild( wrapper ); - - setTimeout( - function() { - const firstInput = popup.querySelector( 'input.frm-custom-grid-size-input' ).focus(); - if ( firstInput ) { - firstInput.focus(); - } - }, - 0 - ); - } - - function customFieldGroupLayoutInsideMergeClick() { - $fields = jQuery( '.frm-selected-field-group li.form-field' ); - setupCustomLayoutOptions( $fields ); - } - - function getPrimaryButton() { - const button = getButton(); - button.classList.add( 'button-primary', 'frm-button-primary' ); - return button; - } - - function getSecondaryButton() { - const button = getButton(); - button.classList.add( 'button-secondary', 'frm-button-secondary' ); - return button; - } - - function getButton() { - const button = document.createElement( 'a' ); - button.setAttribute( 'href', '#' ); - button.classList.add( 'button' ); - button.style.textDecoration = 'none'; - return button; - } - - function getSizeOfLayoutClass( className ) { - switch ( className ) { - case 'frm_half': - return 6; - case 'frm_third': - return 4; - case 'frm_two_thirds': - return 8; - case 'frm_fourth': - return 3; - case 'frm_three_fourths': - return 9; - case 'frm_sixth': - return 2; - } - - if ( 0 === className.indexOf( 'frm' ) ) { - return parseInt( className.substr( 3 ) ); - } - - // Anything missing a layout class should be a full width row. - return 12; - } - - function getLayoutClassName( classList ) { - let classes, index, currentClass; - classes = getLayoutClasses(); - for ( index = 0; index < classes.length; ++index ) { - currentClass = classes[ index ]; - if ( classList.contains( currentClass ) ) { - return currentClass; - } - } - return ''; - } - - function getLayoutClassForSize( size ) { - return 'frm' + size; - } - - function breakFieldGroupClick() { - const row = document.querySelector( '.frm-field-group-hover-target' ); - breakRow( row ); - destroyFieldGroupPopup(); - } - - function breakRow( row ) { - const $row = jQuery( row ); - getFieldsInRow( $row ).each( - function( index ) { - const field = this; - if ( 0 !== index ) { - $row.parent().after( wrapFieldLi( field ) ); - } - stripLayoutFromFields( jQuery( field ) ); - } - ); - } - - function stripLayoutFromFields( field ) { - syncLayoutClasses( field, 'clear' ); - } - - function focusFieldGroupInputOnClick() { - this.select(); - } - - function cancelCustomFieldGroupClick() { - revertToFieldGroupPopupFirstPage( this ); - } - - function revertToFieldGroupPopupFirstPage( triggerElement ) { - jQuery( document.getElementById( 'frm_field_group_popup' ) ).replaceWith( - getFieldGroupPopup( getSizeOfFieldGroupFromChildElement( triggerElement ), triggerElement ) - ); - } - - function destroyFieldGroupPopup() { - let popup, wrapper; - popup = document.getElementById( 'frm_field_group_popup' ); - if ( popup === null ) { - return; - } - wrapper = document.querySelector( '.frm-has-open-field-group-popup' ); - if ( null !== wrapper ) { - wrapper.classList.remove( 'frm-has-open-field-group-popup' ); - popup.parentNode.remove(); - } - jQuery( document ).off( 'click', '#frm_builder_page', destroyFieldGroupPopupOnOutsideClick ); - } - - function saveCustomFieldGroupClick() { - let syncDetails, $controls, $ul; - - syncDetails = []; - - jQuery( document.getElementById( 'frm_field_group_popup' ).querySelectorAll( '.frm_grid_container input' ) ) - .each( - function() { - syncDetails.push( parseInt( this.value ) ); - } - ); - - $controls = jQuery( document.getElementById( 'frm_field_group_controls' ) ); - - if ( $controls.length && 'none' !== $controls.get( 0 ).style.display ) { - syncLayoutClasses( getFieldsInRow( jQuery( document.querySelector( '.frm-field-group-hover-target' ) ) ).first(), syncDetails ); - } else { - $ul = mergeSelectedFieldGroups(); - syncLayoutClasses( getFieldsInRow( $ul ).first(), syncDetails ); - unselectFieldGroups(); - } - - destroyFieldGroupPopup(); - } - - function fieldGroupClick( e ) { - maybeShowFieldGroupMessage(); - - if ( 'ul' !== e.originalEvent.target.nodeName.toLowerCase() ) { - // only continue if the group itself was clicked / ignore when a field is clicked. - return; - } - - const hoverTarget = document.querySelector( '.frm-field-group-hover-target' ); - if ( ! hoverTarget ) { - return; - } - - const ctrlOrCmdKeyIsDown = e.ctrlKey || e.metaKey; - const shiftKeyIsDown = e.shiftKey; - const groupIsActive = hoverTarget.classList.contains( 'frm-selected-field-group' ); - const $selectedFieldGroups = getSelectedFieldGroups(); - - let numberOfSelectedGroups = $selectedFieldGroups.length; - - if ( ctrlOrCmdKeyIsDown || shiftKeyIsDown ) { - // multi-selecting - - const selectedField = getSelectedField(); - if ( null !== selectedField && ! jQuery( selectedField ).siblings( 'li.form-field' ).length ) { - // count a selected field on its own as a selected field group when multiselecting. - selectedField.parentNode.classList.add( 'frm-selected-field-group' ); - ++numberOfSelectedGroups; - } - - if ( ctrlOrCmdKeyIsDown ) { - if ( groupIsActive ) { - // unselect if holding ctrl or cmd and the group was already active. - --numberOfSelectedGroups; - hoverTarget.classList.remove( 'frm-selected-field-group' ); - syncAfterMultiSelect( numberOfSelectedGroups ); - return; // exit early to avoid adding back frm-selected-field-group - } - - ++numberOfSelectedGroups; - } else if ( shiftKeyIsDown && ! groupIsActive ) { - ++numberOfSelectedGroups; // include the one we're selecting right now. - const $firstGroup = $selectedFieldGroups.first(); - - let $range; - if ( $firstGroup.parent().index() < jQuery( hoverTarget.parentNode ).index() ) { - $range = $firstGroup.parent().nextUntil( hoverTarget.parentNode ); - } else { - $range = $firstGroup.parent().prevUntil( hoverTarget.parentNode ); - } - - $range.each( - function() { - const $fieldGroup = jQuery( this ).closest( 'li' ).find( 'ul.frm_sorting' ); - if ( ! $fieldGroup.hasClass( 'frm-selected-field-group' ) ) { - ++numberOfSelectedGroups; - $fieldGroup.addClass( 'frm-selected-field-group' ); - } - } - ); - } - } else { - // not multi-selecting - unselectFieldGroups(); - numberOfSelectedGroups = 1; - } - - hoverTarget.classList.add( 'frm-selected-field-group' ); - syncAfterMultiSelect( numberOfSelectedGroups ); - - maybeHideFieldGroupMessage(); - - jQuery( document ).off( 'click', unselectFieldGroups ); - jQuery( document ).on( 'click', unselectFieldGroups ); - } - - /** - * Hide the field group message by manipulating classes. - * - * @param {Element} fieldGroupMessage The field group message element. - * @return {void} - */ - function hideFieldGroupMessage( fieldGroupMessage ) { - if ( ! fieldGroupMessage ) { - return; - } - - fieldGroupMessage.classList.add( 'frm_hidden' ); - fieldGroupMessage.classList.remove( 'frm-fadein-up-back' ); - } - - /** - * Show the field group message by manipulating classes. - * - * @param {Element} fieldGroupMessage The field group message element. - * @return {void} - */ - function showFieldGroupMessage( fieldGroupMessage ) { - if ( ! fieldGroupMessage ) { - return; - } - - fieldGroupMessage.classList.remove( 'frm_hidden' ); - fieldGroupMessage.classList.add( 'frm-fadein-up-back' ); - } - - /** - * Maybe show a message if there are at least two rows. - * - * @return {void} - */ - function maybeShowFieldGroupMessage() { - let fieldGroupMessage = document.getElementById( 'frm-field-group-message' ); - const rows = document.querySelectorAll( '.edit_form_item:not(.edit_field_type_end_divider)' ); - - if ( rows.length < 2 ) { - hideFieldGroupMessage( fieldGroupMessage ); - return; - } - - if ( fieldGroupMessage ) { - showFieldGroupMessage( fieldGroupMessage ); - return; - } - - fieldGroupMessage = div({ - id: 'frm-field-group-message', - className: 'frm-flex-center frm-fadein-up-back', - children: [ - span({ - id: 'frm-field-group-message-dismiss', - className: 'frm-flex-center', - child: svg({ href: '#frm_close_icon' }) - }) - ] - }); - - // Insert the field group into the DOM - document.getElementById( 'post-body-content' ).appendChild( fieldGroupMessage ); - - // Get and add the field group message text - const messageText = getFieldGroupMessageText(); - fieldGroupMessage.prepend( messageText ); - - // Set up a click event listener - document.getElementById( 'frm-field-group-message-dismiss' ).addEventListener( 'click', () => { - hideFieldGroupMessage( document.getElementById( 'frm-field-group-message' ) ); - }); - } - - /** - * Get a span element with text about selecting multiple fields. - * - * @return {HTMLElement} A span element with the message and style classes. - */ - function getFieldGroupMessageText() { - const text = document.createElement( 'span' ); - text.classList.add( 'frm-field-group-message-text', 'frm-flex-center' ); - text.innerHTML = sprintf( - /* translators: %1$s: Start span HTML, %2$s: end span HTML */ - frm_admin_js.holdShiftMsg, // eslint-disable-line camelcase - '', - '' - ); - - return text; - } - - /** - * Maybe hide the field group message based on the number of selected rows. - * - * @return {void} - */ - function maybeHideFieldGroupMessage() { - const selectedRowCount = document.querySelectorAll( '.frm-selected-field-group' ).length; - if ( selectedRowCount < 2 ) { - return; - } - - const fieldGroupMessage = document.getElementById( 'frm-field-group-message' ); - hideFieldGroupMessage( fieldGroupMessage ); - } - - function getSelectedField() { - return document.getElementById( 'frm-show-fields' ).querySelector( 'li.form-field.selected' ); - } - - function getSelectedFieldGroups() { - const $fieldGroups = jQuery( '.frm-selected-field-group' ); - if ( $fieldGroups.length ) { - return $fieldGroups; - } - - const selectedField = getSelectedField(); - if ( selectedField ) { - // If there is only one field in a group and the field is selected, consider the field's group as selected for multi-select. - const selectedFieldGroup = selectedField.closest( 'ul' ); - if ( selectedFieldGroup && 1 === getFieldsInRow( jQuery( selectedFieldGroup ) ).length ) { - selectedFieldGroup.classList.add( 'frm-selected-field-group' ); - return jQuery( selectedFieldGroup ); - } - } - - return jQuery(); - } - - function syncAfterMultiSelect( numberOfSelectedGroups ) { - clearSettingsBox( true ); // unselect any fields if one is selected. - if ( numberOfSelectedGroups >= 2 || ( 1 === numberOfSelectedGroups && selectedGroupHasMultipleFields() ) ) { - addFieldMultiselectPopup(); - } else { - maybeRemoveMultiselectPopup(); - } - maybeRemoveGroupHoverTarget(); - } - - function selectedGroupHasMultipleFields() { - return getFieldsInRow( jQuery( document.querySelector( '.frm-selected-field-group' ) ) ).length > 1; - } - - function unselectFieldGroups( event ) { - if ( 'undefined' !== typeof event ) { - if ( null !== event.originalEvent.target.closest( '#frm-show-fields' ) ) { - return; - } - if ( event.originalEvent.target.classList.contains( 'frm-merge-fields-into-row' ) ) { - return; - } - if ( null !== event.originalEvent.target.closest( '.frm-merge-fields-into-row' ) ) { - return; - } - if ( event.originalEvent.target.classList.contains( 'frm-custom-field-group-layout' ) ) { - return; - } - if ( event.originalEvent.target.classList.contains( 'frm-cancel-custom-field-group-layout' ) ) { - return; - } - } - jQuery( '.frm-selected-field-group' ).removeClass( 'frm-selected-field-group' ); - jQuery( document ).off( 'click', unselectFieldGroups ); - maybeRemoveMultiselectPopup(); - } - - function maybeRemoveMultiselectPopup() { - const popup = document.getElementById( 'frm_field_multiselect_popup' ); - if ( null !== popup ) { - popup.remove(); - } - } - - function addFieldMultiselectPopup() { - getFieldMultiselectPopup(); - } - - function getFieldMultiselectPopup() { - let popup, mergeOption, caret, verticalSeparator, deleteOption; - - popup = document.getElementById( 'frm_field_multiselect_popup' ); - - if ( null !== popup ) { - popup.classList.toggle( 'frm-unmergable', ! selectedFieldsAreMergeable() ); - return popup; - } - - popup = div(); - popup.id = 'frm_field_multiselect_popup'; - if ( ! selectedFieldsAreMergeable() ) { - popup.classList.add( 'frm-unmergable' ); - } - - mergeOption = div(); - mergeOption.classList.add( 'frm-merge-fields-into-row' ); - mergeOption.textContent = __( 'Merge into row', 'formidable' ); - - caret = document.createElement( 'a' ); - caret.style.marginLeft = '5px'; - caret.classList.add( 'frm_icon_font', 'frm_arrowdown6_icon' ); - caret.setAttribute( 'href', '#' ); - mergeOption.appendChild( caret ); - - popup.appendChild( mergeOption ); - - verticalSeparator = div(); - verticalSeparator.classList.add( 'frm-multiselect-popup-separator' ); - popup.appendChild( verticalSeparator ); - - deleteOption = div(); - deleteOption.classList.add( 'frm-delete-field-groups' ); - deleteOption.appendChild( getIconClone( 'frm_trash_svg' ) ); - popup.appendChild( deleteOption ); - - document.getElementById( 'post-body-content' ).appendChild( popup ); - - jQuery( popup ).hide().fadeIn(); - - return popup; - } - - function selectedFieldsAreMergeable() { - let selectedFieldGroups, totalFieldCount, length, index, fieldGroup; - selectedFieldGroups = document.querySelectorAll( '.frm-selected-field-group' ); - length = selectedFieldGroups.length; - if ( 1 === length ) { - return false; - } - totalFieldCount = 0; - for ( index = 0; index < length; ++index ) { - fieldGroup = selectedFieldGroups[ index ]; - if ( null !== fieldGroup.querySelector( '.edit_field_type_break, .edit_field_type_hidden' ) ) { - return false; - } - totalFieldCount += getFieldsInRow( jQuery( fieldGroup ) ).length; - if ( totalFieldCount > 6 ) { - return false; - } - } - return true; - } - - function mergeFieldsIntoRowClick( event ) { - let size, popup; - - if ( null !== event.originalEvent.target.closest( '#frm_field_group_popup' ) ) { - // prevent clicks within the popup from triggering the button again. - return; - } - - if ( event.originalEvent.target.classList.contains( 'frm-custom-field-group-layout' ) ) { - // avoid switching back to the first page when clicking the custom option nested inside of the merge option. - return; - } - - size = getSelectedFieldCount(); - popup = getFieldGroupPopup( size, document.querySelector( '.frm-selected-field-group' ).firstChild ); - this.appendChild( popup ); - } - - function getSelectedFieldCount() { - let count = 0; - jQuery( document.querySelectorAll( '.frm-selected-field-group' ) ).each( - function() { - count += getFieldsInRow( jQuery( this ) ).length; - } - ); - return count; - } - - function deleteFieldGroupsClick() { - let fieldIdsToDelete, deleteOnConfirm, multiselectPopup; - - fieldIdsToDelete = getSelectedFieldIds(); - deleteOnConfirm = getDeleteSelectedFieldGroupsOnConfirmFunction( fieldIdsToDelete ); - - multiselectPopup = document.getElementById( 'frm_field_multiselect_popup' ); - if ( null !== multiselectPopup ) { - multiselectPopup.remove(); - } - - this.setAttribute( 'data-frmverify', confirmFieldsDeleteMessage( fieldIdsToDelete.length ) ); - confirmLinkClick( this ); - - const confirmedClick = document.getElementById( 'frm-confirmed-click' ); - - // Remove any previous delete field data so delete confirmation does not attempt - // to delete a field that was already deleted or previously attempted and cancelled. - confirmedClick?.removeAttribute( 'data-deletefield' ); - - jQuery( confirmedClick ).on( 'click', deleteOnConfirm ); - jQuery( '#frm_confirm_modal' ).one( 'dialogclose', function() { - jQuery( confirmedClick ).off( 'click', deleteOnConfirm ); - }); - } - - function getSelectedFieldIds() { - const deleteFieldIds = []; - jQuery( '.frm-selected-field-group > li.form-field' ) - .each( - function() { - deleteFieldIds.push( this.dataset.fid ); - } - ); - return deleteFieldIds; - } - - function getDeleteSelectedFieldGroupsOnConfirmFunction( deleteFieldIds ) { - return function( event ) { - event.preventDefault(); - deleteAllSelectedFieldGroups( deleteFieldIds ); - }; - } - - function deleteAllSelectedFieldGroups( deleteFieldIds ) { - deleteFieldIds.forEach( - function( fieldId ) { - deleteFields( fieldId ); - } - ); - } - - function deleteFieldConfirmed() { - /*jshint validthis:true */ - deleteFields( this.getAttribute( 'data-deletefield' ) ); - } - - function deleteFields( fieldId ) { - const field = jQuery( '#frm_field_id_' + fieldId ); - - deleteField( fieldId ); - - if ( field.hasClass( 'edit_field_type_divider' ) ) { - field.find( 'li.frm_field_box' ).each( function() { - //TODO: maybe delete only end section - //if(n.hasClass('edit_field_type_end_divider')){ - deleteField( this.getAttribute( 'data-fid' ) ); - //} - }); - } - toggleSectionHolder(); - } - - /** - * Checks if there is only submit field in the form builder. - * - * @return {Boolean} - */ - function hasOnlySubmitField() { - // If there are at least 2 rows, return false. - if ( $newFields.get( 0 ).childElementCount > 1 ) { - return false; - } - - const childUl = $newFields.get( 0 ).firstElementChild.firstElementChild; - - // Use query instead of children because there might be a div inside this ul. - const childLi = childUl.querySelectorAll( 'li.frm_field_box' ); - - // If there are at least 2 items in the row, return false. - if ( childLi.length > 1 ) { - return false; - } - - return childLi[0].classList.contains( 'edit_field_type_submit' ); - } - - /** - * Moves open modals out of the field options form. - * - * When a modal is open, it is moved in the DOM and appended to the parent element of the modal trigger input. That - * creates a problem since deleting the field also deletes the modal and this function fixes that problem. - * - * @since 6.22 - * - * @param {Object} settings - * @returns {void} - */ - function moveOpenModalsOutOfFieldOptions( settings ) { - const openModals = settings[0].querySelectorAll( '.frm-inline-modal[data-fills]' ); - if ( ! openModals.length ) { - return; - } - openModals.forEach( modal => { - modal.classList.add( 'frm_hidden' ); - modal.removeAttribute( 'data-fills' ); - modal.closest( 'form' ).appendChild( modal ); - }); - } - - function deleteField( fieldId ) { - jQuery.ajax({ - type: 'POST', - url: ajaxurl, - data: { - action: 'frm_delete_field', - field_id: fieldId, - nonce: frmGlobal.nonce - }, - success: function() { - const $thisField = jQuery( document.getElementById( 'frm_field_id_' + fieldId ) ), - settings = jQuery( '#frm-single-settings-' + fieldId ); - - // Remove settings from sidebar. - if ( settings.is( ':visible' ) ) { - document.getElementById( 'frm_insert_fields_tab' ).click(); - } - - moveOpenModalsOutOfFieldOptions( settings ); - settings.remove(); - - $thisField.fadeOut( 'slow', function() { - let $section = $thisField.closest( '.start_divider' ), - type = $thisField.data( 'type' ), - $adjacentFields = $thisField.siblings( 'li.form-field' ), - $liWrapper; - - if ( ! $adjacentFields.length ) { - if ( $thisField.is( '.edit_field_type_end_divider' ) ) { - $adjacentFields.length = $thisField.closest( 'li.form-field' ).siblings(); - } else { - $liWrapper = $thisField.closest( 'ul.frm_sorting' ).parent(); - } - } - - $thisField.remove(); - if ( type === 'break' ) { - renumberPageBreaks(); - } else if ( type === 'product' ) { - maybeHideQuantityProductFieldOption(); - // a product field attached to a quantity field earlier might be the one deleted, so re-populate - popAllProductFields(); - } - - if ( $adjacentFields.length ) { - syncLayoutClasses( $adjacentFields.first() ); - } else { - $liWrapper.remove(); - } - - if ( jQuery( '#frm-show-fields li' ).length === 0 || hasOnlySubmitField() ) { - const formEditorContainer = document.getElementById( 'frm_form_editor_container' ); - formEditorContainer.classList.remove( 'frm-has-fields' ); - formEditorContainer.classList.add( 'frm-empty-fields' ); - } else if ( $section.length ) { - toggleOneSectionHolder( $section ); - } - - // prevent "More Options" tooltips from staying around after their target field is deleted. - deleteTooltips(); - }); - - if ( $thisField.length ) { - wp.hooks.doAction( 'frm_after_delete_field', $thisField[0] ); - } - } - }); - } - - function addFieldLogicRow() { - /*jshint validthis:true */ - const id = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ), - formId = thisFormId, - logicRows = document.getElementById( 'frm_logic_row_' + id ).querySelectorAll( '.frm_logic_row' ); - jQuery.ajax({ - type: 'POST', - url: ajaxurl, - data: { - action: 'frm_add_logic_row', - form_id: formId, - field_id: id, - nonce: frmGlobal.nonce, - meta_name: getNewRowId( logicRows, 'frm_logic_' + id + '_' ), - fields: getFieldList() - }, - success: function( html ) { - jQuery( document.getElementById( 'logic_' + id ) ).fadeOut( 'slow', function() { - const logicRow = jQuery( document.getElementById( 'frm_logic_row_' + id ) ); - logicRow.append( html ); - logicRow.closest( '.frm_logic_rows' ).fadeIn( 'slow' ); - }); - } - }); - return false; - } - - function getNewRowId( rows, replace, defaultValue ) { - if ( ! rows.length ) { - return 'undefined' !== typeof defaultValue ? defaultValue : 0; - } - return parseInt( rows[ rows.length - 1 ].id.replace( replace, '' ), 10 ) + 1; - } - - function addWatchLookupRow() { - /*jshint validthis:true */ - let lastRowId, - id = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ), - formId = thisFormId, - lookupBlockRows = document.getElementById( 'frm_watch_lookup_block_' + id ).children; - jQuery.ajax({ - type: 'POST', - url: ajaxurl, - data: { - action: 'frm_add_watch_lookup_row', - form_id: formId, - field_id: id, - row_key: getNewRowId( lookupBlockRows, 'frm_watch_lookup_' + id + '_' ), - nonce: frmGlobal.nonce - }, - success: function( newRow ) { - const watchRowBlock = jQuery( document.getElementById( 'frm_watch_lookup_block_' + id ) ); - watchRowBlock.append( newRow ); - watchRowBlock.fadeIn( 'slow' ); - } - }); - return false; - } - - function resetOptionTextDetails() { - jQuery( '.frm-single-settings ul input[type="text"][name^="field_options[options_"]' ).filter( '[data-value-on-load]' ).removeAttr( 'data-value-on-load' ); - jQuery( 'input[type="hidden"][name^=optionmap]' ).remove(); - } - - function optionTextAlreadyExists( input ) { - let fieldId = jQuery( input ).closest( '.frm-single-settings' ).attr( 'data-fid' ), - optionInputs = jQuery( input ).closest( 'ul' ).get( 0 ).querySelectorAll( '.field_' + fieldId + '_option' ), - index, - optionInput; - - for ( index in optionInputs ) { - optionInput = optionInputs[ index ]; - if ( optionInput.id !== input.id && optionInput.value === input.value && optionInput.getAttribute( 'data-duplicate' ) !== 'true' ) { - return true; - } - } - - return false; - } - - function onOptionTextFocus() { - let input, - fieldId; - - if ( this.getAttribute( 'data-value-on-load' ) === null ) { - this.setAttribute( 'data-value-on-load', this.value ); - - fieldId = jQuery( this ).closest( '.frm-single-settings' ).attr( 'data-fid' ); - input = document.createElement( 'input' ); - input.value = this.value; - input.setAttribute( 'type', 'hidden' ); - input.setAttribute( 'name', 'optionmap[' + fieldId + '][' + this.value + ']' ); - this.parentNode.appendChild( input ); - - if ( typeof optionMap[ fieldId ] === 'undefined' ) { - optionMap[ fieldId ] = {}; - } - - optionMap[ fieldId ][ this.value ] = input; - } - - if ( this.getAttribute( 'data-duplicate' ) === 'true' ) { - this.removeAttribute( 'data-duplicate' ); - - // we want to use original value if actually still a duplicate - if ( optionTextAlreadyExists( this ) ) { - this.setAttribute( 'data-value-on-focus', this.getAttribute( 'data-value-on-load' ) ); - return; - } - } - - if ( '' !== this.value || frmAdminJs.new_option !== this.getAttribute( 'data-value-on-focus' ) ) { - this.setAttribute( 'data-value-on-focus', this.value ); - } - } - - /** - * Returns an object that has the old and new values and labels, when a field choice is changed. - * - * @param {HTMLElement} input - * @returns {Object} - */ - function getChoiceOldAndNewValues( input ) { - const { oldValue, oldLabel } = getChoiceOldValueAndLabel( input ); - const { newValue, newLabel } = getChoiceNewValueAndLabel( input ); - - return { oldValue, oldLabel, newValue, newLabel }; - } - - /** - * Returns an object that has the new value and label, when a field choice is changed. - * - * @param {HTMLElement} choiceElement - * @returns {Object} - */ - function getChoiceNewValueAndLabel( choiceElement ) { - const singleOptionContainer = choiceElement.closest( '.frm_single_option' ); - - let newValue, newLabel; - - if ( choiceElement.parentElement.classList.contains( 'frm_single_option' ) ) { // label changed - newValue = singleOptionContainer.querySelector( '.frm_option_key input[type="text"]' ).value; - newLabel = choiceElement.value; - return { newValue, newLabel }; - } - - // saved value changed - newLabel = singleOptionContainer.querySelector( 'input[type="text"]' ).value; - newValue = choiceElement.value; - return { newValue, newLabel }; - } - - /** - * Returns an object that has the old value and label, when a field choice is changed. - * - * @param {HTMLElement} choiceElement - * @returns {Object} - */ - function getChoiceOldValueAndLabel( choiceElement ) { - const usingSeparateValues = choiceElement.closest( '.frm-single-settings' ).querySelector( '.frm_toggle_sep_values' )?.checked ?? false; - const singleOptionContainer = choiceElement.closest( '.frm_single_option' ); - - let oldValue, oldLabel; - - if ( usingSeparateValues ) { - if ( choiceElement.parentElement.classList.contains( 'frm_single_option' ) ) { // label changed - oldValue = singleOptionContainer.querySelector( '.frm_option_key input[type="text"]' ).getAttribute( 'data-value-on-focus' ); - oldLabel = choiceElement.getAttribute( 'data-value-on-focus' ); - return { oldValue, oldLabel }; - } - } - oldValue = choiceElement.getAttribute( 'data-value-on-focus' ); - oldLabel = singleOptionContainer.querySelector( 'input[type="text"]' ).getAttribute( 'data-value-on-focus' ); - - return { oldValue, oldLabel }; - } - - function onOptionTextBlur() { - let originalValue, - fieldId, - fieldIndex, - logicId, - row, - rowLength, - rowIndex, - valueSelect, - opts, - fieldIds, - settingId, - setting, - optionMatches, - option; - - const { oldValue, oldLabel, newValue, newLabel } = getChoiceOldAndNewValues( this ); - - if ( oldValue === newValue && oldLabel === newLabel ) { - return; - } - - const singleSettingsContainer = this.closest( '.frm-single-settings' ); - - fieldId = singleSettingsContainer.getAttribute( 'data-fid' ); - originalValue = this.getAttribute( 'data-value-on-load' ); - - // check if the newValue is already mapped to another option - // if it is, mark as duplicate and return - if ( optionTextAlreadyExists( this ) ) { - this.setAttribute( 'data-duplicate', 'true' ); - - if ( typeof optionMap[ fieldId ] !== 'undefined' && typeof optionMap[ fieldId ][ originalValue ] !== 'undefined' ) { - // unmap any other change that may have happened before instead of changing it to something unused - optionMap[ fieldId ][ originalValue ].value = originalValue; - } - - return; - } - - if ( typeof optionMap[ fieldId ] !== 'undefined' && typeof optionMap[ fieldId ][ originalValue ] !== 'undefined' ) { - optionMap[ fieldId ][ originalValue ].value = newValue; - } - - fieldIds = []; - rows = builderPage.querySelectorAll( '.frm_logic_row' ); - rowLength = rows.length; - for ( rowIndex = 0; rowIndex < rowLength; rowIndex++ ) { - row = rows[ rowIndex ]; - opts = row.querySelector( '.frm_logic_field_opts' ); - - if ( opts.value !== fieldId ) { - continue; - } - - logicId = row.id.split( '_' )[ 2 ]; - valueSelect = row.querySelector( 'select[name="field_options[hide_opt_' + logicId + '][]"]' ); - - if ( '' === oldValue ) { - optionMatches = []; - } else { - optionMatches = valueSelect.querySelectorAll( 'option[value="' + oldValue + '"]' ); - } - - if ( ! optionMatches.length ) { - optionMatches = valueSelect.querySelectorAll( 'option[value="' + newValue + '"]' ); - - if ( ! optionMatches.length ) { - if ( ! singleSettingsContainer.querySelector( '.frm_toggle_sep_values' )?.checked ) { - option = searchSelectByText( valueSelect, oldValue ); // Find conditional logic option with oldValue - } - - if ( ! option ) { - option = document.createElement( 'option' ); - valueSelect.appendChild( option ); - } - } - } - - if ( optionMatches.length ) { - option = optionMatches[ optionMatches.length - 1 ]; - } - - option.setAttribute( 'value', newValue ); - option.textContent = newLabel; - - if ( fieldIds.indexOf( logicId ) === -1 ) { - fieldIds.push( logicId ); - } - } - - for ( fieldIndex in fieldIds ) { - settingId = fieldIds[ fieldIndex ]; - setting = document.getElementById( 'frm-single-settings-' + settingId ); - moveFieldSettings( setting ); - } - } - - /** - * Returns an option element that matches a string with its text content. - * - * @param {HTMLElement} selectElement - * @param {string} searchText - * @returns {HTMLElement|null} - */ - function searchSelectByText( selectElement, searchText ) { - const options = selectElement.options; - - for ( let i = 0; i < options.length; i++ ) { - const option = options[i]; - if ( searchText === option.textContent ) { - return option; - } - } - - return null; - } - - function updateGetValueFieldSelection() { - /*jshint validthis:true */ - const fieldID = this.id.replace( 'get_values_form_', '' ); - const fieldSelect = document.getElementById( 'get_values_field_' + fieldID ); - const fieldType = this.getAttribute( 'data-fieldtype' ); - - if ( this.value === '' ) { - fieldSelect.options.length = 1; - } else { - const formID = this.value; - jQuery.ajax({ - type: 'POST', url: ajaxurl, - data: { - action: 'frm_get_options_for_get_values_field', - form_id: formID, - field_type: fieldType, - nonce: frmGlobal.nonce - }, - success: function( fields ) { - fieldSelect.innerHTML = fields; - } - }); - } - } - - // Clear the Watch Fields option when Lookup field switches to "Text" option - function maybeClearWatchFields() { - /*jshint validthis:true */ - let link, lookupBlock, - fieldID = this.name.replace( 'field_options[data_type_', '' ).replace( ']', '' ); - - link = document.getElementById( 'frm_add_watch_lookup_link_' + fieldID ); - if ( ! link ) { - return; - } - link = link.parentNode; - - if ( this.value === 'text' ) { - lookupBlock = document.getElementById( 'frm_watch_lookup_block_' + fieldID ); - if ( lookupBlock !== null ) { - // Clear and hide the Watch Fields option - lookupBlock.innerHTML = ''; - link.classList.add( 'frm_hidden' ); - - // Hide the Watch Fields row - link.previousElementSibling.style.display = 'none'; - link.previousElementSibling.previousElementSibling.style.display = 'none'; - link.previousElementSibling.previousElementSibling.previousElementSibling.style.display = 'none'; - } - } else { - // Show the Watch Fields option - link.classList.remove( 'frm_hidden' ); - } - - toggleMultiSelect( fieldID, this.value ); - } - - // Number the pages and hide/show the first page as needed. - function renumberPageBreaks() { - let i, containerClass, - pages = document.getElementsByClassName( 'frm-page-num' ); - - if ( pages.length > 1 ) { - document.getElementById( 'frm-fake-page' ).style.display = 'block'; - for ( i = 0; i < pages.length; i++ ) { - containerClass = pages[i].parentNode.parentNode.parentNode.classList; - if ( i === 1 ) { - // Hide previous button on page 1 - containerClass.add( 'frm-first-page' ); - } else { - containerClass.remove( 'frm-first-page' ); - } - pages[i].textContent = ( i + 1 ); - } - } else { - document.getElementById( 'frm-fake-page' ).style.display = 'none'; - } - - wp.hooks.doAction( 'frm_renumber_page_breaks', pages ); - } - - // The fake field works differently than real fields. - function maybeCollapsePage() { - /*jshint validthis:true */ - const field = jQuery( this ).closest( '.frm_field_box[data-ftype=break]' ); - if ( field.length ) { - toggleCollapsePage( field ); - } else { - toggleCollapseFakePage(); - } - } - - // Find all fields in a page and hide/show them - function toggleCollapsePage( field ) { - const toCollapse = getAllFieldsForPage( field.get( 0 ).parentNode.closest( 'li.frm_field_box' ).nextElementSibling ); - togglePage( field, toCollapse ); - } - - function toggleCollapseFakePage() { - const topLevel = document.getElementById( 'frm-fake-page' ), - firstField = document.getElementById( 'frm-show-fields' ).firstElementChild, - toCollapse = getAllFieldsForPage( firstField ); - - if ( firstField.getAttribute( 'data-ftype' ) === 'break' ) { - // Don't collapse if the first field is a page break. - return; - } - - togglePage( jQuery( topLevel ), toCollapse ); - } - - function getAllFieldsForPage( firstWrapper ) { - let $fieldsForPage, currentWrapper; - - $fieldsForPage = jQuery(); - - if ( null === firstWrapper ) { - return $fieldsForPage; - } - - currentWrapper = firstWrapper; - - do { - if ( null !== currentWrapper.querySelector( '.edit_field_type_break' ) ) { - break; - } - $fieldsForPage = $fieldsForPage.add( jQuery( currentWrapper ) ); - currentWrapper = currentWrapper.nextElementSibling; - } while ( null !== currentWrapper ); - - return $fieldsForPage; - } - - function togglePage( field, toCollapse ) { - let i, - fieldCount = toCollapse.length, - slide = Math.min( fieldCount, 3 ); - - if ( field.hasClass( 'frm-page-collapsed' ) ) { - field.removeClass( 'frm-page-collapsed' ); - toCollapse.removeClass( 'frm-is-collapsed' ); - for ( i = 0; i < slide; i++ ) { - if ( i === slide - 1 ) { - jQuery( toCollapse[ i ]).slideDown( 150, function() { - toCollapse.show(); - }); - } else { - jQuery( toCollapse[ i ]).slideDown( 150 ); - } - } - } else { - field.addClass( 'frm-page-collapsed' ); - toCollapse.addClass( 'frm-is-collapsed' ); - for ( i = 0; i < slide; i++ ) { - if ( i === slide - 1 ) { - jQuery( toCollapse[ i ]).slideUp( 150, function() { - toCollapse.css( 'cssText', 'display:none !important;' ); - }); - } else { - jQuery( toCollapse[ i ]).slideUp( 150 ); - } - } - } - } - - function maybeCollapseSection() { - /*jshint validthis:true */ - const parentCont = this.parentNode.parentNode.parentNode.parentNode; - - parentCont.classList.toggle( 'frm-section-collapsed' ); - } - - function maybeCollapseSettings() { - /*jshint validthis:true */ - this.classList.toggle( 'frm-collapsed' ); - - // Toggles the "aria-expanded" attribute - const expanded = this.getAttribute( 'aria-expanded' ) === 'true' || false; - this.setAttribute( 'aria-expanded', ! expanded ); - } - - function clickLabel() { - if ( ! this.id ) { - return; - } - - /*jshint validthis:true */ - let setting = document.querySelectorAll( '[data-changeme="' + this.id + '"]' )[0], - fieldId = this.id.replace( 'field_label_', '' ), - fieldType = document.getElementById( 'field_options_type_' + fieldId ), - fieldTypeName = fieldType.value; - - if ( typeof setting !== 'undefined' ) { - if ( fieldType.tagName === 'SELECT' ) { - fieldTypeName = fieldType.options[ fieldType.selectedIndex ].text.toLowerCase(); - } else { - fieldTypeName = fieldTypeName.replace( '_', ' ' ); - } - - fieldTypeName = normalizeFieldName( fieldTypeName ); - - setTimeout( function() { - if ( setting.value.toLowerCase() === fieldTypeName ) { - setting.select(); - } else { - setting.focus(); - } - }, 50 ); - } - } - - function clickDescription() { - /*jshint validthis:true */ - const setting = document.querySelectorAll( '[data-changeme="' + this.id + '"]' )[0]; - if ( typeof setting !== 'undefined' ) { - setTimeout( function() { - setting.focus(); - autoExpandSettings( setting ); - }, 50 ); - } - } - - function autoExpandSettings( setting ) { - const inSection = setting.closest( '.frm-collapse-me' ); - if ( inSection !== null ) { - inSection.previousElementSibling.classList.remove( 'frm-collapsed' ); - } - } - - function normalizeFieldName( fieldTypeName ) { - if ( fieldTypeName === 'divider' ) { - fieldTypeName = 'section'; - } else if ( fieldTypeName === 'range' ) { - fieldTypeName = 'slider'; - } else if ( fieldTypeName === 'data' ) { - fieldTypeName = 'dynamic'; - } else if ( fieldTypeName === 'form' ) { - fieldTypeName = 'embed form'; - } - return fieldTypeName; - } - - function clickVis( e ) { - /*jshint validthis:true */ - let currentClass, originalList; - - currentClass = e.target.classList; - - if ( currentClass.contains( 'frm-collapse-page' ) || currentClass.contains( 'frm-sub-label' ) || e.target.closest( '.dropdown' ) !== null ) { - return; - } - - if ( this.closest( '.start_divider' ) !== null ) { - e.stopPropagation(); - } - - if ( this.classList.contains( 'edit_field_type_divider' ) ) { - originalList = e.originalEvent.target.closest( 'ul.frm_sorting' ); - if ( null !== originalList ) { - // prevent section click if clicking a field group within a section. - if ( originalList.classList.contains( 'edit_field_type_divider' ) || originalList.parentNode.parentNode.classList.contains( 'start_divider' ) ) { - return; - } - } - } - - clickAction( this ); - } - - /** - * Update the format input based on the selected format type. - * - * @since 6.9 - * - * @param {Event} event The event object from the format type selection. - * @return {void} - */ - function maybeUpdateFormatInput( event ) { - const formatElement = event.target; - const type = formatElement.value - - if ( 'custom' === type ) { - const fieldId = formatElement.dataset.fieldId; - const formatInput = document.getElementById( `frm-field-format-custom-${fieldId}` ).querySelector( '.frm_format_opt' ); - - if ( 'international' === formatInput.value || 'currency' === formatInput.value || 'number' === formatInput.value ) { - formatInput.setAttribute( 'value', '' ); - } - } - - setTimeout( - () => { - formatElement.querySelectorAll( 'option' ).forEach( - option => { - if ( option.selected && option.classList.contains( 'frm_show_upgrade' ) ) { - formatElement.value = 'none'; - } - } - ); - }, - 0 - ); - } - - /** - * Open Advanced settings on double click. - */ - function openAdvanced() { - const fieldId = this.getAttribute( 'data-fid' ); - autoExpandSettings( document.getElementById( 'field_options_field_key_' + fieldId ) ); - } - - function toggleRepeatButtons() { - /*jshint validthis:true */ - const $thisField = jQuery( this ).closest( '.frm_field_box' ); - $thisField.find( '.repeat_icon_links' ).removeClass( 'repeat_format repeat_formatboth repeat_formattext' ).addClass( 'repeat_format' + this.value ); - if ( this.value === 'text' || this.value === 'both' ) { - $thisField.find( '.frm_repeat_text' ).show(); - $thisField.find( '.repeat_icon_links a' ).addClass( 'frm_button' ); - } else { - $thisField.find( '.frm_repeat_text' ).hide(); - $thisField.find( '.repeat_icon_links a' ).removeClass( 'frm_button' ); - } - } - - function checkRepeatLimit() { - /*jshint validthis:true */ - const val = this.value; - if ( val !== '' && ( val < 2 || val > 200 ) ) { - infoModal( frmAdminJs.repeat_limit_min ); - this.value = ''; - } - } - - function checkCheckboxSelectionsLimit() { - /*jshint validthis:true */ - const val = this.value; - if ( val !== '' && ( val < 1 || val > 200 ) ) { - infoModal( frmAdminJs.checkbox_limit ); - this.value = ''; - } - } - - function updateRepeatText( obj, addRemove ) { - const $thisField = jQuery( obj ).closest( '.frm_field_box' ); - $thisField.find( '.frm_' + addRemove + '_form_row .frm_repeat_label' ).text( obj.value ); - } - - function fieldsInSection( id ) { - const children = []; - jQuery( document.getElementById( 'frm_field_id_' + id ) ).find( 'li.frm_field_box:not(.no_repeat_section .edit_field_type_end_divider)' ).each( function() { - children.push( jQuery( this ).data( 'fid' ) ); - }); - return children; - } - - function toggleFormTax() { - /*jshint validthis:true */ - const id = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ); - const val = this.value; - const $showFields = document.getElementById( 'frm_show_selected_fields_' + id ); - const $showForms = document.getElementById( 'frm_show_selected_forms_' + id ); - - jQuery( $showForms ).find( 'select' ).val( '' ); - if ( val === 'form' ) { - $showForms.style.display = 'inline'; - empty( $showFields ); - } else { - $showFields.style.display = 'none'; - $showForms.style.display = 'none'; - getTaxOrFieldSelection( val, id ); - } - - } - - function resetOptOnChange() { - /*jshint validthis:true */ - let field, thisOpt; - - field = getFieldKeyFromOpt( this ); - if ( ! field ) { - return; - } - - thisOpt = jQuery( this ).closest( '.frm_single_option' ); - - resetSingleOpt( field.fieldId, field.fieldKey, thisOpt ); - } - - function getFieldKeyFromOpt( object ) { - let allOpts, fieldId, fieldKey; - - allOpts = jQuery( object ).closest( '.frm_sortable_field_opts' ); - if ( ! allOpts.length ) { - return false; - } - - fieldId = allOpts.attr( 'id' ).replace( 'frm_field_', '' ).replace( '_opts', '' ); - fieldKey = allOpts.data( 'key' ); - - return { - fieldId: fieldId, - fieldKey: fieldKey - }; - } - - function resetSingleOpt( fieldId, fieldKey, thisOpt ) { - let saved, text, defaultVal, previewInput, labelForDisplay, optContainer, - optKey = thisOpt.data( 'optkey' ), - separateValues = usingSeparateValues( fieldId ), - single = jQuery( 'label[for="field_' + fieldKey + '-' + optKey + '"]' ), - baseName = 'field_options[options_' + fieldId + '][' + optKey + ']', - label = jQuery( 'input[name="' + baseName + '[label]"]' ); - - if ( single.length < 1 ) { - resetDisplayedOpts( fieldId ); - - // Set the default value. - defaultVal = thisOpt.find( 'input[name^="default_value_"]' ); - if ( defaultVal.is( ':checked' ) && label.length > 0 ) { - jQuery( 'select[name^="item_meta[' + fieldId + ']"]' ).val( label.val() ); - } - return; - } - - previewInput = single.children( 'input' ); - - if ( label.length < 1 ) { - // Check for other label. - label = jQuery( 'input[name="' + baseName + '"]' ); - saved = label.val(); - } else if ( separateValues ) { - saved = jQuery( 'input[name="' + baseName + '[value]"]' ).val(); - } else { - saved = label.val(); - } - - if ( label.length < 1 ) { - return; - } - - // Set the displayed value. - text = single[0].childNodes; - - if ( imagesAsOptions( fieldId ) ) { - labelForDisplay = getImageDisplayValue( thisOpt, fieldId, label ); - optContainer = single.find( '.frm_image_option_container' ); - - if ( optContainer.length > 0 ) { - optContainer.replaceWith( labelForDisplay ); - } else { - text[ text.length - 1 ].nodeValue = ''; - single.append( labelForDisplay ); - } - } else { - let firstInputIndex = false; - text.forEach( ( node, index ) => { - if ( firstInputIndex === false ) { - if ( node.tagName === 'INPUT' ) { - firstInputIndex = index; - } - } else if ( index === firstInputIndex + 1 ) { - let nodeValue = ''; - - if ( buttonsAsOptions( fieldId ) ) { - nodeValue = div({ className: 'frm_label_button_container', text: ' ' + label.val() }); - single[0].replaceChild( nodeValue, node ); - } else { - node.nodeValue = ' ' + label.val(); - } - } else { - single[0].removeChild( node ); - } - }); - } - - // Set saved value. - previewInput.val( saved ); - - // Set the default value. - defaultVal = thisOpt.find( 'input[name^="default_value_"]' ); - previewInput.prop( 'checked', defaultVal.is( ':checked' ) ? true : false ); - } - - function buttonsAsOptions( fieldId ) { - const fields = document.getElementsByName( 'field_options[image_options_' + fieldId + ']' ); - const result = Array.from( fields ).find( field => field.checked && ( 'buttons' === field.value ) ); - - return typeof result !== 'undefined'; - } - - /** - * Set the displayed value for an image option. - */ - function getImageDisplayValue( thisOpt, fieldId, label ) { - let image, imageUrl, showLabelWithImage, fieldType; - - image = thisOpt.find( 'img' ); - if ( image ) { - imageUrl = image.attr( 'src' ); - } - - showLabelWithImage = showingLabelWithImage( fieldId ); - fieldType = radioOrCheckbox( fieldId ); - return getImageLabel( label.val(), showLabelWithImage, imageUrl, fieldType ); - } - - function getImageOptionSize( fieldId ) { - let val, - field = document.getElementById( 'field_options_image_size_' + fieldId ), - size = ''; - - if ( field !== null ) { - val = field.value; - if ( val !== '' ) { - size = val; - } - } - - return size; - } - - function resetDisplayedOpts( fieldId ) { - let i, opts, type, placeholder, fieldInfo, - input = jQuery( '[name^="item_meta[' + fieldId + ']"]' ); - - if ( input.length < 1 ) { - return; - } - - if ( input.is( 'select' ) ) { - placeholder = document.getElementById( 'frm_placeholder_' + fieldId ); - if ( placeholder !== null && placeholder.value === '' ) { - fillDropdownOpts( input[0], { sourceID: fieldId }); - } else { - fillDropdownOpts( input[0], { - sourceID: fieldId, - placeholder: placeholder.value - }); - } - } else { - opts = getMultipleOpts( fieldId ); - jQuery( '#field_' + fieldId + '_inner_container > .frm_form_fields' ).html( '' ); - fieldInfo = getFieldKeyFromOpt( jQuery( '#frm_delete_field_' + fieldId + '-000_container' ) ); - - const container = jQuery( '#field_' + fieldId + '_inner_container > .frm_form_fields' ), - hasImageOptions = imagesAsOptions( fieldId ), - imageSize = hasImageOptions ? getImageOptionSize( fieldId ) : '', - imageOptionClass = hasImageOptions ? ( 'frm_image_option frm_image_' + imageSize + ' ' ) : '', - isProduct = isProductField( fieldId ); - - type = ( 'hidden' === input.attr( 'type' ) ? input.data( 'field-type' ) : input.attr( 'type' ) ); - for ( i = 0; i < opts.length; i++ ) { - container.append( addRadioCheckboxOpt( type, opts[ i ], fieldId, fieldInfo.fieldKey, isProduct, imageOptionClass ) ); - } - } - - adjustConditionalLogicOptionOrders( fieldId ); - } - - /** - * Returns an object that has a value and label for new conditional logic option, for a given option value. - * - * @param {Number} fieldId - * @param {string} expectedOption - * @returns {Object} - */ - function getNewConditionalLogicOption( fieldId, expectedOption ) { - const optionsContainer = document.getElementById( 'frm_field_' + fieldId + '_opts' ); - - const expectedOptionInput = optionsContainer.querySelector( 'input[value="' + expectedOption + '"]' ); - - if ( expectedOptionInput ) { - return getChoiceNewValueAndLabel( expectedOptionInput ); - } - - return { newValue: expectedOption, newLabel: expectedOption }; - } - - function adjustConditionalLogicOptionOrders( fieldId, type ) { - let row, opts, logicId, valueSelect, optionLength, optionIndex, expectedOption, optionMatch, fieldOptions, - rows = builderPage.querySelectorAll( '.frm_logic_row' ), - rowLength = rows.length; - - fieldOptions = wp.hooks.applyFilters( 'frm_conditional_logic_field_options', getFieldOptions( fieldId ), { type, fieldId }); - optionLength = fieldOptions.length; - - for ( rowIndex = 0; rowIndex < rowLength; rowIndex++ ) { - row = rows[ rowIndex ]; - opts = row.querySelector( '.frm_logic_field_opts' ); - - if ( opts.value != fieldId ) { - continue; - } - - logicId = row.id.split( '_' )[ 2 ]; - valueSelect = row.querySelector( 'select[name="field_options[hide_opt_' + logicId + '][]"]' ); - - for ( optionIndex = optionLength - 1; optionIndex >= 0; optionIndex-- ) { - expectedOption = fieldOptions[ optionIndex ]; - let expectedOptionValue = document.getElementById( 'frm_field_' + fieldId + '_opts' ).querySelector( '.frm_option_key input[type="text"]' )?.value; - if ( ! expectedOptionValue ) { - expectedOptionValue = expectedOption; - } - - optionMatch = valueSelect.querySelector( 'option[value="' + expectedOptionValue + '"]' ); - - const { newValue, newLabel } = getNewConditionalLogicOption( fieldId, expectedOption ); - - const fieldChoices = document.querySelectorAll( '#frm_field_' + fieldId + '_opts input[data-value-on-focus]' ); - const expectedChoiceEl = Array.from( fieldChoices ).find( element => element.value === expectedOption ); - if ( expectedChoiceEl ) { - const oldValue = expectedChoiceEl.dataset.valueOnFocus; - const hasMatch = oldValue && valueSelect.querySelector( 'option[value="' + oldValue + '"]' ); - if ( hasMatch ) { - continue; - } - } - prependValueSelectWithOptionMatch( valueSelect, optionMatch, newValue, newLabel ); - } - - optionMatch = valueSelect.querySelector( 'option[value=""]' ); - if ( optionMatch !== null ) { - valueSelect.prepend( optionMatch ); - } - } - } - - function prependValueSelectWithOptionMatch( valueSelect, optionMatch, newValue, newLabel ) { - if ( optionMatch === null && ! valueSelect.querySelector( 'option[value="' + newValue + '"]' )) { - optionMatch = frmDom.tag( 'option', { text: newLabel }); - optionMatch.value = newValue; - } - - valueSelect.prepend( optionMatch ); - } - - function getFieldOptions( fieldId ) { - let index, input, li, listItems, optsContainer, length, - options = []; - optsContainer = document.getElementById( 'frm_field_' + fieldId + '_opts' ); - - if ( ! optsContainer ) { - return options; - } - listItems = optsContainer.querySelectorAll( '.frm_single_option' ); - length = listItems.length; - - for ( index = 0; index < length; index++ ) { - li = listItems[ index ]; - - if ( li.classList.contains( 'frm_hidden' ) ) { - continue; - } - - input = li.querySelector( '.field_' + fieldId + '_option' ); - options.push( input.value ); - } - return options; - } - - function addRadioCheckboxOpt( type, opt, fieldId, fieldKey, isProduct, classes ) { - let other, - single = '', - isOther = opt.key.indexOf( 'other' ) !== -1, - id = 'field_' + fieldKey + '-' + opt.key, - inputType = type === 'scale' ? 'radio' : type; - - other = ''; - - this.getSingle = function() { - - /** - * Get single option template. - * @param {Object} option Object containing the option data. - * @param {string} type The field type. - * @param {string} fieldId The field id. - * @param {string} classes The option clasnames. - * @param {string} id The input id attribute. - */ - single = wp.hooks.applyFilters( 'frm_admin.build_single_option_template', single, { opt, type, fieldId, classes, id }); - - if ( '' !== single ) { - return single; - } - - return '
      ' + - ( isOther ? other : '' ) + - '
      '; - }; - - return this.getSingle(); - } - - function fillDropdownOpts( field, atts ) { - if ( field === null ) { - return; - } - const sourceID = atts.sourceID, - placeholder = atts.placeholder, - isProduct = isProductField( sourceID ), - showOther = atts.other; - - removeDropdownOpts( field ); - let opts = getMultipleOpts( sourceID ), - hasPlaceholder = ( typeof placeholder !== 'undefined' ); - - for ( let i = 0; i < opts.length; i++ ) { - let label = opts[ i ].label, - isOther = opts[ i ].key.indexOf( 'other' ) !== -1; - - if ( hasPlaceholder && label !== '' ) { - addBlankSelectOption( field, placeholder ); - } else if ( hasPlaceholder ) { - label = placeholder; - } - hasPlaceholder = false; - - if ( ! isOther || showOther ) { - const opt = document.createElement( 'option' ); - opt.value = opts[ i ].saved; - opt.innerHTML = purifyHtml( label ); - - if ( isProduct ) { - opt.setAttribute( 'data-price', opts[ i ].price ); - } - - field.appendChild( opt ); - } - } - } - - function addBlankSelectOption( field, placeholder ) { - const opt = document.createElement( 'option' ), - firstChild = field.firstChild; - - opt.value = ''; - opt.innerHTML = placeholder; - if ( firstChild !== null ) { - field.insertBefore( opt, firstChild ); - field.selectedIndex = 0; - } else { - field.appendChild( opt ); - } - } - - function getMultipleOpts( fieldId ) { - let i, saved, labelName, label, key, optObj, - fieldType, - checked = false, - opts = [], - imageUrl = ''; - - const optVals = jQuery( 'input[name^="field_options[options_' + fieldId + ']"]' ); - const isProduct = isProductField( fieldId ); - const showLabelWithImage = showingLabelWithImage( fieldId ); - const hasImageOptions = imagesAsOptions( fieldId ); - const separateValues = usingSeparateValues( fieldId ); - - for ( i = 0; i < optVals.length; i++ ) { - if ( optVals[ i ].name.indexOf( '[000]' ) > 0 || optVals[ i ].name.indexOf( '[value]' ) > 0 || optVals[ i ].name.indexOf( '[image]' ) > 0 || optVals[ i ].name.indexOf( '[price]' ) > 0 ) { - continue; - } - - saved = optVals[ i ].value; - label = saved; - key = optVals[ i ].name.replace( 'field_options[options_' + fieldId + '][', '' ).replace( '[label]', '' ).replace( ']', '' ); - - if ( separateValues ) { - labelName = optVals[ i ].name.replace( '[label]', '[value]' ); - saved = jQuery( 'input[name="' + labelName + '"]' ).val(); - } - - if ( hasImageOptions ) { - imageUrl = getImageUrlFromInput( optVals[i]); - fieldType = radioOrCheckbox( fieldId ); - label = getImageLabel( label, showLabelWithImage, imageUrl, fieldType ); - } - - /** - * @since 5.0.04 - */ - label = frmAdminBuild.hooks.applyFilters( 'frm_choice_field_label', label, fieldId, optVals[ i ], hasImageOptions ); - - checked = getChecked( optVals[ i ].id ); - - optObj = { - saved: saved, - label: label, - checked: checked, - key: key - }; - - if ( isProduct ) { - labelName = optVals[ i ].name.replace( '[label]', '[price]' ); - optObj.price = jQuery( 'input[name="' + labelName + '"]' ).val(); - } - - opts.push( optObj ); - } - - return opts; - } - - function radioOrCheckbox( fieldId ) { - const settings = document.getElementById( 'frm-single-settings-' + fieldId ); - if ( settings === null ) { - return 'radio'; - } - - return settings.classList.contains( 'frm-type-checkbox' ) ? 'checkbox' : 'radio'; - } - - function getImageUrlFromInput( optVal ) { - let img, - wrapper = jQuery( optVal ).siblings( '.frm_image_preview_wrapper' ); - - if ( ! wrapper.length ) { - return ''; - } - - img = wrapper.find( 'img' ); - if ( ! img.length ) { - return ''; - } - - return img.attr( 'src' ); - } - - function purifyHtml( html ) { - if ( html instanceof Element || html instanceof Document ) { - html = html.outerHTML; - } - - const clean = jQuery.parseHTML( html ).reduce( - ( total, currentNode ) => { - const cleanNode = frmDom.cleanNode( currentNode ); - - if ( '#text' === cleanNode.nodeName ) { - return total += cleanNode.textContent; - } - - return total + cleanNode.outerHTML; - }, - '' - ); - - if ( clean !== html ) { - // Clean it until nothing changes, in case the stripped result is now unsafe. - return purifyHtml( clean ); - } - - return clean; - } - - function getImageLabel( label, showLabelWithImage, imageUrl, fieldType ) { - let imageLabelClass, - originalLabel = label, - shape = fieldType === 'checkbox' ? 'square' : 'circle', - labelImage, - labelNode, - imageLabel; - - originalLabel = purifyHtml( originalLabel ); - - if ( imageUrl ) { - labelImage = img({ src: imageUrl, alt: originalLabel }); - } else { - labelImage = div({ className: 'frm_empty_url' }); - labelImage.innerHTML = frmAdminJs.image_placeholder_icon; - } - - imageLabelClass = showLabelWithImage ? ' frm_label_with_image' : ''; - - imageLabel = tag( 'span', { className: 'frm_text_label_for_image_inner' }); - - imageLabel.innerHTML = originalLabel; - labelNode = tag( - 'span', - { - className: 'frm_image_option_container' + imageLabelClass, - children: [ - labelImage, - tag( 'span', { className: 'frm_text_label_for_image', child: imageLabel }) - ] - } - ); - - return labelNode; - } - - function getChecked( id ) { - field = jQuery( '#' + id ); - - if ( field.length === 0 ) { - return false; - } - - checkbox = field.siblings( 'input[type=checkbox]' ); - - return checkbox.length && checkbox.prop( 'checked' ); - } - - function removeDropdownOpts( field ) { - let i; - if ( typeof field.options === 'undefined' ) { - return; - } - - for ( i = field.options.length - 1; i >= 0; i-- ) { - field.remove( i ); - } - } - - /** - * Is the box checked to use separate values? - */ - function usingSeparateValues( fieldId ) { - return isChecked( 'separate_value_' + fieldId ); - } - - /** - * Is the box checked to use images as options? - */ - function imagesAsOptions( fieldId ) { - let checked = false, - field = document.getElementsByName( 'field_options[image_options_' + fieldId + ']' ); - - for ( let i = 0; i < field.length; i++ ) { - if ( field[ i ].checked ) { - checked = '0' !== field[ i ].value; - } - } - - /** - * @since 5.0.04 - */ - return frmAdminBuild.hooks.applyFilters( 'frm_choice_field_images_as_options', checked, fieldId ); - } - - function showingLabelWithImage( fieldId ) { - const isShowing = ! isChecked( 'hide_image_text_' + fieldId ); - - /** - * @since 5.0.04 - */ - return frmAdminBuild.hooks.applyFilters( 'frm_choice_field_showing_label_with_image', isShowing, fieldId ); - } - - function isChecked( id ) { - const field = document.getElementById( id ); - if ( field === null ) { - return false; - } - return field.checked; - } - - function checkUniqueOpt( targetInput ) { - const settingsContainer = targetInput.closest( '.frm-single-settings' ); - const fieldId = settingsContainer.getAttribute( 'data-fid' ); - const areValuesSeparate = settingsContainer.querySelector( '[name="field_options[separate_value_' + fieldId + ']"]' ).checked; - - if ( areValuesSeparate && ! targetInput.name.endsWith( '[value]' ) ) { - return; - } - - const container = document.getElementById( 'frm_field_' + fieldId + '_opts' ); - const conflicts = Array.from( container.querySelectorAll( 'input[type="text"]' ) ).filter( - input => input.id !== targetInput.id && - areValuesSeparate === input.name.endsWith( '[value]' ) && - input.value === targetInput.value - ); - - if ( conflicts.length ) { - /* translators: %s: The detected option value. */ - infoModal( sprintf( __( 'Duplicate option value "%s" detected', 'formidable' ), purifyHtml( targetInput.value ) ) ); - } - } - - function getFieldValues() { - /*jshint validthis:true */ - let isTaxonomy, - val = this.value; - - if ( val ) { - const parentIDs = this.parentNode.id.replace( 'frm_logic_', '' ).split( '_' ); - const fieldID = parentIDs[0]; - const metaKey = parentIDs[1]; - const valueField = document.getElementById( 'frm_field_id_' + val ); - const valueFieldType = valueField.getAttribute( 'data-ftype' ); - const fill = document.getElementById( 'frm_show_selected_values_' + fieldID + '_' + metaKey ); - const optionName = 'field_options[hide_opt_' + fieldID + '][]'; - const optionID = 'frm_field_logic_opt_' + fieldID; - let input = false; - let showSelect = ( valueFieldType === 'select' || valueFieldType === 'checkbox' || valueFieldType === 'radio' ); - const showText = ( valueFieldType === 'text' || valueFieldType === 'email' || valueFieldType === 'phone' || valueFieldType === 'url' || valueFieldType === 'number' ); - - if ( showSelect ) { - isTaxonomy = document.getElementById( 'frm_has_hidden_options_' + val ); - if ( isTaxonomy !== null ) { - // get the category options with ajax - showSelect = false; - } - } - - if ( showSelect || showText ) { - const comparison = document.querySelector( `#frm_logic_${fieldID}_${metaKey} [name="field_options[hide_field_cond_${fieldID}][]"]` ).value; - fill.innerHTML = ''; - const creatingValuesDropdown = showSelect && ! [ 'LIKE', 'not LIKE', 'LIKE%', '%LIKE' ].includes( comparison ); - if ( creatingValuesDropdown ) { - input = document.createElement( 'select' ); - } else { - input = document.createElement( 'input' ); - input.type = 'text'; - } - input.name = optionName; - input.id = optionID + '_' + metaKey; - fill.appendChild( input ); - - if ( creatingValuesDropdown ) { - const fillField = document.getElementById( input.id ); - fillDropdownOpts( fillField, { - sourceID: val, - placeholder: '', - other: true - }); - } - } else { - const thisType = this.getAttribute( 'data-type' ); - const callback = () => { - const event = new CustomEvent( 'frm_logic_options_loaded' ); - event.frmData = { valueFieldType, fieldID, metaKey }; - document.dispatchEvent( event ); - }; - - frmGetFieldValues( val, fieldID, metaKey, thisType, undefined, callback ); - } - } - } - - function getFieldSelection() { - /*jshint validthis:true */ - const formId = this.value; - if ( formId ) { - const fieldId = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ); - getTaxOrFieldSelection( formId, fieldId ); - } - } - - function getTaxOrFieldSelection( formId, fieldId ) { - if ( formId ) { - jQuery.ajax({ - type: 'POST', - url: ajaxurl, - data: { - action: 'frm_get_field_selection', - field_id: fieldId, - form_id: formId, - nonce: frmGlobal.nonce - }, - success: function( msg ) { - jQuery( '#frm_show_selected_fields_' + fieldId ).html( msg ).show(); - } - }); - } - } - - function updateFieldOrder() { - let self = this; - - this.initOnceInAllInstances = function() { - if ( 'undefined' !== typeof updateFieldOrder.prototype.orderFieldsObject ) { - return; - } - - // It will store the order input fields ( input[name="field_options[field_order_{fieldId}]"] ). - // It will help to reduce the DOM searches based on fieldId. - // The same object data is used across all "updateFieldOrder" instances. - updateFieldOrder.prototype.orderFieldsObject = {}; - - // Get the Form group that will handle the fields settings. - // Perform a single DOM search and use it across all "updateFieldOrder" instances. - updateFieldOrder.prototype.fieldSettingsForm = document.getElementById( 'frm-end-form-marker' ).closest( 'form' ); - }; - - this.getFieldOrderInputById = function( fieldId, parent ) { - let field; - const orderFieldsObject = updateFieldOrder.prototype.orderFieldsObject; - const fieldSettingsForm = updateFieldOrder.prototype.fieldSettingsForm; - - if ( 'undefined' === typeof orderFieldsObject[ fieldId ]) { - field = fieldSettingsForm.querySelector( 'input[name="field_options[field_order_' + fieldId + ']"]' ); - if ( null === field ) { - field = parent.querySelector( 'input[name="field_options[field_order_' + fieldId + ']"]' ); - } - orderFieldsObject[ fieldId ] = field; - return field; - } - - return orderFieldsObject[ fieldId ]; - }; - - this.initOnceInAllInstances(); - renumberPageBreaks(); - - return ( function() { - let fieldId, field, currentOrder, newOrder, - moveFieldsClass = new moveFieldSettings(), - fields = jQuery( 'li.frm_field_box', jQuery( '#frm-show-fields' ) ); - - for ( i = 0; i < fields.length; i++ ) { - fieldId = fields[ i ].getAttribute( 'data-fid' ); - field = self.getFieldOrderInputById( fieldId, fields[ i ]); - - // get current field order, make sure we don't get the "field" reference as the "field" value will get updated later. - currentOrder = null !== field ? Object.assign({}, field.value )[0] : null; - newOrder = i + 1; - - if ( currentOrder != newOrder && null !== currentOrder ) { - field.value = newOrder; - singleField = fields[ i ].querySelector( '#frm-single-settings-' + fieldId ); - - // add field that needs to be moved to "updateFieldOrder.prototype.fieldSettingsForm" - moveFieldsClass.append( singleField ); - fieldUpdated(); - } - } - // move all appended fields - moveFieldsClass.moveFields(); - }() ); - } - - function toggleSectionHolder() { - document.querySelectorAll( '.start_divider' ).forEach( - function( divider ) { - toggleOneSectionHolder( jQuery( divider ) ); - } - ); - } - - function toggleOneSectionHolder( $section ) { - let noSectionFields, $rows, length, index, sectionHasFields; - - if ( ! $section.length ) { - return; - } - - $rows = $section.find( 'ul.frm_sorting' ); - sectionHasFields = false; - length = $rows.length; - for ( index = 0; index < length; ++index ) { - if ( 0 !== getFieldsInRow( jQuery( $rows.get( index ) ) ).length ) { - sectionHasFields = true; - break; - } - } - - noSectionFields = $section.parent().children( '.frm_no_section_fields' ).get( 0 ); - noSectionFields.classList.toggle( 'frm_block', ! sectionHasFields ); - } - - function handleShowPasswordLiveUpdate() { - frmDom.util.documentOn( 'change', '.frm_show_password_setting_input', event => { - const fieldId = event.target.getAttribute( 'data-fid' ); - const fieldEl = document.getElementById( 'frm_field_id_' + fieldId ); - if ( ! fieldEl ) { - return; - } - - fieldEl.classList.toggle( 'frm_disabled_show_password', ! event.target.checked ); - }); - } - - function slideDown() { - /*jshint validthis:true */ - const id = jQuery( this ).data( 'slidedown' ); - const $thisId = jQuery( document.getElementById( id ) ); - if ( $thisId.is( ':hidden' ) ) { - $thisId.slideDown( 'fast' ); - this.style.display = 'none'; - } - return false; - } - - function slideUp() { - /*jshint validthis:true */ - const id = jQuery( this ).data( 'slideup' ); - const $thisId = jQuery( document.getElementById( id ) ); - $thisId.slideUp( 'fast' ); - $thisId.siblings( 'a' ).show(); - return false; - } - - function adjustVisibilityValuesForEveryoneValues( element, option ) { - if ( '' === option.getAttribute( 'value' ) ) { - onEveryoneOptionSelected( jQuery( this ) ); - } else { - unselectEveryoneOptionIfSelected( jQuery( this ) ); - } - } - - function onEveryoneOptionSelected( $select ) { - $select.val( '' ); - $select.next( '.btn-group' ).find( '.multiselect-container input[value!=""]' ).prop( 'checked', false ); - } - - function unselectEveryoneOptionIfSelected( $select ) { - let selectedValues = $select.val(), - index; - - if ( selectedValues === null ) { - $select.next( '.btn-group' ).find( '.multiselect-container input[value=""]' ).prop( 'checked', true ); - onEveryoneOptionSelected( $select ); - return; - } - - index = selectedValues.indexOf( '' ); - if ( index >= 0 ) { - selectedValues.splice( index, 1 ); - $select.val( selectedValues ); - $select.next( '.btn-group' ).find( '.multiselect-container input[value=""]' ).prop( 'checked', false ); - } - } - - /** - * Get rid of empty container that inserts extra space. - */ - function hideEmptyEle() { - jQuery( '.frm-hide-empty' ).each( function() { - if ( jQuery( this ).text().trim().length === 0 ) { - jQuery( this ).remove(); - } - }); - } - - /* Change the classes in the builder */ - function changeFieldClass( field, setting ) { - let classes, replace, alignField, - replaceWith = ' ' + setting.value, - fieldId = field.getAttribute( 'data-fid' ); - - // Include classes from multiple settings. - if ( typeof fieldId !== 'undefined' ) { - if ( setting.classList.contains( 'field_options_align' ) ) { - replaceWith += ' ' + document.getElementById( 'frm_classes_' + fieldId ).value; - } else if ( setting.classList.contains( 'frm_classes' ) ) { - alignField = document.getElementById( 'field_options_align_' + fieldId ); - if ( alignField !== null ) { - replaceWith += ' ' + alignField.value; - } - } - } - replaceWith += ' '; - - // Allow for the column number dropdown. - replaceWith = replaceWith.replace( ' block ', ' ' ).replace( ' inline ', ' horizontal_radio ' ); - - classes = field.className.split( ' frmstart ' )[1]; - classes = 0 === classes.indexOf( 'frmend ' ) ? '' : classes.split( ' frmend ' )[0]; - - if ( classes.trim() === '' ) { - replace = ' frmstart frmend '; - if ( -1 === field.className.indexOf( replace ) ) { - replace = ' frmstart frmend '; - } - replaceWith = ' frmstart ' + replaceWith.trim() + ' frmend '; - } else { - replace = classes.trim(); - replaceWith = replaceWith.trim(); - } - - field.className = field.className.replace( replace, replaceWith ); - } - - function maybeShowInlineModal( e ) { - /*jshint validthis:true */ - e.preventDefault(); - showInlineModal( this ); - } - - function showInlineModal( icon, input ) { - const box = document.getElementById( icon.getAttribute( 'data-open' ) ), - container = jQuery( icon ).closest( 'p' ), - inputTrigger = ( typeof input !== 'undefined' ); - - if ( container.hasClass( 'frm-open' ) ) { - container.removeClass( 'frm-open' ); - box.classList.add( 'frm_hidden' ); - } else { - if ( ! inputTrigger ) { - input = getInputForIcon( icon ); - } - if ( input !== null ) { - if ( ! inputTrigger ) { - input.focus(); - } - container.after( box ); - box.setAttribute( 'data-fills', input.id ); - - if ( box.id.indexOf( 'frm-calc-box' ) === 0 ) { - popCalcFields( box, true ); - } - } - - container.addClass( 'frm-open' ); - box.classList.remove( 'frm_hidden' ); - - /** - * @since 6.4.1 - */ - wp.hooks.doAction( 'frm_show_inline_modal', box, icon ); - } - } - - function dismissInlineModal( e ) { - /*jshint validthis:true */ - e.preventDefault(); - this.parentNode.classList.add( 'frm_hidden' ); - jQuery( '.frm-open [data-open="' + this.parentNode.id + '"]' ).closest( '.frm-open' ).removeClass( 'frm-open' ); - } - - function changeInputtedValue() { - /*jshint validthis:true */ - let i, - action = this.getAttribute( 'data-frmchange' ).split( ',' ); - - for ( i = 0; i < action.length; i++ ) { - if ( action[i] === 'updateOption' ) { - changeHiddenSeparateValue( this ); - } else if ( action[i] === 'updateDefault' ) { - changeDefaultRadioValue( this ); - } else if ( action[i] === 'checkUniqueOpt' ) { - checkUniqueOpt( this ); - } else { - this.value = this.value[ action[i] ](); - } - } - } - - /** - * When the saved value is changed, update the default value radio. - */ - function changeDefaultRadioValue( input ) { - const parentLi = getOptionParent( input ), - key = parentLi.getAttribute( 'data-optkey' ), - fieldId = getOptionFieldId( parentLi, key ), - defaultRadio = parentLi.querySelector( 'input[name="default_value_' + fieldId + '"]' ); - - if ( defaultRadio !== null ) { - defaultRadio.value = input.value; - } - } - - /** - * If separate values are not enabled, change the saved value when - * the displayed value is changed. - */ - function changeHiddenSeparateValue( input ) { - let savedVal, - parentLi = getOptionParent( input ), - key = parentLi.getAttribute( 'data-optkey' ), - fieldId = getOptionFieldId( parentLi, key ), - sep = document.getElementById( 'separate_value_' + fieldId ); - - if ( sep !== null && sep.checked === false ) { - // If separate values are not turned on. - savedVal = document.getElementById( 'field_key_' + fieldId + '-' + key ); - savedVal.value = input.value; - changeDefaultRadioValue( savedVal ); - } - } - - function getOptionParent( input ) { - let parentLi = input.parentNode; - if ( parentLi.tagName !== 'LI' ) { - parentLi = parentLi.parentNode; - } - return parentLi; - } - - function getOptionFieldId( li, key ) { - const liId = li.id; - - return liId.replace( 'frm_delete_field_', '' ).replace( '-' + key + '_container', '' ); - } - - function submitBuild() { - /*jshint validthis:true */ - const $thisEle = this; - - if ( showNameYourFormModal() ) { - return; - } - - preFormSave( this ); - - const $form = jQuery( builderForm ); - const v = JSON.stringify( $form.serializeArray() ); - - jQuery( document.getElementById( 'frm_compact_fields' ) ).val( v ); - jQuery.ajax({ - type: 'POST', - url: ajaxurl, - data: {action: 'frm_save_form', 'frm_compact_fields': v, nonce: frmGlobal.nonce}, - success: function( msg ) { - afterFormSave( $thisEle ); - - const $postStuff = document.getElementById( 'post-body-content' ); - const $html = document.createElement( 'div' ); - $html.setAttribute( 'class', 'frm_updated_message' ); - $html.innerHTML = msg; - $postStuff.insertBefore( $html, $postStuff.firstChild ); - reloadIfAddonActivatedAjaxSubmitOnly(); - }, - error: function() { - triggerSubmit( document.getElementById( 'frm_js_build_form' ) ); - } - }); - } - - function triggerSubmit( form ) { - const button = form.ownerDocument.createElement( 'input' ); - button.style.display = 'none'; - button.type = 'submit'; - form.appendChild( button ).click(); - form.removeChild( button ); - } - - function triggerChange( element ) { - jQuery( element ).trigger( 'change' ); - } - - function submitNoAjax() { - /*jshint validthis:true */ - let form; - - if ( showNameYourFormModal() ) { - return; - } - - preFormSave( this ); - form = jQuery( builderForm ); - jQuery( document.getElementById( 'frm_compact_fields' ) ).val( JSON.stringify( form.serializeArray() ) ); - triggerSubmit( document.getElementById( 'frm_js_build_form' ) ); - } - - /** - * Display a modal dialog for naming a new form template, if applicable. - * - * @return {boolean} True if the modal is successfully initialized and displayed; false otherwise. - */ - function showNameYourFormModal() { - // Exit early if the 'new_template' URL parameter is not set to 'true' - if ( ! shouldShowNameYourFormNameModal() ) { - return false; - } - - const modalWidget = initModal( '#frm-form-templates-modal', '440px' ); - if ( ! modalWidget ) { - return false; - } - - // Set the vertical offset for the modal and open it - offsetModalY( modalWidget, '72px' ); - modalWidget.dialog( 'open' ); - - return true; - } - - /** - * Returns true if 'Name Your Form' modal should be displayed. - * - * @returns {Boolean} - */ - function shouldShowNameYourFormNameModal() { - const formNameInput = document.getElementById( 'frm_form_name' ); - if ( formNameInput && formNameInput.value.trim() !== '' ) { - return false; - } - - return 'true' === urlParams.get( 'new_template' ) && document.querySelector( '#frm_top_bar #frm_bs_dropdown .frm_bstooltip' )?.textContent.trim() === frm_admin_js.noTitleText; // eslint-disable-line camelcase - } - - /** - * Manages event handling for the 'Name your form' modal. - * - * Attaches click and keydown event listeners to the save button and input field. - * - * @return {void} - */ - function addFormNameModalEvents() { - const saveFormNameButton = document.getElementById( 'frm-save-form-name-button' ); - const newFormNameInput = document.getElementById( 'frm_new_form_name_input' ); - - // Attach click event listener - onClickPreventDefault( saveFormNameButton, onSaveFormNameButton ); - - // Attach keydown event listener - newFormNameInput.addEventListener( 'keydown', function( event ) { - if ( event.key === 'Enter' ) { - onSaveFormNameButton.call( this, event ); - } - }); - } - - /** - * Handles the click event on the save form name button. - * - * @param {Event} event The click event object. - * @return {void} - */ - const onSaveFormNameButton = ( event ) => { - const newFormName = document.getElementById( 'frm_new_form_name_input' ).value.trim(); - - // Prepare FormData for the POST request - const formData = new FormData(); - formData.append( 'form_id', urlParams.get( 'id' ) ); - formData.append( 'form_name', newFormName ); - - // Perform the POST request - doJsonPost( 'rename_form', formData ).then( data => { - // Remove the 'new_template' parameter from the URL and update the browser history - urlParams.delete( 'new_template' ); - currentURL.search = urlParams.toString(); - history.replaceState({}, '', currentURL.toString() ); - - if ( null !== document.getElementById( 'frm_notification_settings' ) ) { - document.getElementById( 'frm_form_name' ).value = newFormName; - document.getElementById( 'frm_form_key' ).value = data.form_key; - } - - // Trigger the 'Save' button click using jQuery - jQuery( '#frm-publishing' ).find( '.frm_button_submit' ).trigger( 'click' ); - }); - }; - - function preFormSave( b ) { - removeWPUnload(); - if ( jQuery( 'form.inplace_form' ).length ) { - jQuery( '.inplace_save, .postbox' ).trigger( 'click' ); - } - - if ( b.classList.contains( 'frm_button_submit' ) ) { - b.classList.add( 'frm_loading_form' ); - } else { - b.classList.add( 'frm_loading_button' ); - } - b.setAttribute( 'aria-busy', 'true' ); - - adjustFormatInputBeforeSave(); - } - - /** - * Updates the format input based on the selected format type from dropdowns during the form save process. - * - * @since 6.9 - * - * @return {void} - */ - function adjustFormatInputBeforeSave() { - const formatTypes = document.querySelectorAll( '.frm_format_dropdown, .frm_phone_type_dropdown' ); - const valueMap = { - none: '', - international: 'international', - currency: 'currency', - number: 'number' - }; - - formatTypes.forEach( formatType => { - const value = formatType.value; - if ( value in valueMap ) { - const formatInput = document.getElementById( `frm_format_${formatType.dataset.fieldId}` ); - formatInput.value = valueMap[ value ]; - } - }); - } - - function afterFormSave( button ) { - button.classList.remove( 'frm_loading_form' ); - button.classList.remove( 'frm_loading_button' ); - resetOptionTextDetails(); - fieldsUpdated = 0; - button.setAttribute( 'aria-busy', 'false' ); - - setTimeout( function() { - jQuery( '.frm_updated_message' ).fadeOut( 'slow', function() { - this.parentNode.removeChild( this ); - }); - }, 5000 ); - } - - function initUpgradeModal() { - const $info = initModal( '#frm_upgrade_modal' ); - if ( $info === false ) { - return; - } - - document.addEventListener( 'click', handleUpgradeClick ); - frmDom.util.documentOn( 'change', 'select.frm_select_with_upgrade', handleUpgradeClick ); - - function handleUpgradeClick( event ) { - let element, link, content; - - element = event.target; - - if ( ! element.classList ) { - return; - } - - const showExpiredModal = element.classList.contains( 'frm_show_expired_modal' ) || null !== element.querySelector( '.frm_show_expired_modal' ) || element.closest( '.frm_show_expired_modal' ); - - // If a `select` element is clicked, check if the selected option has a 'data-upgrade' attribute - if ( event.type === 'change' && element.classList.contains( 'frm_select_with_upgrade' ) ) { - const selectedOption = element.options[element.selectedIndex]; - if ( selectedOption && selectedOption.dataset.upgrade ) { - element = selectedOption; - } - } - - if ( ! element.dataset.upgrade ) { - let parent = element.closest( '[data-upgrade]' ); - if ( ! parent ) { - parent = element.closest( '.frm_field_box' ); - if ( ! parent ) { - return; - } - // Fake it if it's missing to avoid error. - element.dataset.upgrade = ''; - } - element = parent; - } - - if ( showExpiredModal ) { - const hookName = 'frm_show_expired_modal'; - wp.hooks.doAction( hookName, element ); - return; - } - - const upgradeLabel = element.dataset.upgrade; - if ( ! upgradeLabel || element.classList.contains( 'frm_show_upgrade_tab' ) ) { - return; - } - - event.preventDefault(); - - const modal = $info.get( 0 ); - const lockIcon = modal.querySelector( '.frm_lock_icon' ); - - if ( lockIcon ) { - lockIcon.style.display = 'block'; - lockIcon.classList.remove( 'frm_lock_open_icon' ); - lockIcon.querySelector( 'use' ).setAttribute( 'href', '#frm_lock_icon' ); - } - - const upgradeImageId = 'frm_upgrade_modal_image'; - const oldImage = document.getElementById( upgradeImageId ); - if ( oldImage ) { - oldImage.remove(); - } - - if ( element.dataset.image ) { - if ( lockIcon ) { - lockIcon.style.display = 'none'; - } - lockIcon.parentNode.insertBefore( img({ id: upgradeImageId, src: frmGlobal.url + '/images/' + element.dataset.image }), lockIcon ); - } - - const level = modal.querySelector( '.license-level' ); - if ( level ) { - level.textContent = getRequiredLicenseFromTrigger( element ); - } - - // If one click upgrade, hide other content - addOneClick( element, 'modal', upgradeLabel ); - - modal.querySelector( '.frm_are_not_installed' ).style.display = element.dataset.image ? 'none' : 'inline-block'; - modal.querySelector( '.frm_feature_label' ).textContent = upgradeLabel; - modal.querySelector( 'h2' ).style.display = 'block'; - - $info.dialog( 'open' ); - - // set the utm medium - const button = modal.querySelector( '.button-primary:not(.frm-oneclick-button)' ); - link = button.getAttribute( 'href' ).replace( /(medium=)[a-z_-]+/ig, '$1' + element.getAttribute( 'data-medium' ) ); - content = element.getAttribute( 'data-content' ); - if ( content === null ) { - content = ''; - } - link = link.replace( /(content=)[a-z_-]+/ig, '$1' + content ); - button.setAttribute( 'href', link ); - } - } - - function getRequiredLicenseFromTrigger( element ) { - if ( element.dataset.requires ) { - return element.dataset.requires; - } - return 'Pro'; - } - - function populateUpgradeTab( element ) { - const title = element.dataset.upgrade; - - const tab = element.getAttribute( 'href' ).replace( '#', '' ); - const container = document.querySelector( '.frm_' + tab ) || document.querySelector( '.' + tab ); - - if ( ! container ) { - return; - } - - if ( container.querySelector( '.frm-upgrade-message' ) ) { - // Tab has already been populated. - return; - } - - const h2 = container.querySelector( 'h2' ); - h2.style.borderBottom = 'none'; - - /* translators: %s: Form Setting section name (ie Form Permissions, Form Scheduling). */ - h2.textContent = sprintf( __( '%s are not installed', 'formidable' ), title ); - - container.classList.add( 'frmcenter' ); - - const upgradeModal = document.getElementById( 'frm_upgrade_modal' ); - appendClonedModalElementToContainer( 'frm-oneclick' ); - appendClonedModalElementToContainer( 'frm-addon-status' ); - - // Borrow the call to action from the Upgrade upgradeModal which should exist on the settings page (it is still used for other upgrades including Actions). - const upgradeModalLink = upgradeModal.querySelector( '.frm-upgrade-link' ); - if ( upgradeModalLink ) { - const upgradeButton = upgradeModalLink.cloneNode( true ); - const level = upgradeButton.querySelector( '.license-level' ); - - if ( level ) { - level.textContent = getRequiredLicenseFromTrigger( element ); - } - - container.appendChild( upgradeButton ); - - // Maybe append the secondary "Already purchased?" link from the upgradeModal as well. - if ( upgradeModalLink.nextElementSibling && upgradeModalLink.nextElementSibling.querySelector( '.frm-link-secondary' ) ) { - container.appendChild( upgradeModalLink.nextElementSibling.cloneNode( true ) ); - } - - appendClonedModalElementToContainer( 'frm-oneclick-button' ); - } - - appendClonedModalElementToContainer( 'frm-upgrade-message' ); - - let upgradeLabel = element.dataset.message; - - if ( upgradeLabel === undefined ) { - upgradeLabel = element.dataset.upgrade; - } - addOneClick( element, 'tab', upgradeLabel ); - - if ( element.dataset.screenshot ) { - container.appendChild( getScreenshotWrapper( element.dataset.screenshot ) ); - } - - function appendClonedModalElementToContainer( className ) { - container.appendChild( upgradeModal.querySelector( '.' + className ).cloneNode( true ) ); - } - } - - function getScreenshotWrapper( screenshot ) { - const folderUrl = frmGlobal.url + '/images/screenshots/'; - const wrapper = div({ - className: 'frm-settings-screenshot-wrapper', - children: [ - getToolbar(), - div({ child: img({ src: folderUrl + screenshot }) }) - ] - }); - - function getToolbar() { - const children = getColorIcons(); - children.push( img({ src: frmGlobal.url + '/images/tab.svg' }) ); - return div({ - className: 'frm-settings-screenshot-toolbar', - children - }); - } - - function getColorIcons() { - return [ '#ED8181', '#EDE06A', '#80BE30' ].map( - color => { - const circle = div({ className: 'frm-minmax-icon' }); - circle.style.backgroundColor = color; - return circle; - } - ); - } - - return wrapper; - } - - /** - * Allow addons to be installed from the upgrade modal. - * - * @param {Element} link - * @param {String} context Either 'modal' or 'tab'. - * @param {String|undefined} upgradeLabel - */ - function addOneClick( link, context, upgradeLabel ) { - let container; - - if ( 'modal' === context ) { - container = document.getElementById( 'frm_upgrade_modal' ); - } else if ( 'tab' === context ) { - container = document.getElementById( link.getAttribute( 'href' ).substr( 1 ) ); - } else { - return; - } - - const oneclickMessage = container.querySelector( '.frm-oneclick' ); - const upgradeMessage = container.querySelector( '.frm-upgrade-message' ); - const showLink = container.querySelector( '.frm-upgrade-link' ); - const button = container.querySelector( '.frm-oneclick-button' ); - const addonStatus = container.querySelector( '.frm-addon-status' ); - - let oneclick = link.getAttribute( 'data-oneclick' ); - let newMessage = link.getAttribute( 'data-message' ); - let showIt = 'block'; - let showMsg = 'block'; - let hideIt = 'none'; - - // If one click upgrade, hide other content. - if ( oneclickMessage !== null && typeof oneclick !== 'undefined' && oneclick ) { - if ( newMessage === null ) { - showMsg = 'none'; - } - showIt = 'none'; - hideIt = 'block'; - oneclick = JSON.parse( oneclick ); - - button.className = button.className.replace( ' frm-install-addon', '' ).replace( ' frm-activate-addon', '' ); - button.className = button.className + ' ' + oneclick.class; - button.rel = oneclick.url; - - if ( oneclick.class === 'frm-activate-addon' ) { - oneclickMessage.textContent = __( 'This plugin is not activated. Would you like to activate it now?', 'formidable' ); - button.textContent = __( 'Activate', 'formidable' ); - } else { - oneclickMessage.textContent = __( 'That add-on is not installed. Would you like to install it now?', 'formidable' ); - button.textContent = __( 'Install', 'formidable' ); - } - } - - if ( ! newMessage ) { - newMessage = upgradeMessage.getAttribute( 'data-default' ); - } - if ( undefined !== upgradeLabel ) { - newMessage = newMessage.replace( '', upgradeLabel ); - } - - upgradeMessage.innerHTML = newMessage; - - if ( link.dataset.upsellImage ) { - upgradeMessage.appendChild( - img({ - src: link.dataset.upsellImage, - alt: link.dataset.upgrade - }) - ); - } - - // Either set the link or use the default. - showLink.href = getShowLinkHrefValue( link, showLink ); - - addonStatus.style.display = 'none'; - - oneclickMessage.style.display = hideIt; - button.style.display = hideIt === 'block' ? 'inline-block' : hideIt; - upgradeMessage.style.display = showMsg; - showLink.style.display = showIt === 'block' ? 'inline-block' : showIt; - } - - function getShowLinkHrefValue( link, showLink ) { - let customLink = link.getAttribute( 'data-link' ); - if ( customLink === null || typeof customLink === 'undefined' || customLink === '' ) { - customLink = showLink.getAttribute( 'data-default' ); - } - return customLink; - } - - /* Form settings */ - - function showInputIcon( parentClass ) { - if ( typeof parentClass === 'undefined' ) { - parentClass = ''; - } - maybeAddFieldSelection( parentClass ); - jQuery( parentClass + ' .frm_has_shortcodes:not(.frm-with-right-icon) input,' + parentClass + ' .frm_has_shortcodes:not(.frm-with-right-icon) textarea' ).wrap( '' ).before( '' ); - } - - /** - * For reverse compatibility. Check for fields that were - * using the old sidebar. - */ - function maybeAddFieldSelection( parentClass ) { - let i, - missingClass = jQuery( parentClass + ' :not(.frm_has_shortcodes) .frm_not_email_message, ' + parentClass + ' :not(.frm_has_shortcodes) .frm_not_email_to, ' + parentClass + ' :not(.frm_has_shortcodes) .frm_not_email_subject' ); - for ( i = 0; i < missingClass.length; i++ ) { - missingClass[i].parentNode.classList.add( 'frm_has_shortcodes' ); - } - } - - function showSuccessOpt() { - /*jshint validthis:true */ - let c = 'success'; - if ( this.name === 'options[edit_action]' ) { - c = 'edit'; - } - const v = jQuery( this ).val(); - jQuery( '.' + c + '_action_box' ).hide(); - if ( v === 'redirect' ) { - jQuery( '.' + c + '_action_redirect_box.' + c + '_action_box' ).fadeIn( 'slow' ); - } else if ( v === 'page' ) { - jQuery( '.' + c + '_action_page_box.' + c + '_action_box' ).fadeIn( 'slow' ); - } else { - jQuery( '.' + c + '_action_message_box.' + c + '_action_box' ).fadeIn( 'slow' ); - } - } - - function copyFormAction( event ) { - if ( waitForActionToLoadBeforeCopy( event.target ) ) { - return; - } - - const targetSettings = event.target.closest( '.frm_form_action_settings' ); - const wysiwygs = targetSettings.querySelectorAll( '.wp-editor-area' ); - if ( wysiwygs.length ) { - // Temporary remove TinyMCE before cloning to avoid TinyMCE conflicts. - wysiwygs.forEach( wysiwyg => { - tinymce.EditorManager.execCommand( 'mceRemoveEditor', true, wysiwyg.id ); - }); - } - - const $action = jQuery( targetSettings ).clone(); - const currentID = $action.attr( 'id' ).replace( 'frm_form_action_', '' ); - const newID = newActionId( currentID ); - - $action.find( '.frm_action_id, .frm-btn-group' ).remove(); - $action.find( 'input[name$="[' + currentID + '][ID]"]' ).val( '' ); - $action.find( '.widget-inside' ).hide(); - - // the .html() gets original values, so they need to be set - $action.find( 'input[type=text], textarea, input[type=number]' ).prop( 'defaultValue', function() { - return this.value; - }); - - $action.find( 'input[type=checkbox], input[type=radio]' ).prop( 'defaultChecked', function() { - return this.checked; - }); - - const rename = new RegExp( '\\[' + currentID + '\\]', 'g' ); - const reid = new RegExp( '_' + currentID + '"', 'g' ); - const reclass = new RegExp( '-' + currentID + '"', 'g' ); - const revalue = new RegExp( '"' + currentID + '"', 'g' ); // if a field id matches, this could cause trouble - - let html = $action.html().replace( rename, '[' + newID + ']' ).replace( reid, '_' + newID + '"' ); - html = html.replace( reclass, '-' + newID + '"' ).replace( revalue, '"' + newID + '"' ); - - const newAction = div({ - id: 'frm_form_action_' + newID, - className: $action.get( 0 ).className - }); - newAction.setAttribute( 'data-actionkey', newID ); - newAction.innerHTML = html; - newAction.querySelectorAll( '.wp-editor-wrap, .wp-editor-wrap *' ).forEach( - element => { - if ( 'string' === typeof element.className ) { - element.className = element.className.replace( currentID, newID ); - } - element.id = element.id.replace( currentID, newID ); - } - ); - newAction.classList.remove( 'open' ); - document.getElementById( 'frm_notification_settings' ).appendChild( newAction ); - - if ( wysiwygs.length ) { - // Re-initialize the original wysiwyg which was removed before cloning. - wysiwygs.forEach( wysiwyg => { - frmDom.wysiwyg.init( wysiwyg ); - }); - - newAction.querySelectorAll( '.wp-editor-area' ).forEach( wysiwyg => { - frmDom.wysiwyg.init( wysiwyg ); - }); - } - - if ( newAction.classList.contains( 'frm_single_on_submit_settings' ) ) { - const autocompleteInput = newAction.querySelector( 'input.frm-page-search' ); - if ( autocompleteInput ) { - initAutocomplete( newAction ); - } - } - - initiateMultiselect(); - - const hookName = 'frm_after_duplicate_action'; - wp.hooks.doAction( hookName, newAction ); - } - - function waitForActionToLoadBeforeCopy( element ) { - let $trigger = jQuery( element ), - $original = $trigger.closest( '.frm_form_action_settings' ), - $inside = $original.find( '.widget-inside' ), - $top; - - if ( $inside.find( 'p, div, table' ).length ) { - return false; - } - - $top = $original.find( '.widget-top' ); - $top.on( 'frm-action-loaded', function() { - $trigger.trigger( 'click' ); - $original.removeClass( 'open' ); - $inside.hide(); - }); - $top.trigger( 'click' ); - return true; - } - - function newActionId( currentID ) { - let newID = parseInt( currentID, 10 ) + 11; - const exists = document.getElementById( 'frm_form_action_' + newID ); - if ( exists !== null ) { - newID++; - newID = newActionId( newID ); - } - return newID; - } - - function addFormAction() { - /*jshint validthis:true */ - const type = jQuery( this ).data( 'actiontype' ); - - if ( isAtLimitForActionType( type ) ) { - return; - } - - const actionId = getNewActionId(); - const formId = thisFormId; - - const placeholderSetting = document.createElement( 'div' ); - placeholderSetting.classList.add( 'frm_single_' + type + '_settings' ); - - const actionsList = document.getElementById( 'frm_notification_settings' ); - actionsList.appendChild( placeholderSetting ); - - jQuery.ajax({ - type: 'POST', - url: ajaxurl, - data: { - action: 'frm_add_form_action', - type: type, - list_id: actionId, - form_id: formId, - nonce: frmGlobal.nonce - }, - success: handleAddFormActionSuccess - }); - - function handleAddFormActionSuccess( html ) { - fieldUpdated(); - placeholderSetting.remove(); - - closeOpenActions(); - - const newActionContainer = div(); - newActionContainer.innerHTML = html; - - const widgetTop = newActionContainer.querySelector( '.widget-top' ); - Array.from( newActionContainer.children ).forEach( child => actionsList.appendChild( child ) ); - - jQuery( '.frm_form_action_settings' ).fadeIn( 'slow' ); - - const newAction = document.getElementById( 'frm_form_action_' + actionId ); - - newAction.classList.add( 'open' ); - document.getElementById( 'post-body-content' ).scroll({ - top: newAction.offsetTop + 10, - left: 0, - behavior: 'smooth' - }); - - // Check if icon should be active - checkActiveAction( type ); - showInputIcon( '#frm_form_action_' + actionId ); - - initiateMultiselect(); - initAutocomplete( newAction ); - - if ( widgetTop ) { - jQuery( widgetTop ).trigger( 'frm-action-loaded' ); - } - - /** - * Fires after added a new form action. - * - * @since 5.5.4 - * - * @param {HTMLElement} formAction Form action element. - */ - frmAdminBuild.hooks.doAction( 'frm_added_form_action', newAction ); - } - } - - function closeOpenActions() { - document.querySelectorAll( '.frm_form_action_settings.open' ).forEach( - setting => setting.classList.remove( 'open' ) - ); - } - - function toggleActionGroups() { - /*jshint validthis:true */ - const actions = document.getElementById( 'frm_email_addon_menu' ).classList, - search = document.getElementById( 'actions-search-input' ); - - if ( actions.contains( 'frm-all-actions' ) ) { - actions.remove( 'frm-all-actions' ); - actions.add( 'frm-limited-actions' ); - } else { - actions.add( 'frm-all-actions' ); - actions.remove( 'frm-limited-actions' ); - } - - // Reset search. - search.value = ''; - triggerEvent( search, 'input' ); - } - - function getNewActionId() { - let actionSettings = document.querySelectorAll( '.frm_form_action_settings' ), - len = getNewRowId( actionSettings, 'frm_form_action_' ); - if ( typeof document.getElementById( 'frm_form_action_' + len ) !== 'undefined' ) { - len = len + 100; - } - if ( lastNewActionIdReturned >= len ) { - len = lastNewActionIdReturned + 1; - } - lastNewActionIdReturned = len; - return len; - } - - function clickAction( obj ) { - const $thisobj = jQuery( obj ); - - if ( obj.className.indexOf( 'selected' ) !== -1 ) { - return; - } - if ( obj.className.indexOf( 'edit_field_type_end_divider' ) !== -1 && $thisobj.closest( '.edit_field_type_divider' ).hasClass( 'no_repeat_section' ) ) { - return; - } - - deselectFields(); - $thisobj.addClass( 'selected' ); - showFieldOptions( obj ); - } - - /** - * When a field is selected, show the field settings in the sidebar. - */ - function showFieldOptions( obj ) { - let i, singleField, - fieldId = obj.getAttribute( 'data-fid' ), - fieldType = obj.getAttribute( 'data-type' ), - allFieldSettings = document.querySelectorAll( '.frm-single-settings:not(.frm_hidden)' ); - - for ( i = 0; i < allFieldSettings.length; i++ ) { - allFieldSettings[i].classList.add( 'frm_hidden' ); - } - - singleField = document.getElementById( 'frm-single-settings-' + fieldId ); - moveFieldSettings( singleField ); - - if ( fieldType && 'quantity' === fieldType ) { - popProductFields( jQuery( singleField ).find( '.frmjs_prod_field_opt' )[0]); - } - - singleField.classList.remove( 'frm_hidden' ); - document.getElementById( 'frm-options-panel-tab' ).click(); - - const editor = singleField.querySelector( '.wp-editor-area' ); - if ( editor ) { - frmDom.wysiwyg.init( - editor, - { setupCallback: setupTinyMceEventHandlers } - ); - } - - wp.hooks.doAction( 'frmShowedFieldSettings', obj, singleField ); - maybeAddShortcodesModalTriggerIcon( fieldType, fieldId, singleField ); - } - - function maybeAddShortcodesModalTriggerIcon( fieldType, fieldId, singleField ) { - if ( ! shouldAddShortcodesModalTriggerIcon( fieldType ) ) { - return; - } - - const fieldSettingsSelector = '#frm-single-settings-' + fieldId; - if ( document.querySelector( fieldSettingsSelector + ' .frm-show-box' ) ) { - return; - } - singleField.querySelector( '.wp-editor-container' )?.classList.add( 'frm_has_shortcodes' ); - - const wrapTextareaWithIconContainer = () => { - const textareas = document.querySelectorAll( fieldSettingsSelector + ' .frm_has_shortcodes textarea' ); - textareas.forEach( textarea => { - const wrapperSpan = span({ className: 'frm-with-right-icon' }); - textarea.parentNode.insertBefore( wrapperSpan, textarea ); - wrapperSpan.appendChild( createModalTriggerIcon() ); - wrapperSpan.appendChild( textarea ); - }); - }; - - const createModalTriggerIcon = () => { - return frmDom.svg({ href: '#frm_more_horiz_solid_icon', classList: [ 'frm-show-box' ] }); - }; - - wrapTextareaWithIconContainer(); - } - - function shouldAddShortcodesModalTriggerIcon( fieldType ) { - const fieldsWithShortcodesBox = wp.hooks.applyFilters( 'frm_fields_with_shortcode_popup', [ 'html' ]); - - return fieldsWithShortcodesBox.includes( fieldType ); - } - - function setupTinyMceEventHandlers( editor ) { - editor.on( 'Change', function() { - handleTinyMceChange( editor ); - }); - } - - function handleTinyMceChange( editor ) { - if ( ! isTinyMceActive() || tinyMCE.activeEditor.isHidden() ) { - return; - } - - editor.targetElm.value = editor.getContent(); - jQuery( editor.targetElm ).trigger( 'change' ); - } - - function isTinyMceActive() { - let activeSettings, wrapper; - - activeSettings = document.querySelector( '.frm-single-settings:not(.frm_hidden)' ); - if ( ! activeSettings ) { - return false; - } - - wrapper = activeSettings.querySelector( '.wp-editor-wrap' ); - return null !== wrapper && wrapper.classList.contains( 'tmce-active' ); - } - - /** - * Move the settings to the sidebar the first time they are changed or selected. - * Keep the end marker at the end of the form. - */ - function moveFieldSettings( singleField ) { - let self = this; - - if ( singleField === null ) { - // The field may have not been loaded yet via ajax. - return; - } - - this.fragment = document.createDocumentFragment(); - - this.initOnceInAllInstances = function() { - if ( 'undefined' !== typeof moveFieldSettings.prototype.endMarker ) { - return; - } - // perform a single search in the DOM and use it across all moveFieldSettings instances - moveFieldSettings.prototype.endMarker = document.getElementById( 'frm-end-form-marker' ); - }; - - this.append = function( field ) { - const classname = null !== field ? field.parentElement.classList : ''; - if ( null === field || ( ! classname.contains( 'frm_field_box' ) && ! classname.contains( 'divider_section_only' ) ) ) { - return; - } - self.fragment.appendChild( field ); - }; - - this.moveFields = function() { - builderForm.insertBefore( self.fragment, moveFieldSettings.prototype.endMarker ); - }; - - this.initOnceInAllInstances(); - - // Move the field if function is called as function with a singleField passed as arg. - // In this particular case only 1 field is needed to be moved so the field will get instantly moved. - // "singleField" may be undefined when it's called as a constructor instead of a function. Use the constructor to add multiple fields which are passed through "append" and move these all at once via "moveFields". - if ( 'undefined' !== typeof singleField ) { - this.append( singleField ); - this.moveFields(); - return; - } - - return { - append: this.append, - moveFields: this.moveFields - }; - - } - - function showEmailRow() { - /*jshint validthis:true */ - const actionKey = jQuery( this ).closest( '.frm_form_action_settings' ).data( 'actionkey' ); - const rowType = this.getAttribute( 'data-emailrow' ); - - jQuery( '#frm_form_action_' + actionKey + ' .frm_' + rowType + '_row' ).fadeIn( 'slow' ); - jQuery( this ).fadeOut( 'slow' ); - } - - function hideEmailRow() { - /*jshint validthis:true */ - const actionBox = jQuery( this ).closest( '.frm_form_action_settings' ), - rowType = this.getAttribute( 'data-emailrow' ), - emailRowSelector = '.frm_' + rowType + '_row', - emailButtonSelector = '.frm_' + rowType + '_button'; - - jQuery( actionBox ).find( emailButtonSelector ).fadeIn( 'slow' ); - jQuery( actionBox ).find( emailRowSelector ).fadeOut( 'slow', function() { - jQuery( actionBox ).find( emailRowSelector + ' input' ).val( '' ); - }); - } - - function showEmailWarning() { - /*jshint validthis:true */ - const actionBox = jQuery( this ).closest( '.frm_form_action_settings' ), - emailRowSelector = '.frm_from_to_match_row', - fromVal = actionBox.find( 'input[name$="[post_content][from]"]' ).val(), - toVal = actionBox.find( 'input[name$="[post_content][email_to]"]' ).val(); - - if ( fromVal === toVal ) { - jQuery( actionBox ).find( emailRowSelector ).fadeIn( 'slow' ); - } else { - jQuery( actionBox ).find( emailRowSelector ).fadeOut( 'slow' ); - } - } - - function checkActiveAction( type ) { - const actionTriggers = document.querySelectorAll( '.frm_' + type + '_action' ); - - if ( isAtLimitForActionType( type ) ) { - const addAlreadyUsedClass = getLimitForActionType( type ) > 0; - markActionTriggersInactive( actionTriggers, addAlreadyUsedClass ); - return; - } - - markActionTriggersActive( actionTriggers ); - } - - function markActionTriggersActive( triggers ) { - triggers.forEach( - trigger => { - if ( trigger.querySelector( '.frm_show_upgrade' ) ) { - // Prevent disabled action becoming active. - return; - } - - trigger.classList.remove( 'frm_inactive_action', 'frm_already_used' ); - trigger.classList.add( 'frm_active_action' ); - } - ); - } - - function markActionTriggersInactive( triggers, addAlreadyUsedClass ) { - triggers.forEach( - trigger => { - trigger.classList.remove( 'frm_active_action' ); - trigger.classList.add( 'frm_inactive_action' ); - if ( addAlreadyUsedClass ) { - trigger.classList.add( 'frm_already_used' ); - } - } - ); - } - - function isAtLimitForActionType( type ) { - let atLimit = getNumberOfActionsForType( type ) >= getLimitForActionType( type ); - - const hookName = 'frm_action_at_limit'; - const hookArgs = { type }; - atLimit = wp.hooks.applyFilters( hookName, atLimit, hookArgs ); - - return atLimit; - } - - function getLimitForActionType( type ) { - return parseInt( jQuery( '.frm_' + type + '_action' ).data( 'limit' ), 10 ); - } - - function getNumberOfActionsForType( type ) { - return jQuery( '.frm_single_' + type + '_settings' ).length; - } - - function actionLimitMessage() { - let message = frmAdminJs.only_one_action; - let limit = this.dataset.limit; - - if ( 'undefined' !== typeof limit ) { - limit = parseInt( limit ); - if ( limit > 1 ) { - message = message.replace( 1, limit ).trim(); - } else { - message += ' ' + frmAdminJs.edit_action_text; - } - } - - infoModal( message ); - } - - function addFormLogicRow() { - /*jshint validthis:true */ - const id = jQuery( this ).data( 'emailkey' ); - const type = jQuery( this ).closest( '.frm_form_action_settings' ).find( '.frm_action_name' ).val(); - const formId = document.getElementById( 'form_id' ).value; - const logicRowsContainer = document.getElementById( 'frm_logic_row_' + id ); - const logicRows = logicRowsContainer.querySelectorAll( '.frm_logic_row' ); - const newRowID = getNewRowId( logicRows, 'frm_logic_' + id + '_' ); - const placeholder = div({ - id: 'frm_logic_' + id + '_' + newRowID, - className: 'frm_logic_row frm_hidden' - }); - - logicRowsContainer.appendChild( placeholder ); - jQuery.ajax({ - type: 'POST', url: ajaxurl, - data: { - action: 'frm_add_form_logic_row', - email_id: id, - form_id: formId, - meta_name: newRowID, - type: type, - nonce: frmGlobal.nonce - }, - success: function( html ) { - jQuery( document.getElementById( 'logic_link_' + id ) ).fadeOut( 'slow', () => { - placeholder.insertAdjacentHTML( 'beforebegin', html ); - placeholder.remove(); - - // Show conditional logic options after "Add Conditional Logic" is clicked. - jQuery( logicRowsContainer ).parent( '.frm_logic_rows' ).fadeIn( 'slow' ); - }); - } - }); - return false; - } - - function checkDupPost() { - /*jshint validthis:true */ - const postField = jQuery( 'select.frm_single_post_field' ); - postField.css( 'border-color', '' ); - const $t = this; - const v = jQuery( $t ).val(); - if ( v === '' || v === 'checkbox' ) { - return false; - } - postField.each( function() { - if ( jQuery( this ).val() === v && this.name !== $t.name ) { - this.style.borderColor = 'red'; - jQuery( $t ).val( '' ); - infoModal( frmAdminJs.field_already_used ); - return false; - } - }); - } - - function togglePostContent() { - /*jshint validthis:true */ - const v = jQuery( this ).val(); - if ( '' === v ) { - jQuery( '.frm_post_content_opt, select.frm_dyncontent_opt' ).hide().val( '' ); - jQuery( '.frm_dyncontent_opt' ).hide(); - } else if ( 'post_content' === v ) { - jQuery( '.frm_post_content_opt' ).show(); - jQuery( '.frm_dyncontent_opt' ).hide(); - jQuery( 'select.frm_dyncontent_opt' ).val( '' ); - } else { - jQuery( '.frm_post_content_opt' ).hide().val( '' ); - jQuery( 'select.frm_dyncontent_opt, .frm_form_field.frm_dyncontent_opt' ).show(); - } - } - - function fillDyncontent() { - /*jshint validthis:true */ - const v = jQuery( this ).val(); - const $dyn = jQuery( document.getElementById( 'frm_dyncontent' ) ); - if ( '' === v || 'new' === v ) { - $dyn.val( '' ); - jQuery( '.frm_dyncontent_opt' ).show(); - } else { - jQuery.ajax({ - type: 'POST', url: ajaxurl, - data: {action: 'frm_display_get_content', id: v, nonce: frmGlobal.nonce}, - success: function( val ) { - $dyn.val( val ); - jQuery( '.frm_dyncontent_opt' ).show(); - } - }); - } - } - - function switchPostType() { - /*jshint validthis:true */ - // update all rows of categories/taxonomies - let curSelect, newSelect, - catRows = document.getElementById( 'frm_posttax_rows' ).childNodes, - postParentField = document.querySelector( '.frm_post_parent_field' ), - postMenuOrderField = document.querySelector( '.frm_post_menu_order_field' ), - postType = this.value; - - // Get new category/taxonomy options - jQuery.ajax({ - type: 'POST', - url: ajaxurl, - data: { - action: 'frm_replace_posttax_options', - post_type: postType, - nonce: frmGlobal.nonce - }, - success: function( html ) { - - // Loop through each category row, and replace the first dropdown - for ( i = 0; i < catRows.length; i++ ) { - // Check if current element is a div - if ( catRows[i].tagName !== 'DIV' ) { - continue; - } - - // Get current category select - curSelect = catRows[i].getElementsByTagName( 'select' )[0]; - - // Set up new select - newSelect = document.createElement( 'select' ); - newSelect.innerHTML = html; - newSelect.className = curSelect.className; - newSelect.name = curSelect.name; - - // Replace the old select with the new select - catRows[i].replaceChild( newSelect, curSelect ); - } - } - }); - - // Get new post parent option. - if ( postParentField ) { - getActionOption( - postParentField, - postType, - 'frm_get_post_parent_option', - function( response, optName ) { - // The replaced string is declared in FrmProFormActionController::ajax_get_post_menu_order_option() in the pro version. - postParentField.querySelector( '.frm_post_parent_opt_wrapper' ).innerHTML = response.replaceAll( 'REPLACETHISNAME', optName ); - initAutocomplete( postParentField ); - } - ); - } - - if ( postMenuOrderField ) { - getActionOption( postMenuOrderField, postType, 'frm_should_use_post_menu_order_option' ); - } - } - - function getActionOption( field, postType, action, successHandler ) { - const opt = field.querySelector( '.frm_autocomplete_value_input' ) || field.querySelector( 'select' ), - optName = opt.getAttribute( 'name' ); - - jQuery.ajax({ - url: ajaxurl, - method: 'POST', - data: { - action: action, - post_type: postType, - _wpnonce: frmGlobal.nonce - }, - success: response => { - if ( 'string' !== typeof response ) { - console.error( response ); - return; - } - - if ( '0' === response ) { - // This post type does not support this field. - field.classList.add( 'frm_hidden' ); - field.value = ''; - return; - } - - field.classList.remove( 'frm_hidden' ); - - if ( 'function' === typeof successHandler ) { - successHandler( response, optName ); - } - }, - error: response => console.error( response ) - }); - } - - function addPosttaxRow() { - /*jshint validthis:true */ - addPostRow( 'tax', this ); - } - - function addPostmetaRow() { - /*jshint validthis:true */ - addPostRow( 'meta', this ); - } - - function addPostRow( type, button ) { - let name, - id = jQuery( 'input[name="id"]' ).val(), - settings = jQuery( button ).closest( '.frm_form_action_settings' ), - key = settings.data( 'actionkey' ), - postType = settings.find( '.frm_post_type' ).val(), - metaName = 0, - postTypeRows = document.querySelectorAll( '.frm_post' + type + '_row' ); - - if ( postTypeRows.length ) { - name = postTypeRows[ postTypeRows.length - 1 ].id.replace( 'frm_post' + type + '_', '' ); - if ( isNumeric( name ) ) { - metaName = 1 + parseInt( name, 10 ); - } else { - metaName = 1; - } - } - - jQuery.ajax({ - type: 'POST', url: ajaxurl, - data: { - action: 'frm_add_post' + type + '_row', - form_id: id, - meta_name: metaName, - tax_key: metaName, - post_type: postType, - action_key: key, - nonce: frmGlobal.nonce - }, - success: function( html ) { - let cfOpts, optIndex; - jQuery( document.getElementById( 'frm_post' + type + '_rows' ) ).append( html ); - jQuery( '.frm_add_post' + type + '_row.button' ).hide(); - - if ( type === 'meta' ) { - jQuery( '.frm_name_value' ).show(); - cfOpts = document.querySelectorAll( '.frm_toggle_cf_opts' ); - for ( optIndex = 0; optIndex < cfOpts.length - 1; ++optIndex ) { - cfOpts[ optIndex ].style.display = 'none'; - } - } else if ( type === 'tax' ) { - jQuery( '.frm_posttax_labels' ).show(); - } - } - }); - } - - function isNumeric( value ) { - return ! isNaN( parseFloat( value ) ) && isFinite( value ); - } - - function changePosttaxRow() { - /*jshint validthis:true */ - if ( ! jQuery( this ).closest( '.frm_posttax_row' ).find( '.frm_posttax_opt_list' ).length ) { - return; - } - - jQuery( this ).closest( '.frm_posttax_row' ).find( '.frm_posttax_opt_list' ).html( '
      ' ); - - const postType = jQuery( this ).closest( '.frm_form_action_settings' ).find( 'select[name$="[post_content][post_type]"]' ).val(), - actionKey = jQuery( this ).closest( '.frm_form_action_settings' ).data( 'actionkey' ), - taxKey = jQuery( this ).closest( '.frm_posttax_row' ).attr( 'id' ).replace( 'frm_posttax_', '' ), - metaName = jQuery( this ).val(), - showExclude = jQuery( document.getElementById( taxKey + '_show_exclude' ) ).is( ':checked' ) ? 1 : 0, - fieldId = jQuery( 'select[name$="[post_category][' + taxKey + '][field_id]"]' ).val(), - id = jQuery( 'input[name="id"]' ).val(); - - jQuery.ajax({ - type: 'POST', - url: ajaxurl, - data: { - action: 'frm_add_posttax_row', - form_id: id, - post_type: postType, - tax_key: taxKey, - action_key: actionKey, - meta_name: metaName, - field_id: fieldId, - show_exclude: showExclude, - nonce: frmGlobal.nonce - }, - success: function( html ) { - const $tax = jQuery( document.getElementById( 'frm_posttax_' + taxKey ) ); - $tax.replaceWith( html ); - } - }); - } - - function toggleCfOpts() { - /*jshint validthis:true */ - const row = jQuery( this ).closest( '.frm_postmeta_row' ); - const cancel = row.find( '.frm_cancelnew' ); - const select = row.find( '.frm_enternew' ); - if ( row.find( 'select.frm_cancelnew' ).is( ':visible' ) ) { - cancel.hide(); - select.show(); - } else { - cancel.show(); - select.hide(); - } - - row.find( 'input.frm_enternew, select.frm_cancelnew' ).val( '' ); - return false; - } - - function toggleFormOpts() { - /*jshint validthis:true */ - const changedOpt = jQuery( this ); - let val = changedOpt.val(); - if ( changedOpt.attr( 'type' ) === 'checkbox' ) { - if ( this.checked === false ) { - val = ''; - } - } - - const toggleClass = changedOpt.data( 'toggleclass' ); - if ( val === '' ) { - jQuery( '.' + toggleClass ).hide(); - } else { - jQuery( '.' + toggleClass ).show(); - jQuery( '.hide_' + toggleClass + '_' + val ).hide(); - } - } - - function submitSettings() { - if ( showNameYourFormModal() ) { - return; - } - - /*jshint validthis:true */ - preFormSave( this ); - triggerSubmit( document.querySelector( '.frm_form_settings' ) ); - } - - /* Customization Panel */ - function insertCode( e ) { - /*jshint validthis:true */ - e.preventDefault(); - insertFieldCode( jQuery( this ), this.getAttribute( 'data-code' ) ); - return false; - } - - function insertFieldCode( element, variable ) { - let rich = false, - elementId = element; - if ( typeof element === 'object' ) { - if ( element.hasClass( 'frm_noallow' ) ) { - return; - } - - elementId = jQuery( element ).closest( '[data-fills]' ).attr( 'data-fills' ); - if ( typeof elementId === 'undefined' ) { - elementId = element.closest( 'div' ).attr( 'class' ); - if ( typeof elementId !== 'undefined' ) { - elementId = elementId.split( ' ' )[1]; - } - } - } - - if ( typeof elementId === 'undefined' ) { - let active = document.activeElement; - if ( active.type === 'search' ) { - // If the search field has focus, find the correct field. - elementId = active.id.replace( '-search-input', '' ); - if ( elementId.match( /\d/gi ) === null ) { - active = jQuery( '.frm-single-settings:visible .' + elementId ); - elementId = active.attr( 'id' ); - } - } else { - elementId = active.id; - } - } - - if ( elementId ) { - rich = jQuery( '#wp-' + elementId + '-wrap.wp-editor-wrap' ).length > 0; - } - - const contentBox = jQuery( document.getElementById( elementId ) ); - if ( typeof element.attr( 'data-shortcode' ) === 'undefined' && ( ! contentBox.length || typeof contentBox.attr( 'data-shortcode' ) === 'undefined' ) ) { - // this helps to exclude those that don't want shortcode-like inserted content e.g. frm-pro's summary field - const doShortcode = element.parents( 'ul.frm_code_list' ).attr( 'data-shortcode' ); - if ( doShortcode === 'undefined' || doShortcode !== 'no' ) { - variable = '[' + variable + ']'; - } - } - - if ( rich ) { - wpActiveEditor = elementId; - } - - if ( ! contentBox.length ) { - return false; - } - - if ( variable === '[default-html]' || variable === '[default-plain]' ) { - let p = 0; - if ( variable === '[default-plain]' ) { - p = 1; - } - jQuery.ajax({ - type: 'POST', url: ajaxurl, - data: { - action: 'frm_get_default_html', - form_id: jQuery( 'input[name="id"]' ).val(), - plain_text: p, - nonce: frmGlobal.nonce - }, - elementId: elementId, - success: function( msg ) { - if ( rich ) { - const p = document.createElement( 'p' ); - p.innerText = msg; - send_to_editor( p.innerHTML ); - } else { - insertContent( contentBox, msg ); - } - } - }); - } else { - variable = maybeAddSanitizeUrlToShortcodeVariable( variable, element, contentBox ); - if ( rich ) { - send_to_editor( variable ); - } else { - insertContent( contentBox, variable ); - } - } - return false; - } - - function maybeAddSanitizeUrlToShortcodeVariable( variable, element, contentBox ) { - if ( 'object' !== typeof element || ! ( element instanceof jQuery ) || 0 !== contentBox[0].id.indexOf( 'success_url_' ) ) { - return variable; - } - - element = element[0]; - if ( ! element.closest( '#frm-insert-fields-box' ) ) { - // Only add sanitize_url=1 to field shortcodes. - return variable; - } - - if ( ! element.parentNode.classList.contains( 'frm_insert_url' ) ) { - variable = variable.replace( ']', ' sanitize_url=1]' ); - } - - return variable; - } - - function insertContent( contentBox, variable ) { - if ( document.selection ) { - contentBox[0].focus(); - document.selection.createRange().text = variable; - } else { - obj = contentBox[0]; - const e = obj.selectionEnd; - - variable = maybeFormatInsertedContent( contentBox, variable, obj.selectionStart, e ); - - obj.value = obj.value.substr( 0, obj.selectionStart ) + variable + obj.value.substr( obj.selectionEnd, obj.value.length ); - - const s = e + variable.length; - - maybeRemoveLayoutClasses( obj, variable ); - - obj.focus(); - obj.setSelectionRange( s, s ); - } - triggerChange( contentBox ); - } - - /** - * When a layout class is added, remove any previous layout classes to avoid conflicts. - * We only expect one layout class to exist for a given field. - * For example, if a field has frm_half and we set it to frm_third, frm_half will be removed. - * - * @since 6.11 - * - * @param {HTMLElement} obj - * @param {string} variable - * @return {void} - */ - function maybeRemoveLayoutClasses( obj, variable ) { - if ( ! obj.classList.contains( 'frm_classes' ) || ! isALayoutClass( variable ) ) { - return; - } - - const removeClasses = obj.value.split( ' ' ).filter( isALayoutClass ); - if ( removeClasses.length ) { - obj.value = maybeRemoveClasses( obj.value, removeClasses, variable.trim() ); - } - } - - /** - * Check if a given class is a layout class. - * - * @since 6.11 - * - * @param {string} className - * @return {boolean} - */ - function isALayoutClass( className ) { - let layoutClasses = [ 'frm_half', 'frm_third', 'frm_two_thirds', 'frm_fourth', 'frm_three_fourths', 'frm_fifth', 'frm_sixth', 'frm2', 'frm3', 'frm4', 'frm6', 'frm8', 'frm9', 'frm10', 'frm12' ]; - return layoutClasses.includes( className.trim() ); - } - - /** - * @since 6.11 - * - * @param {string} beforeValue - * @param {Array} removeClasses - * @param {string} variable - * @return {string} - */ - function maybeRemoveClasses( beforeValue, removeClasses, variable ) { - const currentClasses = beforeValue.split( ' ' ).filter( - currentClass => { - currentClass = currentClass.trim(); - return currentClass.length && ! removeClasses.includes( currentClass ); - } - ); - if ( ! currentClasses.includes( variable ) ) { - currentClasses.push( variable ); - } - return currentClasses.join( ' ' ); - } - - function maybeFormatInsertedContent( input, textToInsert, selectionStart, selectionEnd ) { - const separator = input.data( 'sep' ); - if ( undefined === separator ) { - return textToInsert; - } - - const value = input.val(); - - if ( ! value.trim().length ) { - return textToInsert; - } - - const startPattern = new RegExp( separator + '\\s*$' ); - const endPattern = new RegExp( '^\\s*' + separator ); - - if ( value.substr( 0, selectionStart ).trim().length && false === startPattern.test( value.substr( 0, selectionStart ) ) ) { - textToInsert = separator + textToInsert; - } - - if ( value.substr( selectionEnd, value.length ).trim().length && false === endPattern.test( value.substr( selectionEnd, value.length ) ) ) { - textToInsert += separator; - } - - return textToInsert; - } - - function resetLogicBuilder() { - /*jshint validthis:true */ - const id = document.getElementById( 'frm-id-condition' ), - key = document.getElementById( 'frm-key-condition' ); - - if ( this.checked ) { - id.classList.remove( 'frm_hidden' ); - key.classList.add( 'frm_hidden' ); - triggerEvent( key, 'change' ); - } else { - id.classList.add( 'frm_hidden' ); - key.classList.remove( 'frm_hidden' ); - triggerEvent( id, 'change' ); - } - } - - function setLogicExample() { - let field, code, - idKey = document.getElementById( 'frm-id-key-condition' ).checked ? 'frm-id-condition' : 'frm-key-condition', - is = document.getElementById( 'frm-is-condition' ).value, - text = document.getElementById( 'frm-text-condition' ).value, - result = document.getElementById( 'frm-insert-condition' ); - - idKey = document.getElementById( idKey ); - field = idKey.options[idKey.selectedIndex].value; - code = 'if ' + field + ' ' + is + '="' + text + '"]'; - result.setAttribute( 'data-code', code + frmAdminJs.conditional_text + '[/if ' + field ); - result.innerHTML = '[' + code + '[/if ' + field + ']'; - } - - function showBuilderModal() { - /*jshint validthis:true */ - const moreIcon = getIconForInput( this ); - showInlineModal( moreIcon, this ); - } - - function maybeShowModal( input ) { - let moreIcon; - if ( input.parentNode.parentNode.classList.contains( 'frm_has_shortcodes' ) ) { - hideShortcodes(); - moreIcon = getIconForInput( input ); - if ( moreIcon.tagName === 'use' ) { - moreIcon = moreIcon.firstElementChild; - - if ( moreIcon.getAttributeNS( 'http://www.w3.org/1999/xlink', 'href' ).indexOf( 'frm_close_icon' ) === -1 ) { - showShortcodeBox( moreIcon, 'nofocus' ); - } - } else if ( ! moreIcon.classList.contains( 'frm_close_icon' ) ) { - showShortcodeBox( moreIcon, 'nofocus' ); - } - } - } - - function showShortcodes( e ) { - /*jshint validthis:true */ - e.preventDefault(); - e.stopPropagation(); - - showShortcodeBox( this ); - } - - /** - * Handles 'change' event on the document. - * - * @since 6.16.3 - * - * @param {Event} event - * @returns {Void} - */ - function handleBuilderChangeEvent( event ) { - maybeShowSaveAndReloadModal( event.target ); - } - - /** - * Shows 'Save and Reload' modal if the target field's type is changed. - * - * @since 6.16.3 - * - * @param {HTMLElement} target - * @returns {Void} - */ - function maybeShowSaveAndReloadModal( target ) { - if ( ! target.id.startsWith( 'field_options_type_' ) ) { - return; - } - const idParts = target.id.split( '_' ); - const fieldId = idParts.length && idParts[ idParts.length - 1 ]; - - if ( document.querySelector( `#frm-single-settings-${fieldId}` )?.classList.contains( `frm-type-${target.value}` ) ) { - // Do not show modal if the field type is reverted back to the original type when builder is loaded. - return; - } - showSaveAndReloadModal(); - } - - /** - * Shows 'Save and Reload' modal with the given message. - * - * @since 6.16.3 - * - * @param {string} message - * @returns {Void} - */ - function showSaveAndReloadModal( message ) { - if ( 'undefined' === typeof message ) { - message = __( 'You are changing the field type. Not all field settings will appear as expected until you reload the page. Would you like to reload the page now?', 'formidable' ); - } - frmDom.modal.maybeCreateModal( - 'frmSaveAndReloadModal', - { - title: __( 'Save and Reload?', 'formidable' ), - content: getModalContent(), - footer: getModalFooter() - } - ); - - function getModalContent() { - const modalContent = div( message ); - modalContent.style.padding = 'var(--gap-md)'; - return modalContent; - } - - function getModalFooter() { - const continueButton = frmDom.modal.footerButton({ - text: __( 'Save and Reload', 'formidable' ), - buttonType: 'primary' - }); - - onClickPreventDefault( continueButton, () => { - saveAndReloadFormBuilder(); - } ); - - const cancelButton = frmDom.modal.footerButton({ - text: __( 'Cancel', 'formidable' ), - buttonType: 'cancel' - }); - cancelButton.classList.add( 'dismiss' ); - - return frmDom.div({ - children: [ cancelButton, continueButton ] - }); - } - } - - function updateShortcodesPopupPosition( target ) { - let moreIcon; - if ( target instanceof Event ) { - const useElements = document.querySelectorAll( '.frm-single-settings .frm-show-box.frmsvg use' ); - const openTrigger = Array.from( useElements ).find( use => use.getAttribute( 'href' ) === '#frm_close_icon' ); - if ( 'undefined' === typeof openTrigger ) { - return; - } - moreIcon = openTrigger.parentElement; - } else { - moreIcon = target; - } - - const moreIconPosition = moreIcon.getBoundingClientRect(); - const shortCodesPopup = document.getElementById( 'frm_adv_info' ); - const parentPos = shortCodesPopup.parentElement.getBoundingClientRect(); - - shortCodesPopup.style.top = ( moreIconPosition.top - parentPos.top + 32 ) + 'px'; - shortCodesPopup.style.left = ( moreIconPosition.left - parentPos.left - 280 ) + 'px'; - } - - function showShortcodeBox( moreIcon, shouldFocus ) { - let input = getInputForIcon( moreIcon ), - box = document.getElementById( 'frm_adv_info' ), - classes = moreIcon.className; - - if ( moreIcon.tagName === 'svg' ) { - moreIcon = moreIcon.firstElementChild; - } - if ( moreIcon.tagName === 'use' ) { - classes = moreIcon.getAttributeNS( 'http://www.w3.org/1999/xlink', 'href' ); - - if ( null === classes ) { - // If the deprecated xlink:href is not defined, check for href. - classes = moreIcon.getAttribute( 'href' ); - } - } - - if ( classes.indexOf( 'frm_close_icon' ) !== -1 ) { - hideShortcodes( box ); - } else { - updateShortcodesPopupPosition( moreIcon ); - - jQuery( '.frm_code_list a' ).removeClass( 'frm_noallow' ); - if ( input.classList.contains( 'frm_not_email_to' ) ) { - jQuery( '#frm-insert-fields-box .frm_code_list li:not(.show_frm_not_email_to) a' ).addClass( 'frm_noallow' ); - } else if ( input.classList.contains( 'frm_not_email_subject' ) ) { - jQuery( '.frm_code_list li.hide_frm_not_email_subject a' ).addClass( 'frm_noallow' ); - } - - box.setAttribute( 'data-fills', input.id ); - box.style.display = 'block'; - - if ( moreIcon.tagName === 'use' ) { - if ( moreIcon.hasAttributeNS( 'http://www.w3.org/1999/xlink', 'href' ) ) { - moreIcon.setAttributeNS( 'http://www.w3.org/1999/xlink', 'href', '#frm_close_icon' ); - } else { - const newMoreIcon = document.createElementNS( 'http://www.w3.org/2000/svg', 'use' ); - newMoreIcon.setAttributeNS( 'http://www.w3.org/1999/xlink', 'href', '#frm_close_icon' ); - moreIcon.parentNode.replaceChild( newMoreIcon, moreIcon ); - } - } else { - moreIcon.className = classes.replace( 'frm_more_horiz_solid_icon', 'frm_close_icon' ); - } - - if ( shouldFocus !== 'nofocus' ) { - if ( 'none' !== input.style.display ) { - input.focus(); - } else { - jQuery( tinymce.get( input.id ) ).trigger( 'focus' ); - } - } - showOrHideContextualShortcodes( input ); - } - } - - /** - * Returns true if a shortcode could be shown in the search result. - * - * @since 6.16.3 - * - * @param {HTMLElement} item - * @returns {Boolean} - */ - function checkContextualShortcode( item ) { - if ( frmAdminJs.contextualShortcodes.length === 0 ) { - return true; - } - return ! isContextualShortcode( item ) || canShowContextualShortcode( item ); - } - - /** - * Returns true if a shortcode is contextual to fields. - * - * @since 6.16.3 - * - * @param {HTMLElement} item - * @returns {Boolean} - */ - function isContextualShortcode( item ) { - const anchor = item.querySelector( 'a' ); - if ( ! anchor ) { - return false; - } - - const shortcode = anchor.dataset.code; - return frmAdminJs.contextualShortcodes.address.includes( shortcode ) || frmAdminJs.contextualShortcodes.body.includes( shortcode ); - } - - /** - * @since 6.16.3 - * - * @param {HTMLElement} item - * @returns {Boolean} - */ - function canShowContextualShortcode( item ) { - const shortcode = item.querySelector( 'a' ).dataset.code; - const inputId = document.getElementById( 'frm_adv_info' ).dataset.fills; - const input = document.getElementById( inputId ); - const contextualShortcodes = frmAdminJs.contextualShortcodes; - if ( contextualShortcodes.address.includes( shortcode ) ) { - return input.matches( contextualShortcodes.addressSelector ); - } - return input.matches( contextualShortcodes.bodySelector ); - } - - /** - * @since 6.16.3 - * - * @param {HTMLElement} input - * @returns {Void} - */ - function showOrHideContextualShortcodes( input ) { - [ 'address', 'body' ].forEach( type => { - toggleContextualShortcodes( input, type ); - }); - } - - /** - * @since 6.16.3 - * - * @param {HTMLElement} input - * @param {string} type - * - * @returns {Void} - */ - function toggleContextualShortcodes( input, type ) { - let selector, contextualShortcodes; - selector = frmAdminJs.contextualShortcodes[ type + 'Selector' ]; - contextualShortcodes = frmAdminJs.contextualShortcodes[ type ]; - let shouldShowShortcodes = input.matches( selector ); - for ( let shortcode of contextualShortcodes ) { - const shortcodeLi = document.querySelector( '#frm-adv-info-tab .frm_code_list [data-code="' + shortcode + '"]' )?.closest( 'li'); - shortcodeLi?.classList.toggle( 'frm_hidden', ! shouldShowShortcodes ); - } - } - - /** - * Returns shortcodes that are contextual to the current input field. - * - * @since 6.16.3 - * - * @returns {Array} - */ - function getContextualShortcodes() { - let contextualShortcodes = document.getElementById( 'frm_adv_info' )?.dataset.contextualShortcodes; - if ( ! contextualShortcodes) { - return []; - } - contextualShortcodes = JSON.parse( contextualShortcodes ); - contextualShortcodes.addressSelector = '[id^=email_to], [id^=from_], [id^=cc], [id^=bcc]'; - contextualShortcodes.bodySelector = '[id^=email_message_]'; - return contextualShortcodes; - } - - function fieldUpdated() { - if ( ! fieldsUpdated ) { - fieldsUpdated = 1; - window.addEventListener( 'beforeunload', confirmExit ); - } - } - - function buildSubmittedNoAjax() { - // set fieldsUpdated to 0 to avoid the unsaved changes pop up - fieldsUpdated = 0; - } - - function settingsSubmitted() { - // set fieldsUpdated to 0 to avoid the unsaved changes pop up - fieldsUpdated = 0; - } - - function saveAndReloadSettings() { - let page, form; - page = document.getElementById( 'form_settings_page' ); - if ( null !== page ) { - form = page.querySelector( 'form.frm_form_settings' ); - if ( null !== form ) { - fieldsUpdated = 0; - form.submit(); - } - } - } - - function reloadIfAddonActivatedAjaxSubmitOnly() { - const submitButton = document.getElementById( 'frm_submit_side_top' ); - if ( submitButton.hasAttribute( 'data-new-addon-installed' ) && 'true' === submitButton.getAttribute( 'data-new-addon-installed' ) ) { - submitButton.removeAttribute( 'data-new-addon-installed' ); - window.location.reload(); - } - - } - - function saveAndReloadFormBuilder() { - const submitButton = document.getElementById( 'frm_submit_side_top' ); - if ( submitButton.classList.contains( 'frm_submit_ajax' ) ) { - submitButton.setAttribute( 'data-new-addon-installed', true ); - } - submitButton.click(); - } - - function confirmExit( event ) { - if ( fieldsUpdated ) { - event.preventDefault(); - event.returnValue = ''; - } - } - - function bindClickForDialogClose( $modal ) { - const closeModal = function() { - $modal.dialog( 'close' ); - }; - jQuery( '.ui-widget-overlay' ).on( 'click', closeModal ); - $modal.on( 'click', 'a.dismiss', closeModal ); - } - - function offsetModalY( $modal, amount ) { - const position = { - my: 'top', - at: 'top+' + amount, - of: window - }; - $modal.dialog( 'option', 'position', position ); - } - - /** - * Get the input box for the selected ... icon. - */ - function getInputForIcon( moreIcon ) { - let input = moreIcon.nextElementSibling; - - while ( input !== null && input.tagName !== 'INPUT' && input.tagName !== 'TEXTAREA' ) { - input = getInputForIcon( input ); - } - - return input; - } - - /** - * Get the ... icon for the selected input box. - */ - function getIconForInput( input ) { - let moreIcon = input.previousElementSibling; - - while ( moreIcon !== null && moreIcon.tagName !== 'I' && moreIcon.tagName !== 'svg' ) { - moreIcon = getIconForInput( moreIcon ); - } - - return moreIcon; - } - - function hideShortcodes( box ) { - let i, u, closeIcons, closeSvg; - if ( typeof box === 'undefined' ) { - box = document.getElementById( 'frm_adv_info' ); - if ( box === null ) { - return; - } - } - - if ( document.getElementById( 'frm_dyncontent' ) !== null ) { - // Don't run when in the sidebar. - return; - } - - box.style.display = 'none'; - - closeIcons = document.querySelectorAll( '.frm-show-box.frm_close_icon' ); - for ( i = 0; i < closeIcons.length; i++ ) { - closeIcons[i].classList.remove( 'frm_close_icon' ); - closeIcons[i].classList.add( 'frm_more_horiz_solid_icon' ); - } - - closeSvg = document.querySelectorAll( '.frm_has_shortcodes use' ); - for ( u = 0; u < closeSvg.length; u++ ) { - if ( closeSvg[u].getAttributeNS( 'http://www.w3.org/1999/xlink', 'href' ) === '#frm_close_icon' ) { - if ( closeSvg[u].closest( '.frm_remove_field' ) ) { - // Don't change the icon for the email fields remove button. - continue; - } - closeSvg[u].setAttributeNS( 'http://www.w3.org/1999/xlink', 'href', '#frm_more_horiz_solid_icon' ); - } - } - } - - function toggleAllowedHTML( input ) { - let b, - id = input.id; - if ( typeof id === 'undefined' || id.indexOf( '-search-input' ) !== -1 ) { - return; - } - - jQuery( '#frm-adv-info-tab' ).attr( 'data-fills', id.trim() ); - if ( input.classList.contains( 'field_custom_html' ) ) { - id = 'field_custom_html'; - } - - b = [ 'after_html', 'before_html', 'submit_html', 'field_custom_html' ]; - if ( jQuery.inArray( id, b ) >= 0 ) { - jQuery( '.frm_code_list li:not(.show_' + id + ')' ).addClass( 'frm_hidden' ); - jQuery( '.frm_code_list li.show_' + id ).removeClass( 'frm_hidden' ); - } - } - - function toggleKeyID( switchTo, e ) { - e.stopPropagation(); - jQuery( '.frm_code_list .frmids, .frm_code_list .frmkeys' ).addClass( 'frm_hidden' ); - jQuery( '.frm_code_list .' + switchTo ).removeClass( 'frm_hidden' ); - jQuery( '.frmids, .frmkeys' ).removeClass( 'current' ); - jQuery( '.' + switchTo ).addClass( 'current' ); - } - - function onActionLoaded( event ) { - const settings = event.target.closest( '.frm_form_action_settings' ); - if ( settings && ( settings.classList.contains( 'frm_single_email_settings' ) || settings.classList.contains( 'frm_single_on_submit_settings' ) ) ) { - initWysiwygOnActionLoaded( settings ); - } - } - - function initWysiwygOnActionLoaded( settings ) { - settings.querySelectorAll( '.wp-editor-area' ).forEach( wysiwyg => { - frmDom.wysiwyg.init( - wysiwyg, - { height: 160, addFocusEvents: true } - ); - }); - } - - /* Global settings page */ - function loadSettingsTab( anchor ) { - const holder = anchor.replace( '#', '' ); - const holderContainer = jQuery( '.frm_' + holder + '_ajax' ); - if ( holderContainer.length ) { - jQuery.ajax({ - type: 'POST', url: ajaxurl, - data: { - 'action': 'frm_settings_tab', - 'tab': holder.replace( '_settings', '' ), - 'nonce': frmGlobal.nonce - }, - success: function( html ) { - holderContainer.replaceWith( html ); - } - }); - } - } - - function uninstallNow() { - /*jshint validthis:true */ - if ( confirmLinkClick( this ) === true ) { - jQuery( '.frm_uninstall .frm-wait' ).css( 'visibility', 'visible' ); - jQuery.ajax({ - type: 'POST', - url: ajaxurl, - data: 'action=frm_uninstall&nonce=' + frmGlobal.nonce, - success: function( msg ) { - jQuery( '.frm_uninstall' ).fadeOut( 'slow' ); - window.location = msg; - } - }); - } - return false; - } - - function saveAddonLicense() { - /*jshint validthis:true */ - const button = jQuery( this ); - const buttonName = this.name; - const pluginSlug = this.getAttribute( 'data-plugin' ); - const action = buttonName.replace( 'edd_' + pluginSlug + '_license_', '' ); - let license = document.getElementById( 'edd_' + pluginSlug + '_license_key' ).value; - button.get(0).disabled = true; - jQuery.ajax({ - type: 'POST', url: ajaxurl, dataType: 'json', - data: {action: 'frm_addon_' + action, license: license, plugin: pluginSlug, nonce: frmGlobal.nonce}, - success: function( msg ) { - button.get(0).disabled = false; - const thisRow = button.closest( '.edd_frm_license_row' ); - if ( action === 'deactivate' ) { - license = ''; - document.getElementById( 'edd_' + pluginSlug + '_license_key' ).value = ''; - } - thisRow.find( '.edd_frm_license' ).html( license ); - const eddWrapper = button.get(0).closest( '.frm_form_field' ); - const actionIsSuccess = msg.success === true; - eddWrapper.querySelector( `.frm_icon_font.frm_action_success` ).classList.toggle( 'frm_hidden', ! actionIsSuccess || action === 'deactivate' ); - eddWrapper.querySelector( `.frm_icon_font.frm_action_error` ).classList.toggle( 'frm_hidden', actionIsSuccess); - - const messageBox = thisRow.find( '.frm_license_msg' ); - messageBox.html( msg.message ); - if ( msg.message !== '' ) { - setTimeout( function() { - messageBox.html( '' ); - thisRow.find( '.frm_icon_font' ).addClass( 'frm_hidden' ); - if ( actionIsSuccess ) { - const actionIsActivate = action === 'activate'; - thisRow.get(0).querySelector( '.edd_frm_unauthorized' ).classList.toggle( 'frm_hidden', actionIsActivate ); - thisRow.get(0).querySelector( '.edd_frm_authorized' ).classList.toggle( 'frm_hidden', ! actionIsActivate ); - } - }, 2000 ); - } - } - }); - } - - /* Import/Export page */ - - function startFormMigration( event ) { - event.preventDefault(); - - const checkedBoxes = jQuery( event.target ).find( 'input:checked' ); - if ( ! checkedBoxes.length ) { - return; - } - - const ids = []; - checkedBoxes.each( function( i ) { - ids[i] = this.value; - }); - - // Begin the import process. - importForms( ids, event.target ); - } - - /** - * Begins the process of importing the forms. - */ - function importForms( forms, targetForm ) { - - // Hide the form select section. - const $form = jQuery( targetForm ), - $processSettings = $form.next( '.frm-importer-process' ); - - // Display total number of forms we have to import. - $processSettings.find( '.form-total' ).text( forms.length ); - $processSettings.find( '.form-current' ).text( '1' ); - - $form.hide(); - - // Show processing status. - // '.process-completed' might have been shown earlier during a previous import, so hide now. - $processSettings.find( '.process-completed' ).hide(); - $processSettings.show(); - - // Create global import queue. - s.importQueue = forms; - s.imported = 0; - - // Import the first form in the queue. - importForm( $processSettings ); - } - - /** - * Imports a single form from the import queue. - */ - function importForm( $processSettings ) { - const formID = s.importQueue[0], - provider = jQuery( '#welcome-panel' ).find( 'input[name="slug"]' ).val(), - data = { - action: 'frm_import_' + provider, - form_id: formID, - nonce: frmGlobal.nonce - }; - - // Trigger AJAX import for this form. - jQuery.post( ajaxurl, data, function( res ) { - - if ( res.success ) { - let statusUpdate; - - if ( res.data.error ) { - statusUpdate = '

      ' + res.data.name + ': ' + res.data.msg + '

      '; - } else { - statusUpdate = '

      Imported ' + res.data.name + '

      '; - } - - $processSettings.find( '.status' ).prepend( statusUpdate ); - $processSettings.find( '.status' ).show(); - - // Remove this form ID from the queue. - s.importQueue = jQuery.grep( s.importQueue, function( value ) { - return value != formID; - }); - s.imported++; - - if ( s.importQueue.length === 0 ) { - $processSettings.find( '.process-count' ).hide(); - $processSettings.find( '.forms-completed' ).text( s.imported ); - $processSettings.find( '.process-completed' ).show(); - } else { - // Import next form in the queue. - $processSettings.find( '.form-current' ).text( s.imported + 1 ); - importForm( $processSettings ); - } - } - }); - } - - function validateExport( e ) { - /*jshint validthis:true */ - e.preventDefault(); - - let s = false; - const $exportForms = jQuery( 'input[name="frm_export_forms[]"]' ); - - if ( ! jQuery( 'input[name="frm_export_forms[]"]:checked' ).val() ) { - $exportForms.closest( '.frm-table-box' ).addClass( 'frm_blank_field' ); - s = 'stop'; - } - - const $exportType = jQuery( 'input[name="type[]"]' ); - if ( ! jQuery( 'input[name="type[]"]:checked' ).val() && $exportType.attr( 'type' ) === 'checkbox' ) { - $exportType.closest( 'p' ).addClass( 'frm_blank_field' ); - s = 'stop'; - } - - if ( s === 'stop' ) { - return false; - } - - e.stopPropagation(); - this.submit(); - } - - function removeExportError() { - /*jshint validthis:true */ - const t = jQuery( this ).closest( '.frm_blank_field' ); - if ( typeof t === 'undefined' ) { - return; - } - - const $thisName = this.name; - if ( $thisName === 'type[]' && jQuery( 'input[name="type[]"]:checked' ).val() ) { - t.removeClass( 'frm_blank_field' ); - } else if ( $thisName === 'frm_export_forms[]' && jQuery( this ).val() ) { - t.removeClass( 'frm_blank_field' ); - } - - } - - function checkCSVExtension() { - /*jshint validthis:true */ - const f = jQuery( this ).val(); - const re = /\.csv$/i; - if ( f.match( re ) !== null ) { - jQuery( '.show_csv' ).fadeIn(); - } else { - jQuery( '.show_csv' ).fadeOut(); - } - } - - function getExportOption() { - const exportFormatSelect = document.querySelector( 'select[name="format"]' ); - if ( exportFormatSelect ) { - return exportFormatSelect.value; - } - return ''; - } - - function exportTypeChanged( event ) { - const value = event.target.value; - showOrHideRepeaters( value ); - checkExportTypes.call( event.target ); - checkSelectedAllFormsCheckbox( value ); - } - - function checkSelectedAllFormsCheckbox( exportType ) { - const selectAllCheckbox = document.getElementById( 'frm-export-select-all' ); - if ( exportType === 'csv' ) { - selectAllCheckbox.checked = false; - selectAllCheckbox.disabled = true; - } else { - selectAllCheckbox.disabled = false; - } - } - - function checkExportTypes() { - /*jshint validthis:true */ - const $dropdown = jQuery( this ); - const $selected = $dropdown.find( ':selected' ); - const s = $selected.data( 'support' ); - - const multiple = s.indexOf( '|' ); - jQuery( 'input[name="type[]"]' ).each( function() { - this.checked = false; - if ( s.indexOf( this.value ) >= 0 ) { - this.disabled = false; - if ( multiple === -1 ) { - this.checked = true; - } - } else { - this.disabled = true; - } - }); - - if ( $dropdown.val() === 'csv' ) { - jQuery( '.csv_opts' ).show(); - jQuery( '.xml_opts' ).hide(); - } else { - jQuery( '.csv_opts' ).hide(); - jQuery( '.xml_opts' ).show(); - } - - const c = $selected.data( 'count' ); - const exportField = jQuery( 'input[name="frm_export_forms[]"]' ); - if ( c === 'single' ) { - exportField.prop( 'multiple', false ); - exportField.prop( 'checked', false ); - } else { - exportField.prop( 'multiple', true ); - exportField.prop( 'disabled', false ); - } - $dropdown.trigger( 'change' ); - } - - function showOrHideRepeaters( exportOption ) { - if ( exportOption === '' ) { - return; - } - - const repeaters = document.querySelectorAll( '.frm-is-repeater' ); - if ( ! repeaters.length ) { - return; - } - - if ( exportOption === 'csv' ) { - repeaters.forEach( form => { - form.classList.remove( 'frm_hidden' ); - }); - } else { - repeaters.forEach( form => { - form.classList.add( 'frm_hidden' ); - }); - } - - searchContent.call( document.querySelector( '.frm-auto-search' ) ); - } - - function preventMultipleExport() { - const type = jQuery( 'select[name=format]' ), - selected = type.find( ':selected' ), - count = selected.data( 'count' ), - exportField = jQuery( 'input[name="frm_export_forms[]"]' ); - - if ( count === 'single' ) { - // Disable all other fields to prevent multiple selections. - if ( this.checked ) { - exportField.prop( 'disabled', true ); - this.removeAttribute( 'disabled' ); - } else { - exportField.prop( 'disabled', false ); - } - } else { - exportField.prop( 'disabled', false ); - } - } - - function initiateMultiselect() { - jQuery( '.frm_multiselect' ).hide().each( frmDom.bootstrap.multiselect.init ); - } - - /* Addons page */ - function installMultipleAddons( e ) { - e.preventDefault(); - toggleAddonState( this, 'frm_multiple_addons' ); - } - - function activateAddon( e ) { - e.preventDefault(); - toggleAddonState( this, 'frm_activate_addon' ); - } - - function installAddon( e ) { - e.preventDefault(); - toggleAddonState( this, 'frm_install_addon' ); - } - - function toggleAddonState( clicked, action ) { - let button, plugin, el, message; - - // Remove any leftover error messages, output an icon and get the plugin basename that needs to be activated. - jQuery( '.frm-addon-error' ).remove(); - button = jQuery( clicked ); - plugin = button.attr( 'rel' ); - el = button.parent(); - message = el.parent().find( '.addon-status-label' ); - - button.addClass( 'frm_loading_button' ); - - // Process the Ajax to perform the activation. - jQuery.ajax({ - url: ajaxurl, - type: 'POST', - async: true, - cache: false, - dataType: 'json', - data: { - action: action, - nonce: frmGlobal.nonce, - plugin: plugin - }, - success: function( response ) { - response = response?.data ?? response; - - let saveAndReload; - - if ( 'string' !== typeof response && 'string' === typeof response.message ) { - if ( 'undefined' !== typeof response.saveAndReload ) { - saveAndReload = response.saveAndReload; - } - response = response.message; - } - - const error = extractErrorFromAddOnResponse( response ); - if ( error ) { - addonError( error, el, button ); - return; - } - - afterAddonInstall( response, button, message, el, saveAndReload, action ); - - /** - * Trigger an action after successfully toggling the addon state. - * - * @param {Object} response - */ - wp.hooks.doAction( 'frm_update_addon_state', response ); - }, - error: function() { - button.removeClass( 'frm_loading_button' ); - } - }); - } - - function installAddonWithCreds( e ) { - // Prevent the default action, let the user know we are attempting to install again and go with it. - e.preventDefault(); - - // Now let's make another Ajax request once the user has submitted their credentials. - const proceed = jQuery( this ); - const el = proceed.parent().parent(); - const plugin = proceed.attr( 'rel' ); - - proceed.addClass( 'frm_loading_button' ); - - jQuery.ajax({ - url: ajaxurl, - type: 'POST', - async: true, - cache: false, - dataType: 'json', - data: { - action: 'frm_install_addon', - nonce: frmAdminJs.nonce, - plugin: plugin, - hostname: el.find( '#hostname' ).val(), - username: el.find( '#username' ).val(), - password: el.find( '#password' ).val() - }, - success: function( response ) { - response = response?.data ?? response; - - const error = extractErrorFromAddOnResponse( response ); - if ( error ) { - addonError( error, el, proceed ); - return; - } - - afterAddonInstall( response, proceed, message, el ); - }, - error: function() { - proceed.removeClass( 'frm_loading_button' ); - } - }); - } - - function afterAddonInstall( response, button, message, el, saveAndReload, action = 'frm_activate_addon' ) { - const addonStatuses = document.querySelectorAll( '.frm-addon-status' ); - addonStatuses.forEach( - addonStatus => { - addonStatus.textContent = response; - addonStatus.style.display = 'block'; - } - ); - - // The Ajax request was successful, so let's update the output. - button.css({ opacity: '0' }); - - document.querySelectorAll( '.frm-oneclick' ).forEach( - oneClick => { - oneClick.style.display = 'none'; - } - ); - - jQuery( '#frm_upgrade_modal h2' ).hide(); - jQuery( '#frm_upgrade_modal .frm_lock_icon' ).addClass( 'frm_lock_open_icon' ); - jQuery( '#frm_upgrade_modal .frm_lock_icon use' ).attr( 'xlink:href', '#frm_lock_open_icon' ); - - // Proceed with CSS changes - const actionMap = { - frm_activate_addon: { class: 'frm-addon-active', message: frmAdminJs.active }, - frm_deactivate_addon: { class: 'frm-addon-installed', message: frmAdminJs.installed }, - frm_uninstall_addon: { class: 'frm-addon-not-installed', message: frmAdminJs.not_installed } - }; - actionMap.frm_install_addon = actionMap.frm_activate_addon; - - const messageElement = message[0]; - if ( messageElement ) { - messageElement.textContent = actionMap[action].message; - } - - const parentElement = el[0].parentElement; - parentElement.classList.remove( 'frm-addon-not-installed', 'frm-addon-installed', 'frm-addon-active' ); - parentElement.classList.add( actionMap[action].class ); - - const buttonElement = button[0]; - buttonElement.classList.remove( 'frm_loading_button' ); - - // Maybe refresh import and SMTP pages - const refreshPage = document.querySelectorAll( '.frm-admin-page-import, #frm-admin-smtp, #frm-welcome' ); - if ( refreshPage.length > 0 ) { - window.location.reload(); - return; - } - - if ([ 'settings', 'form_builder' ].includes( saveAndReload ) ) { - addonStatuses.forEach( - addonStatus => { - const inModal = null !== addonStatus.closest( '#frm_upgrade_modal' ); - addonStatus.appendChild( getSaveAndReloadSettingsOptions( saveAndReload, inModal ) ); - } - ); - } - } - - function getSaveAndReloadSettingsOptions( saveAndReload, inModal ) { - const className = 'frm-save-and-reload-options'; - const children = [ saveAndReloadSettingsButton( saveAndReload ) ]; - if ( inModal ) { - children.push( closePopupButton() ); - } - return div({ className, children }); - } - - function saveAndReloadSettingsButton( saveAndReload ) { - const button = document.createElement( 'button' ); - button.classList.add( 'frm-save-and-reload', 'button', 'button-primary', 'frm-button-primary' ); - button.textContent = __( 'Save and Reload', 'formidable' ); - button.addEventListener( 'click', () => { - if ( saveAndReload === 'form_builder' ) { - saveAndReloadFormBuilder(); - } else if ( saveAndReload === 'settings' ) { - saveAndReloadSettings(); - } - }); - return button; - } - - function closePopupButton() { - const a = document.createElement( 'a' ); - a.setAttribute( 'href', '#' ); - a.classList.add( 'button', 'button-secondary', 'frm-button-secondary', 'dismiss' ); - a.textContent = __( 'Close', 'formidable' ); - return a; - } - - function extractErrorFromAddOnResponse( response ) { - if ( typeof response !== 'string' ) { - if ( typeof response.success !== 'undefined' && response.success ) { - return false; - } - - if ( response.form ) { - if ( jQuery( response.form ).is( '#message' ) ) { - return { - message: jQuery( response.form ).find( 'p' ).html() - }; - } - } - - return response; - } - - return false; - } - - function addonError( response, el, button ) { - if ( response.form ) { - jQuery( '.frm-inline-error' ).remove(); - button.closest( '.frm-card' ) - .html( response.form ) - .css({ padding: 5 }) - .find( '#upgrade' ) - .attr( 'rel', button.attr( 'rel' ) ) - .on( 'click', installAddonWithCreds ); - } else { - el.append( '

      ' + response.message + '

      ' ); - button.removeClass( 'frm_loading_button' ); - jQuery( '.frm-addon-error' ).delay( 4000 ).fadeOut(); - } - } - - /* Templates */ - function showActiveCampaignForm() { - loadApiEmailForm(); - } - - function handleApiFormError( inputId, errorId, type, message ) { - const $error = jQuery( errorId ); - $error.removeClass( 'frm_hidden' ).attr( 'frm-error', type ); - - if ( typeof message !== 'undefined' ) { - $error.find( 'span[frm-error="' + type + '"]' ).text( message ); - } - - jQuery( inputId ).one( 'keyup', function() { - $error.addClass( 'frm_hidden' ); - }); - } - - function handleEmailAddressError( type ) { - handleApiFormError( '#frm_leave_email', '#frm_leave_email_error', type ); - } - - function loadApiEmailForm() { - const formContainer = document.getElementById( 'frmapi-email-form' ); - jQuery.ajax({ - dataType: 'json', - url: formContainer.getAttribute( 'data-url' ), - success: function( json ) { - let form = json.renderedHtml; - form = form.replace( /]*(formidableforms.css|action=frmpro_css)[^>]*>/gi, '' ); - formContainer.innerHTML = form; - } - }); - } - - function initAutocomplete( container ) { - frmDom.autocomplete.initSelectionAutocomplete( container ); - } - - function nextInstallStep( thisStep ) { - thisStep.classList.add( 'frm_grey' ); - thisStep.nextElementSibling.classList.remove( 'frm_grey' ); - } - - function installTemplateFieldset( e ) { - /*jshint validthis:true */ - const fieldset = this.parentNode.parentNode, - action = fieldset.elements.type.value, - button = this; - e.preventDefault(); - button.classList.add( 'frm_loading_button' ); - installNewForm( fieldset, action, button ); - } - - function installTemplate( e ) { - /*jshint validthis:true */ - const action = this.elements.type.value, - button = this.querySelector( 'button' ); - e.preventDefault(); - button.classList.add( 'frm_loading_button' ); - installNewForm( this, action, button ); - } - - function installNewForm( form, action, button ) { - const formData = formToData( form ); - const formName = formData.template_name; - const formDesc = formData.template_desc; - const link = form.elements.link.value; - - let data = { - action: action, - xml: link, - name: formName, - desc: formDesc, - form: JSON.stringify( formData ), - nonce: frmGlobal.nonce - }; - - const hookName = 'frm_before_install_new_form'; - const filterArgs = { formData }; - data = wp.hooks.applyFilters( hookName, data, filterArgs ); - - postAjax( data, function( response ) { - if ( typeof response.redirect !== 'undefined' ) { - const redirect = response.redirect; - if ( typeof form.elements.redirect === 'undefined' ) { - window.location = redirect; - } else { - const href = document.getElementById( 'frm-redirect-link' ); - if ( typeof link !== 'undefined' && href !== null ) { - // Show the next installation step. - href.setAttribute( 'href', redirect ); - href.classList.remove( 'frm_grey', 'disabled' ); - nextInstallStep( form.parentNode.parentNode ); - button.classList.add( 'frm_grey', 'disabled' ); - } - } - } else { - jQuery( '.spinner' ).css( 'visibility', 'hidden' ); - - // Show response.message - if ( 'string' === typeof response.message ) { - showInstallFormErrorModal( response.message ); - } - } - button.classList.remove( 'frm_loading_button' ); - }); - } - - function showInstallFormErrorModal( message ) { - const modalContent = div( message ); - modalContent.style.padding = '20px 40px'; - const modal = frmDom.modal.maybeCreateModal( - 'frmInstallFormErrorModal', - { - title: __( 'Unable to install template', 'formidable' ), - content: modalContent - } - ); - modal.classList.add( 'frm_common_modal' ); - } - - function handleCaptchaTypeChange( e ) { - const thresholdContainer = document.getElementById( 'frm_captcha_threshold_container' ); - if ( thresholdContainer ) { - thresholdContainer.classList.toggle( 'frm_hidden', 'v3' !== e.target.value ); - } - } - - function trashTemplate( e ) { - /*jshint validthis:true */ - const id = this.getAttribute( 'data-id' ); - e.preventDefault(); - - data = { - action: 'frm_forms_trash', - id: id, - nonce: frmGlobal.nonce - }; - postAjax( data, function() { - const card = document.getElementById( 'frm-template-custom-' + id ); - fadeOut( card, function() { - card.parentNode.removeChild( card ); - }); - }); - } - - function searchContent() { - /*jshint validthis:true */ - let i, - regEx = false, - searchText = this.value.toLowerCase(), - toSearch = this.getAttribute( 'data-tosearch' ), - items = document.getElementsByClassName( toSearch ); - - if ( this.tagName === 'SELECT' ) { - searchText = selectedOptions( this ); - searchText = searchText.join( '|' ).toLowerCase(); - regEx = true; - } - - if ( toSearch === 'frm-action' && searchText !== '' ) { - const addons = document.getElementById( 'frm_email_addon_menu' ).classList; - addons.remove( 'frm-all-actions' ); - addons.add( 'frm-limited-actions' ); - } - - for ( i = 0; i < items.length; i++ ) { - const innerText = items[i].innerText.toLowerCase(); - - const itemCanBeShown = ! ( getExportOption() === 'xml' && items[i].classList.contains( 'frm-is-repeater' ) ); - if ( searchText === '' ) { - if ( itemCanBeShown && checkContextualShortcode( items[i] ) ) { - items[i].classList.remove( 'frm_hidden' ); - } - items[i].classList.remove( 'frm-search-result' ); - } else if ( ( regEx && new RegExp( searchText ).test( innerText ) ) || innerText.indexOf( searchText ) >= 0 || textMatchesPlural( innerText, searchText ) ) { - if ( itemCanBeShown && checkContextualShortcode( items[i] ) ) { - items[i].classList.remove( 'frm_hidden' ); - } - items[i].classList.add( 'frm-search-result' ); - } else { - items[i].classList.add( 'frm_hidden' ); - items[i].classList.remove( 'frm-search-result' ); - } - } - - // Updates the visibility of category headings based on search results. - updateCatHeadingVisibility(); - - jQuery( this ).trigger( 'frmAfterSearch' ); - } - - /** - * Allow a search for "signatures" to still match "signature" for example when searching fields. - * - * @since 6.15 - * - * @param {string} text The text in the element we are checking for a match. - * @param {string} searchText The text value that is being searched. - * @return {boolean} - */ - function textMatchesPlural( text, searchText ) { - if ( searchText === 's' ) { - // Don't match everything when just "s" is searched. - return false; - } - - if ( text[ text.length - 1 ] === 's' ) { - // Do not match something with double s if the text already ends in s. - return false; - } - - return ( text + 's' ).indexOf( searchText ) >= 0; - } - - /** - * Updates the visibility of category headings based on search results. - * If all associated fields are hidden (indicating no search matches), - * the heading is hidden. - * - * @since 6.4.1 - */ - function updateCatHeadingVisibility() { - const insertFieldsElement = document.querySelector( '#frm-insert-fields' ); - if ( ! insertFieldsElement ) { - return; - } - - const headingElements = insertFieldsElement.querySelectorAll( ':scope > .frm-with-line' ); - headingElements.forEach( heading => { - const fieldsListElement = heading.nextElementSibling; - if ( ! fieldsListElement ) { - return; - } - const listItemElements = fieldsListElement.querySelectorAll( ':scope > li.frmbutton' ); - const allHidden = Array.from( listItemElements ).every( li => li.classList.contains( 'frm_hidden' ) ); - - // Add or remove class based on `allHidden` condition - heading.classList.toggle( 'frm_hidden', allHidden ); - }); - } - - function stopPropagation( e ) { - e.stopPropagation(); - } - - /* Helpers */ - - function selectedOptions( select ) { - let opt, - result = [], - options = select && select.options; - - for ( let i = 0, iLen = options.length; i < iLen; i++ ) { - opt = options[i]; - - if ( opt.selected ) { - result.push( opt.value ); - } - } - return result; - } - - function triggerEvent( element, event ) { - const evt = document.createEvent( 'HTMLEvents' ); - evt.initEvent( event, false, true ); - element.dispatchEvent( evt ); - } - - function postAjax( data, success ) { - let response; - - const xmlHttp = new XMLHttpRequest(); - const params = typeof data === 'string' ? data : Object.keys( data ).map( - function( k ) { - return encodeURIComponent( k ) + '=' + encodeURIComponent( data[k]); - } - ).join( '&' ); - - xmlHttp.open( 'post', ajaxurl, true ); - xmlHttp.onreadystatechange = function() { - if ( xmlHttp.readyState > 3 && xmlHttp.status == 200 ) { - response = xmlHttp.responseText; - try { - response = JSON.parse( response ); - } catch ( e ) { - // The response may not be JSON, so just return it. - } - success( response ); - } - }; - xmlHttp.setRequestHeader( 'X-Requested-With', 'XMLHttpRequest' ); - xmlHttp.setRequestHeader( 'Content-type', 'application/x-www-form-urlencoded' ); - xmlHttp.send( params ); - return xmlHttp; - } - - function fadeOut( element, success ) { - element.classList.add( 'frm-fade' ); - setTimeout( success, 1000 ); - } - - function invisible( classes ) { - jQuery( classes ).css( 'visibility', 'hidden' ); - } - - function visible( classes ) { - jQuery( classes ).css( 'visibility', 'visible' ); - } - - function initModal( id, width ) { - const $info = jQuery( id ); - if ( ! $info.length ) { - return false; - } - - if ( typeof width === 'undefined' ) { - width = '550px'; - } - - const dialogArgs = { - dialogClass: 'frm-dialog', - modal: true, - autoOpen: false, - closeOnEscape: true, - width: width, - resizable: false, - draggable: false, - open: function() { - jQuery( '.ui-dialog-titlebar' ).addClass( 'frm_hidden' ).removeClass( 'ui-helper-clearfix' ); - jQuery( '#wpwrap' ).addClass( 'frm_overlay' ); - jQuery( '.frm-dialog' ).removeClass( 'ui-widget ui-widget-content ui-corner-all' ); - $info.removeClass( 'ui-dialog-content ui-widget-content' ); - bindClickForDialogClose( $info ); - }, - close: function() { - jQuery( '#wpwrap' ).removeClass( 'frm_overlay' ); - jQuery( '.spinner' ).css( 'visibility', 'hidden' ); - - this.removeAttribute( 'data-option-type' ); - const optionType = document.getElementById( 'bulk-option-type' ); - if ( optionType ) { - optionType.value = ''; - } - } - }; - - $info.dialog( dialogArgs ); - - return $info; - } - - function toggle( cname, id ) { - if ( id === '#' ) { - const cont = document.getElementById( cname ); - const hidden = cont.style.display; - if ( hidden === 'none' ) { - cont.style.display = 'block'; - } else { - cont.style.display = 'none'; - } - } else { - const vis = cname.is( ':visible' ); - if ( vis ) { - cname.hide(); - } else { - cname.show(); - } - } - } - - function removeWPUnload() { - window.onbeforeunload = null; - const w = jQuery( window ); - w.off( 'beforeunload.widgets' ); - w.off( 'beforeunload.edit-post' ); - } - - function addMultiselectLabelListener() { - const clickListener = ( e ) => { - if ( 'LABEL' !== e.target.nodeName ) { - return; - } - - const labelFor = e.target.getAttribute( 'for' ); - if ( ! labelFor ) { - return; - } - - const input = document.getElementById( labelFor ); - if ( ! input || ! input.nextElementSibling ) { - return; - } - - const buttonToggle = input.nextElementSibling.querySelector( 'button.dropdown-toggle.multiselect' ); - if ( ! buttonToggle ) { - return; - } - - const triggerMultiselectClick = () => buttonToggle.click(); - setTimeout( triggerMultiselectClick, 0 ); - }; - document.addEventListener( 'click', clickListener ); - } - - function maybeChangeEmbedFormMsg() { - const fieldId = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ); - let fieldItem = document.getElementById( 'frm_field_id_' + fieldId ); - if ( null === fieldItem || 'form' !== fieldItem.dataset.type ) { - return; - } - - fieldItem = jQuery( fieldItem ); - - if ( this.options[ this.selectedIndex ].value ) { - fieldItem.find( '.frm-not-set' )[0].classList.add( 'frm_hidden' ); - const embedMsg = fieldItem.find( '.frm-embed-message' ); - embedMsg.html( embedMsg.data( 'embedmsg' ) + this.options[ this.selectedIndex ].text ); - fieldItem.find( '.frm-embed-field-placeholder' )[0].classList.remove( 'frm_hidden' ); - } else { - fieldItem.find( '.frm-not-set' )[0].classList.remove( 'frm_hidden' ); - fieldItem.find( '.frm-embed-field-placeholder' )[0].classList.add( 'frm_hidden' ); - } - } - - function toggleProductType() { - const settings = jQuery( this ).closest( '.frm-single-settings' ), - container = settings.find( '.frmjs_product_choices' ), - heading = settings.find( '.frm_prod_options_heading' ), - currentVal = this.options[ this.selectedIndex ].value; - - container.removeClass( 'frm_prod_type_single frm_prod_type_user_def' ); - heading.removeClass( 'frm_prod_user_def' ); - - if ( 'single' === currentVal ) { - container.addClass( 'frm_prod_type_single' ); - } else if ( 'user_def' === currentVal ) { - container.addClass( 'frm_prod_type_user_def' ); - heading.addClass( 'frm_prod_user_def' ); - } - } - - /** - * @param {Number | string} fieldId - * @return {boolean} True if the field is a product field. - */ - function isProductField( fieldId ) { - const field = document.getElementById( 'frm_field_id_' + fieldId ); - if ( field === null ) { - return false; - } - return 'product' === field.getAttribute( 'data-type' ); - } - - /** - * Serialize form data with vanilla JS. - */ - function formToData( form ) { - let subKey, i, - object = {}, - formData = form.elements; - - for ( i = 0; i < formData.length; i++ ) { - let input = formData[i], - key = input.name, - value = input.value, - names = key.match( /(.*)\[(.*)\]/ ); - - if ( ( input.type === 'radio' || input.type === 'checkbox' ) && ! input.checked ) { - continue; - } - - if ( names !== null ) { - key = names[1]; - subKey = names[2]; - if ( ! Reflect.has( object, key ) ) { - object[key] = {}; - } - object[key][subKey] = value; - continue; - } - - // Reflect.has in favor of: object.hasOwnProperty(key) - if ( ! Reflect.has( object, key ) ) { - object[key] = value; - continue; - } - if ( ! Array.isArray( object[key]) ) { - object[key] = [ object[key] ]; - } - object[key].push( value ); - } - - return object; - } - - /** - * Show, hide, and sort subfields of Name field on form builder. - * - * @since 4.11 - */ - function handleNameFieldOnFormBuilder() { - /** - * Gets subfield element from cache. - * - * @param {String} fieldId Field ID. - * @param {String} key Cache key. - * @returns {HTMLElement|undefined} Return the element from cache or undefined if not found. - */ - const getSubFieldElFromCache = ( fieldId, key ) => { - window.frmCachedSubFields = window.frmCachedSubFields || {}; - window.frmCachedSubFields[fieldId] = window.frmCachedSubFields[fieldId] || {}; - return window.frmCachedSubFields[fieldId][key]; - }; - - /** - * Sets subfield element to cache. - * - * @param {String} fieldId Field ID. - * @param {String} key Cache key. - * @param {HTMLElement} el Element. - */ - const setSubFieldElToCache = ( fieldId, key, el ) => { - window.frmCachedSubFields = window.frmCachedSubFields || {}; - window.frmCachedSubFields[fieldId] = window.frmCachedSubFields[fieldId] || {}; - window.frmCachedSubFields[fieldId][key] = el; - }; - - /** - * Gets column class from the number of columns. - * - * @param {Number} colCount Number of columns. - * @returns {string} - */ - const getColClass = colCount => 'frm' + parseInt( 12 / colCount ); - - const colClasses = [ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12 ].map( num => 'frm' + num ); - - const allSubFieldNames = [ 'first', 'middle', 'last' ]; - - /** - * Handles name layout change. - * - * @param {Event} event Event object. - */ - const onChangeLayout = event => { - const value = event.target.value; - const subFieldNames = value.split( '_' ); - const fieldId = event.target.dataset.fieldId; - - /* - * Live update form on the form builder. - */ - const container = document.querySelector( '#field_' + fieldId + '_inner_container .frm_combo_inputs_container' ); - const newColClass = getColClass( subFieldNames.length ); - - // Set all sub field elements to cache and hide all of them first. - allSubFieldNames.forEach( name => { - const subFieldEl = container.querySelector( '[data-sub-field-name="' + name + '"]' ); - if ( subFieldEl ) { - subFieldEl.classList.add( 'frm_hidden' ); - subFieldEl.classList.remove( ...colClasses ); - setSubFieldElToCache( fieldId, name, subFieldEl ); - } - }); - - subFieldNames.forEach( subFieldName => { - const subFieldEl = getSubFieldElFromCache( fieldId, subFieldName ); - if ( ! subFieldEl ) { - return; - } - - subFieldEl.classList.remove( 'frm_hidden' ); - subFieldEl.classList.add( newColClass ); - - container.append( subFieldEl ); - }); - - /* - * Live update subfield options. - */ - // Hide all subfield options. - allSubFieldNames.forEach( name => { - const optionsEl = document.querySelector( '.frm_sub_field_options-' + name + '[data-field-id="' + fieldId + '"]' ); - if ( optionsEl ) { - optionsEl.classList.add( 'frm_hidden' ); - setSubFieldElToCache( fieldId, name + '_options', optionsEl ); - } - }); - - subFieldNames.forEach( subFieldName => { - const optionsEl = getSubFieldElFromCache( fieldId, subFieldName + '_options' ); - if ( ! optionsEl ) { - return; - } - optionsEl.classList.remove( 'frm_hidden' ); - }); - }; - - const dropdownSelector = '.frm_name_layout_dropdown'; - document.addEventListener( 'change', event => { - if ( event.target.matches( dropdownSelector ) ) { - onChangeLayout( event ); - } - }, false ); - } - - function debounce( func, wait = 100 ) { - return frmDom.util.debounce( func, wait ); - } - - function addSaveAndDragIconsToOption( fieldId, liObject ) { - let li, useTag, useTagHref; - let hasDragIcon = false; - let hasSaveIcon = false; - - if ( liObject.newOption ) { - const parser = new DOMParser(); - li = parser.parseFromString( liObject.newOption, 'text/html' ).body.childNodes[0]; - } else { - li = liObject; - } - - const liIcons = li.querySelectorAll( 'svg' ); - - liIcons.forEach( ( svg, key ) => { - useTag = svg.getElementsByTagNameNS( 'http://www.w3.org/2000/svg', 'use' )[0]; - if ( ! useTag ) { - return; - } - useTagHref = useTag.getAttributeNS( 'http://www.w3.org/1999/xlink', 'href' ) || useTag.getAttribute( 'href' ); - - if ( useTagHref === '#frm_drag_icon' ) { - hasDragIcon = true; - } - - if ( useTagHref === '#frm_save_icon' ) { - hasSaveIcon = true; - } - }); - - if ( ! hasDragIcon ) { - li.prepend( icons.drag.cloneNode( true ) ); - } - - if ( li.querySelector( `[id^=field_key_${fieldId}-]` ) && ! hasSaveIcon ) { - li.querySelector( `[id^=field_key_${fieldId}-]` ).after( icons.save.cloneNode( true ) ); - } - - if ( liObject.newOption ) { - liObject.newOption = li; - } - } - - function maybeAddSaveAndDragIcons( fieldId ) { - fieldOptions = document.querySelectorAll( `[id^=frm_delete_field_${fieldId}-]` ); - // return if there are no options. - if ( fieldOptions.length < 2 ) { - return; - } - - const options = [ ...fieldOptions ].slice( 1 ); - options.forEach( ( li, _key ) => { - if ( li.classList.contains( 'frm_other_option' ) ) { - return; - } - addSaveAndDragIconsToOption( fieldId, li ); - }); - } - - function initOnSubmitAction() { - const onChangeType = event => { - if ( ! event.target.checked ) { - return; - } - - const actionEl = event.target.closest( '.frm_form_action_settings' ); - actionEl.querySelectorAll( '.frm_on_submit_dependent_setting:not(.frm_hidden)' ).forEach( el => { - el.classList.add( 'frm_hidden' ); - }); - - const activeEls = actionEl.querySelectorAll( '.frm_on_submit_dependent_setting[data-show-if-' + event.target.value + ']' ); - activeEls.forEach( activeEl => { - activeEl.classList.remove( 'frm_hidden' ); - }); - - actionEl.setAttribute( 'data-on-submit-type', event.target.value ); - }; - - frmDom.util.documentOn( 'change', '.frm_on_submit_type input[type="radio"]', onChangeType ); - } - - /** - * Listen for click events for an API-loaded email collection form. - * - * This is used for the Active Campaign sign-up form in the inbox page (when there are no messages). - */ - function initAddMyEmailAddress() { - jQuery( document ).on( - 'click', - '#frm-add-my-email-address', - event => { - event.preventDefault(); - addMyEmailAddress(); - } - ); - - const emptyInbox = document.getElementById( 'frm_empty_inbox' ); - const leaveEmailInput = document.getElementById( 'frm_leave_email' ); - - if ( emptyInbox && leaveEmailInput ) { - const leaveEmailModal = document.getElementById( 'frm-leave-email-modal' ); - leaveEmailModal.classList.remove( 'frm_hidden' ); - leaveEmailModal.querySelector( '.frm_modal_footer' ).classList.add( 'frm_hidden' ); - - leaveEmailInput.addEventListener( - 'keyup', - event => { - if ( 'Enter' === event.key ) { - const button = document.getElementById( 'frm-add-my-email-address' ); - if ( button ) { - button.click(); - } - } - } - ); - } - } - - function addMyEmailAddress() { - const email = document.getElementById( 'frm_leave_email' ).value.trim(); - if ( '' === email ) { - handleEmailAddressError( 'empty' ); - return; - } - - const regex = /^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/i; - if ( regex.test( email ) === false ) { - handleEmailAddressError( 'invalid' ); - return; - } - - const $hiddenForm = jQuery( '#frmapi-email-form' ).find( 'form' ); - const $hiddenEmailField = $hiddenForm.find( '[type="email"]' ).not( '.frm_verify' ); - if ( ! $hiddenEmailField.length ) { - return; - } - - const emptyInbox = document.getElementById( 'frm_empty_inbox' ); - if ( emptyInbox ) { - document.getElementById( 'frm-add-my-email-address' ).remove(); - - const emailWrapper = document.getElementById( 'frm_leave_email_wrapper' ); - if ( emailWrapper ) { - emailWrapper.classList.add( 'frm_hidden' ); - const spinner = span({ className: 'frm-wait frm_spinner' }); - spinner.style.visibility = 'visible'; - spinner.style.float = 'none'; - spinner.style.width = 'unset'; - emailWrapper.parentElement.insertBefore( - spinner, - emailWrapper.nextElementSibling - ); - } - } - - $hiddenEmailField.val( email ); - jQuery.ajax({ - type: 'POST', - url: $hiddenForm.attr( 'action' ), - data: $hiddenForm.serialize() + '&action=frm_forms_preview' - }).done( function( data ) { - const message = jQuery( data ).find( '.frm_message' ).text().trim(); - if ( message.indexOf( 'Thanks!' ) === -1 ) { - handleEmailAddressError( 'invalid' ); - return; - } - - const apiForm = document.getElementById( 'frmapi-email-form' ); - const spinner = apiForm.parentElement.querySelector( '.frm_spinner' ); - if ( spinner ) { - spinner.remove(); - } - - const showSuccessMessage = wp.hooks.applyFilters( 'frm_thank_you_on_signup', true ); - if ( showSuccessMessage ) { - // Handle successful form submission. - // handle the Active Campaign form on the inbox page. - document.getElementById( 'frm_leave_email_wrapper' ).replaceWith( - span( __( 'Thank you for signing up!', 'formidable' ) ) - ); - } - }); - } - - /** - * Adds footer links to the admin body content. - * - * @return {void} - */ - function addAdminFooterLinks() { - const footerLinks = document.querySelector( '.frm-admin-footer-links' ); - const container = document.querySelector( '.frm_page_container' ) ?? document.getElementById( 'wpbody-content' ); - - if ( ! footerLinks || ! container ) { - return; - } - - container.appendChild( footerLinks ); - footerLinks.classList.remove( 'frm_hidden' ); - } - - /** - * Apply zebra striping to a table while ignoring empty rows. - * - * @param {string} tableSelector The CSS selector for the table. - * @param {string} emptyRowClass The class name used to identify empty rows. - */ - function applyZebraStriping( tableSelector, emptyRowClass ) { - // Get all non-empty table rows within the specified table - const rows = document.querySelectorAll( `${tableSelector} tr${emptyRowClass ? `:not(.${emptyRowClass})` : ''}` ); - if ( rows.length < 1 ) { - return; - } - - let isOdd = true; - rows.forEach( row => { - // Clean old "frm-odd" or "frm-even" classes and add the appropriate new class - row.classList.remove( 'frm-odd', 'frm-even' ); - row.classList.add( isOdd ? 'frm-odd' : 'frm-even' ); - - isOdd = ! isOdd; - }); - - const tables = document.querySelectorAll( tableSelector ); - tables.forEach( table => table.classList.add( 'frm-zebra-striping' ) ); - }; - - function maybeHideShortcodes( e ) { - if ( ! builderPage ) { - e.stopPropagation(); - } - - if ( e.target.classList.contains( 'frm-show-box' ) || ( e.target.parentElement && e.target.parentElement.classList.contains( 'frm-show-box' ) ) ) { - return; - } - - const sidebar = document.getElementById( 'frm_adv_info' ); - if ( ! sidebar ) { - return; - } - - if ( sidebar.dataset.fills === e.target.id && typeof e.target.id !== 'undefined' ) { - return; - } - - const isChild = e.target.closest( '#frm_adv_info' ); - - if ( ! isChild && sidebar.style.display !== 'none' ) { - hideShortcodes( sidebar ); - } - } - - /** - * Initializes and manages the visibility of dependent elements based on the selected options in dropdowns with the 'frm_select_with_dependency' class. - * It sets up initial visibility at page load and updates it on each dropdown change. - * - * @since 6.9 - * - * @return {void} - */ - function initSelectDependencies() { - const selects = document.querySelectorAll( 'select.frm_select_with_dependency' ); - - /** - * Toggles the visibility of dependent elements associated with a select element based on its current selection. - * - * @since 6.9 - * - * @param {HTMLElement} select The select element whose dependencies need to be managed. - * @return {void} - */ - function toggleDependencyVisibility( select ) { - const selectedOption = select.options[ select.selectedIndex ]; - select.querySelectorAll( 'option[data-dependency]:not([data-dependency-skip])' ).forEach( option => { - const dependencyElement = document.querySelector( option.dataset.dependency ); - dependencyElement?.classList.toggle( 'frm_hidden', selectedOption !== option ); - }); - } - - // Initial setup: Show dependencies based on the current selection in each dropdown - selects.forEach( toggleDependencyVisibility ); - - // Update dependencies visibility on dropdown change - frmDom.util.documentOn( 'change', 'select.frm_select_with_dependency', ( event ) => toggleDependencyVisibility( event.target ) ); - } - - /** - * Moves the focus to the next single option input field in the list and positions the cursor at the end of the text. - * - * @param {HTMLElement} currentInput The currently focused input element. - */ - function focusNextSingleOptionInput( currentInput ) { - const optionsList = currentInput.closest( '.frm_single_option' ).parentElement; - const inputs = optionsList.querySelectorAll( '.frm_single_option input[name^="field_options[" ], .frm_single_option input[name^="rows_"]' ); - const inputsArray = Array.from( inputs ); - - // Find the index of the currently focused input - const currentIndex = inputsArray.indexOf( currentInput ); - - if ( currentIndex < 0 ) { - return; - } - - // Find the next visible input field - const nextInput = inputsArray.slice( currentIndex + 1 ).find( input => input.offsetParent !== null ); - - if ( nextInput ) { - nextInput.focus(); - - // Move the cursor to the end of the text in the next input field - const textLength = nextInput.value.length; - nextInput.setSelectionRange( textLength, textLength ); - } - } - - return { - init: function() { - initAddMyEmailAddress(); - addAdminFooterLinks(); - - s = {}; - - // Bootstrap dropdown button - jQuery( '.wp-admin' ).on( 'click', function( e ) { - const t = jQuery( e.target ); - const $openDrop = jQuery( '.dropdown.open' ); - if ( $openDrop.length && ! t.hasClass( 'dropdown' ) && ! t.closest( '.dropdown' ).length ) { - $openDrop.removeClass( 'open' ); - } - }); - jQuery( '#frm_bs_dropdown:not(.open) a' ).on( 'click', focusSearchBox ); - - if ( typeof thisFormId === 'undefined' ) { - thisFormId = jQuery( document.getElementById( 'form_id' ) ).val(); - } - - // Add event listener for dismissible warning messages. - document.querySelectorAll( '.frm-warning-dismiss' ).forEach( ( dismissIcon ) => { - onClickPreventDefault( dismissIcon, dismissWarningMessage ); - }); - - frmAdminBuild.inboxBannerInit(); - - if ( $newFields.length > 0 ) { - // only load this on the form builder page - frmAdminBuild.buildInit(); - } else if ( document.getElementById( 'frm_notification_settings' ) !== null ) { - // only load on form settings page - frmAdminBuild.settingsInit(); - } else if ( document.getElementById( 'frm_styling_form' ) !== null ) { - // load styling settings js - frmAdminBuild.styleInit(); - } else if ( document.getElementById( 'form_global_settings' ) !== null ) { - // global settings page - frmAdminBuild.globalSettingsInit(); - } else if ( document.getElementById( 'frm_export_xml' ) !== null ) { - // import/export page - frmAdminBuild.exportInit(); - } else if ( null !== document.querySelector( '.frm-inbox-wrapper' ) ) { - // Dashboard page inbox. - frmAdminBuild.inboxInit(); - } else if ( document.getElementById( 'frm-welcome' ) !== null ) { - // Solution install page - frmAdminBuild.solutionInit(); - } else { - initAutocomplete(); - - jQuery( '[data-frmprint]' ).on( 'click', function() { - window.print(); - return false; - }); - } - - jQuery( document ).on( 'change', 'select[data-toggleclass], input[data-toggleclass]', toggleFormOpts ); - initSelectDependencies(); - - const $advInfo = jQuery( document.getElementById( 'frm_adv_info' ) ); - if ( $advInfo.length > 0 || jQuery( '.frm_field_list' ).length > 0 ) { - // only load on the form, form settings, and view settings pages - frmAdminBuild.panelInit(); - } - - loadTooltips(); - initUpgradeModal(); - - // used on build, form settings, and view settings - const $shortCodeDiv = jQuery( document.getElementById( 'frm_shortcodediv' ) ); - if ( $shortCodeDiv.length > 0 ) { - jQuery( 'a.edit-frm_shortcode' ).on( 'click', function() { - if ( $shortCodeDiv.is( ':hidden' ) ) { - $shortCodeDiv.slideDown( 'fast' ); - this.style.display = 'none'; - } - return false; - }); - - jQuery( '.cancel-frm_shortcode', '#frm_shortcodediv' ).on( 'click', function() { - $shortCodeDiv.slideUp( 'fast' ); - $shortCodeDiv.siblings( 'a.edit-frm_shortcode' ).show(); - return false; - }); - } - - // tabs - jQuery( document ).on( 'click', '#frm-nav-tabs a', clickNewTab ); - jQuery( '.post-type-frm_display .frm-nav-tabs a, .frm-category-tabs a' ).on( 'click', function() { - const showUpgradeTab = this.classList.contains( 'frm_show_upgrade_tab' ); - if ( this.classList.contains( 'frm_noallow' ) && ! showUpgradeTab ) { - return; - } - - if ( showUpgradeTab ) { - populateUpgradeTab( this ); - } - - clickTab( this ); - return false; - }); - clickTab( jQuery( '.starttab a' ), 'auto' ); - - // submit the search form with dropdown - jQuery( document ).on( 'click', '#frm-fid-search-menu a', function() { - const val = this.id.replace( 'fid-', '' ); - jQuery( 'select[name="fid"]' ).val( val ); - triggerSubmit( document.getElementById( 'posts-filter' ) ); - return false; - }); - - jQuery( '.frm_select_box' ).on( 'click focus', function() { - this.select(); - }); - - jQuery( document ).on( 'input search change', '.frm-auto-search:not(#frm-form-templates-page #template-search-input)', searchContent ); - jQuery( document ).on( 'focusin click', '.frm-auto-search', stopPropagation ); - const autoSearch = jQuery( '.frm-auto-search' ); - if ( autoSearch.val() !== '' ) { - autoSearch.trigger( 'keyup' ); - } - - // Initialize Formidable Connection. - FrmFormsConnect.init(); - - jQuery( document ).on( 'click', '.frm-install-addon', installAddon ); - jQuery( document ).on( 'click', '.frm-activate-addon', activateAddon ); - jQuery( document ).on( 'click', '.frm-solution-multiple', installMultipleAddons ); - - // prevent annoying confirmation message from WordPress - jQuery( 'button, input[type=submit]' ).on( 'click', removeWPUnload ); - - addMultiselectLabelListener(); - - frmAdminBuild.hooks.addFilter( - 'frm_before_embed_modal', - ( ids, { element, type }) => { - if ( 'form' !== type ) { - return ids; - } - - let formId, formKey; - const row = element.closest( 'tr' ); - - if ( row ) { - // Embed icon on form index. - formId = parseInt( row.querySelector( '.column-id' ).textContent ); - formKey = row.querySelector( '.column-form_key' ).textContent; - } else { - // Embed button in form builder / form settings. - formId = document.getElementById( 'form_id' ).value; - - const formKeyInput = document.getElementById( 'frm_form_key' ); - if ( formKeyInput ) { - formKey = formKeyInput.value; - } else { - const previewDrop = document.getElementById( 'frm-previewDrop' ); - if ( previewDrop ) { - formKey = previewDrop.nextElementSibling.querySelector( '.dropdown-item a' ).getAttribute( 'href' ).split( 'form=' )[1]; - } - } - } - - return [ formId, formKey ]; - } - ); - - document.querySelectorAll( '#frm-show-fields > li, .frm_grid_container li' ).forEach( ( el, _key ) => { - el.addEventListener( 'click', function() { - const fieldId = this.querySelector( 'li' )?.dataset.fid || this.dataset.fid; - maybeAddSaveAndDragIcons( fieldId ); - }); - }); - - const smallScreenProceedButton = document.getElementById( 'frm_small_screen_proceed_button' ); - if ( smallScreenProceedButton ) { - onClickPreventDefault( smallScreenProceedButton, () => { - document.getElementById( 'frm_small_device_message_container' )?.remove(); - doJsonPost( 'small_screen_proceed', new FormData() ); - }); - } - - const saleBanner = document.getElementById( 'frm_sale_banner' ); - const saleDismiss = saleBanner?.querySelector( '.dismiss' ); - if ( saleBanner ) { - onClickPreventDefault( saleBanner, ( event ) => { - const target = event.target; - if ( target.closest( '.dismiss' ) ) { - return; - } - window.location.href = saleBanner.getAttribute( 'data-url' ); - }); - - if ( saleDismiss ) { - onClickPreventDefault( saleDismiss, () => { - saleBanner.remove(); - - const formData = new FormData(); - doJsonPost( 'sale_banner_dismiss', formData ); - }); - } - } - }, - - buildInit: function() { - jQuery( '#frm_builder_page' ).on( 'mouseup', '*:not(.frm-show-box)', maybeHideShortcodes ); - - let loadFieldId, $builderForm, builderArea; - - debouncedSyncAfterDragAndDrop = debounce( syncAfterDragAndDrop, 10 ); - postBodyContent = document.getElementById( 'post-body-content' ); - $postBodyContent = jQuery( postBodyContent ); - - if ( jQuery( '.frm_field_loading' ).length ) { - loadFieldId = jQuery( '.frm_field_loading' ).first().attr( 'id' ); - loadFields( loadFieldId ); - } - - setupSortable( 'ul.frm_sorting' ); - - document.querySelectorAll( '.field_type_list > li:not(.frm_show_upgrade)' ).forEach( makeDraggable ); - - jQuery( 'ul.field_type_list, .field_type_list li, ul.frm_code_list, .frm_code_list li, .frm_code_list li a, #frm_adv_info #category-tabs li, #frm_adv_info #category-tabs li a' ).disableSelection(); - - jQuery( '.frm_submit_ajax' ).on( 'click', submitBuild ); - jQuery( '.frm_submit_no_ajax' ).on( 'click', submitNoAjax ); - - addFormNameModalEvents(); - - jQuery( 'a.edit-form-status' ).on( 'click', slideDown ); - jQuery( '.cancel-form-status' ).on( 'click', slideUp ); - jQuery( '.save-form-status' ).on( 'click', function() { - const newStatus = jQuery( document.getElementById( 'form_change_status' ) ).val(); - jQuery( 'input[name="new_status"]' ).val( newStatus ); - jQuery( document.getElementById( 'form-status-display' ) ).html( newStatus ); - jQuery( '.cancel-form-status' ).trigger( 'click' ); - return false; - }); - - jQuery( '.frm_form_builder form' ).first().on( 'submit', function() { - jQuery( '.inplace_field' ).trigger( 'blur' ); - }); - - initiateMultiselect(); - renumberPageBreaks(); - - $builderForm = jQuery( builderForm ); - builderArea = document.getElementById( 'frm_form_editor_container' ); - $builderForm.on( 'click', '.frm_add_logic_row', addFieldLogicRow ); - $builderForm.on( 'click', '.frm_add_watch_lookup_row', addWatchLookupRow ); - $builderForm.on( 'change', '.frm_get_values_form', updateGetValueFieldSelection ); - $builderForm.on( 'change', '.frm_logic_field_opts', getFieldValues ); - $builderForm.on( 'frm-multiselect-changed', 'select[name^="field_options[admin_only_"]', adjustVisibilityValuesForEveryoneValues ); - - jQuery( document.getElementById( 'frm-insert-fields' ) ).on( 'click', '.frm_add_field', addFieldClick ); - $newFields.on( 'click', '.frm_clone_field', duplicateField ); - $builderForm.on( 'blur', 'input[id^="frm_calc"]', checkCalculationCreatedByUser ); - $builderForm.on( 'change', 'input.frm_format_opt, input.frm_max_length_opt', toggleInvalidMsg ); - $builderForm.on( 'change click', '[data-changeme]', liveChanges ); - $builderForm.on( 'click', 'input.frm_req_field', markRequired ); - $builderForm.on( 'click', '.frm_mark_unique', markUnique ); - - $builderForm.on( 'change', '.frm_repeat_format', toggleRepeatButtons ); - $builderForm.on( 'change', '.frm_repeat_limit', checkRepeatLimit ); - $builderForm.on( 'change', '.frm_js_checkbox_limit', checkCheckboxSelectionsLimit ); - $builderForm.on( 'input', 'input[name^="field_options[add_label_"]', function() { - updateRepeatText( this, 'add' ); - }); - $builderForm.on( 'input', 'input[name^="field_options[remove_label_"]', function() { - updateRepeatText( this, 'remove' ); - }); - $builderForm.on( 'change', 'select[name^="field_options[data_type_"]', maybeClearWatchFields ); - jQuery( builderArea ).on( 'click', '.frm-collapse-page', maybeCollapsePage ); - jQuery( builderArea ).on( 'click', '.frm-collapse-section', maybeCollapseSection ); - $builderForm.on( 'click', '.frm-single-settings h3', maybeCollapseSettings ); - $builderForm.on( 'keydown', '.frm-single-settings h3', function( event ) { - // If so, only proceed if the key pressed was 'Enter' or 'Space' - if ( event.key === 'Enter' || event.key === ' ' ) { - event.preventDefault(); - maybeCollapseSettings.call( this, event ); - } - }); - - jQuery( builderArea ).on( 'show.bs.dropdown hide.bs.dropdown', changeSectionStyle ); - - $builderForm.on( 'click', '.frm_toggle_sep_values', toggleSepValues ); - $builderForm.on( 'click', '.frm_toggle_image_options', toggleImageOptions ); - $builderForm.on( 'click', '.frm_remove_image_option', removeImageFromOption ); - $builderForm.on( 'click', '.frm_choose_image_box', addImageToOption ); - $builderForm.on( 'change', '.frm_hide_image_text', refreshOptionDisplay ); - $builderForm.on( 'change', '.frm_field_options_image_size', setImageSize ); - $builderForm.on( 'click', '.frm_multiselect_opt', toggleMultiselect ); - $newFields.on( 'mousedown', 'input, textarea, select', stopFieldFocus ); - $newFields.on( 'click', 'input[type=radio], input[type=checkbox]', stopFieldFocus ); - $newFields.on( 'click', '.frm_delete_field', clickDeleteField ); - $newFields.on( 'click', '.frm_select_field', clickSelectField ); - jQuery( document ).on( 'click', '.frm_delete_field_group', clickDeleteFieldGroup ); - jQuery( document ).on( 'click', '.frm_clone_field_group', duplicateFieldGroup ); - jQuery( document ).on( 'click', '#frm_field_group_controls > span:first-child', clickFieldGroupLayout ); - jQuery( document ).on( 'click', '.frm-row-layout-option', handleFieldGroupLayoutOptionClick ); - jQuery( document ).on( 'click', '.frm-merge-fields-into-row .frm-row-layout-option', handleFieldGroupLayoutOptionInsideMergeClick ); - jQuery( document ).on( 'click', '.frm-custom-field-group-layout', customFieldGroupLayoutClick ); - jQuery( document ).on( 'click', '.frm-merge-fields-into-row .frm-custom-field-group-layout', customFieldGroupLayoutInsideMergeClick ); - jQuery( document ).on( 'click', '.frm-break-field-group', breakFieldGroupClick ); - $newFields.on( 'click', '#frm_field_group_popup .frm_grid_container input', focusFieldGroupInputOnClick ); - jQuery( document ).on( 'click', '.frm-cancel-custom-field-group-layout', cancelCustomFieldGroupClick ); - jQuery( document ).on( 'click', '.frm-save-custom-field-group-layout', saveCustomFieldGroupClick ); - $newFields.on( 'click', 'ul.frm_sorting', fieldGroupClick ); - jQuery( document ).on( 'click', '.frm-merge-fields-into-row', mergeFieldsIntoRowClick ); - jQuery( document ).on( 'click', '.frm-delete-field-groups', deleteFieldGroupsClick ); - $newFields.on( 'click', '.frm-field-action-icons [data-toggle="dropdown"]', function() { - this.closest( 'li.form-field' ).classList.add( 'frm-field-settings-open' ); - jQuery( document ).on( 'click', '#frm_builder_page', handleClickOutsideOfFieldSettings ); - }); - $newFields.on( 'mousemove', 'ul.frm_sorting', checkForMultiselectKeysOnMouseMove ); - $newFields.on( 'show.bs.dropdown', '.frm-field-action-icons', onFieldActionDropdownShow ); - jQuery( document ).on( 'show.bs.dropdown', '#frm_field_group_controls', onFieldGroupActionDropdownShow ); - $builderForm.on( 'click', '.frm_single_option a[data-removeid]', deleteFieldOption ); - $builderForm.on( 'mousedown', '.frm_single_option input[type=radio]', maybeUncheckRadio ); - $builderForm.on( 'focusin', '.frm_single_option input[type=text]', maybeClearOptText ); - $builderForm.on( 'click', '.frm_add_opt', addFieldOption ); - $builderForm.on( 'change', '.frm_single_option input', resetOptOnChange ); - $builderForm.on( 'change', '.frm_image_id', resetOptOnChange ); - $builderForm.on( 'change', '.frm_toggle_mult_sel', toggleMultSel ); - $builderForm.on( 'focusin', '.frm_classes', showBuilderModal ); - - $newFields.on( 'click', '.frm_primary_label', clickLabel ); - $newFields.on( 'click', '.frm_description', clickDescription ); - $newFields.on( 'click', 'li.ui-state-default:not(.frm_noallow)', clickVis ); - $newFields.on( 'dblclick', 'li.ui-state-default', openAdvanced ); - $builderForm.on( 'change', '.frm_tax_form_select', toggleFormTax ); - $builderForm.on( 'change', 'select.conf_field', addConf ); - - $builderForm.on( 'change', '.frm_get_field_selection', getFieldSelection ); - - $builderForm.on( 'click', '.frm-show-inline-modal', maybeShowInlineModal ); - - $builderForm.on( 'click', '.frm-inline-modal .dismiss', dismissInlineModal ); - jQuery( document ).on( 'change', '[data-frmchange]', changeInputtedValue ); - - $builderForm.on( 'change', '.frm_include_extras_field', rePopCalcFieldsForSummary ); - $builderForm.on( 'change', 'select[name^="field_options[form_select_"]', maybeChangeEmbedFormMsg ); - - jQuery( document ).on( 'submit', '#frm_js_build_form', buildSubmittedNoAjax ); - jQuery( document ).on( 'change', '#frm_builder_page input:not(.frm-search-input):not(.frm-custom-grid-size-input), #frm_builder_page select, #frm_builder_page textarea', fieldUpdated ); - - popAllProductFields(); - - jQuery( document ).on( 'change', '.frmjs_prod_data_type_opt', toggleProductType ); - - jQuery( document ).on( 'focus', '.frm-single-settings ul input[type="text"][name^="field_options[options_"]', onOptionTextFocus ); - jQuery( document ).on( 'blur', '.frm-single-settings ul input[type="text"][name^="field_options[options_"]', onOptionTextBlur ); - - frmDom.util.documentOn( 'click', '.frm-show-field-settings', clickVis ); - frmDom.util.documentOn( 'change', 'select.frm_format_dropdown, select.frm_phone_type_dropdown', maybeUpdateFormatInput ); - - // Navigate to the next input field on pressing Enter in a single option field - $builderForm.on( 'keydown', '.frm_single_option input[name^="field_options["], .frm_single_option input[name^="rows_"]', event => { - if ( 'Enter' === event.key ) { - focusNextSingleOptionInput( event.currentTarget ); - } - }); - - initBulkOptionsOverlay(); - hideEmptyEle(); - maybeHideQuantityProductFieldOption(); - handleNameFieldOnFormBuilder(); - toggleSectionHolder(); - handleShowPasswordLiveUpdate(); - document.addEventListener( 'scroll', updateShortcodesPopupPosition, true ); - document.addEventListener( 'change', handleBuilderChangeEvent ); - document.querySelector( '.frm_form_builder' ).addEventListener( 'mousedown', event => { - if ( event.shiftKey ) { - event.preventDefault(); - } - }); - }, - - settingsInit: function() { - const $formActions = jQuery( document.getElementById( 'frm_notification_settings' ) ); - - let formSettings, $loggedIn, $cookieExp, $editable; - - // BCC, CC, and Reply To button functionality - $formActions.on( 'click', '.frm_email_buttons', showEmailRow ); - $formActions.on( 'click', '.frm_remove_field', hideEmailRow ); - $formActions.on( 'change', '.frm_to_row, .frm_from_row', showEmailWarning ); - $formActions.on( 'change', '.frm_tax_selector', changePosttaxRow ); - $formActions.on( 'change', 'select.frm_single_post_field', checkDupPost ); - $formActions.on( 'change', 'select.frm_toggle_post_content', togglePostContent ); - $formActions.on( 'change', 'select.frm_dyncontent_opt', fillDyncontent ); - $formActions.on( 'change', '.frm_post_type', switchPostType ); - $formActions.on( 'click', '.frm_add_postmeta_row', addPostmetaRow ); - $formActions.on( 'click', '.frm_add_posttax_row', addPosttaxRow ); - $formActions.on( 'click', '.frm_toggle_cf_opts', toggleCfOpts ); - $formActions.on( 'click', '.frm_duplicate_form_action', copyFormAction ); - jQuery( '.frm_actions_list' ).on( 'click', '.frm_active_action', addFormAction ); - jQuery( '#frm-show-groups, #frm-hide-groups' ).on( 'click', toggleActionGroups ); - initiateMultiselect(); - - //set actions icons to inactive - jQuery( 'ul.frm_actions_list li' ).each( function() { - checkActiveAction( jQuery( this ).children( 'a' ).data( 'actiontype' ) ); - - // If the icon is a background image, don't add BG color. - const icon = jQuery( this ).find( 'i' ); - if ( icon.css( 'background-image' ) !== 'none' ) { - icon.addClass( 'frm-inverse' ); - } - }); - - jQuery( '.frm_submit_settings_btn' ).on( 'click', submitSettings ); - - addFormNameModalEvents(); - - formSettings = jQuery( '.frm_form_settings' ); - formSettings.on( 'click', '.frm_add_form_logic', addFormLogicRow ); - formSettings.on( 'click', '.frm_already_used', actionLimitMessage ); - - document.addEventListener( - 'click', - function handleImageUploadClickEvents( event ) { - const { target } = event; - - if ( ! target.closest( '.frm_image_preview_wrapper' ) ) { - return; - } - - if ( target.closest( '.frm_choose_image_box' ) ) { - addImageToOption.bind( target )( event ); - return; - } - - if ( target.closest( '.frm_remove_image_option' ) ) { - removeImageFromOption.bind( target )( event ); - } - } - ); - - // Close shortcode modal on click. - formSettings.on( 'mouseup', '*:not(.frm-show-box)', maybeHideShortcodes ); - - //Warning when user selects "Do not store entries ..." - jQuery( document.getElementById( 'no_save' ) ).on( 'change', function() { - if ( this.checked ) { - if ( confirm( frmAdminJs.no_save_warning ) !== true ) { - // Uncheck box if user hits "Cancel" - jQuery( this ).attr( 'checked', false ); - } - } - }); - - jQuery( 'select[name="options[edit_action]"]' ).on( 'change', showSuccessOpt ); - - $loggedIn = document.getElementById( 'logged_in' ); - jQuery( $loggedIn ).on( 'change', function() { - if ( this.checked ) { - visible( '.hide_logged_in' ); - } else { - invisible( '.hide_logged_in' ); - } - }); - - $cookieExp = jQuery( document.getElementById( 'frm_cookie_expiration' ) ); - jQuery( document.getElementById( 'frm_single_entry_type' ) ).on( 'change', function() { - if ( this.value === 'cookie' ) { - $cookieExp.fadeIn( 'slow' ); - } else { - $cookieExp.fadeOut( 'slow' ); - } - }); - - const $singleEntry = document.getElementById( 'single_entry' ); - jQuery( $singleEntry ).on( 'change', function() { - if ( this.checked ) { - visible( '.hide_single_entry' ); - } else { - invisible( '.hide_single_entry' ); - } - - if ( this.checked && jQuery( document.getElementById( 'frm_single_entry_type' ) ).val() === 'cookie' ) { - $cookieExp.fadeIn( 'slow' ); - } else { - $cookieExp.fadeOut( 'slow' ); - } - }); - - jQuery( '.hide_save_draft' ).hide(); - - const $saveDraft = jQuery( document.getElementById( 'save_draft' ) ); - $saveDraft.on( 'change', function() { - if ( this.checked ) { - jQuery( '.hide_save_draft' ).fadeIn( 'slow' ); - } else { - jQuery( '.hide_save_draft' ).fadeOut( 'slow' ); - } - }); - triggerChange( $saveDraft ); - - //If Allow editing is checked/unchecked - $editable = document.getElementById( 'editable' ); - jQuery( $editable ).on( 'change', function() { - if ( this.checked ) { - jQuery( '.hide_editable' ).fadeIn( 'slow' ); - triggerChange( document.getElementById( 'edit_action' ) ); - } else { - jQuery( '.hide_editable' ).fadeOut( 'slow' ); - jQuery( '.edit_action_message_box' ).fadeOut( 'slow' );//Hide On Update message box - } - }); - - //If File Protection is checked/unchecked - jQuery( document ).on( 'change', '#protect_files', function() { - if ( this.checked ) { - jQuery( '.hide_protect_files' ).fadeIn( 'slow' ); - } else { - jQuery( '.hide_protect_files' ).fadeOut( 'slow' ); - } - }); - - jQuery( document ).on( 'frm-multiselect-changed', '#protect_files_role', adjustVisibilityValuesForEveryoneValues ); - - jQuery( document ).on( 'submit', '.frm_form_settings', settingsSubmitted ); - jQuery( document ).on( 'change', '#form_settings_page input:not(.frm-search-input), #form_settings_page select, #form_settings_page textarea', fieldUpdated ); - - // Page Selection Autocomplete - initAutocomplete(); - - jQuery( document ).on( 'frm-action-loaded', onActionLoaded ); - - initOnSubmitAction(); - }, - - panelInit: function() { - let customPanel, settingsPage, viewPage, insertFieldsTab; - - jQuery( '.frm_wrap, #postbox-container-1' ).on( 'click', '.frm_insert_code', insertCode ); - jQuery( document ).on( 'change', '.frm_insert_val', function() { - insertFieldCode( jQuery( this ).data( 'target' ), jQuery( this ).val() ); - jQuery( this ).val( '' ); - }); - - jQuery( document ).on( 'click change', '#frm-id-key-condition', resetLogicBuilder ); - jQuery( document ).on( 'keyup change', '.frm-build-logic', setLogicExample ); - - showInputIcon(); - jQuery( document ).on( 'frmElementAdded', function( event, parentEle ) { - /* This is here for add-ons to trigger */ - showInputIcon( parentEle ); - }); - jQuery( document ).on( 'mousedown', '.frm-show-box', showShortcodes ); - - settingsPage = document.getElementById( 'form_settings_page' ); - viewPage = document.body.classList.contains( 'post-type-frm_display' ); - insertFieldsTab = document.getElementById( 'frm_insert_fields_tab' ); - - if ( settingsPage !== null || viewPage || builderPage ) { - jQuery( document ).on( 'focusin', 'form input, form textarea', function( e ) { - let htmlTab; - e.stopPropagation(); - maybeShowModal( this ); - - if ( jQuery( this ).is( ':not(:submit, input[type=button], .frm-search-input, input[type=checkbox])' ) ) { - if ( jQuery( e.target ).closest( '#frm_adv_info' ).length ) { - // Don't trigger for fields inside of the modal. - return; - } - - if ( settingsPage !== null || builderPage ) { - /* form settings page */ - htmlTab = jQuery( '#frm_html_tab' ); - if ( jQuery( this ).closest( '#html_settings' ).length > 0 ) { - htmlTab.show(); - htmlTab.siblings().hide(); - jQuery( '#frm_html_tab a' ).trigger( 'click' ); - toggleAllowedHTML( this ); - } else { - showElement( jQuery( '.frm-category-tabs li' ) ); - insertFieldsTab.click(); - htmlTab.hide(); - htmlTab.siblings().show(); - } - } else if ( viewPage ) { - const event = new CustomEvent( 'frm_legacy_views_handle_field_focus' ); - event.frmData = { idAttrValue: this.id }; - document.dispatchEvent( event ); - } - } - }); - } - - jQuery( '.frm_wrap, #postbox-container-1' ).on( 'mousedown', '#frm_adv_info a, .frm_field_list a', function( e ) { - e.preventDefault(); - }); - - customPanel = jQuery( '#frm_adv_info' ); - customPanel.on( 'click', '.subsubsub a.frmids', function( e ) { - toggleKeyID( 'frmids', e ); - }); - customPanel.on( 'click', '.subsubsub a.frmkeys', function( e ) { - toggleKeyID( 'frmkeys', e ); - }); - }, - - inboxInit: function() { - jQuery( '.frm_inbox_dismiss' ).on( 'click', function( e ) { - const message = this.parentNode.parentNode; - const key = message.getAttribute( 'data-message' ); - const href = this.getAttribute( 'href' ); - const dismissedMessage = message.cloneNode( true ); - const dismissedMessagesWrapper = document.querySelector( '.frm-dismissed-inbox-messages' ); - - if ( 'free_templates' === key && ! this.classList.contains( 'frm_inbox_dismiss' ) ) { - return; - } - - e.preventDefault(); - - data = { - action: 'frm_inbox_dismiss', - key, - nonce: frmGlobal.nonce - }; - - const isInboxSlideIn = 'frm_inbox_slide_in' === message.id; - if ( isInboxSlideIn ) { - message.classList.remove( 's11-fadein' ); - message.classList.add( 's11-fadeout' ); - message.addEventListener( 'animationend', () => message.remove(), { once: true }); - } - - postAjax( - data, - () => { - if ( isInboxSlideIn ) { - return; - } - - if ( href !== '#' ) { - window.location = href; - return true; - } - - fadeOut( - message, - () => { - if ( null !== dismissedMessagesWrapper ) { - dismissedMessage.classList.remove( 'frm-fade' ); - dismissedMessage.querySelector( '.frm-inbox-message-heading' )?.removeChild( dismissedMessage.querySelector( '.frm-inbox-message-heading .frm_inbox_dismiss' ) ); - dismissedMessagesWrapper.append( dismissedMessage ); - } - if ( 1 === message.parentNode.querySelectorAll( '.frm-inbox-message-container' ).length ) { - document.getElementById( 'frm_empty_inbox' ).classList.remove( 'frm_hidden' ); - message.parentNode.closest( '.frm-active' ).classList.add( 'frm-empty-inbox' ); - showActiveCampaignForm(); - } - message.parentNode.removeChild( message ); - } - ); - } - ); - }); - - if ( false === document.getElementById( 'frm_empty_inbox' )?.classList.contains( 'frm_hidden' ) ) { - showActiveCampaignForm(); - } - }, - - solutionInit: function() { - jQuery( document ).on( 'submit', '#frm-new-template', installTemplate ); - }, - - styleInit: function() { - const $previewWrapper = jQuery( '.frm_image_preview_wrapper' ); - $previewWrapper.on( 'click', '.frm_choose_image_box', addImageToOption ); - $previewWrapper.on( 'click', '.frm_remove_image_option', removeImageFromOption ); - - wp.hooks.doAction( 'frm_style_editor_init' ); - }, - - customCSSInit: function() { - console.warn( 'Calling frmAdminBuild.customCSSInit is deprecated.' ); - }, - - globalSettingsInit: function() { - let licenseTab; - - jQuery( document ).on( 'click', '[data-frmuninstall]', uninstallNow ); - - initiateMultiselect(); - - // activate addon licenses - licenseTab = document.getElementById( 'licenses_settings' ); - if ( licenseTab !== null ) { - jQuery( licenseTab ).on( 'click', '.edd_frm_save_license', saveAddonLicense ); - } - - // Solution install page - jQuery( document ).on( 'click', '#frm-new-template button', installTemplateFieldset ); - - jQuery( '#frm-dismissable-cta .dismiss' ).on( 'click', function( event ) { - event.preventDefault(); - jQuery.post( - ajaxurl, - { - action: 'frm_lite_settings_upgrade', - nonce: frmGlobal.nonce - } - ); - jQuery( '.settings-lite-cta' ).remove(); - }); - - const captchaType = document.getElementById( 'frm_re_type' ); - if ( captchaType ) { - captchaType.addEventListener( 'change', handleCaptchaTypeChange ); - } - - document.querySelector( '.frm_captchas' ).addEventListener( 'change', function( event ) { - const captchaValueOnLoad = document.querySelector( '.frm_captchas input[checked="checked"]' )?.value; - const showNote = event.target.value !== captchaValueOnLoad; - document.querySelector( '.captcha_settings .frm_note_style' ).classList.toggle( 'frm_hidden', ! showNote ); - }); - - // Set fieldsUpdated to 0 to avoid the unsaved changes pop up. - frmDom.util.documentOn( 'submit', '.frm_settings_form', () => fieldsUpdated = 0 ); - - const manageStyleSettings = document.getElementById( 'manage_styles_settings' ); - if ( manageStyleSettings ) { - manageStyleSettings.addEventListener( - 'change', - event => { - const target = event.target; - if ( 'SELECT' !== target.nodeName || ! target.dataset.name || target.getAttribute( 'name' ) ) { - return; - } - - target.setAttribute( 'name', target.dataset.name ); - } - ); - } - - const paymentsSettings = document.getElementById( 'payments_settings' ); - const paymentSettingsTabs = paymentsSettings?.querySelectorAll( '[name="frm_payment_section"]' ); - if ( paymentSettingsTabs ) { - paymentSettingsTabs.forEach( - element => { - element.addEventListener( 'change', () => { - if ( ! element.checked ) { - return; - } - - const label = paymentsSettings.querySelector( `label[for="${ element.id }"]` ); - if ( label ) { - label.setAttribute( 'aria-selected', 'true' ); - } - - paymentSettingsTabs.forEach( - tab => { - if ( tab === element ) { - return; - } - - const label = paymentsSettings.querySelector( `label[for="${ tab.id }"]` ); - if ( label ) { - label.setAttribute( 'aria-selected', 'false' ); - } - } - ); - }); - } - ); - } - }, - - exportInit: function() { - jQuery( '.frm_form_importer' ).on( 'submit', startFormMigration ); - jQuery( document.getElementById( 'frm_export_xml' ) ).on( 'submit', validateExport ); - jQuery( '#frm_export_xml input, #frm_export_xml select' ).on( 'change', removeExportError ); - jQuery( 'input[name="frm_import_file"]' ).on( 'change', checkCSVExtension ); - document.querySelector( 'select[name="format"]' ).addEventListener( 'change', exportTypeChanged ); - - jQuery( 'input[name="frm_export_forms[]"]' ).on( 'click', preventMultipleExport ); - initiateMultiselect(); - - jQuery( '.frm-feature-banner .dismiss' ).on( 'click', function( event ) { - event.preventDefault(); - jQuery.post( ajaxurl, { - action: 'frm_dismiss_migrator', - plugin: this.id, - nonce: frmGlobal.nonce - }); - this.parentElement.remove(); - }); - - showOrHideRepeaters( getExportOption() ); - - document.querySelector( '#frm-export-select-all' ).addEventListener( 'change', event => { - document.querySelectorAll( '[name="frm_export_forms[]"]' ).forEach( cb => cb.checked = event.target.checked ); - }); - }, - - inboxBannerInit: function() { - const banner = document.getElementById( 'frm_banner' ); - if ( ! banner ) { - return; - } - - const dismissButton = banner.querySelector( '.frm-banner-dismiss' ); - document.addEventListener( - 'click', - function( event ) { - if ( event.target !== dismissButton ) { - return; - } - - const data = { - action: 'frm_inbox_dismiss', - key: banner.dataset.key, - nonce: frmGlobal.nonce - }; - postAjax( - data, - function() { - jQuery( banner ).fadeOut( - 400, - function() { - banner.remove(); - } - ); - } - ); - } - ); - }, - - updateOpts: function( fieldId, opts, modal ) { - const separate = usingSeparateValues( fieldId ), - action = isProductField( fieldId ) ? 'frm_bulk_products' : 'frm_import_options'; - jQuery.ajax({ - type: 'POST', - url: ajaxurl, - data: { - action: action, - field_id: fieldId, - opts: opts, - separate: separate, - nonce: frmGlobal.nonce - }, - success: function( html ) { - document.getElementById( 'frm_field_' + fieldId + '_opts' ).innerHTML = html; - wp.hooks.doAction( 'frm_after_bulk_edit_opts', fieldId ); - resetDisplayedOpts( fieldId ); - - if ( typeof modal !== 'undefined' ) { - modal.dialog( 'close' ); - document.getElementById( 'frm-update-bulk-opts' ).classList.remove( 'frm_loading_button' ); - } - } - }); - }, - - /* remove conditional logic if the field doesn't exist */ - triggerRemoveLogic: function( fieldID, metaName ) { - jQuery( '#frm_logic_' + fieldID + '_' + metaName + ' .frm_remove_tag' ).trigger( 'click' ); - }, - - downloadXML: function( controller, ids, isTemplate ) { - let url = ajaxurl + '?action=frm_' + controller + '_xml&ids=' + ids; - if ( isTemplate !== null ) { - url = url + '&is_template=' + isTemplate; - } - location.href = url; - }, - - /** - * @since 5.0.04 - */ - hooks: { - applyFilters: function( hookName, ...args ) { - return wp.hooks.applyFilters( hookName, ...args ); - }, - addFilter: function( hookName, callback, priority ) { - return wp.hooks.addFilter( hookName, 'formidable', callback, priority ); - }, - doAction: function( hookName, ...args ) { - return wp.hooks.doAction( hookName, ...args ); - }, - addAction: function( hookName, callback, priority ) { - return wp.hooks.addAction( hookName, 'formidable', callback, priority ); - } - }, - - applyZebraStriping, - initModal, - infoModal, - offsetModalY, - adjustConditionalLogicOptionOrders, - addRadioCheckboxOpt, - installNewForm, - toggleAddonState, - purifyHtml, - loadApiEmailForm, - addMyEmailAddress, - fillDropdownOpts, - showSaveAndReloadModal, - deleteField, - insertFormField, - confirmLinkClick, - handleInsertFieldByDraggingResponse, - handleAddFieldClickResponse, - syncLayoutClasses, - }; -} - -window.frmAdminBuild = frmAdminBuildJS(); - -jQuery( document ).ready( - () => { - frmAdminBuild.init(); - - frmDom.bootstrap.setupBootstrapDropdowns( convertOldBootstrapDropdownsToBootstrap4 ); - document.querySelector( '.preview.dropdown .frm-dropdown-toggle' )?.setAttribute( 'data-toggle', 'dropdown' ); - - function convertOldBootstrapDropdownsToBootstrap4( frmDropdownMenu ) { - const toggle = frmDropdownMenu.querySelector( '.frm-dropdown-toggle' ); - if ( toggle ) { - if ( ! toggle.hasAttribute( 'role' ) ) { - toggle.setAttribute( 'role', 'button' ); - } - if ( ! toggle.hasAttribute( 'tabindex' ) ) { - toggle.setAttribute( 'tabindex', 0 ); - } - } - - // Convert
    • and
        tags. - if ( 'UL' === frmDropdownMenu.tagName ) { - convertBootstrapUl( frmDropdownMenu ); - } - } - - function convertBootstrapUl( ul ) { - let html = ul.outerHTML; - html = html.replace( '
          ', '' ); - html = html.replaceAll( '
        • ', '
        • ', '' ); - ul.outerHTML = html; - } - } -); - -function frm_show_div( div, value, showIf, classId ) { // eslint-disable-line camelcase - if ( value == showIf ) { - jQuery( classId + div ).fadeIn( 'slow' ).css( 'visibility', 'visible' ); - } else { - jQuery( classId + div ).fadeOut( 'slow' ); - } -} - -function frmCheckAll( checked, n ) { - jQuery( 'input[name^="' + n + '"]' ).prop( 'checked', ! ! checked ); -} - -function frmCheckAllLevel( checked, n, level ) { - const $kids = jQuery( '.frm_catlevel_' + level ).children( '.frm_checkbox' ).children( 'label' ); - $kids.children( 'input[name^="' + n + '"]' ).prop( 'checked', ! ! checked ); -} - -function frmGetFieldValues( fieldId, cur, rowNumber, fieldType, htmlName, callback ) { - if ( ! fieldId ) { - return; - } - - jQuery.ajax({ - type: 'POST', url: ajaxurl, - data: 'action=frm_get_field_values¤t_field=' + cur + '&field_id=' + fieldId + '&name=' + htmlName + '&t=' + fieldType + '&form_action=' + jQuery( 'input[name="frm_action"]' ).val() + '&nonce=' + frmGlobal.nonce, - success: function( msg ) { - document.getElementById( 'frm_show_selected_values_' + cur + '_' + rowNumber ).innerHTML = msg; - - if ( 'function' === typeof callback ) { - callback(); - } - } - }); -} - -function frmImportCsv( formID ) { - let urlVars = ''; - if ( typeof __FRMURLVARS !== 'undefined' ) { - urlVars = __FRMURLVARS; - } - - jQuery.ajax({ - type: 'POST', url: ajaxurl, - data: 'action=frm_import_csv&nonce=' + frmGlobal.nonce + '&frm_skip_cookie=1' + urlVars, - success: function( count ) { - const max = jQuery( '.frm_admin_progress_bar' ).attr( 'aria-valuemax' ); - const imported = max - count; - const percent = ( imported / max ) * 100; - jQuery( '.frm_admin_progress_bar' ).css( 'width', percent + '%' ).attr( 'aria-valuenow', imported ); - - if ( parseInt( count, 10 ) > 0 ) { - jQuery( '.frm_csv_remaining' ).html( count ); - frmImportCsv( formID ); - } else { - jQuery( document.getElementById( 'frm_import_message' ) ).html( frm_admin_js.import_complete ); // eslint-disable-line camelcase - setTimeout( function() { - location.href = '?page=formidable-entries&frm_action=list&form=' + formID + '&import-message=1'; - }, 2000 ); - } - } - }); -} +(()=>{function e(e){return function(e){if(Array.isArray(e))return r(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||t(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function t(e,t){if(e){if("string"==typeof e)return r(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}}function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r1&&(e="",t=""):0===i.indexOf("frm_postmeta_")&&(jQuery("#frm_postmeta_rows .frm_postmeta_row").length<2&&(e=".frm_add_postmeta_row.button"),jQuery(".frm_toggle_cf_opts").length&&jQuery("#frm_postmeta_rows .frm_postmeta_row:not(#"+i+")").last().length&&(""!==e&&(e+=","),e+="#"+jQuery("#frm_postmeta_rows .frm_postmeta_row:not(#"+i+")").last().attr("id")+" .frm_toggle_cf_opts"));var o=jQuery(document.getElementById(i));return o.fadeOut(400,(function(){var r;o.remove(),Ni(),""!==t&&jQuery(t).hide(),""!==e&&jQuery(e+" a,"+e).removeClass("frm_hidden").fadeIn("slow"),this.closest(".frm_form_action_settings")&&function(e){ii(e);var t={type:e};wp.hooks.doAction("frm_after_action_removed",t)}(this.closest(".frm_form_action_settings").querySelector(".frm_action_name").value),null===(r=document.querySelector(".tooltip"))||void 0===r||r.remove()})),void 0!==r&&(r=jQuery(r)).fadeOut(400,(function(){r.remove()})),""!==e&&jQuery(this).closest(".frm_logic_rows").fadeOut("slow"),!1}}function $(e,t){void 0===t&&(t=this),Ze(t,!1);var r=jQuery(t).closest(".frm_form_action_settings"),n=e.target;if(r.length&&void 0!==n){var i=n.parentElement.className;if("string"==typeof i&&(i.indexOf("frm_email_icons")>-1||i.indexOf("frm_toggle")>-1))return void e.stopPropagation()}var o=r.children(".widget-inside");if(r.length&&o.find("p, div, table").length<1){var a=r.find('input[name$="[ID]"]').val(),l=r.find('input[name$="[post_excerpt]"]').val();l&&(o.html(''),r.find(".spinner").fadeIn("slow"),jQuery.ajax({type:"POST",url:ajaxurl,data:{action:"frm_form_action_fill",action_id:a,action_type:l,nonce:frmGlobal.nonce},success:function(e){o.html(e),no(),Un("#"+r.attr("id")),yo(o),jQuery(t).trigger("frm-action-loaded"),wp.hooks.doAction("frm_filled_form_action",o)}}))}jQuery(t).closest(".frm_field_box").siblings().find(".widget-inside").slideUp("fast"),void 0!==t.className&&-1!==t.className.indexOf("widget-action")||jQuery(t).closest(".start_divider").length<1||((o=jQuery(t).closest("div.widget").children(".widget-inside")).is(":hidden")?o.slideDown("fast"):o.slideUp("fast"))}function W(){var e=this.getAttribute("href");if(void 0===e)return!1;var t=e.replace("#","."),r=jQuery(this);r.closest("li").addClass("frm-tabs active").siblings("li").removeClass("frm-tabs active starttab"),r.closest("div").children(".tabs-panel").not(e).not(t).hide();var n=document.getElementById(e.replace("#",""));return n&&(n.style.display="block"),"frm_insert_fields_tab"!==this.id||this.closest("#frm_adv_info")||Ke(),!1}function U(e,t){var r=(e=jQuery(e)).attr("href");if(void 0!==r){var n,i,o=r.replace("#",".");if(e.closest("li").addClass("frm-tabs active").siblings("li").removeClass("frm-tabs active starttab"),e.closest("div").find(".tabs-panel").length)e.closest("div").children(".tabs-panel").not(r).not(o).hide();else if(null!==document.getElementById("form_global_settings")){var a=e.data("frmajax");e.closest(".frm_wrap").find(".tabs-panel, .hide_with_tabs").hide(),void 0!==a&&"1"==a&&(n=r.replace("#",""),(i=jQuery(".frm_"+n+"_ajax")).length&&jQuery.ajax({type:"POST",url:ajaxurl,data:{action:"frm_settings_tab",tab:n.replace("_settings",""),nonce:frmGlobal.nonce},success:function(e){i.replaceWith(e)}}))}else jQuery("#frm-categorydiv .tabs-panel, .hide_with_tabs").hide();jQuery(r).show(),jQuery(o).show(),Pi(),"auto"!==t&&(jQuery(".frm_updated_message").hide(),jQuery(".frm_warning_style").hide()),jQuery(e).closest("#frm_adv_info").length||(jQuery(".frm_form_settings").length?jQuery(".frm_form_settings").attr("action","?page=formidable&frm_action=settings&id="+jQuery('.frm_form_settings input[name="id"]').val()+"&t="+r.replace("#","")):jQuery(".frm_settings_form").attr("action","?page=formidable-settings&t="+r.replace("#","")))}}function V(e){var t,r;document.querySelectorAll(e).forEach((function(e){K(e),Array.from(e.children).forEach((function(e){return X(e,".frm-move")}));var t=jQuery(e).children('[data-type="divider"]').children(".divider_section_only");t.length&&K(t)})),t=jQuery("#frm_builder_page"),r={items:".frm_sortable_field_opts li",axis:"y",opacity:.65,forcePlaceholderSize:!1,handle:".frm-drag",helper:function(e,t){return E=t.clone().insertAfter(t),t.clone()},stop:function(e,t){E&&E.remove(),tn(t.item.attr("id").replace("frm_delete_field_","").replace("-"+t.item.data("optkey")+"_container","")),Ni()}},jQuery(t).sortable(r)}function K(e){jQuery(e).droppable({accept:".frmbutton, li.frm_field_box",deactivate:ne,over:J,out:Y,tolerance:"pointer"})}function J(e,t){var r=function(e){return e.classList.contains("divider_section_only")&&(e=jQuery(e).nextAll(".start_divider.frm_sorting").get(0)),e}(e.target);if(!Qe(t.draggable[0],r,e))return r.classList.remove("frm-over-droppable"),void jQuery(r).parents("ul.frm_sorting").addClass("frm-over-droppable");document.querySelectorAll(".frm-over-droppable").forEach((function(e){return e.classList.remove("frm-over-droppable")})),r.classList.add("frm-over-droppable"),jQuery(r).parents("ul.frm_sorting").addClass("frm-over-droppable")}function Y(e){e.target.classList.remove("frm-over-droppable")}function X(e,t){var r={helper:Z,revert:"invalid",delay:10,start:ee,stop:te,drag:re,cursor:"grabbing",refreshPositions:!0,cursorAt:{top:0,left:90}};"string"==typeof t&&(r.handle=t),jQuery(e).draggable(r)}function Z(e){var t,r=e.delegateTarget;if(xe(r)){var n=document.getElementById("frm-insert-fields").querySelector(".frm_ttext").cloneNode(!0);return n.querySelector("use").setAttributeNS("http://www.w3.org/1999/xlink","href","#frm_field_group_layout_icon"),n.querySelector("span").textContent=B("Field Group","formidable"),n.classList.add("frm_field_box"),n.classList.add("ui-sortable-helper"),n}if(r.classList.contains("frmbutton"))return(t=r.cloneNode(!0)).classList.add("ui-sortable-helper"),r.classList.add("frm-new-field"),t;if(r.hasAttribute("data-ftype")){var i=r.getAttribute("data-ftype");if((t=(t=document.getElementById("frm-insert-fields").querySelector(".frm_t"+i)).cloneNode(!0)).classList.add("form-field"),t.classList.add("ui-sortable-helper"),t)return t.cloneNode(!0)}return d({className:"frmbutton"})}function ee(e,t){q.dragging=!0;var r,n=h;n.classList.add("frm-dragging-field"),document.body.classList.add("frm-dragging"),t.helper.addClass("frm-sortable-helper"),t.helper.initialOffset=n.scrollTop,e.target.classList.add("frm-drag-fade"),gr(),(r=document.querySelectorAll("ul.start_divider")).length&&r.forEach((function(e){[].slice.call(e.children).forEach((function(e){(0===e.children.length||1===e.children.length&&"ul"===e.firstElementChild.nodeName.toLowerCase()&&0===e.firstElementChild.children.length)&&e.remove()}))})),Me(),Oe(),R()}function te(){h.classList.remove("frm-dragging-field"),document.body.classList.remove("frm-dragging");var e=document.querySelector(".frm-drag-fade");e&&e.classList.remove("frm-drag-fade")}function re(e,t){!function(e){v.scrollTop((function(t,r){var n=e.clientY,i=h.offsetHeight,o=e.clientY-h.offsetTop,a=o-i/2;return o>i-50&&n>5?r+.1*a:o<70&&n<130?r-Math.abs(.1*a):r}))}(e);var r=e.target,n=function(){for(var e=document.getElementById("frm-show-fields");e.querySelector(".frm-over-droppable");)e=e.querySelector(".frm-over-droppable");return"frm-show-fields"!==e.id||e.classList.contains("frm-over-droppable")||(e=!1),e}(),i=document.getElementById("frm_drag_placeholder");if(Qe(r,n,e)){i||(i=s("li",{id:"frm_drag_placeholder",className:"sortable-placeholder"}));var o,a=t.helper.get(0);if((a.classList.contains("form-field")||a.classList.contains("frm_field_box"))&&(a.style.transform="translateY("+(o=t.helper,h.scrollTop-o.initialOffset+"px)")),"frm-show-fields"===n.id||n.classList.contains("start_divider"))return i.style.left=0,void function(e){var t,r=e.y,n=e.placeholder,i=jQuery(e.droppable);if($children=i.children().not(".edit_field_type_end_divider"),0===$children.length)i.prepend(n),t=0;else{var o=ie(i,r);if(o===$children.length){var a=jQuery($children.get(o-1));t=a.offset().top+a.outerHeight(),i.append(n);var l=i.children(".edit_field_type_end_divider");l.length&&i.append(l)}else t=jQuery($children.get(o)).offset().top,jQuery($children.get(o)).before(n)}t-=i.offset().top,n.style.top=t+"px"}({droppable:n,y:e.clientY,placeholder:i});i.style.top="",function(e){var t,r=e.x,n=e.placeholder,i=jQuery(e.droppable),o=ae(i);if(o.length){var a=function(e,t){var r,n,i,o,a=ae(e);for(o=0,r=a.length-1;r>=0;--r)if(n=a.get(r),t>(i=jQuery(n).offset().left)){o=r,t>i+jQuery(n).outerWidth()/2&&(o=r+1);break}return o}(i,r);if(a===o.length){var l=jQuery(o.get(a-1));t=l.offset().left+l.outerWidth(),i.append(n)}else t=jQuery(o.get(a)).offset().left,jQuery(o.get(a)).before(n),t-=0===a?4:8;t-=i.offset().left,n.style.left=t+"px"}}({droppable:n,x:e.clientX,placeholder:i})}else i&&i.remove()}function ne(e,t){if(q.dragging){q.dragging=!1;var r=t.draggable[0],n=document.getElementById("frm_drag_placeholder");if(!n)return t.helper.remove(),void y();!function(e){if(e.previousElementSibling&&e.previousElementSibling.classList.contains("frm-is-collapsed")){var t=jQuery(e).prevUntil('[data-type="break"]');if(t.length){var r=t.find(".frm-collapse-page").get(0);r&&r.click()}}}(n);var i=t.helper.parent(),o=t.helper.get(0).closest("ul.start_divider"),a=n.closest("ul.frm_sorting");r.classList.contains("frm-new-field")?function(e){if(ge(e))wp.hooks.doAction("frm_stopped_inserting_by_dragging",e);else{var t=document.getElementById("frm_drag_placeholder"),r=e.replace("|","-")+"_"+we(),n=s("li",{id:r,className:"frm-wait frmbutton_loadingnow"}),i=jQuery(n),o=fe(jQuery(t)),a=ue(o),l=me(o);t.parentNode.insertBefore(n,t),t.remove(),le(i);var d=0;"summary"===e&&(d=jQuery(".frmbutton_loadingnow#"+r).prevAll('li[data-type="break"]').length?1:0),jQuery.ajax({type:"POST",url:ajaxurl,data:pe(e,l,a,d),success:function(t){ye(t,i);var r=he(t);r&&wp.hooks.doAction("frm_after_field_added_in_form_builder",{field:t,fieldId:r,fieldType:e,form_id:a})},error:je})}}(r.id):function(e,t){t.parentNode.insertBefore(e,t)}(r,n);var l=o?parseInt(o.closest(".edit_field_type_divider").getAttribute("data-fid")):0,d=a.classList.contains("start_divider")?parseInt(a.closest(".edit_field_type_divider").getAttribute("data-fid")):0;n.remove(),t.helper.remove();var c=i.length?ae(i):[];!function(e,t){var r;e.length&&(t.length?le(t.first()):(r=e.get(0).closest("li.frm_field_box"))&&!r.classList.contains("edit_field_type_divider")&&r.remove())}(i,c),function(e,t){0===t.length&&1===ae(jQuery(e.parentNode)).length||le(jQuery(e))}(r,c),l!==d&&_e(jQuery(r),o),y()}}function ie(e,t){var r,n,i,o,a=e.children().not(".edit_field_type_end_divider"),l=a.length;if(!document.querySelector(".frm-has-fields .frm_no_fields"))return 0;for(o=0,r=l-1;r>=0;--r)if(n=a.get(r),t>(i=jQuery(n).offset().top)){o=r,t>i+jQuery(n).outerHeight()/2&&(o=r+1);break}return o}function oe(){document.querySelectorAll("ul#frm-show-fields, ul.start_divider").forEach((function(e){e.childNodes.forEach((function(e){void 0!==e.classList&&(e.classList.contains("edit_field_type_end_divider")||void 0!==e.classList&&e.classList.contains("form-field")&&We(e))}))})),Qn(),document.querySelectorAll(".edit_field_type_end_divider").forEach((function(e){return e.parentNode.appendChild(e)})),document.querySelectorAll("li.form_field_box:not(.form-field)").forEach((function(e){return!e.children.length&&e.remove()})),wn();var e=new Event("frm_sync_after_drag_and_drop",{bubbles:!1});document.dispatchEvent(e)}function ae(e){var t=jQuery(),r=e.get(0);return r.children?(Array.from(r.children).forEach((function(e){if("none"!==e.style.display){var r=e.classList;!r.contains("form-field")||r.contains("edit_field_type_end_divider")||r.contains("frm-sortable-helper")||(t=t.add(e))}})),t):t}function le(e,t){var r,n,i,o;void 0===t&&(t="even"),r=e.parent().children("li.form-field, li.frmbutton_loadingnow").not(".edit_field_type_end_divider"),n=r.length,i=["frm_full","frm_half","frm_third","frm_fourth","frm_sixth","frm_two_thirds","frm_three_fourths","frm1","frm2","frm3","frm4","frm5","frm6","frm7","frm8","frm9","frm10","frm11","frm12"],"even"===t&&5!==n?r.each(ce(i,Ut(n))):"clear"===t?r.each(ce(i,"")):(o=-1!==["left","right","middle","even"].indexOf(t)?function(e){return Wt(n,t,e)}:function(e){return ar(t[e])},r.each(ce(i,o))),se(e.parent(),r.length)}function se(e,t){var r,n;if(void 0!==e.offset()){if(r=t>=2,null===(n=document.getElementById("frm_field_group_controls"))){if(!r)return;(n=d()).id="frm_field_group_controls",n.setAttribute("role","group"),n.setAttribute("tabindex",0),function(e){var t,r;(t=document.createElement("span")).innerHTML='';var n=B("Set Row Layout","formidable");de(t,n),Pt(t,n),(r=document.createElement("span")).innerHTML='',r.classList.add("frm-move");var i=B("Move Field Group","formidable");de(r,i),Pt(r,i),e.innerHTML="",e.appendChild(t),e.appendChild(r),e.appendChild(function(){var e=c({className:"dropdown"}),t=f({className:"frm_bstooltip frm-hover-icon frm-dropdown-toggle dropdown-toggle",children:[c({child:u({href:"#frm_thick_more_vert_icon"})}),c({className:"screen-reader-text",text:B("Toggle More Options Dropdown","formidable")})]});frmDom.setAttributes(t,{title:B("More Options","formidable"),"data-toggle":"dropdown","data-container":"body"}),Pt(t,B("More Options","formidable")),e.appendChild(t);var r=d({className:"frm-dropdown-menu dropdown-menu dropdown-menu-right"});return r.setAttribute("role","menu"),e.appendChild(r),e}())}(n),D.appendChild(n)}e.append(n),n.style.display=r?"block":"none"}}function de(e,t){e.setAttribute("data-toggle","tooltip"),e.setAttribute("data-container","body"),e.setAttribute("title",t),e.addEventListener("mouseover",(function(){null===e.getAttribute("data-original-title")&&jQuery(e).tooltip()}))}function ce(e,t){return function(r){var n,i,o,a,l,s,d;for(n="function"==typeof t?t(r):t,i=e.length,l=!1,o=0;ot.childElementCount-1:s<=jQuery(t.querySelector(".edit_field_type_submit").closest("#frm-show-fields > li")).index()}if(a)return!(t.classList.contains("start_divider")||!Ee(t.parentElement)&&(!Ee(t.parentElement.nextElementSibling)||e.parentElement.querySelector("li.frm_field_box:not(.edit_field_type_submit)")));if(t.classList.contains("start_divider")&&(e.classList.contains("edit_field_type_gdpr")||"gdpr"===e.id)&&t.closest(".repeat_section"))return!1;if(!t.classList.contains("start_divider")){if(n=ae(jQuery(t)),i=jQuery(e),!(n.length<6)&&(n.length>6||(o=i.attr("data-fid"),1!==jQuery(n).filter('[data-fid="'+o+'"]').length)))return!1;if("divider"===e.id&&t.closest(".start_divider"))return!1}return e.classList.contains("frm-new-field")?function(e,t){var r=e.classList,n=r.contains("frm_tbreak"),i=r.contains("frm_thidden"),o=r.contains("frm_tdivider"),a=r.contains("frm_tform"),l=r.contains("frm_tuser_id");return"frm-show-fields"===t.id||t.classList.contains("start_divider")?!(n||i||o||a)||(!(t.classList.contains("start_divider")||null!==t.closest(".start_divider"))||!a&&!o):!(ke(t)||i||n||l)}(e,t):function(e,t){if(xe(e))return function(e,t){return!(!t.classList.contains("start_divider")||null!==e.querySelector(".start_divider"))}(e,t);if(e.classList.contains("edit_field_type_break"))return!1;if(t.classList.contains("start_divider"))return function(e){return!e.classList.contains("edit_field_type_form")&&!e.querySelector(".edit_field_type_form")&&!(e.classList.contains("edit_field_type_divider")||e.querySelector(".edit_field_type_divider"))}(e);var r=e.classList.contains("edit_field_type_hidden"),n=e.classList.contains("edit_field_type_user_id");return!r&&!n&&function(e,t){if(ke(t))return!1;if(jQuery(e).children("ul.frm_sorting").not(".start_divider").length>0)return!1;var r=e.classList.contains("edit_field_type_divider")||e.querySelector(".edit_field_type_divider"),n=e.classList.contains("edit_field_type_form");return null===t.closest(".start_divider")||!r&&!n}(e,t)}(e,t)}function Ee(e){return e&&e.matches("#frm-show-fields > li:last-child")}function xe(e){return e.classList.contains("frm_field_box")&&!e.classList.contains("form-field")}function ke(e){return null!==e.querySelector(".edit_field_type_break, .edit_field_type_hidden, .edit_field_type_user_id")}function Le(e){var t=document.getElementById(e),r=jQuery(t),n=[],i=function(e){var t=e.querySelector(".frm_hidden_fdata");e.classList.add("frm_load_now"),null!==t&&n.push(t.innerHTML)},o=t;i(o);for(var a=Se(o);a&&n.length<15;)i(a),o=a,a=Se(a);jQuery.ajax({type:"POST",url:ajaxurl,data:{action:"frm_load_field",field:n,form_id:k,nonce:frmGlobal.nonce},success:function(e){return function(e,t,r){var n,i;if(0===(e=e.replace(/^\s+|\s+$/g,"")).indexOf("{")){for(n in e=JSON.parse(e))jQuery("#frm_field_id_"+n).replaceWith(e[n]),V("#frm_field_id_"+n+".edit_field_type_divider ul.frm_sorting"),X(document.getElementById("frm_field_id_"+n));((i=t.nextAll(".frm_field_loading:not(.frm_load_now)")).length||(i=jQuery(document.getElementById("frm-show-fields")).find(".frm_field_loading:not(.frm_load_now)")).length)&&Le(i.attr("id")),no(),Or(),Be();var o=new Event("frm_ajax_loaded_field",{bubbles:!1});o.frmFields=r.map((function(e){return JSON.parse(e)})),document.dispatchEvent(o)}else jQuery(".frm_load_now").removeClass(".frm_load_now").html("Error")}(e,r,n)}})}function Se(e){var t;return e.nextElementSibling?e.nextElementSibling:null===(t=e.parentNode)||void 0===t||null===(t=t.closest(".frm_field_box"))||void 0===t||null===(t=t.nextElementSibling)||void 0===t?void 0:t.querySelector(".form-field")}function Ae(){var e=jQuery(this);if(e.hasClass("disabled"))return!1;var t=e.closest(".frmbutton").attr("id");if(!ge(t)){var r=0;"summary"===t&&(r=j.children('li[data-type="break"]').length>0?1:0);var n=k;return jQuery.ajax({type:"POST",url:ajaxurl,data:pe(t,0,n,r),success:function(e){Ie(e);var r=he(e);r&&wp.hooks.doAction("frm_after_field_added_in_form_builder",{field:e,fieldId:r,fieldType:t,form_id:n})},error:je}),!1}}function Ie(e){document.getElementById("frm_form_editor_container").classList.add("frm-has-fields");var t=$e(e),r=j[0].querySelector(".edit_field_type_submit");r?jQuery(r.closest(".frm_field_box:not(.form-field)")).before(t):j.append(t),Ue(e,!0),t.each((function(){K(this.querySelector("ul.frm_sorting")),X(this.querySelector(".form-field"),".frm-move")}))}function Be(){var e=!0,t=document.querySelectorAll(".frmjs_prod_field_opt_cont");j.find("li.edit_field_type_product").length>1&&(e=!1);for(var r=0;r',i.appendChild(document.createTextNode(" ")),i.appendChild(o),n.appendChild(i),e.appendChild(n)}))}(t,!0===e),(r=jQuery(t)).offset().left>jQuery(window).width()-r.outerWidth()&&(t.style.left=-r.outerWidth()+"px");var n=t.firstElementChild.querySelector("a");n&&n.focus()}}),0)}function ze(){He(!0)}function Pe(e){var t=e.target.closest(".frm-section-collapsed");t&&("show"===e.type?t.style.zIndex=3:t.style.zIndex=1)}function Re(e){var t={class:"frm_delete",icon:"frm_delete_icon"};return t.label=B(e?"Delete Group":"Delete","formidable"),t}function Ge(e){var t={class:"frm_clone",icon:"frm_clone_icon"};return t.label=B(e?"Duplicate Group":"Duplicate","formidable"),t}function $e(e){var t=d();"string"==typeof e?t.innerHTML=e:t.appendChild(e);var r=jQuery();return Array.from(t.children).forEach((function(e){r=r.add(jQuery("
        • ").addClass("frm_field_box").html(jQuery("
            ").addClass("frm_grid_container frm_sorting").append(e)))})),r}function We(e){var t=s("ul",{className:"frm_grid_container frm_sorting"}),r=s("li",{className:"frm_field_box",child:t});e.replaceWith(r),t.appendChild(e),K(t),X(r,".frm-move")}function Ue(e,t){var r,n,i=/id="(\S+)"/.exec(e),o=document.getElementById(i[1]),a="#"+i[1]+".edit_field_type_divider ul.frm_sorting.start_divider",l=jQuery(a),s=o.getAttribute("data-type");r=e,(n=d()).innerHTML=r,n.querySelectorAll(".form-field").forEach(Ve);var c,f,u=!1;if(Ni(),V(a),"quantity"===s&&function(e){var t=e.getAttribute("data-fid"),r=document.getElementById("field_options[product_field_"+t+"]");null!==r&&(rt(r),ei(document.getElementById("frm-single-settings-"+t)))}(o),"product"!==s&&"quantity"!==s||Be(),l.length)l.parent(".frm_field_box").children(".frm_no_section_fields").addClass("frm_block");else{var m=jQuery(o).closest("ul.frm_sorting.start_divider");m.length&&(En(m),u=!0)}if(-1!==e.indexOf("frm-collapse-page")&&Or(),f="frm-newly-added",(c=o).classList?c.classList.add(f):c.className+=" "+f,setTimeout((function(){o.classList.remove("frm-newly-added")}),1e3),t){var _=o.getBoundingClientRect(),p=document.getElementById("post-body-content");_.top>=0&&_.left>=0&&_.right<=(window.innerWidth||document.documentElement.clientWidth)&&_.bottom<=(window.innerHeight||document.documentElement.clientHeight)||p.scroll({top:p.scrollHeight,left:0,behavior:"smooth"}),!1===u&&En(l)}Je(),no(),document.getElementById("frm-show-fields").classList.remove("frm-over-droppable");var g=new Event("frm_added_field",{bubbles:!1});g.frmField=o,g.frmSection=a,g.frmType=s,g.frmToggles=u,document.dispatchEvent(g)}function Ve(e){if(e.dataset.fid){var t=document.getElementById("draft_fields");t&&(""===t.value?t.value=e.dataset.fid:t.value.split(",").includes(e.dataset.fid)||(t.value+=","+e.dataset.fid))}}function Ke(e){jQuery("#new_fields .frm-single-settings").addClass("frm_hidden"),jQuery("#frm-options-panel > .frm-single-settings").removeClass("frm_hidden"),Je(e)}function Je(e){jQuery("li.ui-state-default.selected").removeClass("selected"),jQuery(".frm-show-field-settings.selected").removeClass("selected"),e||gr()}function Ye(){var e=this.value,t=function(e){var t,r=[],n=e.split(""),i=n.length,o=["{","[","("],l={"}":"{",")":"(","]":"["},s=[];for(t=0;t0||s.length>0?a.unmatched_parens+"\n\n":""}(e);t+=function(e,t){var r=function(e,t){var r="";return function(e){return jQuery(e).siblings('label[for^="calc_type"]').children("input").prop("checked")}(t)||/\[(date|time|email|ip)\]/.test(e)&&(r=a.text_shortcodes+"\n\n"),r}(e,t);return r+=function(e){var t="";return/\[id\]|\[key\]|\[if\s\w+\]|\[foreach\s\w+\]|\[created-at(\s*)?/g.test(e)&&(t+=a.view_shortcodes+"\n\n"),t}(e)}(e,this),""!==t&&H(e+"\n\n"+t)}function Xe(e,t){for(var r,n,i,o=!1,a=0;a"+l[t].fieldName+"")):(r=r?" checked":"",i.push('"));e.innerHTML=i.join("")}function nt(){for(var e=document.querySelectorAll(".frmjs_prod_field_opt"),t=0;t'):(n.innerHTML=un(r),"TEXTAREA"===n.nodeName&&n.classList.contains("wp-editor-area")&&jQuery(n).trigger("change"),n.classList.contains("frm_primary_label")&&"break"===n.nextElementSibling.getAttribute("data-ftype")&&(n.nextElementSibling.querySelector(".frm_button_submit").textContent=r)))}function at(e){var t=parseFloat(e.getAttribute("max")),r=parseFloat(e.getAttribute("min"));return(t-r)/2+r}function lt(){var e,t=this.getAttribute("data-fid"),r="";["field_options_max_","frm_format_"].forEach((function(e){var n=document.getElementById(e+t);n&&(r+=n.value)})),"text"===(e=document.getElementsByName("field_options[type_"+t+"]")[0]).options[e.selectedIndex].value&&dt(""!==r,".frm_invalid_msg"+t)}function st(){var e=this.id.replace("frm_","").replace("req_field_",""),t=this.checked,r=jQuery("#field_label_"+e+" .frm_required");if(dt(t,".frm_required_details"+e),t){var n=jQuery('input[name="field_options[required_indicator_'+e+']"]');""===n.val()&&n.val("*"),r.removeClass("frm_hidden")}else r.addClass("frm_hidden")}function dt(e,t){$msg=jQuery(t),e?$msg.fadeIn("fast").closest(".frm_validation_msg").fadeIn("fast"):0===$msg.fadeOut("fast").closest(".frm_validation_box").children(":not("+t+"):visible").length&&$msg.closest(".frm_validation_msg").fadeOut("fast")}function ct(){var e=jQuery(this).closest(".frm-single-settings").data("fid"),t=jQuery(".frm_unique_details"+e);this.checked?(t.fadeIn("fast").closest(".frm_validation_msg").fadeIn("fast"),$unqDetail=jQuery(".frm_unique_details"+e+" input"),""===$unqDetail.val()&&$unqDetail.val(a.default_unique)):0===t.fadeOut("fast").closest(".frm_validation_box").children(":not(.frm_unique_details"+e+"):visible").length&&t.closest(".frm_validation_msg").fadeOut("fast")}function ft(){var e=jQuery(this).closest(".frm-single-settings").data("fid"),t=jQuery(this).val(),r=jQuery(document.getElementById("frm_field_id_"+e));if(dt(""!==t,".frm_conf_details"+e),""!==t){var n=jQuery(".frm_validation_box .frm_conf_details"+e+" input");""===n.val()&&n.val(a.default_conf),function(e){var t=document.getElementsByName("field_options[type_"+e+"]")[0].value;ut(document.getElementById("field_description_"+e),"field_options[description_"+e+"]",a["enter_"+t]),ut(document.getElementById("conf_field_description_"+e),"field_options[conf_desc_"+e+"]",a["confirm_"+t])}(e),"inline"===t?r.removeClass("frm_conf_below").addClass("frm_conf_inline"):"below"===t&&r.removeClass("frm_conf_inline").addClass("frm_conf_below"),jQuery(".frm-conf-box-"+e).removeClass("frm_hidden")}else jQuery(".frm-conf-box-"+e).addClass("frm_hidden"),setTimeout((function(){r.removeClass("frm_conf_inline frm_conf_below")}),200)}function ut(e,t,r){e.innerHTML===a.desc&&(e.innerHTML=r,document.getElementsByName(t)[0].value=r)}function mt(e){var t=JSON.parse(this.getAttribute("data-opts"));return e.preventDefault(),document.getElementById("frm_bulk_options").value=t.join("\n"),!1}function _t(){var e=jQuery(this).closest(".frm-single-settings").data("fid"),t=jQuery("#frm_field_"+e+"_opts .frm_option_template").prop("outerHTML"),r=jQuery(this).data("opttype"),n=0,i=function(e){for(var t=0,r=0,n=jQuery("#frm_field_"+e+"_opts li"),i=0;ti||"000"===i)&&(i=r)}return i}(e);if("000"!==i&&(n=i+1),"other"===r){document.getElementById("other_input_"+e).value=1;var o=jQuery(this).data("ftype");"radio"!==o&&"select"!==o||jQuery(this).fadeOut("slow");var a={action:"frm_add_field_option",field_id:e,opt_key:n,opt_type:r,nonce:frmGlobal.nonce};jQuery.post(ajaxurl,a,(function(t){jQuery(document.getElementById("frm_field_"+e+"_opts")).append(t),tn(e)}))}else t=(t=(t=(t=(t=t.replace(new RegExp('optkey="000"',"g"),'optkey="'+n+'"')).replace(new RegExp("-000_","g"),"-"+n+"_")).replace(new RegExp('-000"',"g"),"-"+n+'"')).replace(new RegExp("\\[000\\]","g"),"["+n+"]")).replace("frm_hidden frm_option_template",""),Mo(e,t={newOption:t}),jQuery(document.getElementById("frm_field_"+e+"_opts")).append(t.newOption),tn(e);Ni()}function pt(){gt(jQuery(this).closest(".frm-single-settings").data("fid"),this.value)}function gt(e,t){var r=jQuery(".frm_multiple_cont_"+e);"select"===t?r.fadeIn("fast"):r.fadeOut("fast")}function yt(){var e=jQuery(this).closest(".frm-single-settings").data("fid");Co(jQuery(".field_"+e+"_option_key")),jQuery(".field_"+e+"_option").toggleClass("frm_with_key")}function ht(){var e,t=jQuery(this).closest(".frm-single-settings"),r=t.data("fid"),n=document.getElementById("frm_field_id_"+r);wt(jQuery(this)),Co(jQuery(".field_"+r+"_image_id")),Co(jQuery(".frm_toggle_image_options_"+r)),Co(jQuery(".frm_image_size_"+r)),Co(jQuery(".frm_alignment_"+r)),Co(jQuery(".frm-add-other#frm_add_field_"+r)),pn(r)?(bt(r,"inline"),vt(n),e=en(r),n.classList.add("frm_image_options"),n.classList.add("frm_image_size_"+e),t.find(".frm-bulk-edit-link").hide()):(n.classList.remove("frm_image_options"),vt(n),bt(r,"block"),t.find(".frm-bulk-edit-link").show())}function vt(e){e.classList.remove("frm_image_size_","frm_image_size_small","frm_image_size_medium","frm_image_size_large","frm_image_size_xlarge")}function bt(e,t){jQuery("#field_options_align_"+e).val(t).trigger("change")}function jt(){var e=jQuery(this).closest(".frm-single-settings").data("fid"),t=document.getElementById("frm_field_id_"+e);Qt(),pn(e)&&(vt(t),t.classList.add("frm_image_options"),t.classList.add("frm_image_size_"+en(e)))}function wt(e){var t=e.closest(".frm-single-settings").data("fid");jQuery(".field_"+t+"_option").trigger("change")}function Qt(){wt(jQuery(this))}function Et(e){var t=e.target.closest(".frm_image_preview_wrapper");e.preventDefault(),wp.media.model.settings.post.id=0;var r=wp.media.frames.file_frame=wp.media({multiple:!1,library:{type:["image"]}});r.on("select",(function(){var e=r.state().get("selection").first().toJSON(),n=t.querySelector("img");n.setAttribute("src",e.url),n.classList.remove("frm_hidden"),n.removeAttribute("srcset"),t.querySelector(".frm_image_preview_frame").style.display="block",t.querySelector(".frm_image_preview_title").textContent=e.filename,t.querySelector(".frm_choose_image_box").style.display="none";var i=jQuery(t);i.siblings('input[name*="[label]"]').data("frmimgurl",e.url),i.find("input.frm_image_id").val(e.id).trigger("change"),wp.media.model.settings.post.id=0})),r.open()}function xt(e){var t=jQuery(this).closest(".frm_image_preview_wrapper");e.preventDefault(),e.stopPropagation(),t.find("img").attr("src",""),t.find(".frm_image_preview_frame").hide(),t.find(".frm_choose_image_box").show(),t.find("input.frm_image_id").val(0).trigger("change")}function kt(){var e=jQuery(this).closest("li").find(".frm_form_fields select");this.checked?e.attr("multiple","multiple"):e.removeAttr("multiple")}function Lt(){var e=document.getElementById("dropform-search-input");null!==e&&setTimeout((function(){e.focus()}),100)}function St(e){var t=e.target,r=t.closest(".frm_warning_style");jQuery(r).fadeOut(400,(function(){return r.remove()}));var n=t.dataset.action,i=new FormData;g(n,i)}function At(e){e.preventDefault()}function It(){var e,t=this.parentNode,r=t.parentNode,n=this.getAttribute("data-fid");jQuery(t).fadeOut("slow",(function(){wp.hooks.doAction("frm_before_delete_field_option",this),jQuery(t).remove(),jQuery(r).find(".frm_other_option").length<1&&(null!==(e=document.getElementById("other_input_"+n))&&(e.value=0),jQuery("#other_button_"+n).fadeIn("slow"))})),Ni()}function Bt(){var e,t,r,n;(e=jQuery(this)).is(":checked")&&(t=function(){setTimeout((function(){e.prop("checked",!1)}),0)},r=function(){e.off("mouseup",n)},n=function(){t(),r()},e.on("mouseup",n),e.one("mouseout",r))}function Ct(){this.value===a.new_option&&(this.setAttribute("data-value-on-focus",this.value),this.value="")}function qt(e){return C(B("Are you sure you want to delete these %1$s selected field(s)?","formidable"),e)}function Nt(){var e=a.conf_delete,t=this.parentNode.parentNode.parentNode.parentNode.parentNode,r=t.parentNode,n=jQuery(this).closest("li.form-field"),i=n.data("fid");if("divider"===n.data("ftype")){var o=document.querySelectorAll(".frm-field-group-hover-target .start_divider .frm_field_box"),l=0;o.forEach((function(e){var t=e.querySelectorAll("li.form-field");t&&(l+=t.length)})),l&&(e=qt(++l))}return r.classList.contains("frm-section-collapsed")||r.classList.contains("frm-page-collapsed")||("divider_section_only"===t.className&&(e=a.conf_delete_sec),this.setAttribute("data-frmverify",e),this.setAttribute("data-frmverify-btn","frm-button-red"),this.setAttribute("data-deletefield",i),Oe(),F(this)),!1}function Ot(){this.closest("li.form-field").click()}function Tt(){var e,t;null!==(e=document.querySelector(".frm-field-group-hover-target"))&&(e.classList.add("frm-selected-field-group"),(t=document.createElement("div")).classList.add("frm-delete-field-groups","frm_hidden"),document.body.appendChild(t),t.click())}function Dt(){var e=document.querySelector(".frm-field-group-hover-target");if(null!==e){var t="frm_field_group_"+we(),r=document.createTextNode("");We(r);var n=jQuery(r).closest("li").get(0);n.classList.add("frm_hidden");var i=n.querySelector("ul");i.id=t,jQuery(e.closest("li.frm_field_box")).after(n);var o=ae(jQuery(e)),a=[],l=[],s=o.length,d={},c=0;jQuery(n).on("frm_added_duplicated_field_to_row",(function(e,t){if(d[jQuery(t.duplicatedFieldHtml).attr("data-fid")]=t.originalFieldId,!(s>++c)){var r=jQuery(i),o=ae(r);l.forEach((function(e){e.remove()}));for(var f=0;f0&&ir(Ut(t)))&&l>=12&&(l=Math.floor(12/t)),s=0;s',""),t);e.prepend(r),document.getElementById("frm-field-group-message-dismiss").addEventListener("click",(function(){mr(document.getElementById("frm-field-group-message"))}))}}(),"ul"===e.originalEvent.target.nodeName.toLowerCase()){var t=document.querySelector(".frm-field-group-hover-target");if(t){var r=e.ctrlKey||e.metaKey,n=e.shiftKey,i=t.classList.contains("frm-selected-field-group"),o=function(){var e=jQuery(".frm-selected-field-group");if(e.length)return e;var t=_r();if(t){var r=t.closest("ul");if(r&&1===ae(jQuery(r)).length)return r.classList.add("frm-selected-field-group"),jQuery(r)}return jQuery()}(),a=o.length;if(r||n){var l=_r();if(null===l||jQuery(l).siblings("li.form-field").length||(l.parentNode.classList.add("frm-selected-field-group"),++a),r){if(i)return--a,t.classList.remove("frm-selected-field-group"),void pr(a);++a}else if(n&&!i){++a;var s=o.first();(s.parent().index()=2||1===e&&ae(jQuery(document.querySelector(".frm-selected-field-group"))).length>1?function(){var e,t,r,n,i;if(null!==(e=document.getElementById("frm_field_multiselect_popup")))return e.classList.toggle("frm-unmergable",!hr()),e;(e=d()).id="frm_field_multiselect_popup",hr()||e.classList.add("frm-unmergable"),(t=d()).classList.add("frm-merge-fields-into-row"),t.textContent=B("Merge into row","formidable"),(r=document.createElement("a")).style.marginLeft="5px",r.classList.add("frm_icon_font","frm_arrowdown6_icon"),r.setAttribute("href","#"),t.appendChild(r),e.appendChild(t),(n=d()).classList.add("frm-multiselect-popup-separator"),e.appendChild(n),(i=d()).classList.add("frm-delete-field-groups"),i.appendChild(Rt("frm_trash_svg")),e.appendChild(i),document.getElementById("post-body-content").appendChild(e),jQuery(e).hide().fadeIn()}():yr(),Me()}function gr(e){if(void 0!==e){if(null!==e.originalEvent.target.closest("#frm-show-fields"))return;if(e.originalEvent.target.classList.contains("frm-merge-fields-into-row"))return;if(null!==e.originalEvent.target.closest(".frm-merge-fields-into-row"))return;if(e.originalEvent.target.classList.contains("frm-custom-field-group-layout"))return;if(e.originalEvent.target.classList.contains("frm-cancel-custom-field-group-layout"))return}jQuery(".frm-selected-field-group").removeClass("frm-selected-field-group"),jQuery(document).off("click",gr),yr()}function yr(){var e=document.getElementById("frm_field_multiselect_popup");null!==e&&e.remove()}function hr(){var e,t,r,n,i;if(1===(r=(e=document.querySelectorAll(".frm-selected-field-group")).length))return!1;for(t=0,n=0;n6)return!1}return!0}function vr(e){var t;null===e.originalEvent.target.closest("#frm_field_group_popup")&&(e.originalEvent.target.classList.contains("frm-custom-field-group-layout")||(t=zt(br(),document.querySelector(".frm-selected-field-group").firstChild),this.appendChild(t)))}function br(){var e=0;return jQuery(document.querySelectorAll(".frm-selected-field-group")).each((function(){e+=ae(jQuery(this)).length})),e}function jr(){var e,t,r,n;n=[],jQuery(".frm-selected-field-group > li.form-field").each((function(){n.push(this.dataset.fid)})),t=function(e){return function(t){t.preventDefault(),function(e){e.forEach((function(e){Qr(e)}))}(e)}}(e=n),null!==(r=document.getElementById("frm_field_multiselect_popup"))&&r.remove(),this.setAttribute("data-frmverify",qt(e.length)),F(this);var i=document.getElementById("frm-confirmed-click");null==i||i.removeAttribute("data-deletefield"),jQuery(i).on("click",t),jQuery("#frm_confirm_modal").one("dialogclose",(function(){jQuery(i).off("click",t)}))}function wr(){Qr(this.getAttribute("data-deletefield"))}function Qr(e){var t=jQuery("#frm_field_id_"+e);Er(e),t.hasClass("edit_field_type_divider")&&t.find("li.frm_field_box").each((function(){Er(this.getAttribute("data-fid"))})),Qn()}function Er(e){jQuery.ajax({type:"POST",url:ajaxurl,data:{action:"frm_delete_field",field_id:e,nonce:frmGlobal.nonce},success:function(){var t=jQuery(document.getElementById("frm_field_id_"+e)),r=jQuery("#frm-single-settings-"+e);r.is(":visible")&&document.getElementById("frm_insert_fields_tab").click(),function(e){var t=e[0].querySelectorAll(".frm-inline-modal[data-fills]");t.length&&t.forEach((function(e){e.classList.add("frm_hidden"),e.removeAttribute("data-fills"),e.closest("form").appendChild(e)}))}(r),r.remove(),t.fadeOut("slow",(function(){var e,r=t.closest(".start_divider"),n=t.data("type"),i=t.siblings("li.form-field");if(i.length||(t.is(".edit_field_type_end_divider")?i.length=t.closest("li.form-field").siblings():e=t.closest("ul.frm_sorting").parent()),t.remove(),"break"===n?Or():"product"===n&&(Be(),nt()),i.length?le(i.first()):e.remove(),0===jQuery("#frm-show-fields li").length||function(){if(j.get(0).childElementCount>1)return!1;var e=j.get(0).firstElementChild.firstElementChild.querySelectorAll("li.frm_field_box");return!(e.length>1)&&e[0].classList.contains("edit_field_type_submit")}()){var o=document.getElementById("frm_form_editor_container");o.classList.remove("frm-has-fields"),o.classList.add("frm-empty-fields")}else r.length&&En(r);R()})),t.length&&wp.hooks.doAction("frm_after_delete_field",t[0])}})}function xr(){var e=jQuery(this).closest(".frm-single-settings").data("fid"),t=k,r=document.getElementById("frm_logic_row_"+e).querySelectorAll(".frm_logic_row");return jQuery.ajax({type:"POST",url:ajaxurl,data:{action:"frm_add_logic_row",form_id:t,field_id:e,nonce:frmGlobal.nonce,meta_name:kr(r,"frm_logic_"+e+"_"),fields:tt()},success:function(t){jQuery(document.getElementById("logic_"+e)).fadeOut("slow",(function(){var r=jQuery(document.getElementById("frm_logic_row_"+e));r.append(t),r.closest(".frm_logic_rows").fadeIn("slow")}))}}),!1}function kr(e,t,r){return e.length?parseInt(e[e.length-1].id.replace(t,""),10)+1:void 0!==r?r:0}function Lr(){var e=jQuery(this).closest(".frm-single-settings").data("fid"),t=k,r=document.getElementById("frm_watch_lookup_block_"+e).children;return jQuery.ajax({type:"POST",url:ajaxurl,data:{action:"frm_add_watch_lookup_row",form_id:t,field_id:e,row_key:kr(r,"frm_watch_lookup_"+e+"_"),nonce:frmGlobal.nonce},success:function(t){var r=jQuery(document.getElementById("frm_watch_lookup_block_"+e));r.append(t),r.fadeIn("slow")}}),!1}function Sr(e){var t,r,n=jQuery(e).closest(".frm-single-settings").attr("data-fid"),i=jQuery(e).closest("ul").get(0).querySelectorAll(".field_"+n+"_option");for(t in i)if((r=i[t]).id!==e.id&&r.value===e.value&&"true"!==r.getAttribute("data-duplicate"))return!0;return!1}function Ar(){var e,t;null===this.getAttribute("data-value-on-load")&&(this.setAttribute("data-value-on-load",this.value),t=jQuery(this).closest(".frm-single-settings").attr("data-fid"),(e=document.createElement("input")).value=this.value,e.setAttribute("type","hidden"),e.setAttribute("name","optionmap["+t+"]["+this.value+"]"),this.parentNode.appendChild(e),void 0===S[t]&&(S[t]={}),S[t][this.value]=e),"true"===this.getAttribute("data-duplicate")&&(this.removeAttribute("data-duplicate"),Sr(this))?this.setAttribute("data-value-on-focus",this.getAttribute("data-value-on-load")):""===this.value&&a.new_option===this.getAttribute("data-value-on-focus")||this.setAttribute("data-value-on-focus",this.value)}function Ir(e){var t,r=e.closest(".frm_single_option");return e.parentElement.classList.contains("frm_single_option")?{newValue:r.querySelector('.frm_option_key input[type="text"]').value,newLabel:t=e.value}:(t=r.querySelector('input[type="text"]').value,{newValue:e.value,newLabel:t})}function Br(){var e,t,r,n,i,o,a,l,s,d,c,f,u=function(e){var t=function(e){var t,r,n=null!==(t=null===(r=e.closest(".frm-single-settings").querySelector(".frm_toggle_sep_values"))||void 0===r?void 0:r.checked)&&void 0!==t&&t,i=e.closest(".frm_single_option");return n&&e.parentElement.classList.contains("frm_single_option")?{oldValue:i.querySelector('.frm_option_key input[type="text"]').getAttribute("data-value-on-focus"),oldLabel:e.getAttribute("data-value-on-focus")}:{oldValue:e.getAttribute("data-value-on-focus"),oldLabel:i.querySelector('input[type="text"]').getAttribute("data-value-on-focus")}}(e),r=t.oldValue,n=t.oldLabel,i=Ir(e);return{oldValue:r,oldLabel:n,newValue:i.newValue,newLabel:i.newLabel}}(this),m=u.oldValue,_=u.oldLabel,p=u.newValue,g=u.newLabel;if(m!==p||_!==g){var y=this.closest(".frm-single-settings");if(t=y.getAttribute("data-fid"),e=this.getAttribute("data-value-on-load"),Sr(this))return this.setAttribute("data-duplicate","true"),void(void 0!==S[t]&&void 0!==S[t][e]&&(S[t][e].value=e));for(void 0!==S[t]&&void 0!==S[t][e]&&(S[t][e].value=p),s=[],rows=D.querySelectorAll(".frm_logic_row"),o=rows.length,a=0;a1)for(document.getElementById("frm-fake-page").style.display="block",e=0;e200)&&(H(a.repeat_limit_min),this.value="")}function Kr(){var e=this.value;""!==e&&(e<1||e>200)&&(H(a.checkbox_limit),this.value="")}function Jr(e,t){jQuery(e).closest(".frm_field_box").find(".frm_"+t+"_form_row .frm_repeat_label").text(e.value)}function Yr(){var e=jQuery(this).closest(".frm-single-settings").data("fid"),t=this.value,r=document.getElementById("frm_show_selected_fields_"+e),n=document.getElementById("frm_show_selected_forms_"+e);jQuery(n).find("select").val(""),"form"===t?(n.style.display="inline",function(e){if(null!==e)for(;e.firstChild;)e.removeChild(e.firstChild)}(r)):(r.style.display="none",n.style.display="none",jn(t,e))}function Xr(){var e,t;(e=Zr(this))&&(t=jQuery(this).closest(".frm_single_option"),function(e,t,r){var n,i,o,a,l,s,c=r.data("optkey"),f=_n(e),u=jQuery('label[for="field_'+t+"-"+c+'"]'),m="field_options[options_"+e+"]["+c+"]",_=jQuery('input[name="'+m+'[label]"]');if(u.length<1)return tn(e),void((o=r.find('input[name^="default_value_"]')).is(":checked")&&_.length>0&&jQuery('select[name^="item_meta['+e+']"]').val(_.val()));if(a=u.children("input"),n=_.length<1?(_=jQuery('input[name="'+m+'"]')).val():f?jQuery('input[name="'+m+'[value]"]').val():_.val(),!(_.length<1)){if(i=u[0].childNodes,pn(e))l=function(e,t,r){var n,i,o;return(n=e.find("img"))&&(i=n.attr("src")),o=gn(t),cn(t),mn(r.val(),o,i)}(r,e,_),(s=u.find(".frm_image_option_container")).length>0?s.replaceWith(l):(i[i.length-1].nodeValue="",u.append(l));else{var p=!1;i.forEach((function(t,r){if(!1===p)"INPUT"===t.tagName&&(p=r);else if(r===p+1){var n="";!function(e){var t=document.getElementsByName("field_options[image_options_"+e+"]"),r=Array.from(t).find((function(e){return e.checked&&"buttons"===e.value}));return void 0!==r}(e)?t.nodeValue=" "+_.val():(n=d({className:"frm_label_button_container",text:" "+_.val()}),u[0].replaceChild(n,t))}else u[0].removeChild(t)}))}a.val(n),o=r.find('input[name^="default_value_"]'),a.prop("checked",!!o.is(":checked"))}}(e.fieldId,e.fieldKey,t))}function Zr(e){var t;return!!(t=jQuery(e).closest(".frm_sortable_field_opts")).length&&{fieldId:t.attr("id").replace("frm_field_","").replace("_opts",""),fieldKey:t.data("key")}}function en(e){var t,r=document.getElementById("field_options_image_size_"+e),n="";return null!==r&&""!==(t=r.value)&&(n=t),n}function tn(e){var t,r,n,i,o,a=jQuery('[name^="item_meta['+e+']"]');if(!(a.length<1)){if(a.is("select"))null!==(i=document.getElementById("frm_placeholder_"+e))&&""===i.value?ln(a[0],{sourceID:e}):ln(a[0],{sourceID:e,placeholder:i.value});else{r=dn(e),jQuery("#field_"+e+"_inner_container > .frm_form_fields").html(""),o=Zr(jQuery("#frm_delete_field_"+e+"-000_container"));var l=jQuery("#field_"+e+"_inner_container > .frm_form_fields"),s=pn(e),d=s?en(e):"",c=s?"frm_image_option frm_image_"+d+" ":"",f=To(e);for(n="hidden"===a.attr("type")?a.data("field-type"):a.attr("type"),t=0;t=0;a--){var u;l=d[a];var m=null===(u=document.getElementById("frm_field_"+e+"_opts").querySelector('.frm_option_key input[type="text"]'))||void 0===u?void 0:u.value;m||(m=l),s=i.querySelector('option[value="'+m+'"]');var _=rn(e,l),p=_.newValue,g=_.newLabel,y=document.querySelectorAll("#frm_field_"+e+"_opts input[data-value-on-focus]"),h=Array.from(y).find((function(e){return e.value===l}));if(h){var v=h.dataset.valueOnFocus;if(v&&i.querySelector('option[value="'+v+'"]'))continue}on(i,s,p,g)}null!==(s=i.querySelector('option[value=""]'))&&i.prepend(s)}}function on(e,t,r,n){null!==t||e.querySelector('option[value="'+r+'"]')||((t=frmDom.tag("option",{text:n})).value=r),e.prepend(t)}function an(e,t,r,n,i,o){var a,l="",s=-1!==t.key.indexOf("other"),d="field_"+n+"-"+t.key,c="scale"===e?"radio":e;return a='',this.getSingle=function(){return""!==(l=wp.hooks.applyFilters("frm_admin.build_single_option_template",l,{opt:t,type:e,fieldId:r,classes:o,id:d}))?l:'
            "+(s?a:"")+"
            "},this.getSingle()}function ln(e,t){if(null!==e){var r=t.sourceID,n=t.placeholder,i=To(r),o=t.other;!function(e){var t;if(void 0!==e.options)for(t=e.options.length-1;t>=0;t--)e.remove(t)}(e);for(var a=dn(r),l=void 0!==n,s=0;s0||d[t].name.indexOf("[value]")>0||d[t].name.indexOf("[image]")>0||d[t].name.indexOf("[price]")>0||(i=r=d[t].value,o=d[t].name.replace("field_options[options_"+e+"][","").replace("[label]","").replace("]",""),m&&(n=d[t].name.replace("[label]","[value]"),r=jQuery('input[name="'+n+'"]').val()),u&&(i=mn(i,f,fn(d[t]),cn(e))),a={saved:r,label:i=frmAdminBuild.hooks.applyFilters("frm_choice_field_label",i,e,d[t],u),checked:(l=d[t].id,field=jQuery("#"+l),0!==field.length&&(checkbox=field.siblings("input[type=checkbox]"),checkbox.length&&checkbox.prop("checked"))),key:o},c&&(n=d[t].name.replace("[label]","[price]"),a.price=jQuery('input[name="'+n+'"]').val()),s.push(a));return s}function cn(e){var t=document.getElementById("frm-single-settings-"+e);return null===t?"radio":t.classList.contains("frm-type-checkbox")?"checkbox":"radio"}function fn(e){var t,r=jQuery(e).siblings(".frm_image_preview_wrapper");return r.length&&(t=r.find("img")).length?t.attr("src"):""}function un(e){(e instanceof Element||e instanceof Document)&&(e=e.outerHTML);var t=jQuery.parseHTML(e).reduce((function(e,t){var r=frmDom.cleanNode(t);return"#text"===r.nodeName?e+r.textContent:e+r.outerHTML}),"");return t!==e?un(t):t}function mn(e,t,r,n){var i,o,l,c=e;return c=un(c),r?o=m({src:r,alt:c}):(o=d({className:"frm_empty_url"})).innerHTML=a.image_placeholder_icon,i=t?" frm_label_with_image":"",(l=s("span",{className:"frm_text_label_for_image_inner"})).innerHTML=c,s("span",{className:"frm_image_option_container"+i,children:[o,s("span",{className:"frm_text_label_for_image",child:l})]})}function _n(e){return yn("separate_value_"+e)}function pn(e){for(var t=!1,r=document.getElementsByName("field_options[image_options_"+e+"]"),n=0;n=0&&(r.splice(t,1),e.val(r),e.next(".btn-group").find('.multiselect-container input[value=""]').prop("checked",!1))}(jQuery(this))}function Sn(e){e.val(""),e.next(".btn-group").find('.multiselect-container input[value!=""]').prop("checked",!1)}function An(e){e.preventDefault(),In(this)}function In(e,t){var r=document.getElementById(e.getAttribute("data-open")),n=jQuery(e).closest("p"),i=void 0!==t;n.hasClass("frm-open")?(n.removeClass("frm-open"),r.classList.add("frm_hidden")):(i||(t=Hi(e)),null!==t&&(i||t.focus(),n.after(r),r.setAttribute("data-fills",t.id),0===r.id.indexOf("frm-calc-box")&&Ze(r,!0)),n.addClass("frm-open"),r.classList.remove("frm_hidden"),wp.hooks.doAction("frm_show_inline_modal",r,e))}function Bn(e){e.preventDefault(),this.parentNode.classList.add("frm_hidden"),jQuery('.frm-open [data-open="'+this.parentNode.id+'"]').closest(".frm-open").removeClass("frm-open")}function Cn(){var e,t,r,n,i,o,a,l=this.getAttribute("data-frmchange").split(",");for(e=0;e',r)),o.innerHTML=c,e.dataset.upsellImage&&o.appendChild(m({src:e.dataset.upsellImage,alt:e.dataset.upgrade})),a.href=function(e,t){var r=e.getAttribute("data-link");return null!=r&&""!==r||(r=t.getAttribute("data-default")),r}(e,a),s.style.display="none",i.style.display=_,l.style.display="block"===_?"inline-block":_,o.style.display=u,a.style.display="block"===f?"inline-block":f}function Un(e){void 0===e&&(e=""),function(e){var t,r=jQuery(e+" :not(.frm_has_shortcodes) .frm_not_email_message, "+e+" :not(.frm_has_shortcodes) .frm_not_email_to, "+e+" :not(.frm_has_shortcodes) .frm_not_email_subject");for(t=0;t').before('')}function Vn(){var e="success";"options[edit_action]"===this.name&&(e="edit");var t=jQuery(this).val();jQuery("."+e+"_action_box").hide(),"redirect"===t?jQuery("."+e+"_action_redirect_box."+e+"_action_box").fadeIn("slow"):"page"===t?jQuery("."+e+"_action_page_box."+e+"_action_box").fadeIn("slow"):jQuery("."+e+"_action_message_box."+e+"_action_box").fadeIn("slow")}function Kn(e){if(m=e.target,p=jQuery(m),g=p.closest(".frm_form_action_settings"),(y=g.find(".widget-inside")).find("p, div, table").length||((_=g.find(".widget-top")).on("frm-action-loaded",(function(){p.trigger("click"),g.removeClass("open"),y.hide()})),_.trigger("click"),0)){var t=e.target.closest(".frm_form_action_settings"),r=t.querySelectorAll(".wp-editor-area");r.length&&r.forEach((function(e){tinymce.EditorManager.execCommand("mceRemoveEditor",!0,e.id)}));var n=jQuery(t).clone(),i=n.attr("id").replace("frm_form_action_",""),o=Jn(i);n.find(".frm_action_id, .frm-btn-group").remove(),n.find('input[name$="['+i+'][ID]"]').val(""),n.find(".widget-inside").hide(),n.find("input[type=text], textarea, input[type=number]").prop("defaultValue",(function(){return this.value})),n.find("input[type=checkbox], input[type=radio]").prop("defaultChecked",(function(){return this.checked}));var a=new RegExp("\\["+i+"\\]","g"),l=new RegExp("_"+i+'"',"g"),s=new RegExp("-"+i+'"',"g"),c=new RegExp('"'+i+'"',"g"),f=n.html().replace(a,"["+o+"]").replace(l,"_"+o+'"');f=f.replace(s,"-"+o+'"').replace(c,'"'+o+'"');var u=d({id:"frm_form_action_"+o,className:n.get(0).className});u.setAttribute("data-actionkey",o),u.innerHTML=f,u.querySelectorAll(".wp-editor-wrap, .wp-editor-wrap *").forEach((function(e){"string"==typeof e.className&&(e.className=e.className.replace(i,o)),e.id=e.id.replace(i,o)})),u.classList.remove("open"),document.getElementById("frm_notification_settings").appendChild(u),r.length&&(r.forEach((function(e){frmDom.wysiwyg.init(e)})),u.querySelectorAll(".wp-editor-area").forEach((function(e){frmDom.wysiwyg.init(e)}))),u.classList.contains("frm_single_on_submit_settings")&&u.querySelector("input.frm-page-search")&&yo(u),no(),wp.hooks.doAction("frm_after_duplicate_action",u)}var m,_,p,g,y}function Jn(e){var t=parseInt(e,10)+11;return null!==document.getElementById("frm_form_action_"+t)&&(t=Jn(++t)),t}function Yn(){var e,t=jQuery(this).data("actiontype");if(!oi(t)){var r=(e=kr(document.querySelectorAll(".frm_form_action_settings"),"frm_form_action_"),void 0!==document.getElementById("frm_form_action_"+e)&&(e+=100),A>=e&&(e=A+1),A=e,e),n=k,i=document.createElement("div");i.classList.add("frm_single_"+t+"_settings");var o=document.getElementById("frm_notification_settings");o.appendChild(i),jQuery.ajax({type:"POST",url:ajaxurl,data:{action:"frm_add_form_action",type:t,list_id:r,form_id:n,nonce:frmGlobal.nonce},success:function(e){Ni(),i.remove(),document.querySelectorAll(".frm_form_action_settings.open").forEach((function(e){return e.classList.remove("open")}));var n=d();n.innerHTML=e;var a=n.querySelector(".widget-top");Array.from(n.children).forEach((function(e){return o.appendChild(e)})),jQuery(".frm_form_action_settings").fadeIn("slow");var l=document.getElementById("frm_form_action_"+r);l.classList.add("open"),document.getElementById("post-body-content").scroll({top:l.offsetTop+10,left:0,behavior:"smooth"}),ii(t),Un("#frm_form_action_"+r),no(),yo(l),a&&jQuery(a).trigger("frm-action-loaded"),frmAdminBuild.hooks.doAction("frm_added_form_action",l)}})}}function Xn(){var e=document.getElementById("frm_email_addon_menu").classList,t=document.getElementById("actions-search-input");e.contains("frm-all-actions")?(e.remove("frm-all-actions"),e.add("frm-limited-actions")):(e.add("frm-all-actions"),e.remove("frm-limited-actions")),t.value="",ko(t,"input")}function Zn(e){e.on("Change",(function(){!function(e){var t,r;(t=document.querySelector(".frm-single-settings:not(.frm_hidden)"))&&null!==(r=t.querySelector(".wp-editor-wrap"))&&r.classList.contains("tmce-active")&&!tinyMCE.activeEditor.isHidden()&&(e.targetElm.value=e.getContent(),jQuery(e.targetElm).trigger("change"))}(e)}))}function ei(e){var t=this;if(null!==e)return this.fragment=document.createDocumentFragment(),this.initOnceInAllInstances=function(){void 0===ei.prototype.endMarker&&(ei.prototype.endMarker=document.getElementById("frm-end-form-marker"))},this.append=function(e){var r=null!==e?e.parentElement.classList:"";null!==e&&(r.contains("frm_field_box")||r.contains("divider_section_only"))&&t.fragment.appendChild(e)},this.moveFields=function(){w.insertBefore(t.fragment,ei.prototype.endMarker)},this.initOnceInAllInstances(),void 0!==e?(this.append(e),void this.moveFields()):{append:this.append,moveFields:this.moveFields}}function ti(){var e=jQuery(this).closest(".frm_form_action_settings").data("actionkey"),t=this.getAttribute("data-emailrow");jQuery("#frm_form_action_"+e+" .frm_"+t+"_row").fadeIn("slow"),jQuery(this).fadeOut("slow")}function ri(){var e=jQuery(this).closest(".frm_form_action_settings"),t=this.getAttribute("data-emailrow"),r=".frm_"+t+"_row",n=".frm_"+t+"_button";jQuery(e).find(n).fadeIn("slow"),jQuery(e).find(r).fadeOut("slow",(function(){jQuery(e).find(r+" input").val("")}))}function ni(){var e=jQuery(this).closest(".frm_form_action_settings"),t=".frm_from_to_match_row";e.find('input[name$="[post_content][from]"]').val()===e.find('input[name$="[post_content][email_to]"]').val()?jQuery(e).find(t).fadeIn("slow"):jQuery(e).find(t).fadeOut("slow")}function ii(e){var t,r,n=document.querySelectorAll(".frm_"+e+"_action");oi(e)?(t=n,r=ai(e)>0,t.forEach((function(e){e.classList.remove("frm_active_action"),e.classList.add("frm_inactive_action"),r&&e.classList.add("frm_already_used")}))):n.forEach((function(e){e.querySelector(".frm_show_upgrade")||(e.classList.remove("frm_inactive_action","frm_already_used"),e.classList.add("frm_active_action"))}))}function oi(e){var t=function(e){return jQuery(".frm_single_"+e+"_settings").length}(e)>=ai(e),r={type:e};return wp.hooks.applyFilters("frm_action_at_limit",t,r)}function ai(e){return parseInt(jQuery(".frm_"+e+"_action").data("limit"),10)}function li(){var e=a.only_one_action,t=this.dataset.limit;void 0!==t&&((t=parseInt(t))>1?e=e.replace(1,t).trim():e+=" "+a.edit_action_text),H(e)}function si(){var e=jQuery(this).data("emailkey"),t=jQuery(this).closest(".frm_form_action_settings").find(".frm_action_name").val(),r=document.getElementById("form_id").value,n=document.getElementById("frm_logic_row_"+e),i=kr(n.querySelectorAll(".frm_logic_row"),"frm_logic_"+e+"_"),o=d({id:"frm_logic_"+e+"_"+i,className:"frm_logic_row frm_hidden"});return n.appendChild(o),jQuery.ajax({type:"POST",url:ajaxurl,data:{action:"frm_add_form_logic_row",email_id:e,form_id:r,meta_name:i,type:t,nonce:frmGlobal.nonce},success:function(t){jQuery(document.getElementById("logic_link_"+e)).fadeOut("slow",(function(){o.insertAdjacentHTML("beforebegin",t),o.remove(),jQuery(n).parent(".frm_logic_rows").fadeIn("slow")}))}}),!1}function di(){var e=jQuery("select.frm_single_post_field");e.css("border-color","");var t=this,r=jQuery(t).val();if(""===r||"checkbox"===r)return!1;e.each((function(){if(jQuery(this).val()===r&&this.name!==t.name)return this.style.borderColor="red",jQuery(t).val(""),H(a.field_already_used),!1}))}function ci(){var e=jQuery(this).val();""===e?(jQuery(".frm_post_content_opt, select.frm_dyncontent_opt").hide().val(""),jQuery(".frm_dyncontent_opt").hide()):"post_content"===e?(jQuery(".frm_post_content_opt").show(),jQuery(".frm_dyncontent_opt").hide(),jQuery("select.frm_dyncontent_opt").val("")):(jQuery(".frm_post_content_opt").hide().val(""),jQuery("select.frm_dyncontent_opt, .frm_form_field.frm_dyncontent_opt").show())}function fi(){var e=jQuery(this).val(),t=jQuery(document.getElementById("frm_dyncontent"));""===e||"new"===e?(t.val(""),jQuery(".frm_dyncontent_opt").show()):jQuery.ajax({type:"POST",url:ajaxurl,data:{action:"frm_display_get_content",id:e,nonce:frmGlobal.nonce},success:function(e){t.val(e),jQuery(".frm_dyncontent_opt").show()}})}function ui(){var e,t,r=document.getElementById("frm_posttax_rows").childNodes,n=document.querySelector(".frm_post_parent_field"),o=document.querySelector(".frm_post_menu_order_field"),a=this.value;jQuery.ajax({type:"POST",url:ajaxurl,data:{action:"frm_replace_posttax_options",post_type:a,nonce:frmGlobal.nonce},success:function(n){for(i=0;i');var e=jQuery(this).closest(".frm_form_action_settings").find('select[name$="[post_content][post_type]"]').val(),t=jQuery(this).closest(".frm_form_action_settings").data("actionkey"),r=jQuery(this).closest(".frm_posttax_row").attr("id").replace("frm_posttax_",""),n=jQuery(this).val(),i=jQuery(document.getElementById(r+"_show_exclude")).is(":checked")?1:0,o=jQuery('select[name$="[post_category]['+r+'][field_id]"]').val(),a=jQuery('input[name="id"]').val();jQuery.ajax({type:"POST",url:ajaxurl,data:{action:"frm_add_posttax_row",form_id:a,post_type:e,tax_key:r,action_key:t,meta_name:n,field_id:o,show_exclude:i,nonce:frmGlobal.nonce},success:function(e){jQuery(document.getElementById("frm_posttax_"+r)).replaceWith(e)}})}}function hi(){var e=jQuery(this).closest(".frm_postmeta_row"),t=e.find(".frm_cancelnew"),r=e.find(".frm_enternew");return e.find("select.frm_cancelnew").is(":visible")?(t.hide(),r.show()):(t.show(),r.hide()),e.find("input.frm_enternew, select.frm_cancelnew").val(""),!1}function vi(){var e=jQuery(this),t=e.val();"checkbox"===e.attr("type")&&!1===this.checked&&(t="");var r=e.data("toggleclass");""===t?jQuery("."+r).hide():(jQuery("."+r).show(),jQuery(".hide_"+r+"_"+t).hide())}function bi(){Hn()||(Rn(this),Dn(document.querySelector(".frm_form_settings")))}function ji(e){return e.preventDefault(),wi(jQuery(this),this.getAttribute("data-code")),!1}function wi(e,t){var r=!1,i=e;if("object"===n(e)){if(e.hasClass("frm_noallow"))return;void 0===(i=jQuery(e).closest("[data-fills]").attr("data-fills"))&&void 0!==(i=e.closest("div").attr("class"))&&(i=i.split(" ")[1])}if(void 0===i){var o=document.activeElement;"search"===o.type?null===(i=o.id.replace("-search-input","")).match(/\d/gi)&&(i=(o=jQuery(".frm-single-settings:visible ."+i)).attr("id")):i=o.id}i&&(r=jQuery("#wp-"+i+"-wrap.wp-editor-wrap").length>0);var a=jQuery(document.getElementById(i));if(void 0===e.attr("data-shortcode")&&(!a.length||void 0===a.attr("data-shortcode"))){var l=e.parents("ul.frm_code_list").attr("data-shortcode");"undefined"!==l&&"no"===l||(t="["+t+"]")}if(r&&(wpActiveEditor=i),!a.length)return!1;if("[default-html]"===t||"[default-plain]"===t){var s=0;"[default-plain]"===t&&(s=1),jQuery.ajax({type:"POST",url:ajaxurl,data:{action:"frm_get_default_html",form_id:jQuery('input[name="id"]').val(),plain_text:s,nonce:frmGlobal.nonce},elementId:i,success:function(e){if(r){var t=document.createElement("p");t.innerText=e,send_to_editor(t.innerHTML)}else Qi(a,e)}})}else t=function(e,t,r){return"object"===n(t)&&t instanceof jQuery&&0===r[0].id.indexOf("success_url_")&&(t=t[0]).closest("#frm-insert-fields-box")?(t.parentNode.classList.contains("frm_insert_url")||(e=e.replace("]"," sanitize_url=1]")),e):e}(t,e,a),r?send_to_editor(t):Qi(a,t);return!1}function Qi(e,t){if(document.selection)e[0].focus(),document.selection.createRange().text=t;else{obj=e[0];var r=obj.selectionEnd;t=function(e,t,r,n){var i=e.data("sep");if(void 0===i)return t;var o=e.val();if(!o.trim().length)return t;var a=new RegExp(i+"\\s*$"),l=new RegExp("^\\s*"+i);return o.substr(0,r).trim().length&&!1===a.test(o.substr(0,r))&&(t=i+t),o.substr(n,o.length).trim().length&&!1===l.test(o.substr(n,o.length))&&(t+=i),t}(e,t,obj.selectionStart,r),obj.value=obj.value.substr(0,obj.selectionStart)+t+obj.value.substr(obj.selectionEnd,obj.value.length);var n=r+t.length;!function(e,t){if(e.classList.contains("frm_classes")&&Ei(t)){var r=e.value.split(" ").filter(Ei);r.length&&(e.value=function(e,t,r){var n=e.split(" ").filter((function(e){return(e=e.trim()).length&&!t.includes(e)}));return n.includes(r)||n.push(r),n.join(" ")}(e.value,r,t.trim()))}}(obj,t),obj.focus(),obj.setSelectionRange(n,n)}Mn(e)}function Ei(e){return["frm_half","frm_third","frm_two_thirds","frm_fourth","frm_three_fourths","frm_fifth","frm_sixth","frm2","frm3","frm4","frm6","frm8","frm9","frm10","frm12"].includes(e.trim())}function xi(){var e=document.getElementById("frm-id-condition"),t=document.getElementById("frm-key-condition");this.checked?(e.classList.remove("frm_hidden"),t.classList.add("frm_hidden"),ko(t,"change")):(e.classList.add("frm_hidden"),t.classList.remove("frm_hidden"),ko(e,"change"))}function ki(){var e,t,r=document.getElementById("frm-id-key-condition").checked?"frm-id-condition":"frm-key-condition",n=document.getElementById("frm-is-condition").value,i=document.getElementById("frm-text-condition").value,o=document.getElementById("frm-insert-condition");t="if "+(e=(r=document.getElementById(r)).options[r.selectedIndex].value)+" "+n+'="'+i+'"]',o.setAttribute("data-code",t+a.conditional_text+"[/if "+e),o.innerHTML="["+t+"[/if "+e+"]"}function Li(){In(zi(this),this)}function Si(e){e.preventDefault(),e.stopPropagation(),Ci(this)}function Ai(e){!function(e){var t;if(e.id.startsWith("field_options_type_")){var r=e.id.split("_"),n=r.length&&r[r.length-1];null!==(t=document.querySelector("#frm-single-settings-".concat(n)))&&void 0!==t&&t.classList.contains("frm-type-".concat(e.value))||Ii()}}(e.target)}function Ii(e){var t;void 0===e&&(e=B("You are changing the field type. Not all field settings will appear as expected until you reload the page. Would you like to reload the page now?","formidable")),frmDom.modal.maybeCreateModal("frmSaveAndReloadModal",{title:B("Save and Reload?","formidable"),content:(t=d(e),t.style.padding="var(--gap-md)",t),footer:function(){var e=frmDom.modal.footerButton({text:B("Save and Reload","formidable"),buttonType:"primary"});_(e,(function(){Di()}));var t=frmDom.modal.footerButton({text:B("Cancel","formidable"),buttonType:"cancel"});return t.classList.add("dismiss"),frmDom.div({children:[t,e]})}()})}function Bi(e){var t;if(e instanceof Event){var r=document.querySelectorAll(".frm-single-settings .frm-show-box.frmsvg use"),n=Array.from(r).find((function(e){return"#frm_close_icon"===e.getAttribute("href")}));if(void 0===n)return;t=n.parentElement}else t=e;var i=t.getBoundingClientRect(),o=document.getElementById("frm_adv_info"),a=o.parentElement.getBoundingClientRect();o.style.top=i.top-a.top+32+"px",o.style.left=i.left-a.left-280+"px"}function Ci(e,r){var n=Hi(e),i=document.getElementById("frm_adv_info"),o=e.className;if("svg"===e.tagName&&(e=e.firstElementChild),"use"===e.tagName&&null===(o=e.getAttributeNS("http://www.w3.org/1999/xlink","href"))&&(o=e.getAttribute("href")),-1!==o.indexOf("frm_close_icon"))Pi(i);else{if(Bi(e),jQuery(".frm_code_list a").removeClass("frm_noallow"),n.classList.contains("frm_not_email_to")?jQuery("#frm-insert-fields-box .frm_code_list li:not(.show_frm_not_email_to) a").addClass("frm_noallow"):n.classList.contains("frm_not_email_subject")&&jQuery(".frm_code_list li.hide_frm_not_email_subject a").addClass("frm_noallow"),i.setAttribute("data-fills",n.id),i.style.display="block","use"===e.tagName)if(e.hasAttributeNS("http://www.w3.org/1999/xlink","href"))e.setAttributeNS("http://www.w3.org/1999/xlink","href","#frm_close_icon");else{var l=document.createElementNS("http://www.w3.org/2000/svg","use");l.setAttributeNS("http://www.w3.org/1999/xlink","href","#frm_close_icon"),e.parentNode.replaceChild(l,e)}else e.className=o.replace("frm_more_horiz_solid_icon","frm_close_icon");"nofocus"!==r&&("none"!==n.style.display?n.focus():jQuery(tinymce.get(n.id)).trigger("focus")),function(e){["address","body"].forEach((function(r){!function(e,r){var n,i;n=a.contextualShortcodes[r+"Selector"],i=a.contextualShortcodes[r];var o,l=e.matches(n),s=function(e){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=t(e))){r&&(e=r);var n=0,i=function(){};return{s:i,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,l=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){l=!0,o=e},f:function(){try{a||null==r.return||r.return()}finally{if(l)throw o}}}}(i);try{for(s.s();!(o=s.n()).done;){var d,c=o.value,f=null===(d=document.querySelector('#frm-adv-info-tab .frm_code_list [data-code="'+c+'"]'))||void 0===d?void 0:d.closest("li");null==f||f.classList.toggle("frm_hidden",!l)}}catch(e){s.e(e)}finally{s.f()}}(e,r)}))}(n)}}function qi(e){return 0===a.contextualShortcodes.length||!function(e){var t=e.querySelector("a");if(!t)return!1;var r=t.dataset.code;return a.contextualShortcodes.address.includes(r)||a.contextualShortcodes.body.includes(r)}(e)||function(e){var t=e.querySelector("a").dataset.code,r=document.getElementById("frm_adv_info").dataset.fills,n=document.getElementById(r),i=a.contextualShortcodes;return i.address.includes(t)?n.matches(i.addressSelector):n.matches(i.bodySelector)}(e)}function Ni(){x||(x=1,window.addEventListener("beforeunload",Mi))}function Oi(){x=0}function Ti(){x=0}function Di(){var e=document.getElementById("frm_submit_side_top");e.classList.contains("frm_submit_ajax")&&e.setAttribute("data-new-addon-installed",!0),e.click()}function Mi(e){x&&(e.preventDefault(),e.returnValue="")}function Fi(e,t){var r={my:"top",at:"top+"+t,of:window};e.dialog("option","position",r)}function Hi(e){for(var t=e.nextElementSibling;null!==t&&"INPUT"!==t.tagName&&"TEXTAREA"!==t.tagName;)t=Hi(t);return t}function zi(e){for(var t=e.previousElementSibling;null!==t&&"I"!==t.tagName&&"svg"!==t.tagName;)t=zi(t);return t}function Pi(e){var t,r,n,i;if((void 0!==e||null!==(e=document.getElementById("frm_adv_info")))&&null===document.getElementById("frm_dyncontent")){for(e.style.display="none",n=document.querySelectorAll(".frm-show-box.frm_close_icon"),t=0;t"+r.data.name+": "+r.data.msg+"

            ":'

            Imported '+r.data.name+"

            ",e.find(".status").prepend(n),e.find(".status").show(),N.importQueue=jQuery.grep(N.importQueue,(function(e){return e!=t})),N.imported++,0===N.importQueue.length?(e.find(".process-count").hide(),e.find(".forms-completed").text(N.imported),e.find(".process-completed").show()):(e.find(".form-current").text(N.imported+1),Vi(e)))}))}function Ki(e){e.preventDefault();var t=!1,r=jQuery('input[name="frm_export_forms[]"]');jQuery('input[name="frm_export_forms[]"]:checked').val()||(r.closest(".frm-table-box").addClass("frm_blank_field"),t="stop");var n=jQuery('input[name="type[]"]');if(jQuery('input[name="type[]"]:checked').val()||"checkbox"!==n.attr("type")||(n.closest("p").addClass("frm_blank_field"),t="stop"),"stop"===t)return!1;e.stopPropagation(),this.submit()}function Ji(){var e=jQuery(this).closest(".frm_blank_field");if(void 0!==e){var t=this.name;("type[]"===t&&jQuery('input[name="type[]"]:checked').val()||"frm_export_forms[]"===t&&jQuery(this).val())&&e.removeClass("frm_blank_field")}}function Yi(){null!==jQuery(this).val().match(/\.csv$/i)?jQuery(".show_csv").fadeIn():jQuery(".show_csv").fadeOut()}function Xi(){var e=document.querySelector('select[name="format"]');return e?e.value:""}function Zi(e){var t,r,n=e.target.value;to(n),eo.call(e.target),t=n,r=document.getElementById("frm-export-select-all"),"csv"===t?(r.checked=!1,r.disabled=!0):r.disabled=!1}function eo(){var e=jQuery(this),t=e.find(":selected"),r=t.data("support"),n=r.indexOf("|");jQuery('input[name="type[]"]').each((function(){this.checked=!1,r.indexOf(this.value)>=0?(this.disabled=!1,-1===n&&(this.checked=!0)):this.disabled=!0})),"csv"===e.val()?(jQuery(".csv_opts").show(),jQuery(".xml_opts").hide()):(jQuery(".csv_opts").hide(),jQuery(".xml_opts").show());var i=t.data("count"),o=jQuery('input[name="frm_export_forms[]"]');"single"===i?(o.prop("multiple",!1),o.prop("checked",!1)):(o.prop("multiple",!0),o.prop("disabled",!1)),e.trigger("change")}function to(e){if(""!==e){var t=document.querySelectorAll(".frm-is-repeater");t.length&&("csv"===e?t.forEach((function(e){e.classList.remove("frm_hidden")})):t.forEach((function(e){e.classList.add("frm_hidden")})),Qo.call(document.querySelector(".frm-auto-search")))}}function ro(){var e=jQuery("select[name=format]").find(":selected").data("count"),t=jQuery('input[name="frm_export_forms[]"]');"single"===e&&this.checked?(t.prop("disabled",!0),this.removeAttribute("disabled")):t.prop("disabled",!1)}function no(){jQuery(".frm_multiselect").hide().each(frmDom.bootstrap.multiselect.init)}function io(e){e.preventDefault(),lo(this,"frm_multiple_addons")}function oo(e){e.preventDefault(),lo(this,"frm_activate_addon")}function ao(e){e.preventDefault(),lo(this,"frm_install_addon")}function lo(e,t){var r,n,i,o;jQuery(".frm-addon-error").remove(),n=(r=jQuery(e)).attr("rel"),i=r.parent(),o=i.parent().find(".addon-status-label"),r.addClass("frm_loading_button"),jQuery.ajax({url:ajaxurl,type:"POST",async:!0,cache:!1,dataType:"json",data:{action:t,nonce:frmGlobal.nonce,plugin:n},success:function(e){var n,a,l;"string"!=typeof(e=null!==(n=null===(a=e)||void 0===a?void 0:a.data)&&void 0!==n?n:e)&&"string"==typeof e.message&&(void 0!==e.saveAndReload&&(l=e.saveAndReload),e=e.message);var s=uo(e);s?mo(s,i,r):(co(e,r,o,i,l,t),wp.hooks.doAction("frm_update_addon_state",e))},error:function(){r.removeClass("frm_loading_button")}})}function so(e){e.preventDefault();var t=jQuery(this),r=t.parent().parent(),n=t.attr("rel");t.addClass("frm_loading_button"),jQuery.ajax({url:ajaxurl,type:"POST",async:!0,cache:!1,dataType:"json",data:{action:"frm_install_addon",nonce:a.nonce,plugin:n,hostname:r.find("#hostname").val(),username:r.find("#username").val(),password:r.find("#password").val()},success:function(e){var n,i,o=uo(e=null!==(n=null===(i=e)||void 0===i?void 0:i.data)&&void 0!==n?n:e);o?mo(o,r,t):co(e,t,message,r)},error:function(){t.removeClass("frm_loading_button")}})}function co(e,t,r,n,i){var o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"frm_activate_addon",l=document.querySelectorAll(".frm-addon-status");l.forEach((function(t){t.textContent=e,t.style.display="block"})),t.css({opacity:"0"}),document.querySelectorAll(".frm-oneclick").forEach((function(e){e.style.display="none"})),jQuery("#frm_upgrade_modal h2").hide(),jQuery("#frm_upgrade_modal .frm_lock_icon").addClass("frm_lock_open_icon"),jQuery("#frm_upgrade_modal .frm_lock_icon use").attr("xlink:href","#frm_lock_open_icon");var s={frm_activate_addon:{class:"frm-addon-active",message:a.active},frm_deactivate_addon:{class:"frm-addon-installed",message:a.installed},frm_uninstall_addon:{class:"frm-addon-not-installed",message:a.not_installed}};s.frm_install_addon=s.frm_activate_addon;var c=r[0];c&&(c.textContent=s[o].message);var f=n[0].parentElement;f.classList.remove("frm-addon-not-installed","frm-addon-installed","frm-addon-active"),f.classList.add(s[o].class),t[0].classList.remove("frm_loading_button"),document.querySelectorAll(".frm-admin-page-import, #frm-admin-smtp, #frm-welcome").length>0?window.location.reload():["settings","form_builder"].includes(i)&&l.forEach((function(e){var t=null!==e.closest("#frm_upgrade_modal");e.appendChild(function(e,t){var r=[fo(e)];return t&&r.push(function(){var e=document.createElement("a");return e.setAttribute("href","#"),e.classList.add("button","button-secondary","frm-button-secondary","dismiss"),e.textContent=B("Close","formidable"),e}()),d({className:"frm-save-and-reload-options",children:r})}(i,t))}))}function fo(e){var t=document.createElement("button");return t.classList.add("frm-save-and-reload","button","button-primary","frm-button-primary"),t.textContent=B("Save and Reload","formidable"),t.addEventListener("click",(function(){var t,r;"form_builder"===e?Di():"settings"===e&&null!==(t=document.getElementById("form_settings_page"))&&null!==(r=t.querySelector("form.frm_form_settings"))&&(x=0,r.submit())})),t}function uo(e){return"string"!=typeof e&&(void 0===e.success||!e.success)&&(e.form&&jQuery(e.form).is("#message")?{message:jQuery(e.form).find("p").html()}:e)}function mo(e,t,r){e.form?(jQuery(".frm-inline-error").remove(),r.closest(".frm-card").html(e.form).css({padding:5}).find("#upgrade").attr("rel",r.attr("rel")).on("click",so)):(t.append('

            '+e.message+"

            "),r.removeClass("frm_loading_button"),jQuery(".frm-addon-error").delay(4e3).fadeOut())}function _o(){go()}function po(e){!function(e,t,r){var n=jQuery("#frm_leave_email_error");n.removeClass("frm_hidden").attr("frm-error",r),jQuery("#frm_leave_email").one("keyup",(function(){n.addClass("frm_hidden")}))}(0,0,e)}function go(){var e=document.getElementById("frmapi-email-form");jQuery.ajax({dataType:"json",url:e.getAttribute("data-url"),success:function(t){var r=t.renderedHtml;r=r.replace(/]*(formidableforms.css|action=frmpro_css)[^>]*>/gi,""),e.innerHTML=r}})}function yo(e){frmDom.autocomplete.initSelectionAutocomplete(e)}function ho(e){var t=this.parentNode.parentNode,r=t.elements.type.value;e.preventDefault(),this.classList.add("frm_loading_button"),bo(t,r,this)}function vo(e){var t=this.elements.type.value,r=this.querySelector("button");e.preventDefault(),r.classList.add("frm_loading_button"),bo(this,t,r)}function bo(e,t,r){var n=function(e){var t,r,n={},i=e.elements;for(r=0;r=0||Eo(l,n)?(s&&qi(o[e])&&o[e].classList.remove("frm_hidden"),o[e].classList.add("frm-search-result")):(o[e].classList.add("frm_hidden"),o[e].classList.remove("frm-search-result"))}(t=document.querySelector("#frm-insert-fields"))&&t.querySelectorAll(":scope > .frm-with-line").forEach((function(e){var t=e.nextElementSibling;if(t){var r=t.querySelectorAll(":scope > li.frmbutton"),n=Array.from(r).every((function(e){return e.classList.contains("frm_hidden")}));e.classList.toggle("frm_hidden",n)}})),jQuery(this).trigger("frmAfterSearch")}function Eo(e,t){return"s"!==t&&"s"!==e[e.length-1]&&(e+"s").indexOf(t)>=0}function xo(e){e.stopPropagation()}function ko(e,t){var r=document.createEvent("HTMLEvents");r.initEvent(t,!1,!0),e.dispatchEvent(r)}function Lo(e,t){var r,n=new XMLHttpRequest,i="string"==typeof e?e:Object.keys(e).map((function(t){return encodeURIComponent(t)+"="+encodeURIComponent(e[t])})).join("&");return n.open("post",ajaxurl,!0),n.onreadystatechange=function(){if(n.readyState>3&&200==n.status){r=n.responseText;try{r=JSON.parse(r)}catch(e){}t(r)}},n.setRequestHeader("X-Requested-With","XMLHttpRequest"),n.setRequestHeader("Content-type","application/x-www-form-urlencoded"),n.send(i),n}function So(e,t){e.classList.add("frm-fade"),setTimeout(t,1e3)}function Ao(e){jQuery(e).css("visibility","hidden")}function Io(e){jQuery(e).css("visibility","visible")}function Bo(e,t){var r=jQuery(e);if(!r.length)return!1;void 0===t&&(t="550px");var n={dialogClass:"frm-dialog",modal:!0,autoOpen:!1,closeOnEscape:!0,width:t,resizable:!1,draggable:!1,open:function(){var e,t;jQuery(".ui-dialog-titlebar").addClass("frm_hidden").removeClass("ui-helper-clearfix"),jQuery("#wpwrap").addClass("frm_overlay"),jQuery(".frm-dialog").removeClass("ui-widget ui-widget-content ui-corner-all"),r.removeClass("ui-dialog-content ui-widget-content"),e=r,t=function(){e.dialog("close")},jQuery(".ui-widget-overlay").on("click",t),e.on("click","a.dismiss",t)},close:function(){jQuery("#wpwrap").removeClass("frm_overlay"),jQuery(".spinner").css("visibility","hidden"),this.removeAttribute("data-option-type");var e=document.getElementById("bulk-option-type");e&&(e.value="")}};return r.dialog(n),r}function Co(e,t){if("#"===t){var r=document.getElementById(e),n=r.style.display;r.style.display="none"===n?"block":"none"}else e.is(":visible")?e.hide():e.show()}function qo(){window.onbeforeunload=null;var e=jQuery(window);e.off("beforeunload.widgets"),e.off("beforeunload.edit-post")}function No(){var e=jQuery(this).closest(".frm-single-settings").data("fid"),t=document.getElementById("frm_field_id_"+e);if(null!==t&&"form"===t.dataset.type)if(t=jQuery(t),this.options[this.selectedIndex].value){t.find(".frm-not-set")[0].classList.add("frm_hidden");var r=t.find(".frm-embed-message");r.html(r.data("embedmsg")+this.options[this.selectedIndex].text),t.find(".frm-embed-field-placeholder")[0].classList.remove("frm_hidden")}else t.find(".frm-not-set")[0].classList.remove("frm_hidden"),t.find(".frm-embed-field-placeholder")[0].classList.add("frm_hidden")}function Oo(){var e=jQuery(this).closest(".frm-single-settings"),t=e.find(".frmjs_product_choices"),r=e.find(".frm_prod_options_heading"),n=this.options[this.selectedIndex].value;t.removeClass("frm_prod_type_single frm_prod_type_user_def"),r.removeClass("frm_prod_user_def"),"single"===n?t.addClass("frm_prod_type_single"):"user_def"===n&&(t.addClass("frm_prod_type_user_def"),r.addClass("frm_prod_user_def"))}function To(e){var t=document.getElementById("frm_field_id_"+e);return null!==t&&"product"===t.getAttribute("data-type")}function Do(){var t=function(e,t){return window.frmCachedSubFields=window.frmCachedSubFields||{},window.frmCachedSubFields[e]=window.frmCachedSubFields[e]||{},window.frmCachedSubFields[e][t]},r=function(e,t,r){window.frmCachedSubFields=window.frmCachedSubFields||{},window.frmCachedSubFields[e]=window.frmCachedSubFields[e]||{},window.frmCachedSubFields[e][t]=r},n=[1,2,3,4,5,6,7,8,9,10,11,12].map((function(e){return"frm"+e})),i=["first","middle","last"];document.addEventListener("change",(function(o){o.target.matches(".frm_name_layout_dropdown")&&function(o){var a,l=o.target.value.split("_"),s=o.target.dataset.fieldId,d=document.querySelector("#field_"+s+"_inner_container .frm_combo_inputs_container"),c=(a=l.length,"frm"+parseInt(12/a));i.forEach((function(t){var i,o=d.querySelector('[data-sub-field-name="'+t+'"]');o&&(o.classList.add("frm_hidden"),(i=o.classList).remove.apply(i,e(n)),r(s,t,o))})),l.forEach((function(e){var r=t(s,e);r&&(r.classList.remove("frm_hidden"),r.classList.add(c),d.append(r))})),i.forEach((function(e){var t=document.querySelector(".frm_sub_field_options-"+e+'[data-field-id="'+s+'"]');t&&(t.classList.add("frm_hidden"),r(s,e+"_options",t))})),l.forEach((function(e){var r=t(s,e+"_options");r&&r.classList.remove("frm_hidden")}))}(o)}),!1)}function Mo(e,t){var r,n,i,o=!1,a=!1;(r=t.newOption?(new DOMParser).parseFromString(t.newOption,"text/html").body.childNodes[0]:t).querySelectorAll("svg").forEach((function(e,t){(n=e.getElementsByTagNameNS("http://www.w3.org/2000/svg","use")[0])&&("#frm_drag_icon"===(i=n.getAttributeNS("http://www.w3.org/1999/xlink","href")||n.getAttribute("href"))&&(o=!0),"#frm_save_icon"===i&&(a=!0))})),o||r.prepend(b.drag.cloneNode(!0)),r.querySelector("[id^=field_key_".concat(e,"-]"))&&!a&&r.querySelector("[id^=field_key_".concat(e,"-]")).after(b.save.cloneNode(!0)),t.newOption&&(t.newOption=r)}function Fo(){var e=document.getElementById("frm_leave_email").value.trim();if(""!==e)if(!1!==/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/i.test(e)){var t=jQuery("#frmapi-email-form").find("form"),r=t.find('[type="email"]').not(".frm_verify");if(r.length){if(document.getElementById("frm_empty_inbox")){document.getElementById("frm-add-my-email-address").remove();var n=document.getElementById("frm_leave_email_wrapper");if(n){n.classList.add("frm_hidden");var i=c({className:"frm-wait frm_spinner"});i.style.visibility="visible",i.style.float="none",i.style.width="unset",n.parentElement.insertBefore(i,n.nextElementSibling)}}r.val(e),jQuery.ajax({type:"POST",url:t.attr("action"),data:t.serialize()+"&action=frm_forms_preview"}).done((function(e){if(-1!==jQuery(e).find(".frm_message").text().trim().indexOf("Thanks!")){var t=document.getElementById("frmapi-email-form").parentElement.querySelector(".frm_spinner");t&&t.remove(),wp.hooks.applyFilters("frm_thank_you_on_signup",!0)&&document.getElementById("frm_leave_email_wrapper").replaceWith(c(B("Thank you for signing up!","formidable")))}else po("invalid")}))}}else po("invalid");else po("empty")}function Ho(e){if(D||e.stopPropagation(),!(e.target.classList.contains("frm-show-box")||e.target.parentElement&&e.target.parentElement.classList.contains("frm-show-box"))){var t=document.getElementById("frm_adv_info");t&&(t.dataset.fills===e.target.id&&void 0!==e.target.id||e.target.closest("#frm_adv_info")||"none"===t.style.display||Pi(t))}}return{init:function(){var t,r,n,i,o,a,l;!function(){jQuery(document).on("click","#frm-add-my-email-address",(function(e){e.preventDefault(),Fo()}));var e=document.getElementById("frm_empty_inbox"),t=document.getElementById("frm_leave_email");if(e&&t){var r=document.getElementById("frm-leave-email-modal");r.classList.remove("frm_hidden"),r.querySelector(".frm_modal_footer").classList.add("frm_hidden"),t.addEventListener("keyup",(function(e){if("Enter"===e.key){var t=document.getElementById("frm-add-my-email-address");t&&t.click()}}))}}(),r=document.querySelector(".frm-admin-footer-links"),n=null!==(t=document.querySelector(".frm_page_container"))&&void 0!==t?t:document.getElementById("wpbody-content"),r&&n&&(n.appendChild(r),r.classList.remove("frm_hidden")),N={},jQuery(".wp-admin").on("click",(function(e){var t=jQuery(e.target),r=jQuery(".dropdown.open");!r.length||t.hasClass("dropdown")||t.closest(".dropdown").length||r.removeClass("open")})),jQuery("#frm_bs_dropdown:not(.open) a").on("click",Lt),void 0===k&&(k=jQuery(document.getElementById("form_id")).val()),document.querySelectorAll(".frm-warning-dismiss").forEach((function(e){_(e,St)})),frmAdminBuild.inboxBannerInit(),j.length>0?frmAdminBuild.buildInit():null!==document.getElementById("frm_notification_settings")?frmAdminBuild.settingsInit():null!==document.getElementById("frm_styling_form")?frmAdminBuild.styleInit():null!==document.getElementById("form_global_settings")?frmAdminBuild.globalSettingsInit():null!==document.getElementById("frm_export_xml")?frmAdminBuild.exportInit():null!==document.querySelector(".frm-inbox-wrapper")?frmAdminBuild.inboxInit():null!==document.getElementById("frm-welcome")?frmAdminBuild.solutionInit():(function(){if(document.body.classList.contains("formidable_page_formidable-entries")){var e=document.getElementById("screen-options-wrap");if(e){var t=d({className:"frm_warning_style",text:B("Only 10 columns can be selected at a time.","formidable")});t.style.margin=0;var r=e.querySelector("legend");r.parentNode.insertBefore(t,r.nextElementSibling);var n=Array.from(e.querySelectorAll('input[type="checkbox"]')),i=function(){n.reduce((function(e,t){return t.checked?e+1:e}),0)>=10?(t.classList.remove("frm_hidden"),n.forEach((function(e){e.checked||(e.parentNode.classList.add("frm_noallow"),e.disabled=!0)}))):t.classList.add("frm_hidden")};i(),n.forEach((function(e){e.addEventListener("change",(function(e){e.target.checked?i():(t.classList.add("frm_hidden"),n.forEach((function(e){e.parentNode.classList.remove("frm_noallow"),e.disabled=!1})))}))}))}}}(),yo(),jQuery("[data-frmprint]").on("click",(function(){return window.print(),!1}))),jQuery(document).on("change","select[data-toggleclass], input[data-toggleclass]",vi),function(){function e(e){var t=e.options[e.selectedIndex];e.querySelectorAll("option[data-dependency]:not([data-dependency-skip])").forEach((function(e){var r=document.querySelector(e.dataset.dependency);null==r||r.classList.toggle("frm_hidden",t!==e)}))}document.querySelectorAll("select.frm_select_with_dependency").forEach(e),frmDom.util.documentOn("change","select.frm_select_with_dependency",(function(t){return e(t.target)}))}(),(jQuery(document.getElementById("frm_adv_info")).length>0||jQuery(".frm_field_list").length>0)&&frmAdminBuild.panelInit(),i=jQuery(".wrap, .frm_wrap"),o=document.getElementById("frm_confirm_modal"),a=!1,l=!1,jQuery(o).on("click","[data-deletefield]",wr),jQuery(o).on("click","[data-removeid]",G),jQuery(o).on("click","[data-trashtemplate]",wo),i.on("click",".frm_remove_tag, .frm_remove_form_action",G),i.on("click","a[data-frmverify]",M),i.on("click","a[data-frmtoggle]",z),i.on("click","a[data-frmhide], a[data-frmshow]",P),i.on("change","input[data-frmhide], input[data-frmshow]",P),i.on("click",".widget-top,a.widget-action",$),i.on("mouseenter.frm",".frm_bstooltip, .frm_help",(function(){jQuery(this).off("mouseenter.frm"),jQuery(".frm_bstooltip, .frm_help").tooltip(),jQuery(this).tooltip("show")})),jQuery(".frm_bstooltip, .frm_help").tooltip(),jQuery(document).on("click","#doaction, #doaction2",(function(e){var t="doaction"===this.id?"top":"bottom",r=document.getElementById("bulk-action-selector-"+t),n=document.getElementById("confirm-bulk-delete-"+t);if(null!==r&&null!==n){if(a=this,!l&&"bulk_delete"===r.value)return e.preventDefault(),F(n),!1}else a=!1})),jQuery(document).on("click","#frm-confirmed-click",(function(e){if(!1!==a&&!e.target.classList.contains("frm-btn-inactive"))return"confirm-bulk-delete"===this.getAttribute("href")?(e.preventDefault(),l=!0,a.click(),!1):void 0})),function(){var e=Bo("#frm_upgrade_modal");function t(t){var r,n,i;if((r=t.target).classList){var o=r.classList.contains("frm_show_expired_modal")||null!==r.querySelector(".frm_show_expired_modal")||r.closest(".frm_show_expired_modal");if("change"===t.type&&r.classList.contains("frm_select_with_upgrade")){var a=r.options[r.selectedIndex];a&&a.dataset.upgrade&&(r=a)}if(!r.dataset.upgrade){var l=r.closest("[data-upgrade]");if(!l){if(!(l=r.closest(".frm_field_box")))return;r.dataset.upgrade=""}r=l}if(o)wp.hooks.doAction("frm_show_expired_modal",r);else{var s=r.dataset.upgrade;if(s&&!r.classList.contains("frm_show_upgrade_tab")){t.preventDefault();var d=e.get(0),c=d.querySelector(".frm_lock_icon");c&&(c.style.display="block",c.classList.remove("frm_lock_open_icon"),c.querySelector("use").setAttribute("href","#frm_lock_icon"));var f="frm_upgrade_modal_image",u=document.getElementById(f);u&&u.remove(),r.dataset.image&&(c&&(c.style.display="none"),c.parentNode.insertBefore(m({id:f,src:frmGlobal.url+"/images/"+r.dataset.image}),c));var _=d.querySelector(".license-level");_&&(_.textContent=Gn(r)),Wn(r,"modal",s),d.querySelector(".frm_are_not_installed").style.display=r.dataset.image?"none":"inline-block",d.querySelector(".frm_feature_label").textContent=s,d.querySelector("h2").style.display="block",e.dialog("open");var p=d.querySelector(".button-primary:not(.frm-oneclick-button)");n=p.getAttribute("href").replace(/(medium=)[a-z_-]+/gi,"$1"+r.getAttribute("data-medium")),null===(i=r.getAttribute("data-content"))&&(i=""),n=n.replace(/(content=)[a-z_-]+/gi,"$1"+i),p.setAttribute("href",n)}}}}!1!==e&&(document.addEventListener("click",t),frmDom.util.documentOn("change","select.frm_select_with_upgrade",t))}();var s=jQuery(document.getElementById("frm_shortcodediv"));s.length>0&&(jQuery("a.edit-frm_shortcode").on("click",(function(){return s.is(":hidden")&&(s.slideDown("fast"),this.style.display="none"),!1})),jQuery(".cancel-frm_shortcode","#frm_shortcodediv").on("click",(function(){return s.slideUp("fast"),s.siblings("a.edit-frm_shortcode").show(),!1}))),jQuery(document).on("click","#frm-nav-tabs a",W),jQuery(".post-type-frm_display .frm-nav-tabs a, .frm-category-tabs a").on("click",(function(){var e=this.classList.contains("frm_show_upgrade_tab");if(!this.classList.contains("frm_noallow")||e)return e&&$n(this),U(this),!1})),U(jQuery(".starttab a"),"auto"),jQuery(document).on("click","#frm-fid-search-menu a",(function(){var e=this.id.replace("fid-","");return jQuery('select[name="fid"]').val(e),Dn(document.getElementById("posts-filter")),!1})),jQuery(".frm_select_box").on("click focus",(function(){this.select()})),jQuery(document).on("input search change",".frm-auto-search:not(#frm-form-templates-page #template-search-input)",Qo),jQuery(document).on("focusin click",".frm-auto-search",xo);var c=jQuery(".frm-auto-search");""!==c.val()&&c.trigger("keyup"),FrmFormsConnect.init(),jQuery(document).on("click",".frm-install-addon",ao),jQuery(document).on("click",".frm-activate-addon",oo),jQuery(document).on("click",".frm-solution-multiple",io),jQuery("button, input[type=submit]").on("click",qo),document.addEventListener("click",(function(e){if("LABEL"===e.target.nodeName){var t=e.target.getAttribute("for");if(t){var r=document.getElementById(t);if(r&&r.nextElementSibling){var n=r.nextElementSibling.querySelector("button.dropdown-toggle.multiselect");n&&setTimeout((function(){return n.click()}),0)}}}})),frmAdminBuild.hooks.addFilter("frm_before_embed_modal",(function(e,t){var r,n,i=t.element;if("form"!==t.type)return e;var o=i.closest("tr");if(o)r=parseInt(o.querySelector(".column-id").textContent),n=o.querySelector(".column-form_key").textContent;else{r=document.getElementById("form_id").value;var a=document.getElementById("frm_form_key");if(a)n=a.value;else{var l=document.getElementById("frm-previewDrop");l&&(n=l.nextElementSibling.querySelector(".dropdown-item a").getAttribute("href").split("form=")[1])}}return[r,n]})),document.querySelectorAll("#frm-show-fields > li, .frm_grid_container li").forEach((function(t,r){t.addEventListener("click",(function(){var t,r;r=(null===(t=this.querySelector("li"))||void 0===t?void 0:t.dataset.fid)||this.dataset.fid,fieldOptions=document.querySelectorAll("[id^=frm_delete_field_".concat(r,"-]")),fieldOptions.length<2||e(fieldOptions).slice(1).forEach((function(e,t){e.classList.contains("frm_other_option")||Mo(r,e)}))}))}));var f=document.getElementById("frm_small_screen_proceed_button");f&&_(f,(function(){var e;null===(e=document.getElementById("frm_small_device_message_container"))||void 0===e||e.remove(),g("small_screen_proceed",new FormData)}));var u=document.getElementById("frm_sale_banner"),p=null==u?void 0:u.querySelector(".dismiss");u&&(_(u,(function(e){e.target.closest(".dismiss")||(window.location.href=u.getAttribute("data-url"))})),p&&_(p,(function(){u.remove();var e=new FormData;g("sale_banner_dismiss",e)})))},buildInit:function(){var e,t,r;jQuery("#frm_builder_page").on("mouseup","*:not(.frm-show-box)",Ho),y=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:100;return frmDom.util.debounce(e,t)}(oe,10),h=document.getElementById("post-body-content"),v=jQuery(h),jQuery(".frm_field_loading").length&&Le(jQuery(".frm_field_loading").first().attr("id")),V("ul.frm_sorting"),document.querySelectorAll(".field_type_list > li:not(.frm_show_upgrade)").forEach(X),jQuery("ul.field_type_list, .field_type_list li, ul.frm_code_list, .frm_code_list li, .frm_code_list li a, #frm_adv_info #category-tabs li, #frm_adv_info #category-tabs li a").disableSelection(),jQuery(".frm_submit_ajax").on("click",Tn),jQuery(".frm_submit_no_ajax").on("click",Fn),zn(),jQuery("a.edit-form-status").on("click",xn),jQuery(".cancel-form-status").on("click",kn),jQuery(".save-form-status").on("click",(function(){var e=jQuery(document.getElementById("form_change_status")).val();return jQuery('input[name="new_status"]').val(e),jQuery(document.getElementById("form-status-display")).html(e),jQuery(".cancel-form-status").trigger("click"),!1})),jQuery(".frm_form_builder form").first().on("submit",(function(){jQuery(".inplace_field").trigger("blur")})),no(),Or(),e=jQuery(w),t=document.getElementById("frm_form_editor_container"),e.on("click",".frm_add_logic_row",xr),e.on("click",".frm_add_watch_lookup_row",Lr),e.on("change",".frm_get_values_form",qr),e.on("change",".frm_logic_field_opts",vn),e.on("frm-multiselect-changed",'select[name^="field_options[admin_only_"]',Ln),jQuery(document.getElementById("frm-insert-fields")).on("click",".frm_add_field",Ae),j.on("click",".frm_clone_field",Ce),e.on("blur",'input[id^="frm_calc"]',Ye),e.on("change","input.frm_format_opt, input.frm_max_length_opt",lt),e.on("change click","[data-changeme]",ot),e.on("click","input.frm_req_field",st),e.on("click",".frm_mark_unique",ct),e.on("change",".frm_repeat_format",Ur),e.on("change",".frm_repeat_limit",Vr),e.on("change",".frm_js_checkbox_limit",Kr),e.on("input",'input[name^="field_options[add_label_"]',(function(){Jr(this,"add")})),e.on("input",'input[name^="field_options[remove_label_"]',(function(){Jr(this,"remove")})),e.on("change",'select[name^="field_options[data_type_"]',Nr),jQuery(t).on("click",".frm-collapse-page",Tr),jQuery(t).on("click",".frm-collapse-section",Fr),e.on("click",".frm-single-settings h3",Hr),e.on("keydown",".frm-single-settings h3",(function(e){"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),Hr.call(this,e))})),jQuery(t).on("show.bs.dropdown hide.bs.dropdown",Pe),e.on("click",".frm_toggle_sep_values",yt),e.on("click",".frm_toggle_image_options",ht),e.on("click",".frm_remove_image_option",xt),e.on("click",".frm_choose_image_box",Et),e.on("change",".frm_hide_image_text",Qt),e.on("change",".frm_field_options_image_size",jt),e.on("click",".frm_multiselect_opt",kt),j.on("mousedown","input, textarea, select",At),j.on("click","input[type=radio], input[type=checkbox]",At),j.on("click",".frm_delete_field",Nt),j.on("click",".frm_select_field",Ot),jQuery(document).on("click",".frm_delete_field_group",Tt),jQuery(document).on("click",".frm_clone_field_group",Dt),jQuery(document).on("click","#frm_field_group_controls > span:first-child",Mt),jQuery(document).on("click",".frm-row-layout-option",Yt),jQuery(document).on("click",".frm-merge-fields-into-row .frm-row-layout-option",Xt),jQuery(document).on("click",".frm-custom-field-group-layout",er),jQuery(document).on("click",".frm-merge-fields-into-row .frm-custom-field-group-layout",rr),jQuery(document).on("click",".frm-break-field-group",lr),j.on("click","#frm_field_group_popup .frm_grid_container input",sr),jQuery(document).on("click",".frm-cancel-custom-field-group-layout",dr),jQuery(document).on("click",".frm-save-custom-field-group-layout",fr),j.on("click","ul.frm_sorting",ur),jQuery(document).on("click",".frm-merge-fields-into-row",vr),jQuery(document).on("click",".frm-delete-field-groups",jr),j.on("click",'.frm-field-action-icons [data-toggle="dropdown"]',(function(){this.closest("li.form-field").classList.add("frm-field-settings-open"),jQuery(document).on("click","#frm_builder_page",Te)})),j.on("mousemove","ul.frm_sorting",De),j.on("show.bs.dropdown",".frm-field-action-icons",He),jQuery(document).on("show.bs.dropdown","#frm_field_group_controls",ze),e.on("click",".frm_single_option a[data-removeid]",It),e.on("mousedown",".frm_single_option input[type=radio]",Bt),e.on("focusin",".frm_single_option input[type=text]",Ct),e.on("click",".frm_add_opt",_t),e.on("change",".frm_single_option input",Xr),e.on("change",".frm_image_id",Xr),e.on("change",".frm_toggle_mult_sel",pt),e.on("focusin",".frm_classes",Li),j.on("click",".frm_primary_label",zr),j.on("click",".frm_description",Pr),j.on("click","li.ui-state-default:not(.frm_noallow)",Gr),j.on("dblclick","li.ui-state-default",Wr),e.on("change",".frm_tax_form_select",Yr),e.on("change","select.conf_field",ft),e.on("change",".frm_get_field_selection",bn),e.on("click",".frm-show-inline-modal",An),e.on("click",".frm-inline-modal .dismiss",Bn),jQuery(document).on("change","[data-frmchange]",Cn),e.on("change",".frm_include_extras_field",et),e.on("change",'select[name^="field_options[form_select_"]',No),jQuery(document).on("submit","#frm_js_build_form",Oi),jQuery(document).on("change","#frm_builder_page input:not(.frm-search-input):not(.frm-custom-grid-size-input), #frm_builder_page select, #frm_builder_page textarea",Ni),nt(),jQuery(document).on("change",".frmjs_prod_data_type_opt",Oo),jQuery(document).on("focus",'.frm-single-settings ul input[type="text"][name^="field_options[options_"]',Ar),jQuery(document).on("blur",'.frm-single-settings ul input[type="text"][name^="field_options[options_"]',Br),frmDom.util.documentOn("click",".frm-show-field-settings",Gr),frmDom.util.documentOn("change","select.frm_format_dropdown, select.frm_phone_type_dropdown",$r),e.on("keydown",'.frm_single_option input[name^="field_options["], .frm_single_option input[name^="rows_"]',(function(e){"Enter"===e.key&&function(e){var t=e.closest(".frm_single_option").parentElement.querySelectorAll('.frm_single_option input[name^="field_options[" ], .frm_single_option input[name^="rows_"]'),r=Array.from(t),n=r.indexOf(e);if(!(n<0)){var i=r.slice(n+1).find((function(e){return null!==e.offsetParent}));if(i){i.focus();var o=i.value.length;i.setSelectionRange(o,o)}}}(e.currentTarget)})),!1!==(r=Bo("#frm-bulk-modal","700px"))&&(jQuery(".frm-insert-preset").on("click",mt),jQuery(w).on("click","a.frm-bulk-edit-link",(function(e){e.preventDefault();var t,n,i,o,a,l="",s=jQuery(this).closest("[data-fid]").data("fid"),d=_n(s),c=To(s);if(o=document.getElementById("frm_field_"+s+"_opts")){for(a=o.getElementsByTagName("li"),document.getElementById("bulk-field-id").value=s,t=0;t=a.length-1&&(document.getElementById("frm_bulk_options").value=l);return r.dialog("open"),!1}})),jQuery("#frm-update-bulk-opts").on("click",(function(){var e=document.getElementById("bulk-field-id").value;document.getElementById("bulk-option-type").value||(this.classList.add("frm_loading_button"),frmAdminBuild.updateOpts(e,document.getElementById("frm_bulk_options").value,r),Ni())}))),jQuery(".frm-hide-empty").each((function(){0===jQuery(this).text().trim().length&&jQuery(this).remove()})),Be(),Do(),Qn(),frmDom.util.documentOn("change",".frm_show_password_setting_input",(function(e){var t=e.target.getAttribute("data-fid"),r=document.getElementById("frm_field_id_"+t);r&&r.classList.toggle("frm_disabled_show_password",!e.target.checked)})),document.addEventListener("scroll",Bi,!0),document.addEventListener("change",Ai),document.querySelector(".frm_form_builder").addEventListener("mousedown",(function(e){e.shiftKey&&e.preventDefault()}))},settingsInit:function(){var e,t,r,n,i=jQuery(document.getElementById("frm_notification_settings"));i.on("click",".frm_email_buttons",ti),i.on("click",".frm_remove_field",ri),i.on("change",".frm_to_row, .frm_from_row",ni),i.on("change",".frm_tax_selector",yi),i.on("change","select.frm_single_post_field",di),i.on("change","select.frm_toggle_post_content",ci),i.on("change","select.frm_dyncontent_opt",fi),i.on("change",".frm_post_type",ui),i.on("click",".frm_add_postmeta_row",pi),i.on("click",".frm_add_posttax_row",_i),i.on("click",".frm_toggle_cf_opts",hi),i.on("click",".frm_duplicate_form_action",Kn),jQuery(".frm_actions_list").on("click",".frm_active_action",Yn),jQuery("#frm-show-groups, #frm-hide-groups").on("click",Xn),no(),jQuery("ul.frm_actions_list li").each((function(){ii(jQuery(this).children("a").data("actiontype"));var e=jQuery(this).find("i");"none"!==e.css("background-image")&&e.addClass("frm-inverse")})),jQuery(".frm_submit_settings_btn").on("click",bi),zn(),(e=jQuery(".frm_form_settings")).on("click",".frm_add_form_logic",si),e.on("click",".frm_already_used",li),document.addEventListener("click",(function(e){var t=e.target;t.closest(".frm_image_preview_wrapper")&&(t.closest(".frm_choose_image_box")?Et.bind(t)(e):t.closest(".frm_remove_image_option")&&xt.bind(t)(e))})),e.on("mouseup","*:not(.frm-show-box)",Ho),jQuery(document.getElementById("no_save")).on("change",(function(){this.checked&&!0!==confirm(a.no_save_warning)&&jQuery(this).attr("checked",!1)})),jQuery('select[name="options[edit_action]"]').on("change",Vn),t=document.getElementById("logged_in"),jQuery(t).on("change",(function(){this.checked?Io(".hide_logged_in"):Ao(".hide_logged_in")})),r=jQuery(document.getElementById("frm_cookie_expiration")),jQuery(document.getElementById("frm_single_entry_type")).on("change",(function(){"cookie"===this.value?r.fadeIn("slow"):r.fadeOut("slow")}));var o=document.getElementById("single_entry");jQuery(o).on("change",(function(){this.checked?Io(".hide_single_entry"):Ao(".hide_single_entry"),this.checked&&"cookie"===jQuery(document.getElementById("frm_single_entry_type")).val()?r.fadeIn("slow"):r.fadeOut("slow")})),jQuery(".hide_save_draft").hide();var l=jQuery(document.getElementById("save_draft"));l.on("change",(function(){this.checked?jQuery(".hide_save_draft").fadeIn("slow"):jQuery(".hide_save_draft").fadeOut("slow")})),Mn(l),n=document.getElementById("editable"),jQuery(n).on("change",(function(){this.checked?(jQuery(".hide_editable").fadeIn("slow"),Mn(document.getElementById("edit_action"))):(jQuery(".hide_editable").fadeOut("slow"),jQuery(".edit_action_message_box").fadeOut("slow"))})),jQuery(document).on("change","#protect_files",(function(){this.checked?jQuery(".hide_protect_files").fadeIn("slow"):jQuery(".hide_protect_files").fadeOut("slow")})),jQuery(document).on("frm-multiselect-changed","#protect_files_role",Ln),jQuery(document).on("submit",".frm_form_settings",Ti),jQuery(document).on("change","#form_settings_page input:not(.frm-search-input), #form_settings_page select, #form_settings_page textarea",Ni),yo(),jQuery(document).on("frm-action-loaded",Gi),frmDom.util.documentOn("change",'.frm_on_submit_type input[type="radio"]',(function(e){if(e.target.checked){var t=e.target.closest(".frm_form_action_settings");t.querySelectorAll(".frm_on_submit_dependent_setting:not(.frm_hidden)").forEach((function(e){e.classList.add("frm_hidden")})),t.querySelectorAll(".frm_on_submit_dependent_setting[data-show-if-"+e.target.value+"]").forEach((function(e){e.classList.remove("frm_hidden")})),t.setAttribute("data-on-submit-type",e.target.value)}}))},panelInit:function(){var e,t,r,n;jQuery(".frm_wrap, #postbox-container-1").on("click",".frm_insert_code",ji),jQuery(document).on("change",".frm_insert_val",(function(){wi(jQuery(this).data("target"),jQuery(this).val()),jQuery(this).val("")})),jQuery(document).on("click change","#frm-id-key-condition",xi),jQuery(document).on("keyup change",".frm-build-logic",ki),Un(),jQuery(document).on("frmElementAdded",(function(e,t){Un(t)})),jQuery(document).on("mousedown",".frm-show-box",Si),t=document.getElementById("form_settings_page"),r=document.body.classList.contains("post-type-frm_display"),n=document.getElementById("frm_insert_fields_tab"),(null!==t||r||D)&&jQuery(document).on("focusin","form input, form textarea",(function(e){var i,o,a,l;if(e.stopPropagation(),(o=this).parentNode.parentNode.classList.contains("frm_has_shortcodes")&&(Pi(),"use"===(a=zi(o)).tagName?-1===(a=a.firstElementChild).getAttributeNS("http://www.w3.org/1999/xlink","href").indexOf("frm_close_icon")&&Ci(a,"nofocus"):a.classList.contains("frm_close_icon")||Ci(a,"nofocus")),jQuery(this).is(":not(:submit, input[type=button], .frm-search-input, input[type=checkbox])")){if(jQuery(e.target).closest("#frm_adv_info").length)return;if(null!==t||D)i=jQuery("#frm_html_tab"),jQuery(this).closest("#html_settings").length>0?(i.show(),i.siblings().hide(),jQuery("#frm_html_tab a").trigger("click"),function(e){var t,r=e.id;void 0!==r&&-1===r.indexOf("-search-input")&&(jQuery("#frm-adv-info-tab").attr("data-fills",r.trim()),e.classList.contains("field_custom_html")&&(r="field_custom_html"),t=["after_html","before_html","submit_html","field_custom_html"],jQuery.inArray(r,t)>=0&&(jQuery(".frm_code_list li:not(.show_"+r+")").addClass("frm_hidden"),jQuery(".frm_code_list li.show_"+r).removeClass("frm_hidden")))}(this)):((l=jQuery(".frm-category-tabs li"))[0]&&(l[0].style.display=""),n.click(),i.hide(),i.siblings().show());else if(r){var s=new CustomEvent("frm_legacy_views_handle_field_focus");s.frmData={idAttrValue:this.id},document.dispatchEvent(s)}}})),jQuery(".frm_wrap, #postbox-container-1").on("mousedown","#frm_adv_info a, .frm_field_list a",(function(e){e.preventDefault()})),(e=jQuery("#frm_adv_info")).on("click",".subsubsub a.frmids",(function(e){Ri("frmids",e)})),e.on("click",".subsubsub a.frmkeys",(function(e){Ri("frmkeys",e)}))},inboxInit:function(){var e;jQuery(".frm_inbox_dismiss").on("click",(function(e){var t=this.parentNode.parentNode,r=t.getAttribute("data-message"),n=this.getAttribute("href"),i=t.cloneNode(!0),o=document.querySelector(".frm-dismissed-inbox-messages");if("free_templates"!==r||this.classList.contains("frm_inbox_dismiss")){e.preventDefault(),data={action:"frm_inbox_dismiss",key:r,nonce:frmGlobal.nonce};var a="frm_inbox_slide_in"===t.id;a&&(t.classList.remove("s11-fadein"),t.classList.add("s11-fadeout"),t.addEventListener("animationend",(function(){return t.remove()}),{once:!0})),Lo(data,(function(){if(!a)return"#"!==n?(window.location=n,!0):void So(t,(function(){var e;null!==o&&(i.classList.remove("frm-fade"),null===(e=i.querySelector(".frm-inbox-message-heading"))||void 0===e||e.removeChild(i.querySelector(".frm-inbox-message-heading .frm_inbox_dismiss")),o.append(i)),1===t.parentNode.querySelectorAll(".frm-inbox-message-container").length&&(document.getElementById("frm_empty_inbox").classList.remove("frm_hidden"),t.parentNode.closest(".frm-active").classList.add("frm-empty-inbox"),_o()),t.parentNode.removeChild(t)}))}))}})),!1===(null===(e=document.getElementById("frm_empty_inbox"))||void 0===e?void 0:e.classList.contains("frm_hidden"))&&_o()},solutionInit:function(){jQuery(document).on("submit","#frm-new-template",vo)},styleInit:function(){var e=jQuery(".frm_image_preview_wrapper");e.on("click",".frm_choose_image_box",Et),e.on("click",".frm_remove_image_option",xt),wp.hooks.doAction("frm_style_editor_init")},customCSSInit:function(){console.warn("Calling frmAdminBuild.customCSSInit is deprecated.")},globalSettingsInit:function(){var e;jQuery(document).on("click","[data-frmuninstall]",$i),no(),null!==(e=document.getElementById("licenses_settings"))&&jQuery(e).on("click",".edd_frm_save_license",Wi),jQuery(document).on("click","#frm-new-template button",ho),jQuery("#frm-dismissable-cta .dismiss").on("click",(function(e){e.preventDefault(),jQuery.post(ajaxurl,{action:"frm_lite_settings_upgrade",nonce:frmGlobal.nonce}),jQuery(".settings-lite-cta").remove()}));var t=document.getElementById("frm_re_type");t&&t.addEventListener("change",jo),document.querySelector(".frm_captchas").addEventListener("change",(function(e){var t,r=null===(t=document.querySelector('.frm_captchas input[checked="checked"]'))||void 0===t?void 0:t.value,n=e.target.value!==r;document.querySelector(".captcha_settings .frm_note_style").classList.toggle("frm_hidden",!n)})),frmDom.util.documentOn("submit",".frm_settings_form",(function(){return x=0}));var r=document.getElementById("manage_styles_settings");r&&r.addEventListener("change",(function(e){var t=e.target;"SELECT"===t.nodeName&&t.dataset.name&&!t.getAttribute("name")&&t.setAttribute("name",t.dataset.name)}));var n=document.getElementById("payments_settings"),i=null==n?void 0:n.querySelectorAll('[name="frm_payment_section"]');i&&i.forEach((function(e){e.addEventListener("change",(function(){if(e.checked){var t=n.querySelector('label[for="'.concat(e.id,'"]'));t&&t.setAttribute("aria-selected","true"),i.forEach((function(t){if(t!==e){var r=n.querySelector('label[for="'.concat(t.id,'"]'));r&&r.setAttribute("aria-selected","false")}}))}}))}))},exportInit:function(){jQuery(".frm_form_importer").on("submit",Ui),jQuery(document.getElementById("frm_export_xml")).on("submit",Ki),jQuery("#frm_export_xml input, #frm_export_xml select").on("change",Ji),jQuery('input[name="frm_import_file"]').on("change",Yi),document.querySelector('select[name="format"]').addEventListener("change",Zi),jQuery('input[name="frm_export_forms[]"]').on("click",ro),no(),jQuery(".frm-feature-banner .dismiss").on("click",(function(e){e.preventDefault(),jQuery.post(ajaxurl,{action:"frm_dismiss_migrator",plugin:this.id,nonce:frmGlobal.nonce}),this.parentElement.remove()})),to(Xi()),document.querySelector("#frm-export-select-all").addEventListener("change",(function(e){document.querySelectorAll('[name="frm_export_forms[]"]').forEach((function(t){return t.checked=e.target.checked}))}))},inboxBannerInit:function(){var e=document.getElementById("frm_banner");if(e){var t=e.querySelector(".frm-banner-dismiss");document.addEventListener("click",(function(r){r.target===t&&Lo({action:"frm_inbox_dismiss",key:e.dataset.key,nonce:frmGlobal.nonce},(function(){jQuery(e).fadeOut(400,(function(){e.remove()}))}))}))}},updateOpts:function(e,t,r){var n=_n(e),i=To(e)?"frm_bulk_products":"frm_import_options";jQuery.ajax({type:"POST",url:ajaxurl,data:{action:i,field_id:e,opts:t,separate:n,nonce:frmGlobal.nonce},success:function(t){document.getElementById("frm_field_"+e+"_opts").innerHTML=t,wp.hooks.doAction("frm_after_bulk_edit_opts",e),tn(e),void 0!==r&&(r.dialog("close"),document.getElementById("frm-update-bulk-opts").classList.remove("frm_loading_button"))}})},triggerRemoveLogic:function(e,t){jQuery("#frm_logic_"+e+"_"+t+" .frm_remove_tag").trigger("click")},downloadXML:function(e,t,r){var n=ajaxurl+"?action=frm_"+e+"_xml&ids="+t;null!==r&&(n=n+"&is_template="+r),location.href=n},hooks:{applyFilters:function(e){for(var t,r=arguments.length,n=new Array(r>1?r-1:0),i=1;i1?r-1:0),i=1;i1&&void 0!==arguments[1]?arguments[1]:{};return new Promise((function(r){var n=k,i=0;"summary"===e&&(i=j.children('li[data-type="break"]').length>0?1:0),jQuery.ajax({type:"POST",url:ajaxurl,data:Object.assign(pe(e,0,n,i),{field_options:t}),success:function(t){r(t),setTimeout((function(){wn(),Ue(t,!0);var r=he(t);r&&wp.hooks.doAction("frm_after_field_added_in_form_builder",{field:t,fieldId:r,fieldType:e,form_id:n})}),10)},error:je})}))},confirmLinkClick:F,handleInsertFieldByDraggingResponse:ye,handleAddFieldClickResponse:Ie,syncLayoutClasses:le}}(),jQuery(document).ready((function(){var e;frmAdminBuild.init(),frmDom.bootstrap.setupBootstrapDropdowns((function(e){var t,r,n=e.querySelector(".frm-dropdown-toggle");n&&(n.hasAttribute("role")||n.setAttribute("role","button"),n.hasAttribute("tabindex")||n.setAttribute("tabindex",0)),"UL"===e.tagName&&(r=(r=(r=(r=(r=(r=(t=e).outerHTML).replace("
              ","")).replaceAll("
            • ",'
            • ",""),t.outerHTML=r)})),null===(e=document.querySelector(".preview.dropdown .frm-dropdown-toggle"))||void 0===e||e.setAttribute("data-toggle","dropdown")}))})(); \ No newline at end of file diff --git a/js/formidable_admin_global.js b/js/formidable_admin_global.js index b6bdbe88ce..5fcb4656cc 100644 --- a/js/formidable_admin_global.js +++ b/js/formidable_admin_global.js @@ -3,20 +3,20 @@ /* eslint-disable prefer-const, compat/compat */ jQuery( document ).ready( function() { - let deauthLink, submenuItem, li, + let deauthLink, submenuItem, li, installLink = document.getElementById( 'frm_install_link' ); - if ( installLink !== null ) { - jQuery( installLink ).on( 'click', frmInstallPro ); - } + if ( installLink !== null ) { + jQuery( installLink ).on( 'click', frmInstallPro ); + } deauthLink = jQuery( '.frm_deauthorize_link' ); if ( deauthLink.length ) { deauthLink.on( 'click', frmDeauthorizeNow ); } - if ( typeof tb_remove === 'function' ) { // eslint-disable-line camelcase - frmAdminPopup.init(); - } + if ( typeof tb_remove === 'function' ) { // eslint-disable-line camelcase + frmAdminPopup.init(); + } submenuItem = document.querySelector( '.frm-upgrade-submenu' ); if ( null !== submenuItem ) { @@ -25,12 +25,12 @@ jQuery( document ).ready( function() { li.classList.add( 'frm-submenu-highlight' ); } } -}); +} ); function frm_install_now() { // eslint-disable-line camelcase const $msg = jQuery( document.getElementById( 'frm_install_message' ) ); $msg.html( '
              ' + frmGlobal.updating_msg + '
              ' ); - jQuery.ajax({ + jQuery.ajax( { type: 'POST', url: ajaxurl, data: { @@ -40,7 +40,7 @@ function frm_install_now() { // eslint-disable-line camelcase success: function() { $msg.fadeOut( 'slow' ); } - }); + } ); return false; } @@ -57,7 +57,7 @@ function frmInstallPro( e ) { $msg.html( '
              ' + frmGlobal.updating_msg + '
              ' ); $msg.fadeIn( 'slow' ); - jQuery.ajax({ + jQuery.ajax( { url: ajaxurl, type: 'POST', async: true, @@ -75,38 +75,38 @@ function frmInstallPro( e ) { error: function() { $msg.fadeOut( 'slow' ); } - }); + } ); return false; } function frmDeauthorizeNow() { - if ( ! confirm( frmGlobal.deauthorize ) ) { + if ( ! confirm( frmGlobal.deauthorize ) ) { return false; - } - jQuery( this ).html( '' ); - jQuery.ajax({ - type: 'POST', + } + jQuery( this ).html( '' ); + jQuery.ajax( { + type: 'POST', url: ajaxurl, - data: { + data: { action: 'frm_deauthorize', nonce: frmGlobal.nonce }, - success: function() { + success: function() { jQuery( '.error' ).fadeOut( 'slow' ); } - }); - return false; + } ); + return false; } function frmSelectSubnav() { - const frmMenu = document.getElementById( 'toplevel_page_formidable' ); - jQuery( frmMenu ).removeClass( 'wp-not-current-submenu' ).addClass( 'wp-has-current-submenu wp-menu-open' ); - jQuery( '#toplevel_page_formidable a.wp-has-submenu' ).removeClass( 'wp-not-current-submenu' ).addClass( 'wp-has-current-submenu wp-menu-open' ); + const frmMenu = document.getElementById( 'toplevel_page_formidable' ); + jQuery( frmMenu ).removeClass( 'wp-not-current-submenu' ).addClass( 'wp-has-current-submenu wp-menu-open' ); + jQuery( '#toplevel_page_formidable a.wp-has-submenu' ).removeClass( 'wp-not-current-submenu' ).addClass( 'wp-has-current-submenu wp-menu-open' ); } function frmCreatePostEntry( id, postId ) { - jQuery( '#frm_create_entry p' ).replaceWith( '' + frmGlobal.loading + '' ); - jQuery.ajax({ + jQuery( '#frm_create_entry p' ).replaceWith( '' + frmGlobal.loading + '' ); + jQuery.ajax( { type: 'POST', url: ajaxurl, data: { @@ -118,38 +118,38 @@ function frmCreatePostEntry( id, postId ) { success: function() { jQuery( document.getElementById( 'frm_create_entry' ) ).fadeOut( 'slow' ); } - }); + } ); } function frmAdminPopupJS() { - function switchSc() { + function switchSc() { let val; - jQuery( '.frm_switch_sc' ).removeClass( 'active' ); - jQuery( this ).addClass( 'active' ); - toggleMenu(); - jQuery( '#frm_popup_content .media-frame-title h1' ).html( jQuery( this ).children( '.howto' ).text() + ' ' ); - val = this.id.replace( 'sc-link-', '' ); - populateOpts( val ); - return false; - } + jQuery( '.frm_switch_sc' ).removeClass( 'active' ); + jQuery( this ).addClass( 'active' ); + toggleMenu(); + jQuery( '#frm_popup_content .media-frame-title h1' ).html( jQuery( this ).children( '.howto' ).text() + ' ' ); + val = this.id.replace( 'sc-link-', '' ); + populateOpts( val ); + return false; + } - function populateOpts( val ) { + function populateOpts( val ) { let $settings, $scOpts, $spinner, sc = document.getElementById( 'frm_complete_shortcode' ); if ( sc !== null ) { sc.value = '[' + val + ']'; } - jQuery( '.frm_shortcode_option' ).hide(); + jQuery( '.frm_shortcode_option' ).hide(); - $settings = document.getElementById( 'sc-opts-' + val ); - if ( $settings !== null ) { - $settings.style.display = ''; - jQuery( document.getElementById( 'sc-' + val ) ).trigger( 'click' ); - } else { - $scOpts = jQuery( document.getElementById( 'frm_shortcode_options' ) ); - $spinner = jQuery( '.media-frame-title .spinner' ); - $spinner.show(); - jQuery.ajax({ + $settings = document.getElementById( 'sc-opts-' + val ); + if ( $settings !== null ) { + $settings.style.display = ''; + jQuery( document.getElementById( 'sc-' + val ) ).trigger( 'click' ); + } else { + $scOpts = jQuery( document.getElementById( 'frm_shortcode_options' ) ); + $spinner = jQuery( '.media-frame-title .spinner' ); + $spinner.show(); + jQuery.ajax( { type: 'POST', url: ajaxurl, data: { @@ -162,139 +162,139 @@ function frmAdminPopupJS() { $scOpts.append( html ); jQuery( document.getElementById( 'sc-' + val ) ).trigger( 'click' ); } - }); + } ); } } - function addToShortcode() { - const sc = jQuery( 'input[name=frmsc]:checked' ).val(); - const inputs = jQuery( document.getElementById( 'sc-opts-' + sc ) ).find( 'input, select' ); - let output = '[' + sc; - inputs.each( function() { - let attrName, attrVal, + function addToShortcode() { + const sc = jQuery( 'input[name=frmsc]:checked' ).val(); + const inputs = jQuery( document.getElementById( 'sc-opts-' + sc ) ).find( 'input, select' ); + let output = '[' + sc; + inputs.each( function() { + let attrName, attrVal, $thisInput = jQuery( this ), attrId = this.id; - if ( attrId.indexOf( 'frmsc_' ) === 0 ) { + if ( attrId.indexOf( 'frmsc_' ) === 0 ) { attrName = attrId.replace( 'frmsc_' + sc + '_', '' ); attrVal = $thisInput.val(); - if ( ( $thisInput.attr( 'type' ) === 'checkbox' && ! this.checked ) || ( ( $thisInput.attr( 'type' ) === 'text' || $thisInput.is( 'select' ) ) && attrVal === '' ) ) { - } else { - output += ' ' + attrName + '="' + attrVal + '"'; - } - } - }); - output += ']'; - document.getElementById( 'frm_complete_shortcode' ).value = output; - } + if ( ( $thisInput.attr( 'type' ) === 'checkbox' && ! this.checked ) || ( ( $thisInput.attr( 'type' ) === 'text' || $thisInput.is( 'select' ) ) && attrVal === '' ) ) { + } else { + output += ' ' + attrName + '="' + attrVal + '"'; + } + } + } ); + output += ']'; + document.getElementById( 'frm_complete_shortcode' ).value = output; + } - function insertShortcode() { - const win = window.dialogArguments || opener || parent || top; - win.send_to_editor( document.getElementById( 'frm_complete_shortcode' ).value ); - } + function insertShortcode() { + const win = window.dialogArguments || opener || parent || top; + win.send_to_editor( document.getElementById( 'frm_complete_shortcode' ).value ); + } - function getFieldSelection() { + function getFieldSelection() { let thisId, formId = this.value; - if ( formId ) { - thisId = this.id; - jQuery.ajax({ + if ( formId ) { + thisId = this.id; + jQuery.ajax( { type: 'POST', url: ajaxurl, - data: { + data: { action: 'frm_get_field_selection', field_id: 0, form_id: formId, nonce: frmGlobal.nonce }, - success: function( msg ) { - const baseId = thisId.replace( '_form', '' ); - msg = msg.replace( 'name="field_options[form_select_0]"', 'id="frmsc_' + baseId + '_fields"' ); - jQuery( document.getElementById( baseId + '_fields_container' ) ).html( msg ); - } - }); - } - } + success: function( msg ) { + const baseId = thisId.replace( '_form', '' ); + msg = msg.replace( 'name="field_options[form_select_0]"', 'id="frmsc_' + baseId + '_fields"' ); + jQuery( document.getElementById( baseId + '_fields_container' ) ).html( msg ); + } + } ); + } + } function toggleMenu() { jQuery( document.getElementById( 'frm_popup_content' ) ).find( '.media-menu' ).toggleClass( 'visible' ); } - return { - init: function() { + return { + init: function() { let $scOptsDiv; - jQuery( '.frm_switch_sc' ).on( 'click', switchSc ); - jQuery( '.button.frm_insert_form' ).on( 'click', function() { - populateOpts( 'formidable' ); - }); - jQuery( document.getElementById( 'frm_insert_shortcode' ) ).on( 'click', insertShortcode ); + jQuery( '.frm_switch_sc' ).on( 'click', switchSc ); + jQuery( '.button.frm_insert_form' ).on( 'click', function() { + populateOpts( 'formidable' ); + } ); + jQuery( document.getElementById( 'frm_insert_shortcode' ) ).on( 'click', insertShortcode ); $scOptsDiv = jQuery( document.getElementById( 'frm_shortcode_options' ) ); - $scOptsDiv.on( 'change', 'select, input', addToShortcode ); - $scOptsDiv.on( 'change', '.frm_get_field_selection', getFieldSelection ); + $scOptsDiv.on( 'change', 'select, input', addToShortcode ); + $scOptsDiv.on( 'change', '.frm_get_field_selection', getFieldSelection ); - jQuery( '#frm_popup_content .media-modal-close' ).on( 'click', tb_remove ); - jQuery( '#frm_popup_content .media-frame-title h1' ).on( 'click', toggleMenu ); - } - }; + jQuery( '#frm_popup_content .media-modal-close' ).on( 'click', tb_remove ); + jQuery( '#frm_popup_content .media-frame-title h1' ).on( 'click', toggleMenu ); + } + }; } window.frmAdminPopup = frmAdminPopupJS(); function frmWidgetsJS() { - function toggleCatOpt() { - const catOpts = jQuery( this ).closest( '.widget-content' ).children( '.frm_list_items_hide_cat_opts' ); - if ( this.checked ) { - catOpts.fadeIn(); - } else { - catOpts.fadeOut(); - } - } + function toggleCatOpt() { + const catOpts = jQuery( this ).closest( '.widget-content' ).children( '.frm_list_items_hide_cat_opts' ); + if ( this.checked ) { + catOpts.fadeIn(); + } else { + catOpts.fadeOut(); + } + } - function getFields() { + function getFields() { let widget, displayId = this.value; - if ( displayId !== '' ) { + if ( displayId !== '' ) { widget = jQuery( this ).closest( '.widget-content' ); - jQuery.ajax({ - type: 'POST', + jQuery.ajax( { + type: 'POST', url: ajaxurl, - dataType: 'json', - data: { + dataType: 'json', + data: { action: 'frm_get_dynamic_widget_opts', display_id: displayId, nonce: frmGlobal.nonce }, - success: function( opts ) { + success: function( opts ) { let titleField, catField = widget.find( '.frm_list_items_cat_id' ); - catField.find( 'option' ).remove().end(); - catField.append( jQuery( '' ) ); - jQuery.each( opts.catValues, function( key, value ) { - catField.append( jQuery( '' ).attr( 'value', key ).text( value ) ); - }); + catField.find( 'option' ).remove().end(); + catField.append( jQuery( '' ) ); + jQuery.each( opts.catValues, function( key, value ) { + catField.append( jQuery( '' ).attr( 'value', key ).text( value ) ); + } ); titleField = widget.find( '.frm_list_items_title_id' ); - titleField.find( 'option' ).remove().end(); - titleField.append( jQuery( '' ) ); - jQuery.each( opts.titleValues, function( key, value ) { - titleField.append( jQuery( '' ).attr( 'value', key ).text( value ) ); - }); - } - }); - } - } + titleField.find( 'option' ).remove().end(); + titleField.append( jQuery( '' ) ); + jQuery.each( opts.titleValues, function( key, value ) { + titleField.append( jQuery( '' ).attr( 'value', key ).text( value ) ); + } ); + } + } ); + } + } - return { - init: function() { - jQuery( document ).on( 'click', '.frm_list_items_cat_list', toggleCatOpt ); - jQuery( document ).on( 'change', '.frm_list_items_display_id', getFields ); - } - }; + return { + init: function() { + jQuery( document ).on( 'click', '.frm_list_items_cat_list', toggleCatOpt ); + jQuery( document ).on( 'change', '.frm_list_items_display_id', getFields ); + } + }; } if ( typeof adminpage !== 'undefined' && adminpage === 'widgets-php' ) { - window.frmWidgets = frmWidgetsJS(); - window.frmWidgets.init(); + window.frmWidgets = frmWidgetsJS(); + window.frmWidgets.init(); } diff --git a/js/formidable_blocks.js b/js/formidable_blocks.js index 109b0a29f0..954846e136 100644 --- a/js/formidable_blocks.js +++ b/js/formidable_blocks.js @@ -1 +1 @@ -!function(){var e={532:function(e,t,r){"use strict";var n=r(601),o=r.n(n),i=r(314),a=r.n(i)()(o());a.push([e.id,"button.t3RQZV1ZQbHGYyQUnhIY {\n\tcursor: progress;\n\topacity: 0.7;\n\tposition: relative;\n\ttext-indent: -999px;\n\tmin-width: 70px;\n\toverflow: hidden;\n}\nbutton.t3RQZV1ZQbHGYyQUnhIY:before {\n\tcontent: '';\n\tdisplay: inline-block;\n\tposition: absolute;\n\tbackground: transparent;\n\tborder: 1px solid #fff;\n\tborder-top-color: transparent;\n\tborder-left-color: transparent;\n\tborder-radius: 50%;\n\n\tbox-sizing: border-box;\n\ttop: 50%;\n\tleft: 50%;\n\tmargin-top: -10px;\n\tmargin-left: -10px;\n\twidth: 20px;\n\theight: 20px;\n\n\tanimation: Ts7haRQUDk0YMfLiQW00 2s linear infinite;\n}",""]),t.Ay=a},314:function(e){"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var r="",n=void 0!==t[5];return t[4]&&(r+="@supports (".concat(t[4],") {")),t[2]&&(r+="@media ".concat(t[2]," {")),n&&(r+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),r+=e(t),n&&(r+="}"),t[2]&&(r+="}"),t[4]&&(r+="}"),r})).join("")},t.i=function(e,r,n,o,i){"string"==typeof e&&(e=[[null,e,void 0]]);var a={};if(n)for(var l=0;l0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=i),r&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=r):u[2]=r),o&&(u[4]?(u[1]="@supports (".concat(u[4],") {").concat(u[1],"}"),u[4]=o):u[4]="".concat(o)),t.push(u))}},t}},601:function(e){"use strict";e.exports=function(e){return e[1]}},694:function(e,t,r){"use strict";var n=r(925);function o(){}function i(){}i.resetWarningCache=o,e.exports=function(){function e(e,t,r,o,i,a){if(a!==n){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}function t(){return e}e.isRequired=e;var r={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:i,resetWarningCache:o};return r.PropTypes=r,r}},556:function(e,t,r){e.exports=r(694)()},925:function(e){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},72:function(e){"use strict";var t=[];function r(e){for(var r=-1,n=0;n0?" ".concat(r.layer):""," {")),n+=r.css,o&&(n+="}"),r.media&&(n+="}"),r.supports&&(n+="}");var i=r.sourceMap;i&&"undefined"!=typeof btoa&&(n+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(i))))," */")),t.styleTagTransform(n,e,t.options)}(t,e,r)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},113:function(e){"use strict";e.exports=function(e,t){if(t.styleSheet)t.styleSheet.cssText=e;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(e))}}}},t={};function r(n){var o=t[n];if(void 0!==o)return o.exports;var i=t[n]={id:n,exports:{}};return e[n](i,i.exports,r),i.exports}r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,{a:t}),t},r.d=function(e,t){for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.nc=void 0,function(){"use strict";function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e(t)}function t(t,r,n){var o,i,a;n((o={},a=r,(i=function(t){var r=function(t){if("object"!=e(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,"string");if("object"!=e(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==e(r)?r:r+""}(i=t))in o?Object.defineProperty(o,i,{value:a,enumerable:!0,configurable:!0,writable:!0}):o[i]=a,o))}function n(e,t){return e?" ".concat(t,'="').concat(e,'"'):""}function o(e){return o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},o(e)}function i(e,t){for(var r=0;re.length)&&(t=e.length);for(var r=0,n=Array(t);r-1&&(n=e.substr(0,r)),n+"wp-admin/admin.php?page=formidable&frm_action=edit&id=".concat(c))},V("Go to form","formidable")))),wp.element.createElement(W,{title:V("Options","formidable"),initialOpen:!1},wp.element.createElement(Y,{label:V("Show Form Title","formidable"),checked:s,onChange:function(e){t("title",e?"1":"",i)}}),wp.element.createElement(Y,{label:V("Show Form Description","formidable"),checked:f,onChange:function(e){t("description",e?"1":"",i)}}),wp.element.createElement(Y,{label:V("Minimize HTML","formidable"),checked:m,onChange:function(e){t("minimize",e?"1":"",i)}})),wp.element.createElement(W,{title:V("Shortcode","formidable"),initialOpen:!1},wp.element.createElement(Q,null,wp.element.createElement(u,this.props.attributes))))}}])&&z(n.prototype,o),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,o}(B);function q(e){return q="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},q(e)}function $(e,t){for(var r=0;re.length)&&(t=e.length);for(var r=0,n=Array(t);r{var e={532:(e,t,r)=>{"use strict";r.d(t,{Ay:()=>l});var n=r(601),o=r.n(n),i=r(314),a=r.n(i)()(o());a.push([e.id,"button.t3RQZV1ZQbHGYyQUnhIY {\n\tcursor: progress;\n\topacity: 0.7;\n\tposition: relative;\n\ttext-indent: -999px;\n\tmin-width: 70px;\n\toverflow: hidden;\n}\nbutton.t3RQZV1ZQbHGYyQUnhIY:before {\n\tcontent: '';\n\tdisplay: inline-block;\n\tposition: absolute;\n\tbackground: transparent;\n\tborder: 1px solid #fff;\n\tborder-top-color: transparent;\n\tborder-left-color: transparent;\n\tborder-radius: 50%;\n\n\tbox-sizing: border-box;\n\ttop: 50%;\n\tleft: 50%;\n\tmargin-top: -10px;\n\tmargin-left: -10px;\n\twidth: 20px;\n\theight: 20px;\n\n\tanimation: Ts7haRQUDk0YMfLiQW00 2s linear infinite;\n}",""]);const l=a},314:e=>{"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var r="",n=void 0!==t[5];return t[4]&&(r+="@supports (".concat(t[4],") {")),t[2]&&(r+="@media ".concat(t[2]," {")),n&&(r+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),r+=e(t),n&&(r+="}"),t[2]&&(r+="}"),t[4]&&(r+="}"),r})).join("")},t.i=function(e,r,n,o,i){"string"==typeof e&&(e=[[null,e,void 0]]);var a={};if(n)for(var l=0;l0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=i),r&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=r):u[2]=r),o&&(u[4]?(u[1]="@supports (".concat(u[4],") {").concat(u[1],"}"),u[4]=o):u[4]="".concat(o)),t.push(u))}},t}},601:e=>{"use strict";e.exports=function(e){return e[1]}},694:(e,t,r)=>{"use strict";var n=r(925);function o(){}function i(){}i.resetWarningCache=o,e.exports=function(){function e(e,t,r,o,i,a){if(a!==n){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}function t(){return e}e.isRequired=e;var r={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:i,resetWarningCache:o};return r.PropTypes=r,r}},556:(e,t,r)=>{e.exports=r(694)()},925:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},72:e=>{"use strict";var t=[];function r(e){for(var r=-1,n=0;n{"use strict";var t={};e.exports=function(e,r){var n=function(e){if(void 0===t[e]){var r=document.querySelector(e);if(window.HTMLIFrameElement&&r instanceof window.HTMLIFrameElement)try{r=r.contentDocument.head}catch(e){r=null}t[e]=r}return t[e]}(e);if(!n)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");n.appendChild(r)}},540:e=>{"use strict";e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},56:(e,t,r)=>{"use strict";e.exports=function(e){var t=r.nc;t&&e.setAttribute("nonce",t)}},825:e=>{"use strict";e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(r){!function(e,t,r){var n="";r.supports&&(n+="@supports (".concat(r.supports,") {")),r.media&&(n+="@media ".concat(r.media," {"));var o=void 0!==r.layer;o&&(n+="@layer".concat(r.layer.length>0?" ".concat(r.layer):""," {")),n+=r.css,o&&(n+="}"),r.media&&(n+="}"),r.supports&&(n+="}");var i=r.sourceMap;i&&"undefined"!=typeof btoa&&(n+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(i))))," */")),t.styleTagTransform(n,e,t.options)}(t,e,r)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},113:e=>{"use strict";e.exports=function(e,t){if(t.styleSheet)t.styleSheet.cssText=e;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(e))}}}},t={};function r(n){var o=t[n];if(void 0!==o)return o.exports;var i=t[n]={id:n,exports:{}};return e[n](i,i.exports,r),i.exports}r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.nc=void 0,(()=>{"use strict";function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e(t)}function t(t,r,n){var o,i,a;n((o={},a=r,(i=function(t){var r=function(t){if("object"!=e(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,"string");if("object"!=e(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==e(r)?r:r+""}(i=t))in o?Object.defineProperty(o,i,{value:a,enumerable:!0,configurable:!0,writable:!0}):o[i]=a,o))}function n(e,t){return e?" ".concat(t,'="').concat(e,'"'):""}function o(e){return o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},o(e)}function i(e,t){for(var r=0;re.length)&&(t=e.length);for(var r=0,n=Array(t);r-1&&(n=e.substr(0,r)),n+"wp-admin/admin.php?page=formidable&frm_action=edit&id=".concat(c))},V("Go to form","formidable")))),wp.element.createElement(W,{title:V("Options","formidable"),initialOpen:!1},wp.element.createElement(Y,{label:V("Show Form Title","formidable"),checked:s,onChange:function(e){t("title",e?"1":"",i)}}),wp.element.createElement(Y,{label:V("Show Form Description","formidable"),checked:m,onChange:function(e){t("description",e?"1":"",i)}}),wp.element.createElement(Y,{label:V("Minimize HTML","formidable"),checked:f,onChange:function(e){t("minimize",e?"1":"",i)}})),wp.element.createElement(W,{title:V("Shortcode","formidable"),initialOpen:!1},wp.element.createElement(Q,null,wp.element.createElement(u,this.props.attributes))))}}])&&z(n.prototype,o),Object.defineProperty(n,"prototype",{writable:!1}),n;var n,o}(B);function q(e){return q="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},q(e)}function $(e,t){for(var r=0;re.length)&&(t=e.length);for(var r=0,n=Array(t);r1&&void 0!==arguments[1]?arguments[1]:"default";!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.elements=t,this.type=n,this.prepareElements()},n=[{key:"fadeIn",value:function(){var e=this;this.applyStyleToElements((function(t){t.classList.add("frm-fadein-up"),t.addEventListener("animationend",(function(){e.resetOpacity(),t.classList.remove("frm-fadein-up")}),{once:!0})}))}},{key:"cascadeFadeIn",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.03;setTimeout((function(){e.applyStyleToElements((function(e,n){e.classList.remove("frm-animate"),e.style.transitionDelay=(n+1)*t+"s"}))}),200)}},{key:"prepareElements",value:function(){var e=this;this.applyStyleToElements((function(t){"default"===e.type&&(t.style.opacity="0.0"),"cascade"===e.type&&t.classList.add("frm-init-cascade-animation"),"cascade-3d"===e.type&&t.classList.add("frm-init-fadein-3d"),t.classList.add("frm-animate")}))}},{key:"resetOpacity",value:function(){this.applyStyleToElements((function(e){return e.style.opacity="1.0"}))}},{key:"applyStyleToElements",value:function(e){this.elements instanceof Element?e(this.elements,0):0 li"),this.slideTrackLine=this.wrapper.querySelector(".frm-tabs-active-underline"),this.slideTrack=this.wrapper.querySelector(".frm-tabs-slide-track"),this.slides=this.wrapper.querySelectorAll(".frm-tabs-slide-track > div"),this.init()))},(t=[{key:"init",value:function(){var e=this;null!==this.wrapper&&this.navs.length&&null!==this.trackLine&&null!==this.slideTrack&&this.slides.length&&(this.initDefaultSlideTrackerWidth(),this.navs.forEach((function(t,n){t.addEventListener("click",(function(t){return e.onNavClick(t,n)}))})))}},{key:"onNavClick",value:function(e,t){this.removeActiveClassnameFromNavs(),e.target.classList.add("frm-active"),this.initSlideTrackUnderline(e.target,t),this.changeSlide(t)}},{key:"initDefaultSlideTrackerWidth",value:function(){this.slideTrackLine.dataset.initialWidth&&(this.slideTrackLine.style.width="".concat(this.slideTrackLine.dataset.initialWidth,"px"))}},{key:"initSlideTrackUnderline",value:function(e,t){this.slideTrackLine.classList.remove("frm-first","frm-last");var n=void 0!==e?e:this.navs.filter((function(e){return e.classList.contains("frm-active")}));this.slideTrackLine.style.transform="translateX(".concat(n.offsetLeft,"px)"),this.slideTrackLine.style.width=n.clientWidth+"px",this.navs.length!==t+1?0===t&&this.slideTrackLine.classList.add("frm-first"):this.slideTrackLine.classList.add("frm-last")}},{key:"changeSlide",value:function(e){this.removeActiveClassnameFromSlides();var t=0==e?"0px":"calc( ( ".concat(100*e,"% + ").concat(parseInt(this.flexboxSlidesGap,10)*e,"px ) * -1 )");this.slideTrack.style.transform="translateX(".concat(t,")"),e in this.slides&&this.slides[e].classList.add("frm-active")}},{key:"removeActiveClassnameFromSlides",value:function(){this.slides.forEach((function(e){return e.classList.remove("frm-active")}))}},{key:"removeActiveClassnameFromNavs",value:function(){this.navs.forEach((function(e){return e.classList.remove("frm-active")}))}}])&&o(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();function c(e){return c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},c(e)}function u(e,t){for(var n=0;n{"use strict";function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e(t)}function t(e,t){for(var i=0;i1&&void 0!==arguments[1]?arguments[1]:"default";!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.elements=t,this.type=n,this.prepareElements()},n=[{key:"fadeIn",value:function(){var e=this;this.applyStyleToElements((function(t){t.classList.add("frm-fadein-up"),t.addEventListener("animationend",(function(){e.resetOpacity(),t.classList.remove("frm-fadein-up")}),{once:!0})}))}},{key:"cascadeFadeIn",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.03;setTimeout((function(){e.applyStyleToElements((function(e,n){e.classList.remove("frm-animate"),e.style.transitionDelay=(n+1)*t+"s"}))}),200)}},{key:"prepareElements",value:function(){var e=this;this.applyStyleToElements((function(t){"default"===e.type&&(t.style.opacity="0.0"),"cascade"===e.type&&t.classList.add("frm-init-cascade-animation"),"cascade-3d"===e.type&&t.classList.add("frm-init-fadein-3d"),t.classList.add("frm-animate")}))}},{key:"resetOpacity",value:function(){this.applyStyleToElements((function(e){return e.style.opacity="1.0"}))}},{key:"applyStyleToElements",value:function(e){this.elements instanceof Element?e(this.elements,0):0 li"),this.slideTrackLine=this.wrapper.querySelector(".frm-tabs-active-underline"),this.slideTrack=this.wrapper.querySelector(".frm-tabs-slide-track"),this.slides=this.wrapper.querySelectorAll(".frm-tabs-slide-track > div"),this.init()))},(t=[{key:"init",value:function(){var e=this;null!==this.wrapper&&this.navs.length&&null!==this.trackLine&&null!==this.slideTrack&&this.slides.length&&(this.initDefaultSlideTrackerWidth(),this.navs.forEach((function(t,n){t.addEventListener("click",(function(t){return e.onNavClick(t,n)}))})))}},{key:"onNavClick",value:function(e,t){this.removeActiveClassnameFromNavs(),e.target.classList.add("frm-active"),this.initSlideTrackUnderline(e.target,t),this.changeSlide(t)}},{key:"initDefaultSlideTrackerWidth",value:function(){this.slideTrackLine.dataset.initialWidth&&(this.slideTrackLine.style.width="".concat(this.slideTrackLine.dataset.initialWidth,"px"))}},{key:"initSlideTrackUnderline",value:function(e,t){this.slideTrackLine.classList.remove("frm-first","frm-last");var n=void 0!==e?e:this.navs.filter((function(e){return e.classList.contains("frm-active")}));this.slideTrackLine.style.transform="translateX(".concat(n.offsetLeft,"px)"),this.slideTrackLine.style.width=n.clientWidth+"px",this.navs.length!==t+1?0===t&&this.slideTrackLine.classList.add("frm-first"):this.slideTrackLine.classList.add("frm-last")}},{key:"changeSlide",value:function(e){this.removeActiveClassnameFromSlides();var t=0==e?"0px":"calc( ( ".concat(100*e,"% + ").concat(parseInt(this.flexboxSlidesGap,10)*e,"px ) * -1 )");this.slideTrack.style.transform="translateX(".concat(t,")"),e in this.slides&&this.slides[e].classList.add("frm-active")}},{key:"removeActiveClassnameFromSlides",value:function(){this.slides.forEach((function(e){return e.classList.remove("frm-active")}))}},{key:"removeActiveClassnameFromNavs",value:function(){this.navs.forEach((function(e){return e.classList.remove("frm-active")}))}}])&&o(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();function c(e){return c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},c(e)}function u(e,t){for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:"default";!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.elements=t,this.type=r,this.prepareElements()},r=[{key:"fadeIn",value:function(){var e=this;this.applyStyleToElements((function(t){t.classList.add("frm-fadein-up"),t.addEventListener("animationend",(function(){e.resetOpacity(),t.classList.remove("frm-fadein-up")}),{once:!0})}))}},{key:"cascadeFadeIn",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.03;setTimeout((function(){e.applyStyleToElements((function(e,r){e.classList.remove("frm-animate"),e.style.transitionDelay=(r+1)*t+"s"}))}),200)}},{key:"prepareElements",value:function(){var e=this;this.applyStyleToElements((function(t){"default"===e.type&&(t.style.opacity="0.0"),"cascade"===e.type&&t.classList.add("frm-init-cascade-animation"),"cascade-3d"===e.type&&t.classList.add("frm-init-fadein-3d"),t.classList.add("frm-animate")}))}},{key:"resetOpacity",value:function(){this.applyStyleToElements((function(e){return e.style.opacity="1.0"}))}},{key:"applyStyleToElements",value:function(e){this.elements instanceof Element?e(this.elements,0):0{"use strict";function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e(t)}function t(e,t){for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:"default";!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.elements=t,this.type=r,this.prepareElements()},r=[{key:"fadeIn",value:function(){var e=this;this.applyStyleToElements((function(t){t.classList.add("frm-fadein-up"),t.addEventListener("animationend",(function(){e.resetOpacity(),t.classList.remove("frm-fadein-up")}),{once:!0})}))}},{key:"cascadeFadeIn",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.03;setTimeout((function(){e.applyStyleToElements((function(e,r){e.classList.remove("frm-animate"),e.style.transitionDelay=(r+1)*t+"s"}))}),200)}},{key:"prepareElements",value:function(){var e=this;this.applyStyleToElements((function(t){"default"===e.type&&(t.style.opacity="0.0"),"cascade"===e.type&&t.classList.add("frm-init-cascade-animation"),"cascade-3d"===e.type&&t.classList.add("frm-init-fadein-3d"),t.classList.add("frm-animate")}))}},{key:"resetOpacity",value:function(){this.applyStyleToElements((function(e){return e.style.opacity="1.0"}))}},{key:"applyStyleToElements",value:function(e){this.elements instanceof Element?e(this.elements,0):0=0),s.type){case"b":n=parseInt(n,10).toString(2);break;case"c":n=String.fromCharCode(parseInt(n,10));break;case"d":case"i":n=parseInt(n,10);break;case"j":n=JSON.stringify(n,null,s.width?parseInt(s.width):0);break;case"e":n=s.precision?parseFloat(n).toExponential(s.precision):parseFloat(n).toExponential();break;case"f":n=s.precision?parseFloat(n).toFixed(s.precision):parseFloat(n);break;case"g":n=s.precision?String(Number(n.toPrecision(s.precision))):parseFloat(n);break;case"o":n=(parseInt(n,10)>>>0).toString(8);break;case"s":n=String(n),n=s.precision?n.substring(0,s.precision):n;break;case"t":n=String(!!n),n=s.precision?n.substring(0,s.precision):n;break;case"T":n=Object.prototype.toString.call(n).slice(8,-1).toLowerCase(),n=s.precision?n.substring(0,s.precision):n;break;case"u":n=parseInt(n,10)>>>0;break;case"v":n=n.valueOf(),n=s.precision?n.substring(0,s.precision):n;break;case"x":n=(parseInt(n,10)>>>0).toString(16);break;case"X":n=(parseInt(n,10)>>>0).toString(16).toUpperCase()}i.json.test(s.type)?v+=n:(!i.number.test(s.type)||f&&!s.sign?d="":(d=f?"+":"-",n=n.toString().replace(i.sign,"")),c=s.pad_char?"0"===s.pad_char?"0":s.pad_char.charAt(1):" ",u=s.width-(d+n).length,l=s.width&&u>0?c.repeat(u):"",v+=s.align?d+n+l:"0"===c?d+l+n:l+d+n)}return v}(function(e){if(s[e])return s[e];for(var t,n=e,r=[],o=0;n;){if(null!==(t=i.text.exec(n)))r.push(t[0]);else if(null!==(t=i.modulo.exec(n)))r.push("%");else{if(null===(t=i.placeholder.exec(n)))throw new SyntaxError("[sprintf] unexpected placeholder");if(t[2]){o|=1;var a=[],l=t[2],c=[];if(null===(c=i.key.exec(l)))throw new SyntaxError("[sprintf] failed to parse named argument key");for(a.push(c[1]);""!==(l=l.substring(c[0].length));)if(null!==(c=i.key_access.exec(l)))a.push(c[1]);else{if(null===(c=i.index_access.exec(l)))throw new SyntaxError("[sprintf] failed to parse named argument key");a.push(c[1])}t[2]=a}else o|=2;if(3===o)throw new Error("[sprintf] mixing positional and named placeholders is not (yet) supported");r.push({placeholder:t[0],param_no:t[1],keys:t[2],sign:t[3],pad_char:t[4],align:t[5],width:t[6],precision:t[7],type:t[8]})}n=n.substring(t[0].length)}return s[e]=r}(e),arguments)}function a(e,t){return o.apply(null,[e].concat(t||[]))}var s=Object.create(null);"undefined"!=typeof window&&(window.sprintf=o,window.vsprintf=a,void 0===(r=function(){return{sprintf:o,vsprintf:a}}.call(t,n,t,e))||(e.exports=r))}()}},t={};function n(r){var i=t[r];if(void 0!==i)return i.exports;var o=t[r]={exports:{}};return e[r](o,o.exports,n),o.exports}n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,{a:t}),t},n.d=function(e,t){for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},function(){"use strict";var e,t,r,i,o=n(616),a=n.n(o);function s(e){return s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s(e)}function l(e){var t=function(e){if("object"!=s(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=s(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==s(t)?t:t+""}n(604),a()(console.error),e={"(":9,"!":8,"*":7,"/":7,"%":7,"+":6,"-":6,"<":5,"<=":5,">":5,">=":5,"==":4,"!=":4,"&&":3,"||":2,"?":1,"?:":1},t=["(","?"],r={")":["("],":":["?","?:"]},i=/<=|>=|==|!=|&&|\|\||\?:|\(|!|\*|\/|%|\+|-|<|>|\?|\)|:/;var c={"!":function(e){return!e},"*":function(e,t){return e*t},"/":function(e,t){return e/t},"%":function(e,t){return e%t},"+":function(e,t){return e+t},"-":function(e,t){return e-t},"<":function(e,t){return e":function(e,t){return e>t},">=":function(e,t){return e>=t},"==":function(e,t){return e===t},"!=":function(e,t){return e!==t},"&&":function(e,t){return e&&t},"||":function(e,t){return e||t},"?:":function(e,t,n){if(e)throw t;return n}};var u={contextDelimiter:"",onMissingKey:null};function f(e,t){var n;for(n in this.data=e,this.pluralForms={},this.options={},u)this.options[n]=void 0!==t&&n in t?t[n]:u[n]}function d(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function p(e){for(var t=1;t=0||e[l]3&&void 0!==arguments[3]?arguments[3]:10,a=e[t];if(y(n)&&m(r))if("function"==typeof i)if("number"==typeof o){var s={callback:i,priority:o,namespace:r};if(a[n]){var l,c=a[n].handlers;for(l=c.length;l>0&&!(o>=c[l-1].priority);l--);l===c.length?c[l]=s:c.splice(l,0,s),a.__current.forEach((function(e){e.name===n&&e.currentIndex>=l&&e.currentIndex++}))}else a[n]={handlers:[s],runs:0};"hookAdded"!==n&&e.doAction("hookAdded",n,r,i,o)}else console.error("If specified, the hook priority must be a number.");else console.error("The hook callback must be a function.")}},b=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(r,i){var o=e[t];if(y(r)&&(n||m(i))){if(!o[r])return 0;var a=0;if(n)a=o[r].handlers.length,o[r]={runs:o[r].runs,handlers:[]};else for(var s=o[r].handlers,l=function(e){s[e].namespace===i&&(s.splice(e,1),a++,o.__current.forEach((function(t){t.name===r&&t.currentIndex>=e&&t.currentIndex--})))},c=s.length-1;c>=0;c--)l(c);return"hookRemoved"!==r&&e.doAction("hookRemoved",r,i),a}}},S=function(e,t){return function(n,r){var i=e[t];return void 0!==r?n in i&&i[n].handlers.some((function(e){return e.namespace===r})):n in i}},k=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(r){var i=e[t];i[r]||(i[r]={handlers:[],runs:0}),i[r].runs++;for(var o=i[r].handlers,a=arguments.length,s=new Array(a>1?a-1:0),l=1;l1&&void 0!==arguments[1]?arguments[1]:"default";r.data[t]=p(p(p({},h),r.data[t]),e),r.data[t][""]=p(p({},h[""]),r.data[t][""])},s=function(e,t){a(e,t),o()},l=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default",t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0,i=arguments.length>3?arguments[3]:void 0,o=arguments.length>4?arguments[4]:void 0;return r.data[e]||a(void 0,e),r.dcnpgettext(e,t,n,i,o)},c=function(){return arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default"},u=function(e,t,r){var i=l(r,t,e);return n?(i=n.applyFilters("i18n.gettext_with_context",i,e,t,r),n.applyFilters("i18n.gettext_with_context_"+c(r),i,e,t,r)):i};if(n){var d=function(e){v.test(e)&&o()};n.addAction("hookAdded","core/i18n",d),n.addAction("hookRemoved","core/i18n",d)}return{getLocaleData:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default";return r.data[e]},setLocaleData:s,resetLocaleData:function(e,t){r.data={},r.pluralForms={},s(e,t)},subscribe:function(e){return i.add(e),function(){return i.delete(e)}},__:function(e,t){var r=l(t,void 0,e);return n?(r=n.applyFilters("i18n.gettext",r,e,t),n.applyFilters("i18n.gettext_"+c(t),r,e,t)):r},_x:u,_n:function(e,t,r,i){var o=l(i,void 0,e,t,r);return n?(o=n.applyFilters("i18n.ngettext",o,e,t,r,i),n.applyFilters("i18n.ngettext_"+c(i),o,e,t,r,i)):o},_nx:function(e,t,r,i,o){var a=l(o,i,e,t,r);return n?(a=n.applyFilters("i18n.ngettext_with_context",a,e,t,r,i,o),n.applyFilters("i18n.ngettext_with_context_"+c(o),a,e,t,r,i,o)):a},isRTL:function(){return"rtl"===u("ltr","text direction")},hasTranslation:function(e,t,i){var o,a,s=t?t+""+e:e,l=!(null===(o=r.data)||void 0===o||null===(a=o[null!=i?i:"default"])||void 0===a||!a[s]);return n&&(l=n.applyFilters("i18n.has_translation",l,e,t,i),l=n.applyFilters("i18n.has_translation_"+c(i),l,e,t,i)),l}}}(0,0,E)),A=(L.getLocaleData.bind(L),L.setLocaleData.bind(L),L.resetLocaleData.bind(L),L.subscribe.bind(L),L.__.bind(L));L._x.bind(L),L._n.bind(L),L._nx.bind(L),L.isRTL.bind(L),L.hasTranslation.bind(L),Promise.resolve(),window.frmDom.util.onClickPreventDefault;var C=(new URL(window.location.href).searchParams,window.frmGlobal),T=(C.url,C.nonce,"frm_hidden");function q(e){return q="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},q(e)}function P(e,t){for(var n=0;n=i)){var o=r.querySelector("select").value,a=this.calculateValue(i,n,this.getMaxValue(o,t));r.querySelector('.frm-slider-value input[type="text"]').value=a,r.querySelector(".frm-slider-bullet .frm-slider-value-label").innerText=a,r.querySelector(".frm-slider-active-track").style.width="".concat(n,"px"),this.initChildSlidersWidth(r,n,t,a+o),this.options[t].translateX=n,this.options[t].value=a+o,this.options[t].fullValue=this.updateValue(r,this.options[t].value),this.valueChangeDebouncer(t)}}}},{key:"getMaxValue",value:function(e,t){return"%"===e?100:this.options[t].maxValue}},{key:"enableDragging",value:function(e,t){e.target.classList.add("frm-dragging"),this.options[t].dragging=!0,this.options[t].startX=e.clientX-this.options[t].translateX}},{key:"disableDragging",value:function(e,t){!1!==this.options[e].dragging&&(t.target.classList.remove("frm-dragging"),this.options[e].dragging=!1,this.triggerValueChange(e))}},{key:"triggerValueChange",value:function(e){var t=this;if(null===this.options[e].dependentUpdater){var n=this.sliderElements[e].classList.contains("frm-has-multiple-values")?this.sliderElements[e].closest(".frm-style-component").querySelector('input[type="hidden"]'):this.sliderElements[e].querySelectorAll('.frm-slider-value input[type="hidden"]');n instanceof NodeList?n.forEach((function(n){n.dispatchEvent(t.eventsChange[e])})):n.dispatchEvent(this.eventsChange[e])}else this.options[e].dependentUpdater.updateAllDependentElements(this.options[e].fullValue)}},{key:"calculateValue",value:function(e,t,n){var r=Math.ceil(this.sliderBulletWidth*(t/e)),i=Math.ceil((t+r)/e*n);return Math.min(i,n)}},{key:"updateValue",value:function(e,t){var n=this;if(e.classList.contains("frm-base-font-size")){var r=document.querySelector('input[name="frm_style_setting[post_content][use_base_font_size]"]');null!==r&&(r.value="true")}if(e.classList.contains("frm-has-multiple-values")){var i=e.closest(".frm-style-component").querySelector('input[type="hidden"]'),o=i.value.split(" "),a=e.dataset.type;switch(o[2]||(o[2]="0px"),o[3]||(o[3]="0px"),a){case"vertical":o[0]=t,o[2]=t;break;case"horizontal":o[1]=t,o[3]=t;break;case"top":o[0]=t;break;case"bottom":o[2]=t;break;case"left":o[3]=t;break;case"right":o[1]=t}var s=o.join(" ");return i.value=s,this.getSliderGroupItems(e).forEach((function(e){var r=n.getUnitMeasureFromValue(t);e.querySelector('.frm-slider-value input[type="text"]').value=parseInt(t,10),e.querySelector("select").value=r})),s}if(e.classList.contains("frm-has-independent-fields")){var l=e.querySelectorAll('.frm-slider-value input[type="hidden"]'),c=e.querySelectorAll('.frm-slider-value input[type="text"]');return l.forEach((function(e,n){e.value=t,c[n+1].value=parseInt(t,10)})),t}return e.querySelector('.frm-slider-value input[type="hidden"]').value=t,t}},{key:"getUnitMeasureFromValue",value:function(e){return["%","px","em"].find((function(t){return e.includes(t)}))||""}}])&&M(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();function U(e){return U="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},U(e)}function z(e,t){for(var n=0;n li"),this.slideTrackLine=this.wrapper.querySelector(".frm-tabs-active-underline"),this.slideTrack=this.wrapper.querySelector(".frm-tabs-slide-track"),this.slides=this.wrapper.querySelectorAll(".frm-tabs-slide-track > div"),this.init()))},(t=[{key:"init",value:function(){var e=this;null!==this.wrapper&&this.navs.length&&null!==this.trackLine&&null!==this.slideTrack&&this.slides.length&&(this.initDefaultSlideTrackerWidth(),this.navs.forEach((function(t,n){t.addEventListener("click",(function(t){return e.onNavClick(t,n)}))})))}},{key:"onNavClick",value:function(e,t){this.removeActiveClassnameFromNavs(),e.target.classList.add("frm-active"),this.initSlideTrackUnderline(e.target,t),this.changeSlide(t)}},{key:"initDefaultSlideTrackerWidth",value:function(){this.slideTrackLine.dataset.initialWidth&&(this.slideTrackLine.style.width="".concat(this.slideTrackLine.dataset.initialWidth,"px"))}},{key:"initSlideTrackUnderline",value:function(e,t){this.slideTrackLine.classList.remove("frm-first","frm-last");var n=void 0!==e?e:this.navs.filter((function(e){return e.classList.contains("frm-active")}));this.slideTrackLine.style.transform="translateX(".concat(n.offsetLeft,"px)"),this.slideTrackLine.style.width=n.clientWidth+"px",this.navs.length!==t+1?0===t&&this.slideTrackLine.classList.add("frm-first"):this.slideTrackLine.classList.add("frm-last")}},{key:"changeSlide",value:function(e){this.removeActiveClassnameFromSlides();var t=0==e?"0px":"calc( ( ".concat(100*e,"% + ").concat(parseInt(this.flexboxSlidesGap,10)*e,"px ) * -1 )");this.slideTrack.style.transform="translateX(".concat(t,")"),e in this.slides&&this.slides[e].classList.add("frm-active")}},{key:"removeActiveClassnameFromSlides",value:function(){this.slides.forEach((function(e){return e.classList.remove("frm-active")}))}},{key:"removeActiveClassnameFromNavs",value:function(){this.navs.forEach((function(e){return e.classList.remove("frm-active")}))}}])&&z(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();function B(e){return B="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},B(e)}function $(e,t){for(var n=0;n ul").querySelectorAll(":scope > li").forEach((function(e){e.querySelector("h3").addEventListener("mouseover",(function(e){t.style.transform="translateY(".concat(e.target.closest("li").offsetTop,"px)"),t.classList.add("frm-animating"),t.classList.remove("frm_hidden"),setTimeout((function(){t.classList.remove("frm-animating")}),250)}))})),document.querySelectorAll("#frm_style_sidebar .accordion-section h3").forEach((function(e){e.addEventListener("click",(function(){t.classList.add("frm_hidden")}))}))}}},{key:"initStyleClassCopyToClipboard",value:function(e){var t=this;document.querySelector(".frm-copy-text").addEventListener("click",(function(n){var r=n.currentTarget.innerText;navigator.clipboard.writeText(r).then((function(){t.success(e)}))}))}}])&&H(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}())}()}(); \ No newline at end of file +(()=>{var e={616:e=>{e.exports=function(e,t){var n,r,i=0;function o(){var o,a,s=n,l=arguments.length;e:for(;s;){if(s.args.length===arguments.length){for(a=0;a{var r;!function(){"use strict";var i={not_string:/[^s]/,not_bool:/[^t]/,not_type:/[^T]/,not_primitive:/[^v]/,number:/[diefg]/,numeric_arg:/[bcdiefguxX]/,json:/[j]/,not_json:/[^j]/,text:/^[^\x25]+/,modulo:/^\x25{2}/,placeholder:/^\x25(?:([1-9]\d*)\$|\(([^)]+)\))?(\+)?(0|'[^$])?(-)?(\d+)?(?:\.(\d+))?([b-gijostTuvxX])/,key:/^([a-z_][a-z_\d]*)/i,key_access:/^\.([a-z_][a-z_\d]*)/i,index_access:/^\[(\d+)\]/,sign:/^[+-]/};function o(e){return function(e,t){var n,r,a,s,l,c,u,f,d,p=1,h=e.length,v="";for(r=0;r=0),s.type){case"b":n=parseInt(n,10).toString(2);break;case"c":n=String.fromCharCode(parseInt(n,10));break;case"d":case"i":n=parseInt(n,10);break;case"j":n=JSON.stringify(n,null,s.width?parseInt(s.width):0);break;case"e":n=s.precision?parseFloat(n).toExponential(s.precision):parseFloat(n).toExponential();break;case"f":n=s.precision?parseFloat(n).toFixed(s.precision):parseFloat(n);break;case"g":n=s.precision?String(Number(n.toPrecision(s.precision))):parseFloat(n);break;case"o":n=(parseInt(n,10)>>>0).toString(8);break;case"s":n=String(n),n=s.precision?n.substring(0,s.precision):n;break;case"t":n=String(!!n),n=s.precision?n.substring(0,s.precision):n;break;case"T":n=Object.prototype.toString.call(n).slice(8,-1).toLowerCase(),n=s.precision?n.substring(0,s.precision):n;break;case"u":n=parseInt(n,10)>>>0;break;case"v":n=n.valueOf(),n=s.precision?n.substring(0,s.precision):n;break;case"x":n=(parseInt(n,10)>>>0).toString(16);break;case"X":n=(parseInt(n,10)>>>0).toString(16).toUpperCase()}i.json.test(s.type)?v+=n:(!i.number.test(s.type)||f&&!s.sign?d="":(d=f?"+":"-",n=n.toString().replace(i.sign,"")),c=s.pad_char?"0"===s.pad_char?"0":s.pad_char.charAt(1):" ",u=s.width-(d+n).length,l=s.width&&u>0?c.repeat(u):"",v+=s.align?d+n+l:"0"===c?d+l+n:l+d+n)}return v}(function(e){if(s[e])return s[e];for(var t,n=e,r=[],o=0;n;){if(null!==(t=i.text.exec(n)))r.push(t[0]);else if(null!==(t=i.modulo.exec(n)))r.push("%");else{if(null===(t=i.placeholder.exec(n)))throw new SyntaxError("[sprintf] unexpected placeholder");if(t[2]){o|=1;var a=[],l=t[2],c=[];if(null===(c=i.key.exec(l)))throw new SyntaxError("[sprintf] failed to parse named argument key");for(a.push(c[1]);""!==(l=l.substring(c[0].length));)if(null!==(c=i.key_access.exec(l)))a.push(c[1]);else{if(null===(c=i.index_access.exec(l)))throw new SyntaxError("[sprintf] failed to parse named argument key");a.push(c[1])}t[2]=a}else o|=2;if(3===o)throw new Error("[sprintf] mixing positional and named placeholders is not (yet) supported");r.push({placeholder:t[0],param_no:t[1],keys:t[2],sign:t[3],pad_char:t[4],align:t[5],width:t[6],precision:t[7],type:t[8]})}n=n.substring(t[0].length)}return s[e]=r}(e),arguments)}function a(e,t){return o.apply(null,[e].concat(t||[]))}var s=Object.create(null);"undefined"!=typeof window&&(window.sprintf=o,window.vsprintf=a,void 0===(r=function(){return{sprintf:o,vsprintf:a}}.call(t,n,t,e))||(e.exports=r))}()}},t={};function n(r){var i=t[r];if(void 0!==i)return i.exports;var o=t[r]={exports:{}};return e[r](o,o.exports,n),o.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{"use strict";var e,t,r,i,o=n(616),a=n.n(o);function s(e){return s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s(e)}function l(e){var t=function(e){if("object"!=s(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=s(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==s(t)?t:t+""}n(604),a()(console.error),e={"(":9,"!":8,"*":7,"/":7,"%":7,"+":6,"-":6,"<":5,"<=":5,">":5,">=":5,"==":4,"!=":4,"&&":3,"||":2,"?":1,"?:":1},t=["(","?"],r={")":["("],":":["?","?:"]},i=/<=|>=|==|!=|&&|\|\||\?:|\(|!|\*|\/|%|\+|-|<|>|\?|\)|:/;var c={"!":function(e){return!e},"*":function(e,t){return e*t},"/":function(e,t){return e/t},"%":function(e,t){return e%t},"+":function(e,t){return e+t},"-":function(e,t){return e-t},"<":function(e,t){return e":function(e,t){return e>t},">=":function(e,t){return e>=t},"==":function(e,t){return e===t},"!=":function(e,t){return e!==t},"&&":function(e,t){return e&&t},"||":function(e,t){return e||t},"?:":function(e,t,n){if(e)throw t;return n}};var u={contextDelimiter:"",onMissingKey:null};function f(e,t){var n;for(n in this.data=e,this.pluralForms={},this.options={},u)this.options[n]=void 0!==t&&n in t?t[n]:u[n]}function d(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function p(e){for(var t=1;t=0||e[l]3&&void 0!==arguments[3]?arguments[3]:10,a=e[t];if(y(n)&&m(r))if("function"==typeof i)if("number"==typeof o){var s={callback:i,priority:o,namespace:r};if(a[n]){var l,c=a[n].handlers;for(l=c.length;l>0&&!(o>=c[l-1].priority);l--);l===c.length?c[l]=s:c.splice(l,0,s),a.__current.forEach((function(e){e.name===n&&e.currentIndex>=l&&e.currentIndex++}))}else a[n]={handlers:[s],runs:0};"hookAdded"!==n&&e.doAction("hookAdded",n,r,i,o)}else console.error("If specified, the hook priority must be a number.");else console.error("The hook callback must be a function.")}},b=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(r,i){var o=e[t];if(y(r)&&(n||m(i))){if(!o[r])return 0;var a=0;if(n)a=o[r].handlers.length,o[r]={runs:o[r].runs,handlers:[]};else for(var s=o[r].handlers,l=function(e){s[e].namespace===i&&(s.splice(e,1),a++,o.__current.forEach((function(t){t.name===r&&t.currentIndex>=e&&t.currentIndex--})))},c=s.length-1;c>=0;c--)l(c);return"hookRemoved"!==r&&e.doAction("hookRemoved",r,i),a}}},S=function(e,t){return function(n,r){var i=e[t];return void 0!==r?n in i&&i[n].handlers.some((function(e){return e.namespace===r})):n in i}},k=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(r){var i=e[t];i[r]||(i[r]={handlers:[],runs:0}),i[r].runs++;for(var o=i[r].handlers,a=arguments.length,s=new Array(a>1?a-1:0),l=1;l1&&void 0!==arguments[1]?arguments[1]:"default";r.data[t]=p(p(p({},h),r.data[t]),e),r.data[t][""]=p(p({},h[""]),r.data[t][""])},s=function(e,t){a(e,t),o()},l=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default",t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0,i=arguments.length>3?arguments[3]:void 0,o=arguments.length>4?arguments[4]:void 0;return r.data[e]||a(void 0,e),r.dcnpgettext(e,t,n,i,o)},c=function(){return arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default"},u=function(e,t,r){var i=l(r,t,e);return n?(i=n.applyFilters("i18n.gettext_with_context",i,e,t,r),n.applyFilters("i18n.gettext_with_context_"+c(r),i,e,t,r)):i};if(n){var d=function(e){v.test(e)&&o()};n.addAction("hookAdded","core/i18n",d),n.addAction("hookRemoved","core/i18n",d)}return{getLocaleData:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default";return r.data[e]},setLocaleData:s,resetLocaleData:function(e,t){r.data={},r.pluralForms={},s(e,t)},subscribe:function(e){return i.add(e),function(){return i.delete(e)}},__:function(e,t){var r=l(t,void 0,e);return n?(r=n.applyFilters("i18n.gettext",r,e,t),n.applyFilters("i18n.gettext_"+c(t),r,e,t)):r},_x:u,_n:function(e,t,r,i){var o=l(i,void 0,e,t,r);return n?(o=n.applyFilters("i18n.ngettext",o,e,t,r,i),n.applyFilters("i18n.ngettext_"+c(i),o,e,t,r,i)):o},_nx:function(e,t,r,i,o){var a=l(o,i,e,t,r);return n?(a=n.applyFilters("i18n.ngettext_with_context",a,e,t,r,i,o),n.applyFilters("i18n.ngettext_with_context_"+c(o),a,e,t,r,i,o)):a},isRTL:function(){return"rtl"===u("ltr","text direction")},hasTranslation:function(e,t,i){var o,a,s=t?t+""+e:e,l=!(null===(o=r.data)||void 0===o||null===(a=o[null!=i?i:"default"])||void 0===a||!a[s]);return n&&(l=n.applyFilters("i18n.has_translation",l,e,t,i),l=n.applyFilters("i18n.has_translation_"+c(i),l,e,t,i)),l}}}(0,0,E));L.getLocaleData.bind(L),L.setLocaleData.bind(L),L.resetLocaleData.bind(L),L.subscribe.bind(L);var A=L.__.bind(L);L._x.bind(L),L._n.bind(L),L._nx.bind(L),L.isRTL.bind(L),L.hasTranslation.bind(L),Promise.resolve(),window.frmDom.util.onClickPreventDefault;var C=(new URL(window.location.href).searchParams,window.frmGlobal),T=(C.url,C.nonce,"frm_hidden");function q(e){return q="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},q(e)}function P(e,t){for(var n=0;n=i)){var o=r.querySelector("select").value,a=this.calculateValue(i,n,this.getMaxValue(o,t));r.querySelector('.frm-slider-value input[type="text"]').value=a,r.querySelector(".frm-slider-bullet .frm-slider-value-label").innerText=a,r.querySelector(".frm-slider-active-track").style.width="".concat(n,"px"),this.initChildSlidersWidth(r,n,t,a+o),this.options[t].translateX=n,this.options[t].value=a+o,this.options[t].fullValue=this.updateValue(r,this.options[t].value),this.valueChangeDebouncer(t)}}}},{key:"getMaxValue",value:function(e,t){return"%"===e?100:this.options[t].maxValue}},{key:"enableDragging",value:function(e,t){e.target.classList.add("frm-dragging"),this.options[t].dragging=!0,this.options[t].startX=e.clientX-this.options[t].translateX}},{key:"disableDragging",value:function(e,t){!1!==this.options[e].dragging&&(t.target.classList.remove("frm-dragging"),this.options[e].dragging=!1,this.triggerValueChange(e))}},{key:"triggerValueChange",value:function(e){var t=this;if(null===this.options[e].dependentUpdater){var n=this.sliderElements[e].classList.contains("frm-has-multiple-values")?this.sliderElements[e].closest(".frm-style-component").querySelector('input[type="hidden"]'):this.sliderElements[e].querySelectorAll('.frm-slider-value input[type="hidden"]');n instanceof NodeList?n.forEach((function(n){n.dispatchEvent(t.eventsChange[e])})):n.dispatchEvent(this.eventsChange[e])}else this.options[e].dependentUpdater.updateAllDependentElements(this.options[e].fullValue)}},{key:"calculateValue",value:function(e,t,n){var r=Math.ceil(this.sliderBulletWidth*(t/e)),i=Math.ceil((t+r)/e*n);return Math.min(i,n)}},{key:"updateValue",value:function(e,t){var n=this;if(e.classList.contains("frm-base-font-size")){var r=document.querySelector('input[name="frm_style_setting[post_content][use_base_font_size]"]');null!==r&&(r.value="true")}if(e.classList.contains("frm-has-multiple-values")){var i=e.closest(".frm-style-component").querySelector('input[type="hidden"]'),o=i.value.split(" "),a=e.dataset.type;switch(o[2]||(o[2]="0px"),o[3]||(o[3]="0px"),a){case"vertical":o[0]=t,o[2]=t;break;case"horizontal":o[1]=t,o[3]=t;break;case"top":o[0]=t;break;case"bottom":o[2]=t;break;case"left":o[3]=t;break;case"right":o[1]=t}var s=o.join(" ");return i.value=s,this.getSliderGroupItems(e).forEach((function(e){var r=n.getUnitMeasureFromValue(t);e.querySelector('.frm-slider-value input[type="text"]').value=parseInt(t,10),e.querySelector("select").value=r})),s}if(e.classList.contains("frm-has-independent-fields")){var l=e.querySelectorAll('.frm-slider-value input[type="hidden"]'),c=e.querySelectorAll('.frm-slider-value input[type="text"]');return l.forEach((function(e,n){e.value=t,c[n+1].value=parseInt(t,10)})),t}return e.querySelector('.frm-slider-value input[type="hidden"]').value=t,t}},{key:"getUnitMeasureFromValue",value:function(e){return["%","px","em"].find((function(t){return e.includes(t)}))||""}}])&&M(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();function U(e){return U="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},U(e)}function z(e,t){for(var n=0;n li"),this.slideTrackLine=this.wrapper.querySelector(".frm-tabs-active-underline"),this.slideTrack=this.wrapper.querySelector(".frm-tabs-slide-track"),this.slides=this.wrapper.querySelectorAll(".frm-tabs-slide-track > div"),this.init()))},(t=[{key:"init",value:function(){var e=this;null!==this.wrapper&&this.navs.length&&null!==this.trackLine&&null!==this.slideTrack&&this.slides.length&&(this.initDefaultSlideTrackerWidth(),this.navs.forEach((function(t,n){t.addEventListener("click",(function(t){return e.onNavClick(t,n)}))})))}},{key:"onNavClick",value:function(e,t){this.removeActiveClassnameFromNavs(),e.target.classList.add("frm-active"),this.initSlideTrackUnderline(e.target,t),this.changeSlide(t)}},{key:"initDefaultSlideTrackerWidth",value:function(){this.slideTrackLine.dataset.initialWidth&&(this.slideTrackLine.style.width="".concat(this.slideTrackLine.dataset.initialWidth,"px"))}},{key:"initSlideTrackUnderline",value:function(e,t){this.slideTrackLine.classList.remove("frm-first","frm-last");var n=void 0!==e?e:this.navs.filter((function(e){return e.classList.contains("frm-active")}));this.slideTrackLine.style.transform="translateX(".concat(n.offsetLeft,"px)"),this.slideTrackLine.style.width=n.clientWidth+"px",this.navs.length!==t+1?0===t&&this.slideTrackLine.classList.add("frm-first"):this.slideTrackLine.classList.add("frm-last")}},{key:"changeSlide",value:function(e){this.removeActiveClassnameFromSlides();var t=0==e?"0px":"calc( ( ".concat(100*e,"% + ").concat(parseInt(this.flexboxSlidesGap,10)*e,"px ) * -1 )");this.slideTrack.style.transform="translateX(".concat(t,")"),e in this.slides&&this.slides[e].classList.add("frm-active")}},{key:"removeActiveClassnameFromSlides",value:function(){this.slides.forEach((function(e){return e.classList.remove("frm-active")}))}},{key:"removeActiveClassnameFromNavs",value:function(){this.navs.forEach((function(e){return e.classList.remove("frm-active")}))}}])&&z(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();function B(e){return B="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},B(e)}function $(e,t){for(var n=0;n ul").querySelectorAll(":scope > li").forEach((function(e){e.querySelector("h3").addEventListener("mouseover",(function(e){t.style.transform="translateY(".concat(e.target.closest("li").offsetTop,"px)"),t.classList.add("frm-animating"),t.classList.remove("frm_hidden"),setTimeout((function(){t.classList.remove("frm-animating")}),250)}))})),document.querySelectorAll("#frm_style_sidebar .accordion-section h3").forEach((function(e){e.addEventListener("click",(function(){t.classList.add("frm_hidden")}))}))}}},{key:"initStyleClassCopyToClipboard",value:function(e){var t=this;document.querySelector(".frm-copy-text").addEventListener("click",(function(n){var r=n.currentTarget.innerText;navigator.clipboard.writeText(r).then((function(){t.success(e)}))}))}}])&&H(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}())})()})(); \ No newline at end of file diff --git a/js/onboarding-wizard.js b/js/onboarding-wizard.js index 5db5b96d93..f945a21cc7 100644 --- a/js/onboarding-wizard.js +++ b/js/onboarding-wizard.js @@ -1,2 +1,2 @@ /*! For license information please see onboarding-wizard.js.LICENSE.txt */ -!function(){"use strict";function t(e){return t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t(e)}function e(t,e){for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:"default";!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.elements=e,this.type=r,this.prepareElements()},r=[{key:"fadeIn",value:function(){var t=this;this.applyStyleToElements((function(e){e.classList.add("frm-fadein-up"),e.addEventListener("animationend",(function(){t.resetOpacity(),e.classList.remove("frm-fadein-up")}),{once:!0})}))}},{key:"cascadeFadeIn",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.03;setTimeout((function(){t.applyStyleToElements((function(t,r){t.classList.remove("frm-animate"),t.style.transitionDelay=(r+1)*e+"s"}))}),200)}},{key:"prepareElements",value:function(){var t=this;this.applyStyleToElements((function(e){"default"===t.type&&(e.style.opacity="0.0"),"cascade"===t.type&&e.classList.add("frm-init-cascade-animation"),"cascade-3d"===t.type&&e.classList.add("frm-init-fadein-3d"),e.classList.add("frm-animate")}))}},{key:"resetOpacity",value:function(){this.applyStyleToElements((function(t){return t.style.opacity="1.0"}))}},{key:"applyStyleToElements",value:function(t){this.elements instanceof Element?t(this.elements,0):00&&void 0!==arguments[0]?arguments[0]:{};if("object"!==O(t)||null===t)throw new Error("createPageState: initialState must be a non-null object");var e=t;return{getState:function(){return e},getSingleState:function(t){var r=Reflect.get(e,t);return void 0===r?null:r},setState:function(t){if("object"!==O(t)||null===t)throw new Error("setState: newState must be a non-null object");e=L(L({},e),t)},setSingleState:function(t,r){Reflect.has(e,t)&&Reflect.set(e,t,r)}}}({processedSteps:[],installedAddons:[]}),P=x.getState,_=(x.getSingleState,x.setState,x.setSingleState),k=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if("object"!==g(t)||null===t)throw new Error("createPageElements: initialElements must be a non-null object");var e=t;return{getElements:function(){return e},addElements:function(t){if("object"!==g(t)||null===t)throw new Error("addElements: newElements must be a non-null object");e=v(v({},e),t)}}}({onboardingWizardPage:document.getElementById("".concat(w,"-wizard-page")),container:document.getElementById("".concat(w,"-container")),rootline:document.getElementById("".concat(w,"-rootline")),steps:document.querySelectorAll(".".concat(w,"-step")),skipStepButtons:document.querySelectorAll(".".concat(w,"-skip-step")),backButtons:document.querySelectorAll(".".concat(w,"-back-button")),consentTrackingButton:document.getElementById("".concat(w,"-consent-tracking")),installAddonsButton:document.getElementById("".concat(w,"-install-addons-button")),hiddenLicenseKeyInput:document.getElementById("frm-license-key")}),T=k.getElements;k.addElements;var A=function(t){var e,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"pushState",o=document.querySelector(".".concat(w,'-step[data-step-name="').concat(t,'"]'));if(o){var i=document.querySelector(".".concat(w,"-step.").concat(y));i&&(i.classList.remove(y),null==(e=i)||e.classList.add(h)),o.classList.add(y),function(t){null==t||t.classList.remove(h)}(o),new n(o).fadeIn(),T().onboardingWizardPage.setAttribute("data-current-step",t),function(t,e){var r,n,o,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"pushState";if(u.set(t,e),c.search=u.toString(),["pushState","replaceState"].includes(i)){var l=(r={},o=e,(n=function(t){var e=function(t){if("object"!=a(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=a(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==a(e)?e:e+""}(n=t))in r?Object.defineProperty(r,n,{value:o,enumerable:!0,configurable:!0,writable:!0}):r[n]=o,r);window.history[i](l,"",c)}c.toString()}("step",t,r),function(t){t===S.UNSUCCESSFUL&&(t=S.SUCCESS);var e=T().rootline,r=e.querySelector('.frm-rootline-item[data-step="'.concat(t,'"]'));e.querySelectorAll(".frm-rootline-item").forEach((function(t){t.classList.remove(N),t.classList.remove(y)}));var n=r.previousElementSibling;if(n)for(;n;)n.classList.add(N),n=n.previousElementSibling;t===S.SUCCESS?r.classList.add(N):r.classList.add(y)}(t)}},I=function(){var t=document.querySelector(".".concat(w,"-step.").concat(y)),e=null==t?void 0:t.nextElementSibling;if(e){var r=t.dataset.stepName,n=e.dataset.stepName,o=P().processedSteps;o.includes(r)||(o.push(r),_("processedSteps",o)),function(t,e){var r=function(t,e){var r;if(S.SUCCESS===e||S.UNSUCCESSFUL===e){var n=P().processedSteps;n.length>1&&(n.includes(e)||n.push(e),(r=new FormData).append("processed_steps",n.join(",")),r.append("completed_steps",!0))}if(S.INSTALL_ADDONS===t){var o,i=P().installedAddons;i.length>0&&(r=null!==(o=r)&&void 0!==o?o:new FormData).append("installed_addons",i.join(","))}return r}(t,e);r&&(0,frmDom.ajax.doJsonPost)("onboarding_setup_usage_data",r)}(r,n),A(n)}};var N="frm-completed-step",D=".frm-option-box";function C(t){"input"===t.target.tagName.toLowerCase()&&t.currentTarget.closest(D).classList.toggle("frm-checked")}var F=function(){I()},U=function(){var t,e;(e=null==(t=document.querySelector(".".concat(w,"-step.").concat(y)))?void 0:t.previousElementSibling)&&A(e.dataset.stepName)};function G(t){return G="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},G(t)}function B(){B=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function l(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{l({},"")}catch(t){l=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var i=e&&e.prototype instanceof m?e:m,a=Object.create(i.prototype),c=new T(n||[]);return o(a,"_invoke",{value:x(t,r,c)}),a}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var p="suspendedStart",h="suspendedYield",y="executing",d="completed",v={};function m(){}function g(){}function b(){}var w={};l(w,a,(function(){return this}));var S=Object.getPrototypeOf,E=S&&S(S(A([])));E&&E!==r&&n.call(E,a)&&(w=E);var L=b.prototype=m.prototype=Object.create(w);function j(t){["next","throw","return"].forEach((function(e){l(t,e,(function(t){return this._invoke(e,t)}))}))}function O(t,e){function r(o,i,a,c){var u=f(t[o],t,i);if("throw"!==u.type){var l=u.arg,s=l.value;return s&&"object"==G(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(s).then((function(t){l.value=t,a(l)}),(function(t){return r("throw",t,a,c)}))}c(u.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function x(e,r,n){var o=p;return function(i,a){if(o===y)throw Error("Generator is already running");if(o===d){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=P(c,n);if(u){if(u===v)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=d,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=y;var l=f(e,r,n);if("normal"===l.type){if(o=n.done?d:h,l.arg===v)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(o=d,n.method="throw",n.arg=l.arg)}}}function P(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,P(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),v;var i=f(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,v;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,v):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,v)}function _(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function k(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function T(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(_,this),this.reset(!0)}function A(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function r(){for(;++o=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),l=n.call(a,"finallyLoc");if(u&&l){if(this.prev=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),k(r),v}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;k(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:A(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),v}},e}function q(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}var Y=function(){var t,e=(t=B().mark((function t(){return B().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:(0,frmDom.ajax.doJsonPost)("onboarding_consent_tracking",new FormData).then(I);case 2:case"end":return t.stop()}}),t)})),function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){q(i,n,o,a,c,"next",t)}function c(t){q(i,n,o,a,c,"throw",t)}a(void 0)}))});return function(){return e.apply(this,arguments)}}();function z(t){return z="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},z(t)}function R(){R=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function l(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{l({},"")}catch(t){l=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var i=e&&e.prototype instanceof m?e:m,a=Object.create(i.prototype),c=new T(n||[]);return o(a,"_invoke",{value:x(t,r,c)}),a}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var p="suspendedStart",h="suspendedYield",y="executing",d="completed",v={};function m(){}function g(){}function b(){}var w={};l(w,a,(function(){return this}));var S=Object.getPrototypeOf,E=S&&S(S(A([])));E&&E!==r&&n.call(E,a)&&(w=E);var L=b.prototype=m.prototype=Object.create(w);function j(t){["next","throw","return"].forEach((function(e){l(t,e,(function(t){return this._invoke(e,t)}))}))}function O(t,e){function r(o,i,a,c){var u=f(t[o],t,i);if("throw"!==u.type){var l=u.arg,s=l.value;return s&&"object"==z(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(s).then((function(t){l.value=t,a(l)}),(function(t){return r("throw",t,a,c)}))}c(u.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function x(e,r,n){var o=p;return function(i,a){if(o===y)throw Error("Generator is already running");if(o===d){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=P(c,n);if(u){if(u===v)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=d,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=y;var l=f(e,r,n);if("normal"===l.type){if(o=n.done?d:h,l.arg===v)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(o=d,n.method="throw",n.arg=l.arg)}}}function P(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,P(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),v;var i=f(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,v;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,v):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,v)}function _(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function k(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function T(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(_,this),this.reset(!0)}function A(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function r(){for(;++o=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),l=n.call(a,"finallyLoc");if(u&&l){if(this.prev=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),k(r),v}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;k(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:A(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),v}},e}function W(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=function(t,e){if(t){if("string"==typeof t)return J(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?J(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,o=function(){};return{s:o,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,c=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return a=t.done,t},e:function(t){c=!0,i=t},f:function(){try{a||null==r.return||r.return()}finally{if(c)throw i}}}}function J(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r{"use strict";function t(e){return t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t(e)}function e(t,e){for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:"default";!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.elements=e,this.type=r,this.prepareElements()},r=[{key:"fadeIn",value:function(){var t=this;this.applyStyleToElements((function(e){e.classList.add("frm-fadein-up"),e.addEventListener("animationend",(function(){t.resetOpacity(),e.classList.remove("frm-fadein-up")}),{once:!0})}))}},{key:"cascadeFadeIn",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.03;setTimeout((function(){t.applyStyleToElements((function(t,r){t.classList.remove("frm-animate"),t.style.transitionDelay=(r+1)*e+"s"}))}),200)}},{key:"prepareElements",value:function(){var t=this;this.applyStyleToElements((function(e){"default"===t.type&&(e.style.opacity="0.0"),"cascade"===t.type&&e.classList.add("frm-init-cascade-animation"),"cascade-3d"===t.type&&e.classList.add("frm-init-fadein-3d"),e.classList.add("frm-animate")}))}},{key:"resetOpacity",value:function(){this.applyStyleToElements((function(t){return t.style.opacity="1.0"}))}},{key:"applyStyleToElements",value:function(t){this.elements instanceof Element?t(this.elements,0):00&&void 0!==arguments[0]?arguments[0]:{};if("object"!==O(t)||null===t)throw new Error("createPageState: initialState must be a non-null object");var e=t;return{getState:function(){return e},getSingleState:function(t){var r=Reflect.get(e,t);return void 0===r?null:r},setState:function(t){if("object"!==O(t)||null===t)throw new Error("setState: newState must be a non-null object");e=L(L({},e),t)},setSingleState:function(t,r){Reflect.has(e,t)&&Reflect.set(e,t,r)}}}({processedSteps:[],installedAddons:[]}),P=x.getState,_=(x.getSingleState,x.setState,x.setSingleState),k=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if("object"!==g(t)||null===t)throw new Error("createPageElements: initialElements must be a non-null object");var e=t;return{getElements:function(){return e},addElements:function(t){if("object"!==g(t)||null===t)throw new Error("addElements: newElements must be a non-null object");e=v(v({},e),t)}}}({onboardingWizardPage:document.getElementById("".concat(w,"-wizard-page")),container:document.getElementById("".concat(w,"-container")),rootline:document.getElementById("".concat(w,"-rootline")),steps:document.querySelectorAll(".".concat(w,"-step")),skipStepButtons:document.querySelectorAll(".".concat(w,"-skip-step")),backButtons:document.querySelectorAll(".".concat(w,"-back-button")),consentTrackingButton:document.getElementById("".concat(w,"-consent-tracking")),installAddonsButton:document.getElementById("".concat(w,"-install-addons-button")),hiddenLicenseKeyInput:document.getElementById("frm-license-key")}),T=k.getElements;k.addElements;var A=function(t){var e,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"pushState",o=document.querySelector(".".concat(w,'-step[data-step-name="').concat(t,'"]'));if(o){var i=document.querySelector(".".concat(w,"-step.").concat(y));i&&(i.classList.remove(y),null==(e=i)||e.classList.add(h)),o.classList.add(y),function(t){null==t||t.classList.remove(h)}(o),new n(o).fadeIn(),T().onboardingWizardPage.setAttribute("data-current-step",t),function(t,e){var r,n,o,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"pushState";if(u.set(t,e),c.search=u.toString(),["pushState","replaceState"].includes(i)){var l=(r={},o=e,(n=function(t){var e=function(t){if("object"!=a(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=a(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==a(e)?e:e+""}(n=t))in r?Object.defineProperty(r,n,{value:o,enumerable:!0,configurable:!0,writable:!0}):r[n]=o,r);window.history[i](l,"",c)}c.toString()}("step",t,r),function(t){t===S.UNSUCCESSFUL&&(t=S.SUCCESS);var e=T().rootline,r=e.querySelector('.frm-rootline-item[data-step="'.concat(t,'"]'));e.querySelectorAll(".frm-rootline-item").forEach((function(t){t.classList.remove(N),t.classList.remove(y)}));var n=r.previousElementSibling;if(n)for(;n;)n.classList.add(N),n=n.previousElementSibling;t===S.SUCCESS?r.classList.add(N):r.classList.add(y)}(t)}},I=function(){var t=document.querySelector(".".concat(w,"-step.").concat(y)),e=null==t?void 0:t.nextElementSibling;if(e){var r=t.dataset.stepName,n=e.dataset.stepName,o=P().processedSteps;o.includes(r)||(o.push(r),_("processedSteps",o)),function(t,e){var r=function(t,e){var r;if(S.SUCCESS===e||S.UNSUCCESSFUL===e){var n=P().processedSteps;n.length>1&&(n.includes(e)||n.push(e),(r=new FormData).append("processed_steps",n.join(",")),r.append("completed_steps",!0))}if(S.INSTALL_ADDONS===t){var o,i=P().installedAddons;i.length>0&&(r=null!==(o=r)&&void 0!==o?o:new FormData).append("installed_addons",i.join(","))}return r}(t,e);r&&(0,frmDom.ajax.doJsonPost)("onboarding_setup_usage_data",r)}(r,n),A(n)}};var N="frm-completed-step",D=".frm-option-box";function C(t){"input"===t.target.tagName.toLowerCase()&&t.currentTarget.closest(D).classList.toggle("frm-checked")}var F=function(){I()};var U=function(){var t,e;(e=null==(t=document.querySelector(".".concat(w,"-step.").concat(y)))?void 0:t.previousElementSibling)&&A(e.dataset.stepName)};function G(t){return G="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},G(t)}function B(){B=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function l(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{l({},"")}catch(t){l=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var i=e&&e.prototype instanceof m?e:m,a=Object.create(i.prototype),c=new T(n||[]);return o(a,"_invoke",{value:x(t,r,c)}),a}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var p="suspendedStart",h="suspendedYield",y="executing",d="completed",v={};function m(){}function g(){}function b(){}var w={};l(w,a,(function(){return this}));var S=Object.getPrototypeOf,E=S&&S(S(A([])));E&&E!==r&&n.call(E,a)&&(w=E);var L=b.prototype=m.prototype=Object.create(w);function j(t){["next","throw","return"].forEach((function(e){l(t,e,(function(t){return this._invoke(e,t)}))}))}function O(t,e){function r(o,i,a,c){var u=f(t[o],t,i);if("throw"!==u.type){var l=u.arg,s=l.value;return s&&"object"==G(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(s).then((function(t){l.value=t,a(l)}),(function(t){return r("throw",t,a,c)}))}c(u.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function x(e,r,n){var o=p;return function(i,a){if(o===y)throw Error("Generator is already running");if(o===d){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=P(c,n);if(u){if(u===v)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=d,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=y;var l=f(e,r,n);if("normal"===l.type){if(o=n.done?d:h,l.arg===v)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(o=d,n.method="throw",n.arg=l.arg)}}}function P(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,P(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),v;var i=f(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,v;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,v):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,v)}function _(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function k(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function T(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(_,this),this.reset(!0)}function A(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function r(){for(;++o=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),l=n.call(a,"finallyLoc");if(u&&l){if(this.prev=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),k(r),v}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;k(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:A(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),v}},e}function q(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}var Y=function(){var t,e=(t=B().mark((function t(){return B().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:(0,frmDom.ajax.doJsonPost)("onboarding_consent_tracking",new FormData).then(I);case 2:case"end":return t.stop()}}),t)})),function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){q(i,n,o,a,c,"next",t)}function c(t){q(i,n,o,a,c,"throw",t)}a(void 0)}))});return function(){return e.apply(this,arguments)}}();function z(t){return z="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},z(t)}function R(){R=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function l(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{l({},"")}catch(t){l=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var i=e&&e.prototype instanceof m?e:m,a=Object.create(i.prototype),c=new T(n||[]);return o(a,"_invoke",{value:x(t,r,c)}),a}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var p="suspendedStart",h="suspendedYield",y="executing",d="completed",v={};function m(){}function g(){}function b(){}var w={};l(w,a,(function(){return this}));var S=Object.getPrototypeOf,E=S&&S(S(A([])));E&&E!==r&&n.call(E,a)&&(w=E);var L=b.prototype=m.prototype=Object.create(w);function j(t){["next","throw","return"].forEach((function(e){l(t,e,(function(t){return this._invoke(e,t)}))}))}function O(t,e){function r(o,i,a,c){var u=f(t[o],t,i);if("throw"!==u.type){var l=u.arg,s=l.value;return s&&"object"==z(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(s).then((function(t){l.value=t,a(l)}),(function(t){return r("throw",t,a,c)}))}c(u.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function x(e,r,n){var o=p;return function(i,a){if(o===y)throw Error("Generator is already running");if(o===d){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=P(c,n);if(u){if(u===v)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=d,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=y;var l=f(e,r,n);if("normal"===l.type){if(o=n.done?d:h,l.arg===v)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(o=d,n.method="throw",n.arg=l.arg)}}}function P(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,P(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),v;var i=f(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,v;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,v):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,v)}function _(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function k(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function T(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(_,this),this.reset(!0)}function A(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function r(){for(;++o=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),l=n.call(a,"finallyLoc");if(u&&l){if(this.prev=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),k(r),v}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;k(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:A(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),v}},e}function W(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=function(t,e){if(t){if("string"==typeof t)return J(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?J(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,o=function(){};return{s:o,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,c=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return a=t.done,t},e:function(t){c=!0,i=t},f:function(){try{a||null==r.return||r.return()}finally{if(c)throw i}}}}function J(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r { - +( wp => { /** * WordPress dependencies */ @@ -109,5 +109,4 @@ // Trigger the 'set_floating_links_config' action, passing the config wp.hooks.doAction( 'set_floating_links_config', frmFloatingLinksConfig ); - -})( window.wp ); +} )( window.wp ); diff --git a/js/packages/floating-links/s11-floating-links.js b/js/packages/floating-links/s11-floating-links.js index 5b85021d83..269d0a2453 100644 --- a/js/packages/floating-links/s11-floating-links.js +++ b/js/packages/floating-links/s11-floating-links.js @@ -4,28 +4,27 @@ * @class S11FloatingLinks */ class S11FloatingLinks { - /** * Create a new S11FloatingLinks instance. * - * @constructor + * @class */ constructor() { - wp.hooks.addAction( 'set_floating_links_config', 'S11FloatingLinks', ({ links, options }) => { + wp.hooks.addAction( 'set_floating_links_config', 'S11FloatingLinks', ( { links, options } ) => { this.validateInputs( links, options ); this.links = links; this.options = options; this.initComponent(); - }); + } ); } /** * Validate the input parameters. * - * @param {Array} links - The links array. - * @param {Object} options - The options object. + * @param {Array} links The links array. + * @param {Object} options The options object. * * @throws {Error} If the links array is empty or not provided. * @throws {Error} If the options.logoIcon is not provided or is an empty string. @@ -85,39 +84,39 @@ class S11FloatingLinks { } /** - * @return {HTMLElement} + * @return {HTMLElement} The inbox slide-in element. */ getInboxSlideIn() { - const h3 = frmDom.tag( + const h3 = frmDom.tag( 'h3', { id: 'frm_inbox_slidein_title' } ); - h3.innerHTML = frmAdminBuild.purifyHtml( frmGlobal.inboxSlideIn.subject ); - const messageSpan = frmDom.span({ + h3.innerHTML = frmAdminBuild.purifyHtml( frmGlobal.inboxSlideIn.subject ); + const messageSpan = frmDom.span( { id: 'frm_inbox_slidein_message', text: frmGlobal.inboxSlideIn.slidein - }); - const dismissIcon = frmDom.a({ + } ); + const dismissIcon = frmDom.a( { className: 'dismiss frm_inbox_dismiss', - child: frmDom.svg({ href: '#frm_close_icon' }) - }); + child: frmDom.svg( { href: '#frm_close_icon' } ) + } ); dismissIcon.setAttribute( 'aria-label', wp.i18n.__( 'Dismiss this notice', 'formidable' ) ); dismissIcon.setAttribute( 'role', 'button' ); - const children = frmAdminBuild.hooks.applyFilters( + const children = frmAdminBuild.hooks.applyFilters( 'frm_inbox_slidein_children', [ h3, messageSpan ] ); - const slideIn = frmDom.div({ + const slideIn = frmDom.div( { id: 'frm_inbox_slide_in', className: 'frm-card-item frm-compact-card-item frm-dismissible frm-box-shadow-xxl', children - }); + } ); slideIn.setAttribute( 'data-message', frmGlobal.inboxSlideIn.key ); slideIn.setAttribute( 'role', 'alert' ); slideIn.insertAdjacentHTML( 'beforeend', frmAdminBuild.purifyHtml( frmGlobal.inboxSlideIn.cta ) ); slideIn.querySelector( '.frm-button-secondary' )?.remove(); this.updateSlideInCtaUtm( slideIn ); - slideIn.appendChild( frmDom.span({ child: dismissIcon }) ); + slideIn.appendChild( frmDom.span( { child: dismissIcon } ) ); slideIn.querySelector( 'a[href].frm-button-primary' )?.setAttribute( 'aria-description', ( frmGlobal.inboxSlideIn.subject + ' ' + frmGlobal.inboxSlideIn.slidein ).replace( '&', '&' ) @@ -133,13 +132,13 @@ class S11FloatingLinks { return; } - const urlObj = new URL( anchor.href ); + const urlObj = new URL( anchor.href ); const searchParams = new URLSearchParams( urlObj.search ); searchParams.set( 'utm_medium', 'slidein' ); urlObj.search = searchParams.toString(); - anchor.href = urlObj.toString(); + anchor.href = urlObj.toString(); } ); } @@ -169,7 +168,7 @@ class S11FloatingLinks { this.navMenuElement.classList.add( 's11-floating-links-nav-menu', 's11-fadeout' ); // Create and append link elements - this.links.forEach( ( link ) => { + this.links.forEach( link => { if ( ! this.linkHasRequiredProperties( link ) ) { return; } @@ -180,18 +179,18 @@ class S11FloatingLinks { linkElement.href = link.url; linkElement.title = link.title; - if ( link.openInNewTab === true ) { + if ( link.openInNewTab === true ) { linkElement.target = '_blank'; linkElement.rel = 'noopener noreferrer'; } linkElement.innerHTML = ` - ${link.title} - ${link.icon} + ${ link.title } + ${ link.icon } `; this.navMenuElement.appendChild( linkElement ); - }); + } ); // Append the navigation menu to the wrapper element this.wrapperElement.appendChild( this.navMenuElement ); @@ -231,7 +230,7 @@ class S11FloatingLinks { // Switch the icon of the icon button element this.switchIconButton( closeIcon ); - }); + } ); // Append the icon button to the wrapper element this.wrapperElement.appendChild( this.iconButtonElement ); @@ -275,7 +274,7 @@ class S11FloatingLinks { element.addEventListener( 'animationend', () => { element.classList.remove( 's11-fading' ); - }, { once: true }); + }, { once: true } ); } /** @@ -285,7 +284,7 @@ class S11FloatingLinks { * @memberof S11FloatingLinks */ addOutsideClickListener() { - document.body.addEventListener( 'click', ( e ) => { + document.body.addEventListener( 'click', e => { if ( ! this.wrapperElement.contains( e.target ) && this.navMenuElement.classList.contains( 's11-fadein' ) ) { // Toggle the navigation menu element this.toggleFade( this.navMenuElement ); @@ -297,12 +296,12 @@ class S11FloatingLinks { // Switch the icon of the icon button element this.switchIconButton( this.options.logoIcon.trim() ); } - }); + } ); // Prevent click event from bubbling up to the body when clicking on the wrapper element - this.wrapperElement.addEventListener( 'click', ( e ) => { + this.wrapperElement.addEventListener( 'click', e => { e.stopPropagation(); - }); + } ); } /** @@ -326,7 +325,7 @@ class S11FloatingLinks { } this.lastScrollPosition = currentScrollPosition; - }); + } ); } inboxSlideInIsVisible() { diff --git a/js/plugin-search.js b/js/plugin-search.js index 1df8074b0f..413599db5f 100644 --- a/js/plugin-search.js +++ b/js/plugin-search.js @@ -3,9 +3,9 @@ * of the card with customized content. */ -/* global frmPlugSearch, JSON */ +/* global frmPlugSearch */ -var FormidablePSH = {}; +let FormidablePSH = {}; function frmPS() { FormidablePSH = { @@ -13,17 +13,17 @@ function frmPS() { /** * Get parent search hint element. - * @returns {Element | null} + * @return {Element|null} The parent search hint element. */ - getCard: function () { + getCard: function() { return document.querySelector( '.plugin-card-frm-plugin-search' ); }, /** * Replace bottom row of the card to insert logo, text and link to dismiss the card. */ - replaceCardBottom: function () { - var hint = FormidablePSH.getCard(); + replaceCardBottom: function() { + const hint = FormidablePSH.getCard(); if ( 'object' === typeof hint && null !== hint ) { hint.querySelector( '.plugin-card-bottom' ).outerHTML = '
              ' + @@ -33,19 +33,18 @@ function frmPS() { '
              '; // Remove link and parent li from action links and move it to bottom row - var dismissLink = document.querySelector( '.frm-plugin-search__dismiss' ); + const dismissLink = document.querySelector( '.frm-plugin-search__dismiss' ); dismissLink.parentNode.parentNode.removeChild( dismissLink.parentNode ); document.querySelector( '.frm-plugin-search__bottom' ).appendChild( dismissLink ); } }, - /** * Check if plugin card list nodes changed. If there's a Formidable PSH card, replace the title and the bottom row. - * @param {array} mutationsList + * @param {Array} mutationsList */ - replaceOnNewResults: function ( mutationsList ) { - mutationsList.forEach( function ( mutation ) { + replaceOnNewResults: function( mutationsList ) { + mutationsList.forEach( function( mutation ) { if ( 'childList' === mutation.type && 1 === document.querySelectorAll( '.plugin-card-frm-plugin-search' ).length @@ -58,7 +57,7 @@ function frmPS() { /** * Start suggesting. */ - init: function () { + init: function() { if ( FormidablePSH.$pluginFilter === null ) { return; } @@ -67,11 +66,11 @@ function frmPS() { FormidablePSH.replaceCardBottom(); // Listen for changes in plugin search results - var resultsObserver = new MutationObserver( FormidablePSH.replaceOnNewResults ); + const resultsObserver = new MutationObserver( FormidablePSH.replaceOnNewResults ); resultsObserver.observe( FormidablePSH.$pluginFilter, { childList: true } ); }, }; FormidablePSH.init(); } -FormidablePS = frmPS(); +FormidablePS = frmPS(); //eslint-disable-line sonarjs/no-use-of-empty-return-value diff --git a/js/src/addons-page/addons/categorizeAddons.js b/js/src/addons-page/addons/categorizeAddons.js index c5ddeba169..269f1670fe 100644 --- a/js/src/addons-page/addons/categorizeAddons.js +++ b/js/src/addons-page/addons/categorizeAddons.js @@ -17,7 +17,7 @@ categorizedAddons[ VIEWS.ACTIVE ] = []; export function buildCategorizedAddons() { const { addons } = getElements(); - addons.forEach( ( addon ) => { + addons.forEach( addon => { // Extract and split the categories from data attribute const dataCategories = addon.getAttribute( 'data-categories' ); if ( ! dataCategories ) { @@ -26,7 +26,7 @@ export function buildCategorizedAddons() { const categories = dataCategories.split( ',' ); - categories.forEach( ( category ) => { + categories.forEach( category => { // Initialize the category array if not already done if ( ! categorizedAddons[ category ] ) { categorizedAddons[ category ] = []; diff --git a/js/src/addons-page/elements/elements.js b/js/src/addons-page/elements/elements.js index 9f5a6a6430..baed855fbc 100644 --- a/js/src/addons-page/elements/elements.js +++ b/js/src/addons-page/elements/elements.js @@ -16,7 +16,7 @@ const { bodyContent, sidebar } = getElements(); bodyContent .querySelectorAll( '.frm-card-item:not(.plugin-card-formidable-pro)' ) - .forEach( ( addon ) => { + .forEach( addon => { const categories = addon.dataset.categories; switch ( true ) { case categories.includes( PLANS.BUSINESS ): diff --git a/js/src/addons-page/events/addonToggleListener.js b/js/src/addons-page/events/addonToggleListener.js index aaaaa5fdb6..d59d8ef22f 100644 --- a/js/src/addons-page/events/addonToggleListener.js +++ b/js/src/addons-page/events/addonToggleListener.js @@ -14,13 +14,13 @@ let targetButton; function addAddonToggleEvents() { const { addonsToggle } = getElements(); - addonsToggle.forEach( ( addonToggle ) => + addonsToggle.forEach( addonToggle => addonToggle.addEventListener( 'click', onAddonToggleClick ) ); - wp.hooks.addAction('frm_update_addon_state', 'frmAddonPage', () => { + wp.hooks.addAction( 'frm_update_addon_state', 'frmAddonPage', () => { setupActiveCategory(); - }); + } ); } /** @@ -30,8 +30,8 @@ function addAddonToggleEvents() { * @param {Event} event The click event object. * @return {void} */ -const onAddonToggleClick = ( event ) => { - if (targetButton?.classList.contains( 'frm_loading_button' )) { +const onAddonToggleClick = event => { + if ( targetButton?.classList.contains( 'frm_loading_button' ) ) { return; } diff --git a/js/src/addons-page/events/index.js b/js/src/addons-page/events/index.js index b405c05fb3..fca9a74f97 100644 --- a/js/src/addons-page/events/index.js +++ b/js/src/addons-page/events/index.js @@ -20,7 +20,7 @@ export function addEventListeners() { wp.hooks.addAction( 'frmPage.onCategoryClick', 'frmAddonsPage', - ( selectedCategory ) => { + selectedCategory => { showSelectedCategory( selectedCategory ); } ); diff --git a/js/src/addons-page/ui/setupInitialView.js b/js/src/addons-page/ui/setupInitialView.js index 10dcf88fab..ee76d12822 100644 --- a/js/src/addons-page/ui/setupInitialView.js +++ b/js/src/addons-page/ui/setupInitialView.js @@ -121,7 +121,7 @@ function setupPlansCategory() { elitePlanCategory, } = getElements(); - const getCount = ( category ) => parseInt( category.querySelector( CAT_COUNT_CLASS ).textContent, 10 ) || 0; + const getCount = category => parseInt( category.querySelector( CAT_COUNT_CLASS ).textContent, 10 ) || 0; // The "Formidable Pro" add-on is included in all plans, so we just consider that in the basicCount const basicCount = getCount( basicPlanCategory ); diff --git a/js/src/addons-page/ui/showEmptyState.js b/js/src/addons-page/ui/showEmptyState.js index f377066df9..93a456b82a 100644 --- a/js/src/addons-page/ui/showEmptyState.js +++ b/js/src/addons-page/ui/showEmptyState.js @@ -11,7 +11,7 @@ import { showElements } from 'core/utils'; /** * Internal dependencies */ -import { getElements } from "../elements"; +import { getElements } from '../elements'; import { getState } from '../shared'; import { addonRequestURL } from '../constants'; diff --git a/js/src/admin/admin.js b/js/src/admin/admin.js new file mode 100644 index 0000000000..9a7684d778 --- /dev/null +++ b/js/src/admin/admin.js @@ -0,0 +1,11347 @@ +/* exported frm_add_logic_row, frm_remove_tag, frm_show_div, frmCheckAll, frmCheckAllLevel */ +/* eslint-disable jsdoc/require-param, prefer-const, no-redeclare, @wordpress/no-unused-vars-before-return, jsdoc/check-types, jsdoc/check-tag-names, @wordpress/i18n-translator-comments, @wordpress/valid-sprintf, jsdoc/require-returns-description, jsdoc/require-param-type, no-unused-expressions, compat/compat */ + +window.FrmFormsConnect = window.FrmFormsConnect || ( function( document, window, $ ) { + /*global jQuery:false, frm_admin_js, frmGlobal, ajaxurl */ + + const el = { + messageBox: null, + reset: null, + + setElements: function() { + el.messageBox = document.querySelector( '.frm_pro_license_msg' ); + el.reset = document.getElementById( 'frm_reconnect_link' ); + } + }; + + /** + * Public functions and properties. + * + * @since 4.03 + * + * @type {Object} + */ + const app = { + + /** + * Register connect button event. + * + * @since 4.03 + */ + init: function() { + el.setElements(); + + $( document.getElementById( 'frm_deauthorize_link' ) ).on( 'click', app.deauthorize ); + $( '.frm_authorize_link' ).on( 'click', app.authorize ); + // Handles FF dashboard Authorize & Reauthorize events. + // Attach click event to parent as #frm_deauthorize_link & #frm_reconnect_link dynamically recreated by bootstrap.setupBootstrapDropdowns in dom.js + $( '.frm-dashboard-license-options' ).on( 'click', '#frm_deauthorize_link', app.deauthorize ); + $( '.frm-dashboard-license-options' ).on( 'click', '#frm_reconnect_link', app.reauthorize ); + + if ( el.reset !== null ) { + $( el.reset ).on( 'click', app.reauthorize ); + } + }, + + /* Manual license authorization */ + authorize: function() { + /*jshint validthis:true */ + const button = this; + const pluginSlug = this.getAttribute( 'data-plugin' ); + const input = document.getElementById( 'edd_' + pluginSlug + '_license_key' ); + const license = input.value; + let wpmu = document.getElementById( 'proplug-wpmu' ); + this.classList.add( 'frm_loading_button' ); + if ( wpmu === null ) { + wpmu = 0; + } else if ( wpmu.checked ) { + wpmu = 1; + } else { + wpmu = 0; + } + + $.ajax( { + type: 'POST', url: ajaxurl, dataType: 'json', + data: { + action: 'frm_addon_activate', + license: license, + plugin: pluginSlug, + wpmu: wpmu, + nonce: frmGlobal.nonce + }, + success: function( msg ) { + app.afterAuthorize( msg, input ); + button.classList.remove( 'frm_loading_button' ); + } + } ); + }, + + afterAuthorize: function( msg, input ) { + if ( msg.success === true ) { + input.value = '•••••••••••••••••••'; + } + + wp.hooks.doAction( 'frm_after_authorize', msg ); + app.showMessage( msg ); + }, + + showProgress: function( msg ) { + if ( el.messageBox === null ) { + // In case the message box was added after page load. + el.setElements(); + } + + const messageBox = el.messageBox; + if ( messageBox === null ) { + return; + } + + if ( msg.success === true ) { + messageBox.classList.remove( 'frm_error_style' ); + messageBox.classList.add( 'frm_message', 'frm_updated_message' ); + } else { + messageBox.classList.add( 'frm_error_style' ); + messageBox.classList.remove( 'frm_message', 'frm_updated_message' ); + } + messageBox.classList.remove( 'frm_hidden' ); + messageBox.innerHTML = msg.message; + }, + + showMessage: function( msg ) { + if ( el.messageBox === null ) { + // In case the message box was added after page load. + el.setElements(); + } + const messageBox = el.messageBox; + + if ( msg.success === true ) { + app.showAuthorized( true ); + app.showInlineSuccess(); + + /** + * Triggers the after license is authorized action for a confirmation/success modal. + * @param {Object} msg An object containing message data received from Authorize request. + */ + wp.hooks.doAction( 'frmAdmin.afterLicenseAuthorizeSuccess', { msg } ); + } + app.showProgress( msg ); + + if ( msg.message !== '' ) { + setTimeout( function() { + messageBox.innerHTML = ''; + messageBox.classList.add( 'frm_hidden' ); + messageBox.classList.remove( 'frm_error_style', 'frm_message', 'frm_updated_message' ); + }, 10000 ); + const refreshPage = document.querySelector( '.frm-admin-page-dashboard' ); + if ( refreshPage ) { + setTimeout( function() { + window.location.reload(); + }, 1000 ); + } + } + }, + + showAuthorized: function( show ) { + const from = show ? 'unauthorized' : 'authorized'; + const to = show ? 'authorized' : 'unauthorized'; + const container = document.querySelectorAll( '.frm_' + from + '_box' ); + if ( container.length ) { + // Replace all authorized boxes with unauthorized boxes. + container.forEach( function( box ) { + box.className = box.className.replace( 'frm_' + from + '_box', 'frm_' + to + '_box' ); + } ); + } + }, + + /** + * Use the data-success element to replace the element content. + */ + showInlineSuccess: function() { + const successElement = document.querySelectorAll( '.frm-confirm-msg [data-success]' ); + if ( successElement.length ) { + successElement.forEach( function( element ) { + element.innerHTML = frmAdminBuild.purifyHtml( element.getAttribute( 'data-success' ) ); + } ); + } + }, + + /* Clear the site license cache */ + reauthorize: function() { + /*jshint validthis:true */ + this.innerHTML = ''; + + $.ajax( { + type: 'POST', + url: ajaxurl, + dataType: 'json', + data: { + action: 'frm_reset_cache', + plugin: 'formidable_pro', + nonce: frmGlobal.nonce + }, + success: function( msg ) { + el.reset.textContent = msg.message; + if ( el.reset.getAttribute( 'data-refresh' ) === '1' ) { + window.location.reload(); + } + } + } ); + return false; + }, + + deauthorize: function() { + /*jshint validthis:true */ + if ( ! confirm( frmGlobal.deauthorize ) ) { + return false; + } + const pluginSlug = this.getAttribute( 'data-plugin' ), + input = document.getElementById( 'edd_' + pluginSlug + '_license_key' ), + license = input.value, + link = this; + + this.innerHTML = ''; + + $.ajax( { + type: 'POST', + url: ajaxurl, + data: { + action: 'frm_addon_deactivate', + license: license, + plugin: pluginSlug, + nonce: frmGlobal.nonce + }, + success: function() { + app.showAuthorized( false ); + input.value = ''; + link.replaceWith( 'Disconnected' ); + + /** + * Triggers the after license is deauthorized sruccess action. + */ + wp.hooks.doAction( 'frmAdmin.afterLicenseDeauthorizeSuccess', {} ); + } + } ); + return false; + } + }; + + // Provide access to public functions/properties. + return app; +}( document, window, jQuery ) ); + +function frmAdminBuildJS() { + //'use strict'; + + /*global jQuery:false, frm_admin_js, frmGlobal, ajaxurl, fromDom */ + + const frmAdminJs = frm_admin_js; // eslint-disable-line camelcase + const { tag, div, span, a, svg, img } = frmDom; + const { onClickPreventDefault } = frmDom.util; + const { doJsonFetch, doJsonPost } = frmDom.ajax; + frmAdminJs.contextualShortcodes = getContextualShortcodes(); + const icons = { + save: svg( { href: '#frm_save_icon' } ), + drag: svg( { href: '#frm_drag_icon', classList: [ 'frm_drag_icon', 'frm-drag' ] } ) + }; + + let $newFields = jQuery( document.getElementById( 'frm-show-fields' ) ), + builderForm = document.getElementById( 'new_fields' ), + thisForm = document.getElementById( 'form_id' ), + copyHelper = false, + fieldsUpdated = 0, + thisFormId = 0, + autoId = 0, + optionMap = {}, + lastNewActionIdReturned = 0; + + const { __, sprintf } = wp.i18n; + let debouncedSyncAfterDragAndDrop, postBodyContent, $postBodyContent; + + const dragState = { + dragging: false + }; + + if ( thisForm !== null ) { + thisFormId = thisForm.value; + } + + const currentURL = new URL( window.location.href ); + const urlParams = currentURL.searchParams; + const builderPage = document.getElementById( 'frm_builder_page' ); + + // Global settings + let s; + + function showElement( element ) { + if ( ! element[ 0 ] ) { + return; + } + element[ 0 ].style.display = ''; + } + + function empty( $obj ) { + if ( $obj !== null ) { + while ( $obj.firstChild ) { + $obj.removeChild( $obj.firstChild ); + } + } + } + + function addClass( $obj, className ) { + if ( $obj.classList ) { + $obj.classList.add( className ); + } else { + $obj.className += ' ' + className; + } + } + + function confirmClick( e ) { + /*jshint validthis:true */ + e.stopPropagation(); + e.preventDefault(); + confirmLinkClick( this ); + } + + function confirmLinkClick( link ) { + const message = link.getAttribute( 'data-frmverify' ), + loadedFrom = link.getAttribute( 'data-loaded-from' ); + + if ( message === null || link.id === 'frm-confirmed-click' ) { + return true; + } + + if ( 'entries-list' === loadedFrom ) { + return wp.hooks.applyFilters( 'frm_on_multiple_entries_delete', { link, initModal } ); + } + + return confirmModal( link ); + } + + function confirmModal( link ) { + let verify, $confirmMessage, i, dataAtts, btnClass, + $info = initModal( '#frm_confirm_modal', '400px' ), + continueButton = document.getElementById( 'frm-confirmed-click' ); + + if ( $info === false ) { + return false; + } + + verify = link.getAttribute( 'data-frmverify' ); + btnClass = verify ? link.getAttribute( 'data-frmverify-btn' ) : ''; + $confirmMessage = jQuery( '.frm-confirm-msg' ); + $confirmMessage.empty(); + + if ( verify ) { + $confirmMessage.append( document.createTextNode( verify ) ); + if ( btnClass ) { + continueButton.classList.add( btnClass ); + } + } + + removeAtts = continueButton.dataset; + for ( i in dataAtts ) { + continueButton.removeAttribute( 'data-' + i ); + } + + dataAtts = link.dataset; + for ( i in dataAtts ) { + if ( i !== 'frmverify' ) { + continueButton.setAttribute( 'data-' + i, dataAtts[ i ] ); + } + } + + /** + * Triggers the pre-open action for a confirmation modal. This action passes + * relevant modal information and associated link to any listening hooks. + * + * @param {Object} options An object containing modal elements and data. + * @param {HTMLElement} options.$info The HTML element containing modal information. + * @param {string} options.link The link associated with the modal action. + */ + wp.hooks.doAction( 'frmAdmin.beforeOpenConfirmModal', { $info, link } ); + + $info.dialog( 'open' ); + continueButton.setAttribute( 'href', link.getAttribute( 'href' ) || link.getAttribute( 'data-href' ) ); + return false; + } + + function infoModal( msg ) { + const $info = initModal( '#frm_info_modal', '400px' ); + + if ( $info === false ) { + return false; + } + + jQuery( '.frm-info-msg' ).html( msg ); + + $info.dialog( 'open' ); + return false; + } + + function toggleItem( e ) { + /*jshint validthis:true */ + const toggle = this.getAttribute( 'data-frmtoggle' ); + const text = this.getAttribute( 'data-toggletext' ); + const $items = jQuery( toggle ); + + e.preventDefault(); + + $items.toggle(); + + if ( text !== null && text !== '' ) { + this.setAttribute( 'data-toggletext', this.innerHTML ); + this.textContent = text; + } + + return false; + } + + /** + * Toggle a class on target elements when an anchor is clicked, or when a radio or checkbox has been selected. + * + * @param {Event} e Event with either the change or click type. + * @returns {false} + */ + function hideShowItem( e ) { + /*jshint validthis:true */ + let hide = this.getAttribute( 'data-frmhide' ); + let show = this.getAttribute( 'data-frmshow' ); + let uncheckList = this.getAttribute( 'data-frmuncheck' ); + let uncheckListArray = uncheckList ? uncheckList.split( ',' ) : []; + + // Flip unchecked checkboxes so an off value undoes the on value. + if ( isUncheckedCheckbox( this ) ) { + if ( hide !== null ) { + show = hide; + hide = null; + } else if ( show !== null ) { + hide = show; + show = null; + } + } + + e.preventDefault(); + + const toggleClass = this.getAttribute( 'data-toggleclass' ) || 'frm_hidden'; + + if ( hide !== null ) { + jQuery( hide ).addClass( toggleClass ); + } + + if ( show !== null ) { + jQuery( show ).removeClass( toggleClass ); + } + + const current = this.parentNode.querySelectorAll( 'a.current' ); + if ( current !== null ) { + for ( let i = 0; i < current.length; i++ ) { + current[ i ].classList.remove( 'current' ); + } + this.classList.add( 'current' ); + } + + if ( uncheckListArray.length ) { + uncheckListArray.forEach( function( uncheckItem ) { + const uncheckItemElement = document.querySelector( uncheckItem ); + if ( uncheckItemElement ) { + uncheckItemElement.checked = false; + } + } ); + } + + return false; + } + + function isUncheckedCheckbox( element ) { + return 'INPUT' === element.nodeName && 'checkbox' === element.type && ! element.checked; + } + + function loadTooltips() { + let wrapClass = jQuery( '.wrap, .frm_wrap' ), + confirmModal = document.getElementById( 'frm_confirm_modal' ), + doAction = false, + confirmedBulkDelete = false; + + jQuery( confirmModal ).on( 'click', '[data-deletefield]', deleteFieldConfirmed ); + jQuery( confirmModal ).on( 'click', '[data-removeid]', removeThisTag ); + jQuery( confirmModal ).on( 'click', '[data-trashtemplate]', trashTemplate ); + + wrapClass.on( 'click', '.frm_remove_tag, .frm_remove_form_action', removeThisTag ); + wrapClass.on( 'click', 'a[data-frmverify]', confirmClick ); + wrapClass.on( 'click', 'a[data-frmtoggle]', toggleItem ); + wrapClass.on( 'click', 'a[data-frmhide], a[data-frmshow]', hideShowItem ); + wrapClass.on( 'change', 'input[data-frmhide], input[data-frmshow]', hideShowItem ); + wrapClass.on( 'click', '.widget-top,a.widget-action', clickWidget ); + + wrapClass.on( 'mouseenter.frm', '.frm_bstooltip, .frm_help', function() { + jQuery( this ).off( 'mouseenter.frm' ); + + jQuery( '.frm_bstooltip, .frm_help' ).tooltip(); + jQuery( this ).tooltip( 'show' ); + } ); + + jQuery( '.frm_bstooltip, .frm_help' ).tooltip( ); + + jQuery( document ).on( 'click', '#doaction, #doaction2', function( event ) { + const isTop = this.id === 'doaction', + suffix = isTop ? 'top' : 'bottom', + bulkActionSelector = document.getElementById( 'bulk-action-selector-' + suffix ), + confirmBulkDelete = document.getElementById( 'confirm-bulk-delete-' + suffix ); + + if ( bulkActionSelector !== null && confirmBulkDelete !== null ) { + doAction = this; + + if ( ! confirmedBulkDelete && bulkActionSelector.value === 'bulk_delete' ) { + event.preventDefault(); + confirmLinkClick( confirmBulkDelete ); + return false; + } + } else { + doAction = false; + } + } ); + + jQuery( document ).on( 'click', '#frm-confirmed-click', function( event ) { + if ( doAction === false || event.target.classList.contains( 'frm-btn-inactive' ) ) { + return; + } + + if ( this.getAttribute( 'href' ) === 'confirm-bulk-delete' ) { + event.preventDefault(); + confirmedBulkDelete = true; + doAction.click(); + return false; + } + } ); + } + + function deleteTooltips() { + document.querySelectorAll( '.tooltip' ).forEach( + function( tooltip ) { + tooltip.remove(); + } + ); + } + + function removeThisTag() { + /*jshint validthis:true */ + let show, hide, removeMore; + + if ( parseInt( this.getAttribute( 'data-skip-frm-js' ) ) || confirmLinkClick( this ) === false ) { + return; + } + + const deleteButton = jQuery( this ); + const id = deleteButton.attr( 'data-removeid' ); + + show = deleteButton.attr( 'data-showlast' ); + if ( typeof show === 'undefined' ) { + show = ''; + } + + hide = deleteButton.attr( 'data-hidelast' ); + if ( typeof hide === 'undefined' ) { + hide = ''; + } + + removeMore = deleteButton.attr( 'data-removemore' ); + + if ( show !== '' ) { + if ( deleteButton.closest( '.frm_add_remove' ).find( '.frm_remove_tag:visible' ).length > 1 ) { + show = ''; + hide = ''; + } + } else if ( id.indexOf( 'frm_postmeta_' ) === 0 ) { + if ( jQuery( '#frm_postmeta_rows .frm_postmeta_row' ).length < 2 ) { + show = '.frm_add_postmeta_row.button'; + } + if ( jQuery( '.frm_toggle_cf_opts' ).length && jQuery( '#frm_postmeta_rows .frm_postmeta_row:not(#' + id + ')' ).last().length ) { + if ( show !== '' ) { + show += ','; + } + show += '#' + jQuery( '#frm_postmeta_rows .frm_postmeta_row:not(#' + id + ')' ).last().attr( 'id' ) + ' .frm_toggle_cf_opts'; + } + } + + const $fadeEle = jQuery( document.getElementById( id ) ); + $fadeEle.fadeOut( 400, function() { + $fadeEle.remove(); + fieldUpdated(); + + if ( hide !== '' ) { + jQuery( hide ).hide(); + } + + if ( show !== '' ) { + jQuery( show + ' a,' + show ).removeClass( 'frm_hidden' ).fadeIn( 'slow' ); + } + + if ( this.closest( '.frm_form_action_settings' ) ) { + const type = this.closest( '.frm_form_action_settings' ).querySelector( '.frm_action_name' ).value; + afterActionRemoved( type ); + } + document.querySelector( '.tooltip' )?.remove(); + } ); + + if ( typeof removeMore !== 'undefined' ) { + removeMore = jQuery( removeMore ); + removeMore.fadeOut( 400, function() { + removeMore.remove(); + } ); + } + + if ( show !== '' ) { + jQuery( this ).closest( '.frm_logic_rows' ).fadeOut( 'slow' ); + } + + return false; + } + + function afterActionRemoved( type ) { + checkActiveAction( type ); + + const hookName = 'frm_after_action_removed'; + const hookArgs = { type }; + wp.hooks.doAction( hookName, hookArgs ); + } + + function clickWidget( event, b ) { + /*jshint validthis:true */ + if ( typeof b === 'undefined' ) { + b = this; + } + + popCalcFields( b, false ); + + const cont = jQuery( b ).closest( '.frm_form_action_settings' ); + const target = event.target; + + if ( cont.length && typeof target !== 'undefined' ) { + const className = target.parentElement.className; + if ( 'string' === typeof className ) { + if ( className.indexOf( 'frm_email_icons' ) > -1 || className.indexOf( 'frm_toggle' ) > -1 ) { + // clicking on delete icon shouldn't open it + event.stopPropagation(); + return; + } + } + } + + let inside = cont.children( '.widget-inside' ); + + if ( cont.length && inside.find( 'p, div, table' ).length < 1 ) { + const actionId = cont.find( 'input[name$="[ID]"]' ).val(); + const actionType = cont.find( 'input[name$="[post_excerpt]"]' ).val(); + if ( actionType ) { + inside.html( '' ); + cont.find( '.spinner' ).fadeIn( 'slow' ); + jQuery.ajax( { + type: 'POST', + url: ajaxurl, + data: { + action: 'frm_form_action_fill', + action_id: actionId, + action_type: actionType, + nonce: frmGlobal.nonce + }, + success: function( html ) { + inside.html( html ); + initiateMultiselect(); + showInputIcon( '#' + cont.attr( 'id' ) ); + initAutocomplete( inside ); + jQuery( b ).trigger( 'frm-action-loaded' ); + + /** + * Fires after filling form action content when opening. + * + * @since 5.5.4 + * + * @param {Object} insideElement JQuery object of form action inside element. + */ + wp.hooks.doAction( 'frm_filled_form_action', inside ); + } + } ); + } + } + + jQuery( b ).closest( '.frm_field_box' ).siblings().find( '.widget-inside' ).slideUp( 'fast' ); + if ( ( typeof b.className !== 'undefined' && b.className.indexOf( 'widget-action' ) !== -1 ) || jQuery( b ).closest( '.start_divider' ).length < 1 ) { + return; + } + + inside = jQuery( b ).closest( 'div.widget' ).children( '.widget-inside' ); + if ( inside.is( ':hidden' ) ) { + inside.slideDown( 'fast' ); + } else { + inside.slideUp( 'fast' ); + } + } + + function clickNewTab() { + /*jshint validthis:true */ + const t = this.getAttribute( 'href' ); + if ( typeof t === 'undefined' ) { + return false; + } + + const c = t.replace( '#', '.' ); + const $link = jQuery( this ); + + $link.closest( 'li' ).addClass( 'frm-tabs active' ).siblings( 'li' ).removeClass( 'frm-tabs active starttab' ); + $link.closest( 'div' ).children( '.tabs-panel' ).not( t ).not( c ).hide(); + + const tabContent = document.getElementById( t.replace( '#', '' ) ); + if ( tabContent ) { + tabContent.style.display = 'block'; + } + + // clearSettingsBox would hide field settings when opening the fields modal and we want to skip it there. + if ( this.id === 'frm_insert_fields_tab' && ! this.closest( '#frm_adv_info' ) ) { + clearSettingsBox(); + } + return false; + } + + function clickTab( link, auto ) { + link = jQuery( link ); + const t = link.attr( 'href' ); + if ( typeof t === 'undefined' ) { + return; + } + + const c = t.replace( '#', '.' ); + + link.closest( 'li' ).addClass( 'frm-tabs active' ).siblings( 'li' ).removeClass( 'frm-tabs active starttab' ); + if ( link.closest( 'div' ).find( '.tabs-panel' ).length ) { + link.closest( 'div' ).children( '.tabs-panel' ).not( t ).not( c ).hide(); + } else if ( document.getElementById( 'form_global_settings' ) !== null ) { + /* global settings */ + const ajax = link.data( 'frmajax' ); + link.closest( '.frm_wrap' ).find( '.tabs-panel, .hide_with_tabs' ).hide(); + if ( typeof ajax !== 'undefined' && ajax == '1' ) { + loadSettingsTab( t ); + } + } else { + /* form settings page */ + jQuery( '#frm-categorydiv .tabs-panel, .hide_with_tabs' ).hide(); + } + jQuery( t ).show(); + jQuery( c ).show(); + + hideShortcodes(); + + if ( auto !== 'auto' ) { + // Hide success message on tab change. + jQuery( '.frm_updated_message' ).hide(); + jQuery( '.frm_warning_style' ).hide(); + } + + if ( jQuery( link ).closest( '#frm_adv_info' ).length ) { + return; + } + + if ( jQuery( '.frm_form_settings' ).length ) { + jQuery( '.frm_form_settings' ).attr( 'action', '?page=formidable&frm_action=settings&id=' + jQuery( '.frm_form_settings input[name="id"]' ).val() + '&t=' + t.replace( '#', '' ) ); + } else { + jQuery( '.frm_settings_form' ).attr( 'action', '?page=formidable-settings&t=' + t.replace( '#', '' ) ); + } + } + + function setupSortable( sortableSelector ) { + document.querySelectorAll( sortableSelector ).forEach( + list => { + makeDroppable( list ); + Array.from( list.children ).forEach( child => makeDraggable( child, '.frm-move' ) ); + + const $sectionTitle = jQuery( list ).children( '[data-type="divider"]' ).children( '.divider_section_only' ); + if ( $sectionTitle.length ) { + makeDroppable( $sectionTitle ); + } + } + ); + setupFieldOptionSorting( jQuery( '#frm_builder_page' ) ); + } + + function makeDroppable( list ) { + jQuery( list ).droppable( { + accept: '.frmbutton, li.frm_field_box', + deactivate: handleFieldDrop, + over: onDragOverDroppable, + out: onDraggableLeavesDroppable, + tolerance: 'pointer' + } ); + } + + function onDragOverDroppable( event, ui ) { + const droppable = getDroppableForOnDragOver( event.target ); + const draggable = ui.draggable[ 0 ]; + + if ( ! allowDrop( draggable, droppable, event ) ) { + droppable.classList.remove( 'frm-over-droppable' ); + jQuery( droppable ).parents( 'ul.frm_sorting' ).addClass( 'frm-over-droppable' ); + return; + } + + document.querySelectorAll( '.frm-over-droppable' ).forEach( droppable => droppable.classList.remove( 'frm-over-droppable' ) ); + droppable.classList.add( 'frm-over-droppable' ); + jQuery( droppable ).parents( 'ul.frm_sorting' ).addClass( 'frm-over-droppable' ); + } + + /** + * Maybe change the droppable. + * Section titles are made droppable, but are not a list, so we need to change the droppable to the section's list instead. + * + * @param {Element} droppable + * @return {Element} + */ + function getDroppableForOnDragOver( droppable ) { + if ( droppable.classList.contains( 'divider_section_only' ) ) { + droppable = jQuery( droppable ).nextAll( '.start_divider.frm_sorting' ).get( 0 ); + } + return droppable; + } + + function onDraggableLeavesDroppable( event ) { + const droppable = event.target; + droppable.classList.remove( 'frm-over-droppable' ); + } + + function makeDraggable( draggable, handle ) { + const settings = { + helper: getDraggableHelper, + revert: 'invalid', + delay: 10, + start: handleDragStart, + stop: handleDragStop, + drag: handleDrag, + cursor: 'grabbing', + refreshPositions: true, + cursorAt: { + top: 0, + left: 90 // The width of draggable button is 180. 90 should center the draggable on the cursor. + } + }; + if ( 'string' === typeof handle ) { + settings.handle = handle; + } + jQuery( draggable ).draggable( settings ); + } + + function getDraggableHelper( event ) { + const draggable = event.delegateTarget; + + if ( isFieldGroup( draggable ) ) { + const newTextFieldClone = document.getElementById( 'frm-insert-fields' ).querySelector( '.frm_ttext' ).cloneNode( true ); + newTextFieldClone.querySelector( 'use' ).setAttributeNS( 'http://www.w3.org/1999/xlink', 'href', '#frm_field_group_layout_icon' ); + newTextFieldClone.querySelector( 'span' ).textContent = __( 'Field Group', 'formidable' ); + newTextFieldClone.classList.add( 'frm_field_box' ); + newTextFieldClone.classList.add( 'ui-sortable-helper' ); + return newTextFieldClone; + } + + let copyTarget; + const isNewField = draggable.classList.contains( 'frmbutton' ); + if ( isNewField ) { + copyTarget = draggable.cloneNode( true ); + copyTarget.classList.add( 'ui-sortable-helper' ); + draggable.classList.add( 'frm-new-field' ); + return copyTarget; + } + + if ( draggable.hasAttribute( 'data-ftype' ) ) { + const fieldType = draggable.getAttribute( 'data-ftype' ); + copyTarget = document.getElementById( 'frm-insert-fields' ).querySelector( '.frm_t' + fieldType ); + copyTarget = copyTarget.cloneNode( true ); + copyTarget.classList.add( 'form-field' ); + + copyTarget.classList.add( 'ui-sortable-helper' ); + + if ( copyTarget ) { + return copyTarget.cloneNode( true ); + } + } + + return div( { className: 'frmbutton' } ); + } + + function handleDragStart( event, ui ) { + dragState.dragging = true; + + const container = postBodyContent; + container.classList.add( 'frm-dragging-field' ); + + document.body.classList.add( 'frm-dragging' ); + ui.helper.addClass( 'frm-sortable-helper' ); + ui.helper.initialOffset = container.scrollTop; + + event.target.classList.add( 'frm-drag-fade' ); + + unselectFieldGroups(); + deleteEmptyDividerWrappers(); + maybeRemoveGroupHoverTarget(); + closeOpenFieldDropdowns(); + deleteTooltips(); + } + + function handleDragStop() { + const container = postBodyContent; + container.classList.remove( 'frm-dragging-field' ); + document.body.classList.remove( 'frm-dragging' ); + + const fade = document.querySelector( '.frm-drag-fade' ); + if ( fade ) { + fade.classList.remove( 'frm-drag-fade' ); + } + } + + function handleDrag( event, ui ) { + maybeScrollBuilder( event ); + const draggable = event.target; + const droppable = getDroppableTarget(); + + let placeholder = document.getElementById( 'frm_drag_placeholder' ); + if ( ! allowDrop( draggable, droppable, event ) ) { + if ( placeholder ) { + placeholder.remove(); + } + return; + } + + if ( ! placeholder ) { + placeholder = tag( 'li', { + id: 'frm_drag_placeholder', + className: 'sortable-placeholder' + } ); + } + const frmSortableHelper = ui.helper.get( 0 ); + if ( frmSortableHelper.classList.contains( 'form-field' ) || frmSortableHelper.classList.contains( 'frm_field_box' ) ) { + // Sync the y position of the draggable so it still follows the cursor after scrolling up and down the field list. + frmSortableHelper.style.transform = 'translateY(' + getDragOffset( ui.helper ) + 'px)'; + } + + if ( 'frm-show-fields' === droppable.id || droppable.classList.contains( 'start_divider' ) ) { + placeholder.style.left = 0; + handleDragOverYAxis( { droppable, y: event.clientY, placeholder } ); + return; + } + + placeholder.style.top = ''; + handleDragOverFieldGroup( { droppable, x: event.clientX, placeholder } ); + } + + function maybeScrollBuilder( event ) { + $postBodyContent.scrollTop( + ( _, v ) => { + const moved = event.clientY; + const h = postBodyContent.offsetHeight; + const relativePos = event.clientY - postBodyContent.offsetTop; + const y = relativePos - ( h / 2 ); + + if ( relativePos > ( h - 50 ) && moved > 5 ) { + // Scrolling down. + return v + ( y * 0.1 ); + } + + if ( relativePos < 70 && moved < 130 ) { + // Scrolling up. + return v - Math.abs( y * 0.1 ); + } + + return v; + } + ); + } + + function getDragOffset( $helper ) { + return postBodyContent.scrollTop - $helper.initialOffset; + } + + function getDroppableTarget() { + let droppable = document.getElementById( 'frm-show-fields' ); + while ( droppable.querySelector( '.frm-over-droppable' ) ) { + droppable = droppable.querySelector( '.frm-over-droppable' ); + } + if ( 'frm-show-fields' === droppable.id && ! droppable.classList.contains( 'frm-over-droppable' ) ) { + droppable = false; + } + return droppable; + } + + function handleFieldDrop( _, ui ) { + if ( ! dragState.dragging ) { + // dragState.dragging is set to true on drag start. + // The deactivate event gets called for every droppable. This check to make sure it happens once. + return; + } + + dragState.dragging = false; + + const draggable = ui.draggable[ 0 ]; + const placeholder = document.getElementById( 'frm_drag_placeholder' ); + + if ( ! placeholder ) { + ui.helper.remove(); + debouncedSyncAfterDragAndDrop(); + return; + } + + maybeOpenCollapsedPage( placeholder ); + + const $previousFieldContainer = ui.helper.parent(); + const previousSection = ui.helper.get( 0 ).closest( 'ul.start_divider' ); + const newSection = placeholder.closest( 'ul.frm_sorting' ); + + if ( draggable.classList.contains( 'frm-new-field' ) ) { + insertNewFieldByDragging( draggable.id ); + } else { + moveFieldThatAlreadyExists( draggable, placeholder ); + } + + const previousSectionId = previousSection ? parseInt( previousSection.closest( '.edit_field_type_divider' ).getAttribute( 'data-fid' ) ) : 0; + const newSectionId = newSection.classList.contains( 'start_divider' ) ? parseInt( newSection.closest( '.edit_field_type_divider' ).getAttribute( 'data-fid' ) ) : 0; + + placeholder.remove(); + ui.helper.remove(); + + const $previousContainerFields = $previousFieldContainer.length ? getFieldsInRow( $previousFieldContainer ) : []; + maybeUpdatePreviousFieldContainerAfterDrop( $previousFieldContainer, $previousContainerFields ); + maybeUpdateDraggableClassAfterDrop( draggable, $previousContainerFields ); + + if ( previousSectionId !== newSectionId ) { + updateFieldAfterMovingBetweenSections( jQuery( draggable ), previousSection ); + } + + debouncedSyncAfterDragAndDrop(); + } + + /** + * If a page if collapsed, expand it before dragging since only the page break will move. + * + * @param {Element} placeholder + * @return {void} + */ + function maybeOpenCollapsedPage( placeholder ) { + if ( ! placeholder.previousElementSibling || ! placeholder.previousElementSibling.classList.contains( 'frm-is-collapsed' ) ) { + return; + } + + const $pageBreakField = jQuery( placeholder ).prevUntil( '[data-type="break"]' ); + if ( ! $pageBreakField.length ) { + return; + } + + const collapseButton = $pageBreakField.find( '.frm-collapse-page' ).get( 0 ); + if ( collapseButton ) { + collapseButton.click(); + } + } + + function maybeUpdatePreviousFieldContainerAfterDrop( $previousFieldContainer, $previousContainerFields ) { + if ( ! $previousFieldContainer.length ) { + return; + } + + if ( $previousContainerFields.length ) { + syncLayoutClasses( $previousContainerFields.first() ); + } else { + maybeDeleteAnEmptyFieldGroup( $previousFieldContainer.get( 0 ) ); + } + } + + function maybeUpdateDraggableClassAfterDrop( draggable, $previousContainerFields ) { + if ( 0 !== $previousContainerFields.length || 1 !== getFieldsInRow( jQuery( draggable.parentNode ) ).length ) { + syncLayoutClasses( jQuery( draggable ) ); + } + } + + /** + * Remove an empty field group, but don't remove an empty section. + * + * @param {Element} previousFieldContainer + * @return {void} + */ + function maybeDeleteAnEmptyFieldGroup( previousFieldContainer ) { + const closestFieldBox = previousFieldContainer.closest( 'li.frm_field_box' ); + if ( closestFieldBox && ! closestFieldBox.classList.contains( 'edit_field_type_divider' ) ) { + closestFieldBox.remove(); + } + } + + function handleDragOverYAxis( { droppable, y, placeholder } ) { + const $list = jQuery( droppable ); + + let top; + + $children = $list.children().not( '.edit_field_type_end_divider' ); + if ( 0 === $children.length ) { + $list.prepend( placeholder ); + top = 0; + } else { + const insertAtIndex = determineIndexBasedOffOfMousePositionInList( $list, y ); + + if ( insertAtIndex === $children.length ) { + const $lastChild = jQuery( $children.get( insertAtIndex - 1 ) ); + top = $lastChild.offset().top + $lastChild.outerHeight(); + $list.append( placeholder ); + + // Make sure nothing gets inserted after the end divider. + const $endDivider = $list.children( '.edit_field_type_end_divider' ); + if ( $endDivider.length ) { + $list.append( $endDivider ); + } + } else { + top = jQuery( $children.get( insertAtIndex ) ).offset().top; + jQuery( $children.get( insertAtIndex ) ).before( placeholder ); + } + } + + top -= $list.offset().top; + placeholder.style.top = top + 'px'; + } + + function determineIndexBasedOffOfMousePositionInList( $list, y ) { + const $items = $list.children().not( '.edit_field_type_end_divider' ); + const length = $items.length; + + let index, item, itemTop, returnIndex; + + if ( ! document.querySelector( '.frm-has-fields .frm_no_fields' ) ) { + // Always return 0 when there are no fields. + return 0; + } + + returnIndex = 0; + for ( index = length - 1; index >= 0; --index ) { + item = $items.get( index ); + itemTop = jQuery( item ).offset().top; + if ( y > itemTop ) { + returnIndex = index; + if ( y > itemTop + ( jQuery( item ).outerHeight() / 2 ) ) { + returnIndex = index + 1; + } + break; + } + } + + return returnIndex; + } + + function handleDragOverFieldGroup( { droppable, x, placeholder } ) { + const $row = jQuery( droppable ); + const $children = getFieldsInRow( $row ); + + if ( ! $children.length ) { + return; + } + + let left; + const insertAtIndex = determineIndexBasedOffOfMousePositionInRow( $row, x ); + + if ( insertAtIndex === $children.length ) { + const $lastChild = jQuery( $children.get( insertAtIndex - 1 ) ); + left = $lastChild.offset().left + $lastChild.outerWidth(); + $row.append( placeholder ); + } else { + left = jQuery( $children.get( insertAtIndex ) ).offset().left; + jQuery( $children.get( insertAtIndex ) ).before( placeholder ); + + const amountToOffsetLeftBy = 0 === insertAtIndex ? 4 : 8; // Offset by 8 in between rows, but only 4 for the first item in a group. + left -= amountToOffsetLeftBy; // Offset the placeholder slightly so it appears between two fields. + } + + left -= $row.offset().left; + + placeholder.style.left = left + 'px'; + } + + function syncAfterDragAndDrop() { + fixUnwrappedListItems(); + toggleSectionHolder(); + maybeFixEndDividers(); + maybeDeleteEmptyFieldGroups(); + updateFieldOrder(); + + const event = new Event( 'frm_sync_after_drag_and_drop', { bubbles: false } ); + document.dispatchEvent( event ); + } + + function maybeFixEndDividers() { + document.querySelectorAll( '.edit_field_type_end_divider' ).forEach( + endDivider => endDivider.parentNode.appendChild( endDivider ) + ); + } + + function maybeDeleteEmptyFieldGroups() { + document.querySelectorAll( 'li.form_field_box:not(.form-field)' ).forEach( + fieldGroup => ! fieldGroup.children.length && fieldGroup.remove() + ); + } + + function fixUnwrappedListItems() { + const lists = document.querySelectorAll( 'ul#frm-show-fields, ul.start_divider' ); + lists.forEach( + list => { + list.childNodes.forEach( + child => { + if ( 'undefined' === typeof child.classList ) { + return; + } + + if ( child.classList.contains( 'edit_field_type_end_divider' ) ) { + // Never wrap end divider in place. + return; + } + + if ( 'undefined' !== typeof child.classList && child.classList.contains( 'form-field' ) ) { + wrapFieldLiInPlace( child ); + } + } + ); + } + ); + } + + function deleteEmptyDividerWrappers() { + const dividers = document.querySelectorAll( 'ul.start_divider' ); + if ( ! dividers.length ) { + return; + } + dividers.forEach( + function( divider ) { + const children = [].slice.call( divider.children ); + children.forEach( + function( child ) { + if ( 0 === child.children.length ) { + child.remove(); + } else if ( 1 === child.children.length && 'ul' === child.firstElementChild.nodeName.toLowerCase() && 0 === child.firstElementChild.children.length ) { + child.remove(); + } + } + ); + } + ); + } + + function getFieldsInRow( $row ) { + let $fields = jQuery(); + + const row = $row.get( 0 ); + if ( ! row.children ) { + return $fields; + } + + Array.from( row.children ).forEach( + child => { + if ( 'none' === child.style.display ) { + return; + } + + const classes = child.classList; + if ( ! classes.contains( 'form-field' ) || classes.contains( 'edit_field_type_end_divider' ) || classes.contains( 'frm-sortable-helper' ) ) { + return; + } + + $fields = $fields.add( child ); + } + ); + return $fields; + } + + function determineIndexBasedOffOfMousePositionInRow( $row, x ) { + let $inputs = getFieldsInRow( $row ), + length = $inputs.length, + index, input, inputLeft, returnIndex; + + returnIndex = 0; + for ( index = length - 1; index >= 0; --index ) { + input = $inputs.get( index ); + inputLeft = jQuery( input ).offset().left; + if ( x > inputLeft ) { + returnIndex = index; + if ( x > inputLeft + ( jQuery( input ).outerWidth() / 2 ) ) { + returnIndex = index + 1; + } + break; + } + } + + return returnIndex; + } + + function syncLayoutClasses( $item, type ) { + let $fields, size, layoutClasses, classToAddFunction; + + if ( 'undefined' === typeof type ) { + type = 'even'; + } + + $fields = $item.parent().children( 'li.form-field, li.frmbutton_loadingnow' ).not( '.edit_field_type_end_divider' ); + size = $fields.length; + layoutClasses = getLayoutClasses(); + + if ( 'even' === type && 5 !== size ) { + $fields.each( getSyncLayoutClass( layoutClasses, getEvenClassForSize( size ) ) ); + } else if ( 'clear' === type ) { + $fields.each( getSyncLayoutClass( layoutClasses, '' ) ); + } else { + if ( -1 !== [ 'left', 'right', 'middle', 'even' ].indexOf( type ) ) { + classToAddFunction = function( index ) { + return getClassForBlock( size, type, index ); + }; + } else { + classToAddFunction = function( index ) { + const size = type[ index ]; + return getLayoutClassForSize( size ); + }; + } + + $fields.each( getSyncLayoutClass( layoutClasses, classToAddFunction ) ); + } + + updateFieldGroupControls( $item.parent(), $fields.length ); + } + + function updateFieldGroupControls( $row, count ) { + let rowOffset, shouldShowControls, controls; + + rowOffset = $row.offset(); + + if ( 'undefined' === typeof rowOffset ) { + return; + } + + shouldShowControls = count >= 2; + + controls = document.getElementById( 'frm_field_group_controls' ); + if ( null === controls ) { + if ( ! shouldShowControls ) { + // exit early. if we do not need controls and they do not exist, do nothing. + return; + } + + controls = div(); + controls.id = 'frm_field_group_controls'; + controls.setAttribute( 'role', 'group' ); + controls.setAttribute( 'tabindex', 0 ); + setFieldControlsHtml( controls ); + builderPage.appendChild( controls ); + } + + $row.append( controls ); + controls.style.display = shouldShowControls ? 'block' : 'none'; + } + + function setFieldControlsHtml( controls ) { + let layoutOption, moveOption; + + layoutOption = document.createElement( 'span' ); + layoutOption.innerHTML = ''; + const layoutOptionLabel = __( 'Set Row Layout', 'formidable' ); + addTooltip( layoutOption, layoutOptionLabel ); + makeTabbable( layoutOption, layoutOptionLabel ); + + moveOption = document.createElement( 'span' ); + moveOption.innerHTML = ''; + moveOption.classList.add( 'frm-move' ); + const moveOptionLabel = __( 'Move Field Group', 'formidable' ); + addTooltip( moveOption, moveOptionLabel ); + makeTabbable( moveOption, moveOptionLabel ); + + controls.innerHTML = ''; + controls.appendChild( layoutOption ); + controls.appendChild( moveOption ); + controls.appendChild( getFieldControlsDropdown() ); + } + + function addTooltip( element, title ) { + element.setAttribute( 'data-toggle', 'tooltip' ); + element.setAttribute( 'data-container', 'body' ); + element.setAttribute( 'title', title ); + element.addEventListener( + 'mouseover', + function() { + if ( null === element.getAttribute( 'data-original-title' ) ) { + jQuery( element ).tooltip(); + } + } + ); + } + + function getFieldControlsDropdown() { + const dropdown = span( { className: 'dropdown' } ); + const trigger = a( { + className: 'frm_bstooltip frm-hover-icon frm-dropdown-toggle dropdown-toggle', + children: [ + span( { + child: svg( { href: '#frm_thick_more_vert_icon' } ) + } ), + span( { + className: 'screen-reader-text', + text: __( 'Toggle More Options Dropdown', 'formidable' ) + } ) + ] + } ); + + frmDom.setAttributes( + trigger, + { + title: __( 'More Options', 'formidable' ), + 'data-toggle': 'dropdown', + 'data-container': 'body' + } + ); + makeTabbable( trigger, __( 'More Options', 'formidable' ) ); + dropdown.appendChild( trigger ); + + const ul = div( { + className: 'frm-dropdown-menu dropdown-menu dropdown-menu-right' + } ); + ul.setAttribute( 'role', 'menu' ); + dropdown.appendChild( ul ); + + return dropdown; + } + + function getSyncLayoutClass( layoutClasses, classToAdd ) { + return function( itemIndex ) { + let currentClassToAdd, length, layoutClassIndex, currentClass, activeLayoutClass, fieldId, layoutClassesInput; + + currentClassToAdd = 'function' === typeof classToAdd ? classToAdd( itemIndex ) : classToAdd; + length = layoutClasses.length; + activeLayoutClass = false; + for ( layoutClassIndex = 0; layoutClassIndex < length; ++layoutClassIndex ) { + currentClass = layoutClasses[ layoutClassIndex ]; + if ( this.classList.contains( currentClass ) ) { + activeLayoutClass = currentClass; + break; + } + } + + fieldId = this.dataset.fid; + + if ( 'undefined' === typeof fieldId ) { + // we are syncing the drag/drop placeholder before the actual field has loaded. + // this will get called again afterward and the input will exist then. + this.classList.add( currentClassToAdd ); + return; + } + + moveFieldSettings( document.getElementById( 'frm-single-settings-' + fieldId ) ); + layoutClassesInput = document.getElementById( 'frm_classes_' + fieldId ); + + if ( null === layoutClassesInput ) { + // not every field type has a layout class input. + return; + } + + if ( false === activeLayoutClass ) { + if ( '' !== currentClassToAdd ) { + layoutClassesInput.value = layoutClassesInput.value.concat( ' ' + currentClassToAdd ); + } + } else { + this.classList.remove( activeLayoutClass ); + layoutClassesInput.value = layoutClassesInput.value.replace( activeLayoutClass, currentClassToAdd ); + } + + if ( this.classList.contains( 'frm_first' ) ) { + this.classList.remove( 'frm_first' ); + layoutClassesInput.value = layoutClassesInput.value.replace( 'frm_first', '' ).trim(); + } + + if ( 0 === itemIndex ) { + this.classList.add( 'frm_first' ); + layoutClassesInput.value = layoutClassesInput.value.concat( ' frm_first' ); + } + + jQuery( layoutClassesInput ).trigger( 'change' ); + }; + } + + function getLayoutClasses() { + return [ 'frm_full', 'frm_half', 'frm_third', 'frm_fourth', 'frm_sixth', 'frm_two_thirds', 'frm_three_fourths', 'frm1', 'frm2', 'frm3', 'frm4', 'frm5', 'frm6', 'frm7', 'frm8', 'frm9', 'frm10', 'frm11', 'frm12' ]; + } + + function setupFieldOptionSorting( sort ) { + const opts = { + items: '.frm_sortable_field_opts li', + axis: 'y', + opacity: 0.65, + forcePlaceholderSize: false, + handle: '.frm-drag', + helper: function( e, li ) { + copyHelper = li.clone().insertAfter( li ); + return li.clone(); + }, + stop: function( e, ui ) { + copyHelper && copyHelper.remove(); + const fieldId = ui.item.attr( 'id' ).replace( 'frm_delete_field_', '' ).replace( '-' + ui.item.data( 'optkey' ) + '_container', '' ); + resetDisplayedOpts( fieldId ); + fieldUpdated(); + } + }; + jQuery( sort ).sortable( opts ); + } + + // Get the section where a field is dropped + function getSectionForFieldPlacement( currentItem ) { + let section = ''; + if ( typeof currentItem !== 'undefined' && ! currentItem.hasClass( 'edit_field_type_divider' ) ) { + section = currentItem.closest( '.edit_field_type_divider' ); + } + return section; + } + + // Get the form ID where a field is dropped + function getFormIdForFieldPlacement( section ) { + let formId = ''; + + if ( typeof section[ 0 ] !== 'undefined' ) { + const sDivide = section.children( '.start_divider' ); + sDivide.children( '.edit_field_type_end_divider' ).appendTo( sDivide ); + if ( typeof section.attr( 'data-formid' ) !== 'undefined' ) { + const fieldId = section.attr( 'data-fid' ); + formId = jQuery( 'input[name="field_options[form_select_' + fieldId + ']"]' ).val(); + } + } + + if ( typeof formId === 'undefined' || formId === '' ) { + formId = thisFormId; + } + + return formId; + } + + // Get the section ID where a field is dropped + function getSectionIdForFieldPlacement( section ) { + let sectionId = 0; + if ( typeof section[ 0 ] !== 'undefined' ) { + sectionId = section.attr( 'id' ).replace( 'frm_field_id_', '' ); + } + + return sectionId; + } + + /** + * Update a field after it is dragged and dropped into, out of, or between sections + * + * @param {Object} currentItem + * @param {Object} previousSection + * @return {void} + */ + function updateFieldAfterMovingBetweenSections( currentItem, previousSection ) { + if ( ! currentItem.hasClass( 'form-field' ) ) { + // currentItem is a field group. Call for children recursively. + getFieldsInRow( jQuery( currentItem.get( 0 ).firstChild ) ).each( + function() { + updateFieldAfterMovingBetweenSections( jQuery( this ), previousSection ); + } + ); + return; + } + + const fieldId = currentItem.attr( 'id' ).replace( 'frm_field_id_', '' ); + const section = getSectionForFieldPlacement( currentItem ); + const formId = getFormIdForFieldPlacement( section ); + const sectionId = getSectionIdForFieldPlacement( section ); + const previousFormId = previousSection ? getFormIdForFieldPlacement( jQuery( previousSection.parentNode ) ) : 0; + + jQuery.ajax( { + type: 'POST', + url: ajaxurl, + data: { + action: 'frm_update_field_after_move', + form_id: formId, + field: fieldId, + section_id: sectionId, + previous_form_id: previousFormId, + nonce: frmGlobal.nonce + }, + success: function() { + toggleSectionHolder(); + updateInSectionValue( fieldId, sectionId ); + } + } ); + } + + // Update the in_section field value + function updateInSectionValue( fieldId, sectionId ) { + document.getElementById( 'frm_in_section_' + fieldId ).value = sectionId; + } + + /** + * Get the arguments for inserting a new field. + * + * @since 6.23 + * + * @param {string} fieldType + * @param {string} sectionId + * @param {string} formId + * @param {Number} hasBreak + * + * @return {Object} + */ + function getInsertNewFieldArgs( fieldType, sectionId, formId, hasBreak ) { + return { + action: 'frm_insert_field', + form_id: formId, + field_type: fieldType, + section_id: sectionId, + nonce: frmGlobal.nonce, + has_break: hasBreak, + last_row_field_ids: getFieldIdsInSubmitRow() + }; + } + + /** + * Returns true if it's a range field type and slider type is not selected. + * + * @since 6.23 + * + * @param {string} fieldType + * @return {boolean} + */ + function shouldStopInsertingField( fieldType ) { + return wp.hooks.applyFilters( 'frm_should_stop_inserting_field', false, fieldType ); + } + + /** + * Add a new field by dragging and dropping it from the Fields sidebar + * + * @param {string} fieldType + */ + function insertNewFieldByDragging( fieldType ) { + if ( shouldStopInsertingField( fieldType ) ) { + wp.hooks.doAction( 'frm_stopped_inserting_by_dragging', fieldType ); + return; + } + + const placeholder = document.getElementById( 'frm_drag_placeholder' ); + const loadingID = fieldType.replace( '|', '-' ) + '_' + getAutoId(); + const loading = tag( + 'li', + { + id: loadingID, + className: 'frm-wait frmbutton_loadingnow' + } + ); + const $placeholder = jQuery( loading ); + const currentItem = jQuery( placeholder ); + const section = getSectionForFieldPlacement( currentItem ); + const formId = getFormIdForFieldPlacement( section ); + const sectionId = getSectionIdForFieldPlacement( section ); + + placeholder.parentNode.insertBefore( loading, placeholder ); + placeholder.remove(); + syncLayoutClasses( $placeholder ); + + let hasBreak = 0; + if ( 'summary' === fieldType ) { + // see if we need to insert a page break before this newly-added summary field. Check for at least 1 page break + hasBreak = jQuery( '.frmbutton_loadingnow#' + loadingID ).prevAll( 'li[data-type="break"]' ).length ? 1 : 0; + } + + jQuery.ajax( { + type: 'POST', + url: ajaxurl, + data: getInsertNewFieldArgs( fieldType, sectionId, formId, hasBreak ), + success: function( msg ) { + handleInsertFieldByDraggingResponse( msg, $placeholder ); + + const fieldId = checkMsgForFieldId( msg ); + if ( fieldId ) { + /** + * Fires after a field is added. + * + * @since 6.23 + * + * @param {Object} fieldData The field data. + * @param {string} fieldData.field The field HTML. + * @param {string} fieldData.field_type The field type. + * @param {string} fieldData.form_id The form ID. + */ + wp.hooks.doAction( 'frm_after_field_added_in_form_builder', { + field: msg, + fieldId, + fieldType, + form_id: formId, + } ); + } + }, + error: handleInsertFieldError + } ); + } + + /** + * @param {string} msg + * @param {Object} $placeholder jQuery object. + */ + function handleInsertFieldByDraggingResponse( msg, $placeholder ) { + let replaceWith; + document.getElementById( 'frm_form_editor_container' ).classList.add( 'frm-has-fields' ); + const $siblings = $placeholder.siblings( 'li.form-field' ).not( '.edit_field_type_end_divider' ); + + if ( ! $siblings.length ) { + // if dragging into a new row, we need to wrap the li first. + replaceWith = wrapFieldLi( msg ); + } else { + replaceWith = msgAsjQueryObject( msg ); + if ( ! $placeholder.get( 0 ).parentNode.parentNode.classList.contains( 'ui-draggable' ) ) { + // If a field group wasn't draggable because it only had a single field, make it draggable. + makeDraggable( $placeholder.get( 0 ).parentNode.parentNode, '.frm-move' ); + } + } + $placeholder.replaceWith( replaceWith ); + updateFieldOrder(); + afterAddField( msg, false ); + if ( $siblings.length ) { + syncLayoutClasses( $siblings.first() ); + } + toggleSectionHolder(); + + if ( ! $siblings.length ) { + makeDroppable( replaceWith.get( 0 ).querySelector( 'ul.frm_sorting' ) ); + makeDraggable( replaceWith.get( 0 ).querySelector( 'li.form-field' ), '.frm-move' ); + } else { + makeDraggable( replaceWith.get( 0 ), '.frm-move' ); + } + } + + /** + * Get the field ID from the response message. + * + * @since 6.23 + * + * @param {string} msg + * @return {Number} + */ + function checkMsgForFieldId( msg ) { + const result = msg.match( /data-fid="(\d+)"/ ); + return result ? parseInt( result[ 1 ] ) : 0; + } + + function getFieldIdsInSubmitRow() { + const submitField = document.querySelector( '.edit_field_type_submit' ); + if ( ! submitField ) { + return []; + } + + const lastRowFields = submitField.parentNode.children; + const ids = []; + for ( let i = 0; i < lastRowFields.length; i++ ) { + ids.push( lastRowFields[ i ].dataset.fid ); + } + + return ids; + } + + function moveFieldThatAlreadyExists( draggable, placeholder ) { + placeholder.parentNode.insertBefore( draggable, placeholder ); + } + + function msgAsjQueryObject( msg ) { + const element = div(); + element.innerHTML = msg; + return jQuery( element.firstChild ); + } + + function handleInsertFieldError( jqXHR, _, errorThrown ) { + maybeShowInsertFieldError( errorThrown, jqXHR ); + } + + function maybeShowInsertFieldError( errorThrown, jqXHR ) { + if ( ! jqXHRAborted( jqXHR ) ) { + infoModal( errorThrown + '. Please try again.' ); + } + } + + function jqXHRAborted( jqXHR ) { + return jqXHR.status === 0 || jqXHR.readyState === 0; + } + + /** + * Get a unique id that automatically increments with every function call. + * Can be used for any UI that requires a unique id. + * Not to be used in data. + * + * @return {integer} + */ + function getAutoId() { + return ++autoId; + } + + /** + * Determine if a draggable element can be droppable into a droppable element. + * + * Don't allow page break, embed form, or section inside section field + * Don't allow page breaks inside of field groups. + * Don't allow field groups with sections inside of sections. + * Don't allow field groups in field groups. + * Don't allow hidden fields inside of field groups but allow them in sections. + * Don't allow any fields below the submit button field. + * Don't allow submit button field above any fields. + * Don't allow GDPR fields in repeaters. + * + * @param {HTMLElement} draggable + * @param {HTMLElement} droppable + * @param {Event} event + * @return {Boolean} + */ + function allowDrop( draggable, droppable, event ) { + if ( false === droppable ) { + // Don't show drop placeholder if dragging somewhere off of the droppable area. + return false; + } + + if ( droppable.closest( '.frm-sortable-helper' ) ) { + // Do not allow drop into draggable. + return false; + } + + const isSubmitBtn = draggable.classList.contains( 'edit_field_type_submit' ); + const containSubmitBtn = ! draggable.classList.contains( 'form_field' ) && !! draggable.querySelector( '.edit_field_type_submit' ); + + if ( 'frm-show-fields' === droppable.id ) { + const draggableIndex = determineIndexBasedOffOfMousePositionInList( jQuery( droppable ), event.clientY ); + + if ( isSubmitBtn || containSubmitBtn ) { + // Do not allow dropping submit button to above position. + const lastRowIndex = droppable.childElementCount - 1; + return draggableIndex > lastRowIndex; + } + + // Do not allow dropping other fields to below submit button. + const submitButtonIndex = jQuery( droppable.querySelector( '.edit_field_type_submit' ).closest( '#frm-show-fields > li' ) ).index(); + return draggableIndex <= submitButtonIndex; + } + + if ( isSubmitBtn ) { + if ( droppable.classList.contains( 'start_divider' ) ) { + // Don't allow dropping submit button into a repeater. + return false; + } + + if ( isLastRow( droppable.parentElement ) ) { + // Allow dropping submit button into the last row. + return true; + } + + if ( ! isLastRow( droppable.parentElement.nextElementSibling ) ) { + // Don't a dropping submit button into the row that isn't the second one from bottom. + return false; + } + + // Allow dropping submit button into the second row from bottom if there is only submit button in the last row. + return ! draggable.parentElement.querySelector( 'li.frm_field_box:not(.edit_field_type_submit)' ); + } + + if ( droppable.classList.contains( 'start_divider' ) && ( draggable.classList.contains( 'edit_field_type_gdpr' ) || draggable.id === 'gdpr' ) && droppable.closest( '.repeat_section' ) ) { + // Don't allow GDPR fields in repeaters. + return false; + } + + if ( ! droppable.classList.contains( 'start_divider' ) ) { + const $fieldsInRow = getFieldsInRow( jQuery( droppable ) ); + if ( ! groupCanFitAnotherField( $fieldsInRow, jQuery( draggable ) ) ) { + // Field group is full and cannot accept another field. + return false; + } + + if ( draggable.id === 'divider' && droppable.closest( '.start_divider' ) ) { + return false; + } + } + + const isNewField = draggable.classList.contains( 'frm-new-field' ); + if ( isNewField ) { + return allowNewFieldDrop( draggable, droppable ); + } + + return allowMoveField( draggable, droppable ); + } + + /** + * Checks if given element is the last row in form builder. + * + * @param {HTMLElement} element Element. + * @return {Boolean} + */ + function isLastRow( element ) { + return element && element.matches( '#frm-show-fields > li:last-child' ); + } + + // Don't allow a new page break or hidden field in a field group. + // Don't allow a new field into a field group that includes a page break or hidden field. + // Don't allow a new section inside of a section. + // Don't allow an embedded form in a section. + function allowNewFieldDrop( draggable, droppable ) { + const classes = draggable.classList; + const newPageBreakField = classes.contains( 'frm_tbreak' ); + const newHiddenField = classes.contains( 'frm_thidden' ); + const newSectionField = classes.contains( 'frm_tdivider' ); + const newEmbedField = classes.contains( 'frm_tform' ); + const newUserIdField = classes.contains( 'frm_tuser_id' ); + + const newFieldWillBeAddedToAGroup = ! ( 'frm-show-fields' === droppable.id || droppable.classList.contains( 'start_divider' ) ); + if ( newFieldWillBeAddedToAGroup ) { + if ( groupIncludesBreakOrHiddenOrUserId( droppable ) ) { + // Never allow any field beside a page break or a hidden field. + return false; + } + + return ! newHiddenField && ! newPageBreakField && ! newUserIdField; + } + + const fieldTypeIsAlwaysAllowed = ! newPageBreakField && ! newHiddenField && ! newSectionField && ! newEmbedField; + if ( fieldTypeIsAlwaysAllowed ) { + return true; + } + + const newFieldWillBeAddedToASection = droppable.classList.contains( 'start_divider' ) || null !== droppable.closest( '.start_divider' ); + if ( newFieldWillBeAddedToASection ) { + // Don't allow a section or an embedded form in a section. + return ! newEmbedField && ! newSectionField; + } + + return true; + } + + function allowMoveField( draggable, droppable ) { + if ( isFieldGroup( draggable ) ) { + return allowMoveFieldGroup( draggable, droppable ); + } + + const isPageBreak = draggable.classList.contains( 'edit_field_type_break' ); + if ( isPageBreak ) { + // Page breaks are only allowed in the main list of fields, not in sections or in field groups. + return false; + } + + if ( droppable.classList.contains( 'start_divider' ) ) { + return allowMoveFieldToSection( draggable ); + } + + const isHiddenField = draggable.classList.contains( 'edit_field_type_hidden' ); + const isUserIdField = draggable.classList.contains( 'edit_field_type_user_id' ); + if ( isHiddenField || isUserIdField ) { + // Hidden fields and user id fields should not be added to field groups since they're not shown + // and don't make sense with the grid distribution. + return false; + } + + return allowMoveFieldToGroup( draggable, droppable ); + } + + function isFieldGroup( draggable ) { + return draggable.classList.contains( 'frm_field_box' ) && ! draggable.classList.contains( 'form-field' ); + } + + function allowMoveFieldGroup( fieldGroup, droppable ) { + if ( droppable.classList.contains( 'start_divider' ) && null === fieldGroup.querySelector( '.start_divider' ) ) { + // Allow a field group with no section inside of a section. + return true; + } + return false; + } + + function allowMoveFieldToSection( draggable ) { + const draggableIncludeEmbedForm = draggable.classList.contains( 'edit_field_type_form' ) || draggable.querySelector( '.edit_field_type_form' ); + if ( draggableIncludeEmbedForm ) { + // Do not allow an embedded form inside of a section. + return false; + } + + const draggableIncludesSection = draggable.classList.contains( 'edit_field_type_divider' ) || draggable.querySelector( '.edit_field_type_divider' ); + if ( draggableIncludesSection ) { + // Do not allow a section inside of a section. + return false; + } + + return true; + } + + function allowMoveFieldToGroup( draggable, group ) { + if ( groupIncludesBreakOrHiddenOrUserId( group ) ) { + // Never allow any field beside a page break or a hidden field. + return false; + } + + const isFieldGroup = jQuery( draggable ).children( 'ul.frm_sorting' ).not( '.start_divider' ).length > 0; + if ( isFieldGroup ) { + // Do not allow a field group directly inside of a field group unless it's in a section. + return false; + } + + const draggableIncludesASection = draggable.classList.contains( 'edit_field_type_divider' ) || draggable.querySelector( '.edit_field_type_divider' ); + const draggableIsEmbedField = draggable.classList.contains( 'edit_field_type_form' ); + const groupIsInASection = null !== group.closest( '.start_divider' ); + if ( groupIsInASection && ( draggableIncludesASection || draggableIsEmbedField ) ) { + // Do not allow a section or an embed field inside of a section. + return false; + } + + return true; + } + + function groupIncludesBreakOrHiddenOrUserId( group ) { + return null !== group.querySelector( '.edit_field_type_break, .edit_field_type_hidden, .edit_field_type_user_id' ); + } + + function groupCanFitAnotherField( fieldsInRow, $field ) { + let fieldId; + if ( fieldsInRow.length < 6 ) { + return true; + } + if ( fieldsInRow.length > 6 ) { + return false; + } + fieldId = $field.attr( 'data-fid' ); + // allow 6 if we're not changing field groups. + return 1 === jQuery( fieldsInRow ).filter( '[data-fid="' + fieldId + '"]' ).length; + } + + function loadFields( fieldId ) { + const thisField = document.getElementById( fieldId ); + const $thisField = jQuery( thisField ); + const field = []; + const addHtmlToField = element => { + const frmHiddenFdata = element.querySelector( '.frm_hidden_fdata' ); + element.classList.add( 'frm_load_now' ); + if ( frmHiddenFdata !== null ) { + field.push( frmHiddenFdata.innerHTML ); + } + }; + + let nextElement = thisField; + addHtmlToField( nextElement ); + + let nextField = getNextField( nextElement ); + while ( nextField && field.length < 15 ) { + addHtmlToField( nextField ); + nextElement = nextField; + nextField = getNextField( nextField ); + } + + jQuery.ajax( { + type: 'POST', + url: ajaxurl, + data: { + action: 'frm_load_field', + field: field, + form_id: thisFormId, + nonce: frmGlobal.nonce + }, + success: html => handleAjaxLoadFieldSuccess( html, $thisField, field ) + } ); + } + + function getNextField( field ) { + if ( field.nextElementSibling ) { + return field.nextElementSibling; + } + return field.parentNode?.closest( '.frm_field_box' )?.nextElementSibling?.querySelector( '.form-field' ); + } + + function handleAjaxLoadFieldSuccess( html, $thisField, field ) { + let key, $nextSet; + + html = html.replace( /^\s+|\s+$/g, '' ); + if ( html.indexOf( '{' ) !== 0 ) { + jQuery( '.frm_load_now' ).removeClass( '.frm_load_now' ).html( 'Error' ); + return; + } + + html = JSON.parse( html ); + for ( key in html ) { + jQuery( '#frm_field_id_' + key ).replaceWith( html[ key ] ); + setupSortable( '#frm_field_id_' + key + '.edit_field_type_divider ul.frm_sorting' ); + makeDraggable( document.getElementById( 'frm_field_id_' + key ) ); + } + + $nextSet = $thisField.nextAll( '.frm_field_loading:not(.frm_load_now)' ); + if ( $nextSet.length ) { + loadFields( $nextSet.attr( 'id' ) ); + } else { + // go up a level + $nextSet = jQuery( document.getElementById( 'frm-show-fields' ) ).find( '.frm_field_loading:not(.frm_load_now)' ); + if ( $nextSet.length ) { + loadFields( $nextSet.attr( 'id' ) ); + } + } + + initiateMultiselect(); + renumberPageBreaks(); + maybeHideQuantityProductFieldOption(); + + const loadedEvent = new Event( 'frm_ajax_loaded_field', { bubbles: false } ); + loadedEvent.frmFields = field.map( f => JSON.parse( f ) ); + document.dispatchEvent( loadedEvent ); + } + + function addFieldClick() { + /*jshint validthis:true */ + const $thisObj = jQuery( this ); + // there is no real way to disable a (with a valid href attribute) in HTML - https://css-tricks.com/how-to-disable-links/ + if ( $thisObj.hasClass( 'disabled' ) ) { + return false; + } + + const $button = $thisObj.closest( '.frmbutton' ); + const fieldType = $button.attr( 'id' ); + + if ( shouldStopInsertingField( fieldType ) ) { + return; + } + + let hasBreak = 0; + if ( 'summary' === fieldType ) { + hasBreak = $newFields.children( 'li[data-type="break"]' ).length > 0 ? 1 : 0; + } + + const formId = thisFormId; + jQuery.ajax( { + type: 'POST', + url: ajaxurl, + data: getInsertNewFieldArgs( fieldType, 0, formId, hasBreak ), + success: function( msg ) { + handleAddFieldClickResponse( msg ); + + const fieldId = checkMsgForFieldId( msg ); + if ( fieldId ) { + /** + * Fires after a field is added. + * + * @since 6.23 + * + * @param {Object} fieldData The field data. + * @param {string} fieldData.field The field HTML. + * @param {string} fieldData.field_type The field type. + * @param {string} fieldData.form_id The form ID. + */ + wp.hooks.doAction( 'frm_after_field_added_in_form_builder', { + field: msg, + fieldId, + fieldType, + form_id: formId, + } ); + } + }, + error: handleInsertFieldError + } ); + return false; + } + + function handleAddFieldClickResponse( msg ) { + document.getElementById( 'frm_form_editor_container' ).classList.add( 'frm-has-fields' ); + const replaceWith = wrapFieldLi( msg ); + const submitField = $newFields[ 0 ].querySelector( '.edit_field_type_submit' ); + + if ( ! submitField ) { + $newFields.append( replaceWith ); + } else { + jQuery( submitField.closest( '.frm_field_box:not(.form-field)' ) ).before( replaceWith ); + } + + afterAddField( msg, true ); + + replaceWith.each( + function() { + makeDroppable( this.querySelector( 'ul.frm_sorting' ) ); + makeDraggable( this.querySelector( '.form-field' ), '.frm-move' ); + } + ); + } + + function insertFormField( fieldType, fieldOptions = {} ) { + return new Promise( resolve => { + const formId = thisFormId; + let hasBreak = 0; + + if ( 'summary' === fieldType ) { + hasBreak = $newFields.children( 'li[data-type="break"]' ).length > 0 ? 1 : 0; + } + + jQuery.ajax( { + type: 'POST', + url: ajaxurl, + data: Object.assign( getInsertNewFieldArgs( fieldType, 0, formId, hasBreak ), { field_options: fieldOptions } ), + success: function( msg ) { + resolve( msg ); + + setTimeout( () => { + updateFieldOrder(); + afterAddField( msg, true ); + + const fieldId = checkMsgForFieldId( msg ); + if ( fieldId ) { + /** + * Fires after a field is added. + * + * @since 6.23 + * + * @param {Object} fieldData The field data. + * @param {string} fieldData.field The field HTML. + * @param {string} fieldData.field_type The field type. + * @param {string} fieldData.form_id The form ID. + */ + wp.hooks.doAction( 'frm_after_field_added_in_form_builder', { + field: msg, + fieldId, + fieldType, + form_id: formId, + } ); + } + }, 10 ); + }, + error: handleInsertFieldError + } ); + } ); + } + + function maybeHideQuantityProductFieldOption() { + let hide = true, + opts = document.querySelectorAll( '.frmjs_prod_field_opt_cont' ); + + if ( $newFields.find( 'li.edit_field_type_product' ).length > 1 ) { + hide = false; + } + + for ( let i = 0; i < opts.length; i++ ) { + if ( hide ) { + opts[ i ].classList.add( 'frm_hidden' ); + } else { + opts[ i ].classList.remove( 'frm_hidden' ); + } + } + } + + /** + * Returns true if a field can be duplicated. + * + * @since 6.19 + * + * @param {HTMLElement} field + * @param {number} maxFieldsInGroup + * + * @return {Boolean} + */ + function canDuplicateField( field, maxFieldsInGroup ) { + if ( field.classList.contains( 'frm-page-collapsed' ) ) { + return false; + } + const fieldGroup = field.closest( 'li.frm_field_box:not(.form-field)' ); + if ( ! fieldGroup ) { + return true; + } + const fieldsInGroup = getFieldsInRow( jQuery( fieldGroup.querySelector( 'ul' ) ) ).length; + return fieldsInGroup < maxFieldsInGroup; + } + + function duplicateField() { + let $field, fieldId, children, newRowId, fieldOrder; + const maxFieldsInGroup = 6; + + $field = jQuery( this ).closest( 'li.form-field' ); + newRowId = this.getAttribute( 'frm-target-row-id' ); + + if ( ! ( newRowId && newRowId.startsWith( 'frm_field_group_' ) ) && ! canDuplicateField( $field.get( 0 ), maxFieldsInGroup ) ) { + /* translators: %1$d: Maximum number of fields allowed in a field group. */ + infoModal( sprintf( __( 'You can only have a maximum of %1$d fields in a field group. Delete or move out a field from the group and try again.', 'formidable' ), maxFieldsInGroup ) ); + return; + } + + closeOpenFieldDropdowns(); + fieldId = $field.data( 'fid' ); + children = fieldsInSection( fieldId ); + + if ( null !== newRowId ) { + fieldOrder = this.getAttribute( 'frm-field-order' ); + } + + jQuery.ajax( { + type: 'POST', + url: ajaxurl, + data: { + action: 'frm_duplicate_field', + field_id: fieldId, + form_id: thisFormId, + children: children, + nonce: frmGlobal.nonce + }, + success: function( msg ) { + let newRow; + + let replaceWith; + + if ( null !== newRowId ) { + newRow = document.getElementById( newRowId ); + if ( null !== newRow ) { + replaceWith = msgAsjQueryObject( msg ); + jQuery( newRow ).append( replaceWith ); + makeDraggable( replaceWith.get( 0 ), '.frm-move' ); + if ( null !== fieldOrder ) { + newRow.lastElementChild.setAttribute( 'frm-field-order', fieldOrder ); + } + jQuery( newRow ).trigger( + 'frm_added_duplicated_field_to_row', + { + duplicatedFieldHtml: msg, + originalFieldId: fieldId + } + ); + afterAddField( msg, false ); + setLayoutClassesForDuplicatedFieldInGroup( $field.get( 0 ), replaceWith.get( 0 ) ); + return; + } + } + + if ( $field.siblings( 'li.form-field' ).length ) { + replaceWith = msgAsjQueryObject( msg ); + $field.after( replaceWith ); + syncLayoutClasses( $field ); + makeDraggable( replaceWith.get( 0 ), '.frm-move' ); + } else { + replaceWith = wrapFieldLi( msg ); + $field.parent().parent().after( replaceWith ); + makeDroppable( replaceWith.get( 0 ).querySelector( 'ul.frm_sorting' ) ); + makeDraggable( replaceWith.get( 0 ).querySelector( 'li.form-field' ), '.frm-move' ); + } + + updateFieldOrder(); + afterAddField( msg, false ); + maybeDuplicateUnsavedSettings( fieldId, msg ); + toggleOneSectionHolder( replaceWith.find( '.start_divider' ) ); + $field[ 0 ].querySelector( '.frm-dropdown-menu.dropdown-menu-right' )?.classList.remove( 'show' ); + setLayoutClassesForDuplicatedFieldInGroup( $field.get( 0 ), replaceWith.get( 0 ) ); + } + } ); + return false; + } + + /** + * Sets the layout classes for a duplicated field in a field group from the layout classes of the original field. + * + * @param {HTMLElement} field The original field. + * @param {HTMLElement} newField The duplicated field. + * + * @return {void} + */ + function setLayoutClassesForDuplicatedFieldInGroup( field, newField ) { + const hoverTarget = field.closest( '.frm-field-group-hover-target' ); + if ( ! hoverTarget || ! isFieldGroup( hoverTarget.parentElement ) ) { + return; + } + const fieldId = field.dataset.fid; + let fieldClasses = document.getElementById( 'frm_classes_' + fieldId )?.value; + if ( ! fieldClasses ) { + return; + } + fieldClasses = fieldClasses.replace( 'frm_first', '' ); + if ( ! newField.className.includes( fieldClasses ) ) { + newField.className += ' ' + fieldClasses; + + const classesInput = document.getElementById( 'frm_classes_' + newField.dataset.fid ); + if ( classesInput ) { + classesInput.value = fieldClasses; + } + } + } + + function maybeDuplicateUnsavedSettings( originalFieldId, newFieldHtml ) { + let originalSettings, newFieldId, copySettings, fieldOptionKeys, originalDefault, copyDefault; + + originalSettings = document.getElementById( 'frm-single-settings-' + originalFieldId ); + if ( null === originalSettings ) { + return; + } + + newFieldId = jQuery( newFieldHtml ).attr( 'data-fid' ); + if ( 'undefined' === typeof newFieldId ) { + return; + } + + copySettings = document.getElementById( 'frm-single-settings-' + newFieldId ); + if ( null === copySettings ) { + return; + } + + fieldOptionKeys = [ + 'name', 'required', 'unique', 'read_only', 'placeholder', 'description', 'size', 'max', 'format', 'prepend', 'append', 'separate_value' + ]; + + originalSettings.querySelectorAll( 'input[name^="field_options["], textarea[name^="field_options["]' ).forEach( + function( originalSetting ) { + let key, tagType, copySetting; + + key = getKeyFromSettingInput( originalSetting ); + + if ( 'options' === key ) { + copyOption( originalSetting, copySettings, originalFieldId, newFieldId ); + return; + } + + if ( -1 === fieldOptionKeys.indexOf( key ) ) { + return; + } + + tagType = originalSetting.matches( 'input' ) ? 'input' : 'textarea'; + copySetting = copySettings.querySelector( tagType + '[name="field_options[' + key + '_' + newFieldId + ']"]' ); + if ( null === copySetting ) { + return; + } + + if ( 'checkbox' === originalSetting.type ) { + if ( originalSetting.checked !== copySetting.checked ) { + jQuery( copySetting ).trigger( 'click' ); + } + } else if ( 'text' === originalSetting.type || 'textarea' === tagType ) { + if ( originalSetting.value !== copySetting.value ) { + copySetting.value = originalSetting.value; + jQuery( copySetting ).trigger( 'change' ); + } + } + } + ); + + originalDefault = originalSettings.querySelector( 'input[name="default_value_' + originalFieldId + '"]' ); + if ( null !== originalDefault ) { + copyDefault = copySettings.querySelector( 'input[name="default_value_' + newFieldId + '"]' ); + if ( null !== copyDefault && originalDefault.value !== copyDefault.value ) { + copyDefault.value = originalDefault.value; + jQuery( copyDefault ).trigger( 'change' ); + } + } + } + + function copyOption( originalSetting, copySettings, originalFieldId, newFieldId ) { + let remainingKeyDetails, copyKey, copySetting; + remainingKeyDetails = originalSetting.name.substr( 23 + ( '' + originalFieldId ).length ); + copyKey = 'field_options[options_' + newFieldId + ']' + remainingKeyDetails; + copySetting = copySettings.querySelector( 'input[name="' + copyKey + '"]' ); + if ( null !== copySetting && copySetting.value !== originalSetting.value ) { + copySetting.value = originalSetting.value; + jQuery( copySetting ).trigger( 'change' ); + } + } + + function getKeyFromSettingInput( input ) { + let nameWithoutPrefix, nameSplit; + nameWithoutPrefix = input.name.substr( 14 ); + nameSplit = nameWithoutPrefix.split( '_' ); + nameSplit.pop(); + return nameSplit.join( '_' ); + } + + function closeOpenFieldDropdowns() { + const openSettings = document.querySelector( '.frm-field-settings-open' ); + if ( null !== openSettings ) { + openSettings.classList.remove( 'frm-field-settings-open' ); + jQuery( document ).off( 'click', '#frm_builder_page', handleClickOutsideOfFieldSettings ); + jQuery( '.frm-field-action-icons .dropdown.open' ).removeClass( 'open' ); + } + } + + function handleClickOutsideOfFieldSettings( event ) { + if ( ! jQuery( event.originalEvent.target ).closest( '.frm-field-action-icons' ).length ) { + closeOpenFieldDropdowns(); + } + } + + function checkForMultiselectKeysOnMouseMove( event ) { + const keyIsDown = ! ! ( event.ctrlKey || event.metaKey || event.shiftKey ); + jQuery( builderPage ).toggleClass( 'frm-multiselect-key-is-down', keyIsDown ); + checkForActiveHoverTarget( event ); + } + + function checkForActiveHoverTarget( event ) { + let container, elementFromPoint, list, previousHoverTarget; + + container = postBodyContent; + if ( container.classList.contains( 'frm-dragging-field' ) ) { + return; + } + + if ( null !== document.querySelector( '.frm-field-group-hover-target .frm-field-settings-open' ) ) { + // do not set a hover target if a dropdown is open for the current hover target. + return; + } + + elementFromPoint = document.elementFromPoint( event.clientX, event.clientY ); + if ( null !== elementFromPoint && ! elementFromPoint.classList.contains( 'edit_field_type_divider' ) ) { + list = elementFromPoint.closest( 'ul.frm_sorting' ); + + if ( null !== list && ! list.classList.contains( 'start_divider' ) && 'frm-show-fields' !== list.id ) { + previousHoverTarget = maybeRemoveGroupHoverTarget(); + if ( false !== previousHoverTarget && ! jQuery( previousHoverTarget ).is( list ) ) { + destroyFieldGroupPopup(); + } + updateFieldGroupControls( jQuery( list ), getFieldsInRow( jQuery( list ) ).length ); + list.classList.add( 'frm-field-group-hover-target' ); + jQuery( '#wpbody-content' ).on( 'mousemove', maybeRemoveHoverTargetOnMouseMove ); + } + } + } + + function maybeRemoveGroupHoverTarget() { + let controls, previousHoverTarget; + + controls = document.getElementById( 'frm_field_group_controls' ); + if ( null !== controls ) { + controls.style.display = 'none'; + } + + previousHoverTarget = document.querySelector( '.frm-field-group-hover-target' ); + if ( null === previousHoverTarget ) { + return false; + } + + jQuery( '#wpbody-content' ).off( 'mousemove', maybeRemoveHoverTargetOnMouseMove ); + previousHoverTarget.classList.remove( 'frm-field-group-hover-target' ); + return previousHoverTarget; + } + + function maybeRemoveHoverTargetOnMouseMove( event ) { + const elementFromPoint = document.elementFromPoint( event.clientX, event.clientY ); + if ( null !== elementFromPoint && null !== elementFromPoint.closest( '#frm-show-fields' ) ) { + return; + } + maybeRemoveGroupHoverTarget(); + } + + function onFieldActionDropdownShow( isFieldGroup ) { + unselectFieldGroups(); + // maybe offset the dropdown if it goes off of the right of the screen. + setTimeout( + function() { + let ul, $ul; + ul = document.querySelector( '.dropdown.show .frm-dropdown-menu' ); + if ( null === ul ) { + return; + } + if ( null === ul.getAttribute( 'aria-label' ) ) { + ul.setAttribute( 'aria-label', __( 'More Options', 'formidable' ) ); + } + if ( 0 === ul.children.length ) { + fillFieldActionDropdown( ul, true === isFieldGroup ); + } + $ul = jQuery( ul ); + if ( $ul.offset().left > jQuery( window ).width() - $ul.outerWidth() ) { + ul.style.left = ( -$ul.outerWidth() ) + 'px'; + } + const firstAnchor = ul.firstElementChild.querySelector( 'a' ); + if ( firstAnchor ) { + firstAnchor.focus(); + } + }, + 0 + ); + } + + function onFieldGroupActionDropdownShow() { + onFieldActionDropdownShow( true ); + } + + function changeSectionStyle( e ) { + const collapsedSection = e.target.closest( '.frm-section-collapsed' ); + if ( ! collapsedSection ) { + return; + } + + if ( e.type === 'show' ) { + collapsedSection.style.zIndex = 3; + } else { + collapsedSection.style.zIndex = 1; + } + } + + function fillFieldActionDropdown( ul, isFieldGroup ) { + let classSuffix, options; + classSuffix = isFieldGroup ? '_field_group' : '_field'; + options = [ getDeleteActionOption( isFieldGroup ), getDuplicateActionOption( isFieldGroup ) ]; + if ( ! isFieldGroup ) { + options.push( + { class: 'frm_select', icon: 'frm_settings_icon', label: __( 'Field Settings', 'formidable' ) } + ); + } + options.forEach( + function( option ) { + let li, anchor, span; + li = document.createElement( 'div' ); + li.classList.add( 'frm_more_options_li', 'dropdown-item' ); + + anchor = document.createElement( 'a' ); + anchor.classList.add( option.class + classSuffix ); + anchor.setAttribute( 'href', '#' ); + makeTabbable( anchor ); + + span = document.createElement( 'span' ); + span.textContent = option.label; + anchor.innerHTML = ''; + anchor.appendChild( document.createTextNode( ' ' ) ); + anchor.appendChild( span ); + + li.appendChild( anchor ); + ul.appendChild( li ); + } + ); + } + + function getDeleteActionOption( isFieldGroup ) { + const option = { class: 'frm_delete', icon: 'frm_delete_icon' }; + option.label = isFieldGroup ? __( 'Delete Group', 'formidable' ) : __( 'Delete', 'formidable' ); + return option; + } + + function getDuplicateActionOption( isFieldGroup ) { + const option = { class: 'frm_clone', icon: 'frm_clone_icon' }; + option.label = isFieldGroup ? __( 'Duplicate Group', 'formidable' ) : __( 'Duplicate', 'formidable' ); + return option; + } + + function wrapFieldLi( field ) { + const wrapper = div(); + + if ( 'string' === typeof field ) { + wrapper.innerHTML = field; + } else { + wrapper.appendChild( field ); + } + + let result = jQuery(); + Array.from( wrapper.children ).forEach( + li => { + result = result.add( + jQuery( '
            • ' ) + .addClass( 'frm_field_box' ) + .html( + jQuery( '
                ' ).addClass( 'frm_grid_container frm_sorting' ).append( li ) + ) + ); + } + ); + + return result; + } + + function wrapFieldLiInPlace( li ) { + const ul = tag( + 'ul', + { + className: 'frm_grid_container frm_sorting' + } + ); + const wrapper = tag( + 'li', + { + className: 'frm_field_box', + child: ul + } + ); + + li.replaceWith( wrapper ); + ul.appendChild( li ); + + makeDroppable( ul ); + makeDraggable( wrapper, '.frm-move' ); + } + + function afterAddField( msg, addFocus ) { + const regex = /id="(\S+)"/; + const match = regex.exec( msg ); + const field = document.getElementById( match[ 1 ] ); + const section = '#' + match[ 1 ] + '.edit_field_type_divider ul.frm_sorting.start_divider'; + const $thisSection = jQuery( section ); + const type = field.getAttribute( 'data-type' ); + + checkHtmlForNewFields( msg ); + + let toggled = false; + + fieldUpdated(); + setupSortable( section ); + + if ( 'quantity' === type ) { + // try to automatically attach a product field + maybeSetProductField( field ); + } + + if ( 'product' === type || 'quantity' === type ) { + // quantity too needs to be a part of the if stmt especially cos of the very + // 1st quantity field (or even if it's just one quantity field in the form). + maybeHideQuantityProductFieldOption(); + } + + if ( $thisSection.length ) { + $thisSection.parent( '.frm_field_box' ).children( '.frm_no_section_fields' ).addClass( 'frm_block' ); + } else { + const $parentSection = jQuery( field ).closest( 'ul.frm_sorting.start_divider' ); + if ( $parentSection.length ) { + toggleOneSectionHolder( $parentSection ); + toggled = true; + } + } + + if ( msg.indexOf( 'frm-collapse-page' ) !== -1 ) { + renumberPageBreaks(); + } + + addClass( field, 'frm-newly-added' ); + setTimeout( function() { + field.classList.remove( 'frm-newly-added' ); + }, 1000 ); + + if ( addFocus ) { + const bounding = field.getBoundingClientRect(), + container = document.getElementById( 'post-body-content' ), + inView = ( bounding.top >= 0 && + bounding.left >= 0 && + bounding.right <= ( window.innerWidth || document.documentElement.clientWidth ) && + bounding.bottom <= ( window.innerHeight || document.documentElement.clientHeight ) + ); + + if ( ! inView ) { + container.scroll( { + top: container.scrollHeight, + left: 0, + behavior: 'smooth' + } ); + } + + if ( toggled === false ) { + toggleOneSectionHolder( $thisSection ); + } + } + + deselectFields(); + initiateMultiselect(); + + document.getElementById( 'frm-show-fields' ).classList.remove( 'frm-over-droppable' ); + + const addedEvent = new Event( 'frm_added_field', { bubbles: false } ); + addedEvent.frmField = field; + addedEvent.frmSection = section; + addedEvent.frmType = type; + addedEvent.frmToggles = toggled; + document.dispatchEvent( addedEvent ); + } + + /** + * Since multiple new fields may get added when a new field is inserted, check the HTML. + * + * @param {string} html + * @return {void} + */ + function checkHtmlForNewFields( html ) { + const element = div(); + element.innerHTML = html; + element.querySelectorAll( '.form-field' ).forEach( addFieldIdToDraftFieldsInput ); + } + + /** + * @param {HTMLElement} field + * @return {void} + */ + function addFieldIdToDraftFieldsInput( field ) { + if ( ! field.dataset.fid ) { + return; + } + + const draftInput = document.getElementById( 'draft_fields' ); + if ( ! draftInput ) { + return; + } + + if ( '' === draftInput.value ) { + draftInput.value = field.dataset.fid; + } else { + const split = draftInput.value.split( ',' ); + if ( ! split.includes( field.dataset.fid ) ) { + draftInput.value += ',' + field.dataset.fid; + } + } + } + + function clearSettingsBox( preventFieldGroups ) { + jQuery( '#new_fields .frm-single-settings' ).addClass( 'frm_hidden' ); + jQuery( '#frm-options-panel > .frm-single-settings' ).removeClass( 'frm_hidden' ); + deselectFields( preventFieldGroups ); + } + + function deselectFields( preventFieldGroups ) { + jQuery( 'li.ui-state-default.selected' ).removeClass( 'selected' ); + jQuery( '.frm-show-field-settings.selected' ).removeClass( 'selected' ); + if ( ! preventFieldGroups ) { + unselectFieldGroups(); + } + } + + function scrollToField( field ) { + const newPos = field.getBoundingClientRect().top, + container = document.getElementById( 'post-body-content' ); + + if ( typeof animate === 'undefined' ) { + jQuery( container ).scrollTop( newPos ); + } else { + // TODO: smooth scroll + jQuery( container ).animate( { scrollTop: newPos }, 500 ); + } + } + + function checkCalculationCreatedByUser() { + const calculation = this.value; + let warningMessage = checkMatchingParens( calculation ); + warningMessage += checkShortcodes( calculation, this ); + + if ( warningMessage !== '' ) { + infoModal( calculation + '\n\n' + warningMessage ); + } + } + + /** + * Checks a string for parens, brackets, and curly braces and returns a message if any unmatched are found. + * @param formula + * @return {string} + */ + function checkMatchingParens( formula ) { + let stack = [], + formulaArray = formula.split( '' ), + length = formulaArray.length, + opening = [ '{', '[', '(' ], + closing = { + '}': '{', + ')': '(', + ']': '[' + }, + unmatchedClosing = [], + msg = '', + i, top; + + for ( i = 0; i < length; i++ ) { + if ( opening.includes( formulaArray[ i ] ) ) { + stack.push( formulaArray[ i ] ); + continue; + } + if ( closing.hasOwnProperty( formulaArray[ i ] ) ) { + top = stack.pop(); + if ( top !== closing[ formulaArray[ i ] ] ) { + unmatchedClosing.push( formulaArray[ i ] ); + } + } + } + + if ( stack.length > 0 || unmatchedClosing.length > 0 ) { + msg = frmAdminJs.unmatched_parens + '\n\n'; + return msg; + } + + return ''; + } + + /** + * Checks a calculation for shortcodes that shouldn't be in it and returns a message if found. + * @param calculation + * @param inputElement + * @return {string} + */ + function checkShortcodes( calculation, inputElement ) { + let msg = checkNonNumericShortcodes( calculation, inputElement ); + msg += checkNonFormShortcodes( calculation ); + + return msg; + } + + /** + * Checks if a numeric calculation has shortcodes that output non-numeric strings and returns a message if found. + * @param calculation + * + * @param inputElement + * @return {string} + */ + function checkNonNumericShortcodes( calculation, inputElement ) { + let msg = ''; + + if ( isTextCalculation( inputElement ) ) { + return msg; + } + + const nonNumericShortcodes = getNonNumericShortcodes(); + + if ( nonNumericShortcodes.test( calculation ) ) { + msg = frmAdminJs.text_shortcodes + '\n\n'; + } + + return msg; + } + + /** + * Determines if the calculation input is from a text calculation. + * + * @param inputElement + */ + function isTextCalculation( inputElement ) { + return jQuery( inputElement ).siblings( 'label[for^="calc_type"]' ).children( 'input' ).prop( 'checked' ); + } + + /** + * Returns a regular expression of shortcodes that can't be used in numeric calculations. + * @return {RegExp} + */ + function getNonNumericShortcodes() { + return /\[(date|time|email|ip)\]/; + } + + /** + * Checks if a string has any shortcodes that do not belong in forms and returns a message if any are found. + * @param formula + * @return {string} + */ + function checkNonFormShortcodes( formula ) { + let nonFormShortcodes = getNonFormShortcodes(), + msg = ''; + + if ( nonFormShortcodes.test( formula ) ) { + msg += frmAdminJs.view_shortcodes + '\n\n'; + } + + return msg; + } + + /** + * Returns a regular expression of shortcodes that can't be used in forms but can be used in Views, Email + * Notifications, and other Formidable areas. + * + * @return {RegExp} + */ + function getNonFormShortcodes() { + return /\[id\]|\[key\]|\[if\s\w+\]|\[foreach\s\w+\]|\[created-at(\s*)?/g; + } + + function isCalcBoxType( box, listClass ) { + const list = jQuery( box ).find( '.frm_code_list' ); + return 1 === list.length && list.hasClass( listClass ); + } + + function extractExcludedOptions( exclude ) { + const opts = []; + if ( ! Array.isArray( exclude ) ) { + return opts; + } + + for ( let i = 0; i < exclude.length; i++ ) { + if ( exclude[ i ].startsWith( '[' ) ) { + opts.push( exclude[ i ] ); + // remove it + exclude.splice( i, 1 ); + // https://love2dev.com/blog/javascript-remove-from-array/#remove-from-array-splice-value + i--; + } + } + + return opts; + } + + function hasExcludedOption( field, excludedOpts ) { + let hasOption = false; + for ( let i = 0; i < excludedOpts.length; i++ ) { + const inputs = document.getElementsByName( getFieldOptionInputName( excludedOpts[ i ], field.fieldId ) ); + // 2nd condition checks that there's at least one non-empty value + if ( inputs.length && jQuery( inputs[ 0 ] ).val() ) { + hasOption = true; + break; + } + } + return hasOption; + } + + function getFieldOptionInputName( opt, fieldId ) { + const at = opt.indexOf( ']' ); + return 'field_options' + opt.substring( 0, at ) + '_' + fieldId + opt.substring( at ); + } + + function popCalcFields( v, force ) { + let box, exclude, fields, i, list, + p = jQuery( v ).closest( '.frm-single-settings' ), + calc = p.find( '.frm-calc-field' ); + + if ( ! force && ( ! calc.length || calc.val() === '' || calc.is( ':hidden' ) ) ) { + return; + } + + const isSummary = isCalcBoxType( v, 'frm_js_summary_list' ); + + const fieldId = p.find( 'input[name="frm_fields_submitted[]"]' ).val(); + + if ( force ) { + box = v; + } else { + box = document.getElementById( 'frm-calc-box-' + fieldId ); + } + + exclude = getExcludeArray( box, isSummary ); + const excludedOpts = extractExcludedOptions( exclude ); + + fields = getFieldList(); + list = document.getElementById( 'frm-calc-list-' + fieldId ); + list.innerHTML = ''; + + for ( i = 0; i < fields.length; i++ ) { + if ( ( exclude && exclude.includes( fields[ i ].fieldType ) ) || + ( excludedOpts.length && hasExcludedOption( fields[ i ], excludedOpts ) ) ) { + continue; + } + + const span = document.createElement( 'span' ); + span.appendChild( document.createTextNode( '[' + fields[ i ].fieldId + ']' ) ); + + const a = document.createElement( 'a' ); + a.setAttribute( 'href', '#' ); + a.setAttribute( 'data-code', fields[ i ].fieldId ); + a.classList.add( 'frm_insert_code' ); + a.appendChild( span ); + a.appendChild( document.createTextNode( fields[ i ].fieldName ) ); + + const li = document.createElement( 'li' ); + li.classList.add( 'frm-field-list-' + fieldId ); + li.classList.add( 'frm-field-list-' + fields[ i ].fieldType ); + li.appendChild( a ); + list.appendChild( li ); + } + } + + function getExcludeArray( calcBox, isSummary ) { + const exclude = JSON.parse( calcBox.getElementsByClassName( 'frm_code_list' )[ 0 ].getAttribute( 'data-exclude' ) ); + + if ( isSummary ) { + // includedExtras are those that are normally excluded from the summary but the form owner can choose to include, + // when they have been chosen to be included, then they can now be manually excluded in the calc box. + const includedExtras = getIncludedExtras(); + if ( includedExtras.length ) { + for ( let i = 0; i < exclude.length; i++ ) { + if ( includedExtras.includes( exclude[ i ] ) ) { + // remove it + exclude.splice( i, 1 ); + // https://love2dev.com/blog/javascript-remove-from-array/#remove-from-array-splice-value + i--; + } + } + } + } + + return exclude; + } + + function getIncludedExtras() { + const checked = []; + const checkboxes = document.getElementsByClassName( 'frm_include_extras_field' ); + + for ( let i = 0; i < checkboxes.length; i++ ) { + if ( checkboxes[ i ].checked ) { + checked.push( checkboxes[ i ].value ); + } + } + + return checked; + } + + function rePopCalcFieldsForSummary() { + popCalcFields( jQuery( '.frm-inline-modal.postbox:has(.frm_js_summary_list)' )[ 0 ], true ); + } + + function getFieldList( fieldType ) { + let i, + fields = [], + allFields = document.querySelectorAll( 'li.frm_field_box' ), + checkType = 'undefined' !== typeof fieldType; + + for ( i = 0; i < allFields.length; i++ ) { + // data-ftype is better (than data-type) cos of fields loaded by AJAX - which might not be ready yet + if ( checkType && allFields[ i ].getAttribute( 'data-ftype' ) !== fieldType ) { + continue; + } + + const fieldId = allFields[ i ].getAttribute( 'data-fid' ); + if ( typeof fieldId !== 'undefined' && fieldId ) { + fields.push( { + fieldId: fieldId, + fieldName: getPossibleValue( 'frm_name_' + fieldId ), + fieldType: getPossibleValue( 'field_options_type_' + fieldId ), + fieldKey: getPossibleValue( 'field_options_field_key_' + fieldId ) + } ); + } + } + + return wp.hooks.applyFilters( 'frm_admin_get_field_list', fields, fieldType, allFields ); + } + + function popProductFields( field ) { + let i, checked, id, + options = [], + current = getCurrentProductFields( field ), + fName = field.getAttribute( 'data-frmfname' ), + products = getFieldList( 'product' ), + quantities = getFieldList( 'quantity' ), + isSelect = field.tagName === 'SELECT', // for reverse compatibility. + // whether we have just 1 product and 1 quantity field & should therefore attach the latter to the former + auto = 1 === quantities.length && 1 === products.length; + + if ( isSelect ) { + // This fallback can be removed after 4.05. + current = field.getAttribute( 'data-frmcurrent' ); + } + + for ( i = 0; i < products.length; i++ ) { + // let's be double sure it's string, else indexOf will fail + id = products[ i ].fieldId.toString(); + checked = auto || -1 !== current.indexOf( id ); + if ( isSelect ) { + // This fallback can be removed after 4.05. + checked = checked ? ' selected' : ''; + options.push( '' ); + } else { + checked = checked ? ' checked' : ''; + options.push( '' ); + } + } + + field.innerHTML = options.join( '' ); + } + + function getCurrentProductFields( prodFieldOpt ) { + const products = prodFieldOpt.querySelectorAll( '[type="checkbox"]:checked' ), + idsArray = []; + + for ( let i = 0; i < products.length; i++ ) { + idsArray.push( products[ i ].value ); + } + + return idsArray; + } + + function popAllProductFields() { + const opts = document.querySelectorAll( '.frmjs_prod_field_opt' ); + for ( let i = 0; i < opts.length; i++ ) { + popProductFields( opts[ i ] ); + } + } + + function maybeSetProductField( field ) { + const fieldId = field.getAttribute( 'data-fid' ), + productFieldOpt = document.getElementById( 'field_options[product_field_' + fieldId + ']' ); + + if ( null === productFieldOpt ) { + return; + } + + popProductFields( productFieldOpt ); + // in order to move its settings to that LHS panel where + // the update form resides, else it'll lose this setting + moveFieldSettings( document.getElementById( 'frm-single-settings-' + fieldId ) ); + } + + /** + * If the element doesn't exist, use a blank value. + */ + function getPossibleValue( id ) { + const field = document.getElementById( id ); + if ( field !== null ) { + return field.value; + } + return ''; + } + + function liveChanges() { + /*jshint validthis:true */ + let option, + newValue = this.value, + changes = document.getElementById( this.getAttribute( 'data-changeme' ) ), + att = this.getAttribute( 'data-changeatt' ); + + if ( changes === null ) { + return; + } + + if ( att !== null ) { + if ( changes.tagName === 'SELECT' && att === 'placeholder' ) { + option = changes.options[ 0 ]; + if ( option.value === '' ) { + option.innerHTML = newValue; + } else { + // Create a placeholder option if there are no blank values. + addBlankSelectOption( changes, newValue ); + } + } else if ( att === 'class' ) { + changeFieldClass( changes, this ); + } else if ( isSliderField( changes ) ) { + updateSliderFieldPreview( changes, att, newValue ); + } else { + changes.setAttribute( att, newValue ); + } + } else if ( changes.id.indexOf( 'setup-message' ) === 0 ) { + if ( newValue !== '' ) { + changes.innerHTML = ''; + } + } else { + changes.innerHTML = purifyHtml( newValue ); + if ( 'TEXTAREA' === changes.nodeName && changes.classList.contains( 'wp-editor-area' ) ) { + // Trigger change events on wysiwyg textareas so we can also sync default values in the visual tab. + jQuery( changes ).trigger( 'change' ); + } + + if ( changes.classList.contains( 'frm_primary_label' ) && 'break' === changes.nextElementSibling.getAttribute( 'data-ftype' ) ) { + changes.nextElementSibling.querySelector( '.frm_button_submit' ).textContent = newValue; + } + } + } + + function updateSliderFieldPreview( field, att, newValue ) { + if ( frmGlobal.proIncludesSliderJs ) { + const hookName = 'frm_update_slider_field_preview'; + const hookArgs = { field, att, newValue }; + wp.hooks.doAction( hookName, hookArgs ); + return; + } + + // This functionality has been moved to pro since v5.4.3. This code should be removed eventually. + if ( 'value' === att ) { + if ( '' === newValue ) { + newValue = getSliderMidpoint( field ); + } + field.value = newValue; + } else { + field.setAttribute( att, newValue ); + } + + if ( -1 === [ 'value', 'min', 'max' ].indexOf( att ) ) { + return; + } + + if ( ( 'max' === att || 'min' === att ) && '' === getSliderDefaultValueInput( field.id ) ) { + field.value = getSliderMidpoint( field ); + } + + field.parentNode.querySelector( '.frm_range_value' ).textContent = field.value; + } + + function getSliderDefaultValueInput( previewInputId ) { + return document.querySelector( 'input[data-changeme="' + previewInputId + '"][data-changeatt="value"]' ).value; + } + + function getSliderMidpoint( sliderInput ) { + const max = parseFloat( sliderInput.getAttribute( 'max' ) ); + const min = parseFloat( sliderInput.getAttribute( 'min' ) ); + return ( ( max - min ) / 2 ) + min; + } + + function isSliderField( previewInput ) { + return 'range' === previewInput.type && previewInput.parentNode.classList.contains( 'frm_range_container' ); + } + + function toggleInvalidMsg() { + /*jshint validthis:true */ + let typeDropdown, fieldType, + fieldId = this.getAttribute( 'data-fid' ), + value = ''; + + [ 'field_options_max_', 'frm_format_' ].forEach( function( id ) { + const input = document.getElementById( id + fieldId ); + if ( ! input ) { + return; + } + + value += input.value; + } ); + + typeDropdown = document.getElementsByName( 'field_options[type_' + fieldId + ']' )[ 0 ]; + fieldType = typeDropdown.options[ typeDropdown.selectedIndex ].value; + + if ( fieldType === 'text' ) { + toggleValidationBox( '' !== value, '.frm_invalid_msg' + fieldId ); + } + } + + function markRequired() { + /*jshint validthis:true */ + const thisid = this.id.replace( 'frm_', '' ), + fieldId = thisid.replace( 'req_field_', '' ), + checked = this.checked, + label = jQuery( '#field_label_' + fieldId + ' .frm_required' ); + + toggleValidationBox( checked, '.frm_required_details' + fieldId ); + + if ( checked ) { + const $reqBox = jQuery( 'input[name="field_options[required_indicator_' + fieldId + ']"]' ); + if ( $reqBox.val() === '' ) { + $reqBox.val( '*' ); + } + label.removeClass( 'frm_hidden' ); + } else { + label.addClass( 'frm_hidden' ); + } + } + + function toggleValidationBox( hasValue, messageClass ) { + $msg = jQuery( messageClass ); + if ( hasValue ) { + $msg.fadeIn( 'fast' ).closest( '.frm_validation_msg' ).fadeIn( 'fast' ); + } else { + //Fade out validation options + const v = $msg.fadeOut( 'fast' ).closest( '.frm_validation_box' ).children( ':not(' + messageClass + '):visible' ).length; + if ( v === 0 ) { + $msg.closest( '.frm_validation_msg' ).fadeOut( 'fast' ); + } + } + } + + function markUnique() { + /*jshint validthis:true */ + const fieldId = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ); + const $thisField = jQuery( '.frm_unique_details' + fieldId ); + if ( this.checked ) { + $thisField.fadeIn( 'fast' ).closest( '.frm_validation_msg' ).fadeIn( 'fast' ); + $unqDetail = jQuery( '.frm_unique_details' + fieldId + ' input' ); + if ( $unqDetail.val() === '' ) { + $unqDetail.val( frmAdminJs.default_unique ); + } + } else { + const v = $thisField.fadeOut( 'fast' ).closest( '.frm_validation_box' ).children( ':not(.frm_unique_details' + fieldId + '):visible' ).length; + if ( v === 0 ) { + $thisField.closest( '.frm_validation_msg' ).fadeOut( 'fast' ); + } + } + } + + //Fade confirmation field and validation option in or out + function addConf() { + /*jshint validthis:true */ + const fieldId = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ); + const val = jQuery( this ).val(); + const $thisField = jQuery( document.getElementById( 'frm_field_id_' + fieldId ) ); + + toggleValidationBox( val !== '', '.frm_conf_details' + fieldId ); + + if ( val !== '' ) { + //Add default validation message if empty + const valMsg = jQuery( '.frm_validation_box .frm_conf_details' + fieldId + ' input' ); + if ( valMsg.val() === '' ) { + valMsg.val( frmAdminJs.default_conf ); + } + + setConfirmationFieldDescriptions( fieldId ); + + //Add or remove class for confirmation field styling + if ( val === 'inline' ) { + $thisField.removeClass( 'frm_conf_below' ).addClass( 'frm_conf_inline' ); + } else if ( val === 'below' ) { + $thisField.removeClass( 'frm_conf_inline' ).addClass( 'frm_conf_below' ); + } + jQuery( '.frm-conf-box-' + fieldId ).removeClass( 'frm_hidden' ); + } else { + jQuery( '.frm-conf-box-' + fieldId ).addClass( 'frm_hidden' ); + setTimeout( function() { + $thisField.removeClass( 'frm_conf_inline frm_conf_below' ); + }, 200 ); + } + } + + function setConfirmationFieldDescriptions( fieldId ) { + const fieldType = document.getElementsByName( 'field_options[type_' + fieldId + ']' )[ 0 ].value; + + const fieldDescription = document.getElementById( 'field_description_' + fieldId ); + const hiddenDescName = 'field_options[description_' + fieldId + ']'; + const newValue = frmAdminJs[ 'enter_' + fieldType ]; + maybeSetNewDescription( fieldDescription, hiddenDescName, newValue ); + + const confFieldDescription = document.getElementById( 'conf_field_description_' + fieldId ); + const hiddenConfName = 'field_options[conf_desc_' + fieldId + ']'; + const newConfValue = frmAdminJs[ 'confirm_' + fieldType ]; + maybeSetNewDescription( confFieldDescription, hiddenConfName, newConfValue ); + } + + function maybeSetNewDescription( descriptionDiv, hiddenName, newValue ) { + if ( descriptionDiv.innerHTML === frmAdminJs.desc ) { + // Set the visible description value and the hidden description value + descriptionDiv.innerHTML = newValue; + document.getElementsByName( hiddenName )[ 0 ].value = newValue; + } + } + + function initBulkOptionsOverlay() { + /*jshint validthis:true */ + const $info = initModal( '#frm-bulk-modal', '700px' ); + if ( $info === false ) { + return; + } + + jQuery( '.frm-insert-preset' ).on( 'click', insertBulkPreset ); + + jQuery( builderForm ).on( 'click', 'a.frm-bulk-edit-link', function( event ) { + event.preventDefault(); + let i, key, label, + content = '', + optList, + opts, + fieldId = jQuery( this ).closest( '[data-fid]' ).data( 'fid' ), + separate = usingSeparateValues( fieldId ), + product = isProductField( fieldId ); + + optList = document.getElementById( 'frm_field_' + fieldId + '_opts' ); + if ( ! optList ) { + return; + } + + opts = optList.getElementsByTagName( 'li' ); + + document.getElementById( 'bulk-field-id' ).value = fieldId; + + for ( i = 0; i < opts.length; i++ ) { + key = opts[ i ].getAttribute( 'data-optkey' ); + if ( key !== '000' ) { + label = document.getElementsByName( 'field_options[options_' + fieldId + '][' + key + '][label]' )[ 0 ]; + if ( typeof label !== 'undefined' ) { + content += label.value; + if ( separate ) { + content += '|' + document.getElementsByName( 'field_options[options_' + fieldId + '][' + key + '][value]' )[ 0 ].value; + } + if ( product ) { + content += '|' + document.getElementsByName( 'field_options[options_' + fieldId + '][' + key + '][price]' )[ 0 ].value; + } + content += '\r\n'; + } + } + + if ( i >= opts.length - 1 ) { + document.getElementById( 'frm_bulk_options' ).value = content; + } + } + + $info.dialog( 'open' ); + + return false; + } ); + + jQuery( '#frm-update-bulk-opts' ).on( 'click', function() { + const fieldId = document.getElementById( 'bulk-field-id' ).value; + const optionType = document.getElementById( 'bulk-option-type' ).value; + + if ( optionType ) { + // Use custom handler for custom option type. + return; + } + + this.classList.add( 'frm_loading_button' ); + frmAdminBuild.updateOpts( fieldId, document.getElementById( 'frm_bulk_options' ).value, $info ); + fieldUpdated(); + } ); + } + + function insertBulkPreset( event ) { + /*jshint validthis:true */ + const opts = JSON.parse( this.getAttribute( 'data-opts' ) ); + event.preventDefault(); + document.getElementById( 'frm_bulk_options' ).value = opts.join( '\n' ); + return false; + } + + //Add new option or "Other" option to radio/checkbox/dropdown + function addFieldOption() { + /*jshint validthis:true */ + let fieldId = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ), + newOption = jQuery( '#frm_field_' + fieldId + '_opts .frm_option_template' ).prop( 'outerHTML' ), + optType = jQuery( this ).data( 'opttype' ), + optKey = 0, + oldKey = '000', + lastKey = getHighestOptKey( fieldId ); + + if ( lastKey !== oldKey ) { + optKey = lastKey + 1; + } + + //Update hidden field + if ( optType === 'other' ) { + document.getElementById( 'other_input_' + fieldId ).value = 1; + + //Hide "Add Other" option now if this is radio field + const ftype = jQuery( this ).data( 'ftype' ); + if ( ftype === 'radio' || ftype === 'select' ) { + jQuery( this ).fadeOut( 'slow' ); + } + + const data = { + action: 'frm_add_field_option', + field_id: fieldId, + opt_key: optKey, + opt_type: optType, + nonce: frmGlobal.nonce + }; + jQuery.post( ajaxurl, data, function( msg ) { + jQuery( document.getElementById( 'frm_field_' + fieldId + '_opts' ) ).append( msg ); + resetDisplayedOpts( fieldId ); + } ); + } else { + newOption = newOption.replace( new RegExp( 'optkey="' + oldKey + '"', 'g' ), 'optkey="' + optKey + '"' ); + newOption = newOption.replace( new RegExp( '-' + oldKey + '_', 'g' ), '-' + optKey + '_' ); + newOption = newOption.replace( new RegExp( '-' + oldKey + '"', 'g' ), '-' + optKey + '"' ); + newOption = newOption.replace( new RegExp( '\\[' + oldKey + '\\]', 'g' ), '[' + optKey + ']' ); + newOption = newOption.replace( 'frm_hidden frm_option_template', '' ); + newOption = { newOption }; + addSaveAndDragIconsToOption( fieldId, newOption ); + jQuery( document.getElementById( 'frm_field_' + fieldId + '_opts' ) ).append( newOption.newOption ); + resetDisplayedOpts( fieldId ); + } + fieldUpdated(); + } + + function getHighestOptKey( fieldId ) { + let i = 0, + optKey = 0, + opts = jQuery( '#frm_field_' + fieldId + '_opts li' ), + lastKey = 0; + + for ( i; i < opts.length; i++ ) { + optKey = opts[ i ].getAttribute( 'data-optkey' ); + if ( opts.length === 1 ) { + return optKey; + } + if ( optKey !== '000' ) { + optKey = optKey.replace( 'other_', '' ); + optKey = parseInt( optKey, 10 ); + } + + if ( ! isNaN( lastKey ) && ( optKey > lastKey || lastKey === '000' ) ) { + lastKey = optKey; + } + } + + return lastKey; + } + + function toggleMultSel() { + /*jshint validthis:true */ + const fieldId = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ); + toggleMultiSelect( fieldId, this.value ); + } + + function toggleMultiSelect( fieldId, value ) { + const setting = jQuery( '.frm_multiple_cont_' + fieldId ); + if ( value === 'select' ) { + setting.fadeIn( 'fast' ); + } else { + setting.fadeOut( 'fast' ); + } + } + + function toggleSepValues() { + /*jshint validthis:true */ + const fieldId = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ); + toggle( jQuery( '.field_' + fieldId + '_option_key' ) ); + jQuery( '.field_' + fieldId + '_option' ).toggleClass( 'frm_with_key' ); + } + + function toggleImageOptions() { + /*jshint validthis:true */ + let hasImageOptions, imageSize, + $field = jQuery( this ).closest( '.frm-single-settings' ), + fieldId = $field.data( 'fid' ), + displayField = document.getElementById( 'frm_field_id_' + fieldId ); + + refreshOptionDisplayNow( jQuery( this ) ); + + toggle( jQuery( '.field_' + fieldId + '_image_id' ) ); + toggle( jQuery( '.frm_toggle_image_options_' + fieldId ) ); + toggle( jQuery( '.frm_image_size_' + fieldId ) ); + toggle( jQuery( '.frm_alignment_' + fieldId ) ); + toggle( jQuery( '.frm-add-other#frm_add_field_' + fieldId ) ); + + hasImageOptions = imagesAsOptions( fieldId ); + + if ( hasImageOptions ) { + setAlignment( fieldId, 'inline' ); + removeImageSizeClasses( displayField ); + imageSize = getImageOptionSize( fieldId ); + displayField.classList.add( 'frm_image_options' ); + displayField.classList.add( 'frm_image_size_' + imageSize ); + $field.find( '.frm-bulk-edit-link' ).hide(); + } else { + displayField.classList.remove( 'frm_image_options' ); + removeImageSizeClasses( displayField ); + setAlignment( fieldId, 'block' ); + $field.find( '.frm-bulk-edit-link' ).show(); + } + } + + function removeImageSizeClasses( field ) { + field.classList.remove( 'frm_image_size_', 'frm_image_size_small', 'frm_image_size_medium', 'frm_image_size_large', 'frm_image_size_xlarge' ); + } + + function setAlignment( fieldId, alignment ) { + jQuery( '#field_options_align_' + fieldId ).val( alignment ).trigger( 'change' ); + } + + function setImageSize() { + const $field = jQuery( this ).closest( '.frm-single-settings' ), + fieldId = $field.data( 'fid' ), + displayField = document.getElementById( 'frm_field_id_' + fieldId ); + + refreshOptionDisplay(); + + if ( imagesAsOptions( fieldId ) ) { + removeImageSizeClasses( displayField ); + displayField.classList.add( 'frm_image_options' ); + displayField.classList.add( 'frm_image_size_' + getImageOptionSize( fieldId ) ); + } + } + + function refreshOptionDisplayNow( object ) { + const $field = object.closest( '.frm-single-settings' ), + fieldID = $field.data( 'fid' ); + jQuery( '.field_' + fieldID + '_option' ).trigger( 'change' ); + } + + function refreshOptionDisplay() { + /*jshint validthis:true */ + refreshOptionDisplayNow( jQuery( this ) ); + } + + function addImageToOption( event ) { + const imagePreview = event.target.closest( '.frm_image_preview_wrapper' ); + + event.preventDefault(); + + wp.media.model.settings.post.id = 0; + + const fileFrame = wp.media.frames.file_frame = wp.media( { + multiple: false, + library: { + type: [ 'image' ] + } + } ); + + fileFrame.on( 'select', function() { + const attachment = fileFrame.state().get( 'selection' ).first().toJSON(); + const img = imagePreview.querySelector( 'img' ); + + img.setAttribute( 'src', attachment.url ); + img.classList.remove( 'frm_hidden' ); + img.removeAttribute( 'srcset' ); // Prevent the old image from sticking around. + + imagePreview.querySelector( '.frm_image_preview_frame' ).style.display = 'block'; + imagePreview.querySelector( '.frm_image_preview_title' ).textContent = attachment.filename; + imagePreview.querySelector( '.frm_choose_image_box' ).style.display = 'none'; + + const $imagePreview = jQuery( imagePreview ); + $imagePreview.siblings( 'input[name*="[label]"]' ).data( 'frmimgurl', attachment.url ); + $imagePreview.find( 'input.frm_image_id' ).val( attachment.id ).trigger( 'change' ); + wp.media.model.settings.post.id = 0; + } ); + + fileFrame.open(); + } + + function removeImageFromOption( event ) { + const $this = jQuery( this ), + previewWrapper = $this.closest( '.frm_image_preview_wrapper' ); + + event.preventDefault(); + event.stopPropagation(); + + previewWrapper.find( 'img' ).attr( 'src', '' ); + previewWrapper.find( '.frm_image_preview_frame' ).hide(); + previewWrapper.find( '.frm_choose_image_box' ).show(); + previewWrapper.find( 'input.frm_image_id' ).val( 0 ).trigger( 'change' ); + } + + function toggleMultiselect() { + /*jshint validthis:true */ + const dropdown = jQuery( this ).closest( 'li' ).find( '.frm_form_fields select' ); + if ( this.checked ) { + dropdown.attr( 'multiple', 'multiple' ); + } else { + dropdown.removeAttr( 'multiple' ); + } + } + + /** + * Allow typing on form switcher click without an extra click to search. + */ + function focusSearchBox() { + const searchBox = document.getElementById( 'dropform-search-input' ); + if ( searchBox !== null ) { + setTimeout( function() { + searchBox.focus(); + }, 100 ); + } + } + + /** + * Dismiss a warning message and send an AJAX request to update the dismissal state. + * + * @since 6.3 + * + * @param {Event} event The event object associated with the click on the dismiss icon. + */ + function dismissWarningMessage( event ) { + const target = event.target; + + const warningEl = target.closest( '.frm_warning_style' ); + jQuery( warningEl ).fadeOut( 400, () => warningEl.remove() ); + + const action = target.dataset.action; + const formData = new FormData(); + doJsonPost( action, formData ); + } + + /** + * If a field is clicked in the builder, prevent inputs from changing. + */ + function stopFieldFocus( e ) { + e.preventDefault(); + } + + function deleteFieldOption() { + /*jshint validthis:true */ + let otherInput, + parentLi = this.parentNode, + parentUl = parentLi.parentNode, + fieldId = this.getAttribute( 'data-fid' ); + + jQuery( parentLi ).fadeOut( 'slow', function() { + wp.hooks.doAction( 'frm_before_delete_field_option', this ); + jQuery( parentLi ).remove(); + + const hasOther = jQuery( parentUl ).find( '.frm_other_option' ); + if ( hasOther.length < 1 ) { + otherInput = document.getElementById( 'other_input_' + fieldId ); + if ( otherInput !== null ) { + otherInput.value = 0; + } + jQuery( '#other_button_' + fieldId ).fadeIn( 'slow' ); + } + } ); + fieldUpdated(); + } + + /** + * If a radio button is set as default, allow a click to + * deselect it. + */ + function maybeUncheckRadio() { + let $self, uncheck, unbind, up; + + /*jshint validthis:true */ + $self = jQuery( this ); + if ( $self.is( ':checked' ) ) { + uncheck = function() { + setTimeout( function() { + $self.prop( 'checked', false ); + }, 0 ); + }; + unbind = function() { + $self.off( 'mouseup', up ); + }; + up = function() { + uncheck(); + unbind(); + }; + $self.on( 'mouseup', up ); + $self.one( 'mouseout', unbind ); + } + } + + /** + * If the field option has the default text, clear it out on click. + */ + function maybeClearOptText() { + /*jshint validthis:true */ + if ( this.value === frmAdminJs.new_option ) { + this.setAttribute( 'data-value-on-focus', this.value ); + this.value = ''; + } + } + + function confirmFieldsDeleteMessage( numberOfFields ) { + /* translators: %1$s: Number of fields that are selected to be deleted. */ + return sprintf( __( 'Are you sure you want to delete these %1$s selected field(s)?', 'formidable' ), numberOfFields ); + } + + function clickDeleteField() { + /*jshint validthis:true */ + let confirmMsg = frmAdminJs.conf_delete, + maybeDivider = this.parentNode.parentNode.parentNode.parentNode.parentNode, + li = maybeDivider.parentNode, + field = jQuery( this ).closest( 'li.form-field' ), + fieldId = field.data( 'fid' ); + + if ( field.data( 'ftype' ) === 'divider' ) { + const fieldBoxes = document.querySelectorAll( '.frm-field-group-hover-target .start_divider .frm_field_box' ); + let fieldIdsToDelete = 0; + fieldBoxes.forEach( fieldBox => { + const fieldsInsideFieldBox = fieldBox.querySelectorAll( 'li.form-field' ); + if ( fieldsInsideFieldBox ) { + fieldIdsToDelete += fieldsInsideFieldBox.length; + } + } ); + if ( fieldIdsToDelete ) { + confirmMsg = confirmFieldsDeleteMessage( ++fieldIdsToDelete ); + } + } + + if ( li.classList.contains( 'frm-section-collapsed' ) || li.classList.contains( 'frm-page-collapsed' ) ) { + return false; + } + + // If deleting a section, use a special message. + if ( maybeDivider.className === 'divider_section_only' ) { + confirmMsg = frmAdminJs.conf_delete_sec; + } + + this.setAttribute( 'data-frmverify', confirmMsg ); + this.setAttribute( 'data-frmverify-btn', 'frm-button-red' ); + this.setAttribute( 'data-deletefield', fieldId ); + + closeOpenFieldDropdowns(); + + confirmLinkClick( this ); + return false; + } + + function clickSelectField() { + this.closest( 'li.form-field' ).click(); + } + + function clickDeleteFieldGroup() { + let hoverTarget, decoy; + + hoverTarget = document.querySelector( '.frm-field-group-hover-target' ); + if ( null === hoverTarget ) { + return; + } + + hoverTarget.classList.add( 'frm-selected-field-group' ); + + decoy = document.createElement( 'div' ); + decoy.classList.add( 'frm-delete-field-groups', 'frm_hidden' ); + document.body.appendChild( decoy ); + decoy.click(); + } + + function duplicateFieldGroup() { + const hoverTarget = document.querySelector( '.frm-field-group-hover-target' ); + if ( null === hoverTarget ) { + return; + } + + const newRowId = 'frm_field_group_' + getAutoId(); + const placeholderUlChild = document.createTextNode( '' ); + wrapFieldLiInPlace( placeholderUlChild ); + + const newRow = jQuery( placeholderUlChild ).closest( 'li' ).get( 0 ); + newRow.classList.add( 'frm_hidden' ); + + const newRowUl = newRow.querySelector( 'ul' ); + newRowUl.id = newRowId; + + jQuery( hoverTarget.closest( 'li.frm_field_box' ) ).after( newRow ); + + const $fields = getFieldsInRow( jQuery( hoverTarget ) ); + const syncDetails = []; + const injectedCloneOptions = []; + + const expectedLength = $fields.length; + const originalFieldIdByDuplicatedFieldId = {}; + + let duplicatedCount = 0; + + jQuery( newRow ).on( + 'frm_added_duplicated_field_to_row', + function( _, args ) { + originalFieldIdByDuplicatedFieldId[ jQuery( args.duplicatedFieldHtml ).attr( 'data-fid' ) ] = args.originalFieldId; + + if ( expectedLength > ++duplicatedCount ) { + return; + } + + const $newRowUl = jQuery( newRowUl ); + const $duplicatedFields = getFieldsInRow( $newRowUl ); + + injectedCloneOptions.forEach( + function( cloneOption ) { + cloneOption.remove(); + } + ); + + for ( let index = 0; index < expectedLength; ++index ) { + $newRowUl.append( $newRowUl.children( 'li.form-field[frm-field-order="' + index + '"]' ) ); + } + + syncLayoutClasses( $duplicatedFields.first(), syncDetails ); + newRow.classList.remove( 'frm_hidden' ); + updateFieldOrder(); + + getFieldsInRow( $newRowUl ).each( + function() { + maybeDuplicateUnsavedSettings( originalFieldIdByDuplicatedFieldId[ this.getAttribute( 'data-fid' ) ], jQuery( this ).prop( 'outerHTML' ) ); + } + ); + } + ); + + $fields.each( + function( index ) { + let cloneOption; + cloneOption = document.createElement( 'li' ); + cloneOption.classList.add( 'frm_clone_field' ); + cloneOption.setAttribute( 'frm-target-row-id', newRowId ); + cloneOption.setAttribute( 'frm-field-order', index ); + this.appendChild( cloneOption ); + cloneOption.click(); + injectedCloneOptions.push( cloneOption ); + syncDetails.push( getSizeOfLayoutClass( getLayoutClassName( this.classList ) ) ); + } + ); + } + + function clickFieldGroupLayout() { + let hoverTarget, sizeOfFieldGroup, popupWrapper; + + hoverTarget = document.querySelector( '.frm-field-group-hover-target' ); + + if ( null === hoverTarget ) { + return; + } + + deselectFields(); + + sizeOfFieldGroup = getSizeOfFieldGroupFromChildElement( hoverTarget.querySelector( 'li.form-field' ) ); + + hoverTarget.classList.add( 'frm-has-open-field-group-popup' ); + jQuery( document ).on( 'click', '#frm_builder_page', destroyFieldGroupPopupOnOutsideClick ); + + popupWrapper = div(); + popupWrapper.style.position = 'relative'; + popupWrapper.appendChild( getFieldGroupPopup( sizeOfFieldGroup, this ) ); + this.parentNode.appendChild( popupWrapper ); + + const firstLayoutOption = popupWrapper.querySelector( '.frm-row-layout-option' ); + if ( firstLayoutOption ) { + firstLayoutOption.focus(); + } + } + + function destroyFieldGroupPopupOnOutsideClick( event ) { + if ( event.target.classList.contains( 'frm-custom-field-group-layout' ) || event.target.classList.contains( 'frm-cancel-custom-field-group-layout' ) ) { + return; + } + if ( ! jQuery( event.target ).closest( '#frm_field_group_controls' ).length && ! jQuery( event.target ).closest( '#frm_field_group_popup' ).length ) { + destroyFieldGroupPopup(); + } + } + + function getSizeOfFieldGroupFromChildElement( element ) { + const $ul = jQuery( element ).closest( 'ul' ); + if ( $ul.length ) { + return getFieldsInRow( $ul ).length; + } + return getSelectedFieldCount(); + } + + function getFieldGroupPopup( sizeOfFieldGroup, childElement ) { + let popup, wrapper, rowLayoutOptions, ul; + + popup = document.getElementById( 'frm_field_group_popup' ); + if ( null === popup ) { + popup = div(); + } else { + popup.innerHTML = ''; + } + + popup.id = 'frm_field_group_popup'; + + wrapper = div(); + wrapper.style.padding = '0 24px 12px'; + wrapper.appendChild( getRowLayoutTitle() ); + + rowLayoutOptions = getRowLayoutOptions( sizeOfFieldGroup ); + + ul = childElement.closest( 'ul.frm_sorting' ); + if ( null !== ul ) { + maybeMarkRowLayoutAsActive( ul, rowLayoutOptions ); + } + + wrapper.appendChild( rowLayoutOptions ); + + popup.appendChild( wrapper ); + popup.appendChild( separator() ); + + popup.appendChild( getCustomLayoutOption() ); + popup.appendChild( getBreakIntoDifferentRowsOption() ); + + return popup; + } + + function maybeMarkRowLayoutAsActive( activeRow, options ) { + let length, index, currentRow; + + length = options.children.length; + for ( index = 0; index < length; ++index ) { + currentRow = options.children[ index ]; + if ( rowLayoutsMatch( currentRow, activeRow ) ) { + currentRow.classList.add( 'frm-active-row-layout' ); + return; + } + } + } + + function separator() { + return document.createElement( 'hr' ); + } + + function getCustomLayoutOption() { + const option = div(); + option.textContent = __( 'Custom layout', 'formidable' ); + jQuery( option ).prepend( getIconClone( 'frm_gear_svg' ) ); + option.classList.add( 'frm-custom-field-group-layout' ); + makeTabbable( option ); + return option; + } + + function makeTabbable( element, ariaLabel ) { + element.setAttribute( 'tabindex', 0 ); + element.setAttribute( 'role', 'button' ); + if ( 'undefined' !== typeof ariaLabel ) { + element.setAttribute( 'aria-label', ariaLabel ); + } + } + + function getIconClone( iconId ) { + const clone = document.getElementById( iconId ).cloneNode( true ); + clone.id = ''; + return clone; + } + + function getBreakIntoDifferentRowsOption() { + const option = div(); + option.textContent = __( 'Break into rows', 'formidable' ); + jQuery( option ).prepend( getIconClone( 'frm_break_field_group_svg' ) ); + option.classList.add( 'frm-break-field-group' ); + makeTabbable( option ); + return option; + } + + function getRowLayoutTitle() { + const rowLayoutTitle = div(); + rowLayoutTitle.classList.add( 'frm-row-layout-title' ); + rowLayoutTitle.textContent = __( 'Row Layout', 'formidable' ); + return rowLayoutTitle; + } + + function getRowLayoutOptions( size ) { + let wrapper, padding; + + wrapper = getEmptyGridContainer(); + if ( 5 !== size ) { + wrapper.appendChild( getRowLayoutOption( size, 'even' ) ); + } + if ( size % 2 === 1 ) { + // only include the middle option for odd numbers because even doesn't make a lot of sense. + wrapper.appendChild( getRowLayoutOption( size, 'middle' ) ); + } + if ( size < 6 ) { + wrapper.appendChild( getRowLayoutOption( size, 'left' ) ); + wrapper.appendChild( getRowLayoutOption( size, 'right' ) ); + } else { + padding = div(); + padding.classList.add( 'frm_fourth' ); + wrapper.prepend( padding ); + } + + return wrapper; + } + + function getRowLayoutOption( size, type ) { + let option, useClass; + + option = div(); + option.classList.add( 'frm-row-layout-option' ); + makeTabbable( option, type ); + + switch ( size ) { + case 6: + useClass = 'frm_half'; + break; + case 5: + useClass = 'frm_third'; + break; + default: + useClass = size % 2 === 1 ? 'frm_fourth' : 'frm_third'; + break; + } + + option.classList.add( useClass ); + option.setAttribute( 'layout-type', type ); + + option.appendChild( getRowForSizeAndType( size, type ) ); + return option; + } + + function rowLayoutsMatch( row1, row2 ) { + return getRowLayoutAsKey( row1 ) === getRowLayoutAsKey( row2 ); + } + + function getRowLayoutAsKey( row ) { + let $fields, sizes; + if ( row.classList.contains( 'frm-row-layout-option' ) ) { + $fields = jQuery( row ).find( '.frm_grid_container' ).children(); + } else { + $fields = getFieldsInRow( jQuery( row ) ); + } + sizes = []; + $fields.each( + function() { + sizes.push( getSizeOfLayoutClass( getLayoutClassName( this.classList ) ) ); + } + ); + return sizes.join( '-' ); + } + + function getRowForSizeAndType( size, type ) { + let row, index, block; + + row = getEmptyGridContainer(); + for ( index = 0; index < size; ++index ) { + block = div(); + block.classList.add( getClassForBlock( size, type, index ) ); + block.style.height = '16px'; + block.style.background = '#9EA9B8'; + block.style.borderRadius = '1px'; + row.appendChild( block ); + } + + return row; + } + + /** + * @param {int} size 2-6. + * @param {string} type even, middle, left, or right. + * @param {int} index 0-5. + * @return {string} The class name. + */ + function getClassForBlock( size, type, index ) { + if ( 'even' === type ) { + return getEvenClassForSize( size, index ); + } else if ( 'middle' === type ) { + if ( 3 === size ) { + return 1 === index ? 'frm6' : 'frm3'; + } + if ( 5 === size ) { + return 2 === index ? 'frm4' : 'frm2'; + } + } else if ( 'left' === type ) { + return 0 === index ? getLargeClassForSize( size ) : getSmallClassForSize( size ); + } else if ( 'right' === type ) { + return index === size - 1 ? getLargeClassForSize( size ) : getSmallClassForSize( size ); + } + return 'frm12'; + } + + function getEvenClassForSize( size, index ) { + if ( -1 !== [ 2, 3, 4, 6 ].indexOf( size ) ) { + return getLayoutClassForSize( 12 / size ); + } + if ( 5 === size && 'undefined' !== typeof index ) { + return 0 === index ? 'frm4' : 'frm2'; + } + return 'frm12'; + } + + function getSmallClassForSize( size ) { + switch ( size ) { + case 2: case 3: + return 'frm3'; + case 4: + return 'frm2'; + case 5: + return 'frm2'; + case 6: + return 'frm1'; + } + return 'frm12'; + } + + function getLargeClassForSize( size ) { + switch ( size ) { + case 2: + return 'frm9'; + case 3: case 4: + return 'frm6'; + case 5: + return 'frm4'; + case 6: + return 'frm7'; + } + return 'frm12'; + } + + function getEmptyGridContainer() { + const wrapper = div(); + wrapper.classList.add( 'frm_grid_container' ); + return wrapper; + } + + /** + * Handle when a field group layout option (that sets grid classes/column sizing) is selected in the "Row Layout" popup. + * + * @return {void} + */ + function handleFieldGroupLayoutOptionClick() { + const row = document.querySelector( '.frm-field-group-hover-target' ); + if ( ! row ) { + // The field group layout options also get clicked when merging multiple rows. + // The following code isn't required for multiple rows though so just exit early. + return; + } + + const type = this.getAttribute( 'layout-type' ); + syncLayoutClasses( getFieldsInRow( jQuery( row ) ).first(), type ); + destroyFieldGroupPopup(); + } + + function handleFieldGroupLayoutOptionInsideMergeClick() { + let $ul, type; + $ul = mergeSelectedFieldGroups(); + type = this.getAttribute( 'layout-type' ); + syncLayoutClasses( getFieldsInRow( $ul ).first(), type ); + unselectFieldGroups(); + } + + function mergeSelectedFieldGroups() { + const $selectedFieldGroups = jQuery( '.frm-selected-field-group' ), + $firstGroupUl = $selectedFieldGroups.first(); + $selectedFieldGroups.not( $firstGroupUl ).each( + function() { + getFieldsInRow( jQuery( this ) ).each( + function() { + const previousParent = this.parentNode; + getFieldsInRow( $firstGroupUl ).last().after( this ); + if ( ! jQuery( previousParent ).children( 'li.form-field' ).length ) { + // clean up the previous field group if we've removed all of its fields. + previousParent.closest( 'li.frm_field_box' ).remove(); + } + } + ); + } + ); + updateFieldOrder(); + syncLayoutClasses( getFieldsInRow( $firstGroupUl ).first() ); + return $firstGroupUl; + } + + function customFieldGroupLayoutClick() { + let $fields; + if ( null !== this.closest( '.frm-merge-fields-into-row' ) ) { + return; + } + $fields = getFieldsInRow( jQuery( '.frm-field-group-hover-target' ) ); + setupCustomLayoutOptions( $fields ); + } + + function setupCustomLayoutOptions( $fields ) { + let size, popup, wrapper, layoutClass, inputRow, paddingElement, inputValueOverride, index, inputField, heading, label, buttonsWrapper, cancelButton, saveButton; + + size = $fields.length; + + popup = document.getElementById( 'frm_field_group_popup' ); + popup.innerHTML = ''; + + wrapper = div(); + wrapper.style.padding = '0 24px'; + + layoutClass = getEvenClassForSize( 5 === size ? 6 : size ); + + inputRow = div(); + inputRow.style.padding = '20px 0'; + inputRow.classList.add( 'frm_grid_container' ); + + if ( 5 === size ) { + // add a span to pad the inputs by 1 column, to account for the missing 2 columns. + paddingElement = document.createElement( 'span' ); + paddingElement.classList.add( 'frm1' ); + inputRow.appendChild( paddingElement ); + } + + inputValueOverride = getSelectedFieldCount() > 0 ? getSizeOfLayoutClass( getEvenClassForSize( size ) ) : false; + if ( false !== inputValueOverride && inputValueOverride >= 12 ) { + inputValueOverride = Math.floor( 12 / size ); + } + + for ( index = 0; index < size; ++index ) { + inputField = document.createElement( 'input' ); + inputField.type = 'text'; + inputField.classList.add( layoutClass ); + inputField.classList.add( 'frm-custom-grid-size-input' ); + inputField.value = false !== inputValueOverride ? inputValueOverride : getSizeOfLayoutClass( getLayoutClassName( $fields.get( index ).classList ) ); + inputRow.appendChild( inputField ); + } + + heading = div(); + heading.classList.add( 'frm-builder-popup-heading' ); + heading.textContent = __( 'Enter number of columns for each field', 'formidable' ); + + label = div(); + label.classList.add( 'frm-builder-popup-subheading' ); + label.textContent = __( 'Layouts are based on a 12-column grid system', 'formidable' ); + + wrapper.appendChild( heading ); + wrapper.appendChild( label ); + + wrapper.appendChild( inputRow ); + + buttonsWrapper = div(); + buttonsWrapper.style.textAlign = 'right'; + + cancelButton = getSecondaryButton(); + cancelButton.textContent = __( 'Cancel', 'formidable' ); + cancelButton.classList.add( 'frm-cancel-custom-field-group-layout' ); + cancelButton.style.marginRight = '10px'; + + saveButton = getPrimaryButton(); + saveButton.textContent = __( 'Save', 'formidable' ); + saveButton.classList.add( 'frm-save-custom-field-group-layout' ); + + buttonsWrapper.appendChild( cancelButton ); + buttonsWrapper.appendChild( saveButton ); + + wrapper.appendChild( buttonsWrapper ); + + popup.appendChild( wrapper ); + + setTimeout( + function() { + const firstInput = popup.querySelector( 'input.frm-custom-grid-size-input' ).focus(); + if ( firstInput ) { + firstInput.focus(); + } + }, + 0 + ); + } + + function customFieldGroupLayoutInsideMergeClick() { + $fields = jQuery( '.frm-selected-field-group li.form-field' ); + setupCustomLayoutOptions( $fields ); + } + + function getPrimaryButton() { + const button = getButton(); + button.classList.add( 'button-primary', 'frm-button-primary' ); + return button; + } + + function getSecondaryButton() { + const button = getButton(); + button.classList.add( 'button-secondary', 'frm-button-secondary' ); + return button; + } + + function getButton() { + const button = document.createElement( 'a' ); + button.setAttribute( 'href', '#' ); + button.classList.add( 'button' ); + button.style.textDecoration = 'none'; + return button; + } + + function getSizeOfLayoutClass( className ) { + switch ( className ) { + case 'frm_half': + return 6; + case 'frm_third': + return 4; + case 'frm_two_thirds': + return 8; + case 'frm_fourth': + return 3; + case 'frm_three_fourths': + return 9; + case 'frm_sixth': + return 2; + } + + if ( 0 === className.indexOf( 'frm' ) ) { + return parseInt( className.substr( 3 ) ); + } + + // Anything missing a layout class should be a full width row. + return 12; + } + + function getLayoutClassName( classList ) { + let classes, index, currentClass; + classes = getLayoutClasses(); + for ( index = 0; index < classes.length; ++index ) { + currentClass = classes[ index ]; + if ( classList.contains( currentClass ) ) { + return currentClass; + } + } + return ''; + } + + function getLayoutClassForSize( size ) { + return 'frm' + size; + } + + function breakFieldGroupClick() { + const row = document.querySelector( '.frm-field-group-hover-target' ); + breakRow( row ); + destroyFieldGroupPopup(); + } + + function breakRow( row ) { + const $row = jQuery( row ); + getFieldsInRow( $row ).each( + function( index ) { + const field = this; + if ( 0 !== index ) { + $row.parent().after( wrapFieldLi( field ) ); + } + stripLayoutFromFields( jQuery( field ) ); + } + ); + } + + function stripLayoutFromFields( field ) { + syncLayoutClasses( field, 'clear' ); + } + + function focusFieldGroupInputOnClick() { + this.select(); + } + + function cancelCustomFieldGroupClick() { + revertToFieldGroupPopupFirstPage( this ); + } + + function revertToFieldGroupPopupFirstPage( triggerElement ) { + jQuery( document.getElementById( 'frm_field_group_popup' ) ).replaceWith( + getFieldGroupPopup( getSizeOfFieldGroupFromChildElement( triggerElement ), triggerElement ) + ); + } + + function destroyFieldGroupPopup() { + let popup, wrapper; + popup = document.getElementById( 'frm_field_group_popup' ); + if ( popup === null ) { + return; + } + wrapper = document.querySelector( '.frm-has-open-field-group-popup' ); + if ( null !== wrapper ) { + wrapper.classList.remove( 'frm-has-open-field-group-popup' ); + popup.parentNode.remove(); + } + jQuery( document ).off( 'click', '#frm_builder_page', destroyFieldGroupPopupOnOutsideClick ); + } + + function saveCustomFieldGroupClick() { + let syncDetails, $controls, $ul; + + syncDetails = []; + + jQuery( document.getElementById( 'frm_field_group_popup' ).querySelectorAll( '.frm_grid_container input' ) ) + .each( + function() { + syncDetails.push( parseInt( this.value ) ); + } + ); + + $controls = jQuery( document.getElementById( 'frm_field_group_controls' ) ); + + if ( $controls.length && 'none' !== $controls.get( 0 ).style.display ) { + syncLayoutClasses( getFieldsInRow( jQuery( document.querySelector( '.frm-field-group-hover-target' ) ) ).first(), syncDetails ); + } else { + $ul = mergeSelectedFieldGroups(); + syncLayoutClasses( getFieldsInRow( $ul ).first(), syncDetails ); + unselectFieldGroups(); + } + + destroyFieldGroupPopup(); + } + + function fieldGroupClick( e ) { + maybeShowFieldGroupMessage(); + + if ( 'ul' !== e.originalEvent.target.nodeName.toLowerCase() ) { + // only continue if the group itself was clicked / ignore when a field is clicked. + return; + } + + const hoverTarget = document.querySelector( '.frm-field-group-hover-target' ); + if ( ! hoverTarget ) { + return; + } + + const ctrlOrCmdKeyIsDown = e.ctrlKey || e.metaKey; + const shiftKeyIsDown = e.shiftKey; + const groupIsActive = hoverTarget.classList.contains( 'frm-selected-field-group' ); + const $selectedFieldGroups = getSelectedFieldGroups(); + + let numberOfSelectedGroups = $selectedFieldGroups.length; + + if ( ctrlOrCmdKeyIsDown || shiftKeyIsDown ) { + // multi-selecting + + const selectedField = getSelectedField(); + if ( null !== selectedField && ! jQuery( selectedField ).siblings( 'li.form-field' ).length ) { + // count a selected field on its own as a selected field group when multiselecting. + selectedField.parentNode.classList.add( 'frm-selected-field-group' ); + ++numberOfSelectedGroups; + } + + if ( ctrlOrCmdKeyIsDown ) { + if ( groupIsActive ) { + // unselect if holding ctrl or cmd and the group was already active. + --numberOfSelectedGroups; + hoverTarget.classList.remove( 'frm-selected-field-group' ); + syncAfterMultiSelect( numberOfSelectedGroups ); + return; // exit early to avoid adding back frm-selected-field-group + } + + ++numberOfSelectedGroups; + } else if ( shiftKeyIsDown && ! groupIsActive ) { + ++numberOfSelectedGroups; // include the one we're selecting right now. + const $firstGroup = $selectedFieldGroups.first(); + + let $range; + if ( $firstGroup.parent().index() < jQuery( hoverTarget.parentNode ).index() ) { + $range = $firstGroup.parent().nextUntil( hoverTarget.parentNode ); + } else { + $range = $firstGroup.parent().prevUntil( hoverTarget.parentNode ); + } + + $range.each( + function() { + const $fieldGroup = jQuery( this ).closest( 'li' ).find( 'ul.frm_sorting' ); + if ( ! $fieldGroup.hasClass( 'frm-selected-field-group' ) ) { + ++numberOfSelectedGroups; + $fieldGroup.addClass( 'frm-selected-field-group' ); + } + } + ); + } + } else { + // not multi-selecting + unselectFieldGroups(); + numberOfSelectedGroups = 1; + } + + hoverTarget.classList.add( 'frm-selected-field-group' ); + syncAfterMultiSelect( numberOfSelectedGroups ); + + maybeHideFieldGroupMessage(); + + jQuery( document ).off( 'click', unselectFieldGroups ); + jQuery( document ).on( 'click', unselectFieldGroups ); + } + + /** + * Hide the field group message by manipulating classes. + * + * @param {Element} fieldGroupMessage The field group message element. + * @return {void} + */ + function hideFieldGroupMessage( fieldGroupMessage ) { + if ( ! fieldGroupMessage ) { + return; + } + + fieldGroupMessage.classList.add( 'frm_hidden' ); + fieldGroupMessage.classList.remove( 'frm-fadein-up-back' ); + } + + /** + * Show the field group message by manipulating classes. + * + * @param {Element} fieldGroupMessage The field group message element. + * @return {void} + */ + function showFieldGroupMessage( fieldGroupMessage ) { + if ( ! fieldGroupMessage ) { + return; + } + + fieldGroupMessage.classList.remove( 'frm_hidden' ); + fieldGroupMessage.classList.add( 'frm-fadein-up-back' ); + } + + /** + * Maybe show a message if there are at least two rows. + * + * @return {void} + */ + function maybeShowFieldGroupMessage() { + let fieldGroupMessage = document.getElementById( 'frm-field-group-message' ); + const rows = document.querySelectorAll( '.edit_form_item:not(.edit_field_type_end_divider)' ); + + if ( rows.length < 2 ) { + hideFieldGroupMessage( fieldGroupMessage ); + return; + } + + if ( fieldGroupMessage ) { + showFieldGroupMessage( fieldGroupMessage ); + return; + } + + fieldGroupMessage = div( { + id: 'frm-field-group-message', + className: 'frm-flex-center frm-fadein-up-back', + children: [ + span( { + id: 'frm-field-group-message-dismiss', + className: 'frm-flex-center', + child: svg( { href: '#frm_close_icon' } ) + } ) + ] + } ); + + // Insert the field group into the DOM + document.getElementById( 'post-body-content' ).appendChild( fieldGroupMessage ); + + // Get and add the field group message text + const messageText = getFieldGroupMessageText(); + fieldGroupMessage.prepend( messageText ); + + // Set up a click event listener + document.getElementById( 'frm-field-group-message-dismiss' ).addEventListener( 'click', () => { + hideFieldGroupMessage( document.getElementById( 'frm-field-group-message' ) ); + } ); + } + + /** + * Get a span element with text about selecting multiple fields. + * + * @return {HTMLElement} A span element with the message and style classes. + */ + function getFieldGroupMessageText() { + const text = document.createElement( 'span' ); + text.classList.add( 'frm-field-group-message-text', 'frm-flex-center' ); + text.innerHTML = sprintf( + /* translators: %1$s: Start span HTML, %2$s: end span HTML */ + frm_admin_js.holdShiftMsg, // eslint-disable-line camelcase + '', + '' + ); + + return text; + } + + /** + * Maybe hide the field group message based on the number of selected rows. + * + * @return {void} + */ + function maybeHideFieldGroupMessage() { + const selectedRowCount = document.querySelectorAll( '.frm-selected-field-group' ).length; + if ( selectedRowCount < 2 ) { + return; + } + + const fieldGroupMessage = document.getElementById( 'frm-field-group-message' ); + hideFieldGroupMessage( fieldGroupMessage ); + } + + function getSelectedField() { + return document.getElementById( 'frm-show-fields' ).querySelector( 'li.form-field.selected' ); + } + + function getSelectedFieldGroups() { + const $fieldGroups = jQuery( '.frm-selected-field-group' ); + if ( $fieldGroups.length ) { + return $fieldGroups; + } + + const selectedField = getSelectedField(); + if ( selectedField ) { + // If there is only one field in a group and the field is selected, consider the field's group as selected for multi-select. + const selectedFieldGroup = selectedField.closest( 'ul' ); + if ( selectedFieldGroup && 1 === getFieldsInRow( jQuery( selectedFieldGroup ) ).length ) { + selectedFieldGroup.classList.add( 'frm-selected-field-group' ); + return jQuery( selectedFieldGroup ); + } + } + + return jQuery(); + } + + function syncAfterMultiSelect( numberOfSelectedGroups ) { + clearSettingsBox( true ); // unselect any fields if one is selected. + if ( numberOfSelectedGroups >= 2 || ( 1 === numberOfSelectedGroups && selectedGroupHasMultipleFields() ) ) { + addFieldMultiselectPopup(); + } else { + maybeRemoveMultiselectPopup(); + } + maybeRemoveGroupHoverTarget(); + } + + function selectedGroupHasMultipleFields() { + return getFieldsInRow( jQuery( document.querySelector( '.frm-selected-field-group' ) ) ).length > 1; + } + + function unselectFieldGroups( event ) { + if ( 'undefined' !== typeof event ) { + if ( null !== event.originalEvent.target.closest( '#frm-show-fields' ) ) { + return; + } + if ( event.originalEvent.target.classList.contains( 'frm-merge-fields-into-row' ) ) { + return; + } + if ( null !== event.originalEvent.target.closest( '.frm-merge-fields-into-row' ) ) { + return; + } + if ( event.originalEvent.target.classList.contains( 'frm-custom-field-group-layout' ) ) { + return; + } + if ( event.originalEvent.target.classList.contains( 'frm-cancel-custom-field-group-layout' ) ) { + return; + } + } + jQuery( '.frm-selected-field-group' ).removeClass( 'frm-selected-field-group' ); + jQuery( document ).off( 'click', unselectFieldGroups ); + maybeRemoveMultiselectPopup(); + } + + function maybeRemoveMultiselectPopup() { + const popup = document.getElementById( 'frm_field_multiselect_popup' ); + if ( null !== popup ) { + popup.remove(); + } + } + + function addFieldMultiselectPopup() { + getFieldMultiselectPopup(); + } + + function getFieldMultiselectPopup() { + let popup, mergeOption, caret, verticalSeparator, deleteOption; + + popup = document.getElementById( 'frm_field_multiselect_popup' ); + + if ( null !== popup ) { + popup.classList.toggle( 'frm-unmergable', ! selectedFieldsAreMergeable() ); + return popup; + } + + popup = div(); + popup.id = 'frm_field_multiselect_popup'; + if ( ! selectedFieldsAreMergeable() ) { + popup.classList.add( 'frm-unmergable' ); + } + + mergeOption = div(); + mergeOption.classList.add( 'frm-merge-fields-into-row' ); + mergeOption.textContent = __( 'Merge into row', 'formidable' ); + + caret = document.createElement( 'a' ); + caret.style.marginLeft = '5px'; + caret.classList.add( 'frm_icon_font', 'frm_arrowdown6_icon' ); + caret.setAttribute( 'href', '#' ); + mergeOption.appendChild( caret ); + + popup.appendChild( mergeOption ); + + verticalSeparator = div(); + verticalSeparator.classList.add( 'frm-multiselect-popup-separator' ); + popup.appendChild( verticalSeparator ); + + deleteOption = div(); + deleteOption.classList.add( 'frm-delete-field-groups' ); + deleteOption.appendChild( getIconClone( 'frm_trash_svg' ) ); + popup.appendChild( deleteOption ); + + document.getElementById( 'post-body-content' ).appendChild( popup ); + + jQuery( popup ).hide().fadeIn(); + + return popup; + } + + function selectedFieldsAreMergeable() { + let selectedFieldGroups, totalFieldCount, length, index, fieldGroup; + selectedFieldGroups = document.querySelectorAll( '.frm-selected-field-group' ); + length = selectedFieldGroups.length; + if ( 1 === length ) { + return false; + } + totalFieldCount = 0; + for ( index = 0; index < length; ++index ) { + fieldGroup = selectedFieldGroups[ index ]; + if ( null !== fieldGroup.querySelector( '.edit_field_type_break, .edit_field_type_hidden' ) ) { + return false; + } + totalFieldCount += getFieldsInRow( jQuery( fieldGroup ) ).length; + if ( totalFieldCount > 6 ) { + return false; + } + } + return true; + } + + function mergeFieldsIntoRowClick( event ) { + let size, popup; + + if ( null !== event.originalEvent.target.closest( '#frm_field_group_popup' ) ) { + // prevent clicks within the popup from triggering the button again. + return; + } + + if ( event.originalEvent.target.classList.contains( 'frm-custom-field-group-layout' ) ) { + // avoid switching back to the first page when clicking the custom option nested inside of the merge option. + return; + } + + size = getSelectedFieldCount(); + popup = getFieldGroupPopup( size, document.querySelector( '.frm-selected-field-group' ).firstChild ); + this.appendChild( popup ); + } + + function getSelectedFieldCount() { + let count = 0; + jQuery( document.querySelectorAll( '.frm-selected-field-group' ) ).each( + function() { + count += getFieldsInRow( jQuery( this ) ).length; + } + ); + return count; + } + + function deleteFieldGroupsClick() { + let fieldIdsToDelete, deleteOnConfirm, multiselectPopup; + + fieldIdsToDelete = getSelectedFieldIds(); + deleteOnConfirm = getDeleteSelectedFieldGroupsOnConfirmFunction( fieldIdsToDelete ); + + multiselectPopup = document.getElementById( 'frm_field_multiselect_popup' ); + if ( null !== multiselectPopup ) { + multiselectPopup.remove(); + } + + this.setAttribute( 'data-frmverify', confirmFieldsDeleteMessage( fieldIdsToDelete.length ) ); + confirmLinkClick( this ); + + const confirmedClick = document.getElementById( 'frm-confirmed-click' ); + + // Remove any previous delete field data so delete confirmation does not attempt + // to delete a field that was already deleted or previously attempted and cancelled. + confirmedClick?.removeAttribute( 'data-deletefield' ); + + jQuery( confirmedClick ).on( 'click', deleteOnConfirm ); + jQuery( '#frm_confirm_modal' ).one( 'dialogclose', function() { + jQuery( confirmedClick ).off( 'click', deleteOnConfirm ); + } ); + } + + function getSelectedFieldIds() { + const deleteFieldIds = []; + jQuery( '.frm-selected-field-group > li.form-field' ) + .each( + function() { + deleteFieldIds.push( this.dataset.fid ); + } + ); + return deleteFieldIds; + } + + function getDeleteSelectedFieldGroupsOnConfirmFunction( deleteFieldIds ) { + return function( event ) { + event.preventDefault(); + deleteAllSelectedFieldGroups( deleteFieldIds ); + }; + } + + function deleteAllSelectedFieldGroups( deleteFieldIds ) { + deleteFieldIds.forEach( + function( fieldId ) { + deleteFields( fieldId ); + } + ); + } + + function deleteFieldConfirmed() { + /*jshint validthis:true */ + deleteFields( this.getAttribute( 'data-deletefield' ) ); + } + + function deleteFields( fieldId ) { + const field = jQuery( '#frm_field_id_' + fieldId ); + + deleteField( fieldId ); + + if ( field.hasClass( 'edit_field_type_divider' ) ) { + field.find( 'li.frm_field_box' ).each( function() { + //TODO: maybe delete only end section + //if(n.hasClass('edit_field_type_end_divider')){ + deleteField( this.getAttribute( 'data-fid' ) ); + //} + } ); + } + toggleSectionHolder(); + } + + /** + * Checks if there is only submit field in the form builder. + * + * @return {Boolean} + */ + function hasOnlySubmitField() { + // If there are at least 2 rows, return false. + if ( $newFields.get( 0 ).childElementCount > 1 ) { + return false; + } + + const childUl = $newFields.get( 0 ).firstElementChild.firstElementChild; + + // Use query instead of children because there might be a div inside this ul. + const childLi = childUl.querySelectorAll( 'li.frm_field_box' ); + + // If there are at least 2 items in the row, return false. + if ( childLi.length > 1 ) { + return false; + } + + return childLi[ 0 ].classList.contains( 'edit_field_type_submit' ); + } + + /** + * Moves open modals out of the field options form. + * + * When a modal is open, it is moved in the DOM and appended to the parent element of the modal trigger input. That + * creates a problem since deleting the field also deletes the modal and this function fixes that problem. + * + * @since 6.22 + * + * @param {Object} settings + * @return {void} + */ + function moveOpenModalsOutOfFieldOptions( settings ) { + const openModals = settings[ 0 ].querySelectorAll( '.frm-inline-modal[data-fills]' ); + if ( ! openModals.length ) { + return; + } + openModals.forEach( modal => { + modal.classList.add( 'frm_hidden' ); + modal.removeAttribute( 'data-fills' ); + modal.closest( 'form' ).appendChild( modal ); + } ); + } + + function deleteField( fieldId ) { + jQuery.ajax( { + type: 'POST', + url: ajaxurl, + data: { + action: 'frm_delete_field', + field_id: fieldId, + nonce: frmGlobal.nonce + }, + success: function() { + const $thisField = jQuery( document.getElementById( 'frm_field_id_' + fieldId ) ), + settings = jQuery( '#frm-single-settings-' + fieldId ); + + // Remove settings from sidebar. + if ( settings.is( ':visible' ) ) { + document.getElementById( 'frm_insert_fields_tab' ).click(); + } + + moveOpenModalsOutOfFieldOptions( settings ); + settings.remove(); + + $thisField.fadeOut( 'slow', function() { + let $section = $thisField.closest( '.start_divider' ), + type = $thisField.data( 'type' ), + $adjacentFields = $thisField.siblings( 'li.form-field' ), + $liWrapper; + + if ( ! $adjacentFields.length ) { + if ( $thisField.is( '.edit_field_type_end_divider' ) ) { + $adjacentFields.length = $thisField.closest( 'li.form-field' ).siblings(); + } else { + $liWrapper = $thisField.closest( 'ul.frm_sorting' ).parent(); + } + } + + $thisField.remove(); + if ( type === 'break' ) { + renumberPageBreaks(); + } else if ( type === 'product' ) { + maybeHideQuantityProductFieldOption(); + // a product field attached to a quantity field earlier might be the one deleted, so re-populate + popAllProductFields(); + } + + if ( $adjacentFields.length ) { + syncLayoutClasses( $adjacentFields.first() ); + } else { + $liWrapper.remove(); + } + + if ( jQuery( '#frm-show-fields li' ).length === 0 || hasOnlySubmitField() ) { + const formEditorContainer = document.getElementById( 'frm_form_editor_container' ); + formEditorContainer.classList.remove( 'frm-has-fields' ); + formEditorContainer.classList.add( 'frm-empty-fields' ); + } else if ( $section.length ) { + toggleOneSectionHolder( $section ); + } + + // prevent "More Options" tooltips from staying around after their target field is deleted. + deleteTooltips(); + } ); + + if ( $thisField.length ) { + wp.hooks.doAction( 'frm_after_delete_field', $thisField[ 0 ] ); + } + } + } ); + } + + function addFieldLogicRow() { + /*jshint validthis:true */ + const id = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ), + formId = thisFormId, + logicRows = document.getElementById( 'frm_logic_row_' + id ).querySelectorAll( '.frm_logic_row' ); + jQuery.ajax( { + type: 'POST', + url: ajaxurl, + data: { + action: 'frm_add_logic_row', + form_id: formId, + field_id: id, + nonce: frmGlobal.nonce, + meta_name: getNewRowId( logicRows, 'frm_logic_' + id + '_' ), + fields: getFieldList() + }, + success: function( html ) { + jQuery( document.getElementById( 'logic_' + id ) ).fadeOut( 'slow', function() { + const logicRow = jQuery( document.getElementById( 'frm_logic_row_' + id ) ); + logicRow.append( html ); + logicRow.closest( '.frm_logic_rows' ).fadeIn( 'slow' ); + } ); + } + } ); + return false; + } + + function getNewRowId( rows, replace, defaultValue ) { + if ( ! rows.length ) { + return 'undefined' !== typeof defaultValue ? defaultValue : 0; + } + return parseInt( rows[ rows.length - 1 ].id.replace( replace, '' ), 10 ) + 1; + } + + function addWatchLookupRow() { + /*jshint validthis:true */ + let lastRowId, + id = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ), + formId = thisFormId, + lookupBlockRows = document.getElementById( 'frm_watch_lookup_block_' + id ).children; + jQuery.ajax( { + type: 'POST', + url: ajaxurl, + data: { + action: 'frm_add_watch_lookup_row', + form_id: formId, + field_id: id, + row_key: getNewRowId( lookupBlockRows, 'frm_watch_lookup_' + id + '_' ), + nonce: frmGlobal.nonce + }, + success: function( newRow ) { + const watchRowBlock = jQuery( document.getElementById( 'frm_watch_lookup_block_' + id ) ); + watchRowBlock.append( newRow ); + watchRowBlock.fadeIn( 'slow' ); + } + } ); + return false; + } + + function resetOptionTextDetails() { + jQuery( '.frm-single-settings ul input[type="text"][name^="field_options[options_"]' ).filter( '[data-value-on-load]' ).removeAttr( 'data-value-on-load' ); + jQuery( 'input[type="hidden"][name^=optionmap]' ).remove(); + } + + function optionTextAlreadyExists( input ) { + let fieldId = jQuery( input ).closest( '.frm-single-settings' ).attr( 'data-fid' ), + optionInputs = jQuery( input ).closest( 'ul' ).get( 0 ).querySelectorAll( '.field_' + fieldId + '_option' ), + index, + optionInput; + + for ( index in optionInputs ) { + optionInput = optionInputs[ index ]; + if ( optionInput.id !== input.id && optionInput.value === input.value && optionInput.getAttribute( 'data-duplicate' ) !== 'true' ) { + return true; + } + } + + return false; + } + + function onOptionTextFocus() { + let input, + fieldId; + + if ( this.getAttribute( 'data-value-on-load' ) === null ) { + this.setAttribute( 'data-value-on-load', this.value ); + + fieldId = jQuery( this ).closest( '.frm-single-settings' ).attr( 'data-fid' ); + input = document.createElement( 'input' ); + input.value = this.value; + input.setAttribute( 'type', 'hidden' ); + input.setAttribute( 'name', 'optionmap[' + fieldId + '][' + this.value + ']' ); + this.parentNode.appendChild( input ); + + if ( typeof optionMap[ fieldId ] === 'undefined' ) { + optionMap[ fieldId ] = {}; + } + + optionMap[ fieldId ][ this.value ] = input; + } + + if ( this.getAttribute( 'data-duplicate' ) === 'true' ) { + this.removeAttribute( 'data-duplicate' ); + + // we want to use original value if actually still a duplicate + if ( optionTextAlreadyExists( this ) ) { + this.setAttribute( 'data-value-on-focus', this.getAttribute( 'data-value-on-load' ) ); + return; + } + } + + if ( '' !== this.value || frmAdminJs.new_option !== this.getAttribute( 'data-value-on-focus' ) ) { + this.setAttribute( 'data-value-on-focus', this.value ); + } + } + + /** + * Returns an object that has the old and new values and labels, when a field choice is changed. + * + * @param {HTMLElement} input + * @return {Object} + */ + function getChoiceOldAndNewValues( input ) { + const { oldValue, oldLabel } = getChoiceOldValueAndLabel( input ); + const { newValue, newLabel } = getChoiceNewValueAndLabel( input ); + + return { oldValue, oldLabel, newValue, newLabel }; + } + + /** + * Returns an object that has the new value and label, when a field choice is changed. + * + * @param {HTMLElement} choiceElement + * @return {Object} + */ + function getChoiceNewValueAndLabel( choiceElement ) { + const singleOptionContainer = choiceElement.closest( '.frm_single_option' ); + + let newValue, newLabel; + + if ( choiceElement.parentElement.classList.contains( 'frm_single_option' ) ) { // label changed + newValue = singleOptionContainer.querySelector( '.frm_option_key input[type="text"]' ).value; + newLabel = choiceElement.value; + return { newValue, newLabel }; + } + + // saved value changed + newLabel = singleOptionContainer.querySelector( 'input[type="text"]' ).value; + newValue = choiceElement.value; + return { newValue, newLabel }; + } + + /** + * Returns an object that has the old value and label, when a field choice is changed. + * + * @param {HTMLElement} choiceElement + * @return {Object} + */ + function getChoiceOldValueAndLabel( choiceElement ) { + const usingSeparateValues = choiceElement.closest( '.frm-single-settings' ).querySelector( '.frm_toggle_sep_values' )?.checked ?? false; + const singleOptionContainer = choiceElement.closest( '.frm_single_option' ); + + let oldValue, oldLabel; + + if ( usingSeparateValues ) { + if ( choiceElement.parentElement.classList.contains( 'frm_single_option' ) ) { // label changed + oldValue = singleOptionContainer.querySelector( '.frm_option_key input[type="text"]' ).getAttribute( 'data-value-on-focus' ); + oldLabel = choiceElement.getAttribute( 'data-value-on-focus' ); + return { oldValue, oldLabel }; + } + } + oldValue = choiceElement.getAttribute( 'data-value-on-focus' ); + oldLabel = singleOptionContainer.querySelector( 'input[type="text"]' ).getAttribute( 'data-value-on-focus' ); + + return { oldValue, oldLabel }; + } + + function onOptionTextBlur() { + let originalValue, + fieldId, + fieldIndex, + logicId, + row, + rowLength, + rowIndex, + valueSelect, + opts, + fieldIds, + settingId, + setting, + optionMatches, + option; + + const { oldValue, oldLabel, newValue, newLabel } = getChoiceOldAndNewValues( this ); + + if ( oldValue === newValue && oldLabel === newLabel ) { + return; + } + + const singleSettingsContainer = this.closest( '.frm-single-settings' ); + + fieldId = singleSettingsContainer.getAttribute( 'data-fid' ); + originalValue = this.getAttribute( 'data-value-on-load' ); + + // check if the newValue is already mapped to another option + // if it is, mark as duplicate and return + if ( optionTextAlreadyExists( this ) ) { + this.setAttribute( 'data-duplicate', 'true' ); + + if ( typeof optionMap[ fieldId ] !== 'undefined' && typeof optionMap[ fieldId ][ originalValue ] !== 'undefined' ) { + // unmap any other change that may have happened before instead of changing it to something unused + optionMap[ fieldId ][ originalValue ].value = originalValue; + } + + return; + } + + if ( typeof optionMap[ fieldId ] !== 'undefined' && typeof optionMap[ fieldId ][ originalValue ] !== 'undefined' ) { + optionMap[ fieldId ][ originalValue ].value = newValue; + } + + fieldIds = []; + rows = builderPage.querySelectorAll( '.frm_logic_row' ); + rowLength = rows.length; + for ( rowIndex = 0; rowIndex < rowLength; rowIndex++ ) { + row = rows[ rowIndex ]; + opts = row.querySelector( '.frm_logic_field_opts' ); + + if ( opts.value !== fieldId ) { + continue; + } + + logicId = row.id.split( '_' )[ 2 ]; + valueSelect = row.querySelector( 'select[name="field_options[hide_opt_' + logicId + '][]"]' ); + + if ( '' === oldValue ) { + optionMatches = []; + } else { + optionMatches = valueSelect.querySelectorAll( 'option[value="' + oldValue + '"]' ); + } + + if ( ! optionMatches.length ) { + optionMatches = valueSelect.querySelectorAll( 'option[value="' + newValue + '"]' ); + + if ( ! optionMatches.length ) { + if ( ! singleSettingsContainer.querySelector( '.frm_toggle_sep_values' )?.checked ) { + option = searchSelectByText( valueSelect, oldValue ); // Find conditional logic option with oldValue + } + + if ( ! option ) { + option = document.createElement( 'option' ); + valueSelect.appendChild( option ); + } + } + } + + if ( optionMatches.length ) { + option = optionMatches[ optionMatches.length - 1 ]; + } + + option.setAttribute( 'value', newValue ); + option.textContent = newLabel; + + if ( fieldIds.indexOf( logicId ) === -1 ) { + fieldIds.push( logicId ); + } + } + + for ( fieldIndex in fieldIds ) { + settingId = fieldIds[ fieldIndex ]; + setting = document.getElementById( 'frm-single-settings-' + settingId ); + moveFieldSettings( setting ); + } + } + + /** + * Returns an option element that matches a string with its text content. + * + * @param {HTMLElement} selectElement + * @param {string} searchText + * @return {HTMLElement|null} + */ + function searchSelectByText( selectElement, searchText ) { + const options = selectElement.options; + + for ( let i = 0; i < options.length; i++ ) { + const option = options[ i ]; + if ( searchText === option.textContent ) { + return option; + } + } + + return null; + } + + function updateGetValueFieldSelection() { + /*jshint validthis:true */ + const fieldID = this.id.replace( 'get_values_form_', '' ); + const fieldSelect = document.getElementById( 'get_values_field_' + fieldID ); + const fieldType = this.getAttribute( 'data-fieldtype' ); + + if ( this.value === '' ) { + fieldSelect.options.length = 1; + } else { + const formID = this.value; + jQuery.ajax( { + type: 'POST', url: ajaxurl, + data: { + action: 'frm_get_options_for_get_values_field', + form_id: formID, + field_type: fieldType, + nonce: frmGlobal.nonce + }, + success: function( fields ) { + fieldSelect.innerHTML = fields; + } + } ); + } + } + + // Clear the Watch Fields option when Lookup field switches to "Text" option + function maybeClearWatchFields() { + /*jshint validthis:true */ + let link, lookupBlock, + fieldID = this.name.replace( 'field_options[data_type_', '' ).replace( ']', '' ); + + link = document.getElementById( 'frm_add_watch_lookup_link_' + fieldID ); + if ( ! link ) { + return; + } + link = link.parentNode; + + if ( this.value === 'text' ) { + lookupBlock = document.getElementById( 'frm_watch_lookup_block_' + fieldID ); + if ( lookupBlock !== null ) { + // Clear and hide the Watch Fields option + lookupBlock.innerHTML = ''; + link.classList.add( 'frm_hidden' ); + + // Hide the Watch Fields row + link.previousElementSibling.style.display = 'none'; + link.previousElementSibling.previousElementSibling.style.display = 'none'; + link.previousElementSibling.previousElementSibling.previousElementSibling.style.display = 'none'; + } + } else { + // Show the Watch Fields option + link.classList.remove( 'frm_hidden' ); + } + + toggleMultiSelect( fieldID, this.value ); + } + + // Number the pages and hide/show the first page as needed. + function renumberPageBreaks() { + let i, containerClass, + pages = document.getElementsByClassName( 'frm-page-num' ); + + if ( pages.length > 1 ) { + document.getElementById( 'frm-fake-page' ).style.display = 'block'; + for ( i = 0; i < pages.length; i++ ) { + containerClass = pages[ i ].parentNode.parentNode.parentNode.classList; + if ( i === 1 ) { + // Hide previous button on page 1 + containerClass.add( 'frm-first-page' ); + } else { + containerClass.remove( 'frm-first-page' ); + } + pages[ i ].textContent = ( i + 1 ); + } + } else { + document.getElementById( 'frm-fake-page' ).style.display = 'none'; + } + + wp.hooks.doAction( 'frm_renumber_page_breaks', pages ); + } + + // The fake field works differently than real fields. + function maybeCollapsePage() { + /*jshint validthis:true */ + const field = jQuery( this ).closest( '.frm_field_box[data-ftype=break]' ); + if ( field.length ) { + toggleCollapsePage( field ); + } else { + toggleCollapseFakePage(); + } + } + + // Find all fields in a page and hide/show them + function toggleCollapsePage( field ) { + const toCollapse = getAllFieldsForPage( field.get( 0 ).parentNode.closest( 'li.frm_field_box' ).nextElementSibling ); + togglePage( field, toCollapse ); + } + + function toggleCollapseFakePage() { + const topLevel = document.getElementById( 'frm-fake-page' ), + firstField = document.getElementById( 'frm-show-fields' ).firstElementChild, + toCollapse = getAllFieldsForPage( firstField ); + + if ( firstField.getAttribute( 'data-ftype' ) === 'break' ) { + // Don't collapse if the first field is a page break. + return; + } + + togglePage( jQuery( topLevel ), toCollapse ); + } + + function getAllFieldsForPage( firstWrapper ) { + let $fieldsForPage, currentWrapper; + + $fieldsForPage = jQuery(); + + if ( null === firstWrapper ) { + return $fieldsForPage; + } + + currentWrapper = firstWrapper; + + do { + if ( null !== currentWrapper.querySelector( '.edit_field_type_break' ) ) { + break; + } + $fieldsForPage = $fieldsForPage.add( jQuery( currentWrapper ) ); + currentWrapper = currentWrapper.nextElementSibling; + } while ( null !== currentWrapper ); + + return $fieldsForPage; + } + + function togglePage( field, toCollapse ) { + let i, + fieldCount = toCollapse.length, + slide = Math.min( fieldCount, 3 ); + + if ( field.hasClass( 'frm-page-collapsed' ) ) { + field.removeClass( 'frm-page-collapsed' ); + toCollapse.removeClass( 'frm-is-collapsed' ); + for ( i = 0; i < slide; i++ ) { + if ( i === slide - 1 ) { + jQuery( toCollapse[ i ] ).slideDown( 150, function() { + toCollapse.show(); + } ); + } else { + jQuery( toCollapse[ i ] ).slideDown( 150 ); + } + } + } else { + field.addClass( 'frm-page-collapsed' ); + toCollapse.addClass( 'frm-is-collapsed' ); + for ( i = 0; i < slide; i++ ) { + if ( i === slide - 1 ) { + jQuery( toCollapse[ i ] ).slideUp( 150, function() { + toCollapse.css( 'cssText', 'display:none !important;' ); + } ); + } else { + jQuery( toCollapse[ i ] ).slideUp( 150 ); + } + } + } + } + + function maybeCollapseSection() { + /*jshint validthis:true */ + const parentCont = this.parentNode.parentNode.parentNode.parentNode; + + parentCont.classList.toggle( 'frm-section-collapsed' ); + } + + function maybeCollapseSettings() { + /*jshint validthis:true */ + this.classList.toggle( 'frm-collapsed' ); + + // Toggles the "aria-expanded" attribute + const expanded = this.getAttribute( 'aria-expanded' ) === 'true' || false; + this.setAttribute( 'aria-expanded', ! expanded ); + } + + function clickLabel() { + if ( ! this.id ) { + return; + } + + /*jshint validthis:true */ + let setting = document.querySelectorAll( '[data-changeme="' + this.id + '"]' )[ 0 ], + fieldId = this.id.replace( 'field_label_', '' ), + fieldType = document.getElementById( 'field_options_type_' + fieldId ), + fieldTypeName = fieldType.value; + + if ( typeof setting !== 'undefined' ) { + if ( fieldType.tagName === 'SELECT' ) { + fieldTypeName = fieldType.options[ fieldType.selectedIndex ].text.toLowerCase(); + } else { + fieldTypeName = fieldTypeName.replace( '_', ' ' ); + } + + fieldTypeName = normalizeFieldName( fieldTypeName ); + + setTimeout( function() { + if ( setting.value.toLowerCase() === fieldTypeName ) { + setting.select(); + } else { + setting.focus(); + } + }, 50 ); + } + } + + function clickDescription() { + /*jshint validthis:true */ + const setting = document.querySelectorAll( '[data-changeme="' + this.id + '"]' )[ 0 ]; + if ( typeof setting !== 'undefined' ) { + setTimeout( function() { + setting.focus(); + autoExpandSettings( setting ); + }, 50 ); + } + } + + function autoExpandSettings( setting ) { + const inSection = setting.closest( '.frm-collapse-me' ); + if ( inSection !== null ) { + inSection.previousElementSibling.classList.remove( 'frm-collapsed' ); + } + } + + function normalizeFieldName( fieldTypeName ) { + if ( fieldTypeName === 'divider' ) { + fieldTypeName = 'section'; + } else if ( fieldTypeName === 'range' ) { + fieldTypeName = 'slider'; + } else if ( fieldTypeName === 'data' ) { + fieldTypeName = 'dynamic'; + } else if ( fieldTypeName === 'form' ) { + fieldTypeName = 'embed form'; + } + return fieldTypeName; + } + + function clickVis( e ) { + /*jshint validthis:true */ + let currentClass, originalList; + + currentClass = e.target.classList; + + if ( currentClass.contains( 'frm-collapse-page' ) || currentClass.contains( 'frm-sub-label' ) || e.target.closest( '.dropdown' ) !== null ) { + return; + } + + if ( this.closest( '.start_divider' ) !== null ) { + e.stopPropagation(); + } + + if ( this.classList.contains( 'edit_field_type_divider' ) ) { + originalList = e.originalEvent.target.closest( 'ul.frm_sorting' ); + if ( null !== originalList ) { + // prevent section click if clicking a field group within a section. + if ( originalList.classList.contains( 'edit_field_type_divider' ) || originalList.parentNode.parentNode.classList.contains( 'start_divider' ) ) { + return; + } + } + } + + clickAction( this ); + } + + /** + * Update the format input based on the selected format type. + * + * @since 6.9 + * + * @param {Event} event The event object from the format type selection. + * @return {void} + */ + function maybeUpdateFormatInput( event ) { + const formatElement = event.target; + const type = formatElement.value; + + if ( 'custom' === type ) { + const fieldId = formatElement.dataset.fieldId; + const formatInput = document.getElementById( `frm-field-format-custom-${ fieldId }` ).querySelector( '.frm_format_opt' ); + + if ( 'international' === formatInput.value || 'currency' === formatInput.value || 'number' === formatInput.value ) { + formatInput.setAttribute( 'value', '' ); + } + } + + setTimeout( + () => { + formatElement.querySelectorAll( 'option' ).forEach( + option => { + if ( option.selected && option.classList.contains( 'frm_show_upgrade' ) ) { + formatElement.value = 'none'; + } + } + ); + }, + 0 + ); + } + + /** + * Open Advanced settings on double click. + */ + function openAdvanced() { + const fieldId = this.getAttribute( 'data-fid' ); + autoExpandSettings( document.getElementById( 'field_options_field_key_' + fieldId ) ); + } + + function toggleRepeatButtons() { + /*jshint validthis:true */ + const $thisField = jQuery( this ).closest( '.frm_field_box' ); + $thisField.find( '.repeat_icon_links' ).removeClass( 'repeat_format repeat_formatboth repeat_formattext' ).addClass( 'repeat_format' + this.value ); + if ( this.value === 'text' || this.value === 'both' ) { + $thisField.find( '.frm_repeat_text' ).show(); + $thisField.find( '.repeat_icon_links a' ).addClass( 'frm_button' ); + } else { + $thisField.find( '.frm_repeat_text' ).hide(); + $thisField.find( '.repeat_icon_links a' ).removeClass( 'frm_button' ); + } + } + + function checkRepeatLimit() { + /*jshint validthis:true */ + const val = this.value; + if ( val !== '' && ( val < 2 || val > 200 ) ) { + infoModal( frmAdminJs.repeat_limit_min ); + this.value = ''; + } + } + + function checkCheckboxSelectionsLimit() { + /*jshint validthis:true */ + const val = this.value; + if ( val !== '' && ( val < 1 || val > 200 ) ) { + infoModal( frmAdminJs.checkbox_limit ); + this.value = ''; + } + } + + function updateRepeatText( obj, addRemove ) { + const $thisField = jQuery( obj ).closest( '.frm_field_box' ); + $thisField.find( '.frm_' + addRemove + '_form_row .frm_repeat_label' ).text( obj.value ); + } + + function fieldsInSection( id ) { + const children = []; + jQuery( document.getElementById( 'frm_field_id_' + id ) ).find( 'li.frm_field_box:not(.no_repeat_section .edit_field_type_end_divider)' ).each( function() { + children.push( jQuery( this ).data( 'fid' ) ); + } ); + return children; + } + + function toggleFormTax() { + /*jshint validthis:true */ + const id = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ); + const val = this.value; + const $showFields = document.getElementById( 'frm_show_selected_fields_' + id ); + const $showForms = document.getElementById( 'frm_show_selected_forms_' + id ); + + jQuery( $showForms ).find( 'select' ).val( '' ); + if ( val === 'form' ) { + $showForms.style.display = 'inline'; + empty( $showFields ); + } else { + $showFields.style.display = 'none'; + $showForms.style.display = 'none'; + getTaxOrFieldSelection( val, id ); + } + } + + function resetOptOnChange() { + /*jshint validthis:true */ + let field, thisOpt; + + field = getFieldKeyFromOpt( this ); + if ( ! field ) { + return; + } + + thisOpt = jQuery( this ).closest( '.frm_single_option' ); + + resetSingleOpt( field.fieldId, field.fieldKey, thisOpt ); + } + + function getFieldKeyFromOpt( object ) { + let allOpts, fieldId, fieldKey; + + allOpts = jQuery( object ).closest( '.frm_sortable_field_opts' ); + if ( ! allOpts.length ) { + return false; + } + + fieldId = allOpts.attr( 'id' ).replace( 'frm_field_', '' ).replace( '_opts', '' ); + fieldKey = allOpts.data( 'key' ); + + return { + fieldId: fieldId, + fieldKey: fieldKey + }; + } + + function resetSingleOpt( fieldId, fieldKey, thisOpt ) { + let saved, text, defaultVal, previewInput, labelForDisplay, optContainer, + optKey = thisOpt.data( 'optkey' ), + separateValues = usingSeparateValues( fieldId ), + single = jQuery( 'label[for="field_' + fieldKey + '-' + optKey + '"]' ), + baseName = 'field_options[options_' + fieldId + '][' + optKey + ']', + label = jQuery( 'input[name="' + baseName + '[label]"]' ); + + if ( single.length < 1 ) { + resetDisplayedOpts( fieldId ); + + // Set the default value. + defaultVal = thisOpt.find( 'input[name^="default_value_"]' ); + if ( defaultVal.is( ':checked' ) && label.length > 0 ) { + jQuery( 'select[name^="item_meta[' + fieldId + ']"]' ).val( label.val() ); + } + return; + } + + previewInput = single.children( 'input' ); + + if ( label.length < 1 ) { + // Check for other label. + label = jQuery( 'input[name="' + baseName + '"]' ); + saved = label.val(); + } else if ( separateValues ) { + saved = jQuery( 'input[name="' + baseName + '[value]"]' ).val(); + } else { + saved = label.val(); + } + + if ( label.length < 1 ) { + return; + } + + // Set the displayed value. + text = single[ 0 ].childNodes; + + if ( imagesAsOptions( fieldId ) ) { + labelForDisplay = getImageDisplayValue( thisOpt, fieldId, label ); + optContainer = single.find( '.frm_image_option_container' ); + + if ( optContainer.length > 0 ) { + optContainer.replaceWith( labelForDisplay ); + } else { + text[ text.length - 1 ].nodeValue = ''; + single.append( labelForDisplay ); + } + } else { + let firstInputIndex = false; + text.forEach( ( node, index ) => { + if ( firstInputIndex === false ) { + if ( node.tagName === 'INPUT' ) { + firstInputIndex = index; + } + } else if ( index === firstInputIndex + 1 ) { + let nodeValue = ''; + + if ( buttonsAsOptions( fieldId ) ) { + nodeValue = div( { className: 'frm_label_button_container', text: ' ' + label.val() } ); + single[ 0 ].replaceChild( nodeValue, node ); + } else { + node.nodeValue = ' ' + label.val(); + } + } else { + single[ 0 ].removeChild( node ); + } + } ); + } + + // Set saved value. + previewInput.val( saved ); + + // Set the default value. + defaultVal = thisOpt.find( 'input[name^="default_value_"]' ); + previewInput.prop( 'checked', defaultVal.is( ':checked' ) ? true : false ); + } + + function buttonsAsOptions( fieldId ) { + const fields = document.getElementsByName( 'field_options[image_options_' + fieldId + ']' ); + const result = Array.from( fields ).find( field => field.checked && ( 'buttons' === field.value ) ); + + return typeof result !== 'undefined'; + } + + /** + * Set the displayed value for an image option. + */ + function getImageDisplayValue( thisOpt, fieldId, label ) { + let image, imageUrl, showLabelWithImage, fieldType; + + image = thisOpt.find( 'img' ); + if ( image ) { + imageUrl = image.attr( 'src' ); + } + + showLabelWithImage = showingLabelWithImage( fieldId ); + fieldType = radioOrCheckbox( fieldId ); + return getImageLabel( label.val(), showLabelWithImage, imageUrl, fieldType ); + } + + function getImageOptionSize( fieldId ) { + let val, + field = document.getElementById( 'field_options_image_size_' + fieldId ), + size = ''; + + if ( field !== null ) { + val = field.value; + if ( val !== '' ) { + size = val; + } + } + + return size; + } + + function resetDisplayedOpts( fieldId ) { + let i, opts, type, placeholder, fieldInfo, + input = jQuery( '[name^="item_meta[' + fieldId + ']"]' ); + + if ( input.length < 1 ) { + return; + } + + if ( input.is( 'select' ) ) { + placeholder = document.getElementById( 'frm_placeholder_' + fieldId ); + if ( placeholder !== null && placeholder.value === '' ) { + fillDropdownOpts( input[ 0 ], { sourceID: fieldId } ); + } else { + fillDropdownOpts( input[ 0 ], { + sourceID: fieldId, + placeholder: placeholder.value + } ); + } + } else { + opts = getMultipleOpts( fieldId ); + jQuery( '#field_' + fieldId + '_inner_container > .frm_form_fields' ).html( '' ); + fieldInfo = getFieldKeyFromOpt( jQuery( '#frm_delete_field_' + fieldId + '-000_container' ) ); + + const container = jQuery( '#field_' + fieldId + '_inner_container > .frm_form_fields' ), + hasImageOptions = imagesAsOptions( fieldId ), + imageSize = hasImageOptions ? getImageOptionSize( fieldId ) : '', + imageOptionClass = hasImageOptions ? ( 'frm_image_option frm_image_' + imageSize + ' ' ) : '', + isProduct = isProductField( fieldId ); + + type = ( 'hidden' === input.attr( 'type' ) ? input.data( 'field-type' ) : input.attr( 'type' ) ); + for ( i = 0; i < opts.length; i++ ) { + container.append( addRadioCheckboxOpt( type, opts[ i ], fieldId, fieldInfo.fieldKey, isProduct, imageOptionClass ) ); + } + } + + adjustConditionalLogicOptionOrders( fieldId ); + } + + /** + * Returns an object that has a value and label for new conditional logic option, for a given option value. + * + * @param {Number} fieldId + * @param {string} expectedOption + * @return {Object} + */ + function getNewConditionalLogicOption( fieldId, expectedOption ) { + const optionsContainer = document.getElementById( 'frm_field_' + fieldId + '_opts' ); + + const expectedOptionInput = optionsContainer.querySelector( 'input[value="' + expectedOption + '"]' ); + + if ( expectedOptionInput ) { + return getChoiceNewValueAndLabel( expectedOptionInput ); + } + + return { newValue: expectedOption, newLabel: expectedOption }; + } + + function adjustConditionalLogicOptionOrders( fieldId, type ) { + let row, opts, logicId, valueSelect, optionLength, optionIndex, expectedOption, optionMatch, fieldOptions, + rows = builderPage.querySelectorAll( '.frm_logic_row' ), + rowLength = rows.length; + + fieldOptions = wp.hooks.applyFilters( 'frm_conditional_logic_field_options', getFieldOptions( fieldId ), { type, fieldId } ); + optionLength = fieldOptions.length; + + for ( rowIndex = 0; rowIndex < rowLength; rowIndex++ ) { + row = rows[ rowIndex ]; + opts = row.querySelector( '.frm_logic_field_opts' ); + + if ( opts.value != fieldId ) { + continue; + } + + logicId = row.id.split( '_' )[ 2 ]; + valueSelect = row.querySelector( 'select[name="field_options[hide_opt_' + logicId + '][]"]' ); + + for ( optionIndex = optionLength - 1; optionIndex >= 0; optionIndex-- ) { + expectedOption = fieldOptions[ optionIndex ]; + let expectedOptionValue = document.getElementById( 'frm_field_' + fieldId + '_opts' ).querySelector( '.frm_option_key input[type="text"]' )?.value; + if ( ! expectedOptionValue ) { + expectedOptionValue = expectedOption; + } + + optionMatch = valueSelect.querySelector( 'option[value="' + expectedOptionValue + '"]' ); + + const { newValue, newLabel } = getNewConditionalLogicOption( fieldId, expectedOption ); + + const fieldChoices = document.querySelectorAll( '#frm_field_' + fieldId + '_opts input[data-value-on-focus]' ); + const expectedChoiceEl = Array.from( fieldChoices ).find( element => element.value === expectedOption ); + if ( expectedChoiceEl ) { + const oldValue = expectedChoiceEl.dataset.valueOnFocus; + const hasMatch = oldValue && valueSelect.querySelector( 'option[value="' + oldValue + '"]' ); + if ( hasMatch ) { + continue; + } + } + prependValueSelectWithOptionMatch( valueSelect, optionMatch, newValue, newLabel ); + } + + optionMatch = valueSelect.querySelector( 'option[value=""]' ); + if ( optionMatch !== null ) { + valueSelect.prepend( optionMatch ); + } + } + } + + function prependValueSelectWithOptionMatch( valueSelect, optionMatch, newValue, newLabel ) { + if ( optionMatch === null && ! valueSelect.querySelector( 'option[value="' + newValue + '"]' ) ) { + optionMatch = frmDom.tag( 'option', { text: newLabel } ); + optionMatch.value = newValue; + } + + valueSelect.prepend( optionMatch ); + } + + function getFieldOptions( fieldId ) { + let index, input, li, listItems, optsContainer, length, + options = []; + optsContainer = document.getElementById( 'frm_field_' + fieldId + '_opts' ); + + if ( ! optsContainer ) { + return options; + } + listItems = optsContainer.querySelectorAll( '.frm_single_option' ); + length = listItems.length; + + for ( index = 0; index < length; index++ ) { + li = listItems[ index ]; + + if ( li.classList.contains( 'frm_hidden' ) ) { + continue; + } + + input = li.querySelector( '.field_' + fieldId + '_option' ); + options.push( input.value ); + } + return options; + } + + function addRadioCheckboxOpt( type, opt, fieldId, fieldKey, isProduct, classes ) { + let other, + single = '', + isOther = opt.key.indexOf( 'other' ) !== -1, + id = 'field_' + fieldKey + '-' + opt.key, + inputType = type === 'scale' ? 'radio' : type; + + other = ''; + + this.getSingle = function() { + /** + * Get single option template. + * @param {Object} option Object containing the option data. + * @param {string} type The field type. + * @param {string} fieldId The field id. + * @param {string} classes The option clasnames. + * @param {string} id The input id attribute. + */ + single = wp.hooks.applyFilters( 'frm_admin.build_single_option_template', single, { opt, type, fieldId, classes, id } ); + + if ( '' !== single ) { + return single; + } + + return '
                ' + + ( isOther ? other : '' ) + + '
                '; + }; + + return this.getSingle(); + } + + function fillDropdownOpts( field, atts ) { + if ( field === null ) { + return; + } + const sourceID = atts.sourceID, + placeholder = atts.placeholder, + isProduct = isProductField( sourceID ), + showOther = atts.other; + + removeDropdownOpts( field ); + let opts = getMultipleOpts( sourceID ), + hasPlaceholder = ( typeof placeholder !== 'undefined' ); + + for ( let i = 0; i < opts.length; i++ ) { + let label = opts[ i ].label, + isOther = opts[ i ].key.indexOf( 'other' ) !== -1; + + if ( hasPlaceholder && label !== '' ) { + addBlankSelectOption( field, placeholder ); + } else if ( hasPlaceholder ) { + label = placeholder; + } + hasPlaceholder = false; + + if ( ! isOther || showOther ) { + const opt = document.createElement( 'option' ); + opt.value = opts[ i ].saved; + opt.innerHTML = purifyHtml( label ); + + if ( isProduct ) { + opt.setAttribute( 'data-price', opts[ i ].price ); + } + + field.appendChild( opt ); + } + } + } + + function addBlankSelectOption( field, placeholder ) { + const opt = document.createElement( 'option' ), + firstChild = field.firstChild; + + opt.value = ''; + opt.innerHTML = placeholder; + if ( firstChild !== null ) { + field.insertBefore( opt, firstChild ); + field.selectedIndex = 0; + } else { + field.appendChild( opt ); + } + } + + function getMultipleOpts( fieldId ) { + let i, saved, labelName, label, key, optObj, + fieldType, + checked = false, + opts = [], + imageUrl = ''; + + const optVals = jQuery( 'input[name^="field_options[options_' + fieldId + ']"]' ); + const isProduct = isProductField( fieldId ); + const showLabelWithImage = showingLabelWithImage( fieldId ); + const hasImageOptions = imagesAsOptions( fieldId ); + const separateValues = usingSeparateValues( fieldId ); + + for ( i = 0; i < optVals.length; i++ ) { + if ( optVals[ i ].name.indexOf( '[000]' ) > 0 || optVals[ i ].name.indexOf( '[value]' ) > 0 || optVals[ i ].name.indexOf( '[image]' ) > 0 || optVals[ i ].name.indexOf( '[price]' ) > 0 ) { + continue; + } + + saved = optVals[ i ].value; + label = saved; + key = optVals[ i ].name.replace( 'field_options[options_' + fieldId + '][', '' ).replace( '[label]', '' ).replace( ']', '' ); + + if ( separateValues ) { + labelName = optVals[ i ].name.replace( '[label]', '[value]' ); + saved = jQuery( 'input[name="' + labelName + '"]' ).val(); + } + + if ( hasImageOptions ) { + imageUrl = getImageUrlFromInput( optVals[ i ] ); + fieldType = radioOrCheckbox( fieldId ); + label = getImageLabel( label, showLabelWithImage, imageUrl, fieldType ); + } + + /** + * @since 5.0.04 + */ + label = frmAdminBuild.hooks.applyFilters( 'frm_choice_field_label', label, fieldId, optVals[ i ], hasImageOptions ); + + checked = getChecked( optVals[ i ].id ); + + optObj = { + saved: saved, + label: label, + checked: checked, + key: key + }; + + if ( isProduct ) { + labelName = optVals[ i ].name.replace( '[label]', '[price]' ); + optObj.price = jQuery( 'input[name="' + labelName + '"]' ).val(); + } + + opts.push( optObj ); + } + + return opts; + } + + function radioOrCheckbox( fieldId ) { + const settings = document.getElementById( 'frm-single-settings-' + fieldId ); + if ( settings === null ) { + return 'radio'; + } + + return settings.classList.contains( 'frm-type-checkbox' ) ? 'checkbox' : 'radio'; + } + + function getImageUrlFromInput( optVal ) { + let img, + wrapper = jQuery( optVal ).siblings( '.frm_image_preview_wrapper' ); + + if ( ! wrapper.length ) { + return ''; + } + + img = wrapper.find( 'img' ); + if ( ! img.length ) { + return ''; + } + + return img.attr( 'src' ); + } + + function purifyHtml( html ) { + if ( html instanceof Element || html instanceof Document ) { + html = html.outerHTML; + } + + const clean = jQuery.parseHTML( html ).reduce( + ( total, currentNode ) => { + const cleanNode = frmDom.cleanNode( currentNode ); + + if ( '#text' === cleanNode.nodeName ) { + return total += cleanNode.textContent; + } + + return total + cleanNode.outerHTML; + }, + '' + ); + + if ( clean !== html ) { + // Clean it until nothing changes, in case the stripped result is now unsafe. + return purifyHtml( clean ); + } + + return clean; + } + + function getImageLabel( label, showLabelWithImage, imageUrl, fieldType ) { + let imageLabelClass, + originalLabel = label, + shape = fieldType === 'checkbox' ? 'square' : 'circle', + labelImage, + labelNode, + imageLabel; + + originalLabel = purifyHtml( originalLabel ); + + if ( imageUrl ) { + labelImage = img( { src: imageUrl, alt: originalLabel } ); + } else { + labelImage = div( { className: 'frm_empty_url' } ); + labelImage.innerHTML = frmAdminJs.image_placeholder_icon; + } + + imageLabelClass = showLabelWithImage ? ' frm_label_with_image' : ''; + + imageLabel = tag( 'span', { className: 'frm_text_label_for_image_inner' } ); + + imageLabel.innerHTML = originalLabel; + labelNode = tag( + 'span', + { + className: 'frm_image_option_container' + imageLabelClass, + children: [ + labelImage, + tag( 'span', { className: 'frm_text_label_for_image', child: imageLabel } ) + ] + } + ); + + return labelNode; + } + + function getChecked( id ) { + field = jQuery( '#' + id ); + + if ( field.length === 0 ) { + return false; + } + + checkbox = field.siblings( 'input[type=checkbox]' ); + + return checkbox.length && checkbox.prop( 'checked' ); + } + + function removeDropdownOpts( field ) { + let i; + if ( typeof field.options === 'undefined' ) { + return; + } + + for ( i = field.options.length - 1; i >= 0; i-- ) { + field.remove( i ); + } + } + + /** + * Is the box checked to use separate values? + */ + function usingSeparateValues( fieldId ) { + return isChecked( 'separate_value_' + fieldId ); + } + + /** + * Is the box checked to use images as options? + */ + function imagesAsOptions( fieldId ) { + let checked = false, + field = document.getElementsByName( 'field_options[image_options_' + fieldId + ']' ); + + for ( let i = 0; i < field.length; i++ ) { + if ( field[ i ].checked ) { + checked = '0' !== field[ i ].value; + } + } + + /** + * @since 5.0.04 + */ + return frmAdminBuild.hooks.applyFilters( 'frm_choice_field_images_as_options', checked, fieldId ); + } + + function showingLabelWithImage( fieldId ) { + const isShowing = ! isChecked( 'hide_image_text_' + fieldId ); + + /** + * @since 5.0.04 + */ + return frmAdminBuild.hooks.applyFilters( 'frm_choice_field_showing_label_with_image', isShowing, fieldId ); + } + + function isChecked( id ) { + const field = document.getElementById( id ); + if ( field === null ) { + return false; + } + return field.checked; + } + + function checkUniqueOpt( targetInput ) { + const settingsContainer = targetInput.closest( '.frm-single-settings' ); + const fieldId = settingsContainer.getAttribute( 'data-fid' ); + const areValuesSeparate = settingsContainer.querySelector( '[name="field_options[separate_value_' + fieldId + ']"]' ).checked; + + if ( areValuesSeparate && ! targetInput.name.endsWith( '[value]' ) ) { + return; + } + + const container = document.getElementById( 'frm_field_' + fieldId + '_opts' ); + const conflicts = Array.from( container.querySelectorAll( 'input[type="text"]' ) ).filter( + input => input.id !== targetInput.id && + areValuesSeparate === input.name.endsWith( '[value]' ) && + input.value === targetInput.value + ); + + if ( conflicts.length ) { + /* translators: %s: The detected option value. */ + infoModal( sprintf( __( 'Duplicate option value "%s" detected', 'formidable' ), purifyHtml( targetInput.value ) ) ); + } + } + + function getFieldValues() { + /*jshint validthis:true */ + let isTaxonomy, + val = this.value; + + if ( val ) { + const parentIDs = this.parentNode.id.replace( 'frm_logic_', '' ).split( '_' ); + const fieldID = parentIDs[ 0 ]; + const metaKey = parentIDs[ 1 ]; + const valueField = document.getElementById( 'frm_field_id_' + val ); + const valueFieldType = valueField.getAttribute( 'data-ftype' ); + const fill = document.getElementById( 'frm_show_selected_values_' + fieldID + '_' + metaKey ); + const optionName = 'field_options[hide_opt_' + fieldID + '][]'; + const optionID = 'frm_field_logic_opt_' + fieldID; + let input = false; + let showSelect = ( valueFieldType === 'select' || valueFieldType === 'checkbox' || valueFieldType === 'radio' ); + const showText = ( valueFieldType === 'text' || valueFieldType === 'email' || valueFieldType === 'phone' || valueFieldType === 'url' || valueFieldType === 'number' ); + + if ( showSelect ) { + isTaxonomy = document.getElementById( 'frm_has_hidden_options_' + val ); + if ( isTaxonomy !== null ) { + // get the category options with ajax + showSelect = false; + } + } + + if ( showSelect || showText ) { + const comparison = document.querySelector( `#frm_logic_${ fieldID }_${ metaKey } [name="field_options[hide_field_cond_${ fieldID }][]"]` ).value; + fill.innerHTML = ''; + const creatingValuesDropdown = showSelect && ! [ 'LIKE', 'not LIKE', 'LIKE%', '%LIKE' ].includes( comparison ); + if ( creatingValuesDropdown ) { + input = document.createElement( 'select' ); + } else { + input = document.createElement( 'input' ); + input.type = 'text'; + } + input.name = optionName; + input.id = optionID + '_' + metaKey; + fill.appendChild( input ); + + if ( creatingValuesDropdown ) { + const fillField = document.getElementById( input.id ); + fillDropdownOpts( fillField, { + sourceID: val, + placeholder: '', + other: true + } ); + } + } else { + const thisType = this.getAttribute( 'data-type' ); + const callback = () => { + const event = new CustomEvent( 'frm_logic_options_loaded' ); + event.frmData = { valueFieldType, fieldID, metaKey }; + document.dispatchEvent( event ); + }; + + frmGetFieldValues( val, fieldID, metaKey, thisType, undefined, callback ); + } + } + } + + function getFieldSelection() { + /*jshint validthis:true */ + const formId = this.value; + if ( formId ) { + const fieldId = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ); + getTaxOrFieldSelection( formId, fieldId ); + } + } + + function getTaxOrFieldSelection( formId, fieldId ) { + if ( formId ) { + jQuery.ajax( { + type: 'POST', + url: ajaxurl, + data: { + action: 'frm_get_field_selection', + field_id: fieldId, + form_id: formId, + nonce: frmGlobal.nonce + }, + success: function( msg ) { + jQuery( '#frm_show_selected_fields_' + fieldId ).html( msg ).show(); + } + } ); + } + } + + function updateFieldOrder() { + let self = this; + + this.initOnceInAllInstances = function() { + if ( 'undefined' !== typeof updateFieldOrder.prototype.orderFieldsObject ) { + return; + } + + // It will store the order input fields ( input[name="field_options[field_order_{fieldId}]"] ). + // It will help to reduce the DOM searches based on fieldId. + // The same object data is used across all "updateFieldOrder" instances. + updateFieldOrder.prototype.orderFieldsObject = {}; + + // Get the Form group that will handle the fields settings. + // Perform a single DOM search and use it across all "updateFieldOrder" instances. + updateFieldOrder.prototype.fieldSettingsForm = document.getElementById( 'frm-end-form-marker' ).closest( 'form' ); + }; + + this.getFieldOrderInputById = function( fieldId, parent ) { + let field; + const orderFieldsObject = updateFieldOrder.prototype.orderFieldsObject; + const fieldSettingsForm = updateFieldOrder.prototype.fieldSettingsForm; + + if ( 'undefined' === typeof orderFieldsObject[ fieldId ] ) { + field = fieldSettingsForm.querySelector( 'input[name="field_options[field_order_' + fieldId + ']"]' ); + if ( null === field ) { + field = parent.querySelector( 'input[name="field_options[field_order_' + fieldId + ']"]' ); + } + orderFieldsObject[ fieldId ] = field; + return field; + } + + return orderFieldsObject[ fieldId ]; + }; + + this.initOnceInAllInstances(); + renumberPageBreaks(); + + return ( function() { + let fieldId, field, currentOrder, newOrder, + moveFieldsClass = new moveFieldSettings(), + fields = jQuery( 'li.frm_field_box', jQuery( '#frm-show-fields' ) ); + + for ( i = 0; i < fields.length; i++ ) { + fieldId = fields[ i ].getAttribute( 'data-fid' ); + field = self.getFieldOrderInputById( fieldId, fields[ i ] ); + + // get current field order, make sure we don't get the "field" reference as the "field" value will get updated later. + currentOrder = null !== field ? Object.assign( {}, field.value )[ 0 ] : null; + newOrder = i + 1; + + if ( currentOrder != newOrder && null !== currentOrder ) { + field.value = newOrder; + singleField = fields[ i ].querySelector( '#frm-single-settings-' + fieldId ); + + // add field that needs to be moved to "updateFieldOrder.prototype.fieldSettingsForm" + moveFieldsClass.append( singleField ); + fieldUpdated(); + } + } + // move all appended fields + moveFieldsClass.moveFields(); + }() ); + } + + function toggleSectionHolder() { + document.querySelectorAll( '.start_divider' ).forEach( + function( divider ) { + toggleOneSectionHolder( jQuery( divider ) ); + } + ); + } + + function toggleOneSectionHolder( $section ) { + let noSectionFields, $rows, length, index, sectionHasFields; + + if ( ! $section.length ) { + return; + } + + $rows = $section.find( 'ul.frm_sorting' ); + sectionHasFields = false; + length = $rows.length; + for ( index = 0; index < length; ++index ) { + if ( 0 !== getFieldsInRow( jQuery( $rows.get( index ) ) ).length ) { + sectionHasFields = true; + break; + } + } + + noSectionFields = $section.parent().children( '.frm_no_section_fields' ).get( 0 ); + noSectionFields.classList.toggle( 'frm_block', ! sectionHasFields ); + } + + function handleShowPasswordLiveUpdate() { + frmDom.util.documentOn( 'change', '.frm_show_password_setting_input', event => { + const fieldId = event.target.getAttribute( 'data-fid' ); + const fieldEl = document.getElementById( 'frm_field_id_' + fieldId ); + if ( ! fieldEl ) { + return; + } + + fieldEl.classList.toggle( 'frm_disabled_show_password', ! event.target.checked ); + } ); + } + + function slideDown() { + /*jshint validthis:true */ + const id = jQuery( this ).data( 'slidedown' ); + const $thisId = jQuery( document.getElementById( id ) ); + if ( $thisId.is( ':hidden' ) ) { + $thisId.slideDown( 'fast' ); + this.style.display = 'none'; + } + return false; + } + + function slideUp() { + /*jshint validthis:true */ + const id = jQuery( this ).data( 'slideup' ); + const $thisId = jQuery( document.getElementById( id ) ); + $thisId.slideUp( 'fast' ); + $thisId.siblings( 'a' ).show(); + return false; + } + + function adjustVisibilityValuesForEveryoneValues( element, option ) { + if ( '' === option.getAttribute( 'value' ) ) { + onEveryoneOptionSelected( jQuery( this ) ); + } else { + unselectEveryoneOptionIfSelected( jQuery( this ) ); + } + } + + function onEveryoneOptionSelected( $select ) { + $select.val( '' ); + $select.next( '.btn-group' ).find( '.multiselect-container input[value!=""]' ).prop( 'checked', false ); + } + + function unselectEveryoneOptionIfSelected( $select ) { + let selectedValues = $select.val(), + index; + + if ( selectedValues === null ) { + $select.next( '.btn-group' ).find( '.multiselect-container input[value=""]' ).prop( 'checked', true ); + onEveryoneOptionSelected( $select ); + return; + } + + index = selectedValues.indexOf( '' ); + if ( index >= 0 ) { + selectedValues.splice( index, 1 ); + $select.val( selectedValues ); + $select.next( '.btn-group' ).find( '.multiselect-container input[value=""]' ).prop( 'checked', false ); + } + } + + /** + * Get rid of empty container that inserts extra space. + */ + function hideEmptyEle() { + jQuery( '.frm-hide-empty' ).each( function() { + if ( jQuery( this ).text().trim().length === 0 ) { + jQuery( this ).remove(); + } + } ); + } + + /* Change the classes in the builder */ + function changeFieldClass( field, setting ) { + let classes, replace, alignField, + replaceWith = ' ' + setting.value, + fieldId = field.getAttribute( 'data-fid' ); + + // Include classes from multiple settings. + if ( typeof fieldId !== 'undefined' ) { + if ( setting.classList.contains( 'field_options_align' ) ) { + replaceWith += ' ' + document.getElementById( 'frm_classes_' + fieldId ).value; + } else if ( setting.classList.contains( 'frm_classes' ) ) { + alignField = document.getElementById( 'field_options_align_' + fieldId ); + if ( alignField !== null ) { + replaceWith += ' ' + alignField.value; + } + } + } + replaceWith += ' '; + + // Allow for the column number dropdown. + replaceWith = replaceWith.replace( ' block ', ' ' ).replace( ' inline ', ' horizontal_radio ' ); + + classes = field.className.split( ' frmstart ' )[ 1 ]; + classes = 0 === classes.indexOf( 'frmend ' ) ? '' : classes.split( ' frmend ' )[ 0 ]; + + if ( classes.trim() === '' ) { + replace = ' frmstart frmend '; + if ( -1 === field.className.indexOf( replace ) ) { + replace = ' frmstart frmend '; + } + replaceWith = ' frmstart ' + replaceWith.trim() + ' frmend '; + } else { + replace = classes.trim(); + replaceWith = replaceWith.trim(); + } + + field.className = field.className.replace( replace, replaceWith ); + } + + function maybeShowInlineModal( e ) { + /*jshint validthis:true */ + e.preventDefault(); + showInlineModal( this ); + } + + function showInlineModal( icon, input ) { + const box = document.getElementById( icon.getAttribute( 'data-open' ) ), + container = jQuery( icon ).closest( 'p' ), + inputTrigger = ( typeof input !== 'undefined' ); + + if ( container.hasClass( 'frm-open' ) ) { + container.removeClass( 'frm-open' ); + box.classList.add( 'frm_hidden' ); + } else { + if ( ! inputTrigger ) { + input = getInputForIcon( icon ); + } + if ( input !== null ) { + if ( ! inputTrigger ) { + input.focus(); + } + container.after( box ); + box.setAttribute( 'data-fills', input.id ); + + if ( box.id.indexOf( 'frm-calc-box' ) === 0 ) { + popCalcFields( box, true ); + } + } + + container.addClass( 'frm-open' ); + box.classList.remove( 'frm_hidden' ); + + /** + * @since 6.4.1 + */ + wp.hooks.doAction( 'frm_show_inline_modal', box, icon ); + } + } + + function dismissInlineModal( e ) { + /*jshint validthis:true */ + e.preventDefault(); + this.parentNode.classList.add( 'frm_hidden' ); + jQuery( '.frm-open [data-open="' + this.parentNode.id + '"]' ).closest( '.frm-open' ).removeClass( 'frm-open' ); + } + + function changeInputtedValue() { + /*jshint validthis:true */ + let i, + action = this.getAttribute( 'data-frmchange' ).split( ',' ); + + for ( i = 0; i < action.length; i++ ) { + if ( action[ i ] === 'updateOption' ) { + changeHiddenSeparateValue( this ); + } else if ( action[ i ] === 'updateDefault' ) { + changeDefaultRadioValue( this ); + } else if ( action[ i ] === 'checkUniqueOpt' ) { + checkUniqueOpt( this ); + } else { + this.value = this.value[ action[ i ] ](); + } + } + } + + /** + * When the saved value is changed, update the default value radio. + */ + function changeDefaultRadioValue( input ) { + const parentLi = getOptionParent( input ), + key = parentLi.getAttribute( 'data-optkey' ), + fieldId = getOptionFieldId( parentLi, key ), + defaultRadio = parentLi.querySelector( 'input[name="default_value_' + fieldId + '"]' ); + + if ( defaultRadio !== null ) { + defaultRadio.value = input.value; + } + } + + /** + * If separate values are not enabled, change the saved value when + * the displayed value is changed. + */ + function changeHiddenSeparateValue( input ) { + let savedVal, + parentLi = getOptionParent( input ), + key = parentLi.getAttribute( 'data-optkey' ), + fieldId = getOptionFieldId( parentLi, key ), + sep = document.getElementById( 'separate_value_' + fieldId ); + + if ( sep !== null && sep.checked === false ) { + // If separate values are not turned on. + savedVal = document.getElementById( 'field_key_' + fieldId + '-' + key ); + savedVal.value = input.value; + changeDefaultRadioValue( savedVal ); + } + } + + function getOptionParent( input ) { + let parentLi = input.parentNode; + if ( parentLi.tagName !== 'LI' ) { + parentLi = parentLi.parentNode; + } + return parentLi; + } + + function getOptionFieldId( li, key ) { + const liId = li.id; + + return liId.replace( 'frm_delete_field_', '' ).replace( '-' + key + '_container', '' ); + } + + function submitBuild() { + /*jshint validthis:true */ + const $thisEle = this; + + if ( showNameYourFormModal() ) { + return; + } + + preFormSave( this ); + + const $form = jQuery( builderForm ); + const v = JSON.stringify( $form.serializeArray() ); + + jQuery( document.getElementById( 'frm_compact_fields' ) ).val( v ); + jQuery.ajax( { + type: 'POST', + url: ajaxurl, + data: { action: 'frm_save_form', frm_compact_fields: v, nonce: frmGlobal.nonce }, + success: function( msg ) { + afterFormSave( $thisEle ); + + const $postStuff = document.getElementById( 'post-body-content' ); + const $html = document.createElement( 'div' ); + $html.setAttribute( 'class', 'frm_updated_message' ); + $html.innerHTML = msg; + $postStuff.insertBefore( $html, $postStuff.firstChild ); + reloadIfAddonActivatedAjaxSubmitOnly(); + }, + error: function() { + triggerSubmit( document.getElementById( 'frm_js_build_form' ) ); + } + } ); + } + + function triggerSubmit( form ) { + const button = form.ownerDocument.createElement( 'input' ); + button.style.display = 'none'; + button.type = 'submit'; + form.appendChild( button ).click(); + form.removeChild( button ); + } + + function triggerChange( element ) { + jQuery( element ).trigger( 'change' ); + } + + function submitNoAjax() { + /*jshint validthis:true */ + let form; + + if ( showNameYourFormModal() ) { + return; + } + + preFormSave( this ); + form = jQuery( builderForm ); + jQuery( document.getElementById( 'frm_compact_fields' ) ).val( JSON.stringify( form.serializeArray() ) ); + triggerSubmit( document.getElementById( 'frm_js_build_form' ) ); + } + + /** + * Display a modal dialog for naming a new form template, if applicable. + * + * @return {boolean} True if the modal is successfully initialized and displayed; false otherwise. + */ + function showNameYourFormModal() { + // Exit early if the 'new_template' URL parameter is not set to 'true' + if ( ! shouldShowNameYourFormNameModal() ) { + return false; + } + + const modalWidget = initModal( '#frm-form-templates-modal', '440px' ); + if ( ! modalWidget ) { + return false; + } + + // Set the vertical offset for the modal and open it + offsetModalY( modalWidget, '72px' ); + modalWidget.dialog( 'open' ); + + return true; + } + + /** + * Returns true if 'Name Your Form' modal should be displayed. + * + * @return {Boolean} + */ + function shouldShowNameYourFormNameModal() { + const formNameInput = document.getElementById( 'frm_form_name' ); + if ( formNameInput && formNameInput.value.trim() !== '' ) { + return false; + } + + return 'true' === urlParams.get( 'new_template' ) && document.querySelector( '#frm_top_bar #frm_bs_dropdown .frm_bstooltip' )?.textContent.trim() === frm_admin_js.noTitleText; // eslint-disable-line camelcase + } + + /** + * Manages event handling for the 'Name your form' modal. + * + * Attaches click and keydown event listeners to the save button and input field. + * + * @return {void} + */ + function addFormNameModalEvents() { + const saveFormNameButton = document.getElementById( 'frm-save-form-name-button' ); + const newFormNameInput = document.getElementById( 'frm_new_form_name_input' ); + + // Attach click event listener + onClickPreventDefault( saveFormNameButton, onSaveFormNameButton ); + + // Attach keydown event listener + newFormNameInput.addEventListener( 'keydown', function( event ) { + if ( event.key === 'Enter' ) { + onSaveFormNameButton.call( this, event ); + } + } ); + } + + /** + * Handles the click event on the save form name button. + * + * @param {Event} event The click event object. + * @return {void} + */ + const onSaveFormNameButton = event => { + const newFormName = document.getElementById( 'frm_new_form_name_input' ).value.trim(); + + // Prepare FormData for the POST request + const formData = new FormData(); + formData.append( 'form_id', urlParams.get( 'id' ) ); + formData.append( 'form_name', newFormName ); + + // Perform the POST request + doJsonPost( 'rename_form', formData ).then( data => { + // Remove the 'new_template' parameter from the URL and update the browser history + urlParams.delete( 'new_template' ); + currentURL.search = urlParams.toString(); + history.replaceState( {}, '', currentURL.toString() ); + + if ( null !== document.getElementById( 'frm_notification_settings' ) ) { + document.getElementById( 'frm_form_name' ).value = newFormName; + document.getElementById( 'frm_form_key' ).value = data.form_key; + } + + // Trigger the 'Save' button click using jQuery + jQuery( '#frm-publishing' ).find( '.frm_button_submit' ).trigger( 'click' ); + } ); + }; + + function preFormSave( b ) { + removeWPUnload(); + if ( jQuery( 'form.inplace_form' ).length ) { + jQuery( '.inplace_save, .postbox' ).trigger( 'click' ); + } + + if ( b.classList.contains( 'frm_button_submit' ) ) { + b.classList.add( 'frm_loading_form' ); + } else { + b.classList.add( 'frm_loading_button' ); + } + b.setAttribute( 'aria-busy', 'true' ); + + adjustFormatInputBeforeSave(); + } + + /** + * Updates the format input based on the selected format type from dropdowns during the form save process. + * + * @since 6.9 + * + * @return {void} + */ + function adjustFormatInputBeforeSave() { + const formatTypes = document.querySelectorAll( '.frm_format_dropdown, .frm_phone_type_dropdown' ); + const valueMap = { + none: '', + international: 'international', + currency: 'currency', + number: 'number' + }; + + formatTypes.forEach( formatType => { + const value = formatType.value; + if ( value in valueMap ) { + const formatInput = document.getElementById( `frm_format_${ formatType.dataset.fieldId }` ); + formatInput.value = valueMap[ value ]; + } + } ); + } + + function afterFormSave( button ) { + button.classList.remove( 'frm_loading_form' ); + button.classList.remove( 'frm_loading_button' ); + resetOptionTextDetails(); + fieldsUpdated = 0; + button.setAttribute( 'aria-busy', 'false' ); + + setTimeout( function() { + jQuery( '.frm_updated_message' ).fadeOut( 'slow', function() { + this.parentNode.removeChild( this ); + } ); + }, 5000 ); + } + + function initUpgradeModal() { + const $info = initModal( '#frm_upgrade_modal' ); + if ( $info === false ) { + return; + } + + document.addEventListener( 'click', handleUpgradeClick ); + frmDom.util.documentOn( 'change', 'select.frm_select_with_upgrade', handleUpgradeClick ); + + function handleUpgradeClick( event ) { + let element, link, content; + + element = event.target; + + if ( ! element.classList ) { + return; + } + + const showExpiredModal = element.classList.contains( 'frm_show_expired_modal' ) || null !== element.querySelector( '.frm_show_expired_modal' ) || element.closest( '.frm_show_expired_modal' ); + + // If a `select` element is clicked, check if the selected option has a 'data-upgrade' attribute + if ( event.type === 'change' && element.classList.contains( 'frm_select_with_upgrade' ) ) { + const selectedOption = element.options[ element.selectedIndex ]; + if ( selectedOption && selectedOption.dataset.upgrade ) { + element = selectedOption; + } + } + + if ( ! element.dataset.upgrade ) { + let parent = element.closest( '[data-upgrade]' ); + if ( ! parent ) { + parent = element.closest( '.frm_field_box' ); + if ( ! parent ) { + return; + } + // Fake it if it's missing to avoid error. + element.dataset.upgrade = ''; + } + element = parent; + } + + if ( showExpiredModal ) { + const hookName = 'frm_show_expired_modal'; + wp.hooks.doAction( hookName, element ); + return; + } + + const upgradeLabel = element.dataset.upgrade; + if ( ! upgradeLabel || element.classList.contains( 'frm_show_upgrade_tab' ) ) { + return; + } + + event.preventDefault(); + + const modal = $info.get( 0 ); + const lockIcon = modal.querySelector( '.frm_lock_icon' ); + + if ( lockIcon ) { + lockIcon.style.display = 'block'; + lockIcon.classList.remove( 'frm_lock_open_icon' ); + lockIcon.querySelector( 'use' ).setAttribute( 'href', '#frm_lock_icon' ); + } + + const upgradeImageId = 'frm_upgrade_modal_image'; + const oldImage = document.getElementById( upgradeImageId ); + if ( oldImage ) { + oldImage.remove(); + } + + if ( element.dataset.image ) { + if ( lockIcon ) { + lockIcon.style.display = 'none'; + } + lockIcon.parentNode.insertBefore( img( { id: upgradeImageId, src: frmGlobal.url + '/images/' + element.dataset.image } ), lockIcon ); + } + + const level = modal.querySelector( '.license-level' ); + if ( level ) { + level.textContent = getRequiredLicenseFromTrigger( element ); + } + + // If one click upgrade, hide other content + addOneClick( element, 'modal', upgradeLabel ); + + modal.querySelector( '.frm_are_not_installed' ).style.display = element.dataset.image ? 'none' : 'inline-block'; + modal.querySelector( '.frm_feature_label' ).textContent = upgradeLabel; + modal.querySelector( 'h2' ).style.display = 'block'; + + $info.dialog( 'open' ); + + // set the utm medium + const button = modal.querySelector( '.button-primary:not(.frm-oneclick-button)' ); + link = button.getAttribute( 'href' ).replace( /(medium=)[a-z_-]+/ig, '$1' + element.getAttribute( 'data-medium' ) ); + content = element.getAttribute( 'data-content' ); + if ( content === null ) { + content = ''; + } + link = link.replace( /(content=)[a-z_-]+/ig, '$1' + content ); + button.setAttribute( 'href', link ); + } + } + + function getRequiredLicenseFromTrigger( element ) { + if ( element.dataset.requires ) { + return element.dataset.requires; + } + return 'Pro'; + } + + function populateUpgradeTab( element ) { + const title = element.dataset.upgrade; + + const tab = element.getAttribute( 'href' ).replace( '#', '' ); + const container = document.querySelector( '.frm_' + tab ) || document.querySelector( '.' + tab ); + + if ( ! container ) { + return; + } + + if ( container.querySelector( '.frm-upgrade-message' ) ) { + // Tab has already been populated. + return; + } + + const h2 = container.querySelector( 'h2' ); + h2.style.borderBottom = 'none'; + + /* translators: %s: Form Setting section name (ie Form Permissions, Form Scheduling). */ + h2.textContent = sprintf( __( '%s are not installed', 'formidable' ), title ); + + container.classList.add( 'frmcenter' ); + + const upgradeModal = document.getElementById( 'frm_upgrade_modal' ); + appendClonedModalElementToContainer( 'frm-oneclick' ); + appendClonedModalElementToContainer( 'frm-addon-status' ); + + // Borrow the call to action from the Upgrade upgradeModal which should exist on the settings page (it is still used for other upgrades including Actions). + const upgradeModalLink = upgradeModal.querySelector( '.frm-upgrade-link' ); + if ( upgradeModalLink ) { + const upgradeButton = upgradeModalLink.cloneNode( true ); + const level = upgradeButton.querySelector( '.license-level' ); + + if ( level ) { + level.textContent = getRequiredLicenseFromTrigger( element ); + } + + container.appendChild( upgradeButton ); + + // Maybe append the secondary "Already purchased?" link from the upgradeModal as well. + if ( upgradeModalLink.nextElementSibling && upgradeModalLink.nextElementSibling.querySelector( '.frm-link-secondary' ) ) { + container.appendChild( upgradeModalLink.nextElementSibling.cloneNode( true ) ); + } + + appendClonedModalElementToContainer( 'frm-oneclick-button' ); + } + + appendClonedModalElementToContainer( 'frm-upgrade-message' ); + + let upgradeLabel = element.dataset.message; + + if ( upgradeLabel === undefined ) { + upgradeLabel = element.dataset.upgrade; + } + addOneClick( element, 'tab', upgradeLabel ); + + if ( element.dataset.screenshot ) { + container.appendChild( getScreenshotWrapper( element.dataset.screenshot ) ); + } + + function appendClonedModalElementToContainer( className ) { + container.appendChild( upgradeModal.querySelector( '.' + className ).cloneNode( true ) ); + } + } + + function getScreenshotWrapper( screenshot ) { + const folderUrl = frmGlobal.url + '/images/screenshots/'; + const wrapper = div( { + className: 'frm-settings-screenshot-wrapper', + children: [ + getToolbar(), + div( { child: img( { src: folderUrl + screenshot } ) } ) + ] + } ); + + function getToolbar() { + const children = getColorIcons(); + children.push( img( { src: frmGlobal.url + '/images/tab.svg' } ) ); + return div( { + className: 'frm-settings-screenshot-toolbar', + children + } ); + } + + function getColorIcons() { + return [ '#ED8181', '#EDE06A', '#80BE30' ].map( + color => { + const circle = div( { className: 'frm-minmax-icon' } ); + circle.style.backgroundColor = color; + return circle; + } + ); + } + + return wrapper; + } + + /** + * Allow addons to be installed from the upgrade modal. + * + * @param {Element} link + * @param {string} context Either 'modal' or 'tab'. + * @param {string|undefined} upgradeLabel + */ + function addOneClick( link, context, upgradeLabel ) { + let container; + + if ( 'modal' === context ) { + container = document.getElementById( 'frm_upgrade_modal' ); + } else if ( 'tab' === context ) { + container = document.getElementById( link.getAttribute( 'href' ).substr( 1 ) ); + } else { + return; + } + + const oneclickMessage = container.querySelector( '.frm-oneclick' ); + const upgradeMessage = container.querySelector( '.frm-upgrade-message' ); + const showLink = container.querySelector( '.frm-upgrade-link' ); + const button = container.querySelector( '.frm-oneclick-button' ); + const addonStatus = container.querySelector( '.frm-addon-status' ); + + let oneclick = link.getAttribute( 'data-oneclick' ); + let newMessage = link.getAttribute( 'data-message' ); + let showIt = 'block'; + let showMsg = 'block'; + let hideIt = 'none'; + + // If one click upgrade, hide other content. + if ( oneclickMessage !== null && typeof oneclick !== 'undefined' && oneclick ) { + if ( newMessage === null ) { + showMsg = 'none'; + } + showIt = 'none'; + hideIt = 'block'; + oneclick = JSON.parse( oneclick ); + + button.className = button.className.replace( ' frm-install-addon', '' ).replace( ' frm-activate-addon', '' ); + button.className = button.className + ' ' + oneclick.class; + button.rel = oneclick.url; + + if ( oneclick.class === 'frm-activate-addon' ) { + oneclickMessage.textContent = __( 'This plugin is not activated. Would you like to activate it now?', 'formidable' ); + button.textContent = __( 'Activate', 'formidable' ); + } else { + oneclickMessage.textContent = __( 'That add-on is not installed. Would you like to install it now?', 'formidable' ); + button.textContent = __( 'Install', 'formidable' ); + } + } + + if ( ! newMessage ) { + newMessage = upgradeMessage.getAttribute( 'data-default' ); + } + if ( undefined !== upgradeLabel ) { + newMessage = newMessage.replace( '', upgradeLabel ); + } + + upgradeMessage.innerHTML = newMessage; + + if ( link.dataset.upsellImage ) { + upgradeMessage.appendChild( + img( { + src: link.dataset.upsellImage, + alt: link.dataset.upgrade + } ) + ); + } + + // Either set the link or use the default. + showLink.href = getShowLinkHrefValue( link, showLink ); + + addonStatus.style.display = 'none'; + + oneclickMessage.style.display = hideIt; + button.style.display = hideIt === 'block' ? 'inline-block' : hideIt; + upgradeMessage.style.display = showMsg; + showLink.style.display = showIt === 'block' ? 'inline-block' : showIt; + } + + function getShowLinkHrefValue( link, showLink ) { + let customLink = link.getAttribute( 'data-link' ); + if ( customLink === null || typeof customLink === 'undefined' || customLink === '' ) { + customLink = showLink.getAttribute( 'data-default' ); + } + return customLink; + } + + /* Form settings */ + + function showInputIcon( parentClass ) { + if ( typeof parentClass === 'undefined' ) { + parentClass = ''; + } + maybeAddFieldSelection( parentClass ); + jQuery( parentClass + ' .frm_has_shortcodes:not(.frm-with-right-icon) input,' + parentClass + ' .frm_has_shortcodes:not(.frm-with-right-icon) textarea' ).wrap( '' ).before( '' ); + } + + /** + * For reverse compatibility. Check for fields that were + * using the old sidebar. + */ + function maybeAddFieldSelection( parentClass ) { + let i, + missingClass = jQuery( parentClass + ' :not(.frm_has_shortcodes) .frm_not_email_message, ' + parentClass + ' :not(.frm_has_shortcodes) .frm_not_email_to, ' + parentClass + ' :not(.frm_has_shortcodes) .frm_not_email_subject' ); + for ( i = 0; i < missingClass.length; i++ ) { + missingClass[ i ].parentNode.classList.add( 'frm_has_shortcodes' ); + } + } + + function showSuccessOpt() { + /*jshint validthis:true */ + let c = 'success'; + if ( this.name === 'options[edit_action]' ) { + c = 'edit'; + } + const v = jQuery( this ).val(); + jQuery( '.' + c + '_action_box' ).hide(); + if ( v === 'redirect' ) { + jQuery( '.' + c + '_action_redirect_box.' + c + '_action_box' ).fadeIn( 'slow' ); + } else if ( v === 'page' ) { + jQuery( '.' + c + '_action_page_box.' + c + '_action_box' ).fadeIn( 'slow' ); + } else { + jQuery( '.' + c + '_action_message_box.' + c + '_action_box' ).fadeIn( 'slow' ); + } + } + + function copyFormAction( event ) { + if ( waitForActionToLoadBeforeCopy( event.target ) ) { + return; + } + + const targetSettings = event.target.closest( '.frm_form_action_settings' ); + const wysiwygs = targetSettings.querySelectorAll( '.wp-editor-area' ); + if ( wysiwygs.length ) { + // Temporary remove TinyMCE before cloning to avoid TinyMCE conflicts. + wysiwygs.forEach( wysiwyg => { + tinymce.EditorManager.execCommand( 'mceRemoveEditor', true, wysiwyg.id ); + } ); + } + + const $action = jQuery( targetSettings ).clone(); + const currentID = $action.attr( 'id' ).replace( 'frm_form_action_', '' ); + const newID = newActionId( currentID ); + + $action.find( '.frm_action_id, .frm-btn-group' ).remove(); + $action.find( 'input[name$="[' + currentID + '][ID]"]' ).val( '' ); + $action.find( '.widget-inside' ).hide(); + + // the .html() gets original values, so they need to be set + $action.find( 'input[type=text], textarea, input[type=number]' ).prop( 'defaultValue', function() { + return this.value; + } ); + + $action.find( 'input[type=checkbox], input[type=radio]' ).prop( 'defaultChecked', function() { + return this.checked; + } ); + + const rename = new RegExp( '\\[' + currentID + '\\]', 'g' ); + const reid = new RegExp( '_' + currentID + '"', 'g' ); + const reclass = new RegExp( '-' + currentID + '"', 'g' ); + const revalue = new RegExp( '"' + currentID + '"', 'g' ); // if a field id matches, this could cause trouble + + let html = $action.html().replace( rename, '[' + newID + ']' ).replace( reid, '_' + newID + '"' ); + html = html.replace( reclass, '-' + newID + '"' ).replace( revalue, '"' + newID + '"' ); + + const newAction = div( { + id: 'frm_form_action_' + newID, + className: $action.get( 0 ).className + } ); + newAction.setAttribute( 'data-actionkey', newID ); + newAction.innerHTML = html; + newAction.querySelectorAll( '.wp-editor-wrap, .wp-editor-wrap *' ).forEach( + element => { + if ( 'string' === typeof element.className ) { + element.className = element.className.replace( currentID, newID ); + } + element.id = element.id.replace( currentID, newID ); + } + ); + newAction.classList.remove( 'open' ); + document.getElementById( 'frm_notification_settings' ).appendChild( newAction ); + + if ( wysiwygs.length ) { + // Re-initialize the original wysiwyg which was removed before cloning. + wysiwygs.forEach( wysiwyg => { + frmDom.wysiwyg.init( wysiwyg ); + } ); + + newAction.querySelectorAll( '.wp-editor-area' ).forEach( wysiwyg => { + frmDom.wysiwyg.init( wysiwyg ); + } ); + } + + if ( newAction.classList.contains( 'frm_single_on_submit_settings' ) ) { + const autocompleteInput = newAction.querySelector( 'input.frm-page-search' ); + if ( autocompleteInput ) { + initAutocomplete( newAction ); + } + } + + initiateMultiselect(); + + const hookName = 'frm_after_duplicate_action'; + wp.hooks.doAction( hookName, newAction ); + } + + function waitForActionToLoadBeforeCopy( element ) { + let $trigger = jQuery( element ), + $original = $trigger.closest( '.frm_form_action_settings' ), + $inside = $original.find( '.widget-inside' ), + $top; + + if ( $inside.find( 'p, div, table' ).length ) { + return false; + } + + $top = $original.find( '.widget-top' ); + $top.on( 'frm-action-loaded', function() { + $trigger.trigger( 'click' ); + $original.removeClass( 'open' ); + $inside.hide(); + } ); + $top.trigger( 'click' ); + return true; + } + + function newActionId( currentID ) { + let newID = parseInt( currentID, 10 ) + 11; + const exists = document.getElementById( 'frm_form_action_' + newID ); + if ( exists !== null ) { + newID++; + newID = newActionId( newID ); + } + return newID; + } + + function addFormAction() { + /*jshint validthis:true */ + const type = jQuery( this ).data( 'actiontype' ); + + if ( isAtLimitForActionType( type ) ) { + return; + } + + const actionId = getNewActionId(); + const formId = thisFormId; + + const placeholderSetting = document.createElement( 'div' ); + placeholderSetting.classList.add( 'frm_single_' + type + '_settings' ); + + const actionsList = document.getElementById( 'frm_notification_settings' ); + actionsList.appendChild( placeholderSetting ); + + jQuery.ajax( { + type: 'POST', + url: ajaxurl, + data: { + action: 'frm_add_form_action', + type: type, + list_id: actionId, + form_id: formId, + nonce: frmGlobal.nonce + }, + success: handleAddFormActionSuccess + } ); + + function handleAddFormActionSuccess( html ) { + fieldUpdated(); + placeholderSetting.remove(); + + closeOpenActions(); + + const newActionContainer = div(); + newActionContainer.innerHTML = html; + + const widgetTop = newActionContainer.querySelector( '.widget-top' ); + Array.from( newActionContainer.children ).forEach( child => actionsList.appendChild( child ) ); + + jQuery( '.frm_form_action_settings' ).fadeIn( 'slow' ); + + const newAction = document.getElementById( 'frm_form_action_' + actionId ); + + newAction.classList.add( 'open' ); + document.getElementById( 'post-body-content' ).scroll( { + top: newAction.offsetTop + 10, + left: 0, + behavior: 'smooth' + } ); + + // Check if icon should be active + checkActiveAction( type ); + showInputIcon( '#frm_form_action_' + actionId ); + + initiateMultiselect(); + initAutocomplete( newAction ); + + if ( widgetTop ) { + jQuery( widgetTop ).trigger( 'frm-action-loaded' ); + } + + /** + * Fires after added a new form action. + * + * @since 5.5.4 + * + * @param {HTMLElement} formAction Form action element. + */ + frmAdminBuild.hooks.doAction( 'frm_added_form_action', newAction ); + } + } + + function closeOpenActions() { + document.querySelectorAll( '.frm_form_action_settings.open' ).forEach( + setting => setting.classList.remove( 'open' ) + ); + } + + function toggleActionGroups() { + /*jshint validthis:true */ + const actions = document.getElementById( 'frm_email_addon_menu' ).classList, + search = document.getElementById( 'actions-search-input' ); + + if ( actions.contains( 'frm-all-actions' ) ) { + actions.remove( 'frm-all-actions' ); + actions.add( 'frm-limited-actions' ); + } else { + actions.add( 'frm-all-actions' ); + actions.remove( 'frm-limited-actions' ); + } + + // Reset search. + search.value = ''; + triggerEvent( search, 'input' ); + } + + function getNewActionId() { + let actionSettings = document.querySelectorAll( '.frm_form_action_settings' ), + len = getNewRowId( actionSettings, 'frm_form_action_' ); + if ( typeof document.getElementById( 'frm_form_action_' + len ) !== 'undefined' ) { + len = len + 100; + } + if ( lastNewActionIdReturned >= len ) { + len = lastNewActionIdReturned + 1; + } + lastNewActionIdReturned = len; + return len; + } + + function clickAction( obj ) { + const $thisobj = jQuery( obj ); + + if ( obj.className.indexOf( 'selected' ) !== -1 ) { + return; + } + if ( obj.className.indexOf( 'edit_field_type_end_divider' ) !== -1 && $thisobj.closest( '.edit_field_type_divider' ).hasClass( 'no_repeat_section' ) ) { + return; + } + + deselectFields(); + $thisobj.addClass( 'selected' ); + showFieldOptions( obj ); + } + + /** + * When a field is selected, show the field settings in the sidebar. + */ + function showFieldOptions( obj ) { + let i, singleField, + fieldId = obj.getAttribute( 'data-fid' ), + fieldType = obj.getAttribute( 'data-type' ), + allFieldSettings = document.querySelectorAll( '.frm-single-settings:not(.frm_hidden)' ); + + for ( i = 0; i < allFieldSettings.length; i++ ) { + allFieldSettings[ i ].classList.add( 'frm_hidden' ); + } + + singleField = document.getElementById( 'frm-single-settings-' + fieldId ); + moveFieldSettings( singleField ); + + if ( fieldType && 'quantity' === fieldType ) { + popProductFields( jQuery( singleField ).find( '.frmjs_prod_field_opt' )[ 0 ] ); + } + + singleField.classList.remove( 'frm_hidden' ); + document.getElementById( 'frm-options-panel-tab' ).click(); + + const editor = singleField.querySelector( '.wp-editor-area' ); + if ( editor ) { + frmDom.wysiwyg.init( + editor, + { setupCallback: setupTinyMceEventHandlers } + ); + } + + wp.hooks.doAction( 'frmShowedFieldSettings', obj, singleField ); + maybeAddShortcodesModalTriggerIcon( fieldType, fieldId, singleField ); + } + + function maybeAddShortcodesModalTriggerIcon( fieldType, fieldId, singleField ) { + if ( ! shouldAddShortcodesModalTriggerIcon( fieldType ) ) { + return; + } + + const fieldSettingsSelector = '#frm-single-settings-' + fieldId; + if ( document.querySelector( fieldSettingsSelector + ' .frm-show-box' ) ) { + return; + } + singleField.querySelector( '.wp-editor-container' )?.classList.add( 'frm_has_shortcodes' ); + + const wrapTextareaWithIconContainer = () => { + const textareas = document.querySelectorAll( fieldSettingsSelector + ' .frm_has_shortcodes textarea' ); + textareas.forEach( textarea => { + const wrapperSpan = span( { className: 'frm-with-right-icon' } ); + textarea.parentNode.insertBefore( wrapperSpan, textarea ); + wrapperSpan.appendChild( createModalTriggerIcon() ); + wrapperSpan.appendChild( textarea ); + } ); + }; + + const createModalTriggerIcon = () => { + return frmDom.svg( { href: '#frm_more_horiz_solid_icon', classList: [ 'frm-show-box' ] } ); + }; + + wrapTextareaWithIconContainer(); + } + + function shouldAddShortcodesModalTriggerIcon( fieldType ) { + const fieldsWithShortcodesBox = wp.hooks.applyFilters( 'frm_fields_with_shortcode_popup', [ 'html' ] ); + + return fieldsWithShortcodesBox.includes( fieldType ); + } + + function setupTinyMceEventHandlers( editor ) { + editor.on( 'Change', function() { + handleTinyMceChange( editor ); + } ); + } + + function handleTinyMceChange( editor ) { + if ( ! isTinyMceActive() || tinyMCE.activeEditor.isHidden() ) { + return; + } + + editor.targetElm.value = editor.getContent(); + jQuery( editor.targetElm ).trigger( 'change' ); + } + + function isTinyMceActive() { + let activeSettings, wrapper; + + activeSettings = document.querySelector( '.frm-single-settings:not(.frm_hidden)' ); + if ( ! activeSettings ) { + return false; + } + + wrapper = activeSettings.querySelector( '.wp-editor-wrap' ); + return null !== wrapper && wrapper.classList.contains( 'tmce-active' ); + } + + /** + * Move the settings to the sidebar the first time they are changed or selected. + * Keep the end marker at the end of the form. + */ + function moveFieldSettings( singleField ) { + let self = this; + + if ( singleField === null ) { + // The field may have not been loaded yet via ajax. + return; + } + + this.fragment = document.createDocumentFragment(); + + this.initOnceInAllInstances = function() { + if ( 'undefined' !== typeof moveFieldSettings.prototype.endMarker ) { + return; + } + // perform a single search in the DOM and use it across all moveFieldSettings instances + moveFieldSettings.prototype.endMarker = document.getElementById( 'frm-end-form-marker' ); + }; + + this.append = function( field ) { + const classname = null !== field ? field.parentElement.classList : ''; + if ( null === field || ( ! classname.contains( 'frm_field_box' ) && ! classname.contains( 'divider_section_only' ) ) ) { + return; + } + self.fragment.appendChild( field ); + }; + + this.moveFields = function() { + builderForm.insertBefore( self.fragment, moveFieldSettings.prototype.endMarker ); + }; + + this.initOnceInAllInstances(); + + // Move the field if function is called as function with a singleField passed as arg. + // In this particular case only 1 field is needed to be moved so the field will get instantly moved. + // "singleField" may be undefined when it's called as a constructor instead of a function. Use the constructor to add multiple fields which are passed through "append" and move these all at once via "moveFields". + if ( 'undefined' !== typeof singleField ) { + this.append( singleField ); + this.moveFields(); + return; + } + + return { + append: this.append, + moveFields: this.moveFields + }; + } + + function showEmailRow() { + /*jshint validthis:true */ + const actionKey = jQuery( this ).closest( '.frm_form_action_settings' ).data( 'actionkey' ); + const rowType = this.getAttribute( 'data-emailrow' ); + + jQuery( '#frm_form_action_' + actionKey + ' .frm_' + rowType + '_row' ).fadeIn( 'slow' ); + jQuery( this ).fadeOut( 'slow' ); + } + + function hideEmailRow() { + /*jshint validthis:true */ + const actionBox = jQuery( this ).closest( '.frm_form_action_settings' ), + rowType = this.getAttribute( 'data-emailrow' ), + emailRowSelector = '.frm_' + rowType + '_row', + emailButtonSelector = '.frm_' + rowType + '_button'; + + jQuery( actionBox ).find( emailButtonSelector ).fadeIn( 'slow' ); + jQuery( actionBox ).find( emailRowSelector ).fadeOut( 'slow', function() { + jQuery( actionBox ).find( emailRowSelector + ' input' ).val( '' ); + } ); + } + + function showEmailWarning() { + /*jshint validthis:true */ + const actionBox = jQuery( this ).closest( '.frm_form_action_settings' ), + emailRowSelector = '.frm_from_to_match_row', + fromVal = actionBox.find( 'input[name$="[post_content][from]"]' ).val(), + toVal = actionBox.find( 'input[name$="[post_content][email_to]"]' ).val(); + + if ( fromVal === toVal ) { + jQuery( actionBox ).find( emailRowSelector ).fadeIn( 'slow' ); + } else { + jQuery( actionBox ).find( emailRowSelector ).fadeOut( 'slow' ); + } + } + + function checkActiveAction( type ) { + const actionTriggers = document.querySelectorAll( '.frm_' + type + '_action' ); + + if ( isAtLimitForActionType( type ) ) { + const addAlreadyUsedClass = getLimitForActionType( type ) > 0; + markActionTriggersInactive( actionTriggers, addAlreadyUsedClass ); + return; + } + + markActionTriggersActive( actionTriggers ); + } + + function markActionTriggersActive( triggers ) { + triggers.forEach( + trigger => { + if ( trigger.querySelector( '.frm_show_upgrade' ) ) { + // Prevent disabled action becoming active. + return; + } + + trigger.classList.remove( 'frm_inactive_action', 'frm_already_used' ); + trigger.classList.add( 'frm_active_action' ); + } + ); + } + + function markActionTriggersInactive( triggers, addAlreadyUsedClass ) { + triggers.forEach( + trigger => { + trigger.classList.remove( 'frm_active_action' ); + trigger.classList.add( 'frm_inactive_action' ); + if ( addAlreadyUsedClass ) { + trigger.classList.add( 'frm_already_used' ); + } + } + ); + } + + function isAtLimitForActionType( type ) { + let atLimit = getNumberOfActionsForType( type ) >= getLimitForActionType( type ); + + const hookName = 'frm_action_at_limit'; + const hookArgs = { type }; + atLimit = wp.hooks.applyFilters( hookName, atLimit, hookArgs ); + + return atLimit; + } + + function getLimitForActionType( type ) { + return parseInt( jQuery( '.frm_' + type + '_action' ).data( 'limit' ), 10 ); + } + + function getNumberOfActionsForType( type ) { + return jQuery( '.frm_single_' + type + '_settings' ).length; + } + + function actionLimitMessage() { + let message = frmAdminJs.only_one_action; + let limit = this.dataset.limit; + + if ( 'undefined' !== typeof limit ) { + limit = parseInt( limit ); + if ( limit > 1 ) { + message = message.replace( 1, limit ).trim(); + } else { + message += ' ' + frmAdminJs.edit_action_text; + } + } + + infoModal( message ); + } + + function addFormLogicRow() { + /*jshint validthis:true */ + const id = jQuery( this ).data( 'emailkey' ); + const type = jQuery( this ).closest( '.frm_form_action_settings' ).find( '.frm_action_name' ).val(); + const formId = document.getElementById( 'form_id' ).value; + const logicRowsContainer = document.getElementById( 'frm_logic_row_' + id ); + const logicRows = logicRowsContainer.querySelectorAll( '.frm_logic_row' ); + const newRowID = getNewRowId( logicRows, 'frm_logic_' + id + '_' ); + const placeholder = div( { + id: 'frm_logic_' + id + '_' + newRowID, + className: 'frm_logic_row frm_hidden' + } ); + + logicRowsContainer.appendChild( placeholder ); + jQuery.ajax( { + type: 'POST', url: ajaxurl, + data: { + action: 'frm_add_form_logic_row', + email_id: id, + form_id: formId, + meta_name: newRowID, + type: type, + nonce: frmGlobal.nonce + }, + success: function( html ) { + jQuery( document.getElementById( 'logic_link_' + id ) ).fadeOut( 'slow', () => { + placeholder.insertAdjacentHTML( 'beforebegin', html ); + placeholder.remove(); + + // Show conditional logic options after "Add Conditional Logic" is clicked. + jQuery( logicRowsContainer ).parent( '.frm_logic_rows' ).fadeIn( 'slow' ); + } ); + } + } ); + return false; + } + + function checkDupPost() { + /*jshint validthis:true */ + const postField = jQuery( 'select.frm_single_post_field' ); + postField.css( 'border-color', '' ); + const $t = this; + const v = jQuery( $t ).val(); + if ( v === '' || v === 'checkbox' ) { + return false; + } + postField.each( function() { + if ( jQuery( this ).val() === v && this.name !== $t.name ) { + this.style.borderColor = 'red'; + jQuery( $t ).val( '' ); + infoModal( frmAdminJs.field_already_used ); + return false; + } + } ); + } + + function togglePostContent() { + /*jshint validthis:true */ + const v = jQuery( this ).val(); + if ( '' === v ) { + jQuery( '.frm_post_content_opt, select.frm_dyncontent_opt' ).hide().val( '' ); + jQuery( '.frm_dyncontent_opt' ).hide(); + } else if ( 'post_content' === v ) { + jQuery( '.frm_post_content_opt' ).show(); + jQuery( '.frm_dyncontent_opt' ).hide(); + jQuery( 'select.frm_dyncontent_opt' ).val( '' ); + } else { + jQuery( '.frm_post_content_opt' ).hide().val( '' ); + jQuery( 'select.frm_dyncontent_opt, .frm_form_field.frm_dyncontent_opt' ).show(); + } + } + + function fillDyncontent() { + /*jshint validthis:true */ + const v = jQuery( this ).val(); + const $dyn = jQuery( document.getElementById( 'frm_dyncontent' ) ); + if ( '' === v || 'new' === v ) { + $dyn.val( '' ); + jQuery( '.frm_dyncontent_opt' ).show(); + } else { + jQuery.ajax( { + type: 'POST', url: ajaxurl, + data: { action: 'frm_display_get_content', id: v, nonce: frmGlobal.nonce }, + success: function( val ) { + $dyn.val( val ); + jQuery( '.frm_dyncontent_opt' ).show(); + } + } ); + } + } + + function switchPostType() { + /*jshint validthis:true */ + // update all rows of categories/taxonomies + let curSelect, newSelect, + catRows = document.getElementById( 'frm_posttax_rows' ).childNodes, + postParentField = document.querySelector( '.frm_post_parent_field' ), + postMenuOrderField = document.querySelector( '.frm_post_menu_order_field' ), + postType = this.value; + + // Get new category/taxonomy options + jQuery.ajax( { + type: 'POST', + url: ajaxurl, + data: { + action: 'frm_replace_posttax_options', + post_type: postType, + nonce: frmGlobal.nonce + }, + success: function( html ) { + // Loop through each category row, and replace the first dropdown + for ( i = 0; i < catRows.length; i++ ) { + // Check if current element is a div + if ( catRows[ i ].tagName !== 'DIV' ) { + continue; + } + + // Get current category select + curSelect = catRows[ i ].getElementsByTagName( 'select' )[ 0 ]; + + // Set up new select + newSelect = document.createElement( 'select' ); + newSelect.innerHTML = html; + newSelect.className = curSelect.className; + newSelect.name = curSelect.name; + + // Replace the old select with the new select + catRows[ i ].replaceChild( newSelect, curSelect ); + } + } + } ); + + // Get new post parent option. + if ( postParentField ) { + getActionOption( + postParentField, + postType, + 'frm_get_post_parent_option', + function( response, optName ) { + // The replaced string is declared in FrmProFormActionController::ajax_get_post_menu_order_option() in the pro version. + postParentField.querySelector( '.frm_post_parent_opt_wrapper' ).innerHTML = response.replaceAll( 'REPLACETHISNAME', optName ); + initAutocomplete( postParentField ); + } + ); + } + + if ( postMenuOrderField ) { + getActionOption( postMenuOrderField, postType, 'frm_should_use_post_menu_order_option' ); + } + } + + function getActionOption( field, postType, action, successHandler ) { + const opt = field.querySelector( '.frm_autocomplete_value_input' ) || field.querySelector( 'select' ), + optName = opt.getAttribute( 'name' ); + + jQuery.ajax( { + url: ajaxurl, + method: 'POST', + data: { + action: action, + post_type: postType, + _wpnonce: frmGlobal.nonce + }, + success: response => { + if ( 'string' !== typeof response ) { + console.error( response ); + return; + } + + if ( '0' === response ) { + // This post type does not support this field. + field.classList.add( 'frm_hidden' ); + field.value = ''; + return; + } + + field.classList.remove( 'frm_hidden' ); + + if ( 'function' === typeof successHandler ) { + successHandler( response, optName ); + } + }, + error: response => console.error( response ) + } ); + } + + function addPosttaxRow() { + /*jshint validthis:true */ + addPostRow( 'tax', this ); + } + + function addPostmetaRow() { + /*jshint validthis:true */ + addPostRow( 'meta', this ); + } + + function addPostRow( type, button ) { + let name, + id = jQuery( 'input[name="id"]' ).val(), + settings = jQuery( button ).closest( '.frm_form_action_settings' ), + key = settings.data( 'actionkey' ), + postType = settings.find( '.frm_post_type' ).val(), + metaName = 0, + postTypeRows = document.querySelectorAll( '.frm_post' + type + '_row' ); + + if ( postTypeRows.length ) { + name = postTypeRows[ postTypeRows.length - 1 ].id.replace( 'frm_post' + type + '_', '' ); + if ( isNumeric( name ) ) { + metaName = 1 + parseInt( name, 10 ); + } else { + metaName = 1; + } + } + + jQuery.ajax( { + type: 'POST', url: ajaxurl, + data: { + action: 'frm_add_post' + type + '_row', + form_id: id, + meta_name: metaName, + tax_key: metaName, + post_type: postType, + action_key: key, + nonce: frmGlobal.nonce + }, + success: function( html ) { + let cfOpts, optIndex; + jQuery( document.getElementById( 'frm_post' + type + '_rows' ) ).append( html ); + jQuery( '.frm_add_post' + type + '_row.button' ).hide(); + + if ( type === 'meta' ) { + jQuery( '.frm_name_value' ).show(); + cfOpts = document.querySelectorAll( '.frm_toggle_cf_opts' ); + for ( optIndex = 0; optIndex < cfOpts.length - 1; ++optIndex ) { + cfOpts[ optIndex ].style.display = 'none'; + } + } else if ( type === 'tax' ) { + jQuery( '.frm_posttax_labels' ).show(); + } + } + } ); + } + + function isNumeric( value ) { + return ! isNaN( parseFloat( value ) ) && isFinite( value ); + } + + function changePosttaxRow() { + /*jshint validthis:true */ + if ( ! jQuery( this ).closest( '.frm_posttax_row' ).find( '.frm_posttax_opt_list' ).length ) { + return; + } + + jQuery( this ).closest( '.frm_posttax_row' ).find( '.frm_posttax_opt_list' ).html( '
                ' ); + + const postType = jQuery( this ).closest( '.frm_form_action_settings' ).find( 'select[name$="[post_content][post_type]"]' ).val(), + actionKey = jQuery( this ).closest( '.frm_form_action_settings' ).data( 'actionkey' ), + taxKey = jQuery( this ).closest( '.frm_posttax_row' ).attr( 'id' ).replace( 'frm_posttax_', '' ), + metaName = jQuery( this ).val(), + showExclude = jQuery( document.getElementById( taxKey + '_show_exclude' ) ).is( ':checked' ) ? 1 : 0, + fieldId = jQuery( 'select[name$="[post_category][' + taxKey + '][field_id]"]' ).val(), + id = jQuery( 'input[name="id"]' ).val(); + + jQuery.ajax( { + type: 'POST', + url: ajaxurl, + data: { + action: 'frm_add_posttax_row', + form_id: id, + post_type: postType, + tax_key: taxKey, + action_key: actionKey, + meta_name: metaName, + field_id: fieldId, + show_exclude: showExclude, + nonce: frmGlobal.nonce + }, + success: function( html ) { + const $tax = jQuery( document.getElementById( 'frm_posttax_' + taxKey ) ); + $tax.replaceWith( html ); + } + } ); + } + + function toggleCfOpts() { + /*jshint validthis:true */ + const row = jQuery( this ).closest( '.frm_postmeta_row' ); + const cancel = row.find( '.frm_cancelnew' ); + const select = row.find( '.frm_enternew' ); + if ( row.find( 'select.frm_cancelnew' ).is( ':visible' ) ) { + cancel.hide(); + select.show(); + } else { + cancel.show(); + select.hide(); + } + + row.find( 'input.frm_enternew, select.frm_cancelnew' ).val( '' ); + return false; + } + + function toggleFormOpts() { + /*jshint validthis:true */ + const changedOpt = jQuery( this ); + let val = changedOpt.val(); + if ( changedOpt.attr( 'type' ) === 'checkbox' ) { + if ( this.checked === false ) { + val = ''; + } + } + + const toggleClass = changedOpt.data( 'toggleclass' ); + if ( val === '' ) { + jQuery( '.' + toggleClass ).hide(); + } else { + jQuery( '.' + toggleClass ).show(); + jQuery( '.hide_' + toggleClass + '_' + val ).hide(); + } + } + + function submitSettings() { + if ( showNameYourFormModal() ) { + return; + } + + /*jshint validthis:true */ + preFormSave( this ); + triggerSubmit( document.querySelector( '.frm_form_settings' ) ); + } + + /* Customization Panel */ + function insertCode( e ) { + /*jshint validthis:true */ + e.preventDefault(); + insertFieldCode( jQuery( this ), this.getAttribute( 'data-code' ) ); + return false; + } + + function insertFieldCode( element, variable ) { + let rich = false, + elementId = element; + if ( typeof element === 'object' ) { + if ( element.hasClass( 'frm_noallow' ) ) { + return; + } + + elementId = jQuery( element ).closest( '[data-fills]' ).attr( 'data-fills' ); + if ( typeof elementId === 'undefined' ) { + elementId = element.closest( 'div' ).attr( 'class' ); + if ( typeof elementId !== 'undefined' ) { + elementId = elementId.split( ' ' )[ 1 ]; + } + } + } + + if ( typeof elementId === 'undefined' ) { + let active = document.activeElement; + if ( active.type === 'search' ) { + // If the search field has focus, find the correct field. + elementId = active.id.replace( '-search-input', '' ); + if ( elementId.match( /\d/gi ) === null ) { + active = jQuery( '.frm-single-settings:visible .' + elementId ); + elementId = active.attr( 'id' ); + } + } else { + elementId = active.id; + } + } + + if ( elementId ) { + rich = jQuery( '#wp-' + elementId + '-wrap.wp-editor-wrap' ).length > 0; + } + + const contentBox = jQuery( document.getElementById( elementId ) ); + if ( typeof element.attr( 'data-shortcode' ) === 'undefined' && ( ! contentBox.length || typeof contentBox.attr( 'data-shortcode' ) === 'undefined' ) ) { + // this helps to exclude those that don't want shortcode-like inserted content e.g. frm-pro's summary field + const doShortcode = element.parents( 'ul.frm_code_list' ).attr( 'data-shortcode' ); + if ( doShortcode === 'undefined' || doShortcode !== 'no' ) { + variable = '[' + variable + ']'; + } + } + + if ( rich ) { + wpActiveEditor = elementId; + } + + if ( ! contentBox.length ) { + return false; + } + + if ( variable === '[default-html]' || variable === '[default-plain]' ) { + let p = 0; + if ( variable === '[default-plain]' ) { + p = 1; + } + jQuery.ajax( { + type: 'POST', url: ajaxurl, + data: { + action: 'frm_get_default_html', + form_id: jQuery( 'input[name="id"]' ).val(), + plain_text: p, + nonce: frmGlobal.nonce + }, + elementId: elementId, + success: function( msg ) { + if ( rich ) { + const p = document.createElement( 'p' ); + p.innerText = msg; + send_to_editor( p.innerHTML ); + } else { + insertContent( contentBox, msg ); + } + } + } ); + } else { + variable = maybeAddSanitizeUrlToShortcodeVariable( variable, element, contentBox ); + if ( rich ) { + send_to_editor( variable ); + } else { + insertContent( contentBox, variable ); + } + } + return false; + } + + function maybeAddSanitizeUrlToShortcodeVariable( variable, element, contentBox ) { + if ( 'object' !== typeof element || ! ( element instanceof jQuery ) || 0 !== contentBox[ 0 ].id.indexOf( 'success_url_' ) ) { + return variable; + } + + element = element[ 0 ]; + if ( ! element.closest( '#frm-insert-fields-box' ) ) { + // Only add sanitize_url=1 to field shortcodes. + return variable; + } + + if ( ! element.parentNode.classList.contains( 'frm_insert_url' ) ) { + variable = variable.replace( ']', ' sanitize_url=1]' ); + } + + return variable; + } + + function insertContent( contentBox, variable ) { + if ( document.selection ) { + contentBox[ 0 ].focus(); + document.selection.createRange().text = variable; + } else { + obj = contentBox[ 0 ]; + const e = obj.selectionEnd; + + variable = maybeFormatInsertedContent( contentBox, variable, obj.selectionStart, e ); + + obj.value = obj.value.substr( 0, obj.selectionStart ) + variable + obj.value.substr( obj.selectionEnd, obj.value.length ); + + const s = e + variable.length; + + maybeRemoveLayoutClasses( obj, variable ); + + obj.focus(); + obj.setSelectionRange( s, s ); + } + triggerChange( contentBox ); + } + + /** + * When a layout class is added, remove any previous layout classes to avoid conflicts. + * We only expect one layout class to exist for a given field. + * For example, if a field has frm_half and we set it to frm_third, frm_half will be removed. + * + * @since 6.11 + * + * @param {HTMLElement} obj + * @param {string} variable + * @return {void} + */ + function maybeRemoveLayoutClasses( obj, variable ) { + if ( ! obj.classList.contains( 'frm_classes' ) || ! isALayoutClass( variable ) ) { + return; + } + + const removeClasses = obj.value.split( ' ' ).filter( isALayoutClass ); + if ( removeClasses.length ) { + obj.value = maybeRemoveClasses( obj.value, removeClasses, variable.trim() ); + } + } + + /** + * Check if a given class is a layout class. + * + * @since 6.11 + * + * @param {string} className + * @return {boolean} + */ + function isALayoutClass( className ) { + let layoutClasses = [ 'frm_half', 'frm_third', 'frm_two_thirds', 'frm_fourth', 'frm_three_fourths', 'frm_fifth', 'frm_sixth', 'frm2', 'frm3', 'frm4', 'frm6', 'frm8', 'frm9', 'frm10', 'frm12' ]; + return layoutClasses.includes( className.trim() ); + } + + /** + * @since 6.11 + * + * @param {string} beforeValue + * @param {Array} removeClasses + * @param {string} variable + * @return {string} + */ + function maybeRemoveClasses( beforeValue, removeClasses, variable ) { + const currentClasses = beforeValue.split( ' ' ).filter( + currentClass => { + currentClass = currentClass.trim(); + return currentClass.length && ! removeClasses.includes( currentClass ); + } + ); + if ( ! currentClasses.includes( variable ) ) { + currentClasses.push( variable ); + } + return currentClasses.join( ' ' ); + } + + function maybeFormatInsertedContent( input, textToInsert, selectionStart, selectionEnd ) { + const separator = input.data( 'sep' ); + if ( undefined === separator ) { + return textToInsert; + } + + const value = input.val(); + + if ( ! value.trim().length ) { + return textToInsert; + } + + const startPattern = new RegExp( separator + '\\s*$' ); + const endPattern = new RegExp( '^\\s*' + separator ); + + if ( value.substr( 0, selectionStart ).trim().length && false === startPattern.test( value.substr( 0, selectionStart ) ) ) { + textToInsert = separator + textToInsert; + } + + if ( value.substr( selectionEnd, value.length ).trim().length && false === endPattern.test( value.substr( selectionEnd, value.length ) ) ) { + textToInsert += separator; + } + + return textToInsert; + } + + function resetLogicBuilder() { + /*jshint validthis:true */ + const id = document.getElementById( 'frm-id-condition' ), + key = document.getElementById( 'frm-key-condition' ); + + if ( this.checked ) { + id.classList.remove( 'frm_hidden' ); + key.classList.add( 'frm_hidden' ); + triggerEvent( key, 'change' ); + } else { + id.classList.add( 'frm_hidden' ); + key.classList.remove( 'frm_hidden' ); + triggerEvent( id, 'change' ); + } + } + + function setLogicExample() { + let field, code, + idKey = document.getElementById( 'frm-id-key-condition' ).checked ? 'frm-id-condition' : 'frm-key-condition', + is = document.getElementById( 'frm-is-condition' ).value, + text = document.getElementById( 'frm-text-condition' ).value, + result = document.getElementById( 'frm-insert-condition' ); + + idKey = document.getElementById( idKey ); + field = idKey.options[ idKey.selectedIndex ].value; + code = 'if ' + field + ' ' + is + '="' + text + '"]'; + result.setAttribute( 'data-code', code + frmAdminJs.conditional_text + '[/if ' + field ); + result.innerHTML = '[' + code + '[/if ' + field + ']'; + } + + function showBuilderModal() { + /*jshint validthis:true */ + const moreIcon = getIconForInput( this ); + showInlineModal( moreIcon, this ); + } + + function maybeShowModal( input ) { + let moreIcon; + if ( input.parentNode.parentNode.classList.contains( 'frm_has_shortcodes' ) ) { + hideShortcodes(); + moreIcon = getIconForInput( input ); + if ( moreIcon.tagName === 'use' ) { + moreIcon = moreIcon.firstElementChild; + + if ( moreIcon.getAttributeNS( 'http://www.w3.org/1999/xlink', 'href' ).indexOf( 'frm_close_icon' ) === -1 ) { + showShortcodeBox( moreIcon, 'nofocus' ); + } + } else if ( ! moreIcon.classList.contains( 'frm_close_icon' ) ) { + showShortcodeBox( moreIcon, 'nofocus' ); + } + } + } + + function showShortcodes( e ) { + /*jshint validthis:true */ + e.preventDefault(); + e.stopPropagation(); + + showShortcodeBox( this ); + } + + /** + * Handles 'change' event on the document. + * + * @since 6.16.3 + * + * @param {Event} event + * @return {void} + */ + function handleBuilderChangeEvent( event ) { + maybeShowSaveAndReloadModal( event.target ); + } + + /** + * Shows 'Save and Reload' modal if the target field's type is changed. + * + * @since 6.16.3 + * + * @param {HTMLElement} target + * @return {void} + */ + function maybeShowSaveAndReloadModal( target ) { + if ( ! target.id.startsWith( 'field_options_type_' ) ) { + return; + } + const idParts = target.id.split( '_' ); + const fieldId = idParts.length && idParts[ idParts.length - 1 ]; + + if ( document.querySelector( `#frm-single-settings-${ fieldId }` )?.classList.contains( `frm-type-${ target.value }` ) ) { + // Do not show modal if the field type is reverted back to the original type when builder is loaded. + return; + } + showSaveAndReloadModal(); + } + + /** + * Shows 'Save and Reload' modal with the given message. + * + * @since 6.16.3 + * + * @param {string} message + * @return {void} + */ + function showSaveAndReloadModal( message ) { + if ( 'undefined' === typeof message ) { + message = __( 'You are changing the field type. Not all field settings will appear as expected until you reload the page. Would you like to reload the page now?', 'formidable' ); + } + frmDom.modal.maybeCreateModal( + 'frmSaveAndReloadModal', + { + title: __( 'Save and Reload?', 'formidable' ), + content: getModalContent(), + footer: getModalFooter() + } + ); + + function getModalContent() { + const modalContent = div( message ); + modalContent.style.padding = 'var(--gap-md)'; + return modalContent; + } + + function getModalFooter() { + const continueButton = frmDom.modal.footerButton( { + text: __( 'Save and Reload', 'formidable' ), + buttonType: 'primary' + } ); + + onClickPreventDefault( continueButton, () => { + saveAndReloadFormBuilder(); + } ); + + const cancelButton = frmDom.modal.footerButton( { + text: __( 'Cancel', 'formidable' ), + buttonType: 'cancel' + } ); + cancelButton.classList.add( 'dismiss' ); + + return frmDom.div( { + children: [ cancelButton, continueButton ] + } ); + } + } + + function updateShortcodesPopupPosition( target ) { + let moreIcon; + if ( target instanceof Event ) { + const useElements = document.querySelectorAll( '.frm-single-settings .frm-show-box.frmsvg use' ); + const openTrigger = Array.from( useElements ).find( use => use.getAttribute( 'href' ) === '#frm_close_icon' ); + if ( 'undefined' === typeof openTrigger ) { + return; + } + moreIcon = openTrigger.parentElement; + } else { + moreIcon = target; + } + + const moreIconPosition = moreIcon.getBoundingClientRect(); + const shortCodesPopup = document.getElementById( 'frm_adv_info' ); + const parentPos = shortCodesPopup.parentElement.getBoundingClientRect(); + + shortCodesPopup.style.top = ( moreIconPosition.top - parentPos.top + 32 ) + 'px'; + shortCodesPopup.style.left = ( moreIconPosition.left - parentPos.left - 280 ) + 'px'; + } + + function showShortcodeBox( moreIcon, shouldFocus ) { + let input = getInputForIcon( moreIcon ), + box = document.getElementById( 'frm_adv_info' ), + classes = moreIcon.className; + + if ( moreIcon.tagName === 'svg' ) { + moreIcon = moreIcon.firstElementChild; + } + if ( moreIcon.tagName === 'use' ) { + classes = moreIcon.getAttributeNS( 'http://www.w3.org/1999/xlink', 'href' ); + + if ( null === classes ) { + // If the deprecated xlink:href is not defined, check for href. + classes = moreIcon.getAttribute( 'href' ); + } + } + + if ( classes.indexOf( 'frm_close_icon' ) !== -1 ) { + hideShortcodes( box ); + } else { + updateShortcodesPopupPosition( moreIcon ); + + jQuery( '.frm_code_list a' ).removeClass( 'frm_noallow' ); + if ( input.classList.contains( 'frm_not_email_to' ) ) { + jQuery( '#frm-insert-fields-box .frm_code_list li:not(.show_frm_not_email_to) a' ).addClass( 'frm_noallow' ); + } else if ( input.classList.contains( 'frm_not_email_subject' ) ) { + jQuery( '.frm_code_list li.hide_frm_not_email_subject a' ).addClass( 'frm_noallow' ); + } + + box.setAttribute( 'data-fills', input.id ); + box.style.display = 'block'; + + if ( moreIcon.tagName === 'use' ) { + if ( moreIcon.hasAttributeNS( 'http://www.w3.org/1999/xlink', 'href' ) ) { + moreIcon.setAttributeNS( 'http://www.w3.org/1999/xlink', 'href', '#frm_close_icon' ); + } else { + const newMoreIcon = document.createElementNS( 'http://www.w3.org/2000/svg', 'use' ); + newMoreIcon.setAttributeNS( 'http://www.w3.org/1999/xlink', 'href', '#frm_close_icon' ); + moreIcon.parentNode.replaceChild( newMoreIcon, moreIcon ); + } + } else { + moreIcon.className = classes.replace( 'frm_more_horiz_solid_icon', 'frm_close_icon' ); + } + + if ( shouldFocus !== 'nofocus' ) { + if ( 'none' !== input.style.display ) { + input.focus(); + } else { + jQuery( tinymce.get( input.id ) ).trigger( 'focus' ); + } + } + showOrHideContextualShortcodes( input ); + } + } + + /** + * Returns true if a shortcode could be shown in the search result. + * + * @since 6.16.3 + * + * @param {HTMLElement} item + * @return {Boolean} + */ + function checkContextualShortcode( item ) { + if ( frmAdminJs.contextualShortcodes.length === 0 ) { + return true; + } + return ! isContextualShortcode( item ) || canShowContextualShortcode( item ); + } + + /** + * Returns true if a shortcode is contextual to fields. + * + * @since 6.16.3 + * + * @param {HTMLElement} item + * @return {Boolean} + */ + function isContextualShortcode( item ) { + const anchor = item.querySelector( 'a' ); + if ( ! anchor ) { + return false; + } + + const shortcode = anchor.dataset.code; + return frmAdminJs.contextualShortcodes.address.includes( shortcode ) || frmAdminJs.contextualShortcodes.body.includes( shortcode ); + } + + /** + * @since 6.16.3 + * + * @param {HTMLElement} item + * @return {Boolean} + */ + function canShowContextualShortcode( item ) { + const shortcode = item.querySelector( 'a' ).dataset.code; + const inputId = document.getElementById( 'frm_adv_info' ).dataset.fills; + const input = document.getElementById( inputId ); + const contextualShortcodes = frmAdminJs.contextualShortcodes; + if ( contextualShortcodes.address.includes( shortcode ) ) { + return input.matches( contextualShortcodes.addressSelector ); + } + return input.matches( contextualShortcodes.bodySelector ); + } + + /** + * @since 6.16.3 + * + * @param {HTMLElement} input + * @return {void} + */ + function showOrHideContextualShortcodes( input ) { + [ 'address', 'body' ].forEach( type => { + toggleContextualShortcodes( input, type ); + } ); + } + + /** + * @since 6.16.3 + * + * @param {HTMLElement} input + * @param {string} type + * + * @return {void} + */ + function toggleContextualShortcodes( input, type ) { + let selector, contextualShortcodes; + selector = frmAdminJs.contextualShortcodes[ type + 'Selector' ]; + contextualShortcodes = frmAdminJs.contextualShortcodes[ type ]; + let shouldShowShortcodes = input.matches( selector ); + for ( let shortcode of contextualShortcodes ) { + const shortcodeLi = document.querySelector( '#frm-adv-info-tab .frm_code_list [data-code="' + shortcode + '"]' )?.closest( 'li' ); + shortcodeLi?.classList.toggle( 'frm_hidden', ! shouldShowShortcodes ); + } + } + + /** + * Returns shortcodes that are contextual to the current input field. + * + * @since 6.16.3 + * + * @return {Array} + */ + function getContextualShortcodes() { + let contextualShortcodes = document.getElementById( 'frm_adv_info' )?.dataset.contextualShortcodes; + if ( ! contextualShortcodes ) { + return []; + } + contextualShortcodes = JSON.parse( contextualShortcodes ); + contextualShortcodes.addressSelector = '[id^=email_to], [id^=from_], [id^=cc], [id^=bcc]'; + contextualShortcodes.bodySelector = '[id^=email_message_]'; + return contextualShortcodes; + } + + function fieldUpdated() { + if ( ! fieldsUpdated ) { + fieldsUpdated = 1; + window.addEventListener( 'beforeunload', confirmExit ); + } + } + + function buildSubmittedNoAjax() { + // set fieldsUpdated to 0 to avoid the unsaved changes pop up + fieldsUpdated = 0; + } + + function settingsSubmitted() { + // set fieldsUpdated to 0 to avoid the unsaved changes pop up + fieldsUpdated = 0; + } + + function saveAndReloadSettings() { + let page, form; + page = document.getElementById( 'form_settings_page' ); + if ( null !== page ) { + form = page.querySelector( 'form.frm_form_settings' ); + if ( null !== form ) { + fieldsUpdated = 0; + form.submit(); + } + } + } + + function reloadIfAddonActivatedAjaxSubmitOnly() { + const submitButton = document.getElementById( 'frm_submit_side_top' ); + if ( submitButton.hasAttribute( 'data-new-addon-installed' ) && 'true' === submitButton.getAttribute( 'data-new-addon-installed' ) ) { + submitButton.removeAttribute( 'data-new-addon-installed' ); + window.location.reload(); + } + } + + function saveAndReloadFormBuilder() { + const submitButton = document.getElementById( 'frm_submit_side_top' ); + if ( submitButton.classList.contains( 'frm_submit_ajax' ) ) { + submitButton.setAttribute( 'data-new-addon-installed', true ); + } + submitButton.click(); + } + + function confirmExit( event ) { + if ( fieldsUpdated ) { + event.preventDefault(); + event.returnValue = ''; + } + } + + function bindClickForDialogClose( $modal ) { + const closeModal = function() { + $modal.dialog( 'close' ); + }; + jQuery( '.ui-widget-overlay' ).on( 'click', closeModal ); + $modal.on( 'click', 'a.dismiss', closeModal ); + } + + function offsetModalY( $modal, amount ) { + const position = { + my: 'top', + at: 'top+' + amount, + of: window + }; + $modal.dialog( 'option', 'position', position ); + } + + /** + * Get the input box for the selected ... icon. + */ + function getInputForIcon( moreIcon ) { + let input = moreIcon.nextElementSibling; + + while ( input !== null && input.tagName !== 'INPUT' && input.tagName !== 'TEXTAREA' ) { + input = getInputForIcon( input ); + } + + return input; + } + + /** + * Get the ... icon for the selected input box. + */ + function getIconForInput( input ) { + let moreIcon = input.previousElementSibling; + + while ( moreIcon !== null && moreIcon.tagName !== 'I' && moreIcon.tagName !== 'svg' ) { + moreIcon = getIconForInput( moreIcon ); + } + + return moreIcon; + } + + function hideShortcodes( box ) { + let i, u, closeIcons, closeSvg; + if ( typeof box === 'undefined' ) { + box = document.getElementById( 'frm_adv_info' ); + if ( box === null ) { + return; + } + } + + if ( document.getElementById( 'frm_dyncontent' ) !== null ) { + // Don't run when in the sidebar. + return; + } + + box.style.display = 'none'; + + closeIcons = document.querySelectorAll( '.frm-show-box.frm_close_icon' ); + for ( i = 0; i < closeIcons.length; i++ ) { + closeIcons[ i ].classList.remove( 'frm_close_icon' ); + closeIcons[ i ].classList.add( 'frm_more_horiz_solid_icon' ); + } + + closeSvg = document.querySelectorAll( '.frm_has_shortcodes use' ); + for ( u = 0; u < closeSvg.length; u++ ) { + if ( closeSvg[ u ].getAttributeNS( 'http://www.w3.org/1999/xlink', 'href' ) === '#frm_close_icon' ) { + if ( closeSvg[ u ].closest( '.frm_remove_field' ) ) { + // Don't change the icon for the email fields remove button. + continue; + } + closeSvg[ u ].setAttributeNS( 'http://www.w3.org/1999/xlink', 'href', '#frm_more_horiz_solid_icon' ); + } + } + } + + function toggleAllowedHTML( input ) { + let b, + id = input.id; + if ( typeof id === 'undefined' || id.indexOf( '-search-input' ) !== -1 ) { + return; + } + + jQuery( '#frm-adv-info-tab' ).attr( 'data-fills', id.trim() ); + if ( input.classList.contains( 'field_custom_html' ) ) { + id = 'field_custom_html'; + } + + b = [ 'after_html', 'before_html', 'submit_html', 'field_custom_html' ]; + if ( jQuery.inArray( id, b ) >= 0 ) { + jQuery( '.frm_code_list li:not(.show_' + id + ')' ).addClass( 'frm_hidden' ); + jQuery( '.frm_code_list li.show_' + id ).removeClass( 'frm_hidden' ); + } + } + + function toggleKeyID( switchTo, e ) { + e.stopPropagation(); + jQuery( '.frm_code_list .frmids, .frm_code_list .frmkeys' ).addClass( 'frm_hidden' ); + jQuery( '.frm_code_list .' + switchTo ).removeClass( 'frm_hidden' ); + jQuery( '.frmids, .frmkeys' ).removeClass( 'current' ); + jQuery( '.' + switchTo ).addClass( 'current' ); + } + + function onActionLoaded( event ) { + const settings = event.target.closest( '.frm_form_action_settings' ); + if ( settings && ( settings.classList.contains( 'frm_single_email_settings' ) || settings.classList.contains( 'frm_single_on_submit_settings' ) ) ) { + initWysiwygOnActionLoaded( settings ); + } + } + + function initWysiwygOnActionLoaded( settings ) { + settings.querySelectorAll( '.wp-editor-area' ).forEach( wysiwyg => { + frmDom.wysiwyg.init( + wysiwyg, + { height: 160, addFocusEvents: true } + ); + } ); + } + + /* Global settings page */ + function loadSettingsTab( anchor ) { + const holder = anchor.replace( '#', '' ); + const holderContainer = jQuery( '.frm_' + holder + '_ajax' ); + if ( holderContainer.length ) { + jQuery.ajax( { + type: 'POST', url: ajaxurl, + data: { + action: 'frm_settings_tab', + tab: holder.replace( '_settings', '' ), + nonce: frmGlobal.nonce + }, + success: function( html ) { + holderContainer.replaceWith( html ); + } + } ); + } + } + + function uninstallNow() { + /*jshint validthis:true */ + if ( confirmLinkClick( this ) === true ) { + jQuery( '.frm_uninstall .frm-wait' ).css( 'visibility', 'visible' ); + jQuery.ajax( { + type: 'POST', + url: ajaxurl, + data: 'action=frm_uninstall&nonce=' + frmGlobal.nonce, + success: function( msg ) { + jQuery( '.frm_uninstall' ).fadeOut( 'slow' ); + window.location = msg; + } + } ); + } + return false; + } + + function saveAddonLicense() { + /*jshint validthis:true */ + const button = jQuery( this ); + const buttonName = this.name; + const pluginSlug = this.getAttribute( 'data-plugin' ); + const action = buttonName.replace( 'edd_' + pluginSlug + '_license_', '' ); + let license = document.getElementById( 'edd_' + pluginSlug + '_license_key' ).value; + button.get( 0 ).disabled = true; + jQuery.ajax( { + type: 'POST', url: ajaxurl, dataType: 'json', + data: { action: 'frm_addon_' + action, license: license, plugin: pluginSlug, nonce: frmGlobal.nonce }, + success: function( msg ) { + button.get( 0 ).disabled = false; + const thisRow = button.closest( '.edd_frm_license_row' ); + if ( action === 'deactivate' ) { + license = ''; + document.getElementById( 'edd_' + pluginSlug + '_license_key' ).value = ''; + } + thisRow.find( '.edd_frm_license' ).html( license ); + const eddWrapper = button.get( 0 ).closest( '.frm_form_field' ); + const actionIsSuccess = msg.success === true; + eddWrapper.querySelector( `.frm_icon_font.frm_action_success` ).classList.toggle( 'frm_hidden', ! actionIsSuccess || action === 'deactivate' ); + eddWrapper.querySelector( `.frm_icon_font.frm_action_error` ).classList.toggle( 'frm_hidden', actionIsSuccess ); + + const messageBox = thisRow.find( '.frm_license_msg' ); + messageBox.html( msg.message ); + if ( msg.message !== '' ) { + setTimeout( function() { + messageBox.html( '' ); + thisRow.find( '.frm_icon_font' ).addClass( 'frm_hidden' ); + if ( actionIsSuccess ) { + const actionIsActivate = action === 'activate'; + thisRow.get( 0 ).querySelector( '.edd_frm_unauthorized' ).classList.toggle( 'frm_hidden', actionIsActivate ); + thisRow.get( 0 ).querySelector( '.edd_frm_authorized' ).classList.toggle( 'frm_hidden', ! actionIsActivate ); + } + }, 2000 ); + } + } + } ); + } + + /* Import/Export page */ + + function startFormMigration( event ) { + event.preventDefault(); + + const checkedBoxes = jQuery( event.target ).find( 'input:checked' ); + if ( ! checkedBoxes.length ) { + return; + } + + const ids = []; + checkedBoxes.each( function( i ) { + ids[ i ] = this.value; + } ); + + // Begin the import process. + importForms( ids, event.target ); + } + + /** + * Begins the process of importing the forms. + */ + function importForms( forms, targetForm ) { + // Hide the form select section. + const $form = jQuery( targetForm ), + $processSettings = $form.next( '.frm-importer-process' ); + + // Display total number of forms we have to import. + $processSettings.find( '.form-total' ).text( forms.length ); + $processSettings.find( '.form-current' ).text( '1' ); + + $form.hide(); + + // Show processing status. + // '.process-completed' might have been shown earlier during a previous import, so hide now. + $processSettings.find( '.process-completed' ).hide(); + $processSettings.show(); + + // Create global import queue. + s.importQueue = forms; + s.imported = 0; + + // Import the first form in the queue. + importForm( $processSettings ); + } + + /** + * Imports a single form from the import queue. + */ + function importForm( $processSettings ) { + const formID = s.importQueue[ 0 ], + provider = jQuery( '#welcome-panel' ).find( 'input[name="slug"]' ).val(), + data = { + action: 'frm_import_' + provider, + form_id: formID, + nonce: frmGlobal.nonce + }; + + // Trigger AJAX import for this form. + jQuery.post( ajaxurl, data, function( res ) { + if ( res.success ) { + let statusUpdate; + + if ( res.data.error ) { + statusUpdate = '

                ' + res.data.name + ': ' + res.data.msg + '

                '; + } else { + statusUpdate = '

                Imported ' + res.data.name + '

                '; + } + + $processSettings.find( '.status' ).prepend( statusUpdate ); + $processSettings.find( '.status' ).show(); + + // Remove this form ID from the queue. + s.importQueue = jQuery.grep( s.importQueue, function( value ) { + return value != formID; + } ); + s.imported++; + + if ( s.importQueue.length === 0 ) { + $processSettings.find( '.process-count' ).hide(); + $processSettings.find( '.forms-completed' ).text( s.imported ); + $processSettings.find( '.process-completed' ).show(); + } else { + // Import next form in the queue. + $processSettings.find( '.form-current' ).text( s.imported + 1 ); + importForm( $processSettings ); + } + } + } ); + } + + function validateExport( e ) { + /*jshint validthis:true */ + e.preventDefault(); + + let s = false; + const $exportForms = jQuery( 'input[name="frm_export_forms[]"]' ); + + if ( ! jQuery( 'input[name="frm_export_forms[]"]:checked' ).val() ) { + $exportForms.closest( '.frm-table-box' ).addClass( 'frm_blank_field' ); + s = 'stop'; + } + + const $exportType = jQuery( 'input[name="type[]"]' ); + if ( ! jQuery( 'input[name="type[]"]:checked' ).val() && $exportType.attr( 'type' ) === 'checkbox' ) { + $exportType.closest( 'p' ).addClass( 'frm_blank_field' ); + s = 'stop'; + } + + if ( s === 'stop' ) { + return false; + } + + e.stopPropagation(); + this.submit(); + } + + function removeExportError() { + /*jshint validthis:true */ + const t = jQuery( this ).closest( '.frm_blank_field' ); + if ( typeof t === 'undefined' ) { + return; + } + + const $thisName = this.name; + if ( $thisName === 'type[]' && jQuery( 'input[name="type[]"]:checked' ).val() ) { + t.removeClass( 'frm_blank_field' ); + } else if ( $thisName === 'frm_export_forms[]' && jQuery( this ).val() ) { + t.removeClass( 'frm_blank_field' ); + } + } + + function checkCSVExtension() { + /*jshint validthis:true */ + const f = jQuery( this ).val(); + const re = /\.csv$/i; + if ( f.match( re ) !== null ) { + jQuery( '.show_csv' ).fadeIn(); + } else { + jQuery( '.show_csv' ).fadeOut(); + } + } + + function getExportOption() { + const exportFormatSelect = document.querySelector( 'select[name="format"]' ); + if ( exportFormatSelect ) { + return exportFormatSelect.value; + } + return ''; + } + + function exportTypeChanged( event ) { + const value = event.target.value; + showOrHideRepeaters( value ); + checkExportTypes.call( event.target ); + checkSelectedAllFormsCheckbox( value ); + } + + function checkSelectedAllFormsCheckbox( exportType ) { + const selectAllCheckbox = document.getElementById( 'frm-export-select-all' ); + if ( exportType === 'csv' ) { + selectAllCheckbox.checked = false; + selectAllCheckbox.disabled = true; + } else { + selectAllCheckbox.disabled = false; + } + } + + function checkExportTypes() { + /*jshint validthis:true */ + const $dropdown = jQuery( this ); + const $selected = $dropdown.find( ':selected' ); + const s = $selected.data( 'support' ); + + const multiple = s.indexOf( '|' ); + jQuery( 'input[name="type[]"]' ).each( function() { + this.checked = false; + if ( s.indexOf( this.value ) >= 0 ) { + this.disabled = false; + if ( multiple === -1 ) { + this.checked = true; + } + } else { + this.disabled = true; + } + } ); + + if ( $dropdown.val() === 'csv' ) { + jQuery( '.csv_opts' ).show(); + jQuery( '.xml_opts' ).hide(); + } else { + jQuery( '.csv_opts' ).hide(); + jQuery( '.xml_opts' ).show(); + } + + const c = $selected.data( 'count' ); + const exportField = jQuery( 'input[name="frm_export_forms[]"]' ); + if ( c === 'single' ) { + exportField.prop( 'multiple', false ); + exportField.prop( 'checked', false ); + } else { + exportField.prop( 'multiple', true ); + exportField.prop( 'disabled', false ); + } + $dropdown.trigger( 'change' ); + } + + function showOrHideRepeaters( exportOption ) { + if ( exportOption === '' ) { + return; + } + + const repeaters = document.querySelectorAll( '.frm-is-repeater' ); + if ( ! repeaters.length ) { + return; + } + + if ( exportOption === 'csv' ) { + repeaters.forEach( form => { + form.classList.remove( 'frm_hidden' ); + } ); + } else { + repeaters.forEach( form => { + form.classList.add( 'frm_hidden' ); + } ); + } + + searchContent.call( document.querySelector( '.frm-auto-search' ) ); + } + + function preventMultipleExport() { + const type = jQuery( 'select[name=format]' ), + selected = type.find( ':selected' ), + count = selected.data( 'count' ), + exportField = jQuery( 'input[name="frm_export_forms[]"]' ); + + if ( count === 'single' ) { + // Disable all other fields to prevent multiple selections. + if ( this.checked ) { + exportField.prop( 'disabled', true ); + this.removeAttribute( 'disabled' ); + } else { + exportField.prop( 'disabled', false ); + } + } else { + exportField.prop( 'disabled', false ); + } + } + + function initiateMultiselect() { + jQuery( '.frm_multiselect' ).hide().each( frmDom.bootstrap.multiselect.init ); + } + + /* Addons page */ + function installMultipleAddons( e ) { + e.preventDefault(); + toggleAddonState( this, 'frm_multiple_addons' ); + } + + function activateAddon( e ) { + e.preventDefault(); + toggleAddonState( this, 'frm_activate_addon' ); + } + + function installAddon( e ) { + e.preventDefault(); + toggleAddonState( this, 'frm_install_addon' ); + } + + function toggleAddonState( clicked, action ) { + let button, plugin, el, message; + + // Remove any leftover error messages, output an icon and get the plugin basename that needs to be activated. + jQuery( '.frm-addon-error' ).remove(); + button = jQuery( clicked ); + plugin = button.attr( 'rel' ); + el = button.parent(); + message = el.parent().find( '.addon-status-label' ); + + button.addClass( 'frm_loading_button' ); + + // Process the Ajax to perform the activation. + jQuery.ajax( { + url: ajaxurl, + type: 'POST', + async: true, + cache: false, + dataType: 'json', + data: { + action: action, + nonce: frmGlobal.nonce, + plugin: plugin + }, + success: function( response ) { + response = response?.data ?? response; + + let saveAndReload; + + if ( 'string' !== typeof response && 'string' === typeof response.message ) { + if ( 'undefined' !== typeof response.saveAndReload ) { + saveAndReload = response.saveAndReload; + } + response = response.message; + } + + const error = extractErrorFromAddOnResponse( response ); + if ( error ) { + addonError( error, el, button ); + return; + } + + afterAddonInstall( response, button, message, el, saveAndReload, action ); + + /** + * Trigger an action after successfully toggling the addon state. + * + * @param {Object} response + */ + wp.hooks.doAction( 'frm_update_addon_state', response ); + }, + error: function() { + button.removeClass( 'frm_loading_button' ); + } + } ); + } + + function installAddonWithCreds( e ) { + // Prevent the default action, let the user know we are attempting to install again and go with it. + e.preventDefault(); + + // Now let's make another Ajax request once the user has submitted their credentials. + const proceed = jQuery( this ); + const el = proceed.parent().parent(); + const plugin = proceed.attr( 'rel' ); + + proceed.addClass( 'frm_loading_button' ); + + jQuery.ajax( { + url: ajaxurl, + type: 'POST', + async: true, + cache: false, + dataType: 'json', + data: { + action: 'frm_install_addon', + nonce: frmAdminJs.nonce, + plugin: plugin, + hostname: el.find( '#hostname' ).val(), + username: el.find( '#username' ).val(), + password: el.find( '#password' ).val() + }, + success: function( response ) { + response = response?.data ?? response; + + const error = extractErrorFromAddOnResponse( response ); + if ( error ) { + addonError( error, el, proceed ); + return; + } + + afterAddonInstall( response, proceed, message, el ); + }, + error: function() { + proceed.removeClass( 'frm_loading_button' ); + } + } ); + } + + function afterAddonInstall( response, button, message, el, saveAndReload, action = 'frm_activate_addon' ) { + const addonStatuses = document.querySelectorAll( '.frm-addon-status' ); + addonStatuses.forEach( + addonStatus => { + addonStatus.textContent = response; + addonStatus.style.display = 'block'; + } + ); + + // The Ajax request was successful, so let's update the output. + button.css( { opacity: '0' } ); + + document.querySelectorAll( '.frm-oneclick' ).forEach( + oneClick => { + oneClick.style.display = 'none'; + } + ); + + jQuery( '#frm_upgrade_modal h2' ).hide(); + jQuery( '#frm_upgrade_modal .frm_lock_icon' ).addClass( 'frm_lock_open_icon' ); + jQuery( '#frm_upgrade_modal .frm_lock_icon use' ).attr( 'xlink:href', '#frm_lock_open_icon' ); + + // Proceed with CSS changes + const actionMap = { + frm_activate_addon: { class: 'frm-addon-active', message: frmAdminJs.active }, + frm_deactivate_addon: { class: 'frm-addon-installed', message: frmAdminJs.installed }, + frm_uninstall_addon: { class: 'frm-addon-not-installed', message: frmAdminJs.not_installed } + }; + actionMap.frm_install_addon = actionMap.frm_activate_addon; + + const messageElement = message[ 0 ]; + if ( messageElement ) { + messageElement.textContent = actionMap[ action ].message; + } + + const parentElement = el[ 0 ].parentElement; + parentElement.classList.remove( 'frm-addon-not-installed', 'frm-addon-installed', 'frm-addon-active' ); + parentElement.classList.add( actionMap[ action ].class ); + + const buttonElement = button[ 0 ]; + buttonElement.classList.remove( 'frm_loading_button' ); + + // Maybe refresh import and SMTP pages + const refreshPage = document.querySelectorAll( '.frm-admin-page-import, #frm-admin-smtp, #frm-welcome' ); + if ( refreshPage.length > 0 ) { + window.location.reload(); + return; + } + + if ( [ 'settings', 'form_builder' ].includes( saveAndReload ) ) { + addonStatuses.forEach( + addonStatus => { + const inModal = null !== addonStatus.closest( '#frm_upgrade_modal' ); + addonStatus.appendChild( getSaveAndReloadSettingsOptions( saveAndReload, inModal ) ); + } + ); + } + } + + function getSaveAndReloadSettingsOptions( saveAndReload, inModal ) { + const className = 'frm-save-and-reload-options'; + const children = [ saveAndReloadSettingsButton( saveAndReload ) ]; + if ( inModal ) { + children.push( closePopupButton() ); + } + return div( { className, children } ); + } + + function saveAndReloadSettingsButton( saveAndReload ) { + const button = document.createElement( 'button' ); + button.classList.add( 'frm-save-and-reload', 'button', 'button-primary', 'frm-button-primary' ); + button.textContent = __( 'Save and Reload', 'formidable' ); + button.addEventListener( 'click', () => { + if ( saveAndReload === 'form_builder' ) { + saveAndReloadFormBuilder(); + } else if ( saveAndReload === 'settings' ) { + saveAndReloadSettings(); + } + } ); + return button; + } + + function closePopupButton() { + const a = document.createElement( 'a' ); + a.setAttribute( 'href', '#' ); + a.classList.add( 'button', 'button-secondary', 'frm-button-secondary', 'dismiss' ); + a.textContent = __( 'Close', 'formidable' ); + return a; + } + + function extractErrorFromAddOnResponse( response ) { + if ( typeof response !== 'string' ) { + if ( typeof response.success !== 'undefined' && response.success ) { + return false; + } + + if ( response.form ) { + if ( jQuery( response.form ).is( '#message' ) ) { + return { + message: jQuery( response.form ).find( 'p' ).html() + }; + } + } + + return response; + } + + return false; + } + + function addonError( response, el, button ) { + if ( response.form ) { + jQuery( '.frm-inline-error' ).remove(); + button.closest( '.frm-card' ) + .html( response.form ) + .css( { padding: 5 } ) + .find( '#upgrade' ) + .attr( 'rel', button.attr( 'rel' ) ) + .on( 'click', installAddonWithCreds ); + } else { + el.append( '

                ' + response.message + '

                ' ); + button.removeClass( 'frm_loading_button' ); + jQuery( '.frm-addon-error' ).delay( 4000 ).fadeOut(); + } + } + + /* Templates */ + function showActiveCampaignForm() { + loadApiEmailForm(); + } + + function handleApiFormError( inputId, errorId, type, message ) { + const $error = jQuery( errorId ); + $error.removeClass( 'frm_hidden' ).attr( 'frm-error', type ); + + if ( typeof message !== 'undefined' ) { + $error.find( 'span[frm-error="' + type + '"]' ).text( message ); + } + + jQuery( inputId ).one( 'keyup', function() { + $error.addClass( 'frm_hidden' ); + } ); + } + + function handleEmailAddressError( type ) { + handleApiFormError( '#frm_leave_email', '#frm_leave_email_error', type ); + } + + function loadApiEmailForm() { + const formContainer = document.getElementById( 'frmapi-email-form' ); + jQuery.ajax( { + dataType: 'json', + url: formContainer.getAttribute( 'data-url' ), + success: function( json ) { + let form = json.renderedHtml; + form = form.replace( /]*(formidableforms.css|action=frmpro_css)[^>]*>/gi, '' ); + formContainer.innerHTML = form; + } + } ); + } + + function initAutocomplete( container ) { + frmDom.autocomplete.initSelectionAutocomplete( container ); + } + + function nextInstallStep( thisStep ) { + thisStep.classList.add( 'frm_grey' ); + thisStep.nextElementSibling.classList.remove( 'frm_grey' ); + } + + function installTemplateFieldset( e ) { + /*jshint validthis:true */ + const fieldset = this.parentNode.parentNode, + action = fieldset.elements.type.value, + button = this; + e.preventDefault(); + button.classList.add( 'frm_loading_button' ); + installNewForm( fieldset, action, button ); + } + + function installTemplate( e ) { + /*jshint validthis:true */ + const action = this.elements.type.value, + button = this.querySelector( 'button' ); + e.preventDefault(); + button.classList.add( 'frm_loading_button' ); + installNewForm( this, action, button ); + } + + function installNewForm( form, action, button ) { + const formData = formToData( form ); + const formName = formData.template_name; + const formDesc = formData.template_desc; + const link = form.elements.link.value; + + let data = { + action: action, + xml: link, + name: formName, + desc: formDesc, + form: JSON.stringify( formData ), + nonce: frmGlobal.nonce + }; + + const hookName = 'frm_before_install_new_form'; + const filterArgs = { formData }; + data = wp.hooks.applyFilters( hookName, data, filterArgs ); + + postAjax( data, function( response ) { + if ( typeof response.redirect !== 'undefined' ) { + const redirect = response.redirect; + if ( typeof form.elements.redirect === 'undefined' ) { + window.location = redirect; + } else { + const href = document.getElementById( 'frm-redirect-link' ); + if ( typeof link !== 'undefined' && href !== null ) { + // Show the next installation step. + href.setAttribute( 'href', redirect ); + href.classList.remove( 'frm_grey', 'disabled' ); + nextInstallStep( form.parentNode.parentNode ); + button.classList.add( 'frm_grey', 'disabled' ); + } + } + } else { + jQuery( '.spinner' ).css( 'visibility', 'hidden' ); + + // Show response.message + if ( 'string' === typeof response.message ) { + showInstallFormErrorModal( response.message ); + } + } + button.classList.remove( 'frm_loading_button' ); + } ); + } + + function showInstallFormErrorModal( message ) { + const modalContent = div( message ); + modalContent.style.padding = '20px 40px'; + const modal = frmDom.modal.maybeCreateModal( + 'frmInstallFormErrorModal', + { + title: __( 'Unable to install template', 'formidable' ), + content: modalContent + } + ); + modal.classList.add( 'frm_common_modal' ); + } + + function handleCaptchaTypeChange( e ) { + const thresholdContainer = document.getElementById( 'frm_captcha_threshold_container' ); + if ( thresholdContainer ) { + thresholdContainer.classList.toggle( 'frm_hidden', 'v3' !== e.target.value ); + } + } + + function trashTemplate( e ) { + /*jshint validthis:true */ + const id = this.getAttribute( 'data-id' ); + e.preventDefault(); + + data = { + action: 'frm_forms_trash', + id: id, + nonce: frmGlobal.nonce + }; + postAjax( data, function() { + const card = document.getElementById( 'frm-template-custom-' + id ); + fadeOut( card, function() { + card.parentNode.removeChild( card ); + } ); + } ); + } + + function searchContent() { + /*jshint validthis:true */ + let i, + regEx = false, + searchText = this.value.toLowerCase(), + toSearch = this.getAttribute( 'data-tosearch' ), + items = document.getElementsByClassName( toSearch ); + + if ( this.tagName === 'SELECT' ) { + searchText = selectedOptions( this ); + searchText = searchText.join( '|' ).toLowerCase(); + regEx = true; + } + + if ( toSearch === 'frm-action' && searchText !== '' ) { + const addons = document.getElementById( 'frm_email_addon_menu' ).classList; + addons.remove( 'frm-all-actions' ); + addons.add( 'frm-limited-actions' ); + } + + for ( i = 0; i < items.length; i++ ) { + const innerText = items[ i ].innerText.toLowerCase(); + + const itemCanBeShown = ! ( getExportOption() === 'xml' && items[ i ].classList.contains( 'frm-is-repeater' ) ); + if ( searchText === '' ) { + if ( itemCanBeShown && checkContextualShortcode( items[ i ] ) ) { + items[ i ].classList.remove( 'frm_hidden' ); + } + items[ i ].classList.remove( 'frm-search-result' ); + } else if ( ( regEx && new RegExp( searchText ).test( innerText ) ) || innerText.indexOf( searchText ) >= 0 || textMatchesPlural( innerText, searchText ) ) { + if ( itemCanBeShown && checkContextualShortcode( items[ i ] ) ) { + items[ i ].classList.remove( 'frm_hidden' ); + } + items[ i ].classList.add( 'frm-search-result' ); + } else { + items[ i ].classList.add( 'frm_hidden' ); + items[ i ].classList.remove( 'frm-search-result' ); + } + } + + // Updates the visibility of category headings based on search results. + updateCatHeadingVisibility(); + + jQuery( this ).trigger( 'frmAfterSearch' ); + } + + /** + * Allow a search for "signatures" to still match "signature" for example when searching fields. + * + * @since 6.15 + * + * @param {string} text The text in the element we are checking for a match. + * @param {string} searchText The text value that is being searched. + * @return {boolean} + */ + function textMatchesPlural( text, searchText ) { + if ( searchText === 's' ) { + // Don't match everything when just "s" is searched. + return false; + } + + if ( text[ text.length - 1 ] === 's' ) { + // Do not match something with double s if the text already ends in s. + return false; + } + + return ( text + 's' ).indexOf( searchText ) >= 0; + } + + /** + * Updates the visibility of category headings based on search results. + * If all associated fields are hidden (indicating no search matches), + * the heading is hidden. + * + * @since 6.4.1 + */ + function updateCatHeadingVisibility() { + const insertFieldsElement = document.querySelector( '#frm-insert-fields' ); + if ( ! insertFieldsElement ) { + return; + } + + const headingElements = insertFieldsElement.querySelectorAll( ':scope > .frm-with-line' ); + headingElements.forEach( heading => { + const fieldsListElement = heading.nextElementSibling; + if ( ! fieldsListElement ) { + return; + } + const listItemElements = fieldsListElement.querySelectorAll( ':scope > li.frmbutton' ); + const allHidden = Array.from( listItemElements ).every( li => li.classList.contains( 'frm_hidden' ) ); + + // Add or remove class based on `allHidden` condition + heading.classList.toggle( 'frm_hidden', allHidden ); + } ); + } + + function stopPropagation( e ) { + e.stopPropagation(); + } + + /* Helpers */ + + function selectedOptions( select ) { + let opt, + result = [], + options = select && select.options; + + for ( let i = 0, iLen = options.length; i < iLen; i++ ) { + opt = options[ i ]; + + if ( opt.selected ) { + result.push( opt.value ); + } + } + return result; + } + + function triggerEvent( element, event ) { + const evt = document.createEvent( 'HTMLEvents' ); + evt.initEvent( event, false, true ); + element.dispatchEvent( evt ); + } + + function postAjax( data, success ) { + let response; + + const xmlHttp = new XMLHttpRequest(); + const params = typeof data === 'string' ? data : Object.keys( data ).map( + function( k ) { + return encodeURIComponent( k ) + '=' + encodeURIComponent( data[ k ] ); + } + ).join( '&' ); + + xmlHttp.open( 'post', ajaxurl, true ); + xmlHttp.onreadystatechange = function() { + if ( xmlHttp.readyState > 3 && xmlHttp.status == 200 ) { + response = xmlHttp.responseText; + try { + response = JSON.parse( response ); + } catch ( e ) { + // The response may not be JSON, so just return it. + } + success( response ); + } + }; + xmlHttp.setRequestHeader( 'X-Requested-With', 'XMLHttpRequest' ); + xmlHttp.setRequestHeader( 'Content-type', 'application/x-www-form-urlencoded' ); + xmlHttp.send( params ); + return xmlHttp; + } + + function fadeOut( element, success ) { + element.classList.add( 'frm-fade' ); + setTimeout( success, 1000 ); + } + + function invisible( classes ) { + jQuery( classes ).css( 'visibility', 'hidden' ); + } + + function visible( classes ) { + jQuery( classes ).css( 'visibility', 'visible' ); + } + + function initModal( id, width ) { + const $info = jQuery( id ); + if ( ! $info.length ) { + return false; + } + + if ( typeof width === 'undefined' ) { + width = '550px'; + } + + const dialogArgs = { + dialogClass: 'frm-dialog', + modal: true, + autoOpen: false, + closeOnEscape: true, + width: width, + resizable: false, + draggable: false, + open: function() { + jQuery( '.ui-dialog-titlebar' ).addClass( 'frm_hidden' ).removeClass( 'ui-helper-clearfix' ); + jQuery( '#wpwrap' ).addClass( 'frm_overlay' ); + jQuery( '.frm-dialog' ).removeClass( 'ui-widget ui-widget-content ui-corner-all' ); + $info.removeClass( 'ui-dialog-content ui-widget-content' ); + bindClickForDialogClose( $info ); + }, + close: function() { + jQuery( '#wpwrap' ).removeClass( 'frm_overlay' ); + jQuery( '.spinner' ).css( 'visibility', 'hidden' ); + + this.removeAttribute( 'data-option-type' ); + const optionType = document.getElementById( 'bulk-option-type' ); + if ( optionType ) { + optionType.value = ''; + } + } + }; + + $info.dialog( dialogArgs ); + + return $info; + } + + function toggle( cname, id ) { + if ( id === '#' ) { + const cont = document.getElementById( cname ); + const hidden = cont.style.display; + if ( hidden === 'none' ) { + cont.style.display = 'block'; + } else { + cont.style.display = 'none'; + } + } else { + const vis = cname.is( ':visible' ); + if ( vis ) { + cname.hide(); + } else { + cname.show(); + } + } + } + + function removeWPUnload() { + window.onbeforeunload = null; + const w = jQuery( window ); + w.off( 'beforeunload.widgets' ); + w.off( 'beforeunload.edit-post' ); + } + + function addMultiselectLabelListener() { + const clickListener = e => { + if ( 'LABEL' !== e.target.nodeName ) { + return; + } + + const labelFor = e.target.getAttribute( 'for' ); + if ( ! labelFor ) { + return; + } + + const input = document.getElementById( labelFor ); + if ( ! input || ! input.nextElementSibling ) { + return; + } + + const buttonToggle = input.nextElementSibling.querySelector( 'button.dropdown-toggle.multiselect' ); + if ( ! buttonToggle ) { + return; + } + + const triggerMultiselectClick = () => buttonToggle.click(); + setTimeout( triggerMultiselectClick, 0 ); + }; + document.addEventListener( 'click', clickListener ); + } + + function maybeChangeEmbedFormMsg() { + const fieldId = jQuery( this ).closest( '.frm-single-settings' ).data( 'fid' ); + let fieldItem = document.getElementById( 'frm_field_id_' + fieldId ); + if ( null === fieldItem || 'form' !== fieldItem.dataset.type ) { + return; + } + + fieldItem = jQuery( fieldItem ); + + if ( this.options[ this.selectedIndex ].value ) { + fieldItem.find( '.frm-not-set' )[ 0 ].classList.add( 'frm_hidden' ); + const embedMsg = fieldItem.find( '.frm-embed-message' ); + embedMsg.html( embedMsg.data( 'embedmsg' ) + this.options[ this.selectedIndex ].text ); + fieldItem.find( '.frm-embed-field-placeholder' )[ 0 ].classList.remove( 'frm_hidden' ); + } else { + fieldItem.find( '.frm-not-set' )[ 0 ].classList.remove( 'frm_hidden' ); + fieldItem.find( '.frm-embed-field-placeholder' )[ 0 ].classList.add( 'frm_hidden' ); + } + } + + function toggleProductType() { + const settings = jQuery( this ).closest( '.frm-single-settings' ), + container = settings.find( '.frmjs_product_choices' ), + heading = settings.find( '.frm_prod_options_heading' ), + currentVal = this.options[ this.selectedIndex ].value; + + container.removeClass( 'frm_prod_type_single frm_prod_type_user_def' ); + heading.removeClass( 'frm_prod_user_def' ); + + if ( 'single' === currentVal ) { + container.addClass( 'frm_prod_type_single' ); + } else if ( 'user_def' === currentVal ) { + container.addClass( 'frm_prod_type_user_def' ); + heading.addClass( 'frm_prod_user_def' ); + } + } + + /** + * @param {Number | string} fieldId + * @return {boolean} True if the field is a product field. + */ + function isProductField( fieldId ) { + const field = document.getElementById( 'frm_field_id_' + fieldId ); + if ( field === null ) { + return false; + } + return 'product' === field.getAttribute( 'data-type' ); + } + + /** + * Serialize form data with vanilla JS. + */ + function formToData( form ) { + let subKey, i, + object = {}, + formData = form.elements; + + for ( i = 0; i < formData.length; i++ ) { + let input = formData[ i ], + key = input.name, + value = input.value, + names = key.match( /(.*)\[(.*)\]/ ); + + if ( ( input.type === 'radio' || input.type === 'checkbox' ) && ! input.checked ) { + continue; + } + + if ( names !== null ) { + key = names[ 1 ]; + subKey = names[ 2 ]; + if ( ! Reflect.has( object, key ) ) { + object[ key ] = {}; + } + object[ key ][ subKey ] = value; + continue; + } + + // Reflect.has in favor of: object.hasOwnProperty(key) + if ( ! Reflect.has( object, key ) ) { + object[ key ] = value; + continue; + } + if ( ! Array.isArray( object[ key ] ) ) { + object[ key ] = [ object[ key ] ]; + } + object[ key ].push( value ); + } + + return object; + } + + /** + * Show, hide, and sort subfields of Name field on form builder. + * + * @since 4.11 + */ + function handleNameFieldOnFormBuilder() { + /** + * Gets subfield element from cache. + * + * @param {string} fieldId Field ID. + * @param {string} key Cache key. + * @return {HTMLElement|undefined} Return the element from cache or undefined if not found. + */ + const getSubFieldElFromCache = ( fieldId, key ) => { + window.frmCachedSubFields = window.frmCachedSubFields || {}; + window.frmCachedSubFields[ fieldId ] = window.frmCachedSubFields[ fieldId ] || {}; + return window.frmCachedSubFields[ fieldId ][ key ]; + }; + + /** + * Sets subfield element to cache. + * + * @param {string} fieldId Field ID. + * @param {string} key Cache key. + * @param {HTMLElement} el Element. + */ + const setSubFieldElToCache = ( fieldId, key, el ) => { + window.frmCachedSubFields = window.frmCachedSubFields || {}; + window.frmCachedSubFields[ fieldId ] = window.frmCachedSubFields[ fieldId ] || {}; + window.frmCachedSubFields[ fieldId ][ key ] = el; + }; + + /** + * Gets column class from the number of columns. + * + * @param {Number} colCount Number of columns. + * @return {string} + */ + const getColClass = colCount => 'frm' + parseInt( 12 / colCount ); + + const colClasses = [ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12 ].map( num => 'frm' + num ); + + const allSubFieldNames = [ 'first', 'middle', 'last' ]; + + /** + * Handles name layout change. + * + * @param {Event} event Event object. + */ + const onChangeLayout = event => { + const value = event.target.value; + const subFieldNames = value.split( '_' ); + const fieldId = event.target.dataset.fieldId; + + /* + * Live update form on the form builder. + */ + const container = document.querySelector( '#field_' + fieldId + '_inner_container .frm_combo_inputs_container' ); + const newColClass = getColClass( subFieldNames.length ); + + // Set all sub field elements to cache and hide all of them first. + allSubFieldNames.forEach( name => { + const subFieldEl = container.querySelector( '[data-sub-field-name="' + name + '"]' ); + if ( subFieldEl ) { + subFieldEl.classList.add( 'frm_hidden' ); + subFieldEl.classList.remove( ...colClasses ); + setSubFieldElToCache( fieldId, name, subFieldEl ); + } + } ); + + subFieldNames.forEach( subFieldName => { + const subFieldEl = getSubFieldElFromCache( fieldId, subFieldName ); + if ( ! subFieldEl ) { + return; + } + + subFieldEl.classList.remove( 'frm_hidden' ); + subFieldEl.classList.add( newColClass ); + + container.append( subFieldEl ); + } ); + + /* + * Live update subfield options. + */ + // Hide all subfield options. + allSubFieldNames.forEach( name => { + const optionsEl = document.querySelector( '.frm_sub_field_options-' + name + '[data-field-id="' + fieldId + '"]' ); + if ( optionsEl ) { + optionsEl.classList.add( 'frm_hidden' ); + setSubFieldElToCache( fieldId, name + '_options', optionsEl ); + } + } ); + + subFieldNames.forEach( subFieldName => { + const optionsEl = getSubFieldElFromCache( fieldId, subFieldName + '_options' ); + if ( ! optionsEl ) { + return; + } + optionsEl.classList.remove( 'frm_hidden' ); + } ); + }; + + const dropdownSelector = '.frm_name_layout_dropdown'; + document.addEventListener( 'change', event => { + if ( event.target.matches( dropdownSelector ) ) { + onChangeLayout( event ); + } + }, false ); + } + + function debounce( func, wait = 100 ) { + return frmDom.util.debounce( func, wait ); + } + + function addSaveAndDragIconsToOption( fieldId, liObject ) { + let li, useTag, useTagHref; + let hasDragIcon = false; + let hasSaveIcon = false; + + if ( liObject.newOption ) { + const parser = new DOMParser(); + li = parser.parseFromString( liObject.newOption, 'text/html' ).body.childNodes[ 0 ]; + } else { + li = liObject; + } + + const liIcons = li.querySelectorAll( 'svg' ); + + liIcons.forEach( ( svg, key ) => { + useTag = svg.getElementsByTagNameNS( 'http://www.w3.org/2000/svg', 'use' )[ 0 ]; + if ( ! useTag ) { + return; + } + useTagHref = useTag.getAttributeNS( 'http://www.w3.org/1999/xlink', 'href' ) || useTag.getAttribute( 'href' ); + + if ( useTagHref === '#frm_drag_icon' ) { + hasDragIcon = true; + } + + if ( useTagHref === '#frm_save_icon' ) { + hasSaveIcon = true; + } + } ); + + if ( ! hasDragIcon ) { + li.prepend( icons.drag.cloneNode( true ) ); + } + + if ( li.querySelector( `[id^=field_key_${ fieldId }-]` ) && ! hasSaveIcon ) { + li.querySelector( `[id^=field_key_${ fieldId }-]` ).after( icons.save.cloneNode( true ) ); + } + + if ( liObject.newOption ) { + liObject.newOption = li; + } + } + + function maybeAddSaveAndDragIcons( fieldId ) { + fieldOptions = document.querySelectorAll( `[id^=frm_delete_field_${ fieldId }-]` ); + // return if there are no options. + if ( fieldOptions.length < 2 ) { + return; + } + + const options = [ ...fieldOptions ].slice( 1 ); + options.forEach( ( li, _key ) => { + if ( li.classList.contains( 'frm_other_option' ) ) { + return; + } + addSaveAndDragIconsToOption( fieldId, li ); + } ); + } + + /** + * Enforce the maximum number of entries list columns dynamically. + * + * @since x.x + * + * @return {void} + */ + function maybeInitEntriesListPage() { + if ( ! document.body.classList.contains( 'formidable_page_formidable-entries' ) ) { + return; + } + + const screenOptionsWrapper = document.getElementById( 'screen-options-wrap' ); + if ( ! screenOptionsWrapper ) { + return; + } + + const maxSelectionsNote = div( { + className: 'frm_warning_style', + text: __( 'Only 10 columns can be selected at a time.', 'formidable' ), + } ); + maxSelectionsNote.style.margin = 0; + + const legend = screenOptionsWrapper.querySelector( 'legend' ); + legend.parentNode.insertBefore( maxSelectionsNote, legend.nextElementSibling ); + + const checkboxes = Array.from( screenOptionsWrapper.querySelectorAll( 'input[type="checkbox"]' ) ); + const maximumColumns = 10; + const getSelectedCount = () => { + return checkboxes.reduce( ( count, checkbox ) => { + return checkbox.checked ? count + 1 : count; + }, 0 ); + }; + const disableCheckboxesIfAtMax = () => { + if ( getSelectedCount() >= maximumColumns ) { + maxSelectionsNote.classList.remove( 'frm_hidden' ); + checkboxes.forEach( checkbox => { + if ( ! checkbox.checked ) { + checkbox.parentNode.classList.add( 'frm_noallow' ); + checkbox.disabled = true; + } + } ); + } else { + maxSelectionsNote.classList.add( 'frm_hidden' ); + } + }; + const addCheckboxListeners = () => { + checkboxes.forEach( + checkbox => { + checkbox.addEventListener( + 'change', + event => { + if ( event.target.checked ) { + disableCheckboxesIfAtMax(); + } else { + maxSelectionsNote.classList.add( 'frm_hidden' ); + + // Enable all checkboxes when a checkbox is unchecked. + checkboxes.forEach( + checkbox => { + checkbox.parentNode.classList.remove( 'frm_noallow' ); + checkbox.disabled = false; + } + ); + } + } + ); + } + ); + }; + + disableCheckboxesIfAtMax(); + addCheckboxListeners(); + } + + function initOnSubmitAction() { + const onChangeType = event => { + if ( ! event.target.checked ) { + return; + } + + const actionEl = event.target.closest( '.frm_form_action_settings' ); + actionEl.querySelectorAll( '.frm_on_submit_dependent_setting:not(.frm_hidden)' ).forEach( el => { + el.classList.add( 'frm_hidden' ); + } ); + + const activeEls = actionEl.querySelectorAll( '.frm_on_submit_dependent_setting[data-show-if-' + event.target.value + ']' ); + activeEls.forEach( activeEl => { + activeEl.classList.remove( 'frm_hidden' ); + } ); + + actionEl.setAttribute( 'data-on-submit-type', event.target.value ); + }; + + frmDom.util.documentOn( 'change', '.frm_on_submit_type input[type="radio"]', onChangeType ); + } + + /** + * Listen for click events for an API-loaded email collection form. + * + * This is used for the Active Campaign sign-up form in the inbox page (when there are no messages). + */ + function initAddMyEmailAddress() { + jQuery( document ).on( + 'click', + '#frm-add-my-email-address', + event => { + event.preventDefault(); + addMyEmailAddress(); + } + ); + + const emptyInbox = document.getElementById( 'frm_empty_inbox' ); + const leaveEmailInput = document.getElementById( 'frm_leave_email' ); + + if ( emptyInbox && leaveEmailInput ) { + const leaveEmailModal = document.getElementById( 'frm-leave-email-modal' ); + leaveEmailModal.classList.remove( 'frm_hidden' ); + leaveEmailModal.querySelector( '.frm_modal_footer' ).classList.add( 'frm_hidden' ); + + leaveEmailInput.addEventListener( + 'keyup', + event => { + if ( 'Enter' === event.key ) { + const button = document.getElementById( 'frm-add-my-email-address' ); + if ( button ) { + button.click(); + } + } + } + ); + } + } + + function addMyEmailAddress() { + const email = document.getElementById( 'frm_leave_email' ).value.trim(); + if ( '' === email ) { + handleEmailAddressError( 'empty' ); + return; + } + + const regex = /^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/i; + if ( regex.test( email ) === false ) { + handleEmailAddressError( 'invalid' ); + return; + } + + const $hiddenForm = jQuery( '#frmapi-email-form' ).find( 'form' ); + const $hiddenEmailField = $hiddenForm.find( '[type="email"]' ).not( '.frm_verify' ); + if ( ! $hiddenEmailField.length ) { + return; + } + + const emptyInbox = document.getElementById( 'frm_empty_inbox' ); + if ( emptyInbox ) { + document.getElementById( 'frm-add-my-email-address' ).remove(); + + const emailWrapper = document.getElementById( 'frm_leave_email_wrapper' ); + if ( emailWrapper ) { + emailWrapper.classList.add( 'frm_hidden' ); + const spinner = span( { className: 'frm-wait frm_spinner' } ); + spinner.style.visibility = 'visible'; + spinner.style.float = 'none'; + spinner.style.width = 'unset'; + emailWrapper.parentElement.insertBefore( + spinner, + emailWrapper.nextElementSibling + ); + } + } + + $hiddenEmailField.val( email ); + jQuery.ajax( { + type: 'POST', + url: $hiddenForm.attr( 'action' ), + data: $hiddenForm.serialize() + '&action=frm_forms_preview' + } ).done( function( data ) { + const message = jQuery( data ).find( '.frm_message' ).text().trim(); + if ( message.indexOf( 'Thanks!' ) === -1 ) { + handleEmailAddressError( 'invalid' ); + return; + } + + const apiForm = document.getElementById( 'frmapi-email-form' ); + const spinner = apiForm.parentElement.querySelector( '.frm_spinner' ); + if ( spinner ) { + spinner.remove(); + } + + const showSuccessMessage = wp.hooks.applyFilters( 'frm_thank_you_on_signup', true ); + if ( showSuccessMessage ) { + // Handle successful form submission. + // handle the Active Campaign form on the inbox page. + document.getElementById( 'frm_leave_email_wrapper' ).replaceWith( + span( __( 'Thank you for signing up!', 'formidable' ) ) + ); + } + } ); + } + + /** + * Adds footer links to the admin body content. + * + * @return {void} + */ + function addAdminFooterLinks() { + const footerLinks = document.querySelector( '.frm-admin-footer-links' ); + const container = document.querySelector( '.frm_page_container' ) ?? document.getElementById( 'wpbody-content' ); + + if ( ! footerLinks || ! container ) { + return; + } + + container.appendChild( footerLinks ); + footerLinks.classList.remove( 'frm_hidden' ); + } + + /** + * Apply zebra striping to a table while ignoring empty rows. + * + * @param {string} tableSelector The CSS selector for the table. + * @param {string} emptyRowClass The class name used to identify empty rows. + */ + function applyZebraStriping( tableSelector, emptyRowClass ) { + // Get all non-empty table rows within the specified table + const rows = document.querySelectorAll( `${ tableSelector } tr${ emptyRowClass ? `:not(.${ emptyRowClass })` : '' }` ); + if ( rows.length < 1 ) { + return; + } + + let isOdd = true; + rows.forEach( row => { + // Clean old "frm-odd" or "frm-even" classes and add the appropriate new class + row.classList.remove( 'frm-odd', 'frm-even' ); + row.classList.add( isOdd ? 'frm-odd' : 'frm-even' ); + + isOdd = ! isOdd; + } ); + + const tables = document.querySelectorAll( tableSelector ); + tables.forEach( table => table.classList.add( 'frm-zebra-striping' ) ); + } + + function maybeHideShortcodes( e ) { + if ( ! builderPage ) { + e.stopPropagation(); + } + + if ( e.target.classList.contains( 'frm-show-box' ) || ( e.target.parentElement && e.target.parentElement.classList.contains( 'frm-show-box' ) ) ) { + return; + } + + const sidebar = document.getElementById( 'frm_adv_info' ); + if ( ! sidebar ) { + return; + } + + if ( sidebar.dataset.fills === e.target.id && typeof e.target.id !== 'undefined' ) { + return; + } + + const isChild = e.target.closest( '#frm_adv_info' ); + + if ( ! isChild && sidebar.style.display !== 'none' ) { + hideShortcodes( sidebar ); + } + } + + /** + * Initializes and manages the visibility of dependent elements based on the selected options in dropdowns with the 'frm_select_with_dependency' class. + * It sets up initial visibility at page load and updates it on each dropdown change. + * + * @since 6.9 + * + * @return {void} + */ + function initSelectDependencies() { + const selects = document.querySelectorAll( 'select.frm_select_with_dependency' ); + + /** + * Toggles the visibility of dependent elements associated with a select element based on its current selection. + * + * @since 6.9 + * + * @param {HTMLElement} select The select element whose dependencies need to be managed. + * @return {void} + */ + function toggleDependencyVisibility( select ) { + const selectedOption = select.options[ select.selectedIndex ]; + select.querySelectorAll( 'option[data-dependency]:not([data-dependency-skip])' ).forEach( option => { + const dependencyElement = document.querySelector( option.dataset.dependency ); + dependencyElement?.classList.toggle( 'frm_hidden', selectedOption !== option ); + } ); + } + + // Initial setup: Show dependencies based on the current selection in each dropdown + selects.forEach( toggleDependencyVisibility ); + + // Update dependencies visibility on dropdown change + frmDom.util.documentOn( 'change', 'select.frm_select_with_dependency', event => toggleDependencyVisibility( event.target ) ); + } + + /** + * Moves the focus to the next single option input field in the list and positions the cursor at the end of the text. + * + * @param {HTMLElement} currentInput The currently focused input element. + */ + function focusNextSingleOptionInput( currentInput ) { + const optionsList = currentInput.closest( '.frm_single_option' ).parentElement; + const inputs = optionsList.querySelectorAll( '.frm_single_option input[name^="field_options[" ], .frm_single_option input[name^="rows_"]' ); + const inputsArray = Array.from( inputs ); + + // Find the index of the currently focused input + const currentIndex = inputsArray.indexOf( currentInput ); + + if ( currentIndex < 0 ) { + return; + } + + // Find the next visible input field + const nextInput = inputsArray.slice( currentIndex + 1 ).find( input => input.offsetParent !== null ); + + if ( nextInput ) { + nextInput.focus(); + + // Move the cursor to the end of the text in the next input field + const textLength = nextInput.value.length; + nextInput.setSelectionRange( textLength, textLength ); + } + } + + return { + init: function() { + initAddMyEmailAddress(); + addAdminFooterLinks(); + + s = {}; + + // Bootstrap dropdown button + jQuery( '.wp-admin' ).on( 'click', function( e ) { + const t = jQuery( e.target ); + const $openDrop = jQuery( '.dropdown.open' ); + if ( $openDrop.length && ! t.hasClass( 'dropdown' ) && ! t.closest( '.dropdown' ).length ) { + $openDrop.removeClass( 'open' ); + } + } ); + jQuery( '#frm_bs_dropdown:not(.open) a' ).on( 'click', focusSearchBox ); + + if ( typeof thisFormId === 'undefined' ) { + thisFormId = jQuery( document.getElementById( 'form_id' ) ).val(); + } + + // Add event listener for dismissible warning messages. + document.querySelectorAll( '.frm-warning-dismiss' ).forEach( dismissIcon => { + onClickPreventDefault( dismissIcon, dismissWarningMessage ); + } ); + + frmAdminBuild.inboxBannerInit(); + + if ( $newFields.length > 0 ) { + // only load this on the form builder page + frmAdminBuild.buildInit(); + } else if ( document.getElementById( 'frm_notification_settings' ) !== null ) { + // only load on form settings page + frmAdminBuild.settingsInit(); + } else if ( document.getElementById( 'frm_styling_form' ) !== null ) { + // load styling settings js + frmAdminBuild.styleInit(); + } else if ( document.getElementById( 'form_global_settings' ) !== null ) { + // global settings page + frmAdminBuild.globalSettingsInit(); + } else if ( document.getElementById( 'frm_export_xml' ) !== null ) { + // import/export page + frmAdminBuild.exportInit(); + } else if ( null !== document.querySelector( '.frm-inbox-wrapper' ) ) { + // Dashboard page inbox. + frmAdminBuild.inboxInit(); + } else if ( document.getElementById( 'frm-welcome' ) !== null ) { + // Solution install page + frmAdminBuild.solutionInit(); + } else { + maybeInitEntriesListPage(); + + initAutocomplete(); + + jQuery( '[data-frmprint]' ).on( 'click', function() { + window.print(); + return false; + } ); + } + + jQuery( document ).on( 'change', 'select[data-toggleclass], input[data-toggleclass]', toggleFormOpts ); + initSelectDependencies(); + + const $advInfo = jQuery( document.getElementById( 'frm_adv_info' ) ); + if ( $advInfo.length > 0 || jQuery( '.frm_field_list' ).length > 0 ) { + // only load on the form, form settings, and view settings pages + frmAdminBuild.panelInit(); + } + + loadTooltips(); + initUpgradeModal(); + + // used on build, form settings, and view settings + const $shortCodeDiv = jQuery( document.getElementById( 'frm_shortcodediv' ) ); + if ( $shortCodeDiv.length > 0 ) { + jQuery( 'a.edit-frm_shortcode' ).on( 'click', function() { + if ( $shortCodeDiv.is( ':hidden' ) ) { + $shortCodeDiv.slideDown( 'fast' ); + this.style.display = 'none'; + } + return false; + } ); + + jQuery( '.cancel-frm_shortcode', '#frm_shortcodediv' ).on( 'click', function() { + $shortCodeDiv.slideUp( 'fast' ); + $shortCodeDiv.siblings( 'a.edit-frm_shortcode' ).show(); + return false; + } ); + } + + // tabs + jQuery( document ).on( 'click', '#frm-nav-tabs a', clickNewTab ); + jQuery( '.post-type-frm_display .frm-nav-tabs a, .frm-category-tabs a' ).on( 'click', function() { + const showUpgradeTab = this.classList.contains( 'frm_show_upgrade_tab' ); + if ( this.classList.contains( 'frm_noallow' ) && ! showUpgradeTab ) { + return; + } + + if ( showUpgradeTab ) { + populateUpgradeTab( this ); + } + + clickTab( this ); + return false; + } ); + clickTab( jQuery( '.starttab a' ), 'auto' ); + + // submit the search form with dropdown + jQuery( document ).on( 'click', '#frm-fid-search-menu a', function() { + const val = this.id.replace( 'fid-', '' ); + jQuery( 'select[name="fid"]' ).val( val ); + triggerSubmit( document.getElementById( 'posts-filter' ) ); + return false; + } ); + + jQuery( '.frm_select_box' ).on( 'click focus', function() { + this.select(); + } ); + + jQuery( document ).on( 'input search change', '.frm-auto-search:not(#frm-form-templates-page #template-search-input)', searchContent ); + jQuery( document ).on( 'focusin click', '.frm-auto-search', stopPropagation ); + const autoSearch = jQuery( '.frm-auto-search' ); + if ( autoSearch.val() !== '' ) { + autoSearch.trigger( 'keyup' ); + } + + // Initialize Formidable Connection. + FrmFormsConnect.init(); + + jQuery( document ).on( 'click', '.frm-install-addon', installAddon ); + jQuery( document ).on( 'click', '.frm-activate-addon', activateAddon ); + jQuery( document ).on( 'click', '.frm-solution-multiple', installMultipleAddons ); + + // prevent annoying confirmation message from WordPress + jQuery( 'button, input[type=submit]' ).on( 'click', removeWPUnload ); + + addMultiselectLabelListener(); + + frmAdminBuild.hooks.addFilter( + 'frm_before_embed_modal', + ( ids, { element, type } ) => { + if ( 'form' !== type ) { + return ids; + } + + let formId, formKey; + const row = element.closest( 'tr' ); + + if ( row ) { + // Embed icon on form index. + formId = parseInt( row.querySelector( '.column-id' ).textContent ); + formKey = row.querySelector( '.column-form_key' ).textContent; + } else { + // Embed button in form builder / form settings. + formId = document.getElementById( 'form_id' ).value; + + const formKeyInput = document.getElementById( 'frm_form_key' ); + if ( formKeyInput ) { + formKey = formKeyInput.value; + } else { + const previewDrop = document.getElementById( 'frm-previewDrop' ); + if ( previewDrop ) { + formKey = previewDrop.nextElementSibling.querySelector( '.dropdown-item a' ).getAttribute( 'href' ).split( 'form=' )[ 1 ]; + } + } + } + + return [ formId, formKey ]; + } + ); + + document.querySelectorAll( '#frm-show-fields > li, .frm_grid_container li' ).forEach( ( el, _key ) => { + el.addEventListener( 'click', function() { + const fieldId = this.querySelector( 'li' )?.dataset.fid || this.dataset.fid; + maybeAddSaveAndDragIcons( fieldId ); + } ); + } ); + + const smallScreenProceedButton = document.getElementById( 'frm_small_screen_proceed_button' ); + if ( smallScreenProceedButton ) { + onClickPreventDefault( smallScreenProceedButton, () => { + document.getElementById( 'frm_small_device_message_container' )?.remove(); + doJsonPost( 'small_screen_proceed', new FormData() ); + } ); + } + + const saleBanner = document.getElementById( 'frm_sale_banner' ); + const saleDismiss = saleBanner?.querySelector( '.dismiss' ); + if ( saleBanner ) { + onClickPreventDefault( saleBanner, event => { + const target = event.target; + if ( target.closest( '.dismiss' ) ) { + return; + } + window.location.href = saleBanner.getAttribute( 'data-url' ); + } ); + + if ( saleDismiss ) { + onClickPreventDefault( saleDismiss, () => { + saleBanner.remove(); + + const formData = new FormData(); + doJsonPost( 'sale_banner_dismiss', formData ); + } ); + } + } + }, + + buildInit: function() { + jQuery( '#frm_builder_page' ).on( 'mouseup', '*:not(.frm-show-box)', maybeHideShortcodes ); + + let loadFieldId, $builderForm, builderArea; + + debouncedSyncAfterDragAndDrop = debounce( syncAfterDragAndDrop, 10 ); + postBodyContent = document.getElementById( 'post-body-content' ); + $postBodyContent = jQuery( postBodyContent ); + + if ( jQuery( '.frm_field_loading' ).length ) { + loadFieldId = jQuery( '.frm_field_loading' ).first().attr( 'id' ); + loadFields( loadFieldId ); + } + + setupSortable( 'ul.frm_sorting' ); + + document.querySelectorAll( '.field_type_list > li:not(.frm_show_upgrade)' ).forEach( makeDraggable ); + + jQuery( 'ul.field_type_list, .field_type_list li, ul.frm_code_list, .frm_code_list li, .frm_code_list li a, #frm_adv_info #category-tabs li, #frm_adv_info #category-tabs li a' ).disableSelection(); + + jQuery( '.frm_submit_ajax' ).on( 'click', submitBuild ); + jQuery( '.frm_submit_no_ajax' ).on( 'click', submitNoAjax ); + + addFormNameModalEvents(); + + jQuery( 'a.edit-form-status' ).on( 'click', slideDown ); + jQuery( '.cancel-form-status' ).on( 'click', slideUp ); + jQuery( '.save-form-status' ).on( 'click', function() { + const newStatus = jQuery( document.getElementById( 'form_change_status' ) ).val(); + jQuery( 'input[name="new_status"]' ).val( newStatus ); + jQuery( document.getElementById( 'form-status-display' ) ).html( newStatus ); + jQuery( '.cancel-form-status' ).trigger( 'click' ); + return false; + } ); + + jQuery( '.frm_form_builder form' ).first().on( 'submit', function() { + jQuery( '.inplace_field' ).trigger( 'blur' ); + } ); + + initiateMultiselect(); + renumberPageBreaks(); + + $builderForm = jQuery( builderForm ); + builderArea = document.getElementById( 'frm_form_editor_container' ); + $builderForm.on( 'click', '.frm_add_logic_row', addFieldLogicRow ); + $builderForm.on( 'click', '.frm_add_watch_lookup_row', addWatchLookupRow ); + $builderForm.on( 'change', '.frm_get_values_form', updateGetValueFieldSelection ); + $builderForm.on( 'change', '.frm_logic_field_opts', getFieldValues ); + $builderForm.on( 'frm-multiselect-changed', 'select[name^="field_options[admin_only_"]', adjustVisibilityValuesForEveryoneValues ); + + jQuery( document.getElementById( 'frm-insert-fields' ) ).on( 'click', '.frm_add_field', addFieldClick ); + $newFields.on( 'click', '.frm_clone_field', duplicateField ); + $builderForm.on( 'blur', 'input[id^="frm_calc"]', checkCalculationCreatedByUser ); + $builderForm.on( 'change', 'input.frm_format_opt, input.frm_max_length_opt', toggleInvalidMsg ); + $builderForm.on( 'change click', '[data-changeme]', liveChanges ); + $builderForm.on( 'click', 'input.frm_req_field', markRequired ); + $builderForm.on( 'click', '.frm_mark_unique', markUnique ); + + $builderForm.on( 'change', '.frm_repeat_format', toggleRepeatButtons ); + $builderForm.on( 'change', '.frm_repeat_limit', checkRepeatLimit ); + $builderForm.on( 'change', '.frm_js_checkbox_limit', checkCheckboxSelectionsLimit ); + $builderForm.on( 'input', 'input[name^="field_options[add_label_"]', function() { + updateRepeatText( this, 'add' ); + } ); + $builderForm.on( 'input', 'input[name^="field_options[remove_label_"]', function() { + updateRepeatText( this, 'remove' ); + } ); + $builderForm.on( 'change', 'select[name^="field_options[data_type_"]', maybeClearWatchFields ); + jQuery( builderArea ).on( 'click', '.frm-collapse-page', maybeCollapsePage ); + jQuery( builderArea ).on( 'click', '.frm-collapse-section', maybeCollapseSection ); + $builderForm.on( 'click', '.frm-single-settings h3', maybeCollapseSettings ); + $builderForm.on( 'keydown', '.frm-single-settings h3', function( event ) { + // If so, only proceed if the key pressed was 'Enter' or 'Space' + if ( event.key === 'Enter' || event.key === ' ' ) { + event.preventDefault(); + maybeCollapseSettings.call( this, event ); + } + } ); + + jQuery( builderArea ).on( 'show.bs.dropdown hide.bs.dropdown', changeSectionStyle ); + + $builderForm.on( 'click', '.frm_toggle_sep_values', toggleSepValues ); + $builderForm.on( 'click', '.frm_toggle_image_options', toggleImageOptions ); + $builderForm.on( 'click', '.frm_remove_image_option', removeImageFromOption ); + $builderForm.on( 'click', '.frm_choose_image_box', addImageToOption ); + $builderForm.on( 'change', '.frm_hide_image_text', refreshOptionDisplay ); + $builderForm.on( 'change', '.frm_field_options_image_size', setImageSize ); + $builderForm.on( 'click', '.frm_multiselect_opt', toggleMultiselect ); + $newFields.on( 'mousedown', 'input, textarea, select', stopFieldFocus ); + $newFields.on( 'click', 'input[type=radio], input[type=checkbox]', stopFieldFocus ); + $newFields.on( 'click', '.frm_delete_field', clickDeleteField ); + $newFields.on( 'click', '.frm_select_field', clickSelectField ); + jQuery( document ).on( 'click', '.frm_delete_field_group', clickDeleteFieldGroup ); + jQuery( document ).on( 'click', '.frm_clone_field_group', duplicateFieldGroup ); + jQuery( document ).on( 'click', '#frm_field_group_controls > span:first-child', clickFieldGroupLayout ); + jQuery( document ).on( 'click', '.frm-row-layout-option', handleFieldGroupLayoutOptionClick ); + jQuery( document ).on( 'click', '.frm-merge-fields-into-row .frm-row-layout-option', handleFieldGroupLayoutOptionInsideMergeClick ); + jQuery( document ).on( 'click', '.frm-custom-field-group-layout', customFieldGroupLayoutClick ); + jQuery( document ).on( 'click', '.frm-merge-fields-into-row .frm-custom-field-group-layout', customFieldGroupLayoutInsideMergeClick ); + jQuery( document ).on( 'click', '.frm-break-field-group', breakFieldGroupClick ); + $newFields.on( 'click', '#frm_field_group_popup .frm_grid_container input', focusFieldGroupInputOnClick ); + jQuery( document ).on( 'click', '.frm-cancel-custom-field-group-layout', cancelCustomFieldGroupClick ); + jQuery( document ).on( 'click', '.frm-save-custom-field-group-layout', saveCustomFieldGroupClick ); + $newFields.on( 'click', 'ul.frm_sorting', fieldGroupClick ); + jQuery( document ).on( 'click', '.frm-merge-fields-into-row', mergeFieldsIntoRowClick ); + jQuery( document ).on( 'click', '.frm-delete-field-groups', deleteFieldGroupsClick ); + $newFields.on( 'click', '.frm-field-action-icons [data-toggle="dropdown"]', function() { + this.closest( 'li.form-field' ).classList.add( 'frm-field-settings-open' ); + jQuery( document ).on( 'click', '#frm_builder_page', handleClickOutsideOfFieldSettings ); + } ); + $newFields.on( 'mousemove', 'ul.frm_sorting', checkForMultiselectKeysOnMouseMove ); + $newFields.on( 'show.bs.dropdown', '.frm-field-action-icons', onFieldActionDropdownShow ); + jQuery( document ).on( 'show.bs.dropdown', '#frm_field_group_controls', onFieldGroupActionDropdownShow ); + $builderForm.on( 'click', '.frm_single_option a[data-removeid]', deleteFieldOption ); + $builderForm.on( 'mousedown', '.frm_single_option input[type=radio]', maybeUncheckRadio ); + $builderForm.on( 'focusin', '.frm_single_option input[type=text]', maybeClearOptText ); + $builderForm.on( 'click', '.frm_add_opt', addFieldOption ); + $builderForm.on( 'change', '.frm_single_option input', resetOptOnChange ); + $builderForm.on( 'change', '.frm_image_id', resetOptOnChange ); + $builderForm.on( 'change', '.frm_toggle_mult_sel', toggleMultSel ); + $builderForm.on( 'focusin', '.frm_classes', showBuilderModal ); + + $newFields.on( 'click', '.frm_primary_label', clickLabel ); + $newFields.on( 'click', '.frm_description', clickDescription ); + $newFields.on( 'click', 'li.ui-state-default:not(.frm_noallow)', clickVis ); + $newFields.on( 'dblclick', 'li.ui-state-default', openAdvanced ); + $builderForm.on( 'change', '.frm_tax_form_select', toggleFormTax ); + $builderForm.on( 'change', 'select.conf_field', addConf ); + + $builderForm.on( 'change', '.frm_get_field_selection', getFieldSelection ); + + $builderForm.on( 'click', '.frm-show-inline-modal', maybeShowInlineModal ); + + $builderForm.on( 'click', '.frm-inline-modal .dismiss', dismissInlineModal ); + jQuery( document ).on( 'change', '[data-frmchange]', changeInputtedValue ); + + $builderForm.on( 'change', '.frm_include_extras_field', rePopCalcFieldsForSummary ); + $builderForm.on( 'change', 'select[name^="field_options[form_select_"]', maybeChangeEmbedFormMsg ); + + jQuery( document ).on( 'submit', '#frm_js_build_form', buildSubmittedNoAjax ); + jQuery( document ).on( 'change', '#frm_builder_page input:not(.frm-search-input):not(.frm-custom-grid-size-input), #frm_builder_page select, #frm_builder_page textarea', fieldUpdated ); + + popAllProductFields(); + + jQuery( document ).on( 'change', '.frmjs_prod_data_type_opt', toggleProductType ); + + jQuery( document ).on( 'focus', '.frm-single-settings ul input[type="text"][name^="field_options[options_"]', onOptionTextFocus ); + jQuery( document ).on( 'blur', '.frm-single-settings ul input[type="text"][name^="field_options[options_"]', onOptionTextBlur ); + + frmDom.util.documentOn( 'click', '.frm-show-field-settings', clickVis ); + frmDom.util.documentOn( 'change', 'select.frm_format_dropdown, select.frm_phone_type_dropdown', maybeUpdateFormatInput ); + + // Navigate to the next input field on pressing Enter in a single option field + $builderForm.on( 'keydown', '.frm_single_option input[name^="field_options["], .frm_single_option input[name^="rows_"]', event => { + if ( 'Enter' === event.key ) { + focusNextSingleOptionInput( event.currentTarget ); + } + } ); + + initBulkOptionsOverlay(); + hideEmptyEle(); + maybeHideQuantityProductFieldOption(); + handleNameFieldOnFormBuilder(); + toggleSectionHolder(); + handleShowPasswordLiveUpdate(); + document.addEventListener( 'scroll', updateShortcodesPopupPosition, true ); + document.addEventListener( 'change', handleBuilderChangeEvent ); + document.querySelector( '.frm_form_builder' ).addEventListener( 'mousedown', event => { + if ( event.shiftKey ) { + event.preventDefault(); + } + } ); + }, + + settingsInit: function() { + const $formActions = jQuery( document.getElementById( 'frm_notification_settings' ) ); + + let formSettings, $loggedIn, $cookieExp, $editable; + + // BCC, CC, and Reply To button functionality + $formActions.on( 'click', '.frm_email_buttons', showEmailRow ); + $formActions.on( 'click', '.frm_remove_field', hideEmailRow ); + $formActions.on( 'change', '.frm_to_row, .frm_from_row', showEmailWarning ); + $formActions.on( 'change', '.frm_tax_selector', changePosttaxRow ); + $formActions.on( 'change', 'select.frm_single_post_field', checkDupPost ); + $formActions.on( 'change', 'select.frm_toggle_post_content', togglePostContent ); + $formActions.on( 'change', 'select.frm_dyncontent_opt', fillDyncontent ); + $formActions.on( 'change', '.frm_post_type', switchPostType ); + $formActions.on( 'click', '.frm_add_postmeta_row', addPostmetaRow ); + $formActions.on( 'click', '.frm_add_posttax_row', addPosttaxRow ); + $formActions.on( 'click', '.frm_toggle_cf_opts', toggleCfOpts ); + $formActions.on( 'click', '.frm_duplicate_form_action', copyFormAction ); + jQuery( '.frm_actions_list' ).on( 'click', '.frm_active_action', addFormAction ); + jQuery( '#frm-show-groups, #frm-hide-groups' ).on( 'click', toggleActionGroups ); + initiateMultiselect(); + + //set actions icons to inactive + jQuery( 'ul.frm_actions_list li' ).each( function() { + checkActiveAction( jQuery( this ).children( 'a' ).data( 'actiontype' ) ); + + // If the icon is a background image, don't add BG color. + const icon = jQuery( this ).find( 'i' ); + if ( icon.css( 'background-image' ) !== 'none' ) { + icon.addClass( 'frm-inverse' ); + } + } ); + + jQuery( '.frm_submit_settings_btn' ).on( 'click', submitSettings ); + + addFormNameModalEvents(); + + formSettings = jQuery( '.frm_form_settings' ); + formSettings.on( 'click', '.frm_add_form_logic', addFormLogicRow ); + formSettings.on( 'click', '.frm_already_used', actionLimitMessage ); + + document.addEventListener( + 'click', + function handleImageUploadClickEvents( event ) { + const { target } = event; + + if ( ! target.closest( '.frm_image_preview_wrapper' ) ) { + return; + } + + if ( target.closest( '.frm_choose_image_box' ) ) { + addImageToOption.bind( target )( event ); + return; + } + + if ( target.closest( '.frm_remove_image_option' ) ) { + removeImageFromOption.bind( target )( event ); + } + } + ); + + // Close shortcode modal on click. + formSettings.on( 'mouseup', '*:not(.frm-show-box)', maybeHideShortcodes ); + + //Warning when user selects "Do not store entries ..." + jQuery( document.getElementById( 'no_save' ) ).on( 'change', function() { + if ( this.checked ) { + if ( confirm( frmAdminJs.no_save_warning ) !== true ) { + // Uncheck box if user hits "Cancel" + jQuery( this ).attr( 'checked', false ); + } + } + } ); + + jQuery( 'select[name="options[edit_action]"]' ).on( 'change', showSuccessOpt ); + + $loggedIn = document.getElementById( 'logged_in' ); + jQuery( $loggedIn ).on( 'change', function() { + if ( this.checked ) { + visible( '.hide_logged_in' ); + } else { + invisible( '.hide_logged_in' ); + } + } ); + + $cookieExp = jQuery( document.getElementById( 'frm_cookie_expiration' ) ); + jQuery( document.getElementById( 'frm_single_entry_type' ) ).on( 'change', function() { + if ( this.value === 'cookie' ) { + $cookieExp.fadeIn( 'slow' ); + } else { + $cookieExp.fadeOut( 'slow' ); + } + } ); + + const $singleEntry = document.getElementById( 'single_entry' ); + jQuery( $singleEntry ).on( 'change', function() { + if ( this.checked ) { + visible( '.hide_single_entry' ); + } else { + invisible( '.hide_single_entry' ); + } + + if ( this.checked && jQuery( document.getElementById( 'frm_single_entry_type' ) ).val() === 'cookie' ) { + $cookieExp.fadeIn( 'slow' ); + } else { + $cookieExp.fadeOut( 'slow' ); + } + } ); + + jQuery( '.hide_save_draft' ).hide(); + + const $saveDraft = jQuery( document.getElementById( 'save_draft' ) ); + $saveDraft.on( 'change', function() { + if ( this.checked ) { + jQuery( '.hide_save_draft' ).fadeIn( 'slow' ); + } else { + jQuery( '.hide_save_draft' ).fadeOut( 'slow' ); + } + } ); + triggerChange( $saveDraft ); + + //If Allow editing is checked/unchecked + $editable = document.getElementById( 'editable' ); + jQuery( $editable ).on( 'change', function() { + if ( this.checked ) { + jQuery( '.hide_editable' ).fadeIn( 'slow' ); + triggerChange( document.getElementById( 'edit_action' ) ); + } else { + jQuery( '.hide_editable' ).fadeOut( 'slow' ); + jQuery( '.edit_action_message_box' ).fadeOut( 'slow' );//Hide On Update message box + } + } ); + + //If File Protection is checked/unchecked + jQuery( document ).on( 'change', '#protect_files', function() { + if ( this.checked ) { + jQuery( '.hide_protect_files' ).fadeIn( 'slow' ); + } else { + jQuery( '.hide_protect_files' ).fadeOut( 'slow' ); + } + } ); + + jQuery( document ).on( 'frm-multiselect-changed', '#protect_files_role', adjustVisibilityValuesForEveryoneValues ); + + jQuery( document ).on( 'submit', '.frm_form_settings', settingsSubmitted ); + jQuery( document ).on( 'change', '#form_settings_page input:not(.frm-search-input), #form_settings_page select, #form_settings_page textarea', fieldUpdated ); + + // Page Selection Autocomplete + initAutocomplete(); + + jQuery( document ).on( 'frm-action-loaded', onActionLoaded ); + + initOnSubmitAction(); + }, + + panelInit: function() { + let customPanel, settingsPage, viewPage, insertFieldsTab; + + jQuery( '.frm_wrap, #postbox-container-1' ).on( 'click', '.frm_insert_code', insertCode ); + jQuery( document ).on( 'change', '.frm_insert_val', function() { + insertFieldCode( jQuery( this ).data( 'target' ), jQuery( this ).val() ); + jQuery( this ).val( '' ); + } ); + + jQuery( document ).on( 'click change', '#frm-id-key-condition', resetLogicBuilder ); + jQuery( document ).on( 'keyup change', '.frm-build-logic', setLogicExample ); + + showInputIcon(); + jQuery( document ).on( 'frmElementAdded', function( event, parentEle ) { + /* This is here for add-ons to trigger */ + showInputIcon( parentEle ); + } ); + jQuery( document ).on( 'mousedown', '.frm-show-box', showShortcodes ); + + settingsPage = document.getElementById( 'form_settings_page' ); + viewPage = document.body.classList.contains( 'post-type-frm_display' ); + insertFieldsTab = document.getElementById( 'frm_insert_fields_tab' ); + + if ( settingsPage !== null || viewPage || builderPage ) { + jQuery( document ).on( 'focusin', 'form input, form textarea', function( e ) { + let htmlTab; + e.stopPropagation(); + maybeShowModal( this ); + + if ( jQuery( this ).is( ':not(:submit, input[type=button], .frm-search-input, input[type=checkbox])' ) ) { + if ( jQuery( e.target ).closest( '#frm_adv_info' ).length ) { + // Don't trigger for fields inside of the modal. + return; + } + + if ( settingsPage !== null || builderPage ) { + /* form settings page */ + htmlTab = jQuery( '#frm_html_tab' ); + if ( jQuery( this ).closest( '#html_settings' ).length > 0 ) { + htmlTab.show(); + htmlTab.siblings().hide(); + jQuery( '#frm_html_tab a' ).trigger( 'click' ); + toggleAllowedHTML( this ); + } else { + showElement( jQuery( '.frm-category-tabs li' ) ); + insertFieldsTab.click(); + htmlTab.hide(); + htmlTab.siblings().show(); + } + } else if ( viewPage ) { + const event = new CustomEvent( 'frm_legacy_views_handle_field_focus' ); + event.frmData = { idAttrValue: this.id }; + document.dispatchEvent( event ); + } + } + } ); + } + + jQuery( '.frm_wrap, #postbox-container-1' ).on( 'mousedown', '#frm_adv_info a, .frm_field_list a', function( e ) { + e.preventDefault(); + } ); + + customPanel = jQuery( '#frm_adv_info' ); + customPanel.on( 'click', '.subsubsub a.frmids', function( e ) { + toggleKeyID( 'frmids', e ); + } ); + customPanel.on( 'click', '.subsubsub a.frmkeys', function( e ) { + toggleKeyID( 'frmkeys', e ); + } ); + }, + + inboxInit: function() { + jQuery( '.frm_inbox_dismiss' ).on( 'click', function( e ) { + const message = this.parentNode.parentNode; + const key = message.getAttribute( 'data-message' ); + const href = this.getAttribute( 'href' ); + const dismissedMessage = message.cloneNode( true ); + const dismissedMessagesWrapper = document.querySelector( '.frm-dismissed-inbox-messages' ); + + if ( 'free_templates' === key && ! this.classList.contains( 'frm_inbox_dismiss' ) ) { + return; + } + + e.preventDefault(); + + data = { + action: 'frm_inbox_dismiss', + key, + nonce: frmGlobal.nonce + }; + + const isInboxSlideIn = 'frm_inbox_slide_in' === message.id; + if ( isInboxSlideIn ) { + message.classList.remove( 's11-fadein' ); + message.classList.add( 's11-fadeout' ); + message.addEventListener( 'animationend', () => message.remove(), { once: true } ); + } + + postAjax( + data, + () => { + if ( isInboxSlideIn ) { + return; + } + + if ( href !== '#' ) { + window.location = href; + return true; + } + + fadeOut( + message, + () => { + if ( null !== dismissedMessagesWrapper ) { + dismissedMessage.classList.remove( 'frm-fade' ); + dismissedMessage.querySelector( '.frm-inbox-message-heading' )?.removeChild( dismissedMessage.querySelector( '.frm-inbox-message-heading .frm_inbox_dismiss' ) ); + dismissedMessagesWrapper.append( dismissedMessage ); + } + if ( 1 === message.parentNode.querySelectorAll( '.frm-inbox-message-container' ).length ) { + document.getElementById( 'frm_empty_inbox' ).classList.remove( 'frm_hidden' ); + message.parentNode.closest( '.frm-active' ).classList.add( 'frm-empty-inbox' ); + showActiveCampaignForm(); + } + message.parentNode.removeChild( message ); + } + ); + } + ); + } ); + + if ( false === document.getElementById( 'frm_empty_inbox' )?.classList.contains( 'frm_hidden' ) ) { + showActiveCampaignForm(); + } + }, + + solutionInit: function() { + jQuery( document ).on( 'submit', '#frm-new-template', installTemplate ); + }, + + styleInit: function() { + const $previewWrapper = jQuery( '.frm_image_preview_wrapper' ); + $previewWrapper.on( 'click', '.frm_choose_image_box', addImageToOption ); + $previewWrapper.on( 'click', '.frm_remove_image_option', removeImageFromOption ); + + wp.hooks.doAction( 'frm_style_editor_init' ); + }, + + customCSSInit: function() { + console.warn( 'Calling frmAdminBuild.customCSSInit is deprecated.' ); + }, + + globalSettingsInit: function() { + let licenseTab; + + jQuery( document ).on( 'click', '[data-frmuninstall]', uninstallNow ); + + initiateMultiselect(); + + // activate addon licenses + licenseTab = document.getElementById( 'licenses_settings' ); + if ( licenseTab !== null ) { + jQuery( licenseTab ).on( 'click', '.edd_frm_save_license', saveAddonLicense ); + } + + // Solution install page + jQuery( document ).on( 'click', '#frm-new-template button', installTemplateFieldset ); + + jQuery( '#frm-dismissable-cta .dismiss' ).on( 'click', function( event ) { + event.preventDefault(); + jQuery.post( + ajaxurl, + { + action: 'frm_lite_settings_upgrade', + nonce: frmGlobal.nonce + } + ); + jQuery( '.settings-lite-cta' ).remove(); + } ); + + const captchaType = document.getElementById( 'frm_re_type' ); + if ( captchaType ) { + captchaType.addEventListener( 'change', handleCaptchaTypeChange ); + } + + document.querySelector( '.frm_captchas' ).addEventListener( 'change', function( event ) { + const captchaValueOnLoad = document.querySelector( '.frm_captchas input[checked="checked"]' )?.value; + const showNote = event.target.value !== captchaValueOnLoad; + document.querySelector( '.captcha_settings .frm_note_style' ).classList.toggle( 'frm_hidden', ! showNote ); + } ); + + // Set fieldsUpdated to 0 to avoid the unsaved changes pop up. + frmDom.util.documentOn( 'submit', '.frm_settings_form', () => fieldsUpdated = 0 ); + + const manageStyleSettings = document.getElementById( 'manage_styles_settings' ); + if ( manageStyleSettings ) { + manageStyleSettings.addEventListener( + 'change', + event => { + const target = event.target; + if ( 'SELECT' !== target.nodeName || ! target.dataset.name || target.getAttribute( 'name' ) ) { + return; + } + + target.setAttribute( 'name', target.dataset.name ); + } + ); + } + + const paymentsSettings = document.getElementById( 'payments_settings' ); + const paymentSettingsTabs = paymentsSettings?.querySelectorAll( '[name="frm_payment_section"]' ); + if ( paymentSettingsTabs ) { + paymentSettingsTabs.forEach( + element => { + element.addEventListener( 'change', () => { + if ( ! element.checked ) { + return; + } + + const label = paymentsSettings.querySelector( `label[for="${ element.id }"]` ); + if ( label ) { + label.setAttribute( 'aria-selected', 'true' ); + } + + paymentSettingsTabs.forEach( + tab => { + if ( tab === element ) { + return; + } + + const label = paymentsSettings.querySelector( `label[for="${ tab.id }"]` ); + if ( label ) { + label.setAttribute( 'aria-selected', 'false' ); + } + } + ); + } ); + } + ); + } + }, + + exportInit: function() { + jQuery( '.frm_form_importer' ).on( 'submit', startFormMigration ); + jQuery( document.getElementById( 'frm_export_xml' ) ).on( 'submit', validateExport ); + jQuery( '#frm_export_xml input, #frm_export_xml select' ).on( 'change', removeExportError ); + jQuery( 'input[name="frm_import_file"]' ).on( 'change', checkCSVExtension ); + document.querySelector( 'select[name="format"]' ).addEventListener( 'change', exportTypeChanged ); + + jQuery( 'input[name="frm_export_forms[]"]' ).on( 'click', preventMultipleExport ); + initiateMultiselect(); + + jQuery( '.frm-feature-banner .dismiss' ).on( 'click', function( event ) { + event.preventDefault(); + jQuery.post( ajaxurl, { + action: 'frm_dismiss_migrator', + plugin: this.id, + nonce: frmGlobal.nonce + } ); + this.parentElement.remove(); + } ); + + showOrHideRepeaters( getExportOption() ); + + document.querySelector( '#frm-export-select-all' ).addEventListener( 'change', event => { + document.querySelectorAll( '[name="frm_export_forms[]"]' ).forEach( cb => cb.checked = event.target.checked ); + } ); + }, + + inboxBannerInit: function() { + const banner = document.getElementById( 'frm_banner' ); + if ( ! banner ) { + return; + } + + const dismissButton = banner.querySelector( '.frm-banner-dismiss' ); + document.addEventListener( + 'click', + function( event ) { + if ( event.target !== dismissButton ) { + return; + } + + const data = { + action: 'frm_inbox_dismiss', + key: banner.dataset.key, + nonce: frmGlobal.nonce + }; + postAjax( + data, + function() { + jQuery( banner ).fadeOut( + 400, + function() { + banner.remove(); + } + ); + } + ); + } + ); + }, + + updateOpts: function( fieldId, opts, modal ) { + const separate = usingSeparateValues( fieldId ), + action = isProductField( fieldId ) ? 'frm_bulk_products' : 'frm_import_options'; + jQuery.ajax( { + type: 'POST', + url: ajaxurl, + data: { + action: action, + field_id: fieldId, + opts: opts, + separate: separate, + nonce: frmGlobal.nonce + }, + success: function( html ) { + document.getElementById( 'frm_field_' + fieldId + '_opts' ).innerHTML = html; + wp.hooks.doAction( 'frm_after_bulk_edit_opts', fieldId ); + resetDisplayedOpts( fieldId ); + + if ( typeof modal !== 'undefined' ) { + modal.dialog( 'close' ); + document.getElementById( 'frm-update-bulk-opts' ).classList.remove( 'frm_loading_button' ); + } + } + } ); + }, + + /* remove conditional logic if the field doesn't exist */ + triggerRemoveLogic: function( fieldID, metaName ) { + jQuery( '#frm_logic_' + fieldID + '_' + metaName + ' .frm_remove_tag' ).trigger( 'click' ); + }, + + downloadXML: function( controller, ids, isTemplate ) { + let url = ajaxurl + '?action=frm_' + controller + '_xml&ids=' + ids; + if ( isTemplate !== null ) { + url = url + '&is_template=' + isTemplate; + } + location.href = url; + }, + + /** + * @since 5.0.04 + */ + hooks: { + applyFilters: function( hookName, ...args ) { + return wp.hooks.applyFilters( hookName, ...args ); + }, + addFilter: function( hookName, callback, priority ) { + return wp.hooks.addFilter( hookName, 'formidable', callback, priority ); + }, + doAction: function( hookName, ...args ) { + return wp.hooks.doAction( hookName, ...args ); + }, + addAction: function( hookName, callback, priority ) { + return wp.hooks.addAction( hookName, 'formidable', callback, priority ); + } + }, + + applyZebraStriping, + initModal, + infoModal, + offsetModalY, + adjustConditionalLogicOptionOrders, + addRadioCheckboxOpt, + installNewForm, + toggleAddonState, + purifyHtml, + loadApiEmailForm, + addMyEmailAddress, + fillDropdownOpts, + showSaveAndReloadModal, + deleteField, + insertFormField, + confirmLinkClick, + handleInsertFieldByDraggingResponse, + handleAddFieldClickResponse, + syncLayoutClasses, + }; +} + +window.frmAdminBuild = frmAdminBuildJS(); + +jQuery( document ).ready( + () => { + frmAdminBuild.init(); + + frmDom.bootstrap.setupBootstrapDropdowns( convertOldBootstrapDropdownsToBootstrap4 ); + document.querySelector( '.preview.dropdown .frm-dropdown-toggle' )?.setAttribute( 'data-toggle', 'dropdown' ); + + function convertOldBootstrapDropdownsToBootstrap4( frmDropdownMenu ) { + const toggle = frmDropdownMenu.querySelector( '.frm-dropdown-toggle' ); + if ( toggle ) { + if ( ! toggle.hasAttribute( 'role' ) ) { + toggle.setAttribute( 'role', 'button' ); + } + if ( ! toggle.hasAttribute( 'tabindex' ) ) { + toggle.setAttribute( 'tabindex', 0 ); + } + } + + // Convert
              • and
                  tags. + if ( 'UL' === frmDropdownMenu.tagName ) { + convertBootstrapUl( frmDropdownMenu ); + } + } + + function convertBootstrapUl( ul ) { + let html = ul.outerHTML; + html = html.replace( '
                    ', '' ); + html = html.replaceAll( '
                  • ', '
                  • ', '' ); + ul.outerHTML = html; + } + } +); + +function frm_show_div( div, value, showIf, classId ) { // eslint-disable-line camelcase + if ( value == showIf ) { + jQuery( classId + div ).fadeIn( 'slow' ).css( 'visibility', 'visible' ); + } else { + jQuery( classId + div ).fadeOut( 'slow' ); + } +} + +function frmCheckAll( checked, n ) { + jQuery( 'input[name^="' + n + '"]' ).prop( 'checked', ! ! checked ); +} + +function frmCheckAllLevel( checked, n, level ) { + const $kids = jQuery( '.frm_catlevel_' + level ).children( '.frm_checkbox' ).children( 'label' ); + $kids.children( 'input[name^="' + n + '"]' ).prop( 'checked', ! ! checked ); +} + +function frmGetFieldValues( fieldId, cur, rowNumber, fieldType, htmlName, callback ) { + if ( ! fieldId ) { + return; + } + + jQuery.ajax( { + type: 'POST', url: ajaxurl, + data: 'action=frm_get_field_values¤t_field=' + cur + '&field_id=' + fieldId + '&name=' + htmlName + '&t=' + fieldType + '&form_action=' + jQuery( 'input[name="frm_action"]' ).val() + '&nonce=' + frmGlobal.nonce, + success: function( msg ) { + document.getElementById( 'frm_show_selected_values_' + cur + '_' + rowNumber ).innerHTML = msg; + + if ( 'function' === typeof callback ) { + callback(); + } + } + } ); +} + +function frmImportCsv( formID ) { + let urlVars = ''; + if ( typeof __FRMURLVARS !== 'undefined' ) { + urlVars = __FRMURLVARS; + } + + jQuery.ajax( { + type: 'POST', url: ajaxurl, + data: 'action=frm_import_csv&nonce=' + frmGlobal.nonce + '&frm_skip_cookie=1' + urlVars, + success: function( count ) { + const max = jQuery( '.frm_admin_progress_bar' ).attr( 'aria-valuemax' ); + const imported = max - count; + const percent = ( imported / max ) * 100; + jQuery( '.frm_admin_progress_bar' ).css( 'width', percent + '%' ).attr( 'aria-valuenow', imported ); + + if ( parseInt( count, 10 ) > 0 ) { + jQuery( '.frm_csv_remaining' ).html( count ); + frmImportCsv( formID ); + } else { + jQuery( document.getElementById( 'frm_import_message' ) ).html( frm_admin_js.import_complete ); // eslint-disable-line camelcase + setTimeout( function() { + location.href = '?page=formidable-entries&frm_action=list&form=' + formID + '&import-message=1'; + }, 2000 ); + } + } + } ); +} diff --git a/js/src/admin/styles/dependent-updater-component.js b/js/src/admin/components/dependent-updater-component.js similarity index 87% rename from js/src/admin/styles/dependent-updater-component.js rename to js/src/admin/components/dependent-updater-component.js index cc1cb94324..813d35a7ba 100644 --- a/js/src/admin/styles/dependent-updater-component.js +++ b/js/src/admin/components/dependent-updater-component.js @@ -5,7 +5,6 @@ * For instance, when the "FrmPrimaryColorStyleComponent" is changed, it simultaneously updates various style elements like border color, text color, and button backgrounds. */ export default class frmStyleDependentUpdaterComponent { - /** * Creates an instance of frmStyleDependentUpdaterComponent. * @param {HTMLElement} component - The component element. @@ -31,12 +30,12 @@ export default class frmStyleDependentUpdaterComponent { */ initPropagationList( inputNames ) { const list = []; - inputNames.forEach( ( name ) => { - const input = document.querySelector( `input[name="${name}"]` ); + inputNames.forEach( name => { + const input = document.querySelector( `input[name="${ name }"]` ); if ( null !== input ) { list.push( input ); } - }); + } ); return list; } @@ -45,9 +44,9 @@ export default class frmStyleDependentUpdaterComponent { * @param {string} value - The value to update the dependent elements with. */ updateAllDependentElements( value ) { - this.data.propagateInputs.forEach( ( input ) => { + this.data.propagateInputs.forEach( input => { input.value = value; - }); - this.data.propagateInputs[0].dispatchEvent( this.data.changeEvent ); + } ); + this.data.propagateInputs[ 0 ].dispatchEvent( this.data.changeEvent ); } -} \ No newline at end of file +} diff --git a/js/src/admin/styles/radio-style-component.js b/js/src/admin/components/radio-style-component.js similarity index 79% rename from js/src/admin/styles/radio-style-component.js rename to js/src/admin/components/radio-style-component.js index 033eb79a64..699e6baed3 100644 --- a/js/src/admin/styles/radio-style-component.js +++ b/js/src/admin/components/radio-style-component.js @@ -5,7 +5,6 @@ import { show, hide } from 'core/utils'; * @class */ export default class frmRadioStyleComponent { - constructor() { this.radioElements = document.querySelectorAll( '.frm-style-component.frm-radio-component' ); if ( 0 < this.radioElements.length ) { @@ -17,25 +16,25 @@ export default class frmRadioStyleComponent { * Initializes the radio style component. */ init() { - this.radioElements.forEach( ( element ) => { + this.radioElements.forEach( element => { this.initOnRadioChange( element ); - }); + } ); this.initTrackerOnAccordionClick(); } initTrackerOnAccordionClick() { const accordionitems = document.querySelectorAll( '#frm_style_sidebar .accordion-section h3' ); - accordionitems.forEach( ( accordionitem ) => { - accordionitem.addEventListener( 'click', ( event ) => { - const wrapper = event.target.closest( '.accordion-section' ); + accordionitems.forEach( accordionitem => { + accordionitem.addEventListener( 'click', event => { + const wrapper = event.target.closest( '.accordion-section' ); const radioButtons = wrapper.querySelectorAll( '.frm-style-component.frm-radio-component input[type="radio"]:checked' ); - radioButtons.forEach( ( radio ) => { + radioButtons.forEach( radio => { setTimeout( () => this.onRadioChange( radio ), 200 ); - }); - }); - }); + } ); + } ); + } ); } /** @@ -43,14 +42,14 @@ export default class frmRadioStyleComponent { * @param {HTMLElement} radioElement - The radio element. */ initOnRadioChange( radioElement ) { - radioElement.querySelectorAll( 'input[type="radio"]' ).forEach( ( radio ) => { + radioElement.querySelectorAll( 'input[type="radio"]' ).forEach( radio => { if ( radio.checked ) { this.onRadioChange( radio ); } - radio.addEventListener( 'change', ( event ) => { + radio.addEventListener( 'change', event => { this.onRadioChange( event.target ); - }); - }); + } ); + } ); } /** @@ -58,7 +57,7 @@ export default class frmRadioStyleComponent { * @param {HTMLElement} target - The active radio button. */ onRadioChange( target ) { - const wrapper = target.closest( '.frm-style-component.frm-radio-component' ); + const wrapper = target.closest( '.frm-style-component.frm-radio-component' ); const activeItem = wrapper.querySelector( 'input[type="radio"]:checked + label' ); if ( null === activeItem ) { @@ -80,16 +79,16 @@ export default class frmRadioStyleComponent { return; } - const elements = document.querySelectorAll( `div[data-frm-element="${elementAttr}"]` ); + const elements = document.querySelectorAll( `div[data-frm-element="${ elementAttr }"]` ); if ( 0 === elements.length ) { return; } - elements.forEach( ( element ) => { + elements.forEach( element => { show( element ); element.classList.add( 'frm-element-is-visible' ); - }); + } ); } /** @@ -100,11 +99,11 @@ export default class frmRadioStyleComponent { if ( 0 === elements.length ) { return; } - elements.forEach( ( element ) => { + elements.forEach( element => { element.classList.remove( 'frm-element-is-visible' ); element.classList.add( 'frm_hidden' ); hide( element ); - }); + } ); } /** @@ -113,12 +112,12 @@ export default class frmRadioStyleComponent { * @param {HTMLElement} wrapper - The wrapper element. */ moveTracker( activeItem, wrapper ) { - const offset = activeItem.offsetLeft; - const width = activeItem.offsetWidth; + const offset = activeItem.offsetLeft; + const width = activeItem.offsetWidth; const tracker = wrapper.querySelector( '.frm-radio-active-tracker' ); tracker.style.left = 0; - tracker.style.width = `${width}px`; + tracker.style.width = `${ width }px`; tracker.style.transform = `translateX(${ offset }px)`; } } diff --git a/js/src/admin/styles/slider-style-component.js b/js/src/admin/components/slider-style-component.js similarity index 81% rename from js/src/admin/styles/slider-style-component.js rename to js/src/admin/components/slider-style-component.js index 448eee765a..cc97c4e947 100644 --- a/js/src/admin/styles/slider-style-component.js +++ b/js/src/admin/components/slider-style-component.js @@ -4,7 +4,6 @@ import frmStyleDependentUpdaterComponent from './dependent-updater-component'; * @class frmSliderStyleComponent */ export default class frmSliderStyleComponent { - constructor() { this.sliderElements = document.querySelectorAll( '.frm-slider-component' ); if ( 0 === this.sliderElements.length ) { @@ -16,8 +15,8 @@ export default class frmSliderStyleComponent { this.sliderMarginRight = 5; this.eventsChange = []; - const { debounce } = frmDom.util; - this.valueChangeDebouncer = debounce( ( index ) => this.triggerValueChange( index ), 25 ); + const { debounce } = frmDom.util; + this.valueChangeDebouncer = debounce( index => this.triggerValueChange( index ), 25 ); this.initOptions(); this.init(); @@ -30,7 +29,7 @@ export default class frmSliderStyleComponent { this.options = []; this.sliderElements.forEach( ( element, index ) => { const parentWrapper = element.classList.contains( 'frm-has-multiple-values' ) ? element.closest( '.frm-style-component' ) : element; - this.options.push({ + this.options.push( { dragging: false, startX: 0, translateX: 0, @@ -39,8 +38,8 @@ export default class frmSliderStyleComponent { index: index, value: 0, dependentUpdater: parentWrapper.classList.contains( 'frm-style-dependent-updater-component' ) ? new frmStyleDependentUpdaterComponent( parentWrapper ) : null - }); - }); + } ); + } ); } /** @@ -56,14 +55,14 @@ export default class frmSliderStyleComponent { */ initDraggable() { this.sliderElements.forEach( ( element, index ) => { - this.eventsChange[ index ] = new Event( 'change', { + this.eventsChange[ index ] = new Event( 'change', { bubbles: true, cancelable: true - }); + } ); const draggableBullet = element.querySelector( '.frm-slider-bullet' ); - const valueInput = element.querySelector( '.frm-slider-value input[type="text"]' ); + const valueInput = element.querySelector( '.frm-slider-value input[type="text"]' ); - valueInput.addEventListener( 'change', ( event ) => { + valueInput.addEventListener( 'change', event => { const unit = element.querySelector( 'select' ).value; if ( this.getMaxValue( unit, index ) < parseInt( event.target.value, 10 ) ) { @@ -73,42 +72,42 @@ export default class frmSliderStyleComponent { this.initSliderWidth( element ); this.options[ index ].fullValue = this.updateValue( element, valueInput.value + unit ); this.triggerValueChange( index ); - }); + } ); this.expandSliderGroup( element ); this.updateOnUnitChange( element, valueInput, index ); this.changeSliderPositionOnClick( element, valueInput, index ); - draggableBullet.addEventListener( 'mousedown', ( event ) => { + draggableBullet.addEventListener( 'mousedown', event => { event.preventDefault(); event.stopPropagation(); if ( element.classList.contains( 'frm-disabled' ) ) { return; } this.enableDragging( event, index ); - }); + } ); - draggableBullet.addEventListener( 'mousemove', ( event ) => { + draggableBullet.addEventListener( 'mousemove', event => { if ( element.classList.contains( 'frm-disabled' ) ) { return; } this.moveTracker( event, index ); - }); + } ); - draggableBullet.addEventListener( 'mouseup', ( event) => { + draggableBullet.addEventListener( 'mouseup', event => { if ( element.classList.contains( 'frm-disabled' ) ) { return; } this.disableDragging( index, event ); - }); + } ); - draggableBullet.addEventListener( 'mouseleave', ( event ) => { + draggableBullet.addEventListener( 'mouseleave', event => { if ( element.classList.contains( 'frm-disabled' ) ) { return; } this.disableDragging( index, event ); - }); - }); + } ); + } ); } expandSliderGroup( element ) { @@ -120,14 +119,14 @@ export default class frmSliderStyleComponent { const sliderGroupItems = this.getSliderGroupItems( element ); svgIcon.addEventListener( 'click', ( ) => { - sliderGroupItems.forEach( ( item ) => { + sliderGroupItems.forEach( item => { item.classList.toggle( 'frm_hidden' ); - }); - }); + } ); + } ); } updateOnUnitChange( element, valueInput, index ) { - element.querySelector( 'select' ).addEventListener( 'change', ( event ) => { + element.querySelector( 'select' ).addEventListener( 'change', event => { const unit = event.target.value.toLowerCase(); if ( '' === unit ) { @@ -147,17 +146,17 @@ export default class frmSliderStyleComponent { this.options[ index ].fullValue = valueInput.value + unit; this.updateValue( element, this.options[ index ].fullValue ); this.triggerValueChange( index ); - }); + } ); } changeSliderPositionOnClick( element, valueInput, index ) { - const frmSlider = element.querySelector( '.frm-slider' ); + const frmSlider = element.querySelector( '.frm-slider' ); const customEvent = new Event( 'change', { - 'bubbles': true, - 'cancelable': true - }); + bubbles: true, + cancelable: true + } ); - frmSlider.addEventListener( 'click', ( event ) => { + frmSlider.addEventListener( 'click', event => { if ( element.classList.contains( 'frm-disabled' ) ) { return; } @@ -170,10 +169,10 @@ export default class frmSliderStyleComponent { } const sliderWidth = frmSlider.offsetWidth - this.sliderBulletWidth; - const sliderRect = frmSlider.getBoundingClientRect(); - const deltaX = event.clientX - sliderRect.left - this.sliderBulletWidth; - const unit = element.querySelector( 'select' ).value; - const value = this.calculateValue( sliderWidth, deltaX, this.getMaxValue( unit, index ) ); + const sliderRect = frmSlider.getBoundingClientRect(); + const deltaX = event.clientX - sliderRect.left - this.sliderBulletWidth; + const unit = element.querySelector( 'select' ).value; + const value = this.calculateValue( sliderWidth, deltaX, this.getMaxValue( unit, index ) ); if ( value < 0 ) { return; @@ -184,8 +183,7 @@ export default class frmSliderStyleComponent { valueInput.value = value; valueInput.dispatchEvent( customEvent ); - - }); + } ); } /** @@ -199,26 +197,26 @@ export default class frmSliderStyleComponent { return []; } const slidersGroup = element.dataset.displaySliders.split( ',' ); - const query = slidersGroup.map( ( item ) => { - return `.frm-slider-component[data-type="${item}"]`; - }).join( ', ' ); + const query = slidersGroup.map( item => { + return `.frm-slider-component[data-type="${ item }"]`; + } ).join( ', ' ); - return element.closest( '.frm-style-component' ).querySelectorAll( query ) + return element.closest( '.frm-style-component' ).querySelectorAll( query ); } /** * Initializes the position of sliders when a style accordion section is opened. */ initSlidersPosition() { - const accordionitems = document.querySelectorAll( '#frm_style_sidebar .accordion-section h3' ); - const quickSettings = document.querySelector( '.frm-quick-settings' ); + const accordionitems = document.querySelectorAll( '#frm_style_sidebar .accordion-section h3' ); + const quickSettings = document.querySelector( '.frm-quick-settings' ); const openedAccordion = document.querySelector( '.accordion-section.open' ); // Detect if upload background image upload has triggered and initialize the "Image Opacity" slider width. - wp.hooks.addAction( 'frm_pro_on_bg_image_upload', 'formidable', ( event ) => { + wp.hooks.addAction( 'frm_pro_on_bg_image_upload', 'formidable', event => { const imageBackgroundOpacitySlider = event.closest( '.accordion-section-content' ).querySelector( '#frm-bg-image-opacity-slider' ); this.initSlidersWidth( imageBackgroundOpacitySlider ); - }); + } ); // init the sliders width from "Quick Settings" page. if ( null !== quickSettings ) { @@ -231,11 +229,11 @@ export default class frmSliderStyleComponent { } // init the sliders width everytime when an accordion section is opened from "Advanced Settings" page. - accordionitems.forEach( ( item ) => { - item.addEventListener( 'click', ( event ) => { + accordionitems.forEach( item => { + item.addEventListener( 'click', event => { this.initSlidersWidth( event.target.closest( '.accordion-section' ) ); - }); - }); + } ); + } ); this.initSliderPositionOnFieldShapeChange(); } @@ -253,14 +251,14 @@ export default class frmSliderStyleComponent { } const radioButtons = fieldShapeType.querySelectorAll( 'input[type="radio"]' ); - radioButtons.forEach( ( radio ) => { - radio.addEventListener( 'change', ( event ) => { + radioButtons.forEach( radio => { + radio.addEventListener( 'change', event => { if ( event.target.checked && 'rounded-corner' === event.target.value ) { const slider = document.querySelector( 'div[data-frm-element="field-shape-corner-radius"] .frm-slider-component' ); this.initSliderWidth( slider ); } - }) - }); + } ); + } ); } /** @@ -271,11 +269,11 @@ export default class frmSliderStyleComponent { */ initSlidersWidth( section ) { const sliders = section.querySelectorAll( '.frm-slider-component' ); - sliders.forEach( ( slider ) => { + sliders.forEach( slider => { setTimeout( () => { this.initSliderWidth( slider ); }, 100 ); - }); + } ); } /** @@ -288,13 +286,13 @@ export default class frmSliderStyleComponent { if ( slider.classList.contains( 'frm-disabled' ) ) { return; } - const index = this.getSliderIndex( slider ); + const index = this.getSliderIndex( slider ); const sliderWidth = slider.querySelector( '.frm-slider' ).offsetWidth - this.sliderBulletWidth; - const value = parseInt( slider.querySelector( '.frm-slider-value input[type="text"]' ).value, 10 ); - const unit = slider.querySelector( 'select' ).value; - const deltaX = '%' === unit ? Math.round( sliderWidth * value / 100 ) : Math.ceil( ( value / this.options[ index ].maxValue ) * sliderWidth ); + const value = parseInt( slider.querySelector( '.frm-slider-value input[type="text"]' ).value, 10 ); + const unit = slider.querySelector( 'select' ).value; + const deltaX = '%' === unit ? Math.round( sliderWidth * value / 100 ) : Math.ceil( ( value / this.options[ index ].maxValue ) * sliderWidth ); - slider.querySelector( '.frm-slider-active-track' ).style.width = `${deltaX}px`; + slider.querySelector( '.frm-slider-active-track' ).style.width = `${ deltaX }px`; this.options[ index ].translateX = deltaX; this.options[ index ].value = value + unit; } @@ -314,10 +312,10 @@ export default class frmSliderStyleComponent { const childSliders = slider.classList.contains( 'frm-has-independent-fields' ) ? slider.querySelectorAll( '.frm-independent-slider-field' ) : this.getSliderGroupItems( slider ); childSliders.forEach( ( item, childIndex ) => { - item.querySelector( '.frm-slider-active-track' ).style.width = `${width}px`; + item.querySelector( '.frm-slider-active-track' ).style.width = `${ width }px`; this.options[ index + childIndex + 1 ].translateX = width; this.options[ index + childIndex + 1 ].value = value; - }); + } ); } /** @@ -327,10 +325,10 @@ export default class frmSliderStyleComponent { * @return {number} The index of the slider element. */ getSliderIndex( slider ) { - return this.options.filter( ( option ) => { + return this.options.filter( option => { return option.element === slider; - })[0].index; - }; + } )[ 0 ].index; + } /** * Handles the movement of the slider tracker. @@ -343,22 +341,22 @@ export default class frmSliderStyleComponent { if ( ! this.options[ index ].dragging ) { return; } - let deltaX = event.clientX - this.options[ index ].startX; - const element = this.sliderElements[ index ]; + let deltaX = event.clientX - this.options[ index ].startX; + const element = this.sliderElements[ index ]; const sliderWidth = element.querySelector( '.frm-slider' ).offsetWidth; // Ensure deltaX does not go below 0 deltaX = Math.max( deltaX, 0 ); - if ( deltaX + this.sliderBulletWidth / 2 + this.sliderMarginRight >= sliderWidth ) { + if ( deltaX + ( this.sliderBulletWidth / 2 ) + this.sliderMarginRight >= sliderWidth ) { return; } - const unit = element.querySelector( 'select' ).value; + const unit = element.querySelector( 'select' ).value; const value = this.calculateValue( sliderWidth, deltaX, this.getMaxValue( unit, index ) ); element.querySelector( '.frm-slider-value input[type="text"]' ).value = value; element.querySelector( '.frm-slider-bullet .frm-slider-value-label' ).innerText = value; - element.querySelector( '.frm-slider-active-track' ).style.width = `${deltaX}px`; + element.querySelector( '.frm-slider-active-track' ).style.width = `${ deltaX }px`; this.initChildSlidersWidth( element, deltaX, index, value + unit ); this.options[ index ].translateX = deltaX; @@ -416,11 +414,11 @@ export default class frmSliderStyleComponent { return; } - const input = this.sliderElements[ index ].classList.contains( 'frm-has-multiple-values' ) ? this.sliderElements[ index ].closest('.frm-style-component').querySelector( 'input[type="hidden"]' ) : this.sliderElements[ index ].querySelectorAll( '.frm-slider-value input[type="hidden"]' ); + const input = this.sliderElements[ index ].classList.contains( 'frm-has-multiple-values' ) ? this.sliderElements[ index ].closest( '.frm-style-component' ).querySelector( 'input[type="hidden"]' ) : this.sliderElements[ index ].querySelectorAll( '.frm-slider-value input[type="hidden"]' ); if ( input instanceof NodeList ) { - input.forEach( ( item ) => { + input.forEach( item => { item.dispatchEvent( this.eventsChange[ index ] ); - }); + } ); return; } input.dispatchEvent( this.eventsChange[ index ] ); @@ -435,14 +433,13 @@ export default class frmSliderStyleComponent { * @return {number} - The calculated value. */ calculateValue( width, deltaX, maxValue ) { - // Indicates the additional value generated by the slider's drag progress (up to 100%) and the width of the slider bullet. // Generates a more accurate value for the slider's start (0) and end (maximum value) positions, taking into account the slider's position and bullet width. const delta = Math.ceil( this.sliderBulletWidth * ( deltaX / width ) ); const value = Math.ceil( ( ( deltaX + delta ) / width ) * maxValue ); - return Math.min( value, maxValue ) + return Math.min( value, maxValue ); } /** @@ -462,43 +459,43 @@ export default class frmSliderStyleComponent { } } if ( element.classList.contains( 'frm-has-multiple-values' ) ) { - const input = element.closest( '.frm-style-component' ).querySelector( 'input[type="hidden"]' ); + const input = element.closest( '.frm-style-component' ).querySelector( 'input[type="hidden"]' ); const inputValue = input.value.split( ' ' ); - const type = element.dataset.type; + const type = element.dataset.type; - if ( ! inputValue[2] ) { - inputValue[2] = '0px'; + if ( ! inputValue[ 2 ] ) { + inputValue[ 2 ] = '0px'; } - if ( ! inputValue[3] ) { - inputValue[3] = '0px'; + if ( ! inputValue[ 3 ] ) { + inputValue[ 3 ] = '0px'; } switch ( type ) { case 'vertical': - inputValue[0] = value; - inputValue[2] = value; + inputValue[ 0 ] = value; + inputValue[ 2 ] = value; break; case 'horizontal': - inputValue[1] = value; - inputValue[3] = value; + inputValue[ 1 ] = value; + inputValue[ 3 ] = value; break; case 'top': - inputValue[0] = value; + inputValue[ 0 ] = value; break; case 'bottom': - inputValue[2] = value; + inputValue[ 2 ] = value; break; case 'left': - inputValue[3] = value; + inputValue[ 3 ] = value; break; case 'right': - inputValue[1] = value; + inputValue[ 1 ] = value; break; } @@ -506,22 +503,22 @@ export default class frmSliderStyleComponent { input.value = newValue; const childSlidersGroup = this.getSliderGroupItems( element ); - childSlidersGroup.forEach( ( slider ) => { + childSlidersGroup.forEach( slider => { const unitMeasure = this.getUnitMeasureFromValue( value ); slider.querySelector( '.frm-slider-value input[type="text"]' ).value = parseInt( value, 10 ); slider.querySelector( 'select' ).value = unitMeasure; - }); + } ); return newValue; } if ( element.classList.contains( 'frm-has-independent-fields' ) ) { - const inputValues = element.querySelectorAll( '.frm-slider-value input[type="hidden"]' ); + const inputValues = element.querySelectorAll( '.frm-slider-value input[type="hidden"]' ); const visibleValues = element.querySelectorAll( '.frm-slider-value input[type="text"]' ); inputValues.forEach( ( input, index ) => { input.value = value; visibleValues[ index + 1 ].value = parseInt( value, 10 ); - }); + } ); return value; } @@ -539,4 +536,4 @@ export default class frmSliderStyleComponent { getUnitMeasureFromValue( value ) { return [ '%', 'px', 'em' ].find( unit => value.includes( unit ) ) || ''; } -} \ No newline at end of file +} diff --git a/js/src/admin/styles/tabs-style-component.js b/js/src/admin/components/tabs-style-component.js similarity index 79% rename from js/src/admin/styles/tabs-style-component.js rename to js/src/admin/components/tabs-style-component.js index 5db18a2ac8..bc828db489 100644 --- a/js/src/admin/styles/tabs-style-component.js +++ b/js/src/admin/components/tabs-style-component.js @@ -4,7 +4,6 @@ import { frmTabsNavigator } from '../../components/class-tabs-navigator'; * @class */ export default class frmTabsStyleComponent { - constructor() { this.elements = document.querySelectorAll( '.frm-style-tabs-wrapper' ); if ( 0 < this.elements.length ) { @@ -16,9 +15,9 @@ export default class frmTabsStyleComponent { * Initializes the Tabs Style Component. */ init() { - this.elements.forEach( ( element ) => { + this.elements.forEach( element => { new frmTabsNavigator( element ); - }); + } ); } /** @@ -27,10 +26,10 @@ export default class frmTabsStyleComponent { */ initOnTabClick( wrapper ) { this.initActiveBackgroundWidth( wrapper ); - wrapper.querySelectorAll( '.frm-tab-item' ).forEach( ( tab ) => { - tab.addEventListener( 'click', ( event ) => { + wrapper.querySelectorAll( '.frm-tab-item' ).forEach( tab => { + tab.addEventListener( 'click', event => { this.onTabClick( event.target.closest( '.frm-tabs-wrapper' ) ); - }); - }); + } ); + } ); } -} \ No newline at end of file +} diff --git a/js/src/admin/styles.js b/js/src/admin/styles.js index 86332e6d60..0e3e0cc820 100644 --- a/js/src/admin/styles.js +++ b/js/src/admin/styles.js @@ -1,15 +1,14 @@ import { __ } from '@wordpress/i18n'; -import frmRadioStyleComponent from './styles/radio-style-component.js'; -import frmSliderStyleComponent from './styles/slider-style-component.js'; -import frmTabsStyleComponent from './styles/tabs-style-component.js'; -import frmStyleDependentUpdaterComponent from './styles/dependent-updater-component.js'; +import frmRadioStyleComponent from './components/radio-style-component.js'; +import frmSliderStyleComponent from './components/slider-style-component.js'; +import frmTabsStyleComponent from './components/tabs-style-component.js'; +import frmStyleDependentUpdaterComponent from './components/dependent-updater-component.js'; /** * Represents the frmStyleOptions class. * @class */ class frmStyleOptions { - constructor() { this.success = frmDom.success; this.init(); @@ -18,7 +17,7 @@ class frmStyleOptions { /** * Initializes the style components: frmRadioStyleComponent, frmSliderStyleComponent, and frmTabsStyleComponent. - * Init the dependent + * Init the dependent */ init() { new frmRadioStyleComponent(); @@ -36,32 +35,32 @@ class frmStyleOptions { */ initColorPickerDependentUpdaterComponents() { const components = document.querySelectorAll( '.frm-style-dependent-updater-component.frm-colorpicker' ); - const elements = []; + const elements = []; - components.forEach( ( component ) => { + components.forEach( component => { const element = component.querySelector( 'input.hex' ); - const id = 'undefined' !== typeof element ? element.getAttribute( 'id' ) : null; + const id = 'undefined' !== typeof element ? element.getAttribute( 'id' ) : null; if ( null !== id ) { - elements.push({ + elements.push( { id: id, dependentUpdaterClass: new frmStyleDependentUpdaterComponent( component, 'colorpicker' ) - }); + } ); } - }); + } ); wp.hooks.addAction( 'frm_style_options_color_change', 'formidable', ( { event, value } ) => { const container = event.target.closest( '.wp-picker-container' ); - const id = event.target.getAttribute( 'id' ); + const id = event.target.getAttribute( 'id' ); container.querySelector( '.wp-color-result-text' ).innerText = value; - elements.forEach( ( element ) => { + elements.forEach( element => { if ( element.id === id ) { element.dependentUpdaterClass.updateAllDependentElements( value ); } - }); - }); + } ); + } ); } /** @@ -81,21 +80,23 @@ class frmStyleOptions { const styleOptionsMenu = settingsWrapper.querySelector( ':scope > ul' ); - styleOptionsMenu.querySelectorAll( ':scope > li' ).forEach( ( item ) => { - item.querySelector('h3').addEventListener( 'mouseover', ( event ) => { - hoverElement.style.transform = `translateY(${event.target.closest('li').offsetTop}px)`; + styleOptionsMenu.querySelectorAll( ':scope > li' ).forEach( item => { + item.querySelector( 'h3' ).addEventListener( 'mouseover', event => { + hoverElement.style.transform = `translateY(${ event.target.closest( 'li' ).offsetTop }px)`; hoverElement.classList.add( 'frm-animating' ); hoverElement.classList.remove( 'frm_hidden' ); - setTimeout( () => { hoverElement.classList.remove( 'frm-animating' ); }, 250 ); - }); - }); + setTimeout( () => { + hoverElement.classList.remove( 'frm-animating' ); + }, 250 ); + } ); + } ); const accordionitems = document.querySelectorAll( '#frm_style_sidebar .accordion-section h3' ); - accordionitems.forEach( ( item ) => { + accordionitems.forEach( item => { item.addEventListener( 'click', () => { hoverElement.classList.add( 'frm_hidden' ); - }); - }); + } ); + } ); } /** @@ -106,12 +107,12 @@ class frmStyleOptions { */ initStyleClassCopyToClipboard( successMessage ) { const copyLabel = document.querySelector( '.frm-copy-text' ); - copyLabel.addEventListener( 'click', ( event ) => { + copyLabel.addEventListener( 'click', event => { const className = event.currentTarget.innerText; navigator.clipboard.writeText( className ).then( () => { this.success( successMessage ); - }); - }) + } ); + } ); } } diff --git a/js/src/api/class-addon-api.js b/js/src/api/class-addon-api.js index 59654d1eb3..826a96f590 100644 --- a/js/src/api/class-addon-api.js +++ b/js/src/api/class-addon-api.js @@ -2,10 +2,10 @@ export class frmAddonAPI { /** * A function designed to toggle different addon states. * - * @param {'frm_install_addon'|'frm_activate_addon'|'frm_multiple_addons'} action The addon state action type. - * @param {string} addon The addon path. Ex: formidable-views/formidable-views.php + * @param {'frm_install_addon'|'frm_activate_addon'|'frm_multiple_addons'} action The addon state action type. + * @param {string} addon The addon path. Ex: formidable-views/formidable-views.php * - * @return {Promise} + * @return {Promise} The response from the server. */ static toggleAddonState( action, addon ) { return fetch( ajaxurl, { @@ -13,11 +13,11 @@ export class frmAddonAPI { headers: { 'Content-Type': 'application/x-www-form-urlencoded' }, - body: new URLSearchParams({ + body: new URLSearchParams( { action: action, nonce: frmGlobal.nonce, plugin: addon - }) - }).then( response => response.json() ); + } ) + } ).then( response => response.json() ); } } diff --git a/js/src/common/components/icon.js b/js/src/common/components/icon.js index 25a7815532..78a7a9c7e9 100644 --- a/js/src/common/components/icon.js +++ b/js/src/common/components/icon.js @@ -5,7 +5,6 @@ const { Component } = wp.element; const { Dashicon } = wp.components; export default class FormidableIcon extends Component { - loadCustomSvgIcon( ) { const icon = formidable_form_selector.icon; if ( icon.match( /frm_white_label_icon/ ) ) { @@ -13,13 +12,12 @@ export default class FormidableIcon extends Component { - ) + ); } return false; } render() { - if ( false !== this.loadCustomSvgIcon() ) { return this.loadCustomSvgIcon(); } @@ -30,9 +28,9 @@ export default class FormidableIcon extends Component { return ( - - - + + + ); } diff --git a/js/src/common/components/itemselect.js b/js/src/common/components/itemselect.js index 3abf65cf90..f700c5190e 100755 --- a/js/src/common/components/itemselect.js +++ b/js/src/common/components/itemselect.js @@ -23,6 +23,7 @@ export default class ItemSelect extends Component { return [ { + // translators: %s is the name of the item label: sprintf( __( 'Select a %s', 'formidable' ), itemName ), value: '', }, @@ -44,7 +45,11 @@ export default class ItemSelect extends Component { if ( ( ! items || items.length === 0 ) ) { return (

                    - { sprintf( __( 'Currently, there are no %s', 'formidable' ), itemNamePlural ) } + { sprintf( + // translators: %s is the name of the item + __( 'Currently, there are no %s', 'formidable' ), + itemNamePlural + ) }

                    ); } diff --git a/js/src/common/components/radio.js b/js/src/common/components/radio.js index 4bdd6dd30f..684cf1b609 100644 --- a/js/src/common/components/radio.js +++ b/js/src/common/components/radio.js @@ -9,15 +9,16 @@ const { function RadioControl( { label, className, selected, help, instanceId, onChange, options = [] } ) { const id = `inspector-radio-control-${ instanceId }`; - const onChangeValue = ( event ) => onChange( event.target.value ); + const onChangeValue = event => onChange( event.target.value ); className = className + ' components-radio-control'; + // eslint-disable-next-line @wordpress/no-base-control-with-label-without-id return { options.map( ( option, index ) =>
                    + > + /> { option.help &&

                    { option.help }

                    - } + }
                    - ) } + ) }
                    ; } diff --git a/js/src/common/utilities/values.js b/js/src/common/utilities/values.js index aee1246913..0b764635de 100755 --- a/js/src/common/utilities/values.js +++ b/js/src/common/utilities/values.js @@ -1,22 +1,22 @@ /** * Updates an attribute with the specified new value * - * @param {string} attributeName Name of block attribute to be updated - * @param {mixed} attributeValue Value of block attribute to be updated - * @param {function} setAttributes Function to set the block attribute to be updated + * @param {string} attributeName Name of block attribute to be updated + * @param {*} attributeValue Value of block attribute to be updated + * @param {Function} setAttributes Function to set the block attribute to be updated */ export function updateAttribute( attributeName, attributeValue, setAttributes ) { - setAttributes({ + setAttributes( { [ attributeName ]: attributeValue - }); + } ); } /** * Sets text attribute for a shortcode from a key value pair * - * @param {mixed} value Value of text attribute to be set + * @param {*} value Value of text attribute to be set * @param {string} attributeName Name of text attribute to be set - * @returns {string} String of the text attribute in the format " id=10" + * @return {string} String of the text attribute in the format " id=10" */ export function setTextAttribute( value, attributeName ) { if ( value ) { @@ -28,7 +28,7 @@ export function setTextAttribute( value, attributeName ) { /** * Gets subdirectory of current site, if the site isn't on the top level of the domain * - * @returns {string} The subdirectory of the current site + * @return {string} The subdirectory of the current site */ export function getSubDir() { const page = window.location.pathname; diff --git a/js/src/components/class-counter.js b/js/src/components/class-counter.js index 42bf92c9c2..98339dc40b 100644 --- a/js/src/components/class-counter.js +++ b/js/src/components/class-counter.js @@ -1,25 +1,24 @@ export class frmCounter { - /** * Init frmCounter * * @param {Element} element - * @param {object} options + * @param {Object} options * @param {integer} options.timetoFinish - Max time in mileseconds for counter to complete the animation. */ constructor( element, options ) { - if ( ! element instanceof Element || ! element.dataset.counter ) { + if ( ! ( element instanceof Element ) || ! element.dataset.counter ) { return; } - this.template = element.dataset.type || 'default'; - this.element = element; - this.value = parseInt( element.dataset.counter, 10 ); - this.activeCounter = 0; - this.locale = element.dataset.locale ? element.dataset.locale.replace( '_', '-' ) : 'en-US'; + this.template = element.dataset.type || 'default'; + this.element = element; + this.value = parseInt( element.dataset.counter, 10 ); + this.activeCounter = 0; + this.locale = element.dataset.locale ? element.dataset.locale.replace( '_', '-' ) : 'en-US'; this.timeoutInterval = 50; - this.timeToFinish = 'undefined' !== typeof options && 'undefined' !== typeof options.timetoFinish ? options.timetoFinish : 1400; - this.valueStep = this.value / Math.ceil( this.timeToFinish / this.timeoutInterval ); + this.timeToFinish = 'undefined' !== typeof options && 'undefined' !== typeof options.timetoFinish ? options.timetoFinish : 1400; + this.valueStep = this.value / Math.ceil( this.timeToFinish / this.timeoutInterval ); if ( 0 === this.value ) { return; @@ -30,7 +29,7 @@ export class frmCounter { formatNumber( number ) { if ( 'currency' === this.template ) { - return number.toLocaleString( this.locale, { minimumFractionDigits: 2 }); + return number.toLocaleString( this.locale, { minimumFractionDigits: 2 } ); } return number; } @@ -43,7 +42,5 @@ export class frmCounter { } else { this.element.innerText = this.formatNumber( this.value ); } - } - } diff --git a/js/src/components/class-overlay.js b/js/src/components/class-overlay.js index 228ec6127c..f9d92c4bc4 100644 --- a/js/src/components/class-overlay.js +++ b/js/src/components/class-overlay.js @@ -4,7 +4,6 @@ import { frmAnimate } from 'core/utils'; export class frmOverlay { - constructor() { this.body = document.body; } @@ -12,14 +11,14 @@ export class frmOverlay { /** * Open overlay * - * @param {Object} overlayData - An object containing data for the overlay. - * @param {string} overlayData.hero_image - URL of the hero image. - * @param {string} overlayData.heading - Heading of the overlay. - * @param {string} overlayData.copy - Copy/content of the overlay. - * @param {Array} overlayData.buttons - Array of button objects. - * @param {string} overlayData.buttons[].url - URL for the button. - * @param {string} overlayData.buttons[].target - Target attribute for the button link. - * @param {string} overlayData.buttons[].label - Label/text of the button. + * @param {Object} overlayData An object containing data for the overlay. + * @param {string} overlayData.hero_image URL of the hero image. + * @param {string} overlayData.heading Heading of the overlay. + * @param {string} overlayData.copy Copy/content of the overlay. + * @param {Array} overlayData.buttons Array of button objects. + * @param {string} overlayData.buttons[].url URL for the button. + * @param {string} overlayData.buttons[].target Target attribute for the button link. + * @param {string} overlayData.buttons[].label Label/text of the button. */ open( overlayData ) { this.overlayData = { @@ -34,7 +33,6 @@ export class frmOverlay { this.body.insertBefore( this.buildOverlay(), this.body.firstChild ); this.initCloseButton(); this.initOverlayIntroAnimation( 200 ); - } bodyAddOverflowHidden() { @@ -66,7 +64,7 @@ export class frmOverlay { getHeroImage() { if ( this.overlayData.hero_image ) { - return frmDom.img({ src: this.overlayData.hero_image }); + return frmDom.img( { src: this.overlayData.hero_image } ); } return ''; } @@ -75,7 +73,7 @@ export class frmOverlay { const buttons = this.overlayData.buttons.map( ( button, index ) => { if ( ! button.url || '' === button.url ) { return ''; - }; + } const buttonTypeClassname = 1 === index ? 'frm-button-primary' : 'frm-button-secondary'; const options = { href: button.url, @@ -86,7 +84,7 @@ export class frmOverlay { options.target = button.target; } return frmDom.a( options ); - }); + } ); if ( buttons ) { const buttonsWrapperElementOptions = { className: 'frm-overlay--cta frm-flex-box', children: buttons }; @@ -98,7 +96,7 @@ export class frmOverlay { getHeading() { if ( this.overlayData.heading ) { - return frmDom.tag( 'h2', { className: 'frm-overlay--heading frm-text-xl', text: this.overlayData.heading }); + return frmDom.tag( 'h2', { className: 'frm-overlay--heading frm-text-xl', text: this.overlayData.heading } ); } return ''; } @@ -107,7 +105,7 @@ export class frmOverlay { if ( this.overlayData.copy ) { const copy = frmDom.tag( 'div' ); copy.innerHTML = this.overlayData.copy; - return frmDom.div({ className: 'frm-overlay--copy', child: copy }); + return frmDom.div( { className: 'frm-overlay--copy', child: copy } ); } return ''; } @@ -120,16 +118,16 @@ export class frmOverlay { } buildOverlay() { - const container = frmDom.div({ + const container = frmDom.div( { className: 'frm-overlay--container', children: [ - frmDom.div({className: 'frm-overlay--hero-image frm-mb-md', children: [ this.getHeroImage() ] }), + frmDom.div( { className: 'frm-overlay--hero-image frm-mb-md', children: [ this.getHeroImage() ] } ), this.getHeading(), this.getCopy(), this.getButtons() ] - }); + } ); - return frmDom.div({ className: 'frm-overlay--wrapper frm_wrap', children: [ container ] }); + return frmDom.div( { className: 'frm-overlay--wrapper frm_wrap', children: [ container ] } ); } } diff --git a/js/src/components/class-tabs-navigator.js b/js/src/components/class-tabs-navigator.js index 5d63af5855..19f4caf10b 100644 --- a/js/src/components/class-tabs-navigator.js +++ b/js/src/components/class-tabs-navigator.js @@ -1,5 +1,4 @@ export class frmTabsNavigator { - constructor( wrapper ) { if ( 'undefined' === typeof wrapper ) { return; @@ -12,10 +11,10 @@ export class frmTabsNavigator { } this.flexboxSlidesGap = '16px'; - this.navs = this.wrapper.querySelectorAll( '.frm-tabs-navs ul > li' ); - this.slideTrackLine = this.wrapper.querySelector( '.frm-tabs-active-underline' ); - this.slideTrack = this.wrapper.querySelector( '.frm-tabs-slide-track' ); - this.slides = this.wrapper.querySelectorAll( '.frm-tabs-slide-track > div' ); + this.navs = this.wrapper.querySelectorAll( '.frm-tabs-navs ul > li' ); + this.slideTrackLine = this.wrapper.querySelector( '.frm-tabs-active-underline' ); + this.slideTrack = this.wrapper.querySelector( '.frm-tabs-slide-track' ); + this.slides = this.wrapper.querySelectorAll( '.frm-tabs-slide-track > div' ); this.init(); } @@ -28,7 +27,7 @@ export class frmTabsNavigator { this.initDefaultSlideTrackerWidth(); this.navs.forEach( ( nav, index ) => { nav.addEventListener( 'click', event => this.onNavClick( event, index ) ); - }); + } ); } onNavClick( event, index ) { @@ -42,15 +41,15 @@ export class frmTabsNavigator { if ( ! this.slideTrackLine.dataset.initialWidth ) { return; } - this.slideTrackLine.style.width = `${this.slideTrackLine.dataset.initialWidth}px`; + this.slideTrackLine.style.width = `${ this.slideTrackLine.dataset.initialWidth }px`; } initSlideTrackUnderline( nav, index ) { this.slideTrackLine.classList.remove( 'frm-first', 'frm-last' ); - const activeNav = 'undefined' !== typeof nav ? nav : this.navs.filter( nav => nav.classList.contains( 'frm-active' ) ) ; - this.slideTrackLine.style.transform = `translateX(${activeNav.offsetLeft}px)`; + const activeNav = 'undefined' !== typeof nav ? nav : this.navs.filter( nav => nav.classList.contains( 'frm-active' ) ); + this.slideTrackLine.style.transform = `translateX(${ activeNav.offsetLeft }px)`; this.slideTrackLine.style.width = activeNav.clientWidth + 'px'; - if ( this.navs.length === index + 1 ) { + if ( this.navs.length === index + 1 ) { this.slideTrackLine.classList.add( 'frm-last' ); return; } @@ -61,8 +60,8 @@ export class frmTabsNavigator { changeSlide( index ) { this.removeActiveClassnameFromSlides(); - const translate = index == 0 ? '0px' : `calc( ( ${( index * 100 )}% + ${parseInt( this.flexboxSlidesGap, 10 ) * index }px ) * -1 )`; - this.slideTrack.style.transform = `translateX(${translate})`; + const translate = index == 0 ? '0px' : `calc( ( ${ ( index * 100 ) }% + ${ parseInt( this.flexboxSlidesGap, 10 ) * index }px ) * -1 )`; + this.slideTrack.style.transform = `translateX(${ translate })`; if ( index in this.slides ) { this.slides[ index ].classList.add( 'frm-active' ); } diff --git a/js/src/core/events/optionBoxListener.js b/js/src/core/events/optionBoxListener.js index 4623abbc3e..4a4b3e5621 100644 --- a/js/src/core/events/optionBoxListener.js +++ b/js/src/core/events/optionBoxListener.js @@ -13,9 +13,9 @@ const OPTION_BOX_CLASS = '.frm-option-box'; export function addOptionBoxEvents() { const optionBoxes = document.querySelectorAll( OPTION_BOX_CLASS ); - optionBoxes.forEach( ( optionBox ) => { + optionBoxes.forEach( optionBox => { optionBox.addEventListener( 'click', onOptionBoxClick ); - }); + } ); } /** diff --git a/js/src/core/factory/createPageState.js b/js/src/core/factory/createPageState.js index 9ecde2c55c..a76c8a2f54 100644 --- a/js/src/core/factory/createPageState.js +++ b/js/src/core/factory/createPageState.js @@ -27,7 +27,7 @@ export function createPageState( initialState = {} ) { * @param {string} propertyName The name of the property to retrieve. * @return {*} The value of the specified property, or null if it doesn't exist. */ - const getSingleState = ( propertyName ) => { + const getSingleState = propertyName => { const value = Reflect.get( state, propertyName ); // We convert `undefined` to `null` for a consistent API. @@ -42,7 +42,7 @@ export function createPageState( initialState = {} ) { * @throws {Error} Throws an error if `newState` is not a plain object. * @return {void} */ - const setState = ( newState ) => { + const setState = newState => { if ( typeof newState !== 'object' || newState === null ) { throw new Error( 'setState: newState must be a non-null object' ); } diff --git a/js/src/core/page-skeleton/events/categoryListener.js b/js/src/core/page-skeleton/events/categoryListener.js index 265385999f..4e41ced165 100644 --- a/js/src/core/page-skeleton/events/categoryListener.js +++ b/js/src/core/page-skeleton/events/categoryListener.js @@ -20,7 +20,7 @@ export function addCategoryEvents() { const { categoryItems } = getElements(); // Attach click and keyboard event listeners to each sidebar category - categoryItems.forEach( ( category ) => { + categoryItems.forEach( category => { onClickPreventDefault( category, onCategoryClick ); category.addEventListener( 'keydown', onCategoryKeydown ); } ); @@ -32,7 +32,7 @@ export function addCategoryEvents() { * @private * @param {Event} event The click event object. */ -const onCategoryClick = ( event ) => { +const onCategoryClick = event => { const clickedCategory = event.currentTarget; const newSelectedCategory = clickedCategory.getAttribute( 'data-category' ); let { selectedCategory, selectedCategoryEl, notEmptySearchText } = diff --git a/js/src/core/ui/addProgressToCardBoxes.js b/js/src/core/ui/addProgressToCardBoxes.js index bd14bf8543..7c8b34b542 100644 --- a/js/src/core/ui/addProgressToCardBoxes.js +++ b/js/src/core/ui/addProgressToCardBoxes.js @@ -23,14 +23,14 @@ function addProgressToCardBoxes( cardBoxes ) { const progressBar = span(); const widthPercentage = ( ( index + 1 ) / cardBoxes.length ) * 100; - progressBar.style.width = `${widthPercentage}%`; + progressBar.style.width = `${ widthPercentage }%`; - const progressBarContainer = span({ + const progressBarContainer = span( { className: 'frm-card-box-progress-bar', child: progressBar - }); + } ); element.insertAdjacentElement( 'afterbegin', progressBarContainer ); - }); + } ); } export default addProgressToCardBoxes; diff --git a/js/src/core/utils/animation.js b/js/src/core/utils/animation.js index b0c03c2dde..4a726f099b 100644 --- a/js/src/core/utils/animation.js +++ b/js/src/core/utils/animation.js @@ -1,15 +1,13 @@ export class frmAnimate { - /** * Construct frmAnimate * - * @param {Element|Element[]} elements - * @param {'default'|'cascade'|'cascade-3d'} type - The animation type: default | cascade | cascade-3d - * + * @param {Element|Element[]} elements The elements to animate. + * @param {'default'|'cascade'|'cascade-3d'} type The animation type: default | cascade | cascade-3d */ constructor( elements, type = 'default' ) { this.elements = elements; - this.type = type; + this.type = type; this.prepareElements(); } @@ -26,8 +24,8 @@ export class frmAnimate { element.addEventListener( 'animationend', () => { this.resetOpacity(); element.classList.remove( 'frm-fadein-up' ); - }, { once: true }); - }); + }, { once: true } ); + } ); } /** @@ -36,15 +34,14 @@ export class frmAnimate { * ex: new frmAnimate( elements, 'cascade' ).cascadeFadeIn(); * new frmAnimate( elements, 'cascade-3d' ).cascadeFadeIn(); * - * @param {float} delay - The transition delay value. - * + * @param {float} delay The transition delay value. */ cascadeFadeIn( delay = 0.03 ) { setTimeout( () => { this.applyStyleToElements( ( element, index ) => { element.classList.remove( 'frm-animate' ); - element.style.transitionDelay = ( index + 1 ) * delay + 's'; - }); + element.style.transitionDelay = ( ( index + 1 ) * delay ) + 's'; + } ); }, 200 ); } @@ -60,7 +57,7 @@ export class frmAnimate { element.classList.add( 'frm-init-fadein-3d' ); } element.classList.add( 'frm-animate' ); - }); + } ); } resetOpacity() { diff --git a/js/src/core/utils/error.js b/js/src/core/utils/error.js index b9b792b5c8..5161691eaa 100644 --- a/js/src/core/utils/error.js +++ b/js/src/core/utils/error.js @@ -23,7 +23,7 @@ export const showFormError = ( inputId, errorId, type, message ) => { // If a message is provided, update the span element's text that matches the error type if ( message ) { - const span = errorElement.querySelector( `span[frm-error="${type}"]` ); + const span = errorElement.querySelector( `span[frm-error="${ type }"]` ); if ( span ) { span.textContent = message; } @@ -36,5 +36,5 @@ export const showFormError = ( inputId, errorId, type, message ) => { // Hide the error message when the user starts typing in the faulty input field inputElement.addEventListener( 'keyup', () => { hide( errorElement ); - }, { once: true }); + }, { once: true } ); }; diff --git a/js/src/core/utils/url.js b/js/src/core/utils/url.js index ffc90ac82f..496e1b1edc 100644 --- a/js/src/core/utils/url.js +++ b/js/src/core/utils/url.js @@ -18,7 +18,7 @@ export const getQueryParam = paramName => urlParams.get( paramName ); * @param {string} paramName The name of the query parameter to remove. * @return {string} The updated URL string. */ -export const removeQueryParam = ( paramName ) => { +export const removeQueryParam = paramName => { urlParams.delete( paramName ); url.search = urlParams.toString(); return url.toString(); @@ -36,9 +36,9 @@ export const setQueryParam = ( paramName, paramValue, updateMethod = 'pushState' urlParams.set( paramName, paramValue ); url.search = urlParams.toString(); - if ([ 'pushState', 'replaceState' ].includes( updateMethod ) ) { - const state = {[paramName]: paramValue}; - window.history[updateMethod]( state, '', url ); + if ( [ 'pushState', 'replaceState' ].includes( updateMethod ) ) { + const state = { [ paramName ]: paramValue }; + window.history[ updateMethod ]( state, '', url ); } return url.toString(); diff --git a/js/src/dashboard.js b/js/src/dashboard.js index e92df58a4d..b8a596f97e 100644 --- a/js/src/dashboard.js +++ b/js/src/dashboard.js @@ -6,9 +6,7 @@ import { frmAnimate } from 'core/utils'; import { frmTabsNavigator } from './components/class-tabs-navigator'; import { frmCounter } from './components/class-counter'; class frmDashboard { - constructor() { - this.options = { ajax: { action: 'dashboard_ajax_action', @@ -32,12 +30,12 @@ class frmDashboard { initInbox() { new frmTabsNavigator( '.frm-inbox-wrapper' ); - const userEmailInput = document.querySelector( '#frm_leave_email' ); + const userEmailInput = document.querySelector( '#frm_leave_email' ); const subscribeButton = document.querySelector( '#frm-add-my-email-address' ); subscribeButton.addEventListener( 'click', () => { this.saveSubscribedEmail( userEmailInput.value ).then(); - }); + } ); } initCounters() { @@ -58,8 +56,8 @@ class frmDashboard { if ( true === data.success ) { dashboardBanner.remove(); } - }); - }); + } ); + } ); } saveSubscribedEmail( email ) { @@ -68,12 +66,12 @@ class frmDashboard { headers: { 'Content-Type': 'application/x-www-form-urlencoded' }, - body: new URLSearchParams({ + body: new URLSearchParams( { action: this.options.ajax.action, dashboard_action: this.options.ajax.dashboardActions.saveSubscribedEmail, email: email - }) - }).then( result => result.json() ); + } ) + } ).then( result => result.json() ); } closeWelcomeBannerSaveCookieRequest() { @@ -82,15 +80,15 @@ class frmDashboard { headers: { 'Content-Type': 'application/x-www-form-urlencoded' }, - body: new URLSearchParams({ + body: new URLSearchParams( { action: this.options.ajax.action, dashboard_action: this.options.ajax.dashboardActions.welcomeBanner, banner_has_closed: 1 - }) - }).then( result => result.json() ); + } ) + } ).then( result => result.json() ); } } const frmDashboardClass = new frmDashboard(); document.addEventListener( 'DOMContentLoaded', () => { frmDashboardClass.init(); -}); +} ); diff --git a/js/src/form-templates/elements/applicationTemplatesElement.js b/js/src/form-templates/elements/applicationTemplatesElement.js index 4ae47c9674..d4a41c7bd5 100644 --- a/js/src/form-templates/elements/applicationTemplatesElement.js +++ b/js/src/form-templates/elements/applicationTemplatesElement.js @@ -21,13 +21,13 @@ const { tag, div, span, a, img } = window.frmDom; let applicationTemplates; // Base URL for the thumbnail images of applications -const thumbnailBaseURL = `${PLUGIN_URL}/images/applications/thumbnails`; +const thumbnailBaseURL = `${ PLUGIN_URL }/images/applications/thumbnails`; /** * Create and return the application templates HTML element. * * @param {Object[]} applications Array of application objects. - * @return {HTMLElement|null} The application templates element or null if no applications are provided. + * @return {void} */ export function createApplicationTemplates( applications ) { if ( ! applications || ! applications.length ) { @@ -36,20 +36,20 @@ export function createApplicationTemplates( applications ) { const templateItems = applications.map( template => createTemplateItem( template ) ); - applicationTemplates = div({ - id: `${PREFIX}-applications`, + applicationTemplates = div( { + id: `${ PREFIX }-applications`, className: HIDDEN_CLASS, children: [ tag( 'h2', { text: __( 'Application Templates' ), className: 'frm-text-sm frm-mb-sm' - }), + } ), tag( 'ul', { - className: `${PREFIX}-list frm-list-grid-layout`, + className: `${ PREFIX }-list frm-list-grid-layout`, children: templateItems - }) + } ) ] - }); + } ); } /** @@ -61,42 +61,43 @@ export function createApplicationTemplates( applications ) { */ function createTemplateItem( template ) { const { name, key, hasLiteThumbnail, isWebp } = template; - const thumbnailURL = hasLiteThumbnail ? - ( isWebp ? `${thumbnailBaseURL}/${key}.webp` : `${thumbnailBaseURL}/${key}.png` ) : - `${thumbnailBaseURL}/placeholder.svg`; + // eslint-disable-next-line no-nested-ternary + const thumbnailURL = hasLiteThumbnail + ? ( isWebp ? `${ thumbnailBaseURL }/${ key }.webp` : `${ thumbnailBaseURL }/${ key }.png` ) + : `${ thumbnailBaseURL }/placeholder.svg`; return tag( 'li', { className: 'frm-card-item', data: { - href: `${applicationsUrl}&triggerViewApplicationModal=1&template=${key}`, + href: `${ applicationsUrl }&triggerViewApplicationModal=1&template=${ key }`, 'frm-search-text': name.toLowerCase() }, children: [ - div({ - className: `${PREFIX}-item-icon`, - child: img({ src: thumbnailURL }) - }), - div({ - className: `${PREFIX}-item-body`, + div( { + className: `${ PREFIX }-item-icon`, + child: img( { src: thumbnailURL } ) + } ), + div( { + className: `${ PREFIX }-item-body`, children: [ - span({ + span( { text: __( 'Ready Made Solution', 'formidable' ), className: 'frm-meta-tag frm-orange-tag frm-text-xs' - }), + } ), tag( 'h3', { text: name, className: 'frm-text-sm frm-font-medium frm-m-0' - }), - a({ + } ), + a( { text: __( 'See all applications', 'formidable' ), className: 'frm-text-xs frm-font-semibold', href: applicationsUrl - }) + } ) ] - }) + } ) ] - }); -}; + } ); +} /** * Inject application Templates elements into the DOM and the elements object. @@ -112,10 +113,10 @@ export function addApplicationTemplatesElement() { elements.bodyContent.appendChild( applicationTemplates ); - addElements({ + addElements( { applicationTemplates, applicationTemplatesTitle: applicationTemplates.querySelector( 'h2' ), - applicationTemplatesList: applicationTemplates.querySelector( `.${PREFIX}-list` ), + applicationTemplatesList: applicationTemplates.querySelector( `.${ PREFIX }-list` ), applicationTemplateItems: applicationTemplates.querySelectorAll( '.frm-card-item' ) - }); + } ); } diff --git a/js/src/form-templates/elements/elements.js b/js/src/form-templates/elements/elements.js index 112fdd0a07..e946390b7e 100644 --- a/js/src/form-templates/elements/elements.js +++ b/js/src/form-templates/elements/elements.js @@ -9,48 +9,48 @@ import { getElements, addElements, PREFIX as SKELETON_PREFIX } from 'core/page-s import { PREFIX, VIEW_SLUGS } from '../shared'; const { bodyContent } = getElements(); -const templatesList = document.getElementById( `${PREFIX}-list` ); -const customTemplatesSection = document.getElementById( `${PREFIX}-custom-list-section` ); +const templatesList = document.getElementById( `${ PREFIX }-list` ); +const customTemplatesSection = document.getElementById( `${ PREFIX }-custom-list-section` ); const favoritesCategory = document.querySelector( - `.${SKELETON_PREFIX}-cat[data-category="${VIEW_SLUGS.FAVORITES}"]` + `.${ SKELETON_PREFIX }-cat[data-category="${ VIEW_SLUGS.FAVORITES }"]` ); -const modal = document.getElementById( `${PREFIX}-modal` ); +const modal = document.getElementById( `${ PREFIX }-modal` ); -addElements({ +addElements( { // Body elements headerCancelButton: document.getElementById( 'frm-publishing' )?.querySelector( 'a' ), - createFormButton: document.getElementById( `${PREFIX}-create-form` ), - pageTitle: document.getElementById( `${PREFIX}-page-title` ), - pageTitleText: document.getElementById( `${PREFIX}-page-title-text` ), - pageTitleDivider: document.getElementById( `${PREFIX}-page-title-divider` ), - upsellBanner: document.getElementById( `${PREFIX}-upsell-banner` ), - extraTemplateCountElements: document.querySelectorAll( `.${PREFIX}-extra-templates-count` ), + createFormButton: document.getElementById( `${ PREFIX }-create-form` ), + pageTitle: document.getElementById( `${ PREFIX }-page-title` ), + pageTitleText: document.getElementById( `${ PREFIX }-page-title-text` ), + pageTitleDivider: document.getElementById( `${ PREFIX }-page-title-divider` ), + upsellBanner: document.getElementById( `${ PREFIX }-upsell-banner` ), + extraTemplateCountElements: document.querySelectorAll( `.${ PREFIX }-extra-templates-count` ), // Templates elements templatesList, templateItems: templatesList.querySelectorAll( '.frm-card-item' ), - availableTemplateItems: templatesList.querySelectorAll( `.frm-card-item:not(.${PREFIX}-locked-item)` ), - twinFeaturedTemplateItems: templatesList.querySelectorAll( `.${PREFIX}-featured-item` ), - featuredTemplatesList: document.getElementById( `${PREFIX}-featured-list` ), + availableTemplateItems: templatesList.querySelectorAll( `.frm-card-item:not(.${ PREFIX }-locked-item)` ), + twinFeaturedTemplateItems: templatesList.querySelectorAll( `.${ PREFIX }-featured-item` ), + featuredTemplatesList: document.getElementById( `${ PREFIX }-featured-list` ), // Custom Templates Section elements customTemplatesSection, customTemplateItems: customTemplatesSection.querySelectorAll( '.frm-card-item' ), - customTemplatesTitle: document.getElementById( `${PREFIX}-custom-list-title` ), - customTemplatesList: document.getElementById( `${PREFIX}-custom-list` ), + customTemplatesTitle: document.getElementById( `${ PREFIX }-custom-list-title` ), + customTemplatesList: document.getElementById( `${ PREFIX }-custom-list` ), // Sidebar elements favoritesCategory, favoritesCategoryCountEl: favoritesCategory?.querySelector( - `.${SKELETON_PREFIX}-cat-count` + `.${ SKELETON_PREFIX }-cat-count` ), availableTemplatesCategory: document.querySelector( - `.${SKELETON_PREFIX}-cat[data-category="${VIEW_SLUGS.AVAILABLE_TEMPLATES}"]` + `.${ SKELETON_PREFIX }-cat[data-category="${ VIEW_SLUGS.AVAILABLE_TEMPLATES }"]` ), // Modal elements modal, - modalItems: modal?.querySelectorAll( `.${PREFIX}-modal-item` ), + modalItems: modal?.querySelectorAll( `.${ PREFIX }-modal-item` ), // Create New Template Modal showCreateTemplateModalButton: document.getElementById( 'frm-show-create-template-modal' ), createTemplateModal: document.getElementById( 'frm-create-template-modal' ), @@ -75,6 +75,6 @@ addElements({ // Add children of the bodyContent to the elements object. bodyContentChildren: bodyContent?.children -}); +} ); export { getElements, addElements }; diff --git a/js/src/form-templates/events/applicationTemplateListener.js b/js/src/form-templates/events/applicationTemplateListener.js index 530e937538..23809f3a9c 100644 --- a/js/src/form-templates/events/applicationTemplateListener.js +++ b/js/src/form-templates/events/applicationTemplateListener.js @@ -18,7 +18,7 @@ export function addApplicationTemplateEvents() { // Attach click event listener applicationTemplateItems.forEach( template => { template.addEventListener( 'click', onApplicationTemplateClick ); - }); + } ); } /** @@ -28,7 +28,7 @@ export function addApplicationTemplateEvents() { * @param {Event} event The click event object. * @return {void} */ -const onApplicationTemplateClick = ( event ) => { +const onApplicationTemplateClick = event => { // Check if the clicked element is an anchor tag if ( event.target.closest( 'a' ) ) { return; diff --git a/js/src/form-templates/events/createFormButtonListener.js b/js/src/form-templates/events/createFormButtonListener.js index ae32e68c68..cfad29e0af 100644 --- a/js/src/form-templates/events/createFormButtonListener.js +++ b/js/src/form-templates/events/createFormButtonListener.js @@ -29,7 +29,6 @@ function addCreateFormButtonEvents() { * Handles the click event on the "Create a blank form" button. * * @private - * @param {Event} event The click event object. * @return {void} */ const onCreateFormButtonClick = () => { diff --git a/js/src/form-templates/events/createTemplateListeners.js b/js/src/form-templates/events/createTemplateListeners.js index 1862712425..e0871d5587 100644 --- a/js/src/form-templates/events/createTemplateListeners.js +++ b/js/src/form-templates/events/createTemplateListeners.js @@ -10,7 +10,7 @@ import { onClickPreventDefault } from 'core/utils'; /** * Internal dependencies -*/ + */ import { getElements } from '../elements'; import { getState } from '../shared'; import { showCreateTemplateModal } from '../ui'; @@ -44,7 +44,6 @@ function addCreateTemplateEvents() { * Handles the click event on the 'Create Template' button, showing the 'Create New Template' modal. * * @private - * @param {Event} event The click event object. * @return {void} */ const onShowCreateTemplateModalButtonClick = () => { @@ -60,7 +59,6 @@ const onShowCreateTemplateModalButtonClick = () => { * Handles changes in the forms selection dropdown for creating a new template. * * @private - * @param {Event} event The change event object. * @return {void} */ const onFormsSelectChange = () => { @@ -74,11 +72,11 @@ const onFormsSelectChange = () => { toggleDisableModalElements( false ); - const selectedOption = formsSelect.options[formsSelect.selectedIndex]; + const selectedOption = formsSelect.options[ formsSelect.selectedIndex ]; const formDescription = selectedOption.dataset.description.trim(); let formName = selectedOption.dataset.name.trim(); - const templateString = ` ${__( 'Template', 'formidable' )}`; + const templateString = ` ${ __( 'Template', 'formidable' ) }`; if ( ! formName.endsWith( templateString ) ) { formName += templateString; } @@ -95,7 +93,7 @@ const onFormsSelectChange = () => { * @param {boolean} shouldDisable True to disable, false to enable. * @return {void} */ -const toggleDisableModalElements = ( shouldDisable ) => { +const toggleDisableModalElements = shouldDisable => { const { createTemplateName, createTemplateDescription, createTemplateButton } = getElements(); // Toggle the disabled attribute for input and textarea @@ -104,7 +102,7 @@ const toggleDisableModalElements = ( shouldDisable ) => { if ( shouldDisable ) { element.value = ''; // Clear the content for input and textarea } - }); + } ); // Toggle the disabled class for the button createTemplateButton.classList.toggle( 'disabled', shouldDisable ); @@ -114,7 +112,6 @@ const toggleDisableModalElements = ( shouldDisable ) => { * Handles the click event on the 'Create Template' button to create a new template. * * @private - * @param {Event} event The click event object. * @return {void} */ const onCreateTemplateButtonClick = () => { diff --git a/js/src/form-templates/events/favoriteButtonListener.js b/js/src/form-templates/events/favoriteButtonListener.js index 752d100d2e..5cb447fc61 100644 --- a/js/src/form-templates/events/favoriteButtonListener.js +++ b/js/src/form-templates/events/favoriteButtonListener.js @@ -11,8 +11,8 @@ import { PREFIX, getState, setSingleState } from '../shared'; import { showFavoritesEmptyState } from '../ui'; import { isFavoriteTemplate, isCustomTemplate, isFeaturedTemplate, isFavoritesCategory } from '../utils'; -const FAVORITE_BUTTON_CLASS = `.${PREFIX}-item-favorite-button`; -const HEART_ICON_SELECTOR = `${FAVORITE_BUTTON_CLASS} use`; +const FAVORITE_BUTTON_CLASS = `.${ PREFIX }-item-favorite-button`; +const HEART_ICON_SELECTOR = `${ FAVORITE_BUTTON_CLASS } use`; const FILLED_HEART_ICON = '#frm_heart_solid_icon'; const LINEAR_HEART_ICON = '#frm_heart_icon'; const OPERATION = { @@ -41,7 +41,7 @@ function addFavoriteButtonEvents() { * @param {Event} event The click event object. * @return {void} */ -const onFavoriteButtonClick = ( event ) => { +const onFavoriteButtonClick = event => { const favoriteButton = event.currentTarget; const { templatesList, featuredTemplatesList, favoritesCategoryCountEl, customTemplatesTitle } = getElements(); @@ -60,19 +60,19 @@ const onFavoriteButtonClick = ( event ) => { */ let twinFeaturedTemplate = null; - template.classList.toggle( `${PREFIX}-favorite-item`, ! isFavorited ); + template.classList.toggle( `${ PREFIX }-favorite-item`, ! isFavorited ); if ( isTemplateFeatured ) { - const templateList = template.closest( `#${PREFIX}-list` ) ? - featuredTemplatesList : - templatesList; + const templateList = template.closest( `#${ PREFIX }-list` ) + ? featuredTemplatesList + : templatesList; if ( templateList ) { twinFeaturedTemplate = templateList.querySelector( - `.frm-card-item[data-id="${templateId}"]` + `.frm-card-item[data-id="${ templateId }"]` ); // Toggle twin template's favorite status twinFeaturedTemplate.classList.toggle( - `${PREFIX}-favorite-item`, + `${ PREFIX }-favorite-item`, ! isFavorited ); } @@ -90,14 +90,14 @@ const onFavoriteButtonClick = ( event ) => { if ( OPERATION.ADD === currentOperation ) { // Increment favorite counts ++favoritesCount.total; - isTemplateCustom ? ++favoritesCount.custom : ++favoritesCount.default; + isTemplateCustom ? ++favoritesCount.custom : ++favoritesCount.default; // eslint-disable-line no-unused-expressions // Set heart icon to filled heartIcon.setAttribute( 'xlink:href', FILLED_HEART_ICON ); twinTemplateHeartIcon?.setAttribute( 'xlink:href', FILLED_HEART_ICON ); } else { // Decrement favorite counts --favoritesCount.total; - isTemplateCustom ? --favoritesCount.custom : --favoritesCount.default; + isTemplateCustom ? --favoritesCount.custom : --favoritesCount.default; // eslint-disable-line no-unused-expressions // Set heart icon to outline heartIcon.setAttribute( 'xlink:href', LINEAR_HEART_ICON ); twinTemplateHeartIcon?.setAttribute( 'xlink:href', LINEAR_HEART_ICON ); @@ -136,7 +136,7 @@ const onFavoriteButtonClick = ( event ) => { * @param {string} id The template ID. * @param {string} operation The operation to perform ('add' or 'remove'). * @param {boolean} isCustom Flag indicating whether the template is custom. - * @return {Promise} + * @return {Promise} The result of the server-side update. */ function updateFavoriteTemplate( id, operation, isCustom ) { const formData = new FormData(); diff --git a/js/src/form-templates/events/index.js b/js/src/form-templates/events/index.js index 9400f0db6a..677494d8fc 100644 --- a/js/src/form-templates/events/index.js +++ b/js/src/form-templates/events/index.js @@ -23,7 +23,7 @@ export function addEventListeners() { wp.hooks.addAction( 'frmPage.onCategoryClick', 'frmFormTemplates', selectedCategory => { // Display templates of the selected category showSelectedCategory( selectedCategory ); - }); + } ); addCreateFormButtonEvents(); addFavoriteButtonEvents(); diff --git a/js/src/form-templates/events/searchListener.js b/js/src/form-templates/events/searchListener.js index 3987a77633..184b184a02 100644 --- a/js/src/form-templates/events/searchListener.js +++ b/js/src/form-templates/events/searchListener.js @@ -36,7 +36,7 @@ function addSearchEvents() { * @param {Event} event The event object (input, search, or change event). * @return {void} */ -function handleSearchResult({ foundSomething, notEmptySearchText }, event ) { +function handleSearchResult( { foundSomething, notEmptySearchText }, event ) { // Prevent double calls as window.frmDom.search.init attaches both 'input' and 'search' events, // triggering this method twice on 'x' button click. if ( event && event.type === 'search' && event.target.value === '' ) { @@ -51,7 +51,7 @@ function handleSearchResult({ foundSomething, notEmptySearchText }, event ) { // Revert to 'All Templates' if search and selected category are both empty if ( ! state.notEmptySearchText && ! state.selectedCategory ) { allItemsCategory.dispatchEvent( - new Event( 'click', { bubbles: true }) + new Event( 'click', { bubbles: true } ) ); return; diff --git a/js/src/form-templates/events/useTemplateButtonListener.js b/js/src/form-templates/events/useTemplateButtonListener.js index 865239fd39..28438698cd 100644 --- a/js/src/form-templates/events/useTemplateButtonListener.js +++ b/js/src/form-templates/events/useTemplateButtonListener.js @@ -12,7 +12,7 @@ import { isCustomTemplate, isLockedTemplate } from '../utils'; * @return {void} */ function addUseTemplateButtonEvents() { - const useTemplateButtons = document.querySelectorAll( `.${PREFIX}-use-template-button` ); + const useTemplateButtons = document.querySelectorAll( `.${ PREFIX }-use-template-button` ); // Attach click event listeners to each use template button useTemplateButtons.forEach( useTemplateButton => @@ -27,7 +27,7 @@ function addUseTemplateButtonEvents() { * @param {Event} event The click event object. * @return {void} */ -const onUseTemplateButtonClick = ( event ) => { +const onUseTemplateButtonClick = event => { const useTemplateButton = event.currentTarget; const template = useTemplateButton.closest( '.frm-card-item' ); diff --git a/js/src/form-templates/index.js b/js/src/form-templates/index.js index 2e840021f4..b08c8d0f2c 100644 --- a/js/src/form-templates/index.js +++ b/js/src/form-templates/index.js @@ -18,7 +18,7 @@ domReady( () => { wp.hooks.doAction( 'frmFormTemplates.beforeInitialize', { getState, setState - }); + } ); // Initialize the form templates initializeFormTemplates(); @@ -31,7 +31,7 @@ domReady( () => { wp.hooks.doAction( 'frmFormTemplates.afterInitialize', { getState, setState - }); + } ); /** * Trigger a specific action to interact with the hidden form '#frm-new-template', @@ -40,4 +40,4 @@ domReady( () => { * @param {jQuery} $form The jQuery object containing the hidden form element. */ wp.hooks.doAction( 'frm_new_form_modal_form', jQuery( '#frm-new-template' ) ); -}); +} ); diff --git a/js/src/form-templates/shared/pageState.js b/js/src/form-templates/shared/pageState.js index b41af27778..7d3045bbac 100644 --- a/js/src/form-templates/shared/pageState.js +++ b/js/src/form-templates/shared/pageState.js @@ -12,12 +12,12 @@ const { templatesCount, favoritesCount, customCount } = window.frmFormTemplatesV const { availableTemplateItems } = getElements(); const availableTemplatesCount = availableTemplateItems.length; -setState({ +setState( { availableTemplatesCount, customCount: Number( customCount ), extraTemplatesCount: templatesCount - availableTemplatesCount, favoritesCount, selectedTemplate: false, -}); +} ); export { getState, getSingleState, setState, setSingleState }; diff --git a/js/src/form-templates/templates/categorizeTemplates.js b/js/src/form-templates/templates/categorizeTemplates.js index 1639d959e1..58c971c790 100644 --- a/js/src/form-templates/templates/categorizeTemplates.js +++ b/js/src/form-templates/templates/categorizeTemplates.js @@ -19,12 +19,12 @@ export function buildCategorizedTemplates() { categories.forEach( category => { // Initialize the category array if not already done - if ( ! categorizedTemplates[ category ]) { + if ( ! categorizedTemplates[ category ] ) { categorizedTemplates[ category ] = []; } // Add the template to the appropriate category categorizedTemplates[ category ].push( template ); - }); - }); + } ); + } ); } diff --git a/js/src/form-templates/ui/initializeModal.js b/js/src/form-templates/ui/initializeModal.js index 4771757c2d..1ec55d2982 100644 --- a/js/src/form-templates/ui/initializeModal.js +++ b/js/src/form-templates/ui/initializeModal.js @@ -18,12 +18,12 @@ export async function initializeModal() { } // Customize the confirm modal appearance: adjusting its width and vertical position - wp.hooks.addAction( 'frmAdmin.beforeOpenConfirmModal', 'frmFormTemplates', ( options ) => { + wp.hooks.addAction( 'frmAdmin.beforeOpenConfirmModal', 'frmFormTemplates', options => { const { $info: confirmModal } = options; confirmModal.dialog( 'option', 'width', MODAL_SIZES.CREATE_TEMPLATE ); offsetModalY( confirmModal, '103px' ); - }); + } ); } /** diff --git a/js/src/form-templates/ui/pageTitle.js b/js/src/form-templates/ui/pageTitle.js index 643292935d..7bde4c34b7 100644 --- a/js/src/form-templates/ui/pageTitle.js +++ b/js/src/form-templates/ui/pageTitle.js @@ -20,7 +20,7 @@ export function updatePageTitle( title ) { const newTitle = title || - getSingleState( 'selectedCategoryEl' ).querySelector( `.${SKELETON_PREFIX}-cat-text` ).textContent; + getSingleState( 'selectedCategoryEl' ).querySelector( `.${ SKELETON_PREFIX }-cat-text` ).textContent; pageTitleText.textContent = newTitle; } diff --git a/js/src/form-templates/ui/searchState.js b/js/src/form-templates/ui/searchState.js index 5864686e3e..6d56ae57a0 100644 --- a/js/src/form-templates/ui/searchState.js +++ b/js/src/form-templates/ui/searchState.js @@ -36,11 +36,11 @@ export function showSearchState( notEmptySearchText ) { // Update the page title and display relevant elements updatePageTitle( __( 'Search Result', 'formidable' ) ); - showElements([ pageTitle, templatesList, applicationTemplates ]); + showElements( [ pageTitle, templatesList, applicationTemplates ] ); // Smoothly display the updated UI elements bodyContentAnimate.fadeIn(); -}; +} /** * Displays search results based on search outcome. @@ -65,10 +65,10 @@ export function displaySearchElements( foundSomething ) { const { templatesList, applicationTemplates, applicationTemplatesTitle, applicationTemplatesList } = getElements(); - showElements([ templatesList, applicationTemplates, applicationTemplatesTitle ]); + showElements( [ templatesList, applicationTemplates, applicationTemplatesTitle ] ); if ( templatesList.offsetHeight === 0 ) { - hideElements([ templatesList, applicationTemplatesTitle ]); + hideElements( [ templatesList, applicationTemplatesTitle ] ); } if ( applicationTemplatesList?.offsetHeight === 0 ) { diff --git a/js/src/form-templates/ui/setupInitialView.js b/js/src/form-templates/ui/setupInitialView.js index 519ac84546..71d5da0703 100644 --- a/js/src/form-templates/ui/setupInitialView.js +++ b/js/src/form-templates/ui/setupInitialView.js @@ -37,7 +37,7 @@ function setupInitialView() { // Set the 'Available Templates' count if it is present if ( availableTemplatesCategory ) { const { availableTemplatesCount } = getState(); - availableTemplatesCategory.querySelector( `.${SKELETON_PREFIX}-cat-count` ).textContent = availableTemplatesCount; + availableTemplatesCategory.querySelector( `.${ SKELETON_PREFIX }-cat-count` ).textContent = availableTemplatesCount; } // Update extra templates count diff --git a/js/src/form-templates/ui/showEmptyState.js b/js/src/form-templates/ui/showEmptyState.js index b6a141dd74..94e1f3016e 100644 --- a/js/src/form-templates/ui/showEmptyState.js +++ b/js/src/form-templates/ui/showEmptyState.js @@ -27,7 +27,7 @@ export function showSearchEmptyState() { if ( VIEW_SLUGS.SEARCH === emptyState.dataset?.view ) { if ( notEmptySearchText ) { show( emptyState ); - hideElements([ pageTitle, applicationTemplates ]); + hideElements( [ pageTitle, applicationTemplates ] ); } else { hide( emptyState ); emptyState.removeAttribute( 'data-view' ); @@ -49,9 +49,9 @@ export function showSearchEmptyState() { emptyStateButton.textContent = __( 'Start from Scratch', 'formidable' ); // Display the empty state - hideElements([ pageTitle, applicationTemplates ]); - showElements([ emptyState, emptyStateButton ]); -}; + hideElements( [ pageTitle, applicationTemplates ] ); + showElements( [ emptyState, emptyStateButton ] ); +} /** * Display the favorites-empty state. @@ -73,9 +73,9 @@ export function showFavoritesEmptyState() { ); // Display the empty state - hideElements([ pageTitle, emptyStateButton ]); + hideElements( [ pageTitle, emptyStateButton ] ); show( emptyState ); -}; +} /** * Display the custom-empty state. @@ -99,8 +99,8 @@ export function showCustomTemplatesEmptyState() { // Display the empty state hide( pageTitle ); - showElements([ emptyState, emptyStateButton ]); -}; + showElements( [ emptyState, emptyStateButton ] ); +} /** * Display the available-templates-empty state. @@ -118,11 +118,12 @@ export function showAvailableTemplatesEmptyState() { const { extraTemplatesCount } = getState(); emptyStateTitle.textContent = __( 'No Templates Available', 'formidable' ); emptyStateText.textContent = sprintf( + // translators: %s is the number of extra templates available __( 'Upgrade to PRO for %s+ options or explore Free Templates.', 'formidable' ), extraTemplatesCount ); // Display the empty state - hideElements([ pageTitle, emptyStateButton ]); + hideElements( [ pageTitle, emptyStateButton ] ); show( emptyState ); -}; +} diff --git a/js/src/form-templates/ui/showHeaderCancelButton.js b/js/src/form-templates/ui/showHeaderCancelButton.js index 965055dd3c..7b8281fc14 100644 --- a/js/src/form-templates/ui/showHeaderCancelButton.js +++ b/js/src/form-templates/ui/showHeaderCancelButton.js @@ -16,4 +16,4 @@ import { getElements } from '../elements'; export function showHeaderCancelButton() { const { headerCancelButton } = getElements(); new frmAnimate( headerCancelButton ).fadeIn(); -}; +} diff --git a/js/src/form-templates/ui/showModal.js b/js/src/form-templates/ui/showModal.js index e97366b935..3082891876 100644 --- a/js/src/form-templates/ui/showModal.js +++ b/js/src/form-templates/ui/showModal.js @@ -43,7 +43,7 @@ export function showLockedTemplateModal( template ) { * @param {Function} executePreOpen The function to be executed before opening the modal dialog. * @return {Function} A higher-order function that can be invoked to display the modal dialog. */ -const showModal = executePreOpen => async( ...params ) => { +const showModal = executePreOpen => async ( ...params ) => { const dialogWidget = getModalWidget(); if ( ! dialogWidget ) { return; @@ -68,7 +68,7 @@ const upgradablePlans = { /** * Display the modal dialog to prompt the user to upgrade their account. * - * @param {string} plan Current plan name + * @param {string} plan Current plan name * @param {HTMLElement} template The template element * @return {void} */ @@ -82,7 +82,7 @@ export const showUpgradeModal = showModal( ( plan, template ) => { // Update plan icons and their availability upgradeModalPlansIcons.forEach( icon => { const planType = icon.dataset.plan; - const shouldDisplayCheck = upgradablePlans[plan].includes( planType ); + const shouldDisplayCheck = upgradablePlans[ plan ].includes( planType ); // Toggle icon class based on plan availability icon.classList.toggle( 'frm_green', shouldDisplayCheck ); @@ -90,14 +90,14 @@ export const showUpgradeModal = showModal( ( plan, template ) => { // Update SVG icon const svg = icon.querySelector( 'svg > use' ); svg.setAttribute( 'xlink:href', shouldDisplayCheck ? '#frm_checkmark_icon' : '#frm_close_icon' ); - }); + } ); // Append template slug to the upgrade modal link URL - const templateSlug = template.dataset.slug ? `-${template.dataset.slug}` : ''; + const templateSlug = template.dataset.slug ? `-${ template.dataset.slug }` : ''; upgradeModalLink.href = upgradeLink + templateSlug; show( upgradeModal ); -}); +} ); /** * Display the modal dialog to prompt the user to renew their account. @@ -107,7 +107,7 @@ export const showUpgradeModal = showModal( ( plan, template ) => { export const showRenewAccountModal = showModal( () => { const { renewAccountModal } = getElements(); show( renewAccountModal ); -}); +} ); /** * Displays a modal dialog prompting the user to create a new template. @@ -120,4 +120,4 @@ export const showCreateTemplateModal = showModal( () => { const { createTemplateModal } = getElements(); show( createTemplateModal ); -}); +} ); diff --git a/js/src/form-templates/ui/showSelectedCategory.js b/js/src/form-templates/ui/showSelectedCategory.js index c729103552..24861f98e4 100644 --- a/js/src/form-templates/ui/showSelectedCategory.js +++ b/js/src/form-templates/ui/showSelectedCategory.js @@ -45,7 +45,7 @@ export function showSelectedCategory( selectedCategory ) { break; default: hideElements( templateItems ); // Clear the view for new content - showElements([ templatesList, ...categorizedTemplates[ selectedCategory ] ]); + showElements( [ templatesList, ...categorizedTemplates[ selectedCategory ] ] ); break; } } @@ -66,8 +66,8 @@ export function showAllTemplates() { applicationTemplates } = getElements(); - showElements([ ...bodyContentChildren, ...templateItems ]); - hideElements([ pageTitleDivider, ...twinFeaturedTemplateItems, customTemplatesSection, emptyState, applicationTemplates ]); + showElements( [ ...bodyContentChildren, ...templateItems ] ); + hideElements( [ pageTitleDivider, ...twinFeaturedTemplateItems, customTemplatesSection, emptyState, applicationTemplates ] ); } /** @@ -99,7 +99,7 @@ export function showFavoriteTemplates() { const elementsToShow = []; // Get all favorite items from the DOM and add the elements to show - const favoriteItems = bodyContent.querySelectorAll( `.${PREFIX}-favorite-item` ); + const favoriteItems = bodyContent.querySelectorAll( `.${ PREFIX }-favorite-item` ); elementsToShow.push( ...favoriteItems ); // Add default favorites if available @@ -151,7 +151,7 @@ export function showCustomTemplates() { } = getElements(); hide( customTemplatesTitle ); - showElements([ showCreateTemplateModalButton, pageTitleDivider, customTemplatesSection, customTemplatesList, ...customTemplateItems ]); + showElements( [ showCreateTemplateModalButton, pageTitleDivider, customTemplatesSection, customTemplatesList, ...customTemplateItems ] ); } /** @@ -170,7 +170,7 @@ export function showAvailableTemplates() { const { templatesList, templateItems, availableTemplateItems } = getElements(); hideElements( templateItems ); // Clear the view for new content - showElements([ templatesList, ...availableTemplateItems ]); + showElements( [ templatesList, ...availableTemplateItems ] ); } export default showSelectedCategory; diff --git a/js/src/form-templates/utils/validation.js b/js/src/form-templates/utils/validation.js index 3cdb2e1592..03d53ba9b4 100644 --- a/js/src/form-templates/utils/validation.js +++ b/js/src/form-templates/utils/validation.js @@ -40,7 +40,7 @@ export const isCustomCategory = category => VIEW_SLUGS.CUSTOM === category; * @return {boolean} True if the template is a favorite, otherwise false. */ export const isFavoriteTemplate = template => - isHTMLElement( template ) ? template.classList.contains( `${PREFIX}-favorite-item` ) : false; + isHTMLElement( template ) ? template.classList.contains( `${ PREFIX }-favorite-item` ) : false; /** * Checks if a template is custom. @@ -49,7 +49,7 @@ export const isFavoriteTemplate = template => * @return {boolean} True if the template is custom, otherwise false. */ export const isCustomTemplate = template => - isHTMLElement( template ) ? template.classList.contains( `${PREFIX}-custom-item` ) : false; + isHTMLElement( template ) ? template.classList.contains( `${ PREFIX }-custom-item` ) : false; /** * Checks if a template is featured. @@ -67,4 +67,4 @@ export const isFeaturedTemplate = template => * @return {boolean} True if the template is locked, otherwise false. */ export const isLockedTemplate = template => - isHTMLElement( template ) ? template.classList.contains( `${PREFIX}-locked-item` ) : false; + isHTMLElement( template ) ? template.classList.contains( `${ PREFIX }-locked-item` ) : false; diff --git a/js/src/form/block.js b/js/src/form/block.js index cfadb0c96d..b56274fdcd 100755 --- a/js/src/form/block.js +++ b/js/src/form/block.js @@ -78,9 +78,9 @@ registerBlockType( 'formidable/simple-form', { } = props; const { formId } = attributes; return ( - ( formId === undefined ) ? - '' : - + ( formId === undefined ) + ? '' + : ); diff --git a/js/src/form/calculator.js b/js/src/form/calculator.js index b82980fe15..e8feed3b73 100644 --- a/js/src/form/calculator.js +++ b/js/src/form/calculator.js @@ -53,7 +53,7 @@ registerBlockType( 'formidable/calculator', {
                    { __( 'This site does not have any calculator forms.', 'formidable' ) } -
                    +
                    { __( 'Upgrade Formidable Forms.', 'formidable' ) } diff --git a/js/src/form/graph.js b/js/src/form/graph.js index 28bbdd1f1f..58a2ab7324 100644 --- a/js/src/form/graph.js +++ b/js/src/form/graph.js @@ -16,7 +16,7 @@ import FormidableIcon from '../common/components/icon'; const UpgradeNotice = ( { text, buttonText, link } ) => ( { text } -
                    +
                    { buttonText } @@ -30,7 +30,7 @@ import FormidableIcon from '../common/components/icon'; description: __( 'Display a chart or graph', 'formidable' ), icon: ( - + ), category: 'design', diff --git a/js/src/form/modal.js b/js/src/form/modal.js index 9e4299e2eb..f41dcacd8d 100644 --- a/js/src/form/modal.js +++ b/js/src/form/modal.js @@ -9,7 +9,7 @@ const { Notice } = wp.components; const UpgradeNotice = ( { text, buttonText, link } ) => ( { text } -
                    +
                    { buttonText } diff --git a/js/src/form/views.js b/js/src/form/views.js index 83055c7bef..72bf3186f5 100644 --- a/js/src/form/views.js +++ b/js/src/form/views.js @@ -24,29 +24,28 @@ registerBlockType( 'formidable/simple-view', { ], edit: () => { - - const [ addonActivateButton, updateAddonActivateButton ] = useState({ + const [ addonActivateButton, updateAddonActivateButton ] = useState( { // eslint-disable-line react-hooks/rules-of-hooks defaultClassname: 'frm-activate-addon frm-button-primary button button-primary', - loadingClassname: buttonStyles['frm-loading'], + loadingClassname: buttonStyles[ 'frm-loading' ], classnames: 'frm-activate-addon frm-button-primary button button-primary', label: ! blockData.viewsAddon.installed && blockData.viewsAddon.hasAccess ? __( 'Install', 'formidable' ) : __( 'Activate', 'formidable' ), isLoading: false - }); + } ); const activateViewsAddon = () => { if ( true === addonActivateButton.isLoading ) { return; } - updateAddonActivateButton({ ...addonActivateButton, isLoading: true, classnames: addonActivateButton.defaultClassname + ' ' + addonActivateButton.loadingClassname }); + updateAddonActivateButton( { ...addonActivateButton, isLoading: true, classnames: addonActivateButton.defaultClassname + ' ' + addonActivateButton.loadingClassname } ); if ( ! blockData.viewsAddon.installed && blockData.viewsAddon.hasAccess ) { frmAddonAPI.toggleAddonState( 'frm_install_addon', blockData.viewsAddon.url ).then( () => { window.location.reload(); - }); + } ); return; } frmAddonAPI.toggleAddonState( 'frm_activate_addon', 'formidable-views/formidable-views.php' ).then( () => { window.location.reload(); - }); + } ); }; const blockName = __( 'Formidable Views', 'formidable' ); @@ -68,9 +67,9 @@ registerBlockType( 'formidable/simple-view', {
                    { blockName }
                    - { ! blockData.viewsAddon.hasAccess && + { ! blockData.viewsAddon.hasAccess && -
                    +
                    { __( 'Effortlessly transform form data into webpages with Views, the only integrated form & application builder.', 'formidable' ) }

                    @@ -82,7 +81,7 @@ registerBlockType( 'formidable/simple-view', { } { blockData.viewsAddon.hasAccess && -
                    +
                    { __( 'Effortlessly transform form data into webpages with Views, the only integrated form & application builder.', 'formidable' ) }

                    @@ -97,4 +96,4 @@ registerBlockType( 'formidable/simple-view', {
                    ); } -}); +} ); diff --git a/js/src/onboarding-wizard/dataUtils/index.js b/js/src/onboarding-wizard/dataUtils/index.js index 71422b7667..5c2b2923f9 100644 --- a/js/src/onboarding-wizard/dataUtils/index.js +++ b/js/src/onboarding-wizard/dataUtils/index.js @@ -1 +1 @@ -export { default as setupUsageData} from './setupUsageData'; +export { default as setupUsageData } from './setupUsageData'; diff --git a/js/src/onboarding-wizard/elements/elements.js b/js/src/onboarding-wizard/elements/elements.js index 5bd720b3a3..497eebe898 100644 --- a/js/src/onboarding-wizard/elements/elements.js +++ b/js/src/onboarding-wizard/elements/elements.js @@ -8,17 +8,17 @@ import { createPageElements } from 'core/factory'; */ import { PREFIX } from '../shared'; -export const { getElements, addElements } = createPageElements({ - onboardingWizardPage: document.getElementById( `${PREFIX}-wizard-page` ), - container: document.getElementById( `${PREFIX}-container` ), +export const { getElements, addElements } = createPageElements( { + onboardingWizardPage: document.getElementById( `${ PREFIX }-wizard-page` ), + container: document.getElementById( `${ PREFIX }-container` ), - rootline: document.getElementById( `${PREFIX}-rootline` ), - steps: document.querySelectorAll( `.${PREFIX}-step` ), - skipStepButtons: document.querySelectorAll( `.${PREFIX}-skip-step` ), - backButtons: document.querySelectorAll( `.${PREFIX}-back-button` ), + rootline: document.getElementById( `${ PREFIX }-rootline` ), + steps: document.querySelectorAll( `.${ PREFIX }-step` ), + skipStepButtons: document.querySelectorAll( `.${ PREFIX }-skip-step` ), + backButtons: document.querySelectorAll( `.${ PREFIX }-back-button` ), - consentTrackingButton: document.getElementById( `${PREFIX}-consent-tracking` ), - installAddonsButton: document.getElementById( `${PREFIX}-install-addons-button` ), + consentTrackingButton: document.getElementById( `${ PREFIX }-consent-tracking` ), + installAddonsButton: document.getElementById( `${ PREFIX }-install-addons-button` ), hiddenLicenseKeyInput: document.getElementById( 'frm-license-key' ), -}); +} ); diff --git a/js/src/onboarding-wizard/events/backButtonListener.js b/js/src/onboarding-wizard/events/backButtonListener.js index 93d941b5b2..4be2e8feac 100644 --- a/js/src/onboarding-wizard/events/backButtonListener.js +++ b/js/src/onboarding-wizard/events/backButtonListener.js @@ -20,7 +20,7 @@ function addBackButtonEvents() { // Attach click event listeners to each back buttons backButtons.forEach( backButton => { onClickPreventDefault( backButton, onBackButtonClick ); - }); + } ); } /** diff --git a/js/src/onboarding-wizard/events/consentTrackingButtonListener.js b/js/src/onboarding-wizard/events/consentTrackingButtonListener.js index f96c602ed9..65948740e8 100644 --- a/js/src/onboarding-wizard/events/consentTrackingButtonListener.js +++ b/js/src/onboarding-wizard/events/consentTrackingButtonListener.js @@ -27,7 +27,7 @@ function addConsentTrackingButtonEvents() { * @private * @return {void} */ -const onConsentTrackingButtonClick = async() => { +const onConsentTrackingButtonClick = async () => { const { doJsonPost } = frmDom.ajax; doJsonPost( 'onboarding_consent_tracking', new FormData() ).then( navigateToNextStep ); }; diff --git a/js/src/onboarding-wizard/events/index.js b/js/src/onboarding-wizard/events/index.js index 4f0fe84be0..0383ecdda7 100644 --- a/js/src/onboarding-wizard/events/index.js +++ b/js/src/onboarding-wizard/events/index.js @@ -37,8 +37,8 @@ export function addEventListeners() { * @param {PopStateEvent} event The event object associated with the navigation action. * @return {void} */ -window.addEventListener( 'popstate', ( event ) => { +window.addEventListener( 'popstate', event => { const stepName = event.state?.step || getQueryParam( 'step' ); // Navigate to the specified step without adding to browser history navigateToStep( stepName, 'replaceState' ); -}); +} ); diff --git a/js/src/onboarding-wizard/events/installAddonsButtonListener.js b/js/src/onboarding-wizard/events/installAddonsButtonListener.js index ce8b7b0f5a..0db22e87e3 100644 --- a/js/src/onboarding-wizard/events/installAddonsButtonListener.js +++ b/js/src/onboarding-wizard/events/installAddonsButtonListener.js @@ -30,7 +30,7 @@ function addInstallAddonsButtonEvents() { * @param {Event} event The click event object. * @return {void} */ -const onInstallAddonsButtonClick = async( event ) => { +const onInstallAddonsButtonClick = async event => { const addons = document.querySelectorAll( '.frm-option-box.frm-checked:not(.frm-disabled)' ); const { installedAddons } = getState(); const installAddonsButton = event.currentTarget; @@ -67,7 +67,7 @@ const onInstallAddonsButtonClick = async( event ) => { * @param {boolean} options.isVendor Indicates whether the plugin is a vendor plugin (true) or a regular add-on (false). * @return {Promise} A promise that resolves with the JSON response from the server after the installation request is completed. */ -async function installAddon( plugin, {isVendor, isInstalled}) { +async function installAddon( plugin, { isVendor, isInstalled } ) { // Prepare FormData for the POST request const formData = new FormData(); formData.append( 'nonce', nonce ); @@ -81,10 +81,10 @@ async function installAddon( plugin, {isVendor, isInstalled}) { const response = await fetch( ajaxurl, { method: 'POST', body: formData - }); + } ); if ( ! response.ok ) { - throw new Error( `Server responded with status ${response.status}` ); + throw new Error( `Server responded with status ${ response.status }` ); } // Parse the JSON response diff --git a/js/src/onboarding-wizard/events/skipStepButtonListener.js b/js/src/onboarding-wizard/events/skipStepButtonListener.js index b4e11eb1b8..1f7dcf9d92 100644 --- a/js/src/onboarding-wizard/events/skipStepButtonListener.js +++ b/js/src/onboarding-wizard/events/skipStepButtonListener.js @@ -20,7 +20,7 @@ function addSkipStepButtonEvents() { // Attach click event listeners to each skip buttons skipStepButtons.forEach( skipButton => { onClickPreventDefault( skipButton, onSkipStepButtonClick ); - }); + } ); } /** diff --git a/js/src/onboarding-wizard/index.js b/js/src/onboarding-wizard/index.js index ac4f5a113b..d7ca30ea11 100644 --- a/js/src/onboarding-wizard/index.js +++ b/js/src/onboarding-wizard/index.js @@ -10,4 +10,4 @@ import initializeOnboardingWizard from './initializeOnboardingWizard'; domReady( () => { initializeOnboardingWizard(); -}); +} ); diff --git a/js/src/onboarding-wizard/shared/constants.js b/js/src/onboarding-wizard/shared/constants.js index 50ccbf3e4c..bdaf343b2a 100644 --- a/js/src/onboarding-wizard/shared/constants.js +++ b/js/src/onboarding-wizard/shared/constants.js @@ -1,4 +1,4 @@ -export const { INITIAL_STEP } = window.frmOnboardingWizardVars; +export const { INITIAL_STEP } = window.frmOnboardingWizardVars; export const PREFIX = 'frm-onboarding'; diff --git a/js/src/onboarding-wizard/shared/pageState.js b/js/src/onboarding-wizard/shared/pageState.js index b1b221270c..88ea5f1b49 100644 --- a/js/src/onboarding-wizard/shared/pageState.js +++ b/js/src/onboarding-wizard/shared/pageState.js @@ -3,7 +3,7 @@ */ import { createPageState } from 'core/factory'; -export const { getState, getSingleState, setState, setSingleState } = createPageState({ +export const { getState, getSingleState, setState, setSingleState } = createPageState( { processedSteps: [], installedAddons: [], -}); +} ); diff --git a/js/src/onboarding-wizard/ui/rootline.js b/js/src/onboarding-wizard/ui/rootline.js index fe9f4fe6fa..759ba15d17 100644 --- a/js/src/onboarding-wizard/ui/rootline.js +++ b/js/src/onboarding-wizard/ui/rootline.js @@ -6,7 +6,7 @@ import { CURRENT_CLASS } from 'core/constants'; /** * Internal dependencies */ -import { getElements } from "../elements"; +import { getElements } from '../elements'; import { STEPS } from '../shared'; const COMPLETED_STEP_CLASS = 'frm-completed-step'; @@ -26,12 +26,12 @@ export function updateRootline( currentStep ) { } const { rootline } = getElements(); - const currentItem = rootline.querySelector( `.frm-rootline-item[data-step="${currentStep}"]` ); + const currentItem = rootline.querySelector( `.frm-rootline-item[data-step="${ currentStep }"]` ); rootline.querySelectorAll( '.frm-rootline-item' ).forEach( item => { item.classList.remove( COMPLETED_STEP_CLASS ); item.classList.remove( CURRENT_CLASS ); - }); + } ); let prevItem = currentItem.previousElementSibling; if ( prevItem ) { diff --git a/js/src/onboarding-wizard/utils/navigateToStep.js b/js/src/onboarding-wizard/utils/navigateToStep.js index 3fb4379bb8..500613089a 100644 --- a/js/src/onboarding-wizard/utils/navigateToStep.js +++ b/js/src/onboarding-wizard/utils/navigateToStep.js @@ -22,13 +22,13 @@ import { updateRootline } from '../ui'; */ export const navigateToStep = ( stepName, updateMethod = 'pushState' ) => { // Find the target step element - const targetStep = document.querySelector( `.${PREFIX}-step[data-step-name="${stepName}"]` ); + const targetStep = document.querySelector( `.${ PREFIX }-step[data-step-name="${ stepName }"]` ); if ( ! targetStep ) { return; } // Find and hide the current step element - const currentStep = document.querySelector( `.${PREFIX}-step.${CURRENT_CLASS}` ); + const currentStep = document.querySelector( `.${ PREFIX }-step.${ CURRENT_CLASS }` ); if ( currentStep ) { currentStep.classList.remove( CURRENT_CLASS ); hide( currentStep ); @@ -57,7 +57,7 @@ export const navigateToStep = ( stepName, updateMethod = 'pushState' ) => { * @return {void} */ export const navigateToNextStep = () => { - const currentStep = document.querySelector( `.${PREFIX}-step.${CURRENT_CLASS}` ); + const currentStep = document.querySelector( `.${ PREFIX }-step.${ CURRENT_CLASS }` ); const nextStep = currentStep?.nextElementSibling; if ( ! nextStep ) { @@ -86,7 +86,7 @@ export const navigateToNextStep = () => { * @return {void} */ export const navigateToPrevStep = () => { - const currentStep = document.querySelector( `.${PREFIX}-step.${CURRENT_CLASS}` ); + const currentStep = document.querySelector( `.${ PREFIX }-step.${ CURRENT_CLASS }` ); const prevStep = currentStep?.previousElementSibling; if ( ! prevStep ) { diff --git a/package-lock.json b/package-lock.json index 64b76d78e8..e266850d74 100644 --- a/package-lock.json +++ b/package-lock.json @@ -17,6 +17,7 @@ "classnames": "^2.2.6", "google-closure-compiler": "^20240317.0.0", "npm": "^10.5.2", + "prop-types": "^15.8.1", "react": "^16.13.1", "react-dom": "^16.13.1", "styled-components": "^5.3.5" @@ -32,6 +33,7 @@ "@svgr/webpack": "^8.1.0", "@wordpress/babel-plugin-makepot": "^5.25.0", "@wordpress/babel-preset-default": "^7.25.0", + "@wordpress/browserslist-config": "^6.29.0", "@wordpress/env": "^9.8.0", "@wordpress/eslint-plugin": "^15.1.0", "@wordpress/stylelint-config": "^23.14.0", @@ -86,6 +88,7 @@ "version": "2.3.0", "resolved": "https://registry.npmjs.org/@ampproject/remapping/-/remapping-2.3.0.tgz", "integrity": "sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw==", + "dev": true, "license": "Apache-2.0", "dependencies": { "@jridgewell/gen-mapping": "^0.3.5", @@ -113,6 +116,7 @@ "version": "7.25.4", "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.25.4.tgz", "integrity": "sha512-+LGRog6RAsCJrrrg/IO6LGmpphNe5DiK30dGjCoxxeGv49B10/3XYGxPsAwrDlMFcFEvdAUavDT8r9k/hSyQqQ==", + "dev": true, "license": "MIT", "engines": { "node": ">=6.9.0" @@ -122,6 +126,7 @@ "version": "7.25.2", "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.25.2.tgz", "integrity": "sha512-BBt3opiCOxUr9euZ5/ro/Xv8/V7yJ5bjYMqG/C1YAo8MIKAnumZalCN+msbci3Pigy4lIQfPUpfMM27HMGaYEA==", + "dev": true, "license": "MIT", "dependencies": { "@ampproject/remapping": "^2.2.0", @@ -198,6 +203,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.24.7.tgz", "integrity": "sha512-xZeCVVdwb4MsDBkkyZ64tReWYrLRHlMN72vP7Bdm3OUOuyFZExhsHUUnuWnm2/XOlAJzR0LfPpB56WXZn0X/lA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/traverse": "^7.24.7", @@ -211,6 +217,7 @@ "version": "7.25.2", "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.25.2.tgz", "integrity": "sha512-U2U5LsSaZ7TAt3cfaymQ8WHh0pxvdHoEk6HVpaexxixjyEquMh0L0YNJNM6CTGKMXV1iksi0iZkGw4AcFkPaaw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/compat-data": "^7.25.2", @@ -227,6 +234,7 @@ "version": "7.25.4", "resolved": "https://registry.npmjs.org/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.25.4.tgz", "integrity": "sha512-ro/bFs3/84MDgDmMwbcHgDa8/E6J3QKNTk4xJJnVeFtGE+tL0K26E3pNxhYz2b67fJpt7Aphw5XcploKXuCvCQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-annotate-as-pure": "^7.24.7", @@ -248,6 +256,7 @@ "version": "7.25.2", "resolved": "https://registry.npmjs.org/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.25.2.tgz", "integrity": "sha512-+wqVGP+DFmqwFD3EH6TMTfUNeqDehV3E/dl+Sd54eaXqm17tEUNbEIn4sVivVowbvUpOtIGxdo3GoXyDH9N/9g==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-annotate-as-pure": "^7.24.7", @@ -265,6 +274,7 @@ "version": "0.6.2", "resolved": "https://registry.npmjs.org/@babel/helper-define-polyfill-provider/-/helper-define-polyfill-provider-0.6.2.tgz", "integrity": "sha512-LV76g+C502biUK6AyZ3LK10vDpDyCzZnhZFXkH1L75zHPj68+qc8Zfpx2th+gzwA2MzyK+1g/3EPl62yFnVttQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-compilation-targets": "^7.22.6", @@ -281,6 +291,7 @@ "version": "7.24.8", "resolved": "https://registry.npmjs.org/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.24.8.tgz", "integrity": "sha512-LABppdt+Lp/RlBxqrh4qgf1oEH/WxdzQNDJIu5gC/W1GyvPVrOBiItmmM8wan2fm4oYqFuFfkXmlGpLQhPY8CA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/traverse": "^7.24.8", @@ -307,6 +318,7 @@ "version": "7.25.2", "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.25.2.tgz", "integrity": "sha512-BjyRAbix6j/wv83ftcVJmBt72QtHI56C7JXZoG2xATiLpmoC7dpd8WnkikExHDVPpi/3qCmO6WY1EaXOluiecQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-module-imports": "^7.24.7", @@ -325,6 +337,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.24.7.tgz", "integrity": "sha512-jKiTsW2xmWwxT1ixIdfXUZp+P5yURx2suzLZr5Hi64rURpDYdMW0pv+Uf17EYk2Rd428Lx4tLsnjGJzYKDM/6A==", + "dev": true, "license": "MIT", "dependencies": { "@babel/types": "^7.24.7" @@ -346,6 +359,7 @@ "version": "7.25.0", "resolved": "https://registry.npmjs.org/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.25.0.tgz", "integrity": "sha512-NhavI2eWEIz/H9dbrG0TuOicDhNexze43i5z7lEqwYm0WEZVTwnPpA0EafUTP7+6/W79HWIP2cTe3Z5NiSTVpw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-annotate-as-pure": "^7.24.7", @@ -363,6 +377,7 @@ "version": "7.25.0", "resolved": "https://registry.npmjs.org/@babel/helper-replace-supers/-/helper-replace-supers-7.25.0.tgz", "integrity": "sha512-q688zIvQVYtZu+i2PsdIu/uWGRpfxzr5WESsfpShfZECkO+d2o+WROWezCi/Q6kJ0tfPa5+pUGUlfx2HhrA3Bg==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-member-expression-to-functions": "^7.24.8", @@ -380,6 +395,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.24.7.tgz", "integrity": "sha512-zBAIvbCMh5Ts+b86r/CjU+4XGYIs+R1j951gxI3KmmxBMhCg4oQMsv6ZXQ64XOm/cvzfU1FmoCyt6+owc5QMYg==", + "dev": true, "license": "MIT", "dependencies": { "@babel/traverse": "^7.24.7", @@ -393,6 +409,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/helper-skip-transparent-expression-wrappers/-/helper-skip-transparent-expression-wrappers-7.24.7.tgz", "integrity": "sha512-IO+DLT3LQUElMbpzlatRASEyQtfhSE0+m465v++3jyyXeBTBUjtVZg28/gHeV5mrTJqvEKhKroBGAvhW+qPHiQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/traverse": "^7.24.7", @@ -424,6 +441,7 @@ "version": "7.24.8", "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.24.8.tgz", "integrity": "sha512-xb8t9tD1MHLungh/AIoWYN+gVHaB9kwlu8gffXGSt3FFEIT7RjS+xWbc2vUD1UTZdIpKj/ab3rdqJ7ufngyi2Q==", + "dev": true, "license": "MIT", "engines": { "node": ">=6.9.0" @@ -433,6 +451,7 @@ "version": "7.25.0", "resolved": "https://registry.npmjs.org/@babel/helper-wrap-function/-/helper-wrap-function-7.25.0.tgz", "integrity": "sha512-s6Q1ebqutSiZnEjaofc/UKDyC4SbzV5n5SrA2Gq8UawLycr3i04f1dX4OzoQVnexm6aOCh37SQNYlJ/8Ku+PMQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/template": "^7.25.0", @@ -447,6 +466,7 @@ "version": "7.26.10", "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.26.10.tgz", "integrity": "sha512-UPYc3SauzZ3JGgj87GgZ89JVdC5dj0AoetR5Bw6wj4niittNyFh6+eOGonYvJ1ao6B8lEa3Q3klS7ADZ53bc5g==", + "dev": true, "license": "MIT", "dependencies": { "@babel/template": "^7.26.9", @@ -475,6 +495,7 @@ "version": "7.25.3", "resolved": "https://registry.npmjs.org/@babel/plugin-bugfix-firefox-class-in-computed-class-key/-/plugin-bugfix-firefox-class-in-computed-class-key-7.25.3.tgz", "integrity": "sha512-wUrcsxZg6rqBXG05HG1FPYgsP6EvwF4WpBbxIpWIIYnH8wG0gzx3yZY3dtEHas4sTAOGkbTsc9EGPxwff8lRoA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.8", @@ -491,6 +512,7 @@ "version": "7.25.0", "resolved": "https://registry.npmjs.org/@babel/plugin-bugfix-safari-class-field-initializer-scope/-/plugin-bugfix-safari-class-field-initializer-scope-7.25.0.tgz", "integrity": "sha512-Bm4bH2qsX880b/3ziJ8KD711LT7z4u8CFudmjqle65AZj/HNUFhEf90dqYv6O86buWvSBmeQDjv0Tn2aF/bIBA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.8" @@ -506,6 +528,7 @@ "version": "7.25.0", "resolved": "https://registry.npmjs.org/@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression/-/plugin-bugfix-safari-id-destructuring-collision-in-function-expression-7.25.0.tgz", "integrity": "sha512-lXwdNZtTmeVOOFtwM/WDe7yg1PL8sYhRk/XH0FzbR2HDQ0xC+EnQ/JHeoMYSavtU115tnUk0q9CDyq8si+LMAA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.8" @@ -521,6 +544,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining/-/plugin-bugfix-v8-spread-parameters-in-optional-chaining-7.24.7.tgz", "integrity": "sha512-+izXIbke1T33mY4MSNnrqhPXDz01WYhEf3yF5NbnUtkiNnm+XBZJl3kNfoK6NKmYlz/D07+l2GWVK/QfDkNCuQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7", @@ -538,6 +562,7 @@ "version": "7.25.0", "resolved": "https://registry.npmjs.org/@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly/-/plugin-bugfix-v8-static-class-fields-redefine-readonly-7.25.0.tgz", "integrity": "sha512-tggFrk1AIShG/RUQbEwt2Tr/E+ObkfwrPjR6BjbRvsx24+PSjK8zrq0GWPNCjo8qpRx4DuJzlcvWJqlm+0h3kw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.8", @@ -550,82 +575,11 @@ "@babel/core": "^7.0.0" } }, - "node_modules/@babel/plugin-proposal-class-properties": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.18.6.tgz", - "integrity": "sha512-cumfXOF0+nzZrrN8Rf0t7M+tF6sZc7vhQwYQck9q1/5w2OExlD+b4v4RpMJFaV1Z7WcDRgO6FqvxqxGlwo+RHQ==", - "deprecated": "This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-class-properties instead.", - "license": "MIT", - "peer": true, - "dependencies": { - "@babel/helper-create-class-features-plugin": "^7.18.6", - "@babel/helper-plugin-utils": "^7.18.6" - }, - "engines": { - "node": ">=6.9.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" - } - }, - "node_modules/@babel/plugin-proposal-export-default-from": { - "version": "7.24.7", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-export-default-from/-/plugin-proposal-export-default-from-7.24.7.tgz", - "integrity": "sha512-CcmFwUJ3tKhLjPdt4NP+SHMshebytF8ZTYOv5ZDpkzq2sin80Wb5vJrGt8fhPrORQCfoSa0LAxC/DW+GAC5+Hw==", - "license": "MIT", - "peer": true, - "dependencies": { - "@babel/helper-plugin-utils": "^7.24.7", - "@babel/plugin-syntax-export-default-from": "^7.24.7" - }, - "engines": { - "node": ">=6.9.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" - } - }, - "node_modules/@babel/plugin-proposal-nullish-coalescing-operator": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.18.6.tgz", - "integrity": "sha512-wQxQzxYeJqHcfppzBDnm1yAY0jSRkUXR2z8RePZYrKwMKgMlE8+Z6LUno+bd6LvbGh8Gltvy74+9pIYkr+XkKA==", - "deprecated": "This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-nullish-coalescing-operator instead.", - "license": "MIT", - "peer": true, - "dependencies": { - "@babel/helper-plugin-utils": "^7.18.6", - "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3" - }, - "engines": { - "node": ">=6.9.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" - } - }, - "node_modules/@babel/plugin-proposal-optional-chaining": { - "version": "7.21.0", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-optional-chaining/-/plugin-proposal-optional-chaining-7.21.0.tgz", - "integrity": "sha512-p4zeefM72gpmEe2fkUr/OnOXpWEf8nAgk7ZYVqqfFiyIG7oFfVZcCrU64hWn5xp4tQ9LkV4bTIa5rD0KANpKNA==", - "deprecated": "This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-optional-chaining instead.", - "license": "MIT", - "peer": true, - "dependencies": { - "@babel/helper-plugin-utils": "^7.20.2", - "@babel/helper-skip-transparent-expression-wrappers": "^7.20.0", - "@babel/plugin-syntax-optional-chaining": "^7.8.3" - }, - "engines": { - "node": ">=6.9.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" - } - }, "node_modules/@babel/plugin-proposal-private-property-in-object": { "version": "7.21.0-placeholder-for-preset-env.2", "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-private-property-in-object/-/plugin-proposal-private-property-in-object-7.21.0-placeholder-for-preset-env.2.tgz", "integrity": "sha512-SOSkfJDddaM7mak6cPEpswyTRnuRltl429hMraQEglW+OkovnCzsiszTmsrlY//qLFjCpQDFRvjdm2wA5pPm9w==", + "dev": true, "license": "MIT", "engines": { "node": ">=6.9.0" @@ -638,6 +592,7 @@ "version": "7.8.4", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz", "integrity": "sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.8.0" @@ -650,6 +605,7 @@ "version": "7.12.13", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.12.13.tgz", "integrity": "sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.12.13" @@ -662,6 +618,7 @@ "version": "7.14.5", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-static-block/-/plugin-syntax-class-static-block-7.14.5.tgz", "integrity": "sha512-b+YyPmr6ldyNnM6sqYeMWE+bgJcJpO6yS4QD7ymxgH34GBPNDM/THBh8iunyvKIZztiwLH4CJZ0RxTk9emgpjw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.14.5" @@ -677,6 +634,7 @@ "version": "7.8.3", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-dynamic-import/-/plugin-syntax-dynamic-import-7.8.3.tgz", "integrity": "sha512-5gdGbFon+PszYzqs83S3E5mpi7/y/8M9eC90MRTZfduQOYW76ig6SOSPNe41IG5LoP3FGBn2N0RjVDSQiS94kQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.8.0" @@ -685,26 +643,11 @@ "@babel/core": "^7.0.0-0" } }, - "node_modules/@babel/plugin-syntax-export-default-from": { - "version": "7.24.7", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-export-default-from/-/plugin-syntax-export-default-from-7.24.7.tgz", - "integrity": "sha512-bTPz4/635WQ9WhwsyPdxUJDVpsi/X9BMmy/8Rf/UAlOO4jSql4CxUCjWI5PiM+jG+c4LVPTScoTw80geFj9+Bw==", - "license": "MIT", - "peer": true, - "dependencies": { - "@babel/helper-plugin-utils": "^7.24.7" - }, - "engines": { - "node": ">=6.9.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" - } - }, "node_modules/@babel/plugin-syntax-export-namespace-from": { "version": "7.8.3", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-export-namespace-from/-/plugin-syntax-export-namespace-from-7.8.3.tgz", "integrity": "sha512-MXf5laXo6c1IbEbegDmzGPwGNTsHZmEy6QGznu5Sh2UCWvueywb2ee+CCE4zQiZstxU9BMoQO9i6zUFSY0Kj0Q==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.8.3" @@ -713,26 +656,11 @@ "@babel/core": "^7.0.0-0" } }, - "node_modules/@babel/plugin-syntax-flow": { - "version": "7.24.7", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-flow/-/plugin-syntax-flow-7.24.7.tgz", - "integrity": "sha512-9G8GYT/dxn/D1IIKOUBmGX0mnmj46mGH9NnZyJLwtCpgh5f7D2VbuKodb+2s9m1Yavh1s7ASQN8lf0eqrb1LTw==", - "license": "MIT", - "peer": true, - "dependencies": { - "@babel/helper-plugin-utils": "^7.24.7" - }, - "engines": { - "node": ">=6.9.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" - } - }, "node_modules/@babel/plugin-syntax-import-assertions": { "version": "7.25.6", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-import-assertions/-/plugin-syntax-import-assertions-7.25.6.tgz", "integrity": "sha512-aABl0jHw9bZ2karQ/uUD6XP4u0SG22SJrOHFoL6XB1R7dTovOP4TzTlsxOYC5yQ1pdscVK2JTUnF6QL3ARoAiQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.8" @@ -748,6 +676,7 @@ "version": "7.25.6", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-import-attributes/-/plugin-syntax-import-attributes-7.25.6.tgz", "integrity": "sha512-sXaDXaJN9SNLymBdlWFA+bjzBhFD617ZaFiY13dGt7TVslVvVgA6fkZOP7Ki3IGElC45lwHdOTrCtKZGVAWeLQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.8" @@ -763,6 +692,7 @@ "version": "7.10.4", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-import-meta/-/plugin-syntax-import-meta-7.10.4.tgz", "integrity": "sha512-Yqfm+XDx0+Prh3VSeEQCPU81yC+JWZ2pDPFSS4ZdpfZhp4MkFMaDC1UqseovEKwSUpnIL7+vK+Clp7bfh0iD7g==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.10.4" @@ -775,6 +705,7 @@ "version": "7.8.3", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz", "integrity": "sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.8.0" @@ -802,6 +733,7 @@ "version": "7.10.4", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz", "integrity": "sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.10.4" @@ -814,6 +746,7 @@ "version": "7.8.3", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz", "integrity": "sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.8.0" @@ -826,6 +759,7 @@ "version": "7.10.4", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz", "integrity": "sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.10.4" @@ -838,6 +772,7 @@ "version": "7.8.3", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz", "integrity": "sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.8.0" @@ -850,6 +785,7 @@ "version": "7.8.3", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz", "integrity": "sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.8.0" @@ -862,6 +798,7 @@ "version": "7.8.3", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz", "integrity": "sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.8.0" @@ -874,6 +811,7 @@ "version": "7.14.5", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-private-property-in-object/-/plugin-syntax-private-property-in-object-7.14.5.tgz", "integrity": "sha512-0wVnp9dxJ72ZUJDV27ZfbSj6iHLoytYZmh3rFcxNnvsJF3ktkzLDZPy/mA17HGsaQT3/DQsWYX1f1QGWkCoVUg==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.14.5" @@ -889,6 +827,7 @@ "version": "7.14.5", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.14.5.tgz", "integrity": "sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.14.5" @@ -904,6 +843,7 @@ "version": "7.25.4", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.25.4.tgz", "integrity": "sha512-uMOCoHVU52BsSWxPOMVv5qKRdeSlPuImUCB2dlPuBSU+W2/ROE7/Zg8F2Kepbk+8yBa68LlRKxO+xgEVWorsDg==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.8" @@ -919,6 +859,7 @@ "version": "7.18.6", "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-unicode-sets-regex/-/plugin-syntax-unicode-sets-regex-7.18.6.tgz", "integrity": "sha512-727YkEAPwSIQTv5im8QHz3upqp92JTWhidIC81Tdx4VJYIte/VndKf1qKrfnnhPLiPghStWfvC/iFaMCQu7Nqg==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-create-regexp-features-plugin": "^7.18.6", @@ -935,6 +876,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.24.7.tgz", "integrity": "sha512-Dt9LQs6iEY++gXUwY03DNFat5C2NbO48jj+j/bSAz6b3HgPs39qcPiYt77fDObIcFwj3/C2ICX9YMwGflUoSHQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7" @@ -950,6 +892,7 @@ "version": "7.25.4", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-async-generator-functions/-/plugin-transform-async-generator-functions-7.25.4.tgz", "integrity": "sha512-jz8cV2XDDTqjKPwVPJBIjORVEmSGYhdRa8e5k5+vN+uwcjSrSxUaebBRa4ko1jqNF2uxyg8G6XYk30Jv285xzg==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.8", @@ -968,6 +911,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.24.7.tgz", "integrity": "sha512-SQY01PcJfmQ+4Ash7NE+rpbLFbmqA2GPIgqzxfFTL4t1FKRq4zTms/7htKpoCUI9OcFYgzqfmCdH53s6/jn5fA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-module-imports": "^7.24.7", @@ -985,6 +929,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoped-functions/-/plugin-transform-block-scoped-functions-7.24.7.tgz", "integrity": "sha512-yO7RAz6EsVQDaBH18IDJcMB1HnrUn2FJ/Jslc/WtPPWcjhpUJXU/rjbwmluzp7v/ZzWcEhTMXELnnsz8djWDwQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7" @@ -1000,6 +945,7 @@ "version": "7.25.0", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.25.0.tgz", "integrity": "sha512-yBQjYoOjXlFv9nlXb3f1casSHOZkWr29NX+zChVanLg5Nc157CrbEX9D7hxxtTpuFy7Q0YzmmWfJxzvps4kXrQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.8" @@ -1015,6 +961,7 @@ "version": "7.25.4", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-class-properties/-/plugin-transform-class-properties-7.25.4.tgz", "integrity": "sha512-nZeZHyCWPfjkdU5pA/uHiTaDAFUEqkpzf1YoQT2NeSynCGYq9rxfyI3XpQbfx/a0hSnFH6TGlEXvae5Vi7GD8g==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-create-class-features-plugin": "^7.25.4", @@ -1031,6 +978,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-class-static-block/-/plugin-transform-class-static-block-7.24.7.tgz", "integrity": "sha512-HMXK3WbBPpZQufbMG4B46A90PkuuhN9vBCb5T8+VAHqvAqvcLi+2cKoukcpmUYkszLhScU3l1iudhrks3DggRQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-create-class-features-plugin": "^7.24.7", @@ -1048,6 +996,7 @@ "version": "7.25.4", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-classes/-/plugin-transform-classes-7.25.4.tgz", "integrity": "sha512-oexUfaQle2pF/b6E0dwsxQtAol9TLSO88kQvym6HHBWFliV2lGdrPieX+WgMRLSJDVzdYywk7jXbLPuO2KLTLg==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-annotate-as-pure": "^7.24.7", @@ -1068,6 +1017,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.24.7.tgz", "integrity": "sha512-25cS7v+707Gu6Ds2oY6tCkUwsJ9YIDbggd9+cu9jzzDgiNq7hR/8dkzxWfKWnTic26vsI3EsCXNd4iEB6e8esQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7", @@ -1084,6 +1034,7 @@ "version": "7.24.8", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.24.8.tgz", "integrity": "sha512-36e87mfY8TnRxc7yc6M9g9gOB7rKgSahqkIKwLpz4Ppk2+zC2Cy1is0uwtuSG6AE4zlTOUa+7JGz9jCJGLqQFQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.8" @@ -1099,6 +1050,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.24.7.tgz", "integrity": "sha512-ZOA3W+1RRTSWvyqcMJDLqbchh7U4NRGqwRfFSVbOLS/ePIP4vHB5e8T8eXcuqyN1QkgKyj5wuW0lcS85v4CrSw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-create-regexp-features-plugin": "^7.24.7", @@ -1115,6 +1067,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.24.7.tgz", "integrity": "sha512-JdYfXyCRihAe46jUIliuL2/s0x0wObgwwiGxw/UbgJBr20gQBThrokO4nYKgWkD7uBaqM7+9x5TU7NkExZJyzw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7" @@ -1130,6 +1083,7 @@ "version": "7.25.0", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-duplicate-named-capturing-groups-regex/-/plugin-transform-duplicate-named-capturing-groups-regex-7.25.0.tgz", "integrity": "sha512-YLpb4LlYSc3sCUa35un84poXoraOiQucUTTu8X1j18JV+gNa8E0nyUf/CjZ171IRGr4jEguF+vzJU66QZhn29g==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-create-regexp-features-plugin": "^7.25.0", @@ -1146,6 +1100,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-dynamic-import/-/plugin-transform-dynamic-import-7.24.7.tgz", "integrity": "sha512-sc3X26PhZQDb3JhORmakcbvkeInvxz+A8oda99lj7J60QRuPZvNAk9wQlTBS1ZynelDrDmTU4pw1tyc5d5ZMUg==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7", @@ -1162,6 +1117,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.24.7.tgz", "integrity": "sha512-Rqe/vSc9OYgDajNIK35u7ot+KeCoetqQYFXM4Epf7M7ez3lWlOjrDjrwMei6caCVhfdw+mIKD4cgdGNy5JQotQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-builder-binary-assignment-operator-visitor": "^7.24.7", @@ -1178,6 +1134,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-export-namespace-from/-/plugin-transform-export-namespace-from-7.24.7.tgz", "integrity": "sha512-v0K9uNYsPL3oXZ/7F9NNIbAj2jv1whUEtyA6aujhekLs56R++JDQuzRcP2/z4WX5Vg/c5lE9uWZA0/iUoFhLTA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7", @@ -1190,27 +1147,11 @@ "@babel/core": "^7.0.0-0" } }, - "node_modules/@babel/plugin-transform-flow-strip-types": { - "version": "7.25.2", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-flow-strip-types/-/plugin-transform-flow-strip-types-7.25.2.tgz", - "integrity": "sha512-InBZ0O8tew5V0K6cHcQ+wgxlrjOw1W4wDXLkOTjLRD8GYhTSkxTVBtdy3MMtvYBrbAWa1Qm3hNoTc1620Yj+Mg==", - "license": "MIT", - "peer": true, - "dependencies": { - "@babel/helper-plugin-utils": "^7.24.8", - "@babel/plugin-syntax-flow": "^7.24.7" - }, - "engines": { - "node": ">=6.9.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" - } - }, "node_modules/@babel/plugin-transform-for-of": { "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.24.7.tgz", "integrity": "sha512-wo9ogrDG1ITTTBsy46oGiN1dS9A7MROBTcYsfS8DtsImMkHk9JXJ3EWQM6X2SUw4x80uGPlwj0o00Uoc6nEE3g==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7", @@ -1227,6 +1168,7 @@ "version": "7.25.1", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.25.1.tgz", "integrity": "sha512-TVVJVdW9RKMNgJJlLtHsKDTydjZAbwIsn6ySBPQaEAUU5+gVvlJt/9nRmqVbsV/IBanRjzWoaAQKLoamWVOUuA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-compilation-targets": "^7.24.8", @@ -1244,6 +1186,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-json-strings/-/plugin-transform-json-strings-7.24.7.tgz", "integrity": "sha512-2yFnBGDvRuxAaE/f0vfBKvtnvvqU8tGpMHqMNpTN2oWMKIR3NqFkjaAgGwawhqK/pIN2T3XdjGPdaG0vDhOBGw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7", @@ -1260,6 +1203,7 @@ "version": "7.25.2", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-literals/-/plugin-transform-literals-7.25.2.tgz", "integrity": "sha512-HQI+HcTbm9ur3Z2DkO+jgESMAMcYLuN/A7NRw9juzxAezN9AvqvUTnpKP/9kkYANz6u7dFlAyOu44ejuGySlfw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.8" @@ -1275,6 +1219,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-logical-assignment-operators/-/plugin-transform-logical-assignment-operators-7.24.7.tgz", "integrity": "sha512-4D2tpwlQ1odXmTEIFWy9ELJcZHqrStlzK/dAOWYyxX3zT0iXQB6banjgeOJQXzEc4S0E0a5A+hahxPaEFYftsw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7", @@ -1291,6 +1236,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.24.7.tgz", "integrity": "sha512-T/hRC1uqrzXMKLQ6UCwMT85S3EvqaBXDGf0FaMf4446Qx9vKwlghvee0+uuZcDUCZU5RuNi4781UQ7R308zzBw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7" @@ -1306,6 +1252,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.24.7.tgz", "integrity": "sha512-9+pB1qxV3vs/8Hdmz/CulFB8w2tuu6EB94JZFsjdqxQokwGa9Unap7Bo2gGBGIvPmDIVvQrom7r5m/TCDMURhg==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-module-transforms": "^7.24.7", @@ -1322,6 +1269,7 @@ "version": "7.24.8", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.24.8.tgz", "integrity": "sha512-WHsk9H8XxRs3JXKWFiqtQebdh9b/pTk4EgueygFzYlTKAg0Ud985mSevdNjdXdFBATSKVJGQXP1tv6aGbssLKA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-module-transforms": "^7.24.8", @@ -1339,6 +1287,7 @@ "version": "7.25.0", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.25.0.tgz", "integrity": "sha512-YPJfjQPDXxyQWg/0+jHKj1llnY5f/R6a0p/vP4lPymxLu7Lvl4k2WMitqi08yxwQcCVUUdG9LCUj4TNEgAp3Jw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-module-transforms": "^7.25.0", @@ -1357,6 +1306,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.24.7.tgz", "integrity": "sha512-3aytQvqJ/h9z4g8AsKPLvD4Zqi2qT+L3j7XoFFu1XBlZWEl2/1kWnhmAbxpLgPrHSY0M6UA02jyTiwUVtiKR6A==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-module-transforms": "^7.24.7", @@ -1373,6 +1323,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.24.7.tgz", "integrity": "sha512-/jr7h/EWeJtk1U/uz2jlsCioHkZk1JJZVcc8oQsJ1dUlaJD83f4/6Zeh2aHt9BIFokHIsSeDfhUmju0+1GPd6g==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-create-regexp-features-plugin": "^7.24.7", @@ -1389,6 +1340,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.24.7.tgz", "integrity": "sha512-RNKwfRIXg4Ls/8mMTza5oPF5RkOW8Wy/WgMAp1/F1yZ8mMbtwXW+HDoJiOsagWrAhI5f57Vncrmr9XeT4CVapA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7" @@ -1404,6 +1356,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-nullish-coalescing-operator/-/plugin-transform-nullish-coalescing-operator-7.24.7.tgz", "integrity": "sha512-Ts7xQVk1OEocqzm8rHMXHlxvsfZ0cEF2yomUqpKENHWMF4zKk175Y4q8H5knJes6PgYad50uuRmt3UJuhBw8pQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7", @@ -1420,6 +1373,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-numeric-separator/-/plugin-transform-numeric-separator-7.24.7.tgz", "integrity": "sha512-e6q1TiVUzvH9KRvicuxdBTUj4AdKSRwzIyFFnfnezpCfP2/7Qmbb8qbU2j7GODbl4JMkblitCQjKYUaX/qkkwA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7", @@ -1436,6 +1390,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-object-rest-spread/-/plugin-transform-object-rest-spread-7.24.7.tgz", "integrity": "sha512-4QrHAr0aXQCEFni2q4DqKLD31n2DL+RxcwnNjDFkSG0eNQ/xCavnRkfCUjsyqGC2OviNJvZOF/mQqZBw7i2C5Q==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-compilation-targets": "^7.24.7", @@ -1454,6 +1409,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.24.7.tgz", "integrity": "sha512-A/vVLwN6lBrMFmMDmPPz0jnE6ZGx7Jq7d6sT/Ev4H65RER6pZ+kczlf1DthF5N0qaPHBsI7UXiE8Zy66nmAovg==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7", @@ -1470,6 +1426,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-optional-catch-binding/-/plugin-transform-optional-catch-binding-7.24.7.tgz", "integrity": "sha512-uLEndKqP5BfBbC/5jTwPxLh9kqPWWgzN/f8w6UwAIirAEqiIVJWWY312X72Eub09g5KF9+Zn7+hT7sDxmhRuKA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7", @@ -1486,6 +1443,7 @@ "version": "7.24.8", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-optional-chaining/-/plugin-transform-optional-chaining-7.24.8.tgz", "integrity": "sha512-5cTOLSMs9eypEy8JUVvIKOu6NgvbJMnpG62VpIHrTmROdQ+L5mDAaI40g25k5vXti55JWNX5jCkq3HZxXBQANw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.8", @@ -1503,6 +1461,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.24.7.tgz", "integrity": "sha512-yGWW5Rr+sQOhK0Ot8hjDJuxU3XLRQGflvT4lhlSY0DFvdb3TwKaY26CJzHtYllU0vT9j58hc37ndFPsqT1SrzA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7" @@ -1518,6 +1477,7 @@ "version": "7.25.4", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-private-methods/-/plugin-transform-private-methods-7.25.4.tgz", "integrity": "sha512-ao8BG7E2b/URaUQGqN3Tlsg+M3KlHY6rJ1O1gXAEUnZoyNQnvKyH87Kfg+FoxSeyWUB8ISZZsC91C44ZuBFytw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-create-class-features-plugin": "^7.25.4", @@ -1534,6 +1494,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-private-property-in-object/-/plugin-transform-private-property-in-object-7.24.7.tgz", "integrity": "sha512-9z76mxwnwFxMyxZWEgdgECQglF2Q7cFLm0kMf8pGwt+GSJsY0cONKj/UuO4bOH0w/uAel3ekS4ra5CEAyJRmDA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-annotate-as-pure": "^7.24.7", @@ -1552,6 +1513,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.24.7.tgz", "integrity": "sha512-EMi4MLQSHfd2nrCqQEWxFdha2gBCqU4ZcCng4WBGZ5CJL4bBRW0ptdqqDdeirGZcpALazVVNJqRmsO8/+oNCBA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7" @@ -1583,6 +1545,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-display-name/-/plugin-transform-react-display-name-7.24.7.tgz", "integrity": "sha512-H/Snz9PFxKsS1JLI4dJLtnJgCJRoo0AUm3chP6NYr+9En1JMKloheEiLIhlp5MDVznWo+H3AAC1Mc8lmUEpsgg==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7" @@ -1598,6 +1561,7 @@ "version": "7.25.2", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx/-/plugin-transform-react-jsx-7.25.2.tgz", "integrity": "sha512-KQsqEAVBpU82NM/B/N9j9WOdphom1SZH3R+2V7INrQUH+V9EBFwZsEJl8eBIVeQE62FxJCc70jzEZwqU7RcVqA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-annotate-as-pure": "^7.24.7", @@ -1629,38 +1593,6 @@ "@babel/core": "^7.0.0-0" } }, - "node_modules/@babel/plugin-transform-react-jsx-self": { - "version": "7.24.7", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx-self/-/plugin-transform-react-jsx-self-7.24.7.tgz", - "integrity": "sha512-fOPQYbGSgH0HUp4UJO4sMBFjY6DuWq+2i8rixyUMb3CdGixs/gccURvYOAhajBdKDoGajFr3mUq5rH3phtkGzw==", - "license": "MIT", - "peer": true, - "dependencies": { - "@babel/helper-plugin-utils": "^7.24.7" - }, - "engines": { - "node": ">=6.9.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" - } - }, - "node_modules/@babel/plugin-transform-react-jsx-source": { - "version": "7.24.7", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx-source/-/plugin-transform-react-jsx-source-7.24.7.tgz", - "integrity": "sha512-J2z+MWzZHVOemyLweMqngXrgGC42jQ//R0KdxqkIz/OrbVIIlhFI3WigZ5fO+nwFvBlncr4MGapd8vTyc7RPNQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "@babel/helper-plugin-utils": "^7.24.7" - }, - "engines": { - "node": ">=6.9.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" - } - }, "node_modules/@babel/plugin-transform-react-pure-annotations": { "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-pure-annotations/-/plugin-transform-react-pure-annotations-7.24.7.tgz", @@ -1682,6 +1614,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.24.7.tgz", "integrity": "sha512-lq3fvXPdimDrlg6LWBoqj+r/DEWgONuwjuOuQCSYgRroXDH/IdM1C0IZf59fL5cHLpjEH/O6opIRBbqv7ELnuA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7", @@ -1698,6 +1631,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.24.7.tgz", "integrity": "sha512-0DUq0pHcPKbjFZCfTss/pGkYMfy3vFWydkUBd9r0GHpIyfs2eCDENvqadMycRS9wZCXR41wucAfJHJmwA0UmoQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7" @@ -1713,6 +1647,7 @@ "version": "7.25.4", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-runtime/-/plugin-transform-runtime-7.25.4.tgz", "integrity": "sha512-8hsyG+KUYGY0coX6KUCDancA0Vw225KJ2HJO0yCNr1vq5r+lJTleDaJf0K7iOhjw4SWhu03TMBzYTJ9krmzULQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-module-imports": "^7.24.7", @@ -1733,6 +1668,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.24.7.tgz", "integrity": "sha512-KsDsevZMDsigzbA09+vacnLpmPH4aWjcZjXdyFKGzpplxhbeB4wYtury3vglQkg6KM/xEPKt73eCjPPf1PgXBA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7" @@ -1748,6 +1684,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-spread/-/plugin-transform-spread-7.24.7.tgz", "integrity": "sha512-x96oO0I09dgMDxJaANcRyD4ellXFLLiWhuwDxKZX5g2rWP1bTPkBSwCYv96VDXVT1bD9aPj8tppr5ITIh8hBng==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7", @@ -1764,6 +1701,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.24.7.tgz", "integrity": "sha512-kHPSIJc9v24zEml5geKg9Mjx5ULpfncj0wRpYtxbvKyTtHCYDkVE3aHQ03FrpEo4gEe2vrJJS1Y9CJTaThA52g==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7" @@ -1779,6 +1717,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.24.7.tgz", "integrity": "sha512-AfDTQmClklHCOLxtGoP7HkeMw56k1/bTQjwsfhL6pppo/M4TOBSq+jjBUBLmV/4oeFg4GWMavIl44ZeCtmmZTw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7" @@ -1794,6 +1733,7 @@ "version": "7.24.8", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.24.8.tgz", "integrity": "sha512-adNTUpDCVnmAE58VEqKlAA6ZBlNkMnWD0ZcW76lyNFN3MJniyGFZfNwERVk8Ap56MCnXztmDr19T4mPTztcuaw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.8" @@ -1809,6 +1749,7 @@ "version": "7.25.2", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.25.2.tgz", "integrity": "sha512-lBwRvjSmqiMYe/pS0+1gggjJleUJi7NzjvQ1Fkqtt69hBa/0t1YuW/MLQMAPixfwaQOHUXsd6jeU3Z+vdGv3+A==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-annotate-as-pure": "^7.24.7", @@ -1828,6 +1769,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.24.7.tgz", "integrity": "sha512-U3ap1gm5+4edc2Q/P+9VrBNhGkfnf+8ZqppY71Bo/pzZmXhhLdqgaUl6cuB07O1+AQJtCLfaOmswiNbSQ9ivhw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7" @@ -1843,6 +1785,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-property-regex/-/plugin-transform-unicode-property-regex-7.24.7.tgz", "integrity": "sha512-uH2O4OV5M9FZYQrwc7NdVmMxQJOCCzFeYudlZSzUAHRFeOujQefa92E74TQDVskNHCzOXoigEuoyzHDhaEaK5w==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-create-regexp-features-plugin": "^7.24.7", @@ -1859,6 +1802,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.24.7.tgz", "integrity": "sha512-hlQ96MBZSAXUq7ltkjtu3FJCCSMx/j629ns3hA3pXnBXjanNP0LHi+JpPeA81zaWgVK1VGH95Xuy7u0RyQ8kMg==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-create-regexp-features-plugin": "^7.24.7", @@ -1875,6 +1819,7 @@ "version": "7.25.4", "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-sets-regex/-/plugin-transform-unicode-sets-regex-7.25.4.tgz", "integrity": "sha512-qesBxiWkgN1Q+31xUE9RcMk79eOXXDCv6tfyGMRSs4RGlioSg2WVyQAm07k726cSE56pa+Kb0y9epX2qaXzTvA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-create-regexp-features-plugin": "^7.25.2", @@ -1891,6 +1836,7 @@ "version": "7.25.4", "resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.25.4.tgz", "integrity": "sha512-W9Gyo+KmcxjGahtt3t9fb14vFRWvPpu5pT6GBlovAK6BTBcxgjfVMSQCfJl4oi35ODrxP6xx2Wr8LNST57Mraw==", + "dev": true, "license": "MIT", "dependencies": { "@babel/compat-data": "^7.25.4", @@ -1984,28 +1930,11 @@ "@babel/core": "^7.0.0-0" } }, - "node_modules/@babel/preset-flow": { - "version": "7.24.7", - "resolved": "https://registry.npmjs.org/@babel/preset-flow/-/preset-flow-7.24.7.tgz", - "integrity": "sha512-NL3Lo0NorCU607zU3NwRyJbpaB6E3t0xtd3LfAQKDfkeX4/ggcDXvkmkW42QWT5owUeW/jAe4hn+2qvkV1IbfQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "@babel/helper-plugin-utils": "^7.24.7", - "@babel/helper-validator-option": "^7.24.7", - "@babel/plugin-transform-flow-strip-types": "^7.24.7" - }, - "engines": { - "node": ">=6.9.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" - } - }, "node_modules/@babel/preset-modules": { "version": "0.1.6-no-external-plugins", "resolved": "https://registry.npmjs.org/@babel/preset-modules/-/preset-modules-0.1.6-no-external-plugins.tgz", "integrity": "sha512-HrcgcIESLm9aIR842yhJ5RWan/gebQUJ6E/E5+rf0y9o6oj7w0Br+sWuL6kEQ/o/AdfvR1Je9jG18/gnpwjEyA==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.0.0", @@ -2041,6 +1970,7 @@ "version": "7.24.7", "resolved": "https://registry.npmjs.org/@babel/preset-typescript/-/preset-typescript-7.24.7.tgz", "integrity": "sha512-SyXRe3OdWwIwalxDg5UtJnJQO+YPcTfwiIY2B0Xlddh9o7jpWLvv8X1RthIeDOxQ+O1ML5BLPCONToObyVQVuQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/helper-plugin-utils": "^7.24.7", @@ -2056,154 +1986,41 @@ "@babel/core": "^7.0.0-0" } }, - "node_modules/@babel/register": { - "version": "7.24.6", - "resolved": "https://registry.npmjs.org/@babel/register/-/register-7.24.6.tgz", - "integrity": "sha512-WSuFCc2wCqMeXkz/i3yfAAsxwWflEgbVkZzivgAmXl/MxrXeoYFZOOPllbC8R8WTF7u61wSRQtDVZ1879cdu6w==", + "node_modules/@babel/regjsgen": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/@babel/regjsgen/-/regjsgen-0.8.0.tgz", + "integrity": "sha512-x/rqGMdzj+fWZvCOYForTghzbtqPDZ5gPwaoNGHdgDfF2QA/XZbCBp4Moo5scrkAMPhB7z26XM/AaHuIJdgauA==", + "dev": true, + "license": "MIT" + }, + "node_modules/@babel/runtime": { + "version": "7.0.0-beta.55", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.0.0-beta.55.tgz", + "integrity": "sha512-0/cvrMwFQra0nC8mRdQ3JdMJWwQ4JkjA0EIUXQyd3eTcIb5r8UEOJYdG0dUIGqz5ROCIdqN6BJTg7QhQ55/xGQ==", "license": "MIT", - "peer": true, "dependencies": { - "clone-deep": "^4.0.1", - "find-cache-dir": "^2.0.0", - "make-dir": "^2.1.0", - "pirates": "^4.0.6", - "source-map-support": "^0.5.16" - }, - "engines": { - "node": ">=6.9.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" + "core-js": "^2.5.7", + "regenerator-runtime": "^0.12.0" } }, - "node_modules/@babel/register/node_modules/find-cache-dir": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-2.1.0.tgz", - "integrity": "sha512-Tq6PixE0w/VMFfCgbONnkiQIVol/JJL7nRMi20fqzA4NRs9AfeqMGeRdPi3wIhYkxjeBaWh2rxwapn5Tu3IqOQ==", + "node_modules/@babel/template": { + "version": "7.26.9", + "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.26.9.tgz", + "integrity": "sha512-qyRplbeIpNZhmzOysF/wFMuP9sctmh2cFzRAZOn1YapxBsE1i9bJIY586R/WBLfLcmcBlM8ROBiQURnnNy+zfA==", "license": "MIT", - "peer": true, "dependencies": { - "commondir": "^1.0.1", - "make-dir": "^2.0.0", - "pkg-dir": "^3.0.0" + "@babel/code-frame": "^7.26.2", + "@babel/parser": "^7.26.9", + "@babel/types": "^7.26.9" }, "engines": { - "node": ">=6" + "node": ">=6.9.0" } }, - "node_modules/@babel/register/node_modules/find-up": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", - "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", - "license": "MIT", - "peer": true, - "dependencies": { - "locate-path": "^3.0.0" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/@babel/register/node_modules/locate-path": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", - "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", - "license": "MIT", - "peer": true, - "dependencies": { - "p-locate": "^3.0.0", - "path-exists": "^3.0.0" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/@babel/register/node_modules/p-limit": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", - "license": "MIT", - "peer": true, - "dependencies": { - "p-try": "^2.0.0" - }, - "engines": { - "node": ">=6" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/@babel/register/node_modules/p-locate": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", - "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "p-limit": "^2.0.0" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/@babel/register/node_modules/path-exists": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", - "integrity": "sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=4" - } - }, - "node_modules/@babel/register/node_modules/pkg-dir": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-3.0.0.tgz", - "integrity": "sha512-/E57AYkoeQ25qkxMj5PBOVgF8Kiu/h7cYS30Z5+R7WaiCCBfLq58ZI/dSeaEKb9WVJV5n/03QwrN3IeWIFllvw==", - "license": "MIT", - "peer": true, - "dependencies": { - "find-up": "^3.0.0" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/@babel/regjsgen": { - "version": "0.8.0", - "resolved": "https://registry.npmjs.org/@babel/regjsgen/-/regjsgen-0.8.0.tgz", - "integrity": "sha512-x/rqGMdzj+fWZvCOYForTghzbtqPDZ5gPwaoNGHdgDfF2QA/XZbCBp4Moo5scrkAMPhB7z26XM/AaHuIJdgauA==", - "license": "MIT" - }, - "node_modules/@babel/runtime": { - "version": "7.0.0-beta.55", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.0.0-beta.55.tgz", - "integrity": "sha512-0/cvrMwFQra0nC8mRdQ3JdMJWwQ4JkjA0EIUXQyd3eTcIb5r8UEOJYdG0dUIGqz5ROCIdqN6BJTg7QhQ55/xGQ==", - "license": "MIT", - "dependencies": { - "core-js": "^2.5.7", - "regenerator-runtime": "^0.12.0" - } - }, - "node_modules/@babel/template": { - "version": "7.26.9", - "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.26.9.tgz", - "integrity": "sha512-qyRplbeIpNZhmzOysF/wFMuP9sctmh2cFzRAZOn1YapxBsE1i9bJIY586R/WBLfLcmcBlM8ROBiQURnnNy+zfA==", - "license": "MIT", - "dependencies": { - "@babel/code-frame": "^7.26.2", - "@babel/parser": "^7.26.9", - "@babel/types": "^7.26.9" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@babel/traverse": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.25.6.tgz", - "integrity": "sha512-9Vrcx5ZW6UwK5tvqsj0nGpp/XzqthkT0dqIc9g1AdtygFToNtTF67XzYS//dm+SAK9cp3B9R4ZO/46p63SCjlQ==", + "node_modules/@babel/traverse": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.25.6.tgz", + "integrity": "sha512-9Vrcx5ZW6UwK5tvqsj0nGpp/XzqthkT0dqIc9g1AdtygFToNtTF67XzYS//dm+SAK9cp3B9R4ZO/46p63SCjlQ==", "license": "MIT", "dependencies": { "@babel/code-frame": "^7.24.7", @@ -2578,23 +2395,6 @@ "node": "^12.22.0 || ^14.17.0 || >=16.0.0" } }, - "node_modules/@hapi/hoek": { - "version": "9.3.0", - "resolved": "https://registry.npmjs.org/@hapi/hoek/-/hoek-9.3.0.tgz", - "integrity": "sha512-/c6rf4UJlmHlC9b5BaNvzAcFv7HZ2QHaV0D4/HNlBdvFnvQq8RI4kYdhyPCl7Xj+oWvTWQ8ujhqS53LIgAe6KQ==", - "license": "BSD-3-Clause", - "peer": true - }, - "node_modules/@hapi/topo": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/@hapi/topo/-/topo-5.1.0.tgz", - "integrity": "sha512-foQZKJig7Ob0BMAYBfcJk8d77QtOe7Wo4ox7ff1lQYoNNAb6jwcY1ncdoy2e9wQZzvNy7ODZCYJkK8kzmcAnAg==", - "license": "BSD-3-Clause", - "peer": true, - "dependencies": { - "@hapi/hoek": "^9.0.0" - } - }, "node_modules/@html-validate/stylish": { "version": "4.2.0", "resolved": "https://registry.npmjs.org/@html-validate/stylish/-/stylish-4.2.0.tgz", @@ -2711,170 +2511,6 @@ "url": "https://github.com/chalk/strip-ansi?sponsor=1" } }, - "node_modules/@isaacs/ttlcache": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/@isaacs/ttlcache/-/ttlcache-1.4.1.tgz", - "integrity": "sha512-RQgQ4uQ+pLbqXfOmieB91ejmLwvSgv9nLx6sT6sD83s7umBypgg+OIBOBbEUiJXrfpnp9j0mRhYYdzp9uqq3lA==", - "license": "ISC", - "peer": true, - "engines": { - "node": ">=12" - } - }, - "node_modules/@jest/create-cache-key-function": { - "version": "29.7.0", - "resolved": "https://registry.npmjs.org/@jest/create-cache-key-function/-/create-cache-key-function-29.7.0.tgz", - "integrity": "sha512-4QqS3LY5PBmTRHj9sAg1HLoPzqAI0uOX6wI/TRqHIcOxlFidy6YEmCQJk6FSZjNLGCeubDMfmkWL+qaLKhSGQA==", - "license": "MIT", - "peer": true, - "dependencies": { - "@jest/types": "^29.6.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" - } - }, - "node_modules/@jest/environment": { - "version": "29.7.0", - "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.7.0.tgz", - "integrity": "sha512-aQIfHDq33ExsN4jP1NWGXhxgQ/wixs60gDiKO+XVMd8Mn0NWPWgc34ZQDTb2jKaUWQ7MuwoitXAsN2XVXNMpAw==", - "license": "MIT", - "peer": true, - "dependencies": { - "@jest/fake-timers": "^29.7.0", - "@jest/types": "^29.6.3", - "@types/node": "*", - "jest-mock": "^29.7.0" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" - } - }, - "node_modules/@jest/fake-timers": { - "version": "29.7.0", - "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-29.7.0.tgz", - "integrity": "sha512-q4DH1Ha4TTFPdxLsqDXK1d3+ioSL7yL5oCMJZgDYm6i+6CygW5E5xVr/D1HdsGxjt1ZWSfUAs9OxSB/BNelWrQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "@jest/types": "^29.6.3", - "@sinonjs/fake-timers": "^10.0.2", - "@types/node": "*", - "jest-message-util": "^29.7.0", - "jest-mock": "^29.7.0", - "jest-util": "^29.7.0" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" - } - }, - "node_modules/@jest/schemas": { - "version": "29.6.3", - "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.6.3.tgz", - "integrity": "sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA==", - "license": "MIT", - "peer": true, - "dependencies": { - "@sinclair/typebox": "^0.27.8" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" - } - }, - "node_modules/@jest/types": { - "version": "29.6.3", - "resolved": "https://registry.npmjs.org/@jest/types/-/types-29.6.3.tgz", - "integrity": "sha512-u3UPsIilWKOM3F9CXtrG8LEJmNxwoCQC/XVj4IKYXvvpx7QIi/Kg1LI5uDmDpKlac62NUtX7eLjRh+jVZcLOzw==", - "license": "MIT", - "peer": true, - "dependencies": { - "@jest/schemas": "^29.6.3", - "@types/istanbul-lib-coverage": "^2.0.0", - "@types/istanbul-reports": "^3.0.0", - "@types/node": "*", - "@types/yargs": "^17.0.8", - "chalk": "^4.0.0" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" - } - }, - "node_modules/@jest/types/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "license": "MIT", - "peer": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@jest/types/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "license": "MIT", - "peer": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@jest/types/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@jest/types/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT", - "peer": true - }, - "node_modules/@jest/types/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@jest/types/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "license": "MIT", - "peer": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/@jridgewell/gen-mapping": { "version": "0.3.5", "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz", @@ -2911,6 +2547,7 @@ "version": "0.3.6", "resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.6.tgz", "integrity": "sha512-1ZJTZebgqllO79ue2bm3rIGud/bOe0pP5BjSRCRxxYkEZS8STV7zN84UBbiYu7jy+eCKSnVIUgoWWE/tt+shMQ==", + "dev": true, "license": "MIT", "dependencies": { "@jridgewell/gen-mapping": "^0.3.5", @@ -3013,6 +2650,7 @@ "version": "2.1.5", "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==", + "dev": true, "license": "MIT", "dependencies": { "@nodelib/fs.stat": "2.0.5", @@ -3026,6 +2664,7 @@ "version": "2.0.5", "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz", "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==", + "dev": true, "license": "MIT", "engines": { "node": ">= 8" @@ -3035,6 +2674,7 @@ "version": "1.2.8", "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz", "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==", + "dev": true, "license": "MIT", "dependencies": { "@nodelib/fs.scandir": "2.1.5", @@ -3378,1075 +3018,892 @@ "url": "https://opencollective.com/unts" } }, - "node_modules/@react-native-community/cli": { - "version": "14.1.0", - "resolved": "https://registry.npmjs.org/@react-native-community/cli/-/cli-14.1.0.tgz", - "integrity": "sha512-k7aTdKNZIec7WMSqMJn9bDVLWPPOaYmshXcnjWy6t5ItsJnREju9p2azMTR5tXY5uIeynose3cxettbhk2Tbnw==", - "license": "MIT", - "peer": true, - "dependencies": { - "@react-native-community/cli-clean": "14.1.0", - "@react-native-community/cli-config": "14.1.0", - "@react-native-community/cli-debugger-ui": "14.1.0", - "@react-native-community/cli-doctor": "14.1.0", - "@react-native-community/cli-server-api": "14.1.0", - "@react-native-community/cli-tools": "14.1.0", - "@react-native-community/cli-types": "14.1.0", - "chalk": "^4.1.2", - "commander": "^9.4.1", - "deepmerge": "^4.3.0", - "execa": "^5.0.0", - "find-up": "^5.0.0", - "fs-extra": "^8.1.0", - "graceful-fs": "^4.1.3", - "prompts": "^2.4.2", - "semver": "^7.5.2" - }, - "bin": { - "rnc-cli": "build/bin.js" - }, - "engines": { - "node": ">=18" - } - }, - "node_modules/@react-native-community/cli-clean": { - "version": "14.1.0", - "resolved": "https://registry.npmjs.org/@react-native-community/cli-clean/-/cli-clean-14.1.0.tgz", - "integrity": "sha512-/C4j1yntLo6faztNgZnsDtgpGqa6j0+GYrxOY8LqaKAN03OCnoeUUKO6w78dycbYSGglc1xjJg2RZI/M2oF2AA==", - "license": "MIT", - "peer": true, - "dependencies": { - "@react-native-community/cli-tools": "14.1.0", - "chalk": "^4.1.2", - "execa": "^5.0.0", - "fast-glob": "^3.3.2" - } + "node_modules/@rtsao/scc": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@rtsao/scc/-/scc-1.1.0.tgz", + "integrity": "sha512-zt6OdqaDoOnJ1ZYsCYGt9YmWzDXl4vQdKTyJev62gFhRGKdx7mcT54V9KIjg+d2wi9EXsPvAPKe7i7WjfVWB8g==", + "dev": true, + "license": "MIT" }, - "node_modules/@react-native-community/cli-clean/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "license": "MIT", - "peer": true, + "node_modules/@sidvind/better-ajv-errors": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sidvind/better-ajv-errors/-/better-ajv-errors-3.0.1.tgz", + "integrity": "sha512-++1mEYIeozfnwWI9P1ECvOPoacy+CgDASrmGvXPMCcqgx0YUzB01vZ78uHdQ443V6sTY+e9MzHqmN9DOls02aw==", + "dev": true, + "license": "Apache-2.0", "dependencies": { - "color-convert": "^2.0.1" + "kleur": "^4.1.0" }, "engines": { - "node": ">=8" + "node": ">= 16.14" }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "peerDependencies": { + "ajv": "^6.12.3 || ^7.0.0 || ^8.0.0" } }, - "node_modules/@react-native-community/cli-clean/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/@sindresorhus/is": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/@sindresorhus/is/-/is-4.6.0.tgz", + "integrity": "sha512-t09vSN3MdfsyCHoFcTRCH/iUtG7OJ0CsjzB8cjAmKc/va/kIgeDI/TxsigdncE/4be734m0cvIYwNaV4i2XqAw==", + "dev": true, "license": "MIT", - "peer": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, "engines": { "node": ">=10" }, "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "url": "https://github.com/sindresorhus/is?sponsor=1" } }, - "node_modules/@react-native-community/cli-clean/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/@stylistic/stylelint-plugin": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/@stylistic/stylelint-plugin/-/stylelint-plugin-3.1.2.tgz", + "integrity": "sha512-tylFJGMQo62alGazK74MNxFjMagYOHmBZiePZFOJK2n13JZta0uVkB3Bh5qodUmOLtRH+uxH297EibK14UKm8g==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "color-name": "~1.1.4" + "@csstools/css-parser-algorithms": "^3.0.1", + "@csstools/css-tokenizer": "^3.0.1", + "@csstools/media-query-list-parser": "^3.0.1", + "is-plain-object": "^5.0.0", + "postcss-selector-parser": "^6.1.2", + "postcss-value-parser": "^4.2.0", + "style-search": "^0.1.0", + "stylelint": "^16.8.2" }, "engines": { - "node": ">=7.0.0" + "node": "^18.12 || >=20.9" + }, + "peerDependencies": { + "stylelint": "^16.8.0" } }, - "node_modules/@react-native-community/cli-clean/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT", - "peer": true - }, - "node_modules/@react-native-community/cli-clean/node_modules/execa": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", - "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", + "node_modules/@stylistic/stylelint-plugin/node_modules/postcss-selector-parser": { + "version": "6.1.2", + "resolved": "https://registry.npmjs.org/postcss-selector-parser/-/postcss-selector-parser-6.1.2.tgz", + "integrity": "sha512-Q8qQfPiZ+THO/3ZrOrO0cJJKfpYCagtMUkXbnEfmgUjwXg6z/WBeOyS9APBBPCTSiDV+s4SwQGu8yFsiMRIudg==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "cross-spawn": "^7.0.3", - "get-stream": "^6.0.0", - "human-signals": "^2.1.0", - "is-stream": "^2.0.0", - "merge-stream": "^2.0.0", - "npm-run-path": "^4.0.1", - "onetime": "^5.1.2", - "signal-exit": "^3.0.3", - "strip-final-newline": "^2.0.0" + "cssesc": "^3.0.0", + "util-deprecate": "^1.0.2" }, "engines": { - "node": ">=10" + "node": ">=4" + } + }, + "node_modules/@svgr/babel-plugin-add-jsx-attribute": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-add-jsx-attribute/-/babel-plugin-add-jsx-attribute-8.0.0.tgz", + "integrity": "sha512-b9MIk7yhdS1pMCZM8VeNfUlSKVRhsHZNMl5O9SfaX0l0t5wjdgu4IDzGB8bpnGBBOjGST3rRFVsaaEtI4W6f7g==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=14" }, "funding": { - "url": "https://github.com/sindresorhus/execa?sponsor=1" + "type": "github", + "url": "https://github.com/sponsors/gregberge" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@react-native-community/cli-clean/node_modules/get-stream": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", - "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", + "node_modules/@svgr/babel-plugin-remove-jsx-attribute": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-remove-jsx-attribute/-/babel-plugin-remove-jsx-attribute-8.0.0.tgz", + "integrity": "sha512-BcCkm/STipKvbCl6b7QFrMh/vx00vIP63k2eM66MfHJzPr6O2U0jYEViXkHJWqXqQYjdeA9cuCl5KWmlwjDvbA==", + "dev": true, "license": "MIT", - "peer": true, "engines": { - "node": ">=10" + "node": ">=14" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "type": "github", + "url": "https://github.com/sponsors/gregberge" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@react-native-community/cli-clean/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/@svgr/babel-plugin-remove-jsx-empty-expression": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-remove-jsx-empty-expression/-/babel-plugin-remove-jsx-empty-expression-8.0.0.tgz", + "integrity": "sha512-5BcGCBfBxB5+XSDSWnhTThfI9jcO5f0Ai2V24gZpG+wXF14BzwxxdDb4g6trdOux0rhibGs385BeFMSmxtS3uA==", + "dev": true, "license": "MIT", - "peer": true, "engines": { - "node": ">=8" + "node": ">=14" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/gregberge" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@react-native-community/cli-clean/node_modules/human-signals": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", - "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", - "license": "Apache-2.0", - "peer": true, + "node_modules/@svgr/babel-plugin-replace-jsx-attribute-value": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-replace-jsx-attribute-value/-/babel-plugin-replace-jsx-attribute-value-8.0.0.tgz", + "integrity": "sha512-KVQ+PtIjb1BuYT3ht8M5KbzWBhdAjjUPdlMtpuw/VjT8coTrItWX6Qafl9+ji831JaJcu6PJNKCV0bp01lBNzQ==", + "dev": true, + "license": "MIT", "engines": { - "node": ">=10.17.0" + "node": ">=14" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/gregberge" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@react-native-community/cli-clean/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/@svgr/babel-plugin-svg-dynamic-title": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-svg-dynamic-title/-/babel-plugin-svg-dynamic-title-8.0.0.tgz", + "integrity": "sha512-omNiKqwjNmOQJ2v6ge4SErBbkooV2aAWwaPFs2vUY7p7GhVkzRkJ00kILXQvRhA6miHnNpXv7MRnnSjdRjK8og==", + "dev": true, "license": "MIT", - "peer": true, - "dependencies": { - "has-flag": "^4.0.0" - }, "engines": { - "node": ">=8" + "node": ">=14" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/gregberge" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@react-native-community/cli-config": { - "version": "14.1.0", - "resolved": "https://registry.npmjs.org/@react-native-community/cli-config/-/cli-config-14.1.0.tgz", - "integrity": "sha512-P3FK2rPUJBD1fmQHLgTqpHxsc111pnMdEEFR7KeqprCNz+Qr2QpPxfNy0V7s15tGL5rAv+wpbOGcioIV50EbxA==", + "node_modules/@svgr/babel-plugin-svg-em-dimensions": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-svg-em-dimensions/-/babel-plugin-svg-em-dimensions-8.0.0.tgz", + "integrity": "sha512-mURHYnu6Iw3UBTbhGwE/vsngtCIbHE43xCRK7kCw4t01xyGqb2Pd+WXekRRoFOBIY29ZoOhUCTEweDMdrjfi9g==", + "dev": true, "license": "MIT", - "peer": true, - "dependencies": { - "@react-native-community/cli-tools": "14.1.0", - "chalk": "^4.1.2", - "cosmiconfig": "^9.0.0", - "deepmerge": "^4.3.0", - "fast-glob": "^3.3.2", - "joi": "^17.2.1" + "engines": { + "node": ">=14" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/gregberge" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@react-native-community/cli-config/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/@svgr/babel-plugin-transform-react-native-svg": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-transform-react-native-svg/-/babel-plugin-transform-react-native-svg-8.1.0.tgz", + "integrity": "sha512-Tx8T58CHo+7nwJ+EhUwx3LfdNSG9R2OKfaIXXs5soiy5HtgoAEkDay9LIimLOcG8dJQH1wPZp/cnAv6S9CrR1Q==", + "dev": true, "license": "MIT", - "peer": true, - "dependencies": { - "color-convert": "^2.0.1" - }, "engines": { - "node": ">=8" + "node": ">=14" }, "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "type": "github", + "url": "https://github.com/sponsors/gregberge" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@react-native-community/cli-config/node_modules/argparse": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", - "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", - "license": "Python-2.0", - "peer": true + "node_modules/@svgr/babel-plugin-transform-svg-component": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-transform-svg-component/-/babel-plugin-transform-svg-component-8.0.0.tgz", + "integrity": "sha512-DFx8xa3cZXTdb/k3kfPeaixecQLgKh5NVBMwD0AQxOzcZawK4oo1Jh9LbrcACUivsCA7TLG8eeWgrDXjTMhRmw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/gregberge" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } }, - "node_modules/@react-native-community/cli-config/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/@svgr/babel-preset": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/@svgr/babel-preset/-/babel-preset-8.1.0.tgz", + "integrity": "sha512-7EYDbHE7MxHpv4sxvnVPngw5fuR6pw79SkcrILHJ/iMpuKySNCl5W1qcwPEpU+LgyRXOaAFgH0KhwD18wwg6ug==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "@svgr/babel-plugin-add-jsx-attribute": "8.0.0", + "@svgr/babel-plugin-remove-jsx-attribute": "8.0.0", + "@svgr/babel-plugin-remove-jsx-empty-expression": "8.0.0", + "@svgr/babel-plugin-replace-jsx-attribute-value": "8.0.0", + "@svgr/babel-plugin-svg-dynamic-title": "8.0.0", + "@svgr/babel-plugin-svg-em-dimensions": "8.0.0", + "@svgr/babel-plugin-transform-react-native-svg": "8.1.0", + "@svgr/babel-plugin-transform-svg-component": "8.0.0" }, "engines": { - "node": ">=10" + "node": ">=14" }, "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "type": "github", + "url": "https://github.com/sponsors/gregberge" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" } }, - "node_modules/@react-native-community/cli-config/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/@svgr/core": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/@svgr/core/-/core-8.1.0.tgz", + "integrity": "sha512-8QqtOQT5ACVlmsvKOJNEaWmRPmcojMOzCz4Hs2BGG/toAp/K38LcsMRyLp349glq5AzJbCEeimEoxaX6v/fLrA==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "color-name": "~1.1.4" + "@babel/core": "^7.21.3", + "@svgr/babel-preset": "8.1.0", + "camelcase": "^6.2.0", + "cosmiconfig": "^8.1.3", + "snake-case": "^3.0.4" }, "engines": { - "node": ">=7.0.0" + "node": ">=14" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/gregberge" } }, - "node_modules/@react-native-community/cli-config/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT", - "peer": true - }, - "node_modules/@react-native-community/cli-config/node_modules/cosmiconfig": { - "version": "9.0.0", - "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-9.0.0.tgz", - "integrity": "sha512-itvL5h8RETACmOTFc4UfIyB2RfEHi71Ax6E/PivVxq9NseKbOWpeyHEOIbmAw1rs8Ak0VursQNww7lf7YtUwzg==", + "node_modules/@svgr/hast-util-to-babel-ast": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/@svgr/hast-util-to-babel-ast/-/hast-util-to-babel-ast-8.0.0.tgz", + "integrity": "sha512-EbDKwO9GpfWP4jN9sGdYwPBU0kdomaPIL2Eu4YwmgP+sJeXT+L7bMwJUBnhzfH8Q2qMBqZ4fJwpCyYsAN3mt2Q==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "env-paths": "^2.2.1", - "import-fresh": "^3.3.0", - "js-yaml": "^4.1.0", - "parse-json": "^5.2.0" + "@babel/types": "^7.21.3", + "entities": "^4.4.0" }, "engines": { "node": ">=14" }, "funding": { - "url": "https://github.com/sponsors/d-fischer" - }, - "peerDependencies": { - "typescript": ">=4.9.5" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } - } - }, - "node_modules/@react-native-community/cli-config/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@react-native-community/cli-config/node_modules/js-yaml": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", - "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", - "license": "MIT", - "peer": true, - "dependencies": { - "argparse": "^2.0.1" - }, - "bin": { - "js-yaml": "bin/js-yaml.js" - } - }, - "node_modules/@react-native-community/cli-config/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "license": "MIT", - "peer": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/@react-native-community/cli-debugger-ui": { - "version": "14.1.0", - "resolved": "https://registry.npmjs.org/@react-native-community/cli-debugger-ui/-/cli-debugger-ui-14.1.0.tgz", - "integrity": "sha512-+YbeCL0wLcBcqDwraJFGsqzcXu9S+bwTVrfImne/4mT6itfe3Oa93yrOVJgNbstrt5pJHuwpU76ZXfXoiuncsg==", - "license": "MIT", - "peer": true, - "dependencies": { - "serve-static": "^1.13.1" - } - }, - "node_modules/@react-native-community/cli-doctor": { - "version": "14.1.0", - "resolved": "https://registry.npmjs.org/@react-native-community/cli-doctor/-/cli-doctor-14.1.0.tgz", - "integrity": "sha512-xIf0oQDRKt7lufUenRwcLYdINGc0x1FSXHaHjd7lQDGT5FJnCEYlIkYEDDgAl5tnVJSvM/IL2c6O+mffkNEPzQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "@react-native-community/cli-config": "14.1.0", - "@react-native-community/cli-platform-android": "14.1.0", - "@react-native-community/cli-platform-apple": "14.1.0", - "@react-native-community/cli-platform-ios": "14.1.0", - "@react-native-community/cli-tools": "14.1.0", - "chalk": "^4.1.2", - "command-exists": "^1.2.8", - "deepmerge": "^4.3.0", - "envinfo": "^7.13.0", - "execa": "^5.0.0", - "node-stream-zip": "^1.9.1", - "ora": "^5.4.1", - "semver": "^7.5.2", - "strip-ansi": "^5.2.0", - "wcwidth": "^1.0.1", - "yaml": "^2.2.1" + "type": "github", + "url": "https://github.com/sponsors/gregberge" } }, - "node_modules/@react-native-community/cli-doctor/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/@svgr/plugin-jsx": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/@svgr/plugin-jsx/-/plugin-jsx-8.1.0.tgz", + "integrity": "sha512-0xiIyBsLlr8quN+WyuxooNW9RJ0Dpr8uOnH/xrCVO8GLUcwHISwj1AG0k+LFzteTkAA0GbX0kj9q6Dk70PTiPA==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "color-convert": "^2.0.1" + "@babel/core": "^7.21.3", + "@svgr/babel-preset": "8.1.0", + "@svgr/hast-util-to-babel-ast": "8.0.0", + "svg-parser": "^2.0.4" }, "engines": { - "node": ">=8" + "node": ">=14" }, "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "type": "github", + "url": "https://github.com/sponsors/gregberge" + }, + "peerDependencies": { + "@svgr/core": "*" } }, - "node_modules/@react-native-community/cli-doctor/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/@svgr/plugin-svgo": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/@svgr/plugin-svgo/-/plugin-svgo-8.1.0.tgz", + "integrity": "sha512-Ywtl837OGO9pTLIN/onoWLmDQ4zFUycI1g76vuKGEz6evR/ZTJlJuz3G/fIkb6OVBJ2g0o6CGJzaEjfmEo3AHA==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "cosmiconfig": "^8.1.3", + "deepmerge": "^4.3.1", + "svgo": "^3.0.2" }, "engines": { - "node": ">=10" + "node": ">=14" }, "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@react-native-community/cli-doctor/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "color-name": "~1.1.4" + "type": "github", + "url": "https://github.com/sponsors/gregberge" }, - "engines": { - "node": ">=7.0.0" + "peerDependencies": { + "@svgr/core": "*" } }, - "node_modules/@react-native-community/cli-doctor/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT", - "peer": true - }, - "node_modules/@react-native-community/cli-doctor/node_modules/execa": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", - "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", + "node_modules/@svgr/webpack": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/@svgr/webpack/-/webpack-8.1.0.tgz", + "integrity": "sha512-LnhVjMWyMQV9ZmeEy26maJk+8HTIbd59cH4F2MJ439k9DqejRisfFNGAPvRYlKETuh9LrImlS8aKsBgKjMA8WA==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "cross-spawn": "^7.0.3", - "get-stream": "^6.0.0", - "human-signals": "^2.1.0", - "is-stream": "^2.0.0", - "merge-stream": "^2.0.0", - "npm-run-path": "^4.0.1", - "onetime": "^5.1.2", - "signal-exit": "^3.0.3", - "strip-final-newline": "^2.0.0" + "@babel/core": "^7.21.3", + "@babel/plugin-transform-react-constant-elements": "^7.21.3", + "@babel/preset-env": "^7.20.2", + "@babel/preset-react": "^7.18.6", + "@babel/preset-typescript": "^7.21.0", + "@svgr/core": "8.1.0", + "@svgr/plugin-jsx": "8.1.0", + "@svgr/plugin-svgo": "8.1.0" }, "engines": { - "node": ">=10" + "node": ">=14" }, "funding": { - "url": "https://github.com/sindresorhus/execa?sponsor=1" + "type": "github", + "url": "https://github.com/sponsors/gregberge" } }, - "node_modules/@react-native-community/cli-doctor/node_modules/get-stream": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", - "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", + "node_modules/@szmarczak/http-timer": { + "version": "4.0.6", + "resolved": "https://registry.npmjs.org/@szmarczak/http-timer/-/http-timer-4.0.6.tgz", + "integrity": "sha512-4BAffykYOgO+5nzBWYwE3W90sBgLJoUPRWWcL8wlyiM8IB8ipJz3UMJ9KXQd1RKQXpKp8Tutn80HZtWsu2u76w==", + "dev": true, "license": "MIT", - "peer": true, + "dependencies": { + "defer-to-connect": "^2.0.0" + }, "engines": { "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@react-native-community/cli-doctor/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/@tannin/compile": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@tannin/compile/-/compile-1.1.0.tgz", + "integrity": "sha512-n8m9eNDfoNZoxdvWiTfW/hSPhehzLJ3zW7f8E7oT6mCROoMNWCB4TYtv041+2FMAxweiE0j7i1jubQU4MEC/Gg==", "license": "MIT", - "peer": true, - "engines": { - "node": ">=8" + "dependencies": { + "@tannin/evaluate": "^1.2.0", + "@tannin/postfix": "^1.1.0" } }, - "node_modules/@react-native-community/cli-doctor/node_modules/human-signals": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", - "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", - "license": "Apache-2.0", - "peer": true, - "engines": { - "node": ">=10.17.0" - } + "node_modules/@tannin/evaluate": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/@tannin/evaluate/-/evaluate-1.2.0.tgz", + "integrity": "sha512-3ioXvNowbO/wSrxsDG5DKIMxC81P0QrQTYai8zFNY+umuoHWRPbQ/TuuDEOju9E+jQDXmj6yI5GyejNuh8I+eg==", + "license": "MIT" }, - "node_modules/@react-native-community/cli-doctor/node_modules/ora": { - "version": "5.4.1", - "resolved": "https://registry.npmjs.org/ora/-/ora-5.4.1.tgz", - "integrity": "sha512-5b6Y85tPxZZ7QytO+BQzysW31HJku27cRIlkbAXaNx+BdcVi+LlRFmVXzeF6a7JCwJpyw5c4b+YSVImQIrBpuQ==", + "node_modules/@tannin/plural-forms": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@tannin/plural-forms/-/plural-forms-1.1.0.tgz", + "integrity": "sha512-xl9R2mDZO/qiHam1AgMnAES6IKIg7OBhcXqy6eDsRCdXuxAFPcjrej9HMjyCLE0DJ/8cHf0i5OQTstuBRhpbHw==", "license": "MIT", - "peer": true, "dependencies": { - "bl": "^4.1.0", - "chalk": "^4.1.0", - "cli-cursor": "^3.1.0", - "cli-spinners": "^2.5.0", - "is-interactive": "^1.0.0", - "is-unicode-supported": "^0.1.0", - "log-symbols": "^4.1.0", - "strip-ansi": "^6.0.0", - "wcwidth": "^1.0.1" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "@tannin/compile": "^1.1.0" } }, - "node_modules/@react-native-community/cli-doctor/node_modules/ora/node_modules/strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "license": "MIT", - "peer": true, - "dependencies": { - "ansi-regex": "^5.0.1" - }, - "engines": { - "node": ">=8" - } + "node_modules/@tannin/postfix": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@tannin/postfix/-/postfix-1.1.0.tgz", + "integrity": "sha512-oocsqY7g0cR+Gur5jRQLSrX2OtpMLMse1I10JQBm8CdGMrDkh1Mg2gjsiquMHRtBs4Qwu5wgEp5GgIYHk4SNPw==", + "license": "MIT" }, - "node_modules/@react-native-community/cli-doctor/node_modules/semver": { - "version": "7.6.3", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", - "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", + "node_modules/@trysound/sax": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/@trysound/sax/-/sax-0.2.0.tgz", + "integrity": "sha512-L7z9BgrNEcYyUYtF+HaEfiS5ebkh9jXqbszz7pC0hRBPaatV0XjSD3+eHrpqFemQfgwiFF0QPIarnIihIDn7OA==", + "dev": true, "license": "ISC", - "peer": true, - "bin": { - "semver": "bin/semver.js" - }, "engines": { - "node": ">=10" + "node": ">=10.13.0" } }, - "node_modules/@react-native-community/cli-doctor/node_modules/strip-ansi": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "node_modules/@types/body-parser": { + "version": "1.19.5", + "resolved": "https://registry.npmjs.org/@types/body-parser/-/body-parser-1.19.5.tgz", + "integrity": "sha512-fB3Zu92ucau0iQ0JMCFQE7b/dv8Ot07NI3KaZIkIUNXq82k4eBAqUaneXfleGY9JWskeS9y+u0nXMyspcuQrCg==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "ansi-regex": "^4.1.0" - }, - "engines": { - "node": ">=6" + "@types/connect": "*", + "@types/node": "*" } }, - "node_modules/@react-native-community/cli-doctor/node_modules/strip-ansi/node_modules/ansi-regex": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.1.tgz", - "integrity": "sha512-ILlv4k/3f6vfQ4OoP2AGvirOktlQ98ZEL1k9FaQjxa3L1abBgbuTDAdPOpvbGncC0BTVQrl+OM8xZGK6tWXt7g==", + "node_modules/@types/bonjour": { + "version": "3.5.13", + "resolved": "https://registry.npmjs.org/@types/bonjour/-/bonjour-3.5.13.tgz", + "integrity": "sha512-z9fJ5Im06zvUL548KvYNecEVlA7cVDkGUi6kZusb04mpyEFKCIZJvloCcmpmLaIahDpOQGHaHmG6imtPMmPXGQ==", + "dev": true, "license": "MIT", - "peer": true, - "engines": { - "node": ">=6" + "dependencies": { + "@types/node": "*" } }, - "node_modules/@react-native-community/cli-doctor/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/@types/cacheable-request": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/@types/cacheable-request/-/cacheable-request-6.0.3.tgz", + "integrity": "sha512-IQ3EbTzGxIigb1I3qPZc1rWJnH0BmSKv5QYTalEwweFvyBDLSAe24zP0le/hyi7ecGfZVlIVAg4BZqb8WBwKqw==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" + "@types/http-cache-semantics": "*", + "@types/keyv": "^3.1.4", + "@types/node": "*", + "@types/responselike": "^1.0.0" } }, - "node_modules/@react-native-community/cli-platform-android": { - "version": "14.1.0", - "resolved": "https://registry.npmjs.org/@react-native-community/cli-platform-android/-/cli-platform-android-14.1.0.tgz", - "integrity": "sha512-4JnXkAV+ca8XdUhZ7xjgDhXAMwTVjQs8JqiwP7FTYVrayShXy2cBXm/C3HNDoe+oQOF5tPT2SqsDAF2vYTnKiQ==", + "node_modules/@types/connect": { + "version": "3.4.38", + "resolved": "https://registry.npmjs.org/@types/connect/-/connect-3.4.38.tgz", + "integrity": "sha512-K6uROf1LD88uDQqJCktA4yzL1YYAK6NgfsI0v/mTgyPKWsX1CnJ0XPSDhViejru1GcRkLWb8RlzFYJRqGUbaug==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "@react-native-community/cli-tools": "14.1.0", - "chalk": "^4.1.2", - "execa": "^5.0.0", - "fast-glob": "^3.3.2", - "fast-xml-parser": "^4.4.1", - "logkitty": "^0.7.1" + "@types/node": "*" } }, - "node_modules/@react-native-community/cli-platform-android/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/@types/connect-history-api-fallback": { + "version": "1.5.4", + "resolved": "https://registry.npmjs.org/@types/connect-history-api-fallback/-/connect-history-api-fallback-1.5.4.tgz", + "integrity": "sha512-n6Cr2xS1h4uAulPRdlw6Jl6s1oG8KrVilPN2yUITEs+K48EzMJJ3W1xy8K5eWuFvjp3R74AOIGSmp2UfBJ8HFw==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "@types/express-serve-static-core": "*", + "@types/node": "*" } }, - "node_modules/@react-native-community/cli-platform-android/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/@types/estree": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.6.tgz", + "integrity": "sha512-AYnb1nQyY49te+VRAVgmzfcgjYS91mY5P0TKUDCLEM+gNnA+3T6rWITXRLYCpahpqSQbN5cE+gHpnPyXjHWxcw==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/express": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/@types/express/-/express-4.17.21.tgz", + "integrity": "sha512-ejlPM315qwLpaQlQDTjPdsUFSc6ZsP4AN6AlWnogPjQ7CVi7PYF3YVz+CY3jE2pwYf7E/7HlDAN0rV2GxTG0HQ==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "@types/body-parser": "*", + "@types/express-serve-static-core": "^4.17.33", + "@types/qs": "*", + "@types/serve-static": "*" } }, - "node_modules/@react-native-community/cli-platform-android/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/@types/express-serve-static-core": { + "version": "4.19.5", + "resolved": "https://registry.npmjs.org/@types/express-serve-static-core/-/express-serve-static-core-4.19.5.tgz", + "integrity": "sha512-y6W03tvrACO72aijJ5uF02FRq5cgDR9lUxddQ8vyF+GvmjJQqbzDcJngEjURc+ZsG31VI3hODNZJ2URj86pzmg==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" + "@types/node": "*", + "@types/qs": "*", + "@types/range-parser": "*", + "@types/send": "*" } }, - "node_modules/@react-native-community/cli-platform-android/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT", - "peer": true + "node_modules/@types/http-cache-semantics": { + "version": "4.0.4", + "resolved": "https://registry.npmjs.org/@types/http-cache-semantics/-/http-cache-semantics-4.0.4.tgz", + "integrity": "sha512-1m0bIFVc7eJWyve9S0RnuRgcQqF/Xd5QsUZAZeQFr1Q3/p9JWoQQEqmVy+DPTNpGXwhgIetAoYF8JSc33q29QA==", + "dev": true, + "license": "MIT" }, - "node_modules/@react-native-community/cli-platform-android/node_modules/execa": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", - "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", + "node_modules/@types/http-errors": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/@types/http-errors/-/http-errors-2.0.4.tgz", + "integrity": "sha512-D0CFMMtydbJAegzOyHjtiKPLlvnm3iTZyZRSZoLq2mRhDdmLfIWOCYPfQJ4cu2erKghU++QvjcUjp/5h7hESpA==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/http-proxy": { + "version": "1.17.15", + "resolved": "https://registry.npmjs.org/@types/http-proxy/-/http-proxy-1.17.15.tgz", + "integrity": "sha512-25g5atgiVNTIv0LBDTg1H74Hvayx0ajtJPLLcYE3whFv75J0pWNtOBzaXJQgDTmrX1bx5U9YC2w/n65BN1HwRQ==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "cross-spawn": "^7.0.3", - "get-stream": "^6.0.0", - "human-signals": "^2.1.0", - "is-stream": "^2.0.0", - "merge-stream": "^2.0.0", - "npm-run-path": "^4.0.1", - "onetime": "^5.1.2", - "signal-exit": "^3.0.3", - "strip-final-newline": "^2.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sindresorhus/execa?sponsor=1" + "@types/node": "*" } }, - "node_modules/@react-native-community/cli-platform-android/node_modules/get-stream": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", - "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } + "node_modules/@types/json-schema": { + "version": "7.0.15", + "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.15.tgz", + "integrity": "sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==", + "dev": true, + "license": "MIT" }, - "node_modules/@react-native-community/cli-platform-android/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/@types/json5": { + "version": "0.0.29", + "resolved": "https://registry.npmjs.org/@types/json5/-/json5-0.0.29.tgz", + "integrity": "sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/keyv": { + "version": "3.1.4", + "resolved": "https://registry.npmjs.org/@types/keyv/-/keyv-3.1.4.tgz", + "integrity": "sha512-BQ5aZNSCpj7D6K2ksrRCTmKRLEpnPvWDiLPfoGyhZ++8YtiK9d/3DBKPJgry359X/P1PfruyYwvnvwFjuEiEIg==", + "dev": true, "license": "MIT", - "peer": true, - "engines": { - "node": ">=8" + "dependencies": { + "@types/node": "*" } }, - "node_modules/@react-native-community/cli-platform-android/node_modules/human-signals": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", - "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", - "license": "Apache-2.0", - "peer": true, - "engines": { - "node": ">=10.17.0" - } + "node_modules/@types/mime": { + "version": "1.3.5", + "resolved": "https://registry.npmjs.org/@types/mime/-/mime-1.3.5.tgz", + "integrity": "sha512-/pyBZWSLD2n0dcHE3hq8s8ZvcETHtEuF+3E7XVt0Ig2nvsVQXdghHVcEkIWjy9A0wKfTn97a/PSDYohKIlnP/w==", + "dev": true, + "license": "MIT" }, - "node_modules/@react-native-community/cli-platform-android/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/@types/node": { + "version": "22.5.5", + "resolved": "https://registry.npmjs.org/@types/node/-/node-22.5.5.tgz", + "integrity": "sha512-Xjs4y5UPO/CLdzpgR6GirZJx36yScjh73+2NlLlkFRSoQN8B0DpfXPdZGnvVmLRLOsqDpOfTNv7D9trgGhmOIA==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" + "undici-types": "~6.19.2" } }, - "node_modules/@react-native-community/cli-platform-apple": { - "version": "14.1.0", - "resolved": "https://registry.npmjs.org/@react-native-community/cli-platform-apple/-/cli-platform-apple-14.1.0.tgz", - "integrity": "sha512-DExd+pZ7hHxXt8I6BBmckeYUxxq7PQ+o4YSmGIeQx0xUpi+f82obBct2WNC3VWU72Jw6obwfoN6Fwe6F7Wxp5Q==", + "node_modules/@types/node-forge": { + "version": "1.3.11", + "resolved": "https://registry.npmjs.org/@types/node-forge/-/node-forge-1.3.11.tgz", + "integrity": "sha512-FQx220y22OKNTqaByeBGqHWYz4cl94tpcxeFdvBo3wjG6XPBuZ0BNgNZRV5J5TFmmcsJ4IzsLkmGRiQbnYsBEQ==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "@react-native-community/cli-tools": "14.1.0", - "chalk": "^4.1.2", - "execa": "^5.0.0", - "fast-glob": "^3.3.2", - "fast-xml-parser": "^4.4.1", - "ora": "^5.4.1" + "@types/node": "*" } }, - "node_modules/@react-native-community/cli-platform-apple/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/@types/parse-json": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@types/parse-json/-/parse-json-4.0.2.tgz", + "integrity": "sha512-dISoDXWWQwUquiKsyZ4Ng+HX2KsPL7LyHKHQwgGFEA3IaKac4Obd+h2a/a6waisAoepJlBcx9paWqjA8/HVjCw==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/prop-types": { + "version": "15.7.13", + "resolved": "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.13.tgz", + "integrity": "sha512-hCZTSvwbzWGvhqxp/RqVqwU999pBf2vp7hzIjiYOsl8wqOmUxkQ6ddw1cV3l8811+kdUFus/q4d1Y3E3SyEifA==", + "license": "MIT" + }, + "node_modules/@types/qs": { + "version": "6.9.16", + "resolved": "https://registry.npmjs.org/@types/qs/-/qs-6.9.16.tgz", + "integrity": "sha512-7i+zxXdPD0T4cKDuxCUXJ4wHcsJLwENa6Z3dCu8cfCK743OGy5Nu1RmAGqDPsoTDINVEcdXKRvR/zre+P2Ku1A==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/range-parser": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/@types/range-parser/-/range-parser-1.2.7.tgz", + "integrity": "sha512-hKormJbkJqzQGhziax5PItDUTMAM9uE2XXQmM37dyd4hVM+5aVl7oVxMVUiVQn2oCQFN/LKCZdvSM0pFRqbSmQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/react": { + "version": "16.14.61", + "resolved": "https://registry.npmjs.org/@types/react/-/react-16.14.61.tgz", + "integrity": "sha512-CK3zd17pDWAEMnN5TdzwQJQlto2dK/lb0WZsI74owWgQ8PR60WRk0sCeBxLWuSuuqqDZKqeUcxod/8yECqrP/g==", "license": "MIT", - "peer": true, "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "@types/prop-types": "*", + "@types/scheduler": "^0.16", + "csstype": "^3.0.2" } }, - "node_modules/@react-native-community/cli-platform-apple/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/@types/react-dom": { + "version": "16.9.24", + "resolved": "https://registry.npmjs.org/@types/react-dom/-/react-dom-16.9.24.tgz", + "integrity": "sha512-Gcmq2JTDheyWn/1eteqyzzWKSqDjYU6KYsIvH7thb7CR5OYInAWOX+7WnKf6PaU/cbdOc4szJItcDEJO7UGmfA==", "license": "MIT", - "peer": true, "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "@types/react": "^16" } }, - "node_modules/@react-native-community/cli-platform-apple/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/@types/responselike": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/@types/responselike/-/responselike-1.0.3.tgz", + "integrity": "sha512-H/+L+UkTV33uf49PH5pCAUBVPNj2nDBXTN+qS1dOwyyg24l3CcicicCA7ca+HMvJBZcFgl5r8e+RR6elsb4Lyw==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" + "@types/node": "*" } }, - "node_modules/@react-native-community/cli-platform-apple/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT", - "peer": true - }, - "node_modules/@react-native-community/cli-platform-apple/node_modules/execa": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", - "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", - "license": "MIT", - "peer": true, - "dependencies": { - "cross-spawn": "^7.0.3", - "get-stream": "^6.0.0", - "human-signals": "^2.1.0", - "is-stream": "^2.0.0", - "merge-stream": "^2.0.0", - "npm-run-path": "^4.0.1", - "onetime": "^5.1.2", - "signal-exit": "^3.0.3", - "strip-final-newline": "^2.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sindresorhus/execa?sponsor=1" - } - }, - "node_modules/@react-native-community/cli-platform-apple/node_modules/get-stream": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", - "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } + "node_modules/@types/retry": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/@types/retry/-/retry-0.12.0.tgz", + "integrity": "sha512-wWKOClTTiizcZhXnPY4wikVAwmdYHp8q6DmC+EJUzAMsycb7HB32Kh9RN4+0gExjmPmZSAQjgURXIGATPegAvA==", + "dev": true, + "license": "MIT" }, - "node_modules/@react-native-community/cli-platform-apple/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=8" - } + "node_modules/@types/scheduler": { + "version": "0.16.8", + "resolved": "https://registry.npmjs.org/@types/scheduler/-/scheduler-0.16.8.tgz", + "integrity": "sha512-WZLiwShhwLRmeV6zH+GkbOFT6Z6VklCItrDioxUnv+u4Ll+8vKeFySoFyK/0ctcRpOmwAicELfmys1sDc/Rw+A==", + "license": "MIT" }, - "node_modules/@react-native-community/cli-platform-apple/node_modules/human-signals": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", - "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", - "license": "Apache-2.0", - "peer": true, - "engines": { - "node": ">=10.17.0" - } + "node_modules/@types/semver": { + "version": "7.5.8", + "resolved": "https://registry.npmjs.org/@types/semver/-/semver-7.5.8.tgz", + "integrity": "sha512-I8EUhyrgfLrcTkzV3TSsGyl1tSuPrEDzr0yd5m90UgNxQkyDXULk3b6MlQqTCpZpNtWe1K0hzclnZkTcLBe2UQ==", + "dev": true, + "license": "MIT" }, - "node_modules/@react-native-community/cli-platform-apple/node_modules/ora": { - "version": "5.4.1", - "resolved": "https://registry.npmjs.org/ora/-/ora-5.4.1.tgz", - "integrity": "sha512-5b6Y85tPxZZ7QytO+BQzysW31HJku27cRIlkbAXaNx+BdcVi+LlRFmVXzeF6a7JCwJpyw5c4b+YSVImQIrBpuQ==", + "node_modules/@types/send": { + "version": "0.17.4", + "resolved": "https://registry.npmjs.org/@types/send/-/send-0.17.4.tgz", + "integrity": "sha512-x2EM6TJOybec7c52BX0ZspPodMsQUd5L6PRwOunVyVUhXiBSKf3AezDL8Dgvgt5o0UfKNfuA0eMLr2wLT4AiBA==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "bl": "^4.1.0", - "chalk": "^4.1.0", - "cli-cursor": "^3.1.0", - "cli-spinners": "^2.5.0", - "is-interactive": "^1.0.0", - "is-unicode-supported": "^0.1.0", - "log-symbols": "^4.1.0", - "strip-ansi": "^6.0.0", - "wcwidth": "^1.0.1" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "@types/mime": "^1", + "@types/node": "*" } }, - "node_modules/@react-native-community/cli-platform-apple/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/@types/serve-index": { + "version": "1.9.4", + "resolved": "https://registry.npmjs.org/@types/serve-index/-/serve-index-1.9.4.tgz", + "integrity": "sha512-qLpGZ/c2fhSs5gnYsQxtDEq3Oy8SXPClIXkW5ghvAvsNuVSA8k+gCONcUCS/UjLEYvYps+e8uBtfgXgvhwfNug==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" + "@types/express": "*" } }, - "node_modules/@react-native-community/cli-platform-ios": { - "version": "14.1.0", - "resolved": "https://registry.npmjs.org/@react-native-community/cli-platform-ios/-/cli-platform-ios-14.1.0.tgz", - "integrity": "sha512-ah/ZTiJXUdCVHujyRJ4OmCL5nTq8OWcURcE3UXa1z0sIIiA8io06n+v5n299T9rtPKMwRtVJlQjtO/nbODABPQ==", + "node_modules/@types/serve-static": { + "version": "1.15.7", + "resolved": "https://registry.npmjs.org/@types/serve-static/-/serve-static-1.15.7.tgz", + "integrity": "sha512-W8Ym+h8nhuRwaKPaDw34QUkwsGi6Rc4yYqvKFo5rm2FUEhCFbzVWrxXUxuKK8TASjWsysJY0nsmNCGhCOIsrOw==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "@react-native-community/cli-platform-apple": "14.1.0" + "@types/http-errors": "*", + "@types/node": "*", + "@types/send": "*" } }, - "node_modules/@react-native-community/cli-server-api": { - "version": "14.1.0", - "resolved": "https://registry.npmjs.org/@react-native-community/cli-server-api/-/cli-server-api-14.1.0.tgz", - "integrity": "sha512-1k2LBQaYsy9RDWFIfKVne3frOye73O33MV6eYMoRPff7wqxHCrsX1CYJQkmwpgVigZHxYwalHj+Axtu3gpomCA==", + "node_modules/@types/sinonjs__fake-timers": { + "version": "8.1.1", + "resolved": "https://registry.npmjs.org/@types/sinonjs__fake-timers/-/sinonjs__fake-timers-8.1.1.tgz", + "integrity": "sha512-0kSuKjAS0TrGLJ0M/+8MaFkGsQhZpB6pxOmvS3K8FYI72K//YmdfoW9X2qPsAKh1mkwxGD5zib9s1FIFed6E8g==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/sizzle": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/@types/sizzle/-/sizzle-2.3.8.tgz", + "integrity": "sha512-0vWLNK2D5MT9dg0iOo8GlKguPAU02QjmZitPEsXRuJXU/OGIOt9vT9Fc26wtYuavLxtO45v9PGleoL9Z0k1LHg==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/sockjs": { + "version": "0.3.36", + "resolved": "https://registry.npmjs.org/@types/sockjs/-/sockjs-0.3.36.tgz", + "integrity": "sha512-MK9V6NzAS1+Ud7JV9lJLFqW85VbC9dq3LmwZCuBe4wBDgKC0Kj/jd8Xl+nSviU+Qc3+m7umHHyHg//2KSa0a0Q==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "@react-native-community/cli-debugger-ui": "14.1.0", - "@react-native-community/cli-tools": "14.1.0", - "compression": "^1.7.1", - "connect": "^3.6.5", - "errorhandler": "^1.5.1", - "nocache": "^3.0.1", - "pretty-format": "^26.6.2", - "serve-static": "^1.13.1", - "ws": "^6.2.3" + "@types/node": "*" } }, - "node_modules/@react-native-community/cli-server-api/node_modules/ws": { - "version": "6.2.3", - "resolved": "https://registry.npmjs.org/ws/-/ws-6.2.3.tgz", - "integrity": "sha512-jmTjYU0j60B+vHey6TfR3Z7RD61z/hmxBS3VMSGIrroOWXQEneK1zNuotOUrGyBHQj0yrpsLHPWtigEFd13ndA==", + "node_modules/@types/ws": { + "version": "8.5.12", + "resolved": "https://registry.npmjs.org/@types/ws/-/ws-8.5.12.tgz", + "integrity": "sha512-3tPRkv1EtkDpzlgyKyI8pGsGZAGPEaXeu0DOj5DI25Ja91bdAYddYHbADRYVrZMRbfW+1l5YwXVDKohDJNQxkQ==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "async-limiter": "~1.0.0" + "@types/node": "*" } }, - "node_modules/@react-native-community/cli-tools": { - "version": "14.1.0", - "resolved": "https://registry.npmjs.org/@react-native-community/cli-tools/-/cli-tools-14.1.0.tgz", - "integrity": "sha512-r1KxSu2+OSuhWFoE//1UR7aSTXMLww/UYWQprEw4bSo/kvutGX//4r9ywgXSWp+39udpNN4jQpNTHuWhGZd/Bg==", + "node_modules/@types/yauzl": { + "version": "2.10.3", + "resolved": "https://registry.npmjs.org/@types/yauzl/-/yauzl-2.10.3.tgz", + "integrity": "sha512-oJoftv0LSuaDZE3Le4DbKX+KS9G36NzOeSap90UIK0yMA/NhKJhqlSGtNDORNRaIbQfzjXDrQa0ytJ6mNRGz/Q==", + "dev": true, "license": "MIT", - "peer": true, + "optional": true, "dependencies": { - "appdirsjs": "^1.2.4", - "chalk": "^4.1.2", - "execa": "^5.0.0", - "find-up": "^5.0.0", - "mime": "^2.4.1", - "open": "^6.2.0", - "ora": "^5.4.1", - "semver": "^7.5.2", - "shell-quote": "^1.7.3", - "sudo-prompt": "^9.0.0" + "@types/node": "*" } }, - "node_modules/@react-native-community/cli-tools/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/@typescript-eslint/eslint-plugin": { + "version": "5.62.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.62.0.tgz", + "integrity": "sha512-TiZzBSJja/LbhNPvk6yc0JrX9XqhQ0hdh6M2svYfsHGejaKFIAGd9MQ+ERIMzLGlN/kZoYIgdxFV0PuljTKXag==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "color-convert": "^2.0.1" + "@eslint-community/regexpp": "^4.4.0", + "@typescript-eslint/scope-manager": "5.62.0", + "@typescript-eslint/type-utils": "5.62.0", + "@typescript-eslint/utils": "5.62.0", + "debug": "^4.3.4", + "graphemer": "^1.4.0", + "ignore": "^5.2.0", + "natural-compare-lite": "^1.4.0", + "semver": "^7.3.7", + "tsutils": "^3.21.0" }, "engines": { - "node": ">=8" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" }, "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@react-native-community/cli-tools/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "license": "MIT", - "peer": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" }, - "engines": { - "node": ">=10" + "peerDependencies": { + "@typescript-eslint/parser": "^5.0.0", + "eslint": "^6.0.0 || ^7.0.0 || ^8.0.0" }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "peerDependenciesMeta": { + "typescript": { + "optional": true + } } }, - "node_modules/@react-native-community/cli-tools/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "color-name": "~1.1.4" + "node_modules/@typescript-eslint/eslint-plugin/node_modules/semver": { + "version": "7.6.3", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", + "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" }, "engines": { - "node": ">=7.0.0" + "node": ">=10" } }, - "node_modules/@react-native-community/cli-tools/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT", - "peer": true - }, - "node_modules/@react-native-community/cli-tools/node_modules/execa": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", - "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", - "license": "MIT", - "peer": true, + "node_modules/@typescript-eslint/parser": { + "version": "5.62.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-5.62.0.tgz", + "integrity": "sha512-VlJEV0fOQ7BExOsHYAGrgbEiZoi8D+Bl2+f6V2RrXerRSylnp+ZBHmPvaIa8cz0Ajx7WO7Z5RqfgYg7ED1nRhA==", + "dev": true, + "license": "BSD-2-Clause", "dependencies": { - "cross-spawn": "^7.0.3", - "get-stream": "^6.0.0", - "human-signals": "^2.1.0", - "is-stream": "^2.0.0", - "merge-stream": "^2.0.0", - "npm-run-path": "^4.0.1", - "onetime": "^5.1.2", - "signal-exit": "^3.0.3", - "strip-final-newline": "^2.0.0" + "@typescript-eslint/scope-manager": "5.62.0", + "@typescript-eslint/types": "5.62.0", + "@typescript-eslint/typescript-estree": "5.62.0", + "debug": "^4.3.4" }, "engines": { - "node": ">=10" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" }, "funding": { - "url": "https://github.com/sindresorhus/execa?sponsor=1" + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependencies": { + "eslint": "^6.0.0 || ^7.0.0 || ^8.0.0" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } } }, - "node_modules/@react-native-community/cli-tools/node_modules/get-stream": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", - "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", + "node_modules/@typescript-eslint/scope-manager": { + "version": "5.62.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-5.62.0.tgz", + "integrity": "sha512-VXuvVvZeQCQb5Zgf4HAxc04q5j+WrNAtNh9OwCsCgpKqESMTu3tF/jhZ3xG6T4NZwWl65Bg8KuS2uEvhSfLl0w==", + "dev": true, "license": "MIT", - "peer": true, + "dependencies": { + "@typescript-eslint/types": "5.62.0", + "@typescript-eslint/visitor-keys": "5.62.0" + }, "engines": { - "node": ">=10" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" } }, - "node_modules/@react-native-community/cli-tools/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@react-native-community/cli-tools/node_modules/human-signals": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", - "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", - "license": "Apache-2.0", - "peer": true, - "engines": { - "node": ">=10.17.0" - } - }, - "node_modules/@react-native-community/cli-tools/node_modules/is-wsl": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/is-wsl/-/is-wsl-1.1.0.tgz", - "integrity": "sha512-gfygJYZ2gLTDlmbWMI0CE2MwnFzSN/2SZfkMlItC4K/JBlsWVDB0bO6XhqcY13YXE7iMcAJnzTCJjPiTeJJ0Mw==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=4" - } - }, - "node_modules/@react-native-community/cli-tools/node_modules/mime": { - "version": "2.6.0", - "resolved": "https://registry.npmjs.org/mime/-/mime-2.6.0.tgz", - "integrity": "sha512-USPkMeET31rOMiarsBNIHZKLGgvKc/LrjofAnBlOttf5ajRvqiRA8QsenbcooctK6d6Ts6aqZXBA+XbkKthiQg==", + "node_modules/@typescript-eslint/type-utils": { + "version": "5.62.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-5.62.0.tgz", + "integrity": "sha512-xsSQreu+VnfbqQpW5vnCJdq1Z3Q0U31qiWmRhr98ONQmcp/yhiPJFPq8MXiJVLiksmOKSjIldZzkebzHuCGzew==", + "dev": true, "license": "MIT", - "peer": true, - "bin": { - "mime": "cli.js" + "dependencies": { + "@typescript-eslint/typescript-estree": "5.62.0", + "@typescript-eslint/utils": "5.62.0", + "debug": "^4.3.4", + "tsutils": "^3.21.0" }, "engines": { - "node": ">=4.0.0" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependencies": { + "eslint": "*" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } } }, - "node_modules/@react-native-community/cli-tools/node_modules/open": { - "version": "6.4.0", - "resolved": "https://registry.npmjs.org/open/-/open-6.4.0.tgz", - "integrity": "sha512-IFenVPgF70fSm1keSd2iDBIDIBZkroLeuffXq+wKTzTJlBpesFWojV9lb8mzOfaAzM1sr7HQHuO0vtV0zYekGg==", + "node_modules/@typescript-eslint/types": { + "version": "5.62.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-5.62.0.tgz", + "integrity": "sha512-87NVngcbVXUahrRTqIK27gD2t5Cu1yuCXxbLcFtCzZGlfyVWWh8mLHkoxzjsB6DDNnvdL+fW8MiwPEJyGJQDgQ==", + "dev": true, "license": "MIT", - "peer": true, - "dependencies": { - "is-wsl": "^1.1.0" - }, "engines": { - "node": ">=8" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" } }, - "node_modules/@react-native-community/cli-tools/node_modules/ora": { - "version": "5.4.1", - "resolved": "https://registry.npmjs.org/ora/-/ora-5.4.1.tgz", - "integrity": "sha512-5b6Y85tPxZZ7QytO+BQzysW31HJku27cRIlkbAXaNx+BdcVi+LlRFmVXzeF6a7JCwJpyw5c4b+YSVImQIrBpuQ==", - "license": "MIT", - "peer": true, + "node_modules/@typescript-eslint/typescript-estree": { + "version": "5.62.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-5.62.0.tgz", + "integrity": "sha512-CmcQ6uY7b9y694lKdRB8FEel7JbU/40iSAPomu++SjLMntB+2Leay2LO6i8VnJk58MtE9/nQSFIH6jpyRWyYzA==", + "dev": true, + "license": "BSD-2-Clause", "dependencies": { - "bl": "^4.1.0", - "chalk": "^4.1.0", - "cli-cursor": "^3.1.0", - "cli-spinners": "^2.5.0", - "is-interactive": "^1.0.0", - "is-unicode-supported": "^0.1.0", - "log-symbols": "^4.1.0", - "strip-ansi": "^6.0.0", - "wcwidth": "^1.0.1" + "@typescript-eslint/types": "5.62.0", + "@typescript-eslint/visitor-keys": "5.62.0", + "debug": "^4.3.4", + "globby": "^11.1.0", + "is-glob": "^4.0.3", + "semver": "^7.3.7", + "tsutils": "^3.21.0" }, "engines": { - "node": ">=10" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } } }, - "node_modules/@react-native-community/cli-tools/node_modules/semver": { + "node_modules/@typescript-eslint/typescript-estree/node_modules/semver": { "version": "7.6.3", "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", + "dev": true, "license": "ISC", - "peer": true, "bin": { "semver": "bin/semver.js" }, @@ -4454,6173 +3911,2451 @@ "node": ">=10" } }, - "node_modules/@react-native-community/cli-tools/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/@typescript-eslint/utils": { + "version": "5.62.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-5.62.0.tgz", + "integrity": "sha512-n8oxjeb5aIbPFEtmQxQYOLI0i9n5ySBEY/ZEHHZqKQSFnxio1rv6dthascc9dLuwrL0RC5mPCxB7vnAVGAYWAQ==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "has-flag": "^4.0.0" + "@eslint-community/eslint-utils": "^4.2.0", + "@types/json-schema": "^7.0.9", + "@types/semver": "^7.3.12", + "@typescript-eslint/scope-manager": "5.62.0", + "@typescript-eslint/types": "5.62.0", + "@typescript-eslint/typescript-estree": "5.62.0", + "eslint-scope": "^5.1.1", + "semver": "^7.3.7" }, "engines": { - "node": ">=8" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependencies": { + "eslint": "^6.0.0 || ^7.0.0 || ^8.0.0" } }, - "node_modules/@react-native-community/cli-types": { - "version": "14.1.0", - "resolved": "https://registry.npmjs.org/@react-native-community/cli-types/-/cli-types-14.1.0.tgz", - "integrity": "sha512-aJwZI9mGRx3HdP8U4CGhqjt3S4r8GmeOqv4kRagC1UHDk4QNMC+bZ8JgPA4W7FrGiPey+lJQHMDPAXOo51SOUw==", - "license": "MIT", - "peer": true, - "dependencies": { - "joi": "^17.2.1" + "node_modules/@typescript-eslint/utils/node_modules/semver": { + "version": "7.6.3", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", + "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" } }, - "node_modules/@react-native-community/cli/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/@typescript-eslint/visitor-keys": { + "version": "5.62.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-5.62.0.tgz", + "integrity": "sha512-07ny+LHRzQXepkGg6w0mFY41fVUNBrL2Roj/++7V1txKugfjm/Ci/qSND03r2RhlJhJYMcTn9AhhSSqQp0Ysyw==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "color-convert": "^2.0.1" + "@typescript-eslint/types": "5.62.0", + "eslint-visitor-keys": "^3.3.0" }, "engines": { - "node": ">=8" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" }, "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" } }, - "node_modules/@react-native-community/cli/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "license": "MIT", - "peer": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, + "node_modules/@typescript-eslint/visitor-keys/node_modules/eslint-visitor-keys": { + "version": "3.4.3", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz", + "integrity": "sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==", + "dev": true, + "license": "Apache-2.0", "engines": { - "node": ">=10" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" }, "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "url": "https://opencollective.com/eslint" } }, - "node_modules/@react-native-community/cli/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/@ungap/structured-clone": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/@ungap/structured-clone/-/structured-clone-1.2.0.tgz", + "integrity": "sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==", + "dev": true, + "license": "ISC" + }, + "node_modules/@webassemblyjs/ast": { + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.12.1.tgz", + "integrity": "sha512-EKfMUOPRRUTy5UII4qJDGPpqfwjOmZ5jeGFwid9mnoqIFK+e0vqoi1qH56JpmZSzEL53jKnNzScdmftJyG5xWg==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" + "@webassemblyjs/helper-numbers": "1.11.6", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6" } }, - "node_modules/@react-native-community/cli/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT", - "peer": true + "node_modules/@webassemblyjs/floating-point-hex-parser": { + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.11.6.tgz", + "integrity": "sha512-ejAj9hfRJ2XMsNHk/v6Fu2dGS+i4UaXBXGemOfQ/JfQ6mdQg/WXtwleQRLLS4OvfDhv8rYnVwH27YJLMyYsxhw==", + "dev": true, + "license": "MIT" }, - "node_modules/@react-native-community/cli/node_modules/commander": { - "version": "9.5.0", - "resolved": "https://registry.npmjs.org/commander/-/commander-9.5.0.tgz", - "integrity": "sha512-KRs7WVDKg86PWiuAqhDrAQnTXZKraVcCc6vFdL14qrZ/DcWwuRo7VoiYXalXO7S5GKpqYiVEwCbgFDfxNHKJBQ==", - "license": "MIT", - "peer": true, - "engines": { - "node": "^12.20.0 || >=14" - } + "node_modules/@webassemblyjs/helper-api-error": { + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.11.6.tgz", + "integrity": "sha512-o0YkoP4pVu4rN8aTJgAyj9hC2Sv5UlkzCHhxqWj8butaLvnpdc2jOwh4ewE6CX0txSfLn/UYaV/pheS2Txg//Q==", + "dev": true, + "license": "MIT" }, - "node_modules/@react-native-community/cli/node_modules/execa": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", - "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", + "node_modules/@webassemblyjs/helper-buffer": { + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.12.1.tgz", + "integrity": "sha512-nzJwQw99DNDKr9BVCOZcLuJJUlqkJh+kVzVl6Fmq/tI5ZtEyWT1KZMyOXltXLZJmDtvLCDgwsyrkohEtopTXCw==", + "dev": true, + "license": "MIT" + }, + "node_modules/@webassemblyjs/helper-numbers": { + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-numbers/-/helper-numbers-1.11.6.tgz", + "integrity": "sha512-vUIhZ8LZoIWHBohiEObxVm6hwP034jwmc9kuq5GdHZH0wiLVLIPcMCdpJzG4C11cHoQ25TFIQj9kaVADVX7N3g==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "cross-spawn": "^7.0.3", - "get-stream": "^6.0.0", - "human-signals": "^2.1.0", - "is-stream": "^2.0.0", - "merge-stream": "^2.0.0", - "npm-run-path": "^4.0.1", - "onetime": "^5.1.2", - "signal-exit": "^3.0.3", - "strip-final-newline": "^2.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sindresorhus/execa?sponsor=1" + "@webassemblyjs/floating-point-hex-parser": "1.11.6", + "@webassemblyjs/helper-api-error": "1.11.6", + "@xtuc/long": "4.2.2" } }, - "node_modules/@react-native-community/cli/node_modules/fs-extra": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-8.1.0.tgz", - "integrity": "sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==", + "node_modules/@webassemblyjs/helper-wasm-bytecode": { + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.11.6.tgz", + "integrity": "sha512-sFFHKwcmBprO9e7Icf0+gddyWYDViL8bpPjJJl0WHxCdETktXdmtWLGVzoHbqUcY4Be1LkNfwTmXOJUFZYSJdA==", + "dev": true, + "license": "MIT" + }, + "node_modules/@webassemblyjs/helper-wasm-section": { + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.12.1.tgz", + "integrity": "sha512-Jif4vfB6FJlUlSbgEMHUyk1j234GTNG9dBJ4XJdOySoj518Xj0oGsNi59cUQF4RRMS9ouBUxDDdyBVfPTypa5g==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "graceful-fs": "^4.2.0", - "jsonfile": "^4.0.0", - "universalify": "^0.1.0" - }, - "engines": { - "node": ">=6 <7 || >=8" - } - }, - "node_modules/@react-native-community/cli/node_modules/get-stream": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", - "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/wasm-gen": "1.12.1" } }, - "node_modules/@react-native-community/cli/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/@webassemblyjs/ieee754": { + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.11.6.tgz", + "integrity": "sha512-LM4p2csPNvbij6U1f19v6WR56QZ8JcHg3QIJTlSwzFcmx6WSORicYj6I63f9yU1kEUtrpG+kjkiIAkevHpDXrg==", + "dev": true, "license": "MIT", - "peer": true, - "engines": { - "node": ">=8" + "dependencies": { + "@xtuc/ieee754": "^1.2.0" } }, - "node_modules/@react-native-community/cli/node_modules/human-signals": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", - "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", + "node_modules/@webassemblyjs/leb128": { + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.11.6.tgz", + "integrity": "sha512-m7a0FhE67DQXgouf1tbN5XQcdWoNgaAuoULHIfGFIEVKA6tu/edls6XnIlkmS6FrXAquJRPni3ZZKjw6FSPjPQ==", + "dev": true, "license": "Apache-2.0", - "peer": true, - "engines": { - "node": ">=10.17.0" + "dependencies": { + "@xtuc/long": "4.2.2" } }, - "node_modules/@react-native-community/cli/node_modules/jsonfile": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-4.0.0.tgz", - "integrity": "sha512-m6F1R3z8jjlf2imQHS2Qez5sjKWQzbuuhuJ/FKYFRZvPE3PuHcSMVZzfsLhGVOkfd20obL5SWEBew5ShlquNxg==", - "license": "MIT", - "peer": true, - "optionalDependencies": { - "graceful-fs": "^4.1.6" - } + "node_modules/@webassemblyjs/utf8": { + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.11.6.tgz", + "integrity": "sha512-vtXf2wTQ3+up9Zsg8sa2yWiQpzSsMyXj0qViVP6xKGCUT8p8YJ6HqI7l5eCnWx1T/FYdsv07HQs2wTFbbof/RA==", + "dev": true, + "license": "MIT" }, - "node_modules/@react-native-community/cli/node_modules/semver": { - "version": "7.6.3", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", - "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", - "license": "ISC", - "peer": true, - "bin": { - "semver": "bin/semver.js" - }, - "engines": { - "node": ">=10" + "node_modules/@webassemblyjs/wasm-edit": { + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.12.1.tgz", + "integrity": "sha512-1DuwbVvADvS5mGnXbE+c9NfA8QRcZ6iKquqjjmR10k6o+zzsRVesil54DKexiowcFCPdr/Q0qaMgB01+SQ1u6g==", + "dev": true, + "license": "MIT", + "dependencies": { + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/helper-wasm-section": "1.12.1", + "@webassemblyjs/wasm-gen": "1.12.1", + "@webassemblyjs/wasm-opt": "1.12.1", + "@webassemblyjs/wasm-parser": "1.12.1", + "@webassemblyjs/wast-printer": "1.12.1" } }, - "node_modules/@react-native-community/cli/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/@webassemblyjs/wasm-gen": { + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.12.1.tgz", + "integrity": "sha512-TDq4Ojh9fcohAw6OIMXqiIcTq5KUXTGRkVxbSo1hQnSy6lAM5GSdfwWeSxpAo0YzgsgF182E/U0mDNhuA0tW7w==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/ieee754": "1.11.6", + "@webassemblyjs/leb128": "1.11.6", + "@webassemblyjs/utf8": "1.11.6" } }, - "node_modules/@react-native-community/cli/node_modules/universalify": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/universalify/-/universalify-0.1.2.tgz", - "integrity": "sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==", + "node_modules/@webassemblyjs/wasm-opt": { + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.12.1.tgz", + "integrity": "sha512-Jg99j/2gG2iaz3hijw857AVYekZe2SAskcqlWIZXjji5WStnOpVoat3gQfT/Q5tb2djnCjBtMocY/Su1GfxPBg==", + "dev": true, "license": "MIT", - "peer": true, - "engines": { - "node": ">= 4.0.0" + "dependencies": { + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/wasm-gen": "1.12.1", + "@webassemblyjs/wasm-parser": "1.12.1" } }, - "node_modules/@react-native/assets-registry": { - "version": "0.75.3", - "resolved": "https://registry.npmjs.org/@react-native/assets-registry/-/assets-registry-0.75.3.tgz", - "integrity": "sha512-i7MaRbYR06WdpJWv3a0PQ2ScFBUeevwcJ0tVopnFwTg0tBWp3NFEMDIcU8lyXVy9Y59WmrP1V2ROaRDaPiESgg==", + "node_modules/@webassemblyjs/wasm-parser": { + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.12.1.tgz", + "integrity": "sha512-xikIi7c2FHXysxXe3COrVUPSheuBtpcfhbpFj4gmu7KRLYOzANztwUU0IbsqvMqzuNK2+glRGWCEqZo1WCLyAQ==", + "dev": true, "license": "MIT", - "peer": true, - "engines": { - "node": ">=18" + "dependencies": { + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-api-error": "1.11.6", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/ieee754": "1.11.6", + "@webassemblyjs/leb128": "1.11.6", + "@webassemblyjs/utf8": "1.11.6" } }, - "node_modules/@react-native/babel-plugin-codegen": { - "version": "0.75.3", - "resolved": "https://registry.npmjs.org/@react-native/babel-plugin-codegen/-/babel-plugin-codegen-0.75.3.tgz", - "integrity": "sha512-8JmXEKq+Efb9AffsV48l8gmKe/ZQ2PbBygZjHdIf8DNZZhO/z5mt27J4B43MWNdp5Ww1l59T0mEaf8l/uywQUg==", + "node_modules/@webassemblyjs/wast-printer": { + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.12.1.tgz", + "integrity": "sha512-+X4WAlOisVWQMikjbcvY2e0rwPsKQ9F688lksZhBcPycBBuii3O7m8FACbDMWDojpAqvjIncrG8J0XHKyQfVeA==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "@react-native/codegen": "0.75.3" - }, - "engines": { - "node": ">=18" + "@webassemblyjs/ast": "1.12.1", + "@xtuc/long": "4.2.2" } }, - "node_modules/@react-native/babel-preset": { - "version": "0.75.3", - "resolved": "https://registry.npmjs.org/@react-native/babel-preset/-/babel-preset-0.75.3.tgz", - "integrity": "sha512-VZQkQEj36DKEGApXFYdVcFtqdglbnoVr7aOZpjffURSgPcIA9vWTm1b+OL4ayOaRZXTZKiDBNQCXvBX5E5AgQg==", - "license": "MIT", - "peer": true, - "dependencies": { - "@babel/core": "^7.20.0", - "@babel/plugin-proposal-export-default-from": "^7.0.0", - "@babel/plugin-syntax-dynamic-import": "^7.8.0", - "@babel/plugin-syntax-export-default-from": "^7.0.0", - "@babel/plugin-syntax-flow": "^7.18.0", - "@babel/plugin-syntax-nullish-coalescing-operator": "^7.0.0", - "@babel/plugin-syntax-optional-chaining": "^7.0.0", - "@babel/plugin-transform-arrow-functions": "^7.0.0", - "@babel/plugin-transform-async-generator-functions": "^7.24.3", - "@babel/plugin-transform-async-to-generator": "^7.20.0", - "@babel/plugin-transform-block-scoping": "^7.0.0", - "@babel/plugin-transform-class-properties": "^7.24.1", - "@babel/plugin-transform-classes": "^7.0.0", - "@babel/plugin-transform-computed-properties": "^7.0.0", - "@babel/plugin-transform-destructuring": "^7.20.0", - "@babel/plugin-transform-flow-strip-types": "^7.20.0", - "@babel/plugin-transform-for-of": "^7.0.0", - "@babel/plugin-transform-function-name": "^7.0.0", - "@babel/plugin-transform-literals": "^7.0.0", - "@babel/plugin-transform-logical-assignment-operators": "^7.24.1", - "@babel/plugin-transform-modules-commonjs": "^7.0.0", - "@babel/plugin-transform-named-capturing-groups-regex": "^7.0.0", - "@babel/plugin-transform-nullish-coalescing-operator": "^7.24.1", - "@babel/plugin-transform-numeric-separator": "^7.24.1", - "@babel/plugin-transform-object-rest-spread": "^7.24.5", - "@babel/plugin-transform-optional-catch-binding": "^7.24.1", - "@babel/plugin-transform-optional-chaining": "^7.24.5", - "@babel/plugin-transform-parameters": "^7.0.0", - "@babel/plugin-transform-private-methods": "^7.22.5", - "@babel/plugin-transform-private-property-in-object": "^7.22.11", - "@babel/plugin-transform-react-display-name": "^7.0.0", - "@babel/plugin-transform-react-jsx": "^7.0.0", - "@babel/plugin-transform-react-jsx-self": "^7.0.0", - "@babel/plugin-transform-react-jsx-source": "^7.0.0", - "@babel/plugin-transform-regenerator": "^7.20.0", - "@babel/plugin-transform-runtime": "^7.0.0", - "@babel/plugin-transform-shorthand-properties": "^7.0.0", - "@babel/plugin-transform-spread": "^7.0.0", - "@babel/plugin-transform-sticky-regex": "^7.0.0", - "@babel/plugin-transform-typescript": "^7.5.0", - "@babel/plugin-transform-unicode-regex": "^7.0.0", - "@babel/template": "^7.0.0", - "@react-native/babel-plugin-codegen": "0.75.3", - "babel-plugin-transform-flow-enums": "^0.0.2", - "react-refresh": "^0.14.0" - }, + "node_modules/@webpack-cli/configtest": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@webpack-cli/configtest/-/configtest-2.1.1.tgz", + "integrity": "sha512-wy0mglZpDSiSS0XHrVR+BAdId2+yxPSoJW8fsna3ZpYSlufjvxnP4YbKTCBZnNIcGN4r6ZPXV55X4mYExOfLmw==", + "dev": true, + "license": "MIT", "engines": { - "node": ">=18" + "node": ">=14.15.0" }, "peerDependencies": { - "@babel/core": "*" + "webpack": "5.x.x", + "webpack-cli": "5.x.x" } }, - "node_modules/@react-native/codegen": { - "version": "0.75.3", - "resolved": "https://registry.npmjs.org/@react-native/codegen/-/codegen-0.75.3.tgz", - "integrity": "sha512-I0bz5jwOkiR7vnhYLGoV22RGmesErUg03tjsCiQgmsMpbyCYumudEtLNN5+DplHGK56bu8KyzBqKkWXGSKSCZQ==", + "node_modules/@webpack-cli/info": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/@webpack-cli/info/-/info-2.0.2.tgz", + "integrity": "sha512-zLHQdI/Qs1UyT5UBdWNqsARasIA+AaF8t+4u2aS2nEpBQh2mWIVb8qAklq0eUENnC5mOItrIB4LiS9xMtph18A==", + "dev": true, "license": "MIT", - "peer": true, - "dependencies": { - "@babel/parser": "^7.20.0", - "glob": "^7.1.1", - "hermes-parser": "0.22.0", - "invariant": "^2.2.4", - "jscodeshift": "^0.14.0", - "mkdirp": "^0.5.1", - "nullthrows": "^1.1.1", - "yargs": "^17.6.2" - }, "engines": { - "node": ">=18" + "node": ">=14.15.0" }, "peerDependencies": { - "@babel/preset-env": "^7.1.6" + "webpack": "5.x.x", + "webpack-cli": "5.x.x" } }, - "node_modules/@react-native/codegen/node_modules/glob": { - "version": "7.2.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", - "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", - "deprecated": "Glob versions prior to v9 are no longer supported", - "license": "ISC", - "peer": true, - "dependencies": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.1.1", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - }, + "node_modules/@webpack-cli/serve": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/@webpack-cli/serve/-/serve-2.0.5.tgz", + "integrity": "sha512-lqaoKnRYBdo1UgDX8uF24AfGMifWK19TxPmM5FHc2vAGxrJ/qtyUyFBWoY1tISZdelsQ5fBcOusifo5o5wSJxQ==", + "dev": true, + "license": "MIT", "engines": { - "node": "*" + "node": ">=14.15.0" }, - "funding": { - "url": "https://github.com/sponsors/isaacs" + "peerDependencies": { + "webpack": "5.x.x", + "webpack-cli": "5.x.x" + }, + "peerDependenciesMeta": { + "webpack-dev-server": { + "optional": true + } } }, - "node_modules/@react-native/community-cli-plugin": { - "version": "0.75.3", - "resolved": "https://registry.npmjs.org/@react-native/community-cli-plugin/-/community-cli-plugin-0.75.3.tgz", - "integrity": "sha512-njsYm+jBWzfLcJcxavAY5QFzYTrmPtjbxq/64GSqwcQYzy9qAkI7LNTK/Wprq1I/4HOuHJO7Km+EddCXB+ByRQ==", - "license": "MIT", - "peer": true, + "node_modules/@wordpress/a11y": { + "version": "2.15.3", + "resolved": "https://registry.npmjs.org/@wordpress/a11y/-/a11y-2.15.3.tgz", + "integrity": "sha512-uoCznHY3/TaNWeXutLI6juC198ykaBwZ34P51PNHHQqi3WzVoBhFx6AnAR/9Uupl3tZcekefpkVHy7AJHMAPIA==", + "license": "GPL-2.0-or-later", "dependencies": { - "@react-native-community/cli-server-api": "14.1.0", - "@react-native-community/cli-tools": "14.1.0", - "@react-native/dev-middleware": "0.75.3", - "@react-native/metro-babel-transformer": "0.75.3", - "chalk": "^4.0.0", - "execa": "^5.1.1", - "metro": "^0.80.3", - "metro-config": "^0.80.3", - "metro-core": "^0.80.3", - "node-fetch": "^2.2.0", - "readline": "^1.3.0" - }, - "engines": { - "node": ">=18" + "@babel/runtime": "^7.13.10", + "@wordpress/dom-ready": "^2.13.2", + "@wordpress/i18n": "^3.20.0" } }, - "node_modules/@react-native/community-cli-plugin/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/@wordpress/a11y/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "license": "MIT", - "peer": true, "dependencies": { - "color-convert": "^2.0.1" + "regenerator-runtime": "^0.14.0" }, "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "node": ">=6.9.0" } }, - "node_modules/@react-native/community-cli-plugin/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "license": "MIT", - "peer": true, + "node_modules/@wordpress/a11y/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", + "license": "MIT" + }, + "node_modules/@wordpress/api-fetch": { + "version": "2.2.8", + "resolved": "https://registry.npmjs.org/@wordpress/api-fetch/-/api-fetch-2.2.8.tgz", + "integrity": "sha512-mbdP9GvDe8Ojv8cobk30mfg2btEZDQEe7IgO+rGSlvVlHC88U8cc2VgOLNX6c9/6/sCvkoGd4Tsy85VbdTlTXw==", + "license": "GPL-2.0-or-later", "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "@babel/runtime": "^7.0.0", + "@wordpress/hooks": "^2.0.5", + "@wordpress/i18n": "^3.1.1", + "@wordpress/url": "^2.3.3" } }, - "node_modules/@react-native/community-cli-plugin/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/@wordpress/api-fetch/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "license": "MIT", - "peer": true, "dependencies": { - "color-name": "~1.1.4" + "regenerator-runtime": "^0.14.0" }, "engines": { - "node": ">=7.0.0" + "node": ">=6.9.0" } }, - "node_modules/@react-native/community-cli-plugin/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT", - "peer": true + "node_modules/@wordpress/api-fetch/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", + "license": "MIT" }, - "node_modules/@react-native/community-cli-plugin/node_modules/execa": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", - "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", - "license": "MIT", - "peer": true, - "dependencies": { - "cross-spawn": "^7.0.3", - "get-stream": "^6.0.0", - "human-signals": "^2.1.0", - "is-stream": "^2.0.0", - "merge-stream": "^2.0.0", - "npm-run-path": "^4.0.1", - "onetime": "^5.1.2", - "signal-exit": "^3.0.3", - "strip-final-newline": "^2.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sindresorhus/execa?sponsor=1" - } + "node_modules/@wordpress/api-request": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/@wordpress/api-request/-/api-request-1.0.0.tgz", + "integrity": "sha512-/6cJaf93LJMgnzYFT1xEjqRBL/AbIzCTpZr9Yb1NoEMeHGvSoJ/lOzxWFCZAA8olzW0WEBlKIZPxp++TtrYEsA==", + "deprecated": "@wordpress/api-request has been discontinued, please install the latest version of @wordpress/api-fetch package instead", + "license": "GPL-2.0-or-later" }, - "node_modules/@react-native/community-cli-plugin/node_modules/get-stream": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", - "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", - "license": "MIT", - "peer": true, + "node_modules/@wordpress/babel-plugin-import-jsx-pragma": { + "version": "4.41.0", + "resolved": "https://registry.npmjs.org/@wordpress/babel-plugin-import-jsx-pragma/-/babel-plugin-import-jsx-pragma-4.41.0.tgz", + "integrity": "sha512-hYxj2Uobxk86ctlfaJou9v13XqXZ30yx4ZwRNu5cH5/LWXe2MIXBTPv7dUk6wqN/qFOjsFvP9jCB0NsW6MnkrA==", + "dev": true, + "license": "GPL-2.0-or-later", "engines": { - "node": ">=10" + "node": ">=14" }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "peerDependencies": { + "@babel/core": "^7.12.9" } }, - "node_modules/@react-native/community-cli-plugin/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "license": "MIT", - "peer": true, + "node_modules/@wordpress/babel-plugin-makepot": { + "version": "5.42.0", + "resolved": "https://registry.npmjs.org/@wordpress/babel-plugin-makepot/-/babel-plugin-makepot-5.42.0.tgz", + "integrity": "sha512-Y8BjbkfQ2QQBG4RW9G3YT6Cpw+yC+Sj76FVLiEI5X1NdNKivVoHCdj73ziF87cCFTjWU7b55huph+kfL8c/DFA==", + "dev": true, + "license": "GPL-2.0-or-later", + "dependencies": { + "deepmerge": "^4.3.0", + "gettext-parser": "^1.3.1", + "is-plain-object": "^5.0.0" + }, "engines": { - "node": ">=8" + "node": ">=14" + }, + "peerDependencies": { + "@babel/core": "^7.12.9" } }, - "node_modules/@react-native/community-cli-plugin/node_modules/human-signals": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", - "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", - "license": "Apache-2.0", - "peer": true, + "node_modules/@wordpress/babel-preset-default": { + "version": "7.42.0", + "resolved": "https://registry.npmjs.org/@wordpress/babel-preset-default/-/babel-preset-default-7.42.0.tgz", + "integrity": "sha512-AWSxWuEuzazt/nWomKiaVhYQeXuqxTniPCKhvks58wB3P4UXvSe3hRnO+nujz20IuxIk2xHT6x47HgpDZy30jw==", + "dev": true, + "license": "GPL-2.0-or-later", + "dependencies": { + "@babel/core": "^7.16.0", + "@babel/plugin-transform-react-jsx": "^7.16.0", + "@babel/plugin-transform-runtime": "^7.16.0", + "@babel/preset-env": "^7.16.0", + "@babel/preset-typescript": "^7.16.0", + "@babel/runtime": "^7.16.0", + "@wordpress/babel-plugin-import-jsx-pragma": "^4.41.0", + "@wordpress/browserslist-config": "^5.41.0", + "@wordpress/warning": "^2.58.0", + "browserslist": "^4.21.10", + "core-js": "^3.31.0", + "react": "^18.3.0" + }, "engines": { - "node": ">=10.17.0" + "node": ">=14" } }, - "node_modules/@react-native/community-cli-plugin/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/@wordpress/babel-preset-default/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "has-flag": "^4.0.0" + "regenerator-runtime": "^0.14.0" }, "engines": { - "node": ">=8" + "node": ">=6.9.0" } }, - "node_modules/@react-native/debugger-frontend": { - "version": "0.75.3", - "resolved": "https://registry.npmjs.org/@react-native/debugger-frontend/-/debugger-frontend-0.75.3.tgz", - "integrity": "sha512-99bLQsUwsxUMNR7Wa9eV2uyR38yfd6mOEqfN+JIm8/L9sKA926oh+CZkjDy1M8RmCB6spB5N9fVFVkrVdf2yFA==", - "license": "BSD-3-Clause", - "peer": true, + "node_modules/@wordpress/babel-preset-default/node_modules/@wordpress/browserslist-config": { + "version": "5.41.0", + "resolved": "https://registry.npmjs.org/@wordpress/browserslist-config/-/browserslist-config-5.41.0.tgz", + "integrity": "sha512-J7ejzzDpPZddVIiq2YiK8J/pNTJDy3X1s+5ZtwkwklCxBMZJurxf9pEhtbaf7us0Q6c1j8Ubv7Fpx3lqk2ypxA==", + "dev": true, + "license": "GPL-2.0-or-later", "engines": { - "node": ">=18" + "node": ">=14" } }, - "node_modules/@react-native/dev-middleware": { - "version": "0.75.3", - "resolved": "https://registry.npmjs.org/@react-native/dev-middleware/-/dev-middleware-0.75.3.tgz", - "integrity": "sha512-h2/6+UGmeMWjnT43axy27jNqoDRsE1C1qpjRC3sYpD4g0bI0jSTkY1kAgj8uqGGXLnHXiHOtjLDGdbAgZrsPaA==", + "node_modules/@wordpress/babel-preset-default/node_modules/core-js": { + "version": "3.38.1", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.38.1.tgz", + "integrity": "sha512-OP35aUorbU3Zvlx7pjsFdu1rGNnD4pgw/CWoYzRY3t2EzoVT7shKHY1dlAy3f41cGIO7ZDPQimhGFTlEYkG/Hw==", + "dev": true, + "hasInstallScript": true, "license": "MIT", - "peer": true, - "dependencies": { - "@isaacs/ttlcache": "^1.4.1", - "@react-native/debugger-frontend": "0.75.3", - "chrome-launcher": "^0.15.2", - "chromium-edge-launcher": "^0.2.0", - "connect": "^3.6.5", - "debug": "^2.2.0", - "node-fetch": "^2.2.0", - "nullthrows": "^1.1.1", - "open": "^7.0.3", - "selfsigned": "^2.4.1", - "serve-static": "^1.13.1", - "ws": "^6.2.2" - }, - "engines": { - "node": ">=18" + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/core-js" } }, - "node_modules/@react-native/dev-middleware/node_modules/debug": { - "version": "2.6.9", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "node_modules/@wordpress/babel-preset-default/node_modules/react": { + "version": "18.3.1", + "resolved": "https://registry.npmjs.org/react/-/react-18.3.1.tgz", + "integrity": "sha512-wS+hAgJShR0KhEvPJArfuPVN1+Hz1t0Y6n5jLrGQbkb4urgPE/0Rve+1kMB1v/oWgHgm4WIcV+i7F2pTVj+2iQ==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "ms": "2.0.0" + "loose-envify": "^1.1.0" + }, + "engines": { + "node": ">=0.10.0" } }, - "node_modules/@react-native/dev-middleware/node_modules/ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", - "license": "MIT", - "peer": true + "node_modules/@wordpress/babel-preset-default/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", + "dev": true, + "license": "MIT" }, - "node_modules/@react-native/dev-middleware/node_modules/open": { - "version": "7.4.2", - "resolved": "https://registry.npmjs.org/open/-/open-7.4.2.tgz", - "integrity": "sha512-MVHddDVweXZF3awtlAS+6pgKLlm/JgxZ90+/NBurBoQctVOOB/zDdVjcyPzQ+0laDGbsWgrRkflI65sQeOgT9Q==", - "license": "MIT", - "peer": true, - "dependencies": { - "is-docker": "^2.0.0", - "is-wsl": "^2.1.1" - }, + "node_modules/@wordpress/browserslist-config": { + "version": "6.29.0", + "resolved": "https://registry.npmjs.org/@wordpress/browserslist-config/-/browserslist-config-6.29.0.tgz", + "integrity": "sha512-MXdhwaVMwr/kv93wr5EwzQgC/l5OTT537iVC6uZrGvGAn/cnrGkkgtanyoX+U4jOkAzB6JZ76Ox4QIhPj1DQPw==", + "dev": true, + "license": "GPL-2.0-or-later", "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "node": ">=18.12.0", + "npm": ">=8.19.2" } }, - "node_modules/@react-native/dev-middleware/node_modules/ws": { - "version": "6.2.3", - "resolved": "https://registry.npmjs.org/ws/-/ws-6.2.3.tgz", - "integrity": "sha512-jmTjYU0j60B+vHey6TfR3Z7RD61z/hmxBS3VMSGIrroOWXQEneK1zNuotOUrGyBHQj0yrpsLHPWtigEFd13ndA==", - "license": "MIT", - "peer": true, + "node_modules/@wordpress/components": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/@wordpress/components/-/components-6.0.2.tgz", + "integrity": "sha512-La9RsHC4IBqfsUbY2hOwQyIHnrd5zzcT+HbbKPV1GPlYOxgIpX41gh8/ktAsuNcZQWOmgze5MRFVl4+2OQEV9Q==", + "license": "GPL-2.0-or-later", "dependencies": { - "async-limiter": "~1.0.0" + "@babel/runtime": "^7.0.0", + "@wordpress/a11y": "^2.0.2", + "@wordpress/api-fetch": "^2.2.4", + "@wordpress/compose": "^3.0.0", + "@wordpress/deprecated": "^2.0.3", + "@wordpress/dom": "^2.0.6", + "@wordpress/element": "^2.1.8", + "@wordpress/hooks": "^2.0.3", + "@wordpress/i18n": "^3.1.0", + "@wordpress/is-shallow-equal": "^1.1.4", + "@wordpress/keycodes": "^2.0.3", + "@wordpress/rich-text": "^3.0.0", + "@wordpress/url": "^2.3.0", + "classnames": "^2.2.5", + "clipboard": "^2.0.1", + "diff": "^3.5.0", + "dom-scroll-into-view": "^1.2.1", + "lodash": "^4.17.10", + "memize": "^1.0.5", + "moment": "^2.22.1", + "mousetrap": "^1.6.2", + "re-resizable": "^4.7.1", + "react-click-outside": "^3.0.0", + "react-dates": "^17.1.1", + "rememo": "^3.0.0", + "tinycolor2": "^1.4.1", + "uuid": "^3.3.2" } }, - "node_modules/@react-native/gradle-plugin": { - "version": "0.75.3", - "resolved": "https://registry.npmjs.org/@react-native/gradle-plugin/-/gradle-plugin-0.75.3.tgz", - "integrity": "sha512-mSfa/Mq/AsALuG/kvXz5ECrc6HdY5waMHal2sSfa8KA0Gt3JqYQVXF9Pdwd4yR5ClPZDI2HRa1tdE8GVlhMvPA==", + "node_modules/@wordpress/components/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "license": "MIT", - "peer": true, + "dependencies": { + "regenerator-runtime": "^0.14.0" + }, "engines": { - "node": ">=18" + "node": ">=6.9.0" } }, - "node_modules/@react-native/js-polyfills": { - "version": "0.75.3", - "resolved": "https://registry.npmjs.org/@react-native/js-polyfills/-/js-polyfills-0.75.3.tgz", - "integrity": "sha512-+JVFJ351GSJT3V7LuXscMqfnpR/UxzsAjbBjfAHBR3kqTbVqrAmBccqPCA3NLzgb/RY8khLJklwMUVlWrn8iFg==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=18" + "node_modules/@wordpress/components/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", + "license": "MIT" + }, + "node_modules/@wordpress/compose": { + "version": "3.25.3", + "resolved": "https://registry.npmjs.org/@wordpress/compose/-/compose-3.25.3.tgz", + "integrity": "sha512-tCO2EnJCkCH548OqA0uU8V1k/1skz2QwBlHs8ZQSpimqUS4OWWsAlndCEFe4U4vDTqFt2ow7tzAir+05Cw8MAg==", + "license": "GPL-2.0-or-later", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@wordpress/deprecated": "^2.12.3", + "@wordpress/dom": "^2.18.0", + "@wordpress/element": "^2.20.3", + "@wordpress/is-shallow-equal": "^3.1.3", + "@wordpress/keycodes": "^2.19.3", + "@wordpress/priority-queue": "^1.11.2", + "clipboard": "^2.0.1", + "lodash": "^4.17.19", + "memize": "^1.1.0", + "mousetrap": "^1.6.5", + "react-resize-aware": "^3.1.0", + "use-memo-one": "^1.1.1" } }, - "node_modules/@react-native/metro-babel-transformer": { - "version": "0.75.3", - "resolved": "https://registry.npmjs.org/@react-native/metro-babel-transformer/-/metro-babel-transformer-0.75.3.tgz", - "integrity": "sha512-gDlEl6C2mwQPLxFOR+yla5MpJpDPNOFD6J5Hd9JM9+lOdUq6MNujh1Xn4ZMvglW7rfViq3nMjg4xPQeGUhDG+w==", + "node_modules/@wordpress/compose/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "license": "MIT", - "peer": true, "dependencies": { - "@babel/core": "^7.20.0", - "@react-native/babel-preset": "0.75.3", - "hermes-parser": "0.22.0", - "nullthrows": "^1.1.1" + "regenerator-runtime": "^0.14.0" }, "engines": { - "node": ">=18" - }, - "peerDependencies": { - "@babel/core": "*" + "node": ">=6.9.0" } }, - "node_modules/@react-native/normalize-colors": { - "version": "0.75.3", - "resolved": "https://registry.npmjs.org/@react-native/normalize-colors/-/normalize-colors-0.75.3.tgz", - "integrity": "sha512-3mhF8AJFfIN0E5bEs/DQ4U2LzMJYm+FPSwY5bJ1DZhrxW1PFAh24bAPrSd8PwS0iarQ7biLdr1lWf/8LFv8pDA==", - "license": "MIT", - "peer": true - }, - "node_modules/@rtsao/scc": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@rtsao/scc/-/scc-1.1.0.tgz", - "integrity": "sha512-zt6OdqaDoOnJ1ZYsCYGt9YmWzDXl4vQdKTyJev62gFhRGKdx7mcT54V9KIjg+d2wi9EXsPvAPKe7i7WjfVWB8g==", - "dev": true, - "license": "MIT" - }, - "node_modules/@sideway/address": { - "version": "4.1.5", - "resolved": "https://registry.npmjs.org/@sideway/address/-/address-4.1.5.tgz", - "integrity": "sha512-IqO/DUQHUkPeixNQ8n0JA6102hT9CmaljNTPmQ1u8MEhBo/R4Q8eKLN/vGZxuebwOroDB4cbpjheD4+/sKFK4Q==", - "license": "BSD-3-Clause", - "peer": true, + "node_modules/@wordpress/compose/node_modules/@wordpress/is-shallow-equal": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/@wordpress/is-shallow-equal/-/is-shallow-equal-3.1.3.tgz", + "integrity": "sha512-eDLhfC4aaSgklzqwc6F/F4zmJVpTVTAvhqX+q0SP/8LPcP2HuKErPHVrEc75PMWqIutja2wJg98YSNPdewrj1w==", + "license": "GPL-2.0-or-later", "dependencies": { - "@hapi/hoek": "^9.0.0" + "@babel/runtime": "^7.13.10" } }, - "node_modules/@sideway/formula": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/@sideway/formula/-/formula-3.0.1.tgz", - "integrity": "sha512-/poHZJJVjx3L+zVD6g9KgHfYnb443oi7wLu/XKojDviHy6HOEOA6z1Trk5aR1dGcmPenJEgb2sK2I80LeS3MIg==", - "license": "BSD-3-Clause", - "peer": true + "node_modules/@wordpress/compose/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", + "license": "MIT" }, - "node_modules/@sideway/pinpoint": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@sideway/pinpoint/-/pinpoint-2.0.0.tgz", - "integrity": "sha512-RNiOoTPkptFtSVzQevY/yWtZwf/RxyVnPy/OcA9HBM3MlGDnBEYL5B41H0MTn0Uec8Hi+2qUtTfG2WWZBmMejQ==", - "license": "BSD-3-Clause", - "peer": true + "node_modules/@wordpress/data": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/@wordpress/data/-/data-3.1.2.tgz", + "integrity": "sha512-aAYgRIljpLboplTaCA7t5r+qVjE53VGMS7rLjSHFsoFxj9GYPiCCX1f/B01eKz9pf04rVdM2N4cEowyxjkhKFA==", + "license": "GPL-2.0-or-later", + "dependencies": { + "@babel/runtime": "^7.0.0", + "@wordpress/compose": "^2.1.2", + "@wordpress/deprecated": "^2.0.3", + "@wordpress/element": "^2.1.7", + "@wordpress/is-shallow-equal": "^1.1.4", + "@wordpress/redux-routine": "^3.0.3", + "equivalent-key-map": "^0.2.2", + "is-promise": "^2.1.0", + "lodash": "^4.17.10", + "redux": "^4.0.0", + "turbo-combine-reducers": "^1.0.2" + } }, - "node_modules/@sidvind/better-ajv-errors": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/@sidvind/better-ajv-errors/-/better-ajv-errors-3.0.1.tgz", - "integrity": "sha512-++1mEYIeozfnwWI9P1ECvOPoacy+CgDASrmGvXPMCcqgx0YUzB01vZ78uHdQ443V6sTY+e9MzHqmN9DOls02aw==", - "dev": true, - "license": "Apache-2.0", + "node_modules/@wordpress/data/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", + "license": "MIT", "dependencies": { - "kleur": "^4.1.0" + "regenerator-runtime": "^0.14.0" }, "engines": { - "node": ">= 16.14" - }, - "peerDependencies": { - "ajv": "^6.12.3 || ^7.0.0 || ^8.0.0" + "node": ">=6.9.0" } }, - "node_modules/@sinclair/typebox": { - "version": "0.27.8", - "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.27.8.tgz", - "integrity": "sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA==", - "license": "MIT", - "peer": true + "node_modules/@wordpress/data/node_modules/@wordpress/compose": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/@wordpress/compose/-/compose-2.1.2.tgz", + "integrity": "sha512-jr1bWRYx8vt4bCWB4hqR9Ve9rk/TCJ5mFRvkwEd+xTDyXG6ZMmps3HszGA6aCH7E+TCHH+bWw2qZo9sAeHVK/w==", + "license": "GPL-2.0-or-later", + "dependencies": { + "@babel/runtime": "^7.0.0", + "@wordpress/deprecated": "^2.0.3", + "@wordpress/element": "^2.1.7", + "@wordpress/is-shallow-equal": "^1.1.4", + "lodash": "^4.17.10" + } }, - "node_modules/@sindresorhus/is": { - "version": "4.6.0", - "resolved": "https://registry.npmjs.org/@sindresorhus/is/-/is-4.6.0.tgz", - "integrity": "sha512-t09vSN3MdfsyCHoFcTRCH/iUtG7OJ0CsjzB8cjAmKc/va/kIgeDI/TxsigdncE/4be734m0cvIYwNaV4i2XqAw==", - "dev": true, + "node_modules/@wordpress/data/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", + "license": "MIT" + }, + "node_modules/@wordpress/deprecated": { + "version": "2.12.3", + "resolved": "https://registry.npmjs.org/@wordpress/deprecated/-/deprecated-2.12.3.tgz", + "integrity": "sha512-qr+yDfTQfI3M4h6oY6IeHWwoHr4jxbILjSlV+Ht6Jjto9Owap6OuzSqR13Ev4xqIoG4C7b5B3gZXVfwVDae1zg==", + "license": "GPL-2.0-or-later", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@wordpress/hooks": "^2.12.3" + } + }, + "node_modules/@wordpress/deprecated/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "license": "MIT", - "engines": { - "node": ">=10" + "dependencies": { + "regenerator-runtime": "^0.14.0" }, - "funding": { - "url": "https://github.com/sindresorhus/is?sponsor=1" + "engines": { + "node": ">=6.9.0" } }, - "node_modules/@sinonjs/commons": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", - "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", - "license": "BSD-3-Clause", - "peer": true, + "node_modules/@wordpress/deprecated/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", + "license": "MIT" + }, + "node_modules/@wordpress/dom": { + "version": "2.18.0", + "resolved": "https://registry.npmjs.org/@wordpress/dom/-/dom-2.18.0.tgz", + "integrity": "sha512-tM2WeQuSObl3nzWjUTF0/dyLnA7sdl/MXaSe32D64OF89bjSyJvjUipI7gjKzI3kJ7ddGhwcTggGvSB06MOoCQ==", + "license": "GPL-2.0-or-later", "dependencies": { - "type-detect": "4.0.8" + "@babel/runtime": "^7.13.10", + "lodash": "^4.17.19" } }, - "node_modules/@sinonjs/fake-timers": { - "version": "10.3.0", - "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-10.3.0.tgz", - "integrity": "sha512-V4BG07kuYSUkTCSBHG8G8TNhM+F19jXFWnQtzj+we8DrkpSBCee9Z3Ms8yiGer/dlmhe35/Xdgyo3/0rQKg7YA==", - "license": "BSD-3-Clause", - "peer": true, + "node_modules/@wordpress/dom-ready": { + "version": "2.13.2", + "resolved": "https://registry.npmjs.org/@wordpress/dom-ready/-/dom-ready-2.13.2.tgz", + "integrity": "sha512-COH7n2uZfBq4FtluSbl37N3nCEcdMXzV42ETCWKUcumiP1Zd3qnkfQKcsxTaHWY8aVt/358RvJ7ghWe3xAd+fg==", + "license": "GPL-2.0-or-later", "dependencies": { - "@sinonjs/commons": "^3.0.0" + "@babel/runtime": "^7.13.10" } }, - "node_modules/@stylistic/stylelint-plugin": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/@stylistic/stylelint-plugin/-/stylelint-plugin-3.1.2.tgz", - "integrity": "sha512-tylFJGMQo62alGazK74MNxFjMagYOHmBZiePZFOJK2n13JZta0uVkB3Bh5qodUmOLtRH+uxH297EibK14UKm8g==", - "dev": true, + "node_modules/@wordpress/dom-ready/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "license": "MIT", "dependencies": { - "@csstools/css-parser-algorithms": "^3.0.1", - "@csstools/css-tokenizer": "^3.0.1", - "@csstools/media-query-list-parser": "^3.0.1", - "is-plain-object": "^5.0.0", - "postcss-selector-parser": "^6.1.2", - "postcss-value-parser": "^4.2.0", - "style-search": "^0.1.0", - "stylelint": "^16.8.2" + "regenerator-runtime": "^0.14.0" }, "engines": { - "node": "^18.12 || >=20.9" - }, - "peerDependencies": { - "stylelint": "^16.8.0" + "node": ">=6.9.0" } }, - "node_modules/@stylistic/stylelint-plugin/node_modules/postcss-selector-parser": { - "version": "6.1.2", - "resolved": "https://registry.npmjs.org/postcss-selector-parser/-/postcss-selector-parser-6.1.2.tgz", - "integrity": "sha512-Q8qQfPiZ+THO/3ZrOrO0cJJKfpYCagtMUkXbnEfmgUjwXg6z/WBeOyS9APBBPCTSiDV+s4SwQGu8yFsiMRIudg==", - "dev": true, + "node_modules/@wordpress/dom-ready/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", + "license": "MIT" + }, + "node_modules/@wordpress/dom/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "license": "MIT", "dependencies": { - "cssesc": "^3.0.0", - "util-deprecate": "^1.0.2" + "regenerator-runtime": "^0.14.0" }, "engines": { - "node": ">=4" + "node": ">=6.9.0" } }, - "node_modules/@svgr/babel-plugin-add-jsx-attribute": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-add-jsx-attribute/-/babel-plugin-add-jsx-attribute-8.0.0.tgz", - "integrity": "sha512-b9MIk7yhdS1pMCZM8VeNfUlSKVRhsHZNMl5O9SfaX0l0t5wjdgu4IDzGB8bpnGBBOjGST3rRFVsaaEtI4W6f7g==", - "dev": true, + "node_modules/@wordpress/dom/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", + "license": "MIT" + }, + "node_modules/@wordpress/element": { + "version": "2.20.3", + "resolved": "https://registry.npmjs.org/@wordpress/element/-/element-2.20.3.tgz", + "integrity": "sha512-f4ZPTDf9CxiiOXiMxc4v1K7jcBMT4dsiehVOpkKzCDKboNXp4qVf8oe5PE23VGZNEjcOj5Mkg9hB57R0nqvMTw==", + "license": "GPL-2.0-or-later", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@types/react": "^16.9.0", + "@types/react-dom": "^16.9.0", + "@wordpress/escape-html": "^1.12.2", + "lodash": "^4.17.19", + "react": "^16.13.1", + "react-dom": "^16.13.1" + } + }, + "node_modules/@wordpress/element/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "license": "MIT", - "engines": { - "node": ">=14" + "dependencies": { + "regenerator-runtime": "^0.14.0" }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/gregberge" + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@wordpress/element/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", + "license": "MIT" + }, + "node_modules/@wordpress/env": { + "version": "9.10.0", + "resolved": "https://registry.npmjs.org/@wordpress/env/-/env-9.10.0.tgz", + "integrity": "sha512-GqUg1XdrUXI3l5NhHhEZisrccW+VPqJSU5xO1IXybI6KOvmSecidxWEqlMj26vzu2P5aLCWZcx28QkrrY3jvdg==", + "dev": true, + "license": "GPL-2.0-or-later", + "dependencies": { + "chalk": "^4.0.0", + "copy-dir": "^1.3.0", + "docker-compose": "^0.24.3", + "extract-zip": "^1.6.7", + "got": "^11.8.5", + "inquirer": "^7.1.0", + "js-yaml": "^3.13.1", + "ora": "^4.0.2", + "rimraf": "^3.0.2", + "simple-git": "^3.5.0", + "terminal-link": "^2.0.0", + "yargs": "^17.3.0" }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" + "bin": { + "wp-env": "bin/wp-env" } }, - "node_modules/@svgr/babel-plugin-remove-jsx-attribute": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-remove-jsx-attribute/-/babel-plugin-remove-jsx-attribute-8.0.0.tgz", - "integrity": "sha512-BcCkm/STipKvbCl6b7QFrMh/vx00vIP63k2eM66MfHJzPr6O2U0jYEViXkHJWqXqQYjdeA9cuCl5KWmlwjDvbA==", + "node_modules/@wordpress/env/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, "license": "MIT", + "dependencies": { + "color-convert": "^2.0.1" + }, "engines": { - "node": ">=14" + "node": ">=8" }, "funding": { - "type": "github", - "url": "https://github.com/sponsors/gregberge" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/@svgr/babel-plugin-remove-jsx-empty-expression": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-remove-jsx-empty-expression/-/babel-plugin-remove-jsx-empty-expression-8.0.0.tgz", - "integrity": "sha512-5BcGCBfBxB5+XSDSWnhTThfI9jcO5f0Ai2V24gZpG+wXF14BzwxxdDb4g6trdOux0rhibGs385BeFMSmxtS3uA==", + "node_modules/@wordpress/env/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, "license": "MIT", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, "engines": { - "node": ">=14" + "node": ">=10" }, "funding": { - "type": "github", - "url": "https://github.com/sponsors/gregberge" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" + "url": "https://github.com/chalk/chalk?sponsor=1" } }, - "node_modules/@svgr/babel-plugin-replace-jsx-attribute-value": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-replace-jsx-attribute-value/-/babel-plugin-replace-jsx-attribute-value-8.0.0.tgz", - "integrity": "sha512-KVQ+PtIjb1BuYT3ht8M5KbzWBhdAjjUPdlMtpuw/VjT8coTrItWX6Qafl9+ji831JaJcu6PJNKCV0bp01lBNzQ==", + "node_modules/@wordpress/env/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, "license": "MIT", - "engines": { - "node": ">=14" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/gregberge" + "dependencies": { + "color-name": "~1.1.4" }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" + "engines": { + "node": ">=7.0.0" } }, - "node_modules/@svgr/babel-plugin-svg-dynamic-title": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-svg-dynamic-title/-/babel-plugin-svg-dynamic-title-8.0.0.tgz", - "integrity": "sha512-omNiKqwjNmOQJ2v6ge4SErBbkooV2aAWwaPFs2vUY7p7GhVkzRkJ00kILXQvRhA6miHnNpXv7MRnnSjdRjK8og==", + "node_modules/@wordpress/env/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "dev": true, - "license": "MIT", - "engines": { - "node": ">=14" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/gregberge" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" - } + "license": "MIT" }, - "node_modules/@svgr/babel-plugin-svg-em-dimensions": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-svg-em-dimensions/-/babel-plugin-svg-em-dimensions-8.0.0.tgz", - "integrity": "sha512-mURHYnu6Iw3UBTbhGwE/vsngtCIbHE43xCRK7kCw4t01xyGqb2Pd+WXekRRoFOBIY29ZoOhUCTEweDMdrjfi9g==", + "node_modules/@wordpress/env/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, "license": "MIT", "engines": { - "node": ">=14" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/gregberge" - }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" + "node": ">=8" } }, - "node_modules/@svgr/babel-plugin-transform-react-native-svg": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-transform-react-native-svg/-/babel-plugin-transform-react-native-svg-8.1.0.tgz", - "integrity": "sha512-Tx8T58CHo+7nwJ+EhUwx3LfdNSG9R2OKfaIXXs5soiy5HtgoAEkDay9LIimLOcG8dJQH1wPZp/cnAv6S9CrR1Q==", + "node_modules/@wordpress/env/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, "license": "MIT", - "engines": { - "node": ">=14" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/gregberge" + "dependencies": { + "has-flag": "^4.0.0" }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" + "engines": { + "node": ">=8" } }, - "node_modules/@svgr/babel-plugin-transform-svg-component": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-transform-svg-component/-/babel-plugin-transform-svg-component-8.0.0.tgz", - "integrity": "sha512-DFx8xa3cZXTdb/k3kfPeaixecQLgKh5NVBMwD0AQxOzcZawK4oo1Jh9LbrcACUivsCA7TLG8eeWgrDXjTMhRmw==", - "dev": true, + "node_modules/@wordpress/escape-html": { + "version": "1.12.2", + "resolved": "https://registry.npmjs.org/@wordpress/escape-html/-/escape-html-1.12.2.tgz", + "integrity": "sha512-FabgSwznhdaUwe6hr1CsGpgxQbzqEoGevv73WIL1B9GvlZ6csRWodgHfWh4P6fYqpzxFL4WYB8wPJ1PdO32XFA==", + "license": "GPL-2.0-or-later", + "dependencies": { + "@babel/runtime": "^7.13.10" + } + }, + "node_modules/@wordpress/escape-html/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "license": "MIT", - "engines": { - "node": ">=12" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/gregberge" + "dependencies": { + "regenerator-runtime": "^0.14.0" }, - "peerDependencies": { - "@babel/core": "^7.0.0-0" + "engines": { + "node": ">=6.9.0" } }, - "node_modules/@svgr/babel-preset": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/@svgr/babel-preset/-/babel-preset-8.1.0.tgz", - "integrity": "sha512-7EYDbHE7MxHpv4sxvnVPngw5fuR6pw79SkcrILHJ/iMpuKySNCl5W1qcwPEpU+LgyRXOaAFgH0KhwD18wwg6ug==", + "node_modules/@wordpress/escape-html/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", + "license": "MIT" + }, + "node_modules/@wordpress/eslint-plugin": { + "version": "15.1.0", + "resolved": "https://registry.npmjs.org/@wordpress/eslint-plugin/-/eslint-plugin-15.1.0.tgz", + "integrity": "sha512-iKc8YnakbOWUh7b5A79XhZ9nIJfkHmKAkluxd56kwmKhhn1dfreRaCXpjjBk9E170axKmkHPqFar4xEMy9kO7A==", "dev": true, - "license": "MIT", + "license": "GPL-2.0-or-later", "dependencies": { - "@svgr/babel-plugin-add-jsx-attribute": "8.0.0", - "@svgr/babel-plugin-remove-jsx-attribute": "8.0.0", - "@svgr/babel-plugin-remove-jsx-empty-expression": "8.0.0", - "@svgr/babel-plugin-replace-jsx-attribute-value": "8.0.0", - "@svgr/babel-plugin-svg-dynamic-title": "8.0.0", - "@svgr/babel-plugin-svg-em-dimensions": "8.0.0", - "@svgr/babel-plugin-transform-react-native-svg": "8.1.0", - "@svgr/babel-plugin-transform-svg-component": "8.0.0" + "@babel/eslint-parser": "^7.16.0", + "@typescript-eslint/eslint-plugin": "^5.62.0", + "@typescript-eslint/parser": "^5.62.0", + "@wordpress/babel-preset-default": "^7.25.0", + "@wordpress/prettier-config": "^2.24.0", + "cosmiconfig": "^7.0.0", + "eslint-config-prettier": "^8.3.0", + "eslint-plugin-import": "^2.25.2", + "eslint-plugin-jest": "^27.2.1", + "eslint-plugin-jsdoc": "^46.4.6", + "eslint-plugin-jsx-a11y": "^6.5.1", + "eslint-plugin-prettier": "^3.3.0", + "eslint-plugin-react": "^7.27.0", + "eslint-plugin-react-hooks": "^4.3.0", + "globals": "^13.12.0", + "requireindex": "^1.2.0" }, "engines": { - "node": ">=14" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/gregberge" + "node": ">=14", + "npm": ">=6.14.4" }, "peerDependencies": { - "@babel/core": "^7.0.0-0" + "@babel/core": ">=7", + "eslint": ">=8", + "prettier": ">=2", + "typescript": ">=4" + }, + "peerDependenciesMeta": { + "prettier": { + "optional": true + }, + "typescript": { + "optional": true + } } }, - "node_modules/@svgr/core": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/@svgr/core/-/core-8.1.0.tgz", - "integrity": "sha512-8QqtOQT5ACVlmsvKOJNEaWmRPmcojMOzCz4Hs2BGG/toAp/K38LcsMRyLp349glq5AzJbCEeimEoxaX6v/fLrA==", + "node_modules/@wordpress/eslint-plugin/node_modules/@es-joy/jsdoccomment": { + "version": "0.41.0", + "resolved": "https://registry.npmjs.org/@es-joy/jsdoccomment/-/jsdoccomment-0.41.0.tgz", + "integrity": "sha512-aKUhyn1QI5Ksbqcr3fFJj16p99QdjUxXAEuFst1Z47DRyoiMwivIH9MV/ARcJOCXVjPfjITciej8ZD2O/6qUmw==", "dev": true, "license": "MIT", "dependencies": { - "@babel/core": "^7.21.3", - "@svgr/babel-preset": "8.1.0", - "camelcase": "^6.2.0", - "cosmiconfig": "^8.1.3", - "snake-case": "^3.0.4" + "comment-parser": "1.4.1", + "esquery": "^1.5.0", + "jsdoc-type-pratt-parser": "~4.0.0" }, "engines": { - "node": ">=14" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/gregberge" + "node": ">=16" } }, - "node_modules/@svgr/hast-util-to-babel-ast": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/@svgr/hast-util-to-babel-ast/-/hast-util-to-babel-ast-8.0.0.tgz", - "integrity": "sha512-EbDKwO9GpfWP4jN9sGdYwPBU0kdomaPIL2Eu4YwmgP+sJeXT+L7bMwJUBnhzfH8Q2qMBqZ4fJwpCyYsAN3mt2Q==", + "node_modules/@wordpress/eslint-plugin/node_modules/cosmiconfig": { + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-7.1.0.tgz", + "integrity": "sha512-AdmX6xUzdNASswsFtmwSt7Vj8po9IuqXm0UXz7QKPuEUmPB4XyjGfaAr2PSuELMwkRMVH1EpIkX5bTZGRB3eCA==", "dev": true, "license": "MIT", "dependencies": { - "@babel/types": "^7.21.3", - "entities": "^4.4.0" + "@types/parse-json": "^4.0.0", + "import-fresh": "^3.2.1", + "parse-json": "^5.0.0", + "path-type": "^4.0.0", + "yaml": "^1.10.0" }, "engines": { - "node": ">=14" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/gregberge" + "node": ">=10" } }, - "node_modules/@svgr/plugin-jsx": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/@svgr/plugin-jsx/-/plugin-jsx-8.1.0.tgz", - "integrity": "sha512-0xiIyBsLlr8quN+WyuxooNW9RJ0Dpr8uOnH/xrCVO8GLUcwHISwj1AG0k+LFzteTkAA0GbX0kj9q6Dk70PTiPA==", + "node_modules/@wordpress/eslint-plugin/node_modules/escape-string-regexp": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", + "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", "dev": true, "license": "MIT", - "dependencies": { - "@babel/core": "^7.21.3", - "@svgr/babel-preset": "8.1.0", - "@svgr/hast-util-to-babel-ast": "8.0.0", - "svg-parser": "^2.0.4" - }, "engines": { - "node": ">=14" + "node": ">=10" }, "funding": { - "type": "github", - "url": "https://github.com/sponsors/gregberge" - }, - "peerDependencies": { - "@svgr/core": "*" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@svgr/plugin-svgo": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/@svgr/plugin-svgo/-/plugin-svgo-8.1.0.tgz", - "integrity": "sha512-Ywtl837OGO9pTLIN/onoWLmDQ4zFUycI1g76vuKGEz6evR/ZTJlJuz3G/fIkb6OVBJ2g0o6CGJzaEjfmEo3AHA==", + "node_modules/@wordpress/eslint-plugin/node_modules/eslint-plugin-jsdoc": { + "version": "46.10.1", + "resolved": "https://registry.npmjs.org/eslint-plugin-jsdoc/-/eslint-plugin-jsdoc-46.10.1.tgz", + "integrity": "sha512-x8wxIpv00Y50NyweDUpa+58ffgSAI5sqe+zcZh33xphD0AVh+1kqr1ombaTRb7Fhpove1zfUuujlX9DWWBP5ag==", "dev": true, - "license": "MIT", + "license": "BSD-3-Clause", "dependencies": { - "cosmiconfig": "^8.1.3", - "deepmerge": "^4.3.1", - "svgo": "^3.0.2" + "@es-joy/jsdoccomment": "~0.41.0", + "are-docs-informative": "^0.0.2", + "comment-parser": "1.4.1", + "debug": "^4.3.4", + "escape-string-regexp": "^4.0.0", + "esquery": "^1.5.0", + "is-builtin-module": "^3.2.1", + "semver": "^7.5.4", + "spdx-expression-parse": "^4.0.0" }, "engines": { - "node": ">=14" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/gregberge" + "node": ">=16" }, "peerDependencies": { - "@svgr/core": "*" + "eslint": "^7.0.0 || ^8.0.0 || ^9.0.0" } }, - "node_modules/@svgr/webpack": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/@svgr/webpack/-/webpack-8.1.0.tgz", - "integrity": "sha512-LnhVjMWyMQV9ZmeEy26maJk+8HTIbd59cH4F2MJ439k9DqejRisfFNGAPvRYlKETuh9LrImlS8aKsBgKjMA8WA==", + "node_modules/@wordpress/eslint-plugin/node_modules/eslint-plugin-prettier": { + "version": "3.4.1", + "resolved": "https://registry.npmjs.org/eslint-plugin-prettier/-/eslint-plugin-prettier-3.4.1.tgz", + "integrity": "sha512-htg25EUYUeIhKHXjOinK4BgCcDwtLHjqaxCDsMy5nbnUMkKFvIhMVCp+5GFUXQ4Nr8lBsPqtGAqBenbpFqAA2g==", "dev": true, "license": "MIT", "dependencies": { - "@babel/core": "^7.21.3", - "@babel/plugin-transform-react-constant-elements": "^7.21.3", - "@babel/preset-env": "^7.20.2", - "@babel/preset-react": "^7.18.6", - "@babel/preset-typescript": "^7.21.0", - "@svgr/core": "8.1.0", - "@svgr/plugin-jsx": "8.1.0", - "@svgr/plugin-svgo": "8.1.0" + "prettier-linter-helpers": "^1.0.0" }, "engines": { - "node": ">=14" + "node": ">=6.0.0" }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/gregberge" + "peerDependencies": { + "eslint": ">=5.0.0", + "prettier": ">=1.13.0" + }, + "peerDependenciesMeta": { + "eslint-config-prettier": { + "optional": true + } } }, - "node_modules/@szmarczak/http-timer": { - "version": "4.0.6", - "resolved": "https://registry.npmjs.org/@szmarczak/http-timer/-/http-timer-4.0.6.tgz", - "integrity": "sha512-4BAffykYOgO+5nzBWYwE3W90sBgLJoUPRWWcL8wlyiM8IB8ipJz3UMJ9KXQd1RKQXpKp8Tutn80HZtWsu2u76w==", + "node_modules/@wordpress/eslint-plugin/node_modules/globals": { + "version": "13.24.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-13.24.0.tgz", + "integrity": "sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==", "dev": true, "license": "MIT", "dependencies": { - "defer-to-connect": "^2.0.0" + "type-fest": "^0.20.2" }, "engines": { - "node": ">=10" + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@tannin/compile": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@tannin/compile/-/compile-1.1.0.tgz", - "integrity": "sha512-n8m9eNDfoNZoxdvWiTfW/hSPhehzLJ3zW7f8E7oT6mCROoMNWCB4TYtv041+2FMAxweiE0j7i1jubQU4MEC/Gg==", - "license": "MIT", - "dependencies": { - "@tannin/evaluate": "^1.2.0", - "@tannin/postfix": "^1.1.0" + "node_modules/@wordpress/eslint-plugin/node_modules/semver": { + "version": "7.6.3", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", + "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" } }, - "node_modules/@tannin/evaluate": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/@tannin/evaluate/-/evaluate-1.2.0.tgz", - "integrity": "sha512-3ioXvNowbO/wSrxsDG5DKIMxC81P0QrQTYai8zFNY+umuoHWRPbQ/TuuDEOju9E+jQDXmj6yI5GyejNuh8I+eg==", - "license": "MIT" - }, - "node_modules/@tannin/plural-forms": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@tannin/plural-forms/-/plural-forms-1.1.0.tgz", - "integrity": "sha512-xl9R2mDZO/qiHam1AgMnAES6IKIg7OBhcXqy6eDsRCdXuxAFPcjrej9HMjyCLE0DJ/8cHf0i5OQTstuBRhpbHw==", - "license": "MIT", - "dependencies": { - "@tannin/compile": "^1.1.0" + "node_modules/@wordpress/eslint-plugin/node_modules/type-fest": { + "version": "0.20.2", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", + "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", + "dev": true, + "license": "(MIT OR CC0-1.0)", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@tannin/postfix": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@tannin/postfix/-/postfix-1.1.0.tgz", - "integrity": "sha512-oocsqY7g0cR+Gur5jRQLSrX2OtpMLMse1I10JQBm8CdGMrDkh1Mg2gjsiquMHRtBs4Qwu5wgEp5GgIYHk4SNPw==", - "license": "MIT" - }, - "node_modules/@trysound/sax": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/@trysound/sax/-/sax-0.2.0.tgz", - "integrity": "sha512-L7z9BgrNEcYyUYtF+HaEfiS5ebkh9jXqbszz7pC0hRBPaatV0XjSD3+eHrpqFemQfgwiFF0QPIarnIihIDn7OA==", + "node_modules/@wordpress/eslint-plugin/node_modules/yaml": { + "version": "1.10.2", + "resolved": "https://registry.npmjs.org/yaml/-/yaml-1.10.2.tgz", + "integrity": "sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg==", "dev": true, "license": "ISC", "engines": { - "node": ">=10.13.0" + "node": ">= 6" } }, - "node_modules/@types/body-parser": { - "version": "1.19.5", - "resolved": "https://registry.npmjs.org/@types/body-parser/-/body-parser-1.19.5.tgz", - "integrity": "sha512-fB3Zu92ucau0iQ0JMCFQE7b/dv8Ot07NI3KaZIkIUNXq82k4eBAqUaneXfleGY9JWskeS9y+u0nXMyspcuQrCg==", - "dev": true, - "license": "MIT", + "node_modules/@wordpress/hooks": { + "version": "2.12.3", + "resolved": "https://registry.npmjs.org/@wordpress/hooks/-/hooks-2.12.3.tgz", + "integrity": "sha512-LmKiwKldZt6UYqOxV/a6+eUFXdvALFnB/pQx3RmrMvO64sgFhfR6dhrlv+uVbuuezSuv8dce1jx8lUWAT0krMA==", + "license": "GPL-2.0-or-later", "dependencies": { - "@types/connect": "*", - "@types/node": "*" + "@babel/runtime": "^7.13.10" } }, - "node_modules/@types/bonjour": { - "version": "3.5.13", - "resolved": "https://registry.npmjs.org/@types/bonjour/-/bonjour-3.5.13.tgz", - "integrity": "sha512-z9fJ5Im06zvUL548KvYNecEVlA7cVDkGUi6kZusb04mpyEFKCIZJvloCcmpmLaIahDpOQGHaHmG6imtPMmPXGQ==", - "dev": true, + "node_modules/@wordpress/hooks/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "license": "MIT", "dependencies": { - "@types/node": "*" + "regenerator-runtime": "^0.14.0" + }, + "engines": { + "node": ">=6.9.0" } }, - "node_modules/@types/cacheable-request": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/@types/cacheable-request/-/cacheable-request-6.0.3.tgz", - "integrity": "sha512-IQ3EbTzGxIigb1I3qPZc1rWJnH0BmSKv5QYTalEwweFvyBDLSAe24zP0le/hyi7ecGfZVlIVAg4BZqb8WBwKqw==", - "dev": true, - "license": "MIT", - "dependencies": { - "@types/http-cache-semantics": "*", - "@types/keyv": "^3.1.4", - "@types/node": "*", - "@types/responselike": "^1.0.0" - } + "node_modules/@wordpress/hooks/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", + "license": "MIT" }, - "node_modules/@types/connect": { - "version": "3.4.38", - "resolved": "https://registry.npmjs.org/@types/connect/-/connect-3.4.38.tgz", - "integrity": "sha512-K6uROf1LD88uDQqJCktA4yzL1YYAK6NgfsI0v/mTgyPKWsX1CnJ0XPSDhViejru1GcRkLWb8RlzFYJRqGUbaug==", - "dev": true, - "license": "MIT", + "node_modules/@wordpress/i18n": { + "version": "3.20.0", + "resolved": "https://registry.npmjs.org/@wordpress/i18n/-/i18n-3.20.0.tgz", + "integrity": "sha512-SIoOJFB4UrrYAScS4H91CYCLW9dX3Ghv8pBKc/yHGculb1AdGr6gRMlmJxZV62Cn3CZ4Ga86c+FfR+GiBu0JPg==", + "license": "GPL-2.0-or-later", "dependencies": { - "@types/node": "*" + "@babel/runtime": "^7.13.10", + "@wordpress/hooks": "^2.12.3", + "gettext-parser": "^1.3.1", + "lodash": "^4.17.19", + "memize": "^1.1.0", + "sprintf-js": "^1.1.1", + "tannin": "^1.2.0" + }, + "bin": { + "pot-to-php": "tools/pot-to-php.js" } }, - "node_modules/@types/connect-history-api-fallback": { - "version": "1.5.4", - "resolved": "https://registry.npmjs.org/@types/connect-history-api-fallback/-/connect-history-api-fallback-1.5.4.tgz", - "integrity": "sha512-n6Cr2xS1h4uAulPRdlw6Jl6s1oG8KrVilPN2yUITEs+K48EzMJJ3W1xy8K5eWuFvjp3R74AOIGSmp2UfBJ8HFw==", - "dev": true, + "node_modules/@wordpress/i18n/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "license": "MIT", "dependencies": { - "@types/express-serve-static-core": "*", - "@types/node": "*" + "regenerator-runtime": "^0.14.0" + }, + "engines": { + "node": ">=6.9.0" } }, - "node_modules/@types/estree": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.6.tgz", - "integrity": "sha512-AYnb1nQyY49te+VRAVgmzfcgjYS91mY5P0TKUDCLEM+gNnA+3T6rWITXRLYCpahpqSQbN5cE+gHpnPyXjHWxcw==", - "dev": true, + "node_modules/@wordpress/i18n/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", "license": "MIT" }, - "node_modules/@types/express": { - "version": "4.17.21", - "resolved": "https://registry.npmjs.org/@types/express/-/express-4.17.21.tgz", - "integrity": "sha512-ejlPM315qwLpaQlQDTjPdsUFSc6ZsP4AN6AlWnogPjQ7CVi7PYF3YVz+CY3jE2pwYf7E/7HlDAN0rV2GxTG0HQ==", - "dev": true, - "license": "MIT", + "node_modules/@wordpress/is-shallow-equal": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/@wordpress/is-shallow-equal/-/is-shallow-equal-1.8.0.tgz", + "integrity": "sha512-OV3qJqP9LhjuOzt85TsyBwv+//CvC8Byf/81D3NmjPKlstLaD/bBCC5nBhH6dKAv4bShYtQ2Hmut+V4dZnOM1A==", + "license": "GPL-2.0-or-later", "dependencies": { - "@types/body-parser": "*", - "@types/express-serve-static-core": "^4.17.33", - "@types/qs": "*", - "@types/serve-static": "*" + "@babel/runtime": "^7.8.3" } }, - "node_modules/@types/express-serve-static-core": { - "version": "4.19.5", - "resolved": "https://registry.npmjs.org/@types/express-serve-static-core/-/express-serve-static-core-4.19.5.tgz", - "integrity": "sha512-y6W03tvrACO72aijJ5uF02FRq5cgDR9lUxddQ8vyF+GvmjJQqbzDcJngEjURc+ZsG31VI3hODNZJ2URj86pzmg==", - "dev": true, + "node_modules/@wordpress/is-shallow-equal/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "license": "MIT", "dependencies": { - "@types/node": "*", - "@types/qs": "*", - "@types/range-parser": "*", - "@types/send": "*" + "regenerator-runtime": "^0.14.0" + }, + "engines": { + "node": ">=6.9.0" } }, - "node_modules/@types/http-cache-semantics": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/@types/http-cache-semantics/-/http-cache-semantics-4.0.4.tgz", - "integrity": "sha512-1m0bIFVc7eJWyve9S0RnuRgcQqF/Xd5QsUZAZeQFr1Q3/p9JWoQQEqmVy+DPTNpGXwhgIetAoYF8JSc33q29QA==", - "dev": true, - "license": "MIT" - }, - "node_modules/@types/http-errors": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/@types/http-errors/-/http-errors-2.0.4.tgz", - "integrity": "sha512-D0CFMMtydbJAegzOyHjtiKPLlvnm3iTZyZRSZoLq2mRhDdmLfIWOCYPfQJ4cu2erKghU++QvjcUjp/5h7hESpA==", - "dev": true, + "node_modules/@wordpress/is-shallow-equal/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", "license": "MIT" }, - "node_modules/@types/http-proxy": { - "version": "1.17.15", - "resolved": "https://registry.npmjs.org/@types/http-proxy/-/http-proxy-1.17.15.tgz", - "integrity": "sha512-25g5atgiVNTIv0LBDTg1H74Hvayx0ajtJPLLcYE3whFv75J0pWNtOBzaXJQgDTmrX1bx5U9YC2w/n65BN1HwRQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@types/node": "*" - } - }, - "node_modules/@types/istanbul-lib-coverage": { - "version": "2.0.6", - "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz", - "integrity": "sha512-2QF/t/auWm0lsy8XtKVPG19v3sSOQlJe/YHZgfjb/KBBHOGSV+J2q/S671rcq9uTBrLAXmZpqJiaQbMT+zNU1w==", - "license": "MIT", - "peer": true - }, - "node_modules/@types/istanbul-lib-report": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@types/istanbul-lib-report/-/istanbul-lib-report-3.0.3.tgz", - "integrity": "sha512-NQn7AHQnk/RSLOxrBbGyJM/aVQ+pjj5HCgasFxc0K/KhoATfQ/47AyUl15I2yBUpihjmas+a+VJBOqecrFH+uA==", - "license": "MIT", - "peer": true, + "node_modules/@wordpress/keycodes": { + "version": "2.19.3", + "resolved": "https://registry.npmjs.org/@wordpress/keycodes/-/keycodes-2.19.3.tgz", + "integrity": "sha512-8rNdmP5M1ifTgLIL0dt/N1uTGsq/Rx1ydCXy+gg24WdxBRhyu5sudNVCtascVXo26aIfOH9OJRdqRZZTEORhog==", + "license": "GPL-2.0-or-later", "dependencies": { - "@types/istanbul-lib-coverage": "*" + "@babel/runtime": "^7.13.10", + "@wordpress/i18n": "^3.20.0", + "lodash": "^4.17.19" } }, - "node_modules/@types/istanbul-reports": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.4.tgz", - "integrity": "sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ==", + "node_modules/@wordpress/keycodes/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "license": "MIT", - "peer": true, "dependencies": { - "@types/istanbul-lib-report": "*" + "regenerator-runtime": "^0.14.0" + }, + "engines": { + "node": ">=6.9.0" } }, - "node_modules/@types/json-schema": { - "version": "7.0.15", - "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.15.tgz", - "integrity": "sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==", - "dev": true, + "node_modules/@wordpress/keycodes/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", "license": "MIT" }, - "node_modules/@types/json5": { - "version": "0.0.29", - "resolved": "https://registry.npmjs.org/@types/json5/-/json5-0.0.29.tgz", - "integrity": "sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==", + "node_modules/@wordpress/prettier-config": { + "version": "2.25.13", + "resolved": "https://registry.npmjs.org/@wordpress/prettier-config/-/prettier-config-2.25.13.tgz", + "integrity": "sha512-iz58o0X91E24j0VFtzwn5qG84w+s4VlRCuZWa/lPL6pfGtOSw30c60wCrYKCA1IWIIAWdpRAYfEh7errPyKiPQ==", "dev": true, - "license": "MIT" + "license": "GPL-2.0-or-later", + "engines": { + "node": ">=14" + }, + "peerDependencies": { + "prettier": ">=2" + } }, - "node_modules/@types/keyv": { - "version": "3.1.4", - "resolved": "https://registry.npmjs.org/@types/keyv/-/keyv-3.1.4.tgz", - "integrity": "sha512-BQ5aZNSCpj7D6K2ksrRCTmKRLEpnPvWDiLPfoGyhZ++8YtiK9d/3DBKPJgry359X/P1PfruyYwvnvwFjuEiEIg==", - "dev": true, + "node_modules/@wordpress/priority-queue": { + "version": "1.11.2", + "resolved": "https://registry.npmjs.org/@wordpress/priority-queue/-/priority-queue-1.11.2.tgz", + "integrity": "sha512-ulwmUOklY3orn1xXpcPnTyGWV5B/oycxI+cHZ6EevBVgM5sq+BW3xo0PKLR/MMm6UNBtFTu/71QAJrNZcD6V1g==", + "license": "GPL-2.0-or-later", + "dependencies": { + "@babel/runtime": "^7.13.10" + } + }, + "node_modules/@wordpress/priority-queue/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "license": "MIT", "dependencies": { - "@types/node": "*" + "regenerator-runtime": "^0.14.0" + }, + "engines": { + "node": ">=6.9.0" } }, - "node_modules/@types/mime": { - "version": "1.3.5", - "resolved": "https://registry.npmjs.org/@types/mime/-/mime-1.3.5.tgz", - "integrity": "sha512-/pyBZWSLD2n0dcHE3hq8s8ZvcETHtEuF+3E7XVt0Ig2nvsVQXdghHVcEkIWjy9A0wKfTn97a/PSDYohKIlnP/w==", - "dev": true, + "node_modules/@wordpress/priority-queue/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", "license": "MIT" }, - "node_modules/@types/node": { - "version": "22.5.5", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.5.5.tgz", - "integrity": "sha512-Xjs4y5UPO/CLdzpgR6GirZJx36yScjh73+2NlLlkFRSoQN8B0DpfXPdZGnvVmLRLOsqDpOfTNv7D9trgGhmOIA==", - "license": "MIT", + "node_modules/@wordpress/redux-routine": { + "version": "3.14.2", + "resolved": "https://registry.npmjs.org/@wordpress/redux-routine/-/redux-routine-3.14.2.tgz", + "integrity": "sha512-aqi4UtvMP/+NhULxyCR8ktG0v4BJVTRcMpByAqDg7Oabq2sz2LPuShxd5UY8vxQYQY9t1uUJbslhom4ytcohWg==", + "license": "GPL-2.0-or-later", "dependencies": { - "undici-types": "~6.19.2" + "@babel/runtime": "^7.13.10", + "is-promise": "^4.0.0", + "lodash": "^4.17.19", + "rungen": "^0.3.2" } }, - "node_modules/@types/node-forge": { - "version": "1.3.11", - "resolved": "https://registry.npmjs.org/@types/node-forge/-/node-forge-1.3.11.tgz", - "integrity": "sha512-FQx220y22OKNTqaByeBGqHWYz4cl94tpcxeFdvBo3wjG6XPBuZ0BNgNZRV5J5TFmmcsJ4IzsLkmGRiQbnYsBEQ==", + "node_modules/@wordpress/redux-routine/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "license": "MIT", "dependencies": { - "@types/node": "*" + "regenerator-runtime": "^0.14.0" + }, + "engines": { + "node": ">=6.9.0" } }, - "node_modules/@types/parse-json": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/@types/parse-json/-/parse-json-4.0.2.tgz", - "integrity": "sha512-dISoDXWWQwUquiKsyZ4Ng+HX2KsPL7LyHKHQwgGFEA3IaKac4Obd+h2a/a6waisAoepJlBcx9paWqjA8/HVjCw==", - "dev": true, - "license": "MIT" - }, - "node_modules/@types/prop-types": { - "version": "15.7.13", - "resolved": "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.13.tgz", - "integrity": "sha512-hCZTSvwbzWGvhqxp/RqVqwU999pBf2vp7hzIjiYOsl8wqOmUxkQ6ddw1cV3l8811+kdUFus/q4d1Y3E3SyEifA==", - "license": "MIT" - }, - "node_modules/@types/qs": { - "version": "6.9.16", - "resolved": "https://registry.npmjs.org/@types/qs/-/qs-6.9.16.tgz", - "integrity": "sha512-7i+zxXdPD0T4cKDuxCUXJ4wHcsJLwENa6Z3dCu8cfCK743OGy5Nu1RmAGqDPsoTDINVEcdXKRvR/zre+P2Ku1A==", - "dev": true, + "node_modules/@wordpress/redux-routine/node_modules/is-promise": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/is-promise/-/is-promise-4.0.0.tgz", + "integrity": "sha512-hvpoI6korhJMnej285dSg6nu1+e6uxs7zG3BYAm5byqDsgJNWwxzM6z6iZiAgQR4TJ30JmBTOwqZUw3WlyH3AQ==", "license": "MIT" }, - "node_modules/@types/range-parser": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/@types/range-parser/-/range-parser-1.2.7.tgz", - "integrity": "sha512-hKormJbkJqzQGhziax5PItDUTMAM9uE2XXQmM37dyd4hVM+5aVl7oVxMVUiVQn2oCQFN/LKCZdvSM0pFRqbSmQ==", - "dev": true, + "node_modules/@wordpress/redux-routine/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", "license": "MIT" }, - "node_modules/@types/react": { - "version": "16.14.61", - "resolved": "https://registry.npmjs.org/@types/react/-/react-16.14.61.tgz", - "integrity": "sha512-CK3zd17pDWAEMnN5TdzwQJQlto2dK/lb0WZsI74owWgQ8PR60WRk0sCeBxLWuSuuqqDZKqeUcxod/8yECqrP/g==", - "license": "MIT", + "node_modules/@wordpress/rich-text": { + "version": "3.25.3", + "resolved": "https://registry.npmjs.org/@wordpress/rich-text/-/rich-text-3.25.3.tgz", + "integrity": "sha512-FdqL1/rHTsRxZ1gW1UEWuy0URmUEqMzj5hcAbOhHFPO5m0ENrkzC9bBa195KqZBSNSmBmXnDZdHu4UJUolzcZg==", + "license": "GPL-2.0-or-later", "dependencies": { - "@types/prop-types": "*", - "@types/scheduler": "^0.16", - "csstype": "^3.0.2" + "@babel/runtime": "^7.13.10", + "@wordpress/compose": "^3.25.3", + "@wordpress/data": "^4.27.3", + "@wordpress/dom": "^2.18.0", + "@wordpress/element": "^2.20.3", + "@wordpress/escape-html": "^1.12.2", + "@wordpress/is-shallow-equal": "^3.1.3", + "@wordpress/keycodes": "^2.19.3", + "classnames": "^2.2.5", + "lodash": "^4.17.19", + "memize": "^1.1.0", + "rememo": "^3.0.0" } }, - "node_modules/@types/react-dom": { - "version": "16.9.24", - "resolved": "https://registry.npmjs.org/@types/react-dom/-/react-dom-16.9.24.tgz", - "integrity": "sha512-Gcmq2JTDheyWn/1eteqyzzWKSqDjYU6KYsIvH7thb7CR5OYInAWOX+7WnKf6PaU/cbdOc4szJItcDEJO7UGmfA==", + "node_modules/@wordpress/rich-text/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "license": "MIT", "dependencies": { - "@types/react": "^16" + "regenerator-runtime": "^0.14.0" + }, + "engines": { + "node": ">=6.9.0" } }, - "node_modules/@types/responselike": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@types/responselike/-/responselike-1.0.3.tgz", - "integrity": "sha512-H/+L+UkTV33uf49PH5pCAUBVPNj2nDBXTN+qS1dOwyyg24l3CcicicCA7ca+HMvJBZcFgl5r8e+RR6elsb4Lyw==", - "dev": true, - "license": "MIT", + "node_modules/@wordpress/rich-text/node_modules/@wordpress/data": { + "version": "4.27.3", + "resolved": "https://registry.npmjs.org/@wordpress/data/-/data-4.27.3.tgz", + "integrity": "sha512-5763NgNV9IIa1CC3Q80dAvrH6108tJtj3IrHfUCZmUk1atSNsOMBCkLdQ7tGTTi2JFejeGEMg1LJI22JD5zM6Q==", + "license": "GPL-2.0-or-later", "dependencies": { - "@types/node": "*" + "@babel/runtime": "^7.13.10", + "@wordpress/compose": "^3.25.3", + "@wordpress/deprecated": "^2.12.3", + "@wordpress/element": "^2.20.3", + "@wordpress/is-shallow-equal": "^3.1.3", + "@wordpress/priority-queue": "^1.11.2", + "@wordpress/redux-routine": "^3.14.2", + "equivalent-key-map": "^0.2.2", + "is-promise": "^4.0.0", + "lodash": "^4.17.19", + "memize": "^1.1.0", + "redux": "^4.0.0", + "turbo-combine-reducers": "^1.0.2", + "use-memo-one": "^1.1.1" } }, - "node_modules/@types/retry": { - "version": "0.12.0", - "resolved": "https://registry.npmjs.org/@types/retry/-/retry-0.12.0.tgz", - "integrity": "sha512-wWKOClTTiizcZhXnPY4wikVAwmdYHp8q6DmC+EJUzAMsycb7HB32Kh9RN4+0gExjmPmZSAQjgURXIGATPegAvA==", - "dev": true, - "license": "MIT" + "node_modules/@wordpress/rich-text/node_modules/@wordpress/is-shallow-equal": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/@wordpress/is-shallow-equal/-/is-shallow-equal-3.1.3.tgz", + "integrity": "sha512-eDLhfC4aaSgklzqwc6F/F4zmJVpTVTAvhqX+q0SP/8LPcP2HuKErPHVrEc75PMWqIutja2wJg98YSNPdewrj1w==", + "license": "GPL-2.0-or-later", + "dependencies": { + "@babel/runtime": "^7.13.10" + } }, - "node_modules/@types/scheduler": { - "version": "0.16.8", - "resolved": "https://registry.npmjs.org/@types/scheduler/-/scheduler-0.16.8.tgz", - "integrity": "sha512-WZLiwShhwLRmeV6zH+GkbOFT6Z6VklCItrDioxUnv+u4Ll+8vKeFySoFyK/0ctcRpOmwAicELfmys1sDc/Rw+A==", + "node_modules/@wordpress/rich-text/node_modules/is-promise": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/is-promise/-/is-promise-4.0.0.tgz", + "integrity": "sha512-hvpoI6korhJMnej285dSg6nu1+e6uxs7zG3BYAm5byqDsgJNWwxzM6z6iZiAgQR4TJ30JmBTOwqZUw3WlyH3AQ==", "license": "MIT" }, - "node_modules/@types/semver": { - "version": "7.5.8", - "resolved": "https://registry.npmjs.org/@types/semver/-/semver-7.5.8.tgz", - "integrity": "sha512-I8EUhyrgfLrcTkzV3TSsGyl1tSuPrEDzr0yd5m90UgNxQkyDXULk3b6MlQqTCpZpNtWe1K0hzclnZkTcLBe2UQ==", - "dev": true, + "node_modules/@wordpress/rich-text/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", "license": "MIT" }, - "node_modules/@types/send": { - "version": "0.17.4", - "resolved": "https://registry.npmjs.org/@types/send/-/send-0.17.4.tgz", - "integrity": "sha512-x2EM6TJOybec7c52BX0ZspPodMsQUd5L6PRwOunVyVUhXiBSKf3AezDL8Dgvgt5o0UfKNfuA0eMLr2wLT4AiBA==", + "node_modules/@wordpress/stylelint-config": { + "version": "23.14.0", + "resolved": "https://registry.npmjs.org/@wordpress/stylelint-config/-/stylelint-config-23.14.0.tgz", + "integrity": "sha512-SxrPIiR7LE8DMQblsPkiE81VY/JQAaU5SGmphDG+Bc2DnxfOdkt1oMsSUfsSEVwHuRlgh4ZD42CLlIV+Y0AexQ==", "dev": true, "license": "MIT", "dependencies": { - "@types/mime": "^1", - "@types/node": "*" - } - }, - "node_modules/@types/serve-index": { - "version": "1.9.4", - "resolved": "https://registry.npmjs.org/@types/serve-index/-/serve-index-1.9.4.tgz", - "integrity": "sha512-qLpGZ/c2fhSs5gnYsQxtDEq3Oy8SXPClIXkW5ghvAvsNuVSA8k+gCONcUCS/UjLEYvYps+e8uBtfgXgvhwfNug==", - "dev": true, + "@stylistic/stylelint-plugin": "^3.0.1", + "stylelint-config-recommended": "^14.0.1", + "stylelint-config-recommended-scss": "^14.1.0" + }, + "engines": { + "node": ">=18.12.0", + "npm": ">=8.19.2" + }, + "peerDependencies": { + "stylelint": "^16.8.2", + "stylelint-scss": "^6.4.0" + } + }, + "node_modules/@wordpress/url": { + "version": "2.22.2", + "resolved": "https://registry.npmjs.org/@wordpress/url/-/url-2.22.2.tgz", + "integrity": "sha512-aqpYKQXzyzkCOm+GzZRYlLb+wh58g0cwR1PaKAl0UXaBS4mdS+X6biMriylb4P8CVC/RR7CSw5XI20JC24KDwQ==", + "license": "GPL-2.0-or-later", + "dependencies": { + "@babel/runtime": "^7.13.10", + "lodash": "^4.17.19", + "react-native-url-polyfill": "^1.1.2" + } + }, + "node_modules/@wordpress/url/node_modules/@babel/runtime": { + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "license": "MIT", "dependencies": { - "@types/express": "*" + "regenerator-runtime": "^0.14.0" + }, + "engines": { + "node": ">=6.9.0" } }, - "node_modules/@types/serve-static": { - "version": "1.15.7", - "resolved": "https://registry.npmjs.org/@types/serve-static/-/serve-static-1.15.7.tgz", - "integrity": "sha512-W8Ym+h8nhuRwaKPaDw34QUkwsGi6Rc4yYqvKFo5rm2FUEhCFbzVWrxXUxuKK8TASjWsysJY0nsmNCGhCOIsrOw==", - "dev": true, + "node_modules/@wordpress/url/node_modules/react-native-url-polyfill": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/react-native-url-polyfill/-/react-native-url-polyfill-1.3.0.tgz", + "integrity": "sha512-w9JfSkvpqqlix9UjDvJjm1EjSt652zVQ6iwCIj1cVVkwXf4jQhQgTNXY6EVTwuAmUjg6BC6k9RHCBynoLFo3IQ==", "license": "MIT", "dependencies": { - "@types/http-errors": "*", - "@types/node": "*", - "@types/send": "*" + "whatwg-url-without-unicode": "8.0.0-3" + }, + "peerDependencies": { + "react-native": "*" } }, - "node_modules/@types/sinonjs__fake-timers": { - "version": "8.1.1", - "resolved": "https://registry.npmjs.org/@types/sinonjs__fake-timers/-/sinonjs__fake-timers-8.1.1.tgz", - "integrity": "sha512-0kSuKjAS0TrGLJ0M/+8MaFkGsQhZpB6pxOmvS3K8FYI72K//YmdfoW9X2qPsAKh1mkwxGD5zib9s1FIFed6E8g==", - "dev": true, + "node_modules/@wordpress/url/node_modules/regenerator-runtime": { + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", "license": "MIT" }, - "node_modules/@types/sizzle": { - "version": "2.3.8", - "resolved": "https://registry.npmjs.org/@types/sizzle/-/sizzle-2.3.8.tgz", - "integrity": "sha512-0vWLNK2D5MT9dg0iOo8GlKguPAU02QjmZitPEsXRuJXU/OGIOt9vT9Fc26wtYuavLxtO45v9PGleoL9Z0k1LHg==", + "node_modules/@wordpress/warning": { + "version": "2.58.0", + "resolved": "https://registry.npmjs.org/@wordpress/warning/-/warning-2.58.0.tgz", + "integrity": "sha512-9bZlORhyMY2nbWozeyC5kqJsFzEPP4DCLhGmjtbv+YWGHttUrxUZEfrKdqO+rUODA8rP5zeIly1nCQOUnkw4Lg==", "dev": true, - "license": "MIT" + "license": "GPL-2.0-or-later", + "engines": { + "node": ">=12" + } }, - "node_modules/@types/sockjs": { - "version": "0.3.36", - "resolved": "https://registry.npmjs.org/@types/sockjs/-/sockjs-0.3.36.tgz", - "integrity": "sha512-MK9V6NzAS1+Ud7JV9lJLFqW85VbC9dq3LmwZCuBe4wBDgKC0Kj/jd8Xl+nSviU+Qc3+m7umHHyHg//2KSa0a0Q==", + "node_modules/@xtuc/ieee754": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/@xtuc/ieee754/-/ieee754-1.2.0.tgz", + "integrity": "sha512-DX8nKgqcGwsc0eJSqYt5lwP4DH5FlHnmuWWBRy7X0NcaGR0ZtuyeESgMwTYVEtxmsNGY+qit4QYT/MIYTOTPeA==", "dev": true, - "license": "MIT", - "dependencies": { - "@types/node": "*" - } + "license": "BSD-3-Clause" }, - "node_modules/@types/stack-utils": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.3.tgz", - "integrity": "sha512-9aEbYZ3TbYMznPdcdr3SmIrLXwC/AKZXQeCf9Pgao5CKb8CyHuEX5jzWPTkvregvhRJHcpRO6BFoGW9ycaOkYw==", - "license": "MIT", - "peer": true + "node_modules/@xtuc/long": { + "version": "4.2.2", + "resolved": "https://registry.npmjs.org/@xtuc/long/-/long-4.2.2.tgz", + "integrity": "sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ==", + "dev": true, + "license": "Apache-2.0" }, - "node_modules/@types/ws": { - "version": "8.5.12", - "resolved": "https://registry.npmjs.org/@types/ws/-/ws-8.5.12.tgz", - "integrity": "sha512-3tPRkv1EtkDpzlgyKyI8pGsGZAGPEaXeu0DOj5DI25Ja91bdAYddYHbADRYVrZMRbfW+1l5YwXVDKohDJNQxkQ==", + "node_modules/accepts": { + "version": "1.3.8", + "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.8.tgz", + "integrity": "sha512-PYAthTa2m2VKxuvSD3DPC/Gy+U+sOA1LAuT8mkmRuvw+NACSaeXEQ+NHcVF7rONl6qcaxV3Uuemwawk+7+SJLw==", "dev": true, "license": "MIT", "dependencies": { - "@types/node": "*" + "mime-types": "~2.1.34", + "negotiator": "0.6.3" + }, + "engines": { + "node": ">= 0.6" } }, - "node_modules/@types/yargs": { - "version": "17.0.33", - "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.33.tgz", - "integrity": "sha512-WpxBCKWPLr4xSsHgz511rFJAM+wS28w2zEO1QDNY5zM/S8ok70NNfztH0xwhqKyaK0OHCbN98LDAZuy1ctxDkA==", + "node_modules/acorn": { + "version": "8.12.1", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.12.1.tgz", + "integrity": "sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg==", + "dev": true, "license": "MIT", - "peer": true, - "dependencies": { - "@types/yargs-parser": "*" + "bin": { + "acorn": "bin/acorn" + }, + "engines": { + "node": ">=0.4.0" } }, - "node_modules/@types/yargs-parser": { - "version": "21.0.3", - "resolved": "https://registry.npmjs.org/@types/yargs-parser/-/yargs-parser-21.0.3.tgz", - "integrity": "sha512-I4q9QU9MQv4oEOz4tAHJtNz1cwuLxn2F3xcc2iV5WdqLPpUnj30aUuxt1mAxYTG+oe8CZMV/+6rU4S4gRDzqtQ==", + "node_modules/acorn-import-attributes": { + "version": "1.9.5", + "resolved": "https://registry.npmjs.org/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz", + "integrity": "sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ==", + "dev": true, "license": "MIT", - "peer": true + "peerDependencies": { + "acorn": "^8" + } }, - "node_modules/@types/yauzl": { - "version": "2.10.3", - "resolved": "https://registry.npmjs.org/@types/yauzl/-/yauzl-2.10.3.tgz", - "integrity": "sha512-oJoftv0LSuaDZE3Le4DbKX+KS9G36NzOeSap90UIK0yMA/NhKJhqlSGtNDORNRaIbQfzjXDrQa0ytJ6mNRGz/Q==", + "node_modules/acorn-jsx": { + "version": "5.3.2", + "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz", + "integrity": "sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==", "dev": true, "license": "MIT", - "optional": true, - "dependencies": { - "@types/node": "*" + "peerDependencies": { + "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" } }, - "node_modules/@typescript-eslint/eslint-plugin": { - "version": "5.62.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.62.0.tgz", - "integrity": "sha512-TiZzBSJja/LbhNPvk6yc0JrX9XqhQ0hdh6M2svYfsHGejaKFIAGd9MQ+ERIMzLGlN/kZoYIgdxFV0PuljTKXag==", + "node_modules/aggregate-error": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/aggregate-error/-/aggregate-error-3.1.0.tgz", + "integrity": "sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==", "dev": true, "license": "MIT", "dependencies": { - "@eslint-community/regexpp": "^4.4.0", - "@typescript-eslint/scope-manager": "5.62.0", - "@typescript-eslint/type-utils": "5.62.0", - "@typescript-eslint/utils": "5.62.0", - "debug": "^4.3.4", - "graphemer": "^1.4.0", - "ignore": "^5.2.0", - "natural-compare-lite": "^1.4.0", - "semver": "^7.3.7", - "tsutils": "^3.21.0" + "clean-stack": "^2.0.0", + "indent-string": "^4.0.0" }, "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "node": ">=8" + } + }, + "node_modules/airbnb-prop-types": { + "version": "2.16.0", + "resolved": "https://registry.npmjs.org/airbnb-prop-types/-/airbnb-prop-types-2.16.0.tgz", + "integrity": "sha512-7WHOFolP/6cS96PhKNrslCLMYAI8yB1Pp6u6XmxozQOiZbsI5ycglZr5cHhBFfuRcQQjzCMith5ZPZdYiJCxUg==", + "deprecated": "This package has been renamed to 'prop-types-tools'", + "license": "MIT", + "dependencies": { + "array.prototype.find": "^2.1.1", + "function.prototype.name": "^1.1.2", + "is-regex": "^1.1.0", + "object-is": "^1.1.2", + "object.assign": "^4.1.0", + "object.entries": "^1.1.2", + "prop-types": "^15.7.2", + "prop-types-exact": "^1.2.0", + "react-is": "^16.13.1" }, "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" + "url": "https://github.com/sponsors/ljharb" }, "peerDependencies": { - "@typescript-eslint/parser": "^5.0.0", - "eslint": "^6.0.0 || ^7.0.0 || ^8.0.0" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } + "react": "^0.14 || ^15.0.0 || ^16.0.0-alpha" } }, - "node_modules/@typescript-eslint/eslint-plugin/node_modules/semver": { - "version": "7.6.3", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", - "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", + "node_modules/airbnb-prop-types/node_modules/react-is": { + "version": "16.13.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", + "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==", + "license": "MIT" + }, + "node_modules/ajv": { + "version": "6.12.6", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", + "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==", "dev": true, - "license": "ISC", - "bin": { - "semver": "bin/semver.js" + "license": "MIT", + "dependencies": { + "fast-deep-equal": "^3.1.1", + "fast-json-stable-stringify": "^2.0.0", + "json-schema-traverse": "^0.4.1", + "uri-js": "^4.2.2" }, - "engines": { - "node": ">=10" + "funding": { + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" } }, - "node_modules/@typescript-eslint/parser": { - "version": "5.62.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-5.62.0.tgz", - "integrity": "sha512-VlJEV0fOQ7BExOsHYAGrgbEiZoi8D+Bl2+f6V2RrXerRSylnp+ZBHmPvaIa8cz0Ajx7WO7Z5RqfgYg7ED1nRhA==", + "node_modules/ajv-formats": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ajv-formats/-/ajv-formats-2.1.1.tgz", + "integrity": "sha512-Wx0Kx52hxE7C18hkMEggYlEifqWZtYaRgouJor+WMdPnQyEK13vgEWyVNup7SoeeoLMsr4kf5h6dOW11I15MUA==", "dev": true, - "license": "BSD-2-Clause", + "license": "MIT", "dependencies": { - "@typescript-eslint/scope-manager": "5.62.0", - "@typescript-eslint/types": "5.62.0", - "@typescript-eslint/typescript-estree": "5.62.0", - "debug": "^4.3.4" - }, - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" + "ajv": "^8.0.0" }, "peerDependencies": { - "eslint": "^6.0.0 || ^7.0.0 || ^8.0.0" + "ajv": "^8.0.0" }, "peerDependenciesMeta": { - "typescript": { + "ajv": { "optional": true } } }, - "node_modules/@typescript-eslint/scope-manager": { - "version": "5.62.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-5.62.0.tgz", - "integrity": "sha512-VXuvVvZeQCQb5Zgf4HAxc04q5j+WrNAtNh9OwCsCgpKqESMTu3tF/jhZ3xG6T4NZwWl65Bg8KuS2uEvhSfLl0w==", + "node_modules/ajv-formats/node_modules/ajv": { + "version": "8.17.1", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.17.1.tgz", + "integrity": "sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/types": "5.62.0", - "@typescript-eslint/visitor-keys": "5.62.0" - }, - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "fast-deep-equal": "^3.1.3", + "fast-uri": "^3.0.1", + "json-schema-traverse": "^1.0.0", + "require-from-string": "^2.0.2" }, "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" } }, - "node_modules/@typescript-eslint/type-utils": { - "version": "5.62.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-5.62.0.tgz", - "integrity": "sha512-xsSQreu+VnfbqQpW5vnCJdq1Z3Q0U31qiWmRhr98ONQmcp/yhiPJFPq8MXiJVLiksmOKSjIldZzkebzHuCGzew==", + "node_modules/ajv-formats/node_modules/json-schema-traverse": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", + "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", + "dev": true, + "license": "MIT" + }, + "node_modules/ajv-keywords": { + "version": "3.5.2", + "resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-3.5.2.tgz", + "integrity": "sha512-5p6WTN0DdTGVQk6VjcEju19IgaHudalcfabD7yhDGeA6bcQnmL+CpveLJq/3hvfwd1aof6L386Ougkx6RfyMIQ==", "dev": true, "license": "MIT", - "dependencies": { - "@typescript-eslint/typescript-estree": "5.62.0", - "@typescript-eslint/utils": "5.62.0", - "debug": "^4.3.4", - "tsutils": "^3.21.0" - }, - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - }, "peerDependencies": { - "eslint": "*" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } + "ajv": "^6.9.1" } }, - "node_modules/@typescript-eslint/types": { - "version": "5.62.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-5.62.0.tgz", - "integrity": "sha512-87NVngcbVXUahrRTqIK27gD2t5Cu1yuCXxbLcFtCzZGlfyVWWh8mLHkoxzjsB6DDNnvdL+fW8MiwPEJyGJQDgQ==", + "node_modules/ansi-colors": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.3.tgz", + "integrity": "sha512-/6w/C21Pm1A7aZitlI5Ni/2J6FFQN8i1Cvz3kHABAAbw93v/NlvKdVOqz7CCWz/3iv/JplRSEEZ83XION15ovw==", "dev": true, "license": "MIT", "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" + "node": ">=6" } }, - "node_modules/@typescript-eslint/typescript-estree": { - "version": "5.62.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-5.62.0.tgz", - "integrity": "sha512-CmcQ6uY7b9y694lKdRB8FEel7JbU/40iSAPomu++SjLMntB+2Leay2LO6i8VnJk58MtE9/nQSFIH6jpyRWyYzA==", + "node_modules/ansi-escapes": { + "version": "4.3.2", + "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", + "integrity": "sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==", "dev": true, - "license": "BSD-2-Clause", + "license": "MIT", "dependencies": { - "@typescript-eslint/types": "5.62.0", - "@typescript-eslint/visitor-keys": "5.62.0", - "debug": "^4.3.4", - "globby": "^11.1.0", - "is-glob": "^4.0.3", - "semver": "^7.3.7", - "tsutils": "^3.21.0" + "type-fest": "^0.21.3" }, "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "node": ">=8" }, "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@typescript-eslint/typescript-estree/node_modules/semver": { - "version": "7.6.3", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", - "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", + "node_modules/ansi-html-community": { + "version": "0.0.8", + "resolved": "https://registry.npmjs.org/ansi-html-community/-/ansi-html-community-0.0.8.tgz", + "integrity": "sha512-1APHAyr3+PCamwNw3bXCPp4HFLONZt/yIH0sZp0/469KWNTEy+qN5jQ3GVX6DMZ1UXAi34yVwtTeaG/HpBuuzw==", "dev": true, - "license": "ISC", + "engines": [ + "node >= 0.8.0" + ], + "license": "Apache-2.0", "bin": { - "semver": "bin/semver.js" - }, - "engines": { - "node": ">=10" + "ansi-html": "bin/ansi-html" } }, - "node_modules/@typescript-eslint/utils": { - "version": "5.62.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-5.62.0.tgz", - "integrity": "sha512-n8oxjeb5aIbPFEtmQxQYOLI0i9n5ySBEY/ZEHHZqKQSFnxio1rv6dthascc9dLuwrL0RC5mPCxB7vnAVGAYWAQ==", + "node_modules/ansi-regex": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", "dev": true, "license": "MIT", - "dependencies": { - "@eslint-community/eslint-utils": "^4.2.0", - "@types/json-schema": "^7.0.9", - "@types/semver": "^7.3.12", - "@typescript-eslint/scope-manager": "5.62.0", - "@typescript-eslint/types": "5.62.0", - "@typescript-eslint/typescript-estree": "5.62.0", - "eslint-scope": "^5.1.1", - "semver": "^7.3.7" - }, "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "node": ">=8" + } + }, + "node_modules/ansis": { + "version": "1.5.2", + "resolved": "https://registry.npmjs.org/ansis/-/ansis-1.5.2.tgz", + "integrity": "sha512-T3vUABrcgSj/HXv27P+A/JxGk5b/ydx0JjN3lgjBTC2iZUFxQGjh43zCzLSbU4C1QTgmx9oaPeWNJFM+auI8qw==", + "dev": true, + "license": "ISC", + "engines": { + "node": ">=12.13" }, "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - }, - "peerDependencies": { - "eslint": "^6.0.0 || ^7.0.0 || ^8.0.0" + "type": "patreon", + "url": "https://patreon.com/biodiscus" } }, - "node_modules/@typescript-eslint/utils/node_modules/semver": { - "version": "7.6.3", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", - "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", + "node_modules/anymatch": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", + "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", "dev": true, "license": "ISC", - "bin": { - "semver": "bin/semver.js" + "dependencies": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" }, "engines": { - "node": ">=10" + "node": ">= 8" } }, - "node_modules/@typescript-eslint/visitor-keys": { - "version": "5.62.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-5.62.0.tgz", - "integrity": "sha512-07ny+LHRzQXepkGg6w0mFY41fVUNBrL2Roj/++7V1txKugfjm/Ci/qSND03r2RhlJhJYMcTn9AhhSSqQp0Ysyw==", + "node_modules/arch": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/arch/-/arch-2.2.0.tgz", + "integrity": "sha512-Of/R0wqp83cgHozfIYLbBMnej79U/SVGOOyuB3VVFv1NRM/PSFMK12x9KVtiYzJqmnU5WR2qp0Z5rHb7sWGnFQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT" + }, + "node_modules/are-docs-informative": { + "version": "0.0.2", + "resolved": "https://registry.npmjs.org/are-docs-informative/-/are-docs-informative-0.0.2.tgz", + "integrity": "sha512-ixiS0nLNNG5jNQzgZJNoUpBKdo9yTYZMGJ+QgT2jmjR7G7+QHRCc4v6LQ3NgE7EBJq+o0ams3waJwkrlBom8Ig==", "dev": true, "license": "MIT", - "dependencies": { - "@typescript-eslint/types": "5.62.0", - "eslint-visitor-keys": "^3.3.0" - }, "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" + "node": ">=14" } }, - "node_modules/@typescript-eslint/visitor-keys/node_modules/eslint-visitor-keys": { - "version": "3.4.3", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz", - "integrity": "sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==", + "node_modules/argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" + "license": "MIT", + "dependencies": { + "sprintf-js": "~1.0.2" } }, - "node_modules/@ungap/structured-clone": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/@ungap/structured-clone/-/structured-clone-1.2.0.tgz", - "integrity": "sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==", + "node_modules/argparse/node_modules/sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==", "dev": true, - "license": "ISC" + "license": "BSD-3-Clause" }, - "node_modules/@webassemblyjs/ast": { - "version": "1.12.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.12.1.tgz", - "integrity": "sha512-EKfMUOPRRUTy5UII4qJDGPpqfwjOmZ5jeGFwid9mnoqIFK+e0vqoi1qH56JpmZSzEL53jKnNzScdmftJyG5xWg==", + "node_modules/aria-query": { + "version": "5.1.3", + "resolved": "https://registry.npmjs.org/aria-query/-/aria-query-5.1.3.tgz", + "integrity": "sha512-R5iJ5lkuHybztUfuOAznmboyjWq8O6sqNqtK7CLOqdydi54VNbORp49mb14KbWgG1QD3JFO9hJdZ+y4KutfdOQ==", "dev": true, + "license": "Apache-2.0", + "dependencies": { + "deep-equal": "^2.0.5" + } + }, + "node_modules/array-buffer-byte-length": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/array-buffer-byte-length/-/array-buffer-byte-length-1.0.1.tgz", + "integrity": "sha512-ahC5W1xgou+KTXix4sAO8Ki12Q+jf4i0+tmk3sC+zgcynshkHxzpXdImBehiUYKKKDwvfFiJl1tZt6ewscS1Mg==", "license": "MIT", "dependencies": { - "@webassemblyjs/helper-numbers": "1.11.6", - "@webassemblyjs/helper-wasm-bytecode": "1.11.6" + "call-bind": "^1.0.5", + "is-array-buffer": "^3.0.4" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/@webassemblyjs/floating-point-hex-parser": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.11.6.tgz", - "integrity": "sha512-ejAj9hfRJ2XMsNHk/v6Fu2dGS+i4UaXBXGemOfQ/JfQ6mdQg/WXtwleQRLLS4OvfDhv8rYnVwH27YJLMyYsxhw==", + "node_modules/array-flatten": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz", + "integrity": "sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==", "dev": true, "license": "MIT" }, - "node_modules/@webassemblyjs/helper-api-error": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.11.6.tgz", - "integrity": "sha512-o0YkoP4pVu4rN8aTJgAyj9hC2Sv5UlkzCHhxqWj8butaLvnpdc2jOwh4ewE6CX0txSfLn/UYaV/pheS2Txg//Q==", - "dev": true, - "license": "MIT" - }, - "node_modules/@webassemblyjs/helper-buffer": { - "version": "1.12.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.12.1.tgz", - "integrity": "sha512-nzJwQw99DNDKr9BVCOZcLuJJUlqkJh+kVzVl6Fmq/tI5ZtEyWT1KZMyOXltXLZJmDtvLCDgwsyrkohEtopTXCw==", - "dev": true, - "license": "MIT" - }, - "node_modules/@webassemblyjs/helper-numbers": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-numbers/-/helper-numbers-1.11.6.tgz", - "integrity": "sha512-vUIhZ8LZoIWHBohiEObxVm6hwP034jwmc9kuq5GdHZH0wiLVLIPcMCdpJzG4C11cHoQ25TFIQj9kaVADVX7N3g==", + "node_modules/array-includes": { + "version": "3.1.8", + "resolved": "https://registry.npmjs.org/array-includes/-/array-includes-3.1.8.tgz", + "integrity": "sha512-itaWrbYbqpGXkGhZPGUulwnhVf5Hpy1xiCFsGqyIGglbBxmG5vSjxQen3/WGOjPpNEv1RtBLKxbmVXm8HpJStQ==", "dev": true, "license": "MIT", "dependencies": { - "@webassemblyjs/floating-point-hex-parser": "1.11.6", - "@webassemblyjs/helper-api-error": "1.11.6", - "@xtuc/long": "4.2.2" + "call-bind": "^1.0.7", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.2", + "es-object-atoms": "^1.0.0", + "get-intrinsic": "^1.2.4", + "is-string": "^1.0.7" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/@webassemblyjs/helper-wasm-bytecode": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.11.6.tgz", - "integrity": "sha512-sFFHKwcmBprO9e7Icf0+gddyWYDViL8bpPjJJl0WHxCdETktXdmtWLGVzoHbqUcY4Be1LkNfwTmXOJUFZYSJdA==", + "node_modules/array-union": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/array-union/-/array-union-2.1.0.tgz", + "integrity": "sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==", "dev": true, - "license": "MIT" + "license": "MIT", + "engines": { + "node": ">=8" + } }, - "node_modules/@webassemblyjs/helper-wasm-section": { - "version": "1.12.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.12.1.tgz", - "integrity": "sha512-Jif4vfB6FJlUlSbgEMHUyk1j234GTNG9dBJ4XJdOySoj518Xj0oGsNi59cUQF4RRMS9ouBUxDDdyBVfPTypa5g==", - "dev": true, + "node_modules/array.prototype.find": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/array.prototype.find/-/array.prototype.find-2.2.3.tgz", + "integrity": "sha512-fO/ORdOELvjbbeIfZfzrXFMhYHGofRGqd+am9zm3tZ4GlJINj/pA2eITyfd65Vg6+ZbHd/Cys7stpoRSWtQFdA==", "license": "MIT", "dependencies": { - "@webassemblyjs/ast": "1.12.1", - "@webassemblyjs/helper-buffer": "1.12.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.6", - "@webassemblyjs/wasm-gen": "1.12.1" + "call-bind": "^1.0.7", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.2", + "es-object-atoms": "^1.0.0", + "es-shim-unscopables": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/@webassemblyjs/ieee754": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.11.6.tgz", - "integrity": "sha512-LM4p2csPNvbij6U1f19v6WR56QZ8JcHg3QIJTlSwzFcmx6WSORicYj6I63f9yU1kEUtrpG+kjkiIAkevHpDXrg==", + "node_modules/array.prototype.findlast": { + "version": "1.2.5", + "resolved": "https://registry.npmjs.org/array.prototype.findlast/-/array.prototype.findlast-1.2.5.tgz", + "integrity": "sha512-CVvd6FHg1Z3POpBLxO6E6zr+rSKEQ9L6rZHAaY7lLfhKsWYUBBOuMs0e9o24oopj6H+geRCX0YJ+TJLBK2eHyQ==", "dev": true, "license": "MIT", "dependencies": { - "@xtuc/ieee754": "^1.2.0" + "call-bind": "^1.0.7", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.2", + "es-errors": "^1.3.0", + "es-object-atoms": "^1.0.0", + "es-shim-unscopables": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/@webassemblyjs/leb128": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.11.6.tgz", - "integrity": "sha512-m7a0FhE67DQXgouf1tbN5XQcdWoNgaAuoULHIfGFIEVKA6tu/edls6XnIlkmS6FrXAquJRPni3ZZKjw6FSPjPQ==", + "node_modules/array.prototype.findlastindex": { + "version": "1.2.5", + "resolved": "https://registry.npmjs.org/array.prototype.findlastindex/-/array.prototype.findlastindex-1.2.5.tgz", + "integrity": "sha512-zfETvRFA8o7EiNn++N5f/kaCw221hrpGsDmcpndVupkPzEc1Wuf3VgC0qby1BbHs7f5DVYjgtEU2LLh5bqeGfQ==", "dev": true, - "license": "Apache-2.0", + "license": "MIT", "dependencies": { - "@xtuc/long": "4.2.2" + "call-bind": "^1.0.7", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.2", + "es-errors": "^1.3.0", + "es-object-atoms": "^1.0.0", + "es-shim-unscopables": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/@webassemblyjs/utf8": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.11.6.tgz", - "integrity": "sha512-vtXf2wTQ3+up9Zsg8sa2yWiQpzSsMyXj0qViVP6xKGCUT8p8YJ6HqI7l5eCnWx1T/FYdsv07HQs2wTFbbof/RA==", - "dev": true, - "license": "MIT" - }, - "node_modules/@webassemblyjs/wasm-edit": { - "version": "1.12.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.12.1.tgz", - "integrity": "sha512-1DuwbVvADvS5mGnXbE+c9NfA8QRcZ6iKquqjjmR10k6o+zzsRVesil54DKexiowcFCPdr/Q0qaMgB01+SQ1u6g==", - "dev": true, + "node_modules/array.prototype.flat": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/array.prototype.flat/-/array.prototype.flat-1.3.2.tgz", + "integrity": "sha512-djYB+Zx2vLewY8RWlNCUdHjDXs2XOgm602S9E7P/UpHgfeHL00cRiIF+IN/G/aUJ7kGPb6yO/ErDI5V2s8iycA==", "license": "MIT", "dependencies": { - "@webassemblyjs/ast": "1.12.1", - "@webassemblyjs/helper-buffer": "1.12.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.6", - "@webassemblyjs/helper-wasm-section": "1.12.1", - "@webassemblyjs/wasm-gen": "1.12.1", - "@webassemblyjs/wasm-opt": "1.12.1", - "@webassemblyjs/wasm-parser": "1.12.1", - "@webassemblyjs/wast-printer": "1.12.1" + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "es-shim-unscopables": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/@webassemblyjs/wasm-gen": { - "version": "1.12.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.12.1.tgz", - "integrity": "sha512-TDq4Ojh9fcohAw6OIMXqiIcTq5KUXTGRkVxbSo1hQnSy6lAM5GSdfwWeSxpAo0YzgsgF182E/U0mDNhuA0tW7w==", + "node_modules/array.prototype.flatmap": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/array.prototype.flatmap/-/array.prototype.flatmap-1.3.2.tgz", + "integrity": "sha512-Ewyx0c9PmpcsByhSW4r+9zDU7sGjFc86qf/kKtuSCRdhfbk0SNLLkaT5qvcHnRGgc5NP/ly/y+qkXkqONX54CQ==", "dev": true, "license": "MIT", "dependencies": { - "@webassemblyjs/ast": "1.12.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.6", - "@webassemblyjs/ieee754": "1.11.6", - "@webassemblyjs/leb128": "1.11.6", - "@webassemblyjs/utf8": "1.11.6" + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "es-shim-unscopables": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/@webassemblyjs/wasm-opt": { - "version": "1.12.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.12.1.tgz", - "integrity": "sha512-Jg99j/2gG2iaz3hijw857AVYekZe2SAskcqlWIZXjji5WStnOpVoat3gQfT/Q5tb2djnCjBtMocY/Su1GfxPBg==", + "node_modules/array.prototype.tosorted": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/array.prototype.tosorted/-/array.prototype.tosorted-1.1.4.tgz", + "integrity": "sha512-p6Fx8B7b7ZhL/gmUsAy0D15WhvDccw3mnGNbZpi3pmeJdxtWsj2jEaI4Y6oo3XiHfzuSgPwKc04MYt6KgvC/wA==", "dev": true, "license": "MIT", "dependencies": { - "@webassemblyjs/ast": "1.12.1", - "@webassemblyjs/helper-buffer": "1.12.1", - "@webassemblyjs/wasm-gen": "1.12.1", - "@webassemblyjs/wasm-parser": "1.12.1" + "call-bind": "^1.0.7", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.3", + "es-errors": "^1.3.0", + "es-shim-unscopables": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" } }, - "node_modules/@webassemblyjs/wasm-parser": { - "version": "1.12.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.12.1.tgz", - "integrity": "sha512-xikIi7c2FHXysxXe3COrVUPSheuBtpcfhbpFj4gmu7KRLYOzANztwUU0IbsqvMqzuNK2+glRGWCEqZo1WCLyAQ==", - "dev": true, + "node_modules/arraybuffer.prototype.slice": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.3.tgz", + "integrity": "sha512-bMxMKAjg13EBSVscxTaYA4mRc5t1UAXa2kXiGTNfZ079HIWXEkKmkgFrh/nJqamaLSrXO5H4WFFkPEaLJWbs3A==", "license": "MIT", "dependencies": { - "@webassemblyjs/ast": "1.12.1", - "@webassemblyjs/helper-api-error": "1.11.6", - "@webassemblyjs/helper-wasm-bytecode": "1.11.6", - "@webassemblyjs/ieee754": "1.11.6", - "@webassemblyjs/leb128": "1.11.6", - "@webassemblyjs/utf8": "1.11.6" + "array-buffer-byte-length": "^1.0.1", + "call-bind": "^1.0.5", + "define-properties": "^1.2.1", + "es-abstract": "^1.22.3", + "es-errors": "^1.2.1", + "get-intrinsic": "^1.2.3", + "is-array-buffer": "^3.0.4", + "is-shared-array-buffer": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/@webassemblyjs/wast-printer": { - "version": "1.12.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.12.1.tgz", - "integrity": "sha512-+X4WAlOisVWQMikjbcvY2e0rwPsKQ9F688lksZhBcPycBBuii3O7m8FACbDMWDojpAqvjIncrG8J0XHKyQfVeA==", + "node_modules/asn1": { + "version": "0.2.6", + "resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.6.tgz", + "integrity": "sha512-ix/FxPn0MDjeyJ7i/yoHGFt/EX6LyNbxSEhPPXODPL+KB0VPk86UYfL0lMdy+KCnv+fmvIzySwaK5COwqVbWTQ==", "dev": true, "license": "MIT", "dependencies": { - "@webassemblyjs/ast": "1.12.1", - "@xtuc/long": "4.2.2" + "safer-buffer": "~2.1.0" } }, - "node_modules/@webpack-cli/configtest": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/@webpack-cli/configtest/-/configtest-2.1.1.tgz", - "integrity": "sha512-wy0mglZpDSiSS0XHrVR+BAdId2+yxPSoJW8fsna3ZpYSlufjvxnP4YbKTCBZnNIcGN4r6ZPXV55X4mYExOfLmw==", + "node_modules/assert-plus": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz", + "integrity": "sha512-NfJ4UzBCcQGLDlQq7nHxH+tv3kyZ0hHQqF5BO6J7tNJeP5do1llPr8dZ8zHonfhAu0PHAdMkSo+8o0wxg9lZWw==", "dev": true, "license": "MIT", "engines": { - "node": ">=14.15.0" - }, - "peerDependencies": { - "webpack": "5.x.x", - "webpack-cli": "5.x.x" + "node": ">=0.8" } }, - "node_modules/@webpack-cli/info": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/@webpack-cli/info/-/info-2.0.2.tgz", - "integrity": "sha512-zLHQdI/Qs1UyT5UBdWNqsARasIA+AaF8t+4u2aS2nEpBQh2mWIVb8qAklq0eUENnC5mOItrIB4LiS9xMtph18A==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=14.15.0" - }, - "peerDependencies": { - "webpack": "5.x.x", - "webpack-cli": "5.x.x" - } - }, - "node_modules/@webpack-cli/serve": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/@webpack-cli/serve/-/serve-2.0.5.tgz", - "integrity": "sha512-lqaoKnRYBdo1UgDX8uF24AfGMifWK19TxPmM5FHc2vAGxrJ/qtyUyFBWoY1tISZdelsQ5fBcOusifo5o5wSJxQ==", + "node_modules/ast-metadata-inferer": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/ast-metadata-inferer/-/ast-metadata-inferer-0.8.0.tgz", + "integrity": "sha512-jOMKcHht9LxYIEQu+RVd22vtgrPaVCtDRQ/16IGmurdzxvYbDd5ynxjnyrzLnieG96eTcAyaoj/wN/4/1FyyeA==", "dev": true, "license": "MIT", - "engines": { - "node": ">=14.15.0" - }, - "peerDependencies": { - "webpack": "5.x.x", - "webpack-cli": "5.x.x" - }, - "peerDependenciesMeta": { - "webpack-dev-server": { - "optional": true - } - } - }, - "node_modules/@wordpress/a11y": { - "version": "2.15.3", - "resolved": "https://registry.npmjs.org/@wordpress/a11y/-/a11y-2.15.3.tgz", - "integrity": "sha512-uoCznHY3/TaNWeXutLI6juC198ykaBwZ34P51PNHHQqi3WzVoBhFx6AnAR/9Uupl3tZcekefpkVHy7AJHMAPIA==", - "license": "GPL-2.0-or-later", "dependencies": { - "@babel/runtime": "^7.13.10", - "@wordpress/dom-ready": "^2.13.2", - "@wordpress/i18n": "^3.20.0" + "@mdn/browser-compat-data": "^5.2.34" } }, - "node_modules/@wordpress/a11y/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", + "node_modules/ast-types-flow": { + "version": "0.0.8", + "resolved": "https://registry.npmjs.org/ast-types-flow/-/ast-types-flow-0.0.8.tgz", + "integrity": "sha512-OH/2E5Fg20h2aPrbe+QL8JZQFko0YZaF+j4mnQ7BGhfavO7OpSLa8a0y9sBwomHdSbkhTS8TQNayBfnW5DwbvQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/astral-regex": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/astral-regex/-/astral-regex-2.0.0.tgz", + "integrity": "sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ==", + "dev": true, "license": "MIT", - "dependencies": { - "regenerator-runtime": "^0.14.0" - }, "engines": { - "node": ">=6.9.0" + "node": ">=8" } }, - "node_modules/@wordpress/a11y/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", + "node_modules/async": { + "version": "3.2.6", + "resolved": "https://registry.npmjs.org/async/-/async-3.2.6.tgz", + "integrity": "sha512-htCUDlxyyCLMgaM3xXg0C0LW2xqfuQ6p05pCEIsXuyQ+a1koYKTuBMzRNwmybfLgvJDMd0r1LTn4+E0Ti6C2AA==", + "dev": true, "license": "MIT" }, - "node_modules/@wordpress/api-fetch": { - "version": "2.2.8", - "resolved": "https://registry.npmjs.org/@wordpress/api-fetch/-/api-fetch-2.2.8.tgz", - "integrity": "sha512-mbdP9GvDe8Ojv8cobk30mfg2btEZDQEe7IgO+rGSlvVlHC88U8cc2VgOLNX6c9/6/sCvkoGd4Tsy85VbdTlTXw==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.0.0", - "@wordpress/hooks": "^2.0.5", - "@wordpress/i18n": "^3.1.1", - "@wordpress/url": "^2.3.3" + "node_modules/asynckit": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", + "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==", + "dev": true, + "license": "MIT" + }, + "node_modules/at-least-node": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/at-least-node/-/at-least-node-1.0.0.tgz", + "integrity": "sha512-+q/t7Ekv1EDY2l6Gda6LLiX14rU9TV20Wa3ofeQmwPFZbOMo9DXrLbOjFaaclkXKWidIaopwAObQDqwWtGUjqg==", + "dev": true, + "license": "ISC", + "engines": { + "node": ">= 4.0.0" } }, - "node_modules/@wordpress/api-fetch/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", + "node_modules/available-typed-arrays": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.7.tgz", + "integrity": "sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ==", "license": "MIT", "dependencies": { - "regenerator-runtime": "^0.14.0" + "possible-typed-array-names": "^1.0.0" }, "engines": { - "node": ">=6.9.0" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/@wordpress/api-fetch/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", + "node_modules/aws-sign2": { + "version": "0.7.0", + "resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz", + "integrity": "sha512-08kcGqnYf/YmjoRhfxyu+CLxBjUtHLXLXX/vUfx9l2LYzG3c1m61nrpyFUZI6zeS+Li/wWMMidD9KgrqtGq3mA==", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": "*" + } + }, + "node_modules/aws4": { + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/aws4/-/aws4-1.13.2.tgz", + "integrity": "sha512-lHe62zvbTB5eEABUVi/AwVh0ZKY9rMMDhmm+eeyuuUQbQ3+J+fONVQOZyj+DdrvD4BY33uYniyRJ4UJIaSKAfw==", + "dev": true, "license": "MIT" }, - "node_modules/@wordpress/api-request": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/@wordpress/api-request/-/api-request-1.0.0.tgz", - "integrity": "sha512-/6cJaf93LJMgnzYFT1xEjqRBL/AbIzCTpZr9Yb1NoEMeHGvSoJ/lOzxWFCZAA8olzW0WEBlKIZPxp++TtrYEsA==", - "deprecated": "@wordpress/api-request has been discontinued, please install the latest version of @wordpress/api-fetch package instead", - "license": "GPL-2.0-or-later" + "node_modules/axe-core": { + "version": "4.10.0", + "resolved": "https://registry.npmjs.org/axe-core/-/axe-core-4.10.0.tgz", + "integrity": "sha512-Mr2ZakwQ7XUAjp7pAwQWRhhK8mQQ6JAaNWSjmjxil0R8BPioMtQsTLOolGYkji1rcL++3dCqZA3zWqpT+9Ew6g==", + "dev": true, + "license": "MPL-2.0", + "engines": { + "node": ">=4" + } }, - "node_modules/@wordpress/babel-plugin-import-jsx-pragma": { - "version": "4.41.0", - "resolved": "https://registry.npmjs.org/@wordpress/babel-plugin-import-jsx-pragma/-/babel-plugin-import-jsx-pragma-4.41.0.tgz", - "integrity": "sha512-hYxj2Uobxk86ctlfaJou9v13XqXZ30yx4ZwRNu5cH5/LWXe2MIXBTPv7dUk6wqN/qFOjsFvP9jCB0NsW6MnkrA==", + "node_modules/axobject-query": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/axobject-query/-/axobject-query-4.1.0.tgz", + "integrity": "sha512-qIj0G9wZbMGNLjLmg1PT6v2mE9AH2zlnADJD/2tC6E00hgmhUOfEB6greHPAfLRSufHqROIUTkw6E+M3lH0PTQ==", "dev": true, - "license": "GPL-2.0-or-later", + "license": "Apache-2.0", "engines": { - "node": ">=14" - }, - "peerDependencies": { - "@babel/core": "^7.12.9" + "node": ">= 0.4" } }, - "node_modules/@wordpress/babel-plugin-makepot": { - "version": "5.42.0", - "resolved": "https://registry.npmjs.org/@wordpress/babel-plugin-makepot/-/babel-plugin-makepot-5.42.0.tgz", - "integrity": "sha512-Y8BjbkfQ2QQBG4RW9G3YT6Cpw+yC+Sj76FVLiEI5X1NdNKivVoHCdj73ziF87cCFTjWU7b55huph+kfL8c/DFA==", + "node_modules/babel-loader": { + "version": "9.2.1", + "resolved": "https://registry.npmjs.org/babel-loader/-/babel-loader-9.2.1.tgz", + "integrity": "sha512-fqe8naHt46e0yIdkjUZYqddSXfej3AHajX+CSO5X7oy0EmPc6o5Xh+RClNoHjnieWz9AW4kZxW9yyFMhVB1QLA==", "dev": true, - "license": "GPL-2.0-or-later", + "license": "MIT", "dependencies": { - "deepmerge": "^4.3.0", - "gettext-parser": "^1.3.1", - "is-plain-object": "^5.0.0" + "find-cache-dir": "^4.0.0", + "schema-utils": "^4.0.0" }, "engines": { - "node": ">=14" + "node": ">= 14.15.0" }, "peerDependencies": { - "@babel/core": "^7.12.9" + "@babel/core": "^7.12.0", + "webpack": ">=5" } }, - "node_modules/@wordpress/babel-preset-default": { - "version": "7.42.0", - "resolved": "https://registry.npmjs.org/@wordpress/babel-preset-default/-/babel-preset-default-7.42.0.tgz", - "integrity": "sha512-AWSxWuEuzazt/nWomKiaVhYQeXuqxTniPCKhvks58wB3P4UXvSe3hRnO+nujz20IuxIk2xHT6x47HgpDZy30jw==", + "node_modules/babel-plugin-polyfill-corejs2": { + "version": "0.4.11", + "resolved": "https://registry.npmjs.org/babel-plugin-polyfill-corejs2/-/babel-plugin-polyfill-corejs2-0.4.11.tgz", + "integrity": "sha512-sMEJ27L0gRHShOh5G54uAAPaiCOygY/5ratXuiyb2G46FmlSpc9eFCzYVyDiPxfNbwzA7mYahmjQc5q+CZQ09Q==", "dev": true, - "license": "GPL-2.0-or-later", + "license": "MIT", "dependencies": { - "@babel/core": "^7.16.0", - "@babel/plugin-transform-react-jsx": "^7.16.0", - "@babel/plugin-transform-runtime": "^7.16.0", - "@babel/preset-env": "^7.16.0", - "@babel/preset-typescript": "^7.16.0", - "@babel/runtime": "^7.16.0", - "@wordpress/babel-plugin-import-jsx-pragma": "^4.41.0", - "@wordpress/browserslist-config": "^5.41.0", - "@wordpress/warning": "^2.58.0", - "browserslist": "^4.21.10", - "core-js": "^3.31.0", - "react": "^18.3.0" + "@babel/compat-data": "^7.22.6", + "@babel/helper-define-polyfill-provider": "^0.6.2", + "semver": "^6.3.1" }, - "engines": { - "node": ">=14" + "peerDependencies": { + "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" } }, - "node_modules/@wordpress/babel-preset-default/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", + "node_modules/babel-plugin-polyfill-corejs3": { + "version": "0.10.6", + "resolved": "https://registry.npmjs.org/babel-plugin-polyfill-corejs3/-/babel-plugin-polyfill-corejs3-0.10.6.tgz", + "integrity": "sha512-b37+KR2i/khY5sKmWNVQAnitvquQbNdWy6lJdsr0kmquCKEEUgMKK4SboVM3HtfnZilfjr4MMQ7vY58FVWDtIA==", "dev": true, "license": "MIT", "dependencies": { - "regenerator-runtime": "^0.14.0" + "@babel/helper-define-polyfill-provider": "^0.6.2", + "core-js-compat": "^3.38.0" }, - "engines": { - "node": ">=6.9.0" + "peerDependencies": { + "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" } }, - "node_modules/@wordpress/babel-preset-default/node_modules/core-js": { - "version": "3.38.1", - "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.38.1.tgz", - "integrity": "sha512-OP35aUorbU3Zvlx7pjsFdu1rGNnD4pgw/CWoYzRY3t2EzoVT7shKHY1dlAy3f41cGIO7ZDPQimhGFTlEYkG/Hw==", + "node_modules/babel-plugin-polyfill-regenerator": { + "version": "0.6.2", + "resolved": "https://registry.npmjs.org/babel-plugin-polyfill-regenerator/-/babel-plugin-polyfill-regenerator-0.6.2.tgz", + "integrity": "sha512-2R25rQZWP63nGwaAswvDazbPXfrM3HwVoBXK6HcqeKrSrL/JqcC/rDcf95l4r7LXLyxDXc8uQDa064GubtCABg==", "dev": true, - "hasInstallScript": true, "license": "MIT", - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/core-js" + "dependencies": { + "@babel/helper-define-polyfill-provider": "^0.6.2" + }, + "peerDependencies": { + "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" } }, - "node_modules/@wordpress/babel-preset-default/node_modules/react": { - "version": "18.3.1", - "resolved": "https://registry.npmjs.org/react/-/react-18.3.1.tgz", - "integrity": "sha512-wS+hAgJShR0KhEvPJArfuPVN1+Hz1t0Y6n5jLrGQbkb4urgPE/0Rve+1kMB1v/oWgHgm4WIcV+i7F2pTVj+2iQ==", - "dev": true, + "node_modules/babel-plugin-styled-components": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/babel-plugin-styled-components/-/babel-plugin-styled-components-2.1.4.tgz", + "integrity": "sha512-Xgp9g+A/cG47sUyRwwYxGM4bR/jDRg5N6it/8+HxCnbT5XNKSKDT9xm4oag/osgqjC2It/vH0yXsomOG6k558g==", "license": "MIT", "dependencies": { - "loose-envify": "^1.1.0" + "@babel/helper-annotate-as-pure": "^7.22.5", + "@babel/helper-module-imports": "^7.22.5", + "@babel/plugin-syntax-jsx": "^7.22.5", + "lodash": "^4.17.21", + "picomatch": "^2.3.1" }, - "engines": { - "node": ">=0.10.0" + "peerDependencies": { + "styled-components": ">= 2" } }, - "node_modules/@wordpress/babel-preset-default/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "dev": true, - "license": "MIT" - }, - "node_modules/@wordpress/browserslist-config": { - "version": "5.41.0", - "resolved": "https://registry.npmjs.org/@wordpress/browserslist-config/-/browserslist-config-5.41.0.tgz", - "integrity": "sha512-J7ejzzDpPZddVIiq2YiK8J/pNTJDy3X1s+5ZtwkwklCxBMZJurxf9pEhtbaf7us0Q6c1j8Ubv7Fpx3lqk2ypxA==", - "dev": true, - "license": "GPL-2.0-or-later", - "engines": { - "node": ">=14" - } - }, - "node_modules/@wordpress/components": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/@wordpress/components/-/components-6.0.2.tgz", - "integrity": "sha512-La9RsHC4IBqfsUbY2hOwQyIHnrd5zzcT+HbbKPV1GPlYOxgIpX41gh8/ktAsuNcZQWOmgze5MRFVl4+2OQEV9Q==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.0.0", - "@wordpress/a11y": "^2.0.2", - "@wordpress/api-fetch": "^2.2.4", - "@wordpress/compose": "^3.0.0", - "@wordpress/deprecated": "^2.0.3", - "@wordpress/dom": "^2.0.6", - "@wordpress/element": "^2.1.8", - "@wordpress/hooks": "^2.0.3", - "@wordpress/i18n": "^3.1.0", - "@wordpress/is-shallow-equal": "^1.1.4", - "@wordpress/keycodes": "^2.0.3", - "@wordpress/rich-text": "^3.0.0", - "@wordpress/url": "^2.3.0", - "classnames": "^2.2.5", - "clipboard": "^2.0.1", - "diff": "^3.5.0", - "dom-scroll-into-view": "^1.2.1", - "lodash": "^4.17.10", - "memize": "^1.0.5", - "moment": "^2.22.1", - "mousetrap": "^1.6.2", - "re-resizable": "^4.7.1", - "react-click-outside": "^3.0.0", - "react-dates": "^17.1.1", - "rememo": "^3.0.0", - "tinycolor2": "^1.4.1", - "uuid": "^3.3.2" - } - }, - "node_modules/@wordpress/components/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", - "license": "MIT", - "dependencies": { - "regenerator-runtime": "^0.14.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@wordpress/components/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "license": "MIT" - }, - "node_modules/@wordpress/compose": { - "version": "3.25.3", - "resolved": "https://registry.npmjs.org/@wordpress/compose/-/compose-3.25.3.tgz", - "integrity": "sha512-tCO2EnJCkCH548OqA0uU8V1k/1skz2QwBlHs8ZQSpimqUS4OWWsAlndCEFe4U4vDTqFt2ow7tzAir+05Cw8MAg==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.13.10", - "@wordpress/deprecated": "^2.12.3", - "@wordpress/dom": "^2.18.0", - "@wordpress/element": "^2.20.3", - "@wordpress/is-shallow-equal": "^3.1.3", - "@wordpress/keycodes": "^2.19.3", - "@wordpress/priority-queue": "^1.11.2", - "clipboard": "^2.0.1", - "lodash": "^4.17.19", - "memize": "^1.1.0", - "mousetrap": "^1.6.5", - "react-resize-aware": "^3.1.0", - "use-memo-one": "^1.1.1" - } - }, - "node_modules/@wordpress/compose/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", - "license": "MIT", - "dependencies": { - "regenerator-runtime": "^0.14.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@wordpress/compose/node_modules/@wordpress/is-shallow-equal": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/@wordpress/is-shallow-equal/-/is-shallow-equal-3.1.3.tgz", - "integrity": "sha512-eDLhfC4aaSgklzqwc6F/F4zmJVpTVTAvhqX+q0SP/8LPcP2HuKErPHVrEc75PMWqIutja2wJg98YSNPdewrj1w==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.13.10" - } - }, - "node_modules/@wordpress/compose/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "license": "MIT" - }, - "node_modules/@wordpress/data": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/@wordpress/data/-/data-3.1.2.tgz", - "integrity": "sha512-aAYgRIljpLboplTaCA7t5r+qVjE53VGMS7rLjSHFsoFxj9GYPiCCX1f/B01eKz9pf04rVdM2N4cEowyxjkhKFA==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.0.0", - "@wordpress/compose": "^2.1.2", - "@wordpress/deprecated": "^2.0.3", - "@wordpress/element": "^2.1.7", - "@wordpress/is-shallow-equal": "^1.1.4", - "@wordpress/redux-routine": "^3.0.3", - "equivalent-key-map": "^0.2.2", - "is-promise": "^2.1.0", - "lodash": "^4.17.10", - "redux": "^4.0.0", - "turbo-combine-reducers": "^1.0.2" - } - }, - "node_modules/@wordpress/data/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", - "license": "MIT", - "dependencies": { - "regenerator-runtime": "^0.14.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@wordpress/data/node_modules/@wordpress/compose": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/@wordpress/compose/-/compose-2.1.2.tgz", - "integrity": "sha512-jr1bWRYx8vt4bCWB4hqR9Ve9rk/TCJ5mFRvkwEd+xTDyXG6ZMmps3HszGA6aCH7E+TCHH+bWw2qZo9sAeHVK/w==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.0.0", - "@wordpress/deprecated": "^2.0.3", - "@wordpress/element": "^2.1.7", - "@wordpress/is-shallow-equal": "^1.1.4", - "lodash": "^4.17.10" - } - }, - "node_modules/@wordpress/data/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "license": "MIT" - }, - "node_modules/@wordpress/deprecated": { - "version": "2.12.3", - "resolved": "https://registry.npmjs.org/@wordpress/deprecated/-/deprecated-2.12.3.tgz", - "integrity": "sha512-qr+yDfTQfI3M4h6oY6IeHWwoHr4jxbILjSlV+Ht6Jjto9Owap6OuzSqR13Ev4xqIoG4C7b5B3gZXVfwVDae1zg==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.13.10", - "@wordpress/hooks": "^2.12.3" - } - }, - "node_modules/@wordpress/deprecated/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", - "license": "MIT", - "dependencies": { - "regenerator-runtime": "^0.14.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@wordpress/deprecated/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "license": "MIT" - }, - "node_modules/@wordpress/dom": { - "version": "2.18.0", - "resolved": "https://registry.npmjs.org/@wordpress/dom/-/dom-2.18.0.tgz", - "integrity": "sha512-tM2WeQuSObl3nzWjUTF0/dyLnA7sdl/MXaSe32D64OF89bjSyJvjUipI7gjKzI3kJ7ddGhwcTggGvSB06MOoCQ==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.13.10", - "lodash": "^4.17.19" - } - }, - "node_modules/@wordpress/dom-ready": { - "version": "2.13.2", - "resolved": "https://registry.npmjs.org/@wordpress/dom-ready/-/dom-ready-2.13.2.tgz", - "integrity": "sha512-COH7n2uZfBq4FtluSbl37N3nCEcdMXzV42ETCWKUcumiP1Zd3qnkfQKcsxTaHWY8aVt/358RvJ7ghWe3xAd+fg==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.13.10" - } - }, - "node_modules/@wordpress/dom-ready/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", - "license": "MIT", - "dependencies": { - "regenerator-runtime": "^0.14.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@wordpress/dom-ready/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "license": "MIT" - }, - "node_modules/@wordpress/dom/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", - "license": "MIT", - "dependencies": { - "regenerator-runtime": "^0.14.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@wordpress/dom/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "license": "MIT" - }, - "node_modules/@wordpress/element": { - "version": "2.20.3", - "resolved": "https://registry.npmjs.org/@wordpress/element/-/element-2.20.3.tgz", - "integrity": "sha512-f4ZPTDf9CxiiOXiMxc4v1K7jcBMT4dsiehVOpkKzCDKboNXp4qVf8oe5PE23VGZNEjcOj5Mkg9hB57R0nqvMTw==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.13.10", - "@types/react": "^16.9.0", - "@types/react-dom": "^16.9.0", - "@wordpress/escape-html": "^1.12.2", - "lodash": "^4.17.19", - "react": "^16.13.1", - "react-dom": "^16.13.1" - } - }, - "node_modules/@wordpress/element/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", - "license": "MIT", - "dependencies": { - "regenerator-runtime": "^0.14.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@wordpress/element/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "license": "MIT" - }, - "node_modules/@wordpress/env": { - "version": "9.10.0", - "resolved": "https://registry.npmjs.org/@wordpress/env/-/env-9.10.0.tgz", - "integrity": "sha512-GqUg1XdrUXI3l5NhHhEZisrccW+VPqJSU5xO1IXybI6KOvmSecidxWEqlMj26vzu2P5aLCWZcx28QkrrY3jvdg==", - "dev": true, - "license": "GPL-2.0-or-later", - "dependencies": { - "chalk": "^4.0.0", - "copy-dir": "^1.3.0", - "docker-compose": "^0.24.3", - "extract-zip": "^1.6.7", - "got": "^11.8.5", - "inquirer": "^7.1.0", - "js-yaml": "^3.13.1", - "ora": "^4.0.2", - "rimraf": "^3.0.2", - "simple-git": "^3.5.0", - "terminal-link": "^2.0.0", - "yargs": "^17.3.0" - }, - "bin": { - "wp-env": "bin/wp-env" - } - }, - "node_modules/@wordpress/env/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "license": "MIT", - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@wordpress/env/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "license": "MIT", - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@wordpress/env/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@wordpress/env/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true, - "license": "MIT" - }, - "node_modules/@wordpress/env/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/@wordpress/env/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "license": "MIT", - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/@wordpress/escape-html": { - "version": "1.12.2", - "resolved": "https://registry.npmjs.org/@wordpress/escape-html/-/escape-html-1.12.2.tgz", - "integrity": "sha512-FabgSwznhdaUwe6hr1CsGpgxQbzqEoGevv73WIL1B9GvlZ6csRWodgHfWh4P6fYqpzxFL4WYB8wPJ1PdO32XFA==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.13.10" - } - }, - "node_modules/@wordpress/escape-html/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", - "license": "MIT", - "dependencies": { - "regenerator-runtime": "^0.14.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@wordpress/escape-html/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "license": "MIT" - }, - "node_modules/@wordpress/eslint-plugin": { - "version": "15.1.0", - "resolved": "https://registry.npmjs.org/@wordpress/eslint-plugin/-/eslint-plugin-15.1.0.tgz", - "integrity": "sha512-iKc8YnakbOWUh7b5A79XhZ9nIJfkHmKAkluxd56kwmKhhn1dfreRaCXpjjBk9E170axKmkHPqFar4xEMy9kO7A==", - "dev": true, - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/eslint-parser": "^7.16.0", - "@typescript-eslint/eslint-plugin": "^5.62.0", - "@typescript-eslint/parser": "^5.62.0", - "@wordpress/babel-preset-default": "^7.25.0", - "@wordpress/prettier-config": "^2.24.0", - "cosmiconfig": "^7.0.0", - "eslint-config-prettier": "^8.3.0", - "eslint-plugin-import": "^2.25.2", - "eslint-plugin-jest": "^27.2.1", - "eslint-plugin-jsdoc": "^46.4.6", - "eslint-plugin-jsx-a11y": "^6.5.1", - "eslint-plugin-prettier": "^3.3.0", - "eslint-plugin-react": "^7.27.0", - "eslint-plugin-react-hooks": "^4.3.0", - "globals": "^13.12.0", - "requireindex": "^1.2.0" - }, - "engines": { - "node": ">=14", - "npm": ">=6.14.4" - }, - "peerDependencies": { - "@babel/core": ">=7", - "eslint": ">=8", - "prettier": ">=2", - "typescript": ">=4" - }, - "peerDependenciesMeta": { - "prettier": { - "optional": true - }, - "typescript": { - "optional": true - } - } - }, - "node_modules/@wordpress/eslint-plugin/node_modules/@es-joy/jsdoccomment": { - "version": "0.41.0", - "resolved": "https://registry.npmjs.org/@es-joy/jsdoccomment/-/jsdoccomment-0.41.0.tgz", - "integrity": "sha512-aKUhyn1QI5Ksbqcr3fFJj16p99QdjUxXAEuFst1Z47DRyoiMwivIH9MV/ARcJOCXVjPfjITciej8ZD2O/6qUmw==", - "dev": true, - "license": "MIT", - "dependencies": { - "comment-parser": "1.4.1", - "esquery": "^1.5.0", - "jsdoc-type-pratt-parser": "~4.0.0" - }, - "engines": { - "node": ">=16" - } - }, - "node_modules/@wordpress/eslint-plugin/node_modules/cosmiconfig": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-7.1.0.tgz", - "integrity": "sha512-AdmX6xUzdNASswsFtmwSt7Vj8po9IuqXm0UXz7QKPuEUmPB4XyjGfaAr2PSuELMwkRMVH1EpIkX5bTZGRB3eCA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@types/parse-json": "^4.0.0", - "import-fresh": "^3.2.1", - "parse-json": "^5.0.0", - "path-type": "^4.0.0", - "yaml": "^1.10.0" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/@wordpress/eslint-plugin/node_modules/escape-string-regexp": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", - "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/@wordpress/eslint-plugin/node_modules/eslint-plugin-jsdoc": { - "version": "46.10.1", - "resolved": "https://registry.npmjs.org/eslint-plugin-jsdoc/-/eslint-plugin-jsdoc-46.10.1.tgz", - "integrity": "sha512-x8wxIpv00Y50NyweDUpa+58ffgSAI5sqe+zcZh33xphD0AVh+1kqr1ombaTRb7Fhpove1zfUuujlX9DWWBP5ag==", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "@es-joy/jsdoccomment": "~0.41.0", - "are-docs-informative": "^0.0.2", - "comment-parser": "1.4.1", - "debug": "^4.3.4", - "escape-string-regexp": "^4.0.0", - "esquery": "^1.5.0", - "is-builtin-module": "^3.2.1", - "semver": "^7.5.4", - "spdx-expression-parse": "^4.0.0" - }, - "engines": { - "node": ">=16" - }, - "peerDependencies": { - "eslint": "^7.0.0 || ^8.0.0 || ^9.0.0" - } - }, - "node_modules/@wordpress/eslint-plugin/node_modules/eslint-plugin-prettier": { - "version": "3.4.1", - "resolved": "https://registry.npmjs.org/eslint-plugin-prettier/-/eslint-plugin-prettier-3.4.1.tgz", - "integrity": "sha512-htg25EUYUeIhKHXjOinK4BgCcDwtLHjqaxCDsMy5nbnUMkKFvIhMVCp+5GFUXQ4Nr8lBsPqtGAqBenbpFqAA2g==", - "dev": true, - "license": "MIT", - "dependencies": { - "prettier-linter-helpers": "^1.0.0" - }, - "engines": { - "node": ">=6.0.0" - }, - "peerDependencies": { - "eslint": ">=5.0.0", - "prettier": ">=1.13.0" - }, - "peerDependenciesMeta": { - "eslint-config-prettier": { - "optional": true - } - } - }, - "node_modules/@wordpress/eslint-plugin/node_modules/globals": { - "version": "13.24.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.24.0.tgz", - "integrity": "sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "type-fest": "^0.20.2" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/@wordpress/eslint-plugin/node_modules/semver": { - "version": "7.6.3", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", - "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", - "dev": true, - "license": "ISC", - "bin": { - "semver": "bin/semver.js" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/@wordpress/eslint-plugin/node_modules/type-fest": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", - "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", - "dev": true, - "license": "(MIT OR CC0-1.0)", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/@wordpress/eslint-plugin/node_modules/yaml": { - "version": "1.10.2", - "resolved": "https://registry.npmjs.org/yaml/-/yaml-1.10.2.tgz", - "integrity": "sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg==", - "dev": true, - "license": "ISC", - "engines": { - "node": ">= 6" - } - }, - "node_modules/@wordpress/hooks": { - "version": "2.12.3", - "resolved": "https://registry.npmjs.org/@wordpress/hooks/-/hooks-2.12.3.tgz", - "integrity": "sha512-LmKiwKldZt6UYqOxV/a6+eUFXdvALFnB/pQx3RmrMvO64sgFhfR6dhrlv+uVbuuezSuv8dce1jx8lUWAT0krMA==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.13.10" - } - }, - "node_modules/@wordpress/hooks/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", - "license": "MIT", - "dependencies": { - "regenerator-runtime": "^0.14.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@wordpress/hooks/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "license": "MIT" - }, - "node_modules/@wordpress/i18n": { - "version": "3.20.0", - "resolved": "https://registry.npmjs.org/@wordpress/i18n/-/i18n-3.20.0.tgz", - "integrity": "sha512-SIoOJFB4UrrYAScS4H91CYCLW9dX3Ghv8pBKc/yHGculb1AdGr6gRMlmJxZV62Cn3CZ4Ga86c+FfR+GiBu0JPg==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.13.10", - "@wordpress/hooks": "^2.12.3", - "gettext-parser": "^1.3.1", - "lodash": "^4.17.19", - "memize": "^1.1.0", - "sprintf-js": "^1.1.1", - "tannin": "^1.2.0" - }, - "bin": { - "pot-to-php": "tools/pot-to-php.js" - } - }, - "node_modules/@wordpress/i18n/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", - "license": "MIT", - "dependencies": { - "regenerator-runtime": "^0.14.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@wordpress/i18n/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "license": "MIT" - }, - "node_modules/@wordpress/is-shallow-equal": { - "version": "1.8.0", - "resolved": "https://registry.npmjs.org/@wordpress/is-shallow-equal/-/is-shallow-equal-1.8.0.tgz", - "integrity": "sha512-OV3qJqP9LhjuOzt85TsyBwv+//CvC8Byf/81D3NmjPKlstLaD/bBCC5nBhH6dKAv4bShYtQ2Hmut+V4dZnOM1A==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.8.3" - } - }, - "node_modules/@wordpress/is-shallow-equal/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", - "license": "MIT", - "dependencies": { - "regenerator-runtime": "^0.14.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@wordpress/is-shallow-equal/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "license": "MIT" - }, - "node_modules/@wordpress/keycodes": { - "version": "2.19.3", - "resolved": "https://registry.npmjs.org/@wordpress/keycodes/-/keycodes-2.19.3.tgz", - "integrity": "sha512-8rNdmP5M1ifTgLIL0dt/N1uTGsq/Rx1ydCXy+gg24WdxBRhyu5sudNVCtascVXo26aIfOH9OJRdqRZZTEORhog==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.13.10", - "@wordpress/i18n": "^3.20.0", - "lodash": "^4.17.19" - } - }, - "node_modules/@wordpress/keycodes/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", - "license": "MIT", - "dependencies": { - "regenerator-runtime": "^0.14.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@wordpress/keycodes/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "license": "MIT" - }, - "node_modules/@wordpress/prettier-config": { - "version": "2.25.13", - "resolved": "https://registry.npmjs.org/@wordpress/prettier-config/-/prettier-config-2.25.13.tgz", - "integrity": "sha512-iz58o0X91E24j0VFtzwn5qG84w+s4VlRCuZWa/lPL6pfGtOSw30c60wCrYKCA1IWIIAWdpRAYfEh7errPyKiPQ==", - "dev": true, - "license": "GPL-2.0-or-later", - "engines": { - "node": ">=14" - }, - "peerDependencies": { - "prettier": ">=2" - } - }, - "node_modules/@wordpress/priority-queue": { - "version": "1.11.2", - "resolved": "https://registry.npmjs.org/@wordpress/priority-queue/-/priority-queue-1.11.2.tgz", - "integrity": "sha512-ulwmUOklY3orn1xXpcPnTyGWV5B/oycxI+cHZ6EevBVgM5sq+BW3xo0PKLR/MMm6UNBtFTu/71QAJrNZcD6V1g==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.13.10" - } - }, - "node_modules/@wordpress/priority-queue/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", - "license": "MIT", - "dependencies": { - "regenerator-runtime": "^0.14.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@wordpress/priority-queue/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "license": "MIT" - }, - "node_modules/@wordpress/redux-routine": { - "version": "3.14.2", - "resolved": "https://registry.npmjs.org/@wordpress/redux-routine/-/redux-routine-3.14.2.tgz", - "integrity": "sha512-aqi4UtvMP/+NhULxyCR8ktG0v4BJVTRcMpByAqDg7Oabq2sz2LPuShxd5UY8vxQYQY9t1uUJbslhom4ytcohWg==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.13.10", - "is-promise": "^4.0.0", - "lodash": "^4.17.19", - "rungen": "^0.3.2" - } - }, - "node_modules/@wordpress/redux-routine/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", - "license": "MIT", - "dependencies": { - "regenerator-runtime": "^0.14.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@wordpress/redux-routine/node_modules/is-promise": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/is-promise/-/is-promise-4.0.0.tgz", - "integrity": "sha512-hvpoI6korhJMnej285dSg6nu1+e6uxs7zG3BYAm5byqDsgJNWwxzM6z6iZiAgQR4TJ30JmBTOwqZUw3WlyH3AQ==", - "license": "MIT" - }, - "node_modules/@wordpress/redux-routine/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "license": "MIT" - }, - "node_modules/@wordpress/rich-text": { - "version": "3.25.3", - "resolved": "https://registry.npmjs.org/@wordpress/rich-text/-/rich-text-3.25.3.tgz", - "integrity": "sha512-FdqL1/rHTsRxZ1gW1UEWuy0URmUEqMzj5hcAbOhHFPO5m0ENrkzC9bBa195KqZBSNSmBmXnDZdHu4UJUolzcZg==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.13.10", - "@wordpress/compose": "^3.25.3", - "@wordpress/data": "^4.27.3", - "@wordpress/dom": "^2.18.0", - "@wordpress/element": "^2.20.3", - "@wordpress/escape-html": "^1.12.2", - "@wordpress/is-shallow-equal": "^3.1.3", - "@wordpress/keycodes": "^2.19.3", - "classnames": "^2.2.5", - "lodash": "^4.17.19", - "memize": "^1.1.0", - "rememo": "^3.0.0" - } - }, - "node_modules/@wordpress/rich-text/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", - "license": "MIT", - "dependencies": { - "regenerator-runtime": "^0.14.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@wordpress/rich-text/node_modules/@wordpress/data": { - "version": "4.27.3", - "resolved": "https://registry.npmjs.org/@wordpress/data/-/data-4.27.3.tgz", - "integrity": "sha512-5763NgNV9IIa1CC3Q80dAvrH6108tJtj3IrHfUCZmUk1atSNsOMBCkLdQ7tGTTi2JFejeGEMg1LJI22JD5zM6Q==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.13.10", - "@wordpress/compose": "^3.25.3", - "@wordpress/deprecated": "^2.12.3", - "@wordpress/element": "^2.20.3", - "@wordpress/is-shallow-equal": "^3.1.3", - "@wordpress/priority-queue": "^1.11.2", - "@wordpress/redux-routine": "^3.14.2", - "equivalent-key-map": "^0.2.2", - "is-promise": "^4.0.0", - "lodash": "^4.17.19", - "memize": "^1.1.0", - "redux": "^4.0.0", - "turbo-combine-reducers": "^1.0.2", - "use-memo-one": "^1.1.1" - } - }, - "node_modules/@wordpress/rich-text/node_modules/@wordpress/is-shallow-equal": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/@wordpress/is-shallow-equal/-/is-shallow-equal-3.1.3.tgz", - "integrity": "sha512-eDLhfC4aaSgklzqwc6F/F4zmJVpTVTAvhqX+q0SP/8LPcP2HuKErPHVrEc75PMWqIutja2wJg98YSNPdewrj1w==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.13.10" - } - }, - "node_modules/@wordpress/rich-text/node_modules/is-promise": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/is-promise/-/is-promise-4.0.0.tgz", - "integrity": "sha512-hvpoI6korhJMnej285dSg6nu1+e6uxs7zG3BYAm5byqDsgJNWwxzM6z6iZiAgQR4TJ30JmBTOwqZUw3WlyH3AQ==", - "license": "MIT" - }, - "node_modules/@wordpress/rich-text/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "license": "MIT" - }, - "node_modules/@wordpress/stylelint-config": { - "version": "23.14.0", - "resolved": "https://registry.npmjs.org/@wordpress/stylelint-config/-/stylelint-config-23.14.0.tgz", - "integrity": "sha512-SxrPIiR7LE8DMQblsPkiE81VY/JQAaU5SGmphDG+Bc2DnxfOdkt1oMsSUfsSEVwHuRlgh4ZD42CLlIV+Y0AexQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@stylistic/stylelint-plugin": "^3.0.1", - "stylelint-config-recommended": "^14.0.1", - "stylelint-config-recommended-scss": "^14.1.0" - }, - "engines": { - "node": ">=18.12.0", - "npm": ">=8.19.2" - }, - "peerDependencies": { - "stylelint": "^16.8.2", - "stylelint-scss": "^6.4.0" - } - }, - "node_modules/@wordpress/url": { - "version": "2.22.2", - "resolved": "https://registry.npmjs.org/@wordpress/url/-/url-2.22.2.tgz", - "integrity": "sha512-aqpYKQXzyzkCOm+GzZRYlLb+wh58g0cwR1PaKAl0UXaBS4mdS+X6biMriylb4P8CVC/RR7CSw5XI20JC24KDwQ==", - "license": "GPL-2.0-or-later", - "dependencies": { - "@babel/runtime": "^7.13.10", - "lodash": "^4.17.19", - "react-native-url-polyfill": "^1.1.2" - } - }, - "node_modules/@wordpress/url/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", - "license": "MIT", - "dependencies": { - "regenerator-runtime": "^0.14.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, - "node_modules/@wordpress/url/node_modules/@react-native/virtualized-lists": { - "version": "0.75.3", - "resolved": "https://registry.npmjs.org/@react-native/virtualized-lists/-/virtualized-lists-0.75.3.tgz", - "integrity": "sha512-cTLm7k7Y//SvV8UK8esrDHEw5OrwwSJ4Fqc3x52Imi6ROuhshfGIPFwhtn4pmAg9nWHzHwwqiJ+9hCSVnXXX+g==", - "license": "MIT", - "peer": true, - "dependencies": { - "invariant": "^2.2.4", - "nullthrows": "^1.1.1" - }, - "engines": { - "node": ">=18" - }, - "peerDependencies": { - "@types/react": "^18.2.6", - "react": "*", - "react-native": "*" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@wordpress/url/node_modules/@types/react": { - "version": "18.3.7", - "resolved": "https://registry.npmjs.org/@types/react/-/react-18.3.7.tgz", - "integrity": "sha512-KUnDCJF5+AiZd8owLIeVHqmW9yM4sqmDVf2JRJiBMFkGvkoZ4/WyV2lL4zVsoinmRS/W3FeEdZLEWFRofnT2FQ==", - "license": "MIT", - "optional": true, - "peer": true, - "dependencies": { - "@types/prop-types": "*", - "csstype": "^3.0.2" - } - }, - "node_modules/@wordpress/url/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "license": "MIT", - "peer": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@wordpress/url/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "license": "MIT", - "peer": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@wordpress/url/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@wordpress/url/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT", - "peer": true - }, - "node_modules/@wordpress/url/node_modules/commander": { - "version": "9.5.0", - "resolved": "https://registry.npmjs.org/commander/-/commander-9.5.0.tgz", - "integrity": "sha512-KRs7WVDKg86PWiuAqhDrAQnTXZKraVcCc6vFdL14qrZ/DcWwuRo7VoiYXalXO7S5GKpqYiVEwCbgFDfxNHKJBQ==", - "license": "MIT", - "peer": true, - "engines": { - "node": "^12.20.0 || >=14" - } - }, - "node_modules/@wordpress/url/node_modules/glob": { - "version": "7.2.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", - "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", - "deprecated": "Glob versions prior to v9 are no longer supported", - "license": "ISC", - "peer": true, - "dependencies": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.1.1", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - }, - "engines": { - "node": "*" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/@wordpress/url/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@wordpress/url/node_modules/react": { - "version": "18.3.1", - "resolved": "https://registry.npmjs.org/react/-/react-18.3.1.tgz", - "integrity": "sha512-wS+hAgJShR0KhEvPJArfuPVN1+Hz1t0Y6n5jLrGQbkb4urgPE/0Rve+1kMB1v/oWgHgm4WIcV+i7F2pTVj+2iQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "loose-envify": "^1.1.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/@wordpress/url/node_modules/react-native": { - "version": "0.75.3", - "resolved": "https://registry.npmjs.org/react-native/-/react-native-0.75.3.tgz", - "integrity": "sha512-+Ne6u5H+tPo36sme19SCd1u2UID2uo0J/XzAJarxmrDj4Nsdi44eyUDKtQHmhgxjRGsuVJqAYrMK0abLSq8AHw==", - "license": "MIT", - "peer": true, - "dependencies": { - "@jest/create-cache-key-function": "^29.6.3", - "@react-native-community/cli": "14.1.0", - "@react-native-community/cli-platform-android": "14.1.0", - "@react-native-community/cli-platform-ios": "14.1.0", - "@react-native/assets-registry": "0.75.3", - "@react-native/codegen": "0.75.3", - "@react-native/community-cli-plugin": "0.75.3", - "@react-native/gradle-plugin": "0.75.3", - "@react-native/js-polyfills": "0.75.3", - "@react-native/normalize-colors": "0.75.3", - "@react-native/virtualized-lists": "0.75.3", - "abort-controller": "^3.0.0", - "anser": "^1.4.9", - "ansi-regex": "^5.0.0", - "base64-js": "^1.5.1", - "chalk": "^4.0.0", - "commander": "^9.4.1", - "event-target-shim": "^5.0.1", - "flow-enums-runtime": "^0.0.6", - "glob": "^7.1.1", - "invariant": "^2.2.4", - "jest-environment-node": "^29.6.3", - "jsc-android": "^250231.0.0", - "memoize-one": "^5.0.0", - "metro-runtime": "^0.80.3", - "metro-source-map": "^0.80.3", - "mkdirp": "^0.5.1", - "nullthrows": "^1.1.1", - "pretty-format": "^26.5.2", - "promise": "^8.3.0", - "react-devtools-core": "^5.3.1", - "react-refresh": "^0.14.0", - "regenerator-runtime": "^0.13.2", - "scheduler": "0.24.0-canary-efb381bbf-20230505", - "semver": "^7.1.3", - "stacktrace-parser": "^0.1.10", - "whatwg-fetch": "^3.0.0", - "ws": "^6.2.2", - "yargs": "^17.6.2" - }, - "bin": { - "react-native": "cli.js" - }, - "engines": { - "node": ">=18" - }, - "peerDependencies": { - "@types/react": "^18.2.6", - "react": "^18.2.0" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@wordpress/url/node_modules/react-native-url-polyfill": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/react-native-url-polyfill/-/react-native-url-polyfill-1.3.0.tgz", - "integrity": "sha512-w9JfSkvpqqlix9UjDvJjm1EjSt652zVQ6iwCIj1cVVkwXf4jQhQgTNXY6EVTwuAmUjg6BC6k9RHCBynoLFo3IQ==", - "license": "MIT", - "dependencies": { - "whatwg-url-without-unicode": "8.0.0-3" - }, - "peerDependencies": { - "react-native": "*" - } - }, - "node_modules/@wordpress/url/node_modules/react-native/node_modules/regenerator-runtime": { - "version": "0.13.11", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.11.tgz", - "integrity": "sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg==", - "license": "MIT", - "peer": true - }, - "node_modules/@wordpress/url/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "license": "MIT" - }, - "node_modules/@wordpress/url/node_modules/scheduler": { - "version": "0.24.0-canary-efb381bbf-20230505", - "resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.24.0-canary-efb381bbf-20230505.tgz", - "integrity": "sha512-ABvovCDe/k9IluqSh4/ISoq8tIJnW8euVAWYt5j/bg6dRnqwQwiGO1F/V4AyK96NGF/FB04FhOUDuWj8IKfABA==", - "license": "MIT", - "peer": true, - "dependencies": { - "loose-envify": "^1.1.0" - } - }, - "node_modules/@wordpress/url/node_modules/semver": { - "version": "7.6.3", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", - "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", - "license": "ISC", - "peer": true, - "bin": { - "semver": "bin/semver.js" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/@wordpress/url/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "license": "MIT", - "peer": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/@wordpress/url/node_modules/ws": { - "version": "6.2.3", - "resolved": "https://registry.npmjs.org/ws/-/ws-6.2.3.tgz", - "integrity": "sha512-jmTjYU0j60B+vHey6TfR3Z7RD61z/hmxBS3VMSGIrroOWXQEneK1zNuotOUrGyBHQj0yrpsLHPWtigEFd13ndA==", - "license": "MIT", - "peer": true, - "dependencies": { - "async-limiter": "~1.0.0" - } - }, - "node_modules/@wordpress/warning": { - "version": "2.58.0", - "resolved": "https://registry.npmjs.org/@wordpress/warning/-/warning-2.58.0.tgz", - "integrity": "sha512-9bZlORhyMY2nbWozeyC5kqJsFzEPP4DCLhGmjtbv+YWGHttUrxUZEfrKdqO+rUODA8rP5zeIly1nCQOUnkw4Lg==", - "dev": true, - "license": "GPL-2.0-or-later", - "engines": { - "node": ">=12" - } - }, - "node_modules/@xtuc/ieee754": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/@xtuc/ieee754/-/ieee754-1.2.0.tgz", - "integrity": "sha512-DX8nKgqcGwsc0eJSqYt5lwP4DH5FlHnmuWWBRy7X0NcaGR0ZtuyeESgMwTYVEtxmsNGY+qit4QYT/MIYTOTPeA==", - "dev": true, - "license": "BSD-3-Clause" - }, - "node_modules/@xtuc/long": { - "version": "4.2.2", - "resolved": "https://registry.npmjs.org/@xtuc/long/-/long-4.2.2.tgz", - "integrity": "sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ==", - "dev": true, - "license": "Apache-2.0" - }, - "node_modules/abort-controller": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/abort-controller/-/abort-controller-3.0.0.tgz", - "integrity": "sha512-h8lQ8tacZYnR3vNQTgibj+tODHI5/+l06Au2Pcriv/Gmet0eaj4TwWH41sO9wnHDiQsEj19q0drzdWdeAHtweg==", - "license": "MIT", - "peer": true, - "dependencies": { - "event-target-shim": "^5.0.0" - }, - "engines": { - "node": ">=6.5" - } - }, - "node_modules/accepts": { - "version": "1.3.8", - "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.8.tgz", - "integrity": "sha512-PYAthTa2m2VKxuvSD3DPC/Gy+U+sOA1LAuT8mkmRuvw+NACSaeXEQ+NHcVF7rONl6qcaxV3Uuemwawk+7+SJLw==", - "license": "MIT", - "dependencies": { - "mime-types": "~2.1.34", - "negotiator": "0.6.3" - }, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/acorn": { - "version": "8.12.1", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.12.1.tgz", - "integrity": "sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg==", - "license": "MIT", - "bin": { - "acorn": "bin/acorn" - }, - "engines": { - "node": ">=0.4.0" - } - }, - "node_modules/acorn-import-attributes": { - "version": "1.9.5", - "resolved": "https://registry.npmjs.org/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz", - "integrity": "sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ==", - "dev": true, - "license": "MIT", - "peerDependencies": { - "acorn": "^8" - } - }, - "node_modules/acorn-jsx": { - "version": "5.3.2", - "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz", - "integrity": "sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==", - "dev": true, - "license": "MIT", - "peerDependencies": { - "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" - } - }, - "node_modules/aggregate-error": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/aggregate-error/-/aggregate-error-3.1.0.tgz", - "integrity": "sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==", - "dev": true, - "license": "MIT", - "dependencies": { - "clean-stack": "^2.0.0", - "indent-string": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/airbnb-prop-types": { - "version": "2.16.0", - "resolved": "https://registry.npmjs.org/airbnb-prop-types/-/airbnb-prop-types-2.16.0.tgz", - "integrity": "sha512-7WHOFolP/6cS96PhKNrslCLMYAI8yB1Pp6u6XmxozQOiZbsI5ycglZr5cHhBFfuRcQQjzCMith5ZPZdYiJCxUg==", - "deprecated": "This package has been renamed to 'prop-types-tools'", - "license": "MIT", - "dependencies": { - "array.prototype.find": "^2.1.1", - "function.prototype.name": "^1.1.2", - "is-regex": "^1.1.0", - "object-is": "^1.1.2", - "object.assign": "^4.1.0", - "object.entries": "^1.1.2", - "prop-types": "^15.7.2", - "prop-types-exact": "^1.2.0", - "react-is": "^16.13.1" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - }, - "peerDependencies": { - "react": "^0.14 || ^15.0.0 || ^16.0.0-alpha" - } - }, - "node_modules/airbnb-prop-types/node_modules/react-is": { - "version": "16.13.1", - "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", - "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==", - "license": "MIT" - }, - "node_modules/ajv": { - "version": "6.12.6", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", - "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==", - "dev": true, - "license": "MIT", - "dependencies": { - "fast-deep-equal": "^3.1.1", - "fast-json-stable-stringify": "^2.0.0", - "json-schema-traverse": "^0.4.1", - "uri-js": "^4.2.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, - "node_modules/ajv-formats": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/ajv-formats/-/ajv-formats-2.1.1.tgz", - "integrity": "sha512-Wx0Kx52hxE7C18hkMEggYlEifqWZtYaRgouJor+WMdPnQyEK13vgEWyVNup7SoeeoLMsr4kf5h6dOW11I15MUA==", - "dev": true, - "license": "MIT", - "dependencies": { - "ajv": "^8.0.0" - }, - "peerDependencies": { - "ajv": "^8.0.0" - }, - "peerDependenciesMeta": { - "ajv": { - "optional": true - } - } - }, - "node_modules/ajv-formats/node_modules/ajv": { - "version": "8.17.1", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.17.1.tgz", - "integrity": "sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g==", - "dev": true, - "license": "MIT", - "dependencies": { - "fast-deep-equal": "^3.1.3", - "fast-uri": "^3.0.1", - "json-schema-traverse": "^1.0.0", - "require-from-string": "^2.0.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, - "node_modules/ajv-formats/node_modules/json-schema-traverse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", - "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", - "dev": true, - "license": "MIT" - }, - "node_modules/ajv-keywords": { - "version": "3.5.2", - "resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-3.5.2.tgz", - "integrity": "sha512-5p6WTN0DdTGVQk6VjcEju19IgaHudalcfabD7yhDGeA6bcQnmL+CpveLJq/3hvfwd1aof6L386Ougkx6RfyMIQ==", - "dev": true, - "license": "MIT", - "peerDependencies": { - "ajv": "^6.9.1" - } - }, - "node_modules/anser": { - "version": "1.4.10", - "resolved": "https://registry.npmjs.org/anser/-/anser-1.4.10.tgz", - "integrity": "sha512-hCv9AqTQ8ycjpSd3upOJd7vFwW1JaoYQ7tpham03GJ1ca8/65rqn0RpaWpItOAd6ylW9wAw6luXYPJIyPFVOww==", - "license": "MIT", - "peer": true - }, - "node_modules/ansi-colors": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.3.tgz", - "integrity": "sha512-/6w/C21Pm1A7aZitlI5Ni/2J6FFQN8i1Cvz3kHABAAbw93v/NlvKdVOqz7CCWz/3iv/JplRSEEZ83XION15ovw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/ansi-escapes": { - "version": "4.3.2", - "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", - "integrity": "sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "type-fest": "^0.21.3" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/ansi-fragments": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/ansi-fragments/-/ansi-fragments-0.2.1.tgz", - "integrity": "sha512-DykbNHxuXQwUDRv5ibc2b0x7uw7wmwOGLBUd5RmaQ5z8Lhx19vwvKV+FAsM5rEA6dEcHxX+/Ad5s9eF2k2bB+w==", - "license": "MIT", - "peer": true, - "dependencies": { - "colorette": "^1.0.7", - "slice-ansi": "^2.0.0", - "strip-ansi": "^5.0.0" - } - }, - "node_modules/ansi-fragments/node_modules/ansi-regex": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.1.tgz", - "integrity": "sha512-ILlv4k/3f6vfQ4OoP2AGvirOktlQ98ZEL1k9FaQjxa3L1abBgbuTDAdPOpvbGncC0BTVQrl+OM8xZGK6tWXt7g==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/ansi-fragments/node_modules/astral-regex": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/astral-regex/-/astral-regex-1.0.0.tgz", - "integrity": "sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=4" - } - }, - "node_modules/ansi-fragments/node_modules/colorette": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/colorette/-/colorette-1.4.0.tgz", - "integrity": "sha512-Y2oEozpomLn7Q3HFP7dpww7AtMJplbM9lGZP6RDfHqmbeRjiwRg4n6VM6j4KLmRke85uWEI7JqF17f3pqdRA0g==", - "license": "MIT", - "peer": true - }, - "node_modules/ansi-fragments/node_modules/is-fullwidth-code-point": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", - "integrity": "sha512-VHskAKYM8RfSFXwee5t5cbN5PZeq1Wrh6qd5bkyiXIf6UQcN6w/A0eXM9r6t8d+GYOh+o6ZhiEnb88LN/Y8m2w==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=4" - } - }, - "node_modules/ansi-fragments/node_modules/slice-ansi": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-2.1.0.tgz", - "integrity": "sha512-Qu+VC3EwYLldKa1fCxuuvULvSJOKEgk9pi8dZeCVK7TqBfUNTH4sFkk4joj8afVSfAYgJoSOetjx9QWOJ5mYoQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "ansi-styles": "^3.2.0", - "astral-regex": "^1.0.0", - "is-fullwidth-code-point": "^2.0.0" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/ansi-fragments/node_modules/strip-ansi": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "license": "MIT", - "peer": true, - "dependencies": { - "ansi-regex": "^4.1.0" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/ansi-html-community": { - "version": "0.0.8", - "resolved": "https://registry.npmjs.org/ansi-html-community/-/ansi-html-community-0.0.8.tgz", - "integrity": "sha512-1APHAyr3+PCamwNw3bXCPp4HFLONZt/yIH0sZp0/469KWNTEy+qN5jQ3GVX6DMZ1UXAi34yVwtTeaG/HpBuuzw==", - "dev": true, - "engines": [ - "node >= 0.8.0" - ], - "license": "Apache-2.0", - "bin": { - "ansi-html": "bin/ansi-html" - } - }, - "node_modules/ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", - "license": "MIT", - "peer": true, - "dependencies": { - "color-convert": "^1.9.0" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/ansis": { - "version": "1.5.2", - "resolved": "https://registry.npmjs.org/ansis/-/ansis-1.5.2.tgz", - "integrity": "sha512-T3vUABrcgSj/HXv27P+A/JxGk5b/ydx0JjN3lgjBTC2iZUFxQGjh43zCzLSbU4C1QTgmx9oaPeWNJFM+auI8qw==", - "dev": true, - "license": "ISC", - "engines": { - "node": ">=12.13" - }, - "funding": { - "type": "patreon", - "url": "https://patreon.com/biodiscus" - } - }, - "node_modules/anymatch": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", - "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", - "license": "ISC", - "dependencies": { - "normalize-path": "^3.0.0", - "picomatch": "^2.0.4" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/appdirsjs": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/appdirsjs/-/appdirsjs-1.2.7.tgz", - "integrity": "sha512-Quji6+8kLBC3NnBeo14nPDq0+2jUs5s3/xEye+udFHumHhRk4M7aAMXp/PBJqkKYGuuyR9M/6Dq7d2AViiGmhw==", - "license": "MIT", - "peer": true - }, - "node_modules/arch": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/arch/-/arch-2.2.0.tgz", - "integrity": "sha512-Of/R0wqp83cgHozfIYLbBMnej79U/SVGOOyuB3VVFv1NRM/PSFMK12x9KVtiYzJqmnU5WR2qp0Z5rHb7sWGnFQ==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "license": "MIT" - }, - "node_modules/are-docs-informative": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/are-docs-informative/-/are-docs-informative-0.0.2.tgz", - "integrity": "sha512-ixiS0nLNNG5jNQzgZJNoUpBKdo9yTYZMGJ+QgT2jmjR7G7+QHRCc4v6LQ3NgE7EBJq+o0ams3waJwkrlBom8Ig==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=14" - } - }, - "node_modules/argparse": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", - "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", - "license": "MIT", - "dependencies": { - "sprintf-js": "~1.0.2" - } - }, - "node_modules/argparse/node_modules/sprintf-js": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", - "integrity": "sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==", - "license": "BSD-3-Clause" - }, - "node_modules/aria-query": { - "version": "5.1.3", - "resolved": "https://registry.npmjs.org/aria-query/-/aria-query-5.1.3.tgz", - "integrity": "sha512-R5iJ5lkuHybztUfuOAznmboyjWq8O6sqNqtK7CLOqdydi54VNbORp49mb14KbWgG1QD3JFO9hJdZ+y4KutfdOQ==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "deep-equal": "^2.0.5" - } - }, - "node_modules/array-buffer-byte-length": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/array-buffer-byte-length/-/array-buffer-byte-length-1.0.1.tgz", - "integrity": "sha512-ahC5W1xgou+KTXix4sAO8Ki12Q+jf4i0+tmk3sC+zgcynshkHxzpXdImBehiUYKKKDwvfFiJl1tZt6ewscS1Mg==", - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.5", - "is-array-buffer": "^3.0.4" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/array-flatten": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz", - "integrity": "sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==", - "dev": true, - "license": "MIT" - }, - "node_modules/array-includes": { - "version": "3.1.8", - "resolved": "https://registry.npmjs.org/array-includes/-/array-includes-3.1.8.tgz", - "integrity": "sha512-itaWrbYbqpGXkGhZPGUulwnhVf5Hpy1xiCFsGqyIGglbBxmG5vSjxQen3/WGOjPpNEv1RtBLKxbmVXm8HpJStQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.7", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.2", - "es-object-atoms": "^1.0.0", - "get-intrinsic": "^1.2.4", - "is-string": "^1.0.7" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/array-union": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/array-union/-/array-union-2.1.0.tgz", - "integrity": "sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/array.prototype.find": { - "version": "2.2.3", - "resolved": "https://registry.npmjs.org/array.prototype.find/-/array.prototype.find-2.2.3.tgz", - "integrity": "sha512-fO/ORdOELvjbbeIfZfzrXFMhYHGofRGqd+am9zm3tZ4GlJINj/pA2eITyfd65Vg6+ZbHd/Cys7stpoRSWtQFdA==", - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.7", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.2", - "es-object-atoms": "^1.0.0", - "es-shim-unscopables": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/array.prototype.findlast": { - "version": "1.2.5", - "resolved": "https://registry.npmjs.org/array.prototype.findlast/-/array.prototype.findlast-1.2.5.tgz", - "integrity": "sha512-CVvd6FHg1Z3POpBLxO6E6zr+rSKEQ9L6rZHAaY7lLfhKsWYUBBOuMs0e9o24oopj6H+geRCX0YJ+TJLBK2eHyQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.7", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.2", - "es-errors": "^1.3.0", - "es-object-atoms": "^1.0.0", - "es-shim-unscopables": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/array.prototype.findlastindex": { - "version": "1.2.5", - "resolved": "https://registry.npmjs.org/array.prototype.findlastindex/-/array.prototype.findlastindex-1.2.5.tgz", - "integrity": "sha512-zfETvRFA8o7EiNn++N5f/kaCw221hrpGsDmcpndVupkPzEc1Wuf3VgC0qby1BbHs7f5DVYjgtEU2LLh5bqeGfQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.7", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.2", - "es-errors": "^1.3.0", - "es-object-atoms": "^1.0.0", - "es-shim-unscopables": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/array.prototype.flat": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/array.prototype.flat/-/array.prototype.flat-1.3.2.tgz", - "integrity": "sha512-djYB+Zx2vLewY8RWlNCUdHjDXs2XOgm602S9E7P/UpHgfeHL00cRiIF+IN/G/aUJ7kGPb6yO/ErDI5V2s8iycA==", - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.2", - "define-properties": "^1.2.0", - "es-abstract": "^1.22.1", - "es-shim-unscopables": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/array.prototype.flatmap": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/array.prototype.flatmap/-/array.prototype.flatmap-1.3.2.tgz", - "integrity": "sha512-Ewyx0c9PmpcsByhSW4r+9zDU7sGjFc86qf/kKtuSCRdhfbk0SNLLkaT5qvcHnRGgc5NP/ly/y+qkXkqONX54CQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.2", - "define-properties": "^1.2.0", - "es-abstract": "^1.22.1", - "es-shim-unscopables": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/array.prototype.tosorted": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/array.prototype.tosorted/-/array.prototype.tosorted-1.1.4.tgz", - "integrity": "sha512-p6Fx8B7b7ZhL/gmUsAy0D15WhvDccw3mnGNbZpi3pmeJdxtWsj2jEaI4Y6oo3XiHfzuSgPwKc04MYt6KgvC/wA==", - "dev": true, - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.7", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.3", - "es-errors": "^1.3.0", - "es-shim-unscopables": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/arraybuffer.prototype.slice": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.3.tgz", - "integrity": "sha512-bMxMKAjg13EBSVscxTaYA4mRc5t1UAXa2kXiGTNfZ079HIWXEkKmkgFrh/nJqamaLSrXO5H4WFFkPEaLJWbs3A==", - "license": "MIT", - "dependencies": { - "array-buffer-byte-length": "^1.0.1", - "call-bind": "^1.0.5", - "define-properties": "^1.2.1", - "es-abstract": "^1.22.3", - "es-errors": "^1.2.1", - "get-intrinsic": "^1.2.3", - "is-array-buffer": "^3.0.4", - "is-shared-array-buffer": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/asap": { - "version": "2.0.6", - "resolved": "https://registry.npmjs.org/asap/-/asap-2.0.6.tgz", - "integrity": "sha512-BSHWgDSAiKs50o2Re8ppvp3seVHXSRM44cdSsT9FfNEUUZLOGWVCsiWaRPWM1Znn+mqZ1OfVZ3z3DWEzSp7hRA==", - "license": "MIT", - "peer": true - }, - "node_modules/asn1": { - "version": "0.2.6", - "resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.6.tgz", - "integrity": "sha512-ix/FxPn0MDjeyJ7i/yoHGFt/EX6LyNbxSEhPPXODPL+KB0VPk86UYfL0lMdy+KCnv+fmvIzySwaK5COwqVbWTQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "safer-buffer": "~2.1.0" - } - }, - "node_modules/assert-plus": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz", - "integrity": "sha512-NfJ4UzBCcQGLDlQq7nHxH+tv3kyZ0hHQqF5BO6J7tNJeP5do1llPr8dZ8zHonfhAu0PHAdMkSo+8o0wxg9lZWw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.8" - } - }, - "node_modules/ast-metadata-inferer": { - "version": "0.8.0", - "resolved": "https://registry.npmjs.org/ast-metadata-inferer/-/ast-metadata-inferer-0.8.0.tgz", - "integrity": "sha512-jOMKcHht9LxYIEQu+RVd22vtgrPaVCtDRQ/16IGmurdzxvYbDd5ynxjnyrzLnieG96eTcAyaoj/wN/4/1FyyeA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@mdn/browser-compat-data": "^5.2.34" - } - }, - "node_modules/ast-types": { - "version": "0.15.2", - "resolved": "https://registry.npmjs.org/ast-types/-/ast-types-0.15.2.tgz", - "integrity": "sha512-c27loCv9QkZinsa5ProX751khO9DJl/AcB5c2KNtA6NRvHKS0PgLfcftz72KVq504vB0Gku5s2kUZzDBvQWvHg==", - "license": "MIT", - "peer": true, - "dependencies": { - "tslib": "^2.0.1" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/ast-types-flow": { - "version": "0.0.8", - "resolved": "https://registry.npmjs.org/ast-types-flow/-/ast-types-flow-0.0.8.tgz", - "integrity": "sha512-OH/2E5Fg20h2aPrbe+QL8JZQFko0YZaF+j4mnQ7BGhfavO7OpSLa8a0y9sBwomHdSbkhTS8TQNayBfnW5DwbvQ==", - "dev": true, - "license": "MIT" - }, - "node_modules/ast-types/node_modules/tslib": { - "version": "2.7.0", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.7.0.tgz", - "integrity": "sha512-gLXCKdN1/j47AiHiOkJN69hJmcbGTHI0ImLmbYLHykhgeN0jVGola9yVjFgzCUklsZQMW55o+dW7IXv3RCXDzA==", - "license": "0BSD", - "peer": true - }, - "node_modules/astral-regex": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/astral-regex/-/astral-regex-2.0.0.tgz", - "integrity": "sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/async": { - "version": "3.2.6", - "resolved": "https://registry.npmjs.org/async/-/async-3.2.6.tgz", - "integrity": "sha512-htCUDlxyyCLMgaM3xXg0C0LW2xqfuQ6p05pCEIsXuyQ+a1koYKTuBMzRNwmybfLgvJDMd0r1LTn4+E0Ti6C2AA==", - "dev": true, - "license": "MIT" - }, - "node_modules/async-limiter": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.1.tgz", - "integrity": "sha512-csOlWGAcRFJaI6m+F2WKdnMKr4HhdhFVBk0H/QbJFMCr+uO2kwohwXQPxw/9OCxp05r5ghVBFSyioixx3gfkNQ==", - "license": "MIT", - "peer": true - }, - "node_modules/asynckit": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", - "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==", - "dev": true, - "license": "MIT" - }, - "node_modules/at-least-node": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/at-least-node/-/at-least-node-1.0.0.tgz", - "integrity": "sha512-+q/t7Ekv1EDY2l6Gda6LLiX14rU9TV20Wa3ofeQmwPFZbOMo9DXrLbOjFaaclkXKWidIaopwAObQDqwWtGUjqg==", - "dev": true, - "license": "ISC", - "engines": { - "node": ">= 4.0.0" - } - }, - "node_modules/available-typed-arrays": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.7.tgz", - "integrity": "sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ==", - "license": "MIT", - "dependencies": { - "possible-typed-array-names": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/aws-sign2": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz", - "integrity": "sha512-08kcGqnYf/YmjoRhfxyu+CLxBjUtHLXLXX/vUfx9l2LYzG3c1m61nrpyFUZI6zeS+Li/wWMMidD9KgrqtGq3mA==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "*" - } - }, - "node_modules/aws4": { - "version": "1.13.2", - "resolved": "https://registry.npmjs.org/aws4/-/aws4-1.13.2.tgz", - "integrity": "sha512-lHe62zvbTB5eEABUVi/AwVh0ZKY9rMMDhmm+eeyuuUQbQ3+J+fONVQOZyj+DdrvD4BY33uYniyRJ4UJIaSKAfw==", - "dev": true, - "license": "MIT" - }, - "node_modules/axe-core": { - "version": "4.10.0", - "resolved": "https://registry.npmjs.org/axe-core/-/axe-core-4.10.0.tgz", - "integrity": "sha512-Mr2ZakwQ7XUAjp7pAwQWRhhK8mQQ6JAaNWSjmjxil0R8BPioMtQsTLOolGYkji1rcL++3dCqZA3zWqpT+9Ew6g==", - "dev": true, - "license": "MPL-2.0", - "engines": { - "node": ">=4" - } - }, - "node_modules/axobject-query": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/axobject-query/-/axobject-query-4.1.0.tgz", - "integrity": "sha512-qIj0G9wZbMGNLjLmg1PT6v2mE9AH2zlnADJD/2tC6E00hgmhUOfEB6greHPAfLRSufHqROIUTkw6E+M3lH0PTQ==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/babel-core": { - "version": "7.0.0-bridge.0", - "resolved": "https://registry.npmjs.org/babel-core/-/babel-core-7.0.0-bridge.0.tgz", - "integrity": "sha512-poPX9mZH/5CSanm50Q+1toVci6pv5KSRv/5TWCwtzQS5XEwn40BcCrgIeMFWP9CKKIniKXNxoIOnOq4VVlGXhg==", - "license": "MIT", - "peer": true, - "peerDependencies": { - "@babel/core": "^7.0.0-0" - } - }, - "node_modules/babel-loader": { - "version": "9.2.1", - "resolved": "https://registry.npmjs.org/babel-loader/-/babel-loader-9.2.1.tgz", - "integrity": "sha512-fqe8naHt46e0yIdkjUZYqddSXfej3AHajX+CSO5X7oy0EmPc6o5Xh+RClNoHjnieWz9AW4kZxW9yyFMhVB1QLA==", - "dev": true, - "license": "MIT", - "dependencies": { - "find-cache-dir": "^4.0.0", - "schema-utils": "^4.0.0" - }, - "engines": { - "node": ">= 14.15.0" - }, - "peerDependencies": { - "@babel/core": "^7.12.0", - "webpack": ">=5" - } - }, - "node_modules/babel-plugin-polyfill-corejs2": { - "version": "0.4.11", - "resolved": "https://registry.npmjs.org/babel-plugin-polyfill-corejs2/-/babel-plugin-polyfill-corejs2-0.4.11.tgz", - "integrity": "sha512-sMEJ27L0gRHShOh5G54uAAPaiCOygY/5ratXuiyb2G46FmlSpc9eFCzYVyDiPxfNbwzA7mYahmjQc5q+CZQ09Q==", - "license": "MIT", - "dependencies": { - "@babel/compat-data": "^7.22.6", - "@babel/helper-define-polyfill-provider": "^0.6.2", - "semver": "^6.3.1" - }, - "peerDependencies": { - "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" - } - }, - "node_modules/babel-plugin-polyfill-corejs3": { - "version": "0.10.6", - "resolved": "https://registry.npmjs.org/babel-plugin-polyfill-corejs3/-/babel-plugin-polyfill-corejs3-0.10.6.tgz", - "integrity": "sha512-b37+KR2i/khY5sKmWNVQAnitvquQbNdWy6lJdsr0kmquCKEEUgMKK4SboVM3HtfnZilfjr4MMQ7vY58FVWDtIA==", - "license": "MIT", - "dependencies": { - "@babel/helper-define-polyfill-provider": "^0.6.2", - "core-js-compat": "^3.38.0" - }, - "peerDependencies": { - "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" - } - }, - "node_modules/babel-plugin-polyfill-regenerator": { - "version": "0.6.2", - "resolved": "https://registry.npmjs.org/babel-plugin-polyfill-regenerator/-/babel-plugin-polyfill-regenerator-0.6.2.tgz", - "integrity": "sha512-2R25rQZWP63nGwaAswvDazbPXfrM3HwVoBXK6HcqeKrSrL/JqcC/rDcf95l4r7LXLyxDXc8uQDa064GubtCABg==", - "license": "MIT", - "dependencies": { - "@babel/helper-define-polyfill-provider": "^0.6.2" - }, - "peerDependencies": { - "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" - } - }, - "node_modules/babel-plugin-styled-components": { - "version": "2.1.4", - "resolved": "https://registry.npmjs.org/babel-plugin-styled-components/-/babel-plugin-styled-components-2.1.4.tgz", - "integrity": "sha512-Xgp9g+A/cG47sUyRwwYxGM4bR/jDRg5N6it/8+HxCnbT5XNKSKDT9xm4oag/osgqjC2It/vH0yXsomOG6k558g==", - "license": "MIT", - "dependencies": { - "@babel/helper-annotate-as-pure": "^7.22.5", - "@babel/helper-module-imports": "^7.22.5", - "@babel/plugin-syntax-jsx": "^7.22.5", - "lodash": "^4.17.21", - "picomatch": "^2.3.1" - }, - "peerDependencies": { - "styled-components": ">= 2" - } - }, - "node_modules/babel-plugin-transform-flow-enums": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/babel-plugin-transform-flow-enums/-/babel-plugin-transform-flow-enums-0.0.2.tgz", - "integrity": "sha512-g4aaCrDDOsWjbm0PUUeVnkcVd6AKJsVc/MbnPhEotEpkeJQP6b8nzewohQi7+QS8UyPehOhGWn0nOwjvWpmMvQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "@babel/plugin-syntax-flow": "^7.12.1" - } - }, - "node_modules/balanced-match": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", - "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", - "license": "MIT" - }, - "node_modules/base64-js": { - "version": "1.5.1", - "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", - "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "license": "MIT" - }, - "node_modules/batch": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/batch/-/batch-0.6.1.tgz", - "integrity": "sha512-x+VAiMRL6UPkx+kudNvxTl6hB2XNNCG2r+7wixVfIYwu/2HKRXimwQyaumLjMveWvT2Hkd/cAJw+QBMfJ/EKVw==", - "dev": true, - "license": "MIT" - }, - "node_modules/bcrypt-pbkdf": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz", - "integrity": "sha512-qeFIXtP4MSoi6NLqO12WfqARWWuCKi2Rn/9hJLEmtB5yTNr9DqFWkJRCf2qShWzPeAMRnOgCrq0sg/KLv5ES9w==", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "tweetnacl": "^0.14.3" - } - }, - "node_modules/binary-extensions": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.3.0.tgz", - "integrity": "sha512-Ceh+7ox5qe7LJuLHoY0feh3pHuUDHAcRUeyL2VYghZwfpkNIy/+8Ocg0a3UuSoYzavmylwuLWQOf3hl0jjMMIw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/bl": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/bl/-/bl-4.1.0.tgz", - "integrity": "sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==", - "license": "MIT", - "peer": true, - "dependencies": { - "buffer": "^5.5.0", - "inherits": "^2.0.4", - "readable-stream": "^3.4.0" - } - }, - "node_modules/bl/node_modules/readable-stream": { - "version": "3.6.2", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", - "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", - "license": "MIT", - "peer": true, - "dependencies": { - "inherits": "^2.0.3", - "string_decoder": "^1.1.1", - "util-deprecate": "^1.0.1" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/blob-util": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/blob-util/-/blob-util-2.0.2.tgz", - "integrity": "sha512-T7JQa+zsXXEa6/8ZhHcQEW1UFfVM49Ts65uBkFL6fz2QmrElqmbajIDJvuA0tEhRe5eIjpV9ZF+0RfZR9voJFQ==", - "dev": true, - "license": "Apache-2.0" - }, - "node_modules/bluebird": { - "version": "3.7.2", - "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.7.2.tgz", - "integrity": "sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==", - "dev": true, - "license": "MIT" - }, - "node_modules/body-parser": { - "version": "1.20.3", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.3.tgz", - "integrity": "sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==", - "dev": true, - "license": "MIT", - "dependencies": { - "bytes": "3.1.2", - "content-type": "~1.0.5", - "debug": "2.6.9", - "depd": "2.0.0", - "destroy": "1.2.0", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "on-finished": "2.4.1", - "qs": "6.13.0", - "raw-body": "2.5.2", - "type-is": "~1.6.18", - "unpipe": "1.0.0" - }, - "engines": { - "node": ">= 0.8", - "npm": "1.2.8000 || >= 1.4.16" - } - }, - "node_modules/body-parser/node_modules/bytes": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.2.tgz", - "integrity": "sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/body-parser/node_modules/debug": { - "version": "2.6.9", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", - "dev": true, - "license": "MIT", - "dependencies": { - "ms": "2.0.0" - } - }, - "node_modules/body-parser/node_modules/iconv-lite": { - "version": "0.4.24", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", - "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", - "dev": true, - "license": "MIT", - "dependencies": { - "safer-buffer": ">= 2.1.2 < 3" - }, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/body-parser/node_modules/ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", - "dev": true, - "license": "MIT" - }, - "node_modules/bonjour-service": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/bonjour-service/-/bonjour-service-1.2.1.tgz", - "integrity": "sha512-oSzCS2zV14bh2kji6vNe7vrpJYCHGvcZnlffFQ1MEoX/WOeQ/teD8SYWKR942OI3INjq8OMNJlbPK5LLLUxFDw==", - "dev": true, - "license": "MIT", - "dependencies": { - "fast-deep-equal": "^3.1.3", - "multicast-dns": "^7.2.5" - } - }, - "node_modules/boolbase": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/boolbase/-/boolbase-1.0.0.tgz", - "integrity": "sha512-JZOSA7Mo9sNGB8+UjSgzdLtokWAky1zbztM3WRLCbZ70/3cTANmQmOdR7y2g+J0e2WXywy1yS468tY+IruqEww==", - "dev": true, - "license": "ISC" - }, - "node_modules/brace-expansion": { - "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" - } - }, - "node_modules/braces": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", - "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", - "license": "MIT", - "dependencies": { - "fill-range": "^7.1.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/brcast": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/brcast/-/brcast-2.0.2.tgz", - "integrity": "sha512-Tfn5JSE7hrUlFcOoaLzVvkbgIemIorMIyoMr3TgvszWW7jFt2C9PdeMLtysYD9RU0MmU17b69+XJG1eRY2OBRg==", - "license": "MIT" - }, - "node_modules/browserslist": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.24.4.tgz", - "integrity": "sha512-KDi1Ny1gSePi1vm0q4oxSF8b4DR44GF4BbmS2YdhPLOEqd8pDviZOGH/GsmRwoWJ2+5Lr085X7naowMwKHDG1A==", - "funding": [ - { - "type": "opencollective", - "url": "https://opencollective.com/browserslist" - }, - { - "type": "tidelift", - "url": "https://tidelift.com/funding/github/npm/browserslist" - }, - { - "type": "github", - "url": "https://github.com/sponsors/ai" - } - ], - "license": "MIT", - "dependencies": { - "caniuse-lite": "^1.0.30001688", - "electron-to-chromium": "^1.5.73", - "node-releases": "^2.0.19", - "update-browserslist-db": "^1.1.1" - }, - "bin": { - "browserslist": "cli.js" - }, - "engines": { - "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7" - } - }, - "node_modules/bser": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/bser/-/bser-2.1.1.tgz", - "integrity": "sha512-gQxTNE/GAfIIrmHLUE3oJyp5FO6HRBfhjnw4/wMmA63ZGDJnWBmgY/lyQBpnDUkGmAhbSe39tx2d/iTOAfglwQ==", - "license": "Apache-2.0", - "peer": true, - "dependencies": { - "node-int64": "^0.4.0" - } - }, - "node_modules/buffer": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", - "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "license": "MIT", - "dependencies": { - "base64-js": "^1.3.1", - "ieee754": "^1.1.13" - } - }, - "node_modules/buffer-crc32": { - "version": "0.2.13", - "resolved": "https://registry.npmjs.org/buffer-crc32/-/buffer-crc32-0.2.13.tgz", - "integrity": "sha512-VO9Ht/+p3SN7SKWqcrgEzjGbRSJYTx+Q1pTQC0wrWqHx0vpJraQ6GtHx8tvcg1rlK1byhU5gccxgOgj7B0TDkQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": "*" - } - }, - "node_modules/buffer-from": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", - "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==", - "license": "MIT" - }, - "node_modules/builtin-modules": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/builtin-modules/-/builtin-modules-3.3.0.tgz", - "integrity": "sha512-zhaCDicdLuWN5UbN5IMnFqNMhNfo919sH85y2/ea+5Yg9TsTkeZxpL+JLbp6cgYFS4sRLp3YV4S6yDuqVWHYOw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/bytes": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.0.0.tgz", - "integrity": "sha512-pMhOfFDPiv9t5jjIXkHosWmkSyQbvsgEVNkz0ERHbuLh2T/7j4Mqqpz523Fe8MVY89KC6Sh/QfS2sM+SjgFDcw==", - "license": "MIT", - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/cacheable": { - "version": "1.8.10", - "resolved": "https://registry.npmjs.org/cacheable/-/cacheable-1.8.10.tgz", - "integrity": "sha512-0ZnbicB/N2R6uziva8l6O6BieBklArWyiGx4GkwAhLKhSHyQtRfM9T1nx7HHuHDKkYB/efJQhz3QJ6x/YqoZzA==", - "dev": true, - "license": "MIT", - "dependencies": { - "hookified": "^1.8.1", - "keyv": "^5.3.2" - } - }, - "node_modules/cacheable-lookup": { - "version": "5.0.4", - "resolved": "https://registry.npmjs.org/cacheable-lookup/-/cacheable-lookup-5.0.4.tgz", - "integrity": "sha512-2/kNscPhpcxrOigMZzbiWF7dz8ilhb/nIHU3EyZiXWXpeq/au8qJ8VhdftMkty3n7Gj6HIGalQG8oiBNB3AJgA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=10.6.0" - } - }, - "node_modules/cacheable-request": { - "version": "7.0.4", - "resolved": "https://registry.npmjs.org/cacheable-request/-/cacheable-request-7.0.4.tgz", - "integrity": "sha512-v+p6ongsrp0yTGbJXjgxPow2+DL93DASP4kXCDKb8/bwRtt9OEF3whggkkDkGNzgcWy2XaF4a8nZglC7uElscg==", - "dev": true, - "license": "MIT", - "dependencies": { - "clone-response": "^1.0.2", - "get-stream": "^5.1.0", - "http-cache-semantics": "^4.0.0", - "keyv": "^4.0.0", - "lowercase-keys": "^2.0.0", - "normalize-url": "^6.0.1", - "responselike": "^2.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/cacheable/node_modules/keyv": { - "version": "5.3.3", - "resolved": "https://registry.npmjs.org/keyv/-/keyv-5.3.3.tgz", - "integrity": "sha512-Rwu4+nXI9fqcxiEHtbkvoes2X+QfkTRo1TMkPfwzipGsJlJO/z69vqB4FNl9xJ3xCpAcbkvmEabZfPzrwN3+gQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@keyv/serialize": "^1.0.3" - } - }, - "node_modules/cachedir": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/cachedir/-/cachedir-2.4.0.tgz", - "integrity": "sha512-9EtFOZR8g22CL7BWjJ9BUx1+A/djkofnyW3aOXZORNW2kxoUpx2h+uN2cOqwPmFhnpVmxg+KW2OjOSgChTEvsQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/call-bind": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.7.tgz", - "integrity": "sha512-GHTSNSYICQ7scH7sZ+M2rFopRoLh8t2bLSW6BbgrtLsahOIB5iyAVJf9GjWK3cYTDaMj4XdBpM1cA6pIS0Kv2w==", - "license": "MIT", - "dependencies": { - "es-define-property": "^1.0.0", - "es-errors": "^1.3.0", - "function-bind": "^1.1.2", - "get-intrinsic": "^1.2.4", - "set-function-length": "^1.2.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/caller-callsite": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/caller-callsite/-/caller-callsite-2.0.0.tgz", - "integrity": "sha512-JuG3qI4QOftFsZyOn1qq87fq5grLIyk1JYd5lJmdA+fG7aQ9pA/i3JIJGcO3q0MrRcHlOt1U+ZeHW8Dq9axALQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "callsites": "^2.0.0" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/caller-callsite/node_modules/callsites": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/callsites/-/callsites-2.0.0.tgz", - "integrity": "sha512-ksWePWBloaWPxJYQ8TL0JHvtci6G5QTKwQ95RcWAa/lzoAKuAOflGdAK92hpHXjkwb8zLxoLNUoNYZgVsaJzvQ==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=4" - } - }, - "node_modules/caller-path": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/caller-path/-/caller-path-2.0.0.tgz", - "integrity": "sha512-MCL3sf6nCSXOwCTzvPKhN18TU7AHTvdtam8DAogxcrJ8Rjfbbg7Lgng64H9Iy+vUV6VGFClN/TyxBkAebLRR4A==", - "license": "MIT", - "peer": true, - "dependencies": { - "caller-callsite": "^2.0.0" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/callsites": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", - "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==", - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/camelcase": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", - "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", - "license": "MIT", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/camelize": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/camelize/-/camelize-1.0.1.tgz", - "integrity": "sha512-dU+Tx2fsypxTgtLoE36npi3UqcjSSMNYfkqgmoEhtZrraP5VWq0K7FkWVTYa8eMPtnU/G2txVsfdCJTn9uzpuQ==", - "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/caniuse-lite": { - "version": "1.0.30001715", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001715.tgz", - "integrity": "sha512-7ptkFGMm2OAOgvZpwgA4yjQ5SQbrNVGdRjzH0pBdy1Fasvcr+KAeECmbCAECzTuDuoX0FCY8KzUxjf9+9kfZEw==", - "funding": [ - { - "type": "opencollective", - "url": "https://opencollective.com/browserslist" - }, - { - "type": "tidelift", - "url": "https://tidelift.com/funding/github/npm/caniuse-lite" - }, - { - "type": "github", - "url": "https://github.com/sponsors/ai" - } - ], - "license": "CC-BY-4.0" - }, - "node_modules/caseless": { - "version": "0.12.0", - "resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz", - "integrity": "sha512-4tYFyifaFfGacoiObjJegolkwSU4xQNGbVgUiNYVUxbQ2x2lUsFvY4hVgVzGiIe6WLOPqycWXA40l+PWsxthUw==", - "dev": true, - "license": "Apache-2.0" - }, - "node_modules/chardet": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/chardet/-/chardet-0.7.0.tgz", - "integrity": "sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==", - "dev": true, - "license": "MIT" - }, - "node_modules/check-more-types": { - "version": "2.24.0", - "resolved": "https://registry.npmjs.org/check-more-types/-/check-more-types-2.24.0.tgz", - "integrity": "sha512-Pj779qHxV2tuapviy1bSZNEL1maXr13bPYpsvSDB68HlYcYuhlDrmGd63i0JHMCLKzc7rUSNIrpdJlhVlNwrxA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/chokidar": { - "version": "3.6.0", - "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.6.0.tgz", - "integrity": "sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw==", - "dev": true, - "license": "MIT", - "dependencies": { - "anymatch": "~3.1.2", - "braces": "~3.0.2", - "glob-parent": "~5.1.2", - "is-binary-path": "~2.1.0", - "is-glob": "~4.0.1", - "normalize-path": "~3.0.0", - "readdirp": "~3.6.0" - }, - "engines": { - "node": ">= 8.10.0" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - }, - "optionalDependencies": { - "fsevents": "~2.3.2" - } - }, - "node_modules/chokidar/node_modules/glob-parent": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", - "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", - "dev": true, - "license": "ISC", - "dependencies": { - "is-glob": "^4.0.1" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/chrome-launcher": { - "version": "0.15.2", - "resolved": "https://registry.npmjs.org/chrome-launcher/-/chrome-launcher-0.15.2.tgz", - "integrity": "sha512-zdLEwNo3aUVzIhKhTtXfxhdvZhUghrnmkvcAq2NoDd+LeOHKf03H5jwZ8T/STsAlzyALkBVK552iaG1fGf1xVQ==", - "license": "Apache-2.0", - "peer": true, - "dependencies": { - "@types/node": "*", - "escape-string-regexp": "^4.0.0", - "is-wsl": "^2.2.0", - "lighthouse-logger": "^1.0.0" - }, - "bin": { - "print-chrome-path": "bin/print-chrome-path.js" - }, - "engines": { - "node": ">=12.13.0" - } - }, - "node_modules/chrome-launcher/node_modules/escape-string-regexp": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", - "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/chrome-trace-event": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/chrome-trace-event/-/chrome-trace-event-1.0.4.tgz", - "integrity": "sha512-rNjApaLzuwaOTjCiT8lSDdGN1APCiqkChLMJxJPWLunPAt5fy8xgU9/jNOchV84wfIxrA0lRQB7oCT8jrn/wrQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6.0" - } - }, - "node_modules/chromium-edge-launcher": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/chromium-edge-launcher/-/chromium-edge-launcher-0.2.0.tgz", - "integrity": "sha512-JfJjUnq25y9yg4FABRRVPmBGWPZZi+AQXT4mxupb67766/0UlhG8PAZCz6xzEMXTbW3CsSoE8PcCWA49n35mKg==", - "license": "Apache-2.0", - "peer": true, - "dependencies": { - "@types/node": "*", - "escape-string-regexp": "^4.0.0", - "is-wsl": "^2.2.0", - "lighthouse-logger": "^1.0.0", - "mkdirp": "^1.0.4", - "rimraf": "^3.0.2" - } - }, - "node_modules/chromium-edge-launcher/node_modules/escape-string-regexp": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", - "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/chromium-edge-launcher/node_modules/mkdirp": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", - "license": "MIT", - "peer": true, - "bin": { - "mkdirp": "bin/cmd.js" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/ci-info": { - "version": "3.9.0", - "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-3.9.0.tgz", - "integrity": "sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/sibiraj-s" - } - ], - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/classnames": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/classnames/-/classnames-2.5.1.tgz", - "integrity": "sha512-saHYOzhIQs6wy2sVxTM6bUDsQO4F50V9RQ22qBpEdCW+I+/Wmke2HOl6lS6dTpdxVhb88/I6+Hs+438c3lfUow==", - "license": "MIT" - }, - "node_modules/clean-stack": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/clean-stack/-/clean-stack-2.2.0.tgz", - "integrity": "sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6" - } - }, - "node_modules/cli-cursor": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-3.1.0.tgz", - "integrity": "sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw==", - "license": "MIT", - "dependencies": { - "restore-cursor": "^3.1.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/cli-spinners": { - "version": "2.9.2", - "resolved": "https://registry.npmjs.org/cli-spinners/-/cli-spinners-2.9.2.tgz", - "integrity": "sha512-ywqV+5MmyL4E7ybXgKys4DugZbX0FC6LnwrhjuykIjnK9k8OQacQ7axGKnjDXWNhns0xot3bZI5h55H8yo9cJg==", - "license": "MIT", - "engines": { - "node": ">=6" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/cli-table3": { - "version": "0.6.5", - "resolved": "https://registry.npmjs.org/cli-table3/-/cli-table3-0.6.5.tgz", - "integrity": "sha512-+W/5efTR7y5HRD7gACw9yQjqMVvEMLBHmboM/kPWam+H+Hmyrgjh6YncVKK122YZkXrLudzTuAukUw9FnMf7IQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "string-width": "^4.2.0" - }, - "engines": { - "node": "10.* || >= 12.*" - }, - "optionalDependencies": { - "@colors/colors": "1.5.0" - } - }, - "node_modules/cli-truncate": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/cli-truncate/-/cli-truncate-2.1.0.tgz", - "integrity": "sha512-n8fOixwDD6b/ObinzTrp1ZKFzbgvKZvuz/TvejnLn1aQfC6r52XEx85FmuC+3HI+JM7coBRXUvNqEU2PHVrHpg==", - "dev": true, - "license": "MIT", - "dependencies": { - "slice-ansi": "^3.0.0", - "string-width": "^4.2.0" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/cli-width": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/cli-width/-/cli-width-3.0.0.tgz", - "integrity": "sha512-FxqpkPPwu1HjuN93Omfm4h8uIanXofW0RxVEW3k5RKx+mJJYSthzNhp32Kzxxy3YAEZ/Dc/EWN1vZRY0+kOhbw==", - "dev": true, - "license": "ISC", - "engines": { - "node": ">= 10" - } - }, - "node_modules/clipboard": { - "version": "2.0.11", - "resolved": "https://registry.npmjs.org/clipboard/-/clipboard-2.0.11.tgz", - "integrity": "sha512-C+0bbOqkezLIsmWSvlsXS0Q0bmkugu7jcfMIACB+RDEntIzQIkdr148we28AfSloQLRdZlYL/QYyrq05j/3Faw==", - "license": "MIT", - "dependencies": { - "good-listener": "^1.2.2", - "select": "^1.1.2", - "tiny-emitter": "^2.0.0" - } - }, - "node_modules/cliui": { - "version": "8.0.1", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", - "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==", - "license": "ISC", - "dependencies": { - "string-width": "^4.2.0", - "strip-ansi": "^6.0.1", - "wrap-ansi": "^7.0.0" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/cliui/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "license": "MIT", - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/cliui/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "license": "MIT", - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/cliui/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT" - }, - "node_modules/cliui/node_modules/wrap-ansi": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", - "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", - "license": "MIT", - "dependencies": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/wrap-ansi?sponsor=1" - } - }, - "node_modules/clone": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/clone/-/clone-2.1.2.tgz", - "integrity": "sha512-3Pe/CF1Nn94hyhIYpjtiLhdCoEoz0DqQ+988E9gmeEdQZlojxnOb74wctFyuwWQHzqyf9X7C7MG8juUpqBJT8w==", - "license": "MIT", - "engines": { - "node": ">=0.8" - } - }, - "node_modules/clone-buffer": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/clone-buffer/-/clone-buffer-1.0.0.tgz", - "integrity": "sha512-KLLTJWrvwIP+OPfMn0x2PheDEP20RPUcGXj/ERegTgdmPEZylALQldygiqrPPu8P45uNuPs7ckmReLY6v/iA5g==", - "license": "MIT", - "engines": { - "node": ">= 0.10" - } - }, - "node_modules/clone-deep": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/clone-deep/-/clone-deep-4.0.1.tgz", - "integrity": "sha512-neHB9xuzh/wk0dIHweyAXv2aPGZIVk3pLMe+/RNzINf17fe0OG96QroktYAUm7SM1PBnzTabaLboqqxDyMU+SQ==", - "license": "MIT", - "dependencies": { - "is-plain-object": "^2.0.4", - "kind-of": "^6.0.2", - "shallow-clone": "^3.0.0" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/clone-deep/node_modules/is-plain-object": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-2.0.4.tgz", - "integrity": "sha512-h5PpgXkWitc38BBMYawTYMWJHFZJVnBquFE57xFpjB8pJFiF6gZ+bU+WyI/yqXiFR5mdLsgYNaPe8uao6Uv9Og==", - "license": "MIT", - "dependencies": { - "isobject": "^3.0.1" - }, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/clone-response": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/clone-response/-/clone-response-1.0.3.tgz", - "integrity": "sha512-ROoL94jJH2dUVML2Y/5PEDNaSHgeOdSDicUyS7izcF63G6sTc/FTjLub4b8Il9S8S0beOfYt0TaA5qvFK+w0wA==", - "dev": true, - "license": "MIT", - "dependencies": { - "mimic-response": "^1.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/clone-stats": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/clone-stats/-/clone-stats-1.0.0.tgz", - "integrity": "sha512-au6ydSpg6nsrigcZ4m8Bc9hxjeW+GJ8xh5G3BJCMt4WXe1H10UNaVOamqQTmrx1kjVuxAHIQSNU6hY4Nsn9/ag==", - "license": "MIT" - }, - "node_modules/cloneable-readable": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/cloneable-readable/-/cloneable-readable-1.1.3.tgz", - "integrity": "sha512-2EF8zTQOxYq70Y4XKtorQupqF0m49MBz2/yf5Bj+MHjvpG3Hy7sImifnqD6UA+TKYxeSV+u6qqQPawN5UvnpKQ==", - "license": "MIT", - "dependencies": { - "inherits": "^2.0.1", - "process-nextick-args": "^2.0.0", - "readable-stream": "^2.3.5" - } - }, - "node_modules/color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", - "license": "MIT", - "peer": true, - "dependencies": { - "color-name": "1.1.3" - } - }, - "node_modules/color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", - "license": "MIT", - "peer": true - }, - "node_modules/colord": { - "version": "2.9.3", - "resolved": "https://registry.npmjs.org/colord/-/colord-2.9.3.tgz", - "integrity": "sha512-jeC1axXpnb0/2nn/Y1LPuLdgXBLH7aDcHu4KEKfqw3CUhX7ZpfBSlPKyqXE6btIgEzfWtrX3/tyBCaCvXvMkOw==", - "dev": true, - "license": "MIT" - }, - "node_modules/colorette": { - "version": "2.0.20", - "resolved": "https://registry.npmjs.org/colorette/-/colorette-2.0.20.tgz", - "integrity": "sha512-IfEDxwoWIjkeXL1eXcDiow4UbKjhLdq6/EuSVR9GMN7KVH3r9gQ83e73hsz1Nd1T3ijd5xv1wcWRYO+D6kCI2w==", - "dev": true, - "license": "MIT" - }, - "node_modules/combined-stream": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", - "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", - "dev": true, - "license": "MIT", - "dependencies": { - "delayed-stream": "~1.0.0" - }, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/command-exists": { - "version": "1.2.9", - "resolved": "https://registry.npmjs.org/command-exists/-/command-exists-1.2.9.tgz", - "integrity": "sha512-LTQ/SGc+s0Xc0Fu5WaKnR0YiygZkm9eKFvyS+fRsU7/ZWFF8ykFM6Pc9aCVf1+xasOOZpO3BAVgVrKvsqKHV7w==", - "license": "MIT", - "peer": true - }, - "node_modules/commander": { - "version": "6.2.1", - "resolved": "https://registry.npmjs.org/commander/-/commander-6.2.1.tgz", - "integrity": "sha512-U7VdrJFnJgo4xjrHpTzu0yrHPGImdsmD95ZlgYSEajAn2JKzDhDTPG9kBTefmObL2w/ngeZnilk+OV9CG3d7UA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 6" - } - }, - "node_modules/comment-parser": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/comment-parser/-/comment-parser-1.4.1.tgz", - "integrity": "sha512-buhp5kePrmda3vhc5B9t7pUQXAb2Tnd0qgpkIhPhkHXxJpiPJ11H0ZEU0oBpJ2QztSbzG/ZxMj/CHsYJqRHmyg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 12.0.0" - } - }, - "node_modules/common-path-prefix": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/common-path-prefix/-/common-path-prefix-3.0.0.tgz", - "integrity": "sha512-QE33hToZseCH3jS0qN96O/bSh3kaw/h+Tq7ngyY9eWDUnTlTNUyqfqvCXioLe5Na5jFsL78ra/wuBU4iuEgd4w==", - "dev": true, - "license": "ISC" - }, - "node_modules/common-tags": { - "version": "1.8.2", - "resolved": "https://registry.npmjs.org/common-tags/-/common-tags-1.8.2.tgz", - "integrity": "sha512-gk/Z852D2Wtb//0I+kRFNKKE9dIIVirjoqPoA1wJU+XePVXZfGeBpk45+A1rKO4Q43prqWBNY/MiIeRLbPWUaA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=4.0.0" - } - }, - "node_modules/commondir": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz", - "integrity": "sha512-W9pAhw0ja1Edb5GVdIF1mjZw/ASI0AlShXM83UUGe2DVr5TdAPEA1OA8m/g8zWp9x6On7gqufY+FatDbC3MDQg==", - "license": "MIT", - "peer": true - }, - "node_modules/compressible": { - "version": "2.0.18", - "resolved": "https://registry.npmjs.org/compressible/-/compressible-2.0.18.tgz", - "integrity": "sha512-AF3r7P5dWxL8MxyITRMlORQNaOA2IkAFaTr4k7BUumjPtRpGDTZpl0Pb1XCO6JeDCBdp126Cgs9sMxqSjgYyRg==", - "license": "MIT", - "dependencies": { - "mime-db": ">= 1.43.0 < 2" - }, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/compression": { - "version": "1.7.4", - "resolved": "https://registry.npmjs.org/compression/-/compression-1.7.4.tgz", - "integrity": "sha512-jaSIDzP9pZVS4ZfQ+TzvtiWhdpFhE2RDHz8QJkpX9SIpLq88VueF5jJw6t+6CUQcAoA6t+x89MLrWAqpfDE8iQ==", - "license": "MIT", - "dependencies": { - "accepts": "~1.3.5", - "bytes": "3.0.0", - "compressible": "~2.0.16", - "debug": "2.6.9", - "on-headers": "~1.0.2", - "safe-buffer": "5.1.2", - "vary": "~1.1.2" - }, - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/compression/node_modules/debug": { - "version": "2.6.9", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", - "license": "MIT", - "dependencies": { - "ms": "2.0.0" - } - }, - "node_modules/compression/node_modules/ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", - "license": "MIT" - }, - "node_modules/compression/node_modules/safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", - "license": "MIT" - }, - "node_modules/concat-map": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", - "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==", - "license": "MIT" - }, - "node_modules/concat-stream": { - "version": "1.6.2", - "resolved": "https://registry.npmjs.org/concat-stream/-/concat-stream-1.6.2.tgz", - "integrity": "sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw==", - "dev": true, - "engines": [ - "node >= 0.8" - ], - "license": "MIT", - "dependencies": { - "buffer-from": "^1.0.0", - "inherits": "^2.0.3", - "readable-stream": "^2.2.2", - "typedarray": "^0.0.6" - } - }, - "node_modules/connect": { - "version": "3.7.0", - "resolved": "https://registry.npmjs.org/connect/-/connect-3.7.0.tgz", - "integrity": "sha512-ZqRXc+tZukToSNmh5C2iWMSoV3X1YUcPbqEM4DkEG5tNQXrQUZCNVGGv3IuicnkMtPfGf3Xtp8WCXs295iQ1pQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "debug": "2.6.9", - "finalhandler": "1.1.2", - "parseurl": "~1.3.3", - "utils-merge": "1.0.1" - }, - "engines": { - "node": ">= 0.10.0" - } - }, - "node_modules/connect-history-api-fallback": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/connect-history-api-fallback/-/connect-history-api-fallback-2.0.0.tgz", - "integrity": "sha512-U73+6lQFmfiNPrYbXqr6kZ1i1wiRqXnp2nhMsINseWXO8lDau0LGEffJ8kQi4EjLZympVgRdvqjAgiZ1tgzDDA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.8" - } - }, - "node_modules/connect/node_modules/debug": { - "version": "2.6.9", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", - "license": "MIT", - "peer": true, - "dependencies": { - "ms": "2.0.0" - } - }, - "node_modules/connect/node_modules/encodeurl": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", - "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/connect/node_modules/finalhandler": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.2.tgz", - "integrity": "sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA==", - "license": "MIT", - "peer": true, - "dependencies": { - "debug": "2.6.9", - "encodeurl": "~1.0.2", - "escape-html": "~1.0.3", - "on-finished": "~2.3.0", - "parseurl": "~1.3.3", - "statuses": "~1.5.0", - "unpipe": "~1.0.0" - }, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/connect/node_modules/ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", - "license": "MIT", - "peer": true - }, - "node_modules/connect/node_modules/on-finished": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.3.0.tgz", - "integrity": "sha512-ikqdkGAAyf/X/gPhXGvfgAytDZtDbr+bkNUJ0N9h5MI/dmdgCs3l6hoHrcUv41sRKew3jIwrp4qQDXiK99Utww==", - "license": "MIT", - "peer": true, - "dependencies": { - "ee-first": "1.1.1" - }, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/connect/node_modules/statuses": { - "version": "1.5.0", - "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz", - "integrity": "sha512-OpZ3zP+jT1PI7I8nemJX4AKmAX070ZkYPVWV/AaKTJl+tXCTGyVdC1a4SL8RUQYEwk/f34ZX8UTykN68FwrqAA==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/consolidated-events": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/consolidated-events/-/consolidated-events-2.0.2.tgz", - "integrity": "sha512-2/uRVMdRypf5z/TW/ncD/66l75P5hH2vM/GR8Jf8HLc2xnfJtmina6F6du8+v4Z2vTrMo7jC+W1tmEEuuELgkQ==", - "license": "MIT" - }, - "node_modules/content-disposition": { - "version": "0.5.4", - "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.4.tgz", - "integrity": "sha512-FveZTNuGw04cxlAiWbzi6zTAL/lhehaWbTtgluJh4/E95DqMwTmha3KZN1aAWA8cFIhHzMZUvLevkw5Rqk+tSQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "safe-buffer": "5.2.1" - }, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/content-type": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.5.tgz", - "integrity": "sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/convert-source-map": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", - "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", - "license": "MIT" - }, - "node_modules/cookie": { - "version": "0.7.1", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.7.1.tgz", - "integrity": "sha512-6DnInpx7SJ2AK3+CTUE/ZM0vWTUboZCegxhC2xiIydHR9jNuTAASBrfEpHhiGOZw/nX51bHt6YQl8jsGo4y/0w==", - "dev": true, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/cookie-signature": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.6.tgz", - "integrity": "sha512-QADzlaHc8icV8I7vbaJXJwod9HWYp8uCqf1xa4OfNu1T7JVxQIrUgOWtHdNDtPiywmFbiS12VjotIXLrKM3orQ==", - "dev": true, - "license": "MIT" - }, - "node_modules/copy-dir": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/copy-dir/-/copy-dir-1.3.0.tgz", - "integrity": "sha512-Q4+qBFnN4bwGwvtXXzbp4P/4iNk0MaiGAzvQ8OiMtlLjkIKjmNN689uVzShSM0908q7GoFHXIPx4zi75ocoaHw==", - "dev": true, - "license": "MIT" - }, - "node_modules/copy-webpack-plugin": { - "version": "11.0.0", - "resolved": "https://registry.npmjs.org/copy-webpack-plugin/-/copy-webpack-plugin-11.0.0.tgz", - "integrity": "sha512-fX2MWpamkW0hZxMEg0+mYnA40LTosOSa5TqZ9GYIBzyJa9C3QUaMPSE2xAi/buNr8u89SfD9wHSQVBzrRa/SOQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "fast-glob": "^3.2.11", - "glob-parent": "^6.0.1", - "globby": "^13.1.1", - "normalize-path": "^3.0.0", - "schema-utils": "^4.0.0", - "serialize-javascript": "^6.0.0" - }, - "engines": { - "node": ">= 14.15.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/webpack" - }, - "peerDependencies": { - "webpack": "^5.1.0" - } - }, - "node_modules/copy-webpack-plugin/node_modules/globby": { - "version": "13.2.2", - "resolved": "https://registry.npmjs.org/globby/-/globby-13.2.2.tgz", - "integrity": "sha512-Y1zNGV+pzQdh7H39l9zgB4PJqjRNqydvdYCDG4HFXM4XuvSaQQlEc91IU1yALL8gUTDomgBAfz3XJdmUS+oo0w==", - "dev": true, - "license": "MIT", - "dependencies": { - "dir-glob": "^3.0.1", - "fast-glob": "^3.3.0", - "ignore": "^5.2.4", - "merge2": "^1.4.1", - "slash": "^4.0.0" - }, - "engines": { - "node": "^12.20.0 || ^14.13.1 || >=16.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/copy-webpack-plugin/node_modules/slash": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/slash/-/slash-4.0.0.tgz", - "integrity": "sha512-3dOsAHXXUkQTpOYcoAxLIorMTp4gIQr5IW3iVb7A7lFIp0VHhnynm9izx6TssdrIcVIESAlVjtnO2K8bg+Coew==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/core-js": { - "version": "2.6.12", - "resolved": "https://registry.npmjs.org/core-js/-/core-js-2.6.12.tgz", - "integrity": "sha512-Kb2wC0fvsWfQrgk8HU5lW6U/Lcs8+9aaYcy4ZFc6DDlo4nZ7n70dEgE5rtR0oG6ufKDUnrwfWL1mXR5ljDatrQ==", - "deprecated": "core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js.", - "hasInstallScript": true, - "license": "MIT" - }, - "node_modules/core-js-compat": { - "version": "3.38.1", - "resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.38.1.tgz", - "integrity": "sha512-JRH6gfXxGmrzF3tZ57lFx97YARxCXPaMzPo6jELZhv88pBH5VXpQ+y0znKGlFnzuaihqhLbefxSJxWJMPtfDzw==", - "license": "MIT", - "dependencies": { - "browserslist": "^4.23.3" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/core-js" - } - }, - "node_modules/core-util-is": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", - "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==", - "license": "MIT" - }, - "node_modules/cosmiconfig": { - "version": "8.3.6", - "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-8.3.6.tgz", - "integrity": "sha512-kcZ6+W5QzcJ3P1Mt+83OUv/oHFqZHIx8DuxG6eZ5RGMERoLqp4BuGjhHLYGK+Kf5XVkQvqBSmAy/nGWN3qDgEA==", - "dev": true, - "license": "MIT", - "dependencies": { - "import-fresh": "^3.3.0", - "js-yaml": "^4.1.0", - "parse-json": "^5.2.0", - "path-type": "^4.0.0" - }, - "engines": { - "node": ">=14" - }, - "funding": { - "url": "https://github.com/sponsors/d-fischer" - }, - "peerDependencies": { - "typescript": ">=4.9.5" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } - } - }, - "node_modules/cosmiconfig/node_modules/argparse": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", - "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", - "dev": true, - "license": "Python-2.0" - }, - "node_modules/cosmiconfig/node_modules/js-yaml": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", - "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", - "dev": true, - "license": "MIT", - "dependencies": { - "argparse": "^2.0.1" - }, - "bin": { - "js-yaml": "bin/js-yaml.js" - } - }, - "node_modules/cross-env": { - "version": "7.0.3", - "resolved": "https://registry.npmjs.org/cross-env/-/cross-env-7.0.3.tgz", - "integrity": "sha512-+/HKd6EgcQCJGh2PSjZuUitQBQynKor4wrFbRg4DtAgS1aWO+gU52xpH7M9ScGgXSYmAVS9bIJ8EzuaGw0oNAw==", - "dev": true, - "license": "MIT", - "dependencies": { - "cross-spawn": "^7.0.1" - }, - "bin": { - "cross-env": "src/bin/cross-env.js", - "cross-env-shell": "src/bin/cross-env-shell.js" - }, - "engines": { - "node": ">=10.14", - "npm": ">=6", - "yarn": ">=1" - } - }, - "node_modules/cross-spawn": { - "version": "7.0.6", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.6.tgz", - "integrity": "sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==", - "dependencies": { - "path-key": "^3.1.0", - "shebang-command": "^2.0.0", - "which": "^2.0.1" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/css-color-keywords": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/css-color-keywords/-/css-color-keywords-1.0.0.tgz", - "integrity": "sha512-FyyrDHZKEjXDpNJYvVsV960FiqQyXc/LlYmsxl2BcdMb2WPx0OGRVgTg55rPSyLSNMqP52R9r8geSp7apN3Ofg==", - "license": "ISC", - "engines": { - "node": ">=4" - } - }, - "node_modules/css-functions-list": { - "version": "3.2.3", - "resolved": "https://registry.npmjs.org/css-functions-list/-/css-functions-list-3.2.3.tgz", - "integrity": "sha512-IQOkD3hbR5KrN93MtcYuad6YPuTSUhntLHDuLEbFWE+ff2/XSZNdZG+LcbbIW5AXKg/WFIfYItIzVoHngHXZzA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=12 || >=16" - } - }, - "node_modules/css-loader": { - "version": "7.1.2", - "resolved": "https://registry.npmjs.org/css-loader/-/css-loader-7.1.2.tgz", - "integrity": "sha512-6WvYYn7l/XEGN8Xu2vWFt9nVzrCn39vKyTEFf/ExEyoksJjjSZV/0/35XPlMbpnr6VGhZIUg5yJrL8tGfes/FA==", - "dev": true, - "license": "MIT", - "dependencies": { - "icss-utils": "^5.1.0", - "postcss": "^8.4.33", - "postcss-modules-extract-imports": "^3.1.0", - "postcss-modules-local-by-default": "^4.0.5", - "postcss-modules-scope": "^3.2.0", - "postcss-modules-values": "^4.0.0", - "postcss-value-parser": "^4.2.0", - "semver": "^7.5.4" - }, - "engines": { - "node": ">= 18.12.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/webpack" - }, - "peerDependencies": { - "@rspack/core": "0.x || 1.x", - "webpack": "^5.27.0" - }, - "peerDependenciesMeta": { - "@rspack/core": { - "optional": true - }, - "webpack": { - "optional": true - } - } - }, - "node_modules/css-loader/node_modules/semver": { - "version": "7.6.3", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", - "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", - "dev": true, - "license": "ISC", - "bin": { - "semver": "bin/semver.js" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/css-select": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/css-select/-/css-select-5.1.0.tgz", - "integrity": "sha512-nwoRF1rvRRnnCqqY7updORDsuqKzqYJ28+oSMaJMMgOauh3fvwHqMS7EZpIPqK8GL+g9mKxF1vP/ZjSeNjEVHg==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "boolbase": "^1.0.0", - "css-what": "^6.1.0", - "domhandler": "^5.0.2", - "domutils": "^3.0.1", - "nth-check": "^2.0.1" - }, - "funding": { - "url": "https://github.com/sponsors/fb55" - } - }, - "node_modules/css-to-react-native": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/css-to-react-native/-/css-to-react-native-3.2.0.tgz", - "integrity": "sha512-e8RKaLXMOFii+02mOlqwjbD00KSEKqblnpO9e++1aXS1fPQOpS1YoqdVHBqPjHNoxeF2mimzVqawm2KCbEdtHQ==", - "license": "MIT", - "dependencies": { - "camelize": "^1.0.0", - "css-color-keywords": "^1.0.0", - "postcss-value-parser": "^4.0.2" - } - }, - "node_modules/css-tree": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-2.3.1.tgz", - "integrity": "sha512-6Fv1DV/TYw//QF5IzQdqsNDjx/wc8TrMBZsqjL9eW01tWb7R7k/mq+/VXfJCl7SoD5emsJop9cOByJZfs8hYIw==", - "dev": true, - "license": "MIT", - "dependencies": { - "mdn-data": "2.0.30", - "source-map-js": "^1.0.1" - }, - "engines": { - "node": "^10 || ^12.20.0 || ^14.13.0 || >=15.0.0" - } - }, - "node_modules/css-unicode-loader": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/css-unicode-loader/-/css-unicode-loader-1.0.3.tgz", - "integrity": "sha512-mszxqB0LCBO2ixbaz/tAH17iEAXmytUv0j/YXtPxhOi8D8Teh+mOXqmz+DZRtDil5tFx7ltbgw16dUptEw4jOg==", - "dev": true, - "license": "MIT" - }, - "node_modules/css-what": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/css-what/-/css-what-6.1.0.tgz", - "integrity": "sha512-HTUrgRJ7r4dsZKU6GjmpfRK1O76h97Z8MfS1G0FozR+oF2kG6Vfe8JE6zwrkbxigziPHinCJ+gCPjA9EaBDtRw==", - "dev": true, - "license": "BSD-2-Clause", - "engines": { - "node": ">= 6" - }, - "funding": { - "url": "https://github.com/sponsors/fb55" - } - }, - "node_modules/cssesc": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/cssesc/-/cssesc-3.0.0.tgz", - "integrity": "sha512-/Tb/JcjK111nNScGob5MNtsntNM1aCNUDipB/TkwZFhyDrrE47SOx/18wF2bbjgc3ZzCSKW1T5nt5EbFoAz/Vg==", - "dev": true, - "license": "MIT", - "bin": { - "cssesc": "bin/cssesc" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/csso": { - "version": "5.0.5", - "resolved": "https://registry.npmjs.org/csso/-/csso-5.0.5.tgz", - "integrity": "sha512-0LrrStPOdJj+SPCCrGhzryycLjwcgUSHBtxNA8aIDxf0GLsRh1cKYhB00Gd1lDOS4yGH69+SNn13+TWbVHETFQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "css-tree": "~2.2.0" - }, - "engines": { - "node": "^10 || ^12.20.0 || ^14.13.0 || >=15.0.0", - "npm": ">=7.0.0" - } - }, - "node_modules/csso/node_modules/css-tree": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-2.2.1.tgz", - "integrity": "sha512-OA0mILzGc1kCOCSJerOeqDxDQ4HOh+G8NbOJFOTgOCzpw7fCBubk0fEyxp8AgOL/jvLgYA/uV0cMbe43ElF1JA==", - "dev": true, - "license": "MIT", - "dependencies": { - "mdn-data": "2.0.28", - "source-map-js": "^1.0.1" - }, - "engines": { - "node": "^10 || ^12.20.0 || ^14.13.0 || >=15.0.0", - "npm": ">=7.0.0" - } - }, - "node_modules/csso/node_modules/mdn-data": { - "version": "2.0.28", - "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.28.tgz", - "integrity": "sha512-aylIc7Z9y4yzHYAJNuESG3hfhC+0Ibp/MAMiaOZgNv4pmEdFyfZhhhny4MNiAfWdBQ1RQ2mfDWmM1x8SvGyp8g==", - "dev": true, - "license": "CC0-1.0" - }, - "node_modules/csstype": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.1.3.tgz", - "integrity": "sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==", - "license": "MIT" - }, - "node_modules/cypress": { - "version": "13.14.2", - "resolved": "https://registry.npmjs.org/cypress/-/cypress-13.14.2.tgz", - "integrity": "sha512-lsiQrN17vHMB2fnvxIrKLAjOr9bPwsNbPZNrWf99s4u+DVmCY6U+w7O3GGG9FvP4EUVYaDu+guWeNLiUzBrqvA==", - "dev": true, - "hasInstallScript": true, - "license": "MIT", - "dependencies": { - "@cypress/request": "^3.0.1", - "@cypress/xvfb": "^1.2.4", - "@types/sinonjs__fake-timers": "8.1.1", - "@types/sizzle": "^2.3.2", - "arch": "^2.2.0", - "blob-util": "^2.0.2", - "bluebird": "^3.7.2", - "buffer": "^5.7.1", - "cachedir": "^2.3.0", - "chalk": "^4.1.0", - "check-more-types": "^2.24.0", - "cli-cursor": "^3.1.0", - "cli-table3": "~0.6.1", - "commander": "^6.2.1", - "common-tags": "^1.8.0", - "dayjs": "^1.10.4", - "debug": "^4.3.4", - "enquirer": "^2.3.6", - "eventemitter2": "6.4.7", - "execa": "4.1.0", - "executable": "^4.1.1", - "extract-zip": "2.0.1", - "figures": "^3.2.0", - "fs-extra": "^9.1.0", - "getos": "^3.2.1", - "is-ci": "^3.0.1", - "is-installed-globally": "~0.4.0", - "lazy-ass": "^1.6.0", - "listr2": "^3.8.3", - "lodash": "^4.17.21", - "log-symbols": "^4.0.0", - "minimist": "^1.2.8", - "ospath": "^1.2.2", - "pretty-bytes": "^5.6.0", - "process": "^0.11.10", - "proxy-from-env": "1.0.0", - "request-progress": "^3.0.0", - "semver": "^7.5.3", - "supports-color": "^8.1.1", - "tmp": "~0.2.3", - "untildify": "^4.0.0", - "yauzl": "^2.10.0" - }, - "bin": { - "cypress": "bin/cypress" - }, - "engines": { - "node": "^16.0.0 || ^18.0.0 || >=20.0.0" - } - }, - "node_modules/cypress-axe": { - "version": "1.5.0", - "resolved": "https://registry.npmjs.org/cypress-axe/-/cypress-axe-1.5.0.tgz", - "integrity": "sha512-Hy/owCjfj+25KMsecvDgo4fC/781ccL+e8p+UUYoadGVM2ogZF9XIKbiM6KI8Y3cEaSreymdD6ZzccbI2bY0lQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=10" - }, - "peerDependencies": { - "axe-core": "^3 || ^4", - "cypress": "^10 || ^11 || ^12 || ^13" - } - }, - "node_modules/cypress-html-validate": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/cypress-html-validate/-/cypress-html-validate-6.1.0.tgz", - "integrity": "sha512-IXVB1ZzdSHMzPM/QYZCXlG3yW2CdvSVY7bJtlijmk4kCRepfdHe0JLQ939h2Dj9ZsjyBockPQpun4omq1uRW6Q==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 16" - }, - "peerDependencies": { - "cypress": "^10 || ^11.0.1 || ^12 || ^13", - "html-validate": "^5 || ^6 || ^7 || ^8" - } - }, - "node_modules/cypress-xpath": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/cypress-xpath/-/cypress-xpath-2.0.1.tgz", - "integrity": "sha512-qMagjvinBppNJdMAkucWESP9aP4rDTs7c96m0vwMuZTVx3NqP2E3z/hkoRf8Ea9soL8yTvUuuyF1cg/Sb1Yhbg==", - "deprecated": "Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.", + "node_modules/balanced-match": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", "dev": true, "license": "MIT" }, - "node_modules/cypress/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "license": "MIT", - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/cypress/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "license": "MIT", - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/cypress/node_modules/chalk/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "license": "MIT", - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/cypress/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/cypress/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true, + "node_modules/base64-js": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", + "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], "license": "MIT" }, - "node_modules/cypress/node_modules/extract-zip": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/extract-zip/-/extract-zip-2.0.1.tgz", - "integrity": "sha512-GDhU9ntwuKyGXdZBUgTIe+vXnWj0fppUEtMDL0+idd5Sta8TGpHssn/eusA9mrPr9qNDym6SxAYZjNvCn/9RBg==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "debug": "^4.1.1", - "get-stream": "^5.1.0", - "yauzl": "^2.10.0" - }, - "bin": { - "extract-zip": "cli.js" - }, - "engines": { - "node": ">= 10.17.0" - }, - "optionalDependencies": { - "@types/yauzl": "^2.9.1" - } - }, - "node_modules/cypress/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/cypress/node_modules/semver": { - "version": "7.6.3", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", - "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", - "dev": true, - "license": "ISC", - "bin": { - "semver": "bin/semver.js" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/cypress/node_modules/supports-color": { - "version": "8.1.1", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", - "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", - "dev": true, - "license": "MIT", - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/supports-color?sponsor=1" - } - }, - "node_modules/damerau-levenshtein": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/damerau-levenshtein/-/damerau-levenshtein-1.0.8.tgz", - "integrity": "sha512-sdQSFB7+llfUcQHUQO3+B8ERRj0Oa4w9POWMI/puGtuf7gFywGmkaLCElnudfTiKZV+NvHqL0ifzdrI8Ro7ESA==", + "node_modules/batch": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/batch/-/batch-0.6.1.tgz", + "integrity": "sha512-x+VAiMRL6UPkx+kudNvxTl6hB2XNNCG2r+7wixVfIYwu/2HKRXimwQyaumLjMveWvT2Hkd/cAJw+QBMfJ/EKVw==", "dev": true, - "license": "BSD-2-Clause" + "license": "MIT" }, - "node_modules/dashdash": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz", - "integrity": "sha512-jRFi8UDGo6j+odZiEpjazZaWqEal3w/basFjQHQEwVtZJGDpxbH1MeYluwCS8Xq5wmLJooDlMgvVarmWfGM44g==", + "node_modules/bcrypt-pbkdf": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz", + "integrity": "sha512-qeFIXtP4MSoi6NLqO12WfqARWWuCKi2Rn/9hJLEmtB5yTNr9DqFWkJRCf2qShWzPeAMRnOgCrq0sg/KLv5ES9w==", "dev": true, - "license": "MIT", - "dependencies": { - "assert-plus": "^1.0.0" - }, - "engines": { - "node": ">=0.10" - } - }, - "node_modules/data-view-buffer": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/data-view-buffer/-/data-view-buffer-1.0.1.tgz", - "integrity": "sha512-0lht7OugA5x3iJLOWFhWK/5ehONdprk0ISXqVFn/NFrDu+cuc8iADFrGQz5BnRK7LLU3JmkbXSxaqX+/mXYtUA==", - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.6", - "es-errors": "^1.3.0", - "is-data-view": "^1.0.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/data-view-byte-length": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/data-view-byte-length/-/data-view-byte-length-1.0.1.tgz", - "integrity": "sha512-4J7wRJD3ABAzr8wP+OcIcqq2dlUKp4DVflx++hs5h5ZKydWMI6/D/fAot+yh6g2tHh8fLFTvNOaVN357NvSrOQ==", - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.7", - "es-errors": "^1.3.0", - "is-data-view": "^1.0.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "license": "BSD-3-Clause", + "dependencies": { + "tweetnacl": "^0.14.3" } }, - "node_modules/data-view-byte-offset": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/data-view-byte-offset/-/data-view-byte-offset-1.0.0.tgz", - "integrity": "sha512-t/Ygsytq+R995EJ5PZlD4Cu56sWa8InXySaViRzw9apusqsOO2bQP+SbYzAhR0pFKoB+43lYy8rWban9JSuXnA==", + "node_modules/binary-extensions": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.3.0.tgz", + "integrity": "sha512-Ceh+7ox5qe7LJuLHoY0feh3pHuUDHAcRUeyL2VYghZwfpkNIy/+8Ocg0a3UuSoYzavmylwuLWQOf3hl0jjMMIw==", + "dev": true, "license": "MIT", - "dependencies": { - "call-bind": "^1.0.6", - "es-errors": "^1.3.0", - "is-data-view": "^1.0.1" - }, "engines": { - "node": ">= 0.4" + "node": ">=8" }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/dayjs": { - "version": "1.11.13", - "resolved": "https://registry.npmjs.org/dayjs/-/dayjs-1.11.13.tgz", - "integrity": "sha512-oaMBel6gjolK862uaPQOVTA7q3TZhuSvuMQAAglQDOWYO9A91IrAOUJEyKVlqJlHE0vq5p5UXxzdPfMH/x6xNg==", + "node_modules/blob-util": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/blob-util/-/blob-util-2.0.2.tgz", + "integrity": "sha512-T7JQa+zsXXEa6/8ZhHcQEW1UFfVM49Ts65uBkFL6fz2QmrElqmbajIDJvuA0tEhRe5eIjpV9ZF+0RfZR9voJFQ==", + "dev": true, + "license": "Apache-2.0" + }, + "node_modules/bluebird": { + "version": "3.7.2", + "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.7.2.tgz", + "integrity": "sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==", + "dev": true, "license": "MIT" }, - "node_modules/debug": { - "version": "4.3.7", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.7.tgz", - "integrity": "sha512-Er2nc/H7RrMXZBFCEim6TCmMk02Z8vLC2Rbi1KEBggpo0fS6l0S1nnapwmIi3yW/+GOJap1Krg4w0Hg80oCqgQ==", + "node_modules/body-parser": { + "version": "1.20.3", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.3.tgz", + "integrity": "sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==", + "dev": true, "license": "MIT", "dependencies": { - "ms": "^2.1.3" + "bytes": "3.1.2", + "content-type": "~1.0.5", + "debug": "2.6.9", + "depd": "2.0.0", + "destroy": "1.2.0", + "http-errors": "2.0.0", + "iconv-lite": "0.4.24", + "on-finished": "2.4.1", + "qs": "6.13.0", + "raw-body": "2.5.2", + "type-is": "~1.6.18", + "unpipe": "1.0.0" }, "engines": { - "node": ">=6.0" - }, - "peerDependenciesMeta": { - "supports-color": { - "optional": true - } + "node": ">= 0.8", + "npm": "1.2.8000 || >= 1.4.16" } }, - "node_modules/decamelize": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", - "integrity": "sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==", + "node_modules/body-parser/node_modules/bytes": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.2.tgz", + "integrity": "sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==", + "dev": true, "license": "MIT", - "peer": true, "engines": { - "node": ">=0.10.0" + "node": ">= 0.8" } }, - "node_modules/decompress-response": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/decompress-response/-/decompress-response-6.0.0.tgz", - "integrity": "sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==", + "node_modules/body-parser/node_modules/debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", "dev": true, "license": "MIT", "dependencies": { - "mimic-response": "^3.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "ms": "2.0.0" } }, - "node_modules/decompress-response/node_modules/mimic-response": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-3.1.0.tgz", - "integrity": "sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==", + "node_modules/body-parser/node_modules/iconv-lite": { + "version": "0.4.24", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", + "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", "dev": true, "license": "MIT", - "engines": { - "node": ">=10" + "dependencies": { + "safer-buffer": ">= 2.1.2 < 3" }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "engines": { + "node": ">=0.10.0" } }, - "node_modules/deep-equal": { - "version": "2.2.3", - "resolved": "https://registry.npmjs.org/deep-equal/-/deep-equal-2.2.3.tgz", - "integrity": "sha512-ZIwpnevOurS8bpT4192sqAowWM76JDKSHYzMLty3BZGSswgq6pBaH3DhCSW5xVAZICZyKdOBPjwww5wfgT/6PA==", + "node_modules/body-parser/node_modules/ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", + "dev": true, + "license": "MIT" + }, + "node_modules/bonjour-service": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/bonjour-service/-/bonjour-service-1.2.1.tgz", + "integrity": "sha512-oSzCS2zV14bh2kji6vNe7vrpJYCHGvcZnlffFQ1MEoX/WOeQ/teD8SYWKR942OI3INjq8OMNJlbPK5LLLUxFDw==", "dev": true, "license": "MIT", "dependencies": { - "array-buffer-byte-length": "^1.0.0", - "call-bind": "^1.0.5", - "es-get-iterator": "^1.1.3", - "get-intrinsic": "^1.2.2", - "is-arguments": "^1.1.1", - "is-array-buffer": "^3.0.2", - "is-date-object": "^1.0.5", - "is-regex": "^1.1.4", - "is-shared-array-buffer": "^1.0.2", - "isarray": "^2.0.5", - "object-is": "^1.1.5", - "object-keys": "^1.1.1", - "object.assign": "^4.1.4", - "regexp.prototype.flags": "^1.5.1", - "side-channel": "^1.0.4", - "which-boxed-primitive": "^1.0.2", - "which-collection": "^1.0.1", - "which-typed-array": "^1.1.13" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "fast-deep-equal": "^3.1.3", + "multicast-dns": "^7.2.5" } }, - "node_modules/deep-is": { - "version": "0.1.4", - "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz", - "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==", + "node_modules/boolbase": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/boolbase/-/boolbase-1.0.0.tgz", + "integrity": "sha512-JZOSA7Mo9sNGB8+UjSgzdLtokWAky1zbztM3WRLCbZ70/3cTANmQmOdR7y2g+J0e2WXywy1yS468tY+IruqEww==", "dev": true, - "license": "MIT" + "license": "ISC" }, - "node_modules/deepmerge": { - "version": "4.3.1", - "resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-4.3.1.tgz", - "integrity": "sha512-3sUqbMEc77XqpdNO7FRyRog+eW3ph+GYCbj+rK+uYyRMuwsVy0rMiVtPn+QJlKFvWP/1PYpapqYn0Me2knFn+A==", + "node_modules/brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, "license": "MIT", - "engines": { - "node": ">=0.10.0" + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" } }, - "node_modules/default-gateway": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/default-gateway/-/default-gateway-6.0.3.tgz", - "integrity": "sha512-fwSOJsbbNzZ/CUFpqFBqYfYNLj1NbMPm8MMCIzHjC83iSJRBEGmDUxU+WP661BaBQImeC2yHwXtz+P/O9o+XEg==", + "node_modules/braces": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", + "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", "dev": true, - "license": "BSD-2-Clause", + "license": "MIT", "dependencies": { - "execa": "^5.0.0" + "fill-range": "^7.1.1" }, "engines": { - "node": ">= 10" + "node": ">=8" } }, - "node_modules/default-gateway/node_modules/execa": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", - "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", + "node_modules/brcast": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/brcast/-/brcast-2.0.2.tgz", + "integrity": "sha512-Tfn5JSE7hrUlFcOoaLzVvkbgIemIorMIyoMr3TgvszWW7jFt2C9PdeMLtysYD9RU0MmU17b69+XJG1eRY2OBRg==", + "license": "MIT" + }, + "node_modules/browserslist": { + "version": "4.24.4", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.24.4.tgz", + "integrity": "sha512-KDi1Ny1gSePi1vm0q4oxSF8b4DR44GF4BbmS2YdhPLOEqd8pDviZOGH/GsmRwoWJ2+5Lr085X7naowMwKHDG1A==", "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], "license": "MIT", "dependencies": { - "cross-spawn": "^7.0.3", - "get-stream": "^6.0.0", - "human-signals": "^2.1.0", - "is-stream": "^2.0.0", - "merge-stream": "^2.0.0", - "npm-run-path": "^4.0.1", - "onetime": "^5.1.2", - "signal-exit": "^3.0.3", - "strip-final-newline": "^2.0.0" + "caniuse-lite": "^1.0.30001688", + "electron-to-chromium": "^1.5.73", + "node-releases": "^2.0.19", + "update-browserslist-db": "^1.1.1" + }, + "bin": { + "browserslist": "cli.js" }, "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sindresorhus/execa?sponsor=1" + "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7" + } + }, + "node_modules/buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT", + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, + "node_modules/buffer-crc32": { + "version": "0.2.13", + "resolved": "https://registry.npmjs.org/buffer-crc32/-/buffer-crc32-0.2.13.tgz", + "integrity": "sha512-VO9Ht/+p3SN7SKWqcrgEzjGbRSJYTx+Q1pTQC0wrWqHx0vpJraQ6GtHx8tvcg1rlK1byhU5gccxgOgj7B0TDkQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": "*" } }, - "node_modules/default-gateway/node_modules/get-stream": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", - "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", + "node_modules/buffer-from": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", + "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/builtin-modules": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/builtin-modules/-/builtin-modules-3.3.0.tgz", + "integrity": "sha512-zhaCDicdLuWN5UbN5IMnFqNMhNfo919sH85y2/ea+5Yg9TsTkeZxpL+JLbp6cgYFS4sRLp3YV4S6yDuqVWHYOw==", "dev": true, "license": "MIT", "engines": { - "node": ">=10" + "node": ">=6" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/default-gateway/node_modules/human-signals": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", - "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", + "node_modules/bytes": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.0.0.tgz", + "integrity": "sha512-pMhOfFDPiv9t5jjIXkHosWmkSyQbvsgEVNkz0ERHbuLh2T/7j4Mqqpz523Fe8MVY89KC6Sh/QfS2sM+SjgFDcw==", "dev": true, - "license": "Apache-2.0", + "license": "MIT", "engines": { - "node": ">=10.17.0" + "node": ">= 0.8" } }, - "node_modules/defaults": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/defaults/-/defaults-1.0.4.tgz", - "integrity": "sha512-eFuaLoy/Rxalv2kr+lqMlUnrDWV+3j4pljOIJgLIhI058IQfWJ7vXhyEIHu+HtC738klGALYxOKDO0bQP3tg8A==", + "node_modules/cacheable": { + "version": "1.8.10", + "resolved": "https://registry.npmjs.org/cacheable/-/cacheable-1.8.10.tgz", + "integrity": "sha512-0ZnbicB/N2R6uziva8l6O6BieBklArWyiGx4GkwAhLKhSHyQtRfM9T1nx7HHuHDKkYB/efJQhz3QJ6x/YqoZzA==", + "dev": true, "license": "MIT", "dependencies": { - "clone": "^1.0.2" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "hookified": "^1.8.1", + "keyv": "^5.3.2" } }, - "node_modules/defaults/node_modules/clone": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/clone/-/clone-1.0.4.tgz", - "integrity": "sha512-JQHZ2QMW6l3aH/j6xCqQThY/9OH4D/9ls34cgkUBiEeocRTU04tHfKPBsUK1PqZCUQM7GiA0IIXJSuXHI64Kbg==", + "node_modules/cacheable-lookup": { + "version": "5.0.4", + "resolved": "https://registry.npmjs.org/cacheable-lookup/-/cacheable-lookup-5.0.4.tgz", + "integrity": "sha512-2/kNscPhpcxrOigMZzbiWF7dz8ilhb/nIHU3EyZiXWXpeq/au8qJ8VhdftMkty3n7Gj6HIGalQG8oiBNB3AJgA==", + "dev": true, "license": "MIT", "engines": { - "node": ">=0.8" + "node": ">=10.6.0" } }, - "node_modules/defer-to-connect": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/defer-to-connect/-/defer-to-connect-2.0.1.tgz", - "integrity": "sha512-4tvttepXG1VaYGrRibk5EwJd1t4udunSOVMdLSAL6mId1ix438oPwPZMALY41FCijukO1L0twNcGsdzS7dHgDg==", + "node_modules/cacheable-request": { + "version": "7.0.4", + "resolved": "https://registry.npmjs.org/cacheable-request/-/cacheable-request-7.0.4.tgz", + "integrity": "sha512-v+p6ongsrp0yTGbJXjgxPow2+DL93DASP4kXCDKb8/bwRtt9OEF3whggkkDkGNzgcWy2XaF4a8nZglC7uElscg==", "dev": true, "license": "MIT", + "dependencies": { + "clone-response": "^1.0.2", + "get-stream": "^5.1.0", + "http-cache-semantics": "^4.0.0", + "keyv": "^4.0.0", + "lowercase-keys": "^2.0.0", + "normalize-url": "^6.0.1", + "responselike": "^2.0.0" + }, "engines": { - "node": ">=10" + "node": ">=8" } }, - "node_modules/define-data-property": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.4.tgz", - "integrity": "sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==", + "node_modules/cacheable/node_modules/keyv": { + "version": "5.3.3", + "resolved": "https://registry.npmjs.org/keyv/-/keyv-5.3.3.tgz", + "integrity": "sha512-Rwu4+nXI9fqcxiEHtbkvoes2X+QfkTRo1TMkPfwzipGsJlJO/z69vqB4FNl9xJ3xCpAcbkvmEabZfPzrwN3+gQ==", + "dev": true, "license": "MIT", "dependencies": { - "es-define-property": "^1.0.0", - "es-errors": "^1.3.0", - "gopd": "^1.0.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "@keyv/serialize": "^1.0.3" } }, - "node_modules/define-lazy-prop": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/define-lazy-prop/-/define-lazy-prop-2.0.0.tgz", - "integrity": "sha512-Ds09qNh8yw3khSjiJjiUInaGX9xlqZDY7JVryGxdxV7NPeuqQfplOpQ66yJFZut3jLa5zOwkXw1g9EI2uKh4Og==", + "node_modules/cachedir": { + "version": "2.4.0", + "resolved": "https://registry.npmjs.org/cachedir/-/cachedir-2.4.0.tgz", + "integrity": "sha512-9EtFOZR8g22CL7BWjJ9BUx1+A/djkofnyW3aOXZORNW2kxoUpx2h+uN2cOqwPmFhnpVmxg+KW2OjOSgChTEvsQ==", "dev": true, "license": "MIT", "engines": { - "node": ">=8" + "node": ">=6" } }, - "node_modules/define-properties": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.1.tgz", - "integrity": "sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==", + "node_modules/call-bind": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.7.tgz", + "integrity": "sha512-GHTSNSYICQ7scH7sZ+M2rFopRoLh8t2bLSW6BbgrtLsahOIB5iyAVJf9GjWK3cYTDaMj4XdBpM1cA6pIS0Kv2w==", "license": "MIT", "dependencies": { - "define-data-property": "^1.0.1", - "has-property-descriptors": "^1.0.0", - "object-keys": "^1.1.1" + "es-define-property": "^1.0.0", + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "get-intrinsic": "^1.2.4", + "set-function-length": "^1.2.1" }, "engines": { "node": ">= 0.4" @@ -10629,822 +6364,822 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/delayed-stream": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", - "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", + "node_modules/callsites": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", + "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==", "dev": true, "license": "MIT", "engines": { - "node": ">=0.4.0" + "node": ">=6" } }, - "node_modules/delegate": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/delegate/-/delegate-3.2.0.tgz", - "integrity": "sha512-IofjkYBZaZivn0V8nnsMJGBr4jVLxHDheKSW88PyxS5QC4Vo9ZbZVvhzlSxY87fVq3STR6r+4cGepyHkcWOQSw==", - "license": "MIT" - }, - "node_modules/denodeify": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/denodeify/-/denodeify-1.2.1.tgz", - "integrity": "sha512-KNTihKNmQENUZeKu5fzfpzRqR5S2VMp4gl9RFHiWzj9DfvYQPMJ6XHKNaQxaGCXwPk6y9yme3aUoaiAe+KX+vg==", - "license": "MIT", - "peer": true - }, - "node_modules/depd": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", - "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==", + "node_modules/camelcase": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", + "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", + "dev": true, "license": "MIT", "engines": { - "node": ">= 0.8" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/destroy": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/destroy/-/destroy-1.2.0.tgz", - "integrity": "sha512-2sJGJTaXIIaR1w4iJSNoN0hnMY7Gpc/n8D4qSCJw8QqFWXf7cuAgnEHxBpweaVcPevC2l3KpjYCx3NypQQgaJg==", + "node_modules/camelize": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/camelize/-/camelize-1.0.1.tgz", + "integrity": "sha512-dU+Tx2fsypxTgtLoE36npi3UqcjSSMNYfkqgmoEhtZrraP5VWq0K7FkWVTYa8eMPtnU/G2txVsfdCJTn9uzpuQ==", "license": "MIT", - "engines": { - "node": ">= 0.8", - "npm": "1.2.8000 || >= 1.4.16" + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/detect-libc": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-1.0.3.tgz", - "integrity": "sha512-pGjwhsmsp4kL2RTz08wcOlGN83otlqHeD/Z5T8GXZB+/YcpQ/dgo+lbU8ZsGxV0HIvqqxo9l7mqYwyYMD9bKDg==", + "node_modules/caniuse-lite": { + "version": "1.0.30001715", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001715.tgz", + "integrity": "sha512-7ptkFGMm2OAOgvZpwgA4yjQ5SQbrNVGdRjzH0pBdy1Fasvcr+KAeECmbCAECzTuDuoX0FCY8KzUxjf9+9kfZEw==", "dev": true, - "license": "Apache-2.0", - "optional": true, - "bin": { - "detect-libc": "bin/detect-libc.js" - }, - "engines": { - "node": ">=0.10" - } + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/caniuse-lite" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "CC-BY-4.0" }, - "node_modules/detect-node": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/detect-node/-/detect-node-2.1.0.tgz", - "integrity": "sha512-T0NIuQpnTvFDATNuHN5roPwSBG83rFsuO+MXXH9/3N1eFbn4wcPjttvjMLEPWJ0RGUYgQE7cGgS3tNxbqCGM7g==", + "node_modules/caseless": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz", + "integrity": "sha512-4tYFyifaFfGacoiObjJegolkwSU4xQNGbVgUiNYVUxbQ2x2lUsFvY4hVgVzGiIe6WLOPqycWXA40l+PWsxthUw==", "dev": true, - "license": "MIT" - }, - "node_modules/diff": { - "version": "3.5.0", - "resolved": "https://registry.npmjs.org/diff/-/diff-3.5.0.tgz", - "integrity": "sha512-A46qtFgd+g7pDZinpnwiRJtxbC1hpgf0uzP3iG89scHk0AUC7A1TGxf5OiiOUv/JMZR8GOt8hL900hV0bOy5xA==", - "license": "BSD-3-Clause", - "engines": { - "node": ">=0.3.1" - } + "license": "Apache-2.0" }, - "node_modules/dir-glob": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/dir-glob/-/dir-glob-3.0.1.tgz", - "integrity": "sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==", + "node_modules/chardet": { + "version": "0.7.0", + "resolved": "https://registry.npmjs.org/chardet/-/chardet-0.7.0.tgz", + "integrity": "sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==", "dev": true, - "license": "MIT", - "dependencies": { - "path-type": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/direction": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/direction/-/direction-1.0.4.tgz", - "integrity": "sha512-GYqKi1aH7PJXxdhTeZBFrg8vUBeKXi+cNprXsC1kpJcbcVnV9wBsrOu1cQEdG0WeQwlfHiy3XvnKfIrJ2R0NzQ==", - "license": "MIT", - "bin": { - "direction": "cli.js" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } + "license": "MIT" }, - "node_modules/dns-packet": { - "version": "5.6.1", - "resolved": "https://registry.npmjs.org/dns-packet/-/dns-packet-5.6.1.tgz", - "integrity": "sha512-l4gcSouhcgIKRvyy99RNVOgxXiicE+2jZoNmaNmZ6JXiGajBOJAesk1OBlJuM5k2c+eudGdLxDqXuPCKIj6kpw==", + "node_modules/check-more-types": { + "version": "2.24.0", + "resolved": "https://registry.npmjs.org/check-more-types/-/check-more-types-2.24.0.tgz", + "integrity": "sha512-Pj779qHxV2tuapviy1bSZNEL1maXr13bPYpsvSDB68HlYcYuhlDrmGd63i0JHMCLKzc7rUSNIrpdJlhVlNwrxA==", "dev": true, "license": "MIT", - "dependencies": { - "@leichtgewicht/ip-codec": "^2.0.1" - }, "engines": { - "node": ">=6" + "node": ">= 0.8.0" } }, - "node_modules/docker-compose": { - "version": "0.24.8", - "resolved": "https://registry.npmjs.org/docker-compose/-/docker-compose-0.24.8.tgz", - "integrity": "sha512-plizRs/Vf15H+GCVxq2EUvyPK7ei9b/cVesHvjnX4xaXjM9spHe2Ytq0BitndFgvTJ3E3NljPNUEl7BAN43iZw==", + "node_modules/chokidar": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.6.0.tgz", + "integrity": "sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw==", "dev": true, "license": "MIT", "dependencies": { - "yaml": "^2.2.2" + "anymatch": "~3.1.2", + "braces": "~3.0.2", + "glob-parent": "~5.1.2", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.6.0" }, "engines": { - "node": ">= 6.0.0" + "node": ">= 8.10.0" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + }, + "optionalDependencies": { + "fsevents": "~2.3.2" } }, - "node_modules/doctrine": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", - "integrity": "sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==", + "node_modules/chokidar/node_modules/glob-parent": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", + "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", "dev": true, - "license": "Apache-2.0", + "license": "ISC", "dependencies": { - "esutils": "^2.0.2" + "is-glob": "^4.0.1" }, "engines": { - "node": ">=6.0.0" - } - }, - "node_modules/document.contains": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/document.contains/-/document.contains-1.0.2.tgz", - "integrity": "sha512-YcvYFs15mX8m3AO1QNQy3BlIpSMfNRj3Ujk2BEJxsZG+HZf7/hZ6jr7mDpXrF8q+ff95Vef5yjhiZxm8CGJr6Q==", - "license": "MIT", - "dependencies": { - "define-properties": "^1.1.3" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "node": ">= 6" } }, - "node_modules/dom-scroll-into-view": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/dom-scroll-into-view/-/dom-scroll-into-view-1.2.1.tgz", - "integrity": "sha512-LwNVg3GJOprWDO+QhLL1Z9MMgWe/KAFLxVWKzjRTxNSPn8/LLDIfmuG71YHznXCqaqTjvHJDYO1MEAgX6XCNbQ==", - "license": "MIT" - }, - "node_modules/dom-serializer": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-2.0.0.tgz", - "integrity": "sha512-wIkAryiqt/nV5EQKqQpo3SToSOV9J0DnbJqwK7Wv/Trc92zIAYZ4FlMu+JPFW1DfGFt81ZTCGgDEabffXeLyJg==", + "node_modules/chrome-trace-event": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/chrome-trace-event/-/chrome-trace-event-1.0.4.tgz", + "integrity": "sha512-rNjApaLzuwaOTjCiT8lSDdGN1APCiqkChLMJxJPWLunPAt5fy8xgU9/jNOchV84wfIxrA0lRQB7oCT8jrn/wrQ==", "dev": true, "license": "MIT", - "dependencies": { - "domelementtype": "^2.3.0", - "domhandler": "^5.0.2", - "entities": "^4.2.0" - }, - "funding": { - "url": "https://github.com/cheeriojs/dom-serializer?sponsor=1" + "engines": { + "node": ">=6.0" } }, - "node_modules/domelementtype": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.3.0.tgz", - "integrity": "sha512-OLETBj6w0OsagBwdXnPdN0cnMfF9opN69co+7ZrbfPGrdpPVNBUj02spi6B1N7wChLQiPn4CSH/zJvXw56gmHw==", + "node_modules/ci-info": { + "version": "3.9.0", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-3.9.0.tgz", + "integrity": "sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==", "dev": true, "funding": [ { "type": "github", - "url": "https://github.com/sponsors/fb55" + "url": "https://github.com/sponsors/sibiraj-s" } ], - "license": "BSD-2-Clause" + "license": "MIT", + "engines": { + "node": ">=8" + } }, - "node_modules/domhandler": { - "version": "5.0.3", - "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-5.0.3.tgz", - "integrity": "sha512-cgwlv/1iFQiFnU96XXgROh8xTeetsnJiDsTc7TYCLFd9+/WNkIqPTxiM/8pSd8VIrhXGTf1Ny1q1hquVqDJB5w==", + "node_modules/classnames": { + "version": "2.5.1", + "resolved": "https://registry.npmjs.org/classnames/-/classnames-2.5.1.tgz", + "integrity": "sha512-saHYOzhIQs6wy2sVxTM6bUDsQO4F50V9RQ22qBpEdCW+I+/Wmke2HOl6lS6dTpdxVhb88/I6+Hs+438c3lfUow==", + "license": "MIT" + }, + "node_modules/clean-stack": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/clean-stack/-/clean-stack-2.2.0.tgz", + "integrity": "sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==", "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "domelementtype": "^2.3.0" - }, + "license": "MIT", "engines": { - "node": ">= 4" - }, - "funding": { - "url": "https://github.com/fb55/domhandler?sponsor=1" + "node": ">=6" } }, - "node_modules/domutils": { + "node_modules/cli-cursor": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/domutils/-/domutils-3.1.0.tgz", - "integrity": "sha512-H78uMmQtI2AhgDJjWeQmHwJJ2bLPD3GMmO7Zja/ZZh84wkm+4ut+IUnUdRa8uCGX88DiVx1j6FRe1XfxEgjEZA==", + "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-3.1.0.tgz", + "integrity": "sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw==", "dev": true, - "license": "BSD-2-Clause", + "license": "MIT", "dependencies": { - "dom-serializer": "^2.0.0", - "domelementtype": "^2.3.0", - "domhandler": "^5.0.3" + "restore-cursor": "^3.1.0" }, - "funding": { - "url": "https://github.com/fb55/domutils?sponsor=1" + "engines": { + "node": ">=8" } }, - "node_modules/dot-case": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/dot-case/-/dot-case-3.0.4.tgz", - "integrity": "sha512-Kv5nKlh6yRrdrGvxeJ2e5y2eRUpkUosIW4A2AS38zwSz27zu7ufDwQPi5Jhs3XAlGNetl3bmnGhQsMtkKJnj3w==", + "node_modules/cli-spinners": { + "version": "2.9.2", + "resolved": "https://registry.npmjs.org/cli-spinners/-/cli-spinners-2.9.2.tgz", + "integrity": "sha512-ywqV+5MmyL4E7ybXgKys4DugZbX0FC6LnwrhjuykIjnK9k8OQacQ7axGKnjDXWNhns0xot3bZI5h55H8yo9cJg==", "dev": true, "license": "MIT", - "dependencies": { - "no-case": "^3.0.4", - "tslib": "^2.0.3" + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/dot-case/node_modules/tslib": { - "version": "2.7.0", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.7.0.tgz", - "integrity": "sha512-gLXCKdN1/j47AiHiOkJN69hJmcbGTHI0ImLmbYLHykhgeN0jVGola9yVjFgzCUklsZQMW55o+dW7IXv3RCXDzA==", - "dev": true, - "license": "0BSD" - }, - "node_modules/eastasianwidth": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/eastasianwidth/-/eastasianwidth-0.2.0.tgz", - "integrity": "sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==", + "node_modules/cli-table3": { + "version": "0.6.5", + "resolved": "https://registry.npmjs.org/cli-table3/-/cli-table3-0.6.5.tgz", + "integrity": "sha512-+W/5efTR7y5HRD7gACw9yQjqMVvEMLBHmboM/kPWam+H+Hmyrgjh6YncVKK122YZkXrLudzTuAukUw9FnMf7IQ==", "dev": true, - "license": "MIT" + "license": "MIT", + "dependencies": { + "string-width": "^4.2.0" + }, + "engines": { + "node": "10.* || >= 12.*" + }, + "optionalDependencies": { + "@colors/colors": "1.5.0" + } }, - "node_modules/ecc-jsbn": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz", - "integrity": "sha512-eh9O+hwRHNbG4BLTjEl3nw044CkGm5X6LoaCf7LPp7UU8Qrt47JYNi6nPX8xjW97TKGKm1ouctg0QSpZe9qrnw==", + "node_modules/cli-truncate": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/cli-truncate/-/cli-truncate-2.1.0.tgz", + "integrity": "sha512-n8fOixwDD6b/ObinzTrp1ZKFzbgvKZvuz/TvejnLn1aQfC6r52XEx85FmuC+3HI+JM7coBRXUvNqEU2PHVrHpg==", "dev": true, "license": "MIT", "dependencies": { - "jsbn": "~0.1.0", - "safer-buffer": "^2.1.0" + "slice-ansi": "^3.0.0", + "string-width": "^4.2.0" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/ee-first": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", - "integrity": "sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==", - "license": "MIT" - }, - "node_modules/electron-to-chromium": { - "version": "1.5.141", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.141.tgz", - "integrity": "sha512-qS+qH9oqVYc1ooubTiB9l904WVyM6qNYxtOEEGReoZXw3xlqeYdFr5GclNzbkAufWgwWLEPoDi3d9MoRwwIjGw==", - "license": "ISC" - }, - "node_modules/emoji-regex": { - "version": "9.2.2", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-9.2.2.tgz", - "integrity": "sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==", + "node_modules/cli-width": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/cli-width/-/cli-width-3.0.0.tgz", + "integrity": "sha512-FxqpkPPwu1HjuN93Omfm4h8uIanXofW0RxVEW3k5RKx+mJJYSthzNhp32Kzxxy3YAEZ/Dc/EWN1vZRY0+kOhbw==", "dev": true, - "license": "MIT" - }, - "node_modules/encodeurl": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.0.tgz", - "integrity": "sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==", - "license": "MIT", + "license": "ISC", "engines": { - "node": ">= 0.8" + "node": ">= 10" } }, - "node_modules/encoding": { - "version": "0.1.13", - "resolved": "https://registry.npmjs.org/encoding/-/encoding-0.1.13.tgz", - "integrity": "sha512-ETBauow1T35Y/WZMkio9jiM0Z5xjHHmJ4XmjZOq1l/dXz3lr2sRn87nJy20RupqSh1F2m3HHPSp8ShIPQJrJ3A==", + "node_modules/clipboard": { + "version": "2.0.11", + "resolved": "https://registry.npmjs.org/clipboard/-/clipboard-2.0.11.tgz", + "integrity": "sha512-C+0bbOqkezLIsmWSvlsXS0Q0bmkugu7jcfMIACB+RDEntIzQIkdr148we28AfSloQLRdZlYL/QYyrq05j/3Faw==", "license": "MIT", "dependencies": { - "iconv-lite": "^0.6.2" + "good-listener": "^1.2.2", + "select": "^1.1.2", + "tiny-emitter": "^2.0.0" + } + }, + "node_modules/cliui": { + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", + "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==", + "dev": true, + "license": "ISC", + "dependencies": { + "string-width": "^4.2.0", + "strip-ansi": "^6.0.1", + "wrap-ansi": "^7.0.0" + }, + "engines": { + "node": ">=12" } }, - "node_modules/end-of-stream": { - "version": "1.4.4", - "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz", - "integrity": "sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==", + "node_modules/cliui/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, "license": "MIT", "dependencies": { - "once": "^1.4.0" + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/enhanced-resolve": { - "version": "0.9.1", - "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-0.9.1.tgz", - "integrity": "sha512-kxpoMgrdtkXZ5h0SeraBS1iRntpTpQ3R8ussdb38+UAFnMGX5DDyJXePm+OCHOcoXvHDw7mc2erbJBpDnl7TPw==", + "node_modules/cliui/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { - "graceful-fs": "^4.1.2", - "memory-fs": "^0.2.0", - "tapable": "^0.1.8" + "color-name": "~1.1.4" }, "engines": { - "node": ">=0.6" + "node": ">=7.0.0" } }, - "node_modules/enquirer": { - "version": "2.4.1", - "resolved": "https://registry.npmjs.org/enquirer/-/enquirer-2.4.1.tgz", - "integrity": "sha512-rRqJg/6gd538VHvR3PSrdRBb/1Vy2YfzHqzvbhGIQpDRKIa4FgV/54b5Q1xYSxOOwKvjXweS26E0Q+nAMwp2pQ==", + "node_modules/cliui/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true, + "license": "MIT" + }, + "node_modules/cliui/node_modules/wrap-ansi": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", + "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", "dev": true, "license": "MIT", "dependencies": { - "ansi-colors": "^4.1.1", - "strip-ansi": "^6.0.1" + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" }, "engines": { - "node": ">=8.6" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/wrap-ansi?sponsor=1" } }, - "node_modules/entities": { - "version": "4.5.0", - "resolved": "https://registry.npmjs.org/entities/-/entities-4.5.0.tgz", - "integrity": "sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==", - "dev": true, - "license": "BSD-2-Clause", + "node_modules/clone": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/clone/-/clone-2.1.2.tgz", + "integrity": "sha512-3Pe/CF1Nn94hyhIYpjtiLhdCoEoz0DqQ+988E9gmeEdQZlojxnOb74wctFyuwWQHzqyf9X7C7MG8juUpqBJT8w==", + "license": "MIT", "engines": { - "node": ">=0.12" - }, - "funding": { - "url": "https://github.com/fb55/entities?sponsor=1" + "node": ">=0.8" } }, - "node_modules/env-paths": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/env-paths/-/env-paths-2.2.1.tgz", - "integrity": "sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A==", + "node_modules/clone-buffer": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/clone-buffer/-/clone-buffer-1.0.0.tgz", + "integrity": "sha512-KLLTJWrvwIP+OPfMn0x2PheDEP20RPUcGXj/ERegTgdmPEZylALQldygiqrPPu8P45uNuPs7ckmReLY6v/iA5g==", "license": "MIT", "engines": { - "node": ">=6" + "node": ">= 0.10" } }, - "node_modules/envinfo": { - "version": "7.14.0", - "resolved": "https://registry.npmjs.org/envinfo/-/envinfo-7.14.0.tgz", - "integrity": "sha512-CO40UI41xDQzhLB1hWyqUKgFhs250pNcGbyGKe1l/e4FSaI/+YE4IMG76GDt0In67WLPACIITC+sOi08x4wIvg==", + "node_modules/clone-deep": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/clone-deep/-/clone-deep-4.0.1.tgz", + "integrity": "sha512-neHB9xuzh/wk0dIHweyAXv2aPGZIVk3pLMe+/RNzINf17fe0OG96QroktYAUm7SM1PBnzTabaLboqqxDyMU+SQ==", + "dev": true, "license": "MIT", - "bin": { - "envinfo": "dist/cli.js" + "dependencies": { + "is-plain-object": "^2.0.4", + "kind-of": "^6.0.2", + "shallow-clone": "^3.0.0" }, "engines": { - "node": ">=4" + "node": ">=6" } }, - "node_modules/equivalent-key-map": { - "version": "0.2.2", - "resolved": "https://registry.npmjs.org/equivalent-key-map/-/equivalent-key-map-0.2.2.tgz", - "integrity": "sha512-xvHeyCDbZzkpN4VHQj/n+j2lOwL0VWszG30X4cOrc9Y7Tuo2qCdZK/0AMod23Z5dCtNUbaju6p0rwOhHUk05ew==", - "license": "MIT" + "node_modules/clone-deep/node_modules/is-plain-object": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-2.0.4.tgz", + "integrity": "sha512-h5PpgXkWitc38BBMYawTYMWJHFZJVnBquFE57xFpjB8pJFiF6gZ+bU+WyI/yqXiFR5mdLsgYNaPe8uao6Uv9Og==", + "dev": true, + "license": "MIT", + "dependencies": { + "isobject": "^3.0.1" + }, + "engines": { + "node": ">=0.10.0" + } }, - "node_modules/error-ex": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", - "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==", + "node_modules/clone-response": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/clone-response/-/clone-response-1.0.3.tgz", + "integrity": "sha512-ROoL94jJH2dUVML2Y/5PEDNaSHgeOdSDicUyS7izcF63G6sTc/FTjLub4b8Il9S8S0beOfYt0TaA5qvFK+w0wA==", + "dev": true, "license": "MIT", "dependencies": { - "is-arrayish": "^0.2.1" + "mimic-response": "^1.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/error-stack-parser": { - "version": "2.1.4", - "resolved": "https://registry.npmjs.org/error-stack-parser/-/error-stack-parser-2.1.4.tgz", - "integrity": "sha512-Sk5V6wVazPhq5MhpO+AUxJn5x7XSXGl1R93Vn7i+zS15KDVxQijejNCrz8340/2bgLBjR9GtEG8ZVKONDjcqGQ==", + "node_modules/clone-stats": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/clone-stats/-/clone-stats-1.0.0.tgz", + "integrity": "sha512-au6ydSpg6nsrigcZ4m8Bc9hxjeW+GJ8xh5G3BJCMt4WXe1H10UNaVOamqQTmrx1kjVuxAHIQSNU6hY4Nsn9/ag==", + "license": "MIT" + }, + "node_modules/cloneable-readable": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/cloneable-readable/-/cloneable-readable-1.1.3.tgz", + "integrity": "sha512-2EF8zTQOxYq70Y4XKtorQupqF0m49MBz2/yf5Bj+MHjvpG3Hy7sImifnqD6UA+TKYxeSV+u6qqQPawN5UvnpKQ==", "license": "MIT", - "peer": true, "dependencies": { - "stackframe": "^1.3.4" + "inherits": "^2.0.1", + "process-nextick-args": "^2.0.0", + "readable-stream": "^2.3.5" } }, - "node_modules/errorhandler": { - "version": "1.5.1", - "resolved": "https://registry.npmjs.org/errorhandler/-/errorhandler-1.5.1.tgz", - "integrity": "sha512-rcOwbfvP1WTViVoUjcfZicVzjhjTuhSMntHh6mW3IrEiyE6mJyXvsToJUJGlGlw/2xU9P5whlWNGlIDVeCiT4A==", + "node_modules/colord": { + "version": "2.9.3", + "resolved": "https://registry.npmjs.org/colord/-/colord-2.9.3.tgz", + "integrity": "sha512-jeC1axXpnb0/2nn/Y1LPuLdgXBLH7aDcHu4KEKfqw3CUhX7ZpfBSlPKyqXE6btIgEzfWtrX3/tyBCaCvXvMkOw==", + "dev": true, + "license": "MIT" + }, + "node_modules/colorette": { + "version": "2.0.20", + "resolved": "https://registry.npmjs.org/colorette/-/colorette-2.0.20.tgz", + "integrity": "sha512-IfEDxwoWIjkeXL1eXcDiow4UbKjhLdq6/EuSVR9GMN7KVH3r9gQ83e73hsz1Nd1T3ijd5xv1wcWRYO+D6kCI2w==", + "dev": true, + "license": "MIT" + }, + "node_modules/combined-stream": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", + "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "accepts": "~1.3.7", - "escape-html": "~1.0.3" + "delayed-stream": "~1.0.0" }, "engines": { "node": ">= 0.8" } }, - "node_modules/es-abstract": { - "version": "1.23.3", - "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.23.3.tgz", - "integrity": "sha512-e+HfNH61Bj1X9/jLc5v1owaLYuHdeHHSQlkhCBiTK8rBvKaULl/beGMxwrMXjpYrv4pz22BlY570vVePA2ho4A==", + "node_modules/commander": { + "version": "6.2.1", + "resolved": "https://registry.npmjs.org/commander/-/commander-6.2.1.tgz", + "integrity": "sha512-U7VdrJFnJgo4xjrHpTzu0yrHPGImdsmD95ZlgYSEajAn2JKzDhDTPG9kBTefmObL2w/ngeZnilk+OV9CG3d7UA==", + "dev": true, "license": "MIT", - "dependencies": { - "array-buffer-byte-length": "^1.0.1", - "arraybuffer.prototype.slice": "^1.0.3", - "available-typed-arrays": "^1.0.7", - "call-bind": "^1.0.7", - "data-view-buffer": "^1.0.1", - "data-view-byte-length": "^1.0.1", - "data-view-byte-offset": "^1.0.0", - "es-define-property": "^1.0.0", - "es-errors": "^1.3.0", - "es-object-atoms": "^1.0.0", - "es-set-tostringtag": "^2.0.3", - "es-to-primitive": "^1.2.1", - "function.prototype.name": "^1.1.6", - "get-intrinsic": "^1.2.4", - "get-symbol-description": "^1.0.2", - "globalthis": "^1.0.3", - "gopd": "^1.0.1", - "has-property-descriptors": "^1.0.2", - "has-proto": "^1.0.3", - "has-symbols": "^1.0.3", - "hasown": "^2.0.2", - "internal-slot": "^1.0.7", - "is-array-buffer": "^3.0.4", - "is-callable": "^1.2.7", - "is-data-view": "^1.0.1", - "is-negative-zero": "^2.0.3", - "is-regex": "^1.1.4", - "is-shared-array-buffer": "^1.0.3", - "is-string": "^1.0.7", - "is-typed-array": "^1.1.13", - "is-weakref": "^1.0.2", - "object-inspect": "^1.13.1", - "object-keys": "^1.1.1", - "object.assign": "^4.1.5", - "regexp.prototype.flags": "^1.5.2", - "safe-array-concat": "^1.1.2", - "safe-regex-test": "^1.0.3", - "string.prototype.trim": "^1.2.9", - "string.prototype.trimend": "^1.0.8", - "string.prototype.trimstart": "^1.0.8", - "typed-array-buffer": "^1.0.2", - "typed-array-byte-length": "^1.0.1", - "typed-array-byte-offset": "^1.0.2", - "typed-array-length": "^1.0.6", - "unbox-primitive": "^1.0.2", - "which-typed-array": "^1.1.15" - }, "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "node": ">= 6" } }, - "node_modules/es-define-property": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.0.tgz", - "integrity": "sha512-jxayLKShrEqqzJ0eumQbVhTYQM27CfT1T35+gCgDFoL82JLsXqTJ76zv6A0YLOgEnLUMvLzsDsGIrl8NFpT2gQ==", + "node_modules/comment-parser": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/comment-parser/-/comment-parser-1.4.1.tgz", + "integrity": "sha512-buhp5kePrmda3vhc5B9t7pUQXAb2Tnd0qgpkIhPhkHXxJpiPJ11H0ZEU0oBpJ2QztSbzG/ZxMj/CHsYJqRHmyg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 12.0.0" + } + }, + "node_modules/common-path-prefix": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/common-path-prefix/-/common-path-prefix-3.0.0.tgz", + "integrity": "sha512-QE33hToZseCH3jS0qN96O/bSh3kaw/h+Tq7ngyY9eWDUnTlTNUyqfqvCXioLe5Na5jFsL78ra/wuBU4iuEgd4w==", + "dev": true, + "license": "ISC" + }, + "node_modules/common-tags": { + "version": "1.8.2", + "resolved": "https://registry.npmjs.org/common-tags/-/common-tags-1.8.2.tgz", + "integrity": "sha512-gk/Z852D2Wtb//0I+kRFNKKE9dIIVirjoqPoA1wJU+XePVXZfGeBpk45+A1rKO4Q43prqWBNY/MiIeRLbPWUaA==", + "dev": true, "license": "MIT", - "dependencies": { - "get-intrinsic": "^1.2.4" - }, "engines": { - "node": ">= 0.4" + "node": ">=4.0.0" } }, - "node_modules/es-errors": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz", - "integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==", + "node_modules/compressible": { + "version": "2.0.18", + "resolved": "https://registry.npmjs.org/compressible/-/compressible-2.0.18.tgz", + "integrity": "sha512-AF3r7P5dWxL8MxyITRMlORQNaOA2IkAFaTr4k7BUumjPtRpGDTZpl0Pb1XCO6JeDCBdp126Cgs9sMxqSjgYyRg==", + "dev": true, "license": "MIT", + "dependencies": { + "mime-db": ">= 1.43.0 < 2" + }, "engines": { - "node": ">= 0.4" + "node": ">= 0.6" } }, - "node_modules/es-get-iterator": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.3.tgz", - "integrity": "sha512-sPZmqHBe6JIiTfN5q2pEi//TwxmAFHwj/XEuYjTuse78i8KxaqMTTzxPoFKuzRpDpTJ+0NAbpfenkmH2rePtuw==", + "node_modules/compression": { + "version": "1.7.4", + "resolved": "https://registry.npmjs.org/compression/-/compression-1.7.4.tgz", + "integrity": "sha512-jaSIDzP9pZVS4ZfQ+TzvtiWhdpFhE2RDHz8QJkpX9SIpLq88VueF5jJw6t+6CUQcAoA6t+x89MLrWAqpfDE8iQ==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.2", - "get-intrinsic": "^1.1.3", - "has-symbols": "^1.0.3", - "is-arguments": "^1.1.1", - "is-map": "^2.0.2", - "is-set": "^2.0.2", - "is-string": "^1.0.7", - "isarray": "^2.0.5", - "stop-iteration-iterator": "^1.0.0" + "accepts": "~1.3.5", + "bytes": "3.0.0", + "compressible": "~2.0.16", + "debug": "2.6.9", + "on-headers": "~1.0.2", + "safe-buffer": "5.1.2", + "vary": "~1.1.2" }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "engines": { + "node": ">= 0.8.0" } }, - "node_modules/es-iterator-helpers": { - "version": "1.0.19", - "resolved": "https://registry.npmjs.org/es-iterator-helpers/-/es-iterator-helpers-1.0.19.tgz", - "integrity": "sha512-zoMwbCcH5hwUkKJkT8kDIBZSz9I6mVG//+lDCinLCGov4+r7NIy0ld8o03M0cJxl2spVf6ESYVS6/gpIfq1FFw==", + "node_modules/compression/node_modules/debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.7", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.3", - "es-errors": "^1.3.0", - "es-set-tostringtag": "^2.0.3", - "function-bind": "^1.1.2", - "get-intrinsic": "^1.2.4", - "globalthis": "^1.0.3", - "has-property-descriptors": "^1.0.2", - "has-proto": "^1.0.3", - "has-symbols": "^1.0.3", - "internal-slot": "^1.0.7", - "iterator.prototype": "^1.1.2", - "safe-array-concat": "^1.1.2" - }, - "engines": { - "node": ">= 0.4" + "ms": "2.0.0" } }, - "node_modules/es-module-lexer": { - "version": "1.5.4", - "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.5.4.tgz", - "integrity": "sha512-MVNK56NiMrOwitFB7cqDwq0CQutbw+0BvLshJSse0MUNU+y1FC3bUS/AQg7oUng+/wKrrki7JfmwtVHkVfPLlw==", + "node_modules/compression/node_modules/ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", "dev": true, "license": "MIT" }, - "node_modules/es-object-atoms": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/es-object-atoms/-/es-object-atoms-1.0.0.tgz", - "integrity": "sha512-MZ4iQ6JwHOBQjahnjwaC1ZtIBH+2ohjamzAO3oaHcXYup7qxjF2fixyH+Q71voWHeOkI2q/TnJao/KfXYIZWbw==", + "node_modules/compression/node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", + "dev": true, + "license": "MIT" + }, + "node_modules/concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==", + "dev": true, + "license": "MIT" + }, + "node_modules/concat-stream": { + "version": "1.6.2", + "resolved": "https://registry.npmjs.org/concat-stream/-/concat-stream-1.6.2.tgz", + "integrity": "sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw==", + "dev": true, + "engines": [ + "node >= 0.8" + ], "license": "MIT", "dependencies": { - "es-errors": "^1.3.0" - }, - "engines": { - "node": ">= 0.4" + "buffer-from": "^1.0.0", + "inherits": "^2.0.3", + "readable-stream": "^2.2.2", + "typedarray": "^0.0.6" } }, - "node_modules/es-set-tostringtag": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.0.3.tgz", - "integrity": "sha512-3T8uNMC3OQTHkFUsFq8r/BwAXLHvU/9O9mE0fBc/MY5iq/8H7ncvO947LmYA6ldWw9Uh8Yhf25zu6n7nML5QWQ==", + "node_modules/connect-history-api-fallback": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/connect-history-api-fallback/-/connect-history-api-fallback-2.0.0.tgz", + "integrity": "sha512-U73+6lQFmfiNPrYbXqr6kZ1i1wiRqXnp2nhMsINseWXO8lDau0LGEffJ8kQi4EjLZympVgRdvqjAgiZ1tgzDDA==", + "dev": true, "license": "MIT", - "dependencies": { - "get-intrinsic": "^1.2.4", - "has-tostringtag": "^1.0.2", - "hasown": "^2.0.1" - }, "engines": { - "node": ">= 0.4" + "node": ">=0.8" } }, - "node_modules/es-shim-unscopables": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/es-shim-unscopables/-/es-shim-unscopables-1.0.2.tgz", - "integrity": "sha512-J3yBRXCzDu4ULnQwxyToo/OjdMx6akgVC7K6few0a7F/0wLtmKKN7I73AH5T2836UuXRqN7Qg+IIUw/+YJksRw==", - "license": "MIT", - "dependencies": { - "hasown": "^2.0.0" - } + "node_modules/consolidated-events": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/consolidated-events/-/consolidated-events-2.0.2.tgz", + "integrity": "sha512-2/uRVMdRypf5z/TW/ncD/66l75P5hH2vM/GR8Jf8HLc2xnfJtmina6F6du8+v4Z2vTrMo7jC+W1tmEEuuELgkQ==", + "license": "MIT" }, - "node_modules/es-to-primitive": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", - "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", + "node_modules/content-disposition": { + "version": "0.5.4", + "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.4.tgz", + "integrity": "sha512-FveZTNuGw04cxlAiWbzi6zTAL/lhehaWbTtgluJh4/E95DqMwTmha3KZN1aAWA8cFIhHzMZUvLevkw5Rqk+tSQ==", + "dev": true, "license": "MIT", "dependencies": { - "is-callable": "^1.1.4", - "is-date-object": "^1.0.1", - "is-symbol": "^1.0.2" + "safe-buffer": "5.2.1" }, "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "node": ">= 0.6" } }, - "node_modules/escalade": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.2.0.tgz", - "integrity": "sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==", + "node_modules/content-type": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.5.tgz", + "integrity": "sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA==", + "dev": true, "license": "MIT", "engines": { - "node": ">=6" + "node": ">= 0.6" } }, - "node_modules/escape-html": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", - "integrity": "sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow==", + "node_modules/convert-source-map": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", + "dev": true, "license": "MIT" }, - "node_modules/escape-string-regexp": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", + "node_modules/cookie": { + "version": "0.7.1", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.7.1.tgz", + "integrity": "sha512-6DnInpx7SJ2AK3+CTUE/ZM0vWTUboZCegxhC2xiIydHR9jNuTAASBrfEpHhiGOZw/nX51bHt6YQl8jsGo4y/0w==", "dev": true, - "license": "MIT", "engines": { - "node": ">=0.8.0" + "node": ">= 0.6" } }, - "node_modules/eslint": { - "version": "8.57.1", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.57.1.tgz", - "integrity": "sha512-ypowyDxpVSYpkXr9WPv2PAZCtNip1Mv5KTW0SCurXv/9iOpcrH9PaqUElksqEB6pChqHGDRCFTyrZlGhnLNGiA==", + "node_modules/cookie-signature": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.6.tgz", + "integrity": "sha512-QADzlaHc8icV8I7vbaJXJwod9HWYp8uCqf1xa4OfNu1T7JVxQIrUgOWtHdNDtPiywmFbiS12VjotIXLrKM3orQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/copy-dir": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/copy-dir/-/copy-dir-1.3.0.tgz", + "integrity": "sha512-Q4+qBFnN4bwGwvtXXzbp4P/4iNk0MaiGAzvQ8OiMtlLjkIKjmNN689uVzShSM0908q7GoFHXIPx4zi75ocoaHw==", + "dev": true, + "license": "MIT" + }, + "node_modules/copy-webpack-plugin": { + "version": "11.0.0", + "resolved": "https://registry.npmjs.org/copy-webpack-plugin/-/copy-webpack-plugin-11.0.0.tgz", + "integrity": "sha512-fX2MWpamkW0hZxMEg0+mYnA40LTosOSa5TqZ9GYIBzyJa9C3QUaMPSE2xAi/buNr8u89SfD9wHSQVBzrRa/SOQ==", "dev": true, "license": "MIT", - "dependencies": { - "@eslint-community/eslint-utils": "^4.2.0", - "@eslint-community/regexpp": "^4.6.1", - "@eslint/eslintrc": "^2.1.4", - "@eslint/js": "8.57.1", - "@humanwhocodes/config-array": "^0.13.0", - "@humanwhocodes/module-importer": "^1.0.1", - "@nodelib/fs.walk": "^1.2.8", - "@ungap/structured-clone": "^1.2.0", - "ajv": "^6.12.4", - "chalk": "^4.0.0", - "cross-spawn": "^7.0.2", - "debug": "^4.3.2", - "doctrine": "^3.0.0", - "escape-string-regexp": "^4.0.0", - "eslint-scope": "^7.2.2", - "eslint-visitor-keys": "^3.4.3", - "espree": "^9.6.1", - "esquery": "^1.4.2", - "esutils": "^2.0.2", - "fast-deep-equal": "^3.1.3", - "file-entry-cache": "^6.0.1", - "find-up": "^5.0.0", - "glob-parent": "^6.0.2", - "globals": "^13.19.0", - "graphemer": "^1.4.0", - "ignore": "^5.2.0", - "imurmurhash": "^0.1.4", - "is-glob": "^4.0.0", - "is-path-inside": "^3.0.3", - "js-yaml": "^4.1.0", - "json-stable-stringify-without-jsonify": "^1.0.1", - "levn": "^0.4.1", - "lodash.merge": "^4.6.2", - "minimatch": "^3.1.2", - "natural-compare": "^1.4.0", - "optionator": "^0.9.3", - "strip-ansi": "^6.0.1", - "text-table": "^0.2.0" - }, - "bin": { - "eslint": "bin/eslint.js" + "dependencies": { + "fast-glob": "^3.2.11", + "glob-parent": "^6.0.1", + "globby": "^13.1.1", + "normalize-path": "^3.0.0", + "schema-utils": "^4.0.0", + "serialize-javascript": "^6.0.0" }, "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "node": ">= 14.15.0" }, "funding": { - "url": "https://opencollective.com/eslint" + "type": "opencollective", + "url": "https://opencollective.com/webpack" + }, + "peerDependencies": { + "webpack": "^5.1.0" } }, - "node_modules/eslint-config-prettier": { - "version": "8.10.0", - "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-8.10.0.tgz", - "integrity": "sha512-SM8AMJdeQqRYT9O9zguiruQZaN7+z+E4eAP9oiLNGKMtomwaB1E9dcgUD6ZAn/eQAb52USbvezbiljfZUhbJcg==", + "node_modules/copy-webpack-plugin/node_modules/globby": { + "version": "13.2.2", + "resolved": "https://registry.npmjs.org/globby/-/globby-13.2.2.tgz", + "integrity": "sha512-Y1zNGV+pzQdh7H39l9zgB4PJqjRNqydvdYCDG4HFXM4XuvSaQQlEc91IU1yALL8gUTDomgBAfz3XJdmUS+oo0w==", "dev": true, "license": "MIT", - "bin": { - "eslint-config-prettier": "bin/cli.js" + "dependencies": { + "dir-glob": "^3.0.1", + "fast-glob": "^3.3.0", + "ignore": "^5.2.4", + "merge2": "^1.4.1", + "slash": "^4.0.0" }, - "peerDependencies": { - "eslint": ">=7.0.0" + "engines": { + "node": "^12.20.0 || ^14.13.1 || >=16.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/eslint-import-resolver-node": { - "version": "0.3.9", - "resolved": "https://registry.npmjs.org/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.9.tgz", - "integrity": "sha512-WFj2isz22JahUv+B788TlO3N6zL3nNJGU8CcZbPZvVEkBPaJdCV4vy5wyghty5ROFbCRnm132v8BScu5/1BQ8g==", + "node_modules/copy-webpack-plugin/node_modules/slash": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/slash/-/slash-4.0.0.tgz", + "integrity": "sha512-3dOsAHXXUkQTpOYcoAxLIorMTp4gIQr5IW3iVb7A7lFIp0VHhnynm9izx6TssdrIcVIESAlVjtnO2K8bg+Coew==", "dev": true, "license": "MIT", - "dependencies": { - "debug": "^3.2.7", - "is-core-module": "^2.13.0", - "resolve": "^1.22.4" + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/eslint-import-resolver-node/node_modules/debug": { - "version": "3.2.7", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", - "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "node_modules/core-js": { + "version": "2.6.12", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-2.6.12.tgz", + "integrity": "sha512-Kb2wC0fvsWfQrgk8HU5lW6U/Lcs8+9aaYcy4ZFc6DDlo4nZ7n70dEgE5rtR0oG6ufKDUnrwfWL1mXR5ljDatrQ==", + "deprecated": "core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js.", + "hasInstallScript": true, + "license": "MIT" + }, + "node_modules/core-js-compat": { + "version": "3.38.1", + "resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.38.1.tgz", + "integrity": "sha512-JRH6gfXxGmrzF3tZ57lFx97YARxCXPaMzPo6jELZhv88pBH5VXpQ+y0znKGlFnzuaihqhLbefxSJxWJMPtfDzw==", "dev": true, "license": "MIT", "dependencies": { - "ms": "^2.1.1" + "browserslist": "^4.23.3" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/core-js" } }, - "node_modules/eslint-import-resolver-webpack": { - "version": "0.13.9", - "resolved": "https://registry.npmjs.org/eslint-import-resolver-webpack/-/eslint-import-resolver-webpack-0.13.9.tgz", - "integrity": "sha512-yGngeefNiHXau2yzKKs2BNON4HLpxBabY40BGL/vUSKZtqzjlVsTTZm57jhHULhm+mJEwKsEIIN3NXup5AiiBQ==", + "node_modules/core-util-is": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", + "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==", + "license": "MIT" + }, + "node_modules/cosmiconfig": { + "version": "8.3.6", + "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-8.3.6.tgz", + "integrity": "sha512-kcZ6+W5QzcJ3P1Mt+83OUv/oHFqZHIx8DuxG6eZ5RGMERoLqp4BuGjhHLYGK+Kf5XVkQvqBSmAy/nGWN3qDgEA==", "dev": true, "license": "MIT", "dependencies": { - "debug": "^3.2.7", - "enhanced-resolve": "^0.9.1", - "find-root": "^1.1.0", - "hasown": "^2.0.0", - "interpret": "^1.4.0", - "is-core-module": "^2.13.1", - "is-regex": "^1.1.4", - "lodash": "^4.17.21", - "resolve": "^2.0.0-next.5", - "semver": "^5.7.2" + "import-fresh": "^3.3.0", + "js-yaml": "^4.1.0", + "parse-json": "^5.2.0", + "path-type": "^4.0.0" }, "engines": { - "node": ">= 6" + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/d-fischer" }, "peerDependencies": { - "eslint-plugin-import": ">=1.4.0", - "webpack": ">=1.11.0" + "typescript": ">=4.9.5" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } } }, - "node_modules/eslint-import-resolver-webpack/node_modules/debug": { - "version": "3.2.7", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", - "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "node_modules/cosmiconfig/node_modules/argparse": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", + "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", "dev": true, - "license": "MIT", - "dependencies": { - "ms": "^2.1.1" - } + "license": "Python-2.0" }, - "node_modules/eslint-import-resolver-webpack/node_modules/resolve": { - "version": "2.0.0-next.5", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-2.0.0-next.5.tgz", - "integrity": "sha512-U7WjGVG9sH8tvjW5SmGbQuui75FiyjAX72HX15DwBBwF9dNiQZRQAg9nnPhYy+TUnE0+VcrttuvNI8oSxZcocA==", + "node_modules/cosmiconfig/node_modules/js-yaml": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", + "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", "dev": true, "license": "MIT", "dependencies": { - "is-core-module": "^2.13.0", - "path-parse": "^1.0.7", - "supports-preserve-symlinks-flag": "^1.0.0" + "argparse": "^2.0.1" }, "bin": { - "resolve": "bin/resolve" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "js-yaml": "bin/js-yaml.js" } }, - "node_modules/eslint-import-resolver-webpack/node_modules/semver": { - "version": "5.7.2", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz", - "integrity": "sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==", + "node_modules/cross-env": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/cross-env/-/cross-env-7.0.3.tgz", + "integrity": "sha512-+/HKd6EgcQCJGh2PSjZuUitQBQynKor4wrFbRg4DtAgS1aWO+gU52xpH7M9ScGgXSYmAVS9bIJ8EzuaGw0oNAw==", "dev": true, - "license": "ISC", + "license": "MIT", + "dependencies": { + "cross-spawn": "^7.0.1" + }, "bin": { - "semver": "bin/semver" + "cross-env": "src/bin/cross-env.js", + "cross-env-shell": "src/bin/cross-env-shell.js" + }, + "engines": { + "node": ">=10.14", + "npm": ">=6", + "yarn": ">=1" } }, - "node_modules/eslint-module-utils": { - "version": "2.11.0", - "resolved": "https://registry.npmjs.org/eslint-module-utils/-/eslint-module-utils-2.11.0.tgz", - "integrity": "sha512-gbBE5Hitek/oG6MUVj6sFuzEjA/ClzNflVrLovHi/JgLdC7fiN5gLAY1WIPW1a0V5I999MnsrvVrCOGmmVqDBQ==", + "node_modules/cross-spawn": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.6.tgz", + "integrity": "sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==", "dev": true, - "license": "MIT", "dependencies": { - "debug": "^3.2.7" + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/css-color-keywords": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/css-color-keywords/-/css-color-keywords-1.0.0.tgz", + "integrity": "sha512-FyyrDHZKEjXDpNJYvVsV960FiqQyXc/LlYmsxl2BcdMb2WPx0OGRVgTg55rPSyLSNMqP52R9r8geSp7apN3Ofg==", + "license": "ISC", "engines": { "node": ">=4" - }, - "peerDependenciesMeta": { - "eslint": { - "optional": true - } } }, - "node_modules/eslint-module-utils/node_modules/debug": { - "version": "3.2.7", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", - "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "node_modules/css-functions-list": { + "version": "3.2.3", + "resolved": "https://registry.npmjs.org/css-functions-list/-/css-functions-list-3.2.3.tgz", + "integrity": "sha512-IQOkD3hbR5KrN93MtcYuad6YPuTSUhntLHDuLEbFWE+ff2/XSZNdZG+LcbbIW5AXKg/WFIfYItIzVoHngHXZzA==", "dev": true, "license": "MIT", - "dependencies": { - "ms": "^2.1.1" + "engines": { + "node": ">=12 || >=16" } }, - "node_modules/eslint-plugin-compat": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-compat/-/eslint-plugin-compat-4.2.0.tgz", - "integrity": "sha512-RDKSYD0maWy5r7zb5cWQS+uSPc26mgOzdORJ8hxILmWM7S/Ncwky7BcAtXVY5iRbKjBdHsWU8Yg7hfoZjtkv7w==", + "node_modules/css-loader": { + "version": "7.1.2", + "resolved": "https://registry.npmjs.org/css-loader/-/css-loader-7.1.2.tgz", + "integrity": "sha512-6WvYYn7l/XEGN8Xu2vWFt9nVzrCn39vKyTEFf/ExEyoksJjjSZV/0/35XPlMbpnr6VGhZIUg5yJrL8tGfes/FA==", "dev": true, "license": "MIT", "dependencies": { - "@mdn/browser-compat-data": "^5.3.13", - "ast-metadata-inferer": "^0.8.0", - "browserslist": "^4.21.10", - "caniuse-lite": "^1.0.30001524", - "find-up": "^5.0.0", - "lodash.memoize": "^4.1.2", + "icss-utils": "^5.1.0", + "postcss": "^8.4.33", + "postcss-modules-extract-imports": "^3.1.0", + "postcss-modules-local-by-default": "^4.0.5", + "postcss-modules-scope": "^3.2.0", + "postcss-modules-values": "^4.0.0", + "postcss-value-parser": "^4.2.0", "semver": "^7.5.4" }, "engines": { - "node": ">=14.x" + "node": ">= 18.12.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/webpack" }, "peerDependencies": { - "eslint": "^4.0.0 || ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0" + "@rspack/core": "0.x || 1.x", + "webpack": "^5.27.0" + }, + "peerDependenciesMeta": { + "@rspack/core": { + "optional": true + }, + "webpack": { + "optional": true + } } }, - "node_modules/eslint-plugin-compat/node_modules/semver": { + "node_modules/css-loader/node_modules/semver": { "version": "7.6.3", "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", @@ -11453,205 +7188,319 @@ "bin": { "semver": "bin/semver.js" }, - "engines": { - "node": ">=10" + "engines": { + "node": ">=10" + } + }, + "node_modules/css-select": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/css-select/-/css-select-5.1.0.tgz", + "integrity": "sha512-nwoRF1rvRRnnCqqY7updORDsuqKzqYJ28+oSMaJMMgOauh3fvwHqMS7EZpIPqK8GL+g9mKxF1vP/ZjSeNjEVHg==", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "boolbase": "^1.0.0", + "css-what": "^6.1.0", + "domhandler": "^5.0.2", + "domutils": "^3.0.1", + "nth-check": "^2.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/fb55" } }, - "node_modules/eslint-plugin-cypress": { - "version": "3.5.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-cypress/-/eslint-plugin-cypress-3.5.0.tgz", - "integrity": "sha512-JZQ6XnBTNI8h1B9M7wJSFzc48SYbh7VMMKaNTQOFa3BQlnmXPrVc4PKen8R+fpv6VleiPeej6VxloGb42zdRvw==", - "dev": true, + "node_modules/css-to-react-native": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/css-to-react-native/-/css-to-react-native-3.2.0.tgz", + "integrity": "sha512-e8RKaLXMOFii+02mOlqwjbD00KSEKqblnpO9e++1aXS1fPQOpS1YoqdVHBqPjHNoxeF2mimzVqawm2KCbEdtHQ==", "license": "MIT", "dependencies": { - "globals": "^13.20.0" - }, - "peerDependencies": { - "eslint": ">=7" + "camelize": "^1.0.0", + "css-color-keywords": "^1.0.0", + "postcss-value-parser": "^4.0.2" } }, - "node_modules/eslint-plugin-cypress/node_modules/globals": { - "version": "13.24.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.24.0.tgz", - "integrity": "sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==", + "node_modules/css-tree": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-2.3.1.tgz", + "integrity": "sha512-6Fv1DV/TYw//QF5IzQdqsNDjx/wc8TrMBZsqjL9eW01tWb7R7k/mq+/VXfJCl7SoD5emsJop9cOByJZfs8hYIw==", "dev": true, "license": "MIT", "dependencies": { - "type-fest": "^0.20.2" + "mdn-data": "2.0.30", + "source-map-js": "^1.0.1" }, "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "node": "^10 || ^12.20.0 || ^14.13.0 || >=15.0.0" } }, - "node_modules/eslint-plugin-cypress/node_modules/type-fest": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", - "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", + "node_modules/css-unicode-loader": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/css-unicode-loader/-/css-unicode-loader-1.0.3.tgz", + "integrity": "sha512-mszxqB0LCBO2ixbaz/tAH17iEAXmytUv0j/YXtPxhOi8D8Teh+mOXqmz+DZRtDil5tFx7ltbgw16dUptEw4jOg==", "dev": true, - "license": "(MIT OR CC0-1.0)", + "license": "MIT" + }, + "node_modules/css-what": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/css-what/-/css-what-6.1.0.tgz", + "integrity": "sha512-HTUrgRJ7r4dsZKU6GjmpfRK1O76h97Z8MfS1G0FozR+oF2kG6Vfe8JE6zwrkbxigziPHinCJ+gCPjA9EaBDtRw==", + "dev": true, + "license": "BSD-2-Clause", "engines": { - "node": ">=10" + "node": ">= 6" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://github.com/sponsors/fb55" } }, - "node_modules/eslint-plugin-import": { - "version": "2.30.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-import/-/eslint-plugin-import-2.30.0.tgz", - "integrity": "sha512-/mHNE9jINJfiD2EKkg1BKyPyUk4zdnT54YgbOgfjSakWT5oyX/qQLVNTkehyfpcMxZXMy1zyonZ2v7hZTX43Yw==", + "node_modules/cssesc": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/cssesc/-/cssesc-3.0.0.tgz", + "integrity": "sha512-/Tb/JcjK111nNScGob5MNtsntNM1aCNUDipB/TkwZFhyDrrE47SOx/18wF2bbjgc3ZzCSKW1T5nt5EbFoAz/Vg==", "dev": true, "license": "MIT", - "dependencies": { - "@rtsao/scc": "^1.1.0", - "array-includes": "^3.1.8", - "array.prototype.findlastindex": "^1.2.5", - "array.prototype.flat": "^1.3.2", - "array.prototype.flatmap": "^1.3.2", - "debug": "^3.2.7", - "doctrine": "^2.1.0", - "eslint-import-resolver-node": "^0.3.9", - "eslint-module-utils": "^2.9.0", - "hasown": "^2.0.2", - "is-core-module": "^2.15.1", - "is-glob": "^4.0.3", - "minimatch": "^3.1.2", - "object.fromentries": "^2.0.8", - "object.groupby": "^1.0.3", - "object.values": "^1.2.0", - "semver": "^6.3.1", - "tsconfig-paths": "^3.15.0" + "bin": { + "cssesc": "bin/cssesc" }, "engines": { "node": ">=4" - }, - "peerDependencies": { - "eslint": "^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8" } }, - "node_modules/eslint-plugin-import/node_modules/debug": { - "version": "3.2.7", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", - "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "node_modules/csso": { + "version": "5.0.5", + "resolved": "https://registry.npmjs.org/csso/-/csso-5.0.5.tgz", + "integrity": "sha512-0LrrStPOdJj+SPCCrGhzryycLjwcgUSHBtxNA8aIDxf0GLsRh1cKYhB00Gd1lDOS4yGH69+SNn13+TWbVHETFQ==", "dev": true, "license": "MIT", "dependencies": { - "ms": "^2.1.1" + "css-tree": "~2.2.0" + }, + "engines": { + "node": "^10 || ^12.20.0 || ^14.13.0 || >=15.0.0", + "npm": ">=7.0.0" } }, - "node_modules/eslint-plugin-import/node_modules/doctrine": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz", - "integrity": "sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==", + "node_modules/csso/node_modules/css-tree": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-2.2.1.tgz", + "integrity": "sha512-OA0mILzGc1kCOCSJerOeqDxDQ4HOh+G8NbOJFOTgOCzpw7fCBubk0fEyxp8AgOL/jvLgYA/uV0cMbe43ElF1JA==", "dev": true, - "license": "Apache-2.0", + "license": "MIT", "dependencies": { - "esutils": "^2.0.2" + "mdn-data": "2.0.28", + "source-map-js": "^1.0.1" }, "engines": { - "node": ">=0.10.0" + "node": "^10 || ^12.20.0 || ^14.13.0 || >=15.0.0", + "npm": ">=7.0.0" } }, - "node_modules/eslint-plugin-jest": { - "version": "27.9.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-jest/-/eslint-plugin-jest-27.9.0.tgz", - "integrity": "sha512-QIT7FH7fNmd9n4se7FFKHbsLKGQiw885Ds6Y/sxKgCZ6natwCsXdgPOADnYVxN2QrRweF0FZWbJ6S7Rsn7llug==", + "node_modules/csso/node_modules/mdn-data": { + "version": "2.0.28", + "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.28.tgz", + "integrity": "sha512-aylIc7Z9y4yzHYAJNuESG3hfhC+0Ibp/MAMiaOZgNv4pmEdFyfZhhhny4MNiAfWdBQ1RQ2mfDWmM1x8SvGyp8g==", + "dev": true, + "license": "CC0-1.0" + }, + "node_modules/csstype": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.1.3.tgz", + "integrity": "sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==", + "license": "MIT" + }, + "node_modules/cypress": { + "version": "13.14.2", + "resolved": "https://registry.npmjs.org/cypress/-/cypress-13.14.2.tgz", + "integrity": "sha512-lsiQrN17vHMB2fnvxIrKLAjOr9bPwsNbPZNrWf99s4u+DVmCY6U+w7O3GGG9FvP4EUVYaDu+guWeNLiUzBrqvA==", "dev": true, + "hasInstallScript": true, "license": "MIT", "dependencies": { - "@typescript-eslint/utils": "^5.10.0" + "@cypress/request": "^3.0.1", + "@cypress/xvfb": "^1.2.4", + "@types/sinonjs__fake-timers": "8.1.1", + "@types/sizzle": "^2.3.2", + "arch": "^2.2.0", + "blob-util": "^2.0.2", + "bluebird": "^3.7.2", + "buffer": "^5.7.1", + "cachedir": "^2.3.0", + "chalk": "^4.1.0", + "check-more-types": "^2.24.0", + "cli-cursor": "^3.1.0", + "cli-table3": "~0.6.1", + "commander": "^6.2.1", + "common-tags": "^1.8.0", + "dayjs": "^1.10.4", + "debug": "^4.3.4", + "enquirer": "^2.3.6", + "eventemitter2": "6.4.7", + "execa": "4.1.0", + "executable": "^4.1.1", + "extract-zip": "2.0.1", + "figures": "^3.2.0", + "fs-extra": "^9.1.0", + "getos": "^3.2.1", + "is-ci": "^3.0.1", + "is-installed-globally": "~0.4.0", + "lazy-ass": "^1.6.0", + "listr2": "^3.8.3", + "lodash": "^4.17.21", + "log-symbols": "^4.0.0", + "minimist": "^1.2.8", + "ospath": "^1.2.2", + "pretty-bytes": "^5.6.0", + "process": "^0.11.10", + "proxy-from-env": "1.0.0", + "request-progress": "^3.0.0", + "semver": "^7.5.3", + "supports-color": "^8.1.1", + "tmp": "~0.2.3", + "untildify": "^4.0.0", + "yauzl": "^2.10.0" + }, + "bin": { + "cypress": "bin/cypress" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": "^16.0.0 || ^18.0.0 || >=20.0.0" + } + }, + "node_modules/cypress-axe": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/cypress-axe/-/cypress-axe-1.5.0.tgz", + "integrity": "sha512-Hy/owCjfj+25KMsecvDgo4fC/781ccL+e8p+UUYoadGVM2ogZF9XIKbiM6KI8Y3cEaSreymdD6ZzccbI2bY0lQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" }, "peerDependencies": { - "@typescript-eslint/eslint-plugin": "^5.0.0 || ^6.0.0 || ^7.0.0", - "eslint": "^7.0.0 || ^8.0.0", - "jest": "*" + "axe-core": "^3 || ^4", + "cypress": "^10 || ^11 || ^12 || ^13" + } + }, + "node_modules/cypress-html-validate": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/cypress-html-validate/-/cypress-html-validate-6.1.0.tgz", + "integrity": "sha512-IXVB1ZzdSHMzPM/QYZCXlG3yW2CdvSVY7bJtlijmk4kCRepfdHe0JLQ939h2Dj9ZsjyBockPQpun4omq1uRW6Q==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 16" }, - "peerDependenciesMeta": { - "@typescript-eslint/eslint-plugin": { - "optional": true - }, - "jest": { - "optional": true - } + "peerDependencies": { + "cypress": "^10 || ^11.0.1 || ^12 || ^13", + "html-validate": "^5 || ^6 || ^7 || ^8" } }, - "node_modules/eslint-plugin-jsdoc": { - "version": "48.11.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-jsdoc/-/eslint-plugin-jsdoc-48.11.0.tgz", - "integrity": "sha512-d12JHJDPNo7IFwTOAItCeJY1hcqoIxE0lHA8infQByLilQ9xkqrRa6laWCnsuCrf+8rUnvxXY1XuTbibRBNylA==", + "node_modules/cypress-xpath": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/cypress-xpath/-/cypress-xpath-2.0.1.tgz", + "integrity": "sha512-qMagjvinBppNJdMAkucWESP9aP4rDTs7c96m0vwMuZTVx3NqP2E3z/hkoRf8Ea9soL8yTvUuuyF1cg/Sb1Yhbg==", + "deprecated": "Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.", "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "@es-joy/jsdoccomment": "~0.46.0", - "are-docs-informative": "^0.0.2", - "comment-parser": "1.4.1", - "debug": "^4.3.5", - "escape-string-regexp": "^4.0.0", - "espree": "^10.1.0", - "esquery": "^1.6.0", - "parse-imports": "^2.1.1", - "semver": "^7.6.3", - "spdx-expression-parse": "^4.0.0", - "synckit": "^0.9.1" + "license": "MIT" + }, + "node_modules/cypress/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "license": "MIT", + "dependencies": { + "color-convert": "^2.0.1" }, "engines": { - "node": ">=18" + "node": ">=8" }, - "peerDependencies": { - "eslint": "^7.0.0 || ^8.0.0 || ^9.0.0" + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/eslint-plugin-jsdoc/node_modules/escape-string-regexp": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", - "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", + "node_modules/cypress/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, "license": "MIT", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, "engines": { "node": ">=10" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://github.com/chalk/chalk?sponsor=1" } }, - "node_modules/eslint-plugin-jsdoc/node_modules/eslint-visitor-keys": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-4.0.0.tgz", - "integrity": "sha512-OtIRv/2GyiF6o/d8K7MYKKbXrOUBIK6SfkIRM4Z0dY3w+LiQ0vy3F57m0Z71bjbyeiWFiHJ8brqnmE6H6/jEuw==", + "node_modules/cypress/node_modules/chalk/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, - "license": "Apache-2.0", + "license": "MIT", + "dependencies": { + "has-flag": "^4.0.0" + }, "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + "node": ">=8" + } + }, + "node_modules/cypress/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "color-name": "~1.1.4" }, - "funding": { - "url": "https://opencollective.com/eslint" + "engines": { + "node": ">=7.0.0" } }, - "node_modules/eslint-plugin-jsdoc/node_modules/espree": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/espree/-/espree-10.1.0.tgz", - "integrity": "sha512-M1M6CpiE6ffoigIOWYO9UDP8TMUw9kqb21tf+08IgDYjCsOvCuDt4jQcZmoYxx+w7zlKw9/N0KXfto+I8/FrXA==", + "node_modules/cypress/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true, + "license": "MIT" + }, + "node_modules/cypress/node_modules/extract-zip": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extract-zip/-/extract-zip-2.0.1.tgz", + "integrity": "sha512-GDhU9ntwuKyGXdZBUgTIe+vXnWj0fppUEtMDL0+idd5Sta8TGpHssn/eusA9mrPr9qNDym6SxAYZjNvCn/9RBg==", "dev": true, "license": "BSD-2-Clause", "dependencies": { - "acorn": "^8.12.0", - "acorn-jsx": "^5.3.2", - "eslint-visitor-keys": "^4.0.0" + "debug": "^4.1.1", + "get-stream": "^5.1.0", + "yauzl": "^2.10.0" + }, + "bin": { + "extract-zip": "cli.js" }, "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + "node": ">= 10.17.0" }, - "funding": { - "url": "https://opencollective.com/eslint" + "optionalDependencies": { + "@types/yauzl": "^2.9.1" } }, - "node_modules/eslint-plugin-jsdoc/node_modules/semver": { + "node_modules/cypress/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/cypress/node_modules/semver": { "version": "7.6.3", "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", @@ -11664,1566 +7513,1548 @@ "node": ">=10" } }, - "node_modules/eslint-plugin-jsx-a11y": { - "version": "6.10.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-jsx-a11y/-/eslint-plugin-jsx-a11y-6.10.0.tgz", - "integrity": "sha512-ySOHvXX8eSN6zz8Bywacm7CvGNhUtdjvqfQDVe6020TUK34Cywkw7m0KsCCk1Qtm9G1FayfTN1/7mMYnYO2Bhg==", + "node_modules/cypress/node_modules/supports-color": { + "version": "8.1.1", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", + "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", "dev": true, "license": "MIT", "dependencies": { - "aria-query": "~5.1.3", - "array-includes": "^3.1.8", - "array.prototype.flatmap": "^1.3.2", - "ast-types-flow": "^0.0.8", - "axe-core": "^4.10.0", - "axobject-query": "^4.1.0", - "damerau-levenshtein": "^1.0.8", - "emoji-regex": "^9.2.2", - "es-iterator-helpers": "^1.0.19", - "hasown": "^2.0.2", - "jsx-ast-utils": "^3.3.5", - "language-tags": "^1.0.9", - "minimatch": "^3.1.2", - "object.fromentries": "^2.0.8", - "safe-regex-test": "^1.0.3", - "string.prototype.includes": "^2.0.0" + "has-flag": "^4.0.0" }, "engines": { - "node": ">=4.0" + "node": ">=10" }, - "peerDependencies": { - "eslint": "^3 || ^4 || ^5 || ^6 || ^7 || ^8 || ^9" + "funding": { + "url": "https://github.com/chalk/supports-color?sponsor=1" } }, - "node_modules/eslint-plugin-no-jquery": { - "version": "2.7.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-no-jquery/-/eslint-plugin-no-jquery-2.7.0.tgz", - "integrity": "sha512-Aeg7dA6GTH1AcWLlBtWNzOU9efK5KpNi7b0EhBO0o0M+awyzguUUo8gF6hXGjQ9n5h8/uRtYv9zOqQkeC5CG0w==", + "node_modules/damerau-levenshtein": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/damerau-levenshtein/-/damerau-levenshtein-1.0.8.tgz", + "integrity": "sha512-sdQSFB7+llfUcQHUQO3+B8ERRj0Oa4w9POWMI/puGtuf7gFywGmkaLCElnudfTiKZV+NvHqL0ifzdrI8Ro7ESA==", + "dev": true, + "license": "BSD-2-Clause" + }, + "node_modules/dashdash": { + "version": "1.14.1", + "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz", + "integrity": "sha512-jRFi8UDGo6j+odZiEpjazZaWqEal3w/basFjQHQEwVtZJGDpxbH1MeYluwCS8Xq5wmLJooDlMgvVarmWfGM44g==", "dev": true, "license": "MIT", - "peerDependencies": { - "eslint": ">=2.3.0" + "dependencies": { + "assert-plus": "^1.0.0" + }, + "engines": { + "node": ">=0.10" } }, - "node_modules/eslint-plugin-prettier": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/eslint-plugin-prettier/-/eslint-plugin-prettier-5.2.1.tgz", - "integrity": "sha512-gH3iR3g4JfF+yYPaJYkN7jEl9QbweL/YfkoRlNnuIEHEz1vHVlCmWOS+eGGiRuzHQXdJFCOTxRgvju9b8VUmrw==", - "dev": true, + "node_modules/data-view-buffer": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/data-view-buffer/-/data-view-buffer-1.0.1.tgz", + "integrity": "sha512-0lht7OugA5x3iJLOWFhWK/5ehONdprk0ISXqVFn/NFrDu+cuc8iADFrGQz5BnRK7LLU3JmkbXSxaqX+/mXYtUA==", "license": "MIT", "dependencies": { - "prettier-linter-helpers": "^1.0.0", - "synckit": "^0.9.1" + "call-bind": "^1.0.6", + "es-errors": "^1.3.0", + "is-data-view": "^1.0.1" }, "engines": { - "node": "^14.18.0 || >=16.0.0" + "node": ">= 0.4" }, "funding": { - "url": "https://opencollective.com/eslint-plugin-prettier" + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/data-view-byte-length": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/data-view-byte-length/-/data-view-byte-length-1.0.1.tgz", + "integrity": "sha512-4J7wRJD3ABAzr8wP+OcIcqq2dlUKp4DVflx++hs5h5ZKydWMI6/D/fAot+yh6g2tHh8fLFTvNOaVN357NvSrOQ==", + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.7", + "es-errors": "^1.3.0", + "is-data-view": "^1.0.1" }, - "peerDependencies": { - "@types/eslint": ">=8.0.0", - "eslint": ">=8.0.0", - "eslint-config-prettier": "*", - "prettier": ">=3.0.0" + "engines": { + "node": ">= 0.4" }, - "peerDependenciesMeta": { - "@types/eslint": { - "optional": true - }, - "eslint-config-prettier": { - "optional": true - } + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/eslint-plugin-react": { - "version": "7.36.1", - "resolved": "https://registry.npmjs.org/eslint-plugin-react/-/eslint-plugin-react-7.36.1.tgz", - "integrity": "sha512-/qwbqNXZoq+VP30s1d4Nc1C5GTxjJQjk4Jzs4Wq2qzxFM7dSmuG2UkIjg2USMLh3A/aVcUNrK7v0J5U1XEGGwA==", + "node_modules/data-view-byte-offset": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/data-view-byte-offset/-/data-view-byte-offset-1.0.0.tgz", + "integrity": "sha512-t/Ygsytq+R995EJ5PZlD4Cu56sWa8InXySaViRzw9apusqsOO2bQP+SbYzAhR0pFKoB+43lYy8rWban9JSuXnA==", + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.6", + "es-errors": "^1.3.0", + "is-data-view": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/dayjs": { + "version": "1.11.13", + "resolved": "https://registry.npmjs.org/dayjs/-/dayjs-1.11.13.tgz", + "integrity": "sha512-oaMBel6gjolK862uaPQOVTA7q3TZhuSvuMQAAglQDOWYO9A91IrAOUJEyKVlqJlHE0vq5p5UXxzdPfMH/x6xNg==", "dev": true, + "license": "MIT" + }, + "node_modules/debug": { + "version": "4.3.7", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.7.tgz", + "integrity": "sha512-Er2nc/H7RrMXZBFCEim6TCmMk02Z8vLC2Rbi1KEBggpo0fS6l0S1nnapwmIi3yW/+GOJap1Krg4w0Hg80oCqgQ==", "license": "MIT", "dependencies": { - "array-includes": "^3.1.8", - "array.prototype.findlast": "^1.2.5", - "array.prototype.flatmap": "^1.3.2", - "array.prototype.tosorted": "^1.1.4", - "doctrine": "^2.1.0", - "es-iterator-helpers": "^1.0.19", - "estraverse": "^5.3.0", - "hasown": "^2.0.2", - "jsx-ast-utils": "^2.4.1 || ^3.0.0", - "minimatch": "^3.1.2", - "object.entries": "^1.1.8", - "object.fromentries": "^2.0.8", - "object.values": "^1.2.0", - "prop-types": "^15.8.1", - "resolve": "^2.0.0-next.5", - "semver": "^6.3.1", - "string.prototype.matchall": "^4.0.11", - "string.prototype.repeat": "^1.0.0" + "ms": "^2.1.3" }, "engines": { - "node": ">=4" + "node": ">=6.0" }, - "peerDependencies": { - "eslint": "^3 || ^4 || ^5 || ^6 || ^7 || ^8 || ^9.7" + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } } }, - "node_modules/eslint-plugin-react-hooks": { - "version": "4.6.2", - "resolved": "https://registry.npmjs.org/eslint-plugin-react-hooks/-/eslint-plugin-react-hooks-4.6.2.tgz", - "integrity": "sha512-QzliNJq4GinDBcD8gPB5v0wh6g8q3SUi6EFF0x8N/BL9PoVs0atuGc47ozMRyOWAKdwaZ5OnbOEa3WR+dSGKuQ==", + "node_modules/decompress-response": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/decompress-response/-/decompress-response-6.0.0.tgz", + "integrity": "sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==", "dev": true, "license": "MIT", + "dependencies": { + "mimic-response": "^3.1.0" + }, "engines": { "node": ">=10" }, - "peerDependencies": { - "eslint": "^3.0.0 || ^4.0.0 || ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0-0" + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/eslint-plugin-react/node_modules/doctrine": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz", - "integrity": "sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==", + "node_modules/decompress-response/node_modules/mimic-response": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-3.1.0.tgz", + "integrity": "sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==", "dev": true, - "license": "Apache-2.0", - "dependencies": { - "esutils": "^2.0.2" - }, + "license": "MIT", "engines": { - "node": ">=0.10.0" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/eslint-plugin-react/node_modules/resolve": { - "version": "2.0.0-next.5", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-2.0.0-next.5.tgz", - "integrity": "sha512-U7WjGVG9sH8tvjW5SmGbQuui75FiyjAX72HX15DwBBwF9dNiQZRQAg9nnPhYy+TUnE0+VcrttuvNI8oSxZcocA==", + "node_modules/deep-equal": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/deep-equal/-/deep-equal-2.2.3.tgz", + "integrity": "sha512-ZIwpnevOurS8bpT4192sqAowWM76JDKSHYzMLty3BZGSswgq6pBaH3DhCSW5xVAZICZyKdOBPjwww5wfgT/6PA==", "dev": true, "license": "MIT", "dependencies": { - "is-core-module": "^2.13.0", - "path-parse": "^1.0.7", - "supports-preserve-symlinks-flag": "^1.0.0" + "array-buffer-byte-length": "^1.0.0", + "call-bind": "^1.0.5", + "es-get-iterator": "^1.1.3", + "get-intrinsic": "^1.2.2", + "is-arguments": "^1.1.1", + "is-array-buffer": "^3.0.2", + "is-date-object": "^1.0.5", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "isarray": "^2.0.5", + "object-is": "^1.1.5", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.5.1", + "side-channel": "^1.0.4", + "which-boxed-primitive": "^1.0.2", + "which-collection": "^1.0.1", + "which-typed-array": "^1.1.13" }, - "bin": { - "resolve": "bin/resolve" + "engines": { + "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/eslint-plugin-sonarjs": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/eslint-plugin-sonarjs/-/eslint-plugin-sonarjs-1.0.4.tgz", - "integrity": "sha512-jF0eGCUsq/HzMub4ExAyD8x1oEgjOyB9XVytYGyWgSFvdiJQJp6IuP7RmtauCf06o6N/kZErh+zW4b10y1WZ+Q==", + "node_modules/deep-is": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz", + "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==", "dev": true, - "license": "LGPL-3.0-only", - "engines": { - "node": ">=16" - }, - "peerDependencies": { - "eslint": "^8.0.0 || ^9.0.0" - } + "license": "MIT" }, - "node_modules/eslint-scope": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.1.1.tgz", - "integrity": "sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw==", + "node_modules/deepmerge": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-4.3.1.tgz", + "integrity": "sha512-3sUqbMEc77XqpdNO7FRyRog+eW3ph+GYCbj+rK+uYyRMuwsVy0rMiVtPn+QJlKFvWP/1PYpapqYn0Me2knFn+A==", "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "esrecurse": "^4.3.0", - "estraverse": "^4.1.1" - }, + "license": "MIT", "engines": { - "node": ">=8.0.0" + "node": ">=0.10.0" } }, - "node_modules/eslint-scope/node_modules/estraverse": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.3.0.tgz", - "integrity": "sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==", + "node_modules/default-gateway": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/default-gateway/-/default-gateway-6.0.3.tgz", + "integrity": "sha512-fwSOJsbbNzZ/CUFpqFBqYfYNLj1NbMPm8MMCIzHjC83iSJRBEGmDUxU+WP661BaBQImeC2yHwXtz+P/O9o+XEg==", "dev": true, "license": "BSD-2-Clause", + "dependencies": { + "execa": "^5.0.0" + }, "engines": { - "node": ">=4.0" + "node": ">= 10" } }, - "node_modules/eslint-visitor-keys": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-2.1.0.tgz", - "integrity": "sha512-0rSmRBzXgDzIsD6mGdJgevzgezI534Cer5L/vyMX0kHzT/jiB43jRhd9YUlMGYLQy2zprNmoT8qasCGtY+QaKw==", + "node_modules/default-gateway/node_modules/execa": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", + "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", "dev": true, - "license": "Apache-2.0", + "license": "MIT", + "dependencies": { + "cross-spawn": "^7.0.3", + "get-stream": "^6.0.0", + "human-signals": "^2.1.0", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.1", + "onetime": "^5.1.2", + "signal-exit": "^3.0.3", + "strip-final-newline": "^2.0.0" + }, "engines": { "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/execa?sponsor=1" } }, - "node_modules/eslint/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/default-gateway/node_modules/get-stream": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", + "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", "dev": true, "license": "MIT", - "dependencies": { - "color-convert": "^2.0.1" - }, "engines": { - "node": ">=8" + "node": ">=10" }, "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/eslint/node_modules/argparse": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", - "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", + "node_modules/default-gateway/node_modules/human-signals": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", + "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", "dev": true, - "license": "Python-2.0" + "license": "Apache-2.0", + "engines": { + "node": ">=10.17.0" + } }, - "node_modules/eslint/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/defaults": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/defaults/-/defaults-1.0.4.tgz", + "integrity": "sha512-eFuaLoy/Rxalv2kr+lqMlUnrDWV+3j4pljOIJgLIhI058IQfWJ7vXhyEIHu+HtC738klGALYxOKDO0bQP3tg8A==", "dev": true, "license": "MIT", "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" + "clone": "^1.0.2" }, "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/eslint/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/defaults/node_modules/clone": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/clone/-/clone-1.0.4.tgz", + "integrity": "sha512-JQHZ2QMW6l3aH/j6xCqQThY/9OH4D/9ls34cgkUBiEeocRTU04tHfKPBsUK1PqZCUQM7GiA0IIXJSuXHI64Kbg==", "dev": true, "license": "MIT", - "dependencies": { - "color-name": "~1.1.4" - }, "engines": { - "node": ">=7.0.0" + "node": ">=0.8" } }, - "node_modules/eslint/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true, - "license": "MIT" - }, - "node_modules/eslint/node_modules/escape-string-regexp": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", - "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", + "node_modules/defer-to-connect": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/defer-to-connect/-/defer-to-connect-2.0.1.tgz", + "integrity": "sha512-4tvttepXG1VaYGrRibk5EwJd1t4udunSOVMdLSAL6mId1ix438oPwPZMALY41FCijukO1L0twNcGsdzS7dHgDg==", "dev": true, "license": "MIT", "engines": { "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/eslint/node_modules/eslint-scope": { - "version": "7.2.2", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.2.2.tgz", - "integrity": "sha512-dOt21O7lTMhDM+X9mB4GX+DZrZtCUJPL/wlcTqxyrx5IvO0IYtILdtrQGQp+8n5S0gwSVmOf9NQrjMOgfQZlIg==", - "dev": true, - "license": "BSD-2-Clause", + "node_modules/define-data-property": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.4.tgz", + "integrity": "sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==", + "license": "MIT", "dependencies": { - "esrecurse": "^4.3.0", - "estraverse": "^5.2.0" + "es-define-property": "^1.0.0", + "es-errors": "^1.3.0", + "gopd": "^1.0.1" }, "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "node": ">= 0.4" }, "funding": { - "url": "https://opencollective.com/eslint" + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/eslint/node_modules/eslint-visitor-keys": { - "version": "3.4.3", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz", - "integrity": "sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==", + "node_modules/define-lazy-prop": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/define-lazy-prop/-/define-lazy-prop-2.0.0.tgz", + "integrity": "sha512-Ds09qNh8yw3khSjiJjiUInaGX9xlqZDY7JVryGxdxV7NPeuqQfplOpQ66yJFZut3jLa5zOwkXw1g9EI2uKh4Og==", "dev": true, - "license": "Apache-2.0", + "license": "MIT", "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" + "node": ">=8" } }, - "node_modules/eslint/node_modules/globals": { - "version": "13.24.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.24.0.tgz", - "integrity": "sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==", - "dev": true, + "node_modules/define-properties": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.1.tgz", + "integrity": "sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==", "license": "MIT", "dependencies": { - "type-fest": "^0.20.2" + "define-data-property": "^1.0.1", + "has-property-descriptors": "^1.0.0", + "object-keys": "^1.1.1" }, "engines": { - "node": ">=8" + "node": ">= 0.4" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/eslint/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/delayed-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", + "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", "dev": true, "license": "MIT", "engines": { - "node": ">=8" + "node": ">=0.4.0" } }, - "node_modules/eslint/node_modules/js-yaml": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", - "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", + "node_modules/delegate": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/delegate/-/delegate-3.2.0.tgz", + "integrity": "sha512-IofjkYBZaZivn0V8nnsMJGBr4jVLxHDheKSW88PyxS5QC4Vo9ZbZVvhzlSxY87fVq3STR6r+4cGepyHkcWOQSw==", + "license": "MIT" + }, + "node_modules/depd": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", + "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==", "dev": true, "license": "MIT", - "dependencies": { - "argparse": "^2.0.1" - }, - "bin": { - "js-yaml": "bin/js-yaml.js" + "engines": { + "node": ">= 0.8" } }, - "node_modules/eslint/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/destroy": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/destroy/-/destroy-1.2.0.tgz", + "integrity": "sha512-2sJGJTaXIIaR1w4iJSNoN0hnMY7Gpc/n8D4qSCJw8QqFWXf7cuAgnEHxBpweaVcPevC2l3KpjYCx3NypQQgaJg==", "dev": true, "license": "MIT", - "dependencies": { - "has-flag": "^4.0.0" - }, "engines": { - "node": ">=8" + "node": ">= 0.8", + "npm": "1.2.8000 || >= 1.4.16" } }, - "node_modules/eslint/node_modules/type-fest": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", - "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", + "node_modules/detect-libc": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-1.0.3.tgz", + "integrity": "sha512-pGjwhsmsp4kL2RTz08wcOlGN83otlqHeD/Z5T8GXZB+/YcpQ/dgo+lbU8ZsGxV0HIvqqxo9l7mqYwyYMD9bKDg==", "dev": true, - "license": "(MIT OR CC0-1.0)", - "engines": { - "node": ">=10" + "license": "Apache-2.0", + "optional": true, + "bin": { + "detect-libc": "bin/detect-libc.js" }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "engines": { + "node": ">=0.10" } }, - "node_modules/espree": { - "version": "9.6.1", - "resolved": "https://registry.npmjs.org/espree/-/espree-9.6.1.tgz", - "integrity": "sha512-oruZaFkjorTpF32kDSI5/75ViwGeZginGGy2NoOSg3Q9bnwlnmDm4HLnkl0RE3n+njDXR037aY1+x58Z/zFdwQ==", + "node_modules/detect-node": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/detect-node/-/detect-node-2.1.0.tgz", + "integrity": "sha512-T0NIuQpnTvFDATNuHN5roPwSBG83rFsuO+MXXH9/3N1eFbn4wcPjttvjMLEPWJ0RGUYgQE7cGgS3tNxbqCGM7g==", "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "acorn": "^8.9.0", - "acorn-jsx": "^5.3.2", - "eslint-visitor-keys": "^3.4.1" - }, + "license": "MIT" + }, + "node_modules/diff": { + "version": "3.5.0", + "resolved": "https://registry.npmjs.org/diff/-/diff-3.5.0.tgz", + "integrity": "sha512-A46qtFgd+g7pDZinpnwiRJtxbC1hpgf0uzP3iG89scHk0AUC7A1TGxf5OiiOUv/JMZR8GOt8hL900hV0bOy5xA==", + "license": "BSD-3-Clause", "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" + "node": ">=0.3.1" } }, - "node_modules/espree/node_modules/eslint-visitor-keys": { - "version": "3.4.3", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz", - "integrity": "sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==", + "node_modules/dir-glob": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/dir-glob/-/dir-glob-3.0.1.tgz", + "integrity": "sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==", "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "license": "MIT", + "dependencies": { + "path-type": "^4.0.0" }, - "funding": { - "url": "https://opencollective.com/eslint" + "engines": { + "node": ">=8" } }, - "node_modules/esprima": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", - "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", - "license": "BSD-2-Clause", + "node_modules/direction": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/direction/-/direction-1.0.4.tgz", + "integrity": "sha512-GYqKi1aH7PJXxdhTeZBFrg8vUBeKXi+cNprXsC1kpJcbcVnV9wBsrOu1cQEdG0WeQwlfHiy3XvnKfIrJ2R0NzQ==", + "license": "MIT", "bin": { - "esparse": "bin/esparse.js", - "esvalidate": "bin/esvalidate.js" + "direction": "cli.js" }, - "engines": { - "node": ">=4" + "funding": { + "type": "github", + "url": "https://github.com/sponsors/wooorm" } }, - "node_modules/esquery": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.6.0.tgz", - "integrity": "sha512-ca9pw9fomFcKPvFLXhBKUK90ZvGibiGOvRJNbjljY7s7uq/5YO4BOzcYtJqExdx99rF6aAcnRxHmcUHcz6sQsg==", + "node_modules/dns-packet": { + "version": "5.6.1", + "resolved": "https://registry.npmjs.org/dns-packet/-/dns-packet-5.6.1.tgz", + "integrity": "sha512-l4gcSouhcgIKRvyy99RNVOgxXiicE+2jZoNmaNmZ6JXiGajBOJAesk1OBlJuM5k2c+eudGdLxDqXuPCKIj6kpw==", "dev": true, - "license": "BSD-3-Clause", + "license": "MIT", "dependencies": { - "estraverse": "^5.1.0" + "@leichtgewicht/ip-codec": "^2.0.1" }, "engines": { - "node": ">=0.10" + "node": ">=6" } }, - "node_modules/esrecurse": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz", - "integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==", + "node_modules/docker-compose": { + "version": "0.24.8", + "resolved": "https://registry.npmjs.org/docker-compose/-/docker-compose-0.24.8.tgz", + "integrity": "sha512-plizRs/Vf15H+GCVxq2EUvyPK7ei9b/cVesHvjnX4xaXjM9spHe2Ytq0BitndFgvTJ3E3NljPNUEl7BAN43iZw==", "dev": true, - "license": "BSD-2-Clause", + "license": "MIT", "dependencies": { - "estraverse": "^5.2.0" + "yaml": "^2.2.2" }, "engines": { - "node": ">=4.0" + "node": ">= 6.0.0" } }, - "node_modules/estraverse": { - "version": "5.3.0", - "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz", - "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==", + "node_modules/doctrine": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", + "integrity": "sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==", "dev": true, - "license": "BSD-2-Clause", - "engines": { - "node": ">=4.0" - } - }, - "node_modules/esutils": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", - "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", - "license": "BSD-2-Clause", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/etag": { - "version": "1.8.1", - "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", - "integrity": "sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg==", - "license": "MIT", + "license": "Apache-2.0", + "dependencies": { + "esutils": "^2.0.2" + }, "engines": { - "node": ">= 0.6" + "node": ">=6.0.0" } }, - "node_modules/event-target-shim": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/event-target-shim/-/event-target-shim-5.0.1.tgz", - "integrity": "sha512-i/2XbnSz/uxRCU6+NdVJgKWDTM427+MqYbkQzD321DuCQJUqOuJKIA0IM2+W2xtYHdKOmZ4dR6fExsd4SXL+WQ==", + "node_modules/document.contains": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/document.contains/-/document.contains-1.0.2.tgz", + "integrity": "sha512-YcvYFs15mX8m3AO1QNQy3BlIpSMfNRj3Ujk2BEJxsZG+HZf7/hZ6jr7mDpXrF8q+ff95Vef5yjhiZxm8CGJr6Q==", "license": "MIT", - "peer": true, - "engines": { - "node": ">=6" + "dependencies": { + "define-properties": "^1.1.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/eventemitter2": { - "version": "6.4.7", - "resolved": "https://registry.npmjs.org/eventemitter2/-/eventemitter2-6.4.7.tgz", - "integrity": "sha512-tYUSVOGeQPKt/eC1ABfhHy5Xd96N3oIijJvN3O9+TsC28T5V9yX9oEfEK5faP0EFSNVOG97qtAS68GBrQB2hDg==", - "dev": true, - "license": "MIT" - }, - "node_modules/eventemitter3": { - "version": "4.0.7", - "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.7.tgz", - "integrity": "sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw==", - "dev": true, + "node_modules/dom-scroll-into-view": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/dom-scroll-into-view/-/dom-scroll-into-view-1.2.1.tgz", + "integrity": "sha512-LwNVg3GJOprWDO+QhLL1Z9MMgWe/KAFLxVWKzjRTxNSPn8/LLDIfmuG71YHznXCqaqTjvHJDYO1MEAgX6XCNbQ==", "license": "MIT" }, - "node_modules/events": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/events/-/events-3.3.0.tgz", - "integrity": "sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q==", + "node_modules/dom-serializer": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-2.0.0.tgz", + "integrity": "sha512-wIkAryiqt/nV5EQKqQpo3SToSOV9J0DnbJqwK7Wv/Trc92zIAYZ4FlMu+JPFW1DfGFt81ZTCGgDEabffXeLyJg==", "dev": true, "license": "MIT", - "engines": { - "node": ">=0.8.x" + "dependencies": { + "domelementtype": "^2.3.0", + "domhandler": "^5.0.2", + "entities": "^4.2.0" + }, + "funding": { + "url": "https://github.com/cheeriojs/dom-serializer?sponsor=1" } }, - "node_modules/execa": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/execa/-/execa-4.1.0.tgz", - "integrity": "sha512-j5W0//W7f8UxAn8hXVnwG8tLwdiUy4FJLcSupCg6maBYZDpyBvTApK7KyuI4bKj8KOh1r2YH+6ucuYtJv1bTZA==", + "node_modules/domelementtype": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.3.0.tgz", + "integrity": "sha512-OLETBj6w0OsagBwdXnPdN0cnMfF9opN69co+7ZrbfPGrdpPVNBUj02spi6B1N7wChLQiPn4CSH/zJvXw56gmHw==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/fb55" + } + ], + "license": "BSD-2-Clause" + }, + "node_modules/domhandler": { + "version": "5.0.3", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-5.0.3.tgz", + "integrity": "sha512-cgwlv/1iFQiFnU96XXgROh8xTeetsnJiDsTc7TYCLFd9+/WNkIqPTxiM/8pSd8VIrhXGTf1Ny1q1hquVqDJB5w==", "dev": true, - "license": "MIT", + "license": "BSD-2-Clause", "dependencies": { - "cross-spawn": "^7.0.0", - "get-stream": "^5.0.0", - "human-signals": "^1.1.1", - "is-stream": "^2.0.0", - "merge-stream": "^2.0.0", - "npm-run-path": "^4.0.0", - "onetime": "^5.1.0", - "signal-exit": "^3.0.2", - "strip-final-newline": "^2.0.0" + "domelementtype": "^2.3.0" }, "engines": { - "node": ">=10" + "node": ">= 4" }, "funding": { - "url": "https://github.com/sindresorhus/execa?sponsor=1" + "url": "https://github.com/fb55/domhandler?sponsor=1" } }, - "node_modules/executable": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/executable/-/executable-4.1.1.tgz", - "integrity": "sha512-8iA79xD3uAch729dUG8xaaBBFGaEa0wdD2VkYLFHwlqosEj/jT66AzcreRDSgV7ehnNLBW2WR5jIXwGKjVdTLg==", + "node_modules/domutils": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-3.1.0.tgz", + "integrity": "sha512-H78uMmQtI2AhgDJjWeQmHwJJ2bLPD3GMmO7Zja/ZZh84wkm+4ut+IUnUdRa8uCGX88DiVx1j6FRe1XfxEgjEZA==", "dev": true, - "license": "MIT", + "license": "BSD-2-Clause", "dependencies": { - "pify": "^2.2.0" + "dom-serializer": "^2.0.0", + "domelementtype": "^2.3.0", + "domhandler": "^5.0.3" }, - "engines": { - "node": ">=4" + "funding": { + "url": "https://github.com/fb55/domutils?sponsor=1" } }, - "node_modules/exponential-backoff": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/exponential-backoff/-/exponential-backoff-3.1.1.tgz", - "integrity": "sha512-dX7e/LHVJ6W3DE1MHWi9S1EYzDESENfLrYohG2G++ovZrYOkm4Knwa0mc1cn84xJOR4KEU0WSchhLbd0UklbHw==", - "license": "Apache-2.0", - "peer": true - }, - "node_modules/express": { - "version": "4.21.1", - "resolved": "https://registry.npmjs.org/express/-/express-4.21.1.tgz", - "integrity": "sha512-YSFlK1Ee0/GC8QaO91tHcDxJiE/X4FbpAyQWkxAvG6AXCuR65YzK8ua6D9hvi/TzUfZMpc+BwuM1IPw8fmQBiQ==", + "node_modules/dot-case": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/dot-case/-/dot-case-3.0.4.tgz", + "integrity": "sha512-Kv5nKlh6yRrdrGvxeJ2e5y2eRUpkUosIW4A2AS38zwSz27zu7ufDwQPi5Jhs3XAlGNetl3bmnGhQsMtkKJnj3w==", "dev": true, + "license": "MIT", "dependencies": { - "accepts": "~1.3.8", - "array-flatten": "1.1.1", - "body-parser": "1.20.3", - "content-disposition": "0.5.4", - "content-type": "~1.0.4", - "cookie": "0.7.1", - "cookie-signature": "1.0.6", - "debug": "2.6.9", - "depd": "2.0.0", - "encodeurl": "~2.0.0", - "escape-html": "~1.0.3", - "etag": "~1.8.1", - "finalhandler": "1.3.1", - "fresh": "0.5.2", - "http-errors": "2.0.0", - "merge-descriptors": "1.0.3", - "methods": "~1.1.2", - "on-finished": "2.4.1", - "parseurl": "~1.3.3", - "path-to-regexp": "0.1.10", - "proxy-addr": "~2.0.7", - "qs": "6.13.0", - "range-parser": "~1.2.1", - "safe-buffer": "5.2.1", - "send": "0.19.0", - "serve-static": "1.16.2", - "setprototypeof": "1.2.0", - "statuses": "2.0.1", - "type-is": "~1.6.18", - "utils-merge": "1.0.1", - "vary": "~1.1.2" - }, - "engines": { - "node": ">= 0.10.0" + "no-case": "^3.0.4", + "tslib": "^2.0.3" } }, - "node_modules/express/node_modules/debug": { - "version": "2.6.9", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "node_modules/dot-case/node_modules/tslib": { + "version": "2.7.0", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.7.0.tgz", + "integrity": "sha512-gLXCKdN1/j47AiHiOkJN69hJmcbGTHI0ImLmbYLHykhgeN0jVGola9yVjFgzCUklsZQMW55o+dW7IXv3RCXDzA==", + "dev": true, + "license": "0BSD" + }, + "node_modules/eastasianwidth": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/eastasianwidth/-/eastasianwidth-0.2.0.tgz", + "integrity": "sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==", + "dev": true, + "license": "MIT" + }, + "node_modules/ecc-jsbn": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz", + "integrity": "sha512-eh9O+hwRHNbG4BLTjEl3nw044CkGm5X6LoaCf7LPp7UU8Qrt47JYNi6nPX8xjW97TKGKm1ouctg0QSpZe9qrnw==", "dev": true, "license": "MIT", "dependencies": { - "ms": "2.0.0" + "jsbn": "~0.1.0", + "safer-buffer": "^2.1.0" } }, - "node_modules/express/node_modules/ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", + "node_modules/ee-first": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", + "integrity": "sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==", "dev": true, "license": "MIT" }, - "node_modules/extend": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.2.tgz", - "integrity": "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==", + "node_modules/electron-to-chromium": { + "version": "1.5.141", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.141.tgz", + "integrity": "sha512-qS+qH9oqVYc1ooubTiB9l904WVyM6qNYxtOEEGReoZXw3xlqeYdFr5GclNzbkAufWgwWLEPoDi3d9MoRwwIjGw==", + "dev": true, + "license": "ISC" + }, + "node_modules/emoji-regex": { + "version": "9.2.2", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-9.2.2.tgz", + "integrity": "sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==", "dev": true, "license": "MIT" }, - "node_modules/external-editor": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/external-editor/-/external-editor-3.1.0.tgz", - "integrity": "sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew==", + "node_modules/encodeurl": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.0.tgz", + "integrity": "sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==", "dev": true, "license": "MIT", - "dependencies": { - "chardet": "^0.7.0", - "iconv-lite": "^0.4.24", - "tmp": "^0.0.33" - }, "engines": { - "node": ">=4" + "node": ">= 0.8" } }, - "node_modules/external-editor/node_modules/iconv-lite": { - "version": "0.4.24", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", - "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", - "dev": true, + "node_modules/encoding": { + "version": "0.1.13", + "resolved": "https://registry.npmjs.org/encoding/-/encoding-0.1.13.tgz", + "integrity": "sha512-ETBauow1T35Y/WZMkio9jiM0Z5xjHHmJ4XmjZOq1l/dXz3lr2sRn87nJy20RupqSh1F2m3HHPSp8ShIPQJrJ3A==", "license": "MIT", "dependencies": { - "safer-buffer": ">= 2.1.2 < 3" - }, - "engines": { - "node": ">=0.10.0" + "iconv-lite": "^0.6.2" } }, - "node_modules/external-editor/node_modules/tmp": { - "version": "0.0.33", - "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.0.33.tgz", - "integrity": "sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==", + "node_modules/end-of-stream": { + "version": "1.4.4", + "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz", + "integrity": "sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==", "dev": true, "license": "MIT", "dependencies": { - "os-tmpdir": "~1.0.2" - }, - "engines": { - "node": ">=0.6.0" + "once": "^1.4.0" } }, - "node_modules/extract-zip": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/extract-zip/-/extract-zip-1.7.0.tgz", - "integrity": "sha512-xoh5G1W/PB0/27lXgMQyIhP5DSY/LhoCsOyZgb+6iMmRtCwVBo55uKaMoEYrDCKQhWvqEip5ZPKAc6eFNyf/MA==", + "node_modules/enhanced-resolve": { + "version": "0.9.1", + "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-0.9.1.tgz", + "integrity": "sha512-kxpoMgrdtkXZ5h0SeraBS1iRntpTpQ3R8ussdb38+UAFnMGX5DDyJXePm+OCHOcoXvHDw7mc2erbJBpDnl7TPw==", "dev": true, - "license": "BSD-2-Clause", "dependencies": { - "concat-stream": "^1.6.2", - "debug": "^2.6.9", - "mkdirp": "^0.5.4", - "yauzl": "^2.10.0" + "graceful-fs": "^4.1.2", + "memory-fs": "^0.2.0", + "tapable": "^0.1.8" }, - "bin": { - "extract-zip": "cli.js" + "engines": { + "node": ">=0.6" } }, - "node_modules/extract-zip/node_modules/debug": { - "version": "2.6.9", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "node_modules/enquirer": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/enquirer/-/enquirer-2.4.1.tgz", + "integrity": "sha512-rRqJg/6gd538VHvR3PSrdRBb/1Vy2YfzHqzvbhGIQpDRKIa4FgV/54b5Q1xYSxOOwKvjXweS26E0Q+nAMwp2pQ==", "dev": true, "license": "MIT", "dependencies": { - "ms": "2.0.0" + "ansi-colors": "^4.1.1", + "strip-ansi": "^6.0.1" + }, + "engines": { + "node": ">=8.6" } }, - "node_modules/extract-zip/node_modules/ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", - "dev": true, - "license": "MIT" - }, - "node_modules/extsprintf": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz", - "integrity": "sha512-11Ndz7Nv+mvAC1j0ktTa7fAb0vLyGGX+rMHNBYQviQDGU0Hw7lhctJANqbPhu9nV9/izT/IntTgZ7Im/9LJs9g==", - "dev": true, - "engines": [ - "node >=0.6.0" - ], - "license": "MIT" - }, - "node_modules/fast-deep-equal": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", - "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", + "node_modules/entities": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-4.5.0.tgz", + "integrity": "sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==", "dev": true, - "license": "MIT" + "license": "BSD-2-Clause", + "engines": { + "node": ">=0.12" + }, + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } }, - "node_modules/fast-diff": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/fast-diff/-/fast-diff-1.3.0.tgz", - "integrity": "sha512-VxPP4NqbUjj6MaAOafWeUn2cXWLcCtljklUtZf0Ind4XQ+QPtmA0b18zZy0jIQx+ExRVCR/ZQpBmik5lXshNsw==", + "node_modules/env-paths": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/env-paths/-/env-paths-2.2.1.tgz", + "integrity": "sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A==", "dev": true, - "license": "Apache-2.0" - }, - "node_modules/fast-glob": { - "version": "3.3.3", - "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.3.tgz", - "integrity": "sha512-7MptL8U0cqcFdzIzwOTHoilX9x5BrNqye7Z/LuC7kCMRio1EMSyqRK3BEAUD7sXRq4iT4AzTVuZdhgQ2TCvYLg==", "license": "MIT", - "dependencies": { - "@nodelib/fs.stat": "^2.0.2", - "@nodelib/fs.walk": "^1.2.3", - "glob-parent": "^5.1.2", - "merge2": "^1.3.0", - "micromatch": "^4.0.8" - }, "engines": { - "node": ">=8.6.0" + "node": ">=6" } }, - "node_modules/fast-glob/node_modules/glob-parent": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", - "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", - "license": "ISC", - "dependencies": { - "is-glob": "^4.0.1" + "node_modules/envinfo": { + "version": "7.14.0", + "resolved": "https://registry.npmjs.org/envinfo/-/envinfo-7.14.0.tgz", + "integrity": "sha512-CO40UI41xDQzhLB1hWyqUKgFhs250pNcGbyGKe1l/e4FSaI/+YE4IMG76GDt0In67WLPACIITC+sOi08x4wIvg==", + "dev": true, + "license": "MIT", + "bin": { + "envinfo": "dist/cli.js" }, "engines": { - "node": ">= 6" + "node": ">=4" } }, - "node_modules/fast-json-stable-stringify": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", - "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==", - "dev": true, - "license": "MIT" - }, - "node_modules/fast-levenshtein": { - "version": "2.0.6", - "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", - "integrity": "sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==", - "dev": true, + "node_modules/equivalent-key-map": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/equivalent-key-map/-/equivalent-key-map-0.2.2.tgz", + "integrity": "sha512-xvHeyCDbZzkpN4VHQj/n+j2lOwL0VWszG30X4cOrc9Y7Tuo2qCdZK/0AMod23Z5dCtNUbaju6p0rwOhHUk05ew==", "license": "MIT" }, - "node_modules/fast-uri": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/fast-uri/-/fast-uri-3.0.1.tgz", - "integrity": "sha512-MWipKbbYiYI0UC7cl8m/i/IWTqfC8YXsqjzybjddLsFjStroQzsHXkc73JutMvBiXmOvapk+axIl79ig5t55Bw==", + "node_modules/error-ex": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", + "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==", "dev": true, - "license": "MIT" - }, - "node_modules/fast-xml-parser": { - "version": "4.5.0", - "resolved": "https://registry.npmjs.org/fast-xml-parser/-/fast-xml-parser-4.5.0.tgz", - "integrity": "sha512-/PlTQCI96+fZMAOLMZK4CWG1ItCbfZ/0jx7UIJFChPNrx7tcEgerUgWbeieCM9MfHInUDyK8DWYZ+YrywDJuTg==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/NaturalIntelligence" - }, - { - "type": "paypal", - "url": "https://paypal.me/naturalintelligence" - } - ], "license": "MIT", - "peer": true, "dependencies": { - "strnum": "^1.0.5" - }, - "bin": { - "fxparser": "src/cli/cli.js" + "is-arrayish": "^0.2.1" } }, - "node_modules/fastest-levenshtein": { - "version": "1.0.16", - "resolved": "https://registry.npmjs.org/fastest-levenshtein/-/fastest-levenshtein-1.0.16.tgz", - "integrity": "sha512-eRnCtTTtGZFpQCwhJiUOuxPQWRXVKYDn0b2PeHfXL6/Zi53SLAzAHfVhVWK2AryC/WH05kGfxhFIPvTF0SXQzg==", - "dev": true, + "node_modules/es-abstract": { + "version": "1.23.3", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.23.3.tgz", + "integrity": "sha512-e+HfNH61Bj1X9/jLc5v1owaLYuHdeHHSQlkhCBiTK8rBvKaULl/beGMxwrMXjpYrv4pz22BlY570vVePA2ho4A==", "license": "MIT", - "engines": { - "node": ">= 4.9.1" - } - }, - "node_modules/fastq": { - "version": "1.17.1", - "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.17.1.tgz", - "integrity": "sha512-sRVD3lWVIXWg6By68ZN7vho9a1pQcN/WBFaAAsDDFzlJjvoGx0P8z7V1t72grFJfJhu3YPZBuu25f7Kaw2jN1w==", - "license": "ISC", "dependencies": { - "reusify": "^1.0.4" + "array-buffer-byte-length": "^1.0.1", + "arraybuffer.prototype.slice": "^1.0.3", + "available-typed-arrays": "^1.0.7", + "call-bind": "^1.0.7", + "data-view-buffer": "^1.0.1", + "data-view-byte-length": "^1.0.1", + "data-view-byte-offset": "^1.0.0", + "es-define-property": "^1.0.0", + "es-errors": "^1.3.0", + "es-object-atoms": "^1.0.0", + "es-set-tostringtag": "^2.0.3", + "es-to-primitive": "^1.2.1", + "function.prototype.name": "^1.1.6", + "get-intrinsic": "^1.2.4", + "get-symbol-description": "^1.0.2", + "globalthis": "^1.0.3", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.2", + "has-proto": "^1.0.3", + "has-symbols": "^1.0.3", + "hasown": "^2.0.2", + "internal-slot": "^1.0.7", + "is-array-buffer": "^3.0.4", + "is-callable": "^1.2.7", + "is-data-view": "^1.0.1", + "is-negative-zero": "^2.0.3", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.3", + "is-string": "^1.0.7", + "is-typed-array": "^1.1.13", + "is-weakref": "^1.0.2", + "object-inspect": "^1.13.1", + "object-keys": "^1.1.1", + "object.assign": "^4.1.5", + "regexp.prototype.flags": "^1.5.2", + "safe-array-concat": "^1.1.2", + "safe-regex-test": "^1.0.3", + "string.prototype.trim": "^1.2.9", + "string.prototype.trimend": "^1.0.8", + "string.prototype.trimstart": "^1.0.8", + "typed-array-buffer": "^1.0.2", + "typed-array-byte-length": "^1.0.1", + "typed-array-byte-offset": "^1.0.2", + "typed-array-length": "^1.0.6", + "unbox-primitive": "^1.0.2", + "which-typed-array": "^1.1.15" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/faye-websocket": { - "version": "0.11.4", - "resolved": "https://registry.npmjs.org/faye-websocket/-/faye-websocket-0.11.4.tgz", - "integrity": "sha512-CzbClwlXAuiRQAlUyfqPgvPoNKTckTPGfwZV4ZdAhVcP2lh9KUxJg2b5GkE7XbjKQ3YJnQ9z6D9ntLAlB+tP8g==", - "dev": true, - "license": "Apache-2.0", + "node_modules/es-define-property": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.0.tgz", + "integrity": "sha512-jxayLKShrEqqzJ0eumQbVhTYQM27CfT1T35+gCgDFoL82JLsXqTJ76zv6A0YLOgEnLUMvLzsDsGIrl8NFpT2gQ==", + "license": "MIT", "dependencies": { - "websocket-driver": ">=0.5.1" + "get-intrinsic": "^1.2.4" }, "engines": { - "node": ">=0.8.0" + "node": ">= 0.4" } }, - "node_modules/fb-watchman": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/fb-watchman/-/fb-watchman-2.0.2.tgz", - "integrity": "sha512-p5161BqbuCaSnB8jIbzQHOlpgsPmK5rJVDfDKO91Axs5NC1uu3HRQm6wt9cd9/+GtQQIO53JdGXXoyDpTAsgYA==", - "license": "Apache-2.0", - "peer": true, - "dependencies": { - "bser": "2.1.1" + "node_modules/es-errors": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz", + "integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==", + "license": "MIT", + "engines": { + "node": ">= 0.4" } }, - "node_modules/fd-slicer": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/fd-slicer/-/fd-slicer-1.1.0.tgz", - "integrity": "sha512-cE1qsB/VwyQozZ+q1dGxR8LBYNZeofhEdUNGSMbQD3Gw2lAzX9Zb3uIU6Ebc/Fmyjo9AWWfnn0AUCHqtevs/8g==", + "node_modules/es-get-iterator": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.3.tgz", + "integrity": "sha512-sPZmqHBe6JIiTfN5q2pEi//TwxmAFHwj/XEuYjTuse78i8KxaqMTTzxPoFKuzRpDpTJ+0NAbpfenkmH2rePtuw==", "dev": true, "license": "MIT", "dependencies": { - "pend": "~1.2.0" + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "has-symbols": "^1.0.3", + "is-arguments": "^1.1.1", + "is-map": "^2.0.2", + "is-set": "^2.0.2", + "is-string": "^1.0.7", + "isarray": "^2.0.5", + "stop-iteration-iterator": "^1.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/figures": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/figures/-/figures-3.2.0.tgz", - "integrity": "sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg==", + "node_modules/es-iterator-helpers": { + "version": "1.0.19", + "resolved": "https://registry.npmjs.org/es-iterator-helpers/-/es-iterator-helpers-1.0.19.tgz", + "integrity": "sha512-zoMwbCcH5hwUkKJkT8kDIBZSz9I6mVG//+lDCinLCGov4+r7NIy0ld8o03M0cJxl2spVf6ESYVS6/gpIfq1FFw==", "dev": true, "license": "MIT", "dependencies": { - "escape-string-regexp": "^1.0.5" + "call-bind": "^1.0.7", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.3", + "es-errors": "^1.3.0", + "es-set-tostringtag": "^2.0.3", + "function-bind": "^1.1.2", + "get-intrinsic": "^1.2.4", + "globalthis": "^1.0.3", + "has-property-descriptors": "^1.0.2", + "has-proto": "^1.0.3", + "has-symbols": "^1.0.3", + "internal-slot": "^1.0.7", + "iterator.prototype": "^1.1.2", + "safe-array-concat": "^1.1.2" }, "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "node": ">= 0.4" } }, - "node_modules/file-entry-cache": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-6.0.1.tgz", - "integrity": "sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==", + "node_modules/es-module-lexer": { + "version": "1.5.4", + "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.5.4.tgz", + "integrity": "sha512-MVNK56NiMrOwitFB7cqDwq0CQutbw+0BvLshJSse0MUNU+y1FC3bUS/AQg7oUng+/wKrrki7JfmwtVHkVfPLlw==", "dev": true, + "license": "MIT" + }, + "node_modules/es-object-atoms": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/es-object-atoms/-/es-object-atoms-1.0.0.tgz", + "integrity": "sha512-MZ4iQ6JwHOBQjahnjwaC1ZtIBH+2ohjamzAO3oaHcXYup7qxjF2fixyH+Q71voWHeOkI2q/TnJao/KfXYIZWbw==", "license": "MIT", "dependencies": { - "flat-cache": "^3.0.4" + "es-errors": "^1.3.0" }, "engines": { - "node": "^10.12.0 || >=12.0.0" + "node": ">= 0.4" } }, - "node_modules/fill-range": { - "version": "7.1.1", - "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", - "integrity": "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==", + "node_modules/es-set-tostringtag": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.0.3.tgz", + "integrity": "sha512-3T8uNMC3OQTHkFUsFq8r/BwAXLHvU/9O9mE0fBc/MY5iq/8H7ncvO947LmYA6ldWw9Uh8Yhf25zu6n7nML5QWQ==", "license": "MIT", "dependencies": { - "to-regex-range": "^5.0.1" + "get-intrinsic": "^1.2.4", + "has-tostringtag": "^1.0.2", + "hasown": "^2.0.1" }, "engines": { - "node": ">=8" + "node": ">= 0.4" } }, - "node_modules/finalhandler": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.3.1.tgz", - "integrity": "sha512-6BN9trH7bp3qvnrRyzsBz+g3lZxTNZTbVO2EV1CS0WIcDbawYVdYvGflME/9QP0h0pYlCDBCTjYa9nZzMDpyxQ==", - "dev": true, + "node_modules/es-shim-unscopables": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/es-shim-unscopables/-/es-shim-unscopables-1.0.2.tgz", + "integrity": "sha512-J3yBRXCzDu4ULnQwxyToo/OjdMx6akgVC7K6few0a7F/0wLtmKKN7I73AH5T2836UuXRqN7Qg+IIUw/+YJksRw==", + "license": "MIT", + "dependencies": { + "hasown": "^2.0.0" + } + }, + "node_modules/es-to-primitive": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", + "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", "license": "MIT", "dependencies": { - "debug": "2.6.9", - "encodeurl": "~2.0.0", - "escape-html": "~1.0.3", - "on-finished": "2.4.1", - "parseurl": "~1.3.3", - "statuses": "2.0.1", - "unpipe": "~1.0.0" + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" }, "engines": { - "node": ">= 0.8" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/finalhandler/node_modules/debug": { - "version": "2.6.9", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "node_modules/escalade": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.2.0.tgz", + "integrity": "sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==", "dev": true, "license": "MIT", - "dependencies": { - "ms": "2.0.0" + "engines": { + "node": ">=6" } }, - "node_modules/finalhandler/node_modules/ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", + "node_modules/escape-html": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", + "integrity": "sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow==", "dev": true, "license": "MIT" }, - "node_modules/find-cache-dir": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-4.0.0.tgz", - "integrity": "sha512-9ZonPT4ZAK4a+1pUPVPZJapbi7O5qbbJPdYw/NOQWZZbVLdDTYM3A4R9z/DpAM08IDaFGsvPgiGZ82WEwUDWjg==", + "node_modules/escape-string-regexp": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", + "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", "dev": true, "license": "MIT", - "dependencies": { - "common-path-prefix": "^3.0.0", - "pkg-dir": "^7.0.0" - }, "engines": { - "node": ">=14.16" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "node": ">=0.8.0" } }, - "node_modules/find-root": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/find-root/-/find-root-1.1.0.tgz", - "integrity": "sha512-NKfW6bec6GfKc0SGx1e07QZY9PE99u0Bft/0rzSD5k3sO/vwkVUpDUKVm5Gpp5Ue3YfShPFTX2070tDs5kB9Ng==", + "node_modules/eslint": { + "version": "8.57.1", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.57.1.tgz", + "integrity": "sha512-ypowyDxpVSYpkXr9WPv2PAZCtNip1Mv5KTW0SCurXv/9iOpcrH9PaqUElksqEB6pChqHGDRCFTyrZlGhnLNGiA==", "dev": true, - "license": "MIT" - }, - "node_modules/find-up": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", - "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", "license": "MIT", "dependencies": { - "locate-path": "^6.0.0", - "path-exists": "^4.0.0" + "@eslint-community/eslint-utils": "^4.2.0", + "@eslint-community/regexpp": "^4.6.1", + "@eslint/eslintrc": "^2.1.4", + "@eslint/js": "8.57.1", + "@humanwhocodes/config-array": "^0.13.0", + "@humanwhocodes/module-importer": "^1.0.1", + "@nodelib/fs.walk": "^1.2.8", + "@ungap/structured-clone": "^1.2.0", + "ajv": "^6.12.4", + "chalk": "^4.0.0", + "cross-spawn": "^7.0.2", + "debug": "^4.3.2", + "doctrine": "^3.0.0", + "escape-string-regexp": "^4.0.0", + "eslint-scope": "^7.2.2", + "eslint-visitor-keys": "^3.4.3", + "espree": "^9.6.1", + "esquery": "^1.4.2", + "esutils": "^2.0.2", + "fast-deep-equal": "^3.1.3", + "file-entry-cache": "^6.0.1", + "find-up": "^5.0.0", + "glob-parent": "^6.0.2", + "globals": "^13.19.0", + "graphemer": "^1.4.0", + "ignore": "^5.2.0", + "imurmurhash": "^0.1.4", + "is-glob": "^4.0.0", + "is-path-inside": "^3.0.3", + "js-yaml": "^4.1.0", + "json-stable-stringify-without-jsonify": "^1.0.1", + "levn": "^0.4.1", + "lodash.merge": "^4.6.2", + "minimatch": "^3.1.2", + "natural-compare": "^1.4.0", + "optionator": "^0.9.3", + "strip-ansi": "^6.0.1", + "text-table": "^0.2.0" + }, + "bin": { + "eslint": "bin/eslint.js" }, "engines": { - "node": ">=10" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://opencollective.com/eslint" } }, - "node_modules/flat": { - "version": "5.0.2", - "resolved": "https://registry.npmjs.org/flat/-/flat-5.0.2.tgz", - "integrity": "sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ==", + "node_modules/eslint-config-prettier": { + "version": "8.10.0", + "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-8.10.0.tgz", + "integrity": "sha512-SM8AMJdeQqRYT9O9zguiruQZaN7+z+E4eAP9oiLNGKMtomwaB1E9dcgUD6ZAn/eQAb52USbvezbiljfZUhbJcg==", "dev": true, - "license": "BSD-3-Clause", + "license": "MIT", "bin": { - "flat": "cli.js" + "eslint-config-prettier": "bin/cli.js" + }, + "peerDependencies": { + "eslint": ">=7.0.0" } }, - "node_modules/flat-cache": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-3.2.0.tgz", - "integrity": "sha512-CYcENa+FtcUKLmhhqyctpclsq7QF38pKjZHsGNiSQF5r4FtoKDWabFDl3hzaEQMvT1LHEysw5twgLvpYYb4vbw==", + "node_modules/eslint-import-resolver-node": { + "version": "0.3.9", + "resolved": "https://registry.npmjs.org/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.9.tgz", + "integrity": "sha512-WFj2isz22JahUv+B788TlO3N6zL3nNJGU8CcZbPZvVEkBPaJdCV4vy5wyghty5ROFbCRnm132v8BScu5/1BQ8g==", "dev": true, "license": "MIT", "dependencies": { - "flatted": "^3.2.9", - "keyv": "^4.5.3", - "rimraf": "^3.0.2" - }, - "engines": { - "node": "^10.12.0 || >=12.0.0" + "debug": "^3.2.7", + "is-core-module": "^2.13.0", + "resolve": "^1.22.4" } }, - "node_modules/flatted": { - "version": "3.3.3", - "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.3.3.tgz", - "integrity": "sha512-GX+ysw4PBCz0PzosHDepZGANEuFCMLrnRTiEy9McGjmkCQYwRq4A/X786G/fjM/+OjsWSU1ZrY5qyARZmO/uwg==", + "node_modules/eslint-import-resolver-node/node_modules/debug": { + "version": "3.2.7", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", + "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", "dev": true, - "license": "ISC" - }, - "node_modules/flow-enums-runtime": { - "version": "0.0.6", - "resolved": "https://registry.npmjs.org/flow-enums-runtime/-/flow-enums-runtime-0.0.6.tgz", - "integrity": "sha512-3PYnM29RFXwvAN6Pc/scUfkI7RwhQ/xqyLUyPNlXUp9S40zI8nup9tUSrTLSVnWGBN38FNiGWbwZOB6uR4OGdw==", - "license": "MIT", - "peer": true - }, - "node_modules/flow-parser": { - "version": "0.246.0", - "resolved": "https://registry.npmjs.org/flow-parser/-/flow-parser-0.246.0.tgz", - "integrity": "sha512-WHRizzSrWFTcKo7cVcbP3wzZVhzsoYxoWqbnH4z+JXGqrjVmnsld6kBZWVlB200PwD5ur8r+HV3KUDxv3cHhOQ==", "license": "MIT", - "peer": true, - "engines": { - "node": ">=0.4.0" + "dependencies": { + "ms": "^2.1.1" } }, - "node_modules/follow-redirects": { - "version": "1.15.9", - "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.9.tgz", - "integrity": "sha512-gew4GsXizNgdoRyqmyfMHyAmXsZDk6mHkSxZFCzW9gwlbtOW44CDtYavM+y+72qD/Vq2l550kMF52DT8fOLJqQ==", + "node_modules/eslint-import-resolver-webpack": { + "version": "0.13.9", + "resolved": "https://registry.npmjs.org/eslint-import-resolver-webpack/-/eslint-import-resolver-webpack-0.13.9.tgz", + "integrity": "sha512-yGngeefNiHXau2yzKKs2BNON4HLpxBabY40BGL/vUSKZtqzjlVsTTZm57jhHULhm+mJEwKsEIIN3NXup5AiiBQ==", "dev": true, - "funding": [ - { - "type": "individual", - "url": "https://github.com/sponsors/RubenVerborgh" - } - ], "license": "MIT", + "dependencies": { + "debug": "^3.2.7", + "enhanced-resolve": "^0.9.1", + "find-root": "^1.1.0", + "hasown": "^2.0.0", + "interpret": "^1.4.0", + "is-core-module": "^2.13.1", + "is-regex": "^1.1.4", + "lodash": "^4.17.21", + "resolve": "^2.0.0-next.5", + "semver": "^5.7.2" + }, "engines": { - "node": ">=4.0" + "node": ">= 6" }, - "peerDependenciesMeta": { - "debug": { - "optional": true - } + "peerDependencies": { + "eslint-plugin-import": ">=1.4.0", + "webpack": ">=1.11.0" } }, - "node_modules/for-each": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz", - "integrity": "sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==", + "node_modules/eslint-import-resolver-webpack/node_modules/debug": { + "version": "3.2.7", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", + "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "dev": true, "license": "MIT", "dependencies": { - "is-callable": "^1.1.3" + "ms": "^2.1.1" } }, - "node_modules/foreground-child": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-3.3.0.tgz", - "integrity": "sha512-Ld2g8rrAyMYFXBhEqMz8ZAHBi4J4uS1i/CxGMDnjyFWddMXLVcDp051DZfu+t7+ab7Wv6SMqpWmyFIj5UbfFvg==", + "node_modules/eslint-import-resolver-webpack/node_modules/resolve": { + "version": "2.0.0-next.5", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-2.0.0-next.5.tgz", + "integrity": "sha512-U7WjGVG9sH8tvjW5SmGbQuui75FiyjAX72HX15DwBBwF9dNiQZRQAg9nnPhYy+TUnE0+VcrttuvNI8oSxZcocA==", "dev": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "cross-spawn": "^7.0.0", - "signal-exit": "^4.0.1" + "is-core-module": "^2.13.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" }, - "engines": { - "node": ">=14" + "bin": { + "resolve": "bin/resolve" }, "funding": { - "url": "https://github.com/sponsors/isaacs" + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/foreground-child/node_modules/signal-exit": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", - "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", + "node_modules/eslint-import-resolver-webpack/node_modules/semver": { + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz", + "integrity": "sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==", "dev": true, "license": "ISC", + "bin": { + "semver": "bin/semver" + } + }, + "node_modules/eslint-module-utils": { + "version": "2.11.0", + "resolved": "https://registry.npmjs.org/eslint-module-utils/-/eslint-module-utils-2.11.0.tgz", + "integrity": "sha512-gbBE5Hitek/oG6MUVj6sFuzEjA/ClzNflVrLovHi/JgLdC7fiN5gLAY1WIPW1a0V5I999MnsrvVrCOGmmVqDBQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "debug": "^3.2.7" + }, "engines": { - "node": ">=14" + "node": ">=4" }, - "funding": { - "url": "https://github.com/sponsors/isaacs" + "peerDependenciesMeta": { + "eslint": { + "optional": true + } } }, - "node_modules/forever-agent": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz", - "integrity": "sha512-j0KLYPhm6zeac4lz3oJ3o65qvgQCcPubiyotZrXqEaG4hNagNYO8qdlUrX5vwqv9ohqeT/Z3j6+yW067yWWdUw==", + "node_modules/eslint-module-utils/node_modules/debug": { + "version": "3.2.7", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", + "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "*" + "license": "MIT", + "dependencies": { + "ms": "^2.1.1" } }, - "node_modules/form-data": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz", - "integrity": "sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==", + "node_modules/eslint-plugin-compat": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-compat/-/eslint-plugin-compat-4.2.0.tgz", + "integrity": "sha512-RDKSYD0maWy5r7zb5cWQS+uSPc26mgOzdORJ8hxILmWM7S/Ncwky7BcAtXVY5iRbKjBdHsWU8Yg7hfoZjtkv7w==", "dev": true, "license": "MIT", "dependencies": { - "asynckit": "^0.4.0", - "combined-stream": "^1.0.8", - "mime-types": "^2.1.12" + "@mdn/browser-compat-data": "^5.3.13", + "ast-metadata-inferer": "^0.8.0", + "browserslist": "^4.21.10", + "caniuse-lite": "^1.0.30001524", + "find-up": "^5.0.0", + "lodash.memoize": "^4.1.2", + "semver": "^7.5.4" }, "engines": { - "node": ">= 6" + "node": ">=14.x" + }, + "peerDependencies": { + "eslint": "^4.0.0 || ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0" } }, - "node_modules/forwarded": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.2.0.tgz", - "integrity": "sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow==", + "node_modules/eslint-plugin-compat/node_modules/semver": { + "version": "7.6.3", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", + "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", "dev": true, - "license": "MIT", + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, "engines": { - "node": ">= 0.6" + "node": ">=10" } }, - "node_modules/fresh": { - "version": "0.5.2", - "resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz", - "integrity": "sha512-zJ2mQYM18rEFOudeV4GShTGIQ7RbzA7ozbU9I/XBpm7kqgMywgmylMwXHxZJmkVoYkna9d2pVXVXPdYTP9ej8Q==", + "node_modules/eslint-plugin-cypress": { + "version": "3.5.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-cypress/-/eslint-plugin-cypress-3.5.0.tgz", + "integrity": "sha512-JZQ6XnBTNI8h1B9M7wJSFzc48SYbh7VMMKaNTQOFa3BQlnmXPrVc4PKen8R+fpv6VleiPeej6VxloGb42zdRvw==", + "dev": true, "license": "MIT", - "engines": { - "node": ">= 0.6" + "dependencies": { + "globals": "^13.20.0" + }, + "peerDependencies": { + "eslint": ">=7" } }, - "node_modules/fs-extra": { - "version": "9.1.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", - "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "node_modules/eslint-plugin-cypress/node_modules/globals": { + "version": "13.24.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-13.24.0.tgz", + "integrity": "sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==", "dev": true, "license": "MIT", "dependencies": { - "at-least-node": "^1.0.0", - "graceful-fs": "^4.2.0", - "jsonfile": "^6.0.1", - "universalify": "^2.0.0" + "type-fest": "^0.20.2" }, "engines": { - "node": ">=10" + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/fs-monkey": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/fs-monkey/-/fs-monkey-1.0.6.tgz", - "integrity": "sha512-b1FMfwetIKymC0eioW7mTywihSQE4oLzQn1dB6rZB5fx/3NpNEdAWeCSMB+60/AeT0TCXsxzAlcYVEFCTAksWg==", + "node_modules/eslint-plugin-cypress/node_modules/type-fest": { + "version": "0.20.2", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", + "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", "dev": true, - "license": "Unlicense" - }, - "node_modules/fs.realpath": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", - "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==", - "license": "ISC" - }, - "node_modules/fsevents": { - "version": "2.3.3", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", - "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", - "hasInstallScript": true, - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], + "license": "(MIT OR CC0-1.0)", "engines": { - "node": "^8.16.0 || ^10.6.0 || >=11.0.0" - } - }, - "node_modules/function-bind": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", - "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", - "license": "MIT", + "node": ">=10" + }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/function.prototype.name": { - "version": "1.1.6", - "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.6.tgz", - "integrity": "sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg==", + "node_modules/eslint-plugin-import": { + "version": "2.30.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-import/-/eslint-plugin-import-2.30.0.tgz", + "integrity": "sha512-/mHNE9jINJfiD2EKkg1BKyPyUk4zdnT54YgbOgfjSakWT5oyX/qQLVNTkehyfpcMxZXMy1zyonZ2v7hZTX43Yw==", + "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.2", - "define-properties": "^1.2.0", - "es-abstract": "^1.22.1", - "functions-have-names": "^1.2.3" + "@rtsao/scc": "^1.1.0", + "array-includes": "^3.1.8", + "array.prototype.findlastindex": "^1.2.5", + "array.prototype.flat": "^1.3.2", + "array.prototype.flatmap": "^1.3.2", + "debug": "^3.2.7", + "doctrine": "^2.1.0", + "eslint-import-resolver-node": "^0.3.9", + "eslint-module-utils": "^2.9.0", + "hasown": "^2.0.2", + "is-core-module": "^2.15.1", + "is-glob": "^4.0.3", + "minimatch": "^3.1.2", + "object.fromentries": "^2.0.8", + "object.groupby": "^1.0.3", + "object.values": "^1.2.0", + "semver": "^6.3.1", + "tsconfig-paths": "^3.15.0" }, "engines": { - "node": ">= 0.4" + "node": ">=4" }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "peerDependencies": { + "eslint": "^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8" } }, - "node_modules/functions-have-names": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz", - "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==", + "node_modules/eslint-plugin-import/node_modules/debug": { + "version": "3.2.7", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", + "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "dev": true, "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/ljharb" + "dependencies": { + "ms": "^2.1.1" } }, - "node_modules/gensync": { - "version": "1.0.0-beta.2", - "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.2.tgz", - "integrity": "sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==", - "license": "MIT", + "node_modules/eslint-plugin-import/node_modules/doctrine": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz", + "integrity": "sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "esutils": "^2.0.2" + }, "engines": { - "node": ">=6.9.0" + "node": ">=0.10.0" } }, - "node_modules/get-caller-file": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", - "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", - "license": "ISC", + "node_modules/eslint-plugin-jest": { + "version": "27.9.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-jest/-/eslint-plugin-jest-27.9.0.tgz", + "integrity": "sha512-QIT7FH7fNmd9n4se7FFKHbsLKGQiw885Ds6Y/sxKgCZ6natwCsXdgPOADnYVxN2QrRweF0FZWbJ6S7Rsn7llug==", + "dev": true, + "license": "MIT", + "dependencies": { + "@typescript-eslint/utils": "^5.10.0" + }, "engines": { - "node": "6.* || 8.* || >= 10.*" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + }, + "peerDependencies": { + "@typescript-eslint/eslint-plugin": "^5.0.0 || ^6.0.0 || ^7.0.0", + "eslint": "^7.0.0 || ^8.0.0", + "jest": "*" + }, + "peerDependenciesMeta": { + "@typescript-eslint/eslint-plugin": { + "optional": true + }, + "jest": { + "optional": true + } } }, - "node_modules/get-intrinsic": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.4.tgz", - "integrity": "sha512-5uYhsJH8VJBTv7oslg4BznJYhDoRI6waYCxMmCdnTrcCrHA/fCFKoTFz2JKKE0HdDFUF7/oQuhzumXJK7paBRQ==", - "license": "MIT", + "node_modules/eslint-plugin-jsdoc": { + "version": "48.11.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-jsdoc/-/eslint-plugin-jsdoc-48.11.0.tgz", + "integrity": "sha512-d12JHJDPNo7IFwTOAItCeJY1hcqoIxE0lHA8infQByLilQ9xkqrRa6laWCnsuCrf+8rUnvxXY1XuTbibRBNylA==", + "dev": true, + "license": "BSD-3-Clause", "dependencies": { - "es-errors": "^1.3.0", - "function-bind": "^1.1.2", - "has-proto": "^1.0.1", - "has-symbols": "^1.0.3", - "hasown": "^2.0.0" + "@es-joy/jsdoccomment": "~0.46.0", + "are-docs-informative": "^0.0.2", + "comment-parser": "1.4.1", + "debug": "^4.3.5", + "escape-string-regexp": "^4.0.0", + "espree": "^10.1.0", + "esquery": "^1.6.0", + "parse-imports": "^2.1.1", + "semver": "^7.6.3", + "spdx-expression-parse": "^4.0.0", + "synckit": "^0.9.1" }, "engines": { - "node": ">= 0.4" + "node": ">=18" }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "peerDependencies": { + "eslint": "^7.0.0 || ^8.0.0 || ^9.0.0" } }, - "node_modules/get-stream": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-5.2.0.tgz", - "integrity": "sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==", + "node_modules/eslint-plugin-jsdoc/node_modules/escape-string-regexp": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", + "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", "dev": true, "license": "MIT", - "dependencies": { - "pump": "^3.0.0" - }, "engines": { - "node": ">=8" + "node": ">=10" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/get-symbol-description": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.2.tgz", - "integrity": "sha512-g0QYk1dZBxGwk+Ngc+ltRH2IBp2f7zBkBMBJZCDerh6EhlhSR6+9irMCuT/09zD6qkarHUSn529sK/yL4S27mg==", - "license": "MIT", - "dependencies": { - "call-bind": "^1.0.5", - "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.4" - }, + "node_modules/eslint-plugin-jsdoc/node_modules/eslint-visitor-keys": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-4.0.0.tgz", + "integrity": "sha512-OtIRv/2GyiF6o/d8K7MYKKbXrOUBIK6SfkIRM4Z0dY3w+LiQ0vy3F57m0Z71bjbyeiWFiHJ8brqnmE6H6/jEuw==", + "dev": true, + "license": "Apache-2.0", "engines": { - "node": ">= 0.4" + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" }, "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/getos": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/getos/-/getos-3.2.1.tgz", - "integrity": "sha512-U56CfOK17OKgTVqozZjUKNdkfEv6jk5WISBJ8SHoagjE6L69zOwl3Z+O8myjY9MEW3i2HPWQBt/LTbCgcC973Q==", - "dev": true, - "license": "MIT", - "dependencies": { - "async": "^3.2.0" - } - }, - "node_modules/getpass": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz", - "integrity": "sha512-0fzj9JxOLfJ+XGLhR8ze3unN0KZCgZwiSSDz168VERjK8Wl8kVSdcu2kspd4s4wtAa1y/qrVRiAA0WclVsu0ng==", - "dev": true, - "license": "MIT", - "dependencies": { - "assert-plus": "^1.0.0" - } - }, - "node_modules/gettext-parser": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/gettext-parser/-/gettext-parser-1.4.0.tgz", - "integrity": "sha512-sedZYLHlHeBop/gZ1jdg59hlUEcpcZJofLq2JFwJT1zTqAU3l2wFv6IsuwFHGqbiT9DWzMUW4/em2+hspnmMMA==", - "license": "MIT", - "dependencies": { - "encoding": "^0.1.12", - "safe-buffer": "^5.1.1" + "url": "https://opencollective.com/eslint" } }, - "node_modules/glob": { - "version": "10.4.5", - "resolved": "https://registry.npmjs.org/glob/-/glob-10.4.5.tgz", - "integrity": "sha512-7Bv8RF0k6xjo7d4A/PxYLbUCfb6c+Vpd2/mB2yRDlew7Jb5hEXiCD9ibfO7wpk8i4sevK6DFny9h7EYbM3/sHg==", + "node_modules/eslint-plugin-jsdoc/node_modules/espree": { + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/espree/-/espree-10.1.0.tgz", + "integrity": "sha512-M1M6CpiE6ffoigIOWYO9UDP8TMUw9kqb21tf+08IgDYjCsOvCuDt4jQcZmoYxx+w7zlKw9/N0KXfto+I8/FrXA==", "dev": true, - "license": "ISC", + "license": "BSD-2-Clause", "dependencies": { - "foreground-child": "^3.1.0", - "jackspeak": "^3.1.2", - "minimatch": "^9.0.4", - "minipass": "^7.1.2", - "package-json-from-dist": "^1.0.0", - "path-scurry": "^1.11.1" + "acorn": "^8.12.0", + "acorn-jsx": "^5.3.2", + "eslint-visitor-keys": "^4.0.0" }, - "bin": { - "glob": "dist/esm/bin.mjs" + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" }, "funding": { - "url": "https://github.com/sponsors/isaacs" + "url": "https://opencollective.com/eslint" } }, - "node_modules/glob-parent": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz", - "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==", + "node_modules/eslint-plugin-jsdoc/node_modules/semver": { + "version": "7.6.3", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", + "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", "dev": true, "license": "ISC", - "dependencies": { - "is-glob": "^4.0.3" + "bin": { + "semver": "bin/semver.js" }, "engines": { - "node": ">=10.13.0" + "node": ">=10" } }, - "node_modules/glob-to-regexp": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz", - "integrity": "sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==", - "dev": true, - "license": "BSD-2-Clause" - }, - "node_modules/glob/node_modules/brace-expansion": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz", - "integrity": "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==", + "node_modules/eslint-plugin-jsx-a11y": { + "version": "6.10.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-jsx-a11y/-/eslint-plugin-jsx-a11y-6.10.0.tgz", + "integrity": "sha512-ySOHvXX8eSN6zz8Bywacm7CvGNhUtdjvqfQDVe6020TUK34Cywkw7m0KsCCk1Qtm9G1FayfTN1/7mMYnYO2Bhg==", "dev": true, "license": "MIT", "dependencies": { - "balanced-match": "^1.0.0" - } - }, - "node_modules/glob/node_modules/minimatch": { - "version": "9.0.5", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.5.tgz", - "integrity": "sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^2.0.1" + "aria-query": "~5.1.3", + "array-includes": "^3.1.8", + "array.prototype.flatmap": "^1.3.2", + "ast-types-flow": "^0.0.8", + "axe-core": "^4.10.0", + "axobject-query": "^4.1.0", + "damerau-levenshtein": "^1.0.8", + "emoji-regex": "^9.2.2", + "es-iterator-helpers": "^1.0.19", + "hasown": "^2.0.2", + "jsx-ast-utils": "^3.3.5", + "language-tags": "^1.0.9", + "minimatch": "^3.1.2", + "object.fromentries": "^2.0.8", + "safe-regex-test": "^1.0.3", + "string.prototype.includes": "^2.0.0" }, "engines": { - "node": ">=16 || 14 >=14.17" + "node": ">=4.0" }, - "funding": { - "url": "https://github.com/sponsors/isaacs" + "peerDependencies": { + "eslint": "^3 || ^4 || ^5 || ^6 || ^7 || ^8 || ^9" } }, - "node_modules/global-cache": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/global-cache/-/global-cache-1.2.1.tgz", - "integrity": "sha512-EOeUaup5DgWKlCMhA9YFqNRIlZwoxt731jCh47WBV9fQqHgXhr3Fa55hfgIUqilIcPsfdNKN7LHjrNY+Km40KA==", + "node_modules/eslint-plugin-no-jquery": { + "version": "2.7.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-no-jquery/-/eslint-plugin-no-jquery-2.7.0.tgz", + "integrity": "sha512-Aeg7dA6GTH1AcWLlBtWNzOU9efK5KpNi7b0EhBO0o0M+awyzguUUo8gF6hXGjQ9n5h8/uRtYv9zOqQkeC5CG0w==", + "dev": true, "license": "MIT", - "dependencies": { - "define-properties": "^1.1.2", - "is-symbol": "^1.0.1" - }, - "engines": { - "node": ">= 0.4" + "peerDependencies": { + "eslint": ">=2.3.0" } }, - "node_modules/global-dirs": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/global-dirs/-/global-dirs-3.0.1.tgz", - "integrity": "sha512-NBcGGFbBA9s1VzD41QXDG+3++t9Mn5t1FpLdhESY6oKY4gYTFpX4wO3sqGUa0Srjtbfj3szX0RnemmrVRUdULA==", + "node_modules/eslint-plugin-prettier": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/eslint-plugin-prettier/-/eslint-plugin-prettier-5.2.1.tgz", + "integrity": "sha512-gH3iR3g4JfF+yYPaJYkN7jEl9QbweL/YfkoRlNnuIEHEz1vHVlCmWOS+eGGiRuzHQXdJFCOTxRgvju9b8VUmrw==", "dev": true, "license": "MIT", "dependencies": { - "ini": "2.0.0" + "prettier-linter-helpers": "^1.0.0", + "synckit": "^0.9.1" }, "engines": { - "node": ">=10" + "node": "^14.18.0 || >=16.0.0" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/global-modules": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/global-modules/-/global-modules-2.0.0.tgz", - "integrity": "sha512-NGbfmJBp9x8IxyJSd1P+otYK8vonoJactOogrVfFRIAEY1ukil8RSKDz2Yo7wh1oihl51l/r6W4epkeKJHqL8A==", - "dev": true, - "license": "MIT", - "dependencies": { - "global-prefix": "^3.0.0" + "url": "https://opencollective.com/eslint-plugin-prettier" }, - "engines": { - "node": ">=6" + "peerDependencies": { + "@types/eslint": ">=8.0.0", + "eslint": ">=8.0.0", + "eslint-config-prettier": "*", + "prettier": ">=3.0.0" + }, + "peerDependenciesMeta": { + "@types/eslint": { + "optional": true + }, + "eslint-config-prettier": { + "optional": true + } } }, - "node_modules/global-prefix": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/global-prefix/-/global-prefix-3.0.0.tgz", - "integrity": "sha512-awConJSVCHVGND6x3tmMaKcQvwXLhjdkmomy2W+Goaui8YPgYgXJZewhg3fWC+DlfqqQuWg8AwqjGTD2nAPVWg==", + "node_modules/eslint-plugin-react": { + "version": "7.36.1", + "resolved": "https://registry.npmjs.org/eslint-plugin-react/-/eslint-plugin-react-7.36.1.tgz", + "integrity": "sha512-/qwbqNXZoq+VP30s1d4Nc1C5GTxjJQjk4Jzs4Wq2qzxFM7dSmuG2UkIjg2USMLh3A/aVcUNrK7v0J5U1XEGGwA==", "dev": true, "license": "MIT", "dependencies": { - "ini": "^1.3.5", - "kind-of": "^6.0.2", - "which": "^1.3.1" + "array-includes": "^3.1.8", + "array.prototype.findlast": "^1.2.5", + "array.prototype.flatmap": "^1.3.2", + "array.prototype.tosorted": "^1.1.4", + "doctrine": "^2.1.0", + "es-iterator-helpers": "^1.0.19", + "estraverse": "^5.3.0", + "hasown": "^2.0.2", + "jsx-ast-utils": "^2.4.1 || ^3.0.0", + "minimatch": "^3.1.2", + "object.entries": "^1.1.8", + "object.fromentries": "^2.0.8", + "object.values": "^1.2.0", + "prop-types": "^15.8.1", + "resolve": "^2.0.0-next.5", + "semver": "^6.3.1", + "string.prototype.matchall": "^4.0.11", + "string.prototype.repeat": "^1.0.0" }, "engines": { - "node": ">=6" - } - }, - "node_modules/global-prefix/node_modules/ini": { - "version": "1.3.8", - "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.8.tgz", - "integrity": "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==", - "dev": true, - "license": "ISC" - }, - "node_modules/global-prefix/node_modules/which": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", - "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", - "dev": true, - "license": "ISC", - "dependencies": { - "isexe": "^2.0.0" + "node": ">=4" }, - "bin": { - "which": "bin/which" + "peerDependencies": { + "eslint": "^3 || ^4 || ^5 || ^6 || ^7 || ^8 || ^9.7" } }, - "node_modules/globals": { - "version": "11.12.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", - "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", + "node_modules/eslint-plugin-react-hooks": { + "version": "4.6.2", + "resolved": "https://registry.npmjs.org/eslint-plugin-react-hooks/-/eslint-plugin-react-hooks-4.6.2.tgz", + "integrity": "sha512-QzliNJq4GinDBcD8gPB5v0wh6g8q3SUi6EFF0x8N/BL9PoVs0atuGc47ozMRyOWAKdwaZ5OnbOEa3WR+dSGKuQ==", + "dev": true, "license": "MIT", "engines": { - "node": ">=4" + "node": ">=10" + }, + "peerDependencies": { + "eslint": "^3.0.0 || ^4.0.0 || ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0-0" } }, - "node_modules/globalthis": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.4.tgz", - "integrity": "sha512-DpLKbNU4WylpxJykQujfCcwYWiV/Jhm50Goo0wrVILAv5jOr9d+H+UR3PhSCD2rCCEIg0uc+G+muBTwD54JhDQ==", - "license": "MIT", + "node_modules/eslint-plugin-react/node_modules/doctrine": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz", + "integrity": "sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==", + "dev": true, + "license": "Apache-2.0", "dependencies": { - "define-properties": "^1.2.1", - "gopd": "^1.0.1" + "esutils": "^2.0.2" }, "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "node": ">=0.10.0" } }, - "node_modules/globby": { - "version": "11.1.0", - "resolved": "https://registry.npmjs.org/globby/-/globby-11.1.0.tgz", - "integrity": "sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==", + "node_modules/eslint-plugin-react/node_modules/resolve": { + "version": "2.0.0-next.5", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-2.0.0-next.5.tgz", + "integrity": "sha512-U7WjGVG9sH8tvjW5SmGbQuui75FiyjAX72HX15DwBBwF9dNiQZRQAg9nnPhYy+TUnE0+VcrttuvNI8oSxZcocA==", "dev": true, "license": "MIT", "dependencies": { - "array-union": "^2.1.0", - "dir-glob": "^3.0.1", - "fast-glob": "^3.2.9", - "ignore": "^5.2.0", - "merge2": "^1.4.1", - "slash": "^3.0.0" + "is-core-module": "^2.13.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" }, - "engines": { - "node": ">=10" + "bin": { + "resolve": "bin/resolve" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/globjoin": { - "version": "0.1.4", - "resolved": "https://registry.npmjs.org/globjoin/-/globjoin-0.1.4.tgz", - "integrity": "sha512-xYfnw62CKG8nLkZBfWbhWwDw02CHty86jfPcc2cr3ZfeuK9ysoVPPEUxf21bAD/rWAgk52SuBrLJlefNy8mvFg==", + "node_modules/eslint-plugin-sonarjs": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/eslint-plugin-sonarjs/-/eslint-plugin-sonarjs-1.0.4.tgz", + "integrity": "sha512-jF0eGCUsq/HzMub4ExAyD8x1oEgjOyB9XVytYGyWgSFvdiJQJp6IuP7RmtauCf06o6N/kZErh+zW4b10y1WZ+Q==", "dev": true, - "license": "MIT" - }, - "node_modules/good-listener": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/good-listener/-/good-listener-1.2.2.tgz", - "integrity": "sha512-goW1b+d9q/HIwbVYZzZ6SsTr4IgE+WA44A0GmPIQstuOrgsFcT7VEJ48nmr9GaRtNu0XTKacFLGnBPAM6Afouw==", - "license": "MIT", - "dependencies": { - "delegate": "^3.1.2" + "license": "LGPL-3.0-only", + "engines": { + "node": ">=16" + }, + "peerDependencies": { + "eslint": "^8.0.0 || ^9.0.0" } }, - "node_modules/google-closure-compiler": { - "version": "20240317.0.0", - "resolved": "https://registry.npmjs.org/google-closure-compiler/-/google-closure-compiler-20240317.0.0.tgz", - "integrity": "sha512-PlC5aU2vwsypKbxyFNXOW4psDZfhDoOr2dCwuo8VcgQji+HVIgRi2lviO66x2SfTi0ilm3kI6rq/RSdOMFczcQ==", - "license": "Apache-2.0", + "node_modules/eslint-scope": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.1.1.tgz", + "integrity": "sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw==", + "dev": true, + "license": "BSD-2-Clause", "dependencies": { - "chalk": "4.x", - "google-closure-compiler-java": "^20240317.0.0", - "minimist": "1.x", - "vinyl": "2.x", - "vinyl-sourcemaps-apply": "^0.2.0" - }, - "bin": { - "google-closure-compiler": "cli.js" + "esrecurse": "^4.3.0", + "estraverse": "^4.1.1" }, "engines": { - "node": ">=10" - }, - "optionalDependencies": { - "google-closure-compiler-linux": "^20240317.0.0", - "google-closure-compiler-osx": "^20240317.0.0", - "google-closure-compiler-windows": "^20240317.0.0" + "node": ">=8.0.0" } }, - "node_modules/google-closure-compiler-java": { - "version": "20240317.0.0", - "resolved": "https://registry.npmjs.org/google-closure-compiler-java/-/google-closure-compiler-java-20240317.0.0.tgz", - "integrity": "sha512-oWURPChjcCrVfiQOuVtpSoUJVvtOYo41JGEQ2qtArsTGmk/DpWh40vS6hitwKRM/0YzJX/jYUuyt9ibuXXJKmg==", - "license": "Apache-2.0" - }, - "node_modules/google-closure-compiler-linux": { - "version": "20240317.0.0", - "resolved": "https://registry.npmjs.org/google-closure-compiler-linux/-/google-closure-compiler-linux-20240317.0.0.tgz", - "integrity": "sha512-dYLtcbbJdbbBS0lTy9SzySdVv/aGkpyTekQiW4ADhT/i1p1b4r0wQTKj6kpVVmFvbZ6t9tW/jbXc9EXXNUahZw==", - "cpu": [ - "x32", - "x64" - ], - "license": "Apache-2.0", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/google-closure-compiler-osx": { - "version": "20240317.0.0", - "resolved": "https://registry.npmjs.org/google-closure-compiler-osx/-/google-closure-compiler-osx-20240317.0.0.tgz", - "integrity": "sha512-0mABwjD4HP11rikFd8JRIb9OgPqn9h3o3wS0otufMfmbwS7zRpnnoJkunifhORl3VoR1gFm6vcTC9YziTEFdOw==", - "cpu": [ - "x32", - "x64", - "arm64" - ], - "license": "Apache-2.0", - "optional": true, - "os": [ - "darwin" - ] + "node_modules/eslint-scope/node_modules/estraverse": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.3.0.tgz", + "integrity": "sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=4.0" + } }, - "node_modules/google-closure-compiler-windows": { - "version": "20240317.0.0", - "resolved": "https://registry.npmjs.org/google-closure-compiler-windows/-/google-closure-compiler-windows-20240317.0.0.tgz", - "integrity": "sha512-fTueVFzNOWURFlXZmrFkAB7yA+jzpA2TeDOYeBEFwVlVGHwi8PV3Q9vCIWlbkE8wLpukKEg5wfRHYrLwVPINCA==", - "cpu": [ - "x32", - "x64" - ], + "node_modules/eslint-visitor-keys": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-2.1.0.tgz", + "integrity": "sha512-0rSmRBzXgDzIsD6mGdJgevzgezI534Cer5L/vyMX0kHzT/jiB43jRhd9YUlMGYLQy2zprNmoT8qasCGtY+QaKw==", + "dev": true, "license": "Apache-2.0", - "optional": true, - "os": [ - "win32" - ] + "engines": { + "node": ">=10" + } }, - "node_modules/google-closure-compiler/node_modules/ansi-styles": { + "node_modules/eslint/node_modules/ansi-styles": { "version": "4.3.0", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, "license": "MIT", "dependencies": { "color-convert": "^2.0.1" @@ -13235,10 +9066,18 @@ "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/google-closure-compiler/node_modules/chalk": { + "node_modules/eslint/node_modules/argparse": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", + "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", + "dev": true, + "license": "Python-2.0" + }, + "node_modules/eslint/node_modules/chalk": { "version": "4.1.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, "license": "MIT", "dependencies": { "ansi-styles": "^4.1.0", @@ -13251,10 +9090,11 @@ "url": "https://github.com/chalk/chalk?sponsor=1" } }, - "node_modules/google-closure-compiler/node_modules/color-convert": { + "node_modules/eslint/node_modules/color-convert": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, "license": "MIT", "dependencies": { "color-name": "~1.1.4" @@ -13263,25 +9103,100 @@ "node": ">=7.0.0" } }, - "node_modules/google-closure-compiler/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT" - }, - "node_modules/google-closure-compiler/node_modules/has-flag": { + "node_modules/eslint/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true, + "license": "MIT" + }, + "node_modules/eslint/node_modules/escape-string-regexp": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", + "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/eslint/node_modules/eslint-scope": { + "version": "7.2.2", + "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.2.2.tgz", + "integrity": "sha512-dOt21O7lTMhDM+X9mB4GX+DZrZtCUJPL/wlcTqxyrx5IvO0IYtILdtrQGQp+8n5S0gwSVmOf9NQrjMOgfQZlIg==", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "esrecurse": "^4.3.0", + "estraverse": "^5.2.0" + }, + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" + } + }, + "node_modules/eslint/node_modules/eslint-visitor-keys": { + "version": "3.4.3", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz", + "integrity": "sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" + } + }, + "node_modules/eslint/node_modules/globals": { + "version": "13.24.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-13.24.0.tgz", + "integrity": "sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "type-fest": "^0.20.2" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/eslint/node_modules/has-flag": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, "license": "MIT", "engines": { "node": ">=8" } }, - "node_modules/google-closure-compiler/node_modules/supports-color": { + "node_modules/eslint/node_modules/js-yaml": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", + "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", + "dev": true, + "license": "MIT", + "dependencies": { + "argparse": "^2.0.1" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" + } + }, + "node_modules/eslint/node_modules/supports-color": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, "license": "MIT", "dependencies": { "has-flag": "^4.0.0" @@ -13290,825 +9205,759 @@ "node": ">=8" } }, - "node_modules/gopd": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", - "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", - "license": "MIT", - "dependencies": { - "get-intrinsic": "^1.1.3" + "node_modules/eslint/node_modules/type-fest": { + "version": "0.20.2", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", + "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", + "dev": true, + "license": "(MIT OR CC0-1.0)", + "engines": { + "node": ">=10" }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/got": { - "version": "11.8.6", - "resolved": "https://registry.npmjs.org/got/-/got-11.8.6.tgz", - "integrity": "sha512-6tfZ91bOr7bOXnK7PRDCGBLa1H4U080YHNaAQ2KsMGlLEzRbk44nsZF2E1IeRc3vtJHPVbKCYgdFbaGO2ljd8g==", + "node_modules/espree": { + "version": "9.6.1", + "resolved": "https://registry.npmjs.org/espree/-/espree-9.6.1.tgz", + "integrity": "sha512-oruZaFkjorTpF32kDSI5/75ViwGeZginGGy2NoOSg3Q9bnwlnmDm4HLnkl0RE3n+njDXR037aY1+x58Z/zFdwQ==", "dev": true, - "license": "MIT", + "license": "BSD-2-Clause", "dependencies": { - "@sindresorhus/is": "^4.0.0", - "@szmarczak/http-timer": "^4.0.5", - "@types/cacheable-request": "^6.0.1", - "@types/responselike": "^1.0.0", - "cacheable-lookup": "^5.0.3", - "cacheable-request": "^7.0.2", - "decompress-response": "^6.0.0", - "http2-wrapper": "^1.0.0-beta.5.2", - "lowercase-keys": "^2.0.0", - "p-cancelable": "^2.0.0", - "responselike": "^2.0.0" + "acorn": "^8.9.0", + "acorn-jsx": "^5.3.2", + "eslint-visitor-keys": "^3.4.1" }, "engines": { - "node": ">=10.19.0" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" }, "funding": { - "url": "https://github.com/sindresorhus/got?sponsor=1" + "url": "https://opencollective.com/eslint" } }, - "node_modules/graceful-fs": { - "version": "4.2.11", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", - "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", - "license": "ISC" - }, - "node_modules/graphemer": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/graphemer/-/graphemer-1.4.0.tgz", - "integrity": "sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==", - "dev": true, - "license": "MIT" - }, - "node_modules/handle-thing": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/handle-thing/-/handle-thing-2.0.1.tgz", - "integrity": "sha512-9Qn4yBxelxoh2Ow62nP+Ka/kMnOXRi8BXnRaUwezLNhqelnN49xKz4F/dPP8OYLxLxq6JDtZb2i9XznUQbNPTg==", + "node_modules/espree/node_modules/eslint-visitor-keys": { + "version": "3.4.3", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz", + "integrity": "sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==", "dev": true, - "license": "MIT" - }, - "node_modules/has-bigints": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz", - "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==", - "license": "MIT", + "license": "Apache-2.0", + "engines": { + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "url": "https://opencollective.com/eslint" } }, - "node_modules/has-flag": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", - "license": "MIT", + "node_modules/esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true, + "license": "BSD-2-Clause", + "bin": { + "esparse": "bin/esparse.js", + "esvalidate": "bin/esvalidate.js" + }, "engines": { "node": ">=4" } }, - "node_modules/has-property-descriptors": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.2.tgz", - "integrity": "sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==", - "license": "MIT", + "node_modules/esquery": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.6.0.tgz", + "integrity": "sha512-ca9pw9fomFcKPvFLXhBKUK90ZvGibiGOvRJNbjljY7s7uq/5YO4BOzcYtJqExdx99rF6aAcnRxHmcUHcz6sQsg==", + "dev": true, + "license": "BSD-3-Clause", "dependencies": { - "es-define-property": "^1.0.0" + "estraverse": "^5.1.0" }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "engines": { + "node": ">=0.10" } }, - "node_modules/has-proto": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.3.tgz", - "integrity": "sha512-SJ1amZAJUiZS+PhsVLf5tGydlaVB8EdFpaSO4gmiUKUOxk8qzn5AIy4ZeJUmh22znIdk/uMAUT2pl3FxzVUH+Q==", + "node_modules/esrecurse": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz", + "integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "estraverse": "^5.2.0" + }, + "engines": { + "node": ">=4.0" + } + }, + "node_modules/estraverse": { + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz", + "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=4.0" + } + }, + "node_modules/esutils": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", + "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/etag": { + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", + "integrity": "sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg==", + "dev": true, "license": "MIT", "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "node": ">= 0.6" } }, - "node_modules/has-symbols": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", - "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==", + "node_modules/eventemitter2": { + "version": "6.4.7", + "resolved": "https://registry.npmjs.org/eventemitter2/-/eventemitter2-6.4.7.tgz", + "integrity": "sha512-tYUSVOGeQPKt/eC1ABfhHy5Xd96N3oIijJvN3O9+TsC28T5V9yX9oEfEK5faP0EFSNVOG97qtAS68GBrQB2hDg==", + "dev": true, + "license": "MIT" + }, + "node_modules/eventemitter3": { + "version": "4.0.7", + "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.7.tgz", + "integrity": "sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw==", + "dev": true, + "license": "MIT" + }, + "node_modules/events": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/events/-/events-3.3.0.tgz", + "integrity": "sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q==", + "dev": true, "license": "MIT", "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "node": ">=0.8.x" } }, - "node_modules/has-tostringtag": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.2.tgz", - "integrity": "sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==", + "node_modules/execa": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/execa/-/execa-4.1.0.tgz", + "integrity": "sha512-j5W0//W7f8UxAn8hXVnwG8tLwdiUy4FJLcSupCg6maBYZDpyBvTApK7KyuI4bKj8KOh1r2YH+6ucuYtJv1bTZA==", + "dev": true, "license": "MIT", "dependencies": { - "has-symbols": "^1.0.3" + "cross-spawn": "^7.0.0", + "get-stream": "^5.0.0", + "human-signals": "^1.1.1", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.0", + "onetime": "^5.1.0", + "signal-exit": "^3.0.2", + "strip-final-newline": "^2.0.0" }, "engines": { - "node": ">= 0.4" + "node": ">=10" }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "url": "https://github.com/sindresorhus/execa?sponsor=1" } }, - "node_modules/hasown": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", - "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==", + "node_modules/executable": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/executable/-/executable-4.1.1.tgz", + "integrity": "sha512-8iA79xD3uAch729dUG8xaaBBFGaEa0wdD2VkYLFHwlqosEj/jT66AzcreRDSgV7ehnNLBW2WR5jIXwGKjVdTLg==", + "dev": true, "license": "MIT", "dependencies": { - "function-bind": "^1.1.2" + "pify": "^2.2.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/express": { + "version": "4.21.1", + "resolved": "https://registry.npmjs.org/express/-/express-4.21.1.tgz", + "integrity": "sha512-YSFlK1Ee0/GC8QaO91tHcDxJiE/X4FbpAyQWkxAvG6AXCuR65YzK8ua6D9hvi/TzUfZMpc+BwuM1IPw8fmQBiQ==", + "dev": true, + "dependencies": { + "accepts": "~1.3.8", + "array-flatten": "1.1.1", + "body-parser": "1.20.3", + "content-disposition": "0.5.4", + "content-type": "~1.0.4", + "cookie": "0.7.1", + "cookie-signature": "1.0.6", + "debug": "2.6.9", + "depd": "2.0.0", + "encodeurl": "~2.0.0", + "escape-html": "~1.0.3", + "etag": "~1.8.1", + "finalhandler": "1.3.1", + "fresh": "0.5.2", + "http-errors": "2.0.0", + "merge-descriptors": "1.0.3", + "methods": "~1.1.2", + "on-finished": "2.4.1", + "parseurl": "~1.3.3", + "path-to-regexp": "0.1.10", + "proxy-addr": "~2.0.7", + "qs": "6.13.0", + "range-parser": "~1.2.1", + "safe-buffer": "5.2.1", + "send": "0.19.0", + "serve-static": "1.16.2", + "setprototypeof": "1.2.0", + "statuses": "2.0.1", + "type-is": "~1.6.18", + "utils-merge": "1.0.1", + "vary": "~1.1.2" }, "engines": { - "node": ">= 0.4" + "node": ">= 0.10.0" } }, - "node_modules/hermes-estree": { - "version": "0.22.0", - "resolved": "https://registry.npmjs.org/hermes-estree/-/hermes-estree-0.22.0.tgz", - "integrity": "sha512-FLBt5X9OfA8BERUdc6aZS36Xz3rRuB0Y/mfocSADWEJfomc1xfene33GdyAmtTkKTBXTN/EgAy+rjTKkkZJHlw==", - "license": "MIT", - "peer": true - }, - "node_modules/hermes-parser": { - "version": "0.22.0", - "resolved": "https://registry.npmjs.org/hermes-parser/-/hermes-parser-0.22.0.tgz", - "integrity": "sha512-gn5RfZiEXCsIWsFGsKiykekktUoh0PdFWYocXsUdZIyWSckT6UIyPcyyUIPSR3kpnELWeK3n3ztAse7Mat6PSA==", + "node_modules/express/node_modules/debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "hermes-estree": "0.22.0" + "ms": "2.0.0" } }, - "node_modules/hoist-non-react-statics": { - "version": "2.5.5", - "resolved": "https://registry.npmjs.org/hoist-non-react-statics/-/hoist-non-react-statics-2.5.5.tgz", - "integrity": "sha512-rqcy4pJo55FTTLWt+bU8ukscqHeE/e9KWvsOW2b/a3afxQZhwkQdT1rPPCJ0rYXdj4vNcasY8zHTH+jF/qStxw==", - "license": "BSD-3-Clause" - }, - "node_modules/hookified": { - "version": "1.8.2", - "resolved": "https://registry.npmjs.org/hookified/-/hookified-1.8.2.tgz", - "integrity": "sha512-5nZbBNP44sFCDjSoB//0N7m508APCgbQ4mGGo1KJGBYyCKNHfry1Pvd0JVHZIxjdnqn8nFRBAN/eFB6Rk/4w5w==", + "node_modules/express/node_modules/ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", "dev": true, "license": "MIT" }, - "node_modules/hpack.js": { - "version": "2.1.6", - "resolved": "https://registry.npmjs.org/hpack.js/-/hpack.js-2.1.6.tgz", - "integrity": "sha512-zJxVehUdMGIKsRaNt7apO2Gqp0BdqW5yaiGHXXmbpvxgBYVZnAql+BJb4RO5ad2MgpbZKn5G6nMnegrH1FcNYQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "inherits": "^2.0.1", - "obuf": "^1.0.0", - "readable-stream": "^2.0.1", - "wbuf": "^1.1.0" - } - }, - "node_modules/html-entities": { - "version": "2.5.2", - "resolved": "https://registry.npmjs.org/html-entities/-/html-entities-2.5.2.tgz", - "integrity": "sha512-K//PSRMQk4FZ78Kyau+mZurHn3FH0Vwr+H36eE0rPbeYkRRi9YxceYPhuN60UwWorxyKHhqoAJl2OFKa4BVtaA==", + "node_modules/extend": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.2.tgz", + "integrity": "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==", "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/mdevils" - }, - { - "type": "patreon", - "url": "https://patreon.com/mdevils" - } - ], "license": "MIT" }, - "node_modules/html-tags": { - "version": "3.3.1", - "resolved": "https://registry.npmjs.org/html-tags/-/html-tags-3.3.1.tgz", - "integrity": "sha512-ztqyC3kLto0e9WbNp0aeP+M3kTt+nbaIveGmUxAtZa+8iFgKLUOD4YKM5j+f3QD89bra7UeumolZHKuOXnTmeQ==", + "node_modules/external-editor": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/external-editor/-/external-editor-3.1.0.tgz", + "integrity": "sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew==", "dev": true, "license": "MIT", - "engines": { - "node": ">=8" + "dependencies": { + "chardet": "^0.7.0", + "iconv-lite": "^0.4.24", + "tmp": "^0.0.33" }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "engines": { + "node": ">=4" } }, - "node_modules/html-validate": { - "version": "8.22.0", - "resolved": "https://registry.npmjs.org/html-validate/-/html-validate-8.22.0.tgz", - "integrity": "sha512-kKDnU04zdxQIOSZVD6BKma6gWpCMCCFwYvHWwTorBMVbSYXMW1B5kGgLwOMHzTlC3yiuaO7NvJprXk3w7Jko/Q==", + "node_modules/external-editor/node_modules/iconv-lite": { + "version": "0.4.24", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", + "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/html-validate" - } - ], "license": "MIT", - "workspaces": [ - "docs", - "tests/vitest" - ], "dependencies": { - "@html-validate/stylish": "^4.1.0", - "@sidvind/better-ajv-errors": "3.0.1", - "ajv": "^8.0.0", - "deepmerge": "4.3.1", - "glob": "^10.0.0", - "ignore": "5.3.2", - "kleur": "^4.1.0", - "minimist": "^1.2.0", - "prompts": "^2.0.0", - "semver": "^7.0.0" - }, - "bin": { - "html-validate": "bin/html-validate.js" + "safer-buffer": ">= 2.1.2 < 3" }, "engines": { - "node": ">= 16.14" - }, - "peerDependencies": { - "jest": "^27.1 || ^28.1.3 || ^29.0.3", - "jest-diff": "^27.1 || ^28.1.3 || ^29.0.3", - "jest-snapshot": "^27.1 || ^28.1.3 || ^29.0.3", - "vitest": "^0.34 || ^1" - }, - "peerDependenciesMeta": { - "jest": { - "optional": true - }, - "jest-diff": { - "optional": true - }, - "jest-snapshot": { - "optional": true - }, - "vitest": { - "optional": true - } + "node": ">=0.10.0" } }, - "node_modules/html-validate/node_modules/ajv": { - "version": "8.17.1", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.17.1.tgz", - "integrity": "sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g==", + "node_modules/external-editor/node_modules/tmp": { + "version": "0.0.33", + "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.0.33.tgz", + "integrity": "sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==", "dev": true, "license": "MIT", "dependencies": { - "fast-deep-equal": "^3.1.3", - "fast-uri": "^3.0.1", - "json-schema-traverse": "^1.0.0", - "require-from-string": "^2.0.2" + "os-tmpdir": "~1.0.2" }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" + "engines": { + "node": ">=0.6.0" } }, - "node_modules/html-validate/node_modules/json-schema-traverse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", - "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", - "dev": true, - "license": "MIT" - }, - "node_modules/html-validate/node_modules/semver": { - "version": "7.6.3", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", - "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", + "node_modules/extract-zip": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/extract-zip/-/extract-zip-1.7.0.tgz", + "integrity": "sha512-xoh5G1W/PB0/27lXgMQyIhP5DSY/LhoCsOyZgb+6iMmRtCwVBo55uKaMoEYrDCKQhWvqEip5ZPKAc6eFNyf/MA==", "dev": true, - "license": "ISC", - "bin": { - "semver": "bin/semver.js" + "license": "BSD-2-Clause", + "dependencies": { + "concat-stream": "^1.6.2", + "debug": "^2.6.9", + "mkdirp": "^0.5.4", + "yauzl": "^2.10.0" }, - "engines": { - "node": ">=10" + "bin": { + "extract-zip": "cli.js" } }, - "node_modules/http-cache-semantics": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/http-cache-semantics/-/http-cache-semantics-4.1.1.tgz", - "integrity": "sha512-er295DKPVsV82j5kw1Gjt+ADA/XYHsajl82cGNQG2eyoPkvgUhX+nDIyelzhIWbbsXP39EHcI6l5tYs2FYqYXQ==", + "node_modules/extract-zip/node_modules/debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", "dev": true, - "license": "BSD-2-Clause" + "license": "MIT", + "dependencies": { + "ms": "2.0.0" + } }, - "node_modules/http-deceiver": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/http-deceiver/-/http-deceiver-1.2.7.tgz", - "integrity": "sha512-LmpOGxTfbpgtGVxJrj5k7asXHCgNZp5nLfp+hWc8QQRqtb7fUy6kRY3BO1h9ddF6yIPYUARgxGOwB42DnxIaNw==", + "node_modules/extract-zip/node_modules/ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", "dev": true, "license": "MIT" }, - "node_modules/http-errors": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-2.0.0.tgz", - "integrity": "sha512-FtwrG/euBzaEjYeRqOgly7G0qviiXoJWnvEH2Z1plBdXgbyjv34pHTSb9zoeHMyDy33+DWy5Wt9Wo+TURtOYSQ==", - "license": "MIT", - "dependencies": { - "depd": "2.0.0", - "inherits": "2.0.4", - "setprototypeof": "1.2.0", - "statuses": "2.0.1", - "toidentifier": "1.0.1" - }, - "engines": { - "node": ">= 0.8" - } + "node_modules/extsprintf": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz", + "integrity": "sha512-11Ndz7Nv+mvAC1j0ktTa7fAb0vLyGGX+rMHNBYQviQDGU0Hw7lhctJANqbPhu9nV9/izT/IntTgZ7Im/9LJs9g==", + "dev": true, + "engines": [ + "node >=0.6.0" + ], + "license": "MIT" }, - "node_modules/http-parser-js": { - "version": "0.5.8", - "resolved": "https://registry.npmjs.org/http-parser-js/-/http-parser-js-0.5.8.tgz", - "integrity": "sha512-SGeBX54F94Wgu5RH3X5jsDtf4eHyRogWX1XGT3b4HuW3tQPM4AaBzoUji/4AAJNXCEOWZ5O0DgZmJw1947gD5Q==", + "node_modules/fast-deep-equal": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", + "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", "dev": true, "license": "MIT" }, - "node_modules/http-proxy": { - "version": "1.18.1", - "resolved": "https://registry.npmjs.org/http-proxy/-/http-proxy-1.18.1.tgz", - "integrity": "sha512-7mz/721AbnJwIVbnaSv1Cz3Am0ZLT/UBwkC92VlxhXv/k/BBQfM2fXElQNC27BVGr0uwUpplYPQM9LnaBMR5NQ==", + "node_modules/fast-diff": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/fast-diff/-/fast-diff-1.3.0.tgz", + "integrity": "sha512-VxPP4NqbUjj6MaAOafWeUn2cXWLcCtljklUtZf0Ind4XQ+QPtmA0b18zZy0jIQx+ExRVCR/ZQpBmik5lXshNsw==", + "dev": true, + "license": "Apache-2.0" + }, + "node_modules/fast-glob": { + "version": "3.3.3", + "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.3.tgz", + "integrity": "sha512-7MptL8U0cqcFdzIzwOTHoilX9x5BrNqye7Z/LuC7kCMRio1EMSyqRK3BEAUD7sXRq4iT4AzTVuZdhgQ2TCvYLg==", "dev": true, "license": "MIT", "dependencies": { - "eventemitter3": "^4.0.0", - "follow-redirects": "^1.0.0", - "requires-port": "^1.0.0" + "@nodelib/fs.stat": "^2.0.2", + "@nodelib/fs.walk": "^1.2.3", + "glob-parent": "^5.1.2", + "merge2": "^1.3.0", + "micromatch": "^4.0.8" }, "engines": { - "node": ">=8.0.0" + "node": ">=8.6.0" } }, - "node_modules/http-proxy-middleware": { - "version": "2.0.9", - "resolved": "https://registry.npmjs.org/http-proxy-middleware/-/http-proxy-middleware-2.0.9.tgz", - "integrity": "sha512-c1IyJYLYppU574+YI7R4QyX2ystMtVXZwIdzazUIPIJsHuWNd+mho2j+bKoHftndicGj9yh+xjd+l0yj7VeT1Q==", + "node_modules/fast-glob/node_modules/glob-parent": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", + "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", "dev": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "@types/http-proxy": "^1.17.8", - "http-proxy": "^1.18.1", - "is-glob": "^4.0.1", - "is-plain-obj": "^3.0.0", - "micromatch": "^4.0.2" + "is-glob": "^4.0.1" }, "engines": { - "node": ">=12.0.0" - }, - "peerDependencies": { - "@types/express": "^4.17.13" - }, - "peerDependenciesMeta": { - "@types/express": { - "optional": true - } + "node": ">= 6" } }, - "node_modules/http-signature": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.4.0.tgz", - "integrity": "sha512-G5akfn7eKbpDN+8nPS/cb57YeA1jLTVxjpCj7tmm3QKPdyDy7T+qSC40e9ptydSWvkwjSXw1VbkpyEm39ukeAg==", + "node_modules/fast-json-stable-stringify": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", + "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==", + "dev": true, + "license": "MIT" + }, + "node_modules/fast-levenshtein": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", + "integrity": "sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==", + "dev": true, + "license": "MIT" + }, + "node_modules/fast-uri": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/fast-uri/-/fast-uri-3.0.1.tgz", + "integrity": "sha512-MWipKbbYiYI0UC7cl8m/i/IWTqfC8YXsqjzybjddLsFjStroQzsHXkc73JutMvBiXmOvapk+axIl79ig5t55Bw==", + "dev": true, + "license": "MIT" + }, + "node_modules/fastest-levenshtein": { + "version": "1.0.16", + "resolved": "https://registry.npmjs.org/fastest-levenshtein/-/fastest-levenshtein-1.0.16.tgz", + "integrity": "sha512-eRnCtTTtGZFpQCwhJiUOuxPQWRXVKYDn0b2PeHfXL6/Zi53SLAzAHfVhVWK2AryC/WH05kGfxhFIPvTF0SXQzg==", "dev": true, "license": "MIT", - "dependencies": { - "assert-plus": "^1.0.0", - "jsprim": "^2.0.2", - "sshpk": "^1.18.0" - }, "engines": { - "node": ">=0.10" + "node": ">= 4.9.1" } }, - "node_modules/http2-wrapper": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/http2-wrapper/-/http2-wrapper-1.0.3.tgz", - "integrity": "sha512-V+23sDMr12Wnz7iTcDeJr3O6AIxlnvT/bmaAAAP/Xda35C90p9599p0F1eHR/N1KILWSoWVAiOMFjBBXaXSMxg==", + "node_modules/fastq": { + "version": "1.17.1", + "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.17.1.tgz", + "integrity": "sha512-sRVD3lWVIXWg6By68ZN7vho9a1pQcN/WBFaAAsDDFzlJjvoGx0P8z7V1t72grFJfJhu3YPZBuu25f7Kaw2jN1w==", "dev": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "quick-lru": "^5.1.1", - "resolve-alpn": "^1.0.0" - }, - "engines": { - "node": ">=10.19.0" + "reusify": "^1.0.4" } }, - "node_modules/human-signals": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-1.1.1.tgz", - "integrity": "sha512-SEQu7vl8KjNL2eoGBLF3+wAjpsNfA9XMlXAYj/3EdaNfAlxKthD1xjEQfGOUhllCGGJVNY34bRr6lPINhNjyZw==", + "node_modules/faye-websocket": { + "version": "0.11.4", + "resolved": "https://registry.npmjs.org/faye-websocket/-/faye-websocket-0.11.4.tgz", + "integrity": "sha512-CzbClwlXAuiRQAlUyfqPgvPoNKTckTPGfwZV4ZdAhVcP2lh9KUxJg2b5GkE7XbjKQ3YJnQ9z6D9ntLAlB+tP8g==", "dev": true, "license": "Apache-2.0", + "dependencies": { + "websocket-driver": ">=0.5.1" + }, "engines": { - "node": ">=8.12.0" + "node": ">=0.8.0" } }, - "node_modules/iconv-lite": { - "version": "0.6.3", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz", - "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", + "node_modules/fd-slicer": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/fd-slicer/-/fd-slicer-1.1.0.tgz", + "integrity": "sha512-cE1qsB/VwyQozZ+q1dGxR8LBYNZeofhEdUNGSMbQD3Gw2lAzX9Zb3uIU6Ebc/Fmyjo9AWWfnn0AUCHqtevs/8g==", + "dev": true, "license": "MIT", "dependencies": { - "safer-buffer": ">= 2.1.2 < 3.0.0" - }, - "engines": { - "node": ">=0.10.0" + "pend": "~1.2.0" } }, - "node_modules/icss-utils": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/icss-utils/-/icss-utils-5.1.0.tgz", - "integrity": "sha512-soFhflCVWLfRNOPU3iv5Z9VUdT44xFRbzjLsEzSr5AQmgqPMTHdU3PMT1Cf1ssx8fLNJDA1juftYl+PUcv3MqA==", + "node_modules/figures": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/figures/-/figures-3.2.0.tgz", + "integrity": "sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg==", "dev": true, - "license": "ISC", + "license": "MIT", + "dependencies": { + "escape-string-regexp": "^1.0.5" + }, "engines": { - "node": "^10 || ^12 || >= 14" + "node": ">=8" }, - "peerDependencies": { - "postcss": "^8.1.0" + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/ieee754": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", - "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "license": "BSD-3-Clause" - }, - "node_modules/ignore": { - "version": "5.3.2", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.2.tgz", - "integrity": "sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g==", + "node_modules/file-entry-cache": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-6.0.1.tgz", + "integrity": "sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==", "dev": true, "license": "MIT", + "dependencies": { + "flat-cache": "^3.0.4" + }, "engines": { - "node": ">= 4" + "node": "^10.12.0 || >=12.0.0" } }, - "node_modules/image-size": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/image-size/-/image-size-1.2.1.tgz", - "integrity": "sha512-rH+46sQJ2dlwfjfhCyNx5thzrv+dtmBIhPHk0zgRUukHzZ/kRueTJXoYYsclBaKcSMBWuGbOFXtioLpzTb5euw==", + "node_modules/fill-range": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", + "integrity": "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "queue": "6.0.2" - }, - "bin": { - "image-size": "bin/image-size.js" + "to-regex-range": "^5.0.1" }, "engines": { - "node": ">=16.x" + "node": ">=8" } }, - "node_modules/immutable": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/immutable/-/immutable-5.1.1.tgz", - "integrity": "sha512-3jatXi9ObIsPGr3N5hGw/vWWcTkq6hUYhpQz4k0wLC+owqWi/LiugIw9x0EdNZ2yGedKN/HzePiBvaJRXa0Ujg==", + "node_modules/finalhandler": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.3.1.tgz", + "integrity": "sha512-6BN9trH7bp3qvnrRyzsBz+g3lZxTNZTbVO2EV1CS0WIcDbawYVdYvGflME/9QP0h0pYlCDBCTjYa9nZzMDpyxQ==", "dev": true, - "license": "MIT" - }, - "node_modules/import-fresh": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz", - "integrity": "sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==", "license": "MIT", "dependencies": { - "parent-module": "^1.0.0", - "resolve-from": "^4.0.0" + "debug": "2.6.9", + "encodeurl": "~2.0.0", + "escape-html": "~1.0.3", + "on-finished": "2.4.1", + "parseurl": "~1.3.3", + "statuses": "2.0.1", + "unpipe": "~1.0.0" }, "engines": { - "node": ">=6" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "node": ">= 0.8" } }, - "node_modules/import-local": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/import-local/-/import-local-3.2.0.tgz", - "integrity": "sha512-2SPlun1JUPWoM6t3F0dw0FkCF/jWY8kttcY4f599GLTSjh2OCuuhdTkJQsEcZzBqbXZGKMK2OqW1oZsjtf/gQA==", + "node_modules/finalhandler/node_modules/debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", "dev": true, "license": "MIT", "dependencies": { - "pkg-dir": "^4.2.0", - "resolve-cwd": "^3.0.0" - }, - "bin": { - "import-local-fixture": "fixtures/cli.js" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "ms": "2.0.0" } }, - "node_modules/import-local/node_modules/find-up": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", + "node_modules/finalhandler/node_modules/ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", + "dev": true, + "license": "MIT" + }, + "node_modules/find-cache-dir": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-4.0.0.tgz", + "integrity": "sha512-9ZonPT4ZAK4a+1pUPVPZJapbi7O5qbbJPdYw/NOQWZZbVLdDTYM3A4R9z/DpAM08IDaFGsvPgiGZ82WEwUDWjg==", "dev": true, "license": "MIT", "dependencies": { - "locate-path": "^5.0.0", - "path-exists": "^4.0.0" + "common-path-prefix": "^3.0.0", + "pkg-dir": "^7.0.0" }, "engines": { - "node": ">=8" + "node": ">=14.16" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/import-local/node_modules/locate-path": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", + "node_modules/find-root": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/find-root/-/find-root-1.1.0.tgz", + "integrity": "sha512-NKfW6bec6GfKc0SGx1e07QZY9PE99u0Bft/0rzSD5k3sO/vwkVUpDUKVm5Gpp5Ue3YfShPFTX2070tDs5kB9Ng==", "dev": true, - "license": "MIT", - "dependencies": { - "p-locate": "^4.1.0" - }, - "engines": { - "node": ">=8" - } + "license": "MIT" }, - "node_modules/import-local/node_modules/p-limit": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "node_modules/find-up": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", + "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", "dev": true, "license": "MIT", "dependencies": { - "p-try": "^2.0.0" + "locate-path": "^6.0.0", + "path-exists": "^4.0.0" }, "engines": { - "node": ">=6" + "node": ">=10" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/import-local/node_modules/p-locate": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", + "node_modules/flat": { + "version": "5.0.2", + "resolved": "https://registry.npmjs.org/flat/-/flat-5.0.2.tgz", + "integrity": "sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ==", "dev": true, - "license": "MIT", - "dependencies": { - "p-limit": "^2.2.0" - }, - "engines": { - "node": ">=8" + "license": "BSD-3-Clause", + "bin": { + "flat": "cli.js" } }, - "node_modules/import-local/node_modules/pkg-dir": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-4.2.0.tgz", - "integrity": "sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ==", + "node_modules/flat-cache": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-3.2.0.tgz", + "integrity": "sha512-CYcENa+FtcUKLmhhqyctpclsq7QF38pKjZHsGNiSQF5r4FtoKDWabFDl3hzaEQMvT1LHEysw5twgLvpYYb4vbw==", "dev": true, "license": "MIT", "dependencies": { - "find-up": "^4.0.0" + "flatted": "^3.2.9", + "keyv": "^4.5.3", + "rimraf": "^3.0.2" }, "engines": { - "node": ">=8" - } - }, - "node_modules/imurmurhash": { - "version": "0.1.4", - "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", - "integrity": "sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==", - "license": "MIT", - "engines": { - "node": ">=0.8.19" + "node": "^10.12.0 || >=12.0.0" } }, - "node_modules/indent-string": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-4.0.0.tgz", - "integrity": "sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==", + "node_modules/flatted": { + "version": "3.3.3", + "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.3.3.tgz", + "integrity": "sha512-GX+ysw4PBCz0PzosHDepZGANEuFCMLrnRTiEy9McGjmkCQYwRq4A/X786G/fjM/+OjsWSU1ZrY5qyARZmO/uwg==", "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/inflight": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", - "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==", - "deprecated": "This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.", - "license": "ISC", - "dependencies": { - "once": "^1.3.0", - "wrappy": "1" - } - }, - "node_modules/inherits": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", - "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", "license": "ISC" }, - "node_modules/ini": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ini/-/ini-2.0.0.tgz", - "integrity": "sha512-7PnF4oN3CvZF23ADhA5wRaYEQpJ8qygSkbtTXWBeXWXmEVRXK+1ITciHWwHhsjv1TmW0MgacIv6hEi5pX5NQdA==", + "node_modules/follow-redirects": { + "version": "1.15.9", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.9.tgz", + "integrity": "sha512-gew4GsXizNgdoRyqmyfMHyAmXsZDk6mHkSxZFCzW9gwlbtOW44CDtYavM+y+72qD/Vq2l550kMF52DT8fOLJqQ==", "dev": true, - "license": "ISC", + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/RubenVerborgh" + } + ], + "license": "MIT", "engines": { - "node": ">=10" + "node": ">=4.0" + }, + "peerDependenciesMeta": { + "debug": { + "optional": true + } } }, - "node_modules/inquirer": { - "version": "7.3.3", - "resolved": "https://registry.npmjs.org/inquirer/-/inquirer-7.3.3.tgz", - "integrity": "sha512-JG3eIAj5V9CwcGvuOmoo6LB9kbAYT8HXffUl6memuszlwDC/qvFAJw49XJ5NROSFNPxp3iQg1GqkFhaY/CR0IA==", - "dev": true, + "node_modules/for-each": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz", + "integrity": "sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==", "license": "MIT", "dependencies": { - "ansi-escapes": "^4.2.1", - "chalk": "^4.1.0", - "cli-cursor": "^3.1.0", - "cli-width": "^3.0.0", - "external-editor": "^3.0.3", - "figures": "^3.0.0", - "lodash": "^4.17.19", - "mute-stream": "0.0.8", - "run-async": "^2.4.0", - "rxjs": "^6.6.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0", - "through": "^2.3.6" - }, - "engines": { - "node": ">=8.0.0" + "is-callable": "^1.1.3" } }, - "node_modules/inquirer/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/foreground-child": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-3.3.0.tgz", + "integrity": "sha512-Ld2g8rrAyMYFXBhEqMz8ZAHBi4J4uS1i/CxGMDnjyFWddMXLVcDp051DZfu+t7+ab7Wv6SMqpWmyFIj5UbfFvg==", "dev": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "color-convert": "^2.0.1" + "cross-spawn": "^7.0.0", + "signal-exit": "^4.0.1" }, "engines": { - "node": ">=8" + "node": ">=14" }, "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/inquirer/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/foreground-child/node_modules/signal-exit": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", + "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", "dev": true, - "license": "MIT", - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, + "license": "ISC", "engines": { - "node": ">=10" + "node": ">=14" }, "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/inquirer/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/forever-agent": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz", + "integrity": "sha512-j0KLYPhm6zeac4lz3oJ3o65qvgQCcPubiyotZrXqEaG4hNagNYO8qdlUrX5vwqv9ohqeT/Z3j6+yW067yWWdUw==", "dev": true, - "license": "MIT", - "dependencies": { - "color-name": "~1.1.4" - }, + "license": "Apache-2.0", "engines": { - "node": ">=7.0.0" + "node": "*" } }, - "node_modules/inquirer/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true, - "license": "MIT" - }, - "node_modules/inquirer/node_modules/has-flag": { + "node_modules/form-data": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/inquirer/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz", + "integrity": "sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==", "dev": true, "license": "MIT", "dependencies": { - "has-flag": "^4.0.0" + "asynckit": "^0.4.0", + "combined-stream": "^1.0.8", + "mime-types": "^2.1.12" }, "engines": { - "node": ">=8" + "node": ">= 6" } }, - "node_modules/internal-slot": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.7.tgz", - "integrity": "sha512-NGnrKwXzSms2qUUih/ILZ5JBqNTSa1+ZmP6flaIp6KmSElgE9qdndzS3cqjrDovwFdmwsGsLdeFgB6suw+1e9g==", + "node_modules/forwarded": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.2.0.tgz", + "integrity": "sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow==", + "dev": true, "license": "MIT", - "dependencies": { - "es-errors": "^1.3.0", - "hasown": "^2.0.0", - "side-channel": "^1.0.4" - }, "engines": { - "node": ">= 0.4" - } - }, - "node_modules/interpret": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/interpret/-/interpret-1.4.0.tgz", - "integrity": "sha512-agE4QfB2Lkp9uICn7BAqoscw4SZP9kTE2hxiFI3jBPmXJfdqiahTbUuKGsMoN2GtqL9AxhYioAcVvgsb1HvRbA==", + "node": ">= 0.6" + } + }, + "node_modules/fresh": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz", + "integrity": "sha512-zJ2mQYM18rEFOudeV4GShTGIQ7RbzA7ozbU9I/XBpm7kqgMywgmylMwXHxZJmkVoYkna9d2pVXVXPdYTP9ej8Q==", "dev": true, "license": "MIT", "engines": { - "node": ">= 0.10" + "node": ">= 0.6" } }, - "node_modules/invariant": { - "version": "2.2.4", - "resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz", - "integrity": "sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==", + "node_modules/fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "loose-envify": "^1.0.0" + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=10" } }, - "node_modules/ipaddr.js": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-2.2.0.tgz", - "integrity": "sha512-Ag3wB2o37wslZS19hZqorUnrnzSkpOVy+IiiDEiTqNubEYpYuHWIf6K4psgN2ZWKExS4xhVCrRVfb/wfW8fWJA==", + "node_modules/fs-monkey": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/fs-monkey/-/fs-monkey-1.0.6.tgz", + "integrity": "sha512-b1FMfwetIKymC0eioW7mTywihSQE4oLzQn1dB6rZB5fx/3NpNEdAWeCSMB+60/AeT0TCXsxzAlcYVEFCTAksWg==", + "dev": true, + "license": "Unlicense" + }, + "node_modules/fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==", + "dev": true, + "license": "ISC" + }, + "node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", "dev": true, + "hasInstallScript": true, "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], "engines": { - "node": ">= 10" + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" } }, - "node_modules/is-arguments": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.1.1.tgz", - "integrity": "sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==", - "dev": true, + "node_modules/function-bind": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", + "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", "license": "MIT", - "dependencies": { - "call-bind": "^1.0.2", - "has-tostringtag": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-array-buffer": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.4.tgz", - "integrity": "sha512-wcjaerHw0ydZwfhiKbXJWLDY8A7yV7KhjQOpb83hGgGfId/aQa4TOvwyzn2PuswW2gPCYEL/nEAiSVpdOj1lXw==", + "node_modules/function.prototype.name": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.6.tgz", + "integrity": "sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg==", "license": "MIT", "dependencies": { "call-bind": "^1.0.2", - "get-intrinsic": "^1.2.1" + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "functions-have-names": "^1.2.3" }, "engines": { "node": ">= 0.4" @@ -14117,61 +9966,46 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-arrayish": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", - "integrity": "sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg==", - "license": "MIT" - }, - "node_modules/is-async-function": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/is-async-function/-/is-async-function-2.0.0.tgz", - "integrity": "sha512-Y1JXKrfykRJGdlDwdKlLpLyMIiWqWvuSd17TvZk68PLAOGOoF4Xyav1z0Xhoi+gCYjZVeC5SI+hYFOfvXmGRCA==", - "dev": true, + "node_modules/functions-have-names": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz", + "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==", "license": "MIT", - "dependencies": { - "has-tostringtag": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-bigint": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", - "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==", + "node_modules/gensync": { + "version": "1.0.0-beta.2", + "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.2.tgz", + "integrity": "sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==", + "dev": true, "license": "MIT", - "dependencies": { - "has-bigints": "^1.0.1" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "engines": { + "node": ">=6.9.0" } }, - "node_modules/is-binary-path": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", - "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "node_modules/get-caller-file": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", + "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", "dev": true, - "license": "MIT", - "dependencies": { - "binary-extensions": "^2.0.0" - }, + "license": "ISC", "engines": { - "node": ">=8" + "node": "6.* || 8.* || >= 10.*" } }, - "node_modules/is-boolean-object": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz", - "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==", + "node_modules/get-intrinsic": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.4.tgz", + "integrity": "sha512-5uYhsJH8VJBTv7oslg4BznJYhDoRI6waYCxMmCdnTrcCrHA/fCFKoTFz2JKKE0HdDFUF7/oQuhzumXJK7paBRQ==", "license": "MIT", "dependencies": { - "call-bind": "^1.0.2", - "has-tostringtag": "^1.0.0" + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3", + "hasown": "^2.0.0" }, "engines": { "node": ">= 0.4" @@ -14180,27 +10014,32 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-builtin-module": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/is-builtin-module/-/is-builtin-module-3.2.1.tgz", - "integrity": "sha512-BSLE3HnV2syZ0FK0iMA/yUGplUeMmNz4AW5fnTunbCIqZi4vG3WjJT9FHMy5D69xmAYBHXQhJdALdpwVxV501A==", + "node_modules/get-stream": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-5.2.0.tgz", + "integrity": "sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==", "dev": true, "license": "MIT", "dependencies": { - "builtin-modules": "^3.3.0" + "pump": "^3.0.0" }, "engines": { - "node": ">=6" + "node": ">=8" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/is-callable": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", - "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==", + "node_modules/get-symbol-description": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.2.tgz", + "integrity": "sha512-g0QYk1dZBxGwk+Ngc+ltRH2IBp2f7zBkBMBJZCDerh6EhlhSR6+9irMCuT/09zD6qkarHUSn529sK/yL4S27mg==", "license": "MIT", + "dependencies": { + "call-bind": "^1.0.5", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.4" + }, "engines": { "node": ">= 0.4" }, @@ -14208,157 +10047,124 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-ci": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/is-ci/-/is-ci-3.0.1.tgz", - "integrity": "sha512-ZYvCgrefwqoQ6yTyYUbQu64HsITZ3NfKX1lzaEYdkTDcfKzzCI/wthRRYKkdjHKFVgNiXKAKm65Zo1pk2as/QQ==", + "node_modules/getos": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/getos/-/getos-3.2.1.tgz", + "integrity": "sha512-U56CfOK17OKgTVqozZjUKNdkfEv6jk5WISBJ8SHoagjE6L69zOwl3Z+O8myjY9MEW3i2HPWQBt/LTbCgcC973Q==", "dev": true, "license": "MIT", "dependencies": { - "ci-info": "^3.2.0" - }, - "bin": { - "is-ci": "bin.js" + "async": "^3.2.0" } }, - "node_modules/is-core-module": { - "version": "2.15.1", - "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.15.1.tgz", - "integrity": "sha512-z0vtXSwucUJtANQWldhbtbt7BnL0vxiFjIdDLAatwhDYty2bad6s+rijD6Ri4YuYJubLzIJLUidCh09e1djEVQ==", + "node_modules/getpass": { + "version": "0.1.7", + "resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz", + "integrity": "sha512-0fzj9JxOLfJ+XGLhR8ze3unN0KZCgZwiSSDz168VERjK8Wl8kVSdcu2kspd4s4wtAa1y/qrVRiAA0WclVsu0ng==", + "dev": true, "license": "MIT", "dependencies": { - "hasown": "^2.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "assert-plus": "^1.0.0" } }, - "node_modules/is-data-view": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-data-view/-/is-data-view-1.0.1.tgz", - "integrity": "sha512-AHkaJrsUVW6wq6JS8y3JnM/GJF/9cf+k20+iDzlSaJrinEo5+7vRiteOSwBhHRiAyQATN1AmY4hwzxJKPmYf+w==", + "node_modules/gettext-parser": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/gettext-parser/-/gettext-parser-1.4.0.tgz", + "integrity": "sha512-sedZYLHlHeBop/gZ1jdg59hlUEcpcZJofLq2JFwJT1zTqAU3l2wFv6IsuwFHGqbiT9DWzMUW4/em2+hspnmMMA==", "license": "MIT", "dependencies": { - "is-typed-array": "^1.1.13" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "encoding": "^0.1.12", + "safe-buffer": "^5.1.1" } }, - "node_modules/is-date-object": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz", - "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==", - "license": "MIT", + "node_modules/glob": { + "version": "10.4.5", + "resolved": "https://registry.npmjs.org/glob/-/glob-10.4.5.tgz", + "integrity": "sha512-7Bv8RF0k6xjo7d4A/PxYLbUCfb6c+Vpd2/mB2yRDlew7Jb5hEXiCD9ibfO7wpk8i4sevK6DFny9h7EYbM3/sHg==", + "dev": true, + "license": "ISC", "dependencies": { - "has-tostringtag": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" + "foreground-child": "^3.1.0", + "jackspeak": "^3.1.2", + "minimatch": "^9.0.4", + "minipass": "^7.1.2", + "package-json-from-dist": "^1.0.0", + "path-scurry": "^1.11.1" }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-directory": { - "version": "0.3.1", - "resolved": "https://registry.npmjs.org/is-directory/-/is-directory-0.3.1.tgz", - "integrity": "sha512-yVChGzahRFvbkscn2MlwGismPO12i9+znNruC5gVEntG3qu0xQMzsGg/JFbrsqDOHtHFPci+V5aP5T9I+yeKqw==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/is-docker": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/is-docker/-/is-docker-2.2.1.tgz", - "integrity": "sha512-F+i2BKsFrH66iaUFc0woD8sLy8getkwTwtOBjvs56Cx4CgJDeKQeqfz8wAYiSb8JOprWhHH5p77PbmYCvvUuXQ==", - "license": "MIT", "bin": { - "is-docker": "cli.js" - }, - "engines": { - "node": ">=8" + "glob": "dist/esm/bin.mjs" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/is-extglob": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", - "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==", - "license": "MIT", - "engines": { - "node": ">=0.10.0" + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/is-finalizationregistry": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-finalizationregistry/-/is-finalizationregistry-1.0.2.tgz", - "integrity": "sha512-0by5vtUJs8iFQb5TYUHHPudOR+qXYIMKtiUzvLIZITZUjknFmziyBJuLhVRc+Ds0dREFlskDNJKYIdIzu/9pfw==", + "node_modules/glob-parent": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz", + "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==", "dev": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "call-bind": "^1.0.2" + "is-glob": "^4.0.3" }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "engines": { + "node": ">=10.13.0" } }, - "node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", + "node_modules/glob-to-regexp": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz", + "integrity": "sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==", + "dev": true, + "license": "BSD-2-Clause" + }, + "node_modules/glob/node_modules/brace-expansion": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz", + "integrity": "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==", + "dev": true, "license": "MIT", - "engines": { - "node": ">=8" + "dependencies": { + "balanced-match": "^1.0.0" } }, - "node_modules/is-generator-function": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/is-generator-function/-/is-generator-function-1.0.10.tgz", - "integrity": "sha512-jsEjy9l3yiXEQ+PsXdmBwEPcOxaXWLspKdplFUVI9vq1iZgIekeC0L167qeu86czQaxed3q/Uzuw0swL0irL8A==", + "node_modules/glob/node_modules/minimatch": { + "version": "9.0.5", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.5.tgz", + "integrity": "sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==", "dev": true, - "license": "MIT", + "license": "ISC", "dependencies": { - "has-tostringtag": "^1.0.0" + "brace-expansion": "^2.0.1" }, "engines": { - "node": ">= 0.4" + "node": ">=16 || 14 >=14.17" }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/is-glob": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", - "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", + "node_modules/global-cache": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/global-cache/-/global-cache-1.2.1.tgz", + "integrity": "sha512-EOeUaup5DgWKlCMhA9YFqNRIlZwoxt731jCh47WBV9fQqHgXhr3Fa55hfgIUqilIcPsfdNKN7LHjrNY+Km40KA==", "license": "MIT", "dependencies": { - "is-extglob": "^2.1.1" + "define-properties": "^1.1.2", + "is-symbol": "^1.0.1" }, "engines": { - "node": ">=0.10.0" + "node": ">= 0.4" } }, - "node_modules/is-installed-globally": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/is-installed-globally/-/is-installed-globally-0.4.0.tgz", - "integrity": "sha512-iwGqO3J21aaSkC7jWnHP/difazwS7SFeIqxv6wEtLU8Y5KlzFTjyqcSIT0d8s4+dDhKytsk9PJZ2BkS5eZwQRQ==", + "node_modules/global-dirs": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/global-dirs/-/global-dirs-3.0.1.tgz", + "integrity": "sha512-NBcGGFbBA9s1VzD41QXDG+3++t9Mn5t1FpLdhESY6oKY4gYTFpX4wO3sqGUa0Srjtbfj3szX0RnemmrVRUdULA==", "dev": true, "license": "MIT", "dependencies": { - "global-dirs": "^3.0.0", - "is-path-inside": "^3.0.2" + "ini": "2.0.0" }, "engines": { "node": ">=10" @@ -14367,56 +10173,71 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/is-interactive": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-interactive/-/is-interactive-1.0.0.tgz", - "integrity": "sha512-2HvIEKRoqS62guEC+qBjpvRubdX910WCMuJTZ+I9yvqKU2/12eSL549HMwtabb4oupdj2sMP50k+XJfB/8JE6w==", + "node_modules/global-modules": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/global-modules/-/global-modules-2.0.0.tgz", + "integrity": "sha512-NGbfmJBp9x8IxyJSd1P+otYK8vonoJactOogrVfFRIAEY1ukil8RSKDz2Yo7wh1oihl51l/r6W4epkeKJHqL8A==", + "dev": true, "license": "MIT", + "dependencies": { + "global-prefix": "^3.0.0" + }, "engines": { - "node": ">=8" + "node": ">=6" } }, - "node_modules/is-map": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.3.tgz", - "integrity": "sha512-1Qed0/Hr2m+YqxnM09CjA2d/i6YZNfF6R2oRAOj36eUdS6qIV/huPJNSEpKbupewFs+ZsJlxsjjPbc0/afW6Lw==", + "node_modules/global-prefix": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/global-prefix/-/global-prefix-3.0.0.tgz", + "integrity": "sha512-awConJSVCHVGND6x3tmMaKcQvwXLhjdkmomy2W+Goaui8YPgYgXJZewhg3fWC+DlfqqQuWg8AwqjGTD2nAPVWg==", "dev": true, "license": "MIT", - "engines": { - "node": ">= 0.4" + "dependencies": { + "ini": "^1.3.5", + "kind-of": "^6.0.2", + "which": "^1.3.1" }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "engines": { + "node": ">=6" } }, - "node_modules/is-negative-zero": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.3.tgz", - "integrity": "sha512-5KoIu2Ngpyek75jXodFvnafB6DJgr3u8uuK0LEZJjrU19DrMD3EVERaR8sjz8CCGgpZvxPl9SuE1GMVPFHx1mw==", - "license": "MIT", - "engines": { - "node": ">= 0.4" + "node_modules/global-prefix/node_modules/ini": { + "version": "1.3.8", + "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.8.tgz", + "integrity": "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==", + "dev": true, + "license": "ISC" + }, + "node_modules/global-prefix/node_modules/which": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", + "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", + "dev": true, + "license": "ISC", + "dependencies": { + "isexe": "^2.0.0" }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "bin": { + "which": "bin/which" } }, - "node_modules/is-number": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", - "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", + "node_modules/globals": { + "version": "11.12.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", + "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", "license": "MIT", "engines": { - "node": ">=0.12.0" + "node": ">=4" } }, - "node_modules/is-number-object": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz", - "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==", + "node_modules/globalthis": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.4.tgz", + "integrity": "sha512-DpLKbNU4WylpxJykQujfCcwYWiV/Jhm50Goo0wrVILAv5jOr9d+H+UR3PhSCD2rCCEIg0uc+G+muBTwD54JhDQ==", "license": "MIT", "dependencies": { - "has-tostringtag": "^1.0.0" + "define-properties": "^1.2.1", + "gopd": "^1.0.1" }, "engines": { "node": ">= 0.4" @@ -14425,22 +10246,20 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-path-inside": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-3.0.3.tgz", - "integrity": "sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/is-plain-obj": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-3.0.0.tgz", - "integrity": "sha512-gwsOE28k+23GP1B6vFl1oVh/WOzmawBrKwo5Ev6wMKzPkaXaCDIQKzLnvsA42DRlbVTWorkgTKIviAKCWkfUwA==", + "node_modules/globby": { + "version": "11.1.0", + "resolved": "https://registry.npmjs.org/globby/-/globby-11.1.0.tgz", + "integrity": "sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==", "dev": true, "license": "MIT", + "dependencies": { + "array-union": "^2.1.0", + "dir-glob": "^3.0.1", + "fast-glob": "^3.2.9", + "ignore": "^5.2.0", + "merge2": "^1.4.1", + "slash": "^3.0.0" + }, "engines": { "node": ">=10" }, @@ -14448,779 +10267,817 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/is-plain-object": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-5.0.0.tgz", - "integrity": "sha512-VRSzKkbMm5jMDoKLbltAkFQ5Qr7VDiTFGXxYFXXowVj387GeGNOCsOH6Msy00SGZ3Fp84b1Naa1psqgcCIEP5Q==", + "node_modules/globjoin": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/globjoin/-/globjoin-0.1.4.tgz", + "integrity": "sha512-xYfnw62CKG8nLkZBfWbhWwDw02CHty86jfPcc2cr3ZfeuK9ysoVPPEUxf21bAD/rWAgk52SuBrLJlefNy8mvFg==", "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/is-promise": { - "version": "2.2.2", - "resolved": "https://registry.npmjs.org/is-promise/-/is-promise-2.2.2.tgz", - "integrity": "sha512-+lP4/6lKUBfQjZ2pdxThZvLUAafmZb8OAxFb8XXtiQmS35INgr85hdOGoEs124ez1FCnZJt6jau/T+alh58QFQ==", "license": "MIT" }, - "node_modules/is-regex": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz", - "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==", + "node_modules/good-listener": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/good-listener/-/good-listener-1.2.2.tgz", + "integrity": "sha512-goW1b+d9q/HIwbVYZzZ6SsTr4IgE+WA44A0GmPIQstuOrgsFcT7VEJ48nmr9GaRtNu0XTKacFLGnBPAM6Afouw==", "license": "MIT", "dependencies": { - "call-bind": "^1.0.2", - "has-tostringtag": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-set": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.3.tgz", - "integrity": "sha512-iPAjerrse27/ygGLxw+EBR9agv9Y6uLeYVJMu+QNCoouJ1/1ri0mGrcWpfCqFZuzzx3WjtwxG098X+n4OuRkPg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "delegate": "^3.1.2" } }, - "node_modules/is-shared-array-buffer": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.3.tgz", - "integrity": "sha512-nA2hv5XIhLR3uVzDDfCIknerhx8XUKnstuOERPNNIinXG7v9u+ohXF67vxm4TPTEPU6lm61ZkwP3c9PCB97rhg==", - "license": "MIT", + "node_modules/google-closure-compiler": { + "version": "20240317.0.0", + "resolved": "https://registry.npmjs.org/google-closure-compiler/-/google-closure-compiler-20240317.0.0.tgz", + "integrity": "sha512-PlC5aU2vwsypKbxyFNXOW4psDZfhDoOr2dCwuo8VcgQji+HVIgRi2lviO66x2SfTi0ilm3kI6rq/RSdOMFczcQ==", + "license": "Apache-2.0", "dependencies": { - "call-bind": "^1.0.7" + "chalk": "4.x", + "google-closure-compiler-java": "^20240317.0.0", + "minimist": "1.x", + "vinyl": "2.x", + "vinyl-sourcemaps-apply": "^0.2.0" + }, + "bin": { + "google-closure-compiler": "cli.js" }, "engines": { - "node": ">= 0.4" + "node": ">=10" }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "optionalDependencies": { + "google-closure-compiler-linux": "^20240317.0.0", + "google-closure-compiler-osx": "^20240317.0.0", + "google-closure-compiler-windows": "^20240317.0.0" } }, - "node_modules/is-stream": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", - "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==", - "license": "MIT", - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } + "node_modules/google-closure-compiler-java": { + "version": "20240317.0.0", + "resolved": "https://registry.npmjs.org/google-closure-compiler-java/-/google-closure-compiler-java-20240317.0.0.tgz", + "integrity": "sha512-oWURPChjcCrVfiQOuVtpSoUJVvtOYo41JGEQ2qtArsTGmk/DpWh40vS6hitwKRM/0YzJX/jYUuyt9ibuXXJKmg==", + "license": "Apache-2.0" }, - "node_modules/is-string": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz", - "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==", + "node_modules/google-closure-compiler-linux": { + "version": "20240317.0.0", + "resolved": "https://registry.npmjs.org/google-closure-compiler-linux/-/google-closure-compiler-linux-20240317.0.0.tgz", + "integrity": "sha512-dYLtcbbJdbbBS0lTy9SzySdVv/aGkpyTekQiW4ADhT/i1p1b4r0wQTKj6kpVVmFvbZ6t9tW/jbXc9EXXNUahZw==", + "cpu": [ + "x32", + "x64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/google-closure-compiler-osx": { + "version": "20240317.0.0", + "resolved": "https://registry.npmjs.org/google-closure-compiler-osx/-/google-closure-compiler-osx-20240317.0.0.tgz", + "integrity": "sha512-0mABwjD4HP11rikFd8JRIb9OgPqn9h3o3wS0otufMfmbwS7zRpnnoJkunifhORl3VoR1gFm6vcTC9YziTEFdOw==", + "cpu": [ + "x32", + "x64", + "arm64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/google-closure-compiler-windows": { + "version": "20240317.0.0", + "resolved": "https://registry.npmjs.org/google-closure-compiler-windows/-/google-closure-compiler-windows-20240317.0.0.tgz", + "integrity": "sha512-fTueVFzNOWURFlXZmrFkAB7yA+jzpA2TeDOYeBEFwVlVGHwi8PV3Q9vCIWlbkE8wLpukKEg5wfRHYrLwVPINCA==", + "cpu": [ + "x32", + "x64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/google-closure-compiler/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "license": "MIT", "dependencies": { - "has-tostringtag": "^1.0.0" + "color-convert": "^2.0.1" }, "engines": { - "node": ">= 0.4" + "node": ">=8" }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/is-symbol": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz", - "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==", + "node_modules/google-closure-compiler/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "license": "MIT", "dependencies": { - "has-symbols": "^1.0.2" + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" }, "engines": { - "node": ">= 0.4" + "node": ">=10" }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "url": "https://github.com/chalk/chalk?sponsor=1" } }, - "node_modules/is-touch-device": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-touch-device/-/is-touch-device-1.0.1.tgz", - "integrity": "sha512-LAYzo9kMT1b2p19L/1ATGt2XcSilnzNlyvq6c0pbPRVisLbAPpLqr53tIJS00kvrTkj0HtR8U7+u8X0yR8lPSw==", - "license": "MIT" - }, - "node_modules/is-typed-array": { - "version": "1.1.13", - "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.13.tgz", - "integrity": "sha512-uZ25/bUAlUY5fR4OKT4rZQEBrzQWYV9ZJYGGsUmEJ6thodVJ1HX64ePQ6Z0qPWP+m+Uq6e9UugrE38jeYsDSMw==", + "node_modules/google-closure-compiler/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "license": "MIT", "dependencies": { - "which-typed-array": "^1.1.14" + "color-name": "~1.1.4" }, "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "node": ">=7.0.0" } }, - "node_modules/is-typedarray": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz", - "integrity": "sha512-cyA56iCMHAh5CdzjJIa4aohJyeO1YbwLi3Jc35MmRU6poroFjIGZzUzupGiRPOjgHg9TLu43xbpwXk523fMxKA==", - "dev": true, + "node_modules/google-closure-compiler/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "license": "MIT" }, - "node_modules/is-unicode-supported": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz", - "integrity": "sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw==", + "node_modules/google-closure-compiler/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "license": "MIT", "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "node": ">=8" } }, - "node_modules/is-weakmap": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/is-weakmap/-/is-weakmap-2.0.2.tgz", - "integrity": "sha512-K5pXYOm9wqY1RgjpL3YTkF39tni1XajUIkawTLUo9EZEVUFga5gSQJF8nNS7ZwJQ02y+1YCNYcMh+HIf1ZqE+w==", - "dev": true, + "node_modules/google-closure-compiler/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "license": "MIT", - "engines": { - "node": ">= 0.4" + "dependencies": { + "has-flag": "^4.0.0" }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "engines": { + "node": ">=8" } }, - "node_modules/is-weakref": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz", - "integrity": "sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==", + "node_modules/gopd": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", + "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", "license": "MIT", "dependencies": { - "call-bind": "^1.0.2" + "get-intrinsic": "^1.1.3" }, "funding": { "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-weakset": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/is-weakset/-/is-weakset-2.0.3.tgz", - "integrity": "sha512-LvIm3/KWzS9oRFHugab7d+M/GcBXuXX5xZkzPmN+NxihdQlZUQ4dWuSV1xR/sq6upL1TJEDrfBgRepHFdBtSNQ==", + "node_modules/got": { + "version": "11.8.6", + "resolved": "https://registry.npmjs.org/got/-/got-11.8.6.tgz", + "integrity": "sha512-6tfZ91bOr7bOXnK7PRDCGBLa1H4U080YHNaAQ2KsMGlLEzRbk44nsZF2E1IeRc3vtJHPVbKCYgdFbaGO2ljd8g==", "dev": true, "license": "MIT", "dependencies": { - "call-bind": "^1.0.7", - "get-intrinsic": "^1.2.4" + "@sindresorhus/is": "^4.0.0", + "@szmarczak/http-timer": "^4.0.5", + "@types/cacheable-request": "^6.0.1", + "@types/responselike": "^1.0.0", + "cacheable-lookup": "^5.0.3", + "cacheable-request": "^7.0.2", + "decompress-response": "^6.0.0", + "http2-wrapper": "^1.0.0-beta.5.2", + "lowercase-keys": "^2.0.0", + "p-cancelable": "^2.0.0", + "responselike": "^2.0.0" }, "engines": { - "node": ">= 0.4" + "node": ">=10.19.0" }, "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-wsl": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/is-wsl/-/is-wsl-2.2.0.tgz", - "integrity": "sha512-fKzAra0rGJUUBwGBgNkHZuToZcn+TtXHpeCgmkMJMMYx1sQDYaCSyjJBSCa2nH1DGm7s3n1oBnohoVTBaN7Lww==", - "license": "MIT", - "dependencies": { - "is-docker": "^2.0.0" - }, - "engines": { - "node": ">=8" + "url": "https://github.com/sindresorhus/got?sponsor=1" } }, - "node_modules/isarray": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", - "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", - "license": "MIT" - }, - "node_modules/isexe": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", - "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", + "node_modules/graceful-fs": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", + "dev": true, "license": "ISC" }, - "node_modules/isobject": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", - "integrity": "sha512-WhB9zCku7EGTj/HQQRz5aUQEUeoQZH2bWcltRErOpymJ4boYE6wL9Tbr23krRPSZ+C5zqNSrSw+Cc7sZZ4b7vg==", - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/isstream": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz", - "integrity": "sha512-Yljz7ffyPbrLpLngrMtZ7NduUgVvi6wG9RJ9IUcyCd59YQ911PBJphODUcbOVbqYfxe1wuYf/LJ8PauMRwsM/g==", + "node_modules/graphemer": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/graphemer/-/graphemer-1.4.0.tgz", + "integrity": "sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==", "dev": true, "license": "MIT" }, - "node_modules/iterator.prototype": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/iterator.prototype/-/iterator.prototype-1.1.2.tgz", - "integrity": "sha512-DR33HMMr8EzwuRL8Y9D3u2BMj8+RqSE850jfGu59kS7tbmPLzGkZmVSfyCFSDxuZiEY6Rzt3T2NA/qU+NwVj1w==", - "dev": true, - "license": "MIT", - "dependencies": { - "define-properties": "^1.2.1", - "get-intrinsic": "^1.2.1", - "has-symbols": "^1.0.3", - "reflect.getprototypeof": "^1.0.4", - "set-function-name": "^2.0.1" - } - }, - "node_modules/jackspeak": { - "version": "3.4.3", - "resolved": "https://registry.npmjs.org/jackspeak/-/jackspeak-3.4.3.tgz", - "integrity": "sha512-OGlZQpz2yfahA/Rd1Y8Cd9SIEsqvXkLVoSw/cgwhnhFMDbsQFeZYoJJ7bIZBS9BcamUW96asq/npPWugM+RQBw==", + "node_modules/handle-thing": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/handle-thing/-/handle-thing-2.0.1.tgz", + "integrity": "sha512-9Qn4yBxelxoh2Ow62nP+Ka/kMnOXRi8BXnRaUwezLNhqelnN49xKz4F/dPP8OYLxLxq6JDtZb2i9XznUQbNPTg==", "dev": true, - "license": "BlueOak-1.0.0", - "dependencies": { - "@isaacs/cliui": "^8.0.2" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - }, - "optionalDependencies": { - "@pkgjs/parseargs": "^0.11.0" - } + "license": "MIT" }, - "node_modules/jest-environment-node": { - "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-environment-node/-/jest-environment-node-29.7.0.tgz", - "integrity": "sha512-DOSwCRqXirTOyheM+4d5YZOrWcdu0LNZ87ewUoywbcb2XR4wKgqiG8vNeYwhjFMbEkfju7wx2GYH0P2gevGvFw==", + "node_modules/has-bigints": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz", + "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==", "license": "MIT", - "peer": true, - "dependencies": { - "@jest/environment": "^29.7.0", - "@jest/fake-timers": "^29.7.0", - "@jest/types": "^29.6.3", - "@types/node": "*", - "jest-mock": "^29.7.0", - "jest-util": "^29.7.0" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/jest-get-type": { - "version": "29.6.3", - "resolved": "https://registry.npmjs.org/jest-get-type/-/jest-get-type-29.6.3.tgz", - "integrity": "sha512-zrteXnqYxfQh7l5FHyL38jL39di8H8rHoecLH3JNxH3BwOrBsNeabdap5e0I23lD4HHI8W5VFBZqG4Eaq5LNcw==", + "node_modules/has-flag": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", + "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", "license": "MIT", - "peer": true, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": ">=4" } }, - "node_modules/jest-message-util": { - "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-29.7.0.tgz", - "integrity": "sha512-GBEV4GRADeP+qtB2+6u61stea8mGcOT4mCtrYISZwfu9/ISHFJ/5zOMXYbpBE9RsS5+Gb63DW4FgmnKJ79Kf6w==", + "node_modules/has-property-descriptors": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.2.tgz", + "integrity": "sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==", "license": "MIT", - "peer": true, "dependencies": { - "@babel/code-frame": "^7.12.13", - "@jest/types": "^29.6.3", - "@types/stack-utils": "^2.0.0", - "chalk": "^4.0.0", - "graceful-fs": "^4.2.9", - "micromatch": "^4.0.4", - "pretty-format": "^29.7.0", - "slash": "^3.0.0", - "stack-utils": "^2.0.3" + "es-define-property": "^1.0.0" }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/jest-message-util/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/has-proto": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.3.tgz", + "integrity": "sha512-SJ1amZAJUiZS+PhsVLf5tGydlaVB8EdFpaSO4gmiUKUOxk8qzn5AIy4ZeJUmh22znIdk/uMAUT2pl3FxzVUH+Q==", "license": "MIT", - "peer": true, - "dependencies": { - "color-convert": "^2.0.1" + "engines": { + "node": ">= 0.4" }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==", + "license": "MIT", "engines": { - "node": ">=8" + "node": ">= 0.4" }, "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/jest-message-util/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/has-tostringtag": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.2.tgz", + "integrity": "sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==", "license": "MIT", - "peer": true, "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "has-symbols": "^1.0.3" }, "engines": { - "node": ">=10" + "node": ">= 0.4" }, "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/jest-message-util/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/hasown": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", + "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==", "license": "MIT", - "peer": true, "dependencies": { - "color-name": "~1.1.4" + "function-bind": "^1.1.2" }, "engines": { - "node": ">=7.0.0" + "node": ">= 0.4" } }, - "node_modules/jest-message-util/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "node_modules/hoist-non-react-statics": { + "version": "2.5.5", + "resolved": "https://registry.npmjs.org/hoist-non-react-statics/-/hoist-non-react-statics-2.5.5.tgz", + "integrity": "sha512-rqcy4pJo55FTTLWt+bU8ukscqHeE/e9KWvsOW2b/a3afxQZhwkQdT1rPPCJ0rYXdj4vNcasY8zHTH+jF/qStxw==", + "license": "BSD-3-Clause" + }, + "node_modules/hookified": { + "version": "1.8.2", + "resolved": "https://registry.npmjs.org/hookified/-/hookified-1.8.2.tgz", + "integrity": "sha512-5nZbBNP44sFCDjSoB//0N7m508APCgbQ4mGGo1KJGBYyCKNHfry1Pvd0JVHZIxjdnqn8nFRBAN/eFB6Rk/4w5w==", + "dev": true, + "license": "MIT" + }, + "node_modules/hpack.js": { + "version": "2.1.6", + "resolved": "https://registry.npmjs.org/hpack.js/-/hpack.js-2.1.6.tgz", + "integrity": "sha512-zJxVehUdMGIKsRaNt7apO2Gqp0BdqW5yaiGHXXmbpvxgBYVZnAql+BJb4RO5ad2MgpbZKn5G6nMnegrH1FcNYQ==", + "dev": true, "license": "MIT", - "peer": true + "dependencies": { + "inherits": "^2.0.1", + "obuf": "^1.0.0", + "readable-stream": "^2.0.1", + "wbuf": "^1.1.0" + } }, - "node_modules/jest-message-util/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/html-entities": { + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/html-entities/-/html-entities-2.5.2.tgz", + "integrity": "sha512-K//PSRMQk4FZ78Kyau+mZurHn3FH0Vwr+H36eE0rPbeYkRRi9YxceYPhuN60UwWorxyKHhqoAJl2OFKa4BVtaA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/mdevils" + }, + { + "type": "patreon", + "url": "https://patreon.com/mdevils" + } + ], + "license": "MIT" + }, + "node_modules/html-tags": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/html-tags/-/html-tags-3.3.1.tgz", + "integrity": "sha512-ztqyC3kLto0e9WbNp0aeP+M3kTt+nbaIveGmUxAtZa+8iFgKLUOD4YKM5j+f3QD89bra7UeumolZHKuOXnTmeQ==", + "dev": true, "license": "MIT", - "peer": true, "engines": { "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/jest-message-util/node_modules/pretty-format": { - "version": "29.7.0", - "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-29.7.0.tgz", - "integrity": "sha512-Pdlw/oPxN+aXdmM9R00JVC9WVFoCLTKJvDVLgmJ+qAffBMxsV85l/Lu7sNx4zSzPyoL2euImuEwHhOXdEgNFZQ==", + "node_modules/html-validate": { + "version": "8.22.0", + "resolved": "https://registry.npmjs.org/html-validate/-/html-validate-8.22.0.tgz", + "integrity": "sha512-kKDnU04zdxQIOSZVD6BKma6gWpCMCCFwYvHWwTorBMVbSYXMW1B5kGgLwOMHzTlC3yiuaO7NvJprXk3w7Jko/Q==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/html-validate" + } + ], "license": "MIT", - "peer": true, + "workspaces": [ + "docs", + "tests/vitest" + ], "dependencies": { - "@jest/schemas": "^29.6.3", - "ansi-styles": "^5.0.0", - "react-is": "^18.0.0" + "@html-validate/stylish": "^4.1.0", + "@sidvind/better-ajv-errors": "3.0.1", + "ajv": "^8.0.0", + "deepmerge": "4.3.1", + "glob": "^10.0.0", + "ignore": "5.3.2", + "kleur": "^4.1.0", + "minimist": "^1.2.0", + "prompts": "^2.0.0", + "semver": "^7.0.0" + }, + "bin": { + "html-validate": "bin/html-validate.js" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": ">= 16.14" + }, + "peerDependencies": { + "jest": "^27.1 || ^28.1.3 || ^29.0.3", + "jest-diff": "^27.1 || ^28.1.3 || ^29.0.3", + "jest-snapshot": "^27.1 || ^28.1.3 || ^29.0.3", + "vitest": "^0.34 || ^1" + }, + "peerDependenciesMeta": { + "jest": { + "optional": true + }, + "jest-diff": { + "optional": true + }, + "jest-snapshot": { + "optional": true + }, + "vitest": { + "optional": true + } } }, - "node_modules/jest-message-util/node_modules/pretty-format/node_modules/ansi-styles": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", - "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "node_modules/html-validate/node_modules/ajv": { + "version": "8.17.1", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.17.1.tgz", + "integrity": "sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g==", + "dev": true, "license": "MIT", - "peer": true, - "engines": { - "node": ">=10" + "dependencies": { + "fast-deep-equal": "^3.1.3", + "fast-uri": "^3.0.1", + "json-schema-traverse": "^1.0.0", + "require-from-string": "^2.0.2" }, "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" } }, - "node_modules/jest-message-util/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "license": "MIT", - "peer": true, - "dependencies": { - "has-flag": "^4.0.0" + "node_modules/html-validate/node_modules/json-schema-traverse": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", + "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", + "dev": true, + "license": "MIT" + }, + "node_modules/html-validate/node_modules/semver": { + "version": "7.6.3", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.3.tgz", + "integrity": "sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" }, "engines": { - "node": ">=8" + "node": ">=10" } }, - "node_modules/jest-mock": { - "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-29.7.0.tgz", - "integrity": "sha512-ITOMZn+UkYS4ZFh83xYAOzWStloNzJFO2s8DWrE4lhtGD+AorgnbkiKERe4wQVBydIGPx059g6riW5Btp6Llnw==", + "node_modules/http-cache-semantics": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/http-cache-semantics/-/http-cache-semantics-4.1.1.tgz", + "integrity": "sha512-er295DKPVsV82j5kw1Gjt+ADA/XYHsajl82cGNQG2eyoPkvgUhX+nDIyelzhIWbbsXP39EHcI6l5tYs2FYqYXQ==", + "dev": true, + "license": "BSD-2-Clause" + }, + "node_modules/http-deceiver": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/http-deceiver/-/http-deceiver-1.2.7.tgz", + "integrity": "sha512-LmpOGxTfbpgtGVxJrj5k7asXHCgNZp5nLfp+hWc8QQRqtb7fUy6kRY3BO1h9ddF6yIPYUARgxGOwB42DnxIaNw==", + "dev": true, + "license": "MIT" + }, + "node_modules/http-errors": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-2.0.0.tgz", + "integrity": "sha512-FtwrG/euBzaEjYeRqOgly7G0qviiXoJWnvEH2Z1plBdXgbyjv34pHTSb9zoeHMyDy33+DWy5Wt9Wo+TURtOYSQ==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "@jest/types": "^29.6.3", - "@types/node": "*", - "jest-util": "^29.7.0" + "depd": "2.0.0", + "inherits": "2.0.4", + "setprototypeof": "1.2.0", + "statuses": "2.0.1", + "toidentifier": "1.0.1" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": ">= 0.8" } }, - "node_modules/jest-util": { - "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-29.7.0.tgz", - "integrity": "sha512-z6EbKajIpqGKU56y5KBUgy1dt1ihhQJgWzUlZHArA/+X2ad7Cb5iF+AK1EWVL/Bo7Rz9uurpqw6SiBCefUbCGA==", + "node_modules/http-parser-js": { + "version": "0.5.8", + "resolved": "https://registry.npmjs.org/http-parser-js/-/http-parser-js-0.5.8.tgz", + "integrity": "sha512-SGeBX54F94Wgu5RH3X5jsDtf4eHyRogWX1XGT3b4HuW3tQPM4AaBzoUji/4AAJNXCEOWZ5O0DgZmJw1947gD5Q==", + "dev": true, + "license": "MIT" + }, + "node_modules/http-proxy": { + "version": "1.18.1", + "resolved": "https://registry.npmjs.org/http-proxy/-/http-proxy-1.18.1.tgz", + "integrity": "sha512-7mz/721AbnJwIVbnaSv1Cz3Am0ZLT/UBwkC92VlxhXv/k/BBQfM2fXElQNC27BVGr0uwUpplYPQM9LnaBMR5NQ==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "@jest/types": "^29.6.3", - "@types/node": "*", - "chalk": "^4.0.0", - "ci-info": "^3.2.0", - "graceful-fs": "^4.2.9", - "picomatch": "^2.2.3" + "eventemitter3": "^4.0.0", + "follow-redirects": "^1.0.0", + "requires-port": "^1.0.0" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": ">=8.0.0" } }, - "node_modules/jest-util/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/http-proxy-middleware": { + "version": "2.0.9", + "resolved": "https://registry.npmjs.org/http-proxy-middleware/-/http-proxy-middleware-2.0.9.tgz", + "integrity": "sha512-c1IyJYLYppU574+YI7R4QyX2ystMtVXZwIdzazUIPIJsHuWNd+mho2j+bKoHftndicGj9yh+xjd+l0yj7VeT1Q==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "color-convert": "^2.0.1" + "@types/http-proxy": "^1.17.8", + "http-proxy": "^1.18.1", + "is-glob": "^4.0.1", + "is-plain-obj": "^3.0.0", + "micromatch": "^4.0.2" }, "engines": { - "node": ">=8" + "node": ">=12.0.0" }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "peerDependencies": { + "@types/express": "^4.17.13" + }, + "peerDependenciesMeta": { + "@types/express": { + "optional": true + } } }, - "node_modules/jest-util/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/http-signature": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.4.0.tgz", + "integrity": "sha512-G5akfn7eKbpDN+8nPS/cb57YeA1jLTVxjpCj7tmm3QKPdyDy7T+qSC40e9ptydSWvkwjSXw1VbkpyEm39ukeAg==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "assert-plus": "^1.0.0", + "jsprim": "^2.0.2", + "sshpk": "^1.18.0" }, "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "node": ">=0.10" } }, - "node_modules/jest-util/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/http2-wrapper": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/http2-wrapper/-/http2-wrapper-1.0.3.tgz", + "integrity": "sha512-V+23sDMr12Wnz7iTcDeJr3O6AIxlnvT/bmaAAAP/Xda35C90p9599p0F1eHR/N1KILWSoWVAiOMFjBBXaXSMxg==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "color-name": "~1.1.4" + "quick-lru": "^5.1.1", + "resolve-alpn": "^1.0.0" }, "engines": { - "node": ">=7.0.0" + "node": ">=10.19.0" } }, - "node_modules/jest-util/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT", - "peer": true - }, - "node_modules/jest-util/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "license": "MIT", - "peer": true, + "node_modules/human-signals": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-1.1.1.tgz", + "integrity": "sha512-SEQu7vl8KjNL2eoGBLF3+wAjpsNfA9XMlXAYj/3EdaNfAlxKthD1xjEQfGOUhllCGGJVNY34bRr6lPINhNjyZw==", + "dev": true, + "license": "Apache-2.0", "engines": { - "node": ">=8" + "node": ">=8.12.0" } }, - "node_modules/jest-util/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/iconv-lite": { + "version": "0.6.3", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz", + "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", "license": "MIT", - "peer": true, "dependencies": { - "has-flag": "^4.0.0" + "safer-buffer": ">= 2.1.2 < 3.0.0" }, "engines": { - "node": ">=8" + "node": ">=0.10.0" } }, - "node_modules/jest-validate": { - "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-validate/-/jest-validate-29.7.0.tgz", - "integrity": "sha512-ZB7wHqaRGVw/9hST/OuFUReG7M8vKeq0/J2egIGLdvjHCmYqGARhzXmtgi+gVeZ5uXFF219aOc3Ls2yLg27tkw==", - "license": "MIT", - "peer": true, - "dependencies": { - "@jest/types": "^29.6.3", - "camelcase": "^6.2.0", - "chalk": "^4.0.0", - "jest-get-type": "^29.6.3", - "leven": "^3.1.0", - "pretty-format": "^29.7.0" + "node_modules/icss-utils": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/icss-utils/-/icss-utils-5.1.0.tgz", + "integrity": "sha512-soFhflCVWLfRNOPU3iv5Z9VUdT44xFRbzjLsEzSr5AQmgqPMTHdU3PMT1Cf1ssx8fLNJDA1juftYl+PUcv3MqA==", + "dev": true, + "license": "ISC", + "engines": { + "node": "^10 || ^12 || >= 14" }, + "peerDependencies": { + "postcss": "^8.1.0" + } + }, + "node_modules/ieee754": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", + "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "BSD-3-Clause" + }, + "node_modules/ignore": { + "version": "5.3.2", + "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.2.tgz", + "integrity": "sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g==", + "dev": true, + "license": "MIT", "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": ">= 4" } }, - "node_modules/jest-validate/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/immutable": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/immutable/-/immutable-5.1.1.tgz", + "integrity": "sha512-3jatXi9ObIsPGr3N5hGw/vWWcTkq6hUYhpQz4k0wLC+owqWi/LiugIw9x0EdNZ2yGedKN/HzePiBvaJRXa0Ujg==", + "dev": true, + "license": "MIT" + }, + "node_modules/import-fresh": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz", + "integrity": "sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "color-convert": "^2.0.1" + "parent-module": "^1.0.0", + "resolve-from": "^4.0.0" }, "engines": { - "node": ">=8" + "node": ">=6" }, "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/jest-validate/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/import-local": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/import-local/-/import-local-3.2.0.tgz", + "integrity": "sha512-2SPlun1JUPWoM6t3F0dw0FkCF/jWY8kttcY4f599GLTSjh2OCuuhdTkJQsEcZzBqbXZGKMK2OqW1oZsjtf/gQA==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "pkg-dir": "^4.2.0", + "resolve-cwd": "^3.0.0" + }, + "bin": { + "import-local-fixture": "fixtures/cli.js" }, "engines": { - "node": ">=10" + "node": ">=8" }, "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/jest-validate/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/import-local/node_modules/find-up": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", + "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "color-name": "~1.1.4" + "locate-path": "^5.0.0", + "path-exists": "^4.0.0" }, "engines": { - "node": ">=7.0.0" + "node": ">=8" } }, - "node_modules/jest-validate/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT", - "peer": true - }, - "node_modules/jest-validate/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/import-local/node_modules/locate-path": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", + "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", + "dev": true, "license": "MIT", - "peer": true, + "dependencies": { + "p-locate": "^4.1.0" + }, "engines": { "node": ">=8" } }, - "node_modules/jest-validate/node_modules/pretty-format": { - "version": "29.7.0", - "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-29.7.0.tgz", - "integrity": "sha512-Pdlw/oPxN+aXdmM9R00JVC9WVFoCLTKJvDVLgmJ+qAffBMxsV85l/Lu7sNx4zSzPyoL2euImuEwHhOXdEgNFZQ==", + "node_modules/import-local/node_modules/p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "@jest/schemas": "^29.6.3", - "ansi-styles": "^5.0.0", - "react-is": "^18.0.0" + "p-try": "^2.0.0" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/jest-validate/node_modules/pretty-format/node_modules/ansi-styles": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", - "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "node_modules/import-local/node_modules/p-locate": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", + "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", + "dev": true, "license": "MIT", - "peer": true, - "engines": { - "node": ">=10" + "dependencies": { + "p-limit": "^2.2.0" }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "engines": { + "node": ">=8" } }, - "node_modules/jest-validate/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/import-local/node_modules/pkg-dir": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-4.2.0.tgz", + "integrity": "sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "has-flag": "^4.0.0" + "find-up": "^4.0.0" }, "engines": { "node": ">=8" } }, - "node_modules/jest-worker": { - "version": "27.5.1", - "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-27.5.1.tgz", - "integrity": "sha512-7vuh85V5cdDofPyxn58nrPjBktZo0u9x1g8WtjQol+jZDaE+fhN+cIvTj11GndBnMnyfrUOG1sZQxCdjKh+DKg==", + "node_modules/imurmurhash": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", + "integrity": "sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==", "dev": true, "license": "MIT", - "dependencies": { - "@types/node": "*", - "merge-stream": "^2.0.0", - "supports-color": "^8.0.0" - }, "engines": { - "node": ">= 10.13.0" + "node": ">=0.8.19" } }, - "node_modules/jest-worker/node_modules/has-flag": { + "node_modules/indent-string": { "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-4.0.0.tgz", + "integrity": "sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==", "dev": true, "license": "MIT", "engines": { "node": ">=8" } }, - "node_modules/jest-worker/node_modules/supports-color": { - "version": "8.1.1", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", - "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", + "node_modules/inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==", + "deprecated": "This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.", "dev": true, - "license": "MIT", - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/supports-color?sponsor=1" - } - }, - "node_modules/joi": { - "version": "17.13.3", - "resolved": "https://registry.npmjs.org/joi/-/joi-17.13.3.tgz", - "integrity": "sha512-otDA4ldcIx+ZXsKHWmp0YizCweVRZG96J10b0FevjfuncLO1oX59THoAmHkNubYJ+9gWsYsp5k8v4ib6oDv1fA==", - "license": "BSD-3-Clause", - "peer": true, + "license": "ISC", "dependencies": { - "@hapi/hoek": "^9.3.0", - "@hapi/topo": "^5.1.0", - "@sideway/address": "^4.1.5", - "@sideway/formula": "^3.0.1", - "@sideway/pinpoint": "^2.0.0" + "once": "^1.3.0", + "wrappy": "1" } }, - "node_modules/js-tokens": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", - "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", - "license": "MIT" + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", + "license": "ISC" }, - "node_modules/js-yaml": { - "version": "3.14.1", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.1.tgz", - "integrity": "sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==", - "license": "MIT", - "dependencies": { - "argparse": "^1.0.7", - "esprima": "^4.0.0" - }, - "bin": { - "js-yaml": "bin/js-yaml.js" + "node_modules/ini": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ini/-/ini-2.0.0.tgz", + "integrity": "sha512-7PnF4oN3CvZF23ADhA5wRaYEQpJ8qygSkbtTXWBeXWXmEVRXK+1ITciHWwHhsjv1TmW0MgacIv6hEi5pX5NQdA==", + "dev": true, + "license": "ISC", + "engines": { + "node": ">=10" } }, - "node_modules/jsbn": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz", - "integrity": "sha512-UVU9dibq2JcFWxQPA6KCqj5O42VOmAY3zQUfEKxU0KpTGXwNoCjkX1e13eHNvw/xPynt6pU0rZ1htjWTNTSXsg==", + "node_modules/inquirer": { + "version": "7.3.3", + "resolved": "https://registry.npmjs.org/inquirer/-/inquirer-7.3.3.tgz", + "integrity": "sha512-JG3eIAj5V9CwcGvuOmoo6LB9kbAYT8HXffUl6memuszlwDC/qvFAJw49XJ5NROSFNPxp3iQg1GqkFhaY/CR0IA==", "dev": true, - "license": "MIT" - }, - "node_modules/jsc-android": { - "version": "250231.0.0", - "resolved": "https://registry.npmjs.org/jsc-android/-/jsc-android-250231.0.0.tgz", - "integrity": "sha512-rS46PvsjYmdmuz1OAWXY/1kCYG7pnf1TBqeTiOJr1iDz7s5DLxxC9n/ZMknLDxzYzNVfI7R95MH10emSSG1Wuw==", - "license": "BSD-2-Clause", - "peer": true - }, - "node_modules/jsc-safe-url": { - "version": "0.2.4", - "resolved": "https://registry.npmjs.org/jsc-safe-url/-/jsc-safe-url-0.2.4.tgz", - "integrity": "sha512-0wM3YBWtYePOjfyXQH5MWQ8H7sdk5EXSwZvmSLKk2RboVQ2Bu239jycHDz5J/8Blf3K0Qnoy2b6xD+z10MFB+Q==", - "license": "0BSD", - "peer": true - }, - "node_modules/jscodeshift": { - "version": "0.14.0", - "resolved": "https://registry.npmjs.org/jscodeshift/-/jscodeshift-0.14.0.tgz", - "integrity": "sha512-7eCC1knD7bLUPuSCwXsMZUH51O8jIcoVyKtI6P0XM0IVzlGjckPy3FIwQlorzbN0Sg79oK+RlohN32Mqf/lrYA==", - "license": "MIT", - "peer": true, - "dependencies": { - "@babel/core": "^7.13.16", - "@babel/parser": "^7.13.16", - "@babel/plugin-proposal-class-properties": "^7.13.0", - "@babel/plugin-proposal-nullish-coalescing-operator": "^7.13.8", - "@babel/plugin-proposal-optional-chaining": "^7.13.12", - "@babel/plugin-transform-modules-commonjs": "^7.13.8", - "@babel/preset-flow": "^7.13.13", - "@babel/preset-typescript": "^7.13.0", - "@babel/register": "^7.13.16", - "babel-core": "^7.0.0-bridge.0", - "chalk": "^4.1.2", - "flow-parser": "0.*", - "graceful-fs": "^4.2.4", - "micromatch": "^4.0.4", - "neo-async": "^2.5.0", - "node-dir": "^0.1.17", - "recast": "^0.21.0", - "temp": "^0.8.4", - "write-file-atomic": "^2.3.0" - }, - "bin": { - "jscodeshift": "bin/jscodeshift.js" + "license": "MIT", + "dependencies": { + "ansi-escapes": "^4.2.1", + "chalk": "^4.1.0", + "cli-cursor": "^3.1.0", + "cli-width": "^3.0.0", + "external-editor": "^3.0.3", + "figures": "^3.0.0", + "lodash": "^4.17.19", + "mute-stream": "0.0.8", + "run-async": "^2.4.0", + "rxjs": "^6.6.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0", + "through": "^2.3.6" }, - "peerDependencies": { - "@babel/preset-env": "^7.1.6" + "engines": { + "node": ">=8.0.0" } }, - "node_modules/jscodeshift/node_modules/ansi-styles": { + "node_modules/inquirer/node_modules/ansi-styles": { "version": "4.3.0", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { "color-convert": "^2.0.1" }, @@ -15231,12 +11088,12 @@ "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/jscodeshift/node_modules/chalk": { + "node_modules/inquirer/node_modules/chalk": { "version": "4.1.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -15248,12 +11105,12 @@ "url": "https://github.com/chalk/chalk?sponsor=1" } }, - "node_modules/jscodeshift/node_modules/color-convert": { + "node_modules/inquirer/node_modules/color-convert": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { "color-name": "~1.1.4" }, @@ -15261,29 +11118,29 @@ "node": ">=7.0.0" } }, - "node_modules/jscodeshift/node_modules/color-name": { + "node_modules/inquirer/node_modules/color-name": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT", - "peer": true + "dev": true, + "license": "MIT" }, - "node_modules/jscodeshift/node_modules/has-flag": { + "node_modules/inquirer/node_modules/has-flag": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, "license": "MIT", - "peer": true, "engines": { "node": ">=8" } }, - "node_modules/jscodeshift/node_modules/supports-color": { + "node_modules/inquirer/node_modules/supports-color": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { "has-flag": "^4.0.0" }, @@ -15291,384 +11148,311 @@ "node": ">=8" } }, - "node_modules/jsdoc-type-pratt-parser": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/jsdoc-type-pratt-parser/-/jsdoc-type-pratt-parser-4.0.0.tgz", - "integrity": "sha512-YtOli5Cmzy3q4dP26GraSOeAhqecewG04hoO8DY56CH4KJ9Fvv5qKWUCCo3HZob7esJQHCv6/+bnTy72xZZaVQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=12.0.0" - } - }, - "node_modules/jsesc": { - "version": "2.5.2", - "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz", - "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==", - "license": "MIT", - "bin": { - "jsesc": "bin/jsesc" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/json-buffer": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz", - "integrity": "sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==", - "dev": true, - "license": "MIT" - }, - "node_modules/json-parse-better-errors": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz", - "integrity": "sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw==", - "license": "MIT", - "peer": true - }, - "node_modules/json-parse-even-better-errors": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz", - "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==", - "license": "MIT" - }, - "node_modules/json-schema": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/json-schema/-/json-schema-0.4.0.tgz", - "integrity": "sha512-es94M3nTIfsEPisRafak+HDLfHXnKBhV3vU5eqPcS3flIWqcxJWgXHXiey3YrpaNsanY5ei1VoYEbOzijuq9BA==", - "dev": true, - "license": "(AFL-2.1 OR BSD-3-Clause)" - }, - "node_modules/json-schema-traverse": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", - "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", - "dev": true, - "license": "MIT" - }, - "node_modules/json-stable-stringify-without-jsonify": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz", - "integrity": "sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==", - "dev": true, - "license": "MIT" - }, - "node_modules/json-stringify-safe": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz", - "integrity": "sha512-ZClg6AaYvamvYEE82d3Iyd3vSSIjQ+odgjaTzRuO3s7toCdFKczob2i0zCh7JE8kWn17yvAWhUVxvqGwUalsRA==", - "dev": true, - "license": "ISC" - }, - "node_modules/json5": { - "version": "2.2.3", - "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz", - "integrity": "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==", - "license": "MIT", - "bin": { - "json5": "lib/cli.js" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/jsonfile": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz", - "integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==", - "dev": true, + "node_modules/internal-slot": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.7.tgz", + "integrity": "sha512-NGnrKwXzSms2qUUih/ILZ5JBqNTSa1+ZmP6flaIp6KmSElgE9qdndzS3cqjrDovwFdmwsGsLdeFgB6suw+1e9g==", "license": "MIT", "dependencies": { - "universalify": "^2.0.0" + "es-errors": "^1.3.0", + "hasown": "^2.0.0", + "side-channel": "^1.0.4" }, - "optionalDependencies": { - "graceful-fs": "^4.1.6" - } - }, - "node_modules/jsprim": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/jsprim/-/jsprim-2.0.2.tgz", - "integrity": "sha512-gqXddjPqQ6G40VdnI6T6yObEC+pDNvyP95wdQhkWkg7crHH3km5qP1FsOXEkzEQwnz6gz5qGTn1c2Y52wP3OyQ==", - "dev": true, - "engines": [ - "node >=0.6.0" - ], - "license": "MIT", - "dependencies": { - "assert-plus": "1.0.0", - "extsprintf": "1.3.0", - "json-schema": "0.4.0", - "verror": "1.10.0" + "engines": { + "node": ">= 0.4" } }, - "node_modules/jsx-ast-utils": { - "version": "3.3.5", - "resolved": "https://registry.npmjs.org/jsx-ast-utils/-/jsx-ast-utils-3.3.5.tgz", - "integrity": "sha512-ZZow9HBI5O6EPgSJLUb8n2NKgmVWTwCvHGwFuJlMjvLFqlGG6pjirPhtdsseaLZjSibD8eegzmYpUZwoIlj2cQ==", + "node_modules/interpret": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/interpret/-/interpret-1.4.0.tgz", + "integrity": "sha512-agE4QfB2Lkp9uICn7BAqoscw4SZP9kTE2hxiFI3jBPmXJfdqiahTbUuKGsMoN2GtqL9AxhYioAcVvgsb1HvRbA==", "dev": true, "license": "MIT", - "dependencies": { - "array-includes": "^3.1.6", - "array.prototype.flat": "^1.3.1", - "object.assign": "^4.1.4", - "object.values": "^1.1.6" - }, "engines": { - "node": ">=4.0" + "node": ">= 0.10" } }, - "node_modules/keyv": { - "version": "4.5.4", - "resolved": "https://registry.npmjs.org/keyv/-/keyv-4.5.4.tgz", - "integrity": "sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==", + "node_modules/ipaddr.js": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-2.2.0.tgz", + "integrity": "sha512-Ag3wB2o37wslZS19hZqorUnrnzSkpOVy+IiiDEiTqNubEYpYuHWIf6K4psgN2ZWKExS4xhVCrRVfb/wfW8fWJA==", "dev": true, "license": "MIT", - "dependencies": { - "json-buffer": "3.0.1" + "engines": { + "node": ">= 10" } }, - "node_modules/kind-of": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.3.tgz", - "integrity": "sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==", + "node_modules/is-arguments": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.1.1.tgz", + "integrity": "sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==", + "dev": true, "license": "MIT", + "dependencies": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + }, "engines": { - "node": ">=0.10.0" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/kleur": { - "version": "4.1.5", - "resolved": "https://registry.npmjs.org/kleur/-/kleur-4.1.5.tgz", - "integrity": "sha512-o+NO+8WrRiQEE4/7nwRJhN1HWpVmJm511pBHUxPLtp0BUISzlBplORYSmTclCnJvQq2tKu/sgl3xVpkc7ZWuQQ==", - "dev": true, + "node_modules/is-array-buffer": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.4.tgz", + "integrity": "sha512-wcjaerHw0ydZwfhiKbXJWLDY8A7yV7KhjQOpb83hGgGfId/aQa4TOvwyzn2PuswW2gPCYEL/nEAiSVpdOj1lXw==", "license": "MIT", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.1" + }, "engines": { - "node": ">=6" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/known-css-properties": { - "version": "0.36.0", - "resolved": "https://registry.npmjs.org/known-css-properties/-/known-css-properties-0.36.0.tgz", - "integrity": "sha512-A+9jP+IUmuQsNdsLdcg6Yt7voiMF/D4K83ew0OpJtpu+l34ef7LaohWV0Rc6KNvzw6ZDizkqfyB5JznZnzuKQA==", + "node_modules/is-arrayish": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", + "integrity": "sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg==", "dev": true, "license": "MIT" }, - "node_modules/language-subtag-registry": { - "version": "0.3.23", - "resolved": "https://registry.npmjs.org/language-subtag-registry/-/language-subtag-registry-0.3.23.tgz", - "integrity": "sha512-0K65Lea881pHotoGEa5gDlMxt3pctLi2RplBb7Ezh4rRdLEOtgi7n4EwK9lamnUCkKBqaeKRVebTq6BAxSkpXQ==", - "dev": true, - "license": "CC0-1.0" - }, - "node_modules/language-tags": { - "version": "1.0.9", - "resolved": "https://registry.npmjs.org/language-tags/-/language-tags-1.0.9.tgz", - "integrity": "sha512-MbjN408fEndfiQXbFQ1vnd+1NoLDsnQW41410oQBXiyXDMYH5z505juWa4KUE1LqxRC7DgOgZDbKLxHIwm27hA==", + "node_modules/is-async-function": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-async-function/-/is-async-function-2.0.0.tgz", + "integrity": "sha512-Y1JXKrfykRJGdlDwdKlLpLyMIiWqWvuSd17TvZk68PLAOGOoF4Xyav1z0Xhoi+gCYjZVeC5SI+hYFOfvXmGRCA==", "dev": true, "license": "MIT", "dependencies": { - "language-subtag-registry": "^0.3.20" + "has-tostringtag": "^1.0.0" }, "engines": { - "node": ">=0.10" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/launch-editor": { - "version": "2.9.1", - "resolved": "https://registry.npmjs.org/launch-editor/-/launch-editor-2.9.1.tgz", - "integrity": "sha512-Gcnl4Bd+hRO9P9icCP/RVVT2o8SFlPXofuCxvA2SaZuH45whSvf5p8x5oih5ftLiVhEI4sp5xDY+R+b3zJBh5w==", - "dev": true, + "node_modules/is-bigint": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", + "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==", "license": "MIT", "dependencies": { - "picocolors": "^1.0.0", - "shell-quote": "^1.8.1" + "has-bigints": "^1.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/lazy-ass": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/lazy-ass/-/lazy-ass-1.6.0.tgz", - "integrity": "sha512-cc8oEVoctTvsFZ/Oje/kGnHbpWHYBe8IAJe4C0QNc3t8uM/0Y8+erSz/7Y1ALuXTEZTMvxXwO6YbX1ey3ujiZw==", + "node_modules/is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", "dev": true, "license": "MIT", + "dependencies": { + "binary-extensions": "^2.0.0" + }, "engines": { - "node": "> 0.8" + "node": ">=8" } }, - "node_modules/leven": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/leven/-/leven-3.1.0.tgz", - "integrity": "sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A==", + "node_modules/is-boolean-object": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz", + "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==", "license": "MIT", - "peer": true, + "dependencies": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + }, "engines": { - "node": ">=6" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/levn": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz", - "integrity": "sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==", + "node_modules/is-builtin-module": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/is-builtin-module/-/is-builtin-module-3.2.1.tgz", + "integrity": "sha512-BSLE3HnV2syZ0FK0iMA/yUGplUeMmNz4AW5fnTunbCIqZi4vG3WjJT9FHMy5D69xmAYBHXQhJdALdpwVxV501A==", "dev": true, "license": "MIT", "dependencies": { - "prelude-ls": "^1.2.1", - "type-check": "~0.4.0" + "builtin-modules": "^3.3.0" }, "engines": { - "node": ">= 0.8.0" + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/lighthouse-logger": { - "version": "1.4.2", - "resolved": "https://registry.npmjs.org/lighthouse-logger/-/lighthouse-logger-1.4.2.tgz", - "integrity": "sha512-gPWxznF6TKmUHrOQjlVo2UbaL2EJ71mb2CCeRs/2qBpi4L/g4LUVc9+3lKQ6DTUZwJswfM7ainGrLO1+fOqa2g==", - "license": "Apache-2.0", - "peer": true, - "dependencies": { - "debug": "^2.6.9", - "marky": "^1.2.2" + "node_modules/is-callable": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", + "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==", + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/lighthouse-logger/node_modules/debug": { - "version": "2.6.9", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "node_modules/is-ci": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/is-ci/-/is-ci-3.0.1.tgz", + "integrity": "sha512-ZYvCgrefwqoQ6yTyYUbQu64HsITZ3NfKX1lzaEYdkTDcfKzzCI/wthRRYKkdjHKFVgNiXKAKm65Zo1pk2as/QQ==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "ms": "2.0.0" + "ci-info": "^3.2.0" + }, + "bin": { + "is-ci": "bin.js" } }, - "node_modules/lighthouse-logger/node_modules/ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", - "license": "MIT", - "peer": true - }, - "node_modules/lines-and-columns": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/lines-and-columns/-/lines-and-columns-1.2.4.tgz", - "integrity": "sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==", - "license": "MIT" - }, - "node_modules/listr2": { - "version": "3.14.0", - "resolved": "https://registry.npmjs.org/listr2/-/listr2-3.14.0.tgz", - "integrity": "sha512-TyWI8G99GX9GjE54cJ+RrNMcIFBfwMPxc3XTFiAYGN4s10hWROGtOg7+O6u6LE3mNkyld7RSLE6nrKBvTfcs3g==", + "node_modules/is-core-module": { + "version": "2.15.1", + "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.15.1.tgz", + "integrity": "sha512-z0vtXSwucUJtANQWldhbtbt7BnL0vxiFjIdDLAatwhDYty2bad6s+rijD6Ri4YuYJubLzIJLUidCh09e1djEVQ==", "dev": true, "license": "MIT", "dependencies": { - "cli-truncate": "^2.1.0", - "colorette": "^2.0.16", - "log-update": "^4.0.0", - "p-map": "^4.0.0", - "rfdc": "^1.3.0", - "rxjs": "^7.5.1", - "through": "^2.3.8", - "wrap-ansi": "^7.0.0" + "hasown": "^2.0.2" }, "engines": { - "node": ">=10.0.0" + "node": ">= 0.4" }, - "peerDependencies": { - "enquirer": ">= 2.3.0 < 3" + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-data-view": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-data-view/-/is-data-view-1.0.1.tgz", + "integrity": "sha512-AHkaJrsUVW6wq6JS8y3JnM/GJF/9cf+k20+iDzlSaJrinEo5+7vRiteOSwBhHRiAyQATN1AmY4hwzxJKPmYf+w==", + "license": "MIT", + "dependencies": { + "is-typed-array": "^1.1.13" }, - "peerDependenciesMeta": { - "enquirer": { - "optional": true - } + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/listr2/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, + "node_modules/is-date-object": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz", + "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==", "license": "MIT", "dependencies": { - "color-convert": "^2.0.1" + "has-tostringtag": "^1.0.0" }, "engines": { - "node": ">=8" + "node": ">= 0.4" }, "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/listr2/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/is-docker": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/is-docker/-/is-docker-2.2.1.tgz", + "integrity": "sha512-F+i2BKsFrH66iaUFc0woD8sLy8getkwTwtOBjvs56Cx4CgJDeKQeqfz8wAYiSb8JOprWhHH5p77PbmYCvvUuXQ==", "dev": true, "license": "MIT", - "dependencies": { - "color-name": "~1.1.4" + "bin": { + "is-docker": "cli.js" }, "engines": { - "node": ">=7.0.0" + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/listr2/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "node_modules/is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==", "dev": true, - "license": "MIT" + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } }, - "node_modules/listr2/node_modules/rxjs": { - "version": "7.8.1", - "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-7.8.1.tgz", - "integrity": "sha512-AA3TVj+0A2iuIoQkWEK/tqFjBq2j+6PO6Y0zJcvzLAFhEFIO3HL0vls9hWLncZbAAbK0mar7oZ4V079I/qPMxg==", + "node_modules/is-finalizationregistry": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-finalizationregistry/-/is-finalizationregistry-1.0.2.tgz", + "integrity": "sha512-0by5vtUJs8iFQb5TYUHHPudOR+qXYIMKtiUzvLIZITZUjknFmziyBJuLhVRc+Ds0dREFlskDNJKYIdIzu/9pfw==", "dev": true, - "license": "Apache-2.0", + "license": "MIT", "dependencies": { - "tslib": "^2.1.0" + "call-bind": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/listr2/node_modules/tslib": { - "version": "2.7.0", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.7.0.tgz", - "integrity": "sha512-gLXCKdN1/j47AiHiOkJN69hJmcbGTHI0ImLmbYLHykhgeN0jVGola9yVjFgzCUklsZQMW55o+dW7IXv3RCXDzA==", + "node_modules/is-fullwidth-code-point": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", + "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", "dev": true, - "license": "0BSD" + "license": "MIT", + "engines": { + "node": ">=8" + } }, - "node_modules/listr2/node_modules/wrap-ansi": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", - "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", + "node_modules/is-generator-function": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/is-generator-function/-/is-generator-function-1.0.10.tgz", + "integrity": "sha512-jsEjy9l3yiXEQ+PsXdmBwEPcOxaXWLspKdplFUVI9vq1iZgIekeC0L167qeu86czQaxed3q/Uzuw0swL0irL8A==", "dev": true, "license": "MIT", "dependencies": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" + "has-tostringtag": "^1.0.0" }, "engines": { - "node": ">=10" + "node": ">= 0.4" }, "funding": { - "url": "https://github.com/chalk/wrap-ansi?sponsor=1" + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/loader-runner": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/loader-runner/-/loader-runner-4.3.0.tgz", - "integrity": "sha512-3R/1M+yS3j5ou80Me59j7F9IMs4PXs3VqRrm0TU3AbKPxlmpoY1TNscJV/oGJXo8qCatFGTfDbY6W6ipGOYXfg==", + "node_modules/is-glob": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", + "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", "dev": true, "license": "MIT", + "dependencies": { + "is-extglob": "^2.1.1" + }, "engines": { - "node": ">=6.11.5" + "node": ">=0.10.0" } }, - "node_modules/locate-path": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", - "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", + "node_modules/is-installed-globally": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/is-installed-globally/-/is-installed-globally-0.4.0.tgz", + "integrity": "sha512-iwGqO3J21aaSkC7jWnHP/difazwS7SFeIqxv6wEtLU8Y5KlzFTjyqcSIT0d8s4+dDhKytsk9PJZ2BkS5eZwQRQ==", + "dev": true, "license": "MIT", "dependencies": { - "p-locate": "^5.0.0" + "global-dirs": "^3.0.0", + "is-path-inside": "^3.0.2" }, "engines": { "node": ">=10" @@ -15677,1068 +11461,921 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/lodash": { - "version": "4.17.21", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", - "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", - "license": "MIT" - }, - "node_modules/lodash.debounce": { - "version": "4.0.8", - "resolved": "https://registry.npmjs.org/lodash.debounce/-/lodash.debounce-4.0.8.tgz", - "integrity": "sha512-FT1yDzDYEoYWhnSGnpE/4Kj1fLZkDFyqRb7fNt6FdYOSxlUWAtp42Eh6Wb0rGIv/m9Bgo7x4GhQbm5Ys4SG5ow==", - "license": "MIT" - }, - "node_modules/lodash.memoize": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/lodash.memoize/-/lodash.memoize-4.1.2.tgz", - "integrity": "sha512-t7j+NzmgnQzTAYXcsHYLgimltOV1MXHtlOWf6GjL9Kj8GK5FInw5JotxvbOs+IvV1/Dzo04/fCGfLVs7aXb4Ag==", - "dev": true, - "license": "MIT" - }, - "node_modules/lodash.merge": { - "version": "4.6.2", - "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz", - "integrity": "sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==", + "node_modules/is-interactive": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-interactive/-/is-interactive-1.0.0.tgz", + "integrity": "sha512-2HvIEKRoqS62guEC+qBjpvRubdX910WCMuJTZ+I9yvqKU2/12eSL549HMwtabb4oupdj2sMP50k+XJfB/8JE6w==", "dev": true, - "license": "MIT" + "license": "MIT", + "engines": { + "node": ">=8" + } }, - "node_modules/lodash.once": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/lodash.once/-/lodash.once-4.1.1.tgz", - "integrity": "sha512-Sb487aTOCr9drQVL8pIxOzVhafOjZN9UU54hiN8PU3uAiSV7lx1yYNpbNmex2PK6dSJoNTSJUUswT651yww3Mg==", + "node_modules/is-map": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.3.tgz", + "integrity": "sha512-1Qed0/Hr2m+YqxnM09CjA2d/i6YZNfF6R2oRAOj36eUdS6qIV/huPJNSEpKbupewFs+ZsJlxsjjPbc0/afW6Lw==", "dev": true, - "license": "MIT" + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } }, - "node_modules/lodash.throttle": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/lodash.throttle/-/lodash.throttle-4.1.1.tgz", - "integrity": "sha512-wIkUCfVKpVsWo3JSZlc+8MB5it+2AN5W8J7YVMST30UrvcQNZ1Okbj+rbVniijTWE6FGYy4XJq/rHkas8qJMLQ==", + "node_modules/is-negative-zero": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.3.tgz", + "integrity": "sha512-5KoIu2Ngpyek75jXodFvnafB6DJgr3u8uuK0LEZJjrU19DrMD3EVERaR8sjz8CCGgpZvxPl9SuE1GMVPFHx1mw==", "license": "MIT", - "peer": true + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } }, - "node_modules/lodash.truncate": { - "version": "4.4.2", - "resolved": "https://registry.npmjs.org/lodash.truncate/-/lodash.truncate-4.4.2.tgz", - "integrity": "sha512-jttmRe7bRse52OsWIMDLaXxWqRAmtIUccAQ3garviCqJjafXOfNMO0yMfNpdD6zbGaTU0P5Nz7e7gAT6cKmJRw==", + "node_modules/is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", "dev": true, - "license": "MIT" + "license": "MIT", + "engines": { + "node": ">=0.12.0" + } }, - "node_modules/log-symbols": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz", - "integrity": "sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==", + "node_modules/is-number-object": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz", + "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==", "license": "MIT", "dependencies": { - "chalk": "^4.1.0", - "is-unicode-supported": "^0.1.0" + "has-tostringtag": "^1.0.0" }, "engines": { - "node": ">=10" + "node": ">= 0.4" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/log-symbols/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/is-path-inside": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-3.0.3.tgz", + "integrity": "sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==", + "dev": true, "license": "MIT", - "dependencies": { - "color-convert": "^2.0.1" - }, "engines": { "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/log-symbols/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/is-plain-obj": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-3.0.0.tgz", + "integrity": "sha512-gwsOE28k+23GP1B6vFl1oVh/WOzmawBrKwo5Ev6wMKzPkaXaCDIQKzLnvsA42DRlbVTWorkgTKIviAKCWkfUwA==", + "dev": true, "license": "MIT", - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, "engines": { "node": ">=10" }, "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/log-symbols/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/is-plain-object": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-5.0.0.tgz", + "integrity": "sha512-VRSzKkbMm5jMDoKLbltAkFQ5Qr7VDiTFGXxYFXXowVj387GeGNOCsOH6Msy00SGZ3Fp84b1Naa1psqgcCIEP5Q==", + "dev": true, "license": "MIT", - "dependencies": { - "color-name": "~1.1.4" - }, "engines": { - "node": ">=7.0.0" + "node": ">=0.10.0" } }, - "node_modules/log-symbols/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "node_modules/is-promise": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/is-promise/-/is-promise-2.2.2.tgz", + "integrity": "sha512-+lP4/6lKUBfQjZ2pdxThZvLUAafmZb8OAxFb8XXtiQmS35INgr85hdOGoEs124ez1FCnZJt6jau/T+alh58QFQ==", "license": "MIT" }, - "node_modules/log-symbols/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/is-regex": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz", + "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==", "license": "MIT", + "dependencies": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + }, "engines": { - "node": ">=8" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/log-symbols/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/is-set": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.3.tgz", + "integrity": "sha512-iPAjerrse27/ygGLxw+EBR9agv9Y6uLeYVJMu+QNCoouJ1/1ri0mGrcWpfCqFZuzzx3WjtwxG098X+n4OuRkPg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-shared-array-buffer": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.3.tgz", + "integrity": "sha512-nA2hv5XIhLR3uVzDDfCIknerhx8XUKnstuOERPNNIinXG7v9u+ohXF67vxm4TPTEPU6lm61ZkwP3c9PCB97rhg==", "license": "MIT", "dependencies": { - "has-flag": "^4.0.0" + "call-bind": "^1.0.7" }, "engines": { - "node": ">=8" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/log-update": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/log-update/-/log-update-4.0.0.tgz", - "integrity": "sha512-9fkkDevMefjg0mmzWFBW8YkFP91OrizzkW3diF7CpG+S2EYdy4+TVfGwz1zeF8x7hCx1ovSPTOE9Ngib74qqUg==", + "node_modules/is-stream": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==", "dev": true, "license": "MIT", - "dependencies": { - "ansi-escapes": "^4.3.0", - "cli-cursor": "^3.1.0", - "slice-ansi": "^4.0.0", - "wrap-ansi": "^6.2.0" - }, "engines": { - "node": ">=10" + "node": ">=8" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/log-update/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, + "node_modules/is-string": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz", + "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==", "license": "MIT", "dependencies": { - "color-convert": "^2.0.1" + "has-tostringtag": "^1.0.0" }, "engines": { - "node": ">=8" + "node": ">= 0.4" }, "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/log-update/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, + "node_modules/is-symbol": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz", + "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==", "license": "MIT", "dependencies": { - "color-name": "~1.1.4" + "has-symbols": "^1.0.2" }, "engines": { - "node": ">=7.0.0" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/log-update/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true, + "node_modules/is-touch-device": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-touch-device/-/is-touch-device-1.0.1.tgz", + "integrity": "sha512-LAYzo9kMT1b2p19L/1ATGt2XcSilnzNlyvq6c0pbPRVisLbAPpLqr53tIJS00kvrTkj0HtR8U7+u8X0yR8lPSw==", "license": "MIT" }, - "node_modules/log-update/node_modules/slice-ansi": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-4.0.0.tgz", - "integrity": "sha512-qMCMfhY040cVHT43K9BFygqYbUPFZKHOg7K73mtTWJRb8pyP3fzf4Ixd5SzdEJQ6MRUg/WBnOLxghZtKKurENQ==", - "dev": true, + "node_modules/is-typed-array": { + "version": "1.1.13", + "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.13.tgz", + "integrity": "sha512-uZ25/bUAlUY5fR4OKT4rZQEBrzQWYV9ZJYGGsUmEJ6thodVJ1HX64ePQ6Z0qPWP+m+Uq6e9UugrE38jeYsDSMw==", "license": "MIT", "dependencies": { - "ansi-styles": "^4.0.0", - "astral-regex": "^2.0.0", - "is-fullwidth-code-point": "^3.0.0" + "which-typed-array": "^1.1.14" }, "engines": { - "node": ">=10" + "node": ">= 0.4" }, "funding": { - "url": "https://github.com/chalk/slice-ansi?sponsor=1" + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/log-update/node_modules/wrap-ansi": { - "version": "6.2.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-6.2.0.tgz", - "integrity": "sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==", + "node_modules/is-typedarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz", + "integrity": "sha512-cyA56iCMHAh5CdzjJIa4aohJyeO1YbwLi3Jc35MmRU6poroFjIGZzUzupGiRPOjgHg9TLu43xbpwXk523fMxKA==", "dev": true, - "license": "MIT", - "dependencies": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/logkitty": { - "version": "0.7.1", - "resolved": "https://registry.npmjs.org/logkitty/-/logkitty-0.7.1.tgz", - "integrity": "sha512-/3ER20CTTbahrCrpYfPn7Xavv9diBROZpoXGVZDWMw4b/X4uuUwAC0ki85tgsdMRONURyIJbcOvS94QsUBYPbQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "ansi-fragments": "^0.2.1", - "dayjs": "^1.8.15", - "yargs": "^15.1.0" - }, - "bin": { - "logkitty": "bin/logkitty.js" - } + "license": "MIT" }, - "node_modules/logkitty/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/is-unicode-supported": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz", + "integrity": "sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw==", + "dev": true, "license": "MIT", - "peer": true, - "dependencies": { - "color-convert": "^2.0.1" - }, "engines": { - "node": ">=8" + "node": ">=10" }, "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/logkitty/node_modules/camelcase": { - "version": "5.3.1", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", - "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", + "node_modules/is-weakmap": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-weakmap/-/is-weakmap-2.0.2.tgz", + "integrity": "sha512-K5pXYOm9wqY1RgjpL3YTkF39tni1XajUIkawTLUo9EZEVUFga5gSQJF8nNS7ZwJQ02y+1YCNYcMh+HIf1ZqE+w==", + "dev": true, "license": "MIT", - "peer": true, "engines": { - "node": ">=6" - } - }, - "node_modules/logkitty/node_modules/cliui": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-6.0.0.tgz", - "integrity": "sha512-t6wbgtoCXvAzst7QgXxJYqPt0usEfbgQdftEPbLL/cvv6HPE5VgvqCuAIDR0NgU52ds6rFwqrgakNLrHEjCbrQ==", - "license": "ISC", - "peer": true, - "dependencies": { - "string-width": "^4.2.0", - "strip-ansi": "^6.0.0", - "wrap-ansi": "^6.2.0" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/logkitty/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/is-weakref": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz", + "integrity": "sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==", "license": "MIT", - "peer": true, "dependencies": { - "color-name": "~1.1.4" + "call-bind": "^1.0.2" }, - "engines": { - "node": ">=7.0.0" + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/logkitty/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT", - "peer": true - }, - "node_modules/logkitty/node_modules/find-up": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", + "node_modules/is-weakset": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/is-weakset/-/is-weakset-2.0.3.tgz", + "integrity": "sha512-LvIm3/KWzS9oRFHugab7d+M/GcBXuXX5xZkzPmN+NxihdQlZUQ4dWuSV1xR/sq6upL1TJEDrfBgRepHFdBtSNQ==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "locate-path": "^5.0.0", - "path-exists": "^4.0.0" + "call-bind": "^1.0.7", + "get-intrinsic": "^1.2.4" }, "engines": { - "node": ">=8" + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/logkitty/node_modules/locate-path": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", + "node_modules/is-wsl": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/is-wsl/-/is-wsl-2.2.0.tgz", + "integrity": "sha512-fKzAra0rGJUUBwGBgNkHZuToZcn+TtXHpeCgmkMJMMYx1sQDYaCSyjJBSCa2nH1DGm7s3n1oBnohoVTBaN7Lww==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "p-locate": "^4.1.0" + "is-docker": "^2.0.0" }, "engines": { "node": ">=8" } }, - "node_modules/logkitty/node_modules/p-limit": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "node_modules/isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", + "license": "MIT" + }, + "node_modules/isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", + "dev": true, + "license": "ISC" + }, + "node_modules/isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha512-WhB9zCku7EGTj/HQQRz5aUQEUeoQZH2bWcltRErOpymJ4boYE6wL9Tbr23krRPSZ+C5zqNSrSw+Cc7sZZ4b7vg==", + "dev": true, "license": "MIT", - "peer": true, - "dependencies": { - "p-try": "^2.0.0" - }, "engines": { - "node": ">=6" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "node": ">=0.10.0" } }, - "node_modules/logkitty/node_modules/p-locate": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", + "node_modules/isstream": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz", + "integrity": "sha512-Yljz7ffyPbrLpLngrMtZ7NduUgVvi6wG9RJ9IUcyCd59YQ911PBJphODUcbOVbqYfxe1wuYf/LJ8PauMRwsM/g==", + "dev": true, + "license": "MIT" + }, + "node_modules/iterator.prototype": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/iterator.prototype/-/iterator.prototype-1.1.2.tgz", + "integrity": "sha512-DR33HMMr8EzwuRL8Y9D3u2BMj8+RqSE850jfGu59kS7tbmPLzGkZmVSfyCFSDxuZiEY6Rzt3T2NA/qU+NwVj1w==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "p-limit": "^2.2.0" - }, - "engines": { - "node": ">=8" + "define-properties": "^1.2.1", + "get-intrinsic": "^1.2.1", + "has-symbols": "^1.0.3", + "reflect.getprototypeof": "^1.0.4", + "set-function-name": "^2.0.1" } }, - "node_modules/logkitty/node_modules/wrap-ansi": { - "version": "6.2.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-6.2.0.tgz", - "integrity": "sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==", - "license": "MIT", - "peer": true, + "node_modules/jackspeak": { + "version": "3.4.3", + "resolved": "https://registry.npmjs.org/jackspeak/-/jackspeak-3.4.3.tgz", + "integrity": "sha512-OGlZQpz2yfahA/Rd1Y8Cd9SIEsqvXkLVoSw/cgwhnhFMDbsQFeZYoJJ7bIZBS9BcamUW96asq/npPWugM+RQBw==", + "dev": true, + "license": "BlueOak-1.0.0", "dependencies": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" + "@isaacs/cliui": "^8.0.2" }, - "engines": { - "node": ">=8" + "funding": { + "url": "https://github.com/sponsors/isaacs" + }, + "optionalDependencies": { + "@pkgjs/parseargs": "^0.11.0" } }, - "node_modules/logkitty/node_modules/y18n": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.3.tgz", - "integrity": "sha512-JKhqTOwSrqNA1NY5lSztJ1GrBiUodLMmIZuLiDaMRJ+itFd+ABVE8XBjOvIWL+rSqNDC74LCSFmlb/U4UZ4hJQ==", - "license": "ISC", - "peer": true - }, - "node_modules/logkitty/node_modules/yargs": { - "version": "15.4.1", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-15.4.1.tgz", - "integrity": "sha512-aePbxDmcYW++PaqBsJ+HYUFwCdv4LVvdnhBy78E57PIor8/OVvhMrADFFEDh8DHDFRv/O9i3lPhsENjO7QX0+A==", + "node_modules/jest-worker": { + "version": "27.5.1", + "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-27.5.1.tgz", + "integrity": "sha512-7vuh85V5cdDofPyxn58nrPjBktZo0u9x1g8WtjQol+jZDaE+fhN+cIvTj11GndBnMnyfrUOG1sZQxCdjKh+DKg==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "cliui": "^6.0.0", - "decamelize": "^1.2.0", - "find-up": "^4.1.0", - "get-caller-file": "^2.0.1", - "require-directory": "^2.1.1", - "require-main-filename": "^2.0.0", - "set-blocking": "^2.0.0", - "string-width": "^4.2.0", - "which-module": "^2.0.0", - "y18n": "^4.0.0", - "yargs-parser": "^18.1.2" + "@types/node": "*", + "merge-stream": "^2.0.0", + "supports-color": "^8.0.0" }, "engines": { - "node": ">=8" + "node": ">= 10.13.0" } }, - "node_modules/logkitty/node_modules/yargs-parser": { - "version": "18.1.3", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-18.1.3.tgz", - "integrity": "sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ==", - "license": "ISC", - "peer": true, - "dependencies": { - "camelcase": "^5.0.0", - "decamelize": "^1.2.0" - }, + "node_modules/jest-worker/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "license": "MIT", "engines": { - "node": ">=6" + "node": ">=8" } }, - "node_modules/loose-envify": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", - "integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==", + "node_modules/jest-worker/node_modules/supports-color": { + "version": "8.1.1", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", + "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", + "dev": true, "license": "MIT", "dependencies": { - "js-tokens": "^3.0.0 || ^4.0.0" + "has-flag": "^4.0.0" }, - "bin": { - "loose-envify": "cli.js" + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/supports-color?sponsor=1" } }, - "node_modules/lower-case": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/lower-case/-/lower-case-2.0.2.tgz", - "integrity": "sha512-7fm3l3NAF9WfN6W3JOmf5drwpVqX78JtoGJ3A6W0a6ZnldM41w2fV5D490psKFTpMds8TJse/eHLFFsNHHjHgg==", + "node_modules/js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", + "license": "MIT" + }, + "node_modules/js-yaml": { + "version": "3.14.1", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.1.tgz", + "integrity": "sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==", "dev": true, "license": "MIT", "dependencies": { - "tslib": "^2.0.3" + "argparse": "^1.0.7", + "esprima": "^4.0.0" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" } }, - "node_modules/lower-case/node_modules/tslib": { - "version": "2.7.0", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.7.0.tgz", - "integrity": "sha512-gLXCKdN1/j47AiHiOkJN69hJmcbGTHI0ImLmbYLHykhgeN0jVGola9yVjFgzCUklsZQMW55o+dW7IXv3RCXDzA==", + "node_modules/jsbn": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz", + "integrity": "sha512-UVU9dibq2JcFWxQPA6KCqj5O42VOmAY3zQUfEKxU0KpTGXwNoCjkX1e13eHNvw/xPynt6pU0rZ1htjWTNTSXsg==", "dev": true, - "license": "0BSD" + "license": "MIT" }, - "node_modules/lowercase-keys": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/lowercase-keys/-/lowercase-keys-2.0.0.tgz", - "integrity": "sha512-tqNXrS78oMOE73NMxK4EMLQsQowWf8jKooH9g7xPavRT706R6bkQJ6DY2Te7QukaZsulxa30wQ7bk0pm4XiHmA==", + "node_modules/jsdoc-type-pratt-parser": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/jsdoc-type-pratt-parser/-/jsdoc-type-pratt-parser-4.0.0.tgz", + "integrity": "sha512-YtOli5Cmzy3q4dP26GraSOeAhqecewG04hoO8DY56CH4KJ9Fvv5qKWUCCo3HZob7esJQHCv6/+bnTy72xZZaVQ==", "dev": true, "license": "MIT", "engines": { - "node": ">=8" - } - }, - "node_modules/lru-cache": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz", - "integrity": "sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==", - "license": "ISC", - "dependencies": { - "yallist": "^3.0.2" + "node": ">=12.0.0" } }, - "node_modules/make-dir": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-2.1.0.tgz", - "integrity": "sha512-LS9X+dc8KLxXCb8dni79fLIIUA5VyZoyjSMCwTluaXA0o27cCK0bhXkpgw+sTXVpPy/lSO57ilRixqk0vDmtRA==", + "node_modules/jsesc": { + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz", + "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==", "license": "MIT", - "peer": true, - "dependencies": { - "pify": "^4.0.1", - "semver": "^5.6.0" + "bin": { + "jsesc": "bin/jsesc" }, "engines": { - "node": ">=6" + "node": ">=4" } }, - "node_modules/make-dir/node_modules/pify": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/pify/-/pify-4.0.1.tgz", - "integrity": "sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=6" - } + "node_modules/json-buffer": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz", + "integrity": "sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==", + "dev": true, + "license": "MIT" }, - "node_modules/make-dir/node_modules/semver": { - "version": "5.7.2", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz", - "integrity": "sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==", - "license": "ISC", - "peer": true, - "bin": { - "semver": "bin/semver" - } + "node_modules/json-parse-even-better-errors": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz", + "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==", + "dev": true, + "license": "MIT" }, - "node_modules/makeerror": { - "version": "1.0.12", - "resolved": "https://registry.npmjs.org/makeerror/-/makeerror-1.0.12.tgz", - "integrity": "sha512-JmqCvUhmt43madlpFzG4BQzG2Z3m6tvQDNKdClZnO3VbIudJYmxsT0FNJMeiB2+JTSlTQTSbU8QdesVmwJcmLg==", - "license": "BSD-3-Clause", - "peer": true, - "dependencies": { - "tmpl": "1.0.5" - } + "node_modules/json-schema": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/json-schema/-/json-schema-0.4.0.tgz", + "integrity": "sha512-es94M3nTIfsEPisRafak+HDLfHXnKBhV3vU5eqPcS3flIWqcxJWgXHXiey3YrpaNsanY5ei1VoYEbOzijuq9BA==", + "dev": true, + "license": "(AFL-2.1 OR BSD-3-Clause)" }, - "node_modules/marky": { - "version": "1.2.5", - "resolved": "https://registry.npmjs.org/marky/-/marky-1.2.5.tgz", - "integrity": "sha512-q9JtQJKjpsVxCRVgQ+WapguSbKC3SQ5HEzFGPAJMStgh3QjCawp00UKv3MTTAArTmGmmPUvllHZoNbZ3gs0I+Q==", - "license": "Apache-2.0", - "peer": true + "node_modules/json-schema-traverse": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", + "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", + "dev": true, + "license": "MIT" }, - "node_modules/mathml-tag-names": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/mathml-tag-names/-/mathml-tag-names-2.1.3.tgz", - "integrity": "sha512-APMBEanjybaPzUrfqU0IMU5I0AswKMH7k8OTLs0vvV4KZpExkTkY87nR/zpbuTPj+gARop7aGUbl11pnDfW6xg==", + "node_modules/json-stable-stringify-without-jsonify": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz", + "integrity": "sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==", "dev": true, - "license": "MIT", - "funding": { - "type": "github", - "url": "https://github.com/sponsors/wooorm" - } + "license": "MIT" }, - "node_modules/mdn-data": { - "version": "2.0.30", - "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.30.tgz", - "integrity": "sha512-GaqWWShW4kv/G9IEucWScBx9G1/vsFZZJUO+tD26M8J8z3Kw5RDQjaoZe03YAClgeS/SWPOcb4nkFBTEi5DUEA==", + "node_modules/json-stringify-safe": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz", + "integrity": "sha512-ZClg6AaYvamvYEE82d3Iyd3vSSIjQ+odgjaTzRuO3s7toCdFKczob2i0zCh7JE8kWn17yvAWhUVxvqGwUalsRA==", "dev": true, - "license": "CC0-1.0" + "license": "ISC" }, - "node_modules/media-typer": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz", - "integrity": "sha512-dq+qelQ9akHpcOl/gUVRTxVIOkAJ1wR3QAvb4RsVjS8oVoFjDGTc679wJYmUmknUF5HwMLOgb5O+a3KxfWapPQ==", + "node_modules/json5": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz", + "integrity": "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==", "dev": true, "license": "MIT", + "bin": { + "json5": "lib/cli.js" + }, "engines": { - "node": ">= 0.6" + "node": ">=6" } }, - "node_modules/memfs": { - "version": "3.5.3", - "resolved": "https://registry.npmjs.org/memfs/-/memfs-3.5.3.tgz", - "integrity": "sha512-UERzLsxzllchadvbPs5aolHh65ISpKpM+ccLbOJ8/vvpBKmAWf+la7dXFy7Mr0ySHbdHrFv5kGFCUHHe6GFEmw==", + "node_modules/jsonfile": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz", + "integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==", "dev": true, - "license": "Unlicense", + "license": "MIT", "dependencies": { - "fs-monkey": "^1.0.4" + "universalify": "^2.0.0" }, - "engines": { - "node": ">= 4.0.0" + "optionalDependencies": { + "graceful-fs": "^4.1.6" } }, - "node_modules/memize": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/memize/-/memize-1.1.0.tgz", - "integrity": "sha512-K4FcPETOMTwe7KL2LK0orMhpOmWD2wRGwWWpbZy0fyArwsyIKR8YJVz8+efBAh3BO4zPqlSICu4vsLTRRqtFAg==", - "license": "MIT" - }, - "node_modules/memoize-one": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/memoize-one/-/memoize-one-5.2.1.tgz", - "integrity": "sha512-zYiwtZUcYyXKo/np96AGZAckk+FWWsUdJ3cHGGmld7+AhvcWmQyGCYUh1hc4Q/pkOhb65dQR/pqCyK0cOaHz4Q==", - "license": "MIT", - "peer": true - }, - "node_modules/memory-fs": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/memory-fs/-/memory-fs-0.2.0.tgz", - "integrity": "sha512-+y4mDxU4rvXXu5UDSGCGNiesFmwCHuefGMoPCO1WYucNYj7DsLqrFaa2fXVI0H+NNiPTwwzKwspn9yTZqUGqng==", - "dev": true, - "license": "MIT" - }, - "node_modules/meow": { - "version": "13.2.0", - "resolved": "https://registry.npmjs.org/meow/-/meow-13.2.0.tgz", - "integrity": "sha512-pxQJQzB6djGPXh08dacEloMFopsOqGVRKFPYvPOt9XDZ1HasbgDZA74CJGreSU4G3Ak7EFJGoiH2auq+yXISgA==", + "node_modules/jsprim": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/jsprim/-/jsprim-2.0.2.tgz", + "integrity": "sha512-gqXddjPqQ6G40VdnI6T6yObEC+pDNvyP95wdQhkWkg7crHH3km5qP1FsOXEkzEQwnz6gz5qGTn1c2Y52wP3OyQ==", "dev": true, + "engines": [ + "node >=0.6.0" + ], "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "dependencies": { + "assert-plus": "1.0.0", + "extsprintf": "1.3.0", + "json-schema": "0.4.0", + "verror": "1.10.0" } }, - "node_modules/merge-descriptors": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.3.tgz", - "integrity": "sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==", + "node_modules/jsx-ast-utils": { + "version": "3.3.5", + "resolved": "https://registry.npmjs.org/jsx-ast-utils/-/jsx-ast-utils-3.3.5.tgz", + "integrity": "sha512-ZZow9HBI5O6EPgSJLUb8n2NKgmVWTwCvHGwFuJlMjvLFqlGG6pjirPhtdsseaLZjSibD8eegzmYpUZwoIlj2cQ==", "dev": true, "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "dependencies": { + "array-includes": "^3.1.6", + "array.prototype.flat": "^1.3.1", + "object.assign": "^4.1.4", + "object.values": "^1.1.6" + }, + "engines": { + "node": ">=4.0" } }, - "node_modules/merge-stream": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz", - "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==", - "license": "MIT" - }, - "node_modules/merge2": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", - "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==", + "node_modules/keyv": { + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/keyv/-/keyv-4.5.4.tgz", + "integrity": "sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==", + "dev": true, "license": "MIT", - "engines": { - "node": ">= 8" + "dependencies": { + "json-buffer": "3.0.1" } }, - "node_modules/methods": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz", - "integrity": "sha512-iclAHeNqNm68zFtnZ0e+1L2yUIdvzNoauKU4WBA3VvH/vPFieF7qfRlwUZU+DA9P9bPXIS90ulxoUoCH23sV2w==", + "node_modules/kind-of": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.3.tgz", + "integrity": "sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==", "dev": true, "license": "MIT", "engines": { - "node": ">= 0.6" + "node": ">=0.10.0" } }, - "node_modules/metro": { - "version": "0.80.12", - "resolved": "https://registry.npmjs.org/metro/-/metro-0.80.12.tgz", - "integrity": "sha512-1UsH5FzJd9quUsD1qY+zUG4JY3jo3YEMxbMYH9jT6NK3j4iORhlwTK8fYTfAUBhDKjgLfKjAh7aoazNE23oIRA==", + "node_modules/kleur": { + "version": "4.1.5", + "resolved": "https://registry.npmjs.org/kleur/-/kleur-4.1.5.tgz", + "integrity": "sha512-o+NO+8WrRiQEE4/7nwRJhN1HWpVmJm511pBHUxPLtp0BUISzlBplORYSmTclCnJvQq2tKu/sgl3xVpkc7ZWuQQ==", + "dev": true, "license": "MIT", - "peer": true, - "dependencies": { - "@babel/code-frame": "^7.0.0", - "@babel/core": "^7.20.0", - "@babel/generator": "^7.20.0", - "@babel/parser": "^7.20.0", - "@babel/template": "^7.0.0", - "@babel/traverse": "^7.20.0", - "@babel/types": "^7.20.0", - "accepts": "^1.3.7", - "chalk": "^4.0.0", - "ci-info": "^2.0.0", - "connect": "^3.6.5", - "debug": "^2.2.0", - "denodeify": "^1.2.1", - "error-stack-parser": "^2.0.6", - "flow-enums-runtime": "^0.0.6", - "graceful-fs": "^4.2.4", - "hermes-parser": "0.23.1", - "image-size": "^1.0.2", - "invariant": "^2.2.4", - "jest-worker": "^29.6.3", - "jsc-safe-url": "^0.2.2", - "lodash.throttle": "^4.1.1", - "metro-babel-transformer": "0.80.12", - "metro-cache": "0.80.12", - "metro-cache-key": "0.80.12", - "metro-config": "0.80.12", - "metro-core": "0.80.12", - "metro-file-map": "0.80.12", - "metro-resolver": "0.80.12", - "metro-runtime": "0.80.12", - "metro-source-map": "0.80.12", - "metro-symbolicate": "0.80.12", - "metro-transform-plugins": "0.80.12", - "metro-transform-worker": "0.80.12", - "mime-types": "^2.1.27", - "nullthrows": "^1.1.1", - "serialize-error": "^2.1.0", - "source-map": "^0.5.6", - "strip-ansi": "^6.0.0", - "throat": "^5.0.0", - "ws": "^7.5.10", - "yargs": "^17.6.2" - }, - "bin": { - "metro": "src/cli.js" - }, "engines": { - "node": ">=18" + "node": ">=6" } }, - "node_modules/metro-babel-transformer": { - "version": "0.80.12", - "resolved": "https://registry.npmjs.org/metro-babel-transformer/-/metro-babel-transformer-0.80.12.tgz", - "integrity": "sha512-YZziRs0MgA3pzCkkvOoQRXjIoVjvrpi/yRlJnObyIvMP6lFdtyG4nUGIwGY9VXnBvxmXD6mPY2e+NSw6JAyiRg==", + "node_modules/known-css-properties": { + "version": "0.36.0", + "resolved": "https://registry.npmjs.org/known-css-properties/-/known-css-properties-0.36.0.tgz", + "integrity": "sha512-A+9jP+IUmuQsNdsLdcg6Yt7voiMF/D4K83ew0OpJtpu+l34ef7LaohWV0Rc6KNvzw6ZDizkqfyB5JznZnzuKQA==", + "dev": true, + "license": "MIT" + }, + "node_modules/language-subtag-registry": { + "version": "0.3.23", + "resolved": "https://registry.npmjs.org/language-subtag-registry/-/language-subtag-registry-0.3.23.tgz", + "integrity": "sha512-0K65Lea881pHotoGEa5gDlMxt3pctLi2RplBb7Ezh4rRdLEOtgi7n4EwK9lamnUCkKBqaeKRVebTq6BAxSkpXQ==", + "dev": true, + "license": "CC0-1.0" + }, + "node_modules/language-tags": { + "version": "1.0.9", + "resolved": "https://registry.npmjs.org/language-tags/-/language-tags-1.0.9.tgz", + "integrity": "sha512-MbjN408fEndfiQXbFQ1vnd+1NoLDsnQW41410oQBXiyXDMYH5z505juWa4KUE1LqxRC7DgOgZDbKLxHIwm27hA==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "@babel/core": "^7.20.0", - "flow-enums-runtime": "^0.0.6", - "hermes-parser": "0.23.1", - "nullthrows": "^1.1.1" + "language-subtag-registry": "^0.3.20" }, "engines": { - "node": ">=18" + "node": ">=0.10" } }, - "node_modules/metro-babel-transformer/node_modules/hermes-estree": { - "version": "0.23.1", - "resolved": "https://registry.npmjs.org/hermes-estree/-/hermes-estree-0.23.1.tgz", - "integrity": "sha512-eT5MU3f5aVhTqsfIReZ6n41X5sYn4IdQL0nvz6yO+MMlPxw49aSARHLg/MSehQftyjnrE8X6bYregzSumqc6cg==", - "license": "MIT", - "peer": true - }, - "node_modules/metro-babel-transformer/node_modules/hermes-parser": { - "version": "0.23.1", - "resolved": "https://registry.npmjs.org/hermes-parser/-/hermes-parser-0.23.1.tgz", - "integrity": "sha512-oxl5h2DkFW83hT4DAUJorpah8ou4yvmweUzLJmmr6YV2cezduCdlil1AvU/a/xSsAFo4WUcNA4GoV5Bvq6JffA==", + "node_modules/launch-editor": { + "version": "2.9.1", + "resolved": "https://registry.npmjs.org/launch-editor/-/launch-editor-2.9.1.tgz", + "integrity": "sha512-Gcnl4Bd+hRO9P9icCP/RVVT2o8SFlPXofuCxvA2SaZuH45whSvf5p8x5oih5ftLiVhEI4sp5xDY+R+b3zJBh5w==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "hermes-estree": "0.23.1" + "picocolors": "^1.0.0", + "shell-quote": "^1.8.1" } }, - "node_modules/metro-cache": { - "version": "0.80.12", - "resolved": "https://registry.npmjs.org/metro-cache/-/metro-cache-0.80.12.tgz", - "integrity": "sha512-p5kNHh2KJ0pbQI/H7ZBPCEwkyNcSz7OUkslzsiIWBMPQGFJ/xArMwkV7I+GJcWh+b4m6zbLxE5fk6fqbVK1xGA==", + "node_modules/lazy-ass": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/lazy-ass/-/lazy-ass-1.6.0.tgz", + "integrity": "sha512-cc8oEVoctTvsFZ/Oje/kGnHbpWHYBe8IAJe4C0QNc3t8uM/0Y8+erSz/7Y1ALuXTEZTMvxXwO6YbX1ey3ujiZw==", + "dev": true, "license": "MIT", - "peer": true, - "dependencies": { - "exponential-backoff": "^3.1.1", - "flow-enums-runtime": "^0.0.6", - "metro-core": "0.80.12" - }, "engines": { - "node": ">=18" + "node": "> 0.8" } }, - "node_modules/metro-cache-key": { - "version": "0.80.12", - "resolved": "https://registry.npmjs.org/metro-cache-key/-/metro-cache-key-0.80.12.tgz", - "integrity": "sha512-o4BspKnugg/pE45ei0LGHVuBJXwRgruW7oSFAeSZvBKA/sGr0UhOGY3uycOgWInnS3v5yTTfiBA9lHlNRhsvGA==", + "node_modules/levn": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz", + "integrity": "sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "flow-enums-runtime": "^0.0.6" + "prelude-ls": "^1.2.1", + "type-check": "~0.4.0" }, "engines": { - "node": ">=18" + "node": ">= 0.8.0" } }, - "node_modules/metro-config": { - "version": "0.80.12", - "resolved": "https://registry.npmjs.org/metro-config/-/metro-config-0.80.12.tgz", - "integrity": "sha512-4rwOWwrhm62LjB12ytiuR5NgK1ZBNr24/He8mqCsC+HXZ+ATbrewLNztzbAZHtFsrxP4D4GLTGgh96pCpYLSAQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "connect": "^3.6.5", - "cosmiconfig": "^5.0.5", - "flow-enums-runtime": "^0.0.6", - "jest-validate": "^29.6.3", - "metro": "0.80.12", - "metro-cache": "0.80.12", - "metro-core": "0.80.12", - "metro-runtime": "0.80.12" - }, - "engines": { - "node": ">=18" - } + "node_modules/lines-and-columns": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/lines-and-columns/-/lines-and-columns-1.2.4.tgz", + "integrity": "sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==", + "dev": true, + "license": "MIT" }, - "node_modules/metro-config/node_modules/cosmiconfig": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-5.2.1.tgz", - "integrity": "sha512-H65gsXo1SKjf8zmrJ67eJk8aIRKV5ff2D4uKZIBZShbhGSpEmsQOPW/SKMKYhSTrqR7ufy6RP69rPogdaPh/kA==", + "node_modules/listr2": { + "version": "3.14.0", + "resolved": "https://registry.npmjs.org/listr2/-/listr2-3.14.0.tgz", + "integrity": "sha512-TyWI8G99GX9GjE54cJ+RrNMcIFBfwMPxc3XTFiAYGN4s10hWROGtOg7+O6u6LE3mNkyld7RSLE6nrKBvTfcs3g==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "import-fresh": "^2.0.0", - "is-directory": "^0.3.1", - "js-yaml": "^3.13.1", - "parse-json": "^4.0.0" + "cli-truncate": "^2.1.0", + "colorette": "^2.0.16", + "log-update": "^4.0.0", + "p-map": "^4.0.0", + "rfdc": "^1.3.0", + "rxjs": "^7.5.1", + "through": "^2.3.8", + "wrap-ansi": "^7.0.0" }, "engines": { - "node": ">=4" + "node": ">=10.0.0" + }, + "peerDependencies": { + "enquirer": ">= 2.3.0 < 3" + }, + "peerDependenciesMeta": { + "enquirer": { + "optional": true + } } }, - "node_modules/metro-config/node_modules/import-fresh": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-2.0.0.tgz", - "integrity": "sha512-eZ5H8rcgYazHbKC3PG4ClHNykCSxtAhxSSEM+2mb+7evD2CKF5V7c0dNum7AdpDh0ZdICwZY9sRSn8f+KH96sg==", + "node_modules/listr2/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "caller-path": "^2.0.0", - "resolve-from": "^3.0.0" + "color-convert": "^2.0.1" }, "engines": { - "node": ">=4" + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/metro-config/node_modules/parse-json": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-4.0.0.tgz", - "integrity": "sha512-aOIos8bujGN93/8Ox/jPLh7RwVnPEysynVFE+fQZyg6jKELEHwzgKdLRFHUgXJL6kylijVSBC4BvN9OmsB48Rw==", + "node_modules/listr2/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "error-ex": "^1.3.1", - "json-parse-better-errors": "^1.0.1" + "color-name": "~1.1.4" }, "engines": { - "node": ">=4" + "node": ">=7.0.0" } }, - "node_modules/metro-config/node_modules/resolve-from": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-3.0.0.tgz", - "integrity": "sha512-GnlH6vxLymXJNMBo7XP1fJIzBFbdYt49CuTwmB/6N53t+kMPRMFKz783LlQ4tv28XoQfMWinAJX6WCGf2IlaIw==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=4" - } + "node_modules/listr2/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true, + "license": "MIT" }, - "node_modules/metro-core": { - "version": "0.80.12", - "resolved": "https://registry.npmjs.org/metro-core/-/metro-core-0.80.12.tgz", - "integrity": "sha512-QqdJ/yAK+IpPs2HU/h5v2pKEdANBagSsc6DRSjnwSyJsCoHlmyJKCaCJ7KhWGx+N4OHxh37hoA8fc2CuZbx0Fw==", - "license": "MIT", - "peer": true, + "node_modules/listr2/node_modules/rxjs": { + "version": "7.8.1", + "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-7.8.1.tgz", + "integrity": "sha512-AA3TVj+0A2iuIoQkWEK/tqFjBq2j+6PO6Y0zJcvzLAFhEFIO3HL0vls9hWLncZbAAbK0mar7oZ4V079I/qPMxg==", + "dev": true, + "license": "Apache-2.0", "dependencies": { - "flow-enums-runtime": "^0.0.6", - "lodash.throttle": "^4.1.1", - "metro-resolver": "0.80.12" - }, - "engines": { - "node": ">=18" + "tslib": "^2.1.0" } }, - "node_modules/metro-file-map": { - "version": "0.80.12", - "resolved": "https://registry.npmjs.org/metro-file-map/-/metro-file-map-0.80.12.tgz", - "integrity": "sha512-sYdemWSlk66bWzW2wp79kcPMzwuG32x1ZF3otI0QZTmrnTaaTiGyhE66P1z6KR4n2Eu5QXiABa6EWbAQv0r8bw==", + "node_modules/listr2/node_modules/tslib": { + "version": "2.7.0", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.7.0.tgz", + "integrity": "sha512-gLXCKdN1/j47AiHiOkJN69hJmcbGTHI0ImLmbYLHykhgeN0jVGola9yVjFgzCUklsZQMW55o+dW7IXv3RCXDzA==", + "dev": true, + "license": "0BSD" + }, + "node_modules/listr2/node_modules/wrap-ansi": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", + "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "anymatch": "^3.0.3", - "debug": "^2.2.0", - "fb-watchman": "^2.0.0", - "flow-enums-runtime": "^0.0.6", - "graceful-fs": "^4.2.4", - "invariant": "^2.2.4", - "jest-worker": "^29.6.3", - "micromatch": "^4.0.4", - "node-abort-controller": "^3.1.1", - "nullthrows": "^1.1.1", - "walker": "^1.0.7" + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" }, "engines": { - "node": ">=18" + "node": ">=10" }, - "optionalDependencies": { - "fsevents": "^2.3.2" - } - }, - "node_modules/metro-file-map/node_modules/debug": { - "version": "2.6.9", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", - "license": "MIT", - "peer": true, - "dependencies": { - "ms": "2.0.0" + "funding": { + "url": "https://github.com/chalk/wrap-ansi?sponsor=1" } }, - "node_modules/metro-file-map/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/loader-runner": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/loader-runner/-/loader-runner-4.3.0.tgz", + "integrity": "sha512-3R/1M+yS3j5ou80Me59j7F9IMs4PXs3VqRrm0TU3AbKPxlmpoY1TNscJV/oGJXo8qCatFGTfDbY6W6ipGOYXfg==", + "dev": true, "license": "MIT", - "peer": true, "engines": { - "node": ">=8" + "node": ">=6.11.5" } }, - "node_modules/metro-file-map/node_modules/jest-worker": { - "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-29.7.0.tgz", - "integrity": "sha512-eIz2msL/EzL9UFTFFx7jBTkeZfku0yUAyZZZmJ93H2TYEiroIx2PQjEXcwYtYl8zXCxb+PAmA2hLIt/6ZEkPHw==", + "node_modules/locate-path": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", + "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "@types/node": "*", - "jest-util": "^29.7.0", - "merge-stream": "^2.0.0", - "supports-color": "^8.0.0" + "p-locate": "^5.0.0" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/metro-file-map/node_modules/ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", - "license": "MIT", - "peer": true + "node_modules/lodash": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", + "license": "MIT" + }, + "node_modules/lodash.debounce": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/lodash.debounce/-/lodash.debounce-4.0.8.tgz", + "integrity": "sha512-FT1yDzDYEoYWhnSGnpE/4Kj1fLZkDFyqRb7fNt6FdYOSxlUWAtp42Eh6Wb0rGIv/m9Bgo7x4GhQbm5Ys4SG5ow==", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.memoize": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/lodash.memoize/-/lodash.memoize-4.1.2.tgz", + "integrity": "sha512-t7j+NzmgnQzTAYXcsHYLgimltOV1MXHtlOWf6GjL9Kj8GK5FInw5JotxvbOs+IvV1/Dzo04/fCGfLVs7aXb4Ag==", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.merge": { + "version": "4.6.2", + "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz", + "integrity": "sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.once": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/lodash.once/-/lodash.once-4.1.1.tgz", + "integrity": "sha512-Sb487aTOCr9drQVL8pIxOzVhafOjZN9UU54hiN8PU3uAiSV7lx1yYNpbNmex2PK6dSJoNTSJUUswT651yww3Mg==", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.truncate": { + "version": "4.4.2", + "resolved": "https://registry.npmjs.org/lodash.truncate/-/lodash.truncate-4.4.2.tgz", + "integrity": "sha512-jttmRe7bRse52OsWIMDLaXxWqRAmtIUccAQ3garviCqJjafXOfNMO0yMfNpdD6zbGaTU0P5Nz7e7gAT6cKmJRw==", + "dev": true, + "license": "MIT" }, - "node_modules/metro-file-map/node_modules/supports-color": { - "version": "8.1.1", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", - "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", + "node_modules/log-symbols": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz", + "integrity": "sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "has-flag": "^4.0.0" + "chalk": "^4.1.0", + "is-unicode-supported": "^0.1.0" }, "engines": { "node": ">=10" }, "funding": { - "url": "https://github.com/chalk/supports-color?sponsor=1" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/metro-minify-terser": { - "version": "0.80.12", - "resolved": "https://registry.npmjs.org/metro-minify-terser/-/metro-minify-terser-0.80.12.tgz", - "integrity": "sha512-muWzUw3y5k+9083ZoX9VaJLWEV2Jcgi+Oan0Mmb/fBNMPqP9xVDuy4pOMn/HOiGndgfh/MK7s4bsjkyLJKMnXQ==", + "node_modules/log-symbols/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "flow-enums-runtime": "^0.0.6", - "terser": "^5.15.0" + "color-convert": "^2.0.1" }, "engines": { - "node": ">=18" - } - }, - "node_modules/metro-resolver": { - "version": "0.80.12", - "resolved": "https://registry.npmjs.org/metro-resolver/-/metro-resolver-0.80.12.tgz", - "integrity": "sha512-PR24gYRZnYHM3xT9pg6BdbrGbM/Cu1TcyIFBVlAk7qDAuHkUNQ1nMzWumWs+kwSvtd9eZGzHoucGJpTUEeLZAw==", - "license": "MIT", - "peer": true, - "dependencies": { - "flow-enums-runtime": "^0.0.6" + "node": ">=8" }, - "engines": { - "node": ">=18" + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/metro-runtime": { - "version": "0.80.12", - "resolved": "https://registry.npmjs.org/metro-runtime/-/metro-runtime-0.80.12.tgz", - "integrity": "sha512-LIx7+92p5rpI0i6iB4S4GBvvLxStNt6fF0oPMaUd1Weku7jZdfkCZzmrtDD9CSQ6EPb0T9NUZoyXIxlBa3wOCw==", + "node_modules/log-symbols/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "@babel/runtime": "^7.25.0", - "flow-enums-runtime": "^0.0.6" + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" }, "engines": { - "node": ">=18" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" } }, - "node_modules/metro-runtime/node_modules/@babel/runtime": { - "version": "7.25.6", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", - "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", + "node_modules/log-symbols/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "regenerator-runtime": "^0.14.0" + "color-name": "~1.1.4" }, "engines": { - "node": ">=6.9.0" + "node": ">=7.0.0" } }, - "node_modules/metro-runtime/node_modules/regenerator-runtime": { - "version": "0.14.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", - "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", - "license": "MIT", - "peer": true + "node_modules/log-symbols/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true, + "license": "MIT" }, - "node_modules/metro-source-map": { - "version": "0.80.12", - "resolved": "https://registry.npmjs.org/metro-source-map/-/metro-source-map-0.80.12.tgz", - "integrity": "sha512-o+AXmE7hpvM8r8MKsx7TI21/eerYYy2DCDkWfoBkv+jNkl61khvDHlQn0cXZa6lrcNZiZkl9oHSMcwLLIrFmpw==", + "node_modules/log-symbols/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, "license": "MIT", - "peer": true, - "dependencies": { - "@babel/traverse": "^7.20.0", - "@babel/types": "^7.20.0", - "flow-enums-runtime": "^0.0.6", - "invariant": "^2.2.4", - "metro-symbolicate": "0.80.12", - "nullthrows": "^1.1.1", - "ob1": "0.80.12", - "source-map": "^0.5.6", - "vlq": "^1.0.0" - }, "engines": { - "node": ">=18" + "node": ">=8" } }, - "node_modules/metro-symbolicate": { - "version": "0.80.12", - "resolved": "https://registry.npmjs.org/metro-symbolicate/-/metro-symbolicate-0.80.12.tgz", - "integrity": "sha512-/dIpNdHksXkGHZXARZpL7doUzHqSNxgQ8+kQGxwpJuHnDhGkENxB5PS2QBaTDdEcmyTMjS53CN1rl9n1gR6fmw==", + "node_modules/log-symbols/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "flow-enums-runtime": "^0.0.6", - "invariant": "^2.2.4", - "metro-source-map": "0.80.12", - "nullthrows": "^1.1.1", - "source-map": "^0.5.6", - "through2": "^2.0.1", - "vlq": "^1.0.0" - }, - "bin": { - "metro-symbolicate": "src/index.js" + "has-flag": "^4.0.0" }, "engines": { - "node": ">=18" + "node": ">=8" } }, - "node_modules/metro-transform-plugins": { - "version": "0.80.12", - "resolved": "https://registry.npmjs.org/metro-transform-plugins/-/metro-transform-plugins-0.80.12.tgz", - "integrity": "sha512-WQWp00AcZvXuQdbjQbx1LzFR31IInlkCDYJNRs6gtEtAyhwpMMlL2KcHmdY+wjDO9RPcliZ+Xl1riOuBecVlPA==", + "node_modules/log-update": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/log-update/-/log-update-4.0.0.tgz", + "integrity": "sha512-9fkkDevMefjg0mmzWFBW8YkFP91OrizzkW3diF7CpG+S2EYdy4+TVfGwz1zeF8x7hCx1ovSPTOE9Ngib74qqUg==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "@babel/core": "^7.20.0", - "@babel/generator": "^7.20.0", - "@babel/template": "^7.0.0", - "@babel/traverse": "^7.20.0", - "flow-enums-runtime": "^0.0.6", - "nullthrows": "^1.1.1" + "ansi-escapes": "^4.3.0", + "cli-cursor": "^3.1.0", + "slice-ansi": "^4.0.0", + "wrap-ansi": "^6.2.0" }, "engines": { - "node": ">=18" - } - }, - "node_modules/metro-transform-worker": { - "version": "0.80.12", - "resolved": "https://registry.npmjs.org/metro-transform-worker/-/metro-transform-worker-0.80.12.tgz", - "integrity": "sha512-KAPFN1y3eVqEbKLx1I8WOarHPqDMUa8WelWxaJCNKO/yHCP26zELeqTJvhsQup+8uwB6EYi/sp0b6TGoh6lOEA==", - "license": "MIT", - "peer": true, - "dependencies": { - "@babel/core": "^7.20.0", - "@babel/generator": "^7.20.0", - "@babel/parser": "^7.20.0", - "@babel/types": "^7.20.0", - "flow-enums-runtime": "^0.0.6", - "metro": "0.80.12", - "metro-babel-transformer": "0.80.12", - "metro-cache": "0.80.12", - "metro-cache-key": "0.80.12", - "metro-minify-terser": "0.80.12", - "metro-source-map": "0.80.12", - "metro-transform-plugins": "0.80.12", - "nullthrows": "^1.1.1" + "node": ">=10" }, - "engines": { - "node": ">=18" + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/metro/node_modules/ansi-styles": { + "node_modules/log-update/node_modules/ansi-styles": { "version": "4.3.0", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { "color-convert": "^2.0.1" }, @@ -16749,165 +12386,217 @@ "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/metro/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/log-update/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/log-update/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true, + "license": "MIT" + }, + "node_modules/log-update/node_modules/slice-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-4.0.0.tgz", + "integrity": "sha512-qMCMfhY040cVHT43K9BFygqYbUPFZKHOg7K73mtTWJRb8pyP3fzf4Ixd5SzdEJQ6MRUg/WBnOLxghZtKKurENQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.0.0", + "astral-regex": "^2.0.0", + "is-fullwidth-code-point": "^3.0.0" }, "engines": { "node": ">=10" }, "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "url": "https://github.com/chalk/slice-ansi?sponsor=1" } }, - "node_modules/metro/node_modules/ci-info": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-2.0.0.tgz", - "integrity": "sha512-5tK7EtrZ0N+OLFMthtqOj4fI2Jeb88C4CAZPu25LDVUgXJ0A3Js4PMGqrn0JU1W0Mh1/Z8wZzYPxqUrXeBboCQ==", - "license": "MIT", - "peer": true - }, - "node_modules/metro/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/log-update/node_modules/wrap-ansi": { + "version": "6.2.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-6.2.0.tgz", + "integrity": "sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "color-name": "~1.1.4" + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" }, "engines": { - "node": ">=7.0.0" + "node": ">=8" } }, - "node_modules/metro/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "node_modules/loose-envify": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", + "integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==", "license": "MIT", - "peer": true + "dependencies": { + "js-tokens": "^3.0.0 || ^4.0.0" + }, + "bin": { + "loose-envify": "cli.js" + } }, - "node_modules/metro/node_modules/debug": { - "version": "2.6.9", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "node_modules/lower-case": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/lower-case/-/lower-case-2.0.2.tgz", + "integrity": "sha512-7fm3l3NAF9WfN6W3JOmf5drwpVqX78JtoGJ3A6W0a6ZnldM41w2fV5D490psKFTpMds8TJse/eHLFFsNHHjHgg==", + "dev": true, "license": "MIT", - "peer": true, "dependencies": { - "ms": "2.0.0" + "tslib": "^2.0.3" } }, - "node_modules/metro/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/lower-case/node_modules/tslib": { + "version": "2.7.0", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.7.0.tgz", + "integrity": "sha512-gLXCKdN1/j47AiHiOkJN69hJmcbGTHI0ImLmbYLHykhgeN0jVGola9yVjFgzCUklsZQMW55o+dW7IXv3RCXDzA==", + "dev": true, + "license": "0BSD" + }, + "node_modules/lowercase-keys": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/lowercase-keys/-/lowercase-keys-2.0.0.tgz", + "integrity": "sha512-tqNXrS78oMOE73NMxK4EMLQsQowWf8jKooH9g7xPavRT706R6bkQJ6DY2Te7QukaZsulxa30wQ7bk0pm4XiHmA==", + "dev": true, "license": "MIT", - "peer": true, "engines": { "node": ">=8" } }, - "node_modules/metro/node_modules/hermes-estree": { - "version": "0.23.1", - "resolved": "https://registry.npmjs.org/hermes-estree/-/hermes-estree-0.23.1.tgz", - "integrity": "sha512-eT5MU3f5aVhTqsfIReZ6n41X5sYn4IdQL0nvz6yO+MMlPxw49aSARHLg/MSehQftyjnrE8X6bYregzSumqc6cg==", + "node_modules/lru-cache": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz", + "integrity": "sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==", + "dev": true, + "license": "ISC", + "dependencies": { + "yallist": "^3.0.2" + } + }, + "node_modules/mathml-tag-names": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/mathml-tag-names/-/mathml-tag-names-2.1.3.tgz", + "integrity": "sha512-APMBEanjybaPzUrfqU0IMU5I0AswKMH7k8OTLs0vvV4KZpExkTkY87nR/zpbuTPj+gARop7aGUbl11pnDfW6xg==", + "dev": true, "license": "MIT", - "peer": true + "funding": { + "type": "github", + "url": "https://github.com/sponsors/wooorm" + } + }, + "node_modules/mdn-data": { + "version": "2.0.30", + "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.30.tgz", + "integrity": "sha512-GaqWWShW4kv/G9IEucWScBx9G1/vsFZZJUO+tD26M8J8z3Kw5RDQjaoZe03YAClgeS/SWPOcb4nkFBTEi5DUEA==", + "dev": true, + "license": "CC0-1.0" }, - "node_modules/metro/node_modules/hermes-parser": { - "version": "0.23.1", - "resolved": "https://registry.npmjs.org/hermes-parser/-/hermes-parser-0.23.1.tgz", - "integrity": "sha512-oxl5h2DkFW83hT4DAUJorpah8ou4yvmweUzLJmmr6YV2cezduCdlil1AvU/a/xSsAFo4WUcNA4GoV5Bvq6JffA==", + "node_modules/media-typer": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz", + "integrity": "sha512-dq+qelQ9akHpcOl/gUVRTxVIOkAJ1wR3QAvb4RsVjS8oVoFjDGTc679wJYmUmknUF5HwMLOgb5O+a3KxfWapPQ==", + "dev": true, "license": "MIT", - "peer": true, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/memfs": { + "version": "3.5.3", + "resolved": "https://registry.npmjs.org/memfs/-/memfs-3.5.3.tgz", + "integrity": "sha512-UERzLsxzllchadvbPs5aolHh65ISpKpM+ccLbOJ8/vvpBKmAWf+la7dXFy7Mr0ySHbdHrFv5kGFCUHHe6GFEmw==", + "dev": true, + "license": "Unlicense", "dependencies": { - "hermes-estree": "0.23.1" + "fs-monkey": "^1.0.4" + }, + "engines": { + "node": ">= 4.0.0" } }, - "node_modules/metro/node_modules/jest-worker": { - "version": "29.7.0", - "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-29.7.0.tgz", - "integrity": "sha512-eIz2msL/EzL9UFTFFx7jBTkeZfku0yUAyZZZmJ93H2TYEiroIx2PQjEXcwYtYl8zXCxb+PAmA2hLIt/6ZEkPHw==", + "node_modules/memize": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/memize/-/memize-1.1.0.tgz", + "integrity": "sha512-K4FcPETOMTwe7KL2LK0orMhpOmWD2wRGwWWpbZy0fyArwsyIKR8YJVz8+efBAh3BO4zPqlSICu4vsLTRRqtFAg==", + "license": "MIT" + }, + "node_modules/memory-fs": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/memory-fs/-/memory-fs-0.2.0.tgz", + "integrity": "sha512-+y4mDxU4rvXXu5UDSGCGNiesFmwCHuefGMoPCO1WYucNYj7DsLqrFaa2fXVI0H+NNiPTwwzKwspn9yTZqUGqng==", + "dev": true, + "license": "MIT" + }, + "node_modules/meow": { + "version": "13.2.0", + "resolved": "https://registry.npmjs.org/meow/-/meow-13.2.0.tgz", + "integrity": "sha512-pxQJQzB6djGPXh08dacEloMFopsOqGVRKFPYvPOt9XDZ1HasbgDZA74CJGreSU4G3Ak7EFJGoiH2auq+yXISgA==", + "dev": true, "license": "MIT", - "peer": true, - "dependencies": { - "@types/node": "*", - "jest-util": "^29.7.0", - "merge-stream": "^2.0.0", - "supports-color": "^8.0.0" - }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/metro/node_modules/jest-worker/node_modules/supports-color": { - "version": "8.1.1", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", - "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", + "node_modules/merge-descriptors": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.3.tgz", + "integrity": "sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==", + "dev": true, "license": "MIT", - "peer": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=10" - }, "funding": { - "url": "https://github.com/chalk/supports-color?sponsor=1" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/metro/node_modules/ms": { + "node_modules/merge-stream": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", - "license": "MIT", - "peer": true + "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz", + "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==", + "dev": true, + "license": "MIT" }, - "node_modules/metro/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/merge2": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", + "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==", + "dev": true, "license": "MIT", - "peer": true, - "dependencies": { - "has-flag": "^4.0.0" - }, "engines": { - "node": ">=8" + "node": ">= 8" } }, - "node_modules/metro/node_modules/ws": { - "version": "7.5.10", - "resolved": "https://registry.npmjs.org/ws/-/ws-7.5.10.tgz", - "integrity": "sha512-+dbF1tHwZpXcbOJdVOkzLDxZP1ailvSxM6ZweXTegylPny803bFhA+vqBYw4s31NSAk4S2Qz+AKXK9a4wkdjcQ==", + "node_modules/methods": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz", + "integrity": "sha512-iclAHeNqNm68zFtnZ0e+1L2yUIdvzNoauKU4WBA3VvH/vPFieF7qfRlwUZU+DA9P9bPXIS90ulxoUoCH23sV2w==", + "dev": true, "license": "MIT", - "peer": true, "engines": { - "node": ">=8.3.0" - }, - "peerDependencies": { - "bufferutil": "^4.0.1", - "utf-8-validate": "^5.0.2" - }, - "peerDependenciesMeta": { - "bufferutil": { - "optional": true - }, - "utf-8-validate": { - "optional": true - } + "node": ">= 0.6" } }, "node_modules/micromatch": { "version": "4.0.8", "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.8.tgz", "integrity": "sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==", + "dev": true, "license": "MIT", "dependencies": { "braces": "^3.0.3", @@ -16921,6 +12610,7 @@ "version": "1.6.0", "resolved": "https://registry.npmjs.org/mime/-/mime-1.6.0.tgz", "integrity": "sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==", + "dev": true, "license": "MIT", "bin": { "mime": "cli.js" @@ -16933,6 +12623,7 @@ "version": "1.52.0", "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", + "dev": true, "license": "MIT", "engines": { "node": ">= 0.6" @@ -16942,6 +12633,7 @@ "version": "2.1.35", "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", + "dev": true, "license": "MIT", "dependencies": { "mime-db": "1.52.0" @@ -16954,6 +12646,7 @@ "version": "2.1.0", "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", + "dev": true, "license": "MIT", "engines": { "node": ">=6" @@ -17011,6 +12704,7 @@ "version": "3.1.2", "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, "license": "ISC", "dependencies": { "brace-expansion": "^1.1.7" @@ -17042,6 +12736,7 @@ "version": "0.5.6", "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.6.tgz", "integrity": "sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw==", + "dev": true, "license": "MIT", "dependencies": { "minimist": "^1.2.6" @@ -17129,6 +12824,7 @@ "version": "0.6.3", "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.3.tgz", "integrity": "sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg==", + "dev": true, "license": "MIT", "engines": { "node": ">= 0.6" @@ -17138,6 +12834,7 @@ "version": "2.6.2", "resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.2.tgz", "integrity": "sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==", + "dev": true, "license": "MIT" }, "node_modules/no-case": { @@ -17158,23 +12855,6 @@ "dev": true, "license": "0BSD" }, - "node_modules/nocache": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/nocache/-/nocache-3.0.4.tgz", - "integrity": "sha512-WDD0bdg9mbq6F4mRxEYcPWwfA1vxd0mrvKOyxI7Xj/atfRHVeutzuWByG//jfm4uPzp0y4Kj051EORCBSQMycw==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=12.0.0" - } - }, - "node_modules/node-abort-controller": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/node-abort-controller/-/node-abort-controller-3.1.1.tgz", - "integrity": "sha512-AGK2yQKIjRuqnc6VkX2Xj5d+QW8xZ87pa1UK6yA6ouUyuxfHuMP6umE5QK7UmTeOAymo+Zx1Fxiuw9rVx8taHQ==", - "license": "MIT", - "peer": true - }, "node_modules/node-addon-api": { "version": "7.1.1", "resolved": "https://registry.npmjs.org/node-addon-api/-/node-addon-api-7.1.1.tgz", @@ -17183,80 +12863,28 @@ "license": "MIT", "optional": true }, - "node_modules/node-dir": { - "version": "0.1.17", - "resolved": "https://registry.npmjs.org/node-dir/-/node-dir-0.1.17.tgz", - "integrity": "sha512-tmPX422rYgofd4epzrNoOXiE8XFZYOcCq1vD7MAXCDO+O+zndlA2ztdKKMa+EeuBG5tHETpr4ml4RGgpqDCCAg==", - "license": "MIT", - "peer": true, - "dependencies": { - "minimatch": "^3.0.2" - }, - "engines": { - "node": ">= 0.10.5" - } - }, - "node_modules/node-fetch": { - "version": "2.7.0", - "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.7.0.tgz", - "integrity": "sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==", - "license": "MIT", - "peer": true, - "dependencies": { - "whatwg-url": "^5.0.0" - }, - "engines": { - "node": "4.x || >=6.0.0" - }, - "peerDependencies": { - "encoding": "^0.1.0" - }, - "peerDependenciesMeta": { - "encoding": { - "optional": true - } - } - }, "node_modules/node-forge": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/node-forge/-/node-forge-1.3.1.tgz", "integrity": "sha512-dPEtOeMvF9VMcYV/1Wb8CPoVAXtp6MKMlcbAt4ddqmGqUJ6fQZFXkNZNkNlfevtNkGtaSoXf/vNNNSvgrdXwtA==", + "dev": true, "license": "(BSD-3-Clause OR GPL-2.0)", "engines": { "node": ">= 6.13.0" } }, - "node_modules/node-int64": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/node-int64/-/node-int64-0.4.0.tgz", - "integrity": "sha512-O5lz91xSOeoXP6DulyHfllpq+Eg00MWitZIbtPfoSEvqIHdl5gfcY6hYzDWnj0qD5tz52PI08u9qUvSVeUBeHw==", - "license": "MIT", - "peer": true - }, "node_modules/node-releases": { "version": "2.0.19", "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.19.tgz", "integrity": "sha512-xxOWJsBKtzAq7DY0J+DTzuz58K8e7sJbdgwkbMWQe8UYB6ekmsQ45q0M/tJDsGaZmbC+l7n57UV8Hl5tHxO9uw==", + "dev": true, "license": "MIT" }, - "node_modules/node-stream-zip": { - "version": "1.15.0", - "resolved": "https://registry.npmjs.org/node-stream-zip/-/node-stream-zip-1.15.0.tgz", - "integrity": "sha512-LN4fydt9TqhZhThkZIVQnF9cwjU3qmUH9h78Mx/K7d3VvfRqqwthLwJEUOEL0QPZ0XQmNN7be5Ggit5+4dq3Bw==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=0.12.0" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/antelle" - } - }, "node_modules/normalize-path": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "dev": true, "license": "MIT", "engines": { "node": ">=0.10.0" @@ -17439,6 +13067,7 @@ "version": "4.0.1", "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-4.0.1.tgz", "integrity": "sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==", + "dev": true, "license": "MIT", "dependencies": { "path-key": "^3.0.0" @@ -19641,26 +15270,6 @@ "url": "https://github.com/fb55/nth-check?sponsor=1" } }, - "node_modules/nullthrows": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/nullthrows/-/nullthrows-1.1.1.tgz", - "integrity": "sha512-2vPPEi+Z7WqML2jZYddDIfy5Dqb0r2fze2zTxNNknZaFpVHU3mFB3R+DWeJWGVx0ecvttSGlJTI+WG+8Z4cDWw==", - "license": "MIT", - "peer": true - }, - "node_modules/ob1": { - "version": "0.80.12", - "resolved": "https://registry.npmjs.org/ob1/-/ob1-0.80.12.tgz", - "integrity": "sha512-VMArClVT6LkhUGpnuEoBuyjG9rzUyEzg4PDkav6wK1cLhOK02gPCYFxoiB4mqVnrMhDpIzJcrGNAMVi9P+hXrw==", - "license": "MIT", - "peer": true, - "dependencies": { - "flow-enums-runtime": "^0.0.6" - }, - "engines": { - "node": ">=18" - } - }, "node_modules/object-assign": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", @@ -19801,6 +15410,7 @@ "version": "2.4.1", "resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.4.1.tgz", "integrity": "sha512-oVlzkg3ENAhCk2zdv7IJwd/QUD4z2RxRwpkcGY8psCVcCYZNq4wYnVWALHM+brtuJjePWiYF/ClmuDr8Ch5+kg==", + "dev": true, "license": "MIT", "dependencies": { "ee-first": "1.1.1" @@ -19813,6 +15423,7 @@ "version": "1.0.2", "resolved": "https://registry.npmjs.org/on-headers/-/on-headers-1.0.2.tgz", "integrity": "sha512-pZAE+FJLoyITytdqK0U5s+FIpjN0JP3OzFi/u8Rx+EV5/W+JTWGXG8xFzevE7AjBfDqHv/8vL8qQsIhHnqRkrA==", + "dev": true, "license": "MIT", "engines": { "node": ">= 0.8" @@ -19822,6 +15433,7 @@ "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", + "dev": true, "license": "ISC", "dependencies": { "wrappy": "1" @@ -19831,6 +15443,7 @@ "version": "5.1.2", "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.2.tgz", "integrity": "sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==", + "dev": true, "license": "MIT", "dependencies": { "mimic-fn": "^2.1.0" @@ -20086,6 +15699,7 @@ "version": "3.1.0", "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", + "dev": true, "license": "MIT", "dependencies": { "yocto-queue": "^0.1.0" @@ -20101,6 +15715,7 @@ "version": "5.0.0", "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", + "dev": true, "license": "MIT", "dependencies": { "p-limit": "^3.0.2" @@ -20146,6 +15761,7 @@ "version": "2.2.0", "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", + "dev": true, "license": "MIT", "engines": { "node": ">=6" @@ -20162,6 +15778,7 @@ "version": "1.0.1", "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==", + "dev": true, "license": "MIT", "dependencies": { "callsites": "^3.0.0" @@ -20188,6 +15805,7 @@ "version": "5.2.0", "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.2.0.tgz", "integrity": "sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==", + "dev": true, "license": "MIT", "dependencies": { "@babel/code-frame": "^7.0.0", @@ -20206,6 +15824,7 @@ "version": "1.3.3", "resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz", "integrity": "sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==", + "dev": true, "license": "MIT", "engines": { "node": ">= 0.8" @@ -20215,6 +15834,7 @@ "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", + "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -20224,6 +15844,7 @@ "version": "1.0.1", "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", "integrity": "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==", + "dev": true, "license": "MIT", "engines": { "node": ">=0.10.0" @@ -20233,6 +15854,7 @@ "version": "3.1.1", "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", + "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -20242,6 +15864,7 @@ "version": "1.0.7", "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", + "dev": true, "license": "MIT" }, "node_modules/path-scurry": { @@ -20327,16 +15950,6 @@ "node": ">=0.10.0" } }, - "node_modules/pirates": { - "version": "4.0.6", - "resolved": "https://registry.npmjs.org/pirates/-/pirates-4.0.6.tgz", - "integrity": "sha512-saLsH7WeYYPiD25LDuLRRY/i+6HaPYr6G1OUlN39otzkSTxKnubR9RTxS3/Kk50s1g2JTgFwWQDQyplC5/SHZg==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">= 6" - } - }, "node_modules/pkg-dir": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-7.0.0.tgz", @@ -20640,23 +16253,6 @@ "node": ">= 0.8.0" } }, - "node_modules/prettier": { - "version": "3.3.3", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.3.3.tgz", - "integrity": "sha512-i2tDNA0O5IrMO757lfrdQZCc2jPNDVntV0m/+4whiDfWaTKfMNgR7Qz0NAeGz/nRqF4m5/6CLzbP4/liHt12Ew==", - "dev": true, - "license": "MIT", - "peer": true, - "bin": { - "prettier": "bin/prettier.cjs" - }, - "engines": { - "node": ">=14" - }, - "funding": { - "url": "https://github.com/prettier/prettier?sponsor=1" - } - }, "node_modules/prettier-linter-helpers": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/prettier-linter-helpers/-/prettier-linter-helpers-1.0.0.tgz", @@ -20683,132 +16279,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/pretty-format": { - "version": "26.6.2", - "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-26.6.2.tgz", - "integrity": "sha512-7AeGuCYNGmycyQbCqd/3PWH4eOoX/OiCa0uphp57NVTeAGdJGaAliecxwBDHYQCIvrW7aDBZCYeNTP/WX69mkg==", - "license": "MIT", - "peer": true, - "dependencies": { - "@jest/types": "^26.6.2", - "ansi-regex": "^5.0.0", - "ansi-styles": "^4.0.0", - "react-is": "^17.0.1" - }, - "engines": { - "node": ">= 10" - } - }, - "node_modules/pretty-format/node_modules/@jest/types": { - "version": "26.6.2", - "resolved": "https://registry.npmjs.org/@jest/types/-/types-26.6.2.tgz", - "integrity": "sha512-fC6QCp7Sc5sX6g8Tvbmj4XUTbyrik0akgRy03yjXbQaBWWNWGE7SGtJk98m0N8nzegD/7SggrUlivxo5ax4KWQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "@types/istanbul-lib-coverage": "^2.0.0", - "@types/istanbul-reports": "^3.0.0", - "@types/node": "*", - "@types/yargs": "^15.0.0", - "chalk": "^4.0.0" - }, - "engines": { - "node": ">= 10.14.2" - } - }, - "node_modules/pretty-format/node_modules/@types/yargs": { - "version": "15.0.19", - "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-15.0.19.tgz", - "integrity": "sha512-2XUaGVmyQjgyAZldf0D0c14vvo/yv0MhQBSTJcejMMaitsn3nxCB6TmH4G0ZQf+uxROOa9mpanoSm8h6SG/1ZA==", - "license": "MIT", - "peer": true, - "dependencies": { - "@types/yargs-parser": "*" - } - }, - "node_modules/pretty-format/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "license": "MIT", - "peer": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/pretty-format/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "license": "MIT", - "peer": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/pretty-format/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/pretty-format/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "license": "MIT", - "peer": true - }, - "node_modules/pretty-format/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/pretty-format/node_modules/react-is": { - "version": "17.0.2", - "resolved": "https://registry.npmjs.org/react-is/-/react-is-17.0.2.tgz", - "integrity": "sha512-w2GsyukL62IJnlaff/nRegPQR94C/XXamvMWmSHRJ4y7Ts/4ocGRmTHvOs8PSE6pB3dWOrD/nueuU5sduBsQ4w==", - "license": "MIT", - "peer": true - }, - "node_modules/pretty-format/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "license": "MIT", - "peer": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/process": { "version": "0.11.10", "resolved": "https://registry.npmjs.org/process/-/process-0.11.10.tgz", @@ -20825,20 +16295,11 @@ "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==", "license": "MIT" }, - "node_modules/promise": { - "version": "8.3.0", - "resolved": "https://registry.npmjs.org/promise/-/promise-8.3.0.tgz", - "integrity": "sha512-rZPNPKTOYVNEEKFaq1HqTgOwZD+4/YHS5ukLzQCypkj+OkYx7iv0mA91lJlpPPZ8vMau3IIGj5Qlwrx+8iiSmg==", - "license": "MIT", - "peer": true, - "dependencies": { - "asap": "~2.0.6" - } - }, "node_modules/prompts": { "version": "2.4.2", "resolved": "https://registry.npmjs.org/prompts/-/prompts-2.4.2.tgz", "integrity": "sha512-NxNv/kLguCA7p3jE8oL2aEBsrJWgAakBpgmgK6lpPWV+WuOmY6r2/zbAVnP+T8bQlA0nzHXSJSJW0Hq7ylaD2Q==", + "dev": true, "license": "MIT", "dependencies": { "kleur": "^3.0.3", @@ -20852,6 +16313,7 @@ "version": "3.0.3", "resolved": "https://registry.npmjs.org/kleur/-/kleur-3.0.3.tgz", "integrity": "sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w==", + "dev": true, "license": "MIT", "engines": { "node": ">=6" @@ -20968,24 +16430,15 @@ "node_modules/querystringify": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz", - "integrity": "sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ==", - "dev": true, - "license": "MIT" - }, - "node_modules/queue": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/queue/-/queue-6.0.2.tgz", - "integrity": "sha512-iHZWu+q3IdFZFX36ro/lKBkSvfkztY5Y7HMiPlOUjhupPcG2JMfst2KKEpu5XndviX/3UhFbRngUPNKtgvtZiA==", - "license": "MIT", - "peer": true, - "dependencies": { - "inherits": "~2.0.3" - } + "integrity": "sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ==", + "dev": true, + "license": "MIT" }, "node_modules/queue-microtask": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==", + "dev": true, "funding": [ { "type": "github", @@ -21029,6 +16482,7 @@ "version": "1.2.1", "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz", "integrity": "sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==", + "dev": true, "license": "MIT", "engines": { "node": ">= 0.6" @@ -21137,39 +16591,6 @@ "react-dom": "^0.14 || ^15.5.4 || ^16.1.1" } }, - "node_modules/react-devtools-core": { - "version": "5.3.1", - "resolved": "https://registry.npmjs.org/react-devtools-core/-/react-devtools-core-5.3.1.tgz", - "integrity": "sha512-7FSb9meX0btdBQLwdFOwt6bGqvRPabmVMMslv8fgoSPqXyuGpgQe36kx8gR86XPw7aV1yVouTp6fyZ0EH+NfUw==", - "license": "MIT", - "peer": true, - "dependencies": { - "shell-quote": "^1.6.1", - "ws": "^7" - } - }, - "node_modules/react-devtools-core/node_modules/ws": { - "version": "7.5.10", - "resolved": "https://registry.npmjs.org/ws/-/ws-7.5.10.tgz", - "integrity": "sha512-+dbF1tHwZpXcbOJdVOkzLDxZP1ailvSxM6ZweXTegylPny803bFhA+vqBYw4s31NSAk4S2Qz+AKXK9a4wkdjcQ==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=8.3.0" - }, - "peerDependencies": { - "bufferutil": "^4.0.1", - "utf-8-validate": "^5.0.2" - }, - "peerDependenciesMeta": { - "bufferutil": { - "optional": true - }, - "utf-8-validate": { - "optional": true - } - } - }, "node_modules/react-dom": { "version": "16.14.0", "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-16.14.0.tgz", @@ -21185,13 +16606,6 @@ "react": "^16.14.0" } }, - "node_modules/react-is": { - "version": "18.3.1", - "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz", - "integrity": "sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==", - "license": "MIT", - "peer": true - }, "node_modules/react-moment-proptypes": { "version": "1.8.1", "resolved": "https://registry.npmjs.org/react-moment-proptypes/-/react-moment-proptypes-1.8.1.tgz", @@ -21234,16 +16648,6 @@ "react-dom": "^16.0.0-0 || ^17.0.0-0 || ^18.0.0-0" } }, - "node_modules/react-refresh": { - "version": "0.14.2", - "resolved": "https://registry.npmjs.org/react-refresh/-/react-refresh-0.14.2.tgz", - "integrity": "sha512-jCvmsr+1IUSMUyzOkRcvnVbX3ZYC6g9TDrDbFuFmRDq7PD4yaGbLKNQL6k2jnArV8hjYxh7hVhAZB6s9HDGpZA==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/react-resize-aware": { "version": "3.1.3", "resolved": "https://registry.npmjs.org/react-resize-aware/-/react-resize-aware-3.1.3.tgz", @@ -21381,46 +16785,6 @@ "node": ">=8.10.0" } }, - "node_modules/readline": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/readline/-/readline-1.3.0.tgz", - "integrity": "sha512-k2d6ACCkiNYz222Fs/iNze30rRJ1iIicW7JuX/7/cozvih6YCkFZH+J6mAFDVgv0dRBaAyr4jDqC95R2y4IADg==", - "license": "BSD", - "peer": true - }, - "node_modules/recast": { - "version": "0.21.5", - "resolved": "https://registry.npmjs.org/recast/-/recast-0.21.5.tgz", - "integrity": "sha512-hjMmLaUXAm1hIuTqOdeYObMslq/q+Xff6QE3Y2P+uoHAg2nmVlLBps2hzh1UJDdMtDTMXOFewK6ky51JQIeECg==", - "license": "MIT", - "peer": true, - "dependencies": { - "ast-types": "0.15.2", - "esprima": "~4.0.0", - "source-map": "~0.6.1", - "tslib": "^2.0.1" - }, - "engines": { - "node": ">= 4" - } - }, - "node_modules/recast/node_modules/source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "license": "BSD-3-Clause", - "peer": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/recast/node_modules/tslib": { - "version": "2.7.0", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.7.0.tgz", - "integrity": "sha512-gLXCKdN1/j47AiHiOkJN69hJmcbGTHI0ImLmbYLHykhgeN0jVGola9yVjFgzCUklsZQMW55o+dW7IXv3RCXDzA==", - "license": "0BSD", - "peer": true - }, "node_modules/rechoir": { "version": "0.8.0", "resolved": "https://registry.npmjs.org/rechoir/-/rechoir-0.8.0.tgz", @@ -21503,12 +16867,14 @@ "version": "1.4.2", "resolved": "https://registry.npmjs.org/regenerate/-/regenerate-1.4.2.tgz", "integrity": "sha512-zrceR/XhGYU/d/opr2EKO7aRHUeiBI8qjtfHqADTwZd6Szfy16la6kqD0MIUs5z5hx6AaKa+PixpPrR289+I0A==", + "dev": true, "license": "MIT" }, "node_modules/regenerate-unicode-properties": { "version": "10.2.0", "resolved": "https://registry.npmjs.org/regenerate-unicode-properties/-/regenerate-unicode-properties-10.2.0.tgz", "integrity": "sha512-DqHn3DwbmmPVzeKj9woBadqmXxLvQoQIwu7nopMc72ztvxVmVk2SBhSnx67zuye5TP+lJsb/TBQsjLKhnDf3MA==", + "dev": true, "license": "MIT", "dependencies": { "regenerate": "^1.4.2" @@ -21527,6 +16893,7 @@ "version": "0.15.2", "resolved": "https://registry.npmjs.org/regenerator-transform/-/regenerator-transform-0.15.2.tgz", "integrity": "sha512-hfMp2BoF0qOk3uc5V20ALGDS2ddjQaLrdl7xrGXvAIow7qeWRM2VA2HuCHkUKk9slq3VwEwLNK3DFBqDfPGYtg==", + "dev": true, "license": "MIT", "dependencies": { "@babel/runtime": "^7.8.4" @@ -21536,6 +16903,7 @@ "version": "7.25.6", "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", + "dev": true, "license": "MIT", "dependencies": { "regenerator-runtime": "^0.14.0" @@ -21548,6 +16916,7 @@ "version": "0.14.1", "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==", + "dev": true, "license": "MIT" }, "node_modules/regexp.prototype.flags": { @@ -21572,6 +16941,7 @@ "version": "5.3.2", "resolved": "https://registry.npmjs.org/regexpu-core/-/regexpu-core-5.3.2.tgz", "integrity": "sha512-RAM5FlZz+Lhmo7db9L298p2vHP5ZywrVXmVXpmAD9GuL5MPH6t9ROw1iA/wfHkQ76Qe7AaPF0nGuim96/IrQMQ==", + "dev": true, "license": "MIT", "dependencies": { "@babel/regjsgen": "^0.8.0", @@ -21589,6 +16959,7 @@ "version": "0.9.1", "resolved": "https://registry.npmjs.org/regjsparser/-/regjsparser-0.9.1.tgz", "integrity": "sha512-dQUtn90WanSNl+7mQKcXAgZxvUe7Z0SqXlgzv0za4LwiUhyzBC58yQO3liFoUgu8GiJVInAhJjkj1N0EtQ5nkQ==", + "dev": true, "license": "BSD-2-Clause", "dependencies": { "jsesc": "~0.5.0" @@ -21601,6 +16972,7 @@ "version": "0.5.0", "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-0.5.0.tgz", "integrity": "sha512-uZz5UnB7u4T9LvwmFqXii7pZSouaRPorGs5who1Ip7VO0wxanFvBL7GkM6dTHlgX+jhBApRetaWpnDabOeTcnA==", + "dev": true, "bin": { "jsesc": "bin/jsesc" } @@ -21640,6 +17012,7 @@ "version": "2.1.1", "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", + "dev": true, "license": "MIT", "engines": { "node": ">=0.10.0" @@ -21655,13 +17028,6 @@ "node": ">=0.10.0" } }, - "node_modules/require-main-filename": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", - "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", - "license": "ISC", - "peer": true - }, "node_modules/requireindex": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/requireindex/-/requireindex-1.2.0.tgz", @@ -21683,6 +17049,7 @@ "version": "1.22.8", "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.8.tgz", "integrity": "sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw==", + "dev": true, "license": "MIT", "dependencies": { "is-core-module": "^2.13.0", @@ -21730,6 +17097,7 @@ "version": "4.0.0", "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", + "dev": true, "license": "MIT", "engines": { "node": ">=4" @@ -21752,6 +17120,7 @@ "version": "3.1.0", "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-3.1.0.tgz", "integrity": "sha512-l+sSefzHpj5qimhFSE5a8nufZYAM3sBSVMAPtYkmC+4EH2anSGaEMXSD0izRQbu9nfyQ9y5JrVmp7E8oZrUjvA==", + "dev": true, "license": "MIT", "dependencies": { "onetime": "^5.1.0", @@ -21775,6 +17144,7 @@ "version": "1.0.4", "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz", "integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==", + "dev": true, "license": "MIT", "engines": { "iojs": ">=1.0.0", @@ -21793,6 +17163,7 @@ "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz", "integrity": "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==", "deprecated": "Rimraf versions prior to v4 are no longer supported", + "dev": true, "license": "ISC", "dependencies": { "glob": "^7.1.3" @@ -21809,6 +17180,7 @@ "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", "deprecated": "Glob versions prior to v9 are no longer supported", + "dev": true, "license": "ISC", "dependencies": { "fs.realpath": "^1.0.0", @@ -21839,6 +17211,7 @@ "version": "1.2.0", "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", "integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==", + "dev": true, "funding": [ { "type": "github", @@ -22114,6 +17487,7 @@ "version": "2.4.1", "resolved": "https://registry.npmjs.org/selfsigned/-/selfsigned-2.4.1.tgz", "integrity": "sha512-th5B4L2U+eGLq1TVh7zNRGBapioSORUeymIydxgFpwww9d2qyKvtuPU2jJuHvYAwwqi2Y596QBL3eEqcPEYL8Q==", + "dev": true, "license": "MIT", "dependencies": { "@types/node-forge": "^1.3.0", @@ -22127,6 +17501,7 @@ "version": "6.3.1", "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", + "dev": true, "license": "ISC", "bin": { "semver": "bin/semver.js" @@ -22136,6 +17511,7 @@ "version": "0.19.0", "resolved": "https://registry.npmjs.org/send/-/send-0.19.0.tgz", "integrity": "sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw==", + "dev": true, "license": "MIT", "dependencies": { "debug": "2.6.9", @@ -22160,6 +17536,7 @@ "version": "2.6.9", "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dev": true, "license": "MIT", "dependencies": { "ms": "2.0.0" @@ -22169,27 +17546,19 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", + "dev": true, "license": "MIT" }, "node_modules/send/node_modules/encodeurl": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", + "dev": true, "license": "MIT", "engines": { "node": ">= 0.8" } }, - "node_modules/serialize-error": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/serialize-error/-/serialize-error-2.1.0.tgz", - "integrity": "sha512-ghgmKt5o4Tly5yEG/UJp8qTd0AN7Xalw4XBtDEKP655B699qMEtra1WlXeE6WIvdEG481JvRxULKsInq/iNysw==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/serialize-javascript": { "version": "6.0.2", "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.2.tgz", @@ -22290,6 +17659,7 @@ "version": "1.16.2", "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.16.2.tgz", "integrity": "sha512-VqpjJZKadQB/PEbEwvFdO43Ax5dFBZ2UECszz8bQ7pi7wt//PWe1P6MN7eCnjsatYtBT6EuiClbjSWP2WrIoTw==", + "dev": true, "license": "MIT", "dependencies": { "encodeurl": "~2.0.0", @@ -22301,13 +17671,6 @@ "node": ">= 0.8.0" } }, - "node_modules/set-blocking": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", - "integrity": "sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==", - "license": "ISC", - "peer": true - }, "node_modules/set-function-length": { "version": "1.2.2", "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz", @@ -22344,12 +17707,14 @@ "version": "1.2.0", "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz", "integrity": "sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==", + "dev": true, "license": "ISC" }, "node_modules/shallow-clone": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/shallow-clone/-/shallow-clone-3.0.1.tgz", "integrity": "sha512-/6KqX+GVUdqPuPPd2LxDDxzX6CAbjJehAAOKlNpqqUpAqPM6HeL8f+o3a+JsyGjn2lv0WY8UsTgUJjU9Ok55NA==", + "dev": true, "license": "MIT", "dependencies": { "kind-of": "^6.0.2" @@ -22368,6 +17733,7 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", + "dev": true, "license": "MIT", "dependencies": { "shebang-regex": "^3.0.0" @@ -22380,6 +17746,7 @@ "version": "3.0.0", "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", + "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -22389,6 +17756,7 @@ "version": "1.8.1", "resolved": "https://registry.npmjs.org/shell-quote/-/shell-quote-1.8.1.tgz", "integrity": "sha512-6j1W9l1iAs/4xYBI1SYOVZyFcCis9b4KCLQ8fgAGG07QvzaRLVVRQvAy85yNmmZSjYjg4MWh4gNvlPujU/5LpA==", + "dev": true, "license": "MIT", "funding": { "url": "https://github.com/sponsors/ljharb" @@ -22416,6 +17784,7 @@ "version": "3.0.7", "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==", + "dev": true, "license": "ISC" }, "node_modules/simple-git": { @@ -22438,12 +17807,14 @@ "version": "1.0.5", "resolved": "https://registry.npmjs.org/sisteransi/-/sisteransi-1.0.5.tgz", "integrity": "sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==", + "dev": true, "license": "MIT" }, "node_modules/slash": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==", + "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -22570,6 +17941,7 @@ "version": "0.5.21", "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.21.tgz", "integrity": "sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==", + "dev": true, "license": "MIT", "dependencies": { "buffer-from": "^1.0.0", @@ -22580,6 +17952,7 @@ "version": "0.6.1", "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true, "license": "BSD-3-Clause", "engines": { "node": ">=0.10.0" @@ -22689,63 +18062,11 @@ "node": ">=0.10.0" } }, - "node_modules/stack-utils": { - "version": "2.0.6", - "resolved": "https://registry.npmjs.org/stack-utils/-/stack-utils-2.0.6.tgz", - "integrity": "sha512-XlkWvfIm6RmsWtNJx+uqtKLS8eqFbxUg0ZzLXqY0caEy9l7hruX8IpiDnjsLavoBgqCCR71TqWO8MaXYheJ3RQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "escape-string-regexp": "^2.0.0" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/stack-utils/node_modules/escape-string-regexp": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-2.0.0.tgz", - "integrity": "sha512-UpzcLCXolUWcNu5HtVMHYdXJjArjsF9C0aNnquZYY4uW/Vu0miy5YoWvbV345HauVvcAUnpRuhMMcqTcGOY2+w==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/stackframe": { - "version": "1.3.4", - "resolved": "https://registry.npmjs.org/stackframe/-/stackframe-1.3.4.tgz", - "integrity": "sha512-oeVtt7eWQS+Na6F//S4kJ2K2VbRlS9D43mAlMyVpVWovy9o+jfgH8O9agzANzaiLjclA0oYzUXEM4PurhSUChw==", - "license": "MIT", - "peer": true - }, - "node_modules/stacktrace-parser": { - "version": "0.1.10", - "resolved": "https://registry.npmjs.org/stacktrace-parser/-/stacktrace-parser-0.1.10.tgz", - "integrity": "sha512-KJP1OCML99+8fhOHxwwzyWrlUuVX5GQ0ZpJTd1DFXhdkrvg1szxfHhawXUZ3g9TkXORQd4/WG68jMlQZ2p8wlg==", - "license": "MIT", - "peer": true, - "dependencies": { - "type-fest": "^0.7.1" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/stacktrace-parser/node_modules/type-fest": { - "version": "0.7.1", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.7.1.tgz", - "integrity": "sha512-Ne2YiiGN8bmrmJJEuTWTLJR32nh/JdL1+PSicowtNb0WFpn59GK8/lfD61bVtzguz7b3PBt74nxpv/Pw5po5Rg==", - "license": "(MIT OR CC0-1.0)", - "peer": true, - "engines": { - "node": ">=8" - } - }, "node_modules/statuses": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", "integrity": "sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ==", + "dev": true, "license": "MIT", "engines": { "node": ">= 0.8" @@ -22783,6 +18104,7 @@ "version": "4.2.3", "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", + "dev": true, "license": "MIT", "dependencies": { "emoji-regex": "^8.0.0", @@ -22820,6 +18142,7 @@ "version": "8.0.0", "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", + "dev": true, "license": "MIT" }, "node_modules/string.prototype.includes": { @@ -22924,6 +18247,7 @@ "version": "6.0.1", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dev": true, "license": "MIT", "dependencies": { "ansi-regex": "^5.0.1" @@ -22960,6 +18284,7 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-2.0.0.tgz", "integrity": "sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==", + "dev": true, "license": "MIT", "engines": { "node": ">=6" @@ -22978,13 +18303,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/strnum": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/strnum/-/strnum-1.0.5.tgz", - "integrity": "sha512-J8bbNyKKXl5qYcR36TIO8W3mVGVHrmmxsd5PAItGkmyzwJvybiw2IVq5nqd0i4LSNSkB/sx9VHllbfFdr9k1JA==", - "license": "MIT", - "peer": true - }, "node_modules/style-loader": { "version": "3.3.4", "resolved": "https://registry.npmjs.org/style-loader/-/style-loader-3.3.4.tgz", @@ -23430,13 +18748,6 @@ "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "node_modules/sudo-prompt": { - "version": "9.2.1", - "resolved": "https://registry.npmjs.org/sudo-prompt/-/sudo-prompt-9.2.1.tgz", - "integrity": "sha512-Mu7R0g4ig9TUuGSxJavny5Rv0egCEtpZRNMrZaYS1vxkiIxGiGUwoezU3LazIQ+KE04hTrTfNPgxU5gzi7F5Pw==", - "license": "MIT", - "peer": true - }, "node_modules/supports-color": { "version": "5.5.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", @@ -23490,6 +18801,7 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", + "dev": true, "license": "MIT", "engines": { "node": ">= 0.4" @@ -23685,55 +18997,6 @@ "node": ">=0.6" } }, - "node_modules/temp": { - "version": "0.8.4", - "resolved": "https://registry.npmjs.org/temp/-/temp-0.8.4.tgz", - "integrity": "sha512-s0ZZzd0BzYv5tLSptZooSjK8oj6C+c19p7Vqta9+6NPOf7r+fxq0cJe6/oN4LTC79sy5NY8ucOJNgwsKCSbfqg==", - "license": "MIT", - "peer": true, - "dependencies": { - "rimraf": "~2.6.2" - }, - "engines": { - "node": ">=6.0.0" - } - }, - "node_modules/temp/node_modules/glob": { - "version": "7.2.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", - "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", - "deprecated": "Glob versions prior to v9 are no longer supported", - "license": "ISC", - "peer": true, - "dependencies": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.1.1", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - }, - "engines": { - "node": "*" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/temp/node_modules/rimraf": { - "version": "2.6.3", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz", - "integrity": "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==", - "deprecated": "Rimraf versions prior to v4 are no longer supported", - "license": "ISC", - "peer": true, - "dependencies": { - "glob": "^7.1.3" - }, - "bin": { - "rimraf": "bin.js" - } - }, "node_modules/terminal-link": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/terminal-link/-/terminal-link-2.1.1.tgz", @@ -23755,6 +19018,7 @@ "version": "5.33.0", "resolved": "https://registry.npmjs.org/terser/-/terser-5.33.0.tgz", "integrity": "sha512-JuPVaB7s1gdFKPKTelwUyRq5Sid2A3Gko2S0PncwdBq7kN9Ti9HPWDQ06MPsEDGsZeVESjKEnyGy68quBk1w6g==", + "dev": true, "license": "BSD-2-Clause", "dependencies": { "@jridgewell/source-map": "^0.3.3", @@ -23827,6 +19091,7 @@ "version": "2.20.3", "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", + "dev": true, "license": "MIT" }, "node_modules/text-table": { @@ -23836,13 +19101,6 @@ "dev": true, "license": "MIT" }, - "node_modules/throat": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/throat/-/throat-5.0.0.tgz", - "integrity": "sha512-fcwX4mndzpLQKBS1DVYhGAcYaYt7vsHNIvQV+WXMvnow5cgjPphq5CaayLaGsjRdSCKZFNGt7/GYAuXaNOiYCA==", - "license": "MIT", - "peer": true - }, "node_modules/throttleit": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/throttleit/-/throttleit-1.0.1.tgz", @@ -23860,17 +19118,6 @@ "dev": true, "license": "MIT" }, - "node_modules/through2": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.5.tgz", - "integrity": "sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ==", - "license": "MIT", - "peer": true, - "dependencies": { - "readable-stream": "~2.3.6", - "xtend": "~4.0.1" - } - }, "node_modules/thunky": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/thunky/-/thunky-1.1.0.tgz", @@ -23900,17 +19147,11 @@ "node": ">=14.14" } }, - "node_modules/tmpl": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/tmpl/-/tmpl-1.0.5.tgz", - "integrity": "sha512-3f0uOEAQwIqGuWW2MVzYg8fV/QNnc/IpuJNG837rLuczAaLVHslWHZQj4IGiEl5Hs3kkbhwL9Ab7Hrsmuj+Smw==", - "license": "BSD-3-Clause", - "peer": true - }, "node_modules/to-regex-range": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "dev": true, "license": "MIT", "dependencies": { "is-number": "^7.0.0" @@ -23923,6 +19164,7 @@ "version": "1.0.1", "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.1.tgz", "integrity": "sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA==", + "dev": true, "license": "MIT", "engines": { "node": ">=0.6" @@ -23954,13 +19196,6 @@ "node": ">= 4.0.0" } }, - "node_modules/tr46": { - "version": "0.0.3", - "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", - "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==", - "license": "MIT", - "peer": true - }, "node_modules/tsconfig-paths": { "version": "3.15.0", "resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.15.0.tgz", @@ -24049,16 +19284,6 @@ "node": ">= 0.8.0" } }, - "node_modules/type-detect": { - "version": "4.0.8", - "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", - "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=4" - } - }, "node_modules/type-fest": { "version": "0.21.3", "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.21.3.tgz", @@ -24166,21 +19391,6 @@ "dev": true, "license": "MIT" }, - "node_modules/typescript": { - "version": "5.6.2", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.6.2.tgz", - "integrity": "sha512-NW8ByodCSNCwZeghjN3o+JX5OFH0Ojg6sadjEKY4huZ52TqbJTJnDo5+Tw98lSy63NZvi4n+ez5m2u5d4PkZyw==", - "devOptional": true, - "license": "Apache-2.0", - "peer": true, - "bin": { - "tsc": "bin/tsc", - "tsserver": "bin/tsserver" - }, - "engines": { - "node": ">=14.17" - } - }, "node_modules/unbox-primitive": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz", @@ -24200,12 +19410,14 @@ "version": "6.19.8", "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.19.8.tgz", "integrity": "sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw==", + "dev": true, "license": "MIT" }, "node_modules/unicode-canonical-property-names-ecmascript": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-2.0.1.tgz", "integrity": "sha512-dA8WbNeb2a6oQzAQ55YlT5vQAWGV9WXOsi3SskE3bcCdM0P4SDd+24zS/OCacdRq5BkdsRj9q3Pg6YyQoxIGqg==", + "dev": true, "license": "MIT", "engines": { "node": ">=4" @@ -24215,6 +19427,7 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/unicode-match-property-ecmascript/-/unicode-match-property-ecmascript-2.0.0.tgz", "integrity": "sha512-5kaZCrbp5mmbz5ulBkDkbY0SsPOjKqVS35VpL9ulMPfSl0J0Xsm+9Evphv9CoIZFwre7aJoa94AY6seMKGVN5Q==", + "dev": true, "license": "MIT", "dependencies": { "unicode-canonical-property-names-ecmascript": "^2.0.0", @@ -24228,6 +19441,7 @@ "version": "2.2.0", "resolved": "https://registry.npmjs.org/unicode-match-property-value-ecmascript/-/unicode-match-property-value-ecmascript-2.2.0.tgz", "integrity": "sha512-4IehN3V/+kkr5YeSSDDQG8QLqO26XpL2XP3GQtqwlT/QYSECAwFztxVHjlbh0+gjJ3XmNLS0zDsbgs9jWKExLg==", + "dev": true, "license": "MIT", "engines": { "node": ">=4" @@ -24237,6 +19451,7 @@ "version": "2.1.0", "resolved": "https://registry.npmjs.org/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-2.1.0.tgz", "integrity": "sha512-6t3foTQI9qne+OZoVQB/8x8rk2k1eVy1gRXhV3oFQ5T6R1dqQ1xtin3XqSlx3+ATBkliTaR/hHyJBm+LVPNM8w==", + "dev": true, "license": "MIT", "engines": { "node": ">=4" @@ -24256,6 +19471,7 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", "integrity": "sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ==", + "dev": true, "license": "MIT", "engines": { "node": ">= 0.8" @@ -24275,6 +19491,7 @@ "version": "1.1.3", "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.1.3.tgz", "integrity": "sha512-UxhIZQ+QInVdunkDAaiazvvT/+fXL5Osr0JZlJulepYu6Jd7qJtDZjlur0emRlT71EN3ScPoE7gvsuIKKNavKw==", + "dev": true, "funding": [ { "type": "opencollective", @@ -24341,6 +19558,7 @@ "version": "1.0.1", "resolved": "https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz", "integrity": "sha512-pMZTvIkT1d+TFGvDOqodOclx0QWkkgi6Tdoa8gC8ffGAAqz9pzPTZWAybbsHHoED/ztMtkv/VoYTYyShUn81hA==", + "dev": true, "license": "MIT", "engines": { "node": ">= 0.4.0" @@ -24360,6 +19578,7 @@ "version": "1.1.2", "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", "integrity": "sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg==", + "dev": true, "license": "MIT", "engines": { "node": ">= 0.8" @@ -24413,23 +19632,6 @@ "source-map": "^0.5.1" } }, - "node_modules/vlq": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/vlq/-/vlq-1.0.1.tgz", - "integrity": "sha512-gQpnTgkubC6hQgdIcRdYGDSDc+SaujOdyesZQMv6JlfQee/9Mp0Qhnys6WxDWvQnL5WZdT7o2Ul187aSt0Rq+w==", - "license": "MIT", - "peer": true - }, - "node_modules/walker": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/walker/-/walker-1.0.8.tgz", - "integrity": "sha512-ts/8E8l5b7kY0vlWLewOkDXMmPdLcVV4GmOQLyxuSswIJsweeFZtAsMF7k1Nszz+TYBQrlYRmzOnr398y1JemQ==", - "license": "Apache-2.0", - "peer": true, - "dependencies": { - "makeerror": "1.0.12" - } - }, "node_modules/watchpack": { "version": "2.4.2", "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.2.tgz", @@ -24458,18 +19660,12 @@ "version": "1.0.1", "resolved": "https://registry.npmjs.org/wcwidth/-/wcwidth-1.0.1.tgz", "integrity": "sha512-XHPEwS0q6TaxcvG85+8EYkbiCux2XtWG2mkc47Ng2A77BQu9+DqIOJldST4HgPkuea7dvKSj5VgX3P1d4rW8Tg==", + "dev": true, "license": "MIT", "dependencies": { "defaults": "^1.0.3" } }, - "node_modules/webidl-conversions": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", - "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==", - "license": "BSD-2-Clause", - "peer": true - }, "node_modules/webpack": { "version": "5.94.0", "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.94.0.tgz", @@ -24780,24 +19976,6 @@ "node": ">=0.8.0" } }, - "node_modules/whatwg-fetch": { - "version": "3.6.20", - "resolved": "https://registry.npmjs.org/whatwg-fetch/-/whatwg-fetch-3.6.20.tgz", - "integrity": "sha512-EqhiFU6daOA8kpjOWTL0olhVOF3i7OrFzSYiGsEMB8GcXS+RrzauAERX65xMeNWVqxA6HXH2m69Z9LaKKdisfg==", - "license": "MIT", - "peer": true - }, - "node_modules/whatwg-url": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", - "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==", - "license": "MIT", - "peer": true, - "dependencies": { - "tr46": "~0.0.3", - "webidl-conversions": "^3.0.0" - } - }, "node_modules/whatwg-url-without-unicode": { "version": "8.0.0-3", "resolved": "https://registry.npmjs.org/whatwg-url-without-unicode/-/whatwg-url-without-unicode-8.0.0-3.tgz", @@ -24825,6 +20003,7 @@ "version": "2.0.2", "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "dev": true, "license": "ISC", "dependencies": { "isexe": "^2.0.0" @@ -24898,13 +20077,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/which-module": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.1.tgz", - "integrity": "sha512-iBdZ57RDvnOR9AGBhML2vFZf7h8vmBjhoaZqODJBFWHVtKkDmKuHai3cx5PgVMrX5YDNp27AofYbAwctSS+vhQ==", - "license": "ISC", - "peer": true - }, "node_modules/which-typed-array": { "version": "1.1.15", "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.15.tgz", @@ -25078,20 +20250,9 @@ "version": "1.0.2", "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==", + "dev": true, "license": "ISC" }, - "node_modules/write-file-atomic": { - "version": "2.4.3", - "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-2.4.3.tgz", - "integrity": "sha512-GaETH5wwsX+GcnzhPgKcKjJ6M2Cq3/iZp1WyY/X1CSqrW+jVNM9Y7D8EC2sM4ZG/V8wZlSniJnCKWPmBYAucRQ==", - "license": "ISC", - "peer": true, - "dependencies": { - "graceful-fs": "^4.1.11", - "imurmurhash": "^0.1.4", - "signal-exit": "^3.0.2" - } - }, "node_modules/ws": { "version": "8.18.0", "resolved": "https://registry.npmjs.org/ws/-/ws-8.18.0.tgz", @@ -25114,20 +20275,11 @@ } } }, - "node_modules/xtend": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", - "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==", - "license": "MIT", - "peer": true, - "engines": { - "node": ">=0.4" - } - }, "node_modules/y18n": { "version": "5.0.8", "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==", + "dev": true, "license": "ISC", "engines": { "node": ">=10" @@ -25137,12 +20289,14 @@ "version": "3.1.1", "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz", "integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==", + "dev": true, "license": "ISC" }, "node_modules/yaml": { "version": "2.5.1", "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.5.1.tgz", "integrity": "sha512-bLQOjaX/ADgQ20isPJRvF0iRUHIxVhYvr53Of7wGcWlO2jvtUlH5m87DsmulFVxRpNLOnI4tB6p/oh8D7kpn9Q==", + "dev": true, "license": "ISC", "bin": { "yaml": "bin.mjs" @@ -25155,6 +20309,7 @@ "version": "17.7.2", "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz", "integrity": "sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==", + "dev": true, "license": "MIT", "dependencies": { "cliui": "^8.0.1", @@ -25173,6 +20328,7 @@ "version": "21.1.1", "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==", + "dev": true, "license": "ISC", "engines": { "node": ">=12" @@ -25193,6 +20349,7 @@ "version": "0.1.0", "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==", + "dev": true, "license": "MIT", "engines": { "node": ">=10" diff --git a/package.json b/package.json index e3debd2ce4..d9647690a0 100644 --- a/package.json +++ b/package.json @@ -40,6 +40,7 @@ "classnames": "^2.2.6", "google-closure-compiler": "^20240317.0.0", "npm": "^10.5.2", + "prop-types": "^15.8.1", "react": "^16.13.1", "react-dom": "^16.13.1", "styled-components": "^5.3.5" @@ -55,6 +56,7 @@ "@svgr/webpack": "^8.1.0", "@wordpress/babel-plugin-makepot": "^5.25.0", "@wordpress/babel-preset-default": "^7.25.0", + "@wordpress/browserslist-config": "^6.29.0", "@wordpress/env": "^9.8.0", "@wordpress/eslint-plugin": "^15.1.0", "@wordpress/stylelint-config": "^23.14.0", @@ -94,9 +96,5 @@ "type": "git", "url": "https://github.com/Strategy11/formidable-forms.git" }, - "homepage": "https://formidableforms.com", - "browserslist": [ - "last 2 versions", - "not dead" - ] + "homepage": "https://formidableforms.com" } diff --git a/square/js/action.js b/square/js/action.js index e252866192..ca91e9906a 100644 --- a/square/js/action.js +++ b/square/js/action.js @@ -53,7 +53,7 @@ function onToggleSub() { const target = this; setTimeout( function() { - const settings = target.closest( '.frm_form_action_settings' ); + const settings = target.closest( '.frm_form_action_settings' ); const squareIsActive = settings.querySelector( '[name*="[post_content][gateway]"][value="square"]' ).checked; settings.querySelectorAll( '.frm_trans_sub_opts' ).forEach( @@ -152,7 +152,7 @@ if ( option ) { if ( 'square' === gateway ) { - currencySetting.value = option.value; + currencySetting.value = option.value; currencySetting.disabled = true; } else { currencySetting.disabled = false; @@ -165,7 +165,7 @@ // Option didn't exist yet, so add it. if ( 'square' === gateway ) { option = document.createElement( 'option' ); - option.value = 'square'; + option.value = 'square'; option.textContent = 'Use Square Merchant Currency'; option.classList.add( 'square-currency' ); currencySetting.appendChild( option ); diff --git a/square/js/frontend.js b/square/js/frontend.js index f02cfac04f..38d91df0ae 100644 --- a/square/js/frontend.js +++ b/square/js/frontend.js @@ -3,13 +3,13 @@ return; } - const appId = frmSquareVars.appId; + const appId = frmSquareVars.appId; const locationId = frmSquareVars.locationId; // Track the state of the Square card element let squareCardElementIsComplete = false; - let thisForm = null; - let running = 0; + let thisForm = null; + let running = 0; let cardGlobal; @@ -29,17 +29,17 @@ return; } - const card = await payments.card(); + const card = await payments.card(); const cardStyle = frmSquareVars.style; await card.attach( '.frm-card-element' ); card.configure( { style: cardStyle } ); // Add event listener to track when the card form is valid - card.addEventListener( 'focusClassRemoved', ( e ) => { + card.addEventListener( 'focusClassRemoved', e => { const field = e.detail.field; const value = e.detail.currentState.isCompletelyValid; - cardFields[field] = value; + cardFields[ field ] = value; // Check if all fields are valid squareCardElementIsComplete = Object.values( cardFields ).every( item => item === true ); @@ -69,10 +69,10 @@ frmFrontForm.removeSubmitLoading( jQuery( thisForm ), 'enable', 0 ); // Trigger custom event for other scripts to hook into - const event = new CustomEvent( 'frmSquareLiteEnableSubmit', { + const event = new CustomEvent( 'frmSquareLiteEnableSubmit', { detail: { form: thisForm } - }); - document.dispatchEvent(event); + } ); + document.dispatchEvent( event ); } /** @@ -85,19 +85,19 @@ jQuery( form ).find( 'input[type="submit"],input[type="button"],button[type="submit"]' ).not( '.frm_prev_page' ).attr( 'disabled', 'disabled' ); // Trigger custom event for other scripts to hook into - const event = new CustomEvent( 'frmSquareLiteDisableSubmit', { + const event = new CustomEvent( 'frmSquareLiteDisableSubmit', { detail: { form: form } - }); + } ); document.dispatchEvent( event ); } async function createPayment( event, token, verificationToken ) { - const tokenInput = document.createElement('input'); + const tokenInput = document.createElement( 'input' ); tokenInput.type = 'hidden'; tokenInput.value = token; - tokenInput.setAttribute('name', 'square-token'); + tokenInput.setAttribute( 'name', 'square-token' ); - const verificationInput = document.createElement('input'); + const verificationInput = document.createElement( 'input' ); verificationInput.type = 'hidden'; verificationInput.value = verificationToken; verificationInput.setAttribute( 'name', 'square-verification-token' ); @@ -123,9 +123,9 @@ return tokenResult.token; } - let errorMessage = `Tokenization failed with status: ${tokenResult.status}`; + let errorMessage = `Tokenization failed with status: ${ tokenResult.status }`; if ( tokenResult.errors ) { - errorMessage += ` and errors: ${JSON.stringify( tokenResult.errors )}`; + errorMessage += ` and errors: ${ JSON.stringify( tokenResult.errors ) }`; } throw new Error( errorMessage ); @@ -210,7 +210,7 @@ } return false; - }); + } ); } } @@ -219,10 +219,10 @@ // Square requires HTTPS to work. payments = window.Square.payments( appId, locationId ); } catch ( e ) { - const statusContainer = document.querySelector( '.frm-card-errors' ); + const statusContainer = document.querySelector( '.frm-card-errors' ); statusContainer.classList.add( 'missing-credentials', 'frm_error' ); statusContainer.style.visibility = 'visible'; - statusContainer.textContent = e.message; + statusContainer.textContent = e.message; return; } @@ -238,15 +238,13 @@ /** * @param {Object} $form - * @return {Boolean} false if there are errors. + * @return {boolean} false if there are errors. */ function validateFormSubmit( $form ) { - var errors, keys; - - errors = frmFrontForm.validateFormSubmit( $form ); - keys = Object.keys( errors ); + const errors = frmFrontForm.validateFormSubmit( $form ); + const keys = Object.keys( errors ); - if ( 1 === keys.length && errors[ keys[0] ] === '' ) { + if ( 1 === keys.length && errors[ keys[ 0 ] ] === '' ) { // Pop the empty error that gets added by invisible recaptcha. keys.pop(); } @@ -266,7 +264,7 @@ disableSubmit( thisForm ); } - const token = await tokenize( card ); + const token = await tokenize( card ); const verificationToken = await verifyBuyer( payments, token ); await createPayment( event, token, verificationToken ); @@ -286,7 +284,7 @@ } } - document.addEventListener( 'DOMContentLoaded', async function () { + document.addEventListener( 'DOMContentLoaded', async function() { if ( ! window.Square ) { console.error( 'Square.js failed to load properly' ); return; @@ -297,5 +295,5 @@ jQuery( document ).on( 'frmPageChanged', function() { squareInit(); } ); - }); + } ); }() ); diff --git a/square/js/settings.js b/square/js/settings.js index c2e447990b..936f74edab 100644 --- a/square/js/settings.js +++ b/square/js/settings.js @@ -50,7 +50,7 @@ function getSquareTestSetupModalContent() { const signUpUrl = 'https://app.squareup.com/signup/'; - const confirmationTrigger = frmDom.a({ id: 'frm_confirm_square_test_modal', text: 'here', target: '_blank' }); + const confirmationTrigger = frmDom.a( { id: 'frm_confirm_square_test_modal', text: 'here', target: '_blank' } ); confirmationTrigger.addEventListener( 'click', function( e ) { e.preventDefault(); const modal = document.getElementById( 'frm_square_test_setup_modal' ); @@ -72,8 +72,8 @@ frmDom.tag( 'div', { className: 'frm_note_style', text: 'Important! If you skip these initial steps, you will get stuck on a white screen.' } ), frmDom.tag( 'ol', { children: [ - frmDom.span( { children: [ 'Click ', frmDom.a({ href: signUpUrl, text: 'here' }), ' to create a Square account if you do not already have one.' ] } ), - frmDom.span( { children: [ 'Click ', frmDom.a({ href: 'https://developer.squareup.com/console/en/sandbox-test-accounts', text: 'here', target: '_blank' }), ' and create a Square sandbox test account.' ] } ), + frmDom.span( { children: [ 'Click ', frmDom.a( { href: signUpUrl, text: 'here' } ), ' to create a Square account if you do not already have one.' ] } ), + frmDom.span( { children: [ 'Click ', frmDom.a( { href: 'https://developer.squareup.com/console/en/sandbox-test-accounts', text: 'here', target: '_blank' } ), ' and create a Square sandbox test account.' ] } ), 'Click "Square Dashboard" for the new sandbox test account. Leave the tab open and return to this page.', frmDom.span( { children: [ 'Click ', confirmationTrigger, '. You will be taken to Square to allow the required permissions for handling payments.' ] } ), ].map( diff --git a/stripe/js/connect_settings.js b/stripe/js/connect_settings.js index 0df1b9d04e..6bd2958e6a 100644 --- a/stripe/js/connect_settings.js +++ b/stripe/js/connect_settings.js @@ -7,7 +7,7 @@ } function renderStripeConnectSettingsButton() { - var container = document.getElementById( 'frm_strp_settings_container' ); + const container = document.getElementById( 'frm_strp_settings_container' ); if ( null !== container ) { postAjax( { @@ -24,12 +24,12 @@ jQuery( document ).on( 'click', selector, function( event ) { event.preventDefault(); callback( this ); - }); + } ); } function handleStripeDisconnectClick( trigger ) { const testMode = isTriggerInTestMode( trigger ); - const spinner = frmDom.span({ className: 'frm-wait frm_visible_spinner' }); + const spinner = frmDom.span( { className: 'frm-wait frm_visible_spinner' } ); spinner.style.margin = 0; // The default 20px margin causes the spinner to look bad. trigger.replaceWith( spinner ); @@ -73,7 +73,7 @@ } function strpSettingsAjaxRequest( action, success, testMode ) { - var data = { + const data = { action: action, testMode: testMode, nonce: frmGlobal.nonce @@ -82,18 +82,16 @@ } function postAjax( data, success ) { - var xmlHttp, params; - - xmlHttp = new XMLHttpRequest(); - params = typeof data === 'string' ? data : Object.keys( data ).map( + const xmlHttp = new XMLHttpRequest(); + const params = typeof data === 'string' ? data : Object.keys( data ).map( function( k ) { - return encodeURIComponent( k ) + '=' + encodeURIComponent( data[ k ]); + return encodeURIComponent( k ) + '=' + encodeURIComponent( data[ k ] ); } ).join( '&' ); xmlHttp.open( 'post', ajaxurl, true ); xmlHttp.onreadystatechange = function() { - var response; + let response; if ( xmlHttp.readyState > 3 && xmlHttp.status == 200 ) { response = xmlHttp.responseText; if ( response !== '' ) { diff --git a/stripe/js/frmstrp.js b/stripe/js/frmstrp.js index 68dbf957e5..4c2f950e02 100644 --- a/stripe/js/frmstrp.js +++ b/stripe/js/frmstrp.js @@ -1,5 +1,5 @@ ( function() { - var thisForm = false, + let thisForm = false, formID = 0, event = false, frmstripe, @@ -7,10 +7,9 @@ elements, isStripeLink = false, linkAuthenticationElementIsComplete = false, - stripeLinkElementIsComplete = false, - triggerCustomEvent; + stripeLinkElementIsComplete = false; - triggerCustomEvent = function( el, eventName, data ) { + const triggerCustomEvent = function( el, eventName, data ) { frmFrontForm.triggerCustomEvent( el, eventName, data ); }; @@ -19,7 +18,7 @@ */ function validateForm( e ) { thisForm = this; - formID = jQuery( thisForm ).find( 'input[name="form_id"]' ).val(); + formID = jQuery( thisForm ).find( 'input[name="form_id"]' ).val(); if ( shouldProcessForm() ) { e.preventDefault(); @@ -34,11 +33,9 @@ } /** - * @returns {Boolean} + * @return {boolean} True if form should be processed by Stripe. */ function shouldProcessForm() { - var ccField; - if ( formID != frm_stripe_vars.form_id ) { return false; } @@ -47,7 +44,7 @@ return false; } - ccField = jQuery( thisForm ).find( '.frm-card-element' ); + const ccField = jQuery( thisForm ).find( '.frm-card-element' ); if ( ccField.length && ! ccField.is( ':hidden' ) ) { return true; } @@ -56,10 +53,10 @@ } /** - * @returns {Boolean} + * @return {boolean} True if current action type should be processed. */ function currentActionTypeShouldBeProcessed() { - var action = jQuery( thisForm ).find( 'input[name="frm_action"]' ).val(); + const action = jQuery( thisForm ).find( 'input[name="frm_action"]' ).val(); if ( 'object' !== typeof window.frmProForm || 'function' !== typeof window.frmProForm.currentActionTypeShouldBeProcessed ) { return 'create' === action; @@ -74,9 +71,7 @@ } function processForm() { - var $form, meta; - - $form = jQuery( thisForm ); + const $form = jQuery( thisForm ); // Run javascript validation. $form.addClass( 'frm_js_validate' ); @@ -86,7 +81,7 @@ } frmFrontForm.showSubmitLoading( $form ); - meta = addName( $form ); + const meta = addName( $form ); if ( 'object' === typeof window.frmProForm && 'function' === typeof window.frmProForm.addAddressMeta ) { window.frmProForm.addAddressMeta( $form, meta ); @@ -108,8 +103,8 @@ * @since 6.5, introduced in v3.0 of the Stripe add on. * * @param {Element} object - * @param {Object} meta - * @returns {void} + * @param {Object} meta + * @return {void} */ function stripeLinkSubmit( object, meta ) { object.classList.add( 'frm_trigger_event_on_submit', 'frm_ajax_submit' ); @@ -119,22 +114,18 @@ submitForm(); function confirmPayment( event ) { - var params, confirmFunction; - if ( ! checkEventDataForError( event ) ) { return; } - var params, confirmFunction; - window.onpageshow = function( event ) { // Force the form to reload on back button after submitting. - if ( event.persisted || ( window.performance && window.performance.getEntriesByType( 'navigation' )[0].type === 'back_forward' ) ) { + if ( event.persisted || ( window.performance && window.performance.getEntriesByType( 'navigation' )[ 0 ].type === 'back_forward' ) ) { window.location.reload(); } }; - params = { + let params = { elements: elements, confirmParams: { return_url: getReturnUrl() @@ -145,13 +136,13 @@ params = frmProForm.beforeConfirmPayment( params, meta ); } - confirmFunction = isRecurring() ? 'confirmSetup' : 'confirmPayment'; + const confirmFunction = isRecurring() ? 'confirmSetup' : 'confirmPayment'; frmstripe[ confirmFunction ]( params ).then( handleConfirmPromise ); } function getReturnUrl() { - var url = new URL( frm_stripe_vars.ajax ); + const url = new URL( frm_stripe_vars.ajax ); // eslint-disable-line compat/compat url.searchParams.append( 'action', 'frmstrplinkreturn' ); return url.toString(); @@ -164,19 +155,17 @@ } function handleConfirmPaymentError( error ) { - var fieldset, cardErrors; - running--; enableSubmit(); - fieldset = jQuery( object ).find( '.frm_form_field' ); + const fieldset = jQuery( object ).find( '.frm_form_field' ); fieldset.removeClass( 'frm_doing_ajax' ); object.classList.remove( 'frm_loading_form' ); // Don't show validation_error here as those are added automatically to the email and postal code fields, etc. if ( 'card_error' === error.type || 'invalid_request_error' === error.type || 'form_submit_error' === error.type ) { - cardErrors = object.querySelector( '.frm-card-errors' ); + const cardErrors = object.querySelector( '.frm-card-errors' ); if ( cardErrors ) { cardErrors.textContent = error.message; } @@ -190,40 +179,38 @@ * @since 6.10 * * @param {CustomEvent} event - * @returns {boolean} + * @return {boolean} True if no errors found in event data. */ function checkEventDataForError( event ) { - var element, error; - if ( ! event.frmData || ! event.frmData.content.length || -1 === event.frmData.content.indexOf( '