From 3aab0cb05212434cf63b1c6f1f1c9d43d58312e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anderson=20Gr=C3=BCdtner=20Martins?= Date: Mon, 9 Dec 2024 14:14:20 -0300 Subject: [PATCH] Release 4.2.0 (#1073) * Do not remove post meta when action is disabled, #1053 * Update cross-spawn fixing a security warning (on dev environments only) * Update node-fetch addressing a security (on dev environments only) * Update micromatch addressing a security issue (on dev environment only( * Update cookie addressing a security issue (on dev environmrnts) * Prevent DOM text reinterpreted as HTML * Update the changelog * Move notification settings to a specific tab, #190 * Allow users to change metabox name, #227 * Update the changelog * Fix error when a trigger node type is not found * Fix php warning: PHP Deprecated: ltrim(): Passing null to parameter #1 PHP Deprecated: ltrim(): Passing null to parameter #1 ($string) of type string is deprecated in /Users/andersonmartins/LocalSites/future-free/app/public/wp-includes/formatting.php on line 4467 * Update the changelog * Fix DB error when deleting orphan scheduled steps, #1060 * Fix warning about method get_data not existent * Update minified js scritps * Add global.execution_id variable for the workflow execution, #1061 * 704 export import (#1062) * Implement workflow exporting feature * Add settings to the exported backup * Split the backup window in a component * Fix error on default tab * Fix file upload * Adjust the notices * Adjust UI and create new component * Improve code splitting tab into new components * Rename folders * Implement export and import for general and notifications * Allow to export and import display settings * Allow to import advanced settings * Allow to import post types settings * Fix export and import actions to workflow screenshots * Fix displaced labels, #1057 * Translate the user roles in the settings page, #1050 * Add * to indicate a required field on post query, #974 * Update language files * Update js files * Bump version to 4.2.0-beta.1 * Update the changelgo * Change backup page name to Export / Import * Remove extra chars in backup screen, #1063 * Improve error handling when importing a backup file * Fix error on importing JSON missing some data, #1065 * Add setting to enable/disable the screenshot feature, #1066 * Add custom data field to Ray Debug step, #1067 * Replace input field with text area on log message field, #1068 * Add support to metadata in the variables resolvers, #1069, #939 Add more space for subject and custom email address on send email step. * Set default value to the Email Recipient on Send Email step, #1071 * Add "meta" property on variables schema * Add site ID to the site data type schema * Adjust hooks on settings to implemenet export/import on Pro * Add general filters and actions for export/import * Pass the selected settings to the filter * Update the changelog * Bump version to 4.2.0-beta.2 * Update the js files * Update language files * Make sure to reply only json in the export/import api --- CHANGELOG.md | 35 + assets/js/777.min.js | 1 + assets/js/backupPanel.js | 1406 +++++++++++++++++ assets/js/backupPanel.min.js | 2 + assets/js/backupPanel.min.js.LICENSE.txt | 1 + assets/js/blockEditor.js | 2 +- assets/js/blockEditor.min.js | 2 +- assets/js/bulkEdit.js | 2 +- assets/js/bulkEdit.min.js | 2 +- assets/js/classicEditor.js | 2 +- assets/js/classicEditor.min.js | 2 +- assets/js/futureActions.js | 3 +- assets/js/futureActions.min.js | 2 +- assets/js/quickEdit.js | 2 +- assets/js/quickEdit.min.js | 2 +- assets/js/settingsGeneral.js | 2 +- assets/js/settingsPostTypes.js | 2 +- ...-node_modules_html-to-image_es_index_js.js | 1070 +++++++++++++ assets/js/workflowEditor.js | 1286 ++------------- assets/js/workflowEditor.min.js | 2 +- .../js/workflowManualSelectionBlockEditor.js | 476 +++++- .../workflowManualSelectionBlockEditor.min.js | 2 +- .../workflowManualSelectionClassicEditor.js | 476 +++++- ...orkflowManualSelectionClassicEditor.min.js | 2 +- assets/js/workflowManualSelectionQuickEdit.js | 7 +- .../workflowManualSelectionQuickEdit.min.js | 2 +- .../backup-panel/components/backup-panel.jsx | 36 + .../components/fieldset/index.jsx | 5 + .../components/selectable-list/index.jsx | 51 + .../components/settings-tab/index.jsx | 17 + .../components/tabbed-window/index.jsx | 97 ++ .../components/tabs-content/export.jsx | 214 +++ .../components/tabs-content/import.jsx | 159 ++ assets/jsx/backup-panel/css/general.css | 70 + assets/jsx/backup-panel/index.jsx | 13 + assets/jsx/components/FutureActionPanel.jsx | 2 +- assets/jsx/future-actions.jsx | 4 +- .../components/data-fields/date-offset.jsx | 2 +- .../components/data-fields/debug-data.jsx | 16 +- .../data-fields/email-recipient.jsx | 9 +- .../components/data-fields/post-query.jsx | 19 +- .../components/data-types/post.jsx | 7 +- .../components/data-types/site.jsx | 10 + .../components/data-types/user.jsx | 7 +- .../components/data-types/workflow.jsx | 7 +- .../components/layout/header.jsx | 4 - .../workflow-publish-button/index.jsx | 18 +- .../workflow-save-draft-button/index.jsx | 13 +- .../components/workflow-store/actions.jsx | 10 +- .../components/workflow-store/reducer.jsx | 9 + .../components/workflow-store/selectors.jsx | 55 +- .../workflow-switch-to-draft-button/index.jsx | 12 +- .../block-editor/css/style.css | 3 + .../block-editor/index.jsx | 2 + .../classic-editor/css/style.css | 3 + .../classic-editor/index.jsx | 1 + .../quick-edit/css/style.css | 5 + composer.json | 3 - composer.lock | 540 +++---- dev-workspace/scripts/lang-constants.sh | 2 +- dev-workspace/scripts/lang-make-pot-js.sh | 2 +- docs/translate-js-scripts.md | 19 + ...t-expirator-es_ES-future_backup_panel.json | 1 + ...pirator-es_ES-future_backup_panel.l10n.php | 2 + ...ost-expirator-es_ES-future_backup_panel.po | 16 + languages/post-expirator-es_ES.l10n.php | 2 +- languages/post-expirator-es_ES.mo | Bin 45800 -> 45800 bytes languages/post-expirator-es_ES.po | 4 +- ...t-expirator-fr_FR-future_backup_panel.json | 1 + ...pirator-fr_FR-future_backup_panel.l10n.php | 2 + ...ost-expirator-fr_FR-future_backup_panel.po | 16 + languages/post-expirator-fr_FR.l10n.php | 2 +- languages/post-expirator-fr_FR.mo | Bin 47501 -> 47501 bytes languages/post-expirator-fr_FR.po | 4 +- .../post-expirator-future_backup_panel.pot | 131 ++ ...xpirator-future_workflow_editor_script.pot | 85 +- ...t-expirator-it_IT-future_backup_panel.json | 1 + ...pirator-it_IT-future_backup_panel.l10n.php | 2 + ...ost-expirator-it_IT-future_backup_panel.po | 16 + languages/post-expirator-it_IT.l10n.php | 2 +- languages/post-expirator-it_IT.mo | Bin 45405 -> 45405 bytes languages/post-expirator-it_IT.po | 4 +- ...t-expirator-nl_NL-future_backup_panel.json | 1 + ...pirator-nl_NL-future_backup_panel.l10n.php | 2 + ...ost-expirator-nl_NL-future_backup_panel.po | 16 + ...t-expirator-pt_BR-future_backup_panel.json | 1 + ...pirator-pt_BR-future_backup_panel.l10n.php | 2 + ...ost-expirator-pt_BR-future_backup_panel.po | 16 + languages/post-expirator-pt_BR.l10n.php | 2 +- languages/post-expirator-pt_BR.mo | Bin 44585 -> 44585 bytes languages/post-expirator-pt_BR.po | 6 +- languages/post-expirator.pot | 556 ++++--- legacy/classes/Display.class.php | 105 +- lib/composer.lock | 56 +- lib/vendor/composer/installed.php | 4 +- package.json | 8 +- post-expirator.php | 4 +- readme.txt | 37 +- services.php | 18 +- src/Core/DI/ServicesAbstract.php | 2 + .../Backup/Controllers/BackupAdminPage.php | 138 ++ .../Backup/Controllers/BackupRestApi.php | 442 ++++++ src/Modules/Backup/HooksAbstract.php | 11 + src/Modules/Backup/Module.php | 62 + src/Modules/Backup/Views/debug-panel.php | 33 + .../Controllers/BlockEditorController.php | 8 +- .../Controllers/BulkEditController.php | 8 +- .../Controllers/ClassicEditorController.php | 12 +- .../Controllers/QuickEditController.php | 18 +- src/Modules/Expirator/ExpirationScheduler.php | 6 +- .../Expirator/Models/ExpirablePostModel.php | 5 + src/Modules/Expirator/Module.php | 3 +- .../Tables/ScheduledActionsTable.php | 10 +- .../Settings/Controllers/Controller.php | 1 + src/Modules/Settings/HooksAbstract.php | 10 + src/Modules/Settings/SettingsFacade.php | 292 ++++ src/Modules/VersionNotices/Module.php | 4 + .../Workflows/Controllers/WorkflowEditor.php | 1 + .../Workflows/Controllers/WorkflowsList.php | 29 +- .../Engine/NodeRunnerProcessors/CronStep.php | 11 +- .../Engine/NodeRunners/Advanced/RayDebug.php | 9 +- .../Triggers/CoreOnPostUpdated.php | 2 +- .../Domain/Engine/RuntimeVariablesHandler.php | 15 +- .../VariableResolvers/PostMetaResolver.php | 65 + .../Engine/VariableResolvers/PostResolver.php | 6 +- .../VariableResolvers/SiteMetaResolver.php | 65 + .../Engine/VariableResolvers/SiteResolver.php | 44 +- .../VariableResolvers/UserMetaResolver.php | 65 + .../Engine/VariableResolvers/UserResolver.php | 18 +- .../WorkflowMetaResolver.php | 65 + .../VariableResolvers/WorkflowResolver.php | 16 +- .../Domain/Engine/WorkflowEngine.php | 10 + .../NodeTypes/Actions/CoreSendEmail.php | 5 +- .../NodeTypes/Advanced/CorePostQuery.php | 3 + .../Domain/NodeTypes/Advanced/LogAdd.php | 2 +- .../NodeTypes/Triggers/CoreOnPostUpdated.php | 1 + .../NodeTypes/Triggers/CoreOnSavePost.php | 1 + .../Models/ScheduledActionsModel.php | 6 +- .../Workflows/Models/WorkflowModel.php | 27 + .../Workflows/Models/WorkflowsModel.php | 14 + src/Modules/Workflows/Module.php | 3 +- src/Modules/Workflows/Rest/RestApiManager.php | 15 +- src/Modules/Workflows/Rest/RestApiV1.php | 14 +- src/Views/menu-advanced.php | 4 +- src/Views/menu-display.php | 429 +++-- src/Views/menu-general.php | 180 +-- src/Views/menu-notifications.php | 134 ++ src/Views/tabs.php | 5 + webpack.config.js | 3 +- yarn.lock | 18 +- 150 files changed, 7498 insertions(+), 2216 deletions(-) create mode 100644 assets/js/777.min.js create mode 100644 assets/js/backupPanel.js create mode 100644 assets/js/backupPanel.min.js create mode 100644 assets/js/backupPanel.min.js.LICENSE.txt create mode 100644 assets/js/vendors-node_modules_html-to-image_es_index_js.js create mode 100644 assets/jsx/backup-panel/components/backup-panel.jsx create mode 100644 assets/jsx/backup-panel/components/fieldset/index.jsx create mode 100644 assets/jsx/backup-panel/components/selectable-list/index.jsx create mode 100644 assets/jsx/backup-panel/components/settings-tab/index.jsx create mode 100644 assets/jsx/backup-panel/components/tabbed-window/index.jsx create mode 100644 assets/jsx/backup-panel/components/tabs-content/export.jsx create mode 100644 assets/jsx/backup-panel/components/tabs-content/import.jsx create mode 100644 assets/jsx/backup-panel/css/general.css create mode 100644 assets/jsx/backup-panel/index.jsx create mode 100644 assets/jsx/workflow-manual-selection/block-editor/css/style.css create mode 100644 assets/jsx/workflow-manual-selection/classic-editor/css/style.css create mode 100644 docs/translate-js-scripts.md create mode 100644 languages/post-expirator-es_ES-future_backup_panel.json create mode 100644 languages/post-expirator-es_ES-future_backup_panel.l10n.php create mode 100644 languages/post-expirator-es_ES-future_backup_panel.po create mode 100644 languages/post-expirator-fr_FR-future_backup_panel.json create mode 100644 languages/post-expirator-fr_FR-future_backup_panel.l10n.php create mode 100644 languages/post-expirator-fr_FR-future_backup_panel.po create mode 100644 languages/post-expirator-future_backup_panel.pot create mode 100644 languages/post-expirator-it_IT-future_backup_panel.json create mode 100644 languages/post-expirator-it_IT-future_backup_panel.l10n.php create mode 100644 languages/post-expirator-it_IT-future_backup_panel.po create mode 100644 languages/post-expirator-nl_NL-future_backup_panel.json create mode 100644 languages/post-expirator-nl_NL-future_backup_panel.l10n.php create mode 100644 languages/post-expirator-nl_NL-future_backup_panel.po create mode 100644 languages/post-expirator-pt_BR-future_backup_panel.json create mode 100644 languages/post-expirator-pt_BR-future_backup_panel.l10n.php create mode 100644 languages/post-expirator-pt_BR-future_backup_panel.po create mode 100644 src/Modules/Backup/Controllers/BackupAdminPage.php create mode 100644 src/Modules/Backup/Controllers/BackupRestApi.php create mode 100644 src/Modules/Backup/HooksAbstract.php create mode 100644 src/Modules/Backup/Module.php create mode 100644 src/Modules/Backup/Views/debug-panel.php create mode 100644 src/Modules/Workflows/Domain/Engine/VariableResolvers/PostMetaResolver.php create mode 100644 src/Modules/Workflows/Domain/Engine/VariableResolvers/SiteMetaResolver.php create mode 100644 src/Modules/Workflows/Domain/Engine/VariableResolvers/UserMetaResolver.php create mode 100644 src/Modules/Workflows/Domain/Engine/VariableResolvers/WorkflowMetaResolver.php create mode 100644 src/Views/menu-notifications.php diff --git a/CHANGELOG.md b/CHANGELOG.md index 666c596d2..d8ccbca74 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,41 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/) and this project adheres to [Semantic Versioning](http://semver.org/). +## [4.2.0] - 09 Dec, 2024 + +### Added + +- Add new admin page to export and import workflows and plugin settings (Issue #704). +- Add global variable `global.execution_id` to the workflow engine to identify the current execution of the workflow. +- Add setting fields to customize the metabox title and checkbox label (Issue #227). +- Add method `disableExpiration` to the class `PublishPress\Future\Modules\Expirator\Models\ExpirablePostModel`. +- Add `*` to indicate required fields in the workflow editor (Issue #974). +- Add new setting to disable/enable the screenshot feature in the workflow editor (Issue #1066). +- Add new Custom Data option to "Ray - Debug step" to debug custom expressions on workflows (Issue #1067). +- Add support to metadata when evaluating expressions in a workflow. Post, site, user and workflow (post) metadata are now available when evaluating expressions (Issue #1069). +- Add support to custom email addresses using the post metadata when sending emails in a workflow (Issue #939). + +### Changed + +- Move notification settings to a specific tab (Issue #190). +- Disable the workflow screenshot feature by default (Issue #1066). +- Changed the Message field in the "Log - Add" step displaying a textarea instead of a text field (Issue #1068). +- Changed the Custom Email Addresses field in the Send Email step to be a textarea (Issue #939). +- Changed the Subject field in the Send Email step to be a textarea (Issue #939). +- Set the default value of Email Recipient on Send Email step to Site Admin (Issue #1071). + +### Fixed + +- Do not remove expiration post meta when clearing the scheduled action (Issue #1053). +- Fix DB error when deleting orphan scheduled steps (Issue #1060). +- Potential fix for DOM text reinterpretation as HTML issue. +- Fix error when a trigger node type is not found. +- Fix warning PHP Deprecated: ltrim(): Passing null to parameter #1 ($string) of type string on the Scheduled Actions table. +- Fix error on table ScheduledActionsTable refactoring calls to `next` instead of `get_date`. +- Fix displaced labels for checkboxes in the Future Actions metabox and manual workflow activation checkbox (Issue #1057). +- Fix translations for user roles in the plugin settings page (Issue #1050). +- Fix error on Post Status filter in the Post Updated trigger (Issue #1074). + ## [4.1.3] - 22 Nov, 2024 ### Added diff --git a/assets/js/777.min.js b/assets/js/777.min.js new file mode 100644 index 000000000..143a7fb5b --- /dev/null +++ b/assets/js/777.min.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunkpost_expirator=self.webpackChunkpost_expirator||[]).push([[777],{777:(t,e,n)=>{n.r(e),n.d(e,{getFontEmbedCSS:()=>U,toBlob:()=>q,toCanvas:()=>M,toJpeg:()=>F,toPixelData:()=>H,toPng:()=>V,toSvg:()=>D});const r=(()=>{let t=0;return()=>(t+=1,`u${`0000${(Math.random()*36**4|0).toString(36)}`.slice(-4)}${t}`)})();function o(t){const e=[];for(let n=0,r=t.length;n{const r=new Image;r.decode=()=>e(r),r.onload=()=>e(r),r.onerror=n,r.crossOrigin="anonymous",r.decoding="async",r.src=t}))}const l=(t,e)=>{if(t instanceof e)return!0;const n=Object.getPrototypeOf(t);return null!==n&&(n.constructor.name===e.name||l(n,e))};function u(t,e,n){const i=window.getComputedStyle(t,n),a=i.getPropertyValue("content");if(""===a||"none"===a)return;const c=r();try{e.className=`${e.className} ${c}`}catch(t){return}const s=document.createElement("style");s.appendChild(function(t,e,n){const r=`.${t}:${e}`,i=n.cssText?function(t){const e=t.getPropertyValue("content");return`${t.cssText} content: '${e.replace(/'|"/g,"")}';`}(n):function(t){return o(t).map((e=>`${e}: ${t.getPropertyValue(e)}${t.getPropertyPriority(e)?" !important":""};`)).join(" ")}(n);return document.createTextNode(`${r}{${i}}`)}(c,n,i)),e.appendChild(s)}const h="application/font-woff",d="image/jpeg",f={woff:h,woff2:h,ttf:"application/font-truetype",eot:"application/vnd.ms-fontobject",png:"image/png",jpg:d,jpeg:d,gif:"image/gif",tiff:"image/tiff",svg:"image/svg+xml",webp:"image/webp"};function g(t){const e=function(t){const e=/\.([^./]*?)$/g.exec(t);return e?e[1]:""}(t).toLowerCase();return f[e]||""}function p(t){return-1!==t.search(/^(data:)/)}function m(t,e){return`data:${e};base64,${t}`}async function w(t,e,n){const r=await fetch(t,e);if(404===r.status)throw new Error(`Resource "${r.url}" not found`);const o=await r.blob();return new Promise(((t,e)=>{const i=new FileReader;i.onerror=e,i.onloadend=()=>{try{t(n({res:r,result:i.result}))}catch(t){e(t)}},i.readAsDataURL(o)}))}const y={};async function b(t,e,n){const r=function(t,e,n){let r=t.replace(/\?.*/,"");return n&&(r=t),/ttf|otf|eot|woff2?/i.test(r)&&(r=r.replace(/.*\//,"")),e?`[${e}]${r}`:r}(t,e,n.includeQueryParams);if(null!=y[r])return y[r];let o;n.cacheBust&&(t+=(/\?/.test(t)?"&":"?")+(new Date).getTime());try{const r=await w(t,n.fetchRequestInit,(({res:t,result:n})=>(e||(e=t.headers.get("Content-Type")||""),function(t){return t.split(/,/)[1]}(n))));o=m(r,e)}catch(e){o=n.imagePlaceholder||"";let r=`Failed to fetch resource: ${t}`;e&&(r="string"==typeof e?e:e.message),r&&console.warn(r)}return y[r]=o,o}const S=t=>null!=t.tagName&&"SLOT"===t.tagName.toUpperCase();async function E(t,e,n){return n||!e.filter||e.filter(t)?Promise.resolve(t).then((t=>async function(t,e){return l(t,HTMLCanvasElement)?async function(t){const e=t.toDataURL();return"data:,"===e?t.cloneNode(!1):s(e)}(t):l(t,HTMLVideoElement)?async function(t,e){if(t.currentSrc){const e=document.createElement("canvas"),n=e.getContext("2d");return e.width=t.clientWidth,e.height=t.clientHeight,null==n||n.drawImage(t,0,0,e.width,e.height),s(e.toDataURL())}const n=t.poster,r=g(n);return s(await b(n,r,e))}(t,e):l(t,HTMLIFrameElement)?async function(t){var e;try{if(null===(e=null==t?void 0:t.contentDocument)||void 0===e?void 0:e.body)return await E(t.contentDocument.body,{},!0)}catch(t){}return t.cloneNode(!1)}(t):t.cloneNode(!1)}(t,e))).then((n=>async function(t,e,n){var r,i;let a=[];return a=S(t)&&t.assignedNodes?o(t.assignedNodes()):l(t,HTMLIFrameElement)&&(null===(r=t.contentDocument)||void 0===r?void 0:r.body)?o(t.contentDocument.body.childNodes):o((null!==(i=t.shadowRoot)&&void 0!==i?i:t).childNodes),0===a.length||l(t,HTMLVideoElement)||await a.reduce(((t,r)=>t.then((()=>E(r,n))).then((t=>{t&&e.appendChild(t)}))),Promise.resolve()),e}(t,n,e))).then((e=>function(t,e){return l(e,Element)&&(function(t,e){const n=e.style;if(!n)return;const r=window.getComputedStyle(t);r.cssText?(n.cssText=r.cssText,n.transformOrigin=r.transformOrigin):o(r).forEach((o=>{let i=r.getPropertyValue(o);if("font-size"===o&&i.endsWith("px")){const t=Math.floor(parseFloat(i.substring(0,i.length-2)))-.1;i=`${t}px`}l(t,HTMLIFrameElement)&&"display"===o&&"inline"===i&&(i="block"),"d"===o&&e.getAttribute("d")&&(i=`path(${e.getAttribute("d")})`),n.setProperty(o,i,r.getPropertyPriority(o))}))}(t,e),function(t,e){u(t,e,":before"),u(t,e,":after")}(t,e),function(t,e){l(t,HTMLTextAreaElement)&&(e.innerHTML=t.value),l(t,HTMLInputElement)&&e.setAttribute("value",t.value)}(t,e),function(t,e){if(l(t,HTMLSelectElement)){const n=e,r=Array.from(n.children).find((e=>t.value===e.getAttribute("value")));r&&r.setAttribute("selected","")}}(t,e)),e}(t,e))).then((t=>async function(t,e){const n=t.querySelectorAll?t.querySelectorAll("use"):[];if(0===n.length)return t;const r={};for(let o=0;o{for(;;){const[n,,r]=v.exec(t)||[];if(!r)return"";if(r===e)return`src: ${n};`}})):t}(t,n),o=function(t){const e=[];return t.replace(x,((t,n,r)=>(e.push(r),t))),e.filter((t=>!p(t)))}(r);return o.reduce(((t,r)=>t.then((t=>async function(t,e,n,r,o){try{const i=n?function(t,e){if(t.match(/^[a-z]+:\/\//i))return t;if(t.match(/^\/\//))return window.location.protocol+t;if(t.match(/^[a-z]+:/i))return t;const n=document.implementation.createHTMLDocument(),r=n.createElement("base"),o=n.createElement("a");return n.head.appendChild(r),n.body.appendChild(o),e&&(r.href=e),o.href=t,o.href}(e,n):e,a=g(e);let c;return c=o?m(await o(i),a):await b(i,a,r),t.replace(function(t){const e=t.replace(/([.*+?^${}()|\[\]\/\\])/g,"\\$1");return new RegExp(`(url\\(['"]?)(${e})(['"]?\\))`,"g")}(e),`$1${c}$3`)}catch(t){}return t}(t,r,e,n)))),Promise.resolve(r))}async function R(t,e,n){var r;const o=null===(r=e.style)||void 0===r?void 0:r.getPropertyValue(t);if(o){const r=await P(o,null,n);return e.style.setProperty(t,r,e.style.getPropertyPriority(t)),!0}return!1}async function T(t,e){l(t,Element)&&(await async function(t,e){await R("background",t,e)||await R("background-image",t,e),await R("mask",t,e)||await R("mask-image",t,e)}(t,e),await async function(t,e){const n=l(t,HTMLImageElement);if((!n||p(t.src))&&(!l(t,SVGImageElement)||p(t.href.baseVal)))return;const r=n?t.src:t.href.baseVal,o=await b(r,g(r),e);await new Promise(((e,r)=>{t.onload=e,t.onerror=r;const i=t;i.decode&&(i.decode=e),"lazy"===i.loading&&(i.loading="eager"),n?(t.srcset="",t.src=o):t.href.baseVal=o}))}(t,e),await async function(t,e){const n=o(t.childNodes).map((t=>T(t,e)));await Promise.all(n).then((()=>t))}(t,e))}const A={};async function L(t){let e=A[t];if(null!=e)return e;const n=await fetch(t);return e={url:t,cssText:await n.text()},A[t]=e,e}async function N(t,e){let n=t.cssText;const r=/url\(["']?([^"')]+)["']?\)/g,o=(n.match(/url\([^)]+\)/g)||[]).map((async o=>{let i=o.replace(r,"$1");return i.startsWith("https://")||(i=new URL(i,t.url).href),w(i,e.fetchRequestInit,(({result:t})=>(n=n.replace(o,`url(${t})`),[o,t])))}));return Promise.all(o).then((()=>n))}function k(t){if(null==t)return[];const e=[];let n=t.replace(/(\/\*[\s\S]*?\*\/)/gi,"");const r=new RegExp("((@.*?keyframes [\\s\\S]*?){([\\s\\S]*?}\\s*?)})","gi");for(;;){const t=r.exec(n);if(null===t)break;e.push(t[0])}n=n.replace(r,"");const o=/@import[\s\S]*?url\([^)]*\)[\s\S]*?;/gi,i=new RegExp("((\\s*?(?:\\/\\*[\\s\\S]*?\\*\\/)?\\s*?@media[\\s\\S]*?){([\\s\\S]*?)}\\s*?})|(([\\s\\S]*?){([\\s\\S]*?)})","gi");for(;;){let t=o.exec(n);if(null===t){if(t=i.exec(n),null===t)break;o.lastIndex=i.lastIndex}else i.lastIndex=o.lastIndex;e.push(t[0])}return e}async function I(t,e){const n=await async function(t,e){if(null==t.ownerDocument)throw new Error("Provided element is not within a Document");const n=o(t.ownerDocument.styleSheets),r=await async function(t,e){const n=[],r=[];return t.forEach((n=>{if("cssRules"in n)try{o(n.cssRules||[]).forEach(((t,o)=>{if(t.type===CSSRule.IMPORT_RULE){let i=o+1;const a=L(t.href).then((t=>N(t,e))).then((t=>k(t).forEach((t=>{try{n.insertRule(t,t.startsWith("@import")?i+=1:n.cssRules.length)}catch(e){console.error("Error inserting rule from remote css",{rule:t,error:e})}})))).catch((t=>{console.error("Error loading remote css",t.toString())}));r.push(a)}}))}catch(o){const i=t.find((t=>null==t.href))||document.styleSheets[0];null!=n.href&&r.push(L(n.href).then((t=>N(t,e))).then((t=>k(t).forEach((t=>{i.insertRule(t,n.cssRules.length)})))).catch((t=>{console.error("Error loading remote stylesheet",t)}))),console.error("Error inlining remote css file",o)}})),Promise.all(r).then((()=>(t.forEach((t=>{if("cssRules"in t)try{o(t.cssRules||[]).forEach((t=>{n.push(t)}))}catch(e){console.error(`Error while reading CSS rules from ${t.href}`,e)}})),n)))}(n,e);return function(t){return t.filter((t=>t.type===CSSRule.FONT_FACE_RULE)).filter((t=>C(t.style.getPropertyValue("src"))))}(r)}(t,e);return(await Promise.all(n.map((t=>{const n=t.parentStyleSheet?t.parentStyleSheet.href:null;return P(t.cssText,n,e)})))).join("\n")}async function D(t,e={}){const{width:n,height:r}=a(t,e),o=await E(t,e,!0);return await async function(t,e){const n=null!=e.fontEmbedCSS?e.fontEmbedCSS:e.skipFonts?null:await I(t,e);if(n){const e=document.createElement("style"),r=document.createTextNode(n);e.appendChild(r),t.firstChild?t.insertBefore(e,t.firstChild):t.appendChild(e)}}(o,e),await T(o,e),function(t,e){const{style:n}=t;e.backgroundColor&&(n.backgroundColor=e.backgroundColor),e.width&&(n.width=`${e.width}px`),e.height&&(n.height=`${e.height}px`);const r=e.style;null!=r&&Object.keys(r).forEach((t=>{n[t]=r[t]}))}(o,e),await async function(t,e,n){const r="http://www.w3.org/2000/svg",o=document.createElementNS(r,"svg"),i=document.createElementNS(r,"foreignObject");return o.setAttribute("width",`${e}`),o.setAttribute("height",`${n}`),o.setAttribute("viewBox",`0 0 ${e} ${n}`),i.setAttribute("width","100%"),i.setAttribute("height","100%"),i.setAttribute("x","0"),i.setAttribute("y","0"),i.setAttribute("externalResourcesRequired","true"),o.appendChild(i),i.appendChild(t),async function(t){return Promise.resolve().then((()=>(new XMLSerializer).serializeToString(t))).then(encodeURIComponent).then((t=>`data:image/svg+xml;charset=utf-8,${t}`))}(o)}(o,n,r)}async function M(t,e={}){const{width:n,height:r}=a(t,e),o=await D(t,e),i=await s(o),l=document.createElement("canvas"),u=l.getContext("2d"),h=e.pixelRatio||function(){let t,e;try{e=process}catch(t){}const n=e&&e.env?e.env.devicePixelRatio:null;return n&&(t=parseInt(n,10),Number.isNaN(t)&&(t=1)),t||window.devicePixelRatio||1}(),d=e.canvasWidth||n,f=e.canvasHeight||r;return l.width=d*h,l.height=f*h,e.skipAutoScale||function(t){(t.width>c||t.height>c)&&(t.width>c&&t.height>c?t.width>t.height?(t.height*=c/t.width,t.width=c):(t.width*=c/t.height,t.height=c):t.width>c?(t.height*=c/t.width,t.width=c):(t.width*=c/t.height,t.height=c))}(l),l.style.width=`${d}`,l.style.height=`${f}`,e.backgroundColor&&(u.fillStyle=e.backgroundColor,u.fillRect(0,0,l.width,l.height)),u.drawImage(i,0,0,l.width,l.height),l}async function H(t,e={}){const{width:n,height:r}=a(t,e);return(await M(t,e)).getContext("2d").getImageData(0,0,n,r).data}async function V(t,e={}){return(await M(t,e)).toDataURL()}async function F(t,e={}){return(await M(t,e)).toDataURL("image/jpeg",e.quality||1)}async function q(t,e={}){const n=await M(t,e),r=await function(t,e={}){return t.toBlob?new Promise((n=>{t.toBlob(n,e.type?e.type:"image/png",e.quality?e.quality:1)})):new Promise((n=>{const r=window.atob(t.toDataURL(e.type?e.type:void 0,e.quality?e.quality:void 0).split(",")[1]),o=r.length,i=new Uint8Array(o);for(let t=0;t { // webpackBootstrap +/******/ "use strict"; +/******/ var __webpack_modules__ = ({ + +/***/ "./assets/jsx/backup-panel/components/backup-panel.jsx": +/*!*************************************************************!*\ + !*** ./assets/jsx/backup-panel/components/backup-panel.jsx ***! + \*************************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__) +/* harmony export */ }); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/i18n */ "@wordpress/i18n"); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); +/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _tabs_content_import__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./tabs-content/import */ "./assets/jsx/backup-panel/components/tabs-content/import.jsx"); +/* harmony import */ var _tabs_content_export__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./tabs-content/export */ "./assets/jsx/backup-panel/components/tabs-content/export.jsx"); +/* harmony import */ var _tabbed_window__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./tabbed-window */ "./assets/jsx/backup-panel/components/tabbed-window/index.jsx"); +function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); } +function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } +function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } } +function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; } +function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } } +function _arrayWithHoles(r) { if (Array.isArray(r)) return r; } + + + + + +var BackupPanel = function BackupPanel() { + var _useState = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_1__.useState)(), + _useState2 = _slicedToArray(_useState, 2), + activeTab = _useState2[0], + setActiveTab = _useState2[1]; + var tabs = [{ + label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)('Export', 'post-expirator'), + value: 'export' + }, { + label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)('Import', 'post-expirator'), + value: 'import' + }]; + return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(_tabbed_window__WEBPACK_IMPORTED_MODULE_4__["default"], { + tabs: tabs, + defaultTab: tabs[0].value, + onChange: setActiveTab + }, activeTab === 'import' && /*#__PURE__*/React.createElement(_tabs_content_import__WEBPACK_IMPORTED_MODULE_2__["default"], null), activeTab === 'export' && /*#__PURE__*/React.createElement(_tabs_content_export__WEBPACK_IMPORTED_MODULE_3__["default"], null))); +}; +/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (BackupPanel); + +/***/ }), + +/***/ "./assets/jsx/backup-panel/components/selectable-list/index.jsx": +/*!**********************************************************************!*\ + !*** ./assets/jsx/backup-panel/components/selectable-list/index.jsx ***! + \**********************************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ SelectableList: () => (/* binding */ SelectableList), +/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__) +/* harmony export */ }); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/i18n */ "@wordpress/i18n"); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/components */ "@wordpress/components"); +/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__); +function _toConsumableArray(r) { return _arrayWithoutHoles(r) || _iterableToArray(r) || _unsupportedIterableToArray(r) || _nonIterableSpread(); } +function _nonIterableSpread() { 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 _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } } +function _iterableToArray(r) { if ("undefined" != typeof Symbol && null != r[Symbol.iterator] || null != r["@@iterator"]) return Array.from(r); } +function _arrayWithoutHoles(r) { if (Array.isArray(r)) return _arrayLikeToArray(r); } +function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; } + + +var SelectableList = function SelectableList(_ref) { + var items = _ref.items, + selectedItems = _ref.selectedItems, + onSelect = _ref.onSelect; + var handleSelectAll = function handleSelectAll() { + onSelect(items.map(function (item) { + return item.id; + })); + }; + var handleUnselectAll = function handleUnselectAll() { + onSelect([]); + }; + return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("span", { + className: "pe-settings-tab__backup-actions" + }, /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { + isLink: true, + onClick: handleSelectAll + }, (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)('Select all', 'post-expirator')), " |", /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { + isLink: true, + onClick: handleUnselectAll + }, (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)('Unselect all', 'post-expirator')))), /*#__PURE__*/React.createElement("ul", null, items.map(function (item) { + return /*#__PURE__*/React.createElement("li", { + key: item.id + }, /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.CheckboxControl, { + label: /*#__PURE__*/React.createElement(React.Fragment, null, item.title, item.status && /*#__PURE__*/React.createElement("span", { + className: "pe-settings-tab__backup-status" + }, "[", item.status, "]")), + checked: selectedItems.includes(item.id), + onChange: function onChange(value) { + if (value) { + onSelect([].concat(_toConsumableArray(selectedItems), [item.id])); + } else { + onSelect(selectedItems.filter(function (id) { + return id !== item.id; + })); + } + } + })); + }))); +}; +/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (SelectableList); + +/***/ }), + +/***/ "./assets/jsx/backup-panel/components/settings-tab/index.jsx": +/*!*******************************************************************!*\ + !*** ./assets/jsx/backup-panel/components/settings-tab/index.jsx ***! + \*******************************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ SettingsTab: () => (/* binding */ SettingsTab), +/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__) +/* harmony export */ }); +var SettingsTab = function SettingsTab(_ref) { + var title = _ref.title, + description = _ref.description, + children = _ref.children; + return /*#__PURE__*/React.createElement("div", { + className: "pe-settings-tab" + }, /*#__PURE__*/React.createElement("h2", null, title), /*#__PURE__*/React.createElement("p", null, description), children); +}; +/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (SettingsTab); + +/***/ }), + +/***/ "./assets/jsx/backup-panel/components/tabbed-window/index.jsx": +/*!********************************************************************!*\ + !*** ./assets/jsx/backup-panel/components/tabbed-window/index.jsx ***! + \********************************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__) +/* harmony export */ }); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/i18n */ "@wordpress/i18n"); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); +/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @wordpress/components */ "@wordpress/components"); +/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @wordpress/data */ "@wordpress/data"); +/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_wordpress_data__WEBPACK_IMPORTED_MODULE_3__); +function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); } +function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } +function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } } +function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; } +function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } } +function _arrayWithHoles(r) { if (Array.isArray(r)) return r; } +function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); } + + + + +var TabbedWindow = function TabbedWindow(_ref) { + var _ref$defaultTab = _ref.defaultTab, + defaultTab = _ref$defaultTab === void 0 ? '' : _ref$defaultTab, + _ref$tabs = _ref.tabs, + tabs = _ref$tabs === void 0 ? [{ + label: 'Tab 1', + value: 'tab1' + }, { + label: 'Tab 2', + value: 'tab2' + }] : _ref$tabs, + _ref$onChange = _ref.onChange, + onChange = _ref$onChange === void 0 ? function () {} : _ref$onChange, + children = _ref.children, + _ref$noticeAutoDismis = _ref.noticeAutoDismissTimeout, + noticeAutoDismissTimeout = _ref$noticeAutoDismis === void 0 ? 5000 : _ref$noticeAutoDismis; + var getCurrentTabFromUrl = function getCurrentTabFromUrl() { + var hash = window.location.hash.replace('#', ''); + var theTab = tabs.find(function (tab) { + return tab.value === hash; + }) || defaultTab; + if (_typeof(theTab) === 'object') { + return theTab.value; + } + return theTab; + }; + var _useState = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_1__.useState)(getCurrentTabFromUrl()), + _useState2 = _slicedToArray(_useState, 2), + activeTab = _useState2[0], + setActiveTab = _useState2[1]; + var notices = (0,_wordpress_data__WEBPACK_IMPORTED_MODULE_3__.useSelect)(function (select) { + return select('core/notices').getNotices(); + }); + var _useDispatch = (0,_wordpress_data__WEBPACK_IMPORTED_MODULE_3__.useDispatch)('core/notices'), + removeNotice = _useDispatch.removeNotice; + + // Listen for hash changes + (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_1__.useEffect)(function () { + var handleHashChange = function handleHashChange() { + var newTab = getCurrentTabFromUrl(); + setActiveTab(newTab); + }; + window.addEventListener('hashchange', handleHashChange); + return function () { + return window.removeEventListener('hashchange', handleHashChange); + }; + }, []); + + //Autodismiss notices + (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_1__.useEffect)(function () { + notices.forEach(function (notice) { + setTimeout(function () { + removeNotice(notice.id); + }, noticeAutoDismissTimeout); + }); + }, [notices]); + (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_1__.useEffect)(function () { + window.history.replaceState(null, '', "#".concat(activeTab)); + onChange(activeTab); + }, [activeTab]); + return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", { + id: "pe-settings-tabs" + }, /*#__PURE__*/React.createElement("nav", { + className: "nav-tab-wrapper postexpirator-nav-tab-wrapper", + id: "postexpirator-nav" + }, tabs.map(function (tab) { + return /*#__PURE__*/React.createElement("a", { + key: tab.value, + href: "#", + className: "pe-tab nav-tab ".concat(activeTab === tab.value ? 'nav-tab-active' : ''), + "data-tab": tab.value, + onClick: function onClick(e) { + e.preventDefault(); + setActiveTab(tab.value); + } + }, tab.label); + })), children), /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.SnackbarList, { + notices: notices, + className: "pe-settings-tab__snackbar-list", + onRemove: function onRemove(noticeId) { + removeNotice(noticeId); + } + })); +}; +/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (TabbedWindow); + +/***/ }), + +/***/ "./assets/jsx/backup-panel/components/tabs-content/export.jsx": +/*!********************************************************************!*\ + !*** ./assets/jsx/backup-panel/components/tabs-content/export.jsx ***! + \********************************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__) +/* harmony export */ }); +/* harmony import */ var _wordpress_url__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/url */ "@wordpress/url"); +/* harmony import */ var _wordpress_url__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_url__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/i18n */ "@wordpress/i18n"); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @wordpress/components */ "@wordpress/components"); +/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); +/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @wordpress/data */ "@wordpress/data"); +/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_wordpress_data__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var _selectable_list__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../selectable-list */ "./assets/jsx/backup-panel/components/selectable-list/index.jsx"); +/* harmony import */ var _settings_tab__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../settings-tab */ "./assets/jsx/backup-panel/components/settings-tab/index.jsx"); +function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); } +function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { 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 define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, ""); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, "_invoke", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: "normal", arg: t.call(e, r) }; } catch (t) { return { type: "throw", arg: t }; } } e.wrap = wrap; var h = "suspendedStart", l = "suspendedYield", f = "executing", s = "completed", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { ["next", "throw", "return"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if ("throw" !== c.type) { var u = c.arg, h = u.value; return h && "object" == _typeof(h) && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) { invoke("next", t, i, a); }, function (t) { invoke("throw", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke("throw", t, i, a); }); } a(c.arg); } var r; o(this, "_invoke", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw Error("Generator is already running"); if (o === s) { 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 = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else "return" === n.method && n.abrupt("return", n.arg); o = f; var p = tryCatch(e, r, n); if ("normal" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg); } }; } function maybeInvokeDelegate(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, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y; var i = tryCatch(o, e.iterator, r.arg); if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y; 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, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y); } function pushTryEntry(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 resetTryEntry(t) { var e = t.completion || {}; e.type = "normal", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: "root" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(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 next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(_typeof(e) + " is not iterable"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) { var e = "function" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () { return this; }), define(g, "toString", function () { return "[object Generator]"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if ("throw" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if ("root" === i.tryLoc) return handle("end"); if (i.tryLoc <= this.prev) { var c = n.call(i, "catchLoc"), u = n.call(i, "finallyLoc"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw Error("try statement without catch or finally"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) { var i = o; break; } } i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if ("throw" === t.type) throw t.arg; return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, catch: function _catch(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; resetTryEntry(r); } return o; } } throw Error("illegal catch attempt"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, "next" === this.method && (this.arg = t), y; } }, e; } +function asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); } +function _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, "next", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, "throw", n); } _next(void 0); }); }; } +function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); } +function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } +function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } } +function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; } +function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } } +function _arrayWithHoles(r) { if (Array.isArray(r)) return r; } + + + + + +var _wp = wp, + apiFetch = _wp.apiFetch; + + +var ExportTab = function ExportTab() { + var _useState = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_3__.useState)(true), + _useState2 = _slicedToArray(_useState, 2), + exportActionWorkflows = _useState2[0], + setExportActionWorkflows = _useState2[1]; + var _useState3 = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_3__.useState)(true), + _useState4 = _slicedToArray(_useState3, 2), + exportActionSettings = _useState4[0], + setExportActionSettings = _useState4[1]; + var _useState5 = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_3__.useState)(false), + _useState6 = _slicedToArray(_useState5, 2), + includeScreenshots = _useState6[0], + setIncludeScreenshots = _useState6[1]; + var _useState7 = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_3__.useState)(false), + _useState8 = _slicedToArray(_useState7, 2), + isExporting = _useState8[0], + setIsExporting = _useState8[1]; + var _useState9 = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_3__.useState)([]), + _useState10 = _slicedToArray(_useState9, 2), + workflows = _useState10[0], + setWorkflows = _useState10[1]; + var _useState11 = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_3__.useState)([]), + _useState12 = _slicedToArray(_useState11, 2), + selectedWorkflows = _useState12[0], + setSelectedWorkflows = _useState12[1]; + var _useState13 = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_3__.useState)(['postTypesDefaults', 'general', 'notifications', 'display', 'advanced']), + _useState14 = _slicedToArray(_useState13, 2), + selectedSettings = _useState14[0], + setSelectedSettings = _useState14[1]; + var apiRequestControllerRef = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_3__.useRef)(new AbortController()); + var _futureBackupPanelDat = futureBackupPanelData, + enableWorkflowScreenshot = _futureBackupPanelDat.enableWorkflowScreenshot; + var settingsOptions = [{ + title: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Post Types', 'post-expirator'), + id: 'postTypesDefaults' + }, { + title: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('General', 'post-expirator'), + id: 'general' + }, { + title: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Notifications', 'post-expirator'), + id: 'notifications' + }, { + title: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Display', 'post-expirator'), + id: 'display' + }, { + title: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Advanced', 'post-expirator'), + id: 'advanced' + }]; + var _useDispatch = (0,_wordpress_data__WEBPACK_IMPORTED_MODULE_4__.useDispatch)('core/notices'), + createSuccessNotice = _useDispatch.createSuccessNotice, + createErrorNotice = _useDispatch.createErrorNotice; + (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_3__.useEffect)(function () { + apiFetch({ + path: (0,_wordpress_url__WEBPACK_IMPORTED_MODULE_0__.addQueryArgs)("publishpress-future/v1/backup/workflows") + }).then(function (result) { + setWorkflows(result.workflows); + setSelectedWorkflows(result.workflows.map(function (workflow) { + return workflow.id; + })); + }); + }, []); + var handleJsonDataDownload = function handleJsonDataDownload(resultData) { + // Create a blob with the JSON data + var jsonData = JSON.stringify(resultData, null, 2); + var blob = new Blob([jsonData], { + type: 'application/json' + }); + + // Create download link and trigger click + var downloadUrl = URL.createObjectURL(blob); + var date = new Date().toISOString().replace(':', '-').split('.')[0]; + var link = document.createElement('a'); + link.href = downloadUrl; + link.download = "publishpress-future-backup-".concat(date, ".json"); + document.body.appendChild(link); + link.click(); + document.body.removeChild(link); + + // Clean up the URL object + URL.revokeObjectURL(downloadUrl); + }; + var handleExport = /*#__PURE__*/function () { + var _ref = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee() { + var controller, signal; + return _regeneratorRuntime().wrap(function _callee$(_context) { + while (1) switch (_context.prev = _context.next) { + case 0: + setIsExporting(true); + controller = apiRequestControllerRef.current; + if (controller) { + controller.abort(); + } + apiRequestControllerRef.current = new AbortController(); + signal = apiRequestControllerRef.current.signal; + apiFetch({ + path: (0,_wordpress_url__WEBPACK_IMPORTED_MODULE_0__.addQueryArgs)("publishpress-future/v1/backup/export"), + method: 'POST', + data: { + exportActionWorkflows: exportActionWorkflows, + exportActionSettings: exportActionSettings, + workflows: selectedWorkflows, + includeScreenshots: includeScreenshots, + settings: selectedSettings + }, + signal: signal + }).then(function (result) { + setIsExporting(false); + handleJsonDataDownload(result.data); + createSuccessNotice((0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Settings exported successfully.', 'post-expirator'), { + type: 'snackbar', + isDismissible: true, + actions: [{ + label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Download', 'post-expirator'), + onClick: function onClick() { + handleJsonDataDownload(result.data); + } + }], + icon: /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.Dashicon, { + icon: "yes" + }), + autoDismiss: true, + explicitDismiss: true + }); + }).catch(function (error) { + if (error.name === 'AbortError') { + return; + } + createErrorNotice(error.message || (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Failed to export settings.', 'post-expirator'), { + type: 'snackbar', + isDismissible: true, + actions: [], + icon: /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.Dashicon, { + icon: "no" + }), + autoDismiss: true, + explicitDismiss: true + }); + setIsExporting(false); + }); + case 6: + case "end": + return _context.stop(); + } + }, _callee); + })); + return function handleExport() { + return _ref.apply(this, arguments); + }; + }(); + var handleExportCancel = function handleExportCancel() { + var controller = apiRequestControllerRef.current; + if (controller) { + controller.abort(); + } + }; + var handleSelectAllSettings = function handleSelectAllSettings() { + setSelectedSettings(settingsOptions.map(function (option) { + return option.value; + })); + }; + var handleUnselectAllSettings = function handleUnselectAllSettings() { + setSelectedSettings([]); + }; + return /*#__PURE__*/React.createElement(_settings_tab__WEBPACK_IMPORTED_MODULE_6__.SettingsTab, { + title: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Export Settings', 'post-expirator'), + description: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Export the plugin settings and workflows to a .json file. This file can be imported later to restore the data or migrate to another site.', 'post-expirator') + }, /*#__PURE__*/React.createElement("ul", { + id: "export-actions" + }, /*#__PURE__*/React.createElement("li", { + key: "export-action-workflows" + }, /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.CheckboxControl, { + label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Action Workflows', 'post-expirator'), + checked: exportActionWorkflows && workflows.length > 0, + onChange: function onChange(value) { + return setExportActionWorkflows(value); + }, + disabled: workflows.length === 0 + }), exportActionWorkflows && workflows.length > 0 && /*#__PURE__*/React.createElement("div", { + className: "pe-settings-tab__backup-container" + }, enableWorkflowScreenshot && /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.ToggleControl, { + label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Include screenshots', 'post-expirator'), + checked: includeScreenshots, + onChange: function onChange(value) { + return setIncludeScreenshots(value); + } + })), /*#__PURE__*/React.createElement(_selectable_list__WEBPACK_IMPORTED_MODULE_5__.SelectableList, { + items: workflows, + selectedItems: selectedWorkflows, + onSelect: setSelectedWorkflows + }))), /*#__PURE__*/React.createElement("li", { + key: "export-action-settings" + }, /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.CheckboxControl, { + label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Action Settings', 'post-expirator'), + checked: exportActionSettings, + onChange: function onChange(value) { + return setExportActionSettings(value); + } + }), exportActionSettings && /*#__PURE__*/React.createElement("div", { + className: "pe-settings-tab__backup-container" + }, /*#__PURE__*/React.createElement(_selectable_list__WEBPACK_IMPORTED_MODULE_5__.SelectableList, { + items: settingsOptions, + selectedItems: selectedSettings, + onSelect: setSelectedSettings + })))), (exportActionWorkflows || exportActionSettings) && /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.Button, { + isPrimary: true, + onClick: handleExport, + isBusy: isExporting, + disabled: isExporting + }, isExporting ? (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Exporting...', 'post-expirator') : (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Export', 'post-expirator')), isExporting && /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.Button, { + isLink: true, + onClick: handleExportCancel, + className: "pe-settings-tab__export-cancel-button" + }, (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Cancel', 'post-expirator'))); +}; +/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (ExportTab); + +/***/ }), + +/***/ "./assets/jsx/backup-panel/components/tabs-content/import.jsx": +/*!********************************************************************!*\ + !*** ./assets/jsx/backup-panel/components/tabs-content/import.jsx ***! + \********************************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__) +/* harmony export */ }); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/i18n */ "@wordpress/i18n"); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/components */ "@wordpress/components"); +/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); +/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @wordpress/data */ "@wordpress/data"); +/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_wordpress_data__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _settings_tab__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../settings-tab */ "./assets/jsx/backup-panel/components/settings-tab/index.jsx"); +function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); } +function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } +function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } } +function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; } +function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } } +function _arrayWithHoles(r) { if (Array.isArray(r)) return r; } + + + + + +var formatFileSize = function formatFileSize(bytes) { + if (bytes === 0) return '0 Bytes'; + var k = 1024; + var sizes = ['Bytes', 'KB', 'MB', 'GB']; + var i = Math.floor(Math.log(bytes) / Math.log(k)); + return "".concat(parseFloat((bytes / Math.pow(k, i)).toFixed(2)), " ").concat(sizes[i]); +}; +var ImportTab = function ImportTab() { + var _useState = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_2__.useState)(false), + _useState2 = _slicedToArray(_useState, 2), + isImporting = _useState2[0], + setIsImporting = _useState2[1]; + var _useState3 = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_2__.useState)(null), + _useState4 = _slicedToArray(_useState3, 2), + file = _useState4[0], + setFile = _useState4[1]; + var _useState5 = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_2__.useState)(false), + _useState6 = _slicedToArray(_useState5, 2), + validFile = _useState6[0], + setValidFile = _useState6[1]; + var _useState7 = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_2__.useState)(null), + _useState8 = _slicedToArray(_useState7, 2), + validationError = _useState8[0], + setValidationError = _useState8[1]; + var _useState9 = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_2__.useState)(false), + _useState10 = _slicedToArray(_useState9, 2), + isDragging = _useState10[0], + setIsDragging = _useState10[1]; + var _useDispatch = (0,_wordpress_data__WEBPACK_IMPORTED_MODULE_3__.useDispatch)('core/notices'), + createSuccessNotice = _useDispatch.createSuccessNotice, + createErrorNotice = _useDispatch.createErrorNotice; + var handleImport = function handleImport() { + setIsImporting(true); + + // Create FormData object + var formData = new FormData(); + formData.append('backupFile', file); + var wpNonce = wp.apiFetch.nonceMiddleware ? wp.apiFetch.nonceMiddleware.nonce : ''; + fetch("".concat(futureBackupPanelData.apiRoot, "publishpress-future/v1/backup/import"), { + method: 'POST', + headers: { + 'X-WP-Nonce': wpNonce + }, + body: formData, + credentials: 'same-origin' + }).then(function (response) { + return response.json(); + }).then(function (response) { + if (response.ok) { + setIsImporting(false); + createSuccessNotice(response.message || (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)('Settings imported successfully.', 'post-expirator'), { + type: 'snackbar', + isDismissible: true, + actions: [], + autoDismiss: true, + explicitDismiss: true, + icon: /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Dashicon, { + icon: "yes" + }) + }); + } else { + throw new Error(response.message); + } + }).catch(function (error) { + setIsImporting(false); + createErrorNotice(error || (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)('Failed to import settings.', 'post-expirator'), { + type: 'snackbar', + isDismissible: true, + actions: [], + autoDismiss: true, + explicitDismiss: true, + icon: /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Dashicon, { + icon: "warning" + }) + }); + }); + }; + var validateFile = function validateFile(fileToValidate) { + var fileExtension = fileToValidate.name.split('.').pop(); + if (fileExtension !== 'json') { + setValidFile(false); + setValidationError((0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)('Invalid file type. Please upload a .json file.', 'post-expirator')); + return; + } + setValidFile(true); + setValidationError(null); + }; + return /*#__PURE__*/React.createElement(_settings_tab__WEBPACK_IMPORTED_MODULE_4__.SettingsTab, { + title: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)('Import Settings', 'post-expirator'), + description: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)('Import the plugin settings or workflows from a .json file.', 'post-expirator') + }, /*#__PURE__*/React.createElement("div", { + className: "pe-settings-tab__import-file-upload" + }, /*#__PURE__*/React.createElement("div", { + className: "pe-dropzone ".concat(isDragging ? 'pe-dropzone--active' : ''), + onDrop: function onDrop(e) { + e.preventDefault(); + var droppedFile = e.dataTransfer.files[0]; + setFile(droppedFile); + validateFile(droppedFile); + }, + onDragOver: function onDragOver(e) { + e.preventDefault(); + }, + onDragEnter: function onDragEnter(e) { + e.preventDefault(); + setIsDragging(true); + }, + onDragLeave: function onDragLeave(e) { + e.preventDefault(); + if (e.currentTarget === e.target) { + setIsDragging(false); + } + } + }, /*#__PURE__*/React.createElement("p", null, (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)('Drop your .json file here', 'post-expirator')), /*#__PURE__*/React.createElement("p", null, (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)('or', 'post-expirator')), /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.FormFileUpload, { + accept: ".json,application/json,text/json,text/plain", + onChange: function onChange(event) { + setFile(event.currentTarget.files[0]); + validateFile(event.currentTarget.files[0]); + }, + className: "is-primary" + }, (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)('Select a .json file', 'post-expirator')), file && /*#__PURE__*/React.createElement("div", { + className: "pe-settings-tab__import-file-upload-info" + }, /*#__PURE__*/React.createElement("p", null, (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)('Selected file', 'post-expirator'), ": ", file.name), /*#__PURE__*/React.createElement("p", null, (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)('File size', 'post-expirator'), ": ", formatFileSize(file.size))))), validFile && /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { + isPrimary: true, + isBusy: isImporting, + onClick: handleImport + }, (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)('Import', 'post-expirator')), validationError && /*#__PURE__*/React.createElement("p", { + className: "error" + }, validationError)); +}; +/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (ImportTab); + +/***/ }), + +/***/ "./node_modules/css-loader/dist/cjs.js!./node_modules/postcss-loader/dist/cjs.js!./assets/jsx/backup-panel/css/general.css": +/*!*********************************************************************************************************************************!*\ + !*** ./node_modules/css-loader/dist/cjs.js!./node_modules/postcss-loader/dist/cjs.js!./assets/jsx/backup-panel/css/general.css ***! + \*********************************************************************************************************************************/ +/***/ ((module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__) +/* harmony export */ }); +/* harmony import */ var _node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ "./node_modules/css-loader/dist/runtime/sourceMaps.js"); +/* harmony import */ var _node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ "./node_modules/css-loader/dist/runtime/api.js"); +/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__); +// Imports + + +var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default()((_node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default())); +// Module +___CSS_LOADER_EXPORT___.push([module.id, `ul#export-actions { + margin-bottom: 20px; +} + +ul#export-actions li ul { + margin-top: 10px; + border: 1px solid #e0e0e0e5; + padding: 10px; + background-color: #fff; +} + +ul#export-actions span { + display: inline-block; +} + +.pe-settings-tab__backup-status { + margin-left: 5px; +} + +.pe-settings-tab__backup-actions button { + margin-left: 5px !important; +} + +.pe-settings-tab__backup-container { + margin-left: 30px; +} + +.pe-settings-tab__export-cancel-button { + margin-left: 10px !important; +} + +.components-snackbar-list { + position: fixed !important; + bottom: 20px; + left: 182px; + transform: none; + z-index: 100000; +} + +.components-snackbar { + margin-bottom: 10px; +} + +.wp-admin.folded .components-snackbar-list { + left: 58px; +} + +.pe-settings-tab__import-file-upload { + margin-bottom: 20px; +} + +.pe-settings-tab__import-file-upload-info { + margin-top: 10px; + font-size: 14px; +} + +.pe-dropzone { + border: 3px dashed #ccc; + padding: 20px; + text-align: center; +} + +.pe-dropzone--active { + border-color: #0073aa; +} + +.pe-dropzone p { + margin: 0; +} + +`, "",{"version":3,"sources":["webpack://./assets/jsx/backup-panel/css/general.css"],"names":[],"mappings":"AAAA;IACI,mBAAmB;AACvB;;AAEA;IACI,gBAAgB;IAChB,2BAA2B;IAC3B,aAAa;IACb,sBAAsB;AAC1B;;AAEA;IACI,qBAAqB;AACzB;;AAEA;IACI,gBAAgB;AACpB;;AAEA;IACI,2BAA2B;AAC/B;;AAEA;IACI,iBAAiB;AACrB;;AAEA;IACI,4BAA4B;AAChC;;AAEA;IACI,0BAA0B;IAC1B,YAAY;IACZ,WAAW;IACX,eAAe;IACf,eAAe;AACnB;;AAEA;IACI,mBAAmB;AACvB;;AAEA;IACI,UAAU;AACd;;AAEA;IACI,mBAAmB;AACvB;;AAEA;IACI,gBAAgB;IAChB,eAAe;AACnB;;AAEA;IACI,uBAAuB;IACvB,aAAa;IACb,kBAAkB;AACtB;;AAEA;IACI,qBAAqB;AACzB;;AAEA;IACI,SAAS;AACb","sourcesContent":["ul#export-actions {\n margin-bottom: 20px;\n}\n\nul#export-actions li ul {\n margin-top: 10px;\n border: 1px solid #e0e0e0e5;\n padding: 10px;\n background-color: #fff;\n}\n\nul#export-actions span {\n display: inline-block;\n}\n\n.pe-settings-tab__backup-status {\n margin-left: 5px;\n}\n\n.pe-settings-tab__backup-actions button {\n margin-left: 5px !important;\n}\n\n.pe-settings-tab__backup-container {\n margin-left: 30px;\n}\n\n.pe-settings-tab__export-cancel-button {\n margin-left: 10px !important;\n}\n\n.components-snackbar-list {\n position: fixed !important;\n bottom: 20px;\n left: 182px;\n transform: none;\n z-index: 100000;\n}\n\n.components-snackbar {\n margin-bottom: 10px;\n}\n\n.wp-admin.folded .components-snackbar-list {\n left: 58px;\n}\n\n.pe-settings-tab__import-file-upload {\n margin-bottom: 20px;\n}\n\n.pe-settings-tab__import-file-upload-info {\n margin-top: 10px;\n font-size: 14px;\n}\n\n.pe-dropzone {\n border: 3px dashed #ccc;\n padding: 20px;\n text-align: center;\n}\n\n.pe-dropzone--active {\n border-color: #0073aa;\n}\n\n.pe-dropzone p {\n margin: 0;\n}\n\n"],"sourceRoot":""}]); +// Exports +/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___); + + +/***/ }), + +/***/ "./node_modules/css-loader/dist/runtime/api.js": +/*!*****************************************************!*\ + !*** ./node_modules/css-loader/dist/runtime/api.js ***! + \*****************************************************/ +/***/ ((module) => { + + + +/* + MIT License http://www.opensource.org/licenses/mit-license.php + Author Tobias Koppers @sokra +*/ +module.exports = function (cssWithMappingToString) { + var list = []; + + // return the list of modules as css string + list.toString = function toString() { + return this.map(function (item) { + var content = ""; + var needLayer = typeof item[5] !== "undefined"; + if (item[4]) { + content += "@supports (".concat(item[4], ") {"); + } + if (item[2]) { + content += "@media ".concat(item[2], " {"); + } + if (needLayer) { + content += "@layer".concat(item[5].length > 0 ? " ".concat(item[5]) : "", " {"); + } + content += cssWithMappingToString(item); + if (needLayer) { + content += "}"; + } + if (item[2]) { + content += "}"; + } + if (item[4]) { + content += "}"; + } + return content; + }).join(""); + }; + + // import a list of modules into the list + list.i = function i(modules, media, dedupe, supports, layer) { + if (typeof modules === "string") { + modules = [[null, modules, undefined]]; + } + var alreadyImportedModules = {}; + if (dedupe) { + for (var k = 0; k < this.length; k++) { + var id = this[k][0]; + if (id != null) { + alreadyImportedModules[id] = true; + } + } + } + for (var _k = 0; _k < modules.length; _k++) { + var item = [].concat(modules[_k]); + if (dedupe && alreadyImportedModules[item[0]]) { + continue; + } + if (typeof layer !== "undefined") { + if (typeof item[5] === "undefined") { + item[5] = layer; + } else { + item[1] = "@layer".concat(item[5].length > 0 ? " ".concat(item[5]) : "", " {").concat(item[1], "}"); + item[5] = layer; + } + } + if (media) { + if (!item[2]) { + item[2] = media; + } else { + item[1] = "@media ".concat(item[2], " {").concat(item[1], "}"); + item[2] = media; + } + } + if (supports) { + if (!item[4]) { + item[4] = "".concat(supports); + } else { + item[1] = "@supports (".concat(item[4], ") {").concat(item[1], "}"); + item[4] = supports; + } + } + list.push(item); + } + }; + return list; +}; + +/***/ }), + +/***/ "./node_modules/css-loader/dist/runtime/sourceMaps.js": +/*!************************************************************!*\ + !*** ./node_modules/css-loader/dist/runtime/sourceMaps.js ***! + \************************************************************/ +/***/ ((module) => { + + + +module.exports = function (item) { + var content = item[1]; + var cssMapping = item[3]; + if (!cssMapping) { + return content; + } + if (typeof btoa === "function") { + var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(cssMapping)))); + var data = "sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(base64); + var sourceMapping = "/*# ".concat(data, " */"); + return [content].concat([sourceMapping]).join("\n"); + } + return [content].join("\n"); +}; + +/***/ }), + +/***/ "./node_modules/react-dom/client.js": +/*!******************************************!*\ + !*** ./node_modules/react-dom/client.js ***! + \******************************************/ +/***/ ((__unused_webpack_module, exports, __webpack_require__) => { + + + +var m = __webpack_require__(/*! react-dom */ "react-dom"); +if (false) {} else { + var i = m.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED; + exports.createRoot = function(c, o) { + i.usingClientEntryPoint = true; + try { + return m.createRoot(c, o); + } finally { + i.usingClientEntryPoint = false; + } + }; + exports.hydrateRoot = function(c, h, o) { + i.usingClientEntryPoint = true; + try { + return m.hydrateRoot(c, h, o); + } finally { + i.usingClientEntryPoint = false; + } + }; +} + + +/***/ }), + +/***/ "./assets/jsx/backup-panel/css/general.css": +/*!*************************************************!*\ + !*** ./assets/jsx/backup-panel/css/general.css ***! + \*************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__) +/* harmony export */ }); +/* harmony import */ var _node_modules_style_loader_dist_runtime_injectStylesIntoStyleTag_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! !../../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js */ "./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js"); +/* harmony import */ var _node_modules_style_loader_dist_runtime_injectStylesIntoStyleTag_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_injectStylesIntoStyleTag_js__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _node_modules_style_loader_dist_runtime_styleDomAPI_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! !../../../../node_modules/style-loader/dist/runtime/styleDomAPI.js */ "./node_modules/style-loader/dist/runtime/styleDomAPI.js"); +/* harmony import */ var _node_modules_style_loader_dist_runtime_styleDomAPI_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_styleDomAPI_js__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _node_modules_style_loader_dist_runtime_insertBySelector_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! !../../../../node_modules/style-loader/dist/runtime/insertBySelector.js */ "./node_modules/style-loader/dist/runtime/insertBySelector.js"); +/* harmony import */ var _node_modules_style_loader_dist_runtime_insertBySelector_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_insertBySelector_js__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _node_modules_style_loader_dist_runtime_setAttributesWithoutAttributes_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! !../../../../node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js */ "./node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js"); +/* harmony import */ var _node_modules_style_loader_dist_runtime_setAttributesWithoutAttributes_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_setAttributesWithoutAttributes_js__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _node_modules_style_loader_dist_runtime_insertStyleElement_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! !../../../../node_modules/style-loader/dist/runtime/insertStyleElement.js */ "./node_modules/style-loader/dist/runtime/insertStyleElement.js"); +/* harmony import */ var _node_modules_style_loader_dist_runtime_insertStyleElement_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_insertStyleElement_js__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var _node_modules_style_loader_dist_runtime_styleTagTransform_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! !../../../../node_modules/style-loader/dist/runtime/styleTagTransform.js */ "./node_modules/style-loader/dist/runtime/styleTagTransform.js"); +/* harmony import */ var _node_modules_style_loader_dist_runtime_styleTagTransform_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_styleTagTransform_js__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var _node_modules_css_loader_dist_cjs_js_node_modules_postcss_loader_dist_cjs_js_general_css__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! !!../../../../node_modules/css-loader/dist/cjs.js!../../../../node_modules/postcss-loader/dist/cjs.js!./general.css */ "./node_modules/css-loader/dist/cjs.js!./node_modules/postcss-loader/dist/cjs.js!./assets/jsx/backup-panel/css/general.css"); + + + + + + + + + + + +var options = {}; + +options.styleTagTransform = (_node_modules_style_loader_dist_runtime_styleTagTransform_js__WEBPACK_IMPORTED_MODULE_5___default()); +options.setAttributes = (_node_modules_style_loader_dist_runtime_setAttributesWithoutAttributes_js__WEBPACK_IMPORTED_MODULE_3___default()); +options.insert = _node_modules_style_loader_dist_runtime_insertBySelector_js__WEBPACK_IMPORTED_MODULE_2___default().bind(null, "head"); +options.domAPI = (_node_modules_style_loader_dist_runtime_styleDomAPI_js__WEBPACK_IMPORTED_MODULE_1___default()); +options.insertStyleElement = (_node_modules_style_loader_dist_runtime_insertStyleElement_js__WEBPACK_IMPORTED_MODULE_4___default()); + +var update = _node_modules_style_loader_dist_runtime_injectStylesIntoStyleTag_js__WEBPACK_IMPORTED_MODULE_0___default()(_node_modules_css_loader_dist_cjs_js_node_modules_postcss_loader_dist_cjs_js_general_css__WEBPACK_IMPORTED_MODULE_6__["default"], options); + + + + + /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (_node_modules_css_loader_dist_cjs_js_node_modules_postcss_loader_dist_cjs_js_general_css__WEBPACK_IMPORTED_MODULE_6__["default"] && _node_modules_css_loader_dist_cjs_js_node_modules_postcss_loader_dist_cjs_js_general_css__WEBPACK_IMPORTED_MODULE_6__["default"].locals ? _node_modules_css_loader_dist_cjs_js_node_modules_postcss_loader_dist_cjs_js_general_css__WEBPACK_IMPORTED_MODULE_6__["default"].locals : undefined); + + +/***/ }), + +/***/ "./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js": +/*!****************************************************************************!*\ + !*** ./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js ***! + \****************************************************************************/ +/***/ ((module) => { + + + +var stylesInDOM = []; +function getIndexByIdentifier(identifier) { + var result = -1; + for (var i = 0; i < stylesInDOM.length; i++) { + if (stylesInDOM[i].identifier === identifier) { + result = i; + break; + } + } + return result; +} +function modulesToDom(list, options) { + var idCountMap = {}; + var identifiers = []; + for (var i = 0; i < list.length; i++) { + var item = list[i]; + var id = options.base ? item[0] + options.base : item[0]; + var count = idCountMap[id] || 0; + var identifier = "".concat(id, " ").concat(count); + idCountMap[id] = count + 1; + var indexByIdentifier = getIndexByIdentifier(identifier); + var obj = { + css: item[1], + media: item[2], + sourceMap: item[3], + supports: item[4], + layer: item[5] + }; + if (indexByIdentifier !== -1) { + stylesInDOM[indexByIdentifier].references++; + stylesInDOM[indexByIdentifier].updater(obj); + } else { + var updater = addElementStyle(obj, options); + options.byIndex = i; + stylesInDOM.splice(i, 0, { + identifier: identifier, + updater: updater, + references: 1 + }); + } + identifiers.push(identifier); + } + return identifiers; +} +function addElementStyle(obj, options) { + var api = options.domAPI(options); + api.update(obj); + var updater = function updater(newObj) { + if (newObj) { + if (newObj.css === obj.css && newObj.media === obj.media && newObj.sourceMap === obj.sourceMap && newObj.supports === obj.supports && newObj.layer === obj.layer) { + return; + } + api.update(obj = newObj); + } else { + api.remove(); + } + }; + return updater; +} +module.exports = function (list, options) { + options = options || {}; + list = list || []; + var lastIdentifiers = modulesToDom(list, options); + return function update(newList) { + newList = newList || []; + for (var i = 0; i < lastIdentifiers.length; i++) { + var identifier = lastIdentifiers[i]; + var index = getIndexByIdentifier(identifier); + stylesInDOM[index].references--; + } + var newLastIdentifiers = modulesToDom(newList, options); + for (var _i = 0; _i < lastIdentifiers.length; _i++) { + var _identifier = lastIdentifiers[_i]; + var _index = getIndexByIdentifier(_identifier); + if (stylesInDOM[_index].references === 0) { + stylesInDOM[_index].updater(); + stylesInDOM.splice(_index, 1); + } + } + lastIdentifiers = newLastIdentifiers; + }; +}; + +/***/ }), + +/***/ "./node_modules/style-loader/dist/runtime/insertBySelector.js": +/*!********************************************************************!*\ + !*** ./node_modules/style-loader/dist/runtime/insertBySelector.js ***! + \********************************************************************/ +/***/ ((module) => { + + + +var memo = {}; + +/* istanbul ignore next */ +function getTarget(target) { + if (typeof memo[target] === "undefined") { + var styleTarget = document.querySelector(target); + + // Special case to return head of iframe instead of iframe itself + if (window.HTMLIFrameElement && styleTarget instanceof window.HTMLIFrameElement) { + try { + // This will throw an exception if access to iframe is blocked + // due to cross-origin restrictions + styleTarget = styleTarget.contentDocument.head; + } catch (e) { + // istanbul ignore next + styleTarget = null; + } + } + memo[target] = styleTarget; + } + return memo[target]; +} + +/* istanbul ignore next */ +function insertBySelector(insert, style) { + var target = getTarget(insert); + if (!target) { + throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid."); + } + target.appendChild(style); +} +module.exports = insertBySelector; + +/***/ }), + +/***/ "./node_modules/style-loader/dist/runtime/insertStyleElement.js": +/*!**********************************************************************!*\ + !*** ./node_modules/style-loader/dist/runtime/insertStyleElement.js ***! + \**********************************************************************/ +/***/ ((module) => { + + + +/* istanbul ignore next */ +function insertStyleElement(options) { + var element = document.createElement("style"); + options.setAttributes(element, options.attributes); + options.insert(element, options.options); + return element; +} +module.exports = insertStyleElement; + +/***/ }), + +/***/ "./node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js": +/*!**********************************************************************************!*\ + !*** ./node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js ***! + \**********************************************************************************/ +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + + + +/* istanbul ignore next */ +function setAttributesWithoutAttributes(styleElement) { + var nonce = true ? __webpack_require__.nc : 0; + if (nonce) { + styleElement.setAttribute("nonce", nonce); + } +} +module.exports = setAttributesWithoutAttributes; + +/***/ }), + +/***/ "./node_modules/style-loader/dist/runtime/styleDomAPI.js": +/*!***************************************************************!*\ + !*** ./node_modules/style-loader/dist/runtime/styleDomAPI.js ***! + \***************************************************************/ +/***/ ((module) => { + + + +/* istanbul ignore next */ +function apply(styleElement, options, obj) { + var css = ""; + if (obj.supports) { + css += "@supports (".concat(obj.supports, ") {"); + } + if (obj.media) { + css += "@media ".concat(obj.media, " {"); + } + var needLayer = typeof obj.layer !== "undefined"; + if (needLayer) { + css += "@layer".concat(obj.layer.length > 0 ? " ".concat(obj.layer) : "", " {"); + } + css += obj.css; + if (needLayer) { + css += "}"; + } + if (obj.media) { + css += "}"; + } + if (obj.supports) { + css += "}"; + } + var sourceMap = obj.sourceMap; + if (sourceMap && typeof btoa !== "undefined") { + css += "\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))), " */"); + } + + // For old IE + /* istanbul ignore if */ + options.styleTagTransform(css, styleElement, options.options); +} +function removeStyleElement(styleElement) { + // istanbul ignore if + if (styleElement.parentNode === null) { + return false; + } + styleElement.parentNode.removeChild(styleElement); +} + +/* istanbul ignore next */ +function domAPI(options) { + if (typeof document === "undefined") { + return { + update: function update() {}, + remove: function remove() {} + }; + } + var styleElement = options.insertStyleElement(options); + return { + update: function update(obj) { + apply(styleElement, options, obj); + }, + remove: function remove() { + removeStyleElement(styleElement); + } + }; +} +module.exports = domAPI; + +/***/ }), + +/***/ "./node_modules/style-loader/dist/runtime/styleTagTransform.js": +/*!*********************************************************************!*\ + !*** ./node_modules/style-loader/dist/runtime/styleTagTransform.js ***! + \*********************************************************************/ +/***/ ((module) => { + + + +/* istanbul ignore next */ +function styleTagTransform(css, styleElement) { + if (styleElement.styleSheet) { + styleElement.styleSheet.cssText = css; + } else { + while (styleElement.firstChild) { + styleElement.removeChild(styleElement.firstChild); + } + styleElement.appendChild(document.createTextNode(css)); + } +} +module.exports = styleTagTransform; + +/***/ }), + +/***/ "react-dom": +/*!***************************!*\ + !*** external "ReactDOM" ***! + \***************************/ +/***/ ((module) => { + +module.exports = ReactDOM; + +/***/ }), + +/***/ "@wordpress/components": +/*!********************************!*\ + !*** external "wp.components" ***! + \********************************/ +/***/ ((module) => { + +module.exports = wp.components; + +/***/ }), + +/***/ "@wordpress/data": +/*!**************************!*\ + !*** external "wp.data" ***! + \**************************/ +/***/ ((module) => { + +module.exports = wp.data; + +/***/ }), + +/***/ "@wordpress/element": +/*!*****************************!*\ + !*** external "wp.element" ***! + \*****************************/ +/***/ ((module) => { + +module.exports = wp.element; + +/***/ }), + +/***/ "@wordpress/i18n": +/*!**************************!*\ + !*** external "wp.i18n" ***! + \**************************/ +/***/ ((module) => { + +module.exports = wp.i18n; + +/***/ }), + +/***/ "@wordpress/url": +/*!*************************!*\ + !*** external "wp.url" ***! + \*************************/ +/***/ ((module) => { + +module.exports = wp.url; + +/***/ }) + +/******/ }); +/************************************************************************/ +/******/ // The module cache +/******/ var __webpack_module_cache__ = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ // Check if module is in cache +/******/ var cachedModule = __webpack_module_cache__[moduleId]; +/******/ if (cachedModule !== undefined) { +/******/ return cachedModule.exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = __webpack_module_cache__[moduleId] = { +/******/ id: moduleId, +/******/ // no module.loaded needed +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/************************************************************************/ +/******/ /* webpack/runtime/compat get default export */ +/******/ (() => { +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = (module) => { +/******/ var getter = module && module.__esModule ? +/******/ () => (module['default']) : +/******/ () => (module); +/******/ __webpack_require__.d(getter, { a: getter }); +/******/ return getter; +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/define property getters */ +/******/ (() => { +/******/ // define getter functions for harmony exports +/******/ __webpack_require__.d = (exports, definition) => { +/******/ for(var key in definition) { +/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { +/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); +/******/ } +/******/ } +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/hasOwnProperty shorthand */ +/******/ (() => { +/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) +/******/ })(); +/******/ +/******/ /* webpack/runtime/make namespace object */ +/******/ (() => { +/******/ // define __esModule on exports +/******/ __webpack_require__.r = (exports) => { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/nonce */ +/******/ (() => { +/******/ __webpack_require__.nc = undefined; +/******/ })(); +/******/ +/************************************************************************/ +var __webpack_exports__ = {}; +// This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. +(() => { +/*!*******************************************!*\ + !*** ./assets/jsx/backup-panel/index.jsx ***! + \*******************************************/ +__webpack_require__.r(__webpack_exports__); +/* harmony import */ var react_dom_client__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react-dom/client */ "./node_modules/react-dom/client.js"); +/* harmony import */ var _components_backup_panel__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./components/backup-panel */ "./assets/jsx/backup-panel/components/backup-panel.jsx"); +/* harmony import */ var _css_general_css__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./css/general.css */ "./assets/jsx/backup-panel/css/general.css"); + + + +var container = document.getElementById("backup-panel"); +if (container) { + var component = /*#__PURE__*/React.createElement(_components_backup_panel__WEBPACK_IMPORTED_MODULE_1__["default"], null); + (0,react_dom_client__WEBPACK_IMPORTED_MODULE_0__.createRoot)(container).render(component); +} +})(); + +/******/ })() +; +//# sourceMappingURL=backupPanel.js.map \ No newline at end of file diff --git a/assets/js/backupPanel.min.js b/assets/js/backupPanel.min.js new file mode 100644 index 000000000..0175bda2a --- /dev/null +++ b/assets/js/backupPanel.min.js @@ -0,0 +1,2 @@ +/*! For license information please see backupPanel.min.js.LICENSE.txt */ +(()=>{"use strict";var t={4337:(t,e,n)=>{n.d(e,{A:()=>c});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([t.id,"ul#export-actions {\n margin-bottom: 20px;\n}\n\nul#export-actions li ul {\n margin-top: 10px;\n border: 1px solid #e0e0e0e5;\n padding: 10px;\n background-color: #fff;\n}\n\nul#export-actions span {\n display: inline-block;\n}\n\n.pe-settings-tab__backup-status {\n margin-left: 5px;\n}\n\n.pe-settings-tab__backup-actions button {\n margin-left: 5px !important;\n}\n\n.pe-settings-tab__backup-container {\n margin-left: 30px;\n}\n\n.pe-settings-tab__export-cancel-button {\n margin-left: 10px !important;\n}\n\n.components-snackbar-list {\n position: fixed !important;\n bottom: 20px;\n left: 182px;\n transform: none;\n z-index: 100000;\n}\n\n.components-snackbar {\n margin-bottom: 10px;\n}\n\n.wp-admin.folded .components-snackbar-list {\n left: 58px;\n}\n\n.pe-settings-tab__import-file-upload {\n margin-bottom: 20px;\n}\n\n.pe-settings-tab__import-file-upload-info {\n margin-top: 10px;\n font-size: 14px;\n}\n\n.pe-dropzone {\n border: 3px dashed #ccc;\n padding: 20px;\n text-align: center;\n}\n\n.pe-dropzone--active {\n border-color: #0073aa;\n}\n\n.pe-dropzone p {\n margin: 0;\n}\n\n",""]);const c=i},6314:t=>{t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var n="",r=void 0!==e[5];return e[4]&&(n+="@supports (".concat(e[4],") {")),e[2]&&(n+="@media ".concat(e[2]," {")),r&&(n+="@layer".concat(e[5].length>0?" ".concat(e[5]):""," {")),n+=t(e),r&&(n+="}"),e[2]&&(n+="}"),e[4]&&(n+="}"),n})).join("")},e.i=function(t,n,r,o,a){"string"==typeof t&&(t=[[null,t,void 0]]);var i={};if(r)for(var c=0;c0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=a),n&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=n):u[2]=n),o&&(u[4]?(u[1]="@supports (".concat(u[4],") {").concat(u[1],"}"),u[4]=o):u[4]="".concat(o)),e.push(u))}},e}},1601:t=>{t.exports=function(t){return t[1]}},5338:(t,e,n)=>{var r=n(5206);e.H=r.createRoot,r.hydrateRoot},5072:t=>{var e=[];function n(t){for(var n=-1,r=0;r{var e={};t.exports=function(t,n){var r=function(t){if(void 0===e[t]){var n=document.querySelector(t);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(t){n=null}e[t]=n}return e[t]}(t);if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}},540:t=>{t.exports=function(t){var e=document.createElement("style");return t.setAttributes(e,t.attributes),t.insert(e,t.options),e}},5056:(t,e,n)=>{t.exports=function(t){var e=n.nc;e&&t.setAttribute("nonce",e)}},7825:t=>{t.exports=function(t){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var e=t.insertStyleElement(t);return{update:function(n){!function(t,e,n){var r="";n.supports&&(r+="@supports (".concat(n.supports,") {")),n.media&&(r+="@media ".concat(n.media," {"));var o=void 0!==n.layer;o&&(r+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),r+=n.css,o&&(r+="}"),n.media&&(r+="}"),n.supports&&(r+="}");var a=n.sourceMap;a&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(a))))," */")),e.styleTagTransform(r,t,e.options)}(e,t,n)},remove:function(){!function(t){if(null===t.parentNode)return!1;t.parentNode.removeChild(t)}(e)}}}},1113:t=>{t.exports=function(t,e){if(e.styleSheet)e.styleSheet.cssText=t;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(t))}}},5206:t=>{t.exports=ReactDOM}},e={};function n(r){var o=e[r];if(void 0!==o)return o.exports;var a=e[r]={id:r,exports:{}};return t[r](a,a.exports,n),a.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),n.nc=void 0;var r=n(5338);const o=wp.i18n,a=wp.element,i=wp.components,c=wp.data;var l=function(t){var e=t.title,n=t.description,r=t.children;return React.createElement("div",{className:"pe-settings-tab"},React.createElement("h2",null,e),React.createElement("p",null,n),r)};function s(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,o,a,i,c=[],l=!0,s=!1;try{if(a=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=a.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&&(i=n.return(),Object(i)!==i))return}finally{if(s)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return u(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)?u(t,e):void 0}}(t,e)||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.")}()}function u(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);nt.length)&&(e=t.length);for(var n=0,r=Array(e);n=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var l=r.call(i,"catchLoc"),s=r.call(i,"finallyLoc");if(l&&s){if(this.prev=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),C(n),b}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var r=n.completion;if("throw"===r.type){var o=r.arg;C(n)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,n,r){return this.delegate={iterator:T(e),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=t),b}},e}function v(t,e,n,r,o,a,i){try{var c=t[a](i),l=c.value}catch(t){return void n(t)}c.done?e(l):Promise.resolve(l).then(r,o)}function b(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,o,a,i,c=[],l=!0,s=!1;try{if(a=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=a.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&&(i=n.return(),Object(i)!==i))return}finally{if(s)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return g(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)?g(t,e):void 0}}(t,e)||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.")}()}function g(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n0,onChange:function(t){return n(t)},disabled:0===S.length}),e&&S.length>0&&React.createElement("div",{className:"pe-settings-tab__backup-container"},T&&React.createElement("div",null,React.createElement(i.ToggleControl,{label:(0,o.__)("Include screenshots","post-expirator"),checked:d,onChange:function(t){return h(t)}})),React.createElement(m,{items:S,selectedItems:A,onSelect:j}))),React.createElement("li",{key:"export-action-settings"},React.createElement(i.CheckboxControl,{label:(0,o.__)("Action Settings","post-expirator"),checked:s,onChange:function(t){return u(t)}}),s&&React.createElement("div",{className:"pe-settings-tab__backup-container"},React.createElement(m,{items:I,selectedItems:D,onSelect:C})))),(e||s)&&React.createElement(i.Button,{isPrimary:!0,onClick:B,isBusy:w,disabled:w},w?(0,o.__)("Exporting...","post-expirator"):(0,o.__)("Export","post-expirator")),w&&React.createElement(i.Button,{isLink:!0,onClick:function(){var t=O.current;t&&t.abort()},className:"pe-settings-tab__export-cancel-button"},(0,o.__)("Cancel","post-expirator")))};function _(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);nt.length)&&(e=t.length);for(var n=0,r=Array(e);n{"use strict";var e={1461:(e,t,n)=>{n.d(t,{A:()=>s});var a=n(1601),r=n.n(a),o=n(6314),i=n.n(o)()(r());i.push([e.id,".publishpress-future-date-preview .publishpress-future-date-preview-value {\n font-family: monospace;\n background-color: #e7e7e7;\n padding: 2px 4px;\n}\n\n.publishpress-future-date-preview.compact .publishpress-future-date-preview-label {\n display: block;\n}\n\n.publishpress-future-date-preview.compact {\n margin-bottom: 8px;\n}\n\n.publishpress-future-date-preview.compact h4 {\n font-size: 11px;\n font-weight: 500;\n line-height: 1.4;\n text-transform: uppercase;\n display: inline-block;\n margin-bottom: calc(8px);\n padding: 0px;\n flex-shrink: 0;\n margin-right: 12px;\n max-width: 75%;\n margin-top: 0;\n}\n\n.publishpress-future-notice.publishpress-future-notice-error {\n color: #dc3232;\n}\n",""]);const s=i},6314:e=>{e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",a=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),a&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),a&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,a,r,o){"string"==typeof e&&(e=[[null,e,void 0]]);var i={};if(a)for(var s=0;s0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=o),n&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=n):u[2]=n),r&&(u[4]?(u[1]="@supports (".concat(u[4],") {").concat(u[1],"}"),u[4]=r):u[4]="".concat(r)),t.push(u))}},t}},1601:e=>{e.exports=function(e){return e[1]}},9922:(e,t,n)=>{n.r(t),n.d(t,{default:()=>b});var a=n(5072),r=n.n(a),o=n(7825),i=n.n(o),s=n(7659),c=n.n(s),l=n(5056),u=n.n(l),m=n(540),f=n.n(m),d=n(1113),p=n.n(d),y=n(1461),g={};g.styleTagTransform=p(),g.setAttributes=u(),g.insert=c().bind(null,"head"),g.domAPI=i(),g.insertStyleElement=f(),r()(y.A,g);const b=y.A&&y.A.locals?y.A.locals:void 0},5072:e=>{var t=[];function n(e){for(var n=-1,a=0;a{var t={};e.exports=function(e,n){var a=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!a)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");a.appendChild(n)}},540:e=>{e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},5056:(e,t,n)=>{e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},7825:e=>{e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var a="";n.supports&&(a+="@supports (".concat(n.supports,") {")),n.media&&(a+="@media ".concat(n.media," {"));var r=void 0!==n.layer;r&&(a+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),a+=n.css,r&&(a+="}"),n.media&&(a+="}"),n.supports&&(a+="}");var o=n.sourceMap;o&&"undefined"!=typeof btoa&&(a+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(o))))," */")),t.styleTagTransform(a,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},1113:e=>{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 n(a){var r=t[a];if(void 0!==r)return r.exports;var o=t[a]={id:a,exports:{}};return e[a](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 a in t)n.o(t,a)&&!n.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.nc=void 0;var a=function(e){var t=new Date(o(e)),n=t.getFullYear(),a=("0"+(t.getMonth()+1)).slice(-2),r=("0"+t.getDate()).slice(-2),i=("0"+t.getHours()).slice(-2),s=("0"+t.getMinutes()).slice(-2),c=("0"+t.getSeconds()).slice(-2);return"".concat(n,"-").concat(a,"-").concat(r," ").concat(i,":").concat(s,":").concat(c)},r=function(e){return parseInt(e).toString().length<=10},o=function(e){return e=parseInt(e),r()?e:e/1e3};function i(e){return i="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},i(e)}const s=wp.data;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 l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function u(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,a=Array(t);n0&&u&&(oe=function(e){return"object"!==T(e)||null===e?{}:e.map((function(e){return u[e]}))}(o),"string"==typeof(ie=oe?(Array.isArray(oe)||"object"!==i(oe)||(oe=Object.values(oe)),oe.filter((function(e){return null!=e&&""!==e}))):[])&&(ie=[]));var se=[];"object"===T(l)&&null!==l&&(se=Object.keys(l));var ce,le=d?"future-action-panel":"future-action-panel hidden-calendar",ue=d?"future-action-panel-content":"future-action-panel-content hidden-calendar",me=d?"future-action-date-panel":"future-action-date-panel hidden-calendar";ce="inherited"===e.timeFormat?!e.is12Hour:"24h"===e.timeFormat;var fe=e.actionsSelectOptions;e.taxonomy||(fe=e.actionsSelectOptions.filter((function(e){return-1===["category","category-add","category-remove","category-remove-all"].indexOf(e.value)})));var de=function(e,t){var n=e.split("{"),a=[];a.push(n.shift());var r,o=function(e){var t="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!t){if(Array.isArray(e)||(t=N(e))){t&&(e=t);var n=0,a=function(){};return{s:a,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:a}}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 r,o=!0,i=!1;return{s:function(){t=t.call(e)},n:function(){var e=t.next();return o=e.done,e},e:function(e){i=!0,r=e},f:function(){try{o||null==t.return||t.return()}finally{if(i)throw r}}}}(n);try{for(o.s();!(r=o.n()).done;){var i=x(r.value.split("}"),2),s=i[0],c=i[1];a.push(React.createElement("a",{href:t,target:"_blank",key:t},s)),a.push(c)}}catch(e){o.e(e)}finally{o.f()}return a}(e.strings.timezoneSettingsHelp,"/wp-admin/options-general.php#timezone_string"),pe=String(n).includes("category")&&"category-remove-all"!==n,ye=c;switch(n){case"category":ye=e.strings.newTerms.replace("%s",c);break;case"category-remove":ye=e.strings.removeTerms.replace("%s",c);break;case"category-add":ye=e.strings.addTerms.replace("%s",c)}return F((function(){if(!r)return K(!0),void A("");K(function(){var t=!0;if(!r)return A(""),!0;n||(A(e.strings.errorActionRequired),t=!1),a||(A(e.strings.errorDateRequired),t=!1),a&&new Date(a)e.length)&&(t=e.length);for(var n=0,a=Array(t);n0&&void 0!==arguments[0]?arguments[0]:t,r=arguments.length>1?arguments[1]:void 0;switch(r.type){case"SET_POST_ID":return u(u({},n),{},{postId:r.postId});case"SET_ACTION":return u(u({},n),{},{action:r.action});case"SET_NEW_STATUS":return u(u({},n),{},{newStatus:r.newStatus});case"SET_DATE":return"number"==typeof r.date||(e=r.date,isNaN(e))||(r.date=parseInt(r.date)),"string"==typeof r.date&&(r.date=new Date(r.date).getTime()),r.date=o(r.date),r.date=a(r.date),u(u({},n),{},{date:r.date});case"SET_ENABLED":return u(u({},n),{},{enabled:r.enabled});case"SET_TERMS":return u(u({},n),{},{terms:r.terms});case"SET_TAXONOMY":return u(u({},n),{},{taxonomy:r.taxonomy});case"SET_TERMS_LIST_BY_NAME":return u(u({},n),{},{termsListByName:r.termsListByName});case"SET_TERMS_LIST_BY_ID":return u(u({},n),{},{termsListById:r.termsListById});case"SET_TAXONOMY_NAME":return u(u({},n),{},{taxonomyName:r.taxonomyName});case"SET_CHANGE_ACTION":return u(u({},n),{},{changeAction:r.changeAction});case"SET_CALENDAR_IS_VISIBLE":return u(u({},n),{},{calendarIsVisible:r.calendarIsVisible});case"SET_HAS_VALID_DATA":return u(u({},n),{},{hasValidData:r.hasValidData});case"SET_EXTRA_DATA":return u(u({},n),{},{extraData:u({},r.extraData)});case"SET_EXTRA_DATA_BY_NAME":var i=u(u({},n.extraData),{},m({},r.name,r.value));return u(u({},n),{},{extraData:u({},i)})}return n},actions:{setPostId:function(e){return{type:"SET_POST_ID",postId:e}},setAction:function(e){return{type:"SET_ACTION",action:e}},setNewStatus:function(e){return{type:"SET_NEW_STATUS",newStatus:e}},setDate:function(e){return{type:"SET_DATE",date:e}},setEnabled:function(e){return{type:"SET_ENABLED",enabled:e}},setTerms:function(e){return{type:"SET_TERMS",terms:e}},setTaxonomy:function(e){return{type:"SET_TAXONOMY",taxonomy:e}},setTermsListByName:function(e){return{type:"SET_TERMS_LIST_BY_NAME",termsListByName:e}},setTermsListById:function(e){return{type:"SET_TERMS_LIST_BY_ID",termsListById:e}},setTaxonomyName:function(e){return{type:"SET_TAXONOMY_NAME",taxonomyName:e}},setIsFetchingTerms:function(e){return{type:"SET_IS_FETCHING_TERMS",isFetchingTerms:e}},setChangeAction:function(e){return{type:"SET_CHANGE_ACTION",changeAction:e}},setCalendarIsVisible:function(e){return{type:"SET_CALENDAR_IS_VISIBLE",calendarIsVisible:e}},setHasValidData:function(e){return{type:"SET_HAS_VALID_DATA",hasValidData:e}},setExtraData:function(e){return{type:"SET_EXTRA_DATA",extraData:e}},setExtraDataByName:function(e,t){return{type:"SET_EXTRA_DATA_BY_NAME",name:e,value:t}}},selectors:{getPostId:function(e){return e.postId},getAction:function(e){return e.action},getNewStatus:function(e){return e.newStatus},getDate:function(e){return e.date},getEnabled:function(e){return e.enabled},getTerms:function(e){return e.terms},getTaxonomy:function(e){return e.taxonomy},getTermsListByName:function(e){return e.termsListByName},getTermsListById:function(e){return e.termsListById},getTaxonomyName:function(e){return e.taxonomyName},getIsFetchingTerms:function(e){return e.isFetchingTerms},getChangeAction:function(e){return e.changeAction},getCalendarIsVisible:function(e){return e.calendarIsVisible},getHasValidData:function(e){return e.hasValidData},getExtraData:function(e){return e.extraData},getExtraDataByName:function(e,t){return e.extraData[t]||null}}});(0,s.register)(n)}({name:ae,defaultState:{postId:publishpressFutureBlockEditorConfig.postId,autoEnable:Z.autoEnable,action:Z.expireType,newStatus:Z.newStatus,date:ee,taxonomy:Z.taxonomy,terms:Z.terms}})}),[]),React.createElement(X,{postType:(0,s.select)("core/editor").getCurrentPostType(),isCleanNewPost:(0,s.select)("core/editor").isCleanNewPost(),actionsSelectOptions:z,statusesSelectOptions:te,is12Hour:G,timeFormat:Q,startOfWeek:$,storeName:ae,strings:J,taxonomyName:K,postTypeDefaultConfig:Z,hideCalendarByDefault:ne})}})})(); \ No newline at end of file +(()=>{"use strict";var e={1461:(e,t,n)=>{n.d(t,{A:()=>s});var a=n(1601),r=n.n(a),o=n(6314),i=n.n(o)()(r());i.push([e.id,".publishpress-future-date-preview .publishpress-future-date-preview-value {\n font-family: monospace;\n background-color: #e7e7e7;\n padding: 2px 4px;\n}\n\n.publishpress-future-date-preview.compact .publishpress-future-date-preview-label {\n display: block;\n}\n\n.publishpress-future-date-preview.compact {\n margin-bottom: 8px;\n}\n\n.publishpress-future-date-preview.compact h4 {\n font-size: 11px;\n font-weight: 500;\n line-height: 1.4;\n text-transform: uppercase;\n display: inline-block;\n margin-bottom: calc(8px);\n padding: 0px;\n flex-shrink: 0;\n margin-right: 12px;\n max-width: 75%;\n margin-top: 0;\n}\n\n.publishpress-future-notice.publishpress-future-notice-error {\n color: #dc3232;\n}\n",""]);const s=i},6314:e=>{e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",a=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),a&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),a&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,a,r,o){"string"==typeof e&&(e=[[null,e,void 0]]);var i={};if(a)for(var s=0;s0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=o),n&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=n):u[2]=n),r&&(u[4]?(u[1]="@supports (".concat(u[4],") {").concat(u[1],"}"),u[4]=r):u[4]="".concat(r)),t.push(u))}},t}},1601:e=>{e.exports=function(e){return e[1]}},9922:(e,t,n)=>{n.r(t),n.d(t,{default:()=>b});var a=n(5072),r=n.n(a),o=n(7825),i=n.n(o),s=n(7659),c=n.n(s),l=n(5056),u=n.n(l),m=n(540),f=n.n(m),d=n(1113),p=n.n(d),y=n(1461),g={};g.styleTagTransform=p(),g.setAttributes=u(),g.insert=c().bind(null,"head"),g.domAPI=i(),g.insertStyleElement=f(),r()(y.A,g);const b=y.A&&y.A.locals?y.A.locals:void 0},5072:e=>{var t=[];function n(e){for(var n=-1,a=0;a{var t={};e.exports=function(e,n){var a=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!a)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");a.appendChild(n)}},540:e=>{e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},5056:(e,t,n)=>{e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},7825:e=>{e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var a="";n.supports&&(a+="@supports (".concat(n.supports,") {")),n.media&&(a+="@media ".concat(n.media," {"));var r=void 0!==n.layer;r&&(a+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),a+=n.css,r&&(a+="}"),n.media&&(a+="}"),n.supports&&(a+="}");var o=n.sourceMap;o&&"undefined"!=typeof btoa&&(a+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(o))))," */")),t.styleTagTransform(a,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},1113:e=>{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 n(a){var r=t[a];if(void 0!==r)return r.exports;var o=t[a]={id:a,exports:{}};return e[a](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 a in t)n.o(t,a)&&!n.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.nc=void 0;var a=function(e){var t=new Date(o(e)),n=t.getFullYear(),a=("0"+(t.getMonth()+1)).slice(-2),r=("0"+t.getDate()).slice(-2),i=("0"+t.getHours()).slice(-2),s=("0"+t.getMinutes()).slice(-2),c=("0"+t.getSeconds()).slice(-2);return"".concat(n,"-").concat(a,"-").concat(r," ").concat(i,":").concat(s,":").concat(c)},r=function(e){return parseInt(e).toString().length<=10},o=function(e){return e=parseInt(e),r()?e:e/1e3};function i(e){return i="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},i(e)}const s=wp.data;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 l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function u(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,a=Array(t);n0&&u&&(oe=function(e){return"object"!==T(e)||null===e?{}:e.map((function(e){return u[e]}))}(o),"string"==typeof(ie=oe?(Array.isArray(oe)||"object"!==i(oe)||(oe=Object.values(oe)),oe.filter((function(e){return null!=e&&""!==e}))):[])&&(ie=[]));var se=[];"object"===T(l)&&null!==l&&(se=Object.keys(l));var ce,le=d?"future-action-panel":"future-action-panel hidden-calendar",ue=d?"future-action-panel-content":"future-action-panel-content hidden-calendar",me=d?"future-action-date-panel":"future-action-date-panel hidden-calendar";ce="inherited"===e.timeFormat?!e.is12Hour:"24h"===e.timeFormat;var fe=e.actionsSelectOptions;e.taxonomy||(fe=e.actionsSelectOptions.filter((function(e){return-1===["category","category-add","category-remove","category-remove-all"].indexOf(e.value)})));var de=function(e,t){var n=e.split("{"),a=[];a.push(n.shift());var r,o=function(e){var t="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!t){if(Array.isArray(e)||(t=N(e))){t&&(e=t);var n=0,a=function(){};return{s:a,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:a}}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 r,o=!0,i=!1;return{s:function(){t=t.call(e)},n:function(){var e=t.next();return o=e.done,e},e:function(e){i=!0,r=e},f:function(){try{o||null==t.return||t.return()}finally{if(i)throw r}}}}(n);try{for(o.s();!(r=o.n()).done;){var i=x(r.value.split("}"),2),s=i[0],c=i[1];a.push(React.createElement("a",{href:t,target:"_blank",key:t},s)),a.push(c)}}catch(e){o.e(e)}finally{o.f()}return a}(e.strings.timezoneSettingsHelp,"/wp-admin/options-general.php#timezone_string"),pe=String(n).includes("category")&&"category-remove-all"!==n,ye=c;switch(n){case"category":ye=e.strings.newTerms.replace("%s",c);break;case"category-remove":ye=e.strings.removeTerms.replace("%s",c);break;case"category-add":ye=e.strings.addTerms.replace("%s",c)}return F((function(){if(!r)return K(!0),void A("");K(function(){var t=!0;if(!r)return A(""),!0;n||(A(e.strings.errorActionRequired),t=!1),a||(A(e.strings.errorDateRequired),t=!1),a&&new Date(a)e.length)&&(t=e.length);for(var n=0,a=Array(t);n0&&void 0!==arguments[0]?arguments[0]:t,r=arguments.length>1?arguments[1]:void 0;switch(r.type){case"SET_POST_ID":return u(u({},n),{},{postId:r.postId});case"SET_ACTION":return u(u({},n),{},{action:r.action});case"SET_NEW_STATUS":return u(u({},n),{},{newStatus:r.newStatus});case"SET_DATE":return"number"==typeof r.date||(e=r.date,isNaN(e))||(r.date=parseInt(r.date)),"string"==typeof r.date&&(r.date=new Date(r.date).getTime()),r.date=o(r.date),r.date=a(r.date),u(u({},n),{},{date:r.date});case"SET_ENABLED":return u(u({},n),{},{enabled:r.enabled});case"SET_TERMS":return u(u({},n),{},{terms:r.terms});case"SET_TAXONOMY":return u(u({},n),{},{taxonomy:r.taxonomy});case"SET_TERMS_LIST_BY_NAME":return u(u({},n),{},{termsListByName:r.termsListByName});case"SET_TERMS_LIST_BY_ID":return u(u({},n),{},{termsListById:r.termsListById});case"SET_TAXONOMY_NAME":return u(u({},n),{},{taxonomyName:r.taxonomyName});case"SET_CHANGE_ACTION":return u(u({},n),{},{changeAction:r.changeAction});case"SET_CALENDAR_IS_VISIBLE":return u(u({},n),{},{calendarIsVisible:r.calendarIsVisible});case"SET_HAS_VALID_DATA":return u(u({},n),{},{hasValidData:r.hasValidData});case"SET_EXTRA_DATA":return u(u({},n),{},{extraData:u({},r.extraData)});case"SET_EXTRA_DATA_BY_NAME":var i=u(u({},n.extraData),{},m({},r.name,r.value));return u(u({},n),{},{extraData:u({},i)})}return n},actions:{setPostId:function(e){return{type:"SET_POST_ID",postId:e}},setAction:function(e){return{type:"SET_ACTION",action:e}},setNewStatus:function(e){return{type:"SET_NEW_STATUS",newStatus:e}},setDate:function(e){return{type:"SET_DATE",date:e}},setEnabled:function(e){return{type:"SET_ENABLED",enabled:e}},setTerms:function(e){return{type:"SET_TERMS",terms:e}},setTaxonomy:function(e){return{type:"SET_TAXONOMY",taxonomy:e}},setTermsListByName:function(e){return{type:"SET_TERMS_LIST_BY_NAME",termsListByName:e}},setTermsListById:function(e){return{type:"SET_TERMS_LIST_BY_ID",termsListById:e}},setTaxonomyName:function(e){return{type:"SET_TAXONOMY_NAME",taxonomyName:e}},setIsFetchingTerms:function(e){return{type:"SET_IS_FETCHING_TERMS",isFetchingTerms:e}},setChangeAction:function(e){return{type:"SET_CHANGE_ACTION",changeAction:e}},setCalendarIsVisible:function(e){return{type:"SET_CALENDAR_IS_VISIBLE",calendarIsVisible:e}},setHasValidData:function(e){return{type:"SET_HAS_VALID_DATA",hasValidData:e}},setExtraData:function(e){return{type:"SET_EXTRA_DATA",extraData:e}},setExtraDataByName:function(e,t){return{type:"SET_EXTRA_DATA_BY_NAME",name:e,value:t}}},selectors:{getPostId:function(e){return e.postId},getAction:function(e){return e.action},getNewStatus:function(e){return e.newStatus},getDate:function(e){return e.date},getEnabled:function(e){return e.enabled},getTerms:function(e){return e.terms},getTaxonomy:function(e){return e.taxonomy},getTermsListByName:function(e){return e.termsListByName},getTermsListById:function(e){return e.termsListById},getTaxonomyName:function(e){return e.taxonomyName},getIsFetchingTerms:function(e){return e.isFetchingTerms},getChangeAction:function(e){return e.changeAction},getCalendarIsVisible:function(e){return e.calendarIsVisible},getHasValidData:function(e){return e.hasValidData},getExtraData:function(e){return e.extraData},getExtraDataByName:function(e,t){return e.extraData[t]||null}}});(0,s.register)(n)}({name:ae,defaultState:{postId:publishpressFutureBlockEditorConfig.postId,autoEnable:Z.autoEnable,action:Z.expireType,newStatus:Z.newStatus,date:ee,taxonomy:Z.taxonomy,terms:Z.terms}})}),[]),React.createElement(X,{postType:(0,s.select)("core/editor").getCurrentPostType(),isCleanNewPost:(0,s.select)("core/editor").isCleanNewPost(),actionsSelectOptions:z,statusesSelectOptions:te,is12Hour:G,timeFormat:Q,startOfWeek:$,storeName:ae,strings:J,taxonomyName:K,postTypeDefaultConfig:Z,hideCalendarByDefault:ne})}})})(); \ No newline at end of file diff --git a/assets/js/bulkEdit.js b/assets/js/bulkEdit.js index cf5746314..53371d86b 100644 --- a/assets/js/bulkEdit.js +++ b/assets/js/bulkEdit.js @@ -584,7 +584,7 @@ var FutureActionPanel = function FutureActionPanel(props) { fontWeight: 'bold', marginBottom: '10px' } - }, props.strings.futureActions), /*#__PURE__*/React.createElement(_FutureActionPanelTop__WEBPACK_IMPORTED_MODULE_5__.FutureActionPanelTop.Slot, { + }, props.strings.panelTitle), /*#__PURE__*/React.createElement(_FutureActionPanelTop__WEBPACK_IMPORTED_MODULE_5__.FutureActionPanelTop.Slot, { fillProps: { storeName: props.storeName } diff --git a/assets/js/bulkEdit.min.js b/assets/js/bulkEdit.min.js index a9a227441..07f804af5 100644 --- a/assets/js/bulkEdit.min.js +++ b/assets/js/bulkEdit.min.js @@ -1 +1 @@ -(()=>{"use strict";var e={1461:(e,t,n)=>{n.d(t,{A:()=>s});var a=n(1601),r=n.n(a),o=n(6314),i=n.n(o)()(r());i.push([e.id,".publishpress-future-date-preview .publishpress-future-date-preview-value {\n font-family: monospace;\n background-color: #e7e7e7;\n padding: 2px 4px;\n}\n\n.publishpress-future-date-preview.compact .publishpress-future-date-preview-label {\n display: block;\n}\n\n.publishpress-future-date-preview.compact {\n margin-bottom: 8px;\n}\n\n.publishpress-future-date-preview.compact h4 {\n font-size: 11px;\n font-weight: 500;\n line-height: 1.4;\n text-transform: uppercase;\n display: inline-block;\n margin-bottom: calc(8px);\n padding: 0px;\n flex-shrink: 0;\n margin-right: 12px;\n max-width: 75%;\n margin-top: 0;\n}\n\n.publishpress-future-notice.publishpress-future-notice-error {\n color: #dc3232;\n}\n",""]);const s=i},6314:e=>{e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",a=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),a&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),a&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,a,r,o){"string"==typeof e&&(e=[[null,e,void 0]]);var i={};if(a)for(var s=0;s0?" ".concat(l[5]):""," {").concat(l[1],"}")),l[5]=o),n&&(l[2]?(l[1]="@media ".concat(l[2]," {").concat(l[1],"}"),l[2]=n):l[2]=n),r&&(l[4]?(l[1]="@supports (".concat(l[4],") {").concat(l[1],"}"),l[4]=r):l[4]="".concat(r)),t.push(l))}},t}},1601:e=>{e.exports=function(e){return e[1]}},5338:(e,t,n)=>{var a=n(5206);t.H=a.createRoot,a.hydrateRoot},9922:(e,t,n)=>{n.r(t),n.d(t,{default:()=>b});var a=n(5072),r=n.n(a),o=n(7825),i=n.n(o),s=n(7659),c=n.n(s),u=n(5056),l=n.n(u),m=n(540),d=n.n(m),f=n(1113),p=n.n(f),y=n(1461),g={};g.styleTagTransform=p(),g.setAttributes=l(),g.insert=c().bind(null,"head"),g.domAPI=i(),g.insertStyleElement=d(),r()(y.A,g);const b=y.A&&y.A.locals?y.A.locals:void 0},5072:e=>{var t=[];function n(e){for(var n=-1,a=0;a{var t={};e.exports=function(e,n){var a=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!a)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");a.appendChild(n)}},540:e=>{e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},5056:(e,t,n)=>{e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},7825:e=>{e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var a="";n.supports&&(a+="@supports (".concat(n.supports,") {")),n.media&&(a+="@media ".concat(n.media," {"));var r=void 0!==n.layer;r&&(a+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),a+=n.css,r&&(a+="}"),n.media&&(a+="}"),n.supports&&(a+="}");var o=n.sourceMap;o&&"undefined"!=typeof btoa&&(a+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(o))))," */")),t.styleTagTransform(a,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},1113:e=>{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))}}},5206:e=>{e.exports=ReactDOM}},t={};function n(a){var r=t[a];if(void 0!==r)return r.exports;var o=t[a]={id:a,exports:{}};return e[a](o,o.exports,n),o.exports}function a(e){return a="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},a(e)}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var a in t)n.o(t,a)&&!n.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.nc=void 0;var r=function(e){return document.getElementsByName(e)[0]};const o=wp.components;var i=function(e){var t=e.iconExpanded?e.iconExpanded:"arrow-up-alt2",n=e.iconCollapsed?e.iconCollapsed:"arrow-down-alt2",a=e.isExpanded?t:n,r=e.isExpanded?e.titleExpanded:e.titleCollapsed;return React.createElement(o.Button,{isSmall:!0,title:r,icon:a,onClick:function(){e.onClick&&e.onClick()},className:e.className})},s=function(e){var t=new Date(u(e)),n=t.getFullYear(),a=("0"+(t.getMonth()+1)).slice(-2),r=("0"+t.getDate()).slice(-2),o=("0"+t.getHours()).slice(-2),i=("0"+t.getMinutes()).slice(-2),s=("0"+t.getSeconds()).slice(-2);return"".concat(n,"-").concat(a,"-").concat(r," ").concat(o,":").concat(i,":").concat(s)},c=function(e){return parseInt(e).toString().length<=10},u=function(e){return e=parseInt(e),c()?e:e/1e3},l=function(e){var t,n=e.currentDate,a=e.onChange,r=e.is12Hour,i=e.startOfWeek;return"number"==typeof n&&(t=n,t=parseInt(t),n=c()?1e3*t:t),React.createElement(o.DateTimePicker,{currentDate:n,onChange:a,__nextRemoveHelpButton:!0,is12Hour:r,startOfWeek:i})};const m=wp.element;var d=function(e){var t=e.isExpanded,n=e.strings,a=e.onToggleCalendar,r=e.currentDate,o=e.onChangeDate,s=e.is12Hour,c=e.startOfWeek;return(0,m.useEffect)((function(){var e=document.querySelector(".future-action-calendar-toggle");if(e){var t=e.nextElementSibling;if(t){var n=t.querySelector(".components-datetime__time");if(n){var a=n.nextSibling;a&&t.insertBefore(e,a)}}}})),React.createElement(m.Fragment,null,React.createElement(i,{className:"future-action-calendar-toggle",isExpanded:t,iconExpanded:"arrow-up-alt2",iconCollapsed:"calendar",titleExpanded:n.hideCalendar,titleCollapsed:n.showCalendar,onClick:a}),React.createElement(l,{currentDate:r,onChange:o,__nextRemoveHelpButton:!0,is12Hour:s,startOfWeek:c}))};const f=wp.plugins;function p(){return p=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,a=Array(t);n0&&m&&(oe=function(e){return"object"!==h(e)||null===e?{}:e.map((function(e){return m[e]}))}(s),"string"==typeof(ie=oe?(Array.isArray(oe)||"object"!==a(oe)||(oe=Object.values(oe)),oe.filter((function(e){return null!=e&&""!==e}))):[])&&(ie=[]));var se=[];"object"===h(l)&&null!==l&&(se=Object.keys(l));var ce,ue=g?"future-action-panel":"future-action-panel hidden-calendar",le=g?"future-action-panel-content":"future-action-panel-content hidden-calendar",me=g?"future-action-date-panel":"future-action-date-panel hidden-calendar";ce="inherited"===e.timeFormat?!e.is12Hour:"24h"===e.timeFormat;var de=e.actionsSelectOptions;e.taxonomy||(de=e.actionsSelectOptions.filter((function(e){return-1===["category","category-add","category-remove","category-remove-all"].indexOf(e.value)})));var fe=function(e,t){var n=e.split("{"),a=[];a.push(n.shift());var r,o=function(e){var t="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!t){if(Array.isArray(e)||(t=S(e))){t&&(e=t);var n=0,a=function(){};return{s:a,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:a}}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 r,o=!0,i=!1;return{s:function(){t=t.call(e)},n:function(){var e=t.next();return o=e.done,e},e:function(e){i=!0,r=e},f:function(){try{o||null==t.return||t.return()}finally{if(i)throw r}}}}(n);try{for(o.s();!(r=o.n()).done;){var i=v(r.value.split("}"),2),s=i[0],c=i[1];a.push(React.createElement("a",{href:t,target:"_blank",key:t},s)),a.push(c)}}catch(e){o.e(e)}finally{o.f()}return a}(e.strings.timezoneSettingsHelp,"/wp-admin/options-general.php#timezone_string"),pe=String(n).includes("category")&&"category-remove-all"!==n,ye=u;switch(n){case"category":ye=e.strings.newTerms.replace("%s",u);break;case"category-remove":ye=e.strings.removeTerms.replace("%s",u);break;case"category-add":ye=e.strings.addTerms.replace("%s",u)}return C((function(){if(!i)return K(!0),void V("");K(function(){var t=!0;if(!i)return V(""),!0;n||(V(e.strings.errorActionRequired),t=!1),r||(V(e.strings.errorDateRequired),t=!1),r&&new Date(r)0&&React.createElement(o.SelectControl,{label:e.label,name:e.name,id:e.name,className:e.className,value:e.selected,onChange:function(t){e.onChange(t)},"data-data":e.data,options:e.options}),e.children,React.createElement("p",{className:"description"},e.description))};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 X(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function q(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:t,a=arguments.length>1?arguments[1]:void 0;switch(a.type){case"SET_POST_ID":return q(q({},n),{},{postId:a.postId});case"SET_ACTION":return q(q({},n),{},{action:a.action});case"SET_NEW_STATUS":return q(q({},n),{},{newStatus:a.newStatus});case"SET_DATE":return"number"==typeof a.date||(e=a.date,isNaN(e))||(a.date=parseInt(a.date)),"string"==typeof a.date&&(a.date=new Date(a.date).getTime()),a.date=u(a.date),a.date=s(a.date),q(q({},n),{},{date:a.date});case"SET_ENABLED":return q(q({},n),{},{enabled:a.enabled});case"SET_TERMS":return q(q({},n),{},{terms:a.terms});case"SET_TAXONOMY":return q(q({},n),{},{taxonomy:a.taxonomy});case"SET_TERMS_LIST_BY_NAME":return q(q({},n),{},{termsListByName:a.termsListByName});case"SET_TERMS_LIST_BY_ID":return q(q({},n),{},{termsListById:a.termsListById});case"SET_TAXONOMY_NAME":return q(q({},n),{},{taxonomyName:a.taxonomyName});case"SET_CHANGE_ACTION":return q(q({},n),{},{changeAction:a.changeAction});case"SET_CALENDAR_IS_VISIBLE":return q(q({},n),{},{calendarIsVisible:a.calendarIsVisible});case"SET_HAS_VALID_DATA":return q(q({},n),{},{hasValidData:a.hasValidData});case"SET_EXTRA_DATA":return q(q({},n),{},{extraData:q({},a.extraData)});case"SET_EXTRA_DATA_BY_NAME":var r=q(q({},n.extraData),{},Q({},a.name,a.value));return q(q({},n),{},{extraData:q({},r)})}return n},actions:{setPostId:function(e){return{type:"SET_POST_ID",postId:e}},setAction:function(e){return{type:"SET_ACTION",action:e}},setNewStatus:function(e){return{type:"SET_NEW_STATUS",newStatus:e}},setDate:function(e){return{type:"SET_DATE",date:e}},setEnabled:function(e){return{type:"SET_ENABLED",enabled:e}},setTerms:function(e){return{type:"SET_TERMS",terms:e}},setTaxonomy:function(e){return{type:"SET_TAXONOMY",taxonomy:e}},setTermsListByName:function(e){return{type:"SET_TERMS_LIST_BY_NAME",termsListByName:e}},setTermsListById:function(e){return{type:"SET_TERMS_LIST_BY_ID",termsListById:e}},setTaxonomyName:function(e){return{type:"SET_TAXONOMY_NAME",taxonomyName:e}},setIsFetchingTerms:function(e){return{type:"SET_IS_FETCHING_TERMS",isFetchingTerms:e}},setChangeAction:function(e){return{type:"SET_CHANGE_ACTION",changeAction:e}},setCalendarIsVisible:function(e){return{type:"SET_CALENDAR_IS_VISIBLE",calendarIsVisible:e}},setHasValidData:function(e){return{type:"SET_HAS_VALID_DATA",hasValidData:e}},setExtraData:function(e){return{type:"SET_EXTRA_DATA",extraData:e}},setExtraDataByName:function(e,t){return{type:"SET_EXTRA_DATA_BY_NAME",name:e,value:t}}},selectors:{getPostId:function(e){return e.postId},getAction:function(e){return e.action},getNewStatus:function(e){return e.newStatus},getDate:function(e){return e.date},getEnabled:function(e){return e.enabled},getTerms:function(e){return e.terms},getTaxonomy:function(e){return e.taxonomy},getTermsListByName:function(e){return e.termsListByName},getTermsListById:function(e){return e.termsListById},getTaxonomyName:function(e){return e.taxonomyName},getIsFetchingTerms:function(e){return e.isFetchingTerms},getChangeAction:function(e){return e.changeAction},getCalendarIsVisible:function(e){return e.calendarIsVisible},getHasValidData:function(e){return e.hasValidData},getExtraData:function(e){return e.extraData},getExtraDataByName:function(e,t){return e.extraData[t]||null}}});(0,V.register)(n)}({name:le,defaultState:{action:$.expireType,newStatus:$.newStatus,date:K,taxonomy:$.taxonomy,terms:$.terms,changeAction:"no-change"}});var t=document.getElementById("publishpress-future-bulk-edit");if(t){var n=(0,z.H)(t),a=document.querySelector("#bulk_edit");a&&(a.onclick=function(){setTimeout((function(){n.unmount()}),1e3)});var r=React.createElement(W,{storeName:le,postType:Z,isNewPost:ee,actionsSelectOptions:te,statusesSelectOptions:ce,is12Hour:ne,timeFormat:ae,startOfWeek:re,strings:oe,taxonomyName:ie,nonce:se,hideCalendarByDefault:ue});n.render(r),G.revert=function(){n.unmount(),de.apply(this,arguments)}}}})(); \ No newline at end of file +(()=>{"use strict";var e={1461:(e,t,n)=>{n.d(t,{A:()=>s});var a=n(1601),r=n.n(a),o=n(6314),i=n.n(o)()(r());i.push([e.id,".publishpress-future-date-preview .publishpress-future-date-preview-value {\n font-family: monospace;\n background-color: #e7e7e7;\n padding: 2px 4px;\n}\n\n.publishpress-future-date-preview.compact .publishpress-future-date-preview-label {\n display: block;\n}\n\n.publishpress-future-date-preview.compact {\n margin-bottom: 8px;\n}\n\n.publishpress-future-date-preview.compact h4 {\n font-size: 11px;\n font-weight: 500;\n line-height: 1.4;\n text-transform: uppercase;\n display: inline-block;\n margin-bottom: calc(8px);\n padding: 0px;\n flex-shrink: 0;\n margin-right: 12px;\n max-width: 75%;\n margin-top: 0;\n}\n\n.publishpress-future-notice.publishpress-future-notice-error {\n color: #dc3232;\n}\n",""]);const s=i},6314:e=>{e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",a=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),a&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),a&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,a,r,o){"string"==typeof e&&(e=[[null,e,void 0]]);var i={};if(a)for(var s=0;s0?" ".concat(l[5]):""," {").concat(l[1],"}")),l[5]=o),n&&(l[2]?(l[1]="@media ".concat(l[2]," {").concat(l[1],"}"),l[2]=n):l[2]=n),r&&(l[4]?(l[1]="@supports (".concat(l[4],") {").concat(l[1],"}"),l[4]=r):l[4]="".concat(r)),t.push(l))}},t}},1601:e=>{e.exports=function(e){return e[1]}},5338:(e,t,n)=>{var a=n(5206);t.H=a.createRoot,a.hydrateRoot},9922:(e,t,n)=>{n.r(t),n.d(t,{default:()=>b});var a=n(5072),r=n.n(a),o=n(7825),i=n.n(o),s=n(7659),c=n.n(s),u=n(5056),l=n.n(u),m=n(540),d=n.n(m),f=n(1113),p=n.n(f),y=n(1461),g={};g.styleTagTransform=p(),g.setAttributes=l(),g.insert=c().bind(null,"head"),g.domAPI=i(),g.insertStyleElement=d(),r()(y.A,g);const b=y.A&&y.A.locals?y.A.locals:void 0},5072:e=>{var t=[];function n(e){for(var n=-1,a=0;a{var t={};e.exports=function(e,n){var a=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!a)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");a.appendChild(n)}},540:e=>{e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},5056:(e,t,n)=>{e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},7825:e=>{e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var a="";n.supports&&(a+="@supports (".concat(n.supports,") {")),n.media&&(a+="@media ".concat(n.media," {"));var r=void 0!==n.layer;r&&(a+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),a+=n.css,r&&(a+="}"),n.media&&(a+="}"),n.supports&&(a+="}");var o=n.sourceMap;o&&"undefined"!=typeof btoa&&(a+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(o))))," */")),t.styleTagTransform(a,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},1113:e=>{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))}}},5206:e=>{e.exports=ReactDOM}},t={};function n(a){var r=t[a];if(void 0!==r)return r.exports;var o=t[a]={id:a,exports:{}};return e[a](o,o.exports,n),o.exports}function a(e){return a="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},a(e)}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var a in t)n.o(t,a)&&!n.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.nc=void 0;var r=function(e){return document.getElementsByName(e)[0]};const o=wp.components;var i=function(e){var t=e.iconExpanded?e.iconExpanded:"arrow-up-alt2",n=e.iconCollapsed?e.iconCollapsed:"arrow-down-alt2",a=e.isExpanded?t:n,r=e.isExpanded?e.titleExpanded:e.titleCollapsed;return React.createElement(o.Button,{isSmall:!0,title:r,icon:a,onClick:function(){e.onClick&&e.onClick()},className:e.className})},s=function(e){var t=new Date(u(e)),n=t.getFullYear(),a=("0"+(t.getMonth()+1)).slice(-2),r=("0"+t.getDate()).slice(-2),o=("0"+t.getHours()).slice(-2),i=("0"+t.getMinutes()).slice(-2),s=("0"+t.getSeconds()).slice(-2);return"".concat(n,"-").concat(a,"-").concat(r," ").concat(o,":").concat(i,":").concat(s)},c=function(e){return parseInt(e).toString().length<=10},u=function(e){return e=parseInt(e),c()?e:e/1e3},l=function(e){var t,n=e.currentDate,a=e.onChange,r=e.is12Hour,i=e.startOfWeek;return"number"==typeof n&&(t=n,t=parseInt(t),n=c()?1e3*t:t),React.createElement(o.DateTimePicker,{currentDate:n,onChange:a,__nextRemoveHelpButton:!0,is12Hour:r,startOfWeek:i})};const m=wp.element;var d=function(e){var t=e.isExpanded,n=e.strings,a=e.onToggleCalendar,r=e.currentDate,o=e.onChangeDate,s=e.is12Hour,c=e.startOfWeek;return(0,m.useEffect)((function(){var e=document.querySelector(".future-action-calendar-toggle");if(e){var t=e.nextElementSibling;if(t){var n=t.querySelector(".components-datetime__time");if(n){var a=n.nextSibling;a&&t.insertBefore(e,a)}}}})),React.createElement(m.Fragment,null,React.createElement(i,{className:"future-action-calendar-toggle",isExpanded:t,iconExpanded:"arrow-up-alt2",iconCollapsed:"calendar",titleExpanded:n.hideCalendar,titleCollapsed:n.showCalendar,onClick:a}),React.createElement(l,{currentDate:r,onChange:o,__nextRemoveHelpButton:!0,is12Hour:s,startOfWeek:c}))};const f=wp.plugins;function p(){return p=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,a=Array(t);n0&&m&&(oe=function(e){return"object"!==h(e)||null===e?{}:e.map((function(e){return m[e]}))}(s),"string"==typeof(ie=oe?(Array.isArray(oe)||"object"!==a(oe)||(oe=Object.values(oe)),oe.filter((function(e){return null!=e&&""!==e}))):[])&&(ie=[]));var se=[];"object"===h(l)&&null!==l&&(se=Object.keys(l));var ce,ue=g?"future-action-panel":"future-action-panel hidden-calendar",le=g?"future-action-panel-content":"future-action-panel-content hidden-calendar",me=g?"future-action-date-panel":"future-action-date-panel hidden-calendar";ce="inherited"===e.timeFormat?!e.is12Hour:"24h"===e.timeFormat;var de=e.actionsSelectOptions;e.taxonomy||(de=e.actionsSelectOptions.filter((function(e){return-1===["category","category-add","category-remove","category-remove-all"].indexOf(e.value)})));var fe=function(e,t){var n=e.split("{"),a=[];a.push(n.shift());var r,o=function(e){var t="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!t){if(Array.isArray(e)||(t=S(e))){t&&(e=t);var n=0,a=function(){};return{s:a,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:a}}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 r,o=!0,i=!1;return{s:function(){t=t.call(e)},n:function(){var e=t.next();return o=e.done,e},e:function(e){i=!0,r=e},f:function(){try{o||null==t.return||t.return()}finally{if(i)throw r}}}}(n);try{for(o.s();!(r=o.n()).done;){var i=v(r.value.split("}"),2),s=i[0],c=i[1];a.push(React.createElement("a",{href:t,target:"_blank",key:t},s)),a.push(c)}}catch(e){o.e(e)}finally{o.f()}return a}(e.strings.timezoneSettingsHelp,"/wp-admin/options-general.php#timezone_string"),pe=String(n).includes("category")&&"category-remove-all"!==n,ye=u;switch(n){case"category":ye=e.strings.newTerms.replace("%s",u);break;case"category-remove":ye=e.strings.removeTerms.replace("%s",u);break;case"category-add":ye=e.strings.addTerms.replace("%s",u)}return C((function(){if(!i)return K(!0),void V("");K(function(){var t=!0;if(!i)return V(""),!0;n||(V(e.strings.errorActionRequired),t=!1),r||(V(e.strings.errorDateRequired),t=!1),r&&new Date(r)0&&React.createElement(o.SelectControl,{label:e.label,name:e.name,id:e.name,className:e.className,value:e.selected,onChange:function(t){e.onChange(t)},"data-data":e.data,options:e.options}),e.children,React.createElement("p",{className:"description"},e.description))};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 X(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function q(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:t,a=arguments.length>1?arguments[1]:void 0;switch(a.type){case"SET_POST_ID":return q(q({},n),{},{postId:a.postId});case"SET_ACTION":return q(q({},n),{},{action:a.action});case"SET_NEW_STATUS":return q(q({},n),{},{newStatus:a.newStatus});case"SET_DATE":return"number"==typeof a.date||(e=a.date,isNaN(e))||(a.date=parseInt(a.date)),"string"==typeof a.date&&(a.date=new Date(a.date).getTime()),a.date=u(a.date),a.date=s(a.date),q(q({},n),{},{date:a.date});case"SET_ENABLED":return q(q({},n),{},{enabled:a.enabled});case"SET_TERMS":return q(q({},n),{},{terms:a.terms});case"SET_TAXONOMY":return q(q({},n),{},{taxonomy:a.taxonomy});case"SET_TERMS_LIST_BY_NAME":return q(q({},n),{},{termsListByName:a.termsListByName});case"SET_TERMS_LIST_BY_ID":return q(q({},n),{},{termsListById:a.termsListById});case"SET_TAXONOMY_NAME":return q(q({},n),{},{taxonomyName:a.taxonomyName});case"SET_CHANGE_ACTION":return q(q({},n),{},{changeAction:a.changeAction});case"SET_CALENDAR_IS_VISIBLE":return q(q({},n),{},{calendarIsVisible:a.calendarIsVisible});case"SET_HAS_VALID_DATA":return q(q({},n),{},{hasValidData:a.hasValidData});case"SET_EXTRA_DATA":return q(q({},n),{},{extraData:q({},a.extraData)});case"SET_EXTRA_DATA_BY_NAME":var r=q(q({},n.extraData),{},Q({},a.name,a.value));return q(q({},n),{},{extraData:q({},r)})}return n},actions:{setPostId:function(e){return{type:"SET_POST_ID",postId:e}},setAction:function(e){return{type:"SET_ACTION",action:e}},setNewStatus:function(e){return{type:"SET_NEW_STATUS",newStatus:e}},setDate:function(e){return{type:"SET_DATE",date:e}},setEnabled:function(e){return{type:"SET_ENABLED",enabled:e}},setTerms:function(e){return{type:"SET_TERMS",terms:e}},setTaxonomy:function(e){return{type:"SET_TAXONOMY",taxonomy:e}},setTermsListByName:function(e){return{type:"SET_TERMS_LIST_BY_NAME",termsListByName:e}},setTermsListById:function(e){return{type:"SET_TERMS_LIST_BY_ID",termsListById:e}},setTaxonomyName:function(e){return{type:"SET_TAXONOMY_NAME",taxonomyName:e}},setIsFetchingTerms:function(e){return{type:"SET_IS_FETCHING_TERMS",isFetchingTerms:e}},setChangeAction:function(e){return{type:"SET_CHANGE_ACTION",changeAction:e}},setCalendarIsVisible:function(e){return{type:"SET_CALENDAR_IS_VISIBLE",calendarIsVisible:e}},setHasValidData:function(e){return{type:"SET_HAS_VALID_DATA",hasValidData:e}},setExtraData:function(e){return{type:"SET_EXTRA_DATA",extraData:e}},setExtraDataByName:function(e,t){return{type:"SET_EXTRA_DATA_BY_NAME",name:e,value:t}}},selectors:{getPostId:function(e){return e.postId},getAction:function(e){return e.action},getNewStatus:function(e){return e.newStatus},getDate:function(e){return e.date},getEnabled:function(e){return e.enabled},getTerms:function(e){return e.terms},getTaxonomy:function(e){return e.taxonomy},getTermsListByName:function(e){return e.termsListByName},getTermsListById:function(e){return e.termsListById},getTaxonomyName:function(e){return e.taxonomyName},getIsFetchingTerms:function(e){return e.isFetchingTerms},getChangeAction:function(e){return e.changeAction},getCalendarIsVisible:function(e){return e.calendarIsVisible},getHasValidData:function(e){return e.hasValidData},getExtraData:function(e){return e.extraData},getExtraDataByName:function(e,t){return e.extraData[t]||null}}});(0,V.register)(n)}({name:le,defaultState:{action:$.expireType,newStatus:$.newStatus,date:K,taxonomy:$.taxonomy,terms:$.terms,changeAction:"no-change"}});var t=document.getElementById("publishpress-future-bulk-edit");if(t){var n=(0,z.H)(t),a=document.querySelector("#bulk_edit");a&&(a.onclick=function(){setTimeout((function(){n.unmount()}),1e3)});var r=React.createElement(W,{storeName:le,postType:Z,isNewPost:ee,actionsSelectOptions:te,statusesSelectOptions:ce,is12Hour:ne,timeFormat:ae,startOfWeek:re,strings:oe,taxonomyName:ie,nonce:se,hideCalendarByDefault:ue});n.render(r),G.revert=function(){n.unmount(),de.apply(this,arguments)}}}})(); \ No newline at end of file diff --git a/assets/js/classicEditor.js b/assets/js/classicEditor.js index 66b230a1e..a7d700cb1 100644 --- a/assets/js/classicEditor.js +++ b/assets/js/classicEditor.js @@ -584,7 +584,7 @@ var FutureActionPanel = function FutureActionPanel(props) { fontWeight: 'bold', marginBottom: '10px' } - }, props.strings.futureActions), /*#__PURE__*/React.createElement(_FutureActionPanelTop__WEBPACK_IMPORTED_MODULE_5__.FutureActionPanelTop.Slot, { + }, props.strings.panelTitle), /*#__PURE__*/React.createElement(_FutureActionPanelTop__WEBPACK_IMPORTED_MODULE_5__.FutureActionPanelTop.Slot, { fillProps: { storeName: props.storeName } diff --git a/assets/js/classicEditor.min.js b/assets/js/classicEditor.min.js index 5b6691c4d..71c5bc766 100644 --- a/assets/js/classicEditor.min.js +++ b/assets/js/classicEditor.min.js @@ -1 +1 @@ -(()=>{"use strict";var e={1461:(e,t,n)=>{n.d(t,{A:()=>s});var a=n(1601),r=n.n(a),o=n(6314),i=n.n(o)()(r());i.push([e.id,".publishpress-future-date-preview .publishpress-future-date-preview-value {\n font-family: monospace;\n background-color: #e7e7e7;\n padding: 2px 4px;\n}\n\n.publishpress-future-date-preview.compact .publishpress-future-date-preview-label {\n display: block;\n}\n\n.publishpress-future-date-preview.compact {\n margin-bottom: 8px;\n}\n\n.publishpress-future-date-preview.compact h4 {\n font-size: 11px;\n font-weight: 500;\n line-height: 1.4;\n text-transform: uppercase;\n display: inline-block;\n margin-bottom: calc(8px);\n padding: 0px;\n flex-shrink: 0;\n margin-right: 12px;\n max-width: 75%;\n margin-top: 0;\n}\n\n.publishpress-future-notice.publishpress-future-notice-error {\n color: #dc3232;\n}\n",""]);const s=i},6314:e=>{e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",a=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),a&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),a&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,a,r,o){"string"==typeof e&&(e=[[null,e,void 0]]);var i={};if(a)for(var s=0;s0?" ".concat(l[5]):""," {").concat(l[1],"}")),l[5]=o),n&&(l[2]?(l[1]="@media ".concat(l[2]," {").concat(l[1],"}"),l[2]=n):l[2]=n),r&&(l[4]?(l[1]="@supports (".concat(l[4],") {").concat(l[1],"}"),l[4]=r):l[4]="".concat(r)),t.push(l))}},t}},1601:e=>{e.exports=function(e){return e[1]}},5338:(e,t,n)=>{var a=n(5206);t.H=a.createRoot,a.hydrateRoot},9922:(e,t,n)=>{n.r(t),n.d(t,{default:()=>b});var a=n(5072),r=n.n(a),o=n(7825),i=n.n(o),s=n(7659),c=n.n(s),u=n(5056),l=n.n(u),m=n(540),d=n.n(m),f=n(1113),p=n.n(f),y=n(1461),g={};g.styleTagTransform=p(),g.setAttributes=l(),g.insert=c().bind(null,"head"),g.domAPI=i(),g.insertStyleElement=d(),r()(y.A,g);const b=y.A&&y.A.locals?y.A.locals:void 0},5072:e=>{var t=[];function n(e){for(var n=-1,a=0;a{var t={};e.exports=function(e,n){var a=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!a)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");a.appendChild(n)}},540:e=>{e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},5056:(e,t,n)=>{e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},7825:e=>{e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var a="";n.supports&&(a+="@supports (".concat(n.supports,") {")),n.media&&(a+="@media ".concat(n.media," {"));var r=void 0!==n.layer;r&&(a+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),a+=n.css,r&&(a+="}"),n.media&&(a+="}"),n.supports&&(a+="}");var o=n.sourceMap;o&&"undefined"!=typeof btoa&&(a+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(o))))," */")),t.styleTagTransform(a,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},1113:e=>{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))}}},5206:e=>{e.exports=ReactDOM}},t={};function n(a){var r=t[a];if(void 0!==r)return r.exports;var o=t[a]={id:a,exports:{}};return e[a](o,o.exports,n),o.exports}function a(e){return a="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},a(e)}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var a in t)n.o(t,a)&&!n.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.nc=void 0;const r=wp.components;var o=function(e){var t=e.iconExpanded?e.iconExpanded:"arrow-up-alt2",n=e.iconCollapsed?e.iconCollapsed:"arrow-down-alt2",a=e.isExpanded?t:n,o=e.isExpanded?e.titleExpanded:e.titleCollapsed;return React.createElement(r.Button,{isSmall:!0,title:o,icon:a,onClick:function(){e.onClick&&e.onClick()},className:e.className})},i=function(e){var t=new Date(c(e)),n=t.getFullYear(),a=("0"+(t.getMonth()+1)).slice(-2),r=("0"+t.getDate()).slice(-2),o=("0"+t.getHours()).slice(-2),i=("0"+t.getMinutes()).slice(-2),s=("0"+t.getSeconds()).slice(-2);return"".concat(n,"-").concat(a,"-").concat(r," ").concat(o,":").concat(i,":").concat(s)},s=function(e){return parseInt(e).toString().length<=10},c=function(e){return e=parseInt(e),s()?e:e/1e3},u=function(e){var t,n=e.currentDate,a=e.onChange,o=e.is12Hour,i=e.startOfWeek;return"number"==typeof n&&(t=n,t=parseInt(t),n=s()?1e3*t:t),React.createElement(r.DateTimePicker,{currentDate:n,onChange:a,__nextRemoveHelpButton:!0,is12Hour:o,startOfWeek:i})};const l=wp.element;var m=function(e){var t=e.isExpanded,n=e.strings,a=e.onToggleCalendar,r=e.currentDate,i=e.onChangeDate,s=e.is12Hour,c=e.startOfWeek;return(0,l.useEffect)((function(){var e=document.querySelector(".future-action-calendar-toggle");if(e){var t=e.nextElementSibling;if(t){var n=t.querySelector(".components-datetime__time");if(n){var a=n.nextSibling;a&&t.insertBefore(e,a)}}}})),React.createElement(l.Fragment,null,React.createElement(o,{className:"future-action-calendar-toggle",isExpanded:t,iconExpanded:"arrow-up-alt2",iconCollapsed:"calendar",titleExpanded:n.hideCalendar,titleCollapsed:n.showCalendar,onClick:a}),React.createElement(u,{currentDate:r,onChange:i,__nextRemoveHelpButton:!0,is12Hour:s,startOfWeek:c}))};const d=wp.plugins;function f(){return f=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,a=Array(t);n0&&f&&(oe=function(e){return"object"!==b(e)||null===e?{}:e.map((function(e){return f[e]}))}(s),"string"==typeof(ie=oe?(Array.isArray(oe)||"object"!==a(oe)||(oe=Object.values(oe)),oe.filter((function(e){return null!=e&&""!==e}))):[])&&(ie=[]));var se=[];"object"===b(l)&&null!==l&&(se=Object.keys(l));var ce,ue=E?"future-action-panel":"future-action-panel hidden-calendar",le=E?"future-action-panel-content":"future-action-panel-content hidden-calendar",me=E?"future-action-date-panel":"future-action-date-panel hidden-calendar";ce="inherited"===e.timeFormat?!e.is12Hour:"24h"===e.timeFormat;var de=e.actionsSelectOptions;e.taxonomy||(de=e.actionsSelectOptions.filter((function(e){return-1===["category","category-add","category-remove","category-remove-all"].indexOf(e.value)})));var fe=function(e,t){var n=e.split("{"),a=[];a.push(n.shift());var r,o=function(e){var t="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!t){if(Array.isArray(e)||(t=v(e))){t&&(e=t);var n=0,a=function(){};return{s:a,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:a}}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 r,o=!0,i=!1;return{s:function(){t=t.call(e)},n:function(){var e=t.next();return o=e.done,e},e:function(e){i=!0,r=e},f:function(){try{o||null==t.return||t.return()}finally{if(i)throw r}}}}(n);try{for(o.s();!(r=o.n()).done;){var i=h(r.value.split("}"),2),s=i[0],c=i[1];a.push(React.createElement("a",{href:t,target:"_blank",key:t},s)),a.push(c)}}catch(e){o.e(e)}finally{o.f()}return a}(e.strings.timezoneSettingsHelp,"/wp-admin/options-general.php#timezone_string"),pe=String(n).includes("category")&&"category-remove-all"!==n,ye=u;switch(n){case"category":ye=e.strings.newTerms.replace("%s",u);break;case"category-remove":ye=e.strings.removeTerms.replace("%s",u);break;case"category-add":ye=e.strings.addTerms.replace("%s",u)}return R((function(){if(!i)return K(!0),void M("");K(function(){var t=!0;if(!i)return M(""),!0;n||(M(e.strings.errorActionRequired),t=!1),o||(M(e.strings.errorDateRequired),t=!1),o&&new Date(o)0&&void 0!==arguments[0]?arguments[0]:t,a=arguments.length>1?arguments[1]:void 0;switch(a.type){case"SET_POST_ID":return Y(Y({},n),{},{postId:a.postId});case"SET_ACTION":return Y(Y({},n),{},{action:a.action});case"SET_NEW_STATUS":return Y(Y({},n),{},{newStatus:a.newStatus});case"SET_DATE":return"number"==typeof a.date||(e=a.date,isNaN(e))||(a.date=parseInt(a.date)),"string"==typeof a.date&&(a.date=new Date(a.date).getTime()),a.date=c(a.date),a.date=i(a.date),Y(Y({},n),{},{date:a.date});case"SET_ENABLED":return Y(Y({},n),{},{enabled:a.enabled});case"SET_TERMS":return Y(Y({},n),{},{terms:a.terms});case"SET_TAXONOMY":return Y(Y({},n),{},{taxonomy:a.taxonomy});case"SET_TERMS_LIST_BY_NAME":return Y(Y({},n),{},{termsListByName:a.termsListByName});case"SET_TERMS_LIST_BY_ID":return Y(Y({},n),{},{termsListById:a.termsListById});case"SET_TAXONOMY_NAME":return Y(Y({},n),{},{taxonomyName:a.taxonomyName});case"SET_CHANGE_ACTION":return Y(Y({},n),{},{changeAction:a.changeAction});case"SET_CALENDAR_IS_VISIBLE":return Y(Y({},n),{},{calendarIsVisible:a.calendarIsVisible});case"SET_HAS_VALID_DATA":return Y(Y({},n),{},{hasValidData:a.hasValidData});case"SET_EXTRA_DATA":return Y(Y({},n),{},{extraData:Y({},a.extraData)});case"SET_EXTRA_DATA_BY_NAME":var r=Y(Y({},n.extraData),{},U({},a.name,a.value));return Y(Y({},n),{},{extraData:Y({},r)})}return n},actions:{setPostId:function(e){return{type:"SET_POST_ID",postId:e}},setAction:function(e){return{type:"SET_ACTION",action:e}},setNewStatus:function(e){return{type:"SET_NEW_STATUS",newStatus:e}},setDate:function(e){return{type:"SET_DATE",date:e}},setEnabled:function(e){return{type:"SET_ENABLED",enabled:e}},setTerms:function(e){return{type:"SET_TERMS",terms:e}},setTaxonomy:function(e){return{type:"SET_TAXONOMY",taxonomy:e}},setTermsListByName:function(e){return{type:"SET_TERMS_LIST_BY_NAME",termsListByName:e}},setTermsListById:function(e){return{type:"SET_TERMS_LIST_BY_ID",termsListById:e}},setTaxonomyName:function(e){return{type:"SET_TAXONOMY_NAME",taxonomyName:e}},setIsFetchingTerms:function(e){return{type:"SET_IS_FETCHING_TERMS",isFetchingTerms:e}},setChangeAction:function(e){return{type:"SET_CHANGE_ACTION",changeAction:e}},setCalendarIsVisible:function(e){return{type:"SET_CALENDAR_IS_VISIBLE",calendarIsVisible:e}},setHasValidData:function(e){return{type:"SET_HAS_VALID_DATA",hasValidData:e}},setExtraData:function(e){return{type:"SET_EXTRA_DATA",extraData:e}},setExtraDataByName:function(e,t){return{type:"SET_EXTRA_DATA_BY_NAME",name:e,value:t}}},selectors:{getPostId:function(e){return e.postId},getAction:function(e){return e.action},getNewStatus:function(e){return e.newStatus},getDate:function(e){return e.date},getEnabled:function(e){return e.enabled},getTerms:function(e){return e.terms},getTaxonomy:function(e){return e.taxonomy},getTermsListByName:function(e){return e.termsListByName},getTermsListById:function(e){return e.termsListById},getTaxonomyName:function(e){return e.taxonomyName},getIsFetchingTerms:function(e){return e.isFetchingTerms},getChangeAction:function(e){return e.changeAction},getCalendarIsVisible:function(e){return e.calendarIsVisible},getHasValidData:function(e){return e.hasValidData},getExtraData:function(e){return e.extraData},getExtraDataByName:function(e,t){return e.extraData[t]||null}}});(0,V.register)(n)}({name:oe,defaultState:{postId:document.getElementById("post_ID")?parseInt(document.getElementById("post_ID").value,10):0,autoEnable:te.autoEnable,action:te.expireType,newStatus:te.newStatus,date:ne,taxonomy:te.taxonomy,terms:te.terms}});var ie=document.getElementById("publishpress-future-classic-editor");if(ie){var se=React.createElement(M,{storeName:oe,postType:z,isNewPost:Q,actionsSelectOptions:G,statusesSelectOptions:ae,is12Hour:J,timeFormat:$,startOfWeek:K,strings:Z,taxonomyName:ee,hideCalendarByDefault:re});(0,X.H)(ie).render(se)}}})(); \ No newline at end of file +(()=>{"use strict";var e={1461:(e,t,n)=>{n.d(t,{A:()=>s});var a=n(1601),r=n.n(a),o=n(6314),i=n.n(o)()(r());i.push([e.id,".publishpress-future-date-preview .publishpress-future-date-preview-value {\n font-family: monospace;\n background-color: #e7e7e7;\n padding: 2px 4px;\n}\n\n.publishpress-future-date-preview.compact .publishpress-future-date-preview-label {\n display: block;\n}\n\n.publishpress-future-date-preview.compact {\n margin-bottom: 8px;\n}\n\n.publishpress-future-date-preview.compact h4 {\n font-size: 11px;\n font-weight: 500;\n line-height: 1.4;\n text-transform: uppercase;\n display: inline-block;\n margin-bottom: calc(8px);\n padding: 0px;\n flex-shrink: 0;\n margin-right: 12px;\n max-width: 75%;\n margin-top: 0;\n}\n\n.publishpress-future-notice.publishpress-future-notice-error {\n color: #dc3232;\n}\n",""]);const s=i},6314:e=>{e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",a=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),a&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),a&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,a,r,o){"string"==typeof e&&(e=[[null,e,void 0]]);var i={};if(a)for(var s=0;s0?" ".concat(l[5]):""," {").concat(l[1],"}")),l[5]=o),n&&(l[2]?(l[1]="@media ".concat(l[2]," {").concat(l[1],"}"),l[2]=n):l[2]=n),r&&(l[4]?(l[1]="@supports (".concat(l[4],") {").concat(l[1],"}"),l[4]=r):l[4]="".concat(r)),t.push(l))}},t}},1601:e=>{e.exports=function(e){return e[1]}},5338:(e,t,n)=>{var a=n(5206);t.H=a.createRoot,a.hydrateRoot},9922:(e,t,n)=>{n.r(t),n.d(t,{default:()=>b});var a=n(5072),r=n.n(a),o=n(7825),i=n.n(o),s=n(7659),c=n.n(s),u=n(5056),l=n.n(u),m=n(540),d=n.n(m),f=n(1113),p=n.n(f),y=n(1461),g={};g.styleTagTransform=p(),g.setAttributes=l(),g.insert=c().bind(null,"head"),g.domAPI=i(),g.insertStyleElement=d(),r()(y.A,g);const b=y.A&&y.A.locals?y.A.locals:void 0},5072:e=>{var t=[];function n(e){for(var n=-1,a=0;a{var t={};e.exports=function(e,n){var a=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!a)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");a.appendChild(n)}},540:e=>{e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},5056:(e,t,n)=>{e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},7825:e=>{e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var a="";n.supports&&(a+="@supports (".concat(n.supports,") {")),n.media&&(a+="@media ".concat(n.media," {"));var r=void 0!==n.layer;r&&(a+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),a+=n.css,r&&(a+="}"),n.media&&(a+="}"),n.supports&&(a+="}");var o=n.sourceMap;o&&"undefined"!=typeof btoa&&(a+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(o))))," */")),t.styleTagTransform(a,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},1113:e=>{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))}}},5206:e=>{e.exports=ReactDOM}},t={};function n(a){var r=t[a];if(void 0!==r)return r.exports;var o=t[a]={id:a,exports:{}};return e[a](o,o.exports,n),o.exports}function a(e){return a="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},a(e)}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var a in t)n.o(t,a)&&!n.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.nc=void 0;const r=wp.components;var o=function(e){var t=e.iconExpanded?e.iconExpanded:"arrow-up-alt2",n=e.iconCollapsed?e.iconCollapsed:"arrow-down-alt2",a=e.isExpanded?t:n,o=e.isExpanded?e.titleExpanded:e.titleCollapsed;return React.createElement(r.Button,{isSmall:!0,title:o,icon:a,onClick:function(){e.onClick&&e.onClick()},className:e.className})},i=function(e){var t=new Date(c(e)),n=t.getFullYear(),a=("0"+(t.getMonth()+1)).slice(-2),r=("0"+t.getDate()).slice(-2),o=("0"+t.getHours()).slice(-2),i=("0"+t.getMinutes()).slice(-2),s=("0"+t.getSeconds()).slice(-2);return"".concat(n,"-").concat(a,"-").concat(r," ").concat(o,":").concat(i,":").concat(s)},s=function(e){return parseInt(e).toString().length<=10},c=function(e){return e=parseInt(e),s()?e:e/1e3},u=function(e){var t,n=e.currentDate,a=e.onChange,o=e.is12Hour,i=e.startOfWeek;return"number"==typeof n&&(t=n,t=parseInt(t),n=s()?1e3*t:t),React.createElement(r.DateTimePicker,{currentDate:n,onChange:a,__nextRemoveHelpButton:!0,is12Hour:o,startOfWeek:i})};const l=wp.element;var m=function(e){var t=e.isExpanded,n=e.strings,a=e.onToggleCalendar,r=e.currentDate,i=e.onChangeDate,s=e.is12Hour,c=e.startOfWeek;return(0,l.useEffect)((function(){var e=document.querySelector(".future-action-calendar-toggle");if(e){var t=e.nextElementSibling;if(t){var n=t.querySelector(".components-datetime__time");if(n){var a=n.nextSibling;a&&t.insertBefore(e,a)}}}})),React.createElement(l.Fragment,null,React.createElement(o,{className:"future-action-calendar-toggle",isExpanded:t,iconExpanded:"arrow-up-alt2",iconCollapsed:"calendar",titleExpanded:n.hideCalendar,titleCollapsed:n.showCalendar,onClick:a}),React.createElement(u,{currentDate:r,onChange:i,__nextRemoveHelpButton:!0,is12Hour:s,startOfWeek:c}))};const d=wp.plugins;function f(){return f=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,a=Array(t);n0&&f&&(oe=function(e){return"object"!==b(e)||null===e?{}:e.map((function(e){return f[e]}))}(s),"string"==typeof(ie=oe?(Array.isArray(oe)||"object"!==a(oe)||(oe=Object.values(oe)),oe.filter((function(e){return null!=e&&""!==e}))):[])&&(ie=[]));var se=[];"object"===b(l)&&null!==l&&(se=Object.keys(l));var ce,ue=E?"future-action-panel":"future-action-panel hidden-calendar",le=E?"future-action-panel-content":"future-action-panel-content hidden-calendar",me=E?"future-action-date-panel":"future-action-date-panel hidden-calendar";ce="inherited"===e.timeFormat?!e.is12Hour:"24h"===e.timeFormat;var de=e.actionsSelectOptions;e.taxonomy||(de=e.actionsSelectOptions.filter((function(e){return-1===["category","category-add","category-remove","category-remove-all"].indexOf(e.value)})));var fe=function(e,t){var n=e.split("{"),a=[];a.push(n.shift());var r,o=function(e){var t="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!t){if(Array.isArray(e)||(t=v(e))){t&&(e=t);var n=0,a=function(){};return{s:a,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:a}}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 r,o=!0,i=!1;return{s:function(){t=t.call(e)},n:function(){var e=t.next();return o=e.done,e},e:function(e){i=!0,r=e},f:function(){try{o||null==t.return||t.return()}finally{if(i)throw r}}}}(n);try{for(o.s();!(r=o.n()).done;){var i=h(r.value.split("}"),2),s=i[0],c=i[1];a.push(React.createElement("a",{href:t,target:"_blank",key:t},s)),a.push(c)}}catch(e){o.e(e)}finally{o.f()}return a}(e.strings.timezoneSettingsHelp,"/wp-admin/options-general.php#timezone_string"),pe=String(n).includes("category")&&"category-remove-all"!==n,ye=u;switch(n){case"category":ye=e.strings.newTerms.replace("%s",u);break;case"category-remove":ye=e.strings.removeTerms.replace("%s",u);break;case"category-add":ye=e.strings.addTerms.replace("%s",u)}return R((function(){if(!i)return K(!0),void M("");K(function(){var t=!0;if(!i)return M(""),!0;n||(M(e.strings.errorActionRequired),t=!1),o||(M(e.strings.errorDateRequired),t=!1),o&&new Date(o)0&&void 0!==arguments[0]?arguments[0]:t,a=arguments.length>1?arguments[1]:void 0;switch(a.type){case"SET_POST_ID":return Y(Y({},n),{},{postId:a.postId});case"SET_ACTION":return Y(Y({},n),{},{action:a.action});case"SET_NEW_STATUS":return Y(Y({},n),{},{newStatus:a.newStatus});case"SET_DATE":return"number"==typeof a.date||(e=a.date,isNaN(e))||(a.date=parseInt(a.date)),"string"==typeof a.date&&(a.date=new Date(a.date).getTime()),a.date=c(a.date),a.date=i(a.date),Y(Y({},n),{},{date:a.date});case"SET_ENABLED":return Y(Y({},n),{},{enabled:a.enabled});case"SET_TERMS":return Y(Y({},n),{},{terms:a.terms});case"SET_TAXONOMY":return Y(Y({},n),{},{taxonomy:a.taxonomy});case"SET_TERMS_LIST_BY_NAME":return Y(Y({},n),{},{termsListByName:a.termsListByName});case"SET_TERMS_LIST_BY_ID":return Y(Y({},n),{},{termsListById:a.termsListById});case"SET_TAXONOMY_NAME":return Y(Y({},n),{},{taxonomyName:a.taxonomyName});case"SET_CHANGE_ACTION":return Y(Y({},n),{},{changeAction:a.changeAction});case"SET_CALENDAR_IS_VISIBLE":return Y(Y({},n),{},{calendarIsVisible:a.calendarIsVisible});case"SET_HAS_VALID_DATA":return Y(Y({},n),{},{hasValidData:a.hasValidData});case"SET_EXTRA_DATA":return Y(Y({},n),{},{extraData:Y({},a.extraData)});case"SET_EXTRA_DATA_BY_NAME":var r=Y(Y({},n.extraData),{},U({},a.name,a.value));return Y(Y({},n),{},{extraData:Y({},r)})}return n},actions:{setPostId:function(e){return{type:"SET_POST_ID",postId:e}},setAction:function(e){return{type:"SET_ACTION",action:e}},setNewStatus:function(e){return{type:"SET_NEW_STATUS",newStatus:e}},setDate:function(e){return{type:"SET_DATE",date:e}},setEnabled:function(e){return{type:"SET_ENABLED",enabled:e}},setTerms:function(e){return{type:"SET_TERMS",terms:e}},setTaxonomy:function(e){return{type:"SET_TAXONOMY",taxonomy:e}},setTermsListByName:function(e){return{type:"SET_TERMS_LIST_BY_NAME",termsListByName:e}},setTermsListById:function(e){return{type:"SET_TERMS_LIST_BY_ID",termsListById:e}},setTaxonomyName:function(e){return{type:"SET_TAXONOMY_NAME",taxonomyName:e}},setIsFetchingTerms:function(e){return{type:"SET_IS_FETCHING_TERMS",isFetchingTerms:e}},setChangeAction:function(e){return{type:"SET_CHANGE_ACTION",changeAction:e}},setCalendarIsVisible:function(e){return{type:"SET_CALENDAR_IS_VISIBLE",calendarIsVisible:e}},setHasValidData:function(e){return{type:"SET_HAS_VALID_DATA",hasValidData:e}},setExtraData:function(e){return{type:"SET_EXTRA_DATA",extraData:e}},setExtraDataByName:function(e,t){return{type:"SET_EXTRA_DATA_BY_NAME",name:e,value:t}}},selectors:{getPostId:function(e){return e.postId},getAction:function(e){return e.action},getNewStatus:function(e){return e.newStatus},getDate:function(e){return e.date},getEnabled:function(e){return e.enabled},getTerms:function(e){return e.terms},getTaxonomy:function(e){return e.taxonomy},getTermsListByName:function(e){return e.termsListByName},getTermsListById:function(e){return e.termsListById},getTaxonomyName:function(e){return e.taxonomyName},getIsFetchingTerms:function(e){return e.isFetchingTerms},getChangeAction:function(e){return e.changeAction},getCalendarIsVisible:function(e){return e.calendarIsVisible},getHasValidData:function(e){return e.hasValidData},getExtraData:function(e){return e.extraData},getExtraDataByName:function(e,t){return e.extraData[t]||null}}});(0,V.register)(n)}({name:oe,defaultState:{postId:document.getElementById("post_ID")?parseInt(document.getElementById("post_ID").value,10):0,autoEnable:te.autoEnable,action:te.expireType,newStatus:te.newStatus,date:ne,taxonomy:te.taxonomy,terms:te.terms}});var ie=document.getElementById("publishpress-future-classic-editor");if(ie){var se=React.createElement(M,{storeName:oe,postType:z,isNewPost:Q,actionsSelectOptions:G,statusesSelectOptions:ae,is12Hour:J,timeFormat:$,startOfWeek:K,strings:Z,taxonomyName:ee,hideCalendarByDefault:re});(0,X.H)(ie).render(se)}}})(); \ No newline at end of file diff --git a/assets/js/futureActions.js b/assets/js/futureActions.js index b5b87c5a0..00fc2ff24 100644 --- a/assets/js/futureActions.js +++ b/assets/js/futureActions.js @@ -17,7 +17,8 @@ jQuery(document).ready(function ($) { $("a.publishpres-future-view-log").on('click', function (e) { e.preventDefault(); var id = $(this).data('id'); - $(".publishpress-future-log-" + id).dialog("open"); + var logElement = $.find(".publishpress-future-log-".concat(id)); + $(logElement).dialog("open"); }); }); /******/ })() diff --git a/assets/js/futureActions.min.js b/assets/js/futureActions.min.js index 2dda6c565..35fce7666 100644 --- a/assets/js/futureActions.min.js +++ b/assets/js/futureActions.min.js @@ -1 +1 @@ -jQuery(document).ready((function(e){e(".publishpress-future-log-entries-popup").dialog({autoOpen:!1,modal:!0,width:800,title:publishpressFutureActionsConfig.dialogTitle,buttons:{Close:function(){e(this).dialog("close")}}}),e("a.publishpres-future-view-log").on("click",(function(i){i.preventDefault();var t=e(this).data("id");e(".publishpress-future-log-"+t).dialog("open")}))})); \ No newline at end of file +jQuery(document).ready((function(e){e(".publishpress-future-log-entries-popup").dialog({autoOpen:!1,modal:!0,width:800,title:publishpressFutureActionsConfig.dialogTitle,buttons:{Close:function(){e(this).dialog("close")}}}),e("a.publishpres-future-view-log").on("click",(function(i){i.preventDefault();var t=e(this).data("id"),o=e.find(".publishpress-future-log-".concat(t));e(o).dialog("open")}))})); \ No newline at end of file diff --git a/assets/js/quickEdit.js b/assets/js/quickEdit.js index 70799a986..211cbdbca 100644 --- a/assets/js/quickEdit.js +++ b/assets/js/quickEdit.js @@ -584,7 +584,7 @@ var FutureActionPanel = function FutureActionPanel(props) { fontWeight: 'bold', marginBottom: '10px' } - }, props.strings.futureActions), /*#__PURE__*/React.createElement(_FutureActionPanelTop__WEBPACK_IMPORTED_MODULE_5__.FutureActionPanelTop.Slot, { + }, props.strings.panelTitle), /*#__PURE__*/React.createElement(_FutureActionPanelTop__WEBPACK_IMPORTED_MODULE_5__.FutureActionPanelTop.Slot, { fillProps: { storeName: props.storeName } diff --git a/assets/js/quickEdit.min.js b/assets/js/quickEdit.min.js index c78fb290a..eaff71ecb 100644 --- a/assets/js/quickEdit.min.js +++ b/assets/js/quickEdit.min.js @@ -1 +1 @@ -(()=>{"use strict";var e={1461:(e,t,n)=>{n.d(t,{A:()=>s});var a=n(1601),r=n.n(a),o=n(6314),i=n.n(o)()(r());i.push([e.id,".publishpress-future-date-preview .publishpress-future-date-preview-value {\n font-family: monospace;\n background-color: #e7e7e7;\n padding: 2px 4px;\n}\n\n.publishpress-future-date-preview.compact .publishpress-future-date-preview-label {\n display: block;\n}\n\n.publishpress-future-date-preview.compact {\n margin-bottom: 8px;\n}\n\n.publishpress-future-date-preview.compact h4 {\n font-size: 11px;\n font-weight: 500;\n line-height: 1.4;\n text-transform: uppercase;\n display: inline-block;\n margin-bottom: calc(8px);\n padding: 0px;\n flex-shrink: 0;\n margin-right: 12px;\n max-width: 75%;\n margin-top: 0;\n}\n\n.publishpress-future-notice.publishpress-future-notice-error {\n color: #dc3232;\n}\n",""]);const s=i},6314:e=>{e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",a=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),a&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),a&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,a,r,o){"string"==typeof e&&(e=[[null,e,void 0]]);var i={};if(a)for(var s=0;s0?" ".concat(l[5]):""," {").concat(l[1],"}")),l[5]=o),n&&(l[2]?(l[1]="@media ".concat(l[2]," {").concat(l[1],"}"),l[2]=n):l[2]=n),r&&(l[4]?(l[1]="@supports (".concat(l[4],") {").concat(l[1],"}"),l[4]=r):l[4]="".concat(r)),t.push(l))}},t}},1601:e=>{e.exports=function(e){return e[1]}},5338:(e,t,n)=>{var a=n(5206);t.H=a.createRoot,a.hydrateRoot},9922:(e,t,n)=>{n.r(t),n.d(t,{default:()=>h});var a=n(5072),r=n.n(a),o=n(7825),i=n.n(o),s=n(7659),c=n.n(s),u=n(5056),l=n.n(u),m=n(540),d=n.n(m),f=n(1113),p=n.n(f),y=n(1461),g={};g.styleTagTransform=p(),g.setAttributes=l(),g.insert=c().bind(null,"head"),g.domAPI=i(),g.insertStyleElement=d(),r()(y.A,g);const h=y.A&&y.A.locals?y.A.locals:void 0},5072:e=>{var t=[];function n(e){for(var n=-1,a=0;a{var t={};e.exports=function(e,n){var a=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!a)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");a.appendChild(n)}},540:e=>{e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},5056:(e,t,n)=>{e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},7825:e=>{e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var a="";n.supports&&(a+="@supports (".concat(n.supports,") {")),n.media&&(a+="@media ".concat(n.media," {"));var r=void 0!==n.layer;r&&(a+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),a+=n.css,r&&(a+="}"),n.media&&(a+="}"),n.supports&&(a+="}");var o=n.sourceMap;o&&"undefined"!=typeof btoa&&(a+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(o))))," */")),t.styleTagTransform(a,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},1113:e=>{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))}}},5206:e=>{e.exports=ReactDOM}},t={};function n(a){var r=t[a];if(void 0!==r)return r.exports;var o=t[a]={id:a,exports:{}};return e[a](o,o.exports,n),o.exports}function a(e){return a="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},a(e)}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var a in t)n.o(t,a)&&!n.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.nc=void 0;const r=wp.components;var o=function(e){var t=e.iconExpanded?e.iconExpanded:"arrow-up-alt2",n=e.iconCollapsed?e.iconCollapsed:"arrow-down-alt2",a=e.isExpanded?t:n,o=e.isExpanded?e.titleExpanded:e.titleCollapsed;return React.createElement(r.Button,{isSmall:!0,title:o,icon:a,onClick:function(){e.onClick&&e.onClick()},className:e.className})},i=function(e){var t=new Date(c(e)),n=t.getFullYear(),a=("0"+(t.getMonth()+1)).slice(-2),r=("0"+t.getDate()).slice(-2),o=("0"+t.getHours()).slice(-2),i=("0"+t.getMinutes()).slice(-2),s=("0"+t.getSeconds()).slice(-2);return"".concat(n,"-").concat(a,"-").concat(r," ").concat(o,":").concat(i,":").concat(s)},s=function(e){return parseInt(e).toString().length<=10},c=function(e){return e=parseInt(e),s()?e:e/1e3},u=function(e){var t,n=e.currentDate,a=e.onChange,o=e.is12Hour,i=e.startOfWeek;return"number"==typeof n&&(t=n,t=parseInt(t),n=s()?1e3*t:t),React.createElement(r.DateTimePicker,{currentDate:n,onChange:a,__nextRemoveHelpButton:!0,is12Hour:o,startOfWeek:i})};const l=wp.element;var m=function(e){var t=e.isExpanded,n=e.strings,a=e.onToggleCalendar,r=e.currentDate,i=e.onChangeDate,s=e.is12Hour,c=e.startOfWeek;return(0,l.useEffect)((function(){var e=document.querySelector(".future-action-calendar-toggle");if(e){var t=e.nextElementSibling;if(t){var n=t.querySelector(".components-datetime__time");if(n){var a=n.nextSibling;a&&t.insertBefore(e,a)}}}})),React.createElement(l.Fragment,null,React.createElement(o,{className:"future-action-calendar-toggle",isExpanded:t,iconExpanded:"arrow-up-alt2",iconCollapsed:"calendar",titleExpanded:n.hideCalendar,titleCollapsed:n.showCalendar,onClick:a}),React.createElement(u,{currentDate:r,onChange:i,__nextRemoveHelpButton:!0,is12Hour:s,startOfWeek:c}))};const d=wp.plugins;function f(){return f=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,a=Array(t);n0&&f&&(oe=function(e){return"object"!==h(e)||null===e?{}:e.map((function(e){return f[e]}))}(s),"string"==typeof(ie=oe?(Array.isArray(oe)||"object"!==a(oe)||(oe=Object.values(oe)),oe.filter((function(e){return null!=e&&""!==e}))):[])&&(ie=[]));var se=[];"object"===h(l)&&null!==l&&(se=Object.keys(l));var ce,ue=E?"future-action-panel":"future-action-panel hidden-calendar",le=E?"future-action-panel-content":"future-action-panel-content hidden-calendar",me=E?"future-action-date-panel":"future-action-date-panel hidden-calendar";ce="inherited"===e.timeFormat?!e.is12Hour:"24h"===e.timeFormat;var de=e.actionsSelectOptions;e.taxonomy||(de=e.actionsSelectOptions.filter((function(e){return-1===["category","category-add","category-remove","category-remove-all"].indexOf(e.value)})));var fe=function(e,t){var n=e.split("{"),a=[];a.push(n.shift());var r,o=function(e){var t="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!t){if(Array.isArray(e)||(t=S(e))){t&&(e=t);var n=0,a=function(){};return{s:a,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:a}}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 r,o=!0,i=!1;return{s:function(){t=t.call(e)},n:function(){var e=t.next();return o=e.done,e},e:function(e){i=!0,r=e},f:function(){try{o||null==t.return||t.return()}finally{if(i)throw r}}}}(n);try{for(o.s();!(r=o.n()).done;){var i=b(r.value.split("}"),2),s=i[0],c=i[1];a.push(React.createElement("a",{href:t,target:"_blank",key:t},s)),a.push(c)}}catch(e){o.e(e)}finally{o.f()}return a}(e.strings.timezoneSettingsHelp,"/wp-admin/options-general.php#timezone_string"),pe=String(n).includes("category")&&"category-remove-all"!==n,ye=u;switch(n){case"category":ye=e.strings.newTerms.replace("%s",u);break;case"category-remove":ye=e.strings.removeTerms.replace("%s",u);break;case"category-add":ye=e.strings.addTerms.replace("%s",u)}return R((function(){if(!i)return K(!0),void M("");K(function(){var t=!0;if(!i)return M(""),!0;n||(M(e.strings.errorActionRequired),t=!1),o||(M(e.strings.errorDateRequired),t=!1),o&&new Date(o)0&&void 0!==arguments[0]?arguments[0]:t,a=arguments.length>1?arguments[1]:void 0;switch(a.type){case"SET_POST_ID":return U(U({},n),{},{postId:a.postId});case"SET_ACTION":return U(U({},n),{},{action:a.action});case"SET_NEW_STATUS":return U(U({},n),{},{newStatus:a.newStatus});case"SET_DATE":return"number"==typeof a.date||(e=a.date,isNaN(e))||(a.date=parseInt(a.date)),"string"==typeof a.date&&(a.date=new Date(a.date).getTime()),a.date=c(a.date),a.date=i(a.date),U(U({},n),{},{date:a.date});case"SET_ENABLED":return U(U({},n),{},{enabled:a.enabled});case"SET_TERMS":return U(U({},n),{},{terms:a.terms});case"SET_TAXONOMY":return U(U({},n),{},{taxonomy:a.taxonomy});case"SET_TERMS_LIST_BY_NAME":return U(U({},n),{},{termsListByName:a.termsListByName});case"SET_TERMS_LIST_BY_ID":return U(U({},n),{},{termsListById:a.termsListById});case"SET_TAXONOMY_NAME":return U(U({},n),{},{taxonomyName:a.taxonomyName});case"SET_CHANGE_ACTION":return U(U({},n),{},{changeAction:a.changeAction});case"SET_CALENDAR_IS_VISIBLE":return U(U({},n),{},{calendarIsVisible:a.calendarIsVisible});case"SET_HAS_VALID_DATA":return U(U({},n),{},{hasValidData:a.hasValidData});case"SET_EXTRA_DATA":return U(U({},n),{},{extraData:U({},a.extraData)});case"SET_EXTRA_DATA_BY_NAME":var r=U(U({},n.extraData),{},Y({},a.name,a.value));return U(U({},n),{},{extraData:U({},r)})}return n},actions:{setPostId:function(e){return{type:"SET_POST_ID",postId:e}},setAction:function(e){return{type:"SET_ACTION",action:e}},setNewStatus:function(e){return{type:"SET_NEW_STATUS",newStatus:e}},setDate:function(e){return{type:"SET_DATE",date:e}},setEnabled:function(e){return{type:"SET_ENABLED",enabled:e}},setTerms:function(e){return{type:"SET_TERMS",terms:e}},setTaxonomy:function(e){return{type:"SET_TAXONOMY",taxonomy:e}},setTermsListByName:function(e){return{type:"SET_TERMS_LIST_BY_NAME",termsListByName:e}},setTermsListById:function(e){return{type:"SET_TERMS_LIST_BY_ID",termsListById:e}},setTaxonomyName:function(e){return{type:"SET_TAXONOMY_NAME",taxonomyName:e}},setIsFetchingTerms:function(e){return{type:"SET_IS_FETCHING_TERMS",isFetchingTerms:e}},setChangeAction:function(e){return{type:"SET_CHANGE_ACTION",changeAction:e}},setCalendarIsVisible:function(e){return{type:"SET_CALENDAR_IS_VISIBLE",calendarIsVisible:e}},setHasValidData:function(e){return{type:"SET_HAS_VALID_DATA",hasValidData:e}},setExtraData:function(e){return{type:"SET_EXTRA_DATA",extraData:e}},setExtraDataByName:function(e,t){return{type:"SET_EXTRA_DATA_BY_NAME",name:e,value:t}}},selectors:{getPostId:function(e){return e.postId},getAction:function(e){return e.action},getNewStatus:function(e){return e.newStatus},getDate:function(e){return e.date},getEnabled:function(e){return e.enabled},getTerms:function(e){return e.terms},getTaxonomy:function(e){return e.taxonomy},getTermsListByName:function(e){return e.termsListByName},getTermsListById:function(e){return e.termsListById},getTaxonomyName:function(e){return e.taxonomyName},getIsFetchingTerms:function(e){return e.isFetchingTerms},getChangeAction:function(e){return e.changeAction},getCalendarIsVisible:function(e){return e.calendarIsVisible},getHasValidData:function(e){return e.hasValidData},getExtraData:function(e){return e.extraData},getExtraDataByName:function(e,t){return e.extraData[t]||null}}});(0,V.register)(n)}({name:ie,defaultState:{postId:n,autoEnable:r,action:o,date:s,taxonomy:u,terms:m,newStatus:l}});var d=document.getElementById("publishpress-future-quick-edit");if(d){var f=(0,X.H)(d),p=document.querySelector(".inline-edit-save .save");p&&(p.onclick=function(){setTimeout((function(){f.unmount()}),1e3)});var y=React.createElement(H,{storeName:ie,postType:G,isNewPost:J,actionsSelectOptions:$,statusesSelectOptions:re,is12Hour:K,timeFormat:Z,startOfWeek:ee,strings:te,taxonomyName:ne,nonce:ae,hideCalendarByDefault:oe});f.render(y),Q.revert=function(){f.unmount(),ce.apply(this,arguments)}}}}})(); \ No newline at end of file +(()=>{"use strict";var e={1461:(e,t,n)=>{n.d(t,{A:()=>s});var a=n(1601),r=n.n(a),o=n(6314),i=n.n(o)()(r());i.push([e.id,".publishpress-future-date-preview .publishpress-future-date-preview-value {\n font-family: monospace;\n background-color: #e7e7e7;\n padding: 2px 4px;\n}\n\n.publishpress-future-date-preview.compact .publishpress-future-date-preview-label {\n display: block;\n}\n\n.publishpress-future-date-preview.compact {\n margin-bottom: 8px;\n}\n\n.publishpress-future-date-preview.compact h4 {\n font-size: 11px;\n font-weight: 500;\n line-height: 1.4;\n text-transform: uppercase;\n display: inline-block;\n margin-bottom: calc(8px);\n padding: 0px;\n flex-shrink: 0;\n margin-right: 12px;\n max-width: 75%;\n margin-top: 0;\n}\n\n.publishpress-future-notice.publishpress-future-notice-error {\n color: #dc3232;\n}\n",""]);const s=i},6314:e=>{e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",a=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),a&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),a&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,a,r,o){"string"==typeof e&&(e=[[null,e,void 0]]);var i={};if(a)for(var s=0;s0?" ".concat(l[5]):""," {").concat(l[1],"}")),l[5]=o),n&&(l[2]?(l[1]="@media ".concat(l[2]," {").concat(l[1],"}"),l[2]=n):l[2]=n),r&&(l[4]?(l[1]="@supports (".concat(l[4],") {").concat(l[1],"}"),l[4]=r):l[4]="".concat(r)),t.push(l))}},t}},1601:e=>{e.exports=function(e){return e[1]}},5338:(e,t,n)=>{var a=n(5206);t.H=a.createRoot,a.hydrateRoot},9922:(e,t,n)=>{n.r(t),n.d(t,{default:()=>h});var a=n(5072),r=n.n(a),o=n(7825),i=n.n(o),s=n(7659),c=n.n(s),u=n(5056),l=n.n(u),m=n(540),d=n.n(m),f=n(1113),p=n.n(f),y=n(1461),g={};g.styleTagTransform=p(),g.setAttributes=l(),g.insert=c().bind(null,"head"),g.domAPI=i(),g.insertStyleElement=d(),r()(y.A,g);const h=y.A&&y.A.locals?y.A.locals:void 0},5072:e=>{var t=[];function n(e){for(var n=-1,a=0;a{var t={};e.exports=function(e,n){var a=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!a)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");a.appendChild(n)}},540:e=>{e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},5056:(e,t,n)=>{e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},7825:e=>{e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var a="";n.supports&&(a+="@supports (".concat(n.supports,") {")),n.media&&(a+="@media ".concat(n.media," {"));var r=void 0!==n.layer;r&&(a+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),a+=n.css,r&&(a+="}"),n.media&&(a+="}"),n.supports&&(a+="}");var o=n.sourceMap;o&&"undefined"!=typeof btoa&&(a+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(o))))," */")),t.styleTagTransform(a,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},1113:e=>{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))}}},5206:e=>{e.exports=ReactDOM}},t={};function n(a){var r=t[a];if(void 0!==r)return r.exports;var o=t[a]={id:a,exports:{}};return e[a](o,o.exports,n),o.exports}function a(e){return a="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},a(e)}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var a in t)n.o(t,a)&&!n.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.nc=void 0;const r=wp.components;var o=function(e){var t=e.iconExpanded?e.iconExpanded:"arrow-up-alt2",n=e.iconCollapsed?e.iconCollapsed:"arrow-down-alt2",a=e.isExpanded?t:n,o=e.isExpanded?e.titleExpanded:e.titleCollapsed;return React.createElement(r.Button,{isSmall:!0,title:o,icon:a,onClick:function(){e.onClick&&e.onClick()},className:e.className})},i=function(e){var t=new Date(c(e)),n=t.getFullYear(),a=("0"+(t.getMonth()+1)).slice(-2),r=("0"+t.getDate()).slice(-2),o=("0"+t.getHours()).slice(-2),i=("0"+t.getMinutes()).slice(-2),s=("0"+t.getSeconds()).slice(-2);return"".concat(n,"-").concat(a,"-").concat(r," ").concat(o,":").concat(i,":").concat(s)},s=function(e){return parseInt(e).toString().length<=10},c=function(e){return e=parseInt(e),s()?e:e/1e3},u=function(e){var t,n=e.currentDate,a=e.onChange,o=e.is12Hour,i=e.startOfWeek;return"number"==typeof n&&(t=n,t=parseInt(t),n=s()?1e3*t:t),React.createElement(r.DateTimePicker,{currentDate:n,onChange:a,__nextRemoveHelpButton:!0,is12Hour:o,startOfWeek:i})};const l=wp.element;var m=function(e){var t=e.isExpanded,n=e.strings,a=e.onToggleCalendar,r=e.currentDate,i=e.onChangeDate,s=e.is12Hour,c=e.startOfWeek;return(0,l.useEffect)((function(){var e=document.querySelector(".future-action-calendar-toggle");if(e){var t=e.nextElementSibling;if(t){var n=t.querySelector(".components-datetime__time");if(n){var a=n.nextSibling;a&&t.insertBefore(e,a)}}}})),React.createElement(l.Fragment,null,React.createElement(o,{className:"future-action-calendar-toggle",isExpanded:t,iconExpanded:"arrow-up-alt2",iconCollapsed:"calendar",titleExpanded:n.hideCalendar,titleCollapsed:n.showCalendar,onClick:a}),React.createElement(u,{currentDate:r,onChange:i,__nextRemoveHelpButton:!0,is12Hour:s,startOfWeek:c}))};const d=wp.plugins;function f(){return f=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,a=Array(t);n0&&f&&(oe=function(e){return"object"!==h(e)||null===e?{}:e.map((function(e){return f[e]}))}(s),"string"==typeof(ie=oe?(Array.isArray(oe)||"object"!==a(oe)||(oe=Object.values(oe)),oe.filter((function(e){return null!=e&&""!==e}))):[])&&(ie=[]));var se=[];"object"===h(l)&&null!==l&&(se=Object.keys(l));var ce,ue=E?"future-action-panel":"future-action-panel hidden-calendar",le=E?"future-action-panel-content":"future-action-panel-content hidden-calendar",me=E?"future-action-date-panel":"future-action-date-panel hidden-calendar";ce="inherited"===e.timeFormat?!e.is12Hour:"24h"===e.timeFormat;var de=e.actionsSelectOptions;e.taxonomy||(de=e.actionsSelectOptions.filter((function(e){return-1===["category","category-add","category-remove","category-remove-all"].indexOf(e.value)})));var fe=function(e,t){var n=e.split("{"),a=[];a.push(n.shift());var r,o=function(e){var t="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!t){if(Array.isArray(e)||(t=S(e))){t&&(e=t);var n=0,a=function(){};return{s:a,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:a}}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 r,o=!0,i=!1;return{s:function(){t=t.call(e)},n:function(){var e=t.next();return o=e.done,e},e:function(e){i=!0,r=e},f:function(){try{o||null==t.return||t.return()}finally{if(i)throw r}}}}(n);try{for(o.s();!(r=o.n()).done;){var i=b(r.value.split("}"),2),s=i[0],c=i[1];a.push(React.createElement("a",{href:t,target:"_blank",key:t},s)),a.push(c)}}catch(e){o.e(e)}finally{o.f()}return a}(e.strings.timezoneSettingsHelp,"/wp-admin/options-general.php#timezone_string"),pe=String(n).includes("category")&&"category-remove-all"!==n,ye=u;switch(n){case"category":ye=e.strings.newTerms.replace("%s",u);break;case"category-remove":ye=e.strings.removeTerms.replace("%s",u);break;case"category-add":ye=e.strings.addTerms.replace("%s",u)}return R((function(){if(!i)return K(!0),void M("");K(function(){var t=!0;if(!i)return M(""),!0;n||(M(e.strings.errorActionRequired),t=!1),o||(M(e.strings.errorDateRequired),t=!1),o&&new Date(o)0&&void 0!==arguments[0]?arguments[0]:t,a=arguments.length>1?arguments[1]:void 0;switch(a.type){case"SET_POST_ID":return U(U({},n),{},{postId:a.postId});case"SET_ACTION":return U(U({},n),{},{action:a.action});case"SET_NEW_STATUS":return U(U({},n),{},{newStatus:a.newStatus});case"SET_DATE":return"number"==typeof a.date||(e=a.date,isNaN(e))||(a.date=parseInt(a.date)),"string"==typeof a.date&&(a.date=new Date(a.date).getTime()),a.date=c(a.date),a.date=i(a.date),U(U({},n),{},{date:a.date});case"SET_ENABLED":return U(U({},n),{},{enabled:a.enabled});case"SET_TERMS":return U(U({},n),{},{terms:a.terms});case"SET_TAXONOMY":return U(U({},n),{},{taxonomy:a.taxonomy});case"SET_TERMS_LIST_BY_NAME":return U(U({},n),{},{termsListByName:a.termsListByName});case"SET_TERMS_LIST_BY_ID":return U(U({},n),{},{termsListById:a.termsListById});case"SET_TAXONOMY_NAME":return U(U({},n),{},{taxonomyName:a.taxonomyName});case"SET_CHANGE_ACTION":return U(U({},n),{},{changeAction:a.changeAction});case"SET_CALENDAR_IS_VISIBLE":return U(U({},n),{},{calendarIsVisible:a.calendarIsVisible});case"SET_HAS_VALID_DATA":return U(U({},n),{},{hasValidData:a.hasValidData});case"SET_EXTRA_DATA":return U(U({},n),{},{extraData:U({},a.extraData)});case"SET_EXTRA_DATA_BY_NAME":var r=U(U({},n.extraData),{},Y({},a.name,a.value));return U(U({},n),{},{extraData:U({},r)})}return n},actions:{setPostId:function(e){return{type:"SET_POST_ID",postId:e}},setAction:function(e){return{type:"SET_ACTION",action:e}},setNewStatus:function(e){return{type:"SET_NEW_STATUS",newStatus:e}},setDate:function(e){return{type:"SET_DATE",date:e}},setEnabled:function(e){return{type:"SET_ENABLED",enabled:e}},setTerms:function(e){return{type:"SET_TERMS",terms:e}},setTaxonomy:function(e){return{type:"SET_TAXONOMY",taxonomy:e}},setTermsListByName:function(e){return{type:"SET_TERMS_LIST_BY_NAME",termsListByName:e}},setTermsListById:function(e){return{type:"SET_TERMS_LIST_BY_ID",termsListById:e}},setTaxonomyName:function(e){return{type:"SET_TAXONOMY_NAME",taxonomyName:e}},setIsFetchingTerms:function(e){return{type:"SET_IS_FETCHING_TERMS",isFetchingTerms:e}},setChangeAction:function(e){return{type:"SET_CHANGE_ACTION",changeAction:e}},setCalendarIsVisible:function(e){return{type:"SET_CALENDAR_IS_VISIBLE",calendarIsVisible:e}},setHasValidData:function(e){return{type:"SET_HAS_VALID_DATA",hasValidData:e}},setExtraData:function(e){return{type:"SET_EXTRA_DATA",extraData:e}},setExtraDataByName:function(e,t){return{type:"SET_EXTRA_DATA_BY_NAME",name:e,value:t}}},selectors:{getPostId:function(e){return e.postId},getAction:function(e){return e.action},getNewStatus:function(e){return e.newStatus},getDate:function(e){return e.date},getEnabled:function(e){return e.enabled},getTerms:function(e){return e.terms},getTaxonomy:function(e){return e.taxonomy},getTermsListByName:function(e){return e.termsListByName},getTermsListById:function(e){return e.termsListById},getTaxonomyName:function(e){return e.taxonomyName},getIsFetchingTerms:function(e){return e.isFetchingTerms},getChangeAction:function(e){return e.changeAction},getCalendarIsVisible:function(e){return e.calendarIsVisible},getHasValidData:function(e){return e.hasValidData},getExtraData:function(e){return e.extraData},getExtraDataByName:function(e,t){return e.extraData[t]||null}}});(0,V.register)(n)}({name:ie,defaultState:{postId:n,autoEnable:r,action:o,date:s,taxonomy:u,terms:m,newStatus:l}});var d=document.getElementById("publishpress-future-quick-edit");if(d){var f=(0,X.H)(d),p=document.querySelector(".inline-edit-save .save");p&&(p.onclick=function(){setTimeout((function(){f.unmount()}),1e3)});var y=React.createElement(H,{storeName:ie,postType:G,isNewPost:J,actionsSelectOptions:$,statusesSelectOptions:re,is12Hour:K,timeFormat:Z,startOfWeek:ee,strings:te,taxonomyName:ne,nonce:ae,hideCalendarByDefault:oe});f.render(y),Q.revert=function(){f.unmount(),ce.apply(this,arguments)}}}}})(); \ No newline at end of file diff --git a/assets/js/settingsGeneral.js b/assets/js/settingsGeneral.js index 13990db4e..40c0dad7f 100644 --- a/assets/js/settingsGeneral.js +++ b/assets/js/settingsGeneral.js @@ -584,7 +584,7 @@ var FutureActionPanel = function FutureActionPanel(props) { fontWeight: 'bold', marginBottom: '10px' } - }, props.strings.futureActions), /*#__PURE__*/React.createElement(_FutureActionPanelTop__WEBPACK_IMPORTED_MODULE_5__.FutureActionPanelTop.Slot, { + }, props.strings.panelTitle), /*#__PURE__*/React.createElement(_FutureActionPanelTop__WEBPACK_IMPORTED_MODULE_5__.FutureActionPanelTop.Slot, { fillProps: { storeName: props.storeName } diff --git a/assets/js/settingsPostTypes.js b/assets/js/settingsPostTypes.js index b9c2aa674..7405be6e9 100644 --- a/assets/js/settingsPostTypes.js +++ b/assets/js/settingsPostTypes.js @@ -584,7 +584,7 @@ var FutureActionPanel = function FutureActionPanel(props) { fontWeight: 'bold', marginBottom: '10px' } - }, props.strings.futureActions), /*#__PURE__*/React.createElement(_FutureActionPanelTop__WEBPACK_IMPORTED_MODULE_5__.FutureActionPanelTop.Slot, { + }, props.strings.panelTitle), /*#__PURE__*/React.createElement(_FutureActionPanelTop__WEBPACK_IMPORTED_MODULE_5__.FutureActionPanelTop.Slot, { fillProps: { storeName: props.storeName } diff --git a/assets/js/vendors-node_modules_html-to-image_es_index_js.js b/assets/js/vendors-node_modules_html-to-image_es_index_js.js new file mode 100644 index 000000000..d893b827e --- /dev/null +++ b/assets/js/vendors-node_modules_html-to-image_es_index_js.js @@ -0,0 +1,1070 @@ +"use strict"; +(self["webpackChunkpost_expirator"] = self["webpackChunkpost_expirator"] || []).push([["vendors-node_modules_html-to-image_es_index_js"],{ + +/***/ "./node_modules/html-to-image/es/apply-style.js": +/*!******************************************************!*\ + !*** ./node_modules/html-to-image/es/apply-style.js ***! + \******************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ applyStyle: () => (/* binding */ applyStyle) +/* harmony export */ }); +function applyStyle(node, options) { + const { style } = node; + if (options.backgroundColor) { + style.backgroundColor = options.backgroundColor; + } + if (options.width) { + style.width = `${options.width}px`; + } + if (options.height) { + style.height = `${options.height}px`; + } + const manual = options.style; + if (manual != null) { + Object.keys(manual).forEach((key) => { + style[key] = manual[key]; + }); + } + return node; +} +//# sourceMappingURL=apply-style.js.map + +/***/ }), + +/***/ "./node_modules/html-to-image/es/clone-node.js": +/*!*****************************************************!*\ + !*** ./node_modules/html-to-image/es/clone-node.js ***! + \*****************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ cloneNode: () => (/* binding */ cloneNode) +/* harmony export */ }); +/* harmony import */ var _clone_pseudos__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./clone-pseudos */ "./node_modules/html-to-image/es/clone-pseudos.js"); +/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./util */ "./node_modules/html-to-image/es/util.js"); +/* harmony import */ var _mimes__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./mimes */ "./node_modules/html-to-image/es/mimes.js"); +/* harmony import */ var _dataurl__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./dataurl */ "./node_modules/html-to-image/es/dataurl.js"); + + + + +async function cloneCanvasElement(canvas) { + const dataURL = canvas.toDataURL(); + if (dataURL === 'data:,') { + return canvas.cloneNode(false); + } + return (0,_util__WEBPACK_IMPORTED_MODULE_1__.createImage)(dataURL); +} +async function cloneVideoElement(video, options) { + if (video.currentSrc) { + const canvas = document.createElement('canvas'); + const ctx = canvas.getContext('2d'); + canvas.width = video.clientWidth; + canvas.height = video.clientHeight; + ctx === null || ctx === void 0 ? void 0 : ctx.drawImage(video, 0, 0, canvas.width, canvas.height); + const dataURL = canvas.toDataURL(); + return (0,_util__WEBPACK_IMPORTED_MODULE_1__.createImage)(dataURL); + } + const poster = video.poster; + const contentType = (0,_mimes__WEBPACK_IMPORTED_MODULE_2__.getMimeType)(poster); + const dataURL = await (0,_dataurl__WEBPACK_IMPORTED_MODULE_3__.resourceToDataURL)(poster, contentType, options); + return (0,_util__WEBPACK_IMPORTED_MODULE_1__.createImage)(dataURL); +} +async function cloneIFrameElement(iframe) { + var _a; + try { + if ((_a = iframe === null || iframe === void 0 ? void 0 : iframe.contentDocument) === null || _a === void 0 ? void 0 : _a.body) { + return (await cloneNode(iframe.contentDocument.body, {}, true)); + } + } + catch (_b) { + // Failed to clone iframe + } + return iframe.cloneNode(false); +} +async function cloneSingleNode(node, options) { + if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(node, HTMLCanvasElement)) { + return cloneCanvasElement(node); + } + if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(node, HTMLVideoElement)) { + return cloneVideoElement(node, options); + } + if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(node, HTMLIFrameElement)) { + return cloneIFrameElement(node); + } + return node.cloneNode(false); +} +const isSlotElement = (node) => node.tagName != null && node.tagName.toUpperCase() === 'SLOT'; +async function cloneChildren(nativeNode, clonedNode, options) { + var _a, _b; + let children = []; + if (isSlotElement(nativeNode) && nativeNode.assignedNodes) { + children = (0,_util__WEBPACK_IMPORTED_MODULE_1__.toArray)(nativeNode.assignedNodes()); + } + else if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(nativeNode, HTMLIFrameElement) && + ((_a = nativeNode.contentDocument) === null || _a === void 0 ? void 0 : _a.body)) { + children = (0,_util__WEBPACK_IMPORTED_MODULE_1__.toArray)(nativeNode.contentDocument.body.childNodes); + } + else { + children = (0,_util__WEBPACK_IMPORTED_MODULE_1__.toArray)(((_b = nativeNode.shadowRoot) !== null && _b !== void 0 ? _b : nativeNode).childNodes); + } + if (children.length === 0 || + (0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(nativeNode, HTMLVideoElement)) { + return clonedNode; + } + await children.reduce((deferred, child) => deferred + .then(() => cloneNode(child, options)) + .then((clonedChild) => { + if (clonedChild) { + clonedNode.appendChild(clonedChild); + } + }), Promise.resolve()); + return clonedNode; +} +function cloneCSSStyle(nativeNode, clonedNode) { + const targetStyle = clonedNode.style; + if (!targetStyle) { + return; + } + const sourceStyle = window.getComputedStyle(nativeNode); + if (sourceStyle.cssText) { + targetStyle.cssText = sourceStyle.cssText; + targetStyle.transformOrigin = sourceStyle.transformOrigin; + } + else { + (0,_util__WEBPACK_IMPORTED_MODULE_1__.toArray)(sourceStyle).forEach((name) => { + let value = sourceStyle.getPropertyValue(name); + if (name === 'font-size' && value.endsWith('px')) { + const reducedFont = Math.floor(parseFloat(value.substring(0, value.length - 2))) - 0.1; + value = `${reducedFont}px`; + } + if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(nativeNode, HTMLIFrameElement) && + name === 'display' && + value === 'inline') { + value = 'block'; + } + if (name === 'd' && clonedNode.getAttribute('d')) { + value = `path(${clonedNode.getAttribute('d')})`; + } + targetStyle.setProperty(name, value, sourceStyle.getPropertyPriority(name)); + }); + } +} +function cloneInputValue(nativeNode, clonedNode) { + if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(nativeNode, HTMLTextAreaElement)) { + clonedNode.innerHTML = nativeNode.value; + } + if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(nativeNode, HTMLInputElement)) { + clonedNode.setAttribute('value', nativeNode.value); + } +} +function cloneSelectValue(nativeNode, clonedNode) { + if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(nativeNode, HTMLSelectElement)) { + const clonedSelect = clonedNode; + const selectedOption = Array.from(clonedSelect.children).find((child) => nativeNode.value === child.getAttribute('value')); + if (selectedOption) { + selectedOption.setAttribute('selected', ''); + } + } +} +function decorate(nativeNode, clonedNode) { + if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(clonedNode, Element)) { + cloneCSSStyle(nativeNode, clonedNode); + (0,_clone_pseudos__WEBPACK_IMPORTED_MODULE_0__.clonePseudoElements)(nativeNode, clonedNode); + cloneInputValue(nativeNode, clonedNode); + cloneSelectValue(nativeNode, clonedNode); + } + return clonedNode; +} +async function ensureSVGSymbols(clone, options) { + const uses = clone.querySelectorAll ? clone.querySelectorAll('use') : []; + if (uses.length === 0) { + return clone; + } + const processedDefs = {}; + for (let i = 0; i < uses.length; i++) { + const use = uses[i]; + const id = use.getAttribute('xlink:href'); + if (id) { + const exist = clone.querySelector(id); + const definition = document.querySelector(id); + if (!exist && definition && !processedDefs[id]) { + // eslint-disable-next-line no-await-in-loop + processedDefs[id] = (await cloneNode(definition, options, true)); + } + } + } + const nodes = Object.values(processedDefs); + if (nodes.length) { + const ns = 'http://www.w3.org/1999/xhtml'; + const svg = document.createElementNS(ns, 'svg'); + svg.setAttribute('xmlns', ns); + svg.style.position = 'absolute'; + svg.style.width = '0'; + svg.style.height = '0'; + svg.style.overflow = 'hidden'; + svg.style.display = 'none'; + const defs = document.createElementNS(ns, 'defs'); + svg.appendChild(defs); + for (let i = 0; i < nodes.length; i++) { + defs.appendChild(nodes[i]); + } + clone.appendChild(svg); + } + return clone; +} +async function cloneNode(node, options, isRoot) { + if (!isRoot && options.filter && !options.filter(node)) { + return null; + } + return Promise.resolve(node) + .then((clonedNode) => cloneSingleNode(clonedNode, options)) + .then((clonedNode) => cloneChildren(node, clonedNode, options)) + .then((clonedNode) => decorate(node, clonedNode)) + .then((clonedNode) => ensureSVGSymbols(clonedNode, options)); +} +//# sourceMappingURL=clone-node.js.map + +/***/ }), + +/***/ "./node_modules/html-to-image/es/clone-pseudos.js": +/*!********************************************************!*\ + !*** ./node_modules/html-to-image/es/clone-pseudos.js ***! + \********************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ clonePseudoElements: () => (/* binding */ clonePseudoElements) +/* harmony export */ }); +/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./util */ "./node_modules/html-to-image/es/util.js"); + +function formatCSSText(style) { + const content = style.getPropertyValue('content'); + return `${style.cssText} content: '${content.replace(/'|"/g, '')}';`; +} +function formatCSSProperties(style) { + return (0,_util__WEBPACK_IMPORTED_MODULE_0__.toArray)(style) + .map((name) => { + const value = style.getPropertyValue(name); + const priority = style.getPropertyPriority(name); + return `${name}: ${value}${priority ? ' !important' : ''};`; + }) + .join(' '); +} +function getPseudoElementStyle(className, pseudo, style) { + const selector = `.${className}:${pseudo}`; + const cssText = style.cssText + ? formatCSSText(style) + : formatCSSProperties(style); + return document.createTextNode(`${selector}{${cssText}}`); +} +function clonePseudoElement(nativeNode, clonedNode, pseudo) { + const style = window.getComputedStyle(nativeNode, pseudo); + const content = style.getPropertyValue('content'); + if (content === '' || content === 'none') { + return; + } + const className = (0,_util__WEBPACK_IMPORTED_MODULE_0__.uuid)(); + try { + clonedNode.className = `${clonedNode.className} ${className}`; + } + catch (err) { + return; + } + const styleElement = document.createElement('style'); + styleElement.appendChild(getPseudoElementStyle(className, pseudo, style)); + clonedNode.appendChild(styleElement); +} +function clonePseudoElements(nativeNode, clonedNode) { + clonePseudoElement(nativeNode, clonedNode, ':before'); + clonePseudoElement(nativeNode, clonedNode, ':after'); +} +//# sourceMappingURL=clone-pseudos.js.map + +/***/ }), + +/***/ "./node_modules/html-to-image/es/dataurl.js": +/*!**************************************************!*\ + !*** ./node_modules/html-to-image/es/dataurl.js ***! + \**************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ fetchAsDataURL: () => (/* binding */ fetchAsDataURL), +/* harmony export */ isDataUrl: () => (/* binding */ isDataUrl), +/* harmony export */ makeDataUrl: () => (/* binding */ makeDataUrl), +/* harmony export */ resourceToDataURL: () => (/* binding */ resourceToDataURL) +/* harmony export */ }); +function getContentFromDataUrl(dataURL) { + return dataURL.split(/,/)[1]; +} +function isDataUrl(url) { + return url.search(/^(data:)/) !== -1; +} +function makeDataUrl(content, mimeType) { + return `data:${mimeType};base64,${content}`; +} +async function fetchAsDataURL(url, init, process) { + const res = await fetch(url, init); + if (res.status === 404) { + throw new Error(`Resource "${res.url}" not found`); + } + const blob = await res.blob(); + return new Promise((resolve, reject) => { + const reader = new FileReader(); + reader.onerror = reject; + reader.onloadend = () => { + try { + resolve(process({ res, result: reader.result })); + } + catch (error) { + reject(error); + } + }; + reader.readAsDataURL(blob); + }); +} +const cache = {}; +function getCacheKey(url, contentType, includeQueryParams) { + let key = url.replace(/\?.*/, ''); + if (includeQueryParams) { + key = url; + } + // font resource + if (/ttf|otf|eot|woff2?/i.test(key)) { + key = key.replace(/.*\//, ''); + } + return contentType ? `[${contentType}]${key}` : key; +} +async function resourceToDataURL(resourceUrl, contentType, options) { + const cacheKey = getCacheKey(resourceUrl, contentType, options.includeQueryParams); + if (cache[cacheKey] != null) { + return cache[cacheKey]; + } + // ref: https://developer.mozilla.org/en/docs/Web/API/XMLHttpRequest/Using_XMLHttpRequest#Bypassing_the_cache + if (options.cacheBust) { + // eslint-disable-next-line no-param-reassign + resourceUrl += (/\?/.test(resourceUrl) ? '&' : '?') + new Date().getTime(); + } + let dataURL; + try { + const content = await fetchAsDataURL(resourceUrl, options.fetchRequestInit, ({ res, result }) => { + if (!contentType) { + // eslint-disable-next-line no-param-reassign + contentType = res.headers.get('Content-Type') || ''; + } + return getContentFromDataUrl(result); + }); + dataURL = makeDataUrl(content, contentType); + } + catch (error) { + dataURL = options.imagePlaceholder || ''; + let msg = `Failed to fetch resource: ${resourceUrl}`; + if (error) { + msg = typeof error === 'string' ? error : error.message; + } + if (msg) { + console.warn(msg); + } + } + cache[cacheKey] = dataURL; + return dataURL; +} +//# sourceMappingURL=dataurl.js.map + +/***/ }), + +/***/ "./node_modules/html-to-image/es/embed-images.js": +/*!*******************************************************!*\ + !*** ./node_modules/html-to-image/es/embed-images.js ***! + \*******************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ embedImages: () => (/* binding */ embedImages) +/* harmony export */ }); +/* harmony import */ var _embed_resources__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./embed-resources */ "./node_modules/html-to-image/es/embed-resources.js"); +/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./util */ "./node_modules/html-to-image/es/util.js"); +/* harmony import */ var _dataurl__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./dataurl */ "./node_modules/html-to-image/es/dataurl.js"); +/* harmony import */ var _mimes__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./mimes */ "./node_modules/html-to-image/es/mimes.js"); + + + + +async function embedProp(propName, node, options) { + var _a; + const propValue = (_a = node.style) === null || _a === void 0 ? void 0 : _a.getPropertyValue(propName); + if (propValue) { + const cssString = await (0,_embed_resources__WEBPACK_IMPORTED_MODULE_0__.embedResources)(propValue, null, options); + node.style.setProperty(propName, cssString, node.style.getPropertyPriority(propName)); + return true; + } + return false; +} +async function embedBackground(clonedNode, options) { + if (!(await embedProp('background', clonedNode, options))) { + await embedProp('background-image', clonedNode, options); + } + if (!(await embedProp('mask', clonedNode, options))) { + await embedProp('mask-image', clonedNode, options); + } +} +async function embedImageNode(clonedNode, options) { + const isImageElement = (0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(clonedNode, HTMLImageElement); + if (!(isImageElement && !(0,_dataurl__WEBPACK_IMPORTED_MODULE_2__.isDataUrl)(clonedNode.src)) && + !((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(clonedNode, SVGImageElement) && + !(0,_dataurl__WEBPACK_IMPORTED_MODULE_2__.isDataUrl)(clonedNode.href.baseVal))) { + return; + } + const url = isImageElement ? clonedNode.src : clonedNode.href.baseVal; + const dataURL = await (0,_dataurl__WEBPACK_IMPORTED_MODULE_2__.resourceToDataURL)(url, (0,_mimes__WEBPACK_IMPORTED_MODULE_3__.getMimeType)(url), options); + await new Promise((resolve, reject) => { + clonedNode.onload = resolve; + clonedNode.onerror = reject; + const image = clonedNode; + if (image.decode) { + image.decode = resolve; + } + if (image.loading === 'lazy') { + image.loading = 'eager'; + } + if (isImageElement) { + clonedNode.srcset = ''; + clonedNode.src = dataURL; + } + else { + clonedNode.href.baseVal = dataURL; + } + }); +} +async function embedChildren(clonedNode, options) { + const children = (0,_util__WEBPACK_IMPORTED_MODULE_1__.toArray)(clonedNode.childNodes); + const deferreds = children.map((child) => embedImages(child, options)); + await Promise.all(deferreds).then(() => clonedNode); +} +async function embedImages(clonedNode, options) { + if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(clonedNode, Element)) { + await embedBackground(clonedNode, options); + await embedImageNode(clonedNode, options); + await embedChildren(clonedNode, options); + } +} +//# sourceMappingURL=embed-images.js.map + +/***/ }), + +/***/ "./node_modules/html-to-image/es/embed-resources.js": +/*!**********************************************************!*\ + !*** ./node_modules/html-to-image/es/embed-resources.js ***! + \**********************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ embed: () => (/* binding */ embed), +/* harmony export */ embedResources: () => (/* binding */ embedResources), +/* harmony export */ parseURLs: () => (/* binding */ parseURLs), +/* harmony export */ shouldEmbed: () => (/* binding */ shouldEmbed) +/* harmony export */ }); +/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./util */ "./node_modules/html-to-image/es/util.js"); +/* harmony import */ var _mimes__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./mimes */ "./node_modules/html-to-image/es/mimes.js"); +/* harmony import */ var _dataurl__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./dataurl */ "./node_modules/html-to-image/es/dataurl.js"); + + + +const URL_REGEX = /url\((['"]?)([^'"]+?)\1\)/g; +const URL_WITH_FORMAT_REGEX = /url\([^)]+\)\s*format\((["']?)([^"']+)\1\)/g; +const FONT_SRC_REGEX = /src:\s*(?:url\([^)]+\)\s*format\([^)]+\)[,;]\s*)+/g; +function toRegex(url) { + // eslint-disable-next-line no-useless-escape + const escaped = url.replace(/([.*+?^${}()|\[\]\/\\])/g, '\\$1'); + return new RegExp(`(url\\(['"]?)(${escaped})(['"]?\\))`, 'g'); +} +function parseURLs(cssText) { + const urls = []; + cssText.replace(URL_REGEX, (raw, quotation, url) => { + urls.push(url); + return raw; + }); + return urls.filter((url) => !(0,_dataurl__WEBPACK_IMPORTED_MODULE_2__.isDataUrl)(url)); +} +async function embed(cssText, resourceURL, baseURL, options, getContentFromUrl) { + try { + const resolvedURL = baseURL ? (0,_util__WEBPACK_IMPORTED_MODULE_0__.resolveUrl)(resourceURL, baseURL) : resourceURL; + const contentType = (0,_mimes__WEBPACK_IMPORTED_MODULE_1__.getMimeType)(resourceURL); + let dataURL; + if (getContentFromUrl) { + const content = await getContentFromUrl(resolvedURL); + dataURL = (0,_dataurl__WEBPACK_IMPORTED_MODULE_2__.makeDataUrl)(content, contentType); + } + else { + dataURL = await (0,_dataurl__WEBPACK_IMPORTED_MODULE_2__.resourceToDataURL)(resolvedURL, contentType, options); + } + return cssText.replace(toRegex(resourceURL), `$1${dataURL}$3`); + } + catch (error) { + // pass + } + return cssText; +} +function filterPreferredFontFormat(str, { preferredFontFormat }) { + return !preferredFontFormat + ? str + : str.replace(FONT_SRC_REGEX, (match) => { + // eslint-disable-next-line no-constant-condition + while (true) { + const [src, , format] = URL_WITH_FORMAT_REGEX.exec(match) || []; + if (!format) { + return ''; + } + if (format === preferredFontFormat) { + return `src: ${src};`; + } + } + }); +} +function shouldEmbed(url) { + return url.search(URL_REGEX) !== -1; +} +async function embedResources(cssText, baseUrl, options) { + if (!shouldEmbed(cssText)) { + return cssText; + } + const filteredCSSText = filterPreferredFontFormat(cssText, options); + const urls = parseURLs(filteredCSSText); + return urls.reduce((deferred, url) => deferred.then((css) => embed(css, url, baseUrl, options)), Promise.resolve(filteredCSSText)); +} +//# sourceMappingURL=embed-resources.js.map + +/***/ }), + +/***/ "./node_modules/html-to-image/es/embed-webfonts.js": +/*!*********************************************************!*\ + !*** ./node_modules/html-to-image/es/embed-webfonts.js ***! + \*********************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ embedWebFonts: () => (/* binding */ embedWebFonts), +/* harmony export */ getWebFontCSS: () => (/* binding */ getWebFontCSS) +/* harmony export */ }); +/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./util */ "./node_modules/html-to-image/es/util.js"); +/* harmony import */ var _dataurl__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./dataurl */ "./node_modules/html-to-image/es/dataurl.js"); +/* harmony import */ var _embed_resources__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./embed-resources */ "./node_modules/html-to-image/es/embed-resources.js"); + + + +const cssFetchCache = {}; +async function fetchCSS(url) { + let cache = cssFetchCache[url]; + if (cache != null) { + return cache; + } + const res = await fetch(url); + const cssText = await res.text(); + cache = { url, cssText }; + cssFetchCache[url] = cache; + return cache; +} +async function embedFonts(data, options) { + let cssText = data.cssText; + const regexUrl = /url\(["']?([^"')]+)["']?\)/g; + const fontLocs = cssText.match(/url\([^)]+\)/g) || []; + const loadFonts = fontLocs.map(async (loc) => { + let url = loc.replace(regexUrl, '$1'); + if (!url.startsWith('https://')) { + url = new URL(url, data.url).href; + } + return (0,_dataurl__WEBPACK_IMPORTED_MODULE_1__.fetchAsDataURL)(url, options.fetchRequestInit, ({ result }) => { + cssText = cssText.replace(loc, `url(${result})`); + return [loc, result]; + }); + }); + return Promise.all(loadFonts).then(() => cssText); +} +function parseCSS(source) { + if (source == null) { + return []; + } + const result = []; + const commentsRegex = /(\/\*[\s\S]*?\*\/)/gi; + // strip out comments + let cssText = source.replace(commentsRegex, ''); + // eslint-disable-next-line prefer-regex-literals + const keyframesRegex = new RegExp('((@.*?keyframes [\\s\\S]*?){([\\s\\S]*?}\\s*?)})', 'gi'); + // eslint-disable-next-line no-constant-condition + while (true) { + const matches = keyframesRegex.exec(cssText); + if (matches === null) { + break; + } + result.push(matches[0]); + } + cssText = cssText.replace(keyframesRegex, ''); + const importRegex = /@import[\s\S]*?url\([^)]*\)[\s\S]*?;/gi; + // to match css & media queries together + const combinedCSSRegex = '((\\s*?(?:\\/\\*[\\s\\S]*?\\*\\/)?\\s*?@media[\\s\\S]' + + '*?){([\\s\\S]*?)}\\s*?})|(([\\s\\S]*?){([\\s\\S]*?)})'; + // unified regex + const unifiedRegex = new RegExp(combinedCSSRegex, 'gi'); + // eslint-disable-next-line no-constant-condition + while (true) { + let matches = importRegex.exec(cssText); + if (matches === null) { + matches = unifiedRegex.exec(cssText); + if (matches === null) { + break; + } + else { + importRegex.lastIndex = unifiedRegex.lastIndex; + } + } + else { + unifiedRegex.lastIndex = importRegex.lastIndex; + } + result.push(matches[0]); + } + return result; +} +async function getCSSRules(styleSheets, options) { + const ret = []; + const deferreds = []; + // First loop inlines imports + styleSheets.forEach((sheet) => { + if ('cssRules' in sheet) { + try { + (0,_util__WEBPACK_IMPORTED_MODULE_0__.toArray)(sheet.cssRules || []).forEach((item, index) => { + if (item.type === CSSRule.IMPORT_RULE) { + let importIndex = index + 1; + const url = item.href; + const deferred = fetchCSS(url) + .then((metadata) => embedFonts(metadata, options)) + .then((cssText) => parseCSS(cssText).forEach((rule) => { + try { + sheet.insertRule(rule, rule.startsWith('@import') + ? (importIndex += 1) + : sheet.cssRules.length); + } + catch (error) { + console.error('Error inserting rule from remote css', { + rule, + error, + }); + } + })) + .catch((e) => { + console.error('Error loading remote css', e.toString()); + }); + deferreds.push(deferred); + } + }); + } + catch (e) { + const inline = styleSheets.find((a) => a.href == null) || document.styleSheets[0]; + if (sheet.href != null) { + deferreds.push(fetchCSS(sheet.href) + .then((metadata) => embedFonts(metadata, options)) + .then((cssText) => parseCSS(cssText).forEach((rule) => { + inline.insertRule(rule, sheet.cssRules.length); + })) + .catch((err) => { + console.error('Error loading remote stylesheet', err); + })); + } + console.error('Error inlining remote css file', e); + } + } + }); + return Promise.all(deferreds).then(() => { + // Second loop parses rules + styleSheets.forEach((sheet) => { + if ('cssRules' in sheet) { + try { + (0,_util__WEBPACK_IMPORTED_MODULE_0__.toArray)(sheet.cssRules || []).forEach((item) => { + ret.push(item); + }); + } + catch (e) { + console.error(`Error while reading CSS rules from ${sheet.href}`, e); + } + } + }); + return ret; + }); +} +function getWebFontRules(cssRules) { + return cssRules + .filter((rule) => rule.type === CSSRule.FONT_FACE_RULE) + .filter((rule) => (0,_embed_resources__WEBPACK_IMPORTED_MODULE_2__.shouldEmbed)(rule.style.getPropertyValue('src'))); +} +async function parseWebFontRules(node, options) { + if (node.ownerDocument == null) { + throw new Error('Provided element is not within a Document'); + } + const styleSheets = (0,_util__WEBPACK_IMPORTED_MODULE_0__.toArray)(node.ownerDocument.styleSheets); + const cssRules = await getCSSRules(styleSheets, options); + return getWebFontRules(cssRules); +} +async function getWebFontCSS(node, options) { + const rules = await parseWebFontRules(node, options); + const cssTexts = await Promise.all(rules.map((rule) => { + const baseUrl = rule.parentStyleSheet ? rule.parentStyleSheet.href : null; + return (0,_embed_resources__WEBPACK_IMPORTED_MODULE_2__.embedResources)(rule.cssText, baseUrl, options); + })); + return cssTexts.join('\n'); +} +async function embedWebFonts(clonedNode, options) { + const cssText = options.fontEmbedCSS != null + ? options.fontEmbedCSS + : options.skipFonts + ? null + : await getWebFontCSS(clonedNode, options); + if (cssText) { + const styleNode = document.createElement('style'); + const sytleContent = document.createTextNode(cssText); + styleNode.appendChild(sytleContent); + if (clonedNode.firstChild) { + clonedNode.insertBefore(styleNode, clonedNode.firstChild); + } + else { + clonedNode.appendChild(styleNode); + } + } +} +//# sourceMappingURL=embed-webfonts.js.map + +/***/ }), + +/***/ "./node_modules/html-to-image/es/index.js": +/*!************************************************!*\ + !*** ./node_modules/html-to-image/es/index.js ***! + \************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ getFontEmbedCSS: () => (/* binding */ getFontEmbedCSS), +/* harmony export */ toBlob: () => (/* binding */ toBlob), +/* harmony export */ toCanvas: () => (/* binding */ toCanvas), +/* harmony export */ toJpeg: () => (/* binding */ toJpeg), +/* harmony export */ toPixelData: () => (/* binding */ toPixelData), +/* harmony export */ toPng: () => (/* binding */ toPng), +/* harmony export */ toSvg: () => (/* binding */ toSvg) +/* harmony export */ }); +/* harmony import */ var _clone_node__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./clone-node */ "./node_modules/html-to-image/es/clone-node.js"); +/* harmony import */ var _embed_images__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./embed-images */ "./node_modules/html-to-image/es/embed-images.js"); +/* harmony import */ var _apply_style__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./apply-style */ "./node_modules/html-to-image/es/apply-style.js"); +/* harmony import */ var _embed_webfonts__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./embed-webfonts */ "./node_modules/html-to-image/es/embed-webfonts.js"); +/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./util */ "./node_modules/html-to-image/es/util.js"); + + + + + +async function toSvg(node, options = {}) { + const { width, height } = (0,_util__WEBPACK_IMPORTED_MODULE_4__.getImageSize)(node, options); + const clonedNode = (await (0,_clone_node__WEBPACK_IMPORTED_MODULE_0__.cloneNode)(node, options, true)); + await (0,_embed_webfonts__WEBPACK_IMPORTED_MODULE_3__.embedWebFonts)(clonedNode, options); + await (0,_embed_images__WEBPACK_IMPORTED_MODULE_1__.embedImages)(clonedNode, options); + (0,_apply_style__WEBPACK_IMPORTED_MODULE_2__.applyStyle)(clonedNode, options); + const datauri = await (0,_util__WEBPACK_IMPORTED_MODULE_4__.nodeToDataURL)(clonedNode, width, height); + return datauri; +} +async function toCanvas(node, options = {}) { + const { width, height } = (0,_util__WEBPACK_IMPORTED_MODULE_4__.getImageSize)(node, options); + const svg = await toSvg(node, options); + const img = await (0,_util__WEBPACK_IMPORTED_MODULE_4__.createImage)(svg); + const canvas = document.createElement('canvas'); + const context = canvas.getContext('2d'); + const ratio = options.pixelRatio || (0,_util__WEBPACK_IMPORTED_MODULE_4__.getPixelRatio)(); + const canvasWidth = options.canvasWidth || width; + const canvasHeight = options.canvasHeight || height; + canvas.width = canvasWidth * ratio; + canvas.height = canvasHeight * ratio; + if (!options.skipAutoScale) { + (0,_util__WEBPACK_IMPORTED_MODULE_4__.checkCanvasDimensions)(canvas); + } + canvas.style.width = `${canvasWidth}`; + canvas.style.height = `${canvasHeight}`; + if (options.backgroundColor) { + context.fillStyle = options.backgroundColor; + context.fillRect(0, 0, canvas.width, canvas.height); + } + context.drawImage(img, 0, 0, canvas.width, canvas.height); + return canvas; +} +async function toPixelData(node, options = {}) { + const { width, height } = (0,_util__WEBPACK_IMPORTED_MODULE_4__.getImageSize)(node, options); + const canvas = await toCanvas(node, options); + const ctx = canvas.getContext('2d'); + return ctx.getImageData(0, 0, width, height).data; +} +async function toPng(node, options = {}) { + const canvas = await toCanvas(node, options); + return canvas.toDataURL(); +} +async function toJpeg(node, options = {}) { + const canvas = await toCanvas(node, options); + return canvas.toDataURL('image/jpeg', options.quality || 1); +} +async function toBlob(node, options = {}) { + const canvas = await toCanvas(node, options); + const blob = await (0,_util__WEBPACK_IMPORTED_MODULE_4__.canvasToBlob)(canvas); + return blob; +} +async function getFontEmbedCSS(node, options = {}) { + return (0,_embed_webfonts__WEBPACK_IMPORTED_MODULE_3__.getWebFontCSS)(node, options); +} +//# sourceMappingURL=index.js.map + +/***/ }), + +/***/ "./node_modules/html-to-image/es/mimes.js": +/*!************************************************!*\ + !*** ./node_modules/html-to-image/es/mimes.js ***! + \************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ getMimeType: () => (/* binding */ getMimeType) +/* harmony export */ }); +const WOFF = 'application/font-woff'; +const JPEG = 'image/jpeg'; +const mimes = { + woff: WOFF, + woff2: WOFF, + ttf: 'application/font-truetype', + eot: 'application/vnd.ms-fontobject', + png: 'image/png', + jpg: JPEG, + jpeg: JPEG, + gif: 'image/gif', + tiff: 'image/tiff', + svg: 'image/svg+xml', + webp: 'image/webp', +}; +function getExtension(url) { + const match = /\.([^./]*?)$/g.exec(url); + return match ? match[1] : ''; +} +function getMimeType(url) { + const extension = getExtension(url).toLowerCase(); + return mimes[extension] || ''; +} +//# sourceMappingURL=mimes.js.map + +/***/ }), + +/***/ "./node_modules/html-to-image/es/util.js": +/*!***********************************************!*\ + !*** ./node_modules/html-to-image/es/util.js ***! + \***********************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ canvasToBlob: () => (/* binding */ canvasToBlob), +/* harmony export */ checkCanvasDimensions: () => (/* binding */ checkCanvasDimensions), +/* harmony export */ createImage: () => (/* binding */ createImage), +/* harmony export */ delay: () => (/* binding */ delay), +/* harmony export */ getImageSize: () => (/* binding */ getImageSize), +/* harmony export */ getPixelRatio: () => (/* binding */ getPixelRatio), +/* harmony export */ isInstanceOfElement: () => (/* binding */ isInstanceOfElement), +/* harmony export */ nodeToDataURL: () => (/* binding */ nodeToDataURL), +/* harmony export */ resolveUrl: () => (/* binding */ resolveUrl), +/* harmony export */ svgToDataURL: () => (/* binding */ svgToDataURL), +/* harmony export */ toArray: () => (/* binding */ toArray), +/* harmony export */ uuid: () => (/* binding */ uuid) +/* harmony export */ }); +function resolveUrl(url, baseUrl) { + // url is absolute already + if (url.match(/^[a-z]+:\/\//i)) { + return url; + } + // url is absolute already, without protocol + if (url.match(/^\/\//)) { + return window.location.protocol + url; + } + // dataURI, mailto:, tel:, etc. + if (url.match(/^[a-z]+:/i)) { + return url; + } + const doc = document.implementation.createHTMLDocument(); + const base = doc.createElement('base'); + const a = doc.createElement('a'); + doc.head.appendChild(base); + doc.body.appendChild(a); + if (baseUrl) { + base.href = baseUrl; + } + a.href = url; + return a.href; +} +const uuid = (() => { + // generate uuid for className of pseudo elements. + // We should not use GUIDs, otherwise pseudo elements sometimes cannot be captured. + let counter = 0; + // ref: http://stackoverflow.com/a/6248722/2519373 + const random = () => + // eslint-disable-next-line no-bitwise + `0000${((Math.random() * 36 ** 4) << 0).toString(36)}`.slice(-4); + return () => { + counter += 1; + return `u${random()}${counter}`; + }; +})(); +function delay(ms) { + return (args) => new Promise((resolve) => { + setTimeout(() => resolve(args), ms); + }); +} +function toArray(arrayLike) { + const arr = []; + for (let i = 0, l = arrayLike.length; i < l; i++) { + arr.push(arrayLike[i]); + } + return arr; +} +function px(node, styleProperty) { + const win = node.ownerDocument.defaultView || window; + const val = win.getComputedStyle(node).getPropertyValue(styleProperty); + return val ? parseFloat(val.replace('px', '')) : 0; +} +function getNodeWidth(node) { + const leftBorder = px(node, 'border-left-width'); + const rightBorder = px(node, 'border-right-width'); + return node.clientWidth + leftBorder + rightBorder; +} +function getNodeHeight(node) { + const topBorder = px(node, 'border-top-width'); + const bottomBorder = px(node, 'border-bottom-width'); + return node.clientHeight + topBorder + bottomBorder; +} +function getImageSize(targetNode, options = {}) { + const width = options.width || getNodeWidth(targetNode); + const height = options.height || getNodeHeight(targetNode); + return { width, height }; +} +function getPixelRatio() { + let ratio; + let FINAL_PROCESS; + try { + FINAL_PROCESS = process; + } + catch (e) { + // pass + } + const val = FINAL_PROCESS && FINAL_PROCESS.env + ? FINAL_PROCESS.env.devicePixelRatio + : null; + if (val) { + ratio = parseInt(val, 10); + if (Number.isNaN(ratio)) { + ratio = 1; + } + } + return ratio || window.devicePixelRatio || 1; +} +// @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/canvas#maximum_canvas_size +const canvasDimensionLimit = 16384; +function checkCanvasDimensions(canvas) { + if (canvas.width > canvasDimensionLimit || + canvas.height > canvasDimensionLimit) { + if (canvas.width > canvasDimensionLimit && + canvas.height > canvasDimensionLimit) { + if (canvas.width > canvas.height) { + canvas.height *= canvasDimensionLimit / canvas.width; + canvas.width = canvasDimensionLimit; + } + else { + canvas.width *= canvasDimensionLimit / canvas.height; + canvas.height = canvasDimensionLimit; + } + } + else if (canvas.width > canvasDimensionLimit) { + canvas.height *= canvasDimensionLimit / canvas.width; + canvas.width = canvasDimensionLimit; + } + else { + canvas.width *= canvasDimensionLimit / canvas.height; + canvas.height = canvasDimensionLimit; + } + } +} +function canvasToBlob(canvas, options = {}) { + if (canvas.toBlob) { + return new Promise((resolve) => { + canvas.toBlob(resolve, options.type ? options.type : 'image/png', options.quality ? options.quality : 1); + }); + } + return new Promise((resolve) => { + const binaryString = window.atob(canvas + .toDataURL(options.type ? options.type : undefined, options.quality ? options.quality : undefined) + .split(',')[1]); + const len = binaryString.length; + const binaryArray = new Uint8Array(len); + for (let i = 0; i < len; i += 1) { + binaryArray[i] = binaryString.charCodeAt(i); + } + resolve(new Blob([binaryArray], { + type: options.type ? options.type : 'image/png', + })); + }); +} +function createImage(url) { + return new Promise((resolve, reject) => { + const img = new Image(); + img.decode = () => resolve(img); + img.onload = () => resolve(img); + img.onerror = reject; + img.crossOrigin = 'anonymous'; + img.decoding = 'async'; + img.src = url; + }); +} +async function svgToDataURL(svg) { + return Promise.resolve() + .then(() => new XMLSerializer().serializeToString(svg)) + .then(encodeURIComponent) + .then((html) => `data:image/svg+xml;charset=utf-8,${html}`); +} +async function nodeToDataURL(node, width, height) { + const xmlns = 'http://www.w3.org/2000/svg'; + const svg = document.createElementNS(xmlns, 'svg'); + const foreignObject = document.createElementNS(xmlns, 'foreignObject'); + svg.setAttribute('width', `${width}`); + svg.setAttribute('height', `${height}`); + svg.setAttribute('viewBox', `0 0 ${width} ${height}`); + foreignObject.setAttribute('width', '100%'); + foreignObject.setAttribute('height', '100%'); + foreignObject.setAttribute('x', '0'); + foreignObject.setAttribute('y', '0'); + foreignObject.setAttribute('externalResourcesRequired', 'true'); + svg.appendChild(foreignObject); + foreignObject.appendChild(node); + return svgToDataURL(svg); +} +const isInstanceOfElement = (node, instance) => { + if (node instanceof instance) + return true; + const nodePrototype = Object.getPrototypeOf(node); + if (nodePrototype === null) + return false; + return (nodePrototype.constructor.name === instance.name || + isInstanceOfElement(nodePrototype, instance)); +}; +//# sourceMappingURL=util.js.map + +/***/ }) + +}]); +//# sourceMappingURL=vendors-node_modules_html-to-image_es_index_js.js.map \ No newline at end of file diff --git a/assets/js/workflowEditor.js b/assets/js/workflowEditor.js index b5976c24d..c126cd8c3 100644 --- a/assets/js/workflowEditor.js +++ b/assets/js/workflowEditor.js @@ -12563,7 +12563,7 @@ function DateOffset(_ref) { value: value }); }, - help: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Define a custom expression for a unique task ID. Use placeholders like {{onSavePost1.post.ID}} or {{global.user.ID}} to make sure the ID is unique.", "post-expirator") + help: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Define a custom expression for a unique task ID. Use placeholders like {{onSavePost1.post.ID}}, {{global.user.ID}} or {{global.execution_id}} to make sure the ID is unique.", "post-expirator") })), /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.TextControl, { label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Priority", "post-expirator"), value: defaultValue.priority || 10, @@ -12625,6 +12625,12 @@ function DebugData(_ref) { }); }); } + + // Add a new option to output custom data + debugOptions.push({ + name: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Custom data", "post-expirator"), + id: "custom-data" + }); var defaultDebugOption = "all-input"; var onChangeSetting = function onChangeSetting(_ref2) { var settingName = _ref2.settingName, @@ -12645,6 +12651,15 @@ function DebugData(_ref) { value: value }); } + }), (defaultValue === null || defaultValue === void 0 ? void 0 : defaultValue.dataToOutput) === "custom-data" && /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.TextareaControl, { + label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Custom data", "post-expirator"), + value: defaultValue === null || defaultValue === void 0 ? void 0 : defaultValue.customData, + onChange: function onChange(value) { + return onChangeSetting({ + settingName: "customData", + value: value + }); + } }))); } /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (DebugData); @@ -12766,13 +12781,10 @@ function EmailRecipient(_ref) { _ref$variables = _ref.variables, variables = _ref$variables === void 0 ? [] : _ref$variables; variables = (0,_utils__WEBPACK_IMPORTED_MODULE_3__.filterVariableOptionsByDataType)(variables, ['email']); - var recipientOptions = [{ - name: '', - id: '' - }, { + var recipientOptions = [].concat(_toConsumableArray(variables), [{ name: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Custom Addresses", "post-expirator"), id: "custom" - }].concat(_toConsumableArray(variables)); + }]); var onChangeSetting = function onChangeSetting(_ref2) { var settingName = _ref2.settingName, value = _ref2.value; @@ -12795,7 +12807,7 @@ function EmailRecipient(_ref) { value: value }); } - }), (defaultValue === null || defaultValue === void 0 ? void 0 : defaultValue.recipient) === "custom" && /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.TextControl, { + }), (defaultValue === null || defaultValue === void 0 ? void 0 : defaultValue.recipient) === "custom" && /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.TextareaControl, { label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Custom Email Addresses", "post-expirator"), value: (defaultValue === null || defaultValue === void 0 ? void 0 : defaultValue.custom) || "", onChange: function onChange(value) { @@ -13058,6 +13070,7 @@ function PostQuery(_ref) { } }; var acceptsInput = settings && (settings === null || settings === void 0 ? void 0 : settings.acceptsInput) === true; + var isPostTypeRequired = settings && (settings === null || settings === void 0 ? void 0 : settings.isPostTypeRequired) === true; var defaultPostSource = acceptsInput ? 'input' : 'custom'; var showCustomQueryFields = ((_defaultValue = defaultValue) === null || _defaultValue === void 0 ? void 0 : _defaultValue.postSource) === 'custom' || !acceptsInput; @@ -13076,6 +13089,7 @@ function PostQuery(_ref) { }); } }, []); + var postTypeFieldLabel = isPostTypeRequired ? (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Post Type', 'post-expirator') + ' *' : (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Post Type', 'post-expirator'); return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_0__.__experimentalVStack, null, acceptsInput && /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_0__.RadioControl, { label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Post selection', 'post-expirator'), selected: ((_defaultValue2 = defaultValue) === null || _defaultValue2 === void 0 ? void 0 : _defaultValue2.postSource) || defaultPostSource, @@ -13093,7 +13107,7 @@ function PostQuery(_ref) { }); } }), showCustomQueryFields && /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(_inline_multi_select__WEBPACK_IMPORTED_MODULE_3__.InlineMultiSelect, { - label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Post Type', 'post-expirator'), + label: postTypeFieldLabel, value: ((_defaultValue3 = defaultValue) === null || _defaultValue3 === void 0 ? void 0 : _defaultValue3.postType) || [], suggestions: postTypes, expandOnFocus: true, @@ -13105,7 +13119,7 @@ function PostQuery(_ref) { }); } }), /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_0__.FormTokenField, { - label: "Post ID", + label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('Post ID', 'post-expirator'), value: ((_defaultValue4 = defaultValue) === null || _defaultValue4 === void 0 ? void 0 : _defaultValue4.postId) || [], onChange: function onChange(value) { return onChangeSetting({ @@ -13125,7 +13139,9 @@ function PostQuery(_ref) { value: value }); } - })))); + })), isPostTypeRequired && /*#__PURE__*/React.createElement("p", { + className: "description" + }, (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__.__)('* Required field', 'post-expirator')))); } /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (PostQuery); @@ -13897,6 +13913,10 @@ function PostData() { name: "permalink", type: "string", label: "Permalink" + }, { + name: "meta", + type: "object", + label: "Metadata" }] }; } @@ -13923,6 +13943,10 @@ function SiteData() { type: "object", objectType: "site", propertiesSchema: [{ + name: "id", + type: "integer", + label: "ID" + }, { name: "name", type: "string", label: "Name" @@ -13942,6 +13966,10 @@ function SiteData() { name: "admin_email", type: "email", label: "Admin Email" + }, { + name: "meta", + type: "object", + label: "Metadata" }] }; } @@ -14018,6 +14046,10 @@ function UserData() { name: "user_registered", type: "datetime", label: "Registration Date" + }, { + name: "meta", + type: "object", + label: "Metadata" }] }; } @@ -14063,6 +14095,10 @@ function WorkflowData() { name: "steps", type: "node", label: "Steps" + }, { + name: "meta", + type: "object", + label: "Metadata" }] }; } @@ -16476,8 +16512,6 @@ var LayoutHeader = function LayoutHeader() { isInserterOpened: select(_editor_store__WEBPACK_IMPORTED_MODULE_5__.store).isFeatureActive(_constants__WEBPACK_IMPORTED_MODULE_7__.FEATURE_INSERTER), showIconLabels: select(_editor_store__WEBPACK_IMPORTED_MODULE_5__.store).isFeatureActive(_constants__WEBPACK_IMPORTED_MODULE_7__.FEATURE_SHOW_ICON_LABELS), isLoadingWorkflow: select(_workflow_store__WEBPACK_IMPORTED_MODULE_6__.store).isLoadingWorkflow(), - isEditedWorkflowDirty: select(_workflow_store__WEBPACK_IMPORTED_MODULE_6__.store).isEditedWorkflowDirty(), - takeScreenshot: select(_workflow_store__WEBPACK_IMPORTED_MODULE_6__.store).takeScreenshot, isPro: select(_editor_store__WEBPACK_IMPORTED_MODULE_5__.store).isPro() }; }), @@ -16486,8 +16520,6 @@ var LayoutHeader = function LayoutHeader() { hasReducedUI = _useSelect.hasReducedUI, showIconLabels = _useSelect.showIconLabels, isLoadingWorkflow = _useSelect.isLoadingWorkflow, - isEditedWorkflowDirty = _useSelect.isEditedWorkflowDirty, - takeScreenshot = _useSelect.takeScreenshot, isPro = _useSelect.isPro; var _useDispatch = (0,_wordpress_data__WEBPACK_IMPORTED_MODULE_0__.useDispatch)(_editor_store__WEBPACK_IMPORTED_MODULE_5__.store), enableFeature = _useDispatch.enableFeature, @@ -21222,6 +21254,8 @@ function WorkflowPublishButton(_ref) { saveAsCurrentStatus = _useDispatch.saveAsCurrentStatus, publishWorkflow = _useDispatch.publishWorkflow; var wasSaving = (0,_wordpress_compose__WEBPACK_IMPORTED_MODULE_7__["default"])(isSaving); + var _futureWorkflowEditor = futureWorkflowEditor, + enableWorkflowScreenshot = _futureWorkflowEditor.enableWorkflowScreenshot; (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_3__.useEffect)(function () { var timeoutId; if (wasSaving && !isSaving) { @@ -21255,17 +21289,25 @@ function WorkflowPublishButton(_ref) { if (isDisabled) { return; } - takeScreenshot().then(function (dataUrl) { + if (enableWorkflowScreenshot) { + takeScreenshot().then(function (dataUrl) { + if (isPublished) { + saveAsCurrentStatus({ + screenshot: dataUrl + }); + } else { + publishWorkflow({ + screenshot: dataUrl + }); + } + }); + } else { if (isPublished) { - saveAsCurrentStatus({ - screenshot: dataUrl - }); + saveAsCurrentStatus(); } else { - publishWorkflow({ - screenshot: dataUrl - }); + publishWorkflow(); } - }); + } }; // Use common Button instance for all saved states so that focus is not @@ -21386,6 +21428,8 @@ function WorkflowSaveDraftButton(_ref) { var _useDispatch = (0,_wordpress_data__WEBPACK_IMPORTED_MODULE_2__.useDispatch)(_workflow_store__WEBPACK_IMPORTED_MODULE_5__.store), saveAsDraft = _useDispatch.saveAsDraft; var wasSaving = (0,_wordpress_compose__WEBPACK_IMPORTED_MODULE_7__["default"])(isSaving); + var _futureWorkflowEditor = futureWorkflowEditor, + enableWorkflowScreenshot = _futureWorkflowEditor.enableWorkflowScreenshot; (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_3__.useEffect)(function () { var timeoutId; if (wasSaving && !isSaving) { @@ -21421,11 +21465,15 @@ function WorkflowSaveDraftButton(_ref) { text = shortLabel; } var onClick = function onClick() { - takeScreenshot().then(function (screenshot) { - saveAsDraft({ - screenshot: screenshot + if (enableWorkflowScreenshot) { + takeScreenshot().then(function (screenshot) { + saveAsDraft({ + screenshot: screenshot + }); }); - }); + } else { + saveAsDraft(); + } }; // Use common Button instance for all saved states so that focus is not @@ -21600,8 +21648,9 @@ function setupEditor(workflowId) { }, _marked, null, [[6, 14], [20, 28]]); } ; -function saveAsDraft(_ref) { - var screenshot = _ref.screenshot; +function saveAsDraft() { + var _ref = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}, + screenshot = _ref.screenshot; return /*#__PURE__*/_regeneratorRuntime().mark(function _callee() { var wasNewWorkflow, editedWorkflow, newWorkflow; return _regeneratorRuntime().wrap(function _callee$(_context2) { @@ -21669,8 +21718,9 @@ function saveAsDraft(_ref) { }, _callee, null, [[2, 21]]); })(); } -function saveAsCurrentStatus(_ref2) { - var screenshot = _ref2.screenshot; +function saveAsCurrentStatus() { + var _ref2 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}, + screenshot = _ref2.screenshot; return /*#__PURE__*/_regeneratorRuntime().mark(function _callee2() { var editedWorkflow, newWorkflow; return _regeneratorRuntime().wrap(function _callee2$(_context3) { @@ -21727,8 +21777,9 @@ function saveAsCurrentStatus(_ref2) { }, _callee2, null, [[2, 15]]); })(); } -function publishWorkflow(_ref3) { - var screenshot = _ref3.screenshot; +function publishWorkflow() { + var _ref3 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}, + screenshot = _ref3.screenshot; return /*#__PURE__*/_regeneratorRuntime().mark(function _callee3() { var wasNewWorkflow, editedWorkflow, newWorkflow; return _regeneratorRuntime().wrap(function _callee3$(_context4) { @@ -21796,8 +21847,9 @@ function publishWorkflow(_ref3) { }, _callee3, null, [[2, 21]]); })(); } -function switchToDraft(_ref4) { - var screenshot = _ref4.screenshot; +function switchToDraft() { + var _ref4 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}, + screenshot = _ref4.screenshot; return /*#__PURE__*/_regeneratorRuntime().mark(function _callee4() { var wasNewWorkflow, editedWorkflow, newWorkflow; return _regeneratorRuntime().wrap(function _callee4$(_context5) { @@ -22360,6 +22412,14 @@ function _setInitialStateForGlobalVariables(state) { runtimeOnly: true } }); + state = setGlobalVariable(state, { + payload: { + name: 'execution_id', + label: 'Execution ID', + type: 'string', + runtimeOnly: true + } + }); return state; } var loadWorkflowSuccess = function loadWorkflowSuccess(state, action) { @@ -22961,15 +23021,15 @@ __webpack_require__.r(__webpack_exports__); /* harmony export */ isWorkflowFlowEmpty: () => (/* binding */ isWorkflowFlowEmpty), /* harmony export */ takeScreenshot: () => (/* binding */ takeScreenshot) /* harmony export */ }); -/* harmony import */ var html_to_image__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! html-to-image */ "./node_modules/html-to-image/es/index.js"); +function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { 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 define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, ""); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, "_invoke", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: "normal", arg: t.call(e, r) }; } catch (t) { return { type: "throw", arg: t }; } } e.wrap = wrap; var h = "suspendedStart", l = "suspendedYield", f = "executing", s = "completed", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { ["next", "throw", "return"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if ("throw" !== c.type) { var u = c.arg, h = u.value; return h && "object" == _typeof(h) && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) { invoke("next", t, i, a); }, function (t) { invoke("throw", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke("throw", t, i, a); }); } a(c.arg); } var r; o(this, "_invoke", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw Error("Generator is already running"); if (o === s) { 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 = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else "return" === n.method && n.abrupt("return", n.arg); o = f; var p = tryCatch(e, r, n); if ("normal" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg); } }; } function maybeInvokeDelegate(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, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y; var i = tryCatch(o, e.iterator, r.arg); if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y; 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, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y); } function pushTryEntry(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 resetTryEntry(t) { var e = t.completion || {}; e.type = "normal", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: "root" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(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 next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(_typeof(e) + " is not iterable"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) { var e = "function" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () { return this; }), define(g, "toString", function () { return "[object Generator]"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if ("throw" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if ("root" === i.tryLoc) return handle("end"); if (i.tryLoc <= this.prev) { var c = n.call(i, "catchLoc"), u = n.call(i, "finallyLoc"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw Error("try statement without catch or finally"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) { var i = o; break; } } i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if ("throw" === t.type) throw t.arg; return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, catch: function _catch(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; resetTryEntry(r); } return o; } } throw Error("illegal catch attempt"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, "next" === this.method && (this.arg = t), y; } }, e; } function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); } +function asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); } +function _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, "next", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, "throw", n); } _next(void 0); }); }; } function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; } function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; } function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; } function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; } function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); } -// import { createRegistrySelector } from '@wordpress/data'; - var getPostType = function getPostType(state) { return state.postType; }; @@ -23080,26 +23140,51 @@ var getDataTypeByName = function getDataTypeByName(state, name) { }); }; function takeScreenshot() { - return new Promise(function (resolve, reject) { - try { - (0,html_to_image__WEBPACK_IMPORTED_MODULE_0__.toPng)(document.querySelector('.react-flow'), { - filter: function filter(node) { - var _node$classList, _node$classList2, _node$classList3; - // We don't want to add the minimap and the controls to the image - if (node !== null && node !== void 0 && (_node$classList = node.classList) !== null && _node$classList !== void 0 && _node$classList.contains('react-flow__minimap') || node !== null && node !== void 0 && (_node$classList2 = node.classList) !== null && _node$classList2 !== void 0 && _node$classList2.contains('react-flow__controls') || node !== null && node !== void 0 && (_node$classList3 = node.classList) !== null && _node$classList3 !== void 0 && _node$classList3.contains('pwe-node-edit-button')) { - return false; + return _takeScreenshot.apply(this, arguments); +} +function _takeScreenshot() { + _takeScreenshot = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee() { + var _futureWorkflowEditor, enableWorkflowScreenshot, _yield$import, toPng; + return _regeneratorRuntime().wrap(function _callee$(_context) { + while (1) switch (_context.prev = _context.next) { + case 0: + _futureWorkflowEditor = futureWorkflowEditor, enableWorkflowScreenshot = _futureWorkflowEditor.enableWorkflowScreenshot; + if (enableWorkflowScreenshot) { + _context.next = 3; + break; } - return true; - } - }).then(function (dataUrl) { - resolve(dataUrl); // Resolve with the image dataUrl - }).catch(function (error) { - reject(error); // Reject with the error - }); - } catch (error) { - reject(error); // Reject with the error - } - }); + return _context.abrupt("return", null); + case 3: + _context.prev = 3; + _context.next = 6; + return __webpack_require__.e(/*! import() */ "vendors-node_modules_html-to-image_es_index_js").then(__webpack_require__.bind(__webpack_require__, /*! html-to-image */ "./node_modules/html-to-image/es/index.js")); + case 6: + _yield$import = _context.sent; + toPng = _yield$import.toPng; + _context.next = 10; + return toPng(document.querySelector('.react-flow'), { + filter: function filter(node) { + var _node$classList, _node$classList2, _node$classList3; + if (node !== null && node !== void 0 && (_node$classList = node.classList) !== null && _node$classList !== void 0 && _node$classList.contains('react-flow__minimap') || node !== null && node !== void 0 && (_node$classList2 = node.classList) !== null && _node$classList2 !== void 0 && _node$classList2.contains('react-flow__controls') || node !== null && node !== void 0 && (_node$classList3 = node.classList) !== null && _node$classList3 !== void 0 && _node$classList3.contains('pwe-node-edit-button')) { + return false; + } + return true; + } + }); + case 10: + return _context.abrupt("return", _context.sent); + case 13: + _context.prev = 13; + _context.t0 = _context["catch"](3); + console.error('Error loading html-to-image:', _context.t0); + return _context.abrupt("return", null); + case 17: + case "end": + return _context.stop(); + } + }, _callee, null, [[3, 13]]); + })); + return _takeScreenshot.apply(this, arguments); } function getGlobalVariables(state) { return state.globalVariables; @@ -23262,6 +23347,8 @@ function WorkflowSwitchToDraftButton() { if (!isPublishedWorkflow) { return null; } + var _futureWorkflowEditor = futureWorkflowEditor, + enableWorkflowScreenshot = _futureWorkflowEditor.enableWorkflowScreenshot; var onSwitch = function onSwitch() { var alertMessage; if (isPublishedWorkflow) { @@ -23271,11 +23358,15 @@ function WorkflowSwitchToDraftButton() { return; } if (window.confirm(alertMessage)) { - takeScreenshot().then(function (dataUrl) { - switchToDraft({ - screenshot: dataUrl + if (enableWorkflowScreenshot) { + takeScreenshot().then(function (dataUrl) { + switchToDraft({ + screenshot: dataUrl + }); }); - }); + } else { + switchToDraft(); + } } }; return /*#__PURE__*/React.createElement(_wordpress_components__WEBPACK_IMPORTED_MODULE_0__.Button, { @@ -25685,1081 +25776,6 @@ module.exports = function (item) { /***/ }), -/***/ "./node_modules/html-to-image/es/apply-style.js": -/*!******************************************************!*\ - !*** ./node_modules/html-to-image/es/apply-style.js ***! - \******************************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ applyStyle: () => (/* binding */ applyStyle) -/* harmony export */ }); -function applyStyle(node, options) { - const { style } = node; - if (options.backgroundColor) { - style.backgroundColor = options.backgroundColor; - } - if (options.width) { - style.width = `${options.width}px`; - } - if (options.height) { - style.height = `${options.height}px`; - } - const manual = options.style; - if (manual != null) { - Object.keys(manual).forEach((key) => { - style[key] = manual[key]; - }); - } - return node; -} -//# sourceMappingURL=apply-style.js.map - -/***/ }), - -/***/ "./node_modules/html-to-image/es/clone-node.js": -/*!*****************************************************!*\ - !*** ./node_modules/html-to-image/es/clone-node.js ***! - \*****************************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ cloneNode: () => (/* binding */ cloneNode) -/* harmony export */ }); -/* harmony import */ var _clone_pseudos__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./clone-pseudos */ "./node_modules/html-to-image/es/clone-pseudos.js"); -/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./util */ "./node_modules/html-to-image/es/util.js"); -/* harmony import */ var _mimes__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./mimes */ "./node_modules/html-to-image/es/mimes.js"); -/* harmony import */ var _dataurl__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./dataurl */ "./node_modules/html-to-image/es/dataurl.js"); - - - - -async function cloneCanvasElement(canvas) { - const dataURL = canvas.toDataURL(); - if (dataURL === 'data:,') { - return canvas.cloneNode(false); - } - return (0,_util__WEBPACK_IMPORTED_MODULE_1__.createImage)(dataURL); -} -async function cloneVideoElement(video, options) { - if (video.currentSrc) { - const canvas = document.createElement('canvas'); - const ctx = canvas.getContext('2d'); - canvas.width = video.clientWidth; - canvas.height = video.clientHeight; - ctx === null || ctx === void 0 ? void 0 : ctx.drawImage(video, 0, 0, canvas.width, canvas.height); - const dataURL = canvas.toDataURL(); - return (0,_util__WEBPACK_IMPORTED_MODULE_1__.createImage)(dataURL); - } - const poster = video.poster; - const contentType = (0,_mimes__WEBPACK_IMPORTED_MODULE_2__.getMimeType)(poster); - const dataURL = await (0,_dataurl__WEBPACK_IMPORTED_MODULE_3__.resourceToDataURL)(poster, contentType, options); - return (0,_util__WEBPACK_IMPORTED_MODULE_1__.createImage)(dataURL); -} -async function cloneIFrameElement(iframe) { - var _a; - try { - if ((_a = iframe === null || iframe === void 0 ? void 0 : iframe.contentDocument) === null || _a === void 0 ? void 0 : _a.body) { - return (await cloneNode(iframe.contentDocument.body, {}, true)); - } - } - catch (_b) { - // Failed to clone iframe - } - return iframe.cloneNode(false); -} -async function cloneSingleNode(node, options) { - if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(node, HTMLCanvasElement)) { - return cloneCanvasElement(node); - } - if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(node, HTMLVideoElement)) { - return cloneVideoElement(node, options); - } - if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(node, HTMLIFrameElement)) { - return cloneIFrameElement(node); - } - return node.cloneNode(false); -} -const isSlotElement = (node) => node.tagName != null && node.tagName.toUpperCase() === 'SLOT'; -async function cloneChildren(nativeNode, clonedNode, options) { - var _a, _b; - let children = []; - if (isSlotElement(nativeNode) && nativeNode.assignedNodes) { - children = (0,_util__WEBPACK_IMPORTED_MODULE_1__.toArray)(nativeNode.assignedNodes()); - } - else if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(nativeNode, HTMLIFrameElement) && - ((_a = nativeNode.contentDocument) === null || _a === void 0 ? void 0 : _a.body)) { - children = (0,_util__WEBPACK_IMPORTED_MODULE_1__.toArray)(nativeNode.contentDocument.body.childNodes); - } - else { - children = (0,_util__WEBPACK_IMPORTED_MODULE_1__.toArray)(((_b = nativeNode.shadowRoot) !== null && _b !== void 0 ? _b : nativeNode).childNodes); - } - if (children.length === 0 || - (0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(nativeNode, HTMLVideoElement)) { - return clonedNode; - } - await children.reduce((deferred, child) => deferred - .then(() => cloneNode(child, options)) - .then((clonedChild) => { - if (clonedChild) { - clonedNode.appendChild(clonedChild); - } - }), Promise.resolve()); - return clonedNode; -} -function cloneCSSStyle(nativeNode, clonedNode) { - const targetStyle = clonedNode.style; - if (!targetStyle) { - return; - } - const sourceStyle = window.getComputedStyle(nativeNode); - if (sourceStyle.cssText) { - targetStyle.cssText = sourceStyle.cssText; - targetStyle.transformOrigin = sourceStyle.transformOrigin; - } - else { - (0,_util__WEBPACK_IMPORTED_MODULE_1__.toArray)(sourceStyle).forEach((name) => { - let value = sourceStyle.getPropertyValue(name); - if (name === 'font-size' && value.endsWith('px')) { - const reducedFont = Math.floor(parseFloat(value.substring(0, value.length - 2))) - 0.1; - value = `${reducedFont}px`; - } - if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(nativeNode, HTMLIFrameElement) && - name === 'display' && - value === 'inline') { - value = 'block'; - } - if (name === 'd' && clonedNode.getAttribute('d')) { - value = `path(${clonedNode.getAttribute('d')})`; - } - targetStyle.setProperty(name, value, sourceStyle.getPropertyPriority(name)); - }); - } -} -function cloneInputValue(nativeNode, clonedNode) { - if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(nativeNode, HTMLTextAreaElement)) { - clonedNode.innerHTML = nativeNode.value; - } - if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(nativeNode, HTMLInputElement)) { - clonedNode.setAttribute('value', nativeNode.value); - } -} -function cloneSelectValue(nativeNode, clonedNode) { - if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(nativeNode, HTMLSelectElement)) { - const clonedSelect = clonedNode; - const selectedOption = Array.from(clonedSelect.children).find((child) => nativeNode.value === child.getAttribute('value')); - if (selectedOption) { - selectedOption.setAttribute('selected', ''); - } - } -} -function decorate(nativeNode, clonedNode) { - if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(clonedNode, Element)) { - cloneCSSStyle(nativeNode, clonedNode); - (0,_clone_pseudos__WEBPACK_IMPORTED_MODULE_0__.clonePseudoElements)(nativeNode, clonedNode); - cloneInputValue(nativeNode, clonedNode); - cloneSelectValue(nativeNode, clonedNode); - } - return clonedNode; -} -async function ensureSVGSymbols(clone, options) { - const uses = clone.querySelectorAll ? clone.querySelectorAll('use') : []; - if (uses.length === 0) { - return clone; - } - const processedDefs = {}; - for (let i = 0; i < uses.length; i++) { - const use = uses[i]; - const id = use.getAttribute('xlink:href'); - if (id) { - const exist = clone.querySelector(id); - const definition = document.querySelector(id); - if (!exist && definition && !processedDefs[id]) { - // eslint-disable-next-line no-await-in-loop - processedDefs[id] = (await cloneNode(definition, options, true)); - } - } - } - const nodes = Object.values(processedDefs); - if (nodes.length) { - const ns = 'http://www.w3.org/1999/xhtml'; - const svg = document.createElementNS(ns, 'svg'); - svg.setAttribute('xmlns', ns); - svg.style.position = 'absolute'; - svg.style.width = '0'; - svg.style.height = '0'; - svg.style.overflow = 'hidden'; - svg.style.display = 'none'; - const defs = document.createElementNS(ns, 'defs'); - svg.appendChild(defs); - for (let i = 0; i < nodes.length; i++) { - defs.appendChild(nodes[i]); - } - clone.appendChild(svg); - } - return clone; -} -async function cloneNode(node, options, isRoot) { - if (!isRoot && options.filter && !options.filter(node)) { - return null; - } - return Promise.resolve(node) - .then((clonedNode) => cloneSingleNode(clonedNode, options)) - .then((clonedNode) => cloneChildren(node, clonedNode, options)) - .then((clonedNode) => decorate(node, clonedNode)) - .then((clonedNode) => ensureSVGSymbols(clonedNode, options)); -} -//# sourceMappingURL=clone-node.js.map - -/***/ }), - -/***/ "./node_modules/html-to-image/es/clone-pseudos.js": -/*!********************************************************!*\ - !*** ./node_modules/html-to-image/es/clone-pseudos.js ***! - \********************************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ clonePseudoElements: () => (/* binding */ clonePseudoElements) -/* harmony export */ }); -/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./util */ "./node_modules/html-to-image/es/util.js"); - -function formatCSSText(style) { - const content = style.getPropertyValue('content'); - return `${style.cssText} content: '${content.replace(/'|"/g, '')}';`; -} -function formatCSSProperties(style) { - return (0,_util__WEBPACK_IMPORTED_MODULE_0__.toArray)(style) - .map((name) => { - const value = style.getPropertyValue(name); - const priority = style.getPropertyPriority(name); - return `${name}: ${value}${priority ? ' !important' : ''};`; - }) - .join(' '); -} -function getPseudoElementStyle(className, pseudo, style) { - const selector = `.${className}:${pseudo}`; - const cssText = style.cssText - ? formatCSSText(style) - : formatCSSProperties(style); - return document.createTextNode(`${selector}{${cssText}}`); -} -function clonePseudoElement(nativeNode, clonedNode, pseudo) { - const style = window.getComputedStyle(nativeNode, pseudo); - const content = style.getPropertyValue('content'); - if (content === '' || content === 'none') { - return; - } - const className = (0,_util__WEBPACK_IMPORTED_MODULE_0__.uuid)(); - try { - clonedNode.className = `${clonedNode.className} ${className}`; - } - catch (err) { - return; - } - const styleElement = document.createElement('style'); - styleElement.appendChild(getPseudoElementStyle(className, pseudo, style)); - clonedNode.appendChild(styleElement); -} -function clonePseudoElements(nativeNode, clonedNode) { - clonePseudoElement(nativeNode, clonedNode, ':before'); - clonePseudoElement(nativeNode, clonedNode, ':after'); -} -//# sourceMappingURL=clone-pseudos.js.map - -/***/ }), - -/***/ "./node_modules/html-to-image/es/dataurl.js": -/*!**************************************************!*\ - !*** ./node_modules/html-to-image/es/dataurl.js ***! - \**************************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ fetchAsDataURL: () => (/* binding */ fetchAsDataURL), -/* harmony export */ isDataUrl: () => (/* binding */ isDataUrl), -/* harmony export */ makeDataUrl: () => (/* binding */ makeDataUrl), -/* harmony export */ resourceToDataURL: () => (/* binding */ resourceToDataURL) -/* harmony export */ }); -function getContentFromDataUrl(dataURL) { - return dataURL.split(/,/)[1]; -} -function isDataUrl(url) { - return url.search(/^(data:)/) !== -1; -} -function makeDataUrl(content, mimeType) { - return `data:${mimeType};base64,${content}`; -} -async function fetchAsDataURL(url, init, process) { - const res = await fetch(url, init); - if (res.status === 404) { - throw new Error(`Resource "${res.url}" not found`); - } - const blob = await res.blob(); - return new Promise((resolve, reject) => { - const reader = new FileReader(); - reader.onerror = reject; - reader.onloadend = () => { - try { - resolve(process({ res, result: reader.result })); - } - catch (error) { - reject(error); - } - }; - reader.readAsDataURL(blob); - }); -} -const cache = {}; -function getCacheKey(url, contentType, includeQueryParams) { - let key = url.replace(/\?.*/, ''); - if (includeQueryParams) { - key = url; - } - // font resource - if (/ttf|otf|eot|woff2?/i.test(key)) { - key = key.replace(/.*\//, ''); - } - return contentType ? `[${contentType}]${key}` : key; -} -async function resourceToDataURL(resourceUrl, contentType, options) { - const cacheKey = getCacheKey(resourceUrl, contentType, options.includeQueryParams); - if (cache[cacheKey] != null) { - return cache[cacheKey]; - } - // ref: https://developer.mozilla.org/en/docs/Web/API/XMLHttpRequest/Using_XMLHttpRequest#Bypassing_the_cache - if (options.cacheBust) { - // eslint-disable-next-line no-param-reassign - resourceUrl += (/\?/.test(resourceUrl) ? '&' : '?') + new Date().getTime(); - } - let dataURL; - try { - const content = await fetchAsDataURL(resourceUrl, options.fetchRequestInit, ({ res, result }) => { - if (!contentType) { - // eslint-disable-next-line no-param-reassign - contentType = res.headers.get('Content-Type') || ''; - } - return getContentFromDataUrl(result); - }); - dataURL = makeDataUrl(content, contentType); - } - catch (error) { - dataURL = options.imagePlaceholder || ''; - let msg = `Failed to fetch resource: ${resourceUrl}`; - if (error) { - msg = typeof error === 'string' ? error : error.message; - } - if (msg) { - console.warn(msg); - } - } - cache[cacheKey] = dataURL; - return dataURL; -} -//# sourceMappingURL=dataurl.js.map - -/***/ }), - -/***/ "./node_modules/html-to-image/es/embed-images.js": -/*!*******************************************************!*\ - !*** ./node_modules/html-to-image/es/embed-images.js ***! - \*******************************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ embedImages: () => (/* binding */ embedImages) -/* harmony export */ }); -/* harmony import */ var _embed_resources__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./embed-resources */ "./node_modules/html-to-image/es/embed-resources.js"); -/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./util */ "./node_modules/html-to-image/es/util.js"); -/* harmony import */ var _dataurl__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./dataurl */ "./node_modules/html-to-image/es/dataurl.js"); -/* harmony import */ var _mimes__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./mimes */ "./node_modules/html-to-image/es/mimes.js"); - - - - -async function embedProp(propName, node, options) { - var _a; - const propValue = (_a = node.style) === null || _a === void 0 ? void 0 : _a.getPropertyValue(propName); - if (propValue) { - const cssString = await (0,_embed_resources__WEBPACK_IMPORTED_MODULE_0__.embedResources)(propValue, null, options); - node.style.setProperty(propName, cssString, node.style.getPropertyPriority(propName)); - return true; - } - return false; -} -async function embedBackground(clonedNode, options) { - if (!(await embedProp('background', clonedNode, options))) { - await embedProp('background-image', clonedNode, options); - } - if (!(await embedProp('mask', clonedNode, options))) { - await embedProp('mask-image', clonedNode, options); - } -} -async function embedImageNode(clonedNode, options) { - const isImageElement = (0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(clonedNode, HTMLImageElement); - if (!(isImageElement && !(0,_dataurl__WEBPACK_IMPORTED_MODULE_2__.isDataUrl)(clonedNode.src)) && - !((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(clonedNode, SVGImageElement) && - !(0,_dataurl__WEBPACK_IMPORTED_MODULE_2__.isDataUrl)(clonedNode.href.baseVal))) { - return; - } - const url = isImageElement ? clonedNode.src : clonedNode.href.baseVal; - const dataURL = await (0,_dataurl__WEBPACK_IMPORTED_MODULE_2__.resourceToDataURL)(url, (0,_mimes__WEBPACK_IMPORTED_MODULE_3__.getMimeType)(url), options); - await new Promise((resolve, reject) => { - clonedNode.onload = resolve; - clonedNode.onerror = reject; - const image = clonedNode; - if (image.decode) { - image.decode = resolve; - } - if (image.loading === 'lazy') { - image.loading = 'eager'; - } - if (isImageElement) { - clonedNode.srcset = ''; - clonedNode.src = dataURL; - } - else { - clonedNode.href.baseVal = dataURL; - } - }); -} -async function embedChildren(clonedNode, options) { - const children = (0,_util__WEBPACK_IMPORTED_MODULE_1__.toArray)(clonedNode.childNodes); - const deferreds = children.map((child) => embedImages(child, options)); - await Promise.all(deferreds).then(() => clonedNode); -} -async function embedImages(clonedNode, options) { - if ((0,_util__WEBPACK_IMPORTED_MODULE_1__.isInstanceOfElement)(clonedNode, Element)) { - await embedBackground(clonedNode, options); - await embedImageNode(clonedNode, options); - await embedChildren(clonedNode, options); - } -} -//# sourceMappingURL=embed-images.js.map - -/***/ }), - -/***/ "./node_modules/html-to-image/es/embed-resources.js": -/*!**********************************************************!*\ - !*** ./node_modules/html-to-image/es/embed-resources.js ***! - \**********************************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ embed: () => (/* binding */ embed), -/* harmony export */ embedResources: () => (/* binding */ embedResources), -/* harmony export */ parseURLs: () => (/* binding */ parseURLs), -/* harmony export */ shouldEmbed: () => (/* binding */ shouldEmbed) -/* harmony export */ }); -/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./util */ "./node_modules/html-to-image/es/util.js"); -/* harmony import */ var _mimes__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./mimes */ "./node_modules/html-to-image/es/mimes.js"); -/* harmony import */ var _dataurl__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./dataurl */ "./node_modules/html-to-image/es/dataurl.js"); - - - -const URL_REGEX = /url\((['"]?)([^'"]+?)\1\)/g; -const URL_WITH_FORMAT_REGEX = /url\([^)]+\)\s*format\((["']?)([^"']+)\1\)/g; -const FONT_SRC_REGEX = /src:\s*(?:url\([^)]+\)\s*format\([^)]+\)[,;]\s*)+/g; -function toRegex(url) { - // eslint-disable-next-line no-useless-escape - const escaped = url.replace(/([.*+?^${}()|\[\]\/\\])/g, '\\$1'); - return new RegExp(`(url\\(['"]?)(${escaped})(['"]?\\))`, 'g'); -} -function parseURLs(cssText) { - const urls = []; - cssText.replace(URL_REGEX, (raw, quotation, url) => { - urls.push(url); - return raw; - }); - return urls.filter((url) => !(0,_dataurl__WEBPACK_IMPORTED_MODULE_2__.isDataUrl)(url)); -} -async function embed(cssText, resourceURL, baseURL, options, getContentFromUrl) { - try { - const resolvedURL = baseURL ? (0,_util__WEBPACK_IMPORTED_MODULE_0__.resolveUrl)(resourceURL, baseURL) : resourceURL; - const contentType = (0,_mimes__WEBPACK_IMPORTED_MODULE_1__.getMimeType)(resourceURL); - let dataURL; - if (getContentFromUrl) { - const content = await getContentFromUrl(resolvedURL); - dataURL = (0,_dataurl__WEBPACK_IMPORTED_MODULE_2__.makeDataUrl)(content, contentType); - } - else { - dataURL = await (0,_dataurl__WEBPACK_IMPORTED_MODULE_2__.resourceToDataURL)(resolvedURL, contentType, options); - } - return cssText.replace(toRegex(resourceURL), `$1${dataURL}$3`); - } - catch (error) { - // pass - } - return cssText; -} -function filterPreferredFontFormat(str, { preferredFontFormat }) { - return !preferredFontFormat - ? str - : str.replace(FONT_SRC_REGEX, (match) => { - // eslint-disable-next-line no-constant-condition - while (true) { - const [src, , format] = URL_WITH_FORMAT_REGEX.exec(match) || []; - if (!format) { - return ''; - } - if (format === preferredFontFormat) { - return `src: ${src};`; - } - } - }); -} -function shouldEmbed(url) { - return url.search(URL_REGEX) !== -1; -} -async function embedResources(cssText, baseUrl, options) { - if (!shouldEmbed(cssText)) { - return cssText; - } - const filteredCSSText = filterPreferredFontFormat(cssText, options); - const urls = parseURLs(filteredCSSText); - return urls.reduce((deferred, url) => deferred.then((css) => embed(css, url, baseUrl, options)), Promise.resolve(filteredCSSText)); -} -//# sourceMappingURL=embed-resources.js.map - -/***/ }), - -/***/ "./node_modules/html-to-image/es/embed-webfonts.js": -/*!*********************************************************!*\ - !*** ./node_modules/html-to-image/es/embed-webfonts.js ***! - \*********************************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ embedWebFonts: () => (/* binding */ embedWebFonts), -/* harmony export */ getWebFontCSS: () => (/* binding */ getWebFontCSS) -/* harmony export */ }); -/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./util */ "./node_modules/html-to-image/es/util.js"); -/* harmony import */ var _dataurl__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./dataurl */ "./node_modules/html-to-image/es/dataurl.js"); -/* harmony import */ var _embed_resources__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./embed-resources */ "./node_modules/html-to-image/es/embed-resources.js"); - - - -const cssFetchCache = {}; -async function fetchCSS(url) { - let cache = cssFetchCache[url]; - if (cache != null) { - return cache; - } - const res = await fetch(url); - const cssText = await res.text(); - cache = { url, cssText }; - cssFetchCache[url] = cache; - return cache; -} -async function embedFonts(data, options) { - let cssText = data.cssText; - const regexUrl = /url\(["']?([^"')]+)["']?\)/g; - const fontLocs = cssText.match(/url\([^)]+\)/g) || []; - const loadFonts = fontLocs.map(async (loc) => { - let url = loc.replace(regexUrl, '$1'); - if (!url.startsWith('https://')) { - url = new URL(url, data.url).href; - } - return (0,_dataurl__WEBPACK_IMPORTED_MODULE_1__.fetchAsDataURL)(url, options.fetchRequestInit, ({ result }) => { - cssText = cssText.replace(loc, `url(${result})`); - return [loc, result]; - }); - }); - return Promise.all(loadFonts).then(() => cssText); -} -function parseCSS(source) { - if (source == null) { - return []; - } - const result = []; - const commentsRegex = /(\/\*[\s\S]*?\*\/)/gi; - // strip out comments - let cssText = source.replace(commentsRegex, ''); - // eslint-disable-next-line prefer-regex-literals - const keyframesRegex = new RegExp('((@.*?keyframes [\\s\\S]*?){([\\s\\S]*?}\\s*?)})', 'gi'); - // eslint-disable-next-line no-constant-condition - while (true) { - const matches = keyframesRegex.exec(cssText); - if (matches === null) { - break; - } - result.push(matches[0]); - } - cssText = cssText.replace(keyframesRegex, ''); - const importRegex = /@import[\s\S]*?url\([^)]*\)[\s\S]*?;/gi; - // to match css & media queries together - const combinedCSSRegex = '((\\s*?(?:\\/\\*[\\s\\S]*?\\*\\/)?\\s*?@media[\\s\\S]' + - '*?){([\\s\\S]*?)}\\s*?})|(([\\s\\S]*?){([\\s\\S]*?)})'; - // unified regex - const unifiedRegex = new RegExp(combinedCSSRegex, 'gi'); - // eslint-disable-next-line no-constant-condition - while (true) { - let matches = importRegex.exec(cssText); - if (matches === null) { - matches = unifiedRegex.exec(cssText); - if (matches === null) { - break; - } - else { - importRegex.lastIndex = unifiedRegex.lastIndex; - } - } - else { - unifiedRegex.lastIndex = importRegex.lastIndex; - } - result.push(matches[0]); - } - return result; -} -async function getCSSRules(styleSheets, options) { - const ret = []; - const deferreds = []; - // First loop inlines imports - styleSheets.forEach((sheet) => { - if ('cssRules' in sheet) { - try { - (0,_util__WEBPACK_IMPORTED_MODULE_0__.toArray)(sheet.cssRules || []).forEach((item, index) => { - if (item.type === CSSRule.IMPORT_RULE) { - let importIndex = index + 1; - const url = item.href; - const deferred = fetchCSS(url) - .then((metadata) => embedFonts(metadata, options)) - .then((cssText) => parseCSS(cssText).forEach((rule) => { - try { - sheet.insertRule(rule, rule.startsWith('@import') - ? (importIndex += 1) - : sheet.cssRules.length); - } - catch (error) { - console.error('Error inserting rule from remote css', { - rule, - error, - }); - } - })) - .catch((e) => { - console.error('Error loading remote css', e.toString()); - }); - deferreds.push(deferred); - } - }); - } - catch (e) { - const inline = styleSheets.find((a) => a.href == null) || document.styleSheets[0]; - if (sheet.href != null) { - deferreds.push(fetchCSS(sheet.href) - .then((metadata) => embedFonts(metadata, options)) - .then((cssText) => parseCSS(cssText).forEach((rule) => { - inline.insertRule(rule, sheet.cssRules.length); - })) - .catch((err) => { - console.error('Error loading remote stylesheet', err); - })); - } - console.error('Error inlining remote css file', e); - } - } - }); - return Promise.all(deferreds).then(() => { - // Second loop parses rules - styleSheets.forEach((sheet) => { - if ('cssRules' in sheet) { - try { - (0,_util__WEBPACK_IMPORTED_MODULE_0__.toArray)(sheet.cssRules || []).forEach((item) => { - ret.push(item); - }); - } - catch (e) { - console.error(`Error while reading CSS rules from ${sheet.href}`, e); - } - } - }); - return ret; - }); -} -function getWebFontRules(cssRules) { - return cssRules - .filter((rule) => rule.type === CSSRule.FONT_FACE_RULE) - .filter((rule) => (0,_embed_resources__WEBPACK_IMPORTED_MODULE_2__.shouldEmbed)(rule.style.getPropertyValue('src'))); -} -async function parseWebFontRules(node, options) { - if (node.ownerDocument == null) { - throw new Error('Provided element is not within a Document'); - } - const styleSheets = (0,_util__WEBPACK_IMPORTED_MODULE_0__.toArray)(node.ownerDocument.styleSheets); - const cssRules = await getCSSRules(styleSheets, options); - return getWebFontRules(cssRules); -} -async function getWebFontCSS(node, options) { - const rules = await parseWebFontRules(node, options); - const cssTexts = await Promise.all(rules.map((rule) => { - const baseUrl = rule.parentStyleSheet ? rule.parentStyleSheet.href : null; - return (0,_embed_resources__WEBPACK_IMPORTED_MODULE_2__.embedResources)(rule.cssText, baseUrl, options); - })); - return cssTexts.join('\n'); -} -async function embedWebFonts(clonedNode, options) { - const cssText = options.fontEmbedCSS != null - ? options.fontEmbedCSS - : options.skipFonts - ? null - : await getWebFontCSS(clonedNode, options); - if (cssText) { - const styleNode = document.createElement('style'); - const sytleContent = document.createTextNode(cssText); - styleNode.appendChild(sytleContent); - if (clonedNode.firstChild) { - clonedNode.insertBefore(styleNode, clonedNode.firstChild); - } - else { - clonedNode.appendChild(styleNode); - } - } -} -//# sourceMappingURL=embed-webfonts.js.map - -/***/ }), - -/***/ "./node_modules/html-to-image/es/index.js": -/*!************************************************!*\ - !*** ./node_modules/html-to-image/es/index.js ***! - \************************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ getFontEmbedCSS: () => (/* binding */ getFontEmbedCSS), -/* harmony export */ toBlob: () => (/* binding */ toBlob), -/* harmony export */ toCanvas: () => (/* binding */ toCanvas), -/* harmony export */ toJpeg: () => (/* binding */ toJpeg), -/* harmony export */ toPixelData: () => (/* binding */ toPixelData), -/* harmony export */ toPng: () => (/* binding */ toPng), -/* harmony export */ toSvg: () => (/* binding */ toSvg) -/* harmony export */ }); -/* harmony import */ var _clone_node__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./clone-node */ "./node_modules/html-to-image/es/clone-node.js"); -/* harmony import */ var _embed_images__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./embed-images */ "./node_modules/html-to-image/es/embed-images.js"); -/* harmony import */ var _apply_style__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./apply-style */ "./node_modules/html-to-image/es/apply-style.js"); -/* harmony import */ var _embed_webfonts__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./embed-webfonts */ "./node_modules/html-to-image/es/embed-webfonts.js"); -/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./util */ "./node_modules/html-to-image/es/util.js"); - - - - - -async function toSvg(node, options = {}) { - const { width, height } = (0,_util__WEBPACK_IMPORTED_MODULE_4__.getImageSize)(node, options); - const clonedNode = (await (0,_clone_node__WEBPACK_IMPORTED_MODULE_0__.cloneNode)(node, options, true)); - await (0,_embed_webfonts__WEBPACK_IMPORTED_MODULE_3__.embedWebFonts)(clonedNode, options); - await (0,_embed_images__WEBPACK_IMPORTED_MODULE_1__.embedImages)(clonedNode, options); - (0,_apply_style__WEBPACK_IMPORTED_MODULE_2__.applyStyle)(clonedNode, options); - const datauri = await (0,_util__WEBPACK_IMPORTED_MODULE_4__.nodeToDataURL)(clonedNode, width, height); - return datauri; -} -async function toCanvas(node, options = {}) { - const { width, height } = (0,_util__WEBPACK_IMPORTED_MODULE_4__.getImageSize)(node, options); - const svg = await toSvg(node, options); - const img = await (0,_util__WEBPACK_IMPORTED_MODULE_4__.createImage)(svg); - const canvas = document.createElement('canvas'); - const context = canvas.getContext('2d'); - const ratio = options.pixelRatio || (0,_util__WEBPACK_IMPORTED_MODULE_4__.getPixelRatio)(); - const canvasWidth = options.canvasWidth || width; - const canvasHeight = options.canvasHeight || height; - canvas.width = canvasWidth * ratio; - canvas.height = canvasHeight * ratio; - if (!options.skipAutoScale) { - (0,_util__WEBPACK_IMPORTED_MODULE_4__.checkCanvasDimensions)(canvas); - } - canvas.style.width = `${canvasWidth}`; - canvas.style.height = `${canvasHeight}`; - if (options.backgroundColor) { - context.fillStyle = options.backgroundColor; - context.fillRect(0, 0, canvas.width, canvas.height); - } - context.drawImage(img, 0, 0, canvas.width, canvas.height); - return canvas; -} -async function toPixelData(node, options = {}) { - const { width, height } = (0,_util__WEBPACK_IMPORTED_MODULE_4__.getImageSize)(node, options); - const canvas = await toCanvas(node, options); - const ctx = canvas.getContext('2d'); - return ctx.getImageData(0, 0, width, height).data; -} -async function toPng(node, options = {}) { - const canvas = await toCanvas(node, options); - return canvas.toDataURL(); -} -async function toJpeg(node, options = {}) { - const canvas = await toCanvas(node, options); - return canvas.toDataURL('image/jpeg', options.quality || 1); -} -async function toBlob(node, options = {}) { - const canvas = await toCanvas(node, options); - const blob = await (0,_util__WEBPACK_IMPORTED_MODULE_4__.canvasToBlob)(canvas); - return blob; -} -async function getFontEmbedCSS(node, options = {}) { - return (0,_embed_webfonts__WEBPACK_IMPORTED_MODULE_3__.getWebFontCSS)(node, options); -} -//# sourceMappingURL=index.js.map - -/***/ }), - -/***/ "./node_modules/html-to-image/es/mimes.js": -/*!************************************************!*\ - !*** ./node_modules/html-to-image/es/mimes.js ***! - \************************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ getMimeType: () => (/* binding */ getMimeType) -/* harmony export */ }); -const WOFF = 'application/font-woff'; -const JPEG = 'image/jpeg'; -const mimes = { - woff: WOFF, - woff2: WOFF, - ttf: 'application/font-truetype', - eot: 'application/vnd.ms-fontobject', - png: 'image/png', - jpg: JPEG, - jpeg: JPEG, - gif: 'image/gif', - tiff: 'image/tiff', - svg: 'image/svg+xml', - webp: 'image/webp', -}; -function getExtension(url) { - const match = /\.([^./]*?)$/g.exec(url); - return match ? match[1] : ''; -} -function getMimeType(url) { - const extension = getExtension(url).toLowerCase(); - return mimes[extension] || ''; -} -//# sourceMappingURL=mimes.js.map - -/***/ }), - -/***/ "./node_modules/html-to-image/es/util.js": -/*!***********************************************!*\ - !*** ./node_modules/html-to-image/es/util.js ***! - \***********************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ canvasToBlob: () => (/* binding */ canvasToBlob), -/* harmony export */ checkCanvasDimensions: () => (/* binding */ checkCanvasDimensions), -/* harmony export */ createImage: () => (/* binding */ createImage), -/* harmony export */ delay: () => (/* binding */ delay), -/* harmony export */ getImageSize: () => (/* binding */ getImageSize), -/* harmony export */ getPixelRatio: () => (/* binding */ getPixelRatio), -/* harmony export */ isInstanceOfElement: () => (/* binding */ isInstanceOfElement), -/* harmony export */ nodeToDataURL: () => (/* binding */ nodeToDataURL), -/* harmony export */ resolveUrl: () => (/* binding */ resolveUrl), -/* harmony export */ svgToDataURL: () => (/* binding */ svgToDataURL), -/* harmony export */ toArray: () => (/* binding */ toArray), -/* harmony export */ uuid: () => (/* binding */ uuid) -/* harmony export */ }); -function resolveUrl(url, baseUrl) { - // url is absolute already - if (url.match(/^[a-z]+:\/\//i)) { - return url; - } - // url is absolute already, without protocol - if (url.match(/^\/\//)) { - return window.location.protocol + url; - } - // dataURI, mailto:, tel:, etc. - if (url.match(/^[a-z]+:/i)) { - return url; - } - const doc = document.implementation.createHTMLDocument(); - const base = doc.createElement('base'); - const a = doc.createElement('a'); - doc.head.appendChild(base); - doc.body.appendChild(a); - if (baseUrl) { - base.href = baseUrl; - } - a.href = url; - return a.href; -} -const uuid = (() => { - // generate uuid for className of pseudo elements. - // We should not use GUIDs, otherwise pseudo elements sometimes cannot be captured. - let counter = 0; - // ref: http://stackoverflow.com/a/6248722/2519373 - const random = () => - // eslint-disable-next-line no-bitwise - `0000${((Math.random() * 36 ** 4) << 0).toString(36)}`.slice(-4); - return () => { - counter += 1; - return `u${random()}${counter}`; - }; -})(); -function delay(ms) { - return (args) => new Promise((resolve) => { - setTimeout(() => resolve(args), ms); - }); -} -function toArray(arrayLike) { - const arr = []; - for (let i = 0, l = arrayLike.length; i < l; i++) { - arr.push(arrayLike[i]); - } - return arr; -} -function px(node, styleProperty) { - const win = node.ownerDocument.defaultView || window; - const val = win.getComputedStyle(node).getPropertyValue(styleProperty); - return val ? parseFloat(val.replace('px', '')) : 0; -} -function getNodeWidth(node) { - const leftBorder = px(node, 'border-left-width'); - const rightBorder = px(node, 'border-right-width'); - return node.clientWidth + leftBorder + rightBorder; -} -function getNodeHeight(node) { - const topBorder = px(node, 'border-top-width'); - const bottomBorder = px(node, 'border-bottom-width'); - return node.clientHeight + topBorder + bottomBorder; -} -function getImageSize(targetNode, options = {}) { - const width = options.width || getNodeWidth(targetNode); - const height = options.height || getNodeHeight(targetNode); - return { width, height }; -} -function getPixelRatio() { - let ratio; - let FINAL_PROCESS; - try { - FINAL_PROCESS = process; - } - catch (e) { - // pass - } - const val = FINAL_PROCESS && FINAL_PROCESS.env - ? FINAL_PROCESS.env.devicePixelRatio - : null; - if (val) { - ratio = parseInt(val, 10); - if (Number.isNaN(ratio)) { - ratio = 1; - } - } - return ratio || window.devicePixelRatio || 1; -} -// @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/canvas#maximum_canvas_size -const canvasDimensionLimit = 16384; -function checkCanvasDimensions(canvas) { - if (canvas.width > canvasDimensionLimit || - canvas.height > canvasDimensionLimit) { - if (canvas.width > canvasDimensionLimit && - canvas.height > canvasDimensionLimit) { - if (canvas.width > canvas.height) { - canvas.height *= canvasDimensionLimit / canvas.width; - canvas.width = canvasDimensionLimit; - } - else { - canvas.width *= canvasDimensionLimit / canvas.height; - canvas.height = canvasDimensionLimit; - } - } - else if (canvas.width > canvasDimensionLimit) { - canvas.height *= canvasDimensionLimit / canvas.width; - canvas.width = canvasDimensionLimit; - } - else { - canvas.width *= canvasDimensionLimit / canvas.height; - canvas.height = canvasDimensionLimit; - } - } -} -function canvasToBlob(canvas, options = {}) { - if (canvas.toBlob) { - return new Promise((resolve) => { - canvas.toBlob(resolve, options.type ? options.type : 'image/png', options.quality ? options.quality : 1); - }); - } - return new Promise((resolve) => { - const binaryString = window.atob(canvas - .toDataURL(options.type ? options.type : undefined, options.quality ? options.quality : undefined) - .split(',')[1]); - const len = binaryString.length; - const binaryArray = new Uint8Array(len); - for (let i = 0; i < len; i += 1) { - binaryArray[i] = binaryString.charCodeAt(i); - } - resolve(new Blob([binaryArray], { - type: options.type ? options.type : 'image/png', - })); - }); -} -function createImage(url) { - return new Promise((resolve, reject) => { - const img = new Image(); - img.decode = () => resolve(img); - img.onload = () => resolve(img); - img.onerror = reject; - img.crossOrigin = 'anonymous'; - img.decoding = 'async'; - img.src = url; - }); -} -async function svgToDataURL(svg) { - return Promise.resolve() - .then(() => new XMLSerializer().serializeToString(svg)) - .then(encodeURIComponent) - .then((html) => `data:image/svg+xml;charset=utf-8,${html}`); -} -async function nodeToDataURL(node, width, height) { - const xmlns = 'http://www.w3.org/2000/svg'; - const svg = document.createElementNS(xmlns, 'svg'); - const foreignObject = document.createElementNS(xmlns, 'foreignObject'); - svg.setAttribute('width', `${width}`); - svg.setAttribute('height', `${height}`); - svg.setAttribute('viewBox', `0 0 ${width} ${height}`); - foreignObject.setAttribute('width', '100%'); - foreignObject.setAttribute('height', '100%'); - foreignObject.setAttribute('x', '0'); - foreignObject.setAttribute('y', '0'); - foreignObject.setAttribute('externalResourcesRequired', 'true'); - svg.appendChild(foreignObject); - foreignObject.appendChild(node); - return svgToDataURL(svg); -} -const isInstanceOfElement = (node, instance) => { - if (node instanceof instance) - return true; - const nodePrototype = Object.getPrototypeOf(node); - if (nodePrototype === null) - return false; - return (nodePrototype.constructor.name === instance.name || - isInstanceOfElement(nodePrototype, instance)); -}; -//# sourceMappingURL=util.js.map - -/***/ }), - /***/ "./node_modules/immer/dist/cjs/immer.cjs.development.js": /*!**************************************************************!*\ !*** ./node_modules/immer/dist/cjs/immer.cjs.development.js ***! diff --git a/assets/js/workflowEditor.min.js b/assets/js/workflowEditor.min.js index ee52db43e..1c1c3bed5 100644 --- a/assets/js/workflowEditor.min.js +++ b/assets/js/workflowEditor.min.js @@ -1,2 +1,2 @@ /*! For license information please see workflowEditor.min.js.LICENSE.txt */ -(()=>{var e,t,n,r,o={3018:(e,t,n)=>{"use strict";n.d(t,{Ml:()=>i,qj:()=>r,rx:()=>a,wD:()=>o});var r="RIGHT",o="DOWN",a=o,i="publishpress_future_workflow_editor_auto_layout"},2158:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,'.block-editor-block-types-list > [role="presentation"] {\n\toverflow: hidden;\n\tdisplay: flex;\n\tflex-wrap: wrap;\n}\n',""]);const l=i},217:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".edit-post-sidebar__panel .condition-natural-language {\n margin-top: 12px;\n font-family: monospace, monospace;\n background-color: #f0f0f1;\n padding: 12px;\n border-radius: 4px;\n border: 1px solid #e0e0e1;\n}\n\n.condition-pro-features-notice {\n font-style: italic;\n margin-top: 12px;\n}\n\n.ruleGroup {\n margin: none;\n background: none;\n border: none;\n}\n\n.block-editor-inspector-popover-header__heading {\n font-size: 13px !important;\n margin-bottom: 16px !important;\n}\n",""]);const l=i},6943:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".components-button svg {\n height: 100%;\n}\n\n#wpfooter {\n display: none !important;\n}\n\n.react-flow {\n width: 100% !important;\n}\n\n.components-menu-items__item-icon.has-icon-right {\n width: 24px !important;\n height: 24px !important;\n}\n\n.react-flow__node-default.selectable.selected,\n.react-flow__node-default.selectable:focus,\n.react-flow__node-default.selectable:focus-visible,\n.react-flow__node-input.selectable.selected,\n.react-flow__node-input.selectable:focus,\n.react-flow__node-input.selectable:focus-visible,\n.react-flow__node-output.selectable.selected,\n.react-flow__node-output.selectable:focus,\n.react-flow__node-output.selectable:focus-visible,\n.react-flow__node-group.selectable.selected,\n.react-flow__node-group.selectable:focus,\n.react-flow__node-group.selectable:focus-visible {\n box-shadow: 0 0 0 2px #1a192b;\n}\n\n/* .react-flow {\n background-color: #e1e1e1 !important;\n} */\n\n.settings-field-description {\n font-size: 12px;\n color: #666;\n margin-bottom: 15px;\n}\n\n.settings-field-help-popover {\n font-size: 12px;\n color: #666;\n width: 320px;\n padding: 16px;\n position: relative;\n padding-top: 50px;\n}\n\n.settings-field-help-popover button {\n position: absolute;\n top: 10px;\n right: 10px;\n}\n\n.workflow-editor-inspector-card__handles-schema {\n display: flex;\n flex-direction: column;\n flex-wrap: nowrap;\n justify-content: flex-start;\n align-items: flex-start;\n}\n\n.workflow-editor-inspector-card__handles-schema code {\n padding: 3px 6px;\n border-radius: 4px;\n font-size: 12px;\n background: #ebebeb;\n color: #696969;\n}\n\n.workflow-editor-inspector-card__handles-schema h3 {\n margin-bottom: 4px !important;\n}\n\n.workflow-editor-global-variables-description {\n font-size: 12px;\n color: #666;\n margin-bottom: 15px;\n}\n\n.workflow-editor-global-variables-label {\n font-size: 11px;\n font-weight: 500;\n line-height: 1.4;\n text-transform: uppercase;\n display: inline-block;\n margin-bottom: calc(8px);\n padding: 0px;\n}\n.workflow-editor-global-var-list {\n margin: 0;\n padding: 5px;\n border: 1px solid var(--wp-components-color-gray-600, #949494);\n}\n\n.workflow-editor-global-var-list ul {\n list-style: disc;\n margin-left: 30px;\n}\n\n.workflow-editor-global-var-list ul li {\n margin-bottom: 0;\n}\n\n.edit-post-editor__inserter-panel-content {\n height: 100%;\n}\n\n.block-editor-inserter__content {\n display: flex;\n flex-direction: column;\n gap: 16px;\n height: 100%;\n overflow-y: hidden;\n position: relative;\n}\n\n.block-editor-inserter__panel-content {\n overflow-y: auto;\n}\n\n.interface-interface-skeleton__footer {\n min-height: 25px;\n padding: 3px 20px;\n box-sizing: border-box;\n}\n\n.interface-interface-skeleton__secondary-sidebar {\n box-shadow: 1px 1px 0 0 rgba(0, 0, 0, .133);\n outline: 1px solid #0000;\n}\n\n.editor-inserter-sidebar *, .editor-inserter-sidebar :after, .editor-inserter-sidebar :before {\n box-sizing: inherit;\n}\n",""]);const l=i},8565:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".workflow-editor-dev-info-panel .components-panel__row {\n overflow: scroll;\n}\n\n.workflow-editor-dev-info-wrapper {\n min-width: 1000px;\n}\n\n.workflow-editor-dev-panel {\n background-color: #fffaf1;\n}\n",""]);const l=i},7860:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".components-guide__container {\n max-width: 312px;\n}\n",""]);const l=i},7448:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".edit-post-editor__inserter-panel-header {\n display: flex;\n\tjustify-content: flex-end;\n}\n\n@media (min-width: 782px) {\n .editor-inserter-sidebar__header {\n display: none;\n }\n}\n\n.edit-post-header-toolbar .editor-document-tools__left > .edit-post-header-toolbar__inserter-toggle.is-pressed svg {\n transform: rotate(45deg);\n}\n\n",""]);const l=i},4259:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".edit-post-post-status .components-base-control {\n flex: auto;\n}\n\n.editor-post-title__panel,\n.editor-post-description__panel {\n padding-top: 8px;\n}\n\n.editor-post-status__panel {\n margin-top: 16px;\n gap: 16px !important;\n}\n\n.editor-post-status__panel button {\n flex-grow: 1;\n justify-content: center;\n}\n\n.workflow-editor-element-inspector__warning {\n background: #fff;\n display: block;\n font-size: 13px;\n padding: 32px 36px;\n text-align: center;\n flex-grow: 1;\n justify-content: center;\n}\n\n\n.workflow-editor-inspector-card {\n align-items: flex-start;\n color: #1e1e1e;\n display: flex;\n padding: 16px;\n}\n\n.workflow-editor-inspector-card {\n align-items: flex-start;\n color: #1e1e1e;\n display: flex;\n padding: 16px;\n}\n\n.workflow-editor-inspector-icon {\n align-items: center;\n display: flex;\n height: 24px;\n justify-content: center;\n width: 24px;\n}\n\n.workflow-editor-inspector-card .workflow-editor-inspector-icon {\n flex: 0 0 24px;\n height: 24px;\n margin-left: 0;\n margin-right: 12px;\n width: 24px;\n}\n\n.workflow-editor-inspector-card {\n align-items: flex-start;\n color: #1e1e1e;\n display: flex;\n padding: 16px;\n}\n\n.workflow-editor-inspector-card__content {\n flex-grow: 1;\n}\n\n.workflow-editor-inspector-inspector h2, .workflow-editor-inspector-inspector h3 {\n color: #1e1e1e;\n font-size: 13px;\n margin-bottom: 1.5em;\n}\n\n.interface-complementary-area h2 {\n color: #1e1e1e;\n font-size: 13px;\n margin-bottom: 1.5em;\n}\n\n.workflow-editor-inspector-card__title.workflow-editor-inspector-card__title {\n font-size: 13px;\n line-height: 1.4;\n margin: 0;\n padding: 3px 0;\n}\n\n\n.workflow-editor-inspector-card__description {\n display: block;\n font-size: 13px;\n line-height: 1.4;\n margin-top: 4px;\n}\n\n.workflow-editor-inspector-icon.has-colors svg {\n fill: currentColor;\n}\n\n.workflow-editor-inspector-icon svg {\n max-height: 24px;\n max-width: 24px;\n min-height: 20px;\n min-width: 20px;\n}\n\n.workflow-editor-validation-notification {\n display: flex;\n flex-direction: row;\n align-items: flex-start;\n justify-content: flex-start;\n}\n\n.workflow-editor-validation-panel .node-icon {\n margin-right: 5px;\n}\n\n.workflow-editor-validation-notification.workflow-editor-success .node-icon * {\n color: #46b450;\n}\n\n.workflow-editor-validation-notification.workflow-editor-error .node-icon * {\n color: #d90f0f;\n}\n\n.edit-post-sidebar__panel .components-h-stack {\n width: 100%;\n}\n\n.workflow-editor-inspector-card__content table {\n width: 100%;\n border-collapse: collapse;\n border-spacing: 0;\n margin-top: 20px;\n}\n\n.workflow-editor-inspector-card__content table th,\n.workflow-editor-inspector-card__content table td {\n padding: 2px 3px;\n border: 1px solid #e1e1e1;\n text-align: left;\n}\n\n.workflow-editor-data-flow-variable ul {\n margin-left: 40px;\n margin-top: 6px;\n margin-bottom: 11px;\n padding: 2px;\n}\n\n.workflow-editor-data-flow-variable ul li {\n margin-bottom: 2px;\n list-style: disc;\n line-height: 16px;\n}\n\n.workflow-editor-data-flow-variable ul code {\n max-width: 204px;\n display: inline-block;\n overflow: auto;\n text-wrap: wrap;\n}\n",""]);const l=i},1578:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".react-flow__node {\n max-width: 170px;\n}\n\n.react-flow__node-body {\n border-radius: 8px;\n color: #171717;\n font-size: 10px;\n min-width: 140px;\n box-sizing: border-box;\n border: 1px solid transparent;\n cursor: pointer;\n}\n\n.react-flow__node-inner-body {\n padding: 6px;\n box-sizing: border-box;\n}\n\n.react-flow__node-header {\n text-align: center;\n width: 100%;\n position: relative;\n text-align: left;\n}\n\n.react-flow__node-header .react-flow__node-label {\n margin-left: 22px;\n}\n\n.react-flow__node-header .dashicon {\n margin-right: 4px;\n position: absolute;\n left: 2px;\n top: 2px;\n}\n\n.react-flow__node-header .node-icon {\n margin-right: 4px;\n position: absolute;\n top: 1px;\n left: 2px;\n}\n\n.react-flow__node-slug {\n font-size: 8px;\n display: inline-block;\n height: 6px;\n line-height: 6px;\n padding: 2px;\n position: absolute;\n top: 45px;\n left: 27px;\n}\n\n.react-flow__handle {\n width: 8px !important;\n height: 8px !important;\n box-sizing: border-box;\n}\n\n.react-flow__handle.react-flow__handle-bottom {\n bottom: -4px !important;\n}\n\n.react-flow__handle.react-flow__handle-top {\n top: -4px !important;\n}\n\n.react-flow__node-top {\n font-size: 8px;\n padding: 0 8px;\n border-top-left-radius: 8px;\n border-top-right-radius: 8px;\n border-bottom: 1px solid silver;\n position: relative;\n padding-left: 18px;\n}\n\n.react-flow__node-top .publishpress-icon {\n margin-right: 4px;\n position: absolute;\n top: 1px;\n left: 8px;\n}\n\n/* PLACEHOLDER FOR EMPTY FLOW */\n.react-flow__node-triggerPlaceholderNode {\n background-color: #fff;\n border: 1px dashed #d2d2d2;\n cursor: pointer;\n}\n\n.react-flow__node-triggerPlaceholderNode .react-flow__node-header {\n display: flex;\n align-items: center;\n}\n\n.react-flow__node-triggerPlaceholderNode .react-flow__node-header .icon {\n color: #fff;\n background-color: #d2d2d2;\n padding: 2px;\n display: inline-block;\n width: 12px;\n height: 12px;\n box-sizing: border-box;\n position: relative;\n border-radius: 1px;\n margin-right: 6px;\n}\n\n.react-flow__node-triggerPlaceholderNode .react-flow__node-header .icon svg {\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n width: 12px;\n height: 12px;\n}\n\n.react-flow__node-triggerPlaceholderNode .react-flow__node-header .react-flow__node-label {\n color: #d2d2d2\n}\n\n.react-flow__node-triggerPlaceholderNode .react-flow__node-header {\n padding-left: 0;\n}\n\n.react-flow__node-triggerPlaceholderNode:hover {\n border: 1px dashed #aeaeae;\n}\n\n.react-flow__node-triggerPlaceholderNode:hover .react-flow__node-header .icon {\n background-color: #aeaeae;\n}\n\n.react-flow__node-triggerPlaceholderNode:hover .react-flow__node-header .react-flow__node-label {\n color: #aeaeae;\n}\n\n.react-flow__node-inserter-popover .components-popover__content {\n width: 350px;\n}\n\n.react-flow__node-inserter-popover {\n display: flex;\n flex-direction: column;\n position: relative;\n}\n\n.react-flow__node-inserter-popover-content {\n height: 100%;\n overflow-y: auto;\n height: 340px;\n}\n\n.react-flow__node-inserter-popover-close {\n cursor: pointer;\n background-color: #000;\n color: #fff;\n display: block;\n width: 100%;\n padding: 6px;\n height: 44px;\n}\n\n.react-flow__node-inserter-popover .components-popover__content {\n height: ;\n}\n\n/* GENERIC NODE */\n\n.react-flow__node-genericNode {\n background-color: #b2b2c9;\n border: 1px solid #b2b2c9;\n}\n\n.react-flow__node-genericNode .react-flow__handle {\n background-color: #fff;\n border: 1px solid #b2b2c9;\n}\n\n.react-flow__node-genericNode .react-flow__node-top {\n border-bottom: 1px solid #b2b2c9;\n}\n\n.react-flow__node-genericNode .react-flow__node-slug {\n color: #b2b2c9;\n}\n\n/* TRIGGER */\n\n.react-flow__node-genericTrigger {\n background-color: #dce5df;\n border: 1px solid #b9c0bb;\n}\n\n.react-flow__node-genericTrigger .react-flow__handle {\n background-color: #fff;\n border: 1px solid #B594B6;\n}\n\n.react-flow__node-genericTrigger .react-flow__node-slug {\n color: #939895;\n}\n\n.react-flow__node-genericTrigger .react-flow__node-top {\n border-bottom: 1px solid #b9c0bb;\n}\n\n.react-flow__node-genericTrigger .react-flow__node-slug {\n color: #808882;\n}\n\n/* GENERIC ACTION */\n\n.react-flow__node-genericAction {\n background-color: #89bae4;\n border: 1px solid #7199bc;\n}\n\n.react-flow__node-genericAction .react-flow__handle {\n background-color: #fff;\n border: 1px solid #7199bc;\n}\n\n.react-flow__node-genericAction .react-flow__node-slug {\n color: #8a62be;\n}\n\n.react-flow__node-genericAction .react-flow__node-top {\n border-bottom: 1px solid #7199bc;\n}\n\n.react-flow__node-genericAction .react-flow__node-slug {\n color: #526e87;\n}\n\n/* GENERIC ADVANCED */\n\n.react-flow__node-genericAdvanced {\n background-color: #f8ddad;\n border: 1px solid #d3bc94;\n}\n\n.react-flow__node-genericAdvanced .react-flow__handle {\n background-color: #fff;\n border: 1px solid #d3bc94;\n}\n\n.react-flow__node-genericAdvanced .react-flow__node-slug {\n color: #b19f80;\n}\n\n.react-flow__node-genericAdvanced .react-flow__node-top {\n border-bottom: 1px solid #d3bc94;\n}\n\n.react-flow__node-genericAdvanced .react-flow__node-slug {\n color: #908065;\n}\n\n/* QUERY ACTION */\n\n.react-flow__node-queryAction {\n background-color: #d8b6f2;\n border: 1px solid #b891c2;\n}\n\n.react-flow__node-queryAction .react-flow__handle {\n background-color: #fff;\n border: 1px solid #b891c2;\n}\n\n.react-flow__node-queryAction .react-flow__node-slug {\n color: #9079a1;\n}\n\n.react-flow__node-queryAction .react-flow__node-top {\n border-bottom: 1px solid #b891c2;\n}\n\n.react-flow__node-queryAction .react-flow__node-slug {\n color: rgb(110, 110, 125);\n}\n\n/* DEBUG ACTION */\n\n.react-flow__node-debugAction {\n background-color: #f0aec6;\n border: 1px solid #cf96ab;\n}\n\n.react-flow__node-debugAction .react-flow__handle {\n background-color: #fff;\n border: 1px solid #cf96ab;\n}\n\n.react-flow__node-debugAction .react-flow__node-slug {\n color: #916877;\n}\n\n.react-flow__node-debugAction .react-flow__node-top {\n border-bottom: 1px solid #cf96ab;\n}\n\n\n/* SELECTED NODES */\n\n.react-flow__node.selected .react-flow__node-body {\n border: 1px solid #555;\n}\n\n.react-flow__node-genericNode .react-flow__node-slug {\n color: #b2b2c9;\n}\n\n/* HANDLE AREA */\n\n.react-flow__node-handle-area {\n font-size: 6px;\n background-color: #fff;\n border-bottom-left-radius: 8px;\n border-bottom-right-radius: 8px;\n display: flex;\n flex-direction: row;\n}\n\n.react-flow__node-handle-name {\n padding: 4px 2px 6px 2px;\n text-align: center;\n line-height: 100%;\n flex: 1;\n border-left: 1px solid silver;\n}\n\n.react-flow__node-handle-name:first-child {\n border-left: 0;\n}\n\n/* Node Content */\n.react-flow__node-content {\n font-size: 6px;\n margin-top: 6px;\n}\n\n.react-flow__node-content table {\n border-spacing: 0;\n width: 100%;\n}\n\n.react-flow__node-content table th {\n text-align: left;\n}\n\n.react-flow__node-content table th,\n.react-flow__node-content table td {\n padding: 0 6px;\n font-size: 6px;\n border: 1px solid rgba(0, 0, 0, 0.1);\n}\n\n/* Node Markers */\n.react-flow__node-marker-wrapper {\n position: absolute;\n top: -17px;\n right: 0;\n display: flex;\n flex-direction: row;\n gap: 2px;\n justify-content: right;\n}\n\n.react-flow__node-error,\n.react-flow__node-pro-badge {\n display: flex;\n border-radius: 100%;\n width: 14px;\n height: 14px;\n box-sizing: border-box;\n justify-content: center;\n vertical-align: middle;\n}\n\n.react-flow__node-pro-badge {\n background-color: #ffb200;\n color: #000;\n}\n\n.react-flow__node-pro-badge .node-icon {\n margin-top: -2px;\n}\n\n.react-flow__node-error {\n background-color: #d90f0f;\n color: #fff;\n font-size: 10px;\n text-align: center;\n line-height: 12px;\n font-family: monospace;\n font-weight: 900;\n padding-left: 0px;\n}\n\n.react-flow__node-error .node-icon {\n margin-top: 2px;\n}\n\nbody.workflow-editor.is-free .react-flow__node-handle-name {\n color: #cacaca;\n}\n\nbody.workflow-editor.is-free .react-flow__node-handle-name.handle-area-source-output,\nbody.workflow-editor.is-free .react-flow__node-handle-name.handle-area-source-true {\n color: #000;\n}\n",""]);const l=i},4143:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".workflow-editor-notices__snackbar-list {\n position: fixed;\n bottom: 35px;\n left: 220px;\n}\n\n.folded .workflow-editor-notices__snackbar-list {\n left: 92px;\n}\n\n.is-fullscreen-mode .workflow-editor-notices__snackbar-list {\n left: 60px;\n}\n",""]);const l=i},8501:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".block-editor-block-types-list__item-pro-badge {\n background-color: #ffb200;\n color: #000;\n padding: 3px 8px;\n border-radius: 4px;\n font-size: 10px;\n font-weight: 600;\n width: 81%;\n}\n\n.components-popover__content .block-editor-block-types-list__item-pro-badge {\n width: 100%;\n}\n\n.workflow-editor-inspector-card__pro-badge,\n.block-editor-block-card__pro-badge {\n background-color: #ffb200;\n color: #000;\n padding: 3px 8px;\n border-radius: 4px;\n font-size: 10px;\n font-weight: 600;\n}\n\n.workflow-editor-inspector-card__pro-badge,\n.components-popover__content .block-editor-block-card__pro-badge {\n margin-left: 8px;\n}\n\n.workflow-editor-inspector-card__pro-instructions,\n.block-editor-block-card__pro-instructions {\n font-size: 12px;\n color: #757575;\n margin-top: 8px;\n line-height: 1.5;\n font-style: italic;\n font-weight: 400;\n border-top: 1px solid #e0e0e0;\n padding-top: 8px;\n}\n\n.edit-post-header-toolbar__buy-pro {\n background-color: #ffb200;\n color: #000;\n padding: 4px 10px !important;\n border-radius: 4px;\n}\n\n.edit-post-header-toolbar__buy-pro .publishpress-icon {\n width: 18px !important;\n height: 18px !important;\n margin-right: 4px;\n}\n",""]);const l=i},269:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,"/* .react-flow__node-toolbar {\n position: absolute;\n top: -40px;\n left: 0;\n}\n\n.react-flow__node-toolbar .components-toolbar {\n height: 30px !important;\n min-height: 20px;\n}\n\n.react-flow__node-toolbar .components-toolbar > div {\n min-width: 30px;\n}\n\n.react-flow__node-toolbar button.components-button.components-toolbar__control.has-icon {\n min-width: 30px !important;\n height: 30px !important;\n} */\n",""]);const l=i},1461:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".publishpress-future-date-preview .publishpress-future-date-preview-value {\n font-family: monospace;\n background-color: #e7e7e7;\n padding: 2px 4px;\n}\n\n.publishpress-future-date-preview.compact .publishpress-future-date-preview-label {\n display: block;\n}\n\n.publishpress-future-date-preview.compact {\n margin-bottom: 8px;\n}\n\n.publishpress-future-date-preview.compact h4 {\n font-size: 11px;\n font-weight: 500;\n line-height: 1.4;\n text-transform: uppercase;\n display: inline-block;\n margin-bottom: calc(8px);\n padding: 0px;\n flex-shrink: 0;\n margin-right: 12px;\n max-width: 75%;\n margin-top: 0;\n}\n\n.publishpress-future-notice.publishpress-future-notice-error {\n color: #dc3232;\n}\n",""]);const l=i},3133:(e,t,n)=>{"use strict";n.d(t,{A:()=>v});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a),l=n(6943),s=n(2158),c=n(7448),u=n(4259),d=n(1578),f=n(8565),p=n(7860),h=n(269),m=n(4143),g=n(8501),b=n(217),y=i()(o());y.i(l.A),y.i(s.A),y.i(c.A),y.i(u.A),y.i(d.A),y.i(f.A),y.i(p.A),y.i(h.A),y.i(m.A),y.i(g.A),y.i(b.A),y.push([e.id,".reactflow-wrapper {\n height: 100%;\n}\n\n.components-notice {\n padding: 0 12px;\n}\n\n.components-notice-list .components-notice__dismiss {\n margin-top: 12px;\n}\n",""]);const v=y},6241:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,'.ruleGroup{display:flex;flex-direction:column;gap:.5rem;padding:.5rem;border-width:1px}.ruleGroup .ruleGroup-body{display:flex;flex-direction:column;gap:.5rem}.ruleGroup .ruleGroup-body:empty{display:none}.ruleGroup .ruleGroup-header,.ruleGroup .rule{display:flex;gap:.5rem;align-items:center}.ruleGroup .rule .rule-value:has(.rule-value-list-item){display:flex;gap:.5rem;align-items:baseline}.ruleGroup .betweenRules{display:flex}.ruleGroup .shiftActions{display:flex;flex-direction:column}.ruleGroup .shiftActions>*{padding:0}.dndOver.rule,.dndOver.ruleGroup-header{padding-bottom:.5rem}.dndOver.betweenRules{padding-top:.5rem}.queryBuilder-branches .ruleGroup-body{margin-left:calc(2*0.5rem)}.queryBuilder-branches .rule,.queryBuilder-branches .ruleGroup .ruleGroup{position:relative}.queryBuilder-branches .rule::before,.queryBuilder-branches .rule::after,.queryBuilder-branches .ruleGroup .ruleGroup::before,.queryBuilder-branches .ruleGroup .ruleGroup::after{content:"";width:.5rem;left:calc(-0.5rem - 1px);border-radius:0;position:absolute}.queryBuilder-branches .rule::before,.queryBuilder-branches .ruleGroup .ruleGroup::before{top:-0.5rem;height:calc(50% + 0.5rem);border-width:0 0 1px 1px}.queryBuilder-branches .rule::after,.queryBuilder-branches .ruleGroup .ruleGroup::after{top:50%;height:50%;border-width:0 0 0 1px}.queryBuilder-branches .rule:last-child::after,.queryBuilder-branches .ruleGroup .ruleGroup:last-child::after{display:none}.queryBuilder-branches .ruleGroup .ruleGroup::before,.queryBuilder-branches .ruleGroup .ruleGroup::after{left:calc(-0.5rem - 1px - 1px)}.queryBuilder-branches .ruleGroup .ruleGroup::before{top:calc(-0.5rem - 1px);height:calc(50% + 0.5rem + 1px)}.queryBuilder-branches .ruleGroup .ruleGroup::after{height:calc(50% + 1px)}.queryBuilder-branches .betweenRules{position:relative}.queryBuilder-branches .betweenRules::before{content:"";width:.5rem;left:calc(-0.5rem - 1px);border-radius:0;position:absolute;top:-0.5rem;height:calc(100% + 0.5rem);border-width:0 0 0 1px}.ruleGroup{border-color:#8081a2;border-style:solid;border-radius:.25rem;background:rgba(0,75,183,.2)}.ruleGroup .shiftActions>*{background-color:rgba(0,0,0,0);border:none;cursor:pointer}.dndOver.rule,.dndOver.ruleGroup-header{border-bottom-width:2px;border-bottom-style:dashed;border-bottom-color:#639}.dndOver.rule.dndCopy,.dndOver.ruleGroup-header.dndCopy{border-bottom-color:#693}.dndOver.betweenRules{border-top-width:2px;border-top-style:dashed;border-top-color:#639}.dndOver.betweenRules.dndCopy{border-top-color:#693}.ruleGroup.dndDragging,.rule.dndDragging{opacity:.5}.ruleGroup .queryBuilder-dragHandle,.rule .queryBuilder-dragHandle{cursor:move}.queryBuilder-branches .rule::before,.queryBuilder-branches .rule::after,.queryBuilder-branches .ruleGroup .ruleGroup::before,.queryBuilder-branches .ruleGroup .ruleGroup::after{border-color:#8081a2;border-style:solid}.queryBuilder-branches .rule:last-child::before,.queryBuilder-branches .ruleGroup .ruleGroup:last-child::before{border-bottom-left-radius:.25rem}.queryBuilder-branches .betweenRules{position:relative}.queryBuilder-branches .betweenRules::before{border-color:#8081a2;border-style:solid}',""]);const l=i},2672:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,"/* this gets exported as style.css and can be used for the default theming */\n/* these are the necessary styles for React Flow, they get used by base.css and style.css */\n.react-flow {\n direction: ltr;\n}\n.react-flow__container {\n position: absolute;\n width: 100%;\n height: 100%;\n top: 0;\n left: 0;\n}\n.react-flow__pane {\n z-index: 1;\n cursor: -webkit-grab;\n cursor: grab;\n}\n.react-flow__pane.selection {\n cursor: pointer;\n }\n.react-flow__pane.dragging {\n cursor: -webkit-grabbing;\n cursor: grabbing;\n }\n.react-flow__viewport {\n transform-origin: 0 0;\n z-index: 2;\n pointer-events: none;\n}\n.react-flow__renderer {\n z-index: 4;\n}\n.react-flow__selection {\n z-index: 6;\n}\n.react-flow__nodesselection-rect:focus,\n.react-flow__nodesselection-rect:focus-visible {\n outline: none;\n}\n.react-flow .react-flow__edges {\n pointer-events: none;\n overflow: visible;\n}\n.react-flow__edge-path,\n.react-flow__connection-path {\n stroke: #b1b1b7;\n stroke-width: 1;\n fill: none;\n}\n.react-flow__edge {\n pointer-events: visibleStroke;\n cursor: pointer;\n}\n.react-flow__edge.animated path {\n stroke-dasharray: 5;\n -webkit-animation: dashdraw 0.5s linear infinite;\n animation: dashdraw 0.5s linear infinite;\n }\n.react-flow__edge.animated path.react-flow__edge-interaction {\n stroke-dasharray: none;\n -webkit-animation: none;\n animation: none;\n }\n.react-flow__edge.inactive {\n pointer-events: none;\n }\n.react-flow__edge.selected,\n .react-flow__edge:focus,\n .react-flow__edge:focus-visible {\n outline: none;\n }\n.react-flow__edge.selected .react-flow__edge-path,\n .react-flow__edge:focus .react-flow__edge-path,\n .react-flow__edge:focus-visible .react-flow__edge-path {\n stroke: #555;\n }\n.react-flow__edge-textwrapper {\n pointer-events: all;\n }\n.react-flow__edge-textbg {\n fill: white;\n }\n.react-flow__edge .react-flow__edge-text {\n pointer-events: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none;\n }\n.react-flow__connection {\n pointer-events: none;\n}\n.react-flow__connection .animated {\n stroke-dasharray: 5;\n -webkit-animation: dashdraw 0.5s linear infinite;\n animation: dashdraw 0.5s linear infinite;\n }\n.react-flow__connectionline {\n z-index: 1001;\n}\n.react-flow__nodes {\n pointer-events: none;\n transform-origin: 0 0;\n}\n.react-flow__node {\n position: absolute;\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none;\n pointer-events: all;\n transform-origin: 0 0;\n box-sizing: border-box;\n cursor: -webkit-grab;\n cursor: grab;\n}\n.react-flow__node.dragging {\n cursor: -webkit-grabbing;\n cursor: grabbing;\n }\n.react-flow__nodesselection {\n z-index: 3;\n transform-origin: left top;\n pointer-events: none;\n}\n.react-flow__nodesselection-rect {\n position: absolute;\n pointer-events: all;\n cursor: -webkit-grab;\n cursor: grab;\n }\n.react-flow__handle {\n position: absolute;\n pointer-events: none;\n min-width: 5px;\n min-height: 5px;\n width: 6px;\n height: 6px;\n background: #1a192b;\n border: 1px solid white;\n border-radius: 100%;\n}\n.react-flow__handle.connectionindicator {\n pointer-events: all;\n cursor: crosshair;\n }\n.react-flow__handle-bottom {\n top: auto;\n left: 50%;\n bottom: -4px;\n transform: translate(-50%, 0);\n }\n.react-flow__handle-top {\n left: 50%;\n top: -4px;\n transform: translate(-50%, 0);\n }\n.react-flow__handle-left {\n top: 50%;\n left: -4px;\n transform: translate(0, -50%);\n }\n.react-flow__handle-right {\n right: -4px;\n top: 50%;\n transform: translate(0, -50%);\n }\n.react-flow__edgeupdater {\n cursor: move;\n pointer-events: all;\n}\n.react-flow__panel {\n position: absolute;\n z-index: 5;\n margin: 15px;\n}\n.react-flow__panel.top {\n top: 0;\n }\n.react-flow__panel.bottom {\n bottom: 0;\n }\n.react-flow__panel.left {\n left: 0;\n }\n.react-flow__panel.right {\n right: 0;\n }\n.react-flow__panel.center {\n left: 50%;\n transform: translateX(-50%);\n }\n.react-flow__attribution {\n font-size: 10px;\n background: rgba(255, 255, 255, 0.5);\n padding: 2px 3px;\n margin: 0;\n}\n.react-flow__attribution a {\n text-decoration: none;\n color: #999;\n }\n@-webkit-keyframes dashdraw {\n from {\n stroke-dashoffset: 10;\n }\n}\n@keyframes dashdraw {\n from {\n stroke-dashoffset: 10;\n }\n}\n.react-flow__edgelabel-renderer {\n position: absolute;\n width: 100%;\n height: 100%;\n pointer-events: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none;\n}\n.react-flow__edge.updating .react-flow__edge-path {\n stroke: #777;\n }\n.react-flow__edge-text {\n font-size: 10px;\n }\n.react-flow__node.selectable:focus,\n .react-flow__node.selectable:focus-visible {\n outline: none;\n }\n.react-flow__node-default,\n.react-flow__node-input,\n.react-flow__node-output,\n.react-flow__node-group {\n padding: 10px;\n border-radius: 3px;\n width: 150px;\n font-size: 12px;\n color: #222;\n text-align: center;\n border-width: 1px;\n border-style: solid;\n border-color: #1a192b;\n background-color: white;\n}\n.react-flow__node-default.selectable:hover, .react-flow__node-input.selectable:hover, .react-flow__node-output.selectable:hover, .react-flow__node-group.selectable:hover {\n box-shadow: 0 1px 4px 1px rgba(0, 0, 0, 0.08);\n }\n.react-flow__node-default.selectable.selected,\n .react-flow__node-default.selectable:focus,\n .react-flow__node-default.selectable:focus-visible,\n .react-flow__node-input.selectable.selected,\n .react-flow__node-input.selectable:focus,\n .react-flow__node-input.selectable:focus-visible,\n .react-flow__node-output.selectable.selected,\n .react-flow__node-output.selectable:focus,\n .react-flow__node-output.selectable:focus-visible,\n .react-flow__node-group.selectable.selected,\n .react-flow__node-group.selectable:focus,\n .react-flow__node-group.selectable:focus-visible {\n box-shadow: 0 0 0 0.5px #1a192b;\n }\n.react-flow__node-group {\n background-color: rgba(240, 240, 240, 0.25);\n}\n.react-flow__nodesselection-rect,\n.react-flow__selection {\n background: rgba(0, 89, 220, 0.08);\n border: 1px dotted rgba(0, 89, 220, 0.8);\n}\n.react-flow__nodesselection-rect:focus,\n .react-flow__nodesselection-rect:focus-visible,\n .react-flow__selection:focus,\n .react-flow__selection:focus-visible {\n outline: none;\n }\n.react-flow__controls {\n box-shadow: 0 0 2px 1px rgba(0, 0, 0, 0.08);\n}\n.react-flow__controls-button {\n border: none;\n background: #fefefe;\n border-bottom: 1px solid #eee;\n box-sizing: content-box;\n display: flex;\n justify-content: center;\n align-items: center;\n width: 16px;\n height: 16px;\n cursor: pointer;\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none;\n padding: 5px;\n }\n.react-flow__controls-button:hover {\n background: #f4f4f4;\n }\n.react-flow__controls-button svg {\n width: 100%;\n max-width: 12px;\n max-height: 12px;\n }\n.react-flow__controls-button:disabled {\n pointer-events: none;\n }\n.react-flow__controls-button:disabled svg {\n fill-opacity: 0.4;\n }\n.react-flow__minimap {\n background-color: #fff;\n}\n.react-flow__minimap svg {\n display: block;\n}\n.react-flow__resize-control {\n position: absolute;\n}\n.react-flow__resize-control.left,\n.react-flow__resize-control.right {\n cursor: ew-resize;\n}\n.react-flow__resize-control.top,\n.react-flow__resize-control.bottom {\n cursor: ns-resize;\n}\n.react-flow__resize-control.top.left,\n.react-flow__resize-control.bottom.right {\n cursor: nwse-resize;\n}\n.react-flow__resize-control.bottom.left,\n.react-flow__resize-control.top.right {\n cursor: nesw-resize;\n}\n/* handle styles */\n.react-flow__resize-control.handle {\n width: 4px;\n height: 4px;\n border: 1px solid #fff;\n border-radius: 1px;\n background-color: #3367d9;\n transform: translate(-50%, -50%);\n}\n.react-flow__resize-control.handle.left {\n left: 0;\n top: 50%;\n}\n.react-flow__resize-control.handle.right {\n left: 100%;\n top: 50%;\n}\n.react-flow__resize-control.handle.top {\n left: 50%;\n top: 0;\n}\n.react-flow__resize-control.handle.bottom {\n left: 50%;\n top: 100%;\n}\n.react-flow__resize-control.handle.top.left {\n left: 0;\n}\n.react-flow__resize-control.handle.bottom.left {\n left: 0;\n}\n.react-flow__resize-control.handle.top.right {\n left: 100%;\n}\n.react-flow__resize-control.handle.bottom.right {\n left: 100%;\n}\n/* line styles */\n.react-flow__resize-control.line {\n border-color: #3367d9;\n border-width: 0;\n border-style: solid;\n}\n.react-flow__resize-control.line.left,\n.react-flow__resize-control.line.right {\n width: 1px;\n transform: translate(-50%, 0);\n top: 0;\n height: 100%;\n}\n.react-flow__resize-control.line.left {\n left: 0;\n border-left-width: 1px;\n}\n.react-flow__resize-control.line.right {\n left: 100%;\n border-right-width: 1px;\n}\n.react-flow__resize-control.line.top,\n.react-flow__resize-control.line.bottom {\n height: 1px;\n transform: translate(0, -50%);\n left: 0;\n width: 100%;\n}\n.react-flow__resize-control.line.top {\n top: 0;\n border-top-width: 1px;\n}\n.react-flow__resize-control.line.bottom {\n border-bottom-width: 1px;\n top: 100%;\n}\n",""]);const l=i},6314:e=>{"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",r=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),r&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),r&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,r,o,a){"string"==typeof e&&(e=[[null,e,void 0]]);var i={};if(r)for(var l=0;l0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=a),n&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=n):u[2]=n),o&&(u[4]?(u[1]="@supports (".concat(u[4],") {").concat(u[1],"}"),u[4]=o):u[4]="".concat(o)),t.push(u))}},t}},1601:e=>{"use strict";e.exports=function(e){return e[1]}},124:e=>{"use strict";var t,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,o=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,i={};((e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})})(i,{Immer:()=>Y,applyPatches:()=>ie,castDraft:()=>ce,castImmutable:()=>ue,createDraft:()=>le,current:()=>Q,enableMapSet:()=>ee,enablePatches:()=>J,finishDraft:()=>se,freeze:()=>R,immerable:()=>s,isDraft:()=>f,isDraftable:()=>p,nothing:()=>l,original:()=>g,produce:()=>ne,produceWithPatches:()=>re,setAutoFreeze:()=>oe,setUseStrictShallowCopy:()=>ae}),e.exports=(t=i,((e,t,i,l)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of o(t))!a.call(e,i)&&undefined!==i&&n(e,i,{get:()=>t[i],enumerable:!(l=r(t,i))||l.enumerable});return e})(n({},"__esModule",{value:!0}),t));var l=Symbol.for("immer-nothing"),s=Symbol.for("immer-draftable"),c=Symbol.for("immer-state");function u(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var d=Object.getPrototypeOf;function f(e){return!!e&&!!e[c]}function p(e){return!!e&&(m(e)||Array.isArray(e)||!!e[s]||!!e.constructor?.[s]||E(e)||S(e))}var h=Object.prototype.constructor.toString();function m(e){if(!e||"object"!=typeof e)return!1;let t=d(e);if(null===t)return!0;let n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return n===Object||"function"==typeof n&&Function.toString.call(n)===h}function g(e){return f(e)||u(15),e[c].t}function b(e,t){0===y(e)?Reflect.ownKeys(e).forEach((n=>{t(n,e[n],e)})):e.forEach(((n,r)=>t(r,n,e)))}function y(e){let t=e[c];return t?t.o:Array.isArray(e)?1:E(e)?2:S(e)?3:0}function v(e,t){return 2===y(e)?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function w(e,t){return 2===y(e)?e.get(t):e[t]}function _(e,t,n){let r=y(e);2===r?e.set(t,n):3===r?e.add(n):e[t]=n}function E(e){return e instanceof Map}function S(e){return e instanceof Set}function x(e){return e.e||e.t}function k(e,t){if(E(e))return new Map(e);if(S(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);let n=m(e);if(!0===t||"class_only"===t&&!n){let t=Object.getOwnPropertyDescriptors(e);delete t[c];let n=Reflect.ownKeys(t);for(let r=0;r1&&(e.set=e.add=e.clear=e.delete=C),Object.freeze(e),t&&Object.entries(e).forEach((([e,t])=>R(t,!0)))),e}function C(){u(2)}function N(e){return Object.isFrozen(e)}var O,A={};function P(e){let t=A[e];return t||u(0),t}function D(e,t){A[e]||(A[e]=t)}function T(){return O}function I(e,t){t&&(P("Patches"),e.f=[],e.h=[],e.b=t)}function j(e){M(e),e.a.forEach(L),e.a=null}function M(e){e===O&&(O=e.i)}function $(e){return O=function(e,t){return{a:[],i:e,p:t,P:!0,d:0}}(O,e)}function L(e){let t=e[c];0===t.o||1===t.o?t.x():t.m=!0}function F(e,t){t.d=t.a.length;let n=t.a[0];return void 0!==e&&e!==n?(n[c].s&&(j(t),u(4)),p(e)&&(e=z(t,e),t.i||G(t,e)),t.f&&P("Patches").T(n[c].t,e,t.f,t.h)):e=z(t,n,[]),j(t),t.f&&t.b(t.f,t.h),e!==l?e:void 0}function z(e,t,n){if(N(t))return t;let r=t[c];if(!r)return b(t,((o,a)=>W(e,r,t,o,a,n))),t;if(r.n!==e)return t;if(!r.s)return G(e,r.t,!0),r.t;if(!r.c){r.c=!0,r.n.d--;let t=r.e,o=t,a=!1;3===r.o&&(o=new Set(t),t.clear(),a=!0),b(o,((o,i)=>W(e,r,t,o,i,n,a))),G(e,t,!1),n&&e.f&&P("Patches").g(r,n,e.f,e.h)}return r.e}function W(e,t,n,r,o,a,i){if(f(o)){let i=z(e,o,a&&t&&3!==t.o&&!v(t.r,r)?a.concat(r):void 0);if(_(n,r,i),!f(i))return;e.P=!1}else i&&n.add(o);if(p(o)&&!N(o)){if(!e.p.y&&e.d<1)return;z(e,o),(!t||!t.n.i)&&"symbol"!=typeof r&&Object.prototype.propertyIsEnumerable.call(n,r)&&G(e,o)}}function G(e,t,n=!1){!e.i&&e.p.y&&e.P&&R(t,n)}var B={get(e,t){if(t===c)return e;let n=x(e);if(!v(n,t))return function(e,t,n){let r=U(t,n);return r?"value"in r?r.value:r.get?.call(e.u):void 0}(e,n,t);let r=n[t];return e.c||!p(r)?r:r===H(e.t,t)?(X(e),e.e[t]=K(r,e)):r},has:(e,t)=>t in x(e),ownKeys:e=>Reflect.ownKeys(x(e)),set(e,t,n){let r=U(x(e),t);if(r?.set)return r.set.call(e.u,n),!0;if(!e.s){let r=H(x(e),t),o=r?.[c];if(o&&o.t===n)return e.e[t]=n,e.r[t]=!1,!0;if(function(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}(n,r)&&(void 0!==n||v(e.t,t)))return!0;X(e),q(e)}return e.e[t]===n&&(void 0!==n||t in e.e)||Number.isNaN(n)&&Number.isNaN(e.e[t])||(e.e[t]=n,e.r[t]=!0),!0},deleteProperty:(e,t)=>(void 0!==H(e.t,t)||t in e.t?(e.r[t]=!1,X(e),q(e)):delete e.r[t],e.e&&delete e.e[t],!0),getOwnPropertyDescriptor(e,t){let n=x(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{writable:!0,configurable:1!==e.o||"length"!==t,enumerable:r.enumerable,value:n[t]}},defineProperty(){u(11)},getPrototypeOf:e=>d(e.t),setPrototypeOf(){u(12)}},V={};function H(e,t){let n=e[c];return(n?x(n):e)[t]}function U(e,t){if(!(t in e))return;let n=d(e);for(;n;){let e=Object.getOwnPropertyDescriptor(n,t);if(e)return e;n=d(n)}}function q(e){e.s||(e.s=!0,e.i&&q(e.i))}function X(e){e.e||(e.e=k(e.t,e.n.p.S))}b(B,((e,t)=>{V[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}})),V.deleteProperty=function(e,t){return V.set.call(this,e,t,void 0)},V.set=function(e,t,n){return B.set.call(this,e[0],t,n,e[0])};var Y=class{constructor(e){this.y=!0,this.S=!1,this.produce=(e,t,n)=>{if("function"==typeof e&&"function"!=typeof t){let n=t;t=e;let r=this;return function(e=n,...o){return r.produce(e,(e=>t.call(this,e,...o)))}}let r;if("function"!=typeof t&&u(6),void 0!==n&&"function"!=typeof n&&u(7),p(e)){let o=$(this),a=K(e,void 0),i=!0;try{r=t(a),i=!1}finally{i?j(o):M(o)}return I(o,n),F(r,o)}if(!e||"object"!=typeof e){if(r=t(e),void 0===r&&(r=e),r===l&&(r=void 0),this.y&&R(r,!0),n){let t=[],o=[];P("Patches").T(e,r,t,o),n(t,o)}return r}u(1)},this.produceWithPatches=(e,t)=>{if("function"==typeof e)return(t,...n)=>this.produceWithPatches(t,(t=>e(t,...n)));let n,r;return[this.produce(e,t,((e,t)=>{n=e,r=t})),n,r]},"boolean"==typeof e?.autoFreeze&&this.setAutoFreeze(e.autoFreeze),"boolean"==typeof e?.useStrictShallowCopy&&this.setUseStrictShallowCopy(e.useStrictShallowCopy)}createDraft(e){p(e)||u(8),f(e)&&(e=Q(e));let t=$(this),n=K(e,void 0);return n[c].l=!0,M(t),n}finishDraft(e,t){let n=e&&e[c];(!n||!n.l)&&u(9);let{n:r}=n;return I(r,t),F(void 0,r)}setAutoFreeze(e){this.y=e}setUseStrictShallowCopy(e){this.S=e}applyPatches(e,t){let n;for(n=t.length-1;n>=0;n--){let r=t[n];if(0===r.path.length&&"replace"===r.op){e=r.value;break}}n>-1&&(t=t.slice(n+1));let r=P("Patches").A;return f(e)?r(e,t):this.produce(e,(e=>r(e,t)))}};function K(e,t){let n=E(e)?P("MapSet").I(e,t):S(e)?P("MapSet").D(e,t):function(e,t){let n=Array.isArray(e),r={o:n?1:0,n:t?t.n:T(),s:!1,c:!1,r:{},i:t,t:e,u:null,e:null,x:null,l:!1},o=r,a=B;n&&(o=[r],a=V);let{revoke:i,proxy:l}=Proxy.revocable(o,a);return r.u=l,r.x=i,l}(e,t);return(t?t.n:T()).a.push(n),n}function Q(e){return f(e)||u(10),Z(e)}function Z(e){if(!p(e)||N(e))return e;let t,n=e[c];if(n){if(!n.s)return n.t;n.c=!0,t=k(e,n.n.p.S)}else t=k(e,!0);return b(t,((e,n)=>{_(t,e,Z(n))})),n&&(n.c=!1),t}function J(){let e="replace",t="add",n="remove";function r(e){if(!p(e))return e;if(Array.isArray(e))return e.map(r);if(E(e))return new Map(Array.from(e.entries()).map((([e,t])=>[e,r(t)])));if(S(e))return new Set(Array.from(e).map(r));let t=Object.create(d(e));for(let n in e)t[n]=r(e[n]);return v(e,s)&&(t[s]=e[s]),t}function o(e){return f(e)?r(e):e}D("Patches",{A:function(o,a){return a.forEach((a=>{let{path:i,op:l}=a,s=o;for(let e=0;e{let d=w(s,r),f=w(c,r),p=u?v(s,r)?e:t:n;if(d===f&&p===e)return;let h=a.concat(r);i.push(p===n?{op:p,path:h}:{op:p,path:h,value:f}),l.push(p===t?{op:n,path:h}:p===n?{op:t,path:h,value:o(d)}:{op:e,path:h,value:o(d)})}))}(r,a,i,l);case 1:return function(r,a,i,l){let{t:s,r:c}=r,u=r.e;u.length{if(!l.has(e)){let i=r.concat([s]);o.push({op:n,path:i,value:e}),a.unshift({op:t,path:i,value:e})}s++})),s=0,l.forEach((e=>{if(!i.has(e)){let i=r.concat([s]);o.push({op:t,path:i,value:e}),a.unshift({op:n,path:i,value:e})}s++}))}(r,a,i,l)}},T:function(t,n,r,o){r.push({op:e,path:[],value:n===l?void 0:n}),o.push({op:e,path:[],value:t})}})}function ee(){class e extends Map{constructor(e,t){super(),this[c]={o:2,i:t,n:t?t.n:T(),s:!1,c:!1,e:void 0,r:void 0,t:e,u:this,l:!1,m:!1}}get size(){return x(this[c]).size}has(e){return x(this[c]).has(e)}set(e,n){let r=this[c];return o(r),(!x(r).has(e)||x(r).get(e)!==n)&&(t(r),q(r),r.r.set(e,!0),r.e.set(e,n),r.r.set(e,!0)),this}delete(e){if(!this.has(e))return!1;let n=this[c];return o(n),t(n),q(n),n.t.has(e)?n.r.set(e,!1):n.r.delete(e),n.e.delete(e),!0}clear(){let e=this[c];o(e),x(e).size&&(t(e),q(e),e.r=new Map,b(e.t,(t=>{e.r.set(t,!1)})),e.e.clear())}forEach(e,t){x(this[c]).forEach(((n,r,o)=>{e.call(t,this.get(r),r,this)}))}get(e){let n=this[c];o(n);let r=x(n).get(e);if(n.c||!p(r)||r!==n.t.get(e))return r;let a=K(r,n);return t(n),n.e.set(e,a),a}keys(){return x(this[c]).keys()}values(){let e=this.keys();return{[Symbol.iterator]:()=>this.values(),next:()=>{let t=e.next();return t.done?t:{done:!1,value:this.get(t.value)}}}}entries(){let e=this.keys();return{[Symbol.iterator]:()=>this.entries(),next:()=>{let t=e.next();if(t.done)return t;let n=this.get(t.value);return{done:!1,value:[t.value,n]}}}}[Symbol.iterator](){return this.entries()}}function t(e){e.e||(e.r=new Map,e.e=new Map(e.t))}class n extends Set{constructor(e,t){super(),this[c]={o:3,i:t,n:t?t.n:T(),s:!1,c:!1,e:void 0,t:e,u:this,a:new Map,m:!1,l:!1}}get size(){return x(this[c]).size}has(e){let t=this[c];return o(t),t.e?!!(t.e.has(e)||t.a.has(e)&&t.e.has(t.a.get(e))):t.t.has(e)}add(e){let t=this[c];return o(t),this.has(e)||(r(t),q(t),t.e.add(e)),this}delete(e){if(!this.has(e))return!1;let t=this[c];return o(t),r(t),q(t),t.e.delete(e)||!!t.a.has(e)&&t.e.delete(t.a.get(e))}clear(){let e=this[c];o(e),x(e).size&&(r(e),q(e),e.e.clear())}values(){let e=this[c];return o(e),r(e),e.e.values()}entries(){let e=this[c];return o(e),r(e),e.e.entries()}keys(){return this.values()}[Symbol.iterator](){return this.values()}forEach(e,t){let n=this.values(),r=n.next();for(;!r.done;)e.call(t,r.value,r.value,this),r=n.next()}}function r(e){e.e||(e.e=new Set,e.t.forEach((t=>{if(p(t)){let n=K(t,e);e.a.set(t,n),e.e.add(n)}else e.e.add(t)})))}function o(e){e.m&&u(3,JSON.stringify(x(e)))}D("MapSet",{I:function(t,n){return new e(t,n)},D:function(e,t){return new n(e,t)}})}var te=new Y,ne=te.produce,re=te.produceWithPatches.bind(te),oe=te.setAutoFreeze.bind(te),ae=te.setUseStrictShallowCopy.bind(te),ie=te.applyPatches.bind(te),le=te.createDraft.bind(te),se=te.finishDraft.bind(te);function ce(e){return e}function ue(e){return e}},9407:(e,t,n)=>{"use strict";e.exports=n(124)},5580:(e,t,n)=>{var r=n(6110)(n(9325),"DataView");e.exports=r},1549:(e,t,n)=>{var r=n(2032),o=n(3862),a=n(6721),i=n(2749),l=n(5749);function s(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t{var r=n(9344),o=n(4033);function a(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=4294967295,this.__views__=[]}a.prototype=r(o.prototype),a.prototype.constructor=a,e.exports=a},79:(e,t,n)=>{var r=n(3702),o=n(80),a=n(4739),i=n(1036),l=n(1175);function s(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t{var r=n(9344),o=n(4033);function a(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=void 0}a.prototype=r(o.prototype),a.prototype.constructor=a,e.exports=a},8223:(e,t,n)=>{var r=n(6110)(n(9325),"Map");e.exports=r},3661:(e,t,n)=>{var r=n(3040),o=n(7670),a=n(289),i=n(4509),l=n(2949);function s(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t{var r=n(6110)(n(9325),"Promise");e.exports=r},6545:(e,t,n)=>{var r=n(6110)(n(9325),"Set");e.exports=r},8859:(e,t,n)=>{var r=n(3661),o=n(1380),a=n(1459);function i(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new r;++t{var r=n(79),o=n(1420),a=n(938),i=n(3605),l=n(9817),s=n(945);function c(e){var t=this.__data__=new r(e);this.size=t.size}c.prototype.clear=o,c.prototype.delete=a,c.prototype.get=i,c.prototype.has=l,c.prototype.set=s,e.exports=c},1873:(e,t,n)=>{var r=n(9325).Symbol;e.exports=r},7828:(e,t,n)=>{var r=n(9325).Uint8Array;e.exports=r},8303:(e,t,n)=>{var r=n(6110)(n(9325),"WeakMap");e.exports=r},1033:e=>{e.exports=function(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}},3945:e=>{e.exports=function(e,t,n,r){for(var o=-1,a=null==e?0:e.length;++o{e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length;++n{e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length,o=0,a=[];++n{var r=n(6131);e.exports=function(e,t){return!(null==e||!e.length)&&r(e,t,0)>-1}},9905:e=>{e.exports=function(e,t,n){for(var r=-1,o=null==e?0:e.length;++r{var r=n(8096),o=n(2428),a=n(6449),i=n(3656),l=n(361),s=n(7167),c=Object.prototype.hasOwnProperty;e.exports=function(e,t){var n=a(e),u=!n&&o(e),d=!n&&!u&&i(e),f=!n&&!u&&!d&&s(e),p=n||u||d||f,h=p?r(e.length,String):[],m=h.length;for(var g in e)!t&&!c.call(e,g)||p&&("length"==g||d&&("offset"==g||"parent"==g)||f&&("buffer"==g||"byteLength"==g||"byteOffset"==g)||l(g,m))||h.push(g);return h}},4932:e=>{e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length,o=Array(r);++n{e.exports=function(e,t){for(var n=-1,r=t.length,o=e.length;++n{e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length;++n{var t=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;e.exports=function(e){return e.match(t)||[]}},6025:(e,t,n)=>{var r=n(5288);e.exports=function(e,t){for(var n=e.length;n--;)if(r(e[n][0],t))return n;return-1}},2429:(e,t,n)=>{var r=n(909);e.exports=function(e,t,n,o){return r(e,(function(e,r,a){t(o,e,n(e),a)})),o}},3360:(e,t,n)=>{var r=n(3243);e.exports=function(e,t,n){"__proto__"==t&&r?r(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}},9344:(e,t,n)=>{var r=n(3805),o=Object.create,a=function(){function e(){}return function(t){if(!r(t))return{};if(o)return o(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();e.exports=a},3915:(e,t,n)=>{var r=n(8859),o=n(5325),a=n(9905),i=n(4932),l=n(7301),s=n(9219);e.exports=function(e,t,n,c){var u=-1,d=o,f=!0,p=e.length,h=[],m=t.length;if(!p)return h;n&&(t=i(t,l(n))),c?(d=a,f=!1):t.length>=200&&(d=s,f=!1,t=new r(t));e:for(;++u{var r=n(641),o=n(8329)(r);e.exports=o},6574:(e,t,n)=>{var r=n(909);e.exports=function(e,t){var n=[];return r(e,(function(e,r,o){t(e,r,o)&&n.push(e)})),n}},2523:e=>{e.exports=function(e,t,n,r){for(var o=e.length,a=n+(r?1:-1);r?a--:++a{var r=n(4528),o=n(5891);e.exports=function e(t,n,a,i,l){var s=-1,c=t.length;for(a||(a=o),l||(l=[]);++s0&&a(u)?n>1?e(u,n-1,a,i,l):r(l,u):i||(l[l.length]=u)}return l}},6649:(e,t,n)=>{var r=n(3221)();e.exports=r},641:(e,t,n)=>{var r=n(6649),o=n(5950);e.exports=function(e,t){return e&&r(e,t,o)}},7422:(e,t,n)=>{var r=n(1769),o=n(7797);e.exports=function(e,t){for(var n=0,a=(t=r(t,e)).length;null!=e&&n{var r=n(4528),o=n(6449);e.exports=function(e,t,n){var a=t(e);return o(e)?a:r(a,n(e))}},2552:(e,t,n)=>{var r=n(1873),o=n(659),a=n(9350),i=r?r.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":i&&i in Object(e)?o(e):a(e)}},8077:e=>{e.exports=function(e,t){return null!=e&&t in Object(e)}},6131:(e,t,n)=>{var r=n(2523),o=n(5463),a=n(6959);e.exports=function(e,t,n){return t==t?a(e,t,n):r(e,o,n)}},7534:(e,t,n)=>{var r=n(2552),o=n(346);e.exports=function(e){return o(e)&&"[object Arguments]"==r(e)}},270:(e,t,n)=>{var r=n(7068),o=n(346);e.exports=function e(t,n,a,i,l){return t===n||(null==t||null==n||!o(t)&&!o(n)?t!=t&&n!=n:r(t,n,a,i,e,l))}},7068:(e,t,n)=>{var r=n(7217),o=n(5911),a=n(1986),i=n(689),l=n(5861),s=n(6449),c=n(3656),u=n(7167),d="[object Arguments]",f="[object Array]",p="[object Object]",h=Object.prototype.hasOwnProperty;e.exports=function(e,t,n,m,g,b){var y=s(e),v=s(t),w=y?f:l(e),_=v?f:l(t),E=(w=w==d?p:w)==p,S=(_=_==d?p:_)==p,x=w==_;if(x&&c(e)){if(!c(t))return!1;y=!0,E=!1}if(x&&!E)return b||(b=new r),y||u(e)?o(e,t,n,m,g,b):a(e,t,w,n,m,g,b);if(!(1&n)){var k=E&&h.call(e,"__wrapped__"),R=S&&h.call(t,"__wrapped__");if(k||R){var C=k?e.value():e,N=R?t.value():t;return b||(b=new r),g(C,N,n,m,b)}}return!!x&&(b||(b=new r),i(e,t,n,m,g,b))}},1799:(e,t,n)=>{var r=n(7217),o=n(270);e.exports=function(e,t,n,a){var i=n.length,l=i,s=!a;if(null==e)return!l;for(e=Object(e);i--;){var c=n[i];if(s&&c[2]?c[1]!==e[c[0]]:!(c[0]in e))return!1}for(;++i{e.exports=function(e){return e!=e}},5083:(e,t,n)=>{var r=n(1882),o=n(7296),a=n(3805),i=n(7473),l=/^\[object .+?Constructor\]$/,s=Function.prototype,c=Object.prototype,u=s.toString,d=c.hasOwnProperty,f=RegExp("^"+u.call(d).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=function(e){return!(!a(e)||o(e))&&(r(e)?f:l).test(i(e))}},4901:(e,t,n)=>{var r=n(2552),o=n(294),a=n(346),i={};i["[object Float32Array]"]=i["[object Float64Array]"]=i["[object Int8Array]"]=i["[object Int16Array]"]=i["[object Int32Array]"]=i["[object Uint8Array]"]=i["[object Uint8ClampedArray]"]=i["[object Uint16Array]"]=i["[object Uint32Array]"]=!0,i["[object Arguments]"]=i["[object Array]"]=i["[object ArrayBuffer]"]=i["[object Boolean]"]=i["[object DataView]"]=i["[object Date]"]=i["[object Error]"]=i["[object Function]"]=i["[object Map]"]=i["[object Number]"]=i["[object Object]"]=i["[object RegExp]"]=i["[object Set]"]=i["[object String]"]=i["[object WeakMap]"]=!1,e.exports=function(e){return a(e)&&o(e.length)&&!!i[r(e)]}},5389:(e,t,n)=>{var r=n(3663),o=n(7978),a=n(3488),i=n(6449),l=n(583);e.exports=function(e){return"function"==typeof e?e:null==e?a:"object"==typeof e?i(e)?o(e[0],e[1]):r(e):l(e)}},8984:(e,t,n)=>{var r=n(5527),o=n(3650),a=Object.prototype.hasOwnProperty;e.exports=function(e){if(!r(e))return o(e);var t=[];for(var n in Object(e))a.call(e,n)&&"constructor"!=n&&t.push(n);return t}},4033:e=>{e.exports=function(){}},5128:(e,t,n)=>{var r=n(909),o=n(4894);e.exports=function(e,t){var n=-1,a=o(e)?Array(e.length):[];return r(e,(function(e,r,o){a[++n]=t(e,r,o)})),a}},3663:(e,t,n)=>{var r=n(1799),o=n(776),a=n(7197);e.exports=function(e){var t=o(e);return 1==t.length&&t[0][2]?a(t[0][0],t[0][1]):function(n){return n===e||r(n,e,t)}}},7978:(e,t,n)=>{var r=n(270),o=n(8156),a=n(631),i=n(8586),l=n(756),s=n(7197),c=n(7797);e.exports=function(e,t){return i(e)&&l(t)?s(c(e),t):function(n){var i=o(n,e);return void 0===i&&i===t?a(n,e):r(t,i,3)}}},6155:(e,t,n)=>{var r=n(4932),o=n(7422),a=n(5389),i=n(5128),l=n(3937),s=n(7301),c=n(3714),u=n(3488),d=n(6449);e.exports=function(e,t,n){t=t.length?r(t,(function(e){return d(e)?function(t){return o(t,1===e.length?e[0]:e)}:e})):[u];var f=-1;t=r(t,s(a));var p=i(e,(function(e,n,o){return{criteria:r(t,(function(t){return t(e)})),index:++f,value:e}}));return l(p,(function(e,t){return c(e,t,n)}))}},7237:e=>{e.exports=function(e){return function(t){return null==t?void 0:t[e]}}},7255:(e,t,n)=>{var r=n(7422);e.exports=function(e){return function(t){return r(t,e)}}},4552:e=>{e.exports=function(e){return function(t){return null==e?void 0:e[t]}}},9302:(e,t,n)=>{var r=n(3488),o=n(6757),a=n(2865);e.exports=function(e,t){return a(o(e,t,r),e+"")}},8882:(e,t,n)=>{var r=n(3488),o=n(8152),a=o?function(e,t){return o.set(e,t),e}:r;e.exports=a},9570:(e,t,n)=>{var r=n(7334),o=n(3243),a=n(3488),i=o?function(e,t){return o(e,"toString",{configurable:!0,enumerable:!1,value:r(t),writable:!0})}:a;e.exports=i},3937:e=>{e.exports=function(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}},8096:e=>{e.exports=function(e,t){for(var n=-1,r=Array(e);++n{var r=n(1873),o=n(4932),a=n(6449),i=n(4394),l=r?r.prototype:void 0,s=l?l.toString:void 0;e.exports=function e(t){if("string"==typeof t)return t;if(a(t))return o(t,e)+"";if(i(t))return s?s.call(t):"";var n=t+"";return"0"==n&&1/t==-1/0?"-0":n}},4128:(e,t,n)=>{var r=n(1800),o=/^\s+/;e.exports=function(e){return e?e.slice(0,r(e)+1).replace(o,""):e}},7301:e=>{e.exports=function(e){return function(t){return e(t)}}},9219:e=>{e.exports=function(e,t){return e.has(t)}},1769:(e,t,n)=>{var r=n(6449),o=n(8586),a=n(1802),i=n(3222);e.exports=function(e,t){return r(e)?e:o(e,t)?[e]:a(i(e))}},3730:(e,t,n)=>{var r=n(4394);e.exports=function(e,t){if(e!==t){var n=void 0!==e,o=null===e,a=e==e,i=r(e),l=void 0!==t,s=null===t,c=t==t,u=r(t);if(!s&&!u&&!i&&e>t||i&&l&&c&&!s&&!u||o&&l&&c||!n&&c||!a)return 1;if(!o&&!i&&!u&&e{var r=n(3730);e.exports=function(e,t,n){for(var o=-1,a=e.criteria,i=t.criteria,l=a.length,s=n.length;++o=s?c:c*("desc"==n[o]?-1:1)}return e.index-t.index}},1596:e=>{var t=Math.max;e.exports=function(e,n,r,o){for(var a=-1,i=e.length,l=r.length,s=-1,c=n.length,u=t(i-l,0),d=Array(c+u),f=!o;++s{var t=Math.max;e.exports=function(e,n,r,o){for(var a=-1,i=e.length,l=-1,s=r.length,c=-1,u=n.length,d=t(i-s,0),f=Array(d+u),p=!o;++a{e.exports=function(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n{var r=n(9325)["__core-js_shared__"];e.exports=r},8523:e=>{e.exports=function(e,t){for(var n=e.length,r=0;n--;)e[n]===t&&++r;return r}},2e3:(e,t,n)=>{var r=n(3945),o=n(2429),a=n(5389),i=n(6449);e.exports=function(e,t){return function(n,l){var s=i(n)?r:o,c=t?t():{};return s(n,e,a(l,2),c)}}},8329:(e,t,n)=>{var r=n(4894);e.exports=function(e,t){return function(n,o){if(null==n)return n;if(!r(n))return e(n,o);for(var a=n.length,i=t?a:-1,l=Object(n);(t?i--:++i{e.exports=function(e){return function(t,n,r){for(var o=-1,a=Object(t),i=r(t),l=i.length;l--;){var s=i[e?l:++o];if(!1===n(a[s],s,a))break}return t}}},1842:(e,t,n)=>{var r=n(2819),o=n(9325);e.exports=function(e,t,n){var a=1&t,i=r(e);return function t(){return(this&&this!==o&&this instanceof t?i:e).apply(a?n:this,arguments)}}},2819:(e,t,n)=>{var r=n(9344),o=n(3805);e.exports=function(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var n=r(e.prototype),a=e.apply(n,t);return o(a)?a:n}}},7078:(e,t,n)=>{var r=n(1033),o=n(2819),a=n(7471),i=n(8073),l=n(1287),s=n(6306),c=n(9325);e.exports=function(e,t,n){var u=o(e);return function o(){for(var d=arguments.length,f=Array(d),p=d,h=l(o);p--;)f[p]=arguments[p];var m=d<3&&f[0]!==h&&f[d-1]!==h?[]:s(f,h);return(d-=m.length){var r=n(5389),o=n(4894),a=n(5950);e.exports=function(e){return function(t,n,i){var l=Object(t);if(!o(t)){var s=r(n,3);t=a(t),n=function(e){return s(l[e],e,l)}}var c=e(t,n,i);return c>-1?l[s?t[c]:c]:void 0}}},6929:(e,t,n)=>{var r=n(6017),o=n(8816),a=n(7381),i=n(2284),l=n(6449),s=n(5087);e.exports=function(e){return o((function(t){var n=t.length,o=n,c=r.prototype.thru;for(e&&t.reverse();o--;){var u=t[o];if("function"!=typeof u)throw new TypeError("Expected a function");if(c&&!d&&"wrapper"==i(u))var d=new r([],!0)}for(o=d?o:n;++o{var r=n(1596),o=n(3320),a=n(8523),i=n(2819),l=n(8073),s=n(1287),c=n(8294),u=n(6306),d=n(9325);e.exports=function e(t,n,f,p,h,m,g,b,y,v){var w=128&n,_=1&n,E=2&n,S=24&n,x=512&n,k=E?void 0:i(t);return function R(){for(var C=arguments.length,N=Array(C),O=C;O--;)N[O]=arguments[O];if(S)var A=s(R),P=a(N,A);if(p&&(N=r(N,p,h,S)),m&&(N=o(N,m,g,S)),C-=P,S&&C1&&N.reverse(),w&&y{var r=n(1033),o=n(2819),a=n(9325);e.exports=function(e,t,n,i){var l=1&t,s=o(e);return function t(){for(var o=-1,c=arguments.length,u=-1,d=i.length,f=Array(d+c),p=this&&this!==a&&this instanceof t?s:e;++u{var r=n(5087),o=n(4641),a=n(981);e.exports=function(e,t,n,i,l,s,c,u,d,f){var p=8&t;t|=p?32:64,4&(t&=~(p?64:32))||(t&=-4);var h=[e,t,l,p?s:void 0,p?c:void 0,p?void 0:s,p?void 0:c,u,d,f],m=n.apply(void 0,h);return r(e)&&o(m,h),m.placeholder=i,a(m,e,t)}},6977:(e,t,n)=>{var r=n(8882),o=n(1842),a=n(7078),i=n(7471),l=n(4168),s=n(7381),c=n(3209),u=n(4641),d=n(981),f=n(1489),p=Math.max;e.exports=function(e,t,n,h,m,g,b,y){var v=2&t;if(!v&&"function"!=typeof e)throw new TypeError("Expected a function");var w=h?h.length:0;if(w||(t&=-97,h=m=void 0),b=void 0===b?b:p(f(b),0),y=void 0===y?y:f(y),w-=m?m.length:0,64&t){var _=h,E=m;h=m=void 0}var S=v?void 0:s(e),x=[e,t,n,h,m,_,E,g,b,y];if(S&&c(x,S),e=x[0],t=x[1],n=x[2],h=x[3],m=x[4],!(y=x[9]=void 0===x[9]?v?0:e.length:p(x[9]-w,0))&&24&t&&(t&=-25),t&&1!=t)k=8==t||16==t?a(e,t,y):32!=t&&33!=t||m.length?i.apply(void 0,x):l(e,t,n,h);else var k=o(e,t,n);return d((S?r:u)(k,x),e,t)}},4647:(e,t,n)=>{var r=n(4552)({À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"});e.exports=r},3243:(e,t,n)=>{var r=n(6110),o=function(){try{var e=r(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();e.exports=o},5911:(e,t,n)=>{var r=n(8859),o=n(4248),a=n(9219);e.exports=function(e,t,n,i,l,s){var c=1&n,u=e.length,d=t.length;if(u!=d&&!(c&&d>u))return!1;var f=s.get(e),p=s.get(t);if(f&&p)return f==t&&p==e;var h=-1,m=!0,g=2&n?new r:void 0;for(s.set(e,t),s.set(t,e);++h{var r=n(1873),o=n(7828),a=n(5288),i=n(5911),l=n(317),s=n(4247),c=r?r.prototype:void 0,u=c?c.valueOf:void 0;e.exports=function(e,t,n,r,c,d,f){switch(n){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":return!(e.byteLength!=t.byteLength||!d(new o(e),new o(t)));case"[object Boolean]":case"[object Date]":case"[object Number]":return a(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var p=l;case"[object Set]":var h=1&r;if(p||(p=s),e.size!=t.size&&!h)return!1;var m=f.get(e);if(m)return m==t;r|=2,f.set(e,t);var g=i(p(e),p(t),r,c,d,f);return f.delete(e),g;case"[object Symbol]":if(u)return u.call(e)==u.call(t)}return!1}},689:(e,t,n)=>{var r=n(2),o=Object.prototype.hasOwnProperty;e.exports=function(e,t,n,a,i,l){var s=1&n,c=r(e),u=c.length;if(u!=r(t).length&&!s)return!1;for(var d=u;d--;){var f=c[d];if(!(s?f in t:o.call(t,f)))return!1}var p=l.get(e),h=l.get(t);if(p&&h)return p==t&&h==e;var m=!0;l.set(e,t),l.set(t,e);for(var g=s;++d{var r=n(5970),o=n(6757),a=n(2865);e.exports=function(e){return a(o(e,void 0,r),e+"")}},4840:(e,t,n)=>{var r="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g;e.exports=r},2:(e,t,n)=>{var r=n(2199),o=n(4664),a=n(5950);e.exports=function(e){return r(e,a,o)}},7381:(e,t,n)=>{var r=n(8152),o=n(3950),a=r?function(e){return r.get(e)}:o;e.exports=a},2284:(e,t,n)=>{var r=n(4629),o=Object.prototype.hasOwnProperty;e.exports=function(e){for(var t=e.name+"",n=r[t],a=o.call(r,t)?n.length:0;a--;){var i=n[a],l=i.func;if(null==l||l==e)return i.name}return t}},1287:e=>{e.exports=function(e){return e.placeholder}},2651:(e,t,n)=>{var r=n(4218);e.exports=function(e,t){var n=e.__data__;return r(t)?n["string"==typeof t?"string":"hash"]:n.map}},776:(e,t,n)=>{var r=n(756),o=n(5950);e.exports=function(e){for(var t=o(e),n=t.length;n--;){var a=t[n],i=e[a];t[n]=[a,i,r(i)]}return t}},6110:(e,t,n)=>{var r=n(5083),o=n(392);e.exports=function(e,t){var n=o(e,t);return r(n)?n:void 0}},659:(e,t,n)=>{var r=n(1873),o=Object.prototype,a=o.hasOwnProperty,i=o.toString,l=r?r.toStringTag:void 0;e.exports=function(e){var t=a.call(e,l),n=e[l];try{e[l]=void 0;var r=!0}catch(e){}var o=i.call(e);return r&&(t?e[l]=n:delete e[l]),o}},4664:(e,t,n)=>{var r=n(9770),o=n(3345),a=Object.prototype.propertyIsEnumerable,i=Object.getOwnPropertySymbols,l=i?function(e){return null==e?[]:(e=Object(e),r(i(e),(function(t){return a.call(e,t)})))}:o;e.exports=l},5861:(e,t,n)=>{var r=n(5580),o=n(8223),a=n(2804),i=n(6545),l=n(8303),s=n(2552),c=n(7473),u="[object Map]",d="[object Promise]",f="[object Set]",p="[object WeakMap]",h="[object DataView]",m=c(r),g=c(o),b=c(a),y=c(i),v=c(l),w=s;(r&&w(new r(new ArrayBuffer(1)))!=h||o&&w(new o)!=u||a&&w(a.resolve())!=d||i&&w(new i)!=f||l&&w(new l)!=p)&&(w=function(e){var t=s(e),n="[object Object]"==t?e.constructor:void 0,r=n?c(n):"";if(r)switch(r){case m:return h;case g:return u;case b:return d;case y:return f;case v:return p}return t}),e.exports=w},392:e=>{e.exports=function(e,t){return null==e?void 0:e[t]}},5251:e=>{var t=/\{\n\/\* \[wrapped with (.+)\] \*/,n=/,? & /;e.exports=function(e){var r=e.match(t);return r?r[1].split(n):[]}},9326:(e,t,n)=>{var r=n(1769),o=n(2428),a=n(6449),i=n(361),l=n(294),s=n(7797);e.exports=function(e,t,n){for(var c=-1,u=(t=r(t,e)).length,d=!1;++c{var t=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;e.exports=function(e){return t.test(e)}},2032:(e,t,n)=>{var r=n(1042);e.exports=function(){this.__data__=r?r(null):{},this.size=0}},3862:e=>{e.exports=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}},6721:(e,t,n)=>{var r=n(1042),o=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;if(r){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return o.call(t,e)?t[e]:void 0}},2749:(e,t,n)=>{var r=n(1042),o=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;return r?void 0!==t[e]:o.call(t,e)}},5749:(e,t,n)=>{var r=n(1042);e.exports=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=r&&void 0===t?"__lodash_hash_undefined__":t,this}},2060:e=>{var t=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/;e.exports=function(e,n){var r=n.length;if(!r)return e;var o=r-1;return n[o]=(r>1?"& ":"")+n[o],n=n.join(r>2?", ":" "),e.replace(t,"{\n/* [wrapped with "+n+"] */\n")}},5891:(e,t,n)=>{var r=n(1873),o=n(2428),a=n(6449),i=r?r.isConcatSpreadable:void 0;e.exports=function(e){return a(e)||o(e)||!!(i&&e&&e[i])}},361:e=>{var t=/^(?:0|[1-9]\d*)$/;e.exports=function(e,n){var r=typeof e;return!!(n=null==n?9007199254740991:n)&&("number"==r||"symbol"!=r&&t.test(e))&&e>-1&&e%1==0&&e{var r=n(6449),o=n(4394),a=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,i=/^\w*$/;e.exports=function(e,t){if(r(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!o(e))||i.test(e)||!a.test(e)||null!=t&&e in Object(t)}},4218:e=>{e.exports=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}},5087:(e,t,n)=>{var r=n(980),o=n(7381),a=n(2284),i=n(3758);e.exports=function(e){var t=a(e),n=i[t];if("function"!=typeof n||!(t in r.prototype))return!1;if(e===n)return!0;var l=o(n);return!!l&&e===l[0]}},7296:(e,t,n)=>{var r,o=n(5481),a=(r=/[^.]+$/.exec(o&&o.keys&&o.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"";e.exports=function(e){return!!a&&a in e}},5527:e=>{var t=Object.prototype;e.exports=function(e){var n=e&&e.constructor;return e===("function"==typeof n&&n.prototype||t)}},756:(e,t,n)=>{var r=n(3805);e.exports=function(e){return e==e&&!r(e)}},3702:e=>{e.exports=function(){this.__data__=[],this.size=0}},80:(e,t,n)=>{var r=n(6025),o=Array.prototype.splice;e.exports=function(e){var t=this.__data__,n=r(t,e);return!(n<0||(n==t.length-1?t.pop():o.call(t,n,1),--this.size,0))}},4739:(e,t,n)=>{var r=n(6025);e.exports=function(e){var t=this.__data__,n=r(t,e);return n<0?void 0:t[n][1]}},1036:(e,t,n)=>{var r=n(6025);e.exports=function(e){return r(this.__data__,e)>-1}},1175:(e,t,n)=>{var r=n(6025);e.exports=function(e,t){var n=this.__data__,o=r(n,e);return o<0?(++this.size,n.push([e,t])):n[o][1]=t,this}},3040:(e,t,n)=>{var r=n(1549),o=n(79),a=n(8223);e.exports=function(){this.size=0,this.__data__={hash:new r,map:new(a||o),string:new r}}},7670:(e,t,n)=>{var r=n(2651);e.exports=function(e){var t=r(this,e).delete(e);return this.size-=t?1:0,t}},289:(e,t,n)=>{var r=n(2651);e.exports=function(e){return r(this,e).get(e)}},4509:(e,t,n)=>{var r=n(2651);e.exports=function(e){return r(this,e).has(e)}},2949:(e,t,n)=>{var r=n(2651);e.exports=function(e,t){var n=r(this,e),o=n.size;return n.set(e,t),this.size+=n.size==o?0:1,this}},317:e=>{e.exports=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n}},7197:e=>{e.exports=function(e,t){return function(n){return null!=n&&n[e]===t&&(void 0!==t||e in Object(n))}}},2224:(e,t,n)=>{var r=n(104);e.exports=function(e){var t=r(e,(function(e){return 500===n.size&&n.clear(),e})),n=t.cache;return t}},3209:(e,t,n)=>{var r=n(1596),o=n(3320),a=n(6306),i="__lodash_placeholder__",l=Math.min;e.exports=function(e,t){var n=e[1],s=t[1],c=n|s,u=c<131,d=128==s&&8==n||128==s&&256==n&&e[7].length<=t[8]||384==s&&t[7].length<=t[8]&&8==n;if(!u&&!d)return e;1&s&&(e[2]=t[2],c|=1&n?0:4);var f=t[3];if(f){var p=e[3];e[3]=p?r(p,f,t[4]):f,e[4]=p?a(e[3],i):t[4]}return(f=t[5])&&(p=e[5],e[5]=p?o(p,f,t[6]):f,e[6]=p?a(e[5],i):t[6]),(f=t[7])&&(e[7]=f),128&s&&(e[8]=null==e[8]?t[8]:l(e[8],t[8])),null==e[9]&&(e[9]=t[9]),e[0]=t[0],e[1]=c,e}},8152:(e,t,n)=>{var r=n(8303),o=r&&new r;e.exports=o},1042:(e,t,n)=>{var r=n(6110)(Object,"create");e.exports=r},3650:(e,t,n)=>{var r=n(4335)(Object.keys,Object);e.exports=r},6009:(e,t,n)=>{e=n.nmd(e);var r=n(4840),o=t&&!t.nodeType&&t,a=o&&e&&!e.nodeType&&e,i=a&&a.exports===o&&r.process,l=function(){try{return a&&a.require&&a.require("util").types||i&&i.binding&&i.binding("util")}catch(e){}}();e.exports=l},9350:e=>{var t=Object.prototype.toString;e.exports=function(e){return t.call(e)}},4335:e=>{e.exports=function(e,t){return function(n){return e(t(n))}}},6757:(e,t,n)=>{var r=n(1033),o=Math.max;e.exports=function(e,t,n){return t=o(void 0===t?e.length-1:t,0),function(){for(var a=arguments,i=-1,l=o(a.length-t,0),s=Array(l);++i{e.exports={}},8294:(e,t,n)=>{var r=n(3007),o=n(361),a=Math.min;e.exports=function(e,t){for(var n=e.length,i=a(t.length,n),l=r(e);i--;){var s=t[i];e[i]=o(s,n)?l[s]:void 0}return e}},6306:e=>{var t="__lodash_placeholder__";e.exports=function(e,n){for(var r=-1,o=e.length,a=0,i=[];++r{var r=n(4840),o="object"==typeof self&&self&&self.Object===Object&&self,a=r||o||Function("return this")();e.exports=a},1380:e=>{e.exports=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this}},1459:e=>{e.exports=function(e){return this.__data__.has(e)}},4641:(e,t,n)=>{var r=n(8882),o=n(1811)(r);e.exports=o},4247:e=>{e.exports=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n}},2865:(e,t,n)=>{var r=n(9570),o=n(1811)(r);e.exports=o},981:(e,t,n)=>{var r=n(5251),o=n(2060),a=n(2865),i=n(5948);e.exports=function(e,t,n){var l=t+"";return a(e,o(l,i(r(l),n)))}},1811:e=>{var t=Date.now;e.exports=function(e){var n=0,r=0;return function(){var o=t(),a=16-(o-r);if(r=o,a>0){if(++n>=800)return arguments[0]}else n=0;return e.apply(void 0,arguments)}}},1420:(e,t,n)=>{var r=n(79);e.exports=function(){this.__data__=new r,this.size=0}},938:e=>{e.exports=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}},3605:e=>{e.exports=function(e){return this.__data__.get(e)}},9817:e=>{e.exports=function(e){return this.__data__.has(e)}},945:(e,t,n)=>{var r=n(79),o=n(8223),a=n(3661);e.exports=function(e,t){var n=this.__data__;if(n instanceof r){var i=n.__data__;if(!o||i.length<199)return i.push([e,t]),this.size=++n.size,this;n=this.__data__=new a(i)}return n.set(e,t),this.size=n.size,this}},6959:e=>{e.exports=function(e,t,n){for(var r=n-1,o=e.length;++r{var r=n(2224),o=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,a=/\\(\\)?/g,i=r((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(o,(function(e,n,r,o){t.push(r?o.replace(a,"$1"):n||e)})),t}));e.exports=i},7797:(e,t,n)=>{var r=n(4394);e.exports=function(e){if("string"==typeof e||r(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}},7473:e=>{var t=Function.prototype.toString;e.exports=function(e){if(null!=e){try{return t.call(e)}catch(e){}try{return e+""}catch(e){}}return""}},1800:e=>{var t=/\s/;e.exports=function(e){for(var n=e.length;n--&&t.test(e.charAt(n)););return n}},2225:e=>{var t="\\ud800-\\udfff",n="\\u2700-\\u27bf",r="a-z\\xdf-\\xf6\\xf8-\\xff",o="A-Z\\xc0-\\xd6\\xd8-\\xde",a="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",i="["+a+"]",l="\\d+",s="["+n+"]",c="["+r+"]",u="[^"+t+a+l+n+r+o+"]",d="(?:\\ud83c[\\udde6-\\uddff]){2}",f="[\\ud800-\\udbff][\\udc00-\\udfff]",p="["+o+"]",h="(?:"+c+"|"+u+")",m="(?:"+p+"|"+u+")",g="(?:['’](?:d|ll|m|re|s|t|ve))?",b="(?:['’](?:D|LL|M|RE|S|T|VE))?",y="(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?",v="[\\ufe0e\\ufe0f]?",w=v+y+"(?:\\u200d(?:"+["[^"+t+"]",d,f].join("|")+")"+v+y+")*",_="(?:"+[s,d,f].join("|")+")"+w,E=RegExp([p+"?"+c+"+"+g+"(?="+[i,p,"$"].join("|")+")",m+"+"+b+"(?="+[i,p+h,"$"].join("|")+")",p+"?"+h+"+"+g,p+"+"+b,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",l,_].join("|"),"g");e.exports=function(e){return e.match(E)||[]}},5948:(e,t,n)=>{var r=n(3729),o=n(5325),a=[["ary",128],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",32],["partialRight",64],["rearg",256]];e.exports=function(e,t){return r(a,(function(n){var r="_."+n[0];t&n[1]&&!o(e,r)&&e.push(r)})),e.sort()}},257:(e,t,n)=>{var r=n(980),o=n(6017),a=n(3007);e.exports=function(e){if(e instanceof r)return e.clone();var t=new o(e.__wrapped__,e.__chain__);return t.__actions__=a(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t}},7334:e=>{e.exports=function(e){return function(){return e}}},828:(e,t,n)=>{var r=n(4647),o=n(3222),a=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,i=RegExp("[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]","g");e.exports=function(e){return(e=o(e))&&e.replace(a,r).replace(i,"")}},4889:(e,t,n)=>{var r=n(3915),o=n(3120),a=n(9302),i=n(3693),l=n(8090),s=a((function(e,t){var n=l(t);return i(n)&&(n=void 0),i(e)?r(e,o(t,1,i,!0),void 0,n):[]}));e.exports=s},5288:e=>{e.exports=function(e,t){return e===t||e!=e&&t!=t}},7612:(e,t,n)=>{var r=n(9770),o=n(6574),a=n(5389),i=n(6449);e.exports=function(e,t){return(i(e)?r:o)(e,a(t,3))}},7309:(e,t,n)=>{var r=n(2006)(n(4713));e.exports=r},4713:(e,t,n)=>{var r=n(2523),o=n(5389),a=n(1489),i=Math.max;e.exports=function(e,t,n){var l=null==e?0:e.length;if(!l)return-1;var s=null==n?0:a(n);return s<0&&(s=i(l+s,0)),r(e,o(t,3),s)}},5970:(e,t,n)=>{var r=n(3120);e.exports=function(e){return null!=e&&e.length?r(e,1):[]}},9870:(e,t,n)=>{var r=n(6929)();e.exports=r},8156:(e,t,n)=>{var r=n(7422);e.exports=function(e,t,n){var o=null==e?void 0:r(e,t);return void 0===o?n:o}},2013:(e,t,n)=>{var r=n(3360),o=n(2e3),a=Object.prototype.hasOwnProperty,i=o((function(e,t,n){a.call(e,n)?e[n].push(t):r(e,n,[t])}));e.exports=i},631:(e,t,n)=>{var r=n(8077),o=n(9326);e.exports=function(e,t){return null!=e&&o(e,t,r)}},3488:e=>{e.exports=function(e){return e}},2428:(e,t,n)=>{var r=n(7534),o=n(346),a=Object.prototype,i=a.hasOwnProperty,l=a.propertyIsEnumerable,s=r(function(){return arguments}())?r:function(e){return o(e)&&i.call(e,"callee")&&!l.call(e,"callee")};e.exports=s},6449:e=>{var t=Array.isArray;e.exports=t},4894:(e,t,n)=>{var r=n(1882),o=n(294);e.exports=function(e){return null!=e&&o(e.length)&&!r(e)}},3693:(e,t,n)=>{var r=n(4894),o=n(346);e.exports=function(e){return o(e)&&r(e)}},3656:(e,t,n)=>{e=n.nmd(e);var r=n(9325),o=n(9935),a=t&&!t.nodeType&&t,i=a&&e&&!e.nodeType&&e,l=i&&i.exports===a?r.Buffer:void 0,s=(l?l.isBuffer:void 0)||o;e.exports=s},2193:(e,t,n)=>{var r=n(8984),o=n(5861),a=n(2428),i=n(6449),l=n(4894),s=n(3656),c=n(5527),u=n(7167),d=Object.prototype.hasOwnProperty;e.exports=function(e){if(null==e)return!0;if(l(e)&&(i(e)||"string"==typeof e||"function"==typeof e.splice||s(e)||u(e)||a(e)))return!e.length;var t=o(e);if("[object Map]"==t||"[object Set]"==t)return!e.size;if(c(e))return!r(e).length;for(var n in e)if(d.call(e,n))return!1;return!0}},1882:(e,t,n)=>{var r=n(2552),o=n(3805);e.exports=function(e){if(!o(e))return!1;var t=r(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}},294:e=>{e.exports=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991}},3805:e=>{e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},346:e=>{e.exports=function(e){return null!=e&&"object"==typeof e}},4394:(e,t,n)=>{var r=n(2552),o=n(346);e.exports=function(e){return"symbol"==typeof e||o(e)&&"[object Symbol]"==r(e)}},7167:(e,t,n)=>{var r=n(4901),o=n(7301),a=n(6009),i=a&&a.isTypedArray,l=i?o(i):r;e.exports=l},5950:(e,t,n)=>{var r=n(695),o=n(8984),a=n(4894);e.exports=function(e){return a(e)?r(e):o(e)}},8090:e=>{e.exports=function(e){var t=null==e?0:e.length;return t?e[t-1]:void 0}},5378:(e,t,n)=>{var r=n(4932),o=n(5389),a=n(5128),i=n(6449);e.exports=function(e,t){return(i(e)?r:a)(e,o(t,3))}},104:(e,t,n)=>{var r=n(3661);function o(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var r=arguments,o=t?t.apply(this,r):r[0],a=n.cache;if(a.has(o))return a.get(o);var i=e.apply(this,r);return n.cache=a.set(o,i)||a,i};return n.cache=new(o.Cache||r),n}o.Cache=r,e.exports=o},3950:e=>{e.exports=function(){}},2877:(e,t,n)=>{var r=n(6155),o=n(6449);e.exports=function(e,t,n,a){return null==e?[]:(o(t)||(t=null==t?[]:[t]),o(n=a?void 0:n)||(n=null==n?[]:[n]),r(e,t,n))}},9181:(e,t,n)=>{var r=n(9302),o=n(6977),a=n(1287),i=n(6306),l=r((function(e,t){var n=i(t,a(l));return o(e,32,void 0,t,n)}));l.placeholder={},e.exports=l},583:(e,t,n)=>{var r=n(7237),o=n(7255),a=n(8586),i=n(7797);e.exports=function(e){return a(e)?r(i(e)):o(e)}},3345:e=>{e.exports=function(){return[]}},9935:e=>{e.exports=function(){return!1}},7400:(e,t,n)=>{var r=n(9374),o=1/0;e.exports=function(e){return e?(e=r(e))===o||e===-1/0?17976931348623157e292*(e<0?-1:1):e==e?e:0:0===e?e:0}},1489:(e,t,n)=>{var r=n(7400);e.exports=function(e){var t=r(e),n=t%1;return t==t?n?t-n:t:0}},9374:(e,t,n)=>{var r=n(4128),o=n(3805),a=n(4394),i=/^[-+]0x[0-9a-f]+$/i,l=/^0b[01]+$/i,s=/^0o[0-7]+$/i,c=parseInt;e.exports=function(e){if("number"==typeof e)return e;if(a(e))return NaN;if(o(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=o(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=r(e);var n=l.test(e);return n||s.test(e)?c(e.slice(2),n?2:8):i.test(e)?NaN:+e}},3222:(e,t,n)=>{var r=n(7556);e.exports=function(e){return null==e?"":r(e)}},6645:(e,t,n)=>{var r=n(1733),o=n(5434),a=n(3222),i=n(2225);e.exports=function(e,t,n){return e=a(e),void 0===(t=n?void 0:t)?o(e)?i(e):r(e):e.match(t)||[]}},3758:(e,t,n)=>{var r=n(980),o=n(6017),a=n(4033),i=n(6449),l=n(346),s=n(257),c=Object.prototype.hasOwnProperty;function u(e){if(l(e)&&!i(e)&&!(e instanceof r)){if(e instanceof o)return e;if(c.call(e,"__wrapped__"))return s(e)}return new o(e)}u.prototype=a.prototype,u.prototype.constructor=u,e.exports=u},814:(e,t,n)=>{"use strict";e.exports=n(3258)},3258:e=>{"use strict";var t,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,o=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,i={};((e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})})(i,{defaultOptions:()=>m,numericQuantity:()=>y,numericRegex:()=>s,numericRegexWithTrailingInvalid:()=>c,parseRomanNumerals:()=>g,romanNumeralRegex:()=>h,romanNumeralUnicodeRegex:()=>p,romanNumeralUnicodeToAsciiMap:()=>f,romanNumeralValues:()=>d,vulgarFractionToAsciiMap:()=>l,vulgarFractionsRegex:()=>u}),e.exports=(t=i,((e,t,i,l)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of o(t))!a.call(e,i)&&undefined!==i&&n(e,i,{get:()=>t[i],enumerable:!(l=r(t,i))||l.enumerable});return e})(n({},"__esModule",{value:!0}),t));var l={"¼":"1/4","½":"1/2","¾":"3/4","⅐":"1/7","⅑":"1/9","⅒":"1/10","⅓":"1/3","⅔":"2/3","⅕":"1/5","⅖":"2/5","⅗":"3/5","⅘":"4/5","⅙":"1/6","⅚":"5/6","⅛":"1/8","⅜":"3/8","⅝":"5/8","⅞":"7/8","⅟":"1/"},s=/^(?=-?\s*\.\d|-?\s*\d)(-)?\s*((?:\d(?:[\d,_]*\d)?)*)(([eE][+-]?\d(?:[\d,_]*\d)?)?|\.\d(?:[\d,_]*\d)?([eE][+-]?\d(?:[\d,_]*\d)?)?|(\s+\d(?:[\d,_]*\d)?\s*)?\s*\/\s*\d(?:[\d,_]*\d)?)?$/,c=new RegExp(s.source.replace(/\$$/,"(?:\\s*[^\\.\\d\\/].*)?")),u=new RegExp(`(${Object.keys(l).join("|")})`),d={MMM:3e3,MM:2e3,M:1e3,CM:900,DCCC:800,DCC:700,DC:600,D:500,CD:400,CCC:300,CC:200,C:100,XC:90,LXXX:80,LXX:70,LX:60,L:50,XL:40,XXX:30,XX:20,XII:12,XI:11,X:10,IX:9,VIII:8,VII:7,VI:6,V:5,IV:4,III:3,II:2,I:1},f={Ⅰ:"I",Ⅱ:"II",Ⅲ:"III",Ⅳ:"IV",Ⅴ:"V",Ⅵ:"VI",Ⅶ:"VII",Ⅷ:"VIII",Ⅸ:"IX",Ⅹ:"X",Ⅺ:"XI",Ⅻ:"XII",Ⅼ:"L",Ⅽ:"C",Ⅾ:"D",Ⅿ:"M",ⅰ:"I",ⅱ:"II",ⅲ:"III",ⅳ:"IV",ⅴ:"V",ⅵ:"VI",ⅶ:"VII",ⅷ:"VIII",ⅸ:"IX",ⅹ:"X",ⅺ:"XI",ⅻ:"XII",ⅼ:"L",ⅽ:"C",ⅾ:"D",ⅿ:"M"},p=new RegExp(`(${Object.keys(f).join("|")})`,"gi"),h=/^(?=[MDCLXVI])(M{0,3})(C[MD]|D?C{0,3})(X[CL]|L?X{0,3})(I[XV]|V?I{0,3})$/i,m={round:3,allowTrailingInvalid:!1,romanNumerals:!1},g=e=>{let t=`${e}`.replace(p,((e,t)=>f[t])).toUpperCase(),n=h.exec(t);if(!n)return NaN;let[,r,o,a,i]=n;return(d[r]??0)+(d[o]??0)+(d[a]??0)+(d[i]??0)},b=/^\s*\//,y=(e,t=m)=>{if("number"==typeof e||"bigint"==typeof e)return e;let n=NaN,r=`${e}`.replace(u,((e,t)=>` ${l[t]}`)).replace("⁄","/").trim();if(0===r.length)return NaN;let o={...m,...t},a=(o.allowTrailingInvalid?c:s).exec(r);if(!a)return o.romanNumerals?g(r):NaN;let[,i,d,f]=a,p=d.replace(/[,_]/g,""),h=null==f?void 0:f.replace(/[,_]/g,"");if(n=!p&&h&&h.startsWith(".")?0:parseInt(p),!h)return i?-1*n:n;let y=!1===o.round?NaN:parseFloat(`1e${Math.floor(Math.max(0,o.round))}`);if(h.startsWith(".")||h.startsWith("e")||h.startsWith("E")){let e=parseFloat(`${n}${h}`);n=isNaN(y)?e:Math.round(e*y)/y}else if(b.test(h)){let e=parseInt(p),t=parseInt(h.replace("/",""));n=isNaN(y)?e/t:Math.round(e*y/t)/y}else{let e=h.split("/"),[t,r]=e.map((e=>parseInt(e)));n+=isNaN(y)?t/r:Math.round(t*y/r)/y}return i?-1*n:n}},5338:(e,t,n)=>{"use strict";var r=n(5206);t.H=r.createRoot,r.hydrateRoot},840:(e,t,n)=>{"use strict";var r,o=Object.defineProperty,a=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,l=Object.prototype.hasOwnProperty,s={};((e,t)=>{for(var n in t)o(e,n,{get:t[n],enumerable:!0})})(s,{parseJsonLogic:()=>X}),e.exports=(r=s,((e,t,n,r)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let n of i(t))l.call(e,n)||undefined===n||o(e,n,{get:()=>t[n],enumerable:!(r=a(t,n))||r.enumerable});return e})(o({},"__esModule",{value:!0}),r));var c={"=":"!=","!=":"=","<":">=","<=":">",">":"<=",">=":"<",beginsWith:"doesNotBeginWith",doesNotBeginWith:"beginsWith",endsWith:"doesNotEndWith",doesNotEndWith:"endsWith",contains:"doesNotContain",doesNotContain:"contains",between:"notBetween",notBetween:"between",in:"notIn",notIn:"in",notNull:"null",null:"notNull"},u=(e,t=",")=>e.map((e=>`${e??""}`.replaceAll(t[0],`\\${t[0]}`))).join(t),d=n(814),f=(new RegExp(d.numericRegex.source.replace(/^\^/,String.raw`^\s*`).replace(/\$$/,String.raw`\s*$`)),e=>null!==e&&"object"==typeof e&&Object.getPrototypeOf(e)===Object.prototype),p=e=>f(e)&&Array.isArray(e.rules),h=e=>p(e)&&"string"==typeof e.combinator,m=e=>{if((e=>p(e)&&void 0===e.combinator)(e))return e;const{combinator:t,...n}=e,r=[],{length:o}=e.rules;for(const[n,a]of e.rules.entries())p(a)?r.push(m(a)):r.push(a),t&&nf(e)&&"name"in e&&"string"==typeof e.name,v=e=>f(e)&&"value"in e&&"string"==typeof e.value;function w(e,t){return(0,b.produce)((e=>{const n={};let r=!!t;if(y(e)&&!v(e)?(n.value=e.name,r=!0):!y(e)&&v(e)&&(n.name=e.value,r=!0),r)return Object.assign({},t,e,n)}))(e)}var _=e=>{if(Array.isArray(e))for(const t of e)if(f(t)&&"options"in t)for(const e of t.options)return!(!f(e)||!("name"in e)&&!("value"in e));return!1},E=(e,t,n)=>{const r=w(e),o=w(n);return r.value!==o.value&&("string"==typeof r.comparator?r[r.comparator]===o[r.comparator]:r.comparator?.(o,t)??!1)},S=(e,t,n)=>{if(!e.comparator){const n=t=>(t.value??t.name)!==(e.value??e.name);return _(t)?t.map((e=>({...e,options:e.options.filter((e=>n(e)))}))):t.filter((e=>n(e)))}return _(t)?t.map((t=>({...t,options:t.options.filter((t=>E(e,n,t)))}))).filter((e=>e.options.length>0)):t.filter((t=>E(e,n,t)))},x=["value"],k={name:"name",value:"name",valueSources:null,label:"label"},R=(e,t,n)=>{const r=e?w(e):k;if(r.valueSources)return"function"==typeof r.valueSources?r.valueSources(t):r.valueSources;if(n){const e=n(r.value,t,{fieldData:w(r)});if(e)return e}return x},C=e=>{const t=e?Array.isArray(e)?e:Object.keys(e).map((t=>({...e[t],name:t}))).sort(((e,t)=>e.label.localeCompare(t.label))):[];return(e=>{const t=new Set,n=[];for(const r of e)t.has(r.value??r.name)||(t.add(r.value??r.name),n.push(r));return e.length===n.length?e:n})((e=>Array.isArray(e)&&e.length>0&&f(e[0])&&"options"in e[0]&&Array.isArray(e[0].options))(n=t)?n.flatMap((e=>e.options)):n);var n},N=e=>(e=>f(e)&&"var"in e)(e)&&"string"==typeof e.var,O=e=>f(e)&&"=="in e,A=e=>f(e)&&"==="in e,P=e=>f(e)&&"!="in e,D=e=>f(e)&&"!=="in e,T=e=>f(e)&&"!"in e,I=e=>f(e)&&"!!"in e,j=e=>f(e)&&"or"in e,M=e=>f(e)&&"and"in e,$=e=>f(e)&&">"in e,L=e=>f(e)&&">="in e,F=e=>f(e)&&"<"in e&&2===e["<"].length,z=e=>f(e)&&"<="in e&&2===e["<="].length,W=e=>f(e)&&"in"in e&&Array.isArray(e.in[1]),G=e=>f(e)&&"in"in e&&!Array.isArray(e.in[1]),B=e=>f(e)&&"<"in e&&Array.isArray(e["<"])&&3===e["<"].length,V=e=>f(e)&&"<="in e&&Array.isArray(e["<="])&&3===e["<="].length,H=e=>f(e)&&"startsWith"in e,U=e=>f(e)&&"endsWith"in e,q={combinator:"and",rules:[]};function X(e,t={}){const n=C(t.fields),{getValueSources:r,listsAsArrays:o,jsonLogicOperations:a}=t,i=(e,t,o)=>function(e){const{fieldsFlat:t,fieldName:n,operator:r,subordinateFieldName:o,getValueSources:a}=e;if(0===t.length)return!0;let i=!1;const l=w(t.find((e=>e.name===n)));return l&&(i=!(!o&&"notNull"!==r&&"null"!==r&&!R(l,r,a).includes("value")),i&&o)&&(R(l,r,a).includes("field")&&n!==o&&S(l,t,r).some((e=>e.name===o))||(i=!1)),i}({fieldName:e,fieldsFlat:n,operator:t,subordinateFieldName:o,getValueSources:r});let l=e;if("string"==typeof e)try{l=JSON.parse(e)}catch{return q}const s=function e(t,n){if(n&&!f(t))return!1;const[r,l]=Object.entries(t)?.[0]??[];if(a&&g(a).includes(r)){const e=a[r](l);return!!e&&(n&&!p(e)?{combinator:"and",rules:[e]}:e)}if(M(t))return{combinator:"and",rules:t.and.map((t=>e(t))).filter(Boolean)};if(j(t))return{combinator:"or",rules:t.or.map((t=>e(t))).filter(Boolean)};if(T(t)){const r=e(t["!"]);if(r){if(!(h(r)||"between"!==r.operator&&"in"!==r.operator&&"contains"!==r.operator&&"beginsWith"!==r.operator&&"endsWith"!==r.operator)){const e={...r,operator:c[r.operator]};return n?{combinator:"and",rules:[e]}:e}return B(t["!"])||h(r)?{...r,not:!0}:{combinator:"and",rules:[r],not:!0}}return!1}if(I(t))return e(t["!!"])||!1;let s,d=!1,m="",b="=",y="";if(O(t)||A(t)||P(t)||D(t)||$(t)||L(t)||F(t)||z(t)||G(t)||H(t)||U(t)){const[e,n]=l;if(N(e)&&!f(n))m=e.var,y=n;else if(!f(e)&&N(n))m=n.var,y=e;else{if(!N(e)||!N(n))return!1;m=e.var,y=n.var,s="field"}b=O(t)||A(t)?null===y?"null":"=":P(t)||D(t)?null===y?"notNull":"!=":G(t)?"contains":H(t)?"beginsWith":U(t)?"endsWith":r,i(m,b,"field"===s?y:void 0)&&(d={field:m,operator:b,value:y,valueSource:s})}else if(B(t)&&N(t["<"][1])){m=t["<"][1].var;const n=[t["<"][0],t["<"][2]];if(n.every((e=>N(e)))||n.every((e=>"string"==typeof e))||n.every((e=>"number"==typeof e))||n.every((e=>"boolean"==typeof e)))return e({and:[{">":[{var:m},n[0]]},{"<":[{var:m},n[1]]}]})||!1}else if(V(t)&&N(t["<="][1])){m=t["<="][1].var,b="between";const e=[t["<="][0],t["<="][2]];if(t["<="].every((e=>N(e)))){s="field";const t=e.map((e=>e.var)).filter((e=>i(m,b,e)));y=o?t:u(t,",")}else(e.every((e=>"string"==typeof e))||e.every((e=>"number"==typeof e))||e.every((e=>"boolean"==typeof e)))&&(y=o?e:u(e.map((e=>`${e}`)),","));i(m,b)&&y.length>=2&&(d={field:m,operator:b,value:y,valueSource:s})}else if(W(t)&&N(l[0])){if(m=l[0].var,b="in",t.in[1].every((e=>N(e)))){s="field";const e=t.in[1].map((e=>e.var)).filter((e=>i(m,b,e)));y=o?e:u(e,",")}else(t.in[1].every((e=>"string"==typeof e))||t.in[1].every((e=>"number"==typeof e))||t.in[1].every((e=>"boolean"==typeof e)))&&(y=o?t.in[1]:u(t.in[1].map((e=>`${e}`)),","));y.length>0&&(d={field:m,operator:b,value:y,valueSource:s})}return!!d&&(n?{combinator:"and",rules:[d]}:d)}(l,!0)||q;return t.independentCombinators?m(s):s}},1020:(e,t,n)=>{"use strict";var r=n(1594),o=Symbol.for("react.element"),a=Symbol.for("react.fragment"),i=Object.prototype.hasOwnProperty,l=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,s={key:!0,ref:!0,__self:!0,__source:!0};function c(e,t,n){var r,a={},c=null,u=null;for(r in void 0!==n&&(c=""+n),void 0!==t.key&&(c=""+t.key),void 0!==t.ref&&(u=t.ref),t)i.call(t,r)&&!s.hasOwnProperty(r)&&(a[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps)void 0===a[r]&&(a[r]=t[r]);return{$$typeof:o,type:e,key:c,ref:u,props:a,_owner:l.current}}t.Fragment=a,t.jsx=c,t.jsxs=c},4848:(e,t,n)=>{"use strict";e.exports=n(1020)},8939:(e,t,n)=>{var r,o;void 0===(o="function"==typeof(r=function(){"use strict";var e,t,r,o,a,i,l,s,c="undefined"!=typeof window?window:null!=typeof n.g?n.g:this||{},u=c.cancelRequestAnimationFrame&&c.requestAnimationFrame||setTimeout,d=c.cancelRequestAnimationFrame||clearTimeout,f=[],p=0,h=!1,m=7,g=35,b=125,y=0,v=0,w=0,_={get didTimeout(){return!1},timeRemaining:function(){var e=m-(Date.now()-v);return e<0?0:e}},E=(a=function(){m=22,b=66,g=0},s=function(){var e=Date.now()-l;e<99?i=setTimeout(s,99-e):(i=null,a())},function(){l=Date.now(),i||(i=setTimeout(s,99))});function S(){125!=b&&(m=7,b=125,g=35,h&&(h&&(o&&d(o),r&&clearTimeout(r),h=!1),R())),E()}function x(){o=null,r=setTimeout(C,0)}function k(){r=null,u(x)}function R(){h||(t=b-(Date.now()-v),e=Date.now(),h=!0,g&&t9?r=setTimeout(k,t):(t=0,k()))}function C(){var n,o,a,i=m>9?9:1;if(v=Date.now(),h=!1,r=null,p>2||v-t-50i;o++)n=f.shift(),w++,n&&n(_);f.length?R():p=0}function N(e){return y++,f.push(e),R(),y}function O(e){var t=e-1-w;f[t]&&(f[t]=null)}if(c.requestIdleCallback&&c.cancelIdleCallback)try{c.requestIdleCallback((function(){}),{timeout:0})}catch(e){!function(e){var t,n;if(c.requestIdleCallback=function(t,n){return n&&"number"==typeof n.timeout?e(t,n.timeout):e(t)},c.IdleCallbackDeadline&&(t=IdleCallbackDeadline.prototype)){if(!(n=Object.getOwnPropertyDescriptor(t,"timeRemaining"))||!n.configurable||!n.get)return;Object.defineProperty(t,"timeRemaining",{value:function(){return n.get.call(this)},enumerable:!0,configurable:!0})}}(c.requestIdleCallback)}else c.requestIdleCallback=N,c.cancelIdleCallback=O,c.document&&document.addEventListener&&(c.addEventListener("scroll",S,!0),c.addEventListener("resize",S),document.addEventListener("focus",S,!0),document.addEventListener("mouseover",S,!0),["click","keypress","touchstart","mousedown"].forEach((function(e){document.addEventListener(e,S,{capture:!0,passive:!0})})),c.MutationObserver&&new MutationObserver(S).observe(document.documentElement,{childList:!0,subtree:!0,attributes:!0}));return{request:N,cancel:O}})?r.apply(t,[]):r)||(e.exports=o)},9922:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>b});var r=n(5072),o=n.n(r),a=n(7825),i=n.n(a),l=n(7659),s=n.n(l),c=n(5056),u=n.n(c),d=n(540),f=n.n(d),p=n(1113),h=n.n(p),m=n(1461),g={};g.styleTagTransform=h(),g.setAttributes=u(),g.insert=s().bind(null,"head"),g.domAPI=i(),g.insertStyleElement=f(),o()(m.A,g);const b=m.A&&m.A.locals?m.A.locals:void 0},5072:e=>{"use strict";var t=[];function n(e){for(var n=-1,r=0;r{"use strict";var t={};e.exports=function(e,n){var r=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}},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}},5056:(e,t,n)=>{"use strict";e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},7825:e=>{"use strict";e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var r="";n.supports&&(r+="@supports (".concat(n.supports,") {")),n.media&&(r+="@media ".concat(n.media," {"));var o=void 0!==n.layer;o&&(r+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),r+=n.css,o&&(r+="}"),n.media&&(r+="}"),n.supports&&(r+="}");var a=n.sourceMap;a&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(a))))," */")),t.styleTagTransform(r,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},1113: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))}}},1063:(e,t,n)=>{"use strict";var r=n(1594),o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},a=r.useState,i=r.useEffect,l=r.useLayoutEffect,s=r.useDebugValue;function c(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!o(e,n)}catch(e){return!0}}var u="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var n=t(),r=a({inst:{value:n,getSnapshot:t}}),o=r[0].inst,u=r[1];return l((function(){o.value=n,o.getSnapshot=t,c(o)&&u({inst:o})}),[e,n,t]),i((function(){return c(o)&&u({inst:o}),e((function(){c(o)&&u({inst:o})}))}),[e]),s(n),n};t.useSyncExternalStore=void 0!==r.useSyncExternalStore?r.useSyncExternalStore:u},8940:(e,t,n)=>{"use strict";var r=n(1594),o=n(9888),a="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},i=o.useSyncExternalStore,l=r.useRef,s=r.useEffect,c=r.useMemo,u=r.useDebugValue;t.useSyncExternalStoreWithSelector=function(e,t,n,r,o){var d=l(null);if(null===d.current){var f={hasValue:!1,value:null};d.current=f}else f=d.current;d=c((function(){function e(e){if(!s){if(s=!0,i=e,e=r(e),void 0!==o&&f.hasValue){var t=f.value;if(o(t,e))return l=t}return l=e}if(t=l,a(i,e))return t;var n=r(e);return void 0!==o&&o(t,n)?t:(i=e,l=n)}var i,l,s=!1,c=void 0===n?null:n;return[function(){return e(t())},null===c?void 0:function(){return e(c())}]}),[t,n,r,o]);var p=i(e,d[0],d[1]);return s((function(){f.hasValue=!0,f.value=p}),[p]),u(p),p}},7154:(e,t,n)=>{"use strict";var r=n(1594),o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},a=r.useSyncExternalStore,i=r.useRef,l=r.useEffect,s=r.useMemo,c=r.useDebugValue;t.useSyncExternalStoreWithSelector=function(e,t,n,r,u){var d=i(null);if(null===d.current){var f={hasValue:!1,value:null};d.current=f}else f=d.current;d=s((function(){function e(e){if(!l){if(l=!0,a=e,e=r(e),void 0!==u&&f.hasValue){var t=f.value;if(u(t,e))return i=t}return i=e}if(t=i,o(a,e))return t;var n=r(e);return void 0!==u&&u(t,n)?t:(a=e,i=n)}var a,i,l=!1,s=void 0===n?null:n;return[function(){return e(t())},null===s?void 0:function(){return e(s())}]}),[t,n,r,u]);var p=a(e,d[0],d[1]);return l((function(){f.hasValue=!0,f.value=p}),[p]),c(p),p}},9888:(e,t,n)=>{"use strict";e.exports=n(1063)},9242:(e,t,n)=>{"use strict";e.exports=n(8940)},8418:(e,t,n)=>{"use strict";e.exports=n(7154)},6255:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var n,r;(0,o.default)(e),"object"===a(t)?(n=t.min||0,r=t.max):(n=arguments[1],r=arguments[2]);var i=encodeURI(e).split(/%..|./).length-1;return i>=n&&(void 0===r||i<=r)};var r,o=(r=n(3399))&&r.__esModule?r:{default:r};function a(e){return a="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},a(e)}e.exports=t.default,e.exports.default=t.default},9517:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if((0,r.default)(e),(t=(0,l.default)(t,c)).require_display_name||t.allow_display_name){var n=e.match(u);if(n){var s=n[1];if(e=e.replace(s,"").replace(/(^<|>$)/g,""),s.endsWith(" ")&&(s=s.slice(0,-1)),!function(e){var t=e.replace(/^"(.+)"$/,"$1");if(!t.trim())return!1;if(/[\.";<>]/.test(t)){if(t===e)return!1;if(t.split('"').length!==t.split('\\"').length)return!1}return!0}(s))return!1}else if(t.require_display_name)return!1}if(!t.ignore_max_length&&e.length>g)return!1;var b=e.split("@"),y=b.pop(),v=y.toLowerCase();if(t.host_blacklist.includes(v))return!1;if(t.host_whitelist.length>0&&!t.host_whitelist.includes(v))return!1;var w=b.join("@");if(t.domain_specific_validation&&("gmail.com"===v||"googlemail.com"===v)){var _=(w=w.toLowerCase()).split("+")[0];if(!(0,o.default)(_.replace(/\./g,""),{min:6,max:30}))return!1;for(var E=_.split("."),S=0;S{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){(0,r.default)(e),(t=(0,o.default)(t,i)).allow_trailing_dot&&"."===e[e.length-1]&&(e=e.substring(0,e.length-1)),!0===t.allow_wildcard&&0===e.indexOf("*.")&&(e=e.substring(2));var n=e.split("."),a=n[n.length-1];if(t.require_tld){if(n.length<2)return!1;if(!t.allow_numeric_tld&&!/^([a-z\u00A1-\u00A8\u00AA-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]{2,}|xn[a-z0-9-]{2,})$/i.test(a))return!1;if(/\s/.test(a))return!1}return!(!t.allow_numeric_tld&&/^\d+$/.test(a))&&n.every((function(e){return!(e.length>63&&!t.ignore_max_length||!/^[a-z_\u00a1-\uffff0-9-]+$/i.test(e)||/[\uff01-\uff5e]/.test(e)||/^-|-$/.test(e)||!t.allow_underscores&&/_/.test(e))}))};var r=a(n(3399)),o=a(n(3610));function a(e){return e&&e.__esModule?e:{default:e}}var i={require_tld:!0,allow_underscores:!1,allow_trailing_dot:!1,allow_numeric_tld:!1,allow_wildcard:!1,ignore_max_length:!1};e.exports=t.default,e.exports.default=t.default},5372:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return(0,o.default)(t),(n=String(n))?"4"===n?l.test(t):"6"===n&&c.test(t):e(t,4)||e(t,6)};var r,o=(r=n(3399))&&r.__esModule?r:{default:r},a="(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])",i="(".concat(a,"[.]){3}").concat(a),l=new RegExp("^".concat(i,"$")),s="(?:[0-9a-fA-F]{1,4})",c=new RegExp("^("+"(?:".concat(s,":){7}(?:").concat(s,"|:)|")+"(?:".concat(s,":){6}(?:").concat(i,"|:").concat(s,"|:)|")+"(?:".concat(s,":){5}(?::").concat(i,"|(:").concat(s,"){1,2}|:)|")+"(?:".concat(s,":){4}(?:(:").concat(s,"){0,1}:").concat(i,"|(:").concat(s,"){1,3}|:)|")+"(?:".concat(s,":){3}(?:(:").concat(s,"){0,2}:").concat(i,"|(:").concat(s,"){1,4}|:)|")+"(?:".concat(s,":){2}(?:(:").concat(s,"){0,3}:").concat(i,"|(:").concat(s,"){1,5}|:)|")+"(?:".concat(s,":){1}(?:(:").concat(s,"){0,4}:").concat(i,"|(:").concat(s,"){1,6}|:)|")+"(?::((?::".concat(s,"){0,5}:").concat(i,"|(?::").concat(s,"){1,7}|:))")+")(%[0-9a-zA-Z-.:]{1,})?$");e.exports=t.default,e.exports.default=t.default},6084:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){(0,o.default)(e);var n=!1===(t=t||{}).allow_leading_zeroes?a:i,r=!t.hasOwnProperty("min")||e>=t.min,l=!t.hasOwnProperty("max")||e<=t.max,s=!t.hasOwnProperty("lt")||et.gt;return n.test(e)&&r&&l&&s&&c};var r,o=(r=n(3399))&&r.__esModule?r:{default:r},a=/^(?:[-+]?(?:0|[1-9][0-9]*))$/,i=/^[-+]?[0-9]+$/;e.exports=t.default,e.exports.default=t.default},3399:(e,t)=>{"use strict";function n(e){return n="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},n(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){if(!("string"==typeof e||e instanceof String)){var t=n(e);throw null===e?t="null":"object"===t&&(t=e.constructor.name),new TypeError("Expected a string but received a ".concat(t))}},e.exports=t.default,e.exports.default=t.default},3610:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;for(var n in t)void 0===e[n]&&(e[n]=t[n]);return e},e.exports=t.default,e.exports.default=t.default},1594:e=>{"use strict";e.exports=React},5206:e=>{"use strict";e.exports=ReactDOM},6942:(e,t)=>{var n;!function(){"use strict";var r={}.hasOwnProperty;function o(){for(var e="",t=0;t{var t=e&&e.__esModule?()=>e.default:()=>e;return i.d(t,{a:t}),t},t=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,i.t=function(n,r){if(1&r&&(n=this(n)),8&r)return n;if("object"==typeof n&&n){if(4&r&&n.__esModule)return n;if(16&r&&"function"==typeof n.then)return n}var o=Object.create(null);i.r(o);var a={};e=e||[null,t({}),t([]),t(t)];for(var l=2&r&&n;"object"==typeof l&&!~e.indexOf(l);l=t(l))Object.getOwnPropertyNames(l).forEach((e=>a[e]=()=>n[e]));return a.default=()=>n,i.d(o,a),o},i.d=(e,t)=>{for(var n in t)i.o(t,n)&&!i.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},i.f={},i.e=e=>Promise.all(Object.keys(i.f).reduce(((t,n)=>(i.f[n](e,t),t)),[])),i.u=e=>e+".min.js",i.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),i.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n={},r="post-expirator:",i.l=(e,t,o,a)=>{if(n[e])n[e].push(t);else{var l,s;if(void 0!==o)for(var c=document.getElementsByTagName("script"),u=0;u{l.onerror=l.onload=null,clearTimeout(p);var o=n[e];if(delete n[e],l.parentNode&&l.parentNode.removeChild(l),o&&o.forEach((e=>e(r))),t)return t(r)},p=setTimeout(f.bind(null,void 0,{type:"timeout",target:l}),12e4);l.onerror=f.bind(null,l.onerror),l.onload=f.bind(null,l.onload),s&&document.head.appendChild(l)}},i.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),(()=>{var e;i.g.importScripts&&(e=i.g.location+"");var t=i.g.document;if(!e&&t&&(t.currentScript&&"SCRIPT"===t.currentScript.tagName.toUpperCase()&&(e=t.currentScript.src),!e)){var n=t.getElementsByTagName("script");if(n.length)for(var r=n.length-1;r>-1&&(!e||!/^http(s?):/.test(e));)e=n[r--].src}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),i.p=e})(),(()=>{var e={155:0};i.f.j=(t,n)=>{var r=i.o(e,t)?e[t]:void 0;if(0!==r)if(r)n.push(r[2]);else{var o=new Promise(((n,o)=>r=e[t]=[n,o]));n.push(r[2]=o);var a=i.p+i.u(t),l=new Error;i.l(a,(n=>{if(i.o(e,t)&&(0!==(r=e[t])&&(e[t]=void 0),r)){var o=n&&("load"===n.type?"missing":n.type),a=n&&n.target&&n.target.src;l.message="Loading chunk "+t+" failed.\n("+o+": "+a+")",l.name="ChunkLoadError",l.type=o,l.request=a,r[1](l)}}),"chunk-"+t,t)}};var t=(t,n)=>{var r,o,[a,l,s]=n,c=0;if(a.some((t=>0!==e[t]))){for(r in l)i.o(l,r)&&(i.m[r]=l[r]);s&&s(i)}for(t&&t(n);c{"use strict";var e={};i.r(e),i.d(e,{setIsMatching:()=>U});var t={};i.r(t),i.d(t,{isViewportMatch:()=>q});var n={};i.r(n),i.d(n,{set:()=>Z,setDefaults:()=>J,setPersistenceLayer:()=>ee,toggle:()=>Q});var r={};i.r(r),i.d(r,{get:()=>re});var o={};i.r(o),i.d(o,{closeModal:()=>Ae,disableComplementaryArea:()=>Se,enableComplementaryArea:()=>Ee,openModal:()=>Oe,pinItem:()=>xe,setDefaultComplementaryArea:()=>_e,setFeatureDefaults:()=>Ne,setFeatureValue:()=>Ce,toggleFeature:()=>Re,unpinItem:()=>ke});var a={};i.r(a),i.d(a,{getActiveComplementaryArea:()=>Pe,isComplementaryAreaLoading:()=>De,isFeatureActive:()=>Ie,isItemPinned:()=>Te,isModalActive:()=>je});var l={};i.r(l),i.d(l,{getBaseSlugCounts:()=>Ju,getDataTypeByName:()=>Xu,getDataTypes:()=>qu,getDraggingFromHandle:()=>td,getEdgeById:()=>Eu,getEdges:()=>wu,getEditedWorkflow:()=>Tu,getEditedWorkflowAttribute:()=>Au,getEditedWorkflowAttributes:()=>Ou,getGlobalVariable:()=>Qu,getGlobalVariables:()=>Ku,getInitialViewport:()=>$u,getNodeById:()=>_u,getNodeErrors:()=>ed,getNodes:()=>vu,getPostType:()=>yu,getRayDebugShowEmails:()=>od,getRayDebugShowQueries:()=>rd,getRayDebugShowWordPressErrors:()=>ad,getSelectedEdges:()=>xu,getSelectedEdgesCount:()=>Uu,getSelectedElementsCount:()=>Vu,getSelectedNodes:()=>Su,getSelectedNodesCount:()=>Hu,getTaxonomyTerms:()=>Zu,getWorkflow:()=>Nu,getWorkflowStatus:()=>Cu,hasSelectedEdges:()=>Ru,hasSelectedNodes:()=>ku,isAutosavingWorkflow:()=>Wu,isConnectingNodes:()=>nd,isCreatingWorkflow:()=>Du,isCurrentWorkflowPublished:()=>Bu,isDeletingWorkflow:()=>zu,isEditedWorkflowDirty:()=>Iu,isEditedWorkflowSaveable:()=>Gu,isLoadingWorkflow:()=>Pu,isNewWorkflow:()=>Mu,isPublishedWorkflow:()=>Fu,isSavingWorkflow:()=>Lu,isWorkflowFlowEmpty:()=>ju,takeScreenshot:()=>Yu});var s={};i.r(s),i.d(s,{addDataType:()=>Zd,addNode:()=>cf,addNodeError:()=>rf,deleteWorkflow:()=>Yd,fetchTaxonomyTerms:()=>ef,incrementBaseSlugCounts:()=>tf,publishWorkflow:()=>Ld,removeEdge:()=>sf,removeNode:()=>lf,removeNodeError:()=>of,removePlaceholderNodes:()=>uf,resetNodeErrors:()=>af,saveAsCurrentStatus:()=>$d,saveAsDraft:()=>Md,setDataTypes:()=>Qd,setDraggingFromHandle:()=>df,setEdges:()=>Bd,setEditedWorkflowAttribute:()=>Xd,setFlow:()=>zd,setGlobalVariable:()=>Jd,setInitialViewport:()=>Vd,setIsConnectingNodes:()=>ff,setNodes:()=>Gd,setPostType:()=>Wd,setSelectedEdges:()=>qd,setSelectedNodes:()=>Hd,setupEditor:()=>jd,switchToDraft:()=>Fd,unselectAll:()=>Ud,updateBaseSlugCounts:()=>nf,updateNode:()=>Kd});var c={};i.r(c),i.d(c,{find:()=>Qm});var u={};i.r(u),i.d(u,{find:()=>og,findNext:()=>ig,findPrevious:()=>ag,isTabbableIndex:()=>Jm});var d={};i.r(d),i.d(d,{registerShortcut:()=>Ig,unregisterShortcut:()=>jg});var f={};i.r(f),i.d(f,{getAllShortcutKeyCombinations:()=>Bg,getAllShortcutRawKeyCombinations:()=>Vg,getCategoryShortcuts:()=>Hg,getShortcutAliases:()=>Gg,getShortcutDescription:()=>Wg,getShortcutKeyCombination:()=>Fg,getShortcutRepresentation:()=>zg});var p="ppfuture_workflow",h="fullscreenMode",m="showIconLabels",g="inserter",b="developerMode",y="welcomeGuide",v="advancedSettings",w="miniMap",_="controls",E="triggers",S="actions",x="advanced",k="publishpress-future/edit-workflow",R="application/future-workflow-editor-node",C="trigger",N="action",O="advanced",A="placeholder",P="source",D=i(5338);const T=wp.element;function I(e){var t,n,r="";if("string"==typeof e||"number"==typeof e)r+=e;else if("object"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;t(0,T.createElement)("path",e),W=(0,T.forwardRef)((({className:e,isPressed:t,...n},r)=>{const o={...n,className:j(e,{"is-pressed":t})||void 0,"aria-hidden":!0,focusable:!1};return(0,F.jsx)("svg",{...o,ref:r})}));W.displayName="SVG";const G=(0,F.jsx)(W,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,F.jsx)(z,{d:"M16.7 7.1l-6.3 8.5-3.3-2.5-.9 1.2 4.5 3.4L17.9 8z"})}),B=(0,F.jsx)(W,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,F.jsx)(z,{d:"M11.776 4.454a.25.25 0 01.448 0l2.069 4.192a.25.25 0 00.188.137l4.626.672a.25.25 0 01.139.426l-3.348 3.263a.25.25 0 00-.072.222l.79 4.607a.25.25 0 01-.362.263l-4.138-2.175a.25.25 0 00-.232 0l-4.138 2.175a.25.25 0 01-.363-.263l.79-4.607a.25.25 0 00-.071-.222L4.754 9.881a.25.25 0 01.139-.426l4.626-.672a.25.25 0 00.188-.137l2.069-4.192z"})}),V=(0,F.jsx)(W,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,F.jsx)(z,{fillRule:"evenodd",d:"M9.706 8.646a.25.25 0 01-.188.137l-4.626.672a.25.25 0 00-.139.427l3.348 3.262a.25.25 0 01.072.222l-.79 4.607a.25.25 0 00.362.264l4.138-2.176a.25.25 0 01.233 0l4.137 2.175a.25.25 0 00.363-.263l-.79-4.607a.25.25 0 01.072-.222l3.347-3.262a.25.25 0 00-.139-.427l-4.626-.672a.25.25 0 01-.188-.137l-2.069-4.192a.25.25 0 00-.448 0L9.706 8.646zM12 7.39l-.948 1.921a1.75 1.75 0 01-1.317.957l-2.12.308 1.534 1.495c.412.402.6.982.503 1.55l-.362 2.11 1.896-.997a1.75 1.75 0 011.629 0l1.895.997-.362-2.11a1.75 1.75 0 01.504-1.55l1.533-1.495-2.12-.308a1.75 1.75 0 01-1.317-.957L12 7.39z",clipRule:"evenodd"})}),H=(e,t,n)=>{let r,o,a,i,l,s=0,c=0,u=!1,d=!1,f=!0;function p(t){const n=r,i=o;return r=void 0,o=void 0,c=t,a=e.apply(i,n),a}function h(e,t){i=setTimeout(e,t)}function m(e){return e-(l||0)}function g(e){const n=m(e);return void 0===l||n>=t||n<0||d&&e-c>=s}function b(){const e=Date.now();if(g(e))return v(e);h(b,function(e){const n=m(e),r=e-c,o=t-n;return d?Math.min(o,s-r):o}(e))}function y(){i=void 0}function v(e){return y(),f&&r?p(e):(r=o=void 0,a)}function w(){return void 0!==i}function _(...e){const n=Date.now(),i=g(n);if(r=e,o=this,l=n,i){if(!w())return function(e){return c=e,h(b,t),u?p(e):a}(l);if(d)return h(b,t),p(l)}return w()||h(b,t),a}return n&&(u=!!n.leading,d="maxWait"in n,void 0!==n.maxWait&&(s=Math.max(n.maxWait,t)),f="trailing"in n?!!n.trailing:f),_.cancel=function(){void 0!==i&&clearTimeout(i),c=0,y(),r=l=o=void 0},_.flush=function(){return w()?v(Date.now()):a},_.pending=w,_};function U(e){return{type:"SET_IS_MATCHING",values:e}}function q(e,t){return-1===t.indexOf(" ")&&(t=">= "+t),!!e[t]}const X=(0,$.createReduxStore)("core/viewport",{reducer:function(e={},t){return"SET_IS_MATCHING"===t.type?t.values:e},actions:e,selectors:t});(0,$.register)(X);((e,t)=>{const n=H((()=>{const e=Object.fromEntries(o.map((([e,t])=>[e,t.matches])));(0,$.dispatch)(X).setIsMatching(e)}),0,{leading:!0}),r=Object.entries(t),o=Object.entries(e).flatMap((([e,t])=>r.map((([r,o])=>{const a=window.matchMedia(`(${o}: ${t}px)`);return a.addEventListener("change",n),[`${r} ${e}`,a]}))));window.addEventListener("orientationchange",n),n(),n.flush()})({huge:1440,wide:1280,large:960,medium:782,small:600,mobile:480},{"<":"max-width",">=":"min-width"});const Y=function(){let e;return(t,n)=>{if("SET_PERSISTENCE_LAYER"===n.type){const{persistenceLayer:t,persistedData:r}=n;return e=t,r}const r=((e={},t)=>{if("SET_PREFERENCE_VALUE"===t.type){const{scope:n,name:r,value:o}=t;return{...e,[n]:{...e[n],[r]:o}}}return e})(t,n);return"SET_PREFERENCE_VALUE"===n.type&&e?.set(r),r}}(),K=(0,$.combineReducers)({defaults:function(e={},t){if("SET_PREFERENCE_DEFAULTS"===t.type){const{scope:n,defaults:r}=t;return{...e,[n]:{...e[n],...r}}}return e},preferences:Y});function Q(e,t){return function({select:n,dispatch:r}){const o=n.get(e,t);r.set(e,t,!o)}}function Z(e,t,n){return{type:"SET_PREFERENCE_VALUE",scope:e,name:t,value:n}}function J(e,t){return{type:"SET_PREFERENCE_DEFAULTS",scope:e,defaults:t}}async function ee(e){const t=await e.get();return{type:"SET_PERSISTENCE_LAYER",persistenceLayer:e,persistedData:t}}const te=wp.hooks,ne=Object.create(null),re=(oe=(e,t,n)=>{const r=e.preferences[t]?.[n];return void 0!==r?r:e.defaults[t]?.[n]},(e,t,n)=>["allowRightClickOverrides","distractionFree","editorMode","fixedToolbar","focusMode","hiddenBlockTypes","inactivePanels","keepCaretInsideBlock","mostUsedBlocks","openPanels","showBlockBreadcrumbs","showIconLabels","showListViewByDefault","isPublishSidebarEnabled","isComplementaryAreaVisible","pinnedItems"].includes(n)&&["core/edit-post","core/edit-site"].includes(t)?(function(e,t={}){const{since:n,version:r,alternative:o,plugin:a,link:i,hint:l}=t,s=`${e} is deprecated${n?` since version ${n}`:""}${r?` and will be removed${a?` from ${a}`:""} in version ${r}`:""}.${o?` Please use ${o} instead.`:""}${i?` See: ${i}`:""}${l?` Note: ${l}`:""}`;s in ne||((0,te.doAction)("deprecated",e,t,s),console.warn(s),ne[s]=!0)}(`wp.data.select( 'core/preferences' ).get( '${t}', '${n}' )`,{since:"6.5",alternative:`wp.data.select( 'core/preferences' ).get( 'core', '${n}' )`}),oe(e,"core",n)):oe(e,t,n));var oe;const ae=(0,$.createReduxStore)("core/preferences",{reducer:K,actions:n,selectors:r});(0,$.register)(ae);const ie=new Map;function le(e){const t=(0,T.useMemo)((()=>{const t=function(e){if(!e)return null;let t=ie.get(e);return t||("undefined"!=typeof window&&"function"==typeof window.matchMedia?(t=window.matchMedia(e),ie.set(e,t),t):null)}(e);return{subscribe:e=>t?(t.addEventListener?.("change",e),()=>{t.removeEventListener?.("change",e)}):()=>{},getValue(){var e;return null!==(e=t?.matches)&&void 0!==e&&e}}}),[e]);return(0,T.useSyncExternalStore)(t.subscribe,t.getValue,(()=>!1))}const se=()=>le("(prefers-reduced-motion: reduce)"),ce={xhuge:1920,huge:1440,wide:1280,xlarge:1080,large:960,medium:782,small:600,mobile:480},ue={">=":"min-width","<":"max-width"},de={">=":(e,t)=>t>=e,"<":(e,t)=>t=")=>{const n=(0,T.useContext)(fe),r=le(!n&&`(${ue[t]}: ${ce[e]}px)`||void 0);return n?de[t](ce[e],n):r};pe.__experimentalWidthProvider=fe.Provider;const he=pe;function me(e){const t=(0,T.useRef)();return(0,T.useEffect)((()=>{t.current=e}),[e]),t.current}const ge=(0,F.jsx)(W,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,F.jsx)(z,{d:"M12 13.06l3.712 3.713 1.061-1.06L13.061 12l3.712-3.712-1.06-1.06L12 10.938 8.288 7.227l-1.061 1.06L10.939 12l-3.712 3.712 1.06 1.061L12 13.061z"})}),be=Object.create(null);function ye(e,t={}){const{since:n,version:r,alternative:o,plugin:a,link:i,hint:l}=t,s=`${e} is deprecated${n?` since version ${n}`:""}${r?` and will be removed${a?` from ${a}`:""} in version ${r}`:""}.${o?` Please use ${o} instead.`:""}${i?` See: ${i}`:""}${l?` Note: ${l}`:""}`;s in be||((0,te.doAction)("deprecated",e,t,s),console.warn(s),be[s]=!0)}function ve(e){return["core/edit-post","core/edit-site"].includes(e)?(ye(`${e} interface scope`,{alternative:"core interface scope",hint:"core/edit-post and core/edit-site are merging.",version:"6.6"}),"core"):e}function we(e,t){return"core"===e&&"edit-site/template"===t?(ye("edit-site/template sidebar",{alternative:"edit-post/document",version:"6.6"}),"edit-post/document"):"core"===e&&"edit-site/block-inspector"===t?(ye("edit-site/block-inspector sidebar",{alternative:"edit-post/block",version:"6.6"}),"edit-post/block"):t}const _e=(e,t)=>({type:"SET_DEFAULT_COMPLEMENTARY_AREA",scope:e=ve(e),area:t=we(e,t)}),Ee=(e,t)=>({registry:n,dispatch:r})=>{t&&(e=ve(e),t=we(e,t),n.select(ae).get(e,"isComplementaryAreaVisible")||n.dispatch(ae).set(e,"isComplementaryAreaVisible",!0),r({type:"ENABLE_COMPLEMENTARY_AREA",scope:e,area:t}))},Se=e=>({registry:t})=>{e=ve(e),t.select(ae).get(e,"isComplementaryAreaVisible")&&t.dispatch(ae).set(e,"isComplementaryAreaVisible",!1)},xe=(e,t)=>({registry:n})=>{if(!t)return;e=ve(e),t=we(e,t);const r=n.select(ae).get(e,"pinnedItems");!0!==r?.[t]&&n.dispatch(ae).set(e,"pinnedItems",{...r,[t]:!0})},ke=(e,t)=>({registry:n})=>{if(!t)return;e=ve(e),t=we(e,t);const r=n.select(ae).get(e,"pinnedItems");n.dispatch(ae).set(e,"pinnedItems",{...r,[t]:!1})};function Re(e,t){return function({registry:n}){ye("dispatch( 'core/interface' ).toggleFeature",{since:"6.0",alternative:"dispatch( 'core/preferences' ).toggle"}),n.dispatch(ae).toggle(e,t)}}function Ce(e,t,n){return function({registry:r}){ye("dispatch( 'core/interface' ).setFeatureValue",{since:"6.0",alternative:"dispatch( 'core/preferences' ).set"}),r.dispatch(ae).set(e,t,!!n)}}function Ne(e,t){return function({registry:n}){ye("dispatch( 'core/interface' ).setFeatureDefaults",{since:"6.0",alternative:"dispatch( 'core/preferences' ).setDefaults"}),n.dispatch(ae).setDefaults(e,t)}}function Oe(e){return{type:"OPEN_MODAL",name:e}}function Ae(){return{type:"CLOSE_MODAL"}}const Pe=(0,$.createRegistrySelector)((e=>(t,n)=>{n=ve(n);const r=e(ae).get(n,"isComplementaryAreaVisible");if(void 0!==r)return!1===r?null:t?.complementaryAreas?.[n]})),De=(0,$.createRegistrySelector)((e=>(t,n)=>{n=ve(n);const r=e(ae).get(n,"isComplementaryAreaVisible"),o=t?.complementaryAreas?.[n];return r&&void 0===o})),Te=(0,$.createRegistrySelector)((e=>(t,n,r)=>{var o;r=we(n=ve(n),r);const a=e(ae).get(n,"pinnedItems");return null===(o=a?.[r])||void 0===o||o})),Ie=(0,$.createRegistrySelector)((e=>(t,n,r)=>(ye("select( 'core/interface' ).isFeatureActive( scope, featureName )",{since:"6.0",alternative:"select( 'core/preferences' ).get( scope, featureName )"}),!!e(ae).get(n,r))));function je(e,t){return e.activeModal===t}const Me=(0,$.combineReducers)({complementaryAreas:function(e={},t){switch(t.type){case"SET_DEFAULT_COMPLEMENTARY_AREA":{const{scope:n,area:r}=t;return e[n]?e:{...e,[n]:r}}case"ENABLE_COMPLEMENTARY_AREA":{const{scope:n,area:r}=t;return{...e,[n]:r}}}return e},activeModal:function(e=null,t){switch(t.type){case"OPEN_MODAL":return t.name;case"CLOSE_MODAL":return null}return e}}),$e=(0,$.createReduxStore)("core/interface",{reducer:Me,actions:o,selectors:a});(0,$.register)($e);const Le=wp.plugins,Fe=(0,Le.withPluginContext)(((e,t)=>({icon:t.icon||e.icon,identifier:t.identifier||`${e.name}/${t.name}`}))),ze=Fe((function({as:e=M.Button,scope:t,identifier:n,icon:r,selectedIcon:o,name:a,shortcut:i,...l}){const s=e,c=(0,$.useSelect)((e=>e($e).getActiveComplementaryArea(t)===n),[n,t]),{enableComplementaryArea:u,disableComplementaryArea:d}=(0,$.useDispatch)($e);return(0,F.jsx)(s,{icon:o&&c?o:r,"aria-controls":n.replace("/",":"),"aria-checked":(f=l.role,["checkbox","option","radio","switch","menuitemcheckbox","menuitemradio","treeitem"].includes(f)?c:void 0),onClick:()=>{c?d(t):u(t,n)},shortcut:i,...l});var f})),We=({smallScreenTitle:e,children:t,className:n,toggleButtonProps:r})=>{const o=(0,F.jsx)(ze,{icon:ge,...r});return(0,F.jsxs)(F.Fragment,{children:[(0,F.jsxs)("div",{className:"components-panel__header interface-complementary-area-header__small",children:[e&&(0,F.jsx)("h2",{className:"interface-complementary-area-header__small-title",children:e}),o]}),(0,F.jsxs)("div",{className:j("components-panel__header","interface-complementary-area-header",n),tabIndex:-1,children:[t,o]})]})},Ge=()=>{};function Be({name:e,as:t=M.Button,onClick:n,...r}){return(0,F.jsx)(M.Fill,{name:e,children:({onClick:e})=>(0,F.jsx)(t,{onClick:n||e?(...t)=>{(n||Ge)(...t),(e||Ge)(...t)}:void 0,...r})})}Be.Slot=function({name:e,as:t=M.ButtonGroup,fillProps:n={},bubblesVirtually:r,...o}){return(0,F.jsx)(M.Slot,{name:e,bubblesVirtually:r,fillProps:n,children:e=>{if(!T.Children.toArray(e).length)return null;const n=[];T.Children.forEach(e,(({props:{__unstableExplicitMenuItem:e,__unstableTarget:t}})=>{t&&e&&n.push(t)}));const r=T.Children.map(e,(e=>!e.props.__unstableExplicitMenuItem&&n.includes(e.props.__unstableTarget)?null:e));return(0,F.jsx)(t,{...o,children:r})}})};const Ve=Be,He=({__unstableExplicitMenuItem:e,__unstableTarget:t,...n})=>(0,F.jsx)(M.MenuItem,{...n});function Ue({scope:e,target:t,__unstableExplicitMenuItem:n,...r}){return(0,F.jsx)(ze,{as:r=>(0,F.jsx)(Ve,{__unstableExplicitMenuItem:n,__unstableTarget:`${e}/${t}`,as:He,name:`${e}/plugin-more-menu`,...r}),role:"menuitemcheckbox",selectedIcon:G,name:t,scope:e,...r})}function qe({scope:e,...t}){return(0,F.jsx)(M.Fill,{name:`PinnedItems/${e}`,...t})}qe.Slot=function({scope:e,className:t,...n}){return(0,F.jsx)(M.Slot,{name:`PinnedItems/${e}`,...n,children:e=>e?.length>0&&(0,F.jsx)("div",{className:j(t,"interface-pinned-items"),children:e})})};const Xe=qe,Ye={open:{width:280},closed:{width:0},mobileOpen:{width:"100vw"}};function Ke({activeArea:e,isActive:t,scope:n,children:r,className:o,id:a}){const i=se(),l=he("medium","<"),s=me(e),c=me(t),[,u]=(0,T.useState)({});(0,T.useEffect)((()=>{u({})}),[t]);const d={type:"tween",duration:i||l||s&&e&&e!==s?0:.3,ease:[.6,0,.4,1]};return(0,F.jsx)(M.Fill,{name:`ComplementaryArea/${n}`,children:(0,F.jsx)(M.__unstableAnimatePresence,{initial:!1,children:(c||t)&&(0,F.jsx)(M.__unstableMotion.div,{variants:Ye,initial:"closed",animate:l?"mobileOpen":"open",exit:"closed",transition:d,className:"interface-complementary-area__fill",children:(0,F.jsx)("div",{id:a,className:o,style:{width:l?"100vw":280},children:r})})})})}const Qe=Fe((function({children:e,className:t,closeLabel:n=(0,L.__)("Close plugin"),identifier:r,header:o,headerClassName:a,icon:i,isPinnable:l=!0,panelClassName:s,scope:c,name:u,smallScreenTitle:d,title:f,toggleShortcut:p,isActiveByDefault:h}){const[m,g]=(0,T.useState)(!1),{isLoading:b,isActive:y,isPinned:v,activeArea:w,isSmall:_,isLarge:E,showIconLabels:S}=(0,$.useSelect)((e=>{const{getActiveComplementaryArea:t,isComplementaryAreaLoading:n,isItemPinned:o}=e($e),{get:a}=e(ae),i=t(c);return{isLoading:n(c),isActive:i===r,isPinned:o(c,r),activeArea:i,isSmall:e(X).isViewportMatch("< medium"),isLarge:e(X).isViewportMatch("large"),showIconLabels:a("core","showIconLabels")}}),[r,c]);!function(e,t,n,r,o){const a=(0,T.useRef)(!1),i=(0,T.useRef)(!1),{enableComplementaryArea:l,disableComplementaryArea:s}=(0,$.useDispatch)($e);(0,T.useEffect)((()=>{r&&o&&!a.current?(s(e),i.current=!0):i.current&&!o&&a.current?(i.current=!1,l(e,t)):i.current&&n&&n!==t&&(i.current=!1),o!==a.current&&(a.current=o)}),[r,o,e,t,n,s,l])}(c,r,w,y,_);const{enableComplementaryArea:x,disableComplementaryArea:k,pinItem:R,unpinItem:C}=(0,$.useDispatch)($e);if((0,T.useEffect)((()=>{h&&void 0===w&&!_?x(c,r):void 0===w&&_&&k(c,r),g(!0)}),[w,h,c,r,_,x,k]),m)return(0,F.jsxs)(F.Fragment,{children:[l&&(0,F.jsx)(Xe,{scope:c,children:v&&(0,F.jsx)(ze,{scope:c,identifier:r,isPressed:y&&(!S||E),"aria-expanded":y,"aria-disabled":b,label:f,icon:S?G:i,showTooltip:!S,variant:S?"tertiary":void 0,size:"compact",shortcut:p})}),u&&l&&(0,F.jsx)(Ue,{target:u,scope:c,icon:i,children:f}),(0,F.jsxs)(Ke,{activeArea:w,isActive:y,className:j("interface-complementary-area",t),scope:c,id:r.replace("/",":"),children:[(0,F.jsx)(We,{className:a,closeLabel:n,onClose:()=>k(c),smallScreenTitle:d,toggleButtonProps:{label:n,size:"small",shortcut:p,scope:c,identifier:r},children:o||(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)("h2",{className:"interface-complementary-area-header__title",children:f}),l&&(0,F.jsx)(M.Button,{className:"interface-complementary-area__pin-unpin-item",icon:v?B:V,label:v?(0,L.__)("Unpin from toolbar"):(0,L.__)("Pin to toolbar"),onClick:()=>(v?C:R)(c,r),isPressed:v,"aria-expanded":v,size:"compact"})]})}),(0,F.jsx)(M.Panel,{className:s,children:e})]})]})}));Qe.Slot=function({scope:e,...t}){return(0,F.jsx)(M.Slot,{name:`ComplementaryArea/${e}`,...t})};const Ze=Qe,Je=({isActive:e})=>((0,T.useEffect)((()=>{let e=!1;return document.body.classList.contains("sticky-menu")&&(e=!0,document.body.classList.remove("sticky-menu")),()=>{e&&document.body.classList.add("sticky-menu")}}),[]),(0,T.useEffect)((()=>(e?document.body.classList.add("is-fullscreen-mode"):document.body.classList.remove("is-fullscreen-mode"),()=>{e&&document.body.classList.remove("is-fullscreen-mode")})),[e]),null);function et(e){const t=(0,T.useRef)((()=>{throw new Error("Callbacks created with `useEvent` cannot be called during rendering.")}));return(0,T.useInsertionEffect)((()=>{t.current=e})),(0,T.useCallback)(((...e)=>t.current?.(...e)),[])}function tt(e,t={}){const n=et(e),r=(0,T.useRef)(),o=(0,T.useRef)();return et((e=>{var a;if(e===r.current)return;null!==(a=o.current)&&void 0!==a||(o.current=new ResizeObserver(n));const{current:i}=o;r.current&&i.unobserve(r.current),r.current=e,e&&i.observe(e,t)}))}const nt={position:"absolute",top:0,left:0,right:0,bottom:0,pointerEvents:"none",opacity:0,overflow:"hidden",zIndex:-1};function rt({onResize:e}){const t=tt((t=>{const n=(e=>{let t;if(e.contentBoxSize)if(e.contentBoxSize[0]){const n=e.contentBoxSize[0];t=[n.inlineSize,n.blockSize]}else{const n=e.contentBoxSize;t=[n.inlineSize,n.blockSize]}else t=[e.contentRect.width,e.contentRect.height];const[n,r]=t.map((e=>Math.round(e)));return{width:n,height:r}})(t.at(-1));e(n)}));return(0,F.jsx)("div",{ref:t,style:nt,"aria-hidden":"true"})}const ot={width:null,height:null};function at(e,t){"function"==typeof e?e(t):e&&e.hasOwnProperty("current")&&(e.current=t)}function it(e){const t=(0,T.useRef)(),n=(0,T.useRef)(!1),r=(0,T.useRef)(!1),o=(0,T.useRef)([]),a=(0,T.useRef)(e);return a.current=e,(0,T.useLayoutEffect)((()=>{!1===r.current&&!0===n.current&&e.forEach(((e,n)=>{const r=o.current[n];e!==r&&(at(r,null),at(e,t.current))})),o.current=e}),e),(0,T.useLayoutEffect)((()=>{r.current=!1})),(0,T.useCallback)((e=>{at(t,e),r.current=!0,n.current=null!==e;const i=e?a.current:o.current;for(const t of i)at(t,e)}),[])}function lt({children:e,className:t,ariaLabel:n,as:r="div",...o}){return(0,F.jsx)(r,{className:j("interface-navigable-region",t),"aria-label":n,role:"region",tabIndex:"-1",...o,children:e})}const st={type:"tween",duration:.25,ease:[.6,0,.4,1]},ct={hidden:{opacity:1,marginTop:-60},visible:{opacity:1,marginTop:0},distractionFreeHover:{opacity:1,marginTop:0,transition:{...st,delay:.2,delayChildren:.2}},distractionFreeHidden:{opacity:0,marginTop:-60},distractionFreeDisabled:{opacity:0,marginTop:0,transition:{...st,delay:.8,delayChildren:.8}}},ut=(0,T.forwardRef)((function({isDistractionFree:e,footer:t,header:n,editorNotices:r,sidebar:o,secondarySidebar:a,content:i,actions:l,labels:s,className:c,enableRegionNavigation:u=!0,shortcuts:d},f){const[p,h]=function(e,t={}){return e?tt(e,t):function(){const[e,t]=(0,T.useState)(ot),n=(0,T.useRef)(ot),r=(0,T.useCallback)((e=>{var r,o;o=e,((r=n.current).width!==o.width||r.height!==o.height)&&(n.current=e,t(e))}),[]);return[(0,F.jsx)(rt,{onResize:r}),e]}()}(),m=he("medium","<"),g={type:"tween",duration:se()?0:.25,ease:[.6,0,.4,1]},b=(0,M.__unstableUseNavigateRegions)(d);!function(e){(0,T.useEffect)((()=>{const t=document&&document.querySelector(`html:not(.${e})`);if(t)return t.classList.toggle(e),()=>{t.classList.toggle(e)}}),[e])}("interface-interface-skeleton__html-container");const y={header:(0,L._x)("Header","header landmark area"),body:(0,L.__)("Content"),secondarySidebar:(0,L.__)("Block Library"),sidebar:(0,L.__)("Settings"),actions:(0,L.__)("Publish"),footer:(0,L.__)("Footer"),...s};return(0,F.jsxs)("div",{...u?b:{},ref:it([f,u?b.ref:void 0]),className:j(c,"interface-interface-skeleton",b.className,!!t&&"has-footer"),children:[(0,F.jsxs)("div",{className:"interface-interface-skeleton__editor",children:[(0,F.jsx)(M.__unstableAnimatePresence,{initial:!1,children:!!n&&(0,F.jsx)(lt,{as:M.__unstableMotion.div,className:"interface-interface-skeleton__header","aria-label":y.header,initial:e&&!m?"distractionFreeHidden":"hidden",whileHover:e&&!m?"distractionFreeHover":"visible",animate:e&&!m?"distractionFreeDisabled":"visible",exit:e&&!m?"distractionFreeHidden":"hidden",variants:ct,transition:g,children:n})}),e&&(0,F.jsx)("div",{className:"interface-interface-skeleton__header",children:r}),(0,F.jsxs)("div",{className:"interface-interface-skeleton__body",children:[(0,F.jsx)(M.__unstableAnimatePresence,{initial:!1,children:!!a&&(0,F.jsx)(lt,{className:"interface-interface-skeleton__secondary-sidebar",ariaLabel:y.secondarySidebar,as:M.__unstableMotion.div,initial:"closed",animate:"open",exit:"closed",variants:{open:{width:h.width},closed:{width:0}},transition:g,children:(0,F.jsxs)(M.__unstableMotion.div,{style:{position:"absolute",width:m?"100vw":"fit-content",height:"100%",left:0},variants:{open:{x:0},closed:{x:"-100%"}},transition:g,children:[p,a]})})}),(0,F.jsx)(lt,{className:"interface-interface-skeleton__content",ariaLabel:y.body,children:i}),!!o&&(0,F.jsx)(lt,{className:"interface-interface-skeleton__sidebar",ariaLabel:y.sidebar,children:o}),!!l&&(0,F.jsx)(lt,{className:"interface-interface-skeleton__actions",ariaLabel:y.actions,children:l})]})]}),!!t&&(0,F.jsx)(lt,{className:"interface-interface-skeleton__footer",ariaLabel:y.footer,children:t})]})}));var dt=i(6942),ft=i.n(dt),pt="publishpress-future/workflow",ht=i(1594);function mt(e){if("string"==typeof e||"number"==typeof e)return""+e;let t="";if(Array.isArray(e))for(let n,r=0;r{let t;const n=new Set,r=(e,r)=>{const o="function"==typeof e?e(t):e;if(!Object.is(o,t)){const e=t;t=(null!=r?r:"object"!=typeof o||null===o)?o:Object.assign({},t,o),n.forEach((n=>n(t,e)))}},o=()=>t,a={setState:r,getState:o,getInitialState:()=>i,subscribe:e=>(n.add(e),()=>n.delete(e)),destroy:()=>{console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),n.clear()}},i=t=e(r,o,a);return a},{useDebugValue:yt}=ht,{useSyncExternalStoreWithSelector:vt}=gt,wt=e=>e;function _t(e,t=wt,n){const r=vt(e.subscribe,e.getState,e.getServerState||e.getInitialState,t,n);return yt(r),r}const Et=(e,t)=>{const n=(e=>e?bt(e):bt)(e),r=(e,r=t)=>_t(n,e,r);return Object.assign(r,n),r};function St(e,t){if(Object.is(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;if(e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(const[n,r]of e)if(!Object.is(r,t.get(n)))return!1;return!0}if(e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(const n of e)if(!t.has(n))return!1;return!0}const n=Object.keys(e);if(n.length!==Object.keys(t).length)return!1;for(const r of n)if(!Object.prototype.hasOwnProperty.call(t,r)||!Object.is(e[r],t[r]))return!1;return!0}var xt={value:()=>{}};function kt(){for(var e,t=0,n=arguments.length,r={};t=0&&(t=e.slice(n+1),e=e.slice(0,n)),e&&!r.hasOwnProperty(e))throw new Error("unknown type: "+e);return{type:e,name:t}}))),i=-1,l=a.length;if(!(arguments.length<2)){if(null!=t&&"function"!=typeof t)throw new Error("invalid callback: "+t);for(;++i0)for(var n,r,o=new Array(n),a=0;at?1:e>=t?0:NaN}Wt.prototype={constructor:Wt,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};var qt="http://www.w3.org/1999/xhtml";const Xt={svg:"http://www.w3.org/2000/svg",xhtml:qt,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Yt(e){var t=e+="",n=t.indexOf(":");return n>=0&&"xmlns"!==(t=e.slice(0,n))&&(e=e.slice(n+1)),Xt.hasOwnProperty(t)?{space:Xt[t],local:e}:e}function Kt(e){return function(){this.removeAttribute(e)}}function Qt(e){return function(){this.removeAttributeNS(e.space,e.local)}}function Zt(e,t){return function(){this.setAttribute(e,t)}}function Jt(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function en(e,t){return function(){var n=t.apply(this,arguments);null==n?this.removeAttribute(e):this.setAttribute(e,n)}}function tn(e,t){return function(){var n=t.apply(this,arguments);null==n?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,n)}}function nn(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function rn(e){return function(){this.style.removeProperty(e)}}function on(e,t,n){return function(){this.style.setProperty(e,t,n)}}function an(e,t,n){return function(){var r=t.apply(this,arguments);null==r?this.style.removeProperty(e):this.style.setProperty(e,r,n)}}function ln(e,t){return e.style.getPropertyValue(t)||nn(e).getComputedStyle(e,null).getPropertyValue(t)}function sn(e){return function(){delete this[e]}}function cn(e,t){return function(){this[e]=t}}function un(e,t){return function(){var n=t.apply(this,arguments);null==n?delete this[e]:this[e]=n}}function dn(e){return e.trim().split(/^|\s+/)}function fn(e){return e.classList||new pn(e)}function pn(e){this._node=e,this._names=dn(e.getAttribute("class")||"")}function hn(e,t){for(var n=fn(e),r=-1,o=t.length;++r=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};var Fn=[null];function zn(e,t){this._groups=e,this._parents=t}function Wn(){return new zn([[document.documentElement]],Fn)}zn.prototype=Wn.prototype={constructor:zn,select:function(e){"function"!=typeof e&&(e=Pt(e));for(var t=this._groups,n=t.length,r=new Array(n),o=0;o=_&&(_=w+1);!(v=b[_])&&++_=0;)(r=o[a])&&(i&&4^r.compareDocumentPosition(i)&&i.parentNode.insertBefore(r,i),i=r);return this},sort:function(e){function t(t,n){return t&&n?e(t.__data__,n.__data__):!t-!n}e||(e=Ut);for(var n=this._groups,r=n.length,o=new Array(r),a=0;a1?this.each((null==t?rn:"function"==typeof t?an:on)(e,t,null==n?"":n)):ln(this.node(),e)},property:function(e,t){return arguments.length>1?this.each((null==t?sn:"function"==typeof t?un:cn)(e,t)):this.node()[e]},classed:function(e,t){var n=dn(e+"");if(arguments.length<2){for(var r=fn(this.node()),o=-1,a=n.length;++o=0&&(t=e.slice(n+1),e=e.slice(0,n)),{type:e,name:t}}))}(e+""),i=a.length;if(!(arguments.length<2)){for(l=t?jn:In,r=0;r=0&&t._call.call(void 0,e),t=t._next;--tr}()}finally{tr=0,function(){for(var e,t,n=Jn,r=1/0;n;)n._call?(r>n._time&&(r=n._time),e=n,n=n._next):(t=n._next,n._next=null,n=e?e._next=t:Jn=t);er=e,mr(r)}(),ar=0}}function hr(){var e=lr.now(),t=e-or;t>1e3&&(ir-=t,or=e)}function mr(e){tr||(nr&&(nr=clearTimeout(nr)),e-ar>24?(e<1/0&&(nr=setTimeout(pr,e-lr.now()-ir)),rr&&(rr=clearInterval(rr))):(rr||(or=lr.now(),rr=setInterval(hr,1e3)),tr=1,sr(pr)))}function gr(e,t,n){var r=new dr;return t=null==t?0:+t,r.restart((n=>{r.stop(),e(n+t)}),t,n),r}dr.prototype=fr.prototype={constructor:dr,restart:function(e,t,n){if("function"!=typeof e)throw new TypeError("callback is not a function");n=(null==n?cr():+n)+(null==t?0:+t),this._next||er===this||(er?er._next=this:Jn=this,er=this),this._call=e,this._time=n,mr()},stop:function(){this._call&&(this._call=null,this._time=1/0,mr())}};var br=Ot("start","end","cancel","interrupt"),yr=[];function vr(e,t,n,r,o,a){var i=e.__transition;if(i){if(n in i)return}else e.__transition={};!function(e,t,n){var r,o=e.__transition;function a(s){var c,u,d,f;if(1!==n.state)return l();for(c in o)if((f=o[c]).name===n.name){if(3===f.state)return gr(a);4===f.state?(f.state=6,f.timer.stop(),f.on.call("interrupt",e,e.__data__,f.index,f.group),delete o[c]):+c0)throw new Error("too late; already scheduled");return n}function _r(e,t){var n=Er(e,t);if(n.state>3)throw new Error("too late; already running");return n}function Er(e,t){var n=e.__transition;if(!n||!(n=n[t]))throw new Error("transition not found");return n}function Sr(e,t){var n,r,o,a=e.__transition,i=!0;if(a){for(o in t=null==t?null:t+"",a)(n=a[o]).name===t?(r=n.state>2&&n.state<5,n.state=6,n.timer.stop(),n.on.call(r?"interrupt":"cancel",e,e.__data__,n.index,n.group),delete a[o]):i=!1;i&&delete e.__transition}}function xr(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}var kr,Rr=180/Math.PI,Cr={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Nr(e,t,n,r,o,a){var i,l,s;return(i=Math.sqrt(e*e+t*t))&&(e/=i,t/=i),(s=e*n+t*r)&&(n-=e*s,r-=t*s),(l=Math.sqrt(n*n+r*r))&&(n/=l,r/=l,s/=l),e*r180?t+=360:t-e>180&&(e+=360),a.push({i:n.push(o(n)+"rotate(",null,r)-2,x:xr(e,t)})):t&&n.push(o(n)+"rotate("+t+r)}(a.rotate,i.rotate,l,s),function(e,t,n,a){e!==t?a.push({i:n.push(o(n)+"skewX(",null,r)-2,x:xr(e,t)}):t&&n.push(o(n)+"skewX("+t+r)}(a.skewX,i.skewX,l,s),function(e,t,n,r,a,i){if(e!==n||t!==r){var l=a.push(o(a)+"scale(",null,",",null,")");i.push({i:l-4,x:xr(e,n)},{i:l-2,x:xr(t,r)})}else 1===n&&1===r||a.push(o(a)+"scale("+n+","+r+")")}(a.scaleX,a.scaleY,i.scaleX,i.scaleY,l,s),a=i=null,function(e){for(var t,n=-1,r=s.length;++n>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===n?to(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===n?to(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=Vr.exec(e))?new ro(t[1],t[2],t[3],1):(t=Hr.exec(e))?new ro(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=Ur.exec(e))?to(t[1],t[2],t[3],t[4]):(t=qr.exec(e))?to(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=Xr.exec(e))?co(t[1],t[2]/100,t[3]/100,1):(t=Yr.exec(e))?co(t[1],t[2]/100,t[3]/100,t[4]):Kr.hasOwnProperty(e)?eo(Kr[e]):"transparent"===e?new ro(NaN,NaN,NaN,0):null}function eo(e){return new ro(e>>16&255,e>>8&255,255&e,1)}function to(e,t,n,r){return r<=0&&(e=t=n=NaN),new ro(e,t,n,r)}function no(e,t,n,r){return 1===arguments.length?((o=e)instanceof $r||(o=Jr(o)),o?new ro((o=o.rgb()).r,o.g,o.b,o.opacity):new ro):new ro(e,t,n,null==r?1:r);var o}function ro(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function oo(){return`#${so(this.r)}${so(this.g)}${so(this.b)}`}function ao(){const e=io(this.opacity);return`${1===e?"rgb(":"rgba("}${lo(this.r)}, ${lo(this.g)}, ${lo(this.b)}${1===e?")":`, ${e})`}`}function io(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function lo(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function so(e){return((e=lo(e))<16?"0":"")+e.toString(16)}function co(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new fo(e,t,n,r)}function uo(e){if(e instanceof fo)return new fo(e.h,e.s,e.l,e.opacity);if(e instanceof $r||(e=Jr(e)),!e)return new fo;if(e instanceof fo)return e;var t=(e=e.rgb()).r/255,n=e.g/255,r=e.b/255,o=Math.min(t,n,r),a=Math.max(t,n,r),i=NaN,l=a-o,s=(a+o)/2;return l?(i=t===a?(n-r)/l+6*(n0&&s<1?0:i,new fo(i,l,s,e.opacity)}function fo(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function po(e){return(e=(e||0)%360)<0?e+360:e}function ho(e){return Math.max(0,Math.min(1,e||0))}function mo(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}function go(e,t,n,r,o){var a=e*e,i=a*e;return((1-3*e+3*a-i)*t+(4-6*a+3*i)*n+(1+3*e+3*a-3*i)*r+i*o)/6}jr($r,Jr,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Qr,formatHex:Qr,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return uo(this).formatHsl()},formatRgb:Zr,toString:Zr}),jr(ro,no,Mr($r,{brighter(e){return e=null==e?Fr:Math.pow(Fr,e),new ro(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=null==e?Lr:Math.pow(Lr,e),new ro(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new ro(lo(this.r),lo(this.g),lo(this.b),io(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:oo,formatHex:oo,formatHex8:function(){return`#${so(this.r)}${so(this.g)}${so(this.b)}${so(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:ao,toString:ao})),jr(fo,(function(e,t,n,r){return 1===arguments.length?uo(e):new fo(e,t,n,null==r?1:r)}),Mr($r,{brighter(e){return e=null==e?Fr:Math.pow(Fr,e),new fo(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=null==e?Lr:Math.pow(Lr,e),new fo(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,o=2*n-r;return new ro(mo(e>=240?e-240:e+120,o,r),mo(e,o,r),mo(e<120?e+240:e-120,o,r),this.opacity)},clamp(){return new fo(po(this.h),ho(this.s),ho(this.l),io(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=io(this.opacity);return`${1===e?"hsl(":"hsla("}${po(this.h)}, ${100*ho(this.s)}%, ${100*ho(this.l)}%${1===e?")":`, ${e})`}`}}));const bo=e=>()=>e;function yo(e,t){var n=t-e;return n?function(e,t){return function(n){return e+n*t}}(e,n):bo(isNaN(e)?t:e)}const vo=function e(t){var n=function(e){return 1==(e=+e)?yo:function(t,n){return n-t?function(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}(t,n,e):bo(isNaN(t)?n:t)}}(t);function r(e,t){var r=n((e=no(e)).r,(t=no(t)).r),o=n(e.g,t.g),a=n(e.b,t.b),i=yo(e.opacity,t.opacity);return function(t){return e.r=r(t),e.g=o(t),e.b=a(t),e.opacity=i(t),e+""}}return r.gamma=e,r}(1);function wo(e){return function(t){var n,r,o=t.length,a=new Array(o),i=new Array(o),l=new Array(o);for(n=0;n=1?(n=1,t-1):Math.floor(n*t),o=e[r],a=e[r+1],i=r>0?e[r-1]:2*o-a,l=ra&&(o=t.slice(a,o),l[i]?l[i]+=o:l[++i]=o),(n=n[0])===(r=r[0])?l[i]?l[i]+=r:l[++i]=r:(l[++i]=null,s.push({i,x:xr(n,r)})),a=Eo.lastIndex;return a=0&&(e=e.slice(0,t)),!e||"start"===e}))}(t)?wr:_r;return function(){var i=a(this,e),l=i.on;l!==r&&(o=(r=l).copy()).on(t,n),i.on=o}}(n,e,t))},attr:function(e,t){var n=Yt(e),r="transform"===n?Pr:xo;return this.attrTween(e,"function"==typeof t?(n.local?Ao:Oo)(n,r,Ir(this,"attr."+e,t)):null==t?(n.local?Ro:ko)(n):(n.local?No:Co)(n,r,t))},attrTween:function(e,t){var n="attr."+e;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(null==t)return this.tween(n,null);if("function"!=typeof t)throw new Error;var r=Yt(e);return this.tween(n,(r.local?Po:Do)(r,t))},style:function(e,t,n){var r="transform"==(e+="")?Ar:xo;return null==t?this.styleTween(e,function(e,t){var n,r,o;return function(){var a=ln(this,e),i=(this.style.removeProperty(e),ln(this,e));return a===i?null:a===n&&i===r?o:o=t(n=a,r=i)}}(e,r)).on("end.style."+e,Lo(e)):"function"==typeof t?this.styleTween(e,function(e,t,n){var r,o,a;return function(){var i=ln(this,e),l=n(this),s=l+"";return null==l&&(this.style.removeProperty(e),s=l=ln(this,e)),i===s?null:i===r&&s===o?a:(o=s,a=t(r=i,l))}}(e,r,Ir(this,"style."+e,t))).each(function(e,t){var n,r,o,a,i="style."+t,l="end."+i;return function(){var s=_r(this,e),c=s.on,u=null==s.value[i]?a||(a=Lo(t)):void 0;c===n&&o===u||(r=(n=c).copy()).on(l,o=u),s.on=r}}(this._id,e)):this.styleTween(e,function(e,t,n){var r,o,a=n+"";return function(){var i=ln(this,e);return i===a?null:i===r?o:o=t(r=i,n)}}(e,r,t),n).on("end.style."+e,null)},styleTween:function(e,t,n){var r="style."+(e+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(null==t)return this.tween(r,null);if("function"!=typeof t)throw new Error;return this.tween(r,function(e,t,n){var r,o;function a(){var a=t.apply(this,arguments);return a!==o&&(r=(o=a)&&function(e,t,n){return function(r){this.style.setProperty(e,t.call(this,r),n)}}(e,a,n)),r}return a._value=t,a}(e,t,null==n?"":n))},text:function(e){return this.tween("text","function"==typeof e?function(e){return function(){var t=e(this);this.textContent=null==t?"":t}}(Ir(this,"text",e)):function(e){return function(){this.textContent=e}}(null==e?"":e+""))},textTween:function(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(null==e)return this.tween(t,null);if("function"!=typeof e)throw new Error;return this.tween(t,function(e){var t,n;function r(){var r=e.apply(this,arguments);return r!==n&&(t=(n=r)&&function(e){return function(t){this.textContent=e.call(this,t)}}(r)),t}return r._value=e,r}(e))},remove:function(){return this.on("end.remove",function(e){return function(){var t=this.parentNode;for(var n in this.__transition)if(+n!==e)return;t&&t.removeChild(this)}}(this._id))},tween:function(e,t){var n=this._id;if(e+="",arguments.length<2){for(var r,o=Er(this.node(),n).tween,a=0,i=o.length;a()=>e;function Uo(e,{sourceEvent:t,target:n,transform:r,dispatch:o}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},transform:{value:r,enumerable:!0,configurable:!0},_:{value:o}})}function qo(e,t,n){this.k=e,this.x=t,this.y=n}qo.prototype={constructor:qo,scale:function(e){return 1===e?this:new qo(this.k*e,this.x,this.y)},translate:function(e,t){return 0===e&0===t?this:new qo(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var Xo=new qo(1,0,0);function Yo(e){e.stopImmediatePropagation()}function Ko(e){e.preventDefault(),e.stopImmediatePropagation()}function Qo(e){return!(e.ctrlKey&&"wheel"!==e.type||e.button)}function Zo(){var e=this;return e instanceof SVGElement?(e=e.ownerSVGElement||e).hasAttribute("viewBox")?[[(e=e.viewBox.baseVal).x,e.y],[e.x+e.width,e.y+e.height]]:[[0,0],[e.width.baseVal.value,e.height.baseVal.value]]:[[0,0],[e.clientWidth,e.clientHeight]]}function Jo(){return this.__zoom||Xo}function ea(e){return-e.deltaY*(1===e.deltaMode?.05:e.deltaMode?1:.002)*(e.ctrlKey?10:1)}function ta(){return navigator.maxTouchPoints||"ontouchstart"in this}function na(e,t,n){var r=e.invertX(t[0][0])-n[0][0],o=e.invertX(t[1][0])-n[1][0],a=e.invertY(t[0][1])-n[0][1],i=e.invertY(t[1][1])-n[1][1];return e.translate(o>r?(r+o)/2:Math.min(0,r)||Math.max(0,o),i>a?(a+i)/2:Math.min(0,a)||Math.max(0,i))}function ra(){var e,t,n,r=Qo,o=Zo,a=na,i=ea,l=ta,s=[0,1/0],c=[[-1/0,-1/0],[1/0,1/0]],u=250,d=Qn,f=Ot("start","zoom","end"),p=0,h=10;function m(e){e.property("__zoom",Jo).on("wheel.zoom",E,{passive:!1}).on("mousedown.zoom",S).on("dblclick.zoom",x).filter(l).on("touchstart.zoom",k).on("touchmove.zoom",R).on("touchend.zoom touchcancel.zoom",C).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function g(e,t){return(t=Math.max(s[0],Math.min(s[1],t)))===e.k?e:new qo(t,e.x,e.y)}function b(e,t,n){var r=t[0]-n[0]*e.k,o=t[1]-n[1]*e.k;return r===e.x&&o===e.y?e:new qo(e.k,r,o)}function y(e){return[(+e[0][0]+ +e[1][0])/2,(+e[0][1]+ +e[1][1])/2]}function v(e,t,n,r){e.on("start.zoom",(function(){w(this,arguments).event(r).start()})).on("interrupt.zoom end.zoom",(function(){w(this,arguments).event(r).end()})).tween("zoom",(function(){var e=this,a=arguments,i=w(e,a).event(r),l=o.apply(e,a),s=null==n?y(l):"function"==typeof n?n.apply(e,a):n,c=Math.max(l[1][0]-l[0][0],l[1][1]-l[0][1]),u=e.__zoom,f="function"==typeof t?t.apply(e,a):t,p=d(u.invert(s).concat(c/u.k),f.invert(s).concat(c/f.k));return function(e){if(1===e)e=f;else{var t=p(e),n=c/t[2];e=new qo(n,s[0]-t[0]*n,s[1]-t[1]*n)}i.zoom(null,e)}}))}function w(e,t,n){return!n&&e.__zooming||new _(e,t)}function _(e,t){this.that=e,this.args=t,this.active=0,this.sourceEvent=null,this.extent=o.apply(e,t),this.taps=0}function E(e,...t){if(r.apply(this,arguments)){var n=w(this,t).event(e),o=this.__zoom,l=Math.max(s[0],Math.min(s[1],o.k*Math.pow(2,i.apply(this,arguments)))),u=Zn(e);if(n.wheel)n.mouse[0][0]===u[0]&&n.mouse[0][1]===u[1]||(n.mouse[1]=o.invert(n.mouse[0]=u)),clearTimeout(n.wheel);else{if(o.k===l)return;n.mouse=[u,o.invert(u)],Sr(this),n.start()}Ko(e),n.wheel=setTimeout((function(){n.wheel=null,n.end()}),150),n.zoom("mouse",a(b(g(o,l),n.mouse[0],n.mouse[1]),n.extent,c))}}function S(e,...t){if(!n&&r.apply(this,arguments)){var o=e.currentTarget,i=w(this,t,!0).event(e),l=Bn(e.view).on("mousemove.zoom",(function(e){if(Ko(e),!i.moved){var t=e.clientX-u,n=e.clientY-d;i.moved=t*t+n*n>p}i.event(e).zoom("mouse",a(b(i.that.__zoom,i.mouse[0]=Zn(e,o),i.mouse[1]),i.extent,c))}),!0).on("mouseup.zoom",(function(e){l.on("mousemove.zoom mouseup.zoom",null),Yn(e.view,i.moved),Ko(e),i.event(e).end()}),!0),s=Zn(e,o),u=e.clientX,d=e.clientY;Xn(e.view),Yo(e),i.mouse=[s,this.__zoom.invert(s)],Sr(this),i.start()}}function x(e,...t){if(r.apply(this,arguments)){var n=this.__zoom,i=Zn(e.changedTouches?e.changedTouches[0]:e,this),l=n.invert(i),s=n.k*(e.shiftKey?.5:2),d=a(b(g(n,s),i,l),o.apply(this,t),c);Ko(e),u>0?Bn(this).transition().duration(u).call(v,d,i,e):Bn(this).call(m.transform,d,i,e)}}function k(n,...o){if(r.apply(this,arguments)){var a,i,l,s,c=n.touches,u=c.length,d=w(this,o,n.changedTouches.length===u).event(n);for(Yo(n),i=0;i()=>e;function aa(e,{sourceEvent:t,subject:n,target:r,identifier:o,active:a,x:i,y:l,dx:s,dy:c,dispatch:u}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},subject:{value:n,enumerable:!0,configurable:!0},target:{value:r,enumerable:!0,configurable:!0},identifier:{value:o,enumerable:!0,configurable:!0},active:{value:a,enumerable:!0,configurable:!0},x:{value:i,enumerable:!0,configurable:!0},y:{value:l,enumerable:!0,configurable:!0},dx:{value:s,enumerable:!0,configurable:!0},dy:{value:c,enumerable:!0,configurable:!0},_:{value:u}})}function ia(e){return!e.ctrlKey&&!e.button}function la(){return this.parentNode}function sa(e,t){return null==t?{x:e.x,y:e.y}:t}function ca(){return navigator.maxTouchPoints||"ontouchstart"in this}aa.prototype.on=function(){var e=this._.on.apply(this._,arguments);return e===this._?this:e};var ua=i(5206);const da=(0,ht.createContext)(null),fa=da.Provider,pa="[React Flow]: Seems like you have not used zustand provider as an ancestor. Help: https://reactflow.dev/error#001";function ha(e,t){const n=(0,ht.useContext)(da);if(null===n)throw new Error(pa);return _t(n,e,t)}const ma=()=>{const e=(0,ht.useContext)(da);if(null===e)throw new Error(pa);return(0,ht.useMemo)((()=>({getState:e.getState,setState:e.setState,subscribe:e.subscribe,destroy:e.destroy})),[e])},ga=e=>e.userSelectionActive?"none":"all";function ba({position:e,children:t,className:n,style:r,...o}){const a=ha(ga),i=`${e}`.split("-");return ht.createElement("div",{className:mt(["react-flow__panel",n,...i]),style:{...r,pointerEvents:a},...o},t)}function ya({proOptions:e,position:t="bottom-right"}){return e?.hideAttribution?null:ht.createElement(ba,{position:t,className:"react-flow__attribution","data-message":"Please only hide this attribution when you are subscribed to React Flow Pro: https://reactflow.dev/pro"},ht.createElement("a",{href:"https://reactflow.dev",target:"_blank",rel:"noopener noreferrer","aria-label":"React Flow attribution"},"React Flow"))}var va=(0,ht.memo)((({x:e,y:t,label:n,labelStyle:r={},labelShowBg:o=!0,labelBgStyle:a={},labelBgPadding:i=[2,4],labelBgBorderRadius:l=2,children:s,className:c,...u})=>{const d=(0,ht.useRef)(null),[f,p]=(0,ht.useState)({x:0,y:0,width:0,height:0}),h=mt(["react-flow__edge-textwrapper",c]);return(0,ht.useEffect)((()=>{if(d.current){const e=d.current.getBBox();p({x:e.x,y:e.y,width:e.width,height:e.height})}}),[n]),void 0!==n&&n?ht.createElement("g",{transform:`translate(${e-f.width/2} ${t-f.height/2})`,className:h,visibility:f.width?"visible":"hidden",...u},o&&ht.createElement("rect",{width:f.width+2*i[0],x:-i[0],y:-i[1],height:f.height+2*i[1],className:"react-flow__edge-textbg",style:a,rx:l,ry:l}),ht.createElement("text",{className:"react-flow__edge-text",y:f.height/2,dy:"0.3em",ref:d,style:r},n),s):null}));const wa=e=>({width:e.offsetWidth,height:e.offsetHeight}),_a=(e,t=0,n=1)=>Math.min(Math.max(e,t),n),Ea=(e={x:0,y:0},t)=>({x:_a(e.x,t[0][0],t[1][0]),y:_a(e.y,t[0][1],t[1][1])}),Sa=(e,t,n)=>en?-_a(Math.abs(e-n),1,50)/50:0,xa=(e,t)=>[20*Sa(e.x,35,t.width-35),20*Sa(e.y,35,t.height-35)],ka=e=>e.getRootNode?.()||window?.document,Ra=(e,t)=>({x:Math.min(e.x,t.x),y:Math.min(e.y,t.y),x2:Math.max(e.x2,t.x2),y2:Math.max(e.y2,t.y2)}),Ca=({x:e,y:t,width:n,height:r})=>({x:e,y:t,x2:e+n,y2:t+r}),Na=({x:e,y:t,x2:n,y2:r})=>({x:e,y:t,width:n-e,height:r-t}),Oa=e=>({...e.positionAbsolute||{x:0,y:0},width:e.width||0,height:e.height||0}),Aa=(e,t)=>{const n=Math.max(0,Math.min(e.x+e.width,t.x+t.width)-Math.max(e.x,t.x)),r=Math.max(0,Math.min(e.y+e.height,t.y+t.height)-Math.max(e.y,t.y));return Math.ceil(n*r)},Pa=e=>!isNaN(e)&&isFinite(e),Da=Symbol.for("internals"),Ta=["Enter"," ","Escape"],Ia=(e,t)=>{};function ja(e){const t=(e=>"nativeEvent"in e)(e)?e.nativeEvent:e,n=t.composedPath?.()?.[0]||e.target;return["INPUT","SELECT","TEXTAREA"].includes(n?.nodeName)||n?.hasAttribute("contenteditable")||!!n?.closest(".nokey")}const Ma=e=>"clientX"in e,$a=(e,t)=>{const n=Ma(e),r=n?e.clientX:e.touches?.[0].clientX,o=n?e.clientY:e.touches?.[0].clientY;return{x:r-(t?.left??0),y:o-(t?.top??0)}},La=()=>"undefined"!=typeof navigator&&navigator?.userAgent?.indexOf("Mac")>=0,Fa=({id:e,path:t,labelX:n,labelY:r,label:o,labelStyle:a,labelShowBg:i,labelBgStyle:l,labelBgPadding:s,labelBgBorderRadius:c,style:u,markerEnd:d,markerStart:f,interactionWidth:p=20})=>ht.createElement(ht.Fragment,null,ht.createElement("path",{id:e,style:u,d:t,fill:"none",className:"react-flow__edge-path",markerEnd:d,markerStart:f}),p&&ht.createElement("path",{d:t,fill:"none",strokeOpacity:0,strokeWidth:p,className:"react-flow__edge-interaction"}),o&&Pa(n)&&Pa(r)?ht.createElement(va,{x:n,y:r,label:o,labelStyle:a,labelShowBg:i,labelBgStyle:l,labelBgPadding:s,labelBgBorderRadius:c}):null);function za(e,t,n){return void 0===n?n:r=>{const o=t().edges.find((t=>t.id===e));o&&n(r,{...o})}}function Wa({sourceX:e,sourceY:t,targetX:n,targetY:r}){const o=Math.abs(n-e)/2,a=n{const[g,b,y]=Ka({sourceX:e,sourceY:t,sourcePosition:o,targetX:n,targetY:r,targetPosition:a});return ht.createElement(Fa,{path:g,labelX:b,labelY:y,label:i,labelStyle:l,labelShowBg:s,labelBgStyle:c,labelBgPadding:u,labelBgBorderRadius:d,style:f,markerEnd:p,markerStart:h,interactionWidth:m})}));Qa.displayName="SimpleBezierEdge";const Za={[Xa.Left]:{x:-1,y:0},[Xa.Right]:{x:1,y:0},[Xa.Top]:{x:0,y:-1},[Xa.Bottom]:{x:0,y:1}},Ja=(e,t)=>Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2));function ei({sourceX:e,sourceY:t,sourcePosition:n=Xa.Bottom,targetX:r,targetY:o,targetPosition:a=Xa.Top,borderRadius:i=5,centerX:l,centerY:s,offset:c=20}){const[u,d,f,p,h]=function({source:e,sourcePosition:t=Xa.Bottom,target:n,targetPosition:r=Xa.Top,center:o,offset:a}){const i=Za[t],l=Za[r],s={x:e.x+i.x*a,y:e.y+i.y*a},c={x:n.x+l.x*a,y:n.y+l.y*a},u=(({source:e,sourcePosition:t=Xa.Bottom,target:n})=>t===Xa.Left||t===Xa.Right?e.xe[d]?-1:1)*r:b[d]=(c[d]>n[d]?-1:1)*r}}if(t!==r){const e="x"===d?"y":"x",t=i[d]===l[e],n=s[e]>c[e],r=s[e]=Math.max(Math.abs(y.y-m[0].y),Math.abs(v.y-m[0].y))?(p=(y.x+v.x)/2,h=m[0].y):(p=m[0].x,h=(y.y+v.y)/2)}return[[e,{x:s.x+g.x,y:s.y+g.y},...m,{x:c.x+b.x,y:c.y+b.y},n],p,h,w,_]}({source:{x:e,y:t},sourcePosition:n,target:{x:r,y:o},targetPosition:a,center:{x:l,y:s},offset:c});return[u.reduce(((e,t,n)=>{let r="";return r=n>0&&n{const[b,y,v]=ei({sourceX:e,sourceY:t,sourcePosition:d,targetX:n,targetY:r,targetPosition:f,borderRadius:m?.borderRadius,offset:m?.offset});return ht.createElement(Fa,{path:b,labelX:y,labelY:v,label:o,labelStyle:a,labelShowBg:i,labelBgStyle:l,labelBgPadding:s,labelBgBorderRadius:c,style:u,markerEnd:p,markerStart:h,interactionWidth:g})}));ti.displayName="SmoothStepEdge";const ni=(0,ht.memo)((e=>ht.createElement(ti,{...e,pathOptions:(0,ht.useMemo)((()=>({borderRadius:0,offset:e.pathOptions?.offset})),[e.pathOptions?.offset])})));ni.displayName="StepEdge";const ri=(0,ht.memo)((({sourceX:e,sourceY:t,targetX:n,targetY:r,label:o,labelStyle:a,labelShowBg:i,labelBgStyle:l,labelBgPadding:s,labelBgBorderRadius:c,style:u,markerEnd:d,markerStart:f,interactionWidth:p})=>{const[h,m,g]=function({sourceX:e,sourceY:t,targetX:n,targetY:r}){const[o,a,i,l]=Wa({sourceX:e,sourceY:t,targetX:n,targetY:r});return[`M ${e},${t}L ${n},${r}`,o,a,i,l]}({sourceX:e,sourceY:t,targetX:n,targetY:r});return ht.createElement(Fa,{path:h,labelX:m,labelY:g,label:o,labelStyle:a,labelShowBg:i,labelBgStyle:l,labelBgPadding:s,labelBgBorderRadius:c,style:u,markerEnd:d,markerStart:f,interactionWidth:p})}));function oi(e,t){return e>=0?.5*e:25*t*Math.sqrt(-e)}function ai({pos:e,x1:t,y1:n,x2:r,y2:o,c:a}){switch(e){case Xa.Left:return[t-oi(t-r,a),n];case Xa.Right:return[t+oi(r-t,a),n];case Xa.Top:return[t,n-oi(n-o,a)];case Xa.Bottom:return[t,n+oi(o-n,a)]}}function ii({sourceX:e,sourceY:t,sourcePosition:n=Xa.Bottom,targetX:r,targetY:o,targetPosition:a=Xa.Top,curvature:i=.25}){const[l,s]=ai({pos:n,x1:e,y1:t,x2:r,y2:o,c:i}),[c,u]=ai({pos:a,x1:r,y1:o,x2:e,y2:t,c:i}),[d,f,p,h]=Ga({sourceX:e,sourceY:t,targetX:r,targetY:o,sourceControlX:l,sourceControlY:s,targetControlX:c,targetControlY:u});return[`M${e},${t} C${l},${s} ${c},${u} ${r},${o}`,d,f,p,h]}ri.displayName="StraightEdge";const li=(0,ht.memo)((({sourceX:e,sourceY:t,targetX:n,targetY:r,sourcePosition:o=Xa.Bottom,targetPosition:a=Xa.Top,label:i,labelStyle:l,labelShowBg:s,labelBgStyle:c,labelBgPadding:u,labelBgBorderRadius:d,style:f,markerEnd:p,markerStart:h,pathOptions:m,interactionWidth:g})=>{const[b,y,v]=ii({sourceX:e,sourceY:t,sourcePosition:o,targetX:n,targetY:r,targetPosition:a,curvature:m?.curvature});return ht.createElement(Fa,{path:b,labelX:y,labelY:v,label:i,labelStyle:l,labelShowBg:s,labelBgStyle:c,labelBgPadding:u,labelBgBorderRadius:d,style:f,markerEnd:p,markerStart:h,interactionWidth:g})}));li.displayName="BezierEdge";const si=(0,ht.createContext)(null),ci=si.Provider;si.Consumer;const ui=e=>"id"in e&&!("source"in e)&&!("target"in e),di=({source:e,sourceHandle:t,target:n,targetHandle:r})=>`reactflow__edge-${e}${t||""}-${n}${r||""}`,fi=(e,t)=>void 0===e?"":"string"==typeof e?e:`${t?`${t}__`:""}${Object.keys(e).sort().map((t=>`${t}=${e[t]}`)).join("&")}`,pi=(e,t)=>{if(!e.source||!e.target)return t;let n;var r;return n="id"in(r=e)&&"source"in r&&"target"in r?{...e}:{...e,id:di(e)},((e,t)=>t.some((t=>!(t.source!==e.source||t.target!==e.target||t.sourceHandle!==e.sourceHandle&&(t.sourceHandle||e.sourceHandle)||t.targetHandle!==e.targetHandle&&(t.targetHandle||e.targetHandle)))))(n,t)?t:t.concat(n)},hi=({x:e,y:t},[n,r,o],a,[i,l])=>{const s={x:(e-n)/o,y:(t-r)/o};return a?{x:i*Math.round(s.x/i),y:l*Math.round(s.y/l)}:s},mi=({x:e,y:t},[n,r,o])=>({x:e*o+n,y:t*o+r}),gi=(e,t=[0,0])=>{if(!e)return{x:0,y:0,positionAbsolute:{x:0,y:0}};const n=(e.width??0)*t[0],r=(e.height??0)*t[1],o={x:e.position.x-n,y:e.position.y-r};return{...o,positionAbsolute:e.positionAbsolute?{x:e.positionAbsolute.x-n,y:e.positionAbsolute.y-r}:o}},bi=(e,t=[0,0])=>{if(0===e.length)return{x:0,y:0,width:0,height:0};const n=e.reduce(((e,n)=>{const{x:r,y:o}=gi(n,t).positionAbsolute;return Ra(e,Ca({x:r,y:o,width:n.width||0,height:n.height||0}))}),{x:1/0,y:1/0,x2:-1/0,y2:-1/0});return Na(n)},yi=(e,t,[n,r,o]=[0,0,1],a=!1,i=!1,l=[0,0])=>{const s={x:(t.x-n)/o,y:(t.y-r)/o,width:t.width/o,height:t.height/o},c=[];return e.forEach((e=>{const{width:t,height:n,selectable:r=!0,hidden:o=!1}=e;if(i&&!r||o)return!1;const{positionAbsolute:u}=gi(e,l),d={x:u.x,y:u.y,width:t||0,height:n||0},f=Aa(s,d);(void 0===t||void 0===n||null===t||null===n||a&&f>0||f>=(t||0)*(n||0)||e.dragging)&&c.push(e)})),c},vi=(e,t)=>{const n=e.map((e=>e.id));return t.filter((e=>n.includes(e.source)||n.includes(e.target)))},wi=(e,t,n,r,o,a=.1)=>{const i=t/(e.width*(1+a)),l=n/(e.height*(1+a)),s=Math.min(i,l),c=_a(s,r,o);return{x:t/2-(e.x+e.width/2)*c,y:n/2-(e.y+e.height/2)*c,zoom:c}},_i=(e,t=0)=>e.transition().duration(t);function Ei(e,t,n,r){return(t[n]||[]).reduce(((t,o)=>(`${e.id}-${o.id}-${n}`!==r&&t.push({id:o.id||null,type:n,nodeId:e.id,x:(e.positionAbsolute?.x??0)+o.x+o.width/2,y:(e.positionAbsolute?.y??0)+o.y+o.height/2}),t)),[])}const Si={source:null,target:null,sourceHandle:null,targetHandle:null},xi=()=>({handleDomNode:null,isValid:!1,connection:Si,endHandle:null});function ki(e,t,n,r,o,a,i){const l="target"===o,s=i.querySelector(`.react-flow__handle[data-id="${e?.nodeId}-${e?.id}-${e?.type}"]`),c={...xi(),handleDomNode:s};if(s){const e=Ri(void 0,s),o=s.getAttribute("data-nodeid"),i=s.getAttribute("data-handleid"),u=s.classList.contains("connectable"),d=s.classList.contains("connectableend"),f={source:l?o:n,sourceHandle:l?i:r,target:l?n:o,targetHandle:l?r:i};c.connection=f,u&&d&&(t===Ba.Strict?l&&"source"===e||!l&&"target"===e:o!==n||i!==r)&&(c.endHandle={nodeId:o,handleId:i,type:e},c.isValid=a(f))}return c}function Ri(e,t){return e||(t?.classList.contains("target")?"target":t?.classList.contains("source")?"source":null)}function Ci(e){e?.classList.remove("valid","connecting","react-flow__handle-valid","react-flow__handle-connecting")}function Ni(e,t){let n=null;return t?n="valid":e&&!t&&(n="invalid"),n}function Oi({event:e,handleId:t,nodeId:n,onConnect:r,isTarget:o,getState:a,setState:i,isValidConnection:l,edgeUpdaterType:s,onReconnectEnd:c}){const u=ka(e.target),{connectionMode:d,domNode:f,autoPanOnConnect:p,connectionRadius:h,onConnectStart:m,panBy:g,getNodes:b,cancelConnection:y}=a();let v,w=0;const{x:_,y:E}=$a(e),S=u?.elementFromPoint(_,E),x=Ri(s,S),k=f?.getBoundingClientRect();if(!k||!x)return;let R,C=$a(e,k),N=!1,O=null,A=!1,P=null;const D=function({nodes:e,nodeId:t,handleId:n,handleType:r}){return e.reduce(((e,o)=>{if(o[Da]){const{handleBounds:a}=o[Da];let i=[],l=[];a&&(i=Ei(o,a,"source",`${t}-${n}-${r}`),l=Ei(o,a,"target",`${t}-${n}-${r}`)),e.push(...i,...l)}return e}),[])}({nodes:b(),nodeId:n,handleId:t,handleType:x}),T=()=>{if(!p)return;const[e,t]=xa(C,k);g({x:e,y:t}),w=requestAnimationFrame(T)};function I(e){const{transform:r}=a();C=$a(e,k);const{handle:s,validHandleResult:c}=function(e,t,n,r,o,a){const{x:i,y:l}=$a(e),s=t.elementsFromPoint(i,l).find((e=>e.classList.contains("react-flow__handle")));if(s){const e=s.getAttribute("data-nodeid");if(e){const t=Ri(void 0,s),r=s.getAttribute("data-handleid"),i=a({nodeId:e,id:r,type:t});if(i){const a=o.find((n=>n.nodeId===e&&n.type===t&&n.id===r));return{handle:{id:r,type:t,nodeId:e,x:a?.x||n.x,y:a?.y||n.y},validHandleResult:i}}}}let c=[],u=1/0;if(o.forEach((e=>{const t=Math.sqrt((e.x-n.x)**2+(e.y-n.y)**2);if(t<=r){const n=a(e);t<=u&&(te.isValid)),f=c.some((({handle:e})=>"target"===e.type));return c.find((({handle:e,validHandleResult:t})=>f?"target"===e.type:!d||t.isValid))||c[0]}(e,u,hi(C,r,!1,[1,1]),h,D,(e=>ki(e,d,n,t,o?"target":"source",l,u)));if(v=s,N||(T(),N=!0),P=c.handleDomNode,O=c.connection,A=c.isValid,i({connectionPosition:v&&A?mi({x:v.x,y:v.y},r):C,connectionStatus:Ni(!!v,A),connectionEndHandle:c.endHandle}),!v&&!A&&!P)return Ci(R);O.source!==O.target&&P&&(Ci(R),R=P,P.classList.add("connecting","react-flow__handle-connecting"),P.classList.toggle("valid",A),P.classList.toggle("react-flow__handle-valid",A))}function j(e){(v||P)&&O&&A&&r?.(O),a().onConnectEnd?.(e),s&&c?.(e),Ci(R),y(),cancelAnimationFrame(w),N=!1,A=!1,O=null,P=null,u.removeEventListener("mousemove",I),u.removeEventListener("mouseup",j),u.removeEventListener("touchmove",I),u.removeEventListener("touchend",j)}i({connectionPosition:C,connectionStatus:null,connectionNodeId:n,connectionHandleId:t,connectionHandleType:x,connectionStartHandle:{nodeId:n,handleId:t,type:x},connectionEndHandle:null}),m?.(e,{nodeId:n,handleId:t,handleType:x}),u.addEventListener("mousemove",I),u.addEventListener("mouseup",j),u.addEventListener("touchmove",I),u.addEventListener("touchend",j)}const Ai=()=>!0,Pi=e=>({connectionStartHandle:e.connectionStartHandle,connectOnClick:e.connectOnClick,noPanClassName:e.noPanClassName}),Di=(0,ht.forwardRef)((({type:e="source",position:t=Xa.Top,isValidConnection:n,isConnectable:r=!0,isConnectableStart:o=!0,isConnectableEnd:a=!0,id:i,onConnect:l,children:s,className:c,onMouseDown:u,onTouchStart:d,...f},p)=>{const h=i||null,m="target"===e,g=ma(),b=(0,ht.useContext)(si),{connectOnClick:y,noPanClassName:v}=ha(Pi,St),{connecting:w,clickConnecting:_}=ha(((e,t,n)=>r=>{const{connectionStartHandle:o,connectionEndHandle:a,connectionClickStartHandle:i}=r;return{connecting:o?.nodeId===e&&o?.handleId===t&&o?.type===n||a?.nodeId===e&&a?.handleId===t&&a?.type===n,clickConnecting:i?.nodeId===e&&i?.handleId===t&&i?.type===n}})(b,h,e),St);b||g.getState().onError?.("010","Handle: No node id found. Make sure to only use a Handle inside a custom Node.");const E=e=>{const{defaultEdgeOptions:t,onConnect:n,hasDefaultEdges:r}=g.getState(),o={...t,...e};if(r){const{edges:e,setEdges:t}=g.getState();t(pi(o,e))}n?.(o),l?.(o)},S=e=>{if(!b)return;const t=Ma(e);o&&(t&&0===e.button||!t)&&Oi({event:e,handleId:h,nodeId:b,onConnect:E,isTarget:m,getState:g.getState,setState:g.setState,isValidConnection:n||g.getState().isValidConnection||Ai}),t?u?.(e):d?.(e)};return ht.createElement("div",{"data-handleid":h,"data-nodeid":b,"data-handlepos":t,"data-id":`${b}-${h}-${e}`,className:mt(["react-flow__handle",`react-flow__handle-${t}`,"nodrag",v,c,{source:!m,target:m,connectable:r,connectablestart:o,connectableend:a,connecting:_,connectionindicator:r&&(o&&!w||a&&w)}]),onMouseDown:S,onTouchStart:S,onClick:y?t=>{const{onClickConnectStart:r,onClickConnectEnd:a,connectionClickStartHandle:i,connectionMode:l,isValidConnection:s}=g.getState();if(!b||!i&&!o)return;if(!i)return r?.(t,{nodeId:b,handleId:h,handleType:e}),void g.setState({connectionClickStartHandle:{nodeId:b,type:e,handleId:h}});const c=ka(t.target),u=n||s||Ai,{connection:d,isValid:f}=ki({nodeId:b,id:h,type:e},l,i.nodeId,i.handleId||null,i.type,u,c);f&&E(d),a?.(t),g.setState({connectionClickStartHandle:null})}:void 0,ref:p,...f},s)}));Di.displayName="Handle";var Ti=(0,ht.memo)(Di);const Ii=({data:e,isConnectable:t,targetPosition:n=Xa.Top,sourcePosition:r=Xa.Bottom})=>ht.createElement(ht.Fragment,null,ht.createElement(Ti,{type:"target",position:n,isConnectable:t}),e?.label,ht.createElement(Ti,{type:"source",position:r,isConnectable:t}));Ii.displayName="DefaultNode";var ji=(0,ht.memo)(Ii);const Mi=({data:e,isConnectable:t,sourcePosition:n=Xa.Bottom})=>ht.createElement(ht.Fragment,null,e?.label,ht.createElement(Ti,{type:"source",position:n,isConnectable:t}));Mi.displayName="InputNode";var $i=(0,ht.memo)(Mi);const Li=({data:e,isConnectable:t,targetPosition:n=Xa.Top})=>ht.createElement(ht.Fragment,null,ht.createElement(Ti,{type:"target",position:n,isConnectable:t}),e?.label);Li.displayName="OutputNode";var Fi=(0,ht.memo)(Li);const zi=()=>null;zi.displayName="GroupNode";const Wi=e=>({selectedNodes:e.getNodes().filter((e=>e.selected)),selectedEdges:e.edges.filter((e=>e.selected)).map((e=>({...e})))}),Gi=e=>e.id;function Bi(e,t){return St(e.selectedNodes.map(Gi),t.selectedNodes.map(Gi))&&St(e.selectedEdges.map(Gi),t.selectedEdges.map(Gi))}const Vi=(0,ht.memo)((({onSelectionChange:e})=>{const t=ma(),{selectedNodes:n,selectedEdges:r}=ha(Wi,Bi);return(0,ht.useEffect)((()=>{const o={nodes:n,edges:r};e?.(o),t.getState().onSelectionChange.forEach((e=>e(o)))}),[n,r,e]),null}));Vi.displayName="SelectionListener";const Hi=e=>!!e.onSelectionChange;function Ui({onSelectionChange:e}){const t=ha(Hi);return e||t?ht.createElement(Vi,{onSelectionChange:e}):null}const qi=e=>({setNodes:e.setNodes,setEdges:e.setEdges,setDefaultNodesAndEdges:e.setDefaultNodesAndEdges,setMinZoom:e.setMinZoom,setMaxZoom:e.setMaxZoom,setTranslateExtent:e.setTranslateExtent,setNodeExtent:e.setNodeExtent,reset:e.reset});function Xi(e,t){(0,ht.useEffect)((()=>{void 0!==e&&t(e)}),[e])}function Yi(e,t,n){(0,ht.useEffect)((()=>{void 0!==t&&n({[e]:t})}),[t])}const Ki=({nodes:e,edges:t,defaultNodes:n,defaultEdges:r,onConnect:o,onConnectStart:a,onConnectEnd:i,onClickConnectStart:l,onClickConnectEnd:s,nodesDraggable:c,nodesConnectable:u,nodesFocusable:d,edgesFocusable:f,edgesUpdatable:p,elevateNodesOnSelect:h,minZoom:m,maxZoom:g,nodeExtent:b,onNodesChange:y,onEdgesChange:v,elementsSelectable:w,connectionMode:_,snapGrid:E,snapToGrid:S,translateExtent:x,connectOnClick:k,defaultEdgeOptions:R,fitView:C,fitViewOptions:N,onNodesDelete:O,onEdgesDelete:A,onNodeDrag:P,onNodeDragStart:D,onNodeDragStop:T,onSelectionDrag:I,onSelectionDragStart:j,onSelectionDragStop:M,noPanClassName:$,nodeOrigin:L,rfId:F,autoPanOnConnect:z,autoPanOnNodeDrag:W,onError:G,connectionRadius:B,isValidConnection:V,nodeDragThreshold:H})=>{const{setNodes:U,setEdges:q,setDefaultNodesAndEdges:X,setMinZoom:Y,setMaxZoom:K,setTranslateExtent:Q,setNodeExtent:Z,reset:J}=ha(qi,St),ee=ma();return(0,ht.useEffect)((()=>{const e=r?.map((e=>({...e,...R})));return X(n,e),()=>{J()}}),[]),Yi("defaultEdgeOptions",R,ee.setState),Yi("connectionMode",_,ee.setState),Yi("onConnect",o,ee.setState),Yi("onConnectStart",a,ee.setState),Yi("onConnectEnd",i,ee.setState),Yi("onClickConnectStart",l,ee.setState),Yi("onClickConnectEnd",s,ee.setState),Yi("nodesDraggable",c,ee.setState),Yi("nodesConnectable",u,ee.setState),Yi("nodesFocusable",d,ee.setState),Yi("edgesFocusable",f,ee.setState),Yi("edgesUpdatable",p,ee.setState),Yi("elementsSelectable",w,ee.setState),Yi("elevateNodesOnSelect",h,ee.setState),Yi("snapToGrid",S,ee.setState),Yi("snapGrid",E,ee.setState),Yi("onNodesChange",y,ee.setState),Yi("onEdgesChange",v,ee.setState),Yi("connectOnClick",k,ee.setState),Yi("fitViewOnInit",C,ee.setState),Yi("fitViewOnInitOptions",N,ee.setState),Yi("onNodesDelete",O,ee.setState),Yi("onEdgesDelete",A,ee.setState),Yi("onNodeDrag",P,ee.setState),Yi("onNodeDragStart",D,ee.setState),Yi("onNodeDragStop",T,ee.setState),Yi("onSelectionDrag",I,ee.setState),Yi("onSelectionDragStart",j,ee.setState),Yi("onSelectionDragStop",M,ee.setState),Yi("noPanClassName",$,ee.setState),Yi("nodeOrigin",L,ee.setState),Yi("rfId",F,ee.setState),Yi("autoPanOnConnect",z,ee.setState),Yi("autoPanOnNodeDrag",W,ee.setState),Yi("onError",G,ee.setState),Yi("connectionRadius",B,ee.setState),Yi("isValidConnection",V,ee.setState),Yi("nodeDragThreshold",H,ee.setState),Xi(e,U),Xi(t,q),Xi(m,Y),Xi(g,K),Xi(x,Q),Xi(b,Z),null},Qi={display:"none"},Zi={position:"absolute",width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0px, 0px, 0px, 0px)",clipPath:"inset(100%)"},Ji="react-flow__node-desc",el="react-flow__edge-desc",tl=e=>e.ariaLiveMessage;function nl({rfId:e}){const t=ha(tl);return ht.createElement("div",{id:`react-flow__aria-live-${e}`,"aria-live":"assertive","aria-atomic":"true",style:Zi},t)}function rl({rfId:e,disableKeyboardA11y:t}){return ht.createElement(ht.Fragment,null,ht.createElement("div",{id:`${Ji}-${e}`,style:Qi},"Press enter or space to select a node.",!t&&"You can then use the arrow keys to move the node around."," Press delete to remove it and escape to cancel."," "),ht.createElement("div",{id:`${el}-${e}`,style:Qi},"Press enter or space to select an edge. You can then press delete to remove it or escape to cancel."),!t&&ht.createElement(nl,{rfId:e}))}var ol=(e=null,t={actInsideInputWithModifier:!0})=>{const[n,r]=(0,ht.useState)(!1),o=(0,ht.useRef)(!1),a=(0,ht.useRef)(new Set([])),[i,l]=(0,ht.useMemo)((()=>{if(null!==e){const t=(Array.isArray(e)?e:[e]).filter((e=>"string"==typeof e)).map((e=>e.split("+"))),n=t.reduce(((e,t)=>e.concat(...t)),[]);return[t,n]}return[[],[]]}),[e]);return(0,ht.useEffect)((()=>{const n="undefined"!=typeof document?document:null,s=t?.target||n;if(null!==e){const e=e=>{if(o.current=e.ctrlKey||e.metaKey||e.shiftKey,(!o.current||o.current&&!t.actInsideInputWithModifier)&&ja(e))return!1;const n=il(e.code,l);a.current.add(e[n]),al(i,a.current,!1)&&(e.preventDefault(),r(!0))},n=e=>{if((!o.current||o.current&&!t.actInsideInputWithModifier)&&ja(e))return!1;const n=il(e.code,l);al(i,a.current,!0)?(r(!1),a.current.clear()):a.current.delete(e[n]),"Meta"===e.key&&a.current.clear(),o.current=!1},c=()=>{a.current.clear(),r(!1)};return s?.addEventListener("keydown",e),s?.addEventListener("keyup",n),window.addEventListener("blur",c),()=>{s?.removeEventListener("keydown",e),s?.removeEventListener("keyup",n),window.removeEventListener("blur",c)}}}),[e,r]),n};function al(e,t,n){return e.filter((e=>n||e.length===t.size)).some((e=>e.every((e=>t.has(e)))))}function il(e,t){return t.includes(e)?"code":"key"}function ll(e,t,n,r){const o=e.parentNode||e.parentId;if(!o)return n;const a=t.get(o),i=gi(a,r);return ll(a,t,{x:(n.x??0)+i.x,y:(n.y??0)+i.y,z:(a[Da]?.z??0)>(n.z??0)?a[Da]?.z??0:n.z??0},r)}function sl(e,t,n){e.forEach((r=>{const o=r.parentNode||r.parentId;if(o&&!e.has(o))throw new Error(`Parent node ${o} not found`);if(o||n?.[r.id]){const{x:o,y:a,z:i}=ll(r,e,{...r.position,z:r[Da]?.z??0},t);r.positionAbsolute={x:o,y:a},r[Da].z=i,n?.[r.id]&&(r[Da].isParent=!0)}}))}function cl(e,t,n,r){const o=new Map,a={},i=r?1e3:0;return e.forEach((e=>{const n=(Pa(e.zIndex)?e.zIndex:0)+(e.selected?i:0),r=t.get(e.id),l={...e,positionAbsolute:{x:e.position.x,y:e.position.y}},s=e.parentNode||e.parentId;s&&(a[s]=!0);const c=r?.type&&r?.type!==e.type;Object.defineProperty(l,Da,{enumerable:!1,value:{handleBounds:c?void 0:r?.[Da]?.handleBounds,z:n}}),o.set(e.id,l)})),sl(o,n,a),o}function ul(e,t={}){const{getNodes:n,width:r,height:o,minZoom:a,maxZoom:i,d3Zoom:l,d3Selection:s,fitViewOnInitDone:c,fitViewOnInit:u,nodeOrigin:d}=e(),f=t.initial&&!c&&u;if(l&&s&&(f||!t.initial)){const e=n().filter((e=>{const n=t.includeHiddenNodes?e.width&&e.height:!e.hidden;return t.nodes?.length?n&&t.nodes.some((t=>t.id===e.id)):n})),c=e.every((e=>e.width&&e.height));if(e.length>0&&c){const n=bi(e,d),{x:c,y:u,zoom:f}=wi(n,r,o,t.minZoom??a,t.maxZoom??i,t.padding??.1),p=Xo.translate(c,u).scale(f);return"number"==typeof t.duration&&t.duration>0?l.transform(_i(s,t.duration),p):l.transform(s,p),!0}}return!1}function dl(e,t){return e.forEach((e=>{const n=t.get(e.id);n&&t.set(n.id,{...n,[Da]:n[Da],selected:e.selected})})),new Map(t)}function fl(e,t){return t.map((t=>{const n=e.find((e=>e.id===t.id));return n&&(t.selected=n.selected),t}))}function pl({changedNodes:e,changedEdges:t,get:n,set:r}){const{nodeInternals:o,edges:a,onNodesChange:i,onEdgesChange:l,hasDefaultNodes:s,hasDefaultEdges:c}=n();e?.length&&(s&&r({nodeInternals:dl(e,o)}),i?.(e)),t?.length&&(c&&r({edges:fl(t,a)}),l?.(t))}const hl=()=>{},ml={zoomIn:hl,zoomOut:hl,zoomTo:hl,getZoom:()=>1,setViewport:hl,getViewport:()=>({x:0,y:0,zoom:1}),fitView:()=>!1,setCenter:hl,fitBounds:hl,project:e=>e,screenToFlowPosition:e=>e,flowToScreenPosition:e=>e,viewportInitialized:!1},gl=e=>({d3Zoom:e.d3Zoom,d3Selection:e.d3Selection});function bl(){const e=(()=>{const e=ma(),{d3Zoom:t,d3Selection:n}=ha(gl,St),r=(0,ht.useMemo)((()=>n&&t?{zoomIn:e=>t.scaleBy(_i(n,e?.duration),1.2),zoomOut:e=>t.scaleBy(_i(n,e?.duration),1/1.2),zoomTo:(e,r)=>t.scaleTo(_i(n,r?.duration),e),getZoom:()=>e.getState().transform[2],setViewport:(r,o)=>{const[a,i,l]=e.getState().transform,s=Xo.translate(r.x??a,r.y??i).scale(r.zoom??l);t.transform(_i(n,o?.duration),s)},getViewport:()=>{const[t,n,r]=e.getState().transform;return{x:t,y:n,zoom:r}},fitView:t=>ul(e.getState,t),setCenter:(r,o,a)=>{const{width:i,height:l,maxZoom:s}=e.getState(),c=void 0!==a?.zoom?a.zoom:s,u=i/2-r*c,d=l/2-o*c,f=Xo.translate(u,d).scale(c);t.transform(_i(n,a?.duration),f)},fitBounds:(r,o)=>{const{width:a,height:i,minZoom:l,maxZoom:s}=e.getState(),{x:c,y:u,zoom:d}=wi(r,a,i,l,s,o?.padding??.1),f=Xo.translate(c,u).scale(d);t.transform(_i(n,o?.duration),f)},project:t=>{const{transform:n,snapToGrid:r,snapGrid:o}=e.getState();return console.warn("[DEPRECATED] `project` is deprecated. Instead use `screenToFlowPosition`. There is no need to subtract the react flow bounds anymore! https://reactflow.dev/api-reference/types/react-flow-instance#screen-to-flow-position"),hi(t,n,r,o)},screenToFlowPosition:t=>{const{transform:n,snapToGrid:r,snapGrid:o,domNode:a}=e.getState();if(!a)return t;const{x:i,y:l}=a.getBoundingClientRect(),s={x:t.x-i,y:t.y-l};return hi(s,n,r,o)},flowToScreenPosition:t=>{const{transform:n,domNode:r}=e.getState();if(!r)return t;const{x:o,y:a}=r.getBoundingClientRect(),i=mi(t,n);return{x:i.x+o,y:i.y+a}},viewportInitialized:!0}:ml),[t,n]);return r})(),t=ma(),n=(0,ht.useCallback)((()=>t.getState().getNodes().map((e=>({...e})))),[]),r=(0,ht.useCallback)((e=>t.getState().nodeInternals.get(e)),[]),o=(0,ht.useCallback)((()=>{const{edges:e=[]}=t.getState();return e.map((e=>({...e})))}),[]),a=(0,ht.useCallback)((e=>{const{edges:n=[]}=t.getState();return n.find((t=>t.id===e))}),[]),i=(0,ht.useCallback)((e=>{const{getNodes:n,setNodes:r,hasDefaultNodes:o,onNodesChange:a}=t.getState(),i=n(),l="function"==typeof e?e(i):e;if(o)r(l);else if(a){a(0===l.length?i.map((e=>({type:"remove",id:e.id}))):l.map((e=>({item:e,type:"reset"}))))}}),[]),l=(0,ht.useCallback)((e=>{const{edges:n=[],setEdges:r,hasDefaultEdges:o,onEdgesChange:a}=t.getState(),i="function"==typeof e?e(n):e;o?r(i):a&&a(0===i.length?n.map((e=>({type:"remove",id:e.id}))):i.map((e=>({item:e,type:"reset"}))))}),[]),s=(0,ht.useCallback)((e=>{const n=Array.isArray(e)?e:[e],{getNodes:r,setNodes:o,hasDefaultNodes:a,onNodesChange:i}=t.getState();if(a)o([...r(),...n]);else if(i){i(n.map((e=>({item:e,type:"add"}))))}}),[]),c=(0,ht.useCallback)((e=>{const n=Array.isArray(e)?e:[e],{edges:r=[],setEdges:o,hasDefaultEdges:a,onEdgesChange:i}=t.getState();a?o([...r,...n]):i&&i(n.map((e=>({item:e,type:"add"}))))}),[]),u=(0,ht.useCallback)((()=>{const{getNodes:e,edges:n=[],transform:r}=t.getState(),[o,a,i]=r;return{nodes:e().map((e=>({...e}))),edges:n.map((e=>({...e}))),viewport:{x:o,y:a,zoom:i}}}),[]),d=(0,ht.useCallback)((({nodes:e,edges:n})=>{const{nodeInternals:r,getNodes:o,edges:a,hasDefaultNodes:i,hasDefaultEdges:l,onNodesDelete:s,onEdgesDelete:c,onNodesChange:u,onEdgesChange:d}=t.getState(),f=(e||[]).map((e=>e.id)),p=(n||[]).map((e=>e.id)),h=o().reduce(((e,t)=>{const n=t.parentNode||t.parentId,r=!f.includes(t.id)&&n&&e.find((e=>e.id===n));return("boolean"!=typeof t.deletable||t.deletable)&&(f.includes(t.id)||r)&&e.push(t),e}),[]),m=a.filter((e=>"boolean"!=typeof e.deletable||e.deletable)),g=m.filter((e=>p.includes(e.id)));if(h||g){const e=vi(h,m),n=[...g,...e],o=n.reduce(((e,t)=>(e.includes(t.id)||e.push(t.id),e)),[]);(l||i)&&(l&&t.setState({edges:a.filter((e=>!o.includes(e.id)))}),i&&(h.forEach((e=>{r.delete(e.id)})),t.setState({nodeInternals:new Map(r)}))),o.length>0&&(c?.(n),d&&d(o.map((e=>({id:e,type:"remove"}))))),h.length>0&&(s?.(h),u)&&u(h.map((e=>({id:e.id,type:"remove"}))))}}),[]),f=(0,ht.useCallback)((e=>{const n=Pa((r=e).width)&&Pa(r.height)&&Pa(r.x)&&Pa(r.y);var r;const o=n?null:t.getState().nodeInternals.get(e.id);return n||o?[n?e:Oa(o),o,n]:[null,null,n]}),[]),p=(0,ht.useCallback)(((e,n=!0,r)=>{const[o,a,i]=f(e);return o?(r||t.getState().getNodes()).filter((e=>{if(!(i||e.id!==a.id&&e.positionAbsolute))return!1;const t=Oa(e),r=Aa(t,o);return n&&r>0||r>=o.width*o.height})):[]}),[]),h=(0,ht.useCallback)(((e,t,n=!0)=>{const[r]=f(e);if(!r)return!1;const o=Aa(r,t);return n&&o>0||o>=r.width*r.height}),[]);return(0,ht.useMemo)((()=>({...e,getNodes:n,getNode:r,getEdges:o,getEdge:a,setNodes:i,setEdges:l,addNodes:s,addEdges:c,toObject:u,deleteElements:d,getIntersectingNodes:p,isNodeIntersecting:h})),[e,n,r,o,a,i,l,s,c,u,d,p,h])}const yl={actInsideInputWithModifier:!1},vl={position:"absolute",width:"100%",height:"100%",top:0,left:0},wl=e=>({x:e.x,y:e.y,zoom:e.k}),_l=(e,t)=>e.target.closest(`.${t}`),El=(e,t)=>2===t&&Array.isArray(e)&&e.includes(2),Sl=e=>{const t=e.ctrlKey&&La()?10:1;return-e.deltaY*(1===e.deltaMode?.05:e.deltaMode?1:.002)*t},xl=e=>({d3Zoom:e.d3Zoom,d3Selection:e.d3Selection,d3ZoomHandler:e.d3ZoomHandler,userSelectionActive:e.userSelectionActive}),kl=({onMove:e,onMoveStart:t,onMoveEnd:n,onPaneContextMenu:r,zoomOnScroll:o=!0,zoomOnPinch:a=!0,panOnScroll:i=!1,panOnScrollSpeed:l=.5,panOnScrollMode:s=Va.Free,zoomOnDoubleClick:c=!0,elementsSelectable:u,panOnDrag:d=!0,defaultViewport:f,translateExtent:p,minZoom:h,maxZoom:m,zoomActivationKeyCode:g,preventScrolling:b=!0,children:y,noWheelClassName:v,noPanClassName:w})=>{const _=(0,ht.useRef)(),E=ma(),S=(0,ht.useRef)(!1),x=(0,ht.useRef)(!1),k=(0,ht.useRef)(null),R=(0,ht.useRef)({x:0,y:0,zoom:0}),{d3Zoom:C,d3Selection:N,d3ZoomHandler:O,userSelectionActive:A}=ha(xl,St),P=ol(g),D=(0,ht.useRef)(0),T=(0,ht.useRef)(!1),I=(0,ht.useRef)();return function(e){const t=ma();(0,ht.useEffect)((()=>{let n;const r=()=>{if(!e.current)return;const n=wa(e.current);0!==n.height&&0!==n.width||t.getState().onError?.("004","The React Flow parent container needs a width and a height to render the graph."),t.setState({width:n.width||500,height:n.height||500})};return r(),window.addEventListener("resize",r),e.current&&(n=new ResizeObserver((()=>r())),n.observe(e.current)),()=>{window.removeEventListener("resize",r),n&&e.current&&n.unobserve(e.current)}}),[])}(k),(0,ht.useEffect)((()=>{if(k.current){const e=k.current.getBoundingClientRect(),t=ra().scaleExtent([h,m]).translateExtent(p),n=Bn(k.current).call(t),r=Xo.translate(f.x,f.y).scale(_a(f.zoom,h,m)),o=[[0,0],[e.width,e.height]],a=t.constrain()(r,o,p);t.transform(n,a),t.wheelDelta(Sl),E.setState({d3Zoom:t,d3Selection:n,d3ZoomHandler:n.on("wheel.zoom"),transform:[a.x,a.y,a.k],domNode:k.current.closest(".react-flow")})}}),[]),(0,ht.useEffect)((()=>{N&&C&&(!i||P||A?void 0!==O&&N.on("wheel.zoom",(function(e,t){if(!b&&"wheel"===e.type&&!e.ctrlKey||_l(e,v))return null;e.preventDefault(),O.call(this,e,t)}),{passive:!1}):N.on("wheel.zoom",(r=>{if(_l(r,v))return!1;r.preventDefault(),r.stopImmediatePropagation();const o=N.property("__zoom").k||1;if(r.ctrlKey&&a){const e=Zn(r),t=Sl(r),n=o*Math.pow(2,t);return void C.scaleTo(N,n,e,r)}const i=1===r.deltaMode?20:1;let c=s===Va.Vertical?0:r.deltaX*i,u=s===Va.Horizontal?0:r.deltaY*i;!La()&&r.shiftKey&&s!==Va.Vertical&&(c=r.deltaY*i,u=0),C.translateBy(N,-c/o*l,-u/o*l,{internal:!0});const d=wl(N.property("__zoom")),{onViewportChangeStart:f,onViewportChange:p,onViewportChangeEnd:h}=E.getState();clearTimeout(I.current),T.current||(T.current=!0,t?.(r,d),f?.(d)),T.current&&(e?.(r,d),p?.(d),I.current=setTimeout((()=>{n?.(r,d),h?.(d),T.current=!1}),150))}),{passive:!1}))}),[A,i,s,N,C,O,P,a,b,v,t,e,n]),(0,ht.useEffect)((()=>{C&&C.on("start",(e=>{if(!e.sourceEvent||e.sourceEvent.internal)return null;D.current=e.sourceEvent?.button;const{onViewportChangeStart:n}=E.getState(),r=wl(e.transform);S.current=!0,R.current=r,"mousedown"===e.sourceEvent?.type&&E.setState({paneDragging:!0}),n?.(r),t?.(e.sourceEvent,r)}))}),[C,t]),(0,ht.useEffect)((()=>{C&&(A&&!S.current?C.on("zoom",null):A||C.on("zoom",(t=>{const{onViewportChange:n}=E.getState();if(E.setState({transform:[t.transform.x,t.transform.y,t.transform.k]}),x.current=!(!r||!El(d,D.current??0)),(e||n)&&!t.sourceEvent?.internal){const r=wl(t.transform);n?.(r),e?.(t.sourceEvent,r)}})))}),[A,C,e,d,r]),(0,ht.useEffect)((()=>{C&&C.on("end",(e=>{if(!e.sourceEvent||e.sourceEvent.internal)return null;const{onViewportChangeEnd:t}=E.getState();if(S.current=!1,E.setState({paneDragging:!1}),r&&El(d,D.current??0)&&!x.current&&r(e.sourceEvent),x.current=!1,(n||t)&&(o=R.current,a=e.transform,o.x!==a.x||o.y!==a.y||o.zoom!==a.k)){const r=wl(e.transform);R.current=r,clearTimeout(_.current),_.current=setTimeout((()=>{t?.(r),n?.(e.sourceEvent,r)}),i?150:0)}var o,a}))}),[C,i,d,n,r]),(0,ht.useEffect)((()=>{C&&C.filter((e=>{const t=P||o,n=a&&e.ctrlKey;if((!0===d||Array.isArray(d)&&d.includes(1))&&1===e.button&&"mousedown"===e.type&&(_l(e,"react-flow__node")||_l(e,"react-flow__edge")))return!0;if(!(d||t||i||c||a))return!1;if(A)return!1;if(!c&&"dblclick"===e.type)return!1;if(_l(e,v)&&"wheel"===e.type)return!1;if(_l(e,w)&&("wheel"!==e.type||i&&"wheel"===e.type&&!P))return!1;if(!a&&e.ctrlKey&&"wheel"===e.type)return!1;if(!t&&!i&&!n&&"wheel"===e.type)return!1;if(!d&&("mousedown"===e.type||"touchstart"===e.type))return!1;if(Array.isArray(d)&&!d.includes(e.button)&&"mousedown"===e.type)return!1;const r=Array.isArray(d)&&d.includes(e.button)||!e.button||e.button<=1;return(!e.ctrlKey||"wheel"===e.type)&&r}))}),[A,C,o,a,i,c,d,u,P]),ht.createElement("div",{className:"react-flow__renderer",ref:k,style:vl},y)},Rl=e=>({userSelectionActive:e.userSelectionActive,userSelectionRect:e.userSelectionRect});function Cl(){const{userSelectionActive:e,userSelectionRect:t}=ha(Rl,St);return e&&t?ht.createElement("div",{className:"react-flow__selection react-flow__container",style:{width:t.width,height:t.height,transform:`translate(${t.x}px, ${t.y}px)`}}):null}function Nl(e,t){const n=t.parentNode||t.parentId,r=e.find((e=>e.id===n));if(r){const e=t.position.x+t.width-r.width,n=t.position.y+t.height-r.height;if(e>0||n>0||t.position.x<0||t.position.y<0){if(r.style={...r.style}||{},r.style.width=r.style.width??r.width,r.style.height=r.style.height??r.height,e>0&&(r.style.width+=e),n>0&&(r.style.height+=n),t.position.x<0){const e=Math.abs(t.position.x);r.position.x=r.position.x-e,r.style.width+=e,t.position.x=0}if(t.position.y<0){const e=Math.abs(t.position.y);r.position.y=r.position.y-e,r.style.height+=e,t.position.y=0}r.width=r.style.width,r.height=r.style.height}}}function Ol(e,t){if(e.some((e=>"reset"===e.type)))return e.filter((e=>"reset"===e.type)).map((e=>e.item));const n=e.filter((e=>"add"===e.type)).map((e=>e.item));return t.reduce(((t,n)=>{const r=e.filter((e=>e.id===n.id));if(0===r.length)return t.push(n),t;const o={...n};for(const e of r)if(e)switch(e.type){case"select":o.selected=e.selected;break;case"position":void 0!==e.position&&(o.position=e.position),void 0!==e.positionAbsolute&&(o.positionAbsolute=e.positionAbsolute),void 0!==e.dragging&&(o.dragging=e.dragging),o.expandParent&&Nl(t,o);break;case"dimensions":void 0!==e.dimensions&&(o.width=e.dimensions.width,o.height=e.dimensions.height),void 0!==e.updateStyle&&(o.style={...o.style||{},...e.dimensions}),"boolean"==typeof e.resizing&&(o.resizing=e.resizing),o.expandParent&&Nl(t,o);break;case"remove":return t}return t.push(o),t}),n)}function Al(e,t){return Ol(e,t)}function Pl(e,t){return Ol(e,t)}const Dl=(e,t)=>({id:e,type:"select",selected:t});function Tl(e,t){return e.reduce(((e,n)=>{const r=t.includes(n.id);return!n.selected&&r?(n.selected=!0,e.push(Dl(n.id,!0))):n.selected&&!r&&(n.selected=!1,e.push(Dl(n.id,!1))),e}),[])}const Il=(e,t)=>n=>{n.target===t.current&&e?.(n)},jl=e=>({userSelectionActive:e.userSelectionActive,elementsSelectable:e.elementsSelectable,dragging:e.paneDragging}),Ml=(0,ht.memo)((({isSelecting:e,selectionMode:t=Ha.Full,panOnDrag:n,onSelectionStart:r,onSelectionEnd:o,onPaneClick:a,onPaneContextMenu:i,onPaneScroll:l,onPaneMouseEnter:s,onPaneMouseMove:c,onPaneMouseLeave:u,children:d})=>{const f=(0,ht.useRef)(null),p=ma(),h=(0,ht.useRef)(0),m=(0,ht.useRef)(0),g=(0,ht.useRef)(),{userSelectionActive:b,elementsSelectable:y,dragging:v}=ha(jl,St),w=()=>{p.setState({userSelectionActive:!1,userSelectionRect:null}),h.current=0,m.current=0},_=e=>{a?.(e),p.getState().resetSelectedElements(),p.setState({nodesSelectionActive:!1})},E=l?e=>l(e):void 0,S=y&&(e||b);return ht.createElement("div",{className:mt(["react-flow__pane",{dragging:v,selection:e}]),onClick:S?void 0:Il(_,f),onContextMenu:Il((e=>{Array.isArray(n)&&n?.includes(2)?e.preventDefault():i?.(e)}),f),onWheel:Il(E,f),onMouseEnter:S?void 0:s,onMouseDown:S?t=>{const{resetSelectedElements:n,domNode:o}=p.getState();if(g.current=o?.getBoundingClientRect(),!y||!e||0!==t.button||t.target!==f.current||!g.current)return;const{x:a,y:i}=$a(t,g.current);n(),p.setState({userSelectionRect:{width:0,height:0,startX:a,startY:i,x:a,y:i}}),r?.(t)}:void 0,onMouseMove:S?n=>{const{userSelectionRect:r,nodeInternals:o,edges:a,transform:i,onNodesChange:l,onEdgesChange:s,nodeOrigin:c,getNodes:u}=p.getState();if(!e||!g.current||!r)return;p.setState({userSelectionActive:!0,nodesSelectionActive:!1});const d=$a(n,g.current),f=r.startX??0,b=r.startY??0,y={...r,x:d.xe.id)),E=w.map((e=>e.id));if(h.current!==E.length){h.current=E.length;const e=Tl(v,E);e.length&&l?.(e)}if(m.current!==_.length){m.current=_.length;const e=Tl(a,_);e.length&&s?.(e)}p.setState({userSelectionRect:y})}:c,onMouseUp:S?e=>{if(0!==e.button)return;const{userSelectionRect:t}=p.getState();!b&&t&&e.target===f.current&&_?.(e),p.setState({nodesSelectionActive:h.current>0}),w(),o?.(e)}:void 0,onMouseLeave:S?e=>{b&&(p.setState({nodesSelectionActive:h.current>0}),o?.(e)),w()}:u,ref:f,style:vl},d,ht.createElement(Cl,null))}));function $l(e,t){const n=e.parentNode||e.parentId;if(!n)return!1;const r=t.get(n);return!!r&&(!!r.selected||$l(r,t))}function Ll(e,t,n){let r=e;do{if(r?.matches(t))return!0;if(r===n.current)return!1;r=r.parentElement}while(r);return!1}function Fl(e,t,n,r){return Array.from(e.values()).filter((n=>(n.selected||n.id===r)&&(!n.parentNode||n.parentId||!$l(n,e))&&(n.draggable||t&&void 0===n.draggable))).map((e=>({id:e.id,position:e.position||{x:0,y:0},positionAbsolute:e.positionAbsolute||{x:0,y:0},distance:{x:n.x-(e.positionAbsolute?.x??0),y:n.y-(e.positionAbsolute?.y??0)},delta:{x:0,y:0},extent:e.extent,parentNode:e.parentNode||e.parentId,parentId:e.parentNode||e.parentId,width:e.width,height:e.height,expandParent:e.expandParent})))}function zl(e,t,n,r,o=[0,0],a){const i=function(e,t){return t&&"parent"!==t?[t[0],[t[1][0]-(e.width||0),t[1][1]-(e.height||0)]]:t}(e,e.extent||r);let l=i;const s=e.parentNode||e.parentId;if("parent"!==e.extent||e.expandParent){if(e.extent&&s&&"parent"!==e.extent){const t=n.get(s),{x:r,y:a}=gi(t,o).positionAbsolute;l=[[e.extent[0][0]+r,e.extent[0][1]+a],[e.extent[1][0]+r,e.extent[1][1]+a]]}}else if(s&&e.width&&e.height){const t=n.get(s),{x:r,y:a}=gi(t,o).positionAbsolute;l=t&&Pa(r)&&Pa(a)&&Pa(t.width)&&Pa(t.height)?[[r+e.width*o[0],a+e.height*o[1]],[r+t.width-e.width+e.width*o[0],a+t.height-e.height+e.height*o[1]]]:l}else a?.("005","Only child nodes can use a parent extent."),l=i;let c={x:0,y:0};if(s){const e=n.get(s);c=gi(e,o).positionAbsolute}const u=l&&"parent"!==l?Ea(t,l):t;return{position:{x:u.x-c.x,y:u.y-c.y},positionAbsolute:u}}function Wl({nodeId:e,dragItems:t,nodeInternals:n}){const r=t.map((e=>({...n.get(e.id),position:e.position,positionAbsolute:e.positionAbsolute})));return[e?r.find((t=>t.id===e)):r[0],r]}Ml.displayName="Pane";const Gl=(e,t,n,r)=>{const o=t.querySelectorAll(e);if(!o||!o.length)return null;const a=Array.from(o),i=t.getBoundingClientRect(),l=i.width*r[0],s=i.height*r[1];return a.map((e=>{const t=e.getBoundingClientRect();return{id:e.getAttribute("data-handleid"),position:e.getAttribute("data-handlepos"),x:(t.left-i.left-l)/n,y:(t.top-i.top-s)/n,...wa(e)}}))};function Bl(e,t,n){return void 0===n?n:r=>{const o=t().nodeInternals.get(e);o&&n(r,{...o})}}function Vl({id:e,store:t,unselect:n=!1,nodeRef:r}){const{addSelectedNodes:o,unselectNodesAndEdges:a,multiSelectionActive:i,nodeInternals:l,onError:s}=t.getState(),c=l.get(e);c?(t.setState({nodesSelectionActive:!1}),c.selected?(n||c.selected&&i)&&(a({nodes:[c],edges:[]}),requestAnimationFrame((()=>r?.current?.blur()))):o([e])):s?.("012",(e=>`Node with id "${e}" does not exist, it may have been removed. This can happen when a node is deleted before the "onNodeClick" handler is called.`)(e))}function Hl(e){return(t,n,r)=>e?.(t,r)}function Ul({nodeRef:e,disabled:t=!1,noDragClassName:n,handleSelector:r,nodeId:o,isSelectable:a,selectNodesOnDrag:i}){const l=ma(),[s,c]=(0,ht.useState)(!1),u=(0,ht.useRef)([]),d=(0,ht.useRef)({x:null,y:null}),f=(0,ht.useRef)(0),p=(0,ht.useRef)(null),h=(0,ht.useRef)({x:0,y:0}),m=(0,ht.useRef)(null),g=(0,ht.useRef)(!1),b=(0,ht.useRef)(!1),y=(0,ht.useRef)(!1),v=function(){const e=ma();return(0,ht.useCallback)((({sourceEvent:t})=>{const{transform:n,snapGrid:r,snapToGrid:o}=e.getState(),a=t.touches?t.touches[0].clientX:t.clientX,i=t.touches?t.touches[0].clientY:t.clientY,l={x:(a-n[0])/n[2],y:(i-n[1])/n[2]};return{xSnapped:o?r[0]*Math.round(l.x/r[0]):l.x,ySnapped:o?r[1]*Math.round(l.y/r[1]):l.y,...l}}),[])}();return(0,ht.useEffect)((()=>{if(e?.current){const s=Bn(e.current),w=({x:e,y:t})=>{const{nodeInternals:n,onNodeDrag:r,onSelectionDrag:a,updateNodePositions:i,nodeExtent:s,snapGrid:f,snapToGrid:p,nodeOrigin:h,onError:g}=l.getState();d.current={x:e,y:t};let b=!1,y={x:0,y:0,x2:0,y2:0};if(u.current.length>1&&s){const e=bi(u.current,h);y=Ca(e)}if(u.current=u.current.map((r=>{const o={x:e-r.distance.x,y:t-r.distance.y};p&&(o.x=f[0]*Math.round(o.x/f[0]),o.y=f[1]*Math.round(o.y/f[1]));const a=[[s[0][0],s[0][1]],[s[1][0],s[1][1]]];u.current.length>1&&s&&!r.extent&&(a[0][0]=r.positionAbsolute.x-y.x+s[0][0],a[1][0]=r.positionAbsolute.x+(r.width??0)-y.x2+s[1][0],a[0][1]=r.positionAbsolute.y-y.y+s[0][1],a[1][1]=r.positionAbsolute.y+(r.height??0)-y.y2+s[1][1]);const i=zl(r,o,n,a,h,g);return b=b||r.position.x!==i.position.x||r.position.y!==i.position.y,r.position=i.position,r.positionAbsolute=i.positionAbsolute,r})),!b)return;i(u.current,!0,!0),c(!0);const v=o?r:Hl(a);if(v&&m.current){const[e,t]=Wl({nodeId:o,dragItems:u.current,nodeInternals:n});v(m.current,e,t)}},_=()=>{if(!p.current)return;const[e,t]=xa(h.current,p.current);if(0!==e||0!==t){const{transform:n,panBy:r}=l.getState();d.current.x=(d.current.x??0)-e/n[2],d.current.y=(d.current.y??0)-t/n[2],r({x:e,y:t})&&w(d.current)}f.current=requestAnimationFrame(_)},E=t=>{const{nodeInternals:n,multiSelectionActive:r,nodesDraggable:s,unselectNodesAndEdges:c,onNodeDragStart:f,onSelectionDragStart:p}=l.getState();b.current=!0;const h=o?f:Hl(p);i&&a||r||!o||n.get(o)?.selected||c(),o&&a&&i&&Vl({id:o,store:l,nodeRef:e});const m=v(t);if(d.current=m,u.current=Fl(n,s,m,o),h&&u.current){const[e,r]=Wl({nodeId:o,dragItems:u.current,nodeInternals:n});h(t.sourceEvent,e,r)}};if(!t){const t=function(){var e,t,n,r,o=ia,a=la,i=sa,l=ca,s={},c=Ot("start","drag","end"),u=0,d=0;function f(e){e.on("mousedown.drag",p).filter(l).on("touchstart.drag",g).on("touchmove.drag",b,Vn).on("touchend.drag touchcancel.drag",y).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function p(i,l){if(!r&&o.call(this,i,l)){var s=v(this,a.call(this,i,l),i,l,"mouse");s&&(Bn(i.view).on("mousemove.drag",h,Hn).on("mouseup.drag",m,Hn),Xn(i.view),Un(i),n=!1,e=i.clientX,t=i.clientY,s("start",i))}}function h(r){if(qn(r),!n){var o=r.clientX-e,a=r.clientY-t;n=o*o+a*a>d}s.mouse("drag",r)}function m(e){Bn(e.view).on("mousemove.drag mouseup.drag",null),Yn(e.view,n),qn(e),s.mouse("end",e)}function g(e,t){if(o.call(this,e,t)){var n,r,i=e.changedTouches,l=a.call(this,e,t),s=i.length;for(n=0;n{const{domNode:t,nodeDragThreshold:n}=l.getState();0===n&&E(e),y.current=!1;const r=v(e);d.current=r,p.current=t?.getBoundingClientRect()||null,h.current=$a(e.sourceEvent,p.current)})).on("drag",(e=>{const t=v(e),{autoPanOnNodeDrag:n,nodeDragThreshold:r}=l.getState();if("touchmove"===e.sourceEvent.type&&e.sourceEvent.touches.length>1&&(y.current=!0),!y.current){if(!g.current&&b.current&&n&&(g.current=!0,_()),!b.current){const n=t.xSnapped-(d?.current?.x??0),o=t.ySnapped-(d?.current?.y??0);Math.sqrt(n*n+o*o)>r&&E(e)}(d.current.x!==t.xSnapped||d.current.y!==t.ySnapped)&&u.current&&b.current&&(m.current=e.sourceEvent,h.current=$a(e.sourceEvent,p.current),w(t))}})).on("end",(e=>{if(b.current&&!y.current&&(c(!1),g.current=!1,b.current=!1,cancelAnimationFrame(f.current),u.current)){const{updateNodePositions:t,nodeInternals:n,onNodeDragStop:r,onSelectionDragStop:a}=l.getState(),i=o?r:Hl(a);if(t(u.current,!1,!1),i){const[t,r]=Wl({nodeId:o,dragItems:u.current,nodeInternals:n});i(e.sourceEvent,t,r)}}})).filter((t=>{const o=t.target;return!t.button&&(!n||!Ll(o,`.${n}`,e))&&(!r||Ll(o,r,e))}));return s.call(t),()=>{s.on(".drag",null)}}s.on(".drag",null)}}),[e,t,n,r,a,l,o,i,v]),s}function ql(){const e=ma(),t=(0,ht.useCallback)((t=>{const{nodeInternals:n,nodeExtent:r,updateNodePositions:o,getNodes:a,snapToGrid:i,snapGrid:l,onError:s,nodesDraggable:c}=e.getState(),u=a().filter((e=>e.selected&&(e.draggable||c&&void 0===e.draggable))),d=i?l[0]:5,f=i?l[1]:5,p=t.isShiftPressed?4:1,h=t.x*d*p,m=t.y*f*p;o(u.map((e=>{if(e.positionAbsolute){const t={x:e.positionAbsolute.x+h,y:e.positionAbsolute.y+m};i&&(t.x=l[0]*Math.round(t.x/l[0]),t.y=l[1]*Math.round(t.y/l[1]));const{positionAbsolute:o,position:a}=zl(e,t,n,r,void 0,s);e.position=a,e.positionAbsolute=o}return e})),!0,!1)}),[]);return t}const Xl={ArrowUp:{x:0,y:-1},ArrowDown:{x:0,y:1},ArrowLeft:{x:-1,y:0},ArrowRight:{x:1,y:0}};var Yl=e=>{const t=({id:t,type:n,data:r,xPos:o,yPos:a,xPosOrigin:i,yPosOrigin:l,selected:s,onClick:c,onMouseEnter:u,onMouseMove:d,onMouseLeave:f,onContextMenu:p,onDoubleClick:h,style:m,className:g,isDraggable:b,isSelectable:y,isConnectable:v,isFocusable:w,selectNodesOnDrag:_,sourcePosition:E,targetPosition:S,hidden:x,resizeObserver:k,dragHandle:R,zIndex:C,isParent:N,noDragClassName:O,noPanClassName:A,initialized:P,disableKeyboardA11y:D,ariaLabel:T,rfId:I,hasHandleBounds:j})=>{const M=ma(),$=(0,ht.useRef)(null),L=(0,ht.useRef)(null),F=(0,ht.useRef)(E),z=(0,ht.useRef)(S),W=(0,ht.useRef)(n),G=y||b||c||u||d||f,B=ql(),V=Bl(t,M.getState,u),H=Bl(t,M.getState,d),U=Bl(t,M.getState,f),q=Bl(t,M.getState,p),X=Bl(t,M.getState,h);(0,ht.useEffect)((()=>()=>{L.current&&(k?.unobserve(L.current),L.current=null)}),[]),(0,ht.useEffect)((()=>{if($.current&&!x){const e=$.current;P&&j&&L.current===e||(L.current&&k?.unobserve(L.current),k?.observe(e),L.current=e)}}),[x,P,j]),(0,ht.useEffect)((()=>{const e=W.current!==n,r=F.current!==E,o=z.current!==S;$.current&&(e||r||o)&&(e&&(W.current=n),r&&(F.current=E),o&&(z.current=S),M.getState().updateNodeDimensions([{id:t,nodeElement:$.current,forceUpdate:!0}]))}),[t,n,E,S]);const Y=Ul({nodeRef:$,disabled:x||!b,noDragClassName:O,handleSelector:R,nodeId:t,isSelectable:y,selectNodesOnDrag:_});return x?null:ht.createElement("div",{className:mt(["react-flow__node",`react-flow__node-${n}`,{[A]:b},g,{selected:s,selectable:y,parent:N,dragging:Y}]),ref:$,style:{zIndex:C,transform:`translate(${i}px,${l}px)`,pointerEvents:G?"all":"none",visibility:P?"visible":"hidden",...m},"data-id":t,"data-testid":`rf__node-${t}`,onMouseEnter:V,onMouseMove:H,onMouseLeave:U,onContextMenu:q,onClick:e=>{const{nodeDragThreshold:n}=M.getState();if(y&&(!_||!b||n>0)&&Vl({id:t,store:M,nodeRef:$}),c){const n=M.getState().nodeInternals.get(t);n&&c(e,{...n})}},onDoubleClick:X,onKeyDown:w?e=>{if(!ja(e)&&!D)if(Ta.includes(e.key)&&y){const n="Escape"===e.key;Vl({id:t,store:M,unselect:n,nodeRef:$})}else b&&s&&Object.prototype.hasOwnProperty.call(Xl,e.key)&&(M.setState({ariaLiveMessage:`Moved selected node ${e.key.replace("Arrow","").toLowerCase()}. New position, x: ${~~o}, y: ${~~a}`}),B({x:Xl[e.key].x,y:Xl[e.key].y,isShiftPressed:e.shiftKey}))}:void 0,tabIndex:w?0:void 0,role:w?"button":void 0,"aria-describedby":D?void 0:`${Ji}-${I}`,"aria-label":T},ht.createElement(ci,{value:t},ht.createElement(e,{id:t,data:r,type:n,xPos:o,yPos:a,selected:s,isConnectable:v,sourcePosition:E,targetPosition:S,dragging:Y,dragHandle:R,zIndex:C})))};return t.displayName="NodeWrapper",(0,ht.memo)(t)};const Kl=e=>{const t=e.getNodes().filter((e=>e.selected));return{...bi(t,e.nodeOrigin),transformString:`translate(${e.transform[0]}px,${e.transform[1]}px) scale(${e.transform[2]})`,userSelectionActive:e.userSelectionActive}};var Ql=(0,ht.memo)((function({onSelectionContextMenu:e,noPanClassName:t,disableKeyboardA11y:n}){const r=ma(),{width:o,height:a,x:i,y:l,transformString:s,userSelectionActive:c}=ha(Kl,St),u=ql(),d=(0,ht.useRef)(null);if((0,ht.useEffect)((()=>{n||d.current?.focus({preventScroll:!0})}),[n]),Ul({nodeRef:d}),c||!o||!a)return null;const f=e?t=>{const n=r.getState().getNodes().filter((e=>e.selected));e(t,n)}:void 0;return ht.createElement("div",{className:mt(["react-flow__nodesselection","react-flow__container",t]),style:{transform:s}},ht.createElement("div",{ref:d,className:"react-flow__nodesselection-rect",onContextMenu:f,tabIndex:n?void 0:-1,onKeyDown:n?void 0:e=>{Object.prototype.hasOwnProperty.call(Xl,e.key)&&u({x:Xl[e.key].x,y:Xl[e.key].y,isShiftPressed:e.shiftKey})},style:{width:o,height:a,top:l,left:i}}))}));const Zl=e=>e.nodesSelectionActive,Jl=({children:e,onPaneClick:t,onPaneMouseEnter:n,onPaneMouseMove:r,onPaneMouseLeave:o,onPaneContextMenu:a,onPaneScroll:i,deleteKeyCode:l,onMove:s,onMoveStart:c,onMoveEnd:u,selectionKeyCode:d,selectionOnDrag:f,selectionMode:p,onSelectionStart:h,onSelectionEnd:m,multiSelectionKeyCode:g,panActivationKeyCode:b,zoomActivationKeyCode:y,elementsSelectable:v,zoomOnScroll:w,zoomOnPinch:_,panOnScroll:E,panOnScrollSpeed:S,panOnScrollMode:x,zoomOnDoubleClick:k,panOnDrag:R,defaultViewport:C,translateExtent:N,minZoom:O,maxZoom:A,preventScrolling:P,onSelectionContextMenu:D,noWheelClassName:T,noPanClassName:I,disableKeyboardA11y:j})=>{const M=ha(Zl),$=ol(d),L=ol(b),F=L||R,z=L||E,W=$||f&&!0!==F;return(({deleteKeyCode:e,multiSelectionKeyCode:t})=>{const n=ma(),{deleteElements:r}=bl(),o=ol(e,yl),a=ol(t);(0,ht.useEffect)((()=>{if(o){const{edges:e,getNodes:t}=n.getState(),o=t().filter((e=>e.selected)),a=e.filter((e=>e.selected));r({nodes:o,edges:a}),n.setState({nodesSelectionActive:!1})}}),[o]),(0,ht.useEffect)((()=>{n.setState({multiSelectionActive:a})}),[a])})({deleteKeyCode:l,multiSelectionKeyCode:g}),ht.createElement(kl,{onMove:s,onMoveStart:c,onMoveEnd:u,onPaneContextMenu:a,elementsSelectable:v,zoomOnScroll:w,zoomOnPinch:_,panOnScroll:z,panOnScrollSpeed:S,panOnScrollMode:x,zoomOnDoubleClick:k,panOnDrag:!$&&F,defaultViewport:C,translateExtent:N,minZoom:O,maxZoom:A,zoomActivationKeyCode:y,preventScrolling:P,noWheelClassName:T,noPanClassName:I},ht.createElement(Ml,{onSelectionStart:h,onSelectionEnd:m,onPaneClick:t,onPaneMouseEnter:n,onPaneMouseMove:r,onPaneMouseLeave:o,onPaneContextMenu:a,onPaneScroll:i,panOnDrag:F,isSelecting:!!W,selectionMode:p},e,M&&ht.createElement(Ql,{onSelectionContextMenu:D,noPanClassName:I,disableKeyboardA11y:j})))};Jl.displayName="FlowRenderer";var es=(0,ht.memo)(Jl);function ts(e){return{input:Yl(e.input||$i),default:Yl(e.default||ji),output:Yl(e.output||Fi),group:Yl(e.group||zi),...Object.keys(e).filter((e=>!["input","default","output","group"].includes(e))).reduce(((t,n)=>(t[n]=Yl(e[n]||ji),t)),{})}}const ns=e=>({nodesDraggable:e.nodesDraggable,nodesConnectable:e.nodesConnectable,nodesFocusable:e.nodesFocusable,elementsSelectable:e.elementsSelectable,updateNodeDimensions:e.updateNodeDimensions,onError:e.onError}),rs=e=>{const{nodesDraggable:t,nodesConnectable:n,nodesFocusable:r,elementsSelectable:o,updateNodeDimensions:a,onError:i}=ha(ns,St),l=(s=e.onlyRenderVisibleElements,ha((0,ht.useCallback)((e=>s?yi(e.nodeInternals,{x:0,y:0,width:e.width,height:e.height},e.transform,!0):e.getNodes()),[s])));var s;const c=(0,ht.useRef)(),u=(0,ht.useMemo)((()=>{if("undefined"==typeof ResizeObserver)return null;const e=new ResizeObserver((e=>{const t=e.map((e=>({id:e.target.getAttribute("data-id"),nodeElement:e.target,forceUpdate:!0})));a(t)}));return c.current=e,e}),[]);return(0,ht.useEffect)((()=>()=>{c?.current?.disconnect()}),[]),ht.createElement("div",{className:"react-flow__nodes",style:vl},l.map((a=>{let l=a.type||"default";e.nodeTypes[l]||(i?.("003",(e=>`Node type "${e}" not found. Using fallback type "default".`)(l)),l="default");const s=e.nodeTypes[l]||e.nodeTypes.default,c=!!(a.draggable||t&&void 0===a.draggable),d=!!(a.selectable||o&&void 0===a.selectable),f=!!(a.connectable||n&&void 0===a.connectable),p=!!(a.focusable||r&&void 0===a.focusable),h=e.nodeExtent?Ea(a.positionAbsolute,e.nodeExtent):a.positionAbsolute,m=h?.x??0,g=h?.y??0,b=(({x:e,y:t,width:n,height:r,origin:o})=>n&&r?o[0]<0||o[1]<0||o[0]>1||o[1]>1?{x:e,y:t}:{x:e-n*o[0],y:t-r*o[1]}:{x:e,y:t})({x:m,y:g,width:a.width??0,height:a.height??0,origin:e.nodeOrigin});return ht.createElement(s,{key:a.id,id:a.id,className:a.className,style:a.style,type:l,data:a.data,sourcePosition:a.sourcePosition||Xa.Bottom,targetPosition:a.targetPosition||Xa.Top,hidden:a.hidden,xPos:m,yPos:g,xPosOrigin:b.x,yPosOrigin:b.y,selectNodesOnDrag:e.selectNodesOnDrag,onClick:e.onNodeClick,onMouseEnter:e.onNodeMouseEnter,onMouseMove:e.onNodeMouseMove,onMouseLeave:e.onNodeMouseLeave,onContextMenu:e.onNodeContextMenu,onDoubleClick:e.onNodeDoubleClick,selected:!!a.selected,isDraggable:c,isSelectable:d,isConnectable:f,isFocusable:p,resizeObserver:u,dragHandle:a.dragHandle,zIndex:a[Da]?.z??0,isParent:!!a[Da]?.isParent,noDragClassName:e.noDragClassName,noPanClassName:e.noPanClassName,initialized:!!a.width&&!!a.height,rfId:e.rfId,disableKeyboardA11y:e.disableKeyboardA11y,ariaLabel:a.ariaLabel,hasHandleBounds:!!a[Da]?.handleBounds})})))};rs.displayName="NodeRenderer";var os=(0,ht.memo)(rs);const as=(e,t,n)=>n===Xa.Left?e-t:n===Xa.Right?e+t:e,is=(e,t,n)=>n===Xa.Top?e-t:n===Xa.Bottom?e+t:e,ls="react-flow__edgeupdater",ss=({position:e,centerX:t,centerY:n,radius:r=10,onMouseDown:o,onMouseEnter:a,onMouseOut:i,type:l})=>ht.createElement("circle",{onMouseDown:o,onMouseEnter:a,onMouseOut:i,className:mt([ls,`${ls}-${l}`]),cx:as(t,r,e),cy:is(n,r,e),r,stroke:"transparent",fill:"transparent"}),cs=()=>!0;var us=e=>{const t=({id:t,className:n,type:r,data:o,onClick:a,onEdgeDoubleClick:i,selected:l,animated:s,label:c,labelStyle:u,labelShowBg:d,labelBgStyle:f,labelBgPadding:p,labelBgBorderRadius:h,style:m,source:g,target:b,sourceX:y,sourceY:v,targetX:w,targetY:_,sourcePosition:E,targetPosition:S,elementsSelectable:x,hidden:k,sourceHandleId:R,targetHandleId:C,onContextMenu:N,onMouseEnter:O,onMouseMove:A,onMouseLeave:P,reconnectRadius:D,onReconnect:T,onReconnectStart:I,onReconnectEnd:j,markerEnd:M,markerStart:$,rfId:L,ariaLabel:F,isFocusable:z,isReconnectable:W,pathOptions:G,interactionWidth:B,disableKeyboardA11y:V})=>{const H=(0,ht.useRef)(null),[U,q]=(0,ht.useState)(!1),[X,Y]=(0,ht.useState)(!1),K=ma(),Q=(0,ht.useMemo)((()=>`url('#${fi($,L)}')`),[$,L]),Z=(0,ht.useMemo)((()=>`url('#${fi(M,L)}')`),[M,L]);if(k)return null;const J=za(t,K.getState,i),ee=za(t,K.getState,N),te=za(t,K.getState,O),ne=za(t,K.getState,A),re=za(t,K.getState,P),oe=(e,n)=>{if(0!==e.button)return;const{edges:r,isValidConnection:o}=K.getState(),a=n?b:g,i=(n?C:R)||null,l=n?"target":"source",s=o||cs,c=n,u=r.find((e=>e.id===t));Y(!0),I?.(e,u,l),Oi({event:e,handleId:i,nodeId:a,onConnect:e=>T?.(u,e),isTarget:c,getState:K.getState,setState:K.setState,isValidConnection:s,edgeUpdaterType:l,onReconnectEnd:e=>{Y(!1),j?.(e,u,l)}})},ae=()=>q(!0),ie=()=>q(!1),le=!x&&!a;return ht.createElement("g",{className:mt(["react-flow__edge",`react-flow__edge-${r}`,n,{selected:l,animated:s,inactive:le,updating:U}]),onClick:e=>{const{edges:n,addSelectedEdges:r,unselectNodesAndEdges:o,multiSelectionActive:i}=K.getState(),l=n.find((e=>e.id===t));l&&(x&&(K.setState({nodesSelectionActive:!1}),l.selected&&i?(o({nodes:[],edges:[l]}),H.current?.blur()):r([t])),a&&a(e,l))},onDoubleClick:J,onContextMenu:ee,onMouseEnter:te,onMouseMove:ne,onMouseLeave:re,onKeyDown:z?e=>{if(!V&&Ta.includes(e.key)&&x){const{unselectNodesAndEdges:n,addSelectedEdges:r,edges:o}=K.getState();"Escape"===e.key?(H.current?.blur(),n({edges:[o.find((e=>e.id===t))]})):r([t])}}:void 0,tabIndex:z?0:void 0,role:z?"button":"img","data-testid":`rf__edge-${t}`,"aria-label":null===F?void 0:F||`Edge from ${g} to ${b}`,"aria-describedby":z?`${el}-${L}`:void 0,ref:H},!X&&ht.createElement(e,{id:t,source:g,target:b,selected:l,animated:s,label:c,labelStyle:u,labelShowBg:d,labelBgStyle:f,labelBgPadding:p,labelBgBorderRadius:h,data:o,style:m,sourceX:y,sourceY:v,targetX:w,targetY:_,sourcePosition:E,targetPosition:S,sourceHandleId:R,targetHandleId:C,markerStart:Q,markerEnd:Z,pathOptions:G,interactionWidth:B}),W&&ht.createElement(ht.Fragment,null,("source"===W||!0===W)&&ht.createElement(ss,{position:E,centerX:y,centerY:v,radius:D,onMouseDown:e=>oe(e,!0),onMouseEnter:ae,onMouseOut:ie,type:"source"}),("target"===W||!0===W)&&ht.createElement(ss,{position:S,centerX:w,centerY:_,radius:D,onMouseDown:e=>oe(e,!1),onMouseEnter:ae,onMouseOut:ie,type:"target"})))};return t.displayName="EdgeWrapper",(0,ht.memo)(t)};function ds(e){return{default:us(e.default||li),straight:us(e.bezier||ri),step:us(e.step||ni),smoothstep:us(e.step||ti),simplebezier:us(e.simplebezier||Qa),...Object.keys(e).filter((e=>!["default","bezier"].includes(e))).reduce(((t,n)=>(t[n]=us(e[n]||li),t)),{})}}function fs(e,t,n=null){const r=(n?.x||0)+t.x,o=(n?.y||0)+t.y,a=n?.width||t.width,i=n?.height||t.height;switch(e){case Xa.Top:return{x:r+a/2,y:o};case Xa.Right:return{x:r+a,y:o+i/2};case Xa.Bottom:return{x:r+a/2,y:o+i};case Xa.Left:return{x:r,y:o+i/2}}}function ps(e,t){return e?1!==e.length&&t?t&&e.find((e=>e.id===t))||null:e[0]:null}function hs(e){const t=e?.[Da]?.handleBounds||null,n=t&&e?.width&&e?.height&&void 0!==e?.positionAbsolute?.x&&void 0!==e?.positionAbsolute?.y;return[{x:e?.positionAbsolute?.x||0,y:e?.positionAbsolute?.y||0,width:e?.width||0,height:e?.height||0},t,!!n]}const ms=[{level:0,isMaxLevel:!0,edges:[]}];const gs={[qa.Arrow]:({color:e="none",strokeWidth:t=1})=>ht.createElement("polyline",{style:{stroke:e,strokeWidth:t},strokeLinecap:"round",strokeLinejoin:"round",fill:"none",points:"-5,-4 0,0 -5,4"}),[qa.ArrowClosed]:({color:e="none",strokeWidth:t=1})=>ht.createElement("polyline",{style:{stroke:e,fill:e,strokeWidth:t},strokeLinecap:"round",strokeLinejoin:"round",points:"-5,-4 0,0 -5,4 -5,-4"})},bs=({id:e,type:t,color:n,width:r=12.5,height:o=12.5,markerUnits:a="strokeWidth",strokeWidth:i,orient:l="auto-start-reverse"})=>{const s=function(e){const t=ma();return(0,ht.useMemo)((()=>Object.prototype.hasOwnProperty.call(gs,e)?gs[e]:(t.getState().onError?.("009",(e=>`Marker type "${e}" doesn't exist.`)(e)),null)),[e])}(t);return s?ht.createElement("marker",{className:"react-flow__arrowhead",id:e,markerWidth:`${r}`,markerHeight:`${o}`,viewBox:"-10 -10 20 20",markerUnits:a,orient:l,refX:"0",refY:"0"},ht.createElement(s,{color:n,strokeWidth:i})):null},ys=({defaultColor:e,rfId:t})=>{const n=ha((0,ht.useCallback)((({defaultColor:e,rfId:t})=>n=>{const r=[];return n.edges.reduce(((n,o)=>([o.markerStart,o.markerEnd].forEach((o=>{if(o&&"object"==typeof o){const a=fi(o,t);r.includes(a)||(n.push({id:a,color:o.color||e,...o}),r.push(a))}})),n)),[]).sort(((e,t)=>e.id.localeCompare(t.id)))})({defaultColor:e,rfId:t}),[e,t]),((e,t)=>!(e.length!==t.length||e.some(((e,n)=>e.id!==t[n].id)))));return ht.createElement("defs",null,n.map((e=>ht.createElement(bs,{id:e.id,key:e.id,type:e.type,color:e.color,width:e.width,height:e.height,markerUnits:e.markerUnits,strokeWidth:e.strokeWidth,orient:e.orient}))))};ys.displayName="MarkerDefinitions";var vs=(0,ht.memo)(ys);const ws=e=>({nodesConnectable:e.nodesConnectable,edgesFocusable:e.edgesFocusable,edgesUpdatable:e.edgesUpdatable,elementsSelectable:e.elementsSelectable,width:e.width,height:e.height,connectionMode:e.connectionMode,nodeInternals:e.nodeInternals,onError:e.onError}),_s=({defaultMarkerColor:e,onlyRenderVisibleElements:t,elevateEdgesOnSelect:n,rfId:r,edgeTypes:o,noPanClassName:a,onEdgeContextMenu:i,onEdgeMouseEnter:l,onEdgeMouseMove:s,onEdgeMouseLeave:c,onEdgeClick:u,onEdgeDoubleClick:d,onReconnect:f,onReconnectStart:p,onReconnectEnd:h,reconnectRadius:m,children:g,disableKeyboardA11y:b})=>{const{edgesFocusable:y,edgesUpdatable:v,elementsSelectable:w,width:_,height:E,connectionMode:S,nodeInternals:x,onError:k}=ha(ws,St),R=function(e,t,n){return function(e,t,n=!1){let r=-1;const o=e.reduce(((e,o)=>{const a=Pa(o.zIndex);let i=a?o.zIndex:0;if(n){const e=t.get(o.target),n=t.get(o.source),r=o.selected||e?.selected||n?.selected,l=Math.max(n?.[Da]?.z||0,e?.[Da]?.z||0,1e3);i=(a?o.zIndex:0)+(r?l:0)}return e[i]?e[i].push(o):e[i]=[o],r=i>r?i:r,e}),{}),a=Object.entries(o).map((([e,t])=>{const n=+e;return{edges:t,level:n,isMaxLevel:n===r}}));return 0===a.length?ms:a}(ha((0,ht.useCallback)((n=>e?n.edges.filter((e=>{const r=t.get(e.source),o=t.get(e.target);return r?.width&&r?.height&&o?.width&&o?.height&&function({sourcePos:e,targetPos:t,sourceWidth:n,sourceHeight:r,targetWidth:o,targetHeight:a,width:i,height:l,transform:s}){const c={x:Math.min(e.x,t.x),y:Math.min(e.y,t.y),x2:Math.max(e.x+n,t.x+o),y2:Math.max(e.y+r,t.y+a)};c.x===c.x2&&(c.x2+=1),c.y===c.y2&&(c.y2+=1);const u=Ca({x:(0-s[0])/s[2],y:(0-s[1])/s[2],width:i/s[2],height:l/s[2]}),d=Math.max(0,Math.min(u.x2,c.x2)-Math.max(u.x,c.x)),f=Math.max(0,Math.min(u.y2,c.y2)-Math.max(u.y,c.y));return Math.ceil(d*f)>0}({sourcePos:r.positionAbsolute||{x:0,y:0},targetPos:o.positionAbsolute||{x:0,y:0},sourceWidth:r.width,sourceHeight:r.height,targetWidth:o.width,targetHeight:o.height,width:n.width,height:n.height,transform:n.transform})})):n.edges),[e,t])),t,n)}(t,x,n);return _?ht.createElement(ht.Fragment,null,R.map((({level:t,edges:n,isMaxLevel:g})=>ht.createElement("svg",{key:t,style:{zIndex:t},width:_,height:E,className:"react-flow__edges react-flow__container"},g&&ht.createElement(vs,{defaultColor:e,rfId:r}),ht.createElement("g",null,n.map((e=>{const[t,n,g]=hs(x.get(e.source)),[_,E,R]=hs(x.get(e.target));if(!g||!R)return null;let C=e.type||"default";o[C]||(k?.("011",(e=>`Edge type "${e}" not found. Using fallback type "default".`)(C)),C="default");const N=o[C]||o.default,O=S===Ba.Strict?E.target:(E.target??[]).concat(E.source??[]),A=ps(n.source,e.sourceHandle),P=ps(O,e.targetHandle),D=A?.position||Xa.Bottom,T=P?.position||Xa.Top,I=!!(e.focusable||y&&void 0===e.focusable),j=e.reconnectable||e.updatable,M=void 0!==f&&(j||v&&void 0===j);if(!A||!P)return k?.("008",((e,t)=>`Couldn't create edge for ${e?"target":"source"} handle id: "${e?t.targetHandle:t.sourceHandle}", edge id: ${t.id}.`)(A,e)),null;const{sourceX:$,sourceY:L,targetX:F,targetY:z}=((e,t,n,r,o,a)=>{const i=fs(n,e,t),l=fs(a,r,o);return{sourceX:i.x,sourceY:i.y,targetX:l.x,targetY:l.y}})(t,A,D,_,P,T);return ht.createElement(N,{key:e.id,id:e.id,className:mt([e.className,a]),type:C,data:e.data,selected:!!e.selected,animated:!!e.animated,hidden:!!e.hidden,label:e.label,labelStyle:e.labelStyle,labelShowBg:e.labelShowBg,labelBgStyle:e.labelBgStyle,labelBgPadding:e.labelBgPadding,labelBgBorderRadius:e.labelBgBorderRadius,style:e.style,source:e.source,target:e.target,sourceHandleId:e.sourceHandle,targetHandleId:e.targetHandle,markerEnd:e.markerEnd,markerStart:e.markerStart,sourceX:$,sourceY:L,targetX:F,targetY:z,sourcePosition:D,targetPosition:T,elementsSelectable:w,onContextMenu:i,onMouseEnter:l,onMouseMove:s,onMouseLeave:c,onClick:u,onEdgeDoubleClick:d,onReconnect:f,onReconnectStart:p,onReconnectEnd:h,reconnectRadius:m,rfId:r,ariaLabel:e.ariaLabel,isFocusable:I,isReconnectable:M,pathOptions:"pathOptions"in e?e.pathOptions:void 0,interactionWidth:e.interactionWidth,disableKeyboardA11y:b})})))))),g):null};_s.displayName="EdgeRenderer";var Es=(0,ht.memo)(_s);const Ss=e=>`translate(${e.transform[0]}px,${e.transform[1]}px) scale(${e.transform[2]})`;function xs({children:e}){const t=ha(Ss);return ht.createElement("div",{className:"react-flow__viewport react-flow__container",style:{transform:t}},e)}const ks={[Xa.Left]:Xa.Right,[Xa.Right]:Xa.Left,[Xa.Top]:Xa.Bottom,[Xa.Bottom]:Xa.Top},Rs=({nodeId:e,handleType:t,style:n,type:r=Ua.Bezier,CustomComponent:o,connectionStatus:a})=>{const{fromNode:i,handleId:l,toX:s,toY:c,connectionMode:u}=ha((0,ht.useCallback)((t=>({fromNode:t.nodeInternals.get(e),handleId:t.connectionHandleId,toX:(t.connectionPosition.x-t.transform[0])/t.transform[2],toY:(t.connectionPosition.y-t.transform[1])/t.transform[2],connectionMode:t.connectionMode})),[e]),St),d=i?.[Da]?.handleBounds;let f=d?.[t];if(u===Ba.Loose&&(f=f||d?.["source"===t?"target":"source"]),!i||!f)return null;const p=l?f.find((e=>e.id===l)):f[0],h=p?p.x+p.width/2:(i.width??0)/2,m=p?p.y+p.height/2:i.height??0,g=(i.positionAbsolute?.x??0)+h,b=(i.positionAbsolute?.y??0)+m,y=p?.position,v=y?ks[y]:null;if(!y||!v)return null;if(o)return ht.createElement(o,{connectionLineType:r,connectionLineStyle:n,fromNode:i,fromHandle:p,fromX:g,fromY:b,toX:s,toY:c,fromPosition:y,toPosition:v,connectionStatus:a});let w="";const _={sourceX:g,sourceY:b,sourcePosition:y,targetX:s,targetY:c,targetPosition:v};return r===Ua.Bezier?[w]=ii(_):r===Ua.Step?[w]=ei({..._,borderRadius:0}):r===Ua.SmoothStep?[w]=ei(_):r===Ua.SimpleBezier?[w]=Ka(_):w=`M${g},${b} ${s},${c}`,ht.createElement("path",{d:w,fill:"none",className:"react-flow__connection-path",style:n})};Rs.displayName="ConnectionLine";const Cs=e=>({nodeId:e.connectionNodeId,handleType:e.connectionHandleType,nodesConnectable:e.nodesConnectable,connectionStatus:e.connectionStatus,width:e.width,height:e.height});function Ns({containerStyle:e,style:t,type:n,component:r}){const{nodeId:o,handleType:a,nodesConnectable:i,width:l,height:s,connectionStatus:c}=ha(Cs,St);return o&&a&&l&&i?ht.createElement("svg",{style:e,width:l,height:s,className:"react-flow__edges react-flow__connectionline react-flow__container"},ht.createElement("g",{className:mt(["react-flow__connection",c])},ht.createElement(Rs,{nodeId:o,handleType:a,style:t,type:n,CustomComponent:r,connectionStatus:c}))):null}function Os(e,t){return(0,ht.useRef)(null),ma(),(0,ht.useMemo)((()=>t(e)),[e])}const As=({nodeTypes:e,edgeTypes:t,onMove:n,onMoveStart:r,onMoveEnd:o,onInit:a,onNodeClick:i,onEdgeClick:l,onNodeDoubleClick:s,onEdgeDoubleClick:c,onNodeMouseEnter:u,onNodeMouseMove:d,onNodeMouseLeave:f,onNodeContextMenu:p,onSelectionContextMenu:h,onSelectionStart:m,onSelectionEnd:g,connectionLineType:b,connectionLineStyle:y,connectionLineComponent:v,connectionLineContainerStyle:w,selectionKeyCode:_,selectionOnDrag:E,selectionMode:S,multiSelectionKeyCode:x,panActivationKeyCode:k,zoomActivationKeyCode:R,deleteKeyCode:C,onlyRenderVisibleElements:N,elementsSelectable:O,selectNodesOnDrag:A,defaultViewport:P,translateExtent:D,minZoom:T,maxZoom:I,preventScrolling:j,defaultMarkerColor:M,zoomOnScroll:$,zoomOnPinch:L,panOnScroll:F,panOnScrollSpeed:z,panOnScrollMode:W,zoomOnDoubleClick:G,panOnDrag:B,onPaneClick:V,onPaneMouseEnter:H,onPaneMouseMove:U,onPaneMouseLeave:q,onPaneScroll:X,onPaneContextMenu:Y,onEdgeContextMenu:K,onEdgeMouseEnter:Q,onEdgeMouseMove:Z,onEdgeMouseLeave:J,onReconnect:ee,onReconnectStart:te,onReconnectEnd:ne,reconnectRadius:re,noDragClassName:oe,noWheelClassName:ae,noPanClassName:ie,elevateEdgesOnSelect:le,disableKeyboardA11y:se,nodeOrigin:ce,nodeExtent:ue,rfId:de})=>{const fe=Os(e,ts),pe=Os(t,ds);return function(e){const t=bl(),n=(0,ht.useRef)(!1);(0,ht.useEffect)((()=>{!n.current&&t.viewportInitialized&&e&&(setTimeout((()=>e(t)),1),n.current=!0)}),[e,t.viewportInitialized])}(a),ht.createElement(es,{onPaneClick:V,onPaneMouseEnter:H,onPaneMouseMove:U,onPaneMouseLeave:q,onPaneContextMenu:Y,onPaneScroll:X,deleteKeyCode:C,selectionKeyCode:_,selectionOnDrag:E,selectionMode:S,onSelectionStart:m,onSelectionEnd:g,multiSelectionKeyCode:x,panActivationKeyCode:k,zoomActivationKeyCode:R,elementsSelectable:O,onMove:n,onMoveStart:r,onMoveEnd:o,zoomOnScroll:$,zoomOnPinch:L,zoomOnDoubleClick:G,panOnScroll:F,panOnScrollSpeed:z,panOnScrollMode:W,panOnDrag:B,defaultViewport:P,translateExtent:D,minZoom:T,maxZoom:I,onSelectionContextMenu:h,preventScrolling:j,noDragClassName:oe,noWheelClassName:ae,noPanClassName:ie,disableKeyboardA11y:se},ht.createElement(xs,null,ht.createElement(Es,{edgeTypes:pe,onEdgeClick:l,onEdgeDoubleClick:c,onlyRenderVisibleElements:N,onEdgeContextMenu:K,onEdgeMouseEnter:Q,onEdgeMouseMove:Z,onEdgeMouseLeave:J,onReconnect:ee,onReconnectStart:te,onReconnectEnd:ne,reconnectRadius:re,defaultMarkerColor:M,noPanClassName:ie,elevateEdgesOnSelect:!!le,disableKeyboardA11y:se,rfId:de},ht.createElement(Ns,{style:y,type:b,component:v,containerStyle:w})),ht.createElement("div",{className:"react-flow__edgelabel-renderer"}),ht.createElement(os,{nodeTypes:fe,onNodeClick:i,onNodeDoubleClick:s,onNodeMouseEnter:u,onNodeMouseMove:d,onNodeMouseLeave:f,onNodeContextMenu:p,selectNodesOnDrag:A,onlyRenderVisibleElements:N,noPanClassName:ie,noDragClassName:oe,disableKeyboardA11y:se,nodeOrigin:ce,nodeExtent:ue,rfId:de})))};As.displayName="GraphView";var Ps=(0,ht.memo)(As);const Ds=[[Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY],[Number.POSITIVE_INFINITY,Number.POSITIVE_INFINITY]],Ts={rfId:"1",width:0,height:0,transform:[0,0,1],nodeInternals:new Map,edges:[],onNodesChange:null,onEdgesChange:null,hasDefaultNodes:!1,hasDefaultEdges:!1,d3Zoom:null,d3Selection:null,d3ZoomHandler:void 0,minZoom:.5,maxZoom:2,translateExtent:Ds,nodeExtent:Ds,nodesSelectionActive:!1,userSelectionActive:!1,userSelectionRect:null,connectionNodeId:null,connectionHandleId:null,connectionHandleType:"source",connectionPosition:{x:0,y:0},connectionStatus:null,connectionMode:Ba.Strict,domNode:null,paneDragging:!1,noPanClassName:"nopan",nodeOrigin:[0,0],nodeDragThreshold:0,snapGrid:[15,15],snapToGrid:!1,nodesDraggable:!0,nodesConnectable:!0,nodesFocusable:!0,edgesFocusable:!0,edgesUpdatable:!0,elementsSelectable:!0,elevateNodesOnSelect:!0,fitViewOnInit:!1,fitViewOnInitDone:!1,fitViewOnInitOptions:void 0,onSelectionChange:[],multiSelectionActive:!1,connectionStartHandle:null,connectionEndHandle:null,connectionClickStartHandle:null,connectOnClick:!0,ariaLiveMessage:"",autoPanOnConnect:!0,autoPanOnNodeDrag:!0,connectionRadius:20,onError:Ia,isValidConnection:void 0},Is=({children:e})=>{const t=(0,ht.useRef)(null);return t.current||(t.current=(n=(e,t)=>({...Ts,setNodes:n=>{const{nodeInternals:r,nodeOrigin:o,elevateNodesOnSelect:a}=t();e({nodeInternals:cl(n,r,o,a)})},getNodes:()=>Array.from(t().nodeInternals.values()),setEdges:n=>{const{defaultEdgeOptions:r={}}=t();e({edges:n.map((e=>({...r,...e})))})},setDefaultNodesAndEdges:(n,r)=>{const o=void 0!==n,a=void 0!==r,i=o?cl(n,new Map,t().nodeOrigin,t().elevateNodesOnSelect):new Map;e({nodeInternals:i,edges:a?r:[],hasDefaultNodes:o,hasDefaultEdges:a})},updateNodeDimensions:n=>{const{onNodesChange:r,nodeInternals:o,fitViewOnInit:a,fitViewOnInitDone:i,fitViewOnInitOptions:l,domNode:s,nodeOrigin:c}=t(),u=s?.querySelector(".react-flow__viewport");if(!u)return;const d=window.getComputedStyle(u),{m22:f}=new window.DOMMatrixReadOnly(d.transform),p=n.reduce(((e,t)=>{const n=o.get(t.id);if(n?.hidden)o.set(n.id,{...n,[Da]:{...n[Da],handleBounds:void 0}});else if(n){const r=wa(t.nodeElement);r.width&&r.height&&(n.width!==r.width||n.height!==r.height||t.forceUpdate)&&(o.set(n.id,{...n,[Da]:{...n[Da],handleBounds:{source:Gl(".source",t.nodeElement,f,c),target:Gl(".target",t.nodeElement,f,c)}},...r}),e.push({id:n.id,type:"dimensions",dimensions:r}))}return e}),[]);sl(o,c);const h=i||a&&!i&&ul(t,{initial:!0,...l});e({nodeInternals:new Map(o),fitViewOnInitDone:h}),p?.length>0&&r?.(p)},updateNodePositions:(e,n=!0,r=!1)=>{const{triggerNodeChanges:o}=t();o(e.map((e=>{const t={id:e.id,type:"position",dragging:r};return n&&(t.positionAbsolute=e.positionAbsolute,t.position=e.position),t})))},triggerNodeChanges:n=>{const{onNodesChange:r,nodeInternals:o,hasDefaultNodes:a,nodeOrigin:i,getNodes:l,elevateNodesOnSelect:s}=t();if(n?.length){if(a){const t=cl(Al(n,l()),o,i,s);e({nodeInternals:t})}r?.(n)}},addSelectedNodes:n=>{const{multiSelectionActive:r,edges:o,getNodes:a}=t();let i,l=null;r?i=n.map((e=>Dl(e,!0))):(i=Tl(a(),n),l=Tl(o,[])),pl({changedNodes:i,changedEdges:l,get:t,set:e})},addSelectedEdges:n=>{const{multiSelectionActive:r,edges:o,getNodes:a}=t();let i,l=null;r?i=n.map((e=>Dl(e,!0))):(i=Tl(o,n),l=Tl(a(),[])),pl({changedNodes:l,changedEdges:i,get:t,set:e})},unselectNodesAndEdges:({nodes:n,edges:r}={})=>{const{edges:o,getNodes:a}=t(),i=r||o;pl({changedNodes:(n||a()).map((e=>(e.selected=!1,Dl(e.id,!1)))),changedEdges:i.map((e=>Dl(e.id,!1))),get:t,set:e})},setMinZoom:n=>{const{d3Zoom:r,maxZoom:o}=t();r?.scaleExtent([n,o]),e({minZoom:n})},setMaxZoom:n=>{const{d3Zoom:r,minZoom:o}=t();r?.scaleExtent([o,n]),e({maxZoom:n})},setTranslateExtent:n=>{t().d3Zoom?.translateExtent(n),e({translateExtent:n})},resetSelectedElements:()=>{const{edges:n,getNodes:r}=t();pl({changedNodes:r().filter((e=>e.selected)).map((e=>Dl(e.id,!1))),changedEdges:n.filter((e=>e.selected)).map((e=>Dl(e.id,!1))),get:t,set:e})},setNodeExtent:n=>{const{nodeInternals:r}=t();r.forEach((e=>{e.positionAbsolute=Ea(e.position,n)})),e({nodeExtent:n,nodeInternals:new Map(r)})},panBy:e=>{const{transform:n,width:r,height:o,d3Zoom:a,d3Selection:i,translateExtent:l}=t();if(!a||!i||!e.x&&!e.y)return!1;const s=Xo.translate(n[0]+e.x,n[1]+e.y).scale(n[2]),c=[[0,0],[r,o]],u=a?.constrain()(s,c,l);return a.transform(i,u),n[0]!==u.x||n[1]!==u.y||n[2]!==u.k},cancelConnection:()=>e({connectionNodeId:Ts.connectionNodeId,connectionHandleId:Ts.connectionHandleId,connectionHandleType:Ts.connectionHandleType,connectionStatus:Ts.connectionStatus,connectionStartHandle:Ts.connectionStartHandle,connectionEndHandle:Ts.connectionEndHandle}),reset:()=>e({...Ts})}),r=Object.is,n?Et(n,r):Et)),ht.createElement(fa,{value:t.current},e);var n,r};Is.displayName="ReactFlowProvider";const js=({children:e})=>(0,ht.useContext)(da)?ht.createElement(ht.Fragment,null,e):ht.createElement(Is,null,e);js.displayName="ReactFlowWrapper";const Ms={input:$i,default:ji,output:Fi,group:zi},$s={default:li,straight:ri,step:ni,smoothstep:ti,simplebezier:Qa},Ls=[0,0],Fs=[15,15],zs={x:0,y:0,zoom:1},Ws={width:"100%",height:"100%",overflow:"hidden",position:"relative",zIndex:0},Gs=(0,ht.forwardRef)((({nodes:e,edges:t,defaultNodes:n,defaultEdges:r,className:o,nodeTypes:a=Ms,edgeTypes:i=$s,onNodeClick:l,onEdgeClick:s,onInit:c,onMove:u,onMoveStart:d,onMoveEnd:f,onConnect:p,onConnectStart:h,onConnectEnd:m,onClickConnectStart:g,onClickConnectEnd:b,onNodeMouseEnter:y,onNodeMouseMove:v,onNodeMouseLeave:w,onNodeContextMenu:_,onNodeDoubleClick:E,onNodeDragStart:S,onNodeDrag:x,onNodeDragStop:k,onNodesDelete:R,onEdgesDelete:C,onSelectionChange:N,onSelectionDragStart:O,onSelectionDrag:A,onSelectionDragStop:P,onSelectionContextMenu:D,onSelectionStart:T,onSelectionEnd:I,connectionMode:j=Ba.Strict,connectionLineType:M=Ua.Bezier,connectionLineStyle:$,connectionLineComponent:L,connectionLineContainerStyle:F,deleteKeyCode:z="Backspace",selectionKeyCode:W="Shift",selectionOnDrag:G=!1,selectionMode:B=Ha.Full,panActivationKeyCode:V="Space",multiSelectionKeyCode:H=(La()?"Meta":"Control"),zoomActivationKeyCode:U=(La()?"Meta":"Control"),snapToGrid:q=!1,snapGrid:X=Fs,onlyRenderVisibleElements:Y=!1,selectNodesOnDrag:K=!0,nodesDraggable:Q,nodesConnectable:Z,nodesFocusable:J,nodeOrigin:ee=Ls,edgesFocusable:te,edgesUpdatable:ne,elementsSelectable:re,defaultViewport:oe=zs,minZoom:ae=.5,maxZoom:ie=2,translateExtent:le=Ds,preventScrolling:se=!0,nodeExtent:ce,defaultMarkerColor:ue="#b1b1b7",zoomOnScroll:de=!0,zoomOnPinch:fe=!0,panOnScroll:pe=!1,panOnScrollSpeed:he=.5,panOnScrollMode:me=Va.Free,zoomOnDoubleClick:ge=!0,panOnDrag:be=!0,onPaneClick:ye,onPaneMouseEnter:ve,onPaneMouseMove:we,onPaneMouseLeave:_e,onPaneScroll:Ee,onPaneContextMenu:Se,children:xe,onEdgeContextMenu:ke,onEdgeDoubleClick:Re,onEdgeMouseEnter:Ce,onEdgeMouseMove:Ne,onEdgeMouseLeave:Oe,onEdgeUpdate:Ae,onEdgeUpdateStart:Pe,onEdgeUpdateEnd:De,onReconnect:Te,onReconnectStart:Ie,onReconnectEnd:je,reconnectRadius:Me=10,edgeUpdaterRadius:$e=10,onNodesChange:Le,onEdgesChange:Fe,noDragClassName:ze="nodrag",noWheelClassName:We="nowheel",noPanClassName:Ge="nopan",fitView:Be=!1,fitViewOptions:Ve,connectOnClick:He=!0,attributionPosition:Ue,proOptions:qe,defaultEdgeOptions:Xe,elevateNodesOnSelect:Ye=!0,elevateEdgesOnSelect:Ke=!1,disableKeyboardA11y:Qe=!1,autoPanOnConnect:Ze=!0,autoPanOnNodeDrag:Je=!0,connectionRadius:et=20,isValidConnection:tt,onError:nt,style:rt,id:ot,nodeDragThreshold:at,...it},lt)=>{const st=ot||"1";return ht.createElement("div",{...it,style:{...rt,...Ws},ref:lt,className:mt(["react-flow",o]),"data-testid":"rf__wrapper",id:ot},ht.createElement(js,null,ht.createElement(Ps,{onInit:c,onMove:u,onMoveStart:d,onMoveEnd:f,onNodeClick:l,onEdgeClick:s,onNodeMouseEnter:y,onNodeMouseMove:v,onNodeMouseLeave:w,onNodeContextMenu:_,onNodeDoubleClick:E,nodeTypes:a,edgeTypes:i,connectionLineType:M,connectionLineStyle:$,connectionLineComponent:L,connectionLineContainerStyle:F,selectionKeyCode:W,selectionOnDrag:G,selectionMode:B,deleteKeyCode:z,multiSelectionKeyCode:H,panActivationKeyCode:V,zoomActivationKeyCode:U,onlyRenderVisibleElements:Y,selectNodesOnDrag:K,defaultViewport:oe,translateExtent:le,minZoom:ae,maxZoom:ie,preventScrolling:se,zoomOnScroll:de,zoomOnPinch:fe,zoomOnDoubleClick:ge,panOnScroll:pe,panOnScrollSpeed:he,panOnScrollMode:me,panOnDrag:be,onPaneClick:ye,onPaneMouseEnter:ve,onPaneMouseMove:we,onPaneMouseLeave:_e,onPaneScroll:Ee,onPaneContextMenu:Se,onSelectionContextMenu:D,onSelectionStart:T,onSelectionEnd:I,onEdgeContextMenu:ke,onEdgeDoubleClick:Re,onEdgeMouseEnter:Ce,onEdgeMouseMove:Ne,onEdgeMouseLeave:Oe,onReconnect:Te??Ae,onReconnectStart:Ie??Pe,onReconnectEnd:je??De,reconnectRadius:Me??$e,defaultMarkerColor:ue,noDragClassName:ze,noWheelClassName:We,noPanClassName:Ge,elevateEdgesOnSelect:Ke,rfId:st,disableKeyboardA11y:Qe,nodeOrigin:ee,nodeExtent:ce}),ht.createElement(Ki,{nodes:e,edges:t,defaultNodes:n,defaultEdges:r,onConnect:p,onConnectStart:h,onConnectEnd:m,onClickConnectStart:g,onClickConnectEnd:b,nodesDraggable:Q,nodesConnectable:Z,nodesFocusable:J,edgesFocusable:te,edgesUpdatable:ne,elementsSelectable:re,elevateNodesOnSelect:Ye,minZoom:ae,maxZoom:ie,nodeExtent:ce,onNodesChange:Le,onEdgesChange:Fe,snapToGrid:q,snapGrid:X,connectionMode:j,translateExtent:le,connectOnClick:He,defaultEdgeOptions:Xe,fitView:Be,fitViewOptions:Ve,onNodesDelete:R,onEdgesDelete:C,onNodeDragStart:S,onNodeDrag:x,onNodeDragStop:k,onSelectionDrag:A,onSelectionDragStart:O,onSelectionDragStop:P,noPanClassName:Ge,nodeOrigin:ee,rfId:st,autoPanOnConnect:Ze,autoPanOnNodeDrag:Je,onError:nt,connectionRadius:et,isValidConnection:tt,nodeDragThreshold:at}),ht.createElement(Ui,{onSelectionChange:N}),xe,ht.createElement(ya,{proOptions:qe,position:Ue}),ht.createElement(rl,{rfId:st,disableKeyboardA11y:Qe})))}));Gs.displayName="ReactFlow";const Bs=e=>e.domNode?.querySelector(".react-flow__edgelabel-renderer");function Vs({children:e}){const t=ha(Bs);return t?(0,ua.createPortal)(e,t):null}function Hs(e){return t=>{const[n,r]=(0,ht.useState)(t),o=(0,ht.useCallback)((t=>r((n=>e(t,n)))),[]);return[n,r,o]}}function Us(e){return Us="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},Us(e)}function qs(e){return function(e){if(Array.isArray(e))return Xs(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return Xs(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)?Xs(e,t):void 0}}(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 Xs(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n0&&void 0!==arguments[0]?arguments[0]:Js,n=arguments.length>1?arguments[1]:void 0;switch(n.type){case"SET_ACTIVE_FEATURES":return n.payload.forEach((function(e){nc.includes(e)&&ic(e,!0)})),null===(e=n.payload.includes(g)?null:t.activeSidebarName)&&(0,$.dispatch)("core/interface").disableComplementaryArea(k),Ks(Ks({},t),{},{activeFeatures:n.payload,activeSidebarName:e});case"TOGGLE_FEATURE":var r=n.payload,o=qs(t.activeFeatures);return o.includes(r)?o=o.filter((function(e){return e!==r})):o.push(r),nc.forEach((function(e){o.includes(e)?ic(e,!0):ic(e,!1)})),null===(e=o.includes(g)?null:t.activeSidebarName)&&(0,$.dispatch)("core/interface").disableComplementaryArea(k),Ks(Ks({},t),{},{activeFeatures:o,activeSidebarName:e});case"ENABLE_FEATURE":var a=n.payload;nc.includes(a)&&ic(a,!0);var i=[].concat(qs(t.activeFeatures),[a]);return null===(e=i.includes(g)?null:t.activeSidebarName)&&(0,$.dispatch)("core/interface").disableComplementaryArea(k),Ks(Ks({},t),{},{activeFeatures:i,activeSidebarName:e});case"DISABLE_FEATURE":var l=n.payload;return nc.includes(l)&&ic(l,!1),Ks(Ks({},t),{},{activeFeatures:t.activeFeatures.filter((function(e){return e!==l}))});case"SET_CURRENT_INSERTER_TAB":return Ks(Ks({},t),{},{currentInserterTab:n.payload});case"SET_TRIGGER_CATEGORIES":return Ks(Ks({},t),{},{triggerCategories:n.payload});case"SET_TRIGGER_NODES":return Ks(Ks({},t),{},{triggerNodes:n.payload});case"SET_ACTION_CATEGORIES":return Ks(Ks({},t),{},{actionCategories:n.payload});case"SET_ACTION_NODES":return Ks(Ks({},t),{},{actionNodes:n.payload});case"SET_ADVANCED_CATEGORIES":return Ks(Ks({},t),{},{advancedCategories:n.payload});case"SET_ADVANCED_NODES":return Ks(Ks({},t),{},{advancedNodes:n.payload});case"CLOSE_GENERAL_SIDEBAR":return Ks(Ks({},t),{},{activeSidebarName:null});case"OPEN_GENERAL_SIDEBAR":return Ks(Ks({},t),{},{activeSidebarName:n.payload,activeFeatures:t.activeFeatures.filter((function(e){return e!==g}))});case"SET_HOVERED_ITEM":return Ks(Ks({},t),{},{hoveredItem:n.payload});case"SET_PANEL_BODY_STATE":var s=Ks(Ks({},t),{},{panelBodyStates:Ks(Ks({},t.panelBodyStates),{},Qs({},n.payload.panel,n.payload.state))});return lc(n.payload.panel,n.payload.state),s}return t},actions:{setActiveFeatures:function(e){return{type:"SET_ACTIVE_FEATURES",payload:e}},toggleFeature:function(e){return{type:"TOGGLE_FEATURE",payload:e}},disableFeature:function(e){return{type:"DISABLE_FEATURE",payload:e}},enableFeature:function(e){return{type:"ENABLE_FEATURE",payload:e}},setCurrentInserterTab:function(e){return{type:"SET_CURRENT_INSERTER_TAB",payload:e}},setTriggerCategories:function(e){return{type:"SET_TRIGGER_CATEGORIES",payload:e}},setTriggerNodes:function(e){return{type:"SET_TRIGGER_NODES",payload:e}},setActionCategories:function(e){return{type:"SET_ACTION_CATEGORIES",payload:e}},setActionNodes:function(e){return{type:"SET_ACTION_NODES",payload:e}},setAdvancedCategories:function(e){return{type:"SET_ADVANCED_CATEGORIES",payload:e}},setAdvancedNodes:function(e){return{type:"SET_ADVANCED_NODES",payload:e}},closeGeneralSidebar:function(){return(0,$.dispatch)("core/interface").disableComplementaryArea(k),{type:"CLOSE_GENERAL_SIDEBAR",payload:null}},openGeneralSidebar:function(e){return(0,$.dispatch)("core/interface").enableComplementaryArea(k,e),{type:"OPEN_GENERAL_SIDEBAR",payload:e}},openInserter:function(){return{type:"ENABLE_FEATURE",payload:g}},closeInserter:function(){return{type:"DISABLE_FEATURE",payload:g}},setHoveredItem:function(e){return{type:"SET_HOVERED_ITEM",payload:e}},setPanelBodyState:function(e,t){return{type:"SET_PANEL_BODY_STATE",payload:{panel:e,state:t}}}},selectors:{getActiveFeatures:function(e){return e.activeFeatures},isFeatureActive:function(e,t){return e.activeFeatures.includes(t)},getCurrentInserterTab:function(e){return e.currentInserterTab},getTriggerCategories:function(e){return e.triggerCategories},getTriggerNodes:function(e){return e.triggerNodes},getActionCategories:function(e){return e.actionCategories},getActionNodes:function(e){return e.actionNodes},getAdvancedCategories:function(e){return e.advancedCategories},getAdvancedNodes:function(e){return e.advancedNodes},getHoveredItem:function(e){return e.hoveredItem},getPanelBodyState:function(e,t){return e.panelBodyStates[t]},getAllNodes:function(e){return e.triggerNodes.concat(e.actionNodes,e.advancedNodes)},getNodeTypeByName:function(e,t){return e.triggerNodes.concat(e.actionNodes,e.advancedNodes).find((function(e){return e.name===t}))||{}},isRayDebugInstalled:function(e){return e.advancedNodes.some((function(e){return"advanced/ray.debug"===e.name}))},isPro:function(e){return e.isPro}}});(0,$.register)(ec);var tc="FUTURE_PRO_WORKFLOW_PREFERENCES_"+futureWorkflowEditor.currentUserId,nc=[h,b,y,v,w,_];null===localStorage.getItem(tc)&&localStorage.setItem(tc,JSON.stringify({persistentFeatures:{},panelBodyStates:{}}));var rc=function(){return JSON.parse(localStorage.getItem(tc))},oc=function(e){localStorage.setItem(tc,JSON.stringify(e))},ac=function(e){var t;return null===(t=rc().persistentFeatures)||void 0===t?void 0:t[e]},ic=function(e,t){var n=rc();n.persistentFeatures||(n.persistentFeatures={}),n.persistentFeatures[e]=t,oc(n)},lc=function(e,t){var n=rc();n.panelBodyStates||(n.panelBodyStates={}),n.panelBodyStates[e]=t,oc(n)};null==ac(h)&&ic(h,!0),null==ac(y)&&ic(y,!0),null==ac(_)&&ic(_,!0),nc.forEach((function(e){ac(e)?(0,$.dispatch)(ec).enableFeature(e):(0,$.dispatch)(ec).disableFeature(e)}));var sc=rc().panelBodyStates||{};function cc(e){return cc="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},cc(e)}function uc(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 dc(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:window).navigator.platform;return-1!==e.indexOf("Mac")||["iPad","iPhone"].includes(e)}function hc(e){var t=(0,$.select)(yf).getNodes(),n=(0,$.select)(yf).getEdges();return e?((e,t,n)=>{if(!ui(e))return[];const r=n.filter((t=>t.target===e.id)).map((e=>e.source));return t.filter((e=>r.includes(e.id)))})(e,t,n):[]}function mc(e){var t=hc(e);if(!t.length)return[];var n=t;return t.forEach((function(e){var t=mc(e);n=n.concat(t)})),n}function gc(e){var t=(0,$.select)(ec).getNodeTypeByName,n=hc(e),r=[];n.forEach((function(e){var n,o,a=t(null===(n=e.data)||void 0===n?void 0:n.name);null!=a&&null!==(o=a.outputSchema)&&void 0!==o&&o.length&&a.outputSchema.forEach((function(t){"input"===t.type?gc(e).map((function(e){r.push(dc(dc({},e),{},{name:"".concat(e.name),type:e.type,nodeLabel:a.label}))})):r.push(dc(dc({},t),{},{name:"".concat(e.data.slug,".").concat(t.name),type:t.type,nodeLabel:a.label}))}))}));var o=r.filter((function(e,t,n){return t===n.findIndex((function(t){return t.name===e.name}))}));return o.sort((function(e,t){return e.namet.name?1:0})),o}function bc(e){var t=(0,(0,$.select)(yf).getDataTypeByName)(e.type),n={id:e.name,name:e.label,children:[],type:null==e?void 0:e.type,itemsType:null==e?void 0:e.itemsType};return"object"===t.type&&(n.children=t.propertiesSchema.map((function(t){return{id:e.name+"."+t.name,name:e.label+" -> "+t.label}}))),n}function yc(e,t){var n=!0;return null!=t&&t.length&&(n=t.includes(null==e?void 0:e.type),"object"!==(null==e?void 0:e.type)||n||(n=t.includes(null==e?void 0:e.objectType))),n}function vc(e,t){var n=(0,$.select)(yf).getDataTypeByName,r=[];return e.forEach((function(e){var o=n(e.type),a=null==e?void 0:e.itemsType,i=yc(o,t);if("array"===e.type&&a&&!i){var l=t.map((function(e){return e.startsWith("array:")?e.replace("array:",""):null}));i=yc(n(a),l)}var s=null,c=[];"object"===o.type?(o.propertiesSchema.forEach((function(r){yc(n(r.type),t)&&c.push({id:e.id+"."+r.name,name:e.name+" -> "+r.label})})),s={id:e.id,name:e.name,children:c,type:e.type},i?r.push(s):c.length&&(r=r.concat(c))):i&&r.push(e)})),r}sc&&Object.keys(sc).forEach((function(e){(0,$.dispatch)(ec).setPanelBodyState(e,sc[e])}));var wc=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"node",t=((new Date).getTime()-new Date("2024-01-01 00:00:00").getTime()).toString(32);return"".concat(e,"_").concat(t)};function _c(e){var t,n=e.item,r=e.position,o=e.reactFlowInstance,a=function(e){var t=(0,$.select)(ec).getNodeTypeByName(e.name),n=(0,$.select)(yf).getBaseSlugCounts(),r=t.baseSlug;r||(r="node"),(0,$.dispatch)(yf).incrementBaseSlugCounts(r);var o=n[r]||0;return"".concat(r).concat(o+1)}(n),i=(0,$.select)(yf).getNodes(),l=null!==(t=n.baseSlug)&&void 0!==t?t:"node",s={id:wc(l),type:n.type,position:r,data:{name:n.name,elementaryType:n.elementaryType,version:n.version,slug:a,settings:{}}};return n.settingsSchema&&n.settingsSchema.forEach((function(e){e.fields.forEach((function(e){void 0!==e.default&&(s.data.settings[e.name]=e.default)}))})),i=i.filter((function(e){return e.data.elementaryType!==A})),(0,$.dispatch)(yf).setNodes(i.concat(s)),function(e){setTimeout((function(){(0,$.dispatch)(yf).setEditedWorkflowAttribute("flow",e.toObject())}),400)}(o),s}var Ec=function(){return{id:wc("triggerPlaceholder"),type:"triggerPlaceholder",position:{x:0,y:0},data:{name:"placeholder/trigger",elementaryType:A,version:1,slug:"triggerPlaceholder1"}}};function Sc(e){return Sc="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},Sc(e)}function xc(e){return function(e){if(Array.isArray(e))return kc(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return kc(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)?kc(e,t):void 0}}(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 kc(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);nr?o:r}(e,n),a=null==r?void 0:r.baseSlug;return a&&o?Cc(Cc({},e),{},{baseSlugCounts:Cc(Cc({},e.baseSlugCounts),{},Nc({},a,o))}):e};const Mc=(()=>{let e=0;return()=>(e+=1,`u${`0000${(Math.random()*36**4|0).toString(36)}`.slice(-4)}${e}`)})();function $c(e){const t=[];for(let n=0,r=e.length;n{const r=new Image;r.decode=()=>t(r),r.onload=()=>t(r),r.onerror=n,r.crossOrigin="anonymous",r.decoding="async",r.src=e}))}const Gc=(e,t)=>{if(e instanceof t)return!0;const n=Object.getPrototypeOf(e);return null!==n&&(n.constructor.name===t.name||Gc(n,t))};function Bc(e,t,n){const r=window.getComputedStyle(e,n),o=r.getPropertyValue("content");if(""===o||"none"===o)return;const a=Mc();try{t.className=`${t.className} ${a}`}catch(e){return}const i=document.createElement("style");i.appendChild(function(e,t,n){const r=`.${e}:${t}`,o=n.cssText?function(e){const t=e.getPropertyValue("content");return`${e.cssText} content: '${t.replace(/'|"/g,"")}';`}(n):function(e){return $c(e).map((t=>`${t}: ${e.getPropertyValue(t)}${e.getPropertyPriority(t)?" !important":""};`)).join(" ")}(n);return document.createTextNode(`${r}{${o}}`)}(a,n,r)),t.appendChild(i)}const Vc="application/font-woff",Hc="image/jpeg",Uc={woff:Vc,woff2:Vc,ttf:"application/font-truetype",eot:"application/vnd.ms-fontobject",png:"image/png",jpg:Hc,jpeg:Hc,gif:"image/gif",tiff:"image/tiff",svg:"image/svg+xml",webp:"image/webp"};function qc(e){const t=function(e){const t=/\.([^./]*?)$/g.exec(e);return t?t[1]:""}(e).toLowerCase();return Uc[t]||""}function Xc(e){return-1!==e.search(/^(data:)/)}function Yc(e,t){return`data:${t};base64,${e}`}async function Kc(e,t,n){const r=await fetch(e,t);if(404===r.status)throw new Error(`Resource "${r.url}" not found`);const o=await r.blob();return new Promise(((e,t)=>{const a=new FileReader;a.onerror=t,a.onloadend=()=>{try{e(n({res:r,result:a.result}))}catch(e){t(e)}},a.readAsDataURL(o)}))}const Qc={};async function Zc(e,t,n){const r=function(e,t,n){let r=e.replace(/\?.*/,"");return n&&(r=e),/ttf|otf|eot|woff2?/i.test(r)&&(r=r.replace(/.*\//,"")),t?`[${t}]${r}`:r}(e,t,n.includeQueryParams);if(null!=Qc[r])return Qc[r];let o;n.cacheBust&&(e+=(/\?/.test(e)?"&":"?")+(new Date).getTime());try{const r=await Kc(e,n.fetchRequestInit,(({res:e,result:n})=>(t||(t=e.headers.get("Content-Type")||""),function(e){return e.split(/,/)[1]}(n))));o=Yc(r,t)}catch(t){o=n.imagePlaceholder||"";let r=`Failed to fetch resource: ${e}`;t&&(r="string"==typeof t?t:t.message),r&&console.warn(r)}return Qc[r]=o,o}const Jc=e=>null!=e.tagName&&"SLOT"===e.tagName.toUpperCase();async function eu(e,t,n){return n||!t.filter||t.filter(e)?Promise.resolve(e).then((e=>async function(e,t){return Gc(e,HTMLCanvasElement)?async function(e){const t=e.toDataURL();return"data:,"===t?e.cloneNode(!1):Wc(t)}(e):Gc(e,HTMLVideoElement)?async function(e,t){if(e.currentSrc){const t=document.createElement("canvas"),n=t.getContext("2d");return t.width=e.clientWidth,t.height=e.clientHeight,null==n||n.drawImage(e,0,0,t.width,t.height),Wc(t.toDataURL())}const n=e.poster,r=qc(n);return Wc(await Zc(n,r,t))}(e,t):Gc(e,HTMLIFrameElement)?async function(e){var t;try{if(null===(t=null==e?void 0:e.contentDocument)||void 0===t?void 0:t.body)return await eu(e.contentDocument.body,{},!0)}catch(e){}return e.cloneNode(!1)}(e):e.cloneNode(!1)}(e,t))).then((n=>async function(e,t,n){var r,o;let a=[];return a=Jc(e)&&e.assignedNodes?$c(e.assignedNodes()):Gc(e,HTMLIFrameElement)&&(null===(r=e.contentDocument)||void 0===r?void 0:r.body)?$c(e.contentDocument.body.childNodes):$c((null!==(o=e.shadowRoot)&&void 0!==o?o:e).childNodes),0===a.length||Gc(e,HTMLVideoElement)||await a.reduce(((e,r)=>e.then((()=>eu(r,n))).then((e=>{e&&t.appendChild(e)}))),Promise.resolve()),t}(e,n,t))).then((t=>function(e,t){return Gc(t,Element)&&(function(e,t){const n=t.style;if(!n)return;const r=window.getComputedStyle(e);r.cssText?(n.cssText=r.cssText,n.transformOrigin=r.transformOrigin):$c(r).forEach((o=>{let a=r.getPropertyValue(o);if("font-size"===o&&a.endsWith("px")){const e=Math.floor(parseFloat(a.substring(0,a.length-2)))-.1;a=`${e}px`}Gc(e,HTMLIFrameElement)&&"display"===o&&"inline"===a&&(a="block"),"d"===o&&t.getAttribute("d")&&(a=`path(${t.getAttribute("d")})`),n.setProperty(o,a,r.getPropertyPriority(o))}))}(e,t),function(e,t){Bc(e,t,":before"),Bc(e,t,":after")}(e,t),function(e,t){Gc(e,HTMLTextAreaElement)&&(t.innerHTML=e.value),Gc(e,HTMLInputElement)&&t.setAttribute("value",e.value)}(e,t),function(e,t){if(Gc(e,HTMLSelectElement)){const n=t,r=Array.from(n.children).find((t=>e.value===t.getAttribute("value")));r&&r.setAttribute("selected","")}}(e,t)),t}(e,t))).then((e=>async function(e,t){const n=e.querySelectorAll?e.querySelectorAll("use"):[];if(0===n.length)return e;const r={};for(let o=0;o{for(;;){const[n,,r]=nu.exec(e)||[];if(!r)return"";if(r===t)return`src: ${n};`}})):e}(e,n),o=function(e){const t=[];return e.replace(tu,((e,n,r)=>(t.push(r),e))),t.filter((e=>!Xc(e)))}(r);return o.reduce(((e,r)=>e.then((e=>async function(e,t,n,r,o){try{const a=n?function(e,t){if(e.match(/^[a-z]+:\/\//i))return e;if(e.match(/^\/\//))return window.location.protocol+e;if(e.match(/^[a-z]+:/i))return e;const n=document.implementation.createHTMLDocument(),r=n.createElement("base"),o=n.createElement("a");return n.head.appendChild(r),n.body.appendChild(o),t&&(r.href=t),o.href=e,o.href}(t,n):t,i=qc(t);let l;return l=o?Yc(await o(a),i):await Zc(a,i,r),e.replace(function(e){const t=e.replace(/([.*+?^${}()|\[\]\/\\])/g,"\\$1");return new RegExp(`(url\\(['"]?)(${t})(['"]?\\))`,"g")}(t),`$1${l}$3`)}catch(e){}return e}(e,r,t,n)))),Promise.resolve(r))}async function iu(e,t,n){var r;const o=null===(r=t.style)||void 0===r?void 0:r.getPropertyValue(e);if(o){const r=await au(o,null,n);return t.style.setProperty(e,r,t.style.getPropertyPriority(e)),!0}return!1}async function lu(e,t){Gc(e,Element)&&(await async function(e,t){await iu("background",e,t)||await iu("background-image",e,t),await iu("mask",e,t)||await iu("mask-image",e,t)}(e,t),await async function(e,t){const n=Gc(e,HTMLImageElement);if((!n||Xc(e.src))&&(!Gc(e,SVGImageElement)||Xc(e.href.baseVal)))return;const r=n?e.src:e.href.baseVal,o=await Zc(r,qc(r),t);await new Promise(((t,r)=>{e.onload=t,e.onerror=r;const a=e;a.decode&&(a.decode=t),"lazy"===a.loading&&(a.loading="eager"),n?(e.srcset="",e.src=o):e.href.baseVal=o}))}(e,t),await async function(e,t){const n=$c(e.childNodes).map((e=>lu(e,t)));await Promise.all(n).then((()=>e))}(e,t))}const su={};async function cu(e){let t=su[e];if(null!=t)return t;const n=await fetch(e);return t={url:e,cssText:await n.text()},su[e]=t,t}async function uu(e,t){let n=e.cssText;const r=/url\(["']?([^"')]+)["']?\)/g,o=(n.match(/url\([^)]+\)/g)||[]).map((async o=>{let a=o.replace(r,"$1");return a.startsWith("https://")||(a=new URL(a,e.url).href),Kc(a,t.fetchRequestInit,(({result:e})=>(n=n.replace(o,`url(${e})`),[o,e])))}));return Promise.all(o).then((()=>n))}function du(e){if(null==e)return[];const t=[];let n=e.replace(/(\/\*[\s\S]*?\*\/)/gi,"");const r=new RegExp("((@.*?keyframes [\\s\\S]*?){([\\s\\S]*?}\\s*?)})","gi");for(;;){const e=r.exec(n);if(null===e)break;t.push(e[0])}n=n.replace(r,"");const o=/@import[\s\S]*?url\([^)]*\)[\s\S]*?;/gi,a=new RegExp("((\\s*?(?:\\/\\*[\\s\\S]*?\\*\\/)?\\s*?@media[\\s\\S]*?){([\\s\\S]*?)}\\s*?})|(([\\s\\S]*?){([\\s\\S]*?)})","gi");for(;;){let e=o.exec(n);if(null===e){if(e=a.exec(n),null===e)break;o.lastIndex=a.lastIndex}else a.lastIndex=o.lastIndex;t.push(e[0])}return t}async function fu(e,t){const n=null!=t.fontEmbedCSS?t.fontEmbedCSS:t.skipFonts?null:await async function(e,t){const n=await async function(e,t){if(null==e.ownerDocument)throw new Error("Provided element is not within a Document");const n=$c(e.ownerDocument.styleSheets),r=await async function(e,t){const n=[],r=[];return e.forEach((n=>{if("cssRules"in n)try{$c(n.cssRules||[]).forEach(((e,o)=>{if(e.type===CSSRule.IMPORT_RULE){let a=o+1;const i=cu(e.href).then((e=>uu(e,t))).then((e=>du(e).forEach((e=>{try{n.insertRule(e,e.startsWith("@import")?a+=1:n.cssRules.length)}catch(t){console.error("Error inserting rule from remote css",{rule:e,error:t})}})))).catch((e=>{console.error("Error loading remote css",e.toString())}));r.push(i)}}))}catch(o){const a=e.find((e=>null==e.href))||document.styleSheets[0];null!=n.href&&r.push(cu(n.href).then((e=>uu(e,t))).then((e=>du(e).forEach((e=>{a.insertRule(e,n.cssRules.length)})))).catch((e=>{console.error("Error loading remote stylesheet",e)}))),console.error("Error inlining remote css file",o)}})),Promise.all(r).then((()=>(e.forEach((e=>{if("cssRules"in e)try{$c(e.cssRules||[]).forEach((e=>{n.push(e)}))}catch(t){console.error(`Error while reading CSS rules from ${e.href}`,t)}})),n)))}(n,t);return function(e){return e.filter((e=>e.type===CSSRule.FONT_FACE_RULE)).filter((e=>ou(e.style.getPropertyValue("src"))))}(r)}(e,t);return(await Promise.all(n.map((e=>{const n=e.parentStyleSheet?e.parentStyleSheet.href:null;return au(e.cssText,n,t)})))).join("\n")}(e,t);if(n){const t=document.createElement("style"),r=document.createTextNode(n);t.appendChild(r),e.firstChild?e.insertBefore(t,e.firstChild):e.appendChild(t)}}async function pu(e,t={}){const{width:n,height:r}=Fc(e,t),o=await eu(e,t,!0);return await fu(o,t),await lu(o,t),function(e,t){const{style:n}=e;t.backgroundColor&&(n.backgroundColor=t.backgroundColor),t.width&&(n.width=`${t.width}px`),t.height&&(n.height=`${t.height}px`);const r=t.style;null!=r&&Object.keys(r).forEach((e=>{n[e]=r[e]}))}(o,t),await async function(e,t,n){const r="http://www.w3.org/2000/svg",o=document.createElementNS(r,"svg"),a=document.createElementNS(r,"foreignObject");return o.setAttribute("width",`${t}`),o.setAttribute("height",`${n}`),o.setAttribute("viewBox",`0 0 ${t} ${n}`),a.setAttribute("width","100%"),a.setAttribute("height","100%"),a.setAttribute("x","0"),a.setAttribute("y","0"),a.setAttribute("externalResourcesRequired","true"),o.appendChild(a),a.appendChild(e),async function(e){return Promise.resolve().then((()=>(new XMLSerializer).serializeToString(e))).then(encodeURIComponent).then((e=>`data:image/svg+xml;charset=utf-8,${e}`))}(o)}(o,n,r)}function hu(e){return hu="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},hu(e)}function mu(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 gu(e){for(var t=1;t0},Ru=function(e){return e.selectedEdges.length>0},Cu=function(e){return e.workflow.status},Nu=function(e){return e.workflow},Ou=function(e){return e.editedWorkflowAttributes},Au=function(e,t){return e.editedWorkflowAttributes.hasOwnProperty(t)?e.editedWorkflowAttributes[t]:e.workflow[t]},Pu=function(e){return!!e.isLoadingWorkflow},Du=function(e){return!!e.isCreatingWorkflow},Tu=function(e){return gu(gu({},e.workflow),e.editedWorkflowAttributes)},Iu=function(e){return Object.keys(e.editedWorkflowAttributes).length>0},ju=function(e){return""===e.workflow.flow.trim()},Mu=function(e){return!!e.isNewWorkflow},$u=function(e){return e.initialViewport},Lu=function(e){return!!e.isSavingWorkflow},Fu=function(e){return"publish"===e.workflow.status},zu=function(e){return!!e.isDeletingWorkflow},Wu=function(e){return!!e.isAutosavingWorkflow},Gu=function(e){var t;return t=e.editedWorkflowAttributes.hasOwnProperty("title")?e.editedWorkflowAttributes.title:e.workflow.title,Object.keys(e.editedWorkflowAttributes).length>0&&!e.isSavingWorkflow&&!e.isAutosavingWorkflow&&""!==String(t).trim()},Bu=function(e){return e.isCurrentWorkflowPublished},Vu=function(e){return e.selectedNodes.length+e.selectedEdges.length},Hu=function(e){return e.selectedNodes.length},Uu=function(e){return e.selectedEdges.length},qu=function(e){return e.dataTypes},Xu=function(e,t){return e.dataTypes.find((function(e){return e.name===t}))};function Yu(){return new Promise((function(e,t){try{(async function(e,t={}){return(await async function(e,t={}){const{width:n,height:r}=Fc(e,t),o=await pu(e,t),a=await Wc(o),i=document.createElement("canvas"),l=i.getContext("2d"),s=t.pixelRatio||function(){let e,t;try{t=process}catch(e){}const n=t&&t.env?t.env.devicePixelRatio:null;return n&&(e=parseInt(n,10),Number.isNaN(e)&&(e=1)),e||window.devicePixelRatio||1}(),c=t.canvasWidth||n,u=t.canvasHeight||r;return i.width=c*s,i.height=u*s,t.skipAutoScale||function(e){(e.width>zc||e.height>zc)&&(e.width>zc&&e.height>zc?e.width>e.height?(e.height*=zc/e.width,e.width=zc):(e.width*=zc/e.height,e.height=zc):e.width>zc?(e.height*=zc/e.width,e.width=zc):(e.width*=zc/e.height,e.height=zc))}(i),i.style.width=`${c}`,i.style.height=`${u}`,t.backgroundColor&&(l.fillStyle=t.backgroundColor,l.fillRect(0,0,i.width,i.height)),l.drawImage(a,0,0,i.width,i.height),i}(e,t)).toDataURL()})(document.querySelector(".react-flow"),{filter:function(e){var t,n,r;return!(null!=e&&null!==(t=e.classList)&&void 0!==t&&t.contains("react-flow__minimap")||null!=e&&null!==(n=e.classList)&&void 0!==n&&n.contains("react-flow__controls")||null!=e&&null!==(r=e.classList)&&void 0!==r&&r.contains("pwe-node-edit-button"))}}).then((function(t){e(t)})).catch((function(e){t(e)}))}catch(e){t(e)}}))}function Ku(e){return e.globalVariables}function Qu(e,t){return e.globalVariables.find((function(e){return e.name===t}))}function Zu(e,t){return e.taxonomyTerms[t]||[]}function Ju(e){return e.baseSlugCounts}function ed(e,t){return e.nodeErrors[t]||[]}function td(e){return e.draggingFromHandle}function nd(e){return!!e.isConnectingNodes}function rd(e){return e.rayDebug.showQueries}function od(e){return e.rayDebug.showEmails}function ad(e){return e.rayDebug.showWordPressErrors}const id=(e,t)=>{let n,r,o=e.path;return"string"==typeof e.namespace&&"string"==typeof e.endpoint&&(n=e.namespace.replace(/^\/|\/$/g,""),r=e.endpoint.replace(/^\//,""),o=r?n+"/"+r:n),delete e.namespace,delete e.endpoint,t({...e,path:o})},ld=wp.url;function sd(e,t){return Promise.resolve(t?e.body:new window.Response(JSON.stringify(e.body),{status:200,statusText:"OK",headers:e.headers}))}const cd=({path:e,url:t,...n},r)=>({...n,url:t&&(0,ld.addQueryArgs)(t,r),path:e&&(0,ld.addQueryArgs)(e,r)}),ud=e=>e.json?e.json():Promise.reject(e),dd=e=>{const{next:t}=(e=>{if(!e)return{};const t=e.match(/<([^>]+)>; rel="next"/);return t?{next:t[1]}:{}})(e.headers.get("link"));return t},fd=async(e,t)=>{if(!1===e.parse)return t(e);if(!(e=>{const t=!!e.path&&-1!==e.path.indexOf("per_page=-1"),n=!!e.url&&-1!==e.url.indexOf("per_page=-1");return t||n})(e))return t(e);const n=await Sd({...cd(e,{per_page:100}),parse:!1}),r=await ud(n);if(!Array.isArray(r))return r;let o=dd(n);if(!o)return r;let a=[].concat(r);for(;o;){const t=await Sd({...e,path:void 0,url:o,parse:!1}),n=await ud(t);a=a.concat(n),o=dd(t)}return a},pd=new Set(["PATCH","PUT","DELETE"]),hd="GET",md=(e,t=!0)=>Promise.resolve(((e,t=!0)=>t?204===e.status?null:e.json?e.json():Promise.reject(e):e)(e,t)).catch((e=>gd(e,t)));function gd(e,t=!0){if(!t)throw e;return(e=>{const t={code:"invalid_json",message:(0,L.__)("The response is not a valid JSON response.")};if(!e||!e.json)throw t;return e.json().catch((()=>{throw t}))})(e).then((e=>{const t={code:"unknown_error",message:(0,L.__)("An unknown error occurred.")};throw e||t}))}const bd={Accept:"application/json, */*;q=0.1"},yd={credentials:"include"},vd=[(e,t)=>("string"!=typeof e.url||(0,ld.hasQueryArg)(e.url,"_locale")||(e.url=(0,ld.addQueryArgs)(e.url,{_locale:"user"})),"string"!=typeof e.path||(0,ld.hasQueryArg)(e.path,"_locale")||(e.path=(0,ld.addQueryArgs)(e.path,{_locale:"user"})),t(e)),id,(e,t)=>{const{method:n=hd}=e;return pd.has(n.toUpperCase())&&(e={...e,headers:{...e.headers,"X-HTTP-Method-Override":n,"Content-Type":"application/json"},method:"POST"}),t(e)},fd],wd=e=>{if(e.status>=200&&e.status<300)return e;throw e};let _d=e=>{const{url:t,path:n,data:r,parse:o=!0,...a}=e;let{body:i,headers:l}=e;return l={...bd,...l},r&&(i=JSON.stringify(r),l["Content-Type"]="application/json"),window.fetch(t||n||window.location.href,{...yd,...a,body:i,headers:l}).then((e=>Promise.resolve(e).then(wd).catch((e=>gd(e,o))).then((e=>md(e,o)))),(e=>{if(e&&"AbortError"===e.name)throw e;throw{code:"fetch_error",message:(0,L.__)("You are probably offline.")}}))};function Ed(e){return vd.reduceRight(((e,t)=>n=>t(n,e)),_d)(e).catch((t=>"rest_cookie_invalid_nonce"!==t.code?Promise.reject(t):window.fetch(Ed.nonceEndpoint).then(wd).then((e=>e.text())).then((t=>(Ed.nonceMiddleware.nonce=t,Ed(e))))))}Ed.use=function(e){vd.unshift(e)},Ed.setFetchHandler=function(e){_d=e},Ed.createNonceMiddleware=function(e){const t=(e,n)=>{const{headers:r={}}=e;for(const o in r)if("x-wp-nonce"===o.toLowerCase()&&r[o]===t.nonce)return n(e);return n({...e,headers:{...r,"X-WP-Nonce":t.nonce}})};return t.nonce=e,t},Ed.createPreloadingMiddleware=function(e){const t=Object.fromEntries(Object.entries(e).map((([e,t])=>[(0,ld.normalizePath)(e),t])));return(e,n)=>{const{parse:r=!0}=e;let o=e.path;if(!o&&e.url){const{rest_route:t,...n}=(0,ld.getQueryArgs)(e.url);"string"==typeof t&&(o=(0,ld.addQueryArgs)(t,n))}if("string"!=typeof o)return n(e);const a=e.method||"GET",i=(0,ld.normalizePath)(o);if("GET"===a&&t[i]){const e=t[i];return delete t[i],sd(e,!!r)}if("OPTIONS"===a&&t[a]&&t[a][i]){const e=t[a][i];return delete t[a][i],sd(e,!!r)}return n(e)}},Ed.createRootURLMiddleware=e=>(t,n)=>id(t,(t=>{let r,o=t.url,a=t.path;return"string"==typeof a&&(r=e,-1!==e.indexOf("?")&&(a=a.replace("?","&")),a=a.replace(/^\//,""),"string"==typeof r&&-1!==r.indexOf("?")&&(a=a.replace("?","&")),o=r+a),n({...t,url:o})})),Ed.fetchAllMiddleware=fd,Ed.mediaUploadMiddleware=(e,t)=>{if(!function(e){const t=!!e.method&&"POST"===e.method;return(!!e.path&&-1!==e.path.indexOf("/wp/v2/media")||!!e.url&&-1!==e.url.indexOf("/wp/v2/media"))&&t}(e))return t(e);let n=0;const r=e=>(n++,t({path:`/wp/v2/media/${e}/post-process`,method:"POST",data:{action:"create-image-subsizes"},parse:!1}).catch((()=>n<5?r(e):(t({path:`/wp/v2/media/${e}?force=true`,method:"DELETE"}),Promise.reject()))));return t({...e,parse:!1}).catch((t=>{const n=t.headers.get("x-wp-upload-attachment-id");return t.status>=500&&t.status<600&&n?r(n).catch((()=>!1!==e.parse?Promise.reject({code:"post_process",message:(0,L.__)("Media upload failed. If this is a photo or a large image, please scale it down and try again.")}):Promise.reject(t))):gd(t,e.parse)})).then((t=>md(t,e.parse)))},Ed.createThemePreviewMiddleware=e=>(t,n)=>{if("string"==typeof t.url){const n=(0,ld.getQueryArg)(t.url,"wp_theme_preview");void 0===n?t.url=(0,ld.addQueryArgs)(t.url,{wp_theme_preview:e}):""===n&&(t.url=(0,ld.removeQueryArgs)(t.url,"wp_theme_preview"))}if("string"==typeof t.path){const n=(0,ld.getQueryArg)(t.path,"wp_theme_preview");void 0===n?t.path=(0,ld.addQueryArgs)(t.path,{wp_theme_preview:e}):""===n&&(t.path=(0,ld.removeQueryArgs)(t.path,"wp_theme_preview"))}return n(t)};const Sd=Ed;function xd(e){return{type:"API_FETCH",request:e}}const kd={AWAIT_PROMISE:({promise:e})=>e,API_FETCH:({request:e})=>Sd(e)};function Rd(e){return Rd="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},Rd(e)}function Cd(){Cd=function(){return t};var e,t={},n=Object.prototype,r=n.hasOwnProperty,o=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",l=a.asyncIterator||"@@asyncIterator",s=a.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(e){c=function(e,t,n){return e[t]=n}}function u(e,t,n,r){var a=t&&t.prototype instanceof b?t:b,i=Object.create(a.prototype),l=new A(r||[]);return o(i,"_invoke",{value:R(e,n,l)}),i}function d(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}t.wrap=u;var f="suspendedStart",p="suspendedYield",h="executing",m="completed",g={};function b(){}function y(){}function v(){}var w={};c(w,i,(function(){return this}));var _=Object.getPrototypeOf,E=_&&_(_(P([])));E&&E!==n&&r.call(E,i)&&(w=E);var S=v.prototype=b.prototype=Object.create(w);function x(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function k(e,t){function n(o,a,i,l){var s=d(e[o],e,a);if("throw"!==s.type){var c=s.arg,u=c.value;return u&&"object"==Rd(u)&&r.call(u,"__await")?t.resolve(u.__await).then((function(e){n("next",e,i,l)}),(function(e){n("throw",e,i,l)})):t.resolve(u).then((function(e){c.value=e,i(c)}),(function(e){return n("throw",e,i,l)}))}l(s.arg)}var a;o(this,"_invoke",{value:function(e,r){function o(){return new t((function(t,o){n(e,r,t,o)}))}return a=a?a.then(o,o):o()}})}function R(t,n,r){var o=f;return function(a,i){if(o===h)throw Error("Generator is already running");if(o===m){if("throw"===a)throw i;return{value:e,done:!0}}for(r.method=a,r.arg=i;;){var l=r.delegate;if(l){var s=C(l,r);if(s){if(s===g)continue;return s}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(o===f)throw o=m,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);o=h;var c=d(t,n,r);if("normal"===c.type){if(o=r.done?m:p,c.arg===g)continue;return{value:c.arg,done:r.done}}"throw"===c.type&&(o=m,r.method="throw",r.arg=c.arg)}}}function C(t,n){var r=n.method,o=t.iterator[r];if(o===e)return n.delegate=null,"throw"===r&&t.iterator.return&&(n.method="return",n.arg=e,C(t,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),g;var a=d(o,t.iterator,n.arg);if("throw"===a.type)return n.method="throw",n.arg=a.arg,n.delegate=null,g;var i=a.arg;return i?i.done?(n[t.resultName]=i.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=e),n.delegate=null,g):i:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,g)}function N(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function O(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function A(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(N,this),this.reset(!0)}function P(t){if(t||""===t){var n=t[i];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,a=function n(){for(;++o=0;--a){var i=this.tryEntries[a],l=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var s=r.call(i,"catchLoc"),c=r.call(i,"finallyLoc");if(s&&c){if(this.prev=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),O(n),g}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;O(n)}return o}}throw Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:P(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),g}},t}var Nd=Cd().mark(jd),Od=Cd().mark(Yd),Ad=Cd().mark(ef),Pd=window.futureWorkflowEditor,Dd=Pd.apiUrl,Td=Pd.nonce,Id=["title","description","flow","status","debugRayShowQueries","debugRayShowEmails","debugRayShowWordPressErrors","debugRayShowCurrentRunningStep"];function jd(e){var t,n;return Cd().wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,{type:"LOAD_WORKFLOW_START"};case 2:if(0!=(e=parseInt(e,10))){r.next=19;break}return r.next=6,{type:"CREATE_WORKFLOW_START"};case 6:return r.prev=6,r.next=9,xd({path:"".concat(Dd,"/workflows"),method:"POST",headers:{"X-WP-Nonce":Td}});case 9:return t=r.sent,r.next=12,{type:"CREATE_WORKFLOW_SUCCESS",payload:t};case 12:r.next=19;break;case 14:return r.prev=14,r.t0=r.catch(6),(0,$.dispatch)("core/notices").createErrorNotice((0,L.__)("Unable to create a new workflow. Please try again.","post-expirator")),r.next=19,{type:"CREATE_WORKFLOW_FAILURE"};case 19:if(!(e>0)){r.next=33;break}return r.prev=20,r.next=23,xd({path:"".concat(Dd,"/workflows/").concat(e),headers:{"X-WP-Nonce":Td}});case 23:return n=r.sent,r.next=26,{type:"LOAD_WORKFLOW_SUCCESS",payload:n};case 26:r.next=33;break;case 28:return r.prev=28,r.t1=r.catch(20),(0,$.dispatch)("core/notices").createErrorNotice((0,L.__)("Unable to load the workflow. Please try again.","post-expirator")),r.next=33,{type:"LOAD_WORKFLOW_FAILURE"};case 33:case"end":return r.stop()}}),Nd,null,[[6,14],[20,28]])}function Md(e){var t=e.screenshot;return Cd().mark((function e(){var n,r,o;return Cd().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,{type:"SAVE_AS_DRAFT_START"};case 2:return e.prev=2,e.next=5,(0,$.select)(pt).isNewWorkflow();case 5:return n=e.sent,e.next=8,(0,$.dispatch)(pt).setEditedWorkflowAttribute("status","draft");case 8:return e.next=10,(0,$.select)(pt).getEditedWorkflow();case 10:return r=e.sent,t&&(r.screenshot=t),e.next=14,xd({path:"".concat(Dd,"/workflows/").concat(parseInt(r.id)),method:"PUT",headers:{"X-WP-Nonce":Td},body:JSON.stringify(r)});case 14:return o=e.sent,n&&window.history.pushState({},"","?page=future_workflow_editor&workflow=".concat(parseInt(o.id))),e.next=18,{type:"SAVE_AS_DRAFT_SUCCESS",payload:o};case 18:(0,$.dispatch)("core/notices").createSuccessNotice((0,L.__)("Workflow saved as draft.","post-expirator"),{type:"snackbar",isDismissible:!0}),e.next=26;break;case 21:return e.prev=21,e.t0=e.catch(2),(0,$.dispatch)("core/notices").createErrorNotice((0,L.__)("Unable to save workflow. Please, try again.","post-expirator")),e.next=26,{type:"SAVE_AS_DRAFT_FAILURE"};case 26:case"end":return e.stop()}}),e,null,[[2,21]])}))()}function $d(e){var t=e.screenshot;return Cd().mark((function e(){var n,r;return Cd().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,{type:"SAVE_AS_CURRENT_STATUS_START"};case 2:return e.prev=2,e.next=5,(0,$.select)(pt).getEditedWorkflow();case 5:return n=e.sent,t&&(n.screenshot=t),e.next=9,xd({path:"".concat(Dd,"/workflows/").concat(parseInt(n.id)),method:"PUT",headers:{"X-WP-Nonce":Td},body:JSON.stringify(n)});case 9:return r=e.sent,e.next=12,{type:"SAVE_AS_CURRENT_STATUS_SUCCESS",payload:r};case 12:(0,$.dispatch)("core/notices").createSuccessNotice((0,L.__)("Workflow saved.","post-expirator"),{type:"snackbar",isDismissible:!0}),e.next=20;break;case 15:return e.prev=15,e.t0=e.catch(2),(0,$.dispatch)("core/notices").createErrorNotice((0,L.__)("Unable to save workflow. Please, try again.","post-expirator")),e.next=20,{type:"SAVE_AS_CURRENT_STATUS_FAILURE"};case 20:case"end":return e.stop()}}),e,null,[[2,15]])}))()}function Ld(e){var t=e.screenshot;return Cd().mark((function e(){var n,r,o;return Cd().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,{type:"PUBLISH_WORKFLOW_START"};case 2:return e.prev=2,e.next=5,(0,$.select)(pt).isNewWorkflow();case 5:return n=e.sent,e.next=8,(0,$.dispatch)(pt).setEditedWorkflowAttribute("status","publish");case 8:return e.next=10,(0,$.select)(pt).getEditedWorkflow();case 10:return r=e.sent,t&&(r.screenshot=t),e.next=14,xd({path:"".concat(Dd,"/workflows/").concat(parseInt(r.id)),method:"PUT",headers:{"X-WP-Nonce":Td},body:JSON.stringify(r)});case 14:return o=e.sent,n&&window.history.pushState({},"","?page=future_workflow_editor&workflow=".concat(parseInt(o.id))),e.next=18,{type:"PUBLISH_WORKFLOW_SUCCESS",payload:o};case 18:(0,$.dispatch)("core/notices").createSuccessNotice((0,L.__)("Workflow published.","post-expirator"),{type:"snackbar",isDismissible:!0}),e.next=26;break;case 21:return e.prev=21,e.t0=e.catch(2),(0,$.dispatch)("core/notices").createErrorNotice((0,L.__)("Unable to publish the workflow. Please, try again.","post-expirator")),e.next=26,{type:"PUBLISH_WORKFLOW_FAILURE"};case 26:case"end":return e.stop()}}),e,null,[[2,21]])}))()}function Fd(e){var t=e.screenshot;return Cd().mark((function e(){var n,r,o;return Cd().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,{type:"SWITCH_TO_DRAFT_START"};case 2:return e.prev=2,e.next=5,(0,$.select)(pt).isNewWorkflow();case 5:return n=e.sent,e.next=8,(0,$.dispatch)(pt).setEditedWorkflowAttribute("status","draft");case 8:return e.next=10,(0,$.select)(pt).getEditedWorkflow();case 10:return r=e.sent,t&&(r.screenshot=t),e.next=14,xd({path:"".concat(Dd,"/workflows/").concat(parseInt(r.id)),method:"PUT",headers:{"X-WP-Nonce":Td},body:JSON.stringify(r)});case 14:return o=e.sent,n&&window.history.pushState({},"","?page=future_workflow_editor&workflow=".concat(parseInt(o.id))),e.next=18,{type:"SWITCH_TO_DRAFT_SUCCESS",payload:o};case 18:(0,$.dispatch)("core/notices").createSuccessNotice((0,L.__)("Workflow switched to draft.","post-expirator"),{type:"snackbar",isDismissible:!0}),e.next=26;break;case 21:return e.prev=21,e.t0=e.catch(2),(0,$.dispatch)("core/notices").createErrorNotice((0,L.__)("Unable to switch workflow to draft. Please, try again.","post-expirator")),e.next=26,{type:"SWITCH_TO_DRAFT_FAILURE"};case 26:case"end":return e.stop()}}),e,null,[[2,21]])}))()}var zd=function(e){return{type:"SET_FLOW",payload:e}},Wd=function(e){return{type:"SET_POST_TYPE",payload:e}},Gd=function(e){return{type:"SET_NODES",payload:e}},Bd=function(e){return{type:"SET_EDGES",payload:e}},Vd=function(e){return{type:"SET_INITIAL_VIEWPORT",payload:e}},Hd=function(e){return{type:"SET_SELECTED_NODES",payload:e}},Ud=function(){return{type:"UNSELECT_ALL"}},qd=function(e){return{type:"SET_SELECTED_EDGES",payload:e}},Xd=function(e,t){if(!Id.includes(e))throw new Error('The workflow attribute "'.concat(e,'" is not editable.'));return{type:"SET_EDITED_WORKFLOW_ATTRIBUTE",payload:{key:e,value:t}}};function Yd(){var e,t;return Cd().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,{type:"DELETE_WORKFLOW_START"};case 2:return n.next=4,(0,$.select)(pt).getEditedWorkflow();case 4:return e=n.sent,n.prev=5,n.next=8,xd({path:"".concat(Dd,"/workflows/").concat(parseInt(e.id)),method:"DELETE",headers:{"X-WP-Nonce":Td}});case 8:return t=n.sent,n.next=11,{type:"DELETE_WORKFLOW_SUCCESS",payload:t};case 11:(0,$.dispatch)("core/notices").createSuccessNotice((0,L.__)("Workflow deleted. Redirecting...","post-expirator"),{type:"snackbar",isDismissible:!0}),window.location.href="edit.php?post_type=ppfuture_workflow",n.next=20;break;case 15:return n.prev=15,n.t0=n.catch(5),(0,$.dispatch)("core/notices").createErrorNotice((0,L.__)("Unable to delete the workflow. Please, try again.","post-expirator")),n.next=20,{type:"DELETE_WORKFLOW_FAILURE"};case 20:case"end":return n.stop()}}),Od,null,[[5,15]])}function Kd(e){return{type:"UPDATE_NODE",payload:e}}function Qd(e){return{type:"SET_DATA_TYPES",payload:e}}function Zd(e){return{type:"ADD_DATA_TYPE",payload:e}}function Jd(e){return{type:"SET_GLOBAL_VARIABLE",payload:e}}function ef(e){var t;return Cd().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,{type:"FETCH_TAXONOMY_TERMS_START"};case 2:return n.prev=2,n.next=5,xd({path:"".concat(Dd,"/terms/").concat(e),headers:{"X-WP-Nonce":Td}});case 5:return t=n.sent,n.next=8,{type:"FETCH_TAXONOMY_TERMS_SUCCESS",payload:{taxonomy:e,result:t}};case 8:n.next=14;break;case 10:return n.prev=10,n.t0=n.catch(2),n.next=14,{type:"FETCH_TAXONOMY_TERMS_FAILURE"};case 14:case"end":return n.stop()}}),Ad,null,[[2,10]])}function tf(e){return{type:"INCREMENT_BASE_SLUG_COUNTS",payload:e}}function nf(e){return{type:"UPDATE_BASE_SLUG_COUNTS",payload:e}}function rf(e,t,n){return{type:"ADD_NODE_ERROR",payload:{nodeId:e,error:t,message:n}}}function of(e,t){return{type:"REMOVE_NODE_ERROR",payload:{nodeId:e,error:t}}}function af(e){return{type:"RESET_NODE_ERRORS",payload:e}}function lf(e){return{type:"REMOVE_NODE",payload:e}}function sf(e){return{type:"REMOVE_EDGE",payload:e}}function cf(e){return{type:"ADD_NODE",payload:e}}function uf(){return{type:"REMOVE_PLACEHOLDER_NODES"}}function df(e){return{type:"SET_DRAGGING_FROM_HANDLE",payload:{sourceId:e.sourceId,handleId:e.handleId,handleType:e.handleType}}}function ff(e){return{type:"SET_IS_CONNECTING_NODES",payload:e}}function pf(e){return pf="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},pf(e)}function hf(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 mf(e,t,n){return(t=function(e){var t=function(e){if("object"!=pf(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=pf(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==pf(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var gf=function(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:Oc,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"CREATE_WORKFLOW_START":return function(e){return Cc(Cc({},e),{},{isCreatingWorkflow:!0,isLoadingWorkflow:!0})}(e);case"CREATE_WORKFLOW_SUCCESS":return function(e,t){var n=t.payload,r=[Ec()];return Cc(Cc({},e=Pc(e)),{},{nodes:r,isCreatingWorkflow:!1,isLoadingWorkflow:!1,workflow:n,editedWorkflowAttributes:{},isNewWorkflow:"auto-draft"===n.status,isEditedWorkflowEmpty:0===e.edges.length&&0===e.nodes.length,isCurrentWorkflowPublished:"publish"===n.status})}(e,t);case"CREATE_WORKFLOW_FAILURE":return function(e){return Cc(Cc({},e),{},{isCreatingWorkflow:!1,isLoadingWorkflow:!1})}(e);case"LOAD_WORKFLOW_START":return function(e){return Cc(Cc({},e),{},{isLoadingWorkflow:!0})}(e);case"LOAD_WORKFLOW_SUCCESS":return function(e,t){var n,r,o,a=t.payload,i=(null===(n=a.flow)||void 0===n?void 0:n.nodes)||[],l=(null===(r=a.flow)||void 0===r?void 0:r.edges)||[],s=(null===(o=a.flow)||void 0===o?void 0:o.viewport)||Oc.viewport;return i.map((function(t){var n,r=null==t||null===(n=t.data)||void 0===n?void 0:n.slug;r&&(e=jc(e,{payload:r}))})),i.length||(i=[Ec()]),l=function(e,t){return t.filter((function(t){var n=e.find((function(e){return e.id===t.source})),r=e.find((function(e){return e.id===t.target}));return!(!n||!r)}))}(i,l=Ac(l)),e=Pc(e),Dc(),Cc(Cc({},e),{},{isLoadingWorkflow:!1,workflow:a,editedWorkflowAttributes:{},isNewWorkflow:"auto-draft"===a.status,nodes:i,edges:l,initialViewport:s,isEditedWorkflowEmpty:0===e.edges.length&&0===e.nodes.length,isCurrentWorkflowPublished:"publish"===a.status})}(e,t);case"LOAD_WORKFLOW_FAILURE":return function(e){return Cc(Cc({},e),{},{isLoadingWorkflow:!1})}(e);case"SAVE_AS_DRAFT_START":case"SWITCH_TO_DRAFT_START":case"SAVE_AS_CURRENT_STATUS_START":case"PUBLISH_WORKFLOW_START":return function(e){return Cc(Cc({},e),{},{isSavingWorkflow:!0})}(e);case"SAVE_AS_DRAFT_SUCCESS":return function(e,t){var n=t.payload;return Cc(Cc({},e),{},{isSavingWorkflow:!1,workflow:n,editedWorkflowAttributes:{},isNewWorkflow:"auto-draft"===n.status,isEditedWorkflowEmpty:0===e.edges.length&&0===e.nodes.length,isCurrentWorkflowPublished:"publish"===n.status})}(e,t);case"SAVE_AS_DRAFT_FAILURE":case"SWITCH_TO_DRAFT_FAILURE":case"SAVE_AS_CURRENT_STATUS_FAILURE":case"PUBLISH_WORKFLOW_FAILURE":return function(e){return Cc(Cc({},e),{},{isSavingWorkflow:!1})}(e);case"SWITCH_TO_DRAFT_SUCCESS":return function(e,t){var n=t.payload,r=Cc(Cc({},e.workflow),{},{status:n.status});return Cc(Cc({},e),{},{isSavingWorkflow:!1,workflow:r,isNewWorkflow:!1,isEditedWorkflowEmpty:0===e.edges.length&&0===e.nodes.length,isCurrentWorkflowPublished:"publish"===r.status})}(e,t);case"SAVE_AS_CURRENT_STATUS_SUCCESS":return function(e,t){var n=t.payload,r=Cc(Cc({},e.workflow),{},{status:n.status});return Cc(Cc({},e),{},{isSavingWorkflow:!1,workflow:r,isNewWorkflow:!1,isEditedWorkflowEmpty:0===e.edges.length&&0===e.nodes.length,isCurrentWorkflowPublished:"publish"===r.status})}(e,t);case"PUBLISH_WORKFLOW_SUCCESS":return function(e,t){var n=t.payload,r=Cc(Cc({},e.workflow),{},{status:n.status});return Cc(Cc({},e),{},{isSavingWorkflow:!1,workflow:r,isNewWorkflow:!1,isEditedWorkflowEmpty:0===e.edges.length&&0===e.nodes.length,isCurrentWorkflowPublished:"publish"===r.status})}(e,t);case"SET_EDITED_WORKFLOW_ATTRIBUTE":return function(e,t){var n=t.payload,r=n.key,o=n.value;return Cc(Cc({},e),{},{editedWorkflowAttributes:Cc(Cc({},e.editedWorkflowAttributes),{},Nc({},r,o)),isEditedWorkflowEmpty:0===e.edges.length&&0===e.nodes.length})}(e,t);case"SET_POST_TYPE":return function(e,t){var n=t.payload;return Cc(Cc({},e),{},{postType:n})}(e,t);case"SET_NODES":return function(e,t){var n=t.payload;return Cc(Cc({},e),{},{nodes:n})}(e,t);case"ADD_NODE":return function(e,t){var n=t.payload,r=[].concat(xc(e.nodes),[n]);return Cc(Cc({},e),{},{nodes:r})}(e,t);case"SET_EDGES":return function(e,t){var n=t.payload,r=Ac(n);return Cc(Cc({},e),{},{edges:r})}(e,t);case"ADD_EDGE":return addEdge(e,t);case"SET_INITIAL_VIEWPORT":return function(e,t){var n=t.payload;return Cc(Cc({},e),{},{viewport:n})}(e,t);case"SET_SELECTED_NODES":return function(e,t){var n=t.payload;return Cc(Cc({},e),{},{selectedNodes:n})}(e,t);case"SET_SELECTED_EDGES":return function(e,t){var n=t.payload;return Cc(Cc({},e),{},{selectedEdges:n})}(e,t);case"UNSELECT_ALL":return Dc(e);case"DELETE_WORKFLOW_START":return function(e){return Cc(Cc({},e),{},{isDeletingWorkflow:!0})}(e);case"DELETE_WORKFLOW_SUCCESS":case"DELETE_WORKFLOW_FAILURE":return function(e){return Cc(Cc({},e),{},{isDeletingWorkflow:!1})}(e);case"UPDATE_NODE":return function(e,t){var n=t.payload,r=e.nodes.map((function(e){return e.id===n.id?Cc({},n):e}));return Cc(Cc({},e),{},{nodes:r})}(e,t);case"SET_DATA_TYPES":return function(e,t){var n=t.payload;return Cc(Cc({},e),{},{dataTypes:n})}(e,t);case"ADD_DATA_TYPE":return function(e,t){var n=t.payload.payload;return Cc(Cc({},e),{},{dataTypes:[].concat(xc(e.dataTypes),[n])})}(e,t);case"SET_GLOBAL_VARIABLE":return Tc(e,t);case"FETCH_TAXONOMY_TERMS_START":return function(e){return Cc(Cc({},e),{},{isFetchingTaxonomyTerms:!0})}(e);case"FETCH_TAXONOMY_TERMS_SUCCESS":return function(e,t){var n,r=t.payload,o=r.taxonomy,a=r.result,i=(null==a||null===(n=a.terms)||void 0===n?void 0:n.map((function(e){return{value:e.id,label:e.name}})))||[],l=Cc(Cc({},e.taxonomyTerms),{},Nc({},o,i));return Cc(Cc({},e),{},{isFetchingTaxonomyTerms:!1,taxonomyTerms:l})}(e,t);case"FETCH_TAXONOMY_TERMS_FAILURE":return function(e){return Cc(Cc({},e),{},{isFetchingTaxonomyTerms:!1})}(e);case"INCREMENT_BASE_SLUG_COUNTS":return function(e,t){var n=t.payload,r=Cc(Cc({},e.baseSlugCounts),{},Nc({},n,(e.baseSlugCounts[n]||0)+1));return Cc(Cc({},e),{},{baseSlugCounts:r})}(e,t);case"UPDATE_BASE_SLUG_COUNTS":return jc(e,t);case"ADD_NODE_ERROR":return function(e,t){var n=t.payload,r=e.nodeErrors[n.nodeId]||{};r[n.error]={error:n.error,message:n.message};var o=Cc(Cc({},e.nodeErrors),{},Nc({},n.nodeId,r));return Cc(Cc({},e),{},{nodeErrors:o})}(e,t);case"REMOVE_NODE_ERROR":return function(e,t){var n=t.payload,r=Cc({},e.nodeErrors);return r[n.nodeId]?(delete r[n.nodeId][n.error],Cc(Cc({},e),{},{nodeErrors:r})):e}(e,t);case"RESET_NODE_ERRORS":return function(e,t){var n=t.payload,r=Cc({},e.nodeErrors);return delete r[n],Cc(Cc({},e),{},{nodeErrors:r})}(e,t);case"REMOVE_NODE":return function(e,t){var n=t.payload,r=e.edges.filter((function(e){return e.source!==n&&e.target!==n})),o=e.nodes.filter((function(e){return e.id!==n}));return Cc(Cc({},e),{},{nodes:o,edges:r,selectedNodes:[],selectedEdges:[]})}(e,t);case"REMOVE_EDGE":return function(e,t){var n=t.payload,r=e.edges.filter((function(e){return e.id!==n}));return Cc(Cc({},e),{},{edges:r,selectedNodes:[],selectedEdges:[]})}(e,t);case"REMOVE_PLACEHOLDER_NODES":return function(e){var t=e.nodes.filter((function(e){return e.data.elementaryType!==A}));return Cc(Cc({},e),{},{nodes:t})}(e);case"SET_DRAGGING_FROM_HANDLE":return function(e,t){var n=t.payload,r=n.sourceId,o=n.handleId,a=n.handleType;return Cc(Cc({},e),{},{draggingFromHandle:{sourceId:r,handleId:o,handleType:a}})}(e,t);case"SET_IS_CONNECTING_NODES":return function(e,t){return Cc(Cc({},e),{},{isConnectingNodes:t.payload})}(e,t)}return e},actions:s,selectors:l,controls:bf});(0,$.register)(yf);const vf=({id:e,x:t,y:n,width:r,height:o,style:a,color:i,strokeColor:l,strokeWidth:s,className:c,borderRadius:u,shapeRendering:d,onClick:f,selected:p})=>{const{background:h,backgroundColor:m}=a||{},g=i||h||m;return ht.createElement("rect",{className:mt(["react-flow__minimap-node",{selected:p},c]),x:t,y:n,rx:u,ry:u,width:r,height:o,fill:g,stroke:l,strokeWidth:s,shapeRendering:d,onClick:f?t=>f(t,e):void 0})};vf.displayName="MiniMapNode";var wf=(0,ht.memo)(vf);const _f=e=>e.nodeOrigin,Ef=e=>e.getNodes().filter((e=>!e.hidden&&e.width&&e.height)),Sf=e=>e instanceof Function?e:()=>e;var xf=(0,ht.memo)((function({nodeStrokeColor:e="transparent",nodeColor:t="#e2e2e2",nodeClassName:n="",nodeBorderRadius:r=5,nodeStrokeWidth:o=2,nodeComponent:a=wf,onClick:i}){const l=ha(Ef,St),s=ha(_f),c=Sf(t),u=Sf(e),d=Sf(n),f="undefined"==typeof window||window.chrome?"crispEdges":"geometricPrecision";return ht.createElement(ht.Fragment,null,l.map((e=>{const{x:t,y:n}=gi(e,s).positionAbsolute;return ht.createElement(a,{key:e.id,x:t,y:n,width:e.width,height:e.height,style:e.style,selected:e.selected,className:d(e),color:c(e),borderRadius:r,strokeColor:u(e),strokeWidth:o,shapeRendering:f,onClick:i,id:e.id})})))}));const kf=e=>{const t=e.getNodes(),n={x:-e.transform[0]/e.transform[2],y:-e.transform[1]/e.transform[2],width:e.width/e.transform[2],height:e.height/e.transform[2]};return{viewBB:n,boundingRect:t.length>0?(r=bi(t,e.nodeOrigin),o=n,Na(Ra(Ca(r),Ca(o)))):n,rfId:e.rfId};var r,o};function Rf({style:e,className:t,nodeStrokeColor:n="transparent",nodeColor:r="#e2e2e2",nodeClassName:o="",nodeBorderRadius:a=5,nodeStrokeWidth:i=2,nodeComponent:l,maskColor:s="rgb(240, 240, 240, 0.6)",maskStrokeColor:c="none",maskStrokeWidth:u=1,position:d="bottom-right",onClick:f,onNodeClick:p,pannable:h=!1,zoomable:m=!1,ariaLabel:g="React Flow mini map",inversePan:b=!1,zoomStep:y=10,offsetScale:v=5}){const w=ma(),_=(0,ht.useRef)(null),{boundingRect:E,viewBB:S,rfId:x}=ha(kf,St),k=e?.width??200,R=e?.height??150,C=E.width/k,N=E.height/R,O=Math.max(C,N),A=O*k,P=O*R,D=v*O,T=E.x-(A-E.width)/2-D,I=E.y-(P-E.height)/2-D,j=A+2*D,M=P+2*D,$=`react-flow__minimap-desc-${x}`,L=(0,ht.useRef)(0);L.current=O,(0,ht.useEffect)((()=>{if(_.current){const e=Bn(_.current),t=e=>{const{transform:t,d3Selection:n,d3Zoom:r}=w.getState();if("wheel"!==e.sourceEvent.type||!n||!r)return;const o=-e.sourceEvent.deltaY*(1===e.sourceEvent.deltaMode?.05:e.sourceEvent.deltaMode?1:.002)*y,a=t[2]*Math.pow(2,o);r.scaleTo(n,a)},n=e=>{const{transform:t,d3Selection:n,d3Zoom:r,translateExtent:o,width:a,height:i}=w.getState();if("mousemove"!==e.sourceEvent.type||!n||!r)return;const l=L.current*Math.max(1,t[2])*(b?-1:1),s={x:t[0]-e.sourceEvent.movementX*l,y:t[1]-e.sourceEvent.movementY*l},c=[[0,0],[a,i]],u=Xo.translate(s.x,s.y).scale(t[2]),d=r.constrain()(u,c,o);r.transform(n,d)},r=ra().on("zoom",h?n:null).on("zoom.wheel",m?t:null);return e.call(r),()=>{e.on("zoom",null)}}}),[h,m,b,y]);const F=f?e=>{const t=Zn(e);f(e,{x:t[0],y:t[1]})}:void 0,z=p?(e,t)=>{const n=w.getState().nodeInternals.get(t);p(e,n)}:void 0;return ht.createElement(ba,{position:d,style:e,className:mt(["react-flow__minimap",t]),"data-testid":"rf__minimap"},ht.createElement("svg",{width:k,height:R,viewBox:`${T} ${I} ${j} ${M}`,role:"img","aria-labelledby":$,ref:_,onClick:F},g&&ht.createElement("title",{id:$},g),ht.createElement(xf,{onClick:z,nodeColor:r,nodeStrokeColor:n,nodeBorderRadius:a,nodeClassName:o,nodeStrokeWidth:i,nodeComponent:l}),ht.createElement("path",{className:"react-flow__minimap-mask",d:`M${T-D},${I-D}h${j+2*D}v${M+2*D}h${-j-2*D}z\n M${S.x},${S.y}h${S.width}v${S.height}h${-S.width}z`,fill:s,fillRule:"evenodd",stroke:c,strokeWidth:u,pointerEvents:"none"})))}Rf.displayName="MiniMap";var Cf=(0,ht.memo)(Rf);function Nf(){return ht.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32"},ht.createElement("path",{d:"M32 18.133H18.133V32h-4.266V18.133H0v-4.266h13.867V0h4.266v13.867H32z"}))}function Of(){return ht.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 5"},ht.createElement("path",{d:"M0 0h32v4.2H0z"}))}function Af(){return ht.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 30"},ht.createElement("path",{d:"M3.692 4.63c0-.53.4-.938.939-.938h5.215V0H4.708C2.13 0 0 2.054 0 4.63v5.216h3.692V4.631zM27.354 0h-5.2v3.692h5.17c.53 0 .984.4.984.939v5.215H32V4.631A4.624 4.624 0 0027.354 0zm.954 24.83c0 .532-.4.94-.939.94h-5.215v3.768h5.215c2.577 0 4.631-2.13 4.631-4.707v-5.139h-3.692v5.139zm-23.677.94c-.531 0-.939-.4-.939-.94v-5.138H0v5.139c0 2.577 2.13 4.707 4.708 4.707h5.138V25.77H4.631z"}))}function Pf(){return ht.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 32"},ht.createElement("path",{d:"M21.333 10.667H19.81V7.619C19.81 3.429 16.38 0 12.19 0 8 0 4.571 3.429 4.571 7.619v3.048H3.048A3.056 3.056 0 000 13.714v15.238A3.056 3.056 0 003.048 32h18.285a3.056 3.056 0 003.048-3.048V13.714a3.056 3.056 0 00-3.048-3.047zM12.19 24.533a3.056 3.056 0 01-3.047-3.047 3.056 3.056 0 013.047-3.048 3.056 3.056 0 013.048 3.048 3.056 3.056 0 01-3.048 3.047zm4.724-13.866H7.467V7.619c0-2.59 2.133-4.724 4.723-4.724 2.591 0 4.724 2.133 4.724 4.724v3.048z"}))}function Df(){return ht.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 32"},ht.createElement("path",{d:"M21.333 10.667H19.81V7.619C19.81 3.429 16.38 0 12.19 0c-4.114 1.828-1.37 2.133.305 2.438 1.676.305 4.42 2.59 4.42 5.181v3.048H3.047A3.056 3.056 0 000 13.714v15.238A3.056 3.056 0 003.048 32h18.285a3.056 3.056 0 003.048-3.048V13.714a3.056 3.056 0 00-3.048-3.047zM12.19 24.533a3.056 3.056 0 01-3.047-3.047 3.056 3.056 0 013.047-3.048 3.056 3.056 0 013.048 3.048 3.056 3.056 0 01-3.048 3.047z"}))}const Tf=({children:e,className:t,...n})=>ht.createElement("button",{type:"button",className:mt(["react-flow__controls-button",t]),...n},e);Tf.displayName="ControlButton";const If=e=>({isInteractive:e.nodesDraggable||e.nodesConnectable||e.elementsSelectable,minZoomReached:e.transform[2]<=e.minZoom,maxZoomReached:e.transform[2]>=e.maxZoom}),jf=({style:e,showZoom:t=!0,showFitView:n=!0,showInteractive:r=!0,fitViewOptions:o,onZoomIn:a,onZoomOut:i,onFitView:l,onInteractiveChange:s,className:c,children:u,position:d="bottom-left"})=>{const f=ma(),[p,h]=(0,ht.useState)(!1),{isInteractive:m,minZoomReached:g,maxZoomReached:b}=ha(If,St),{zoomIn:y,zoomOut:v,fitView:w}=bl();return(0,ht.useEffect)((()=>{h(!0)}),[]),p?ht.createElement(ba,{className:mt(["react-flow__controls",c]),position:d,style:e,"data-testid":"rf__controls"},t&&ht.createElement(ht.Fragment,null,ht.createElement(Tf,{onClick:()=>{y(),a?.()},className:"react-flow__controls-zoomin",title:"zoom in","aria-label":"zoom in",disabled:b},ht.createElement(Nf,null)),ht.createElement(Tf,{onClick:()=>{v(),i?.()},className:"react-flow__controls-zoomout",title:"zoom out","aria-label":"zoom out",disabled:g},ht.createElement(Of,null))),n&&ht.createElement(Tf,{className:"react-flow__controls-fitview",onClick:()=>{w(o),l?.()},title:"fit view","aria-label":"fit view"},ht.createElement(Af,null)),r&&ht.createElement(Tf,{className:"react-flow__controls-interactive",onClick:()=>{f.setState({nodesDraggable:!m,nodesConnectable:!m,elementsSelectable:!m}),s?.(!m)},title:"toggle interactivity","aria-label":"toggle interactivity"},m?ht.createElement(Df,null):ht.createElement(Pf,null)),u):null};jf.displayName="Controls";var Mf,$f=(0,ht.memo)(jf);function Lf({color:e,dimensions:t,lineWidth:n}){return ht.createElement("path",{stroke:e,strokeWidth:n,d:`M${t[0]/2} 0 V${t[1]} M0 ${t[1]/2} H${t[0]}`})}function Ff({color:e,radius:t}){return ht.createElement("circle",{cx:t,cy:t,r:t,fill:e})}!function(e){e.Lines="lines",e.Dots="dots",e.Cross="cross"}(Mf||(Mf={}));const zf={[Mf.Dots]:"#91919a",[Mf.Lines]:"#eee",[Mf.Cross]:"#e2e2e2"},Wf={[Mf.Dots]:1,[Mf.Lines]:1,[Mf.Cross]:6},Gf=e=>({transform:e.transform,patternId:`pattern-${e.rfId}`});function Bf({id:e,variant:t=Mf.Dots,gap:n=20,size:r,lineWidth:o=1,offset:a=2,color:i,style:l,className:s}){const c=(0,ht.useRef)(null),{transform:u,patternId:d}=ha(Gf,St),f=i||zf[t],p=r||Wf[t],h=t===Mf.Dots,m=t===Mf.Cross,g=Array.isArray(n)?n:[n,n],b=[g[0]*u[2]||1,g[1]*u[2]||1],y=p*u[2],v=m?[y,y]:b,w=h?[y/a,y/a]:[v[0]/a,v[1]/a];return ht.createElement("svg",{className:mt(["react-flow__background",s]),style:{...l,position:"absolute",width:"100%",height:"100%",top:0,left:0},ref:c,"data-testid":"rf__background"},ht.createElement("pattern",{id:d+e,x:u[0]%b[0],y:u[1]%b[1],width:b[0],height:b[1],patternUnits:"userSpaceOnUse",patternTransform:`translate(-${w[0]},-${w[1]})`},h?ht.createElement(Ff,{color:f,radius:y/a}):ht.createElement(Lf,{dimensions:v,color:f,lineWidth:o})),ht.createElement("rect",{x:"0",y:"0",width:"100%",height:"100%",fill:`url(#${d+e})`}))}Bf.displayName="Background";var Vf=(0,ht.memo)(Bf);const Hf=e=>(0,T.createElement)("path",e),Uf=(0,T.forwardRef)((({className:e,isPressed:t,...n},r)=>{const o={...n,className:j(e,{"is-pressed":t})||void 0,"aria-hidden":!0,focusable:!1};return(0,T.createElement)("svg",{...o,ref:r})}));Uf.displayName="SVG";const qf=(0,ht.createElement)(Uf,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,ht.createElement)(Hf,{d:"M19 8h-1V6h-5v2h-2V6H6v2H5c-1.1 0-2 .9-2 2v8c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-8c0-1.1-.9-2-2-2zm.5 10c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5v-8c0-.3.2-.5.5-.5h14c.3 0 .5.2.5.5v8z"}));function Xf(e){var t=e.children,n=e.size;return React.createElement("span",{className:"publishpress-icon",style:{width:"".concat(n,"px"),height:"".concat(n,"px"),display:"inline-block"}},t)}function Yf(e){var t=e.size,n=void 0===t?24:t;return React.createElement(Xf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",role:"img",viewBox:"0 0 24 24",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M2.227 4.857A2.228 2.228 0 000 7.094v7.457c0 1.236 1.001 2.237 2.237 2.237h9.253l4.229 2.355-.962-2.355h7.006c1.236 0 2.237-1 2.237-2.237V7.094c0-1.236-1-2.237-2.237-2.237zm8.08 1.311c.194.002.372.071.535.2a.769.769 0 01.304.56.851.851 0 01-.098.47c-.382.707-.696 1.894-.951 3.542-.246 1.6-.334 2.846-.275 3.739.02.245-.02.46-.118.647a.632.632 0 01-.52.353c-.255.02-.52-.098-.775-.362-.913-.933-1.639-2.326-2.169-4.18a184.085 184.085 0 00-1.413 2.825c-.578 1.11-1.069 1.678-1.481 1.708-.265.02-.49-.206-.687-.677-.5-1.286-1.04-3.768-1.619-7.448-.03-.255.02-.48.157-.657.137-.186.344-.284.618-.304.5-.04.785.196.854.706.304 2.051.638 3.788.991 5.21L5.809 8.41c.196-.373.441-.57.736-.589.431-.03.696.245.804.824.246 1.305.56 2.414.932 3.356.255-2.492.687-4.288 1.295-5.397.148-.274.363-.412.648-.431a.866.866 0 01.084-.004zm3.734 1.063c.167 0 .343.02.53.06.687.146 1.216.52 1.57 1.137.314.53.47 1.168.47 1.933 0 1.011-.254 1.933-.765 2.777-.588.981-1.354 1.472-2.305 1.472-.167 0-.344-.02-.53-.059-.697-.147-1.217-.52-1.57-1.138-.314-.54-.471-1.187-.471-1.943 0-1.01.255-1.933.765-2.767.599-.981 1.364-1.472 2.306-1.472zm6.152 0c.167 0 .343.02.53.06.696.146 1.216.52 1.57 1.137.314.53.47 1.168.47 1.933 0 1.011-.254 1.933-.765 2.777-.588.981-1.354 1.472-2.305 1.472-.167 0-.344-.02-.53-.059-.697-.147-1.217-.52-1.57-1.138-.314-.54-.471-1.187-.471-1.943 0-1.01.255-1.933.765-2.767.599-.981 1.364-1.472 2.306-1.472zm-6.107 1.645c-.307-.002-.606.201-.889.622a3.173 3.173 0 00-.52 1.168c-.05.225-.069.47-.069.716 0 .284.06.589.177.893.147.382.343.589.579.638.245.049.51-.06.795-.315.363-.323.608-.804.745-1.452.05-.225.069-.47.069-.726a2.49 2.49 0 00-.176-.893c-.148-.382-.344-.588-.58-.637a.714.714 0 00-.131-.014zm6.152 0c-.307-.002-.606.201-.889.622a3.173 3.173 0 00-.52 1.168c-.049.225-.069.47-.069.716 0 .284.06.589.177.893.147.382.344.589.579.638.245.049.51-.06.795-.315.363-.323.608-.804.745-1.452.04-.225.07-.47.07-.726a2.49 2.49 0 00-.177-.893c-.148-.382-.344-.588-.58-.637a.714.714 0 00-.131-.014Z"})))}function Kf(e){var t=e.size,n=void 0===t?24:t;return React.createElement(Xf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 448 512",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M224 256c70.7 0 128-57.3 128-128S294.7 0 224 0 96 57.3 96 128s57.3 128 128 128zm89.6 32h-16.7c-22.2 10.2-46.9 16-72.9 16s-50.6-5.8-72.9-16h-16.7C60.2 288 0 348.2 0 422.4V464c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48v-41.6c0-74.2-60.2-134.4-134.4-134.4z"})))}function Qf(e){var t=e.size,n=void 0===t?24:t;return React.createElement(Xf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 512 512",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M256 0c53 0 96 43 96 96v3.6c0 15.7-12.7 28.4-28.4 28.4H188.4c-15.7 0-28.4-12.7-28.4-28.4V96c0-53 43-96 96-96zM41.4 105.4c12.5-12.5 32.8-12.5 45.3 0l64 64c.7 .7 1.3 1.4 1.9 2.1c14.2-7.3 30.4-11.4 47.5-11.4H312c17.1 0 33.2 4.1 47.5 11.4c.6-.7 1.2-1.4 1.9-2.1l64-64c12.5-12.5 32.8-12.5 45.3 0s12.5 32.8 0 45.3l-64 64c-.7 .7-1.4 1.3-2.1 1.9c6.2 12 10.1 25.3 11.1 39.5H480c17.7 0 32 14.3 32 32s-14.3 32-32 32H416c0 24.6-5.5 47.8-15.4 68.6c2.2 1.3 4.2 2.9 6 4.8l64 64c12.5 12.5 12.5 32.8 0 45.3s-32.8 12.5-45.3 0l-63.1-63.1c-24.5 21.8-55.8 36.2-90.3 39.6V240c0-8.8-7.2-16-16-16s-16 7.2-16 16V479.2c-34.5-3.4-65.8-17.8-90.3-39.6L86.6 502.6c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3l64-64c1.9-1.9 3.9-3.4 6-4.8C101.5 367.8 96 344.6 96 320H32c-17.7 0-32-14.3-32-32s14.3-32 32-32H96.3c1.1-14.1 5-27.5 11.1-39.5c-.7-.6-1.4-1.2-2.1-1.9l-64-64c-12.5-12.5-12.5-32.8 0-45.3z"})))}function Zf(e){var t=e.size,n=void 0===t?24:t;return React.createElement(Xf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",version:"1.1",viewBox:"0 0 16 16",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M8 0c-4.418 0-8 1.119-8 2.5v2c0 1.381 3.582 2.5 8 2.5s8-1.119 8-2.5v-2c0-1.381-3.582-2.5-8-2.5z"}),React.createElement("path",{d:"M8 8.5c-4.418 0-8-1.119-8-2.5v3c0 1.381 3.582 2.5 8 2.5s8-1.119 8-2.5v-3c0 1.381-3.582 2.5-8 2.5z"}),React.createElement("path",{d:"M8 13c-4.418 0-8-1.119-8-2.5v3c0 1.381 3.582 2.5 8 2.5s8-1.119 8-2.5v-3c0 1.381-3.582 2.5-8 2.5z"})))}function Jf(e){var t=e.size,n=void 0===t?24:t;return React.createElement(Xf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"none",strokeWidth:"2",viewBox:"0 0 24 24",strokeLinecap:"round",strokeLinejoin:"round",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M16 3h5v5"}),React.createElement("path",{d:"M8 3h-5v5"}),React.createElement("path",{d:"M21 3l-7.536 7.536a5 5 0 0 0 -1.464 3.534v6.93"}),React.createElement("path",{d:"M6 6.01v-.01"}),React.createElement("path",{d:"M8 8.02v-.01"}),React.createElement("path",{d:"M10 10v.01"})))}function ep(e){var t=e.size,n=void 0===t?24:t;return React.createElement(Xf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 512 512",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M437.332 80H74.668C51.199 80 32 99.198 32 122.667v266.666C32 412.802 51.199 432 74.668 432h362.664C460.801 432 480 412.802 480 389.333V122.667C480 99.198 460.801 80 437.332 80zM432 170.667L256 288 80 170.667V128l176 117.333L432 128v42.667z"})))}function tp(e){var t=e.size,n=void 0===t?24:t;return React.createElement(Xf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 24 24",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M20 2H4c-1.103 0-2 .894-2 1.992v12.016C2 17.106 2.897 18 4 18h3v4l6.351-4H20c1.103 0 2-.894 2-1.992V3.992A1.998 1.998 0 0 0 20 2zm-6 11H7v-2h7v2zm3-4H7V7h10v2z"})))}function np(e){var t=e.size,n=void 0===t?24:t;return React.createElement(Xf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 512 512",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M32 464h448L256 48 32 464zm248-64h-48v-48h48v48zm0-80h-48v-96h48v96z"})))}function rp(e){var t=e.size,n=void 0===t?24:t;return React.createElement(Xf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 24 24",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{fill:"none",d:"M0 0h24v24H0z"}),React.createElement("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),React.createElement("path",{d:"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"})))}function op(e){var t=e.size,n=void 0===t?24:t;return React.createElement(Xf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 20 20","aria-hidden":"true",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{fillRule:"evenodd",d:"M4.5 2A1.5 1.5 0 0 0 3 3.5v13A1.5 1.5 0 0 0 4.5 18h11a1.5 1.5 0 0 0 1.5-1.5V7.621a1.5 1.5 0 0 0-.44-1.06l-4.12-4.122A1.5 1.5 0 0 0 11.378 2H4.5Zm2.25 8.5a.75.75 0 0 0 0 1.5h6.5a.75.75 0 0 0 0-1.5h-6.5Zm0 3a.75.75 0 0 0 0 1.5h6.5a.75.75 0 0 0 0-1.5h-6.5Z",clipRule:"evenodd"})))}function ap(e){var t=e.size,n=void 0===t?24:t;return React.createElement(Xf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"none",strokeWidth:"0",viewBox:"0 0 24 24",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M14 7C13.4477 7 13 7.44772 13 8V16C13 16.5523 13.4477 17 14 17H18C18.5523 17 19 16.5523 19 16V8C19 7.44772 18.5523 7 18 7H14ZM17 9H15V15H17V9Z",fill:"currentColor"}),React.createElement("path",{d:"M6 7C5.44772 7 5 7.44772 5 8C5 8.55228 5.44772 9 6 9H10C10.5523 9 11 8.55228 11 8C11 7.44772 10.5523 7 10 7H6Z",fill:"currentColor"}),React.createElement("path",{d:"M6 11C5.44772 11 5 11.4477 5 12C5 12.5523 5.44772 13 6 13H10C10.5523 13 11 12.5523 11 12C11 11.4477 10.5523 11 10 11H6Z",fill:"currentColor"}),React.createElement("path",{d:"M5 16C5 15.4477 5.44772 15 6 15H10C10.5523 15 11 15.4477 11 16C11 16.5523 10.5523 17 10 17H6C5.44772 17 5 16.5523 5 16Z",fill:"currentColor"}),React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M4 3C2.34315 3 1 4.34315 1 6V18C1 19.6569 2.34315 21 4 21H20C21.6569 21 23 19.6569 23 18V6C23 4.34315 21.6569 3 20 3H4ZM20 5H4C3.44772 5 3 5.44772 3 6V18C3 18.5523 3.44772 19 4 19H20C20.5523 19 21 18.5523 21 18V6C21 5.44772 20.5523 5 20 5Z",fill:"currentColor"})))}function ip(e){var t=e.size,n=void 0===t?24:t;return React.createElement(Xf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 192 512",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M176 432c0 44.112-35.888 80-80 80s-80-35.888-80-80 35.888-80 80-80 80 35.888 80 80zM25.26 25.199l13.6 272C39.499 309.972 50.041 320 62.83 320h66.34c12.789 0 23.331-10.028 23.97-22.801l13.6-272C167.425 11.49 156.496 0 142.77 0H49.23C35.504 0 24.575 11.49 25.26 25.199z"})))}function lp(e){var t=e.size,n=void 0===t?24:t;return React.createElement(Xf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 448 512",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M400 224h-24v-72C376 68.2 307.8 0 224 0S72 68.2 72 152v72H48c-26.5 0-48 21.5-48 48v192c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V272c0-26.5-21.5-48-48-48zm-104 0H152v-72c0-39.7 32.3-72 72-72s72 32.3 72 72v72z"})))}function sp(e){var t=e.size,n=void 0===t?24:t;return React.createElement(Xf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 576 512",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M528.12 301.319l47.273-208C578.806 78.301 567.391 64 551.99 64H159.208l-9.166-44.81C147.758 8.021 137.93 0 126.529 0H24C10.745 0 0 10.745 0 24v16c0 13.255 10.745 24 24 24h69.883l70.248 343.435C147.325 417.1 136 435.222 136 456c0 30.928 25.072 56 56 56s56-25.072 56-56c0-15.674-6.447-29.835-16.824-40h209.647C430.447 426.165 424 440.326 424 456c0 30.928 25.072 56 56 56s56-25.072 56-56c0-22.172-12.888-41.332-31.579-50.405l5.517-24.276c3.413-15.018-8.002-29.319-23.403-29.319H218.117l-6.545-32h293.145c11.206 0 20.92-7.754 23.403-18.681z"})))}function cp(e){return cp="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},cp(e)}function up(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 dp(e){for(var t=1;t0,isAdvancedSettingsEnabled:!0,isSingularElementSelected:1===r,getNodeTypeByName:e(ec).getNodeTypeByName,isPro:e(ec).isPro()}})),l=(i.nodeErrors,i.nodeHasErrors),s=i.isAdvancedSettingsEnabled,c=i.isSingularElementSelected,u=i.getNodeTypeByName,d=i.isPro,f=(0,$.useDispatch)(yf).removeNode,p=(0,$.useDispatch)(ec).openGeneralSidebar,h=u(n.name),m=h.label||n.label||(0,L.__)("Node","publishpress-future-pro"),g=(null==h?void 0:h.className)||"react-flow__node-genericNode",b=null;h.handleSchema&&h.handleSchema.target&&(b=h.handleSchema.target.map((function(e){return React.createElement(Ti,{key:e.id+"_target",type:"target",position:Xa.Top,id:e.id,style:{left:e.left},isConnectable:r,className:"handle-target-"+e.id})})));var y=null,v=null;h.handleSchema&&h.handleSchema.source&&(y=h.handleSchema.source.map((function(e){return React.createElement(Ti,{key:e.id+"_source",type:"source",position:Xa.Bottom,id:e.id,style:{left:e.left},isConnectable:r,className:"handle-source-"+e.id})})),v=h.handleSchema.source.map((function(e){return React.createElement("div",{key:e.id+"handleArea",className:"react-flow__node-handle-name handle-area-source-"+e.id},e.label)})));var w=(0,L.__)("Step","publishpress-future-pro");"action"===n.elementaryType?w=(0,L.__)("Action","publishpress-future-pro"):"advanced"===n.elementaryType?w=(0,L.__)("Advanced","publishpress-future-pro"):"trigger"===n.elementaryType&&(w=(0,L.__)("Trigger","publishpress-future-pro"));var _=[];return a||(a=React.createElement(hp,{size:8})),React.createElement(React.Fragment,null,o&&c&&React.createElement(React.Fragment,null,React.createElement(M.Popover,{placement:"top-start",offset:14},React.createElement(M.Toolbar,{className:"components-accessible-toolbar block-editor-block-contextual-toolbar react-flow__node-toolbar"},React.createElement(M.ToolbarGroup,null,React.createElement(M.ToolbarButton,{icon:"trash",label:(0,L.__)("Delete","publishpress-future-pro"),onClick:function(){f(t)}}))))),React.createElement("div",{className:"react-flow__node-body "+g,onDoubleClick:function(){c&&p(gp)}},b,React.createElement("div",{className:"react-flow__node-top"},a,w),React.createElement("div",{className:"react-flow__node-inner-body"},(l||h.isProFeature&&!d)&&React.createElement("div",{className:"react-flow__node-marker-wrapper"},h.isProFeature&&!d&&React.createElement("div",{className:"react-flow__node-pro-badge",title:(0,L.__)("Currently this step is being skipped. Upgrade to Pro to unlock this feature.","post-expirator")},React.createElement(pp,{icon:"lock",size:8})),l&&React.createElement("div",{className:"react-flow__node-error",title:(0,L.__)("This node has errors","post-expirator")},React.createElement(pp,{icon:"exclamation",size:8}))),React.createElement("div",{className:"react-flow__node-header"},React.createElement(pp,{icon:h.icon.src,size:14}),React.createElement("div",{className:"react-flow__node-label"},m)),s&&_.length>0&&React.createElement("div",{className:"react-flow__node-content"},React.createElement("table",null,React.createElement("tbody",null,_.map((function(e){return React.createElement("tr",{key:"attribute_"+e.id},React.createElement("th",null,e.label),React.createElement("td",null,e.value))})))))),React.createElement("div",{className:"react-flow__node-handle-area"},v),y))}));const yp=bp;var vp=i(3018);function _p(e){var t=e.size,n=void 0===t?24:t;return React.createElement(Xf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 24 24",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("polygon",{fill:"none",strokeWidth:"2",points:"4 14 10 14 7 23 9 23 20 9 14 9 18 1 7 1"})))}function Ep(){return Ep=Object.assign?Object.assign.bind():function(e){for(var t=1;t0})(e)||i(e.id,"no-incomers",(0,L.__)("This step requires a connection from a previous step.","post-expirator"));break;case"hasOutgoingConnection":(function(e){var t=function(e){var t=(0,$.select)(yf).getNodes(),n=(0,$.select)(yf).getEdges();return e?((e,t,n)=>{if(!ui(e))return[];const r=n.filter((t=>t.source===e.id)).map((e=>e.target));return t.filter((e=>r.includes(e.id)))})(e,t,n):[]}(e);return(null==t?void 0:t.length)>0})(e)||i(e.id,"no-outgoers",(0,L.__)("This step requires a connection to a following step.","post-expirator"));break;case"hasIncomerOfName":var n=mc(e),r=!1;if(0===n.length)r=!0;else{var o=!1;n.forEach((function(e){var n;(null===(n=e.data)||void 0===n?void 0:n.name)===t.name&&(o=!0)})),r=!o}r&&i(e.id,"parent-name",t.message)}})),null!=d&&null!==(a=d.settings)&&void 0!==a&&a.rules&&d.settings.rules.forEach((function(t){for(var n,r=t.rule,o=(null==t?void 0:t.field)||"",a=(null==o?void 0:o.split("."))||[],l=(null==t?void 0:t.label)||(null===(n=u.find((function(e){return null==e?void 0:e.fields.find((function(e){return e.name===a[0]}))})))||void 0===n?void 0:n.label),s=c,d=0;de.length)&&(t=e.length);for(var n=0,r=Array(t);n{setTimeout((()=>e(Date.now())),0)}:window.requestIdleCallback;function Hp(e=null){if(!e){if("undefined"==typeof window)return!1;e=window}const{platform:t}=e.navigator;return-1!==t.indexOf("Mac")||["iPad","iPhone"].includes(t)}const Up="alt",qp="ctrl",Xp="meta",Yp="shift";function Kp(e){return e.length<2?e.toUpperCase():e.charAt(0).toUpperCase()+e.slice(1)}function Qp(e,t){return Object.fromEntries(Object.entries(e).map((([e,n])=>[e,t(n)])))}const Zp={primary:e=>e()?[Xp]:[qp],primaryShift:e=>e()?[Yp,Xp]:[qp,Yp],primaryAlt:e=>e()?[Up,Xp]:[qp,Up],secondary:e=>e()?[Yp,Up,Xp]:[qp,Yp,Up],access:e=>e()?[qp,Up]:[Yp,Up],ctrl:()=>[qp],alt:()=>[Up],ctrlShift:()=>[qp,Yp],shift:()=>[Yp],shiftAlt:()=>[Yp,Up],undefined:()=>[]},Jp=Qp(Zp,(e=>(t,n=Hp)=>[...e(n),t.toLowerCase()].join("+"))),eh=Qp(Zp,(e=>(t,n=Hp)=>{const r=n(),o={[Up]:r?"⌥":"Alt",[qp]:r?"⌃":"Ctrl",[Xp]:"⌘",[Yp]:r?"⇧":"Shift"};return[...e(n).reduce(((e,t)=>{var n;const a=null!==(n=o[t])&&void 0!==n?n:t;return r?[...e,a]:[...e,a,"+"]}),[]),Kp(t)]})),th=Qp(eh,(e=>(t,n=Hp)=>e(t,n).join(""))),nh=Qp(Zp,(e=>(t,n=Hp)=>{const r=n(),o={[Yp]:"Shift",[Xp]:r?"Command":"Control",[qp]:"Control",[Up]:r?"Option":"Alt",",":(0,L.__)("Comma"),".":(0,L.__)("Period"),"`":(0,L.__)("Backtick"),"~":(0,L.__)("Tilde")};return[...e(n),t].map((e=>{var t;return Kp(null!==(t=o[e])&&void 0!==t?t:e)})).join(r?" ":" + ")})),rh=Qp(Zp,(e=>(t,n,r=Hp)=>{const o=e(r),a=function(e){return[Up,qp,Xp,Yp].filter((t=>e[`${t}Key`]))}(t),i={Comma:",",Backslash:"\\",IntlRo:"\\",IntlYen:"\\"},l=o.filter((e=>!a.includes(e))),s=a.filter((e=>!o.includes(e)));if(l.length>0||s.length>0)return!1;let c=t.key.toLowerCase();return n?(t.altKey&&1===n.length&&(c=String.fromCharCode(t.keyCode).toLowerCase()),t.shiftKey&&1===n.length&&i[t.code]&&(c=i[t.code]),"del"===n&&(n="delete"),c===n.toLowerCase()):o.includes(c)}));function oh(e="polite"){const t=document.createElement("div");t.id=`a11y-speak-${e}`,t.className="a11y-speak-region",t.setAttribute("style","position: absolute;margin: -1px;padding: 0;height: 1px;width: 1px;overflow: hidden;clip: rect(1px, 1px, 1px, 1px);-webkit-clip-path: inset(50%);clip-path: inset(50%);border: 0;word-wrap: normal !important;"),t.setAttribute("aria-live",e),t.setAttribute("aria-relevant","additions text"),t.setAttribute("aria-atomic","true");const{body:n}=document;return n&&n.appendChild(t),t}let ah="";var ih;function lh(e,t){!function(){const e=document.getElementsByClassName("a11y-speak-region"),t=document.getElementById("a11y-speak-intro-text");for(let t=0;t]+>/g," "),ah===e&&(e+=" "),ah=e,e}(e);const n=document.getElementById("a11y-speak-intro-text"),r=document.getElementById("a11y-speak-assertive"),o=document.getElementById("a11y-speak-polite");r&&"assertive"===t?r.textContent=e:o&&(o.textContent=e),n&&n.removeAttribute("hidden")}function sh(){return sh=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=Array(t);n{let t=function(e,t){const n=[];for(let r=0;r{const e=new Map;let t=!1;const n=r=>{for(const[t,n]of e)if(e.delete(t),n(),"number"==typeof r||r.timeRemaining()<=0)break;0!==e.size?Vp(n):t=!1};return{add:(r,o)=>{e.set(r,o),t||(t=!0,Vp(n))},flush:t=>{const n=e.get(t);return void 0!==n&&(e.delete(t),n(),!0)},cancel:t=>e.delete(t),reset:()=>{e.clear(),t=!1}}})();for(let r=t.length;r{(0,T.flushSync)((()=>{o((t=>[...t,...e.slice(r,r+n)]))}))}));return()=>a.reset()}),[e]),r}(n);return React.createElement(wh,null,React.createElement("div",null,a&&i.length>0&&React.createElement(Ch,{title:(0,L._x)("Most used","nodes","post-expirator")},React.createElement(Rh,{items:i,onSelect:s,onHover:o,label:(0,L._x)("Most used","nodes","post-expirator")})),$p()(c,(function(e){var t=l[e.name];return t&&t.length?React.createElement(Ch,{key:e.name,title:e.label,icon:e.icon},React.createElement(Rh,{items:t,onSelect:s,onHover:o,label:e.label})):null}))))},Oh=i(2193),Ah=i.n(Oh);const Ph=(e,t,n)=>{let r,o,a,i,l,s=0,c=0,u=!1,d=!1,f=!0;function p(t){const n=r,i=o;return r=void 0,o=void 0,c=t,a=e.apply(i,n),a}function h(e,t){i=setTimeout(e,t)}function m(e){return e-(l||0)}function g(e){const n=m(e);return void 0===l||n>=t||n<0||d&&e-c>=s}function b(){const e=Date.now();if(g(e))return v(e);h(b,function(e){const n=m(e),r=e-c,o=t-n;return d?Math.min(o,s-r):o}(e))}function y(){i=void 0}function v(e){return y(),f&&r?p(e):(r=o=void 0,a)}function w(){return void 0!==i}function _(...e){const n=Date.now(),i=g(n);if(r=e,o=this,l=n,i){if(!w())return function(e){return c=e,h(b,t),u?p(e):a}(l);if(d)return h(b,t),p(l)}return w()||h(b,t),a}return n&&(u=!!n.leading,d="maxWait"in n,void 0!==n.maxWait&&(s=Math.max(n.maxWait,t)),f="trailing"in n?!!n.trailing:f),_.cancel=function(){void 0!==i&&clearTimeout(i),c=0,y(),r=l=o=void 0},_.flush=function(){return w()?v(Date.now()):a},_.pending=w,_};var Dh=i(828),Th=i.n(Dh),Ih=i(4889),jh=i.n(Ih),Mh=i(7309),$h=i.n(Mh),Lh=i(6645),Fh=i.n(Lh);function zh(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,l=[],s=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return l}}(e,t)||Wh(e,t)||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.")}()}function Wh(e,t){if(e){if("string"==typeof e)return Gh(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)?Gh(e,t):void 0}}function Gh(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n0&&void 0!==arguments[0]?arguments[0]:"";return(e=(e=Th()(e)).replace(/^\//,"")).toLowerCase()}var Yh=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return Fh()(Xh(e))};function Kh(e,t){var n,r,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},a=o.getName,i=void 0===a?Bh:a,l=o.getTitle,s=void 0===l?Vh:l,c=o.getDescription,u=void 0===c?Hh:c,d=o.getKeywords,f=void 0===d?Uh:d,p=o.getCategory,h=void 0===p?qh:p,m=i(e),g=s(e),b=u(e),y=f(e),v=h(e),w=Xh(t),_=Xh(g),E=0;if(w===_)E+=30;else if(_.startsWith(w))E+=20;else{var S=[m,g,b].concat(function(e){return function(e){if(Array.isArray(e))return Gh(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Wh(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.")}()}(y),[v]).join(" ");0===(n=Fh()(w),r=S,jh()(n,Yh(r),(function(e,t){return t.includes(e)}))).length&&(E+=10)}return 0!==E&&m.startsWith("core/")&&E++,E}const Qh=(0,T.forwardRef)((function({icon:e,size:t=24,...n},r){return(0,T.cloneElement)(e,{width:t,height:t,...n,ref:r})}));function Zh(){return React.createElement("div",{className:"block-editor-inserter__no-results"},React.createElement(Qh,{className:"block-editor-inserter__no-results-icon",icon:qf}),React.createElement("p",null,(0,L.__)("No results found.","post-expirator")))}function Jh(e){return function(e){if(Array.isArray(e))return em(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return em(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)?em(e,t):void 0}}(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 em(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);nPh(e,500,n)),[e,500,n]);return(0,T.useEffect)((()=>()=>r.cancel()),[r]),r}(lh),c=(0,$.useSelect)((function(e){var t=e(ec).getActionNodes(),n=e(ec).getActionCategories(),r=e(ec).getTriggerNodes(),o=e(ec).getTriggerCategories(),a=e(ec).getAdvancedNodes(),i=e(ec).getAdvancedCategories();return{nodeTypes:l&&l.length?[].concat(Jh(t.filter((function(e){return l.includes(e.elementaryType)}))),Jh(r.filter((function(e){return l.includes(e.elementaryType)}))),Jh(a.filter((function(e){return l.includes(e.elementaryType)})))):[].concat(Jh(r),Jh(t),Jh(a)),nodeTypeCategories:[].concat(Jh(n),Jh(o),Jh(i))}})),u=c.nodeTypes,d=c.nodeTypeCategories,f=(0,T.useMemo)((function(){var e,n,r,a=(e=Bp()(u,["frecency"],["desc"]),n=d,0===Yh(r=t).length?e:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(0===Yh(t).length)return e;var r=e.map((function(e){return[e,Kh(e,t,n)]})).filter((function(e){return zh(e,2)[1]>0}));return r.sort((function(e,t){var n=zh(e,2)[1];return zh(t,2)[1]-n})),r.map((function(e){return zh(e,1)[0]}))}(e,r,{getCategory:function(e){var t;return null===(t=$h()(n,{name:e.category}))||void 0===t?void 0:t.label},getName:function(e){return e.name},getTitle:function(e){return e.label},getDescription:function(e){return e.description},getKeywords:function(e){return e.keywords||[]}}));return void 0!==o?a.slice(0,o):a}),[t,u,d,o]);(0,T.useEffect)((function(){if(t){var e=f.length,n=(0,L.sprintf)((0,L._n)("%d result found.","%d results found.",e,"post-expirator"),e);s(n)}}),[t,s,f]);var p=!Ah()(f);return React.createElement(wh,null,!p&&React.createElement(Zh,null),!!p&&React.createElement(Ch,{title:React.createElement(M.VisuallyHidden,null,(0,L.__)("Nodes","post-expirator"))},React.createElement(Rh,{items:f,onSelect:n,onHover:r,label:(0,L.__)("Nodes","post-expirator"),isDraggable:i})))};function nm(e){var t=e.size,n=void 0===t?24:t;return React.createElement(Xf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"none",strokeWidth:"2",viewBox:"0 0 24 24",strokeLinecap:"round",strokeLinejoin:"round",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("line",{x1:"12",y1:"5",x2:"12",y2:"19"}),React.createElement("line",{x1:"5",y1:"12",x2:"19",y2:"12"})))}function rm(e){return function(e){if(Array.isArray(e))return im(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||am(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 om(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,l=[],s=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return l}}(e,t)||am(e,t)||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.")}()}function am(e,t){if(e){if("string"==typeof e)return im(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)?im(e,t):void 0}}function im(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n{r.setState({onViewportChangeStart:e})}),[e]),(0,ht.useEffect)((()=>{r.setState({onViewportChange:t})}),[t]),(0,ht.useEffect)((()=>{r.setState({onViewportChangeEnd:n})}),[n])}({onEnd:function(){z()}}),(0,T.useEffect)((function(){c&&I(c)}),[c]);var W=(0,T.useCallback)((function(e){m(Al(e,n)),z()}),[n]),G=(0,T.useCallback)((function(e){g(Pl(e,r)),z()}),[r]),B=(0,T.useCallback)((function(e,t){g(((e,t,n,r={shouldReplaceId:!0})=>(console.warn("[DEPRECATED] `updateEdge` is deprecated. Instead use `reconnectEdge` https://reactflow.dev/api-reference/utils/reconnect-edge"),((e,t,n,r={shouldReplaceId:!0})=>{const{id:o,...a}=e;if(!t.source||!t.target)return n;if(!n.find((e=>e.id===o)))return n;const i={...a,id:r.shouldReplaceId?di(t):o,source:t.source,target:t.target,sourceHandle:t.sourceHandle,targetHandle:t.targetHandle};return n.filter((e=>e.id!==o)).concat(i)})(e,t,n,r)))(e,t,r)),z()}),[r]),V=(0,T.useCallback)((function(e){e.source!==e.target&&(e=gm(gm({},e),{},{type:"genericEdge",id:"".concat(e.source,"-").concat(e.sourceHandle,"-").concat(e.target,"-").concat(e.targetHandle),markerEnd:{type:qa.ArrowClosed}}),g(pi(e,r)),z())}),[r]),H=(0,T.useCallback)((function(e,t){var n=t.nodeId,r=t.handleId,o=t.handleType;j.current=n,x({sourceId:n,handleId:r,handleType:o})}),[]),U=(0,T.useCallback)((function(e){if(e.stopPropagation(),j.current){if(e.target.classList.contains("react-flow__pane")&&!p){var t=e.target.offsetWidth,n=D.screenToFlowPosition({x:t/2,y:0}),r=D.screenToFlowPosition({x:e.clientX-n.x,y:e.clientY}),o={id:wc(),type:"nodePlaceholder",data:{name:"core/node-placeholder",elementaryType:A},position:r};b(o)}C(!1)}}),[D.screenToFlowPosition,p,b]),q=(0,T.useCallback)((function(e){return C(!0),!0}),[]),X=(0,T.useCallback)((function(e){e.preventDefault(),e.dataTransfer.dropEffect="move"}),[]),Y=(0,T.useCallback)((function(e){e.preventDefault();var t=D.screenToFlowPosition({x:e.clientX,y:e.clientY}),n=e.dataTransfer.getData(R);_c({item:JSON.parse(n),position:t,reactFlowInstance:D}),S()}),[D,n]),K=(0,T.useCallback)((function(){z()})),Q=(0,T.useCallback)((function(){z()})),Z=(0,T.useCallback)((function(){D.fitView()}),[D]);!function({onChange:e}){const t=ma();(0,ht.useEffect)((()=>{const n=[...t.getState().onSelectionChange,e];return t.setState({onSelectionChange:n}),()=>{const n=t.getState().onSelectionChange.filter((t=>t!==e));t.setState({onSelectionChange:n})}}),[e])}({onChange:function(e){var t=e.nodes,n=e.edges;if(t.length>0&&"triggerPlaceholder"===t[0].type)return y([]),void v([]);y(t.map((function(e){return e.id}))),v(n.map((function(e){return e.id}))),l&&(0===t.length&&0===n.length&&N(mp),(t.length>0||n.length>0)&&N(gp))}});var J=(0,T.useCallback)((function(){O((0,L.__)("Applying auto layout.","post-expirator"),{isDismissible:!0,type:"snackbar"}),Promise.all([i.e(845),i.e(251)]).then(i.bind(i,7632)).then((function(e){(0,e.useLayoutedElements)({nodes:n,edges:r,onLayout:function(e,t){m(e),g(t)},onAnimationFrame:function(){Z(),z()}})({direction:vp.rx}),O((0,L.__)("Auto layout applied.","post-expirator"),{isDismissible:!0,type:"snackbar"})}))}),[n,r,Z,z]);return(0,T.useEffect)((function(){T.Platform.select({web:!0,native:!1})&&N(mp)}),[]),(0,T.useEffect)((function(){if("null/undefined"===s){var e=o.length>0||a.length>0?gp:mp;N(e)}}),[s,a,o]),React.createElement("div",{className:"reactflow-wrapper",ref:P},React.createElement(pm,{onLayout:J}),!f&&React.createElement(Gs,{nodes:n,edges:r,onNodesChange:W,onEdgesChange:G,onEdgeUpdate:B,onConnectStart:H,onConnectEnd:U,onConnect:V,isValidConnection:q,onDrop:Y,onDragOver:X,nodesDraggable:!0,proOptions:{hideAttribution:!1},fitView:Z,style:{backgroundColor:"#ffffff"},snapToGrid:!0,snapGrid:[10,10],nodeTypes:M,edgeTypes:F,onNodesDelete:K,onEdgesDelete:Q,connectionLineStyle:{stroke:"#c2c2c2",strokeWidth:2,strokeDasharray:"3,4"}},u&&React.createElement(Cf,{pannable:!0,zoomable:!0,nodeColor:function(e){if("generic"===e.type)return"#FFCC00"}}),d&&React.createElement($f,null),React.createElement(Vf,{variant:"dots",color:"#ccc",gap:10})),React.createElement(Op,null))},vm=i(7612),wm=i.n(vm);function _m(){var e=(0,$.useDispatch)("core/notices").removeNotice,t=(0,$.useSelect)((function(e){return e("core/notices").getNotices()}),[]),n=wm()(t,{isDismissible:!0,type:"default"}),r=wm()(t,{isDismissible:!1,type:"default"}),o=wm()(t,{type:"snackbar"});return React.createElement(React.Fragment,null,React.createElement(M.NoticeList,{notices:r,className:"workflow-editor-notices__notice-list"}),React.createElement(M.NoticeList,{notices:n,className:"workflow-editor-notices__notice-list",onRemove:e}),React.createElement(M.SnackbarList,{notices:o,className:"workflow-editor-notices__snackbar-list",onRemove:e}))}var Em=function(e){return React.createElement(React.Fragment,null,React.createElement(_m,null),React.createElement(ym,null))},Sm=function(e){return React.createElement("div",null,"PublishPress Future Workflow Editor")};const xm=new Map;const km={huge:1440,wide:1280,large:960,medium:782,small:600,mobile:480},Rm={">=":"min-width","<":"max-width"},Cm={">=":(e,t)=>t>=e,"<":(e,t)=>t=")=>{const n=(0,T.useContext)(Nm),r=function(e){const t=(0,T.useMemo)((()=>{const t=function(e){if(!e)return null;let t=xm.get(e);return t||("undefined"!=typeof window&&"function"==typeof window.matchMedia?(t=window.matchMedia(e),xm.set(e,t),t):null)}(e);return{subscribe:e=>t?(t.addEventListener?.("change",e),()=>{t.removeEventListener?.("change",e)}):()=>{},getValue(){var e;return null!==(e=t?.matches)&&void 0!==e&&e}}}),[e]);return(0,T.useSyncExternalStore)(t.subscribe,t.getValue,(()=>!1))}(!n&&`(${Rm[t]}: ${km[e]}px)`||void 0);return n?Cm[t](km[e],n):r};Om.__experimentalWidthProvider=Nm.Provider;const Am=Om,Pm=(0,ht.createElement)(Uf,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,ht.createElement)(Hf,{d:"M11 12.5V17.5H12.5V12.5H17.5V11H12.5V6H11V11H6V12.5H11Z"})),Dm=(0,ht.createElement)(Uf,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,ht.createElement)(Hf,{d:"M18 5.5H6a.5.5 0 00-.5.5v3h13V6a.5.5 0 00-.5-.5zm.5 5H10v8h8a.5.5 0 00.5-.5v-7.5zm-10 0h-3V18a.5.5 0 00.5.5h2.5v-8zM6 4h12a2 2 0 012 2v12a2 2 0 01-2 2H6a2 2 0 01-2-2V6a2 2 0 012-2z"})),Tm=(0,ht.createElement)(Uf,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24"},(0,ht.createElement)(Hf,{d:"M20 10c0-5.51-4.49-10-10-10C4.48 0 0 4.49 0 10c0 5.52 4.48 10 10 10 5.51 0 10-4.48 10-10zM7.78 15.37L4.37 6.22c.55-.02 1.17-.08 1.17-.08.5-.06.44-1.13-.06-1.11 0 0-1.45.11-2.37.11-.18 0-.37 0-.58-.01C4.12 2.69 6.87 1.11 10 1.11c2.33 0 4.45.87 6.05 2.34-.68-.11-1.65.39-1.65 1.58 0 .74.45 1.36.9 2.1.35.61.55 1.36.55 2.46 0 1.49-1.4 5-1.4 5l-3.03-8.37c.54-.02.82-.17.82-.17.5-.05.44-1.25-.06-1.22 0 0-1.44.12-2.38.12-.87 0-2.33-.12-2.33-.12-.5-.03-.56 1.2-.06 1.22l.92.08 1.26 3.41zM17.41 10c.24-.64.74-1.87.43-4.25.7 1.29 1.05 2.71 1.05 4.25 0 3.29-1.73 6.24-4.4 7.78.97-2.59 1.94-5.2 2.92-7.78zM6.1 18.09C3.12 16.65 1.11 13.53 1.11 10c0-1.3.23-2.48.72-3.59C3.25 10.3 4.67 14.2 6.1 18.09zm4.03-6.63l2.58 6.98c-.86.29-1.76.45-2.71.45-.79 0-1.57-.11-2.29-.33.81-2.38 1.62-4.74 2.42-7.1z"}));function Im(e){var t=e.showTooltip,n=(0,$.useSelect)((function(e){var t=e(yf).getPostType;return{isActive:(0,e(ec).isFeatureActive)("fullscreenMode"),postType:t()}}),[]),r=n.isActive,o=n.postType;if(!r||!o)return null;var a=React.createElement(M.Icon,{size:"36px",icon:Tm});return React.createElement(M.__unstableMotion.div,{whileHover:"expand",className:"editor-header__back-button"},React.createElement(M.Button,{className:"edit-post-fullscreen-mode-close",href:(0,ld.addQueryArgs)("edit.php",{post_type:p}),label:(0,L.__)("Back","post-expirator"),showTooltip:t},a))}const jm=(0,ht.createElement)(Uf,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,ht.createElement)(Hf,{d:"M13 19h-2v-2h2v2zm0-6h-2v-2h2v2zm0-6h-2V5h2v2z"}));function Mm(e){return Mm="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},Mm(e)}function $m(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 Lm(e){for(var t=1;t0||e.offsetHeight>0||e.getClientRects().length>0}function Qm(e,{sequential:t=!1}={}){const n=e.querySelectorAll(function(e){return[e?'[tabindex]:not([tabindex^="-"])':"[tabindex]","a[href]","button:not([disabled])",'input:not([type="hidden"]):not([disabled])',"select:not([disabled])","textarea:not([disabled])",'iframe:not([tabindex^="-"])',"object","embed","area[href]","[contenteditable]:not([contenteditable=false])"].join(",")}(t));return Array.from(n).filter((e=>{if(!Km(e))return!1;const{nodeName:t}=e;return"AREA"!==t||function(e){const t=e.closest("map[name]");if(!t)return!1;const n=e.ownerDocument.querySelector('img[usemap="#'+t.name+'"]');return!!n&&Km(n)}(e)}))}function Zm(e){const t=e.getAttribute("tabindex");return null===t?0:parseInt(t,10)}function Jm(e){return-1!==Zm(e)}function eg(e,t){return{element:e,index:t}}function tg(e){return e.element}function ng(e,t){const n=Zm(e.element),r=Zm(t.element);return n===r?e.index-t.index:n-r}function rg(e){return e.filter(Jm).map(eg).sort(ng).map(tg).reduce(function(){const e={};return function(t,n){const{nodeName:r,type:o,checked:a,name:i}=n;if("INPUT"!==r||"radio"!==o||!i)return t.concat(n);const l=e.hasOwnProperty(i);if(!a&&l)return t;if(l){const n=e[i];t=t.filter((e=>e!==n))}return e[i]=n,t.concat(n)}}(),[])}function og(e){return rg(Qm(e))}function ag(e){return rg(Qm(e.ownerDocument.body)).reverse().find((t=>e.compareDocumentPosition(t)&e.DOCUMENT_POSITION_PRECEDING))}function ig(e){return rg(Qm(e.ownerDocument.body)).find((t=>e.compareDocumentPosition(t)&e.DOCUMENT_POSITION_FOLLOWING))}const lg={focusable:c,tabbable:u};var sg=["children","focusOnMount","__experimentalInitialIndex","__experimentalOnIndexChange"];function cg(){return cg=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=Array(t);n{t.current=e}),[e]),t.current}(0,T.forwardRef)((function(e,t){var n=(0,$.useSelect)((function(e){return!1}),[]),r=(0,$.useDispatch)(yf).undo;return React.createElement(M.Button,gg({},e,{ref:t,icon:(0,L.isRTL)()?mg:hg,label:(0,L.__)("Undo","post-expirator"),shortcut:th.primary("z"),"aria-disabled":!n,onClick:n?r:void 0,className:"editor-history__undo"}))})),(0,T.forwardRef)((function(e,t){var n=(0,$.useSelect)((function(e){return!1}),[]),r=(0,$.useDispatch)(yf).redo;return React.createElement(M.Button,bg({},e,{ref:t,icon:(0,L.isRTL)()?hg:mg,label:(0,L.__)("Redo","post-expirator"),shortcut:th.primaryShift("z"),"aria-disabled":!n,onClick:n?r:void 0,className:"editor-history__redo"}))}));const vg=(0,ht.createElement)(Uf,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,ht.createElement)(Hf,{d:"M17.3 10.1c0-2.5-2.1-4.4-4.8-4.4-2.2 0-4.1 1.4-4.6 3.3h-.2C5.7 9 4 10.7 4 12.8c0 2.1 1.7 3.8 3.7 3.8h9c1.8 0 3.2-1.5 3.2-3.3.1-1.6-1.1-2.9-2.6-3.2zm-.5 5.1h-4v-2.4L14 14l1-1-3-3-3 3 1 1 1.2-1.2v2.4H7.7c-1.2 0-2.2-1.1-2.2-2.3s1-2.4 2.2-2.4H9l.3-1.1c.4-1.3 1.7-2.2 3.2-2.2 1.8 0 3.3 1.3 3.3 2.9v1.3l1.3.2c.8.1 1.4.9 1.4 1.8 0 1-.8 1.8-1.7 1.8z"})),wg=(0,ht.createElement)(Uf,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,ht.createElement)(Hf,{d:"M17.3 10.1c0-2.5-2.1-4.4-4.8-4.4-2.2 0-4.1 1.4-4.6 3.3h-.2C5.7 9 4 10.7 4 12.8c0 2.1 1.7 3.8 3.7 3.8h9c1.8 0 3.2-1.5 3.2-3.3.1-1.6-1.1-2.9-2.6-3.2zm-.5 5.1h-9c-1.2 0-2.2-1.1-2.2-2.3s1-2.4 2.2-2.4h1.3l.3-1.1c.4-1.3 1.7-2.2 3.2-2.2 1.8 0 3.3 1.3 3.3 2.9v1.3l1.3.2c.8.1 1.4.9 1.4 1.8-.1 1-.9 1.8-1.8 1.8z"}));function _g(e){return _g="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},_g(e)}function Eg(e,t,n){return(t=function(e){var t=function(e){if("object"!=_g(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=_g(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==_g(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Sg(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);ne.length)&&(t=e.length);for(var n=0,r=Array(t);n[Fg(e,t),...Gg(e,t)].filter(Boolean)),((e,t)=>[e[t]])),Vg=(0,$.createSelector)(((e,t)=>Bg(e,t).map((e=>Lg(e,"raw")))),((e,t)=>[e[t]])),Hg=(0,$.createSelector)(((e,t)=>Object.entries(e).filter((([,e])=>e.category===t)).map((([e])=>e))),(e=>[e])),Ug=(0,$.createReduxStore)("core/keyboard-shortcuts",{reducer:function(e={},t){switch(t.type){case"REGISTER_SHORTCUT":return{...e,[t.name]:{category:t.category,keyCombination:t.keyCombination,aliases:t.aliases,description:t.description}};case"UNREGISTER_SHORTCUT":const{[t.name]:n,...r}=e;return r}return e},actions:d,selectors:f});(0,$.register)(Ug);const qg=new Set,Xg=e=>{for(const t of qg)t(e)},Yg=(0,T.createContext)({add:e=>{0===qg.size&&document.addEventListener("keydown",Xg),qg.add(e)},delete:e=>{qg.delete(e),0===qg.size&&document.removeEventListener("keydown",Xg)}});function Kg(e,t,{isDisabled:n=!1}={}){const r=(0,T.useContext)(Yg),o=function(){const{getAllShortcutKeyCombinations:e}=(0,$.useSelect)(Ug);return function(t,n){return e(t).some((({modifier:e,character:t})=>rh[e](n,t)))}}(),a=(0,T.useRef)();(0,T.useEffect)((()=>{a.current=t}),[t]),(0,T.useEffect)((()=>{if(!n)return r.add(t),()=>{r.delete(t)};function t(t){o(e,t)&&a.current(t)}}),[e,n,r])}const{Provider:Qg}=Yg;var Zg="publishpress-future/workflow-editor/toggle-fullscreen",Jg="publishpress-future/workflow-editor/fit-view",eb="publishpress-future/workflow-editor/toggle-inserter",tb="publishpress-future/workflow-editor/auto-layout",nb="publishpress-future/workflow-editor/toggle-sidebar",rb="publishpress-future/workflow-editor/toggle-developer-mode",ob="publishpress-future/workflow-editor/toggle-advanced-settings",ab=function(){var e=(0,$.useDispatch)(Ug).registerShortcut,t=(0,$.useDispatch)(ec).toggleFeature;(0,T.useEffect)((function(){e({name:Zg,category:"global",description:"Toggle fullscreen mode",keyCombination:{modifier:"secondary",character:"f"}}),e({name:rb,category:"global",description:"Toggle developer mode",keyCombination:{modifier:"secondary",character:"d"}}),e({name:ob,category:"global",description:"Toggle advanced settings",keyCombination:{modifier:"secondary",character:"a"}}),e({name:Jg,category:"global",description:"Fit view",keyCombination:{modifier:"secondary",character:"v"}}),e({name:eb,category:"global",description:"Toggle inserter",keyCombination:{modifier:"secondary",character:"i"}}),e({name:tb,category:"global",description:"Auto layout",keyCombination:{modifier:"secondary",character:"l"}}),e({name:nb,category:"global",description:"Toggle sidebar",keyCombination:{modifier:"secondary",character:"s"}})}),[]),Kg(Zg,(function(){t(h)})),Kg(rb,(function(){t(b)}));var n=bl();return Kg(Jg,(function(){n.fitView()})),Kg(eb,(function(){t(g)})),Kg(tb,(function(){var e=new CustomEvent(vp.Ml,{detail:{direction:vp.wD}});document.dispatchEvent(e)})),Kg(nb,(function(){})),Kg(ob,(function(){t(v)})),null};const ib=(0,ht.createElement)(Uf,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,ht.createElement)(Hf,{d:"M13 11.8l6.1-6.3-1-1-6.1 6.2-6.1-6.2-1 1 6.1 6.3-6.5 6.7 1 1 6.5-6.6 6.5 6.6 1-1z"})),lb=function(){return function(){const e=(0,T.useRef)();return(0,T.useCallback)((t=>{t?e.current=(e=>{function t(t){const{key:n,shiftKey:r,target:o}=t;if("Tab"!==n)return;const a=r?"findPrevious":"findNext",i=lg.tabbable[a](o)||null;if(o.contains(i))return t.preventDefault(),void i?.focus();if(e.contains(i))return;const l=r?"append":"prepend",{ownerDocument:s}=e,c=s.createElement("div");c.tabIndex=-1,e[l](c),c.addEventListener("blur",(()=>e.removeChild(c))),c.focus()}return e.addEventListener("keydown",t),()=>{e.removeEventListener("keydown",t)}})(t):e.current&&e.current()}),[])}()};let sb=null;const cb=["button","submit"];function ub(e,t){"function"==typeof e?e(t):e&&e.hasOwnProperty("current")&&(e.current=t)}function db(e){const t=(0,T.useRef)(),n=(0,T.useRef)(!1),r=(0,T.useRef)(!1),o=(0,T.useRef)([]),a=(0,T.useRef)(e);return a.current=e,(0,T.useLayoutEffect)((()=>{!1===r.current&&!0===n.current&&e.forEach(((e,n)=>{const r=o.current[n];e!==r&&(ub(r,null),ub(e,t.current))})),o.current=e}),e),(0,T.useLayoutEffect)((()=>{r.current=!1})),(0,T.useCallback)((e=>{ub(t,e),r.current=!0,n.current=null!==e;const i=e?a.current:o.current;for(const t of i)ub(t,e)}),[])}const fb=function(e){const t=(0,T.useRef)(),{constrainTabbing:n=!1!==e.focusOnMount}=e;(0,T.useEffect)((()=>{t.current=e}),Object.values(e));const r=lb(),o=function(e="firstElement"){const t=(0,T.useRef)(e),n=e=>{e.focus({preventScroll:!0})},r=(0,T.useRef)();return(0,T.useEffect)((()=>{t.current=e}),[e]),(0,T.useEffect)((()=>()=>{r.current&&clearTimeout(r.current)}),[]),(0,T.useCallback)((e=>{var o;e&&!1!==t.current&&(e.contains(null!==(o=e.ownerDocument?.activeElement)&&void 0!==o?o:null)||("firstElement"!==t.current?n(e):r.current=setTimeout((()=>{const t=lg.tabbable.find(e)[0];t&&n(t)}),0)))}),[])}(e.focusOnMount),a=function(e){const t=(0,T.useRef)(null),n=(0,T.useRef)(null),r=(0,T.useRef)(e);return(0,T.useEffect)((()=>{r.current=e}),[e]),(0,T.useCallback)((e=>{if(e){if(t.current=e,n.current)return;n.current=e.ownerDocument.activeElement}else if(n.current){const e=t.current?.contains(t.current?.ownerDocument.activeElement);var o;if(t.current?.isConnected&&!e)return void(null!==(o=sb)&&void 0!==o||(sb=n.current));r.current?r.current():(n.current.isConnected?n.current:sb)?.focus(),sb=null}}),[])}(),i=function(e){const t=(0,T.useRef)(e);(0,T.useEffect)((()=>{t.current=e}),[e]);const n=(0,T.useRef)(!1),r=(0,T.useRef)(),o=(0,T.useCallback)((()=>{clearTimeout(r.current)}),[]);(0,T.useEffect)((()=>()=>o()),[]),(0,T.useEffect)((()=>{e||o()}),[e,o]);const a=(0,T.useCallback)((e=>{const{type:t,target:r}=e;["mouseup","touchend"].includes(t)?n.current=!1:function(e){if(!(e instanceof window.HTMLElement))return!1;switch(e.nodeName){case"A":case"BUTTON":return!0;case"INPUT":return cb.includes(e.type)}return!1}(r)&&(n.current=!0)}),[]),i=(0,T.useCallback)((e=>{if(e.persist(),n.current)return;const o=e.target.getAttribute("data-unstable-ignore-focus-outside-for-relatedtarget");o&&e.relatedTarget?.closest(o)||(r.current=setTimeout((()=>{document.hasFocus()?"function"==typeof t.current&&t.current(e):e.preventDefault()}),0))}),[]);return{onFocus:o,onMouseDown:a,onMouseUp:a,onTouchStart:a,onTouchEnd:a,onBlur:i}}((e=>{t.current?.__unstableOnClose?t.current.__unstableOnClose("focus-outside",e):t.current?.onClose&&t.current.onClose()})),l=(0,T.useCallback)((e=>{e&&e.addEventListener("keydown",(e=>{27===e.keyCode&&!e.defaultPrevented&&t.current?.onClose&&(e.preventDefault(),t.current.onClose())}))}),[]);return[db([n?r:null,!1!==e.focusOnMount?a:null,!1!==e.focusOnMount?o:null,l]),{...i,tabIndex:-1}]};var pb=i(3950),hb=i.n(pb);function mb(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);ncmd and clicking on each step in the workflow.","post-expirator"),{kbd:React.createElement("kbd",null)}),(0,L.__)("Drag steps from the inserter and drop them directly into your workflow for easy customization.","post-expirator"),(0,L.__)("Simply double-click any step to bring up the settings sidebar for quick adjustments.","post-expirator"),(0,L.__)("Double-click the workflow pane to increase the zoom level for a closer look.","post-expirator"),(0,T.createInterpolateElement)((0,L.__)("Hold down the shift key and double-click the workflow pane to decrease the zoom level.","post-expirator"),{kbd:React.createElement("kbd",null)}),(0,L.__)("Easily add new steps by clicking on a step's handle and dragging it. Drop it in the workflow pane to see a floating inserter where you can type and search for the step you need.","post-expirator")];function bb(){var e=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,l=[],s=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return mb(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)?mb(e,t):void 0}}(e,t)||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.")}()}((0,T.useState)(Math.floor(Math.random()*gb.length)),1)[0];return React.createElement(M.Tip,null,gb[e])}var yb=i(9181),vb=i.n(yb);const wb=new WeakMap;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)}var Eb=["tabId","onClick","children","selected"];function Sb(e,t,n){return(t=function(e){var t=function(e){if("object"!=_b(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=_b(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==_b(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function xb(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n{if(o)return o;const e=function(e){const t=wb.get(e)||0;return wb.set(e,t+1),t}(n);return r?`${r}-${e}`:e}),[n,o,r])),g=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,l=[],s=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return xb(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)?xb(e,t):void 0}}(e,t)||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.")}()}((0,T.useState)(null),2),b=g[0],y=g[1],v=function(e){y(e),h(e)},w=$h()(l,{name:b}),_="".concat(m,"-").concat(null!==(t=null==w?void 0:w.name)&&void 0!==t?t:"none");return(0,T.useEffect)((function(){$h()(l,{name:b})||y(s||(l.length>0?l[0].name:null))}),[l]),(0,T.useEffect)((function(){y(s||l[0].name)}),[s]),React.createElement("div",{className:a},React.createElement(M.NavigableMenu,{role:"tablist",orientation:u,onNavigate:function(e,t){t.click()},className:"components-tab-panel__tabs block-editor-inserter__tablist-and-close-button"},l.map((function(e){return React.createElement(Rb,{className:ft()("components-tab-panel__tabs-item",e.className,Sb({},f,e.name===b)),tabId:"".concat(m,"-").concat(e.name),"aria-controls":"".concat(m,"-").concat(e.name,"-view"),selected:e.name===b,key:e.name,onClick:vb()(v,e.name)},e.title)}))),w&&React.createElement("div",{key:_,"aria-labelledby":_,role:"tabpanel",id:"".concat(_,"-view"),className:"components-tab-panel__tab-content block-editor-inserter__tabpanel"},i(w)))}var Nb={name:E,title:(0,L.__)("Triggers","post-expirator")},Ob={name:S,title:(0,L.__)("Actions","post-expirator")},Ab={name:x,title:(0,L.__)("Advanced","post-expirator")};const Pb=function(e){var t=e.children,n=e.onSelect,r=e.initialTabName,o=void 0===r?E:r,a=(0,T.useMemo)((function(){return[Nb,Ob,Ab]}),[Nb,Ob,Ab]);return React.createElement(Cb,{className:"block-editor-inserter__tabs",tabs:a,onSelect:n,initialTabName:o},t)};function Db(e){var t=e.node,n=(0,$.useSelect)((function(e){return{isPro:e(ec).isPro()}})).isPro;return React.createElement("div",{className:"block-editor-block-card"},React.createElement(pp,{icon:t.icon,showColors:!0,className:"block-editor-block-icon"}),React.createElement("div",{className:"block-editor-block-card__content"},React.createElement("h2",{className:"block-editor-block-card__title"},t.label,t.isProFeature&&!n&&React.createElement("span",{className:"block-editor-block-card__pro-badge"},(0,L.__)("Pro","post-expirator"))),t.description&&React.createElement("span",{className:"block-editor-block-card__description"},t.description),t.isProFeature&&!n&&React.createElement("div",{className:"block-editor-block-card__pro-instructions"},(0,L.__)("Currently this step is being skipped. Upgrade to Pro to unlock this feature.","post-expirator")," ",(0,L.__)("Drag this node to preview its options in your workflow.","post-expirator"))))}const Tb=function(e){var t=e.item;return React.createElement("div",{className:"block-editor-inserter__preview-container"},React.createElement(Db,{node:t}))};function Ib(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);ne.length)&&(t=e.length);for(var n=0,r=Array(t);n0&&React.createElement(React.Fragment,null,React.createElement("table",null,React.createElement("tbody",null,d.map((function(e){return React.createElement("tr",{key:"attribute_"+e.id},React.createElement("th",null,e.label),React.createElement("td",null,e.value))})))))))},ny=function(e){var t,n,r,o=e.node,a=(0,(0,$.useSelect)((function(e){return{getNodeTypeByName:e(ec).getNodeTypeByName}})).getNodeTypeByName)(null==o||null===(t=o.data)||void 0===t?void 0:t.name),i=a.label||(null==o?void 0:o.data.label)||(0,L.__)("Node","post-expirator"),l=a.description||(null==o?void 0:o.data.description)||(0,L.__)("No description","post-expirator"),s=(null===(n=a.icon)||void 0===n?void 0:n.src)||"media-document",c=null==o?void 0:o.id,u=null==o||null===(r=o.data)||void 0===r?void 0:r.slug,d=React.createElement(pp,{icon:s});return React.createElement(ty,{title:i,description:l,id:c,icon:d,slug:u,isProFeature:a.isProFeature})},ry=function(e){var t=e.children;return React.createElement("span",{className:"workflow-editor-element-inspector__warning"},t)};function oy(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,l=[],s=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return ay(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)?ay(e,t):void 0}}(e,t)||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.")}()}function ay(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);ne.length)&&(t=e.length);for(var n=0,r=Array(t);ne.length)&&(t=e.length);for(var n=0,r=Array(t);ne.length)&&(t=e.length);for(var n=0,r=Array(t);n","","","","","","","")}})))))),!k&&React.createElement(Ey,{link:"https://publishpress.com/links/future-workflow-inspector"},React.createElement(_y,{label:(0,L.__)("Repeating Action","post-expirator"),disabled:!0})),React.createElement(M.Slot,{name:"DateOffsetAfterDateSourceField",fillProps:{onChangeSetting:p,defaultValue:r}}),u&&React.createElement(React.Fragment,null,!x&&React.createElement(M.PanelRow,null,React.createElement(M.TextControl,{label:(0,L.__)("Unique ID Expression","post-expirator"),value:null!==(t=r.uniqueIdExpression)&&void 0!==t?t:"",onChange:function(e){return p({settingName:"uniqueIdExpression",value:e})},help:(0,L.__)("Define a custom expression for a unique task ID. Use placeholders like {{onSavePost1.post.ID}} or {{global.user.ID}} to make sure the ID is unique.","post-expirator")})),React.createElement(M.TextControl,{label:(0,L.__)("Priority","post-expirator"),value:r.priority||10,onChange:function(e){return p({settingName:"priority",value:e})},help:(0,L.__)("Sets the execution priority of the scheduled step. Lower numbers indicate higher priority and are executed first.","post-expirator")}))))}function Py(e){return Py="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},Py(e)}function Dy(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 Ty(e,t,n){return(t=function(e){var t=function(e){if("object"!=Py(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Py(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Py(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const Iy=function(e){var t=e.name,n=(e.label,e.defaultValue),r=e.onChange,o=e.variables,a=void 0===o?[]:o,i=[{name:(0,L.__)("All received input","post-expirator"),id:"all-input"}];a.length>0&&a.forEach((function(e){i.push({name:e.name,id:e.id,children:e.children})}));return React.createElement(React.Fragment,null,React.createElement(M.__experimentalVStack,null,React.createElement(M.TreeSelect,{label:(0,L.__)("Data to output","post-expirator"),tree:i,selectedId:(null==n?void 0:n.dataToOutput)||"all-input",onChange:function(e){return function(e){var o=e.settingName,a=e.value,i=function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=Array(t);ne.length)&&(t=e.length);for(var n=0,r=Array(t);ne.length)&&(t=e.length);for(var n=0,r=Array(t);ne.length)&&(t=e.length);for(var n=0,r=Array(t);n{throw new Error("uSES not initialized!")},gv=(e,t)=>e===t;Symbol.for("react.element"),Symbol.for("react.portal"),Symbol.for("react.fragment"),Symbol.for("react.strict_mode"),Symbol.for("react.profiler"),Symbol.for("react.provider"),Symbol.for("react.context"),Symbol.for("react.server_context"),Symbol.for("react.forward_ref"),Symbol.for("react.suspense"),Symbol.for("react.suspense_list"),Symbol.for("react.memo"),Symbol.for("react.lazy"),Symbol.for("react.offscreen"),Symbol.for("react.client.reference");var bv={notify(){},get:()=>[]};var yv=!("undefined"==typeof window||void 0===window.document||void 0===window.document.createElement),vv="undefined"!=typeof navigator&&"ReactNative"===navigator.product,wv=yv||vv?sv.useLayoutEffect:sv.useEffect;Object.defineProperty,Object.getOwnPropertyNames,Object.getOwnPropertySymbols,Object.getOwnPropertyDescriptor,Object.getPrototypeOf,Object.prototype;var _v=function({store:e,context:t,children:n,serverState:r,stabilityCheck:o="once",identityFunctionCheck:a="once"}){const i=sv.useMemo((()=>{const t=function(e,t){let n,r=bv,o=0,a=!1;function i(){c.onStateChange&&c.onStateChange()}function l(){o++,n||(n=t?t.addNestedSub(i):e.subscribe(i),r=function(){let e=null,t=null;return{clear(){e=null,t=null},notify(){!function(e){e()}((()=>{let t=e;for(;t;)t.callback(),t=t.next}))},get(){const t=[];let n=e;for(;n;)t.push(n),n=n.next;return t},subscribe(n){let r=!0;const o=t={callback:n,next:null,prev:t};return o.prev?o.prev.next=o:e=o,function(){r&&null!==e&&(r=!1,o.next?o.next.prev=o.prev:t=o.prev,o.prev?o.prev.next=o.next:e=o.next)}}}}())}function s(){o--,n&&0===o&&(n(),n=void 0,r.clear(),r=bv)}const c={addNestedSub:function(e){l();const t=r.subscribe(e);let n=!1;return()=>{n||(n=!0,t(),s())}},notifyNestedSubs:function(){r.notify()},handleChangeWrapper:i,isSubscribed:function(){return a},trySubscribe:function(){a||(a=!0,l())},tryUnsubscribe:function(){a&&(a=!1,s())},getListeners:()=>r};return c}(e);return{store:e,subscription:t,getServerState:r?()=>r:void 0,stabilityCheck:o,identityFunctionCheck:a}}),[e,r,o,a]),l=sv.useMemo((()=>e.getState()),[e]);wv((()=>{const{subscription:t}=i;return t.onStateChange=t.notifyNestedSubs,t.trySubscribe(),l!==e.getState()&&t.notifyNestedSubs(),()=>{t.tryUnsubscribe(),t.onStateChange=void 0}}),[i,l]);const s=t||fv;return sv.createElement(s.Provider,{value:i},n)};function Ev(e=fv){const t=e===fv?hv:pv(e),n=()=>{const{store:e}=t();return e};return Object.assign(n,{withTypes:()=>n}),n}var Sv,xv=Ev();function kv(e){return`Minified Redux error #${e}; visit https://redux.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}Sv=lv.useSyncExternalStoreWithSelector,mv=Sv,ht.useSyncExternalStore;var Rv=(()=>"function"==typeof Symbol&&Symbol.observable||"@@observable")(),Cv=()=>Math.random().toString(36).substring(7).split("").join("."),Nv={INIT:`@@redux/INIT${Cv()}`,REPLACE:`@@redux/REPLACE${Cv()}`,PROBE_UNKNOWN_ACTION:()=>`@@redux/PROBE_UNKNOWN_ACTION${Cv()}`};function Ov(e){if("object"!=typeof e||null===e)return!1;let t=e;for(;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t||null===Object.getPrototypeOf(e)}function Av(e,t,n){if("function"!=typeof e)throw new Error(kv(2));if("function"==typeof t&&"function"==typeof n||"function"==typeof n&&"function"==typeof arguments[3])throw new Error(kv(0));if("function"==typeof t&&void 0===n&&(n=t,t=void 0),void 0!==n){if("function"!=typeof n)throw new Error(kv(1));return n(Av)(e,t)}let r=e,o=t,a=new Map,i=a,l=0,s=!1;function c(){i===a&&(i=new Map,a.forEach(((e,t)=>{i.set(t,e)})))}function u(){if(s)throw new Error(kv(3));return o}function d(e){if("function"!=typeof e)throw new Error(kv(4));if(s)throw new Error(kv(5));let t=!0;c();const n=l++;return i.set(n,e),function(){if(t){if(s)throw new Error(kv(6));t=!1,c(),i.delete(n),a=null}}}function f(e){if(!Ov(e))throw new Error(kv(7));if(void 0===e.type)throw new Error(kv(8));if("string"!=typeof e.type)throw new Error(kv(17));if(s)throw new Error(kv(9));try{s=!0,o=r(o,e)}finally{s=!1}return(a=i).forEach((e=>{e()})),e}return f({type:Nv.INIT}),{dispatch:f,subscribe:d,getState:u,replaceReducer:function(e){if("function"!=typeof e)throw new Error(kv(10));r=e,f({type:Nv.REPLACE})},[Rv]:function(){const e=d;return{subscribe(t){if("object"!=typeof t||null===t)throw new Error(kv(11));function n(){const e=t;e.next&&e.next(u())}return n(),{unsubscribe:e(n)}},[Rv](){return this}}}}}function Pv(...e){return 0===e.length?e=>e:1===e.length?e[0]:e.reduce(((e,t)=>(...n)=>e(t(...n))))}function Dv(e){return({dispatch:t,getState:n})=>r=>o=>"function"==typeof o?o(t,n,e):r(o)}var Tv=Dv(),Iv=Dv,jv=Symbol.for("immer-nothing"),Mv=Symbol.for("immer-draftable"),$v=Symbol.for("immer-state");function Lv(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var Fv=Object.getPrototypeOf;function zv(e){return!!e&&!!e[$v]}function Wv(e){return!!e&&(Bv(e)||Array.isArray(e)||!!e[Mv]||!!e.constructor?.[Mv]||Xv(e)||Yv(e))}var Gv=Object.prototype.constructor.toString();function Bv(e){if(!e||"object"!=typeof e)return!1;const t=Fv(e);if(null===t)return!0;const n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return n===Object||"function"==typeof n&&Function.toString.call(n)===Gv}function Vv(e,t){0===Hv(e)?Reflect.ownKeys(e).forEach((n=>{t(n,e[n],e)})):e.forEach(((n,r)=>t(r,n,e)))}function Hv(e){const t=e[$v];return t?t.type_:Array.isArray(e)?1:Xv(e)?2:Yv(e)?3:0}function Uv(e,t){return 2===Hv(e)?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function qv(e,t,n){const r=Hv(e);2===r?e.set(t,n):3===r?e.add(n):e[t]=n}function Xv(e){return e instanceof Map}function Yv(e){return e instanceof Set}function Kv(e){return e.copy_||e.base_}function Qv(e,t){if(Xv(e))return new Map(e);if(Yv(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);const n=Bv(e);if(!0===t||"class_only"===t&&!n){const t=Object.getOwnPropertyDescriptors(e);delete t[$v];let n=Reflect.ownKeys(t);for(let r=0;r1&&(e.set=e.add=e.clear=e.delete=Jv),Object.freeze(e),t&&Object.entries(e).forEach((([e,t])=>Zv(t,!0)))),e}function Jv(){Lv(2)}function ew(e){return Object.isFrozen(e)}var tw,nw={};function rw(e){const t=nw[e];return t||Lv(0),t}function ow(){return tw}function aw(e,t){t&&(rw("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function iw(e){lw(e),e.drafts_.forEach(cw),e.drafts_=null}function lw(e){e===tw&&(tw=e.parent_)}function sw(e){return tw={drafts_:[],parent_:tw,immer_:e,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function cw(e){const t=e[$v];0===t.type_||1===t.type_?t.revoke_():t.revoked_=!0}function uw(e,t){t.unfinalizedDrafts_=t.drafts_.length;const n=t.drafts_[0];return void 0!==e&&e!==n?(n[$v].modified_&&(iw(t),Lv(4)),Wv(e)&&(e=dw(t,e),t.parent_||pw(t,e)),t.patches_&&rw("Patches").generateReplacementPatches_(n[$v].base_,e,t.patches_,t.inversePatches_)):e=dw(t,n,[]),iw(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==jv?e:void 0}function dw(e,t,n){if(ew(t))return t;const r=t[$v];if(!r)return Vv(t,((o,a)=>fw(e,r,t,o,a,n))),t;if(r.scope_!==e)return t;if(!r.modified_)return pw(e,r.base_,!0),r.base_;if(!r.finalized_){r.finalized_=!0,r.scope_.unfinalizedDrafts_--;const t=r.copy_;let o=t,a=!1;3===r.type_&&(o=new Set(t),t.clear(),a=!0),Vv(o,((o,i)=>fw(e,r,t,o,i,n,a))),pw(e,t,!1),n&&e.patches_&&rw("Patches").generatePatches_(r,n,e.patches_,e.inversePatches_)}return r.copy_}function fw(e,t,n,r,o,a,i){if(zv(o)){const i=dw(e,o,a&&t&&3!==t.type_&&!Uv(t.assigned_,r)?a.concat(r):void 0);if(qv(n,r,i),!zv(i))return;e.canAutoFreeze_=!1}else i&&n.add(o);if(Wv(o)&&!ew(o)){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1)return;dw(e,o),t&&t.scope_.parent_||"symbol"==typeof r||!Object.prototype.propertyIsEnumerable.call(n,r)||pw(e,o)}}function pw(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&Zv(t,n)}var hw={get(e,t){if(t===$v)return e;const n=Kv(e);if(!Uv(n,t))return function(e,t,n){const r=bw(t,n);return r?"value"in r?r.value:r.get?.call(e.draft_):void 0}(e,n,t);const r=n[t];return e.finalized_||!Wv(r)?r:r===gw(e.base_,t)?(vw(e),e.copy_[t]=ww(r,e)):r},has:(e,t)=>t in Kv(e),ownKeys:e=>Reflect.ownKeys(Kv(e)),set(e,t,n){const r=bw(Kv(e),t);if(r?.set)return r.set.call(e.draft_,n),!0;if(!e.modified_){const r=gw(Kv(e),t),i=r?.[$v];if(i&&i.base_===n)return e.copy_[t]=n,e.assigned_[t]=!1,!0;if(((o=n)===(a=r)?0!==o||1/o==1/a:o!=o&&a!=a)&&(void 0!==n||Uv(e.base_,t)))return!0;vw(e),yw(e)}var o,a;return e.copy_[t]===n&&(void 0!==n||t in e.copy_)||Number.isNaN(n)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=n,e.assigned_[t]=!0),!0},deleteProperty:(e,t)=>(void 0!==gw(e.base_,t)||t in e.base_?(e.assigned_[t]=!1,vw(e),yw(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0),getOwnPropertyDescriptor(e,t){const n=Kv(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r?{writable:!0,configurable:1!==e.type_||"length"!==t,enumerable:r.enumerable,value:n[t]}:r},defineProperty(){Lv(11)},getPrototypeOf:e=>Fv(e.base_),setPrototypeOf(){Lv(12)}},mw={};function gw(e,t){const n=e[$v];return(n?Kv(n):e)[t]}function bw(e,t){if(!(t in e))return;let n=Fv(e);for(;n;){const e=Object.getOwnPropertyDescriptor(n,t);if(e)return e;n=Fv(n)}}function yw(e){e.modified_||(e.modified_=!0,e.parent_&&yw(e.parent_))}function vw(e){e.copy_||(e.copy_=Qv(e.base_,e.scope_.immer_.useStrictShallowCopy_))}function ww(e,t){const n=Xv(e)?rw("MapSet").proxyMap_(e,t):Yv(e)?rw("MapSet").proxySet_(e,t):function(e,t){const n=Array.isArray(e),r={type_:n?1:0,scope_:t?t.scope_:ow(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let o=r,a=hw;n&&(o=[r],a=mw);const{revoke:i,proxy:l}=Proxy.revocable(o,a);return r.draft_=l,r.revoke_=i,l}(e,t);return(t?t.scope_:ow()).drafts_.push(n),n}function _w(e){if(!Wv(e)||ew(e))return e;const t=e[$v];let n;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=Qv(e,t.scope_.immer_.useStrictShallowCopy_)}else n=Qv(e,!0);return Vv(n,((e,t)=>{qv(n,e,_w(t))})),t&&(t.finalized_=!1),n}Vv(hw,((e,t)=>{mw[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}})),mw.deleteProperty=function(e,t){return mw.set.call(this,e,t,void 0)},mw.set=function(e,t,n){return hw.set.call(this,e[0],t,n,e[0])};var Ew=new class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.produce=(e,t,n)=>{if("function"==typeof e&&"function"!=typeof t){const n=t;t=e;const r=this;return function(e=n,...o){return r.produce(e,(e=>t.call(this,e,...o)))}}let r;if("function"!=typeof t&&Lv(6),void 0!==n&&"function"!=typeof n&&Lv(7),Wv(e)){const o=sw(this),a=ww(e,void 0);let i=!0;try{r=t(a),i=!1}finally{i?iw(o):lw(o)}return aw(o,n),uw(r,o)}if(!e||"object"!=typeof e){if(r=t(e),void 0===r&&(r=e),r===jv&&(r=void 0),this.autoFreeze_&&Zv(r,!0),n){const t=[],o=[];rw("Patches").generateReplacementPatches_(e,r,t,o),n(t,o)}return r}Lv(1)},this.produceWithPatches=(e,t)=>{if("function"==typeof e)return(t,...n)=>this.produceWithPatches(t,(t=>e(t,...n)));let n,r;return[this.produce(e,t,((e,t)=>{n=e,r=t})),n,r]},"boolean"==typeof e?.autoFreeze&&this.setAutoFreeze(e.autoFreeze),"boolean"==typeof e?.useStrictShallowCopy&&this.setUseStrictShallowCopy(e.useStrictShallowCopy)}createDraft(e){var t;Wv(e)||Lv(8),zv(e)&&(zv(t=e)||Lv(10),e=_w(t));const n=sw(this),r=ww(e,void 0);return r[$v].isManual_=!0,lw(n),r}finishDraft(e,t){const n=e&&e[$v];n&&n.isManual_||Lv(9);const{scope_:r}=n;return aw(r,t),uw(void 0,r)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}applyPatches(e,t){let n;for(n=t.length-1;n>=0;n--){const r=t[n];if(0===r.path.length&&"replace"===r.op){e=r.value;break}}n>-1&&(t=t.slice(n+1));const r=rw("Patches").applyPatches_;return zv(e)?r(e,t):this.produce(e,(e=>r(e,t)))}},Sw=Ew.produce;Ew.produceWithPatches.bind(Ew),Ew.setAutoFreeze.bind(Ew),Ew.setUseStrictShallowCopy.bind(Ew),Ew.applyPatches.bind(Ew),Ew.createDraft.bind(Ew),Ew.finishDraft.bind(Ew);var xw="undefined"!=typeof window&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(0!==arguments.length)return"object"==typeof arguments[0]?Pv:Pv.apply(null,arguments)};function kw(e,t){function n(...n){if(t){let r=t(...n);if(!r)throw new Error(Fw(0));return{type:e,payload:r.payload,..."meta"in r&&{meta:r.meta},..."error"in r&&{error:r.error}}}return{type:e,payload:n[0]}}return n.toString=()=>`${e}`,n.type=e,n.match=t=>function(e){return Ov(e)&&"type"in e&&"string"==typeof e.type}(t)&&t.type===e,n}"undefined"!=typeof window&&window.__REDUX_DEVTOOLS_EXTENSION__&&window.__REDUX_DEVTOOLS_EXTENSION__;var Rw=class e extends Array{constructor(...t){super(...t),Object.setPrototypeOf(this,e.prototype)}static get[Symbol.species](){return e}concat(...e){return super.concat.apply(this,e)}prepend(...t){return 1===t.length&&Array.isArray(t[0])?new e(...t[0].concat(this)):new e(...t.concat(this))}};function Cw(e){return Wv(e)?Sw(e,(()=>{})):e}function Nw(e,t,n){if(e.has(t)){let r=e.get(t);return n.update&&(r=n.update(r,t,e),e.set(t,r)),r}if(!n.insert)throw new Error(Fw(10));const r=n.insert(t,e);return e.set(t,r),r}var Ow=e=>t=>{setTimeout(t,e)},Aw="undefined"!=typeof window&&window.requestAnimationFrame?window.requestAnimationFrame:Ow(10);function Pw(e){const t={},n=[];let r;const o={addCase(e,n){const r="string"==typeof e?e:e.type;if(!r)throw new Error(Fw(28));if(r in t)throw new Error(Fw(29));return t[r]=n,o},addMatcher:(e,t)=>(n.push({matcher:e,reducer:t}),o),addDefaultCase:e=>(r=e,o)};return e(o),[t,n,r]}var Dw=Symbol.for("rtk-slice-createasyncthunk");function Tw(e,t){return`${e}/${t}`}function Iw({creators:e}={}){const t=e?.asyncThunk?.[Dw];return function(e){const{name:n,reducerPath:r=n}=e;if(!n)throw new Error(Fw(11));const o=("function"==typeof e.reducers?e.reducers(function(){function e(e,t){return{_reducerDefinitionType:"asyncThunk",payloadCreator:e,...t}}return e.withTypes=()=>e,{reducer:e=>Object.assign({[e.name]:(...t)=>e(...t)}[e.name],{_reducerDefinitionType:"reducer"}),preparedReducer:(e,t)=>({_reducerDefinitionType:"reducerWithPrepare",prepare:e,reducer:t}),asyncThunk:e}}()):e.reducers)||{},a=Object.keys(o),i={sliceCaseReducersByName:{},sliceCaseReducersByType:{},actionCreators:{},sliceMatchers:[]},l={addCase(e,t){const n="string"==typeof e?e:e.type;if(!n)throw new Error(Fw(12));if(n in i.sliceCaseReducersByType)throw new Error(Fw(13));return i.sliceCaseReducersByType[n]=t,l},addMatcher:(e,t)=>(i.sliceMatchers.push({matcher:e,reducer:t}),l),exposeAction:(e,t)=>(i.actionCreators[e]=t,l),exposeCaseReducer:(e,t)=>(i.sliceCaseReducersByName[e]=t,l)};function s(){const[t={},n=[],r]="function"==typeof e.extraReducers?Pw(e.extraReducers):[e.extraReducers],o={...t,...i.sliceCaseReducersByType};return function(e){let t,[a,l,s]=Pw((e=>{for(let t in o)e.addCase(t,o[t]);for(let t of i.sliceMatchers)e.addMatcher(t.matcher,t.reducer);for(let t of n)e.addMatcher(t.matcher,t.reducer);r&&e.addDefaultCase(r)}));if("function"==typeof e)t=()=>Cw(e());else{const n=Cw(e);t=()=>n}function c(e=t(),n){let r=[a[n.type],...l.filter((({matcher:e})=>e(n))).map((({reducer:e})=>e))];return 0===r.filter((e=>!!e)).length&&(r=[s]),r.reduce(((e,t)=>{if(t){if(zv(e)){const r=t(e,n);return void 0===r?e:r}if(Wv(e))return Sw(e,(e=>t(e,n)));{const r=t(e,n);if(void 0===r){if(null===e)return e;throw Error("A case reducer on a non-draftable value must not return undefined")}return r}}return e}),e)}return c.getInitialState=t,c}(e.initialState)}a.forEach((r=>{const a=o[r],i={reducerName:r,type:Tw(n,r),createNotation:"function"==typeof e.reducers};!function(e){return"asyncThunk"===e._reducerDefinitionType}(a)?function({type:e,reducerName:t,createNotation:n},r,o){let a,i;if("reducer"in r){if(n&&!function(e){return"reducerWithPrepare"===e._reducerDefinitionType}(r))throw new Error(Fw(17));a=r.reducer,i=r.prepare}else a=r;o.addCase(e,a).exposeCaseReducer(t,a).exposeAction(t,i?kw(e,i):kw(e))}(i,a,l):function({type:e,reducerName:t},n,r,o){if(!o)throw new Error(Fw(18));const{payloadCreator:a,fulfilled:i,pending:l,rejected:s,settled:c,options:u}=n,d=o(e,a,u);r.exposeAction(t,d),i&&r.addCase(d.fulfilled,i),l&&r.addCase(d.pending,l),s&&r.addCase(d.rejected,s),c&&r.addMatcher(d.settled,c),r.exposeCaseReducer(t,{fulfilled:i||$w,pending:l||$w,rejected:s||$w,settled:c||$w})}(i,a,l,t)}));const c=e=>e,u=new Map;let d;function f(e,t){return d||(d=s()),d(e,t)}function p(){return d||(d=s()),d.getInitialState()}function h(t,n=!1){function r(e){let r=e[t];return void 0===r&&n&&(r=p()),r}function o(t=c){const r=Nw(u,n,{insert:()=>new WeakMap});return Nw(r,t,{insert:()=>{const r={};for(const[o,a]of Object.entries(e.selectors??{}))r[o]=jw(a,t,p,n);return r}})}return{reducerPath:t,getSelectors:o,get selectors(){return o(r)},selectSlice:r}}const m={name:n,reducer:f,actions:i.actionCreators,caseReducers:i.sliceCaseReducersByName,getInitialState:p,...h(r),injectInto(e,{reducerPath:t,...n}={}){const o=t??r;return e.inject({reducerPath:o,reducer:f},n),{...m,...h(o,!0)}}};return m}}function jw(e,t,n,r){function o(o,...a){let i=t(o);return void 0===i&&r&&(i=n()),e(i,...a)}return o.unwrapped=e,o}var Mw=Iw();function $w(){}var{assign:Lw}=Object;function Fw(e){return`Minified Redux Toolkit error #${e}; visit https://redux-toolkit.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}Symbol.for("rtk-state-proxy-original");var zw={"¼":"1/4","½":"1/2","¾":"3/4","⅐":"1/7","⅑":"1/9","⅒":"1/10","⅓":"1/3","⅔":"2/3","⅕":"1/5","⅖":"2/5","⅗":"3/5","⅘":"4/5","⅙":"1/6","⅚":"5/6","⅛":"1/8","⅜":"3/8","⅝":"5/8","⅞":"7/8","⅟":"1/"},Ww=/^(?=-?\s*\.\d|-?\s*\d)(-)?\s*((?:\d(?:[\d,_]*\d)?)*)(([eE][+-]?\d(?:[\d,_]*\d)?)?|\.\d(?:[\d,_]*\d)?([eE][+-]?\d(?:[\d,_]*\d)?)?|(\s+\d(?:[\d,_]*\d)?\s*)?\s*\/\s*\d(?:[\d,_]*\d)?)?$/,Gw=new RegExp(Ww.source.replace(/\$$/,"(?:\\s*[^\\.\\d\\/].*)?")),Bw=new RegExp(`(${Object.keys(zw).join("|")})`),Vw={MMM:3e3,MM:2e3,M:1e3,CM:900,DCCC:800,DCC:700,DC:600,D:500,CD:400,CCC:300,CC:200,C:100,XC:90,LXXX:80,LXX:70,LX:60,L:50,XL:40,XXX:30,XX:20,XII:12,XI:11,X:10,IX:9,VIII:8,VII:7,VI:6,V:5,IV:4,III:3,II:2,I:1},Hw={Ⅰ:"I",Ⅱ:"II",Ⅲ:"III",Ⅳ:"IV",Ⅴ:"V",Ⅵ:"VI",Ⅶ:"VII",Ⅷ:"VIII",Ⅸ:"IX",Ⅹ:"X",Ⅺ:"XI",Ⅻ:"XII",Ⅼ:"L",Ⅽ:"C",Ⅾ:"D",Ⅿ:"M",ⅰ:"I",ⅱ:"II",ⅲ:"III",ⅳ:"IV",ⅴ:"V",ⅵ:"VI",ⅶ:"VII",ⅷ:"VIII",ⅸ:"IX",ⅹ:"X",ⅺ:"XI",ⅻ:"XII",ⅼ:"L",ⅽ:"C",ⅾ:"D",ⅿ:"M"},Uw=new RegExp(`(${Object.keys(Hw).join("|")})`,"gi"),qw=/^(?=[MDCLXVI])(M{0,3})(C[MD]|D?C{0,3})(X[CL]|L?X{0,3})(I[XV]|V?I{0,3})$/i,Xw={round:3,allowTrailingInvalid:!1,romanNumerals:!1},Yw=/^\s*\//,Kw=e=>ht.createElement("button",{type:"button","data-testid":e.testID,disabled:e.disabled&&!e.disabledTranslation,className:e.className,title:e.disabledTranslation&&e.disabled?e.disabledTranslation.title:e.title,onClick:t=>e.handleOnClick(t)},e.disabledTranslation&&e.disabled?e.disabledTranslation.label:e.label),Qw=(0,ht.forwardRef)(((e,t)=>ht.createElement("span",{"data-testid":e.testID,ref:t,className:e.className,title:e.title},e.label))),Zw="------",Jw={fields:{title:"Fields",placeholderName:"~",placeholderLabel:Zw,placeholderGroupLabel:Zw},operators:{title:"Operators",placeholderName:"~",placeholderLabel:Zw,placeholderGroupLabel:Zw},value:{title:"Value"},removeRule:{label:"⨯",title:"Remove rule"},removeGroup:{label:"⨯",title:"Remove group"},addRule:{label:"+ Rule",title:"Add rule"},addGroup:{label:"+ Group",title:"Add group"},combinators:{title:"Combinators"},notToggle:{label:"Not",title:"Invert this group"},cloneRule:{label:"⧉",title:"Clone rule"},cloneRuleGroup:{label:"⧉",title:"Clone group"},shiftActionUp:{label:"˄",title:"Shift up"},shiftActionDown:{label:"˅",title:"Shift down"},dragHandle:{label:"⁞⁞",title:"Drag handle"},lockRule:{label:"🔓",title:"Lock rule"},lockGroup:{label:"🔓",title:"Lock group"},lockRuleDisabled:{label:"🔒",title:"Unlock rule"},lockGroupDisabled:{label:"🔒",title:"Unlock group"},valueSourceSelector:{title:"Value source"}},e_=[{name:"=",value:"=",label:"="},{name:"!=",value:"!=",label:"!="},{name:"<",value:"<",label:"<"},{name:">",value:">",label:">"},{name:"<=",value:"<=",label:"<="},{name:">=",value:">=",label:">="},{name:"contains",value:"contains",label:"contains"},{name:"beginsWith",value:"beginsWith",label:"begins with"},{name:"endsWith",value:"endsWith",label:"ends with"},{name:"doesNotContain",value:"doesNotContain",label:"does not contain"},{name:"doesNotBeginWith",value:"doesNotBeginWith",label:"does not begin with"},{name:"doesNotEndWith",value:"doesNotEndWith",label:"does not end with"},{name:"null",value:"null",label:"is null"},{name:"notNull",value:"notNull",label:"is not null"},{name:"in",value:"in",label:"in"},{name:"notIn",value:"notIn",label:"not in"},{name:"between",value:"between",label:"between"},{name:"notBetween",value:"notBetween",label:"not between"}],t_=[{name:"and",value:"and",label:"AND"},{name:"or",value:"or",label:"OR"}],n_="queryBuilder-valid",r_="queryBuilder-invalid",o_="shiftActions",a_="dndDragging",i_="dndOver",l_="dndCopy",s_="queryBuilder-dragHandle",c_="queryBuilder-disabled",u_="rule-value-list-item",d_={queryBuilder:"",ruleGroup:"",header:"",body:"",combinators:"",addRule:"",addGroup:"",cloneRule:"",cloneGroup:"",removeGroup:"",notToggle:"",rule:"",fields:"",operators:"",value:"",removeRule:"",shiftActions:"",dragHandle:"",lockRule:"",lockGroup:"",valueSource:"",actionElement:"",valueSelector:"",betweenRules:"",valid:"",invalid:"",dndDragging:"",dndOver:"",dndCopy:"",disabled:"",valueListItem:"",branches:""},f_="rule",p_="rule-group",h_="inline-combinator",m_="add-group",g_="remove-group",b_="clone-group",y_="add-rule",v_="combinators",w_="not-toggle",__="shift-actions",E_="drag-handle",S_="lock-group",x_="action aborted: parent path disabled",k_="action aborted: path is disabled",R_="rule or group added";function C_(e){let t,n,r="";if("string"==typeof e||"number"==typeof e)r+=e;else if("object"==typeof e)if(Array.isArray(e)){const o=e.length;for(t=0;t{e[t]=n}},selectors:{getQuerySelectorById:(e,t)=>e[t]}}),F_=Mw({name:"warnings",initialState:{[A_]:!1,[P_]:!1,[D_]:!1,[T_]:!1,[I_]:!1,[j_]:!1,[M_]:!1,[$_]:!1},reducers:{rqbWarn:(e,{payload:t})=>{e[t]||(console.error(t),e[t]=!0)}}}),z_={queries:L_.getInitialState(),warnings:F_.getInitialState()},W_=function(e){const t=function(e){const{thunk:t=!0,immutableCheck:n=!0,serializableCheck:r=!0,actionCreatorCheck:o=!0}=e??{};let a=new Rw;return t&&("boolean"==typeof t?a.push(Tv):a.push(Iv(t.extraArgument))),a},{reducer:n,middleware:r,devTools:o=!0,preloadedState:a,enhancers:i}=e||{};let l,s;if("function"==typeof n)l=n;else{if(!Ov(n))throw new Error(Fw(1));l=function(e){const t=Object.keys(e),n={};for(let r=0;r{const n=e[t];if(void 0===n(void 0,{type:Nv.INIT}))throw new Error(kv(12));if(void 0===n(void 0,{type:Nv.PROBE_UNKNOWN_ACTION()}))throw new Error(kv(13))}))}(n)}catch(e){o=e}return function(e={},t){if(o)throw o;let a=!1;const i={};for(let o=0;o(n,r)=>{const o=t(n,r);let a=()=>{throw new Error(kv(15))};const i={getState:o.getState,dispatch:(e,...t)=>a(e,...t)},l=e.map((e=>e(i)));return a=Pv(...l)(o.dispatch),{...o,dispatch:a}}}(...s),d=(e=>function(t){const{autoBatch:n=!0}=t??{};let r=new Rw(e);return n&&r.push(((e={type:"raf"})=>t=>(...n)=>{const r=t(...n);let o=!0,a=!1,i=!1;const l=new Set,s="tick"===e.type?queueMicrotask:"raf"===e.type?Aw:"callback"===e.type?e.queueNotification:Ow(e.timeout),c=()=>{i=!1,a&&(a=!1,l.forEach((e=>e())))};return Object.assign({},r,{subscribe(e){const t=r.subscribe((()=>o&&e()));return l.add(e),()=>{t(),l.delete(e)}},dispatch(e){try{return o=!e?.meta?.RTK_autoBatch,a=!o,a&&(i||(i=!0,s(c))),r.dispatch(e)}finally{o=!0}}})})("object"==typeof n?n:void 0)),r})(u);return Av(l,a,c(..."function"==typeof i?i(d):d()))}({reducer:{queries:L_.reducer,warnings:F_.reducer},preloadedState:z_,middleware:e=>e({serializableCheck:{ignoredActions:["queries/setQueryState"],ignoredPaths:[/^queries\b.*\.rules\.\d+\.value$/]}})}),G_=ht.createContext(null),B_=function(e=fv){const t=e===fv?hv:pv(e),n=(e,n={})=>{const{equalityFn:r=gv,devModeChecks:o={}}="function"==typeof n?{equalityFn:n}:n,{store:a,subscription:i,getServerState:l,stabilityCheck:s,identityFunctionCheck:c}=t(),u=(sv.useRef(!0),sv.useCallback({[e.name]:t=>e(t)}[e.name],[e,s,o.stabilityCheck])),d=mv(i.addNestedSub,a.getState,l||a.getState,u,r);return sv.useDebugValue(d),d};return Object.assign(n,{withTypes:()=>n}),n}(G_),V_=e=>t=>L_.selectors.getQuerySelectorById({queries:t.queries},e),H_=({payload:e,onQueryChange:t})=>n=>{n(L_.actions.setQueryState(e)),"function"==typeof t&&t(e.query)},U_=function(e=fv){const t=e===fv?xv:Ev(e),n=()=>t().dispatch;return Object.assign(n,{withTypes:()=>n}),n}(G_),q_=Ev(G_),{rqbWarn:X_}=F_.actions;function Y_(e,t,n){U_()}var K_=(e,t=",")=>"string"==typeof e?e.split(`\\${t}`).map((e=>e.split(t))).reduce(((e,n,r)=>0===r?n:[...e.slice(0,-1),`${e.at(-1)}${t}${n[0]}`,...n.slice(1)]),[]):[],Q_=(e,t=",")=>e.map((e=>`${e??""}`.replaceAll(t[0],`\\${t[0]}`))).join(t),Z_=e=>"string"==typeof e?e.trim():e,J_=(e,{retainEmptyStrings:t}={})=>Array.isArray(e)?e.map((e=>Z_(e))):"string"==typeof e?K_(e,",").filter(t?()=>!0:e=>!/^\s*$/.test(e)).map((e=>e.trim())):"number"==typeof e?[e]:[],eE=new RegExp(Ww.source.replace(/^\^/,String.raw`^\s*`).replace(/\$$/,String.raw`\s*$`)),tE=e=>null!==e&&"object"==typeof e&&Object.getPrototypeOf(e)===Object.prototype,nE=e=>tE(e)&&Array.isArray(e.rules),rE=e=>nE(e)&&"string"==typeof e.combinator,oE=e=>nE(e)&&void 0===e.combinator,aE=e=>nE(e)?iE(e):e,iE=e=>{const t=[],n=e=>t.push(aE(e));let r=0;for(let o=0;oaE(e)))}),o-=2}else"or"===e.rules[o+1]&&(0===o||o===e.rules.length-3?(0!==o&&"or"!==e.rules[o-1]||n(e.rules[o]),n(e.rules[o+1]),o===e.rules.length-3&&n(e.rules[o+2])):("and"===e.rules[o-1]||n(e.rules[o]),n(e.rules[o+1])));return 1===t.length&&"object"==typeof t[0]&&nE(t[0])?{...e,...t[0]}:{...e,rules:t}},lE=e=>{if(rE(e))return e;const t=iE(e),n=t.rules.map((e=>"string"!=typeof e&&nE(e)?lE(e):e)),r=n.length<2?"and":n[1],o=n.filter((e=>"string"!=typeof e));return{...t,combinator:r,rules:o}},sE=e=>tE(e)&&"name"in e&&"string"==typeof e.name,cE=e=>tE(e)&&"value"in e&&"string"==typeof e.value;function uE(e,t){return Sw((e=>{const n={};let r=!!t;if(sE(e)&&!cE(e)?(n.value=e.name,r=!0):!sE(e)&&cE(e)&&(n.name=e.value,r=!0),r)return Object.assign({},t,e,n)}))(e)}function dE(e,t){return Array.isArray(e)?Sw((e=>{if(gE(e))for(const n of e)for(const[e,r]of n.options.entries())n.options[e]=uE(r,t);else for(const[n,r]of e.entries())e[n]=uE(r,t)}))(e):[]}function fE(e,t){return Object.fromEntries(Object.entries(e).map((([e,n])=>[e,uE(n,t)])))}var pE=e=>{const t=new Set,n=[];for(const r of e)t.has(r.value??r.name)||(t.add(r.value??r.name),n.push(r));return e.length===n.length?e:n},hE=e=>{const t=new Set,n=new Set,r=[];for(const o of e)if(!t.has(o.label)){t.add(o.label);const e=[];for(const t of o.options)n.has(t.value??t.name)||(n.add(t.value??t.name),e.push(uE(t)));r.push({...o,options:e})}return r},mE=e=>Array.isArray(e)&&e.length>0&&tE(e[0])&&"options"in e[0]&&Array.isArray(e[0].options),gE=e=>{if(Array.isArray(e))for(const t of e)if(tE(t)&&"options"in t)for(const e of t.options)return!(!tE(e)||!("name"in e)&&!("value"in e));return!1},bE=(e,t)=>(mE(e)?e.flatMap((e=>e.options)):e).find((e=>e.value===t||e.name===t)),yE=e=>{if(!Array.isArray(e)||0===e.length)return null;if(gE(e)){for(const t of e)if(t.options.length>0)return t.options[0].value??t.options[0].name;return null}return e[0].value??e[0].name},vE=(e,t,n)=>{const r=uE(e),o=uE(n);return r.value!==o.value&&("string"==typeof r.comparator?r[r.comparator]===o[r.comparator]:r.comparator?.(o,t)??!1)},wE=(e,t,n)=>{if(!e.comparator){const n=t=>(t.value??t.name)!==(e.value??e.name);return gE(t)?t.map((e=>({...e,options:e.options.filter((e=>n(e)))}))):t.filter((e=>n(e)))}return gE(t)?t.map((t=>({...t,options:t.options.filter((t=>vE(e,n,t)))}))).filter((e=>e.options.length>0)):t.filter((t=>vE(e,n,t)))},_E=(e,{parseNumbers:t}={})=>{if(!t||"bigint"==typeof e||"number"==typeof e)return e;if("native"===t)return parseFloat(e);const n=((e,t=Xw)=>{if("number"==typeof e||"bigint"==typeof e)return e;let n=NaN;const r=`${e}`.replace(Bw,((e,t)=>` ${zw[t]}`)).replace("⁄","/").trim();if(0===r.length)return NaN;const o={...Xw,...t},a=(o.allowTrailingInvalid?Gw:Ww).exec(r);if(!a)return o.romanNumerals?(e=>{const t=`${e}`.replace(Uw,((e,t)=>Hw[t])).toUpperCase(),n=qw.exec(t);if(!n)return NaN;const[,r,o,a,i]=n;return(Vw[r]??0)+(Vw[o]??0)+(Vw[a]??0)+(Vw[i]??0)})(r):NaN;const[,i,l,s]=a,c=l.replace(/[,_]/g,""),u=null==s?void 0:s.replace(/[,_]/g,"");if(n=!c&&u&&u.startsWith(".")?0:parseInt(c),!u)return i?-1*n:n;const d=!1===o.round?NaN:parseFloat(`1e${Math.floor(Math.max(0,o.round))}`);if(u.startsWith(".")||u.startsWith("e")||u.startsWith("E")){const e=parseFloat(`${n}${u}`);n=isNaN(d)?e:Math.round(e*d)/d}else if(Yw.test(u)){const e=parseInt(c),t=parseInt(u.replace("/",""));n=isNaN(d)?e/t:Math.round(e*d/t)/d}else{const e=u.split("/"),[t,r]=e.map((e=>parseInt(e)));n+=isNaN(d)?t/r:Math.round(t*d/r)/d}return i?-1*n:n})(e,{allowTrailingInvalid:"enhanced"===t,romanNumerals:!1,round:!1});return isNaN(n)?e:n},EE=e=>{switch(e.toLowerCase()){case"null":return"is null";case"notnull":return"is not null";case"notin":return"not in";case"notbetween":return"not between";case"contains":case"beginswith":case"endswith":return"like";case"doesnotcontain":case"doesnotbeginwith":case"doesnotendwith":return"not like";default:return e}},SE={"=":"$eq","!=":"$ne","<":"$lt","<=":"$lte",">":"$gt",">=":"$gte",in:"$in",notIn:"$nin"},xE={and:"&&",or:"||"},kE=e=>({...e,rules:e.rules.map((e=>{if("string"==typeof e)return e;if(nE(e))return kE(e);if(Array.isArray(e.value))return{...e,value:e.value.map((e=>_E(e,{parseNumbers:!0})))};const t=J_(e.value,{retainEmptyStrings:!0}).map((e=>_E(e,{parseNumbers:!0})));if(t.every((e=>"number"==typeof e))){if(t.length>1)return{...e,value:t};if(1===t.length)return{...e,value:t[0]}}return e}))}),RE=e=>"string"==typeof e&&e.length>0||"number"==typeof e&&!isNaN(e)||"string"!=typeof e&&"number"!=typeof e,CE=(e,t)=>t&&("number"==typeof e||"bigint"==typeof e||"string"==typeof e&&eE.test(e)),NE=(e=["",""])=>Array.isArray(e)?e:"string"==typeof e?[e,e]:e??["",""],OE=(e,{quoteFieldNamesWith:t,fieldIdentifierSeparator:n})=>{const[r,o]=NE(t);return"string"==typeof n&&n.length>0?Q_(K_(e,n).map((e=>`${r}${e}${o}`)),n):`${r}${e}${o}`},AE=e=>null==e||""===e,PE=e=>/^(does)?not/i.test(e),DE=(e,t)=>"string"==typeof e&&t?e.replaceAll('"','\\"'):e,TE=({field:e,operator:t,value:n,valueSource:r},{escapeQuotes:o,parseNumbers:a}={})=>{const i="field"===r,l=t.replace(/^=$/,"=="),s="number"==typeof n||"boolean"==typeof n||"bigint"==typeof n||CE(n,a);switch(l){case"<":case"<=":case"==":case"!=":case">":case">=":return`${e} ${l} ${i||s?Z_(n):`"${DE(n,o)}"`}`;case"contains":case"doesNotContain":return`${PE(l)?"!":""}${e}.contains(${i?Z_(n):`"${DE(n,o)}"`})`;case"beginsWith":case"doesNotBeginWith":return`${PE(l)?"!":""}${e}.startsWith(${i?Z_(n):`"${DE(n,o)}"`})`;case"endsWith":case"doesNotEndWith":return`${PE(l)?"!":""}${e}.endsWith(${i?Z_(n):`"${DE(n,o)}"`})`;case"null":return`${e} == null`;case"notNull":return`${e} != null`;case"in":case"notIn":{const t=PE(l);return`${t?"!(":""}${e} in [${J_(n).map((e=>i||CE(e,a)?`${Z_(e)}`:`"${DE(e,o)}"`)).join(", ")}]${t?")":""}`}case"between":case"notBetween":{const r=J_(n);if(r.length>=2&&!AE(r[0])&&!AE(r[1])){const[n,a]=r,l=CE(n,!0)?_E(n,{parseNumbers:!0}):NaN,s=CE(a,!0)?_E(a,{parseNumbers:!0}):NaN;let c=isNaN(l)?i?`${n}`:`"${DE(n,o)}"`:l,u=isNaN(s)?i?`${a}`:`"${DE(a,o)}"`:s;return c===l&&u===s&&s= ${c} && ${e} <= ${u})`:`(${e} < ${c} || ${e} > ${u})`}return""}}return""},IE=JSON.stringify,jE=({field:e,operator:t,value:n,valueSource:r},{parseNumbers:o}={})=>{const a="field"===r;if("="===t&&!a)return IE({[e]:CE(n,o)?_E(n,{parseNumbers:"strict"}):n});switch(t){case"<":case"<=":case"=":case"!=":case">":case">=":{const r=SE[t];return IE(a?{$expr:{[r]:[`$${e}`,`$${n}`]}}:{[e]:{[r]:CE(n,o)?_E(n,{parseNumbers:"strict"}):n}})}case"contains":return IE(a?{$where:`this.${e}.includes(this.${n})`}:{[e]:{$regex:n}});case"beginsWith":return IE(a?{$where:`this.${e}.startsWith(this.${n})`}:{[e]:{$regex:`^${n}`}});case"endsWith":return IE(a?{$where:`this.${e}.endsWith(this.${n})`}:{[e]:{$regex:`${n}$`}});case"doesNotContain":return IE(a?{$where:`!this.${e}.includes(this.${n})`}:{[e]:{$not:{$regex:n}}});case"doesNotBeginWith":return IE(a?{$where:`!this.${e}.startsWith(this.${n})`}:{[e]:{$not:{$regex:`^${n}`}}});case"doesNotEndWith":return IE(a?{$where:`!this.${e}.endsWith(this.${n})`}:{[e]:{$not:{$regex:`${n}$`}}});case"null":return IE({[e]:null});case"notNull":return IE({[e]:{$ne:null}});case"in":case"notIn":{const r=J_(n);return IE(a?{$where:`${"notIn"===t?"!":""}[${r.map((e=>`this.${e}`)).join(",")}].includes(this.${e})`}:{[e]:{[SE[t]]:r.map((e=>CE(e,o)?_E(e,{parseNumbers:"strict"}):e))}})}case"between":case"notBetween":{const r=J_(n);if(r.length>=2&&RE(r[0])&&RE(r[1])){const[n,o]=r,i=CE(n,!0)?_E(n,{parseNumbers:"strict"}):NaN,l=CE(o,!0)?_E(o,{parseNumbers:"strict"}):NaN,s=a||isNaN(i)?n:i,c=a||isNaN(l)?o:l;return IE("between"===t?a?{$and:[{$expr:{$gte:[`$${e}`,`$${s}`]}},{$expr:{$lte:[`$${e}`,`$${c}`]}}]}:{[e]:{$gte:s,$lte:c}}:a?{$or:[{$expr:{$lt:[`$${e}`,`$${s}`]}},{$expr:{$gt:[`$${e}`,`$${c}`]}}]}:{$or:[{[e]:{$lt:s}},{[e]:{$gt:c}}]})}return""}}return""},ME=e=>/^(does)?not/i.test(e),$E=(e,t)=>t?`!(${e})`:`${e}`,LE=(e,t)=>"string"==typeof e&&t?e.replaceAll("'","\\'"):e,FE=({field:e,operator:t,value:n,valueSource:r},{escapeQuotes:o,parseNumbers:a}={})=>{const i="field"===r,l=t.replace(/^=$/,"=="),s="number"==typeof n||"boolean"==typeof n||"bigint"==typeof n||CE(n,a);switch(l){case"<":case"<=":case"==":case"!=":case">":case">=":return`${e} ${l} ${i||s?Z_(n):`'${LE(n,o)}'`}`;case"contains":case"doesNotContain":return $E(`${e} matches ${i||s?Z_(n):`'${LE(n,o)}'`}`,ME(l));case"beginsWith":case"doesNotBeginWith":{const t=i?`'^'.concat(${Z_(n)})`:`'${"string"==typeof n&&!n.startsWith("^")||s?"^":""}${LE(n,o)}'`;return $E(`${e} matches ${t}`,ME(l))}case"endsWith":case"doesNotEndWith":{const t=i?`${Z_(n)}.concat('$')`:`'${LE(n,o)}${"string"==typeof n&&!n.endsWith("$")||s?"$":""}'`;return $E(`${e} matches ${t}`,ME(l))}case"null":return`${e} == null`;case"notNull":return`${e} != null`;case"in":case"notIn":{const t=ME(l)?"!":"",r=J_(n);return r.length>0?`${t}(${r.map((t=>`${e} == ${i||CE(t,a)?`${Z_(t)}`:`'${LE(t,o)}'`}`)).join(" or ")})`:""}case"between":case"notBetween":{const r=J_(n);if(r.length>=2&&!AE(r[0])&&!AE(r[1])){const[n,a]=r,l=CE(n,!0)?_E(n,{parseNumbers:!0}):NaN,s=CE(a,!0)?_E(a,{parseNumbers:!0}):NaN;let c=isNaN(l)?i?`${n}`:`'${LE(n,o)}'`:l,u=isNaN(s)?i?`${a}`:`'${LE(a,o)}'`:s;return c===l&&u===s&&s= ${c} and ${e} <= ${u})`:`(${e} < ${c} or ${e} > ${u})`}return""}}return""},zE=({operator:e,value:t,valueSource:n},{escapeQuotes:r,parseNumbers:o,quoteFieldNamesWith:a,quoteValuesWith:i,concatOperator:l="||",fieldIdentifierSeparator:s}={})=>{const c="field"===n,u=e.toLowerCase(),d=i||"'",f=e=>`${d}${e}${d}`,p=e=>((e,t,n)=>n&&"string"==typeof e?e.replaceAll(`${t}`,`${t}${t}`):e)(e,d,r),h=e=>f(p(e)),m=e=>OE(e,{quoteFieldNamesWith:a,fieldIdentifierSeparator:s}),g=(...e)=>"CONCAT"===l.toUpperCase()?`CONCAT(${e.join(", ")})`:e.join(` ${l} `);switch(u){case"null":case"notnull":return"";case"in":case"notin":{const e=J_(t);return e.length>0?`(${e.map((e=>c?m(e):CE(e,o)?`${Z_(e)}`:`${h(e)}`)).join(", ")})`:""}case"between":case"notbetween":{const e=J_(t,{retainEmptyStrings:!0});if(e.length>=2&&RE(e[0])&&RE(e[1])){const[t,n]=e,r=CE(t,o)?_E(t,{parseNumbers:"strict"}):NaN,a=CE(n,o)?_E(n,{parseNumbers:"strict"}):NaN,i=isNaN(r)?c?`${t}`:t:r,l=isNaN(a)?c?`${n}`:n:a,s=[i,l];return i===r&&l===a&&am(e))):s.every((e=>CE(e,o)))?s.map((e=>_E(e,{parseNumbers:"strict"}))):s.map((e=>h(e)))).join(" and ")}return""}case"contains":case"doesnotcontain":return c?g(f("%"),m(t),f("%")):f(`%${p(t)}%`);case"beginswith":case"doesnotbeginwith":return c?g(m(t),f("%")):f(`${p(t)}%`);case"endswith":case"doesnotendwith":return c?g(f("%"),m(t)):f(`%${p(t)}`)}return"boolean"==typeof t?t?"TRUE":"FALSE":c?m(t):CE(t,o)?`${Z_(t)}`:`${h(t)}`},WE={"<":"lt","<=":"lte",">":"gt",">=":"gte"},GE=(e,t)=>/^(does)?not/i.test(e)?{bool:{must_not:t}}:t,BE=e=>e?.replace(/('|\\)/g,"\\$1"),VE={beginsWith:"startsWith",doesNotContain:"contains",doesNotBeginWith:"startsWith",doesNotEndWith:"endsWith"},HE=(e,t)=>"boolean"==typeof e?e:CE(e,t)?_E(e,{parseNumbers:t}):e,UE=({field:e,operator:t,value:n,valueSource:r},{parseNumbers:o}={})=>{if("field"===r){if(J_(n).some((e=>"string"!=typeof e)))return!1;const r=BE(e);switch(t){case"=":case"!=":case">":case">=":case"<":case"<=":{const e="="===t?"==":t,o=BE(n);return!!o&&{bool:{filter:{script:{script:`doc['${r}'] ${e} doc['${o}']`}}}}}case"in":case"notIn":{const e=J_(n);if(e.length>0){const n=e.map((e=>({bool:{filter:{script:{script:`doc['${r}'] == doc['${e}']`}}}})));return{bool:"in"===t?{should:n}:{must_not:n}}}return!1}case"between":case"notBetween":{const e=J_(n);if(e.length>=2&&e[0]&&e[1]){const n=`doc['${r}'] >= doc['${e[0]}'] && doc['${r}'] <= doc['${e[1]}']`;return{bool:{filter:{script:{script:"notBetween"===t?`!(${n})`:n}}}}}return!1}case"contains":case"doesNotContain":case"beginsWith":case"doesNotBeginWith":case"endsWith":case"doesNotEndWith":{const e=BE(n);return!!e&&{bool:{filter:{script:{script:((e,t,n)=>{const r=`doc['${e}'].${VE[t]??t}(doc['${n}'])`;return t.startsWith("d")?`!${r}`:r})(r,t,e)}}}}}}}switch(t){case"<":case"<=":case">":case">=":return{range:{[e]:{[WE[t]]:HE(n,o)}}};case"=":return{term:{[e]:HE(n,o)}};case"!=":return{bool:{must_not:{term:{[e]:HE(n,o)}}}};case"null":return{bool:{must_not:{exists:{field:e}}}};case"notNull":return{exists:{field:e}};case"in":case"notIn":{const r=J_(n).map((e=>HE(e,o)));if(r.length>0){const n=r.map((t=>({term:{[e]:HE(t,o)}})));return{bool:"in"===t?{should:n}:{must_not:n}}}return!1}case"between":case"notBetween":{const r=J_(n);if(r.length>=2&&RE(r[0])&&RE(r[1])){let[n,o]=r;if(CE(n,!0)&&CE(o,!0)){const e=_E(n,{parseNumbers:!0}),t=_E(o,{parseNumbers:!0});t/^(does)?not/i.test(e),XE=(e,t)=>`"${"string"==typeof e&&t?e.replaceAll('"','\\"'):e}"`,YE=(e,t)=>t?`$not(${e})`:`${e}`,KE=e=>`${e}`.replaceAll(/[$()*+.?[\\\]^{|}]/g,String.raw`\$&`).replaceAll("-",String.raw`\x2d`),QE=({field:e,operator:t,value:n,valueSource:r},{escapeQuotes:o,parseNumbers:a=!0,quoteFieldNamesWith:i=["",""],fieldIdentifierSeparator:l=""}={})=>{const s="field"===r,c="number"==typeof n||"boolean"==typeof n||"bigint"==typeof n||CE(n,a),u=e=>OE(e,{quoteFieldNamesWith:i,fieldIdentifierSeparator:l});switch(t){case"<":case"<=":case"=":case"!=":case">":case">=":return`${u(e)} ${t} ${s?u(Z_(n)):c?Z_(n):XE(n,o)}`;case"contains":case"doesNotContain":return YE(`$contains(${u(e)}, ${s?u(Z_(n)):XE(n,o)})`,qE(t));case"beginsWith":case"doesNotBeginWith":return YE(s?`$substring(${u(e)}, 0, $length(${u(Z_(n))})) = ${u(Z_(n))}`:`$contains(${u(e)}, /^${KE(n)}/)`,qE(t));case"endsWith":case"doesNotEndWith":return YE(s?`$substring(${u(e)}, $length(${u(e)}) - $length(${u(Z_(n))})) = ${u(Z_(n))}`:`$contains(${u(e)}, /${KE(n)}$/)`,qE(t));case"null":return`${u(e)} = null`;case"notNull":return`${u(e)} != null`;case"in":case"notIn":{const r=J_(n);return YE(`${u(e)} in [${r.map((e=>s?`${u(Z_(e))}`:CE(e,a)?`${Z_(e)}`:XE(e,o))).join(", ")}]`,qE(t))}case"between":case"notBetween":{const r=J_(n);if(r.length>=2&&!AE(r[0])&&!AE(r[1])){const[n,i]=r,l=CE(n,!0)?_E(n,{parseNumbers:!0}):NaN,c=CE(i,!0)?_E(i,{parseNumbers:!0}):NaN;let d=isNaN(l)?s?`${n}`:n:l,f=isNaN(c)?s?`${i}`:i:c;d===l&&f===c&&c= ${s?u(n):p?d:XE(d,o)} and ${u(e)} <= ${s?u(i):p?f:XE(f,o)}`;return"between"===t?`(${h})`:YE(h,!0)}return""}}return""},ZE=e=>e.replace(/^(=)$/,"$1=").replace(/^notnull$/i,"!=").replace(/^null$/i,"=="),JE=(e,t)=>/^(does)?not/i.test(e)?{"!":t}:t,eS=({field:e,operator:t,value:n,valueSource:r},{parseNumbers:o}={})=>{const a="field"===r,i={var:e},l=e=>a?{var:`${e}`}:CE(e,o)?_E(e,{parseNumbers:o}):e;switch(t){case"<":case"<=":case"=":case"!=":case">":case">=":return{[ZE(t)]:[i,l(n)]};case"null":case"notNull":return{[("notNull"===t?"!":"=")+"="]:[i,null]};case"in":case"notIn":{const e=J_(n).map((e=>l(e)));return JE(t,{in:[i,e]})}case"between":case"notBetween":{const e=J_(n);if(e.length>=2&&RE(e[0])&&RE(e[1])){let[n,r]=e;if(!a&&CE(n,!0)&&CE(r,!0)){const e=_E(n,{parseNumbers:!0}),t=_E(r,{parseNumbers:!0});t{const{fieldData:r,format:o,getNextNamedParam:a,parseNumbers:i,paramPrefix:l,paramsKeepPrefix:s,numberedParams:c,quoteFieldNamesWith:u=["",""],concatOperator:d,valueProcessor:f=zE}=t??{},{processedParams:p=[]}=n??{},h="parameterized"===o,m=[],g={},b=e=>h?{sql:e,params:m}:{sql:e,params:g},y=f(e,{parseNumbers:i,quoteFieldNamesWith:u,concatOperator:d,fieldData:r,format:o}),v=EE(e.operator),w=v.toLowerCase(),[_,E]=u;if(!("in"!==w&&"not in"!==w&&"between"!==w&&"not between"!==w||y))return b("");if("is null"===w||"is not null"===w)return b(`${_}${e.field}${E} ${v}`);if("field"===e.valueSource)return b(`${_}${e.field}${E} ${v} ${y}`.trim());if("in"===w||"not in"===w){const t=J_(e.value);if(h){for(const e of t)m.push(CE(e,i)?_E(e,{parseNumbers:i}):e);return b(`${_}${e.field}${E} ${v} (${t.map(((e,n)=>c?`${l}${p.length+1+t.length-(t.length-n)}`:"?")).join(", ")})`)}const n=[];for(const r of t){const t=a(e.field);n.push(`${l}${t}`),g[`${s?l:""}${t}`]=CE(r,i)?_E(r,{parseNumbers:i}):r}return b(`${_}${e.field}${E} ${v} (${n.join(", ")})`)}if("between"===w||"not between"===w){const t=J_(e.value,{retainEmptyStrings:!0}),[n,r]=t.slice(0,2).map((e=>CE(e,i)?_E(e,{parseNumbers:i}):e));if(h)return m.push(n,r),b(`${_}${e.field}${E} ${v} ${c?`${l}${p.length+1}`:"?"} and ${c?`${l}${p.length+2}`:"?"}`);const o=a(e.field),u=a(e.field);return g[`${s?l:""}${o}`]=n,g[`${s?l:""}${u}`]=r,b(`${_}${e.field}${E} ${v} ${l}${o} and ${l}${u}`)}let S=e.value;"string"==typeof e.value&&(S=CE(e.value,i)?_E(e.value,{parseNumbers:i}):/^'.*'$/g.test(y)?y.replaceAll(/(^'|'$)/g,""):y);let x="";return h?m.push(S):(x=a(e.field),g[`${s?l:""}${x}`]=S),b(`${_}${e.field}${E} ${v} ${h?c?`${l}${p.length+1}`:"?":`${l}${x}`}`.trim())},nS=e=>tE(e)&&"boolean"==typeof e.valid,rS=(e,t,n)=>{if("boolean"==typeof t)return t;if(nS(t))return t.valid;if("function"==typeof n&&!nE(e)){const t=n(e);if("boolean"==typeof t)return t;if(nS(t))return t.valid}return!0},oS=(e,t={})=>{const{escapeQuotes:n,fields:r,parseNumbers:o,quoteFieldNamesWith:a,quoteValuesWith:i,fieldIdentifierSeparator:l}=t,s="field"===e.valueSource,c=e.operator.toLowerCase(),u=i||"'",d=e=>(e=>`${u}${e}${u}`)((e=>((e,t,n)=>n&&"string"==typeof e?e.replaceAll(`${t}`,`${t}${t}`):e)(e,u,n))(e)),f=e=>OE(e,{quoteFieldNamesWith:a,fieldIdentifierSeparator:l});switch(c){case"null":case"notnull":return"";case"between":case"notbetween":return zE(e,t);case"in":case"notin":{const t=J_(e.value);if(0===t.length)return"";const n=t.map((t=>s?f(bE(r??[],e.value)?.label??t):CE(t,o)?`${Z_(t)}`:`${d(t)}`));return n.length<=2?n.join(" or "):`${n.slice(0,-1).join(", ")}, or ${n.at(-1)}`}}return"boolean"==typeof e.value?e.value?"true":"false":s?f(bE(r??[],e.value)?.label??e.value):CE(e.value,o)?`${Z_(e.value)}`:`${d(e.value)}`},aS=(e,t)=>{const{fields:n,fieldData:r,parseNumbers:o,escapeQuotes:a,quoteFieldNamesWith:i=["",""],fieldIdentifierSeparator:l="",quoteValuesWith:s="'",valueProcessor:c=oS,concatOperator:u="||",getOperators:d=()=>[]}=t??{},f=c(e,{fields:n,parseNumbers:o,escapeQuotes:a,quoteFieldNamesWith:i,fieldIdentifierSeparator:l,quoteValuesWith:s,concatOperator:u}),p=e.operator.toLowerCase();return"in"!==p&&"notin"!==p&&"between"!==p&&"notbetween"!==p||f?`${OE(r?.label??e.field,{quoteFieldNamesWith:i,fieldIdentifierSeparator:l})} ${((e,t="value")=>{switch(e.value.toLowerCase()){case"=":return"field"===t?"is the same as the value in":"is";case"!=":return"field"===t?"is not the same as the value in":"is not";case"<":return"field"===t?"is less than the value in":"is less than";case">":return"field"===t?"is greater than the value in":"is greater than";case"<=":return"field"===t?"is less than or equal to the value in":"is less than or equal to";case">=":return"field"===t?"is greater than or equal to the value in":"is greater than or equal to";case"contains":return"field"===t?"contains the value in":"contains";case"beginswith":return"field"===t?"starts with the value in":"starts with";case"endswith":return"field"===t?"ends with the value in":"ends with";case"doesnotcontain":return"field"===t?"does not contain the value in":"does not contain";case"doesnotbeginwith":return"field"===t?"does not start with the value in":"does not start with";case"doesnotendwith":return"field"===t?"does not end with the value in":"does not end with";case"null":return"is null";case"notnull":return"is not null";case"in":return"field"===t?"is the same as a value in":"is one of the values";case"notin":return"field"===t?"is not the same as any value in":"is not one of the values";case"between":return"field"===t?"is between the values in":"is between";case"notbetween":return"field"===t?"is not between the values in":"is not between";default:return e.label}})(bE(dE(d(e.field,{fieldData:r??{name:e.field,value:e.field,label:e.field}})??[]),e.operator)??{name:e.operator,value:e.operator,label:e.operator},e.valueSource)} ${f}`.trim():""},iS={ansi:{},sqlite:{paramsKeepPrefix:!0},oracle:{},mssql:{concatOperator:"+",quoteFieldNamesWith:["[","]"],fieldIdentifierSeparator:"."},mysql:{concatOperator:"CONCAT"},postgresql:{quoteFieldNamesWith:'"',numberedParams:!0,paramPrefix:"$"}};function lS(e,t={}){let n="json",r=zE,o=null,a=["",""],i="",l=()=>!0,s=[],c=()=>[],u={},d="",f=":",p=!1,h=!1,m=!1,g="~",b="~",y="'",v="||";if("string"==typeof t)switch(n=t.toLowerCase(),n){case"natural_language":o=aS;break;case"mongodb":o=jE;break;case"parameterized":case"parameterized_named":o=tS;break;case"cel":o=TE;break;case"spel":o=FE;break;case"jsonlogic":o=eS;break;case"elasticsearch":o=UE;break;case"jsonata":o=QE}else{const e={...iS[t.preset??"ansi"]??null,...t};n=(e.format??"json").toLowerCase();const{valueProcessor:u=null,ruleProcessor:w=null}=e;"function"==typeof w&&(o=w),r="function"==typeof u?(e,t)=>u.length>=3?u(e.field,e.operator,e.value,e.valueSource):u(e,t):"natural_language"===n?oS:"mongodb"===n?o??jE:"cel"===n?o??TE:"spel"===n?o??FE:"jsonlogic"===n?o??eS:"elasticsearch"===n?o??UE:"jsonata"===n?o??QE:zE,a=NE(e.quoteFieldNamesWith),i=e.fieldIdentifierSeparator??"",l=e.validator??(()=>!0),s=dE(e.fields??[]),c=(t,n)=>dE(e.getOperators?.(t,n)??[]),d=e.fallbackExpression??"",f=e.paramPrefix??":",p=!!e.paramsKeepPrefix,h=!!e.numberedParams,m=!!e.parseNumbers,g=e.placeholderFieldName??"~",b=e.placeholderOperatorName??"~",y=e.quoteValuesWith??"'",v=e.concatOperator??"||"}if(d||(d="mongodb"===n?'"$and":[{"$expr":true}]':"cel"===n||"spel"===n?"1 == 1":"natural_language"===n?"1 is 1":"(1 = 1)"),"json"===n||"json_without_ids"===n){const t=m?Sw(e,kE):e;return"json_without_ids"===n?JSON.stringify(t,((e,t)=>"id"===e||"path"===e?void 0:t)):JSON.stringify(t,null,2)}if("function"==typeof l){const t=l(e);if("boolean"==typeof t){if(!1===t)return"parameterized"===n?{sql:d,params:[]}:"parameterized_named"===n?{sql:d,params:{}}:"mongodb"===n?`{${d}}`:"jsonlogic"!==n&&("elasticsearch"===n?{}:d)}else u=t}const w={},_=pE(mE(E=s)?E.flatMap((e=>e.options)):E);var E;for(const e of _)"function"==typeof e.validator&&(w[e.value??e.name]=e.validator);const S=e=>{let t,n;if(e.id&&(t=u[e.id]),_.length>0){const t=_.filter((t=>t.name===e.field));if(t.length>0){const e=t[0];"function"==typeof e.validator&&(n=e.validator)}}return[t,n]};if("sql"===n){const t=(e,l)=>{if(!rS(e,u[e.id??""]))return l?d:"";const c=e.rules.map((l=>{if("string"==typeof l)return l;if(nE(l))return t(l,1===e.rules.length);const[c,u]=S(l);if(!rS(l,c,u)||l.field===g||l.operator===b)return"";const d="value"===(l.valueSource??"value"),f=bE(s,l.field);return"function"==typeof o?o(l,{parseNumbers:m,escapeQuotes:d,quoteFieldNamesWith:a,fieldIdentifierSeparator:i,fieldData:f,format:n,quoteValuesWith:y,concatOperator:v}):((e,t)=>{const{parseNumbers:n,escapeQuotes:r,quoteFieldNamesWith:o=["",""],fieldIdentifierSeparator:a="",quoteValuesWith:i="'",valueProcessor:l=zE,concatOperator:s="||"}=t??{},c=l(e,{parseNumbers:n,escapeQuotes:r,quoteFieldNamesWith:o,fieldIdentifierSeparator:a,quoteValuesWith:i,concatOperator:s}),u=EE(e.operator),d=u.toLowerCase();return"in"!==d&&"not in"!==d&&"between"!==d&&"not between"!==d||c?`${OE(e.field,{quoteFieldNamesWith:o,fieldIdentifierSeparator:a})} ${u} ${c}`.trim():""})(l,{parseNumbers:m,escapeQuotes:d,valueProcessor:r,quoteFieldNamesWith:a,fieldIdentifierSeparator:i,fieldData:f,format:n,quoteValuesWith:y,concatOperator:v})}));return 0===c.length?d:`${e.not?"NOT ":""}(${c.filter(Boolean).join(rE(e)?` ${e.combinator} `:" ")})`};return t(e,!0)}if("parameterized"===n||"parameterized_named"===n){const t="parameterized"===n,c=[],y={},w=new Map,_=e=>{w.has(e)||w.set(e,new Set);const t=`${e}_${w.get(e).size+1}`;return w.get(e).add(t),t},E=e=>{const[t,u]=S(e);if(!rS(e,t,u)||e.field===g||e.operator===b)return"";const E=bE(s,e.field),x=Object.fromEntries([...w.entries()].map((([e,t])=>[e,[...t]]))),k=("function"==typeof o?o:tS)(e,{getNextNamedParam:_,fieldParamNames:x,parseNumbers:m,quoteFieldNamesWith:a,concatOperator:v,fieldIdentifierSeparator:i,fieldData:E,format:n,paramPrefix:f,paramsKeepPrefix:p,numberedParams:h,fallbackExpression:d,valueProcessor:r,fields:s,placeholderFieldName:g,placeholderOperatorName:b,validator:l},{processedParams:c});if(!tE(k))return"";const{sql:R,params:C}=k;if("string"!=typeof R||!R)return"";if("parameterized"===n&&Array.isArray(C))c.push(...C);else if("parameterized_named"===n&&tE(C)){Object.assign(y,C);for(const t of Object.keys(C))w.get(e.field)?.add(t)}return R},x=(e,t)=>{if(!rS(e,u[e.id??""]))return t?d:"";const n=e.rules.map((t=>"string"==typeof t?t:nE(t)?x(t,1===e.rules.length):E(t)));return 0===n.length?d:`${e.not?"NOT ":""}(${n.filter(Boolean).join(rE(e)?` ${e.combinator} `:" ")})`};return t?{sql:x(e,!0),params:c}:{sql:x(e,!0),params:y}}if("mongodb"===n){const t=(e,a)=>{if(!rS(e,u[e.id??""]))return a?d:"";const i=`"$${e.combinator.toLowerCase()}"`;let l=!1;const c=e.rules.map((e=>{if(nE(e)){const n=t(e);return n?(l=!0,/^{.+}$/.test(n)?n:`{${n}}`):""}const[a,i]=S(e);if(!rS(e,a,i)||e.field===g||e.operator===b)return"";const c=bE(s,e.field);return(o??r)(e,{parseNumbers:m,fieldData:c,format:n})})).filter(Boolean);return c.length>0?1!==c.length||l?`${i}:[${c.join(",")}]`:c[0]:d},a=rE(e)?e:lE(e),i=t(a,!0);return/^{.+}$/.test(i)?i:`{${i}}`}if("cel"===n){const t=(e,a)=>{if(!rS(e,u[e.id??""]))return a?d:"";const i=e.rules.map((e=>{if("string"==typeof e)return xE[e];if(nE(e))return t(e);const[a,i]=S(e);if(!rS(e,a,i)||e.field===g||e.operator===b)return"";const l=bE(s,e.field);return(o??r)(e,{parseNumbers:m,escapeQuotes:"value"===(e.valueSource??"value"),fieldData:l,format:n})})).filter(Boolean).join(rE(e)?` ${xE[e.combinator]} `:" "),[l,c]=e.not||!a?[(e.not?"!":"")+"(",")"]:["",""];return i?`${l}${i}${c}`:d};return t(e,!0)}if("spel"===n){const t=(e,a)=>{if(!rS(e,u[e.id??""]))return a?d:"";const i=e.rules.map((e=>{if("string"==typeof e)return e;if(nE(e))return t(e);const[a,i]=S(e);if(!rS(e,a,i)||e.field===g||e.operator===b)return"";const l=bE(s,e.field);return(o??r)(e,{parseNumbers:m,escapeQuotes:"value"===(e.valueSource??"value"),fieldData:l,format:n})})).filter(Boolean).join(rE(e)?` ${e.combinator} `:" "),[l,c]=e.not||!a?[(e.not?"!":"")+"(",")"]:["",""];return i?`${l}${i}${c}`:d};return t(e,!0)}if("jsonata"===n){const t=(e,l)=>{if(!rS(e,u[e.id??""]))return l?d:"";const c=e.rules.map((e=>{if("string"==typeof e)return e;if(nE(e))return t(e);const[l,c]=S(e);if(!rS(e,l,c)||e.field===g||e.operator===b)return"";const u=bE(s,e.field);return(o??r)(e,{parseNumbers:m,escapeQuotes:"value"===(e.valueSource??"value"),fieldData:u,format:n,quoteFieldNamesWith:a,fieldIdentifierSeparator:i})})).filter(Boolean).join(rE(e)?` ${e.combinator} `:" "),[f,p]=e.not||!l?[(e.not?"$not":"")+"(",")"]:["",""];return c?`${f}${c}${p}`:d};return t(e,!0)}if("jsonlogic"===n){const t=rE(e)?e:lE(e),a=(e,t)=>{if(!rS(e,u[e.id??""]))return!1;const i=e.rules.map((e=>{if(nE(e))return a(e);const[t,i]=S(e);if(!rS(e,t,i)||e.field===g||e.operator===b)return!1;const l=bE(s,e.field);return(o??r)(e,{parseNumbers:m,fieldData:l,format:n})})).filter(Boolean);if(0===i.length)return!1;const l={[e.combinator]:i};return e.not?{"!":l}:l};return a(t,!0)}if("elasticsearch"===n){const t=rE(e)?e:lE(e),a=e=>{if(!rS(e,u[e.id??""]))return!1;const t=e.rules.map((e=>{if(nE(e))return a(e);const[t,i]=S(e);if(!rS(e,t,i)||e.field===g||e.operator===b)return!1;const l=bE(s,e.field);return(o??r)(e,{parseNumbers:m,fieldData:l,format:n})})).filter(Boolean);return 0!==t.length&&{bool:e.not?{must_not:"or"===e.combinator?{bool:{should:t}}:t}:{["or"===e.combinator?"should":"must"]:t}}},i=a(t);return!1===i?{}:i}if("natural_language"===n){const t=(e,l)=>{if(!rS(e,u[e.id??""]))return l?d:"";const f=e.rules.map((l=>{if("string"==typeof l)return`, ${l} `;if(nE(l))return t(l,1===e.rules.length);const[u,d]=S(l);if(!rS(l,u,d)||l.field===g||l.operator===b)return"";const f="value"===(l.valueSource??"value"),p=bE(s,l.field);return"function"==typeof o?o(l,{fields:s,parseNumbers:m,escapeQuotes:f,quoteFieldNamesWith:a,fieldIdentifierSeparator:i,fieldData:p,format:n,quoteValuesWith:y,concatOperator:v,getOperators:c}):aS(l,{fields:s,parseNumbers:m,escapeQuotes:f,valueProcessor:r,quoteFieldNamesWith:a,fieldIdentifierSeparator:i,fieldData:p,format:n,quoteValuesWith:y,concatOperator:v,getOperators:c})}));if(0===f.length)return d;const p=e.not||!l?"(":"",h=e.not||!l?`) is${e.not?" not":""} true`:"";return`${p}${f.filter(Boolean).join(rE(e)?`, ${e.combinator} `:"")}${h}`};return t(e,!0)}return""}var sS={default:zE,mongodb:jE,cel:TE,spel:FE},cS=e=>(t,n,r,o)=>sS[e]({field:t,operator:n,value:r,valueSource:o},{parseNumbers:!1}),uS=(cS("default"),cS("mongodb"),cS("cel"),cS("spel"),(e,t)=>{let n=t,r=0;for(;re.slice(0,-1),fS=(e,t)=>e.length===t.length&&e.every(((e,n)=>e===t[n])),pS=(e,t)=>{let n=!!t.disabled,r=t,o=0;for(;ofS([],e.path)?"Query builder":`Rule group at path ${e.path.join("-")}`,mS=globalThis.crypto,gS=()=>"00-0-4-2-000".replaceAll(/[^-]/g,(e=>(65536*(Math.random()+Math.trunc(e))>>parseInt(e)).toString(16).padStart(4,"0")));if(mS)if("function"==typeof mS.randomUUID)gS=()=>mS.randomUUID();else if("function"==typeof mS.getRandomValues){const e="89ab",t=new Uint32Array(32);gS=()=>{mS.getRandomValues(t);let n=(t[0]%16).toString(16);for(let r=1;r<32;r++)n=12===r?`${n}4`:16===r?`${n}${e[t[17]%4]}`:`${n}${(t[r]%16).toString(16)}`,7!==r&&11!==r&&15!==r&&19!==r||(n=`${n}-`);return n}}var bS=e=>{const t="boolean"==typeof e?e:"object"==typeof e&&null!==e?e.valid:null;return"boolean"==typeof t?t?n_:r_:""},yS=["value"],vS={name:"name",value:"name",valueSources:null,label:"label"},wS=(e,t)=>N_(t.map((t=>N_(t?.[e])))),_S=Object.keys,ES=Object.entries,SS=(e,t,n)=>{const r=ES(t).map((([t,[r,o]])=>[t,r??o??(n?Jw:{})[e]?.[t]])).filter((e=>!!e[1]));return r.length>0?{[e]:Object.fromEntries(r)}:void 0},xS=(e,{idGenerator:t=gS}={})=>Sw(e,(e=>{e.id||(e.id=t())})),kS=(e,{idGenerator:t=gS}={})=>Sw(e,(e=>{e.id||(e.id=t()),e.rules=e.rules.map((e=>"string"==typeof e?e:nE(e)?kS(e,{idGenerator:t}):xS(e,{idGenerator:t})))})),RS=(e,{idGenerator:t=gS}={})=>structuredClone({...e,id:t()}),CS=(e,{idGenerator:t=gS}={})=>{if(!tE(e))return e;if(!nE(e))return structuredClone({...e,id:t()});if(rE(e)){const n=e.rules.map((e=>nE(e)?CS(e,{idGenerator:t}):RS(e,{idGenerator:t})));return{...e,id:t(),rules:n}}const n=e.rules.map((e=>"string"==typeof e?e:nE(e)?CS(e,{idGenerator:t}):RS(e,{idGenerator:t})));return{...e,id:t(),rules:n}},NS=(e,t,n,{combinators:r=t_,combinatorPreceding:o,idGenerator:a=gS}={})=>Sw(e,(e=>{const i=uS(n,e);if(i&&nE(i)){if(oE(i)&&i.rules.length>0){const e=i.rules.at(-2);i.rules.push(o??("string"==typeof e?e:yE(r)))}i.rules.push(((e,{idGenerator:t=gS}={})=>nE(e)?kS(e,{idGenerator:t}):xS(e,{idGenerator:t}))(t,{idGenerator:a}))}})),OS=(e,t,n)=>((e,t,n)=>e?((e,t)=>!1!==e&&(!!e||!1!==t))(t,n):((e,t)=>!!e||!1!==e&&!!t)(t,n))(e,t,n),AS=()=>null,PS=(0,ht.forwardRef)(AS),DS={},TS={},IS={},jS=[],MS={},$S=()=>null,LS=()=>"",FS=()=>!0,zS=(...e)=>{console.log(...e)};function WS(e,t){const{query:n,defaultQuery:r,getValueEditorSeparator:o=$S,getRuleClassname:a=LS,getRuleGroupClassname:i=LS,onAddRule:l=FS,onAddGroup:s=FS,onMoveRule:c=FS,onMoveGroup:u=FS,onRemove:d=FS,onQueryChange:f,showCombinatorsBetweenRules:p=!1,showNotToggle:h=!1,showShiftActions:m=!1,showCloneButtons:g=!1,showLockButtons:b=!1,suppressStandardClassnames:y=!1,resetOnFieldChange:v=!0,resetOnOperatorChange:w=!1,autoSelectField:_=!0,autoSelectOperator:E=!0,addRuleToNewGroups:S=!1,listsAsArrays:x=!1,parseNumbers:k=!1,disabled:R=!1,validator:C,onLog:N=zS,idGenerator:O,accessibleDescriptionGenerator:A=hS}=e,{qbId:P,rqbContext:D,fields:T,fieldMap:I,combinators:j,getOperatorsMain:M,getRuleDefaultOperator:$,getValueEditorTypeMain:L,getValueSourcesMain:F,getValuesMain:z,getRuleDefaultValue:W,getInputTypeMain:G,createRule:B,createRuleGroup:V}=t,{controlClassnames:H,controlElements:U,debugMode:q,enableDragAndDrop:X,enableMountQueryChange:Y,translations:K}=D,Q=!!p,Z=!!h,J=!!m,ee=!!g,te=!!b,ne=!!v,re=!!w,oe=!!_,ae=!!E,ie=!!S,le=!!x,se=!!y,ce=(0,ht.useCallback)(((...e)=>{q&&N(...e)}),[q,N]);(e=>{U_();const{defaultQuery:t,queryProp:n}=e;(e=>{const t=(0,ht.useRef)({value:e,prev:null}),n=t.current.value;e!==n&&(t.current={value:e,prev:n}),t.current.prev})(!!n)})({defaultQuery:r,queryProp:n});const ue=q_(),de=U_(),fe=(0,ht.useMemo)((()=>V_(P)),[P]),pe=(e=>{const t=ht.useContext(HS);return B_(e,void 0)??t?.initialQuery})(fe),he=(0,ht.useCallback)((()=>fe(ue.getState())),[ue,fe]),me=(0,ht.useMemo)((()=>V()),[V]),ge=n??pe??r??me,be=ge.id?ge:kS(ge,{idGenerator:O}),[ye]=(0,ht.useState)(be),ve=(0,ht.useMemo)((()=>({...D,initialQuery:ye})),[D,ye]);(0,ht.useEffect)((()=>{n&&!Object.is(n,pe)&&de(H_({payload:{qbId:P,query:n},onQueryChange:void 0}))}),[n,P,pe,de]);const we=(0,ht.useMemo)((()=>oE(be)),[be]),_e=!!e.independentCombinators&&!we;Y_(0,_e||!_e&&e.independentCombinators);const Ee=(0,ht.useRef)(!1);(0,ht.useEffect)((()=>{Ee.current||(Ee.current=!0,de(H_({payload:{qbId:P,query:be},onQueryChange:Y&&"function"==typeof f?f:void 0})))}),[Y,f,P,de,be]);const Se=(0,ht.useCallback)((e=>{de(H_({payload:{qbId:P,query:e},onQueryChange:f}))}),[f,P,de]),xe=(0,ht.useMemo)((()=>Array.isArray(R)&&R||jS),[R]),ke=!0===R,Re=(0,ht.useMemo)((()=>be.disabled||xe.some((e=>0===e.length))),[xe,be.disabled]),Ce=(0,ht.useCallback)(((e,t,n)=>{const r=V_(P)(ue.getState());if(!r)return;if(pS(t,r)||ke)return void ce({qbId:P,type:x_,rule:e,parentPath:t,query:r});const o=l(e,t,r,n);if(!o)return void ce({qbId:P,type:"onAddRule callback returned false",rule:e,parentPath:t,query:r});const a=!0===o?e:o,i=NS(r,a,t,{combinators:j,combinatorPreceding:a.combinatorPreceding??void 0});ce({qbId:P,type:R_,query:r,newQuery:i,newRule:a,parentPath:t}),Se(i)}),[P,ue,ke,l,j,Se,ce]),Ne=(0,ht.useCallback)(((e,t,n)=>{const r=V_(P)(ue.getState());if(!r)return;if(pS(t,r)||ke)return void ce({qbId:P,type:x_,ruleGroup:e,parentPath:t,query:r});const o=s(e,t,r,n);if(!o)return void ce({qbId:P,type:"onAddGroup callback returned false",ruleGroup:e,parentPath:t,query:r});const a=!0===o?e:o,i=NS(r,a,t,{combinators:j,combinatorPreceding:a.combinatorPreceding??void 0});ce({qbId:P,type:R_,query:r,newQuery:i,newGroup:a,parentPath:t}),Se(i)}),[P,ue,ke,s,j,ce,Se]),Oe=(0,ht.useCallback)(((e,t,n)=>{const r=V_(P)(ue.getState());if(!r)return;if(pS(n,r)&&"disabled"!==e||ke)return void ce({qbId:P,type:k_,path:n,prop:e,value:t,query:r});const o=((e,t,n,r,{resetOnFieldChange:o=!0,resetOnOperatorChange:a=!1,getRuleDefaultOperator:i=()=>"=",getValueSources:l=()=>["value"],getRuleDefaultValue:s=()=>""}={})=>Sw(e,(e=>{if("combinator"===t&&!rE(e)){const t=uS(dS(r),e).rules;return void(r.at(-1)%2==1&&(t[r.at(-1)]=n))}const c=uS(r,e);if(!c)return;const u=nE(c);if(c[t]===n)return;if("valueSource"!==t&&(c[t]=n),u)return;let d=!1,f=!1;o&&"field"===t&&(c.operator=i(n),d=!0,f=!0),a&&"operator"===t&&(d=!0,f=!0);const p=l(c.field,c.operator)[0];(d&&c.valueSource&&p!==c.valueSource||"valueSource"===t&&n!==c.valueSource)&&(f=!!c.valueSource||!c.valueSource&&n!==p,c.valueSource=d?p:n),f&&(c.value=s(c))})))(r,e,t,n,{resetOnFieldChange:ne,resetOnOperatorChange:re,getRuleDefaultOperator:$,getValueSources:F,getRuleDefaultValue:W});ce({qbId:P,type:"rule or group updated",query:r,newQuery:o,prop:e,value:t,path:n}),Se(o)}),[P,ue,ke,ne,re,$,F,W,ce,Se]),Ae=(0,ht.useCallback)(((e,t)=>{const n=V_(P)(ue.getState());if(!n)return;if(pS(e,n)||ke)return void ce({qbId:P,type:k_,path:e,query:n});const r=uS(e,n);if(r)if(d(r,e,n,t)){const t=((e,t)=>0===t.length||!rE(e)&&!uS(t,e)?e:Sw(e,(e=>{const n=t.at(-1),r=uS(dS(t),e);if(r&&nE(r))if(!rE(r)&&r.rules.length>1){const e=0===n?0:n-1;r.rules.splice(e,2)}else r.rules.splice(n,1)})))(n,e);ce({qbId:P,type:"rule or group removed",query:n,newQuery:t,path:e,ruleOrGroup:r}),Se(t)}else ce({qbId:P,type:"onRemove callback returned false",ruleOrGroup:r,path:e,query:n})}),[P,ue,ke,ce,d,Se]),Pe=(0,ht.useCallback)(((e,t,n,r)=>{const o=V_(P)(ue.getState());if(!o)return;if(pS(e,o)||ke)return void ce({qbId:P,type:k_,oldPath:e,newPath:t,query:o});const a=((e,t,n,{clone:r=!1,combinators:o=t_,idGenerator:a=gS}={})=>{const i=((e,t,n)=>{if(Array.isArray(n))return n;const r=oE(e);if("up"===n){if(fS(t,[0]))return t;if(0===t.at(-1)){const e=dS(t);return[...dS(e),Math.max(0,e.at(-1)-(r?1:0))]}{const n=[...dS(t),Math.max(0,t.at(-1)-(r?2:1))],o=uS(n,e);return nE(o)?[...n,o.rules.length]:[...dS(t),Math.max(0,t.at(-1)-(r?3:1))]}}if("down"===n){if(fS([e.rules.length-1],t))return t;if(t.at(-1)===uS(dS(t),e).rules.length-1){const e=dS(t);return[...dS(e),e.at(-1)+1]}{const n=[...dS(t),t.at(-1)+(r?2:1)],o=uS(n,e);return nE(o)?[...n,0]:[...dS(t),t.at(-1)+(r?3:2)]}}return t})(e,t,n);if(0===t.length||fS(t,i)||!uS(dS(i),e))return e;const l=uS(t,e);if(!l)return e;const s=r?CS(l,{idGenerator:a}):l;return Sw(e,(e=>{const n=oE(e),a=uS(dS(t),e),l=t.at(-1),c=n&&l>0?a.rules[l-1]:null,u=n&&l{const n=[],r=dS(e),o=dS(t);let a=0;for(;at[f.length]&&(d[f.length]-=n?2:1);const p=dS(d),h=uS(p,e),m=d.at(-1),g=(...e)=>h.rules.splice(m,0,...e);if(0!==h.rules.length&&n)if(0===m)if(0===l&&u)g(s,u);else{const e=h.rules[1]??c??yE(o);g(s,e)}else g(c||(h.rules[m-2]??u??yE(o)),s);else g(s)}))})(o,e,t,{clone:n,combinators:j}),i=uS(e,o),l=nE(i),s=(l?u:c)(i,e,t,o,a,{clone:n,combinators:j},r);if(!s)return void ce({qbId:P,type:l?"onMoveGroup callback returned false":"onMoveRule callback returned false",ruleOrGroup:i,oldPath:e,newPath:t,clone:n,query:o,nextQuery:a});const d=nE(s)?s:a;ce({qbId:P,type:"rule or group moved",query:o,newQuery:d,oldPath:e,newPath:t,clone:n}),Se(d)}),[P,ue,ke,j,u,c,ce,Se]),{validationResult:De,validationMap:Te}=(0,ht.useMemo)((()=>{const e="function"==typeof C&&be?C(be):TS;return{validationResult:e,validationMap:"boolean"==typeof e?IS:e}}),[be,C]),Ie=(0,ht.useMemo)((()=>X?"enabled":"disabled"),[X]),je=(0,ht.useMemo)((()=>we||Q?"enabled":"disabled"),[we,Q]),Me=(0,ht.useMemo)((()=>"string"==typeof be.combinator?{combinator:be.combinator}:MS),[be.combinator]),$e=(0,ht.useMemo)((()=>N_(se||"queryBuilder",N_(H.queryBuilder),ke&&H.disabled,"boolean"==typeof De&&De&&H.valid,"boolean"==typeof De&&!De&&H.invalid,se||{[c_]:ke,[n_]:"boolean"==typeof De&&De,[r_]:"boolean"==typeof De&&!De})),[H.disabled,H.invalid,H.queryBuilder,H.valid,ke,se,De]),Le=(0,ht.useMemo)((()=>({addRuleToNewGroups:ie,accessibleDescriptionGenerator:A,autoSelectField:oe,autoSelectOperator:ae,classNames:H,combinators:j,controls:U,createRule:B,createRuleGroup:V,disabledPaths:xe,enableDragAndDrop:X,fieldMap:I,fields:T,dispatchQuery:Se,getQuery:he,getInputType:G,getOperators:M,getRuleClassname:a,getRuleGroupClassname:i,getValueEditorSeparator:o,getValueEditorType:L,getValues:z,getValueSources:F,independentCombinators:we,listsAsArrays:le,parseNumbers:k,qbId:P,showCloneButtons:ee,showCombinatorsBetweenRules:Q,showLockButtons:te,showNotToggle:Z,showShiftActions:J,suppressStandardClassnames:se,validationMap:Te})),[A,ie,oe,ae,j,H,U,B,V,xe,Se,X,I,T,G,M,he,a,i,o,L,z,F,we,le,k,P,ee,Q,te,Z,J,se,Te]);return{actions:(0,ht.useMemo)((()=>({moveRule:Pe,onGroupAdd:Ne,onGroupRemove:Ae,onPropChange:Oe,onRuleAdd:Ce,onRuleRemove:Ae})),[Pe,Ne,Oe,Ce,Ae]),rootGroup:be,rootGroupDisabled:Re,queryDisabled:ke,rqbContext:ve,schema:Le,translations:K,wrapperClassName:$e,dndEnabledAttr:Ie,inlineCombinatorsAttr:je,combinatorPropObject:Me}}var GS=(e,t,n)=>{const r=yE(e);if("between"===t.operator||"notBetween"===t.operator){const e=[r,r];return n?e:Q_(e.map((e=>e??"")),",")}return r},BS=e=>{const[t]=(0,ht.useState)(gS),{fields:n,baseField:r,operators:o,baseOperator:a,combinators:i=t_,baseCombinator:l,translations:s,enableMountQueryChange:c=!0,controlClassnames:u,controlElements:d,getDefaultField:f,getDefaultOperator:p,getDefaultValue:h,getOperators:m,getValueEditorType:g,getValueSources:b,getInputType:y,getValues:v,autoSelectField:w=!0,autoSelectOperator:_=!0,addRuleToNewGroups:E=!1,enableDragAndDrop:S,listsAsArrays:x=!1,debugMode:k=!1,idGenerator:R=gS}=e,C=o??e_,[N]=(0,ht.useState)(e.query??e.defaultQuery),O=(({finalize:e,...t})=>{const n=(0,ht.useContext)(HS),r=OS(!1,t.debugMode,n.debugMode),o=e?r:t.debugMode??n.debugMode,a=OS(!0,t.enableMountQueryChange,n.enableMountQueryChange),i=e?a:t.enableMountQueryChange??n.enableMountQueryChange,l=OS(!1,t.enableDragAndDrop,n.enableDragAndDrop)&&!1!==n.enableDragAndDrop,s=e?l:t.enableDragAndDrop??n.enableDragAndDrop,c=(0,ht.useMemo)((()=>((...e)=>({queryBuilder:wS("queryBuilder",e),ruleGroup:wS("ruleGroup",e),header:wS("header",e),body:wS("body",e),combinators:wS("combinators",e),addRule:wS("addRule",e),addGroup:wS("addGroup",e),cloneRule:wS("cloneRule",e),cloneGroup:wS("cloneGroup",e),removeGroup:wS("removeGroup",e),rule:wS("rule",e),fields:wS("fields",e),operators:wS("operators",e),value:wS("value",e),removeRule:wS("removeRule",e),notToggle:wS("notToggle",e),shiftActions:wS("shiftActions",e),dragHandle:wS("dragHandle",e),lockRule:wS("lockRule",e),lockGroup:wS("lockGroup",e),valueSource:wS("valueSource",e),actionElement:wS("actionElement",e),valueSelector:wS("valueSelector",e),betweenRules:wS("betweenRules",e),valid:wS("valid",e),invalid:wS("invalid",e),dndDragging:wS("dndDragging",e),dndOver:wS("dndOver",e),dndCopy:wS("dndCopy",e),disabled:wS("disabled",e),valueListItem:wS("valueListItem",e),branches:wS("branches",e)}))(e?Object.assign({},d_):DS,n.controlClassnames,t.controlClassnames)),[n.controlClassnames,t.controlClassnames,e]),u=(0,ht.useMemo)((()=>({actionElement:c.actionElement,addGroup:c.addGroup,addRule:c.addRule,body:c.body,cloneGroup:c.cloneGroup,cloneRule:c.cloneRule,combinators:c.combinators,dragHandle:c.dragHandle,fields:c.fields,header:c.header,lockGroup:c.lockGroup,lockRule:c.lockRule,notToggle:c.notToggle,operators:c.operators,queryBuilder:c.queryBuilder,removeGroup:c.removeGroup,removeRule:c.removeRule,rule:c.rule,ruleGroup:c.ruleGroup,shiftActions:c.shiftActions,value:c.value,valueSelector:c.valueSelector,valueSource:c.valueSource,betweenRules:c.betweenRules,valid:c.valid,invalid:c.invalid,dndDragging:c.dndDragging,dndOver:c.dndOver,dndCopy:c.dndCopy,disabled:c.disabled,valueListItem:c.valueListItem,branches:c.branches})),[c.actionElement,c.addGroup,c.addRule,c.betweenRules,c.body,c.branches,c.cloneGroup,c.cloneRule,c.combinators,c.disabled,c.dndCopy,c.dndDragging,c.dndOver,c.dragHandle,c.fields,c.header,c.invalid,c.lockGroup,c.lockRule,c.notToggle,c.operators,c.queryBuilder,c.removeGroup,c.removeRule,c.rule,c.ruleGroup,c.shiftActions,c.valid,c.value,c.valueListItem,c.valueSelector,c.valueSource]),d=n.controlElements??DS,f=t.controlElements??DS,p=(0,ht.useCallback)(((t,n,r)=>{const o="dragHandle"===t?PS:AS,a=(t.endsWith("Action")&&f.actionElement?f.actionElement:void 0)??(t.endsWith("Selector")&&f.valueSelector?f.valueSelector:void 0),i=(t.endsWith("Action")&&d.actionElement?d.actionElement:void 0)??(t.endsWith("Selector")&&d.valueSelector?d.valueSelector:void 0),l=null===n?o:n??(e?a:void 0)??(null===r?o:r??(e?i:void 0));return l?{[t]:l}:e?{[t]:nx[t]}:DS}),[d.actionElement,d.valueSelector,e,f.actionElement,f.valueSelector]),h=(0,ht.useMemo)((()=>Object.assign({},p("addGroupAction",f.addGroupAction,d.addGroupAction),p("addRuleAction",f.addRuleAction,d.addRuleAction),p("cloneGroupAction",f.cloneGroupAction,d.cloneGroupAction),p("cloneRuleAction",f.cloneRuleAction,d.cloneRuleAction),p("combinatorSelector",f.combinatorSelector,d.combinatorSelector),p("dragHandle",f.dragHandle,d.dragHandle),p("fieldSelector",f.fieldSelector,d.fieldSelector),p("inlineCombinator",f.inlineCombinator,d.inlineCombinator),p("lockGroupAction",f.lockGroupAction,d.lockGroupAction),p("lockRuleAction",f.lockRuleAction,d.lockRuleAction),p("notToggle",f.notToggle,d.notToggle),p("operatorSelector",f.operatorSelector,d.operatorSelector),p("removeGroupAction",f.removeGroupAction,d.removeGroupAction),p("removeRuleAction",f.removeRuleAction,d.removeRuleAction),p("shiftActions",f.shiftActions,d.shiftActions),{valueEditor:null===f.valueEditor?AS:f.valueEditor??(null===d.valueEditor?AS:d.valueEditor)??nx.valueEditor},p("valueSourceSelector",f.valueSourceSelector,d.valueSourceSelector),p("rule",f.rule,d.rule),p("ruleGroup",f.ruleGroup,d.ruleGroup),p("ruleGroupBodyElements",f.ruleGroupBodyElements,d.ruleGroupBodyElements),p("ruleGroupHeaderElements",f.ruleGroupHeaderElements,d.ruleGroupHeaderElements),{actionElement:f.actionElement??d.actionElement??(e?nx.actionElement:void 0)},{valueSelector:f.valueSelector??d.valueSelector??(e?nx.valueSelector:void 0)})),[d.actionElement,d.addGroupAction,d.addRuleAction,d.cloneGroupAction,d.cloneRuleAction,d.combinatorSelector,d.dragHandle,d.fieldSelector,d.inlineCombinator,d.lockGroupAction,d.lockRuleAction,d.notToggle,d.operatorSelector,d.removeGroupAction,d.removeRuleAction,d.rule,d.ruleGroup,d.ruleGroupBodyElements,d.ruleGroupHeaderElements,d.shiftActions,d.valueEditor,d.valueSelector,d.valueSourceSelector,p,e,f.actionElement,f.addGroupAction,f.addRuleAction,f.cloneGroupAction,f.cloneRuleAction,f.combinatorSelector,f.dragHandle,f.fieldSelector,f.inlineCombinator,f.lockGroupAction,f.lockRuleAction,f.notToggle,f.operatorSelector,f.removeGroupAction,f.removeRuleAction,f.rule,f.ruleGroup,f.ruleGroupBodyElements,f.ruleGroupHeaderElements,f.shiftActions,f.valueEditor,f.valueSelector,f.valueSourceSelector]),m=t.translations??DS,g=n.translations??DS;return{controlClassnames:u,controlElements:h,debugMode:o,enableDragAndDrop:s,enableMountQueryChange:i,translations:(0,ht.useMemo)((()=>Object.assign(e?Object.assign({},Jw):{},SS("addGroup",{label:[m.addGroup?.label,g.addGroup?.label],title:[m.addGroup?.title,g.addGroup?.title]},e),SS("addRule",{label:[m.addRule?.label,g.addRule?.label],title:[m.addRule?.title,g.addRule?.title]},e),SS("cloneRule",{label:[m.cloneRule?.label,g.cloneRule?.label],title:[m.cloneRule?.title,g.cloneRule?.title]},e),SS("cloneRuleGroup",{label:[m.cloneRuleGroup?.label,g.cloneRuleGroup?.label],title:[m.cloneRuleGroup?.title,g.cloneRuleGroup?.title]},e),SS("combinators",{title:[m.combinators?.title,g.combinators?.title]},e),SS("dragHandle",{label:[m.dragHandle?.label,g.dragHandle?.label],title:[m.dragHandle?.title,g.dragHandle?.title]},e),SS("fields",{placeholderGroupLabel:[m.fields?.placeholderGroupLabel,g.fields?.placeholderGroupLabel],placeholderLabel:[m.fields?.placeholderLabel,g.fields?.placeholderLabel],placeholderName:[m.fields?.placeholderName,g.fields?.placeholderName],title:[m.fields?.title,g.fields?.title]},e),SS("lockGroup",{label:[m.lockGroup?.label,g.lockGroup?.label],title:[m.lockGroup?.title,g.lockGroup?.title]},e),SS("lockGroupDisabled",{label:[m.lockGroupDisabled?.label,g.lockGroupDisabled?.label],title:[m.lockGroupDisabled?.title,g.lockGroupDisabled?.title]},e),SS("lockRule",{label:[m.lockRule?.label,g.lockRule?.label],title:[m.lockRule?.title,g.lockRule?.title]},e),SS("lockRuleDisabled",{label:[m.lockRuleDisabled?.label,g.lockRuleDisabled?.label],title:[m.lockRuleDisabled?.title,g.lockRuleDisabled?.title]},e),SS("notToggle",{label:[m.notToggle?.label,g.notToggle?.label],title:[m.notToggle?.title,g.notToggle?.title]},e),SS("operators",{placeholderGroupLabel:[m.operators?.placeholderGroupLabel,g.operators?.placeholderGroupLabel],placeholderLabel:[m.operators?.placeholderLabel,g.operators?.placeholderLabel],placeholderName:[m.operators?.placeholderName,g.operators?.placeholderName],title:[m.operators?.title,g.operators?.title]},e),SS("removeGroup",{label:[m.removeGroup?.label,g.removeGroup?.label],title:[m.removeGroup?.title,g.removeGroup?.title]},e),SS("removeRule",{label:[m.removeRule?.label,g.removeRule?.label],title:[m.removeRule?.title,g.removeRule?.title]},e),SS("shiftActionDown",{label:[m.shiftActionDown?.label,g.shiftActionDown?.label],title:[m.shiftActionDown?.title,g.shiftActionDown?.title]},e),SS("shiftActionUp",{label:[m.shiftActionUp?.label,g.shiftActionUp?.label],title:[m.shiftActionUp?.title,g.shiftActionUp?.title]},e),SS("value",{title:[m.value?.title,g.value?.title]},e),SS("valueSourceSelector",{title:[m.valueSourceSelector?.title,g.valueSourceSelector?.title]},e))),[m.addGroup?.label,m.addGroup?.title,m.addRule?.label,m.addRule?.title,m.cloneRule?.label,m.cloneRule?.title,m.cloneRuleGroup?.label,m.cloneRuleGroup?.title,m.combinators?.title,m.dragHandle?.label,m.dragHandle?.title,m.fields?.placeholderGroupLabel,m.fields?.placeholderLabel,m.fields?.placeholderName,m.fields?.title,m.lockGroup?.label,m.lockGroup?.title,m.lockGroupDisabled?.label,m.lockGroupDisabled?.title,m.lockRule?.label,m.lockRule?.title,m.lockRuleDisabled?.label,m.lockRuleDisabled?.title,m.notToggle?.label,m.notToggle?.title,m.operators?.placeholderGroupLabel,m.operators?.placeholderLabel,m.operators?.placeholderName,m.operators?.title,m.removeGroup?.label,m.removeGroup?.title,m.removeRule?.label,m.removeRule?.title,m.shiftActionDown?.label,m.shiftActionDown?.title,m.shiftActionUp?.label,m.shiftActionUp?.title,m.value?.title,m.valueSourceSelector?.title,e,g.addGroup?.label,g.addGroup?.title,g.addRule?.label,g.addRule?.title,g.cloneRule?.label,g.cloneRule?.title,g.cloneRuleGroup?.label,g.cloneRuleGroup?.title,g.combinators?.title,g.dragHandle?.label,g.dragHandle?.title,g.fields?.placeholderGroupLabel,g.fields?.placeholderLabel,g.fields?.placeholderName,g.fields?.title,g.lockGroup?.label,g.lockGroup?.title,g.lockGroupDisabled?.label,g.lockGroupDisabled?.title,g.lockRule?.label,g.lockRule?.title,g.lockRuleDisabled?.label,g.lockRuleDisabled?.title,g.notToggle?.label,g.notToggle?.title,g.operators?.placeholderGroupLabel,g.operators?.placeholderLabel,g.operators?.placeholderName,g.operators?.title,g.removeGroup?.label,g.removeGroup?.title,g.removeRule?.label,g.removeRule?.title,g.shiftActionDown?.label,g.shiftActionDown?.title,g.shiftActionUp?.label,g.shiftActionUp?.title,g.value?.title,g.valueSourceSelector?.title]),initialQuery:t.initialQuery,qbId:t.qbId}})({controlClassnames:u,controlElements:d,debugMode:k,enableDragAndDrop:S,enableMountQueryChange:c,translations:s,initialQuery:N,qbId:t,finalize:!0}),{translations:A}=O,P=(0,ht.useMemo)((()=>({id:A.fields.placeholderName,name:A.fields.placeholderName,value:A.fields.placeholderName,label:A.fields.placeholderLabel})),[A.fields.placeholderLabel,A.fields.placeholderName]),D=(0,ht.useMemo)((()=>n??[P]),[P,n]),T=(0,ht.useMemo)((()=>{const e=Array.isArray(D)?dE(D,r):_S(fE(D,r)).map((e=>({...D[e],name:e,value:e}))).sort(((e,t)=>e.label.localeCompare(t.label)));return gE(e)?hE(w?e:[{label:A.fields.placeholderGroupLabel,options:[P]},...e]):pE(w?e:[P,...e])}),[w,r,P,D,A.fields.placeholderGroupLabel]),I=(0,ht.useMemo)((()=>{if(!Array.isArray(D)){const e=fE(D,r);return w?e:{...e,[A.fields.placeholderName]:P}}const e={};if(gE(T))for(const t of T)for(const n of t.options)e[n.value??n.name]=uE(n,r);else for(const t of T)e[t.value??t.name]=uE(t,r);return e}),[w,r,P,T,D,A.fields.placeholderName]),j=(0,ht.useMemo)((()=>dE(i,l)),[l,i]),M=(0,ht.useMemo)((()=>({id:A.operators.placeholderName,name:A.operators.placeholderName,value:A.operators.placeholderName,label:A.operators.placeholderLabel})),[A.operators.placeholderLabel,A.operators.placeholderName]),$=(0,ht.useCallback)(((e,{fieldData:t})=>{let n=dE(C,a);if(t?.operators)n=dE(t.operators,a);else if(m){const r=m(e,{fieldData:t});r&&(n=dE(r,a))}return _||(n=gE(n)?[{label:A.operators.placeholderGroupLabel,options:[M]},...n]:[M,...n]),gE(r=n)?hE(r):pE(r.map((e=>uE(e))));var r}),[_,a,M,m,C,A.operators.placeholderGroupLabel]),L=(0,ht.useCallback)((e=>{const t=I[e];if(t?.defaultOperator)return t.defaultOperator;if(p)return"function"==typeof p?p(e,{fieldData:t}):p;const n=$(e,{fieldData:t})??[];return yE(n)??""}),[I,p,$]),F=(0,ht.useCallback)(((e,t,{fieldData:n})=>n.valueEditorType?"function"==typeof n.valueEditorType?n.valueEditorType(t):n.valueEditorType:g?.(e,t,{fieldData:n})??"text"),[g]),z=(0,ht.useCallback)(((e,t)=>((e,t,n)=>{const r=e?uE(e):vS;if(r.valueSources)return"function"==typeof r.valueSources?r.valueSources(t):r.valueSources;if(n){const e=n(r.value,t,{fieldData:uE(r)});if(e)return e}return yS})(I[e],t,b)),[I,b]),W=(0,ht.useCallback)(((e,t,{fieldData:n})=>n?.values?dE(n.values):v?dE(v(e,t,{fieldData:n})):[]),[v]),G=(0,ht.useCallback)((e=>{const t=I[e.field]??{};if(void 0!==t?.defaultValue&&null!==t.defaultValue)return t.defaultValue;if(h)return h(e,{fieldData:t});let n="";const r=W(e.field,e.operator,{fieldData:t});if("field"===e.valueSource){const r=wE(t,T,e.operator);n=r.length>0?GS(r,e,x):""}else if(r.length>0){const o=F(e.field,e.operator,{fieldData:t});"multiselect"===o?n=x?[]:"":"select"!==o&&"radio"!==o||(n=GS(r,e,x))}else"checkbox"===F(e.field,e.operator,{fieldData:t})&&(n=!1);return n}),[I,T,h,F,W,x]),B=(0,ht.useCallback)(((e,t,{fieldData:n})=>{if(y){const r=y(e,t,{fieldData:n});if(r)return r}return"text"}),[y]),V=(0,ht.useCallback)((()=>{let e="";const t=T;if(t?.length>0&&t[0]){const n=yE(t);n&&(e=n)}if(f)if("function"==typeof f){const n=f(t);n&&(e=n)}else e=f;const n=L(e),r=z(e,n)[0]??"value",o={id:R(),field:e,operator:n,valueSource:r,value:""},a=G(o);return{...o,value:a}}),[T,f,L,G,z,R]),H=(0,ht.useCallback)((e=>e?{id:R(),rules:E?[V()]:[],not:!1}:{id:R(),rules:E?[V()]:[],combinator:yE(j)??"",not:!1}),[E,j,V,R]);return{qbId:t,rqbContext:O,fields:T,fieldMap:I,combinators:j,getOperatorsMain:$,getRuleDefaultOperator:L,getValueEditorTypeMain:F,getValueSourcesMain:z,getValuesMain:W,getRuleDefaultValue:G,getInputTypeMain:B,createRule:V,createRuleGroup:H}},VS=e=>(0,ht.useCallback)(((t,n)=>{t?.preventDefault(),t?.stopPropagation(),e(t,n)}),[e]),HS=(0,ht.createContext)({}),US=[],qS=e=>ht.createElement(_v,{context:G_,store:W_},e.children),XS=({props:e})=>{const t=(e=>WS(e,BS(e)))(e),n=t.schema.controls.ruleGroup,r=HS;return ht.createElement(r.Provider,{key:t.dndEnabledAttr,value:t.rqbContext},ht.createElement("div",{role:"form",className:t.wrapperClassName,"data-dnd":t.dndEnabledAttr,"data-inlinecombinators":t.inlineCombinatorsAttr},ht.createElement(n,{translations:t.translations,ruleGroup:t.rootGroup,rules:t.rootGroup.rules,...t.combinatorPropObject,not:!!t.rootGroup.not,schema:t.schema,actions:t.actions,id:t.rootGroup.id,path:US,disabled:t.rootGroupDisabled,shiftUpDisabled:!0,shiftDownDisabled:!0,parentDisabled:t.queryDisabled,context:e.context})))},YS=e=>ht.createElement(qS,null,ht.createElement(XS,{props:e})),KS=ht.memo((e=>{const t=(e=>{const{id:t,path:n,rule:r,schema:{classNames:o,fields:a,fieldMap:i,getInputType:l,getOperators:s,getValueEditorType:c,getValueEditorSeparator:u,getValueSources:d,getValues:f,validationMap:p,enableDragAndDrop:h,getRuleClassname:m,suppressStandardClassnames:g},actions:{moveRule:b,onPropChange:y,onRuleRemove:v},disabled:w,parentDisabled:_,shiftUpDisabled:E,shiftDownDisabled:S,field:x,operator:k,value:R,valueSource:C,dropEffect:N="move",dragMonitorId:O="",dropMonitorId:A="",dndRef:P=null,dragRef:D=null,isDragging:T=!1,isOver:I=!1}=e;Y_();const j=!!_||!!w,M=(0,ht.useMemo)((()=>r??{id:t,field:x??"",operator:k??"",value:R,valueSource:C}),[x,t,k,r,R,C]),$=(0,ht.useMemo)((()=>({shiftActions:N_(g||o_,o.shiftActions),dragHandle:N_(g||s_,o.dragHandle),fields:N_(g||"rule-fields",o.valueSelector,o.fields),operators:N_(g||"rule-operators",o.valueSelector,o.operators),valueSource:N_(g||"rule-valueSource",o.valueSelector,o.valueSource),value:N_(g||"rule-value",o.value),cloneRule:N_(g||"rule-cloneRule",o.actionElement,o.cloneRule),lockRule:N_(g||"rule-lock",o.actionElement,o.lockRule),removeRule:N_(g||"rule-remove",o.actionElement,o.removeRule),valueListItem:N_(g||u_,o.valueListItem)})),[o.shiftActions,o.dragHandle,o.valueSelector,o.fields,o.operators,o.valueSource,o.value,o.actionElement,o.cloneRule,o.lockRule,o.removeRule,o.valueListItem,g]),L=(0,ht.useCallback)((e=>(t,r)=>{j||y(e,t,n)}),[j,y,n]),F=(0,ht.useCallback)((()=>{if(!j){const e=[...dS(n),n.at(-1)+1];b(n,e,!0)}}),[j,b,n]),z=(0,ht.useCallback)(((e,t)=>{y("disabled",!j,n)}),[j,y,n]),W=(0,ht.useCallback)(((e,t)=>{j||v(n)}),[j,v,n]),G=(0,ht.useCallback)(((e,t)=>{j||E||b(n,"up",e?.altKey)}),[j,b,n,E]),B=(0,ht.useCallback)(((e,t)=>{j||S||b(n,"down",e?.altKey)}),[j,b,n,S]),V=(0,ht.useMemo)((()=>i?.[M.field]??{name:M.field,value:M.field,label:M.field}),[i,M.field]),H=(0,ht.useMemo)((()=>V.inputType??l(M.field,M.operator,{fieldData:V})),[V,l,M.field,M.operator]),U=(0,ht.useMemo)((()=>s(M.field,{fieldData:V})),[V,s,M.field]),q=(0,ht.useMemo)((()=>bE(U,M.operator)),[U,M.operator]),X=q?.arity,Y="string"==typeof X&&"unary"===X||"number"==typeof X&&X<2,K=(0,ht.useMemo)((()=>"function"==typeof V.valueSources?V.valueSources(M.operator):V.valueSources??d(M.field,M.operator,{fieldData:V})),[V,d,M.field,M.operator]),Q=(0,ht.useMemo)((()=>"field"===M.valueSource?"select":c(M.field,M.operator,{fieldData:V})),[V,c,M.field,M.operator,M.valueSource]),Z=(0,ht.useMemo)((()=>u(M.field,M.operator,{fieldData:V})),[V,u,M.field,M.operator]),J=(0,ht.useMemo)((()=>"field"===M.valueSource?wE(V,a,M.operator):V.values??f(M.field,M.operator,{fieldData:V})),[V,a,f,M.field,M.operator,M.valueSource]),ee=(0,ht.useMemo)((()=>K.map((e=>({name:e,value:e,label:e})))),[K]),te=(0,ht.useMemo)((()=>p[t??""]??("function"==typeof V.validator?V.validator(M):null)),[V,t,M,p]),ne=(0,ht.useMemo)((()=>bS(te)),[te]),re=(0,ht.useMemo)((()=>V?.className??""),[V?.className]),oe=(0,ht.useMemo)((()=>q?.className??""),[q?.className]),ae=(0,ht.useMemo)((()=>N_(m(M,{fieldData:V}),re,oe,g||"rule",o.rule,j&&o.disabled,T&&o.dndDragging,I&&o.dndOver,I&&"copy"===N&&o.dndCopy,g||{[c_]:j,[a_]:T,[i_]:I,[l_]:I&&"copy"===N},ne)),[o.disabled,o.dndCopy,o.dndDragging,o.dndOver,o.rule,j,N,re,V,m,T,I,oe,M,g,ne]);return{...e,classNames:$,cloneRule:F,disabled:j,dndRef:P,dragMonitorId:O,dragRef:D,dropMonitorId:A,fieldData:V,generateOnChangeHandler:L,hideValueControls:Y,inputType:H,operators:U,outerClassName:ae,removeRule:W,rule:M,shiftRuleUp:G,shiftRuleDown:B,toggleLockRule:z,validationResult:te,valueEditorSeparator:Z,valueEditorType:Q,values:J,valueSourceOptions:ee,valueSources:K}})(e),n=VS(t.cloneRule),r=VS(t.toggleLockRule),o=VS(t.removeRule),a=VS(t.shiftRuleUp),i=VS(t.shiftRuleDown);return ht.createElement("div",{ref:t.dndRef,"data-testid":f_,"data-dragmonitorid":t.dragMonitorId,"data-dropmonitorid":t.dropMonitorId,className:t.outerClassName,"data-rule-id":t.id,"data-level":t.path.length,"data-path":JSON.stringify(t.path)},ht.createElement(QS,{...t,cloneRule:n,toggleLockRule:r,removeRule:o,shiftRuleUp:a,shiftRuleDown:i}))})),QS=ht.memo((e=>{const{schema:{controls:{shiftActions:t,dragHandle:n,fieldSelector:r,operatorSelector:o,valueSourceSelector:a,valueEditor:i,cloneRuleAction:l,lockRuleAction:s,removeRuleAction:c}}}=e;return ht.createElement(ht.Fragment,null,e.schema.showShiftActions&&ht.createElement(t,{testID:__,level:e.path.length,path:e.path,titles:{shiftUp:e.translations.shiftActionUp.title,shiftDown:e.translations.shiftActionDown.title},labels:{shiftUp:e.translations.shiftActionUp.label,shiftDown:e.translations.shiftActionDown.label},className:e.classNames.shiftActions,disabled:e.disabled,shiftUp:e.shiftRuleUp,shiftDown:e.shiftRuleDown,shiftUpDisabled:e.shiftUpDisabled,shiftDownDisabled:e.shiftDownDisabled,context:e.context,validation:e.validationResult,schema:e.schema,ruleOrGroup:e.rule}),e.schema.enableDragAndDrop&&ht.createElement(n,{testID:E_,ref:e.dragRef,level:e.path.length,path:e.path,title:e.translations.dragHandle.title,label:e.translations.dragHandle.label,className:e.classNames.dragHandle,disabled:e.disabled,context:e.context,validation:e.validationResult,schema:e.schema,ruleOrGroup:e.rule}),ht.createElement(r,{testID:"fields",options:e.schema.fields,title:e.translations.fields.title,value:e.rule.field,operator:e.rule.operator,className:e.classNames.fields,handleOnChange:e.generateOnChangeHandler("field"),level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,schema:e.schema,rule:e.rule}),(e.schema.autoSelectField||e.rule.field!==e.translations.fields.placeholderName)&&ht.createElement(ht.Fragment,null,ht.createElement(o,{testID:"operators",field:e.rule.field,fieldData:e.fieldData,title:e.translations.operators.title,options:e.operators,value:e.rule.operator,className:e.classNames.operators,handleOnChange:e.generateOnChangeHandler("operator"),level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,schema:e.schema,rule:e.rule}),(e.schema.autoSelectOperator||e.rule.operator!==e.translations.operators.placeholderName)&&!e.hideValueControls&&ht.createElement(ht.Fragment,null,!["null","notNull"].includes(e.rule.operator)&&e.valueSources.length>1&&ht.createElement(a,{testID:"value-source-selector",field:e.rule.field,fieldData:e.fieldData,title:e.translations.valueSourceSelector.title,options:e.valueSourceOptions,value:e.rule.valueSource??"value",className:e.classNames.valueSource,handleOnChange:e.generateOnChangeHandler("valueSource"),level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,schema:e.schema,rule:e.rule}),ht.createElement(i,{testID:"value-editor",field:e.rule.field,fieldData:e.fieldData,title:e.translations.value.title,operator:e.rule.operator,value:e.rule.value,valueSource:e.rule.valueSource??"value",type:e.valueEditorType,inputType:e.inputType,values:e.values,listsAsArrays:e.schema.listsAsArrays,parseNumbers:e.schema.parseNumbers,separator:e.valueEditorSeparator,className:e.classNames.value,handleOnChange:e.generateOnChangeHandler("value"),level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,schema:e.schema,rule:e.rule}))),e.schema.showCloneButtons&&ht.createElement(l,{testID:"clone-rule",label:e.translations.cloneRule.label,title:e.translations.cloneRule.title,className:e.classNames.cloneRule,handleOnClick:e.cloneRule,level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,ruleOrGroup:e.rule,schema:e.schema}),e.schema.showLockButtons&&ht.createElement(s,{testID:"lock-rule",label:e.translations.lockRule.label,title:e.translations.lockRule.title,className:e.classNames.lockRule,handleOnClick:e.toggleLockRule,level:e.path.length,path:e.path,disabled:e.disabled,disabledTranslation:e.parentDisabled?void 0:e.translations.lockRuleDisabled,context:e.context,validation:e.validationResult,ruleOrGroup:e.rule,schema:e.schema}),ht.createElement(c,{testID:"remove-rule",label:e.translations.removeRule.label,title:e.translations.removeRule.title,className:e.classNames.removeRule,handleOnClick:e.removeRule,level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,ruleOrGroup:e.rule,schema:e.schema}))})),ZS=ht.memo((e=>{const t=(e=>{const{id:t,path:n,ruleGroup:r,schema:{qbId:o,accessibleDescriptionGenerator:a,classNames:i,combinators:l,createRule:s,createRuleGroup:c,disabledPaths:u,independentCombinators:d,validationMap:f,enableDragAndDrop:p,getRuleGroupClassname:h,suppressStandardClassnames:m},actions:{onGroupAdd:g,onGroupRemove:b,onPropChange:y,onRuleAdd:v,moveRule:w},disabled:_,parentDisabled:E,shiftUpDisabled:S,shiftDownDisabled:x,combinator:k,rules:R,not:C,dropEffect:N="move",dragMonitorId:O="",dropMonitorId:A="",previewRef:P=null,dragRef:D=null,dropRef:T=null,isDragging:I=!1,isOver:j=!1}=e;Y_();const M=!!E||!!_,$=(0,ht.useMemo)((()=>r&&rE(r)?r.combinator:r?yE(l):k??yE(l)),[k,l,r]),L=(0,ht.useMemo)((()=>{if(r){if(r.combinator===$||d)return r;const e=structuredClone(r);return e.combinator=$,e}return{rules:R,not:C}}),[$,d,C,r,R]),F=(0,ht.useMemo)((()=>({header:N_(m||"ruleGroup-header",i.header,j&&"copy"===N&&i.dndCopy,m||{[i_]:j,[l_]:j&&"copy"===N}),shiftActions:N_(m||o_,i.shiftActions),dragHandle:N_(m||s_,i.dragHandle),combinators:N_(m||"ruleGroup-combinators",i.valueSelector,i.combinators),notToggle:N_(m||"ruleGroup-notToggle",i.notToggle),addRule:N_(m||"ruleGroup-addRule",i.actionElement,i.addRule),addGroup:N_(m||"ruleGroup-addGroup",i.actionElement,i.addGroup),cloneGroup:N_(m||"ruleGroup-cloneGroup",i.actionElement,i.cloneGroup),lockGroup:N_(m||"ruleGroup-lock",i.actionElement,i.lockGroup),removeGroup:N_(m||"ruleGroup-remove",i.actionElement,i.removeGroup),body:N_(m||"ruleGroup-body",i.body)})),[i.actionElement,i.addGroup,i.addRule,i.body,i.cloneGroup,i.combinators,i.dndCopy,i.dragHandle,i.header,i.lockGroup,i.notToggle,i.removeGroup,i.shiftActions,i.valueSelector,N,j,m]),z=(0,ht.useCallback)((e=>{M||y("combinator",e,n)}),[M,y,n]),W=(0,ht.useCallback)(((e,t,r)=>{M||y("combinator",e,[...n,t])}),[M,y,n]),G=(0,ht.useCallback)(((e,t)=>{M||y("not",e,n)}),[M,y,n]),B=(0,ht.useCallback)(((e,t)=>{if(!M){const e=s();v(e,n,t)}}),[s,M,v,n]),V=(0,ht.useCallback)(((e,t)=>{if(!M){const e=c(d);g(e,n,t)}}),[c,M,d,g,n]),H=(0,ht.useCallback)((()=>{if(!M){const e=[...dS(n),n.at(-1)+1];w(n,e,!0)}}),[M,w,n]),U=(0,ht.useCallback)(((e,t)=>{M||S||w(n,"up",e?.altKey)}),[M,w,n,S]),q=(0,ht.useCallback)(((e,t)=>{M||x||w(n,"down",e?.altKey)}),[M,w,n,x]),X=(0,ht.useCallback)((()=>{y("disabled",!M,n)}),[M,y,n]),Y=(0,ht.useCallback)((()=>{M||b(n)}),[M,b,n]),K=(0,ht.useMemo)((()=>f[t??""]),[t,f]),Q=(0,ht.useMemo)((()=>bS(K)),[K]),Z=(0,ht.useMemo)((()=>d?null:bE(l,$)?.className??""),[$,l,d]),J=(0,ht.useMemo)((()=>h(L)),[h,L]),ee=(0,ht.useMemo)((()=>N_(J,Z,m||"ruleGroup",i.ruleGroup,M&&i.disabled,I&&i.dndDragging,m||{[c_]:M,[a_]:I},Q)),[i.disabled,i.dndDragging,i.ruleGroup,Z,M,I,J,m,Q]),te=(0,ht.useMemo)((()=>{const e=[];for(let t=0;tfS(r,e)))}}return e}),[M,n,L.rules.length,u]),ne=(0,ht.useMemo)((()=>a({path:n,qbId:o})),[a,n,o]);return{...e,addGroup:V,addRule:B,accessibleDescription:ne,classNames:F,cloneGroup:H,combinator:$,disabled:M,dragMonitorId:O,dragRef:D,dropMonitorId:A,dropRef:T,isDragging:I,isOver:j,onCombinatorChange:z,onGroupAdd:g,onIndependentCombinatorChange:W,onNotToggleChange:G,outerClassName:ee,parentDisabled:E,pathsMemo:te,previewRef:P,removeGroup:Y,ruleGroup:L,shiftGroupUp:U,shiftGroupDown:q,toggleLockGroup:X,validationClassName:Q,validationResult:K}})(e),{schema:{controls:{ruleGroupBodyElements:n,ruleGroupHeaderElements:r}}}=t,o=VS(t.addRule),a=VS(t.addGroup),i=VS(t.cloneGroup),l=VS(t.toggleLockGroup),s=VS(t.removeGroup),c=VS(t.shiftGroupUp),u=VS(t.shiftGroupDown);return ht.createElement("div",{ref:t.previewRef,title:t.accessibleDescription,className:t.outerClassName,"data-testid":p_,"data-dragmonitorid":t.dragMonitorId,"data-dropmonitorid":t.dropMonitorId,"data-rule-group-id":t.id,"data-level":t.path.length,"data-path":JSON.stringify(t.path)},ht.createElement("div",{ref:t.dropRef,className:t.classNames.header},ht.createElement(r,{...t,addRule:o,addGroup:a,cloneGroup:i,toggleLockGroup:l,removeGroup:s,shiftGroupUp:c,shiftGroupDown:u})),ht.createElement("div",{className:t.classNames.body},ht.createElement(n,{...t,addRule:o,addGroup:a,cloneGroup:i,toggleLockGroup:l,removeGroup:s,shiftGroupUp:c,shiftGroupDown:u})))})),JS=ht.memo((e=>{const{schema:{controls:{shiftActions:t,dragHandle:n,combinatorSelector:r,notToggle:o,addRuleAction:a,addGroupAction:i,cloneGroupAction:l,lockGroupAction:s,removeGroupAction:c}}}=e;return ht.createElement(ht.Fragment,null,e.schema.showShiftActions&&e.path.length>0&&ht.createElement(t,{key:__,testID:__,level:e.path.length,path:e.path,titles:{shiftUp:e.translations.shiftActionUp.title,shiftDown:e.translations.shiftActionDown.title},labels:{shiftUp:e.translations.shiftActionUp.label,shiftDown:e.translations.shiftActionDown.label},className:e.classNames.shiftActions,disabled:e.disabled,shiftUp:e.shiftGroupUp,shiftDown:e.shiftGroupDown,shiftUpDisabled:e.shiftUpDisabled,shiftDownDisabled:e.shiftDownDisabled,context:e.context,validation:e.validationResult,schema:e.schema,ruleOrGroup:e.ruleGroup}),e.path.length>0&&e.schema.enableDragAndDrop&&ht.createElement(n,{key:E_,testID:E_,ref:e.dragRef,level:e.path.length,path:e.path,title:e.translations.dragHandle.title,label:e.translations.dragHandle.label,className:e.classNames.dragHandle,disabled:e.disabled,context:e.context,validation:e.validationResult,schema:e.schema,ruleOrGroup:e.ruleGroup}),!e.schema.showCombinatorsBetweenRules&&!e.schema.independentCombinators&&ht.createElement(r,{key:v_,testID:v_,options:e.schema.combinators,value:e.combinator,title:e.translations.combinators.title,className:e.classNames.combinators,handleOnChange:e.onCombinatorChange,rules:e.ruleGroup.rules,level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,schema:e.schema}),e.schema.showNotToggle&&ht.createElement(o,{key:w_,testID:w_,className:e.classNames.notToggle,title:e.translations.notToggle.title,label:e.translations.notToggle.label,checked:e.ruleGroup.not,handleOnChange:e.onNotToggleChange,level:e.path.length,disabled:e.disabled,path:e.path,context:e.context,validation:e.validationResult,schema:e.schema,ruleGroup:e.ruleGroup}),ht.createElement(a,{key:y_,testID:y_,label:e.translations.addRule.label,title:e.translations.addRule.title,className:e.classNames.addRule,handleOnClick:e.addRule,rules:e.ruleGroup.rules,level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,ruleOrGroup:e.ruleGroup,schema:e.schema}),ht.createElement(i,{key:m_,testID:m_,label:e.translations.addGroup.label,title:e.translations.addGroup.title,className:e.classNames.addGroup,handleOnClick:e.addGroup,rules:e.ruleGroup.rules,level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,ruleOrGroup:e.ruleGroup,schema:e.schema}),e.schema.showCloneButtons&&e.path.length>0&&ht.createElement(l,{key:b_,testID:b_,label:e.translations.cloneRuleGroup.label,title:e.translations.cloneRuleGroup.title,className:e.classNames.cloneGroup,handleOnClick:e.cloneGroup,rules:e.ruleGroup.rules,level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,ruleOrGroup:e.ruleGroup,schema:e.schema}),e.schema.showLockButtons&&ht.createElement(s,{key:S_,testID:S_,label:e.translations.lockGroup.label,title:e.translations.lockGroup.title,className:e.classNames.lockGroup,handleOnClick:e.toggleLockGroup,rules:e.ruleGroup.rules,level:e.path.length,path:e.path,disabled:e.disabled,disabledTranslation:e.parentDisabled?void 0:e.translations.lockGroupDisabled,context:e.context,validation:e.validationResult,ruleOrGroup:e.ruleGroup,schema:e.schema}),e.path.length>0&&ht.createElement(c,{key:g_,testID:g_,label:e.translations.removeGroup.label,title:e.translations.removeGroup.title,className:e.classNames.removeGroup,handleOnClick:e.removeGroup,rules:e.ruleGroup.rules,level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,ruleOrGroup:e.ruleGroup,schema:e.schema}))})),ex=ht.memo((e=>{const{schema:{controls:{combinatorSelector:t,inlineCombinator:n,ruleGroup:r,rule:o}}}=e;return e.ruleGroup.rules.map(((a,i,{length:l})=>{const s=e.pathsMemo[i],c=s.path,u=s.disabled||"string"!=typeof a&&a.disabled,d=fS([0],c),f=0===e.path.length&&i===l-1,p="string"==typeof a?[...c,a].join("-"):a.id;return ht.createElement(ht.Fragment,{key:p},i>0&&!e.schema.independentCombinators&&e.schema.showCombinatorsBetweenRules&&ht.createElement(n,{key:h_,options:e.schema.combinators,value:e.combinator,title:e.translations.combinators.title,className:e.classNames.combinators,handleOnChange:e.onCombinatorChange,rules:e.ruleGroup.rules,level:e.path.length,context:e.context,validation:e.validationResult,component:t,path:c,disabled:e.disabled,schema:e.schema}),"string"==typeof a?ht.createElement(n,{key:`${h_}-independent`,options:e.schema.combinators,value:a,title:e.translations.combinators.title,className:e.classNames.combinators,handleOnChange:t=>e.onIndependentCombinatorChange(t,i),rules:e.ruleGroup.rules,level:e.path.length,context:e.context,validation:e.validationResult,component:t,path:c,disabled:u,schema:e.schema}):nE(a)?ht.createElement(r,{key:p_,id:a.id,schema:e.schema,actions:e.actions,path:c,translations:e.translations,ruleGroup:a,rules:a.rules,combinator:rE(a)?a.combinator:void 0,not:!!a.not,disabled:u,parentDisabled:e.parentDisabled||e.disabled,shiftUpDisabled:d,shiftDownDisabled:f,context:e.context}):ht.createElement(o,{key:f_,id:a.id,rule:a,field:a.field,operator:a.operator,value:a.value,valueSource:a.valueSource,schema:e.schema,actions:e.actions,path:c,disabled:u,parentDisabled:e.parentDisabled||e.disabled,translations:e.translations,shiftUpDisabled:d,shiftDownDisabled:f,context:e.context}))}))})),tx=e=>{const{onChange:t,val:n}=(e=>{const{handleOnChange:t,listsAsArrays:n=!1,multiple:r=!1,value:o}=e;return{onChange:(0,ht.useCallback)((e=>{if(r){const r=J_(e);t(n?r:Q_(r,","))}else t(e)}),[t,n,r]),val:(0,ht.useMemo)((()=>r?J_(o):o),[r,o])}})(e),r=(e=>{const{multiple:t,onChange:n}=e;return(0,ht.useMemo)((()=>t?e=>n(Array.from(e.target.selectedOptions).map((e=>e.value))):e=>n(e.target.value)),[t,n])})({multiple:e.multiple,onChange:t});return ht.createElement("select",{"data-testid":e.testID,className:e.className,value:n,title:e.title,disabled:e.disabled,multiple:!!e.multiple,onChange:r},(o=e.options,mE(o)?o.map((e=>ht.createElement("optgroup",{key:e.label,label:e.label},e.options.map((e=>ht.createElement("option",{key:e.name,value:e.name,disabled:e.disabled},e.label)))))):Array.isArray(o)?o.map((e=>ht.createElement("option",{key:e.name,value:e.name,disabled:e.disabled},e.label))):null));var o},nx={actionElement:Kw,addGroupAction:Kw,addRuleAction:Kw,cloneGroupAction:Kw,cloneRuleAction:Kw,combinatorSelector:tx,dragHandle:Qw,fieldSelector:tx,inlineCombinator:e=>{const{component:t,...n}=e,r=N_(n.schema.suppressStandardClassnames||"betweenRules",n.schema.classNames.betweenRules);return ht.createElement("div",{className:r,"data-testid":h_},ht.createElement(t,{...n,testID:v_}))},lockGroupAction:Kw,lockRuleAction:Kw,notToggle:e=>ht.createElement("label",{"data-testid":e.testID,className:e.className,title:e.title},ht.createElement("input",{type:"checkbox",onChange:t=>e.handleOnChange(t.target.checked),checked:!!e.checked,disabled:e.disabled}),e.label),operatorSelector:tx,removeGroupAction:Kw,removeRuleAction:Kw,rule:KS,ruleGroup:ZS,ruleGroupBodyElements:ex,ruleGroupHeaderElements:JS,shiftActions:e=>ht.createElement("div",{"data-testid":e.testID,className:e.className},ht.createElement("button",{disabled:e.disabled||e.shiftUpDisabled,onClick:e.shiftUp,title:e.titles?.shiftUp},e.labels?.shiftUp),ht.createElement("button",{disabled:e.disabled||e.shiftDownDisabled,onClick:e.shiftDown,title:e.titles?.shiftDown},e.labels?.shiftDown)),valueEditor:e=>{const{operator:t,value:n,handleOnChange:r,title:o,className:a,type:i="text",inputType:l="text",values:s=[],listsAsArrays:c,fieldData:u,disabled:d,separator:f=null,testID:p,selectorComponent:h=e.schema.controls.valueSelector,...m}=e,{valueAsArray:g,multiValueHandler:b,parseNumberMethod:y,valueListItemClassName:v}=(e=>{const{handleOnChange:t,inputType:n,operator:r,value:o,listsAsArrays:a,parseNumbers:i,values:l,type:s,skipHook:c,schema:{classNames:u,suppressStandardClassnames:d}}=e;(0,ht.useEffect)((()=>{c||"multiselect"===s||["between","notBetween","in","notIn"].includes(r)||!(Array.isArray(o)||"number"===n&&"string"==typeof o&&o.includes(","))||t(J_(o,{retainEmptyStrings:!0})[0]??"")}),[t,n,r,c,s,o]);const f=(0,ht.useMemo)((()=>J_(o,{retainEmptyStrings:!0})),[o]),p=(0,ht.useMemo)((()=>{if("string"==typeof i){const[e,t]=i.split("-");return"limited"===t?"number"===n&&e:e}return!!i&&"strict"}),[n,i]),h=(0,ht.useCallback)(((e,n)=>{const o=Sw(f,(t=>{t[n]=_E(e,{parseNumbers:p}),0!==n||"between"!==r&&"notBetween"!==r||!(t.length<2||void 0===t[1])||(t[1]=yE(l))}));t(a?o:Q_(o,","))}),[t,a,r,p,f,l]),m=O_(d||u_,u?.valueListItem);return{valueAsArray:f,multiValueHandler:h,parseNumberMethod:p,valueListItemClassName:m}})(e);if("null"===t||"notNull"===t)return null;const w=u?.placeholder??"",_=["in","notIn"].includes(t)?"text":l||"text";if(!("between"!==t&&"notBetween"!==t||"select"!==i&&"text"!==i)){const t=["from","to"].map(((t,n)=>"text"===i?ht.createElement("input",{key:t,type:_,placeholder:w,value:g[n]??"",className:v,disabled:d,onChange:e=>b(e.target.value,n)}):ht.createElement(h,{key:t,...m,schema:e.schema,className:v,handleOnChange:e=>b(e,n),disabled:d,value:g[n]??yE(s),options:s,listsAsArrays:c})));return ht.createElement("span",{"data-testid":p,className:a,title:o},t[0],f,t[1])}switch(i){case"select":case"multiselect":return ht.createElement(h,{...m,schema:e.schema,testID:p,className:a,title:o,handleOnChange:r,disabled:d,value:n,options:s,multiple:"multiselect"===i,listsAsArrays:c});case"textarea":return ht.createElement("textarea",{"data-testid":p,placeholder:w,value:n,title:o,className:a,disabled:d,onChange:e=>r(e.target.value)});case"switch":case"checkbox":return ht.createElement("input",{"data-testid":p,type:"checkbox",className:a,title:o,onChange:e=>r(e.target.checked),checked:!!n,disabled:d});case"radio":return ht.createElement("span",{"data-testid":p,className:a,title:o},s.map((e=>ht.createElement("label",{key:e.name},ht.createElement("input",{type:"radio",value:e.name,disabled:d,checked:n===e.name,onChange:e=>r(e.target.value)}),e.label))))}return ht.createElement("input",{"data-testid":p,type:_,placeholder:w,value:n,title:o,className:a,disabled:d,onChange:e=>r(_E(e.target.value,{parseNumbers:y}))})},valueSelector:tx,valueSourceSelector:tx},rx=i(840),ox=i(5072),ax=i.n(ox),ix=i(7825),lx=i.n(ix),sx=i(7659),cx=i.n(sx),ux=i(5056),dx=i.n(ux),fx=i(540),px=i.n(fx),hx=i(1113),mx=i.n(hx),gx=i(6241),bx={};function yx(e){return yx="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},yx(e)}function vx(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 wx(e,t,n){return(t=function(e){var t=function(e){if("object"!=yx(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=yx(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==yx(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function _x(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=Sx(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},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 a,i=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return i=e.done,e},e:function(e){l=!0,a=e},f:function(){try{i||null==n.return||n.return()}finally{if(l)throw a}}}}function Ex(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,l=[],s=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return l}}(e,t)||Sx(e,t)||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.")}()}function Sx(e,t){if(e){if("string"==typeof e)return xx(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)?xx(e,t):void 0}}function xx(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n0;return React.createElement(Qb,{title:(0,L.__)("Validation","post-expirator"),className:"workflow-editor-validation-panel"},o&&React.createElement(React.Fragment,null,r.map((function(e,t){return React.createElement(M.PanelRow,{key:"".concat(e.error,"-").concat(t),className:"workflow-editor-validation-notification workflow-editor-error"},React.createElement(pp,{icon:"error",size:18}),e.message)}))),!o&&React.createElement(M.PanelRow,{className:"workflow-editor-validation-notification workflow-editor-success"},React.createElement(pp,{icon:"yes-alt",size:18}),(0,L.__)("All checks have passed for this step.","post-expirator")))};function Ix(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n0&&React.createElement(React.Fragment,null,React.createElement("div",null,(0,L.__)("This step receives the following input from previous step:","post-expirator")),React.createElement("ul",null,n.map((function(e,t){return React.createElement("li",{key:"input-".concat(e.name,"-").concat(t)},React.createElement(u,{schemaItem:e}))})))),0===n.length&&(0,L.__)("This step does not receive any input from previous step.","post-expirator"))),React.createElement(M.PanelRow,{className:"workflow-editor-inspector-card__handles-schema"},React.createElement("h3",null,(0,L.__)("Outputs","post-expirator")),React.createElement("div",null,o.length>0&&React.createElement(React.Fragment,null,React.createElement("div",null,(0,L.__)("This step outputs the following data:","post-expirator")),React.createElement("ul",null,o.map((function(e,t){return React.createElement("li",{key:"output-".concat(e.name,"-").concat(t)},React.createElement(u,{schemaItem:e}))})))),0===o.length&&(0,L.__)("This step does not output any data.","post-expirator"))),React.createElement(M.PanelRow,{className:"workflow-editor-inspector-card__handles-schema"},React.createElement("h3",null,(0,L.__)("Global Variables","post-expirator")),React.createElement("div",null,!i&&0===c.length&&React.createElement("div",null,(0,L.__)("No global variables are declared","post-expirator")),!i&&c.length>0&&React.createElement("ul",null,c.map((function(e){return React.createElement("li",{key:"global-".concat(e)},React.createElement(u,{schemaItem:s[e],prefix:"global."}))}))))))};function Mx(e){var t=e.size,n=void 0===t?24:t;return React.createElement(Xf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 24 24",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{fill:"none",strokeWidth:"2",d:"M1,1 L4,1 L4,4 L1,4 L1,1 Z M20,1 L23,1 L23,4 L20,4 L20,1 Z M4,2 L20,2 M4,22 L20,22 M1,20 L4,20 L4,23 L1,23 L1,20 Z M20,20 L23,20 L23,23 L20,23 L20,20 Z M2,4 L2,20 M22,4 L22,20 M7,7 L14,7 L14,13 L7,13 L7,7 Z M17,10 L17,17 L10,17 L10,15"})))}function $x(e){var t=e.size,n=void 0===t?24:t;return React.createElement(Xf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 384 512",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M190.4 74.1c5.6-16.8-3.5-34.9-20.2-40.5s-34.9 3.5-40.5 20.2l-128 384c-5.6 16.8 3.5 34.9 20.2 40.5s34.9-3.5 40.5-20.2l128-384zm70.9-41.7c-17.4-2.9-33.9 8.9-36.8 26.3l-64 384c-2.9 17.4 8.9 33.9 26.3 36.8s33.9-8.9 36.8-26.3l64-384c2.9-17.4-8.9-33.9-26.3-36.8zM352 32c-17.7 0-32 14.3-32 32V448c0 17.7 14.3 32 32 32s32-14.3 32-32V64c0-17.7-14.3-32-32-32z"})))}function Lx(){return Lx=Object.assign?Object.assign.bind():function(e){for(var t=1;t0&&0===r.length,h=0===n.length&&r.length>0,m=(null==s||null===(e=s.settingsSchema)||void 0===e?void 0:e.length)>0,g=function(e){var t,n,r=(0,$.select)(ec).getNodeTypeByName(null==e||null===(t=e.data)||void 0===t?void 0:t.name),o=hc(e);return(null==o?void 0:o.length)>0&&(null===(n=o.filter((function(e){var t;return(null==r||null===(t=r.outputSchema)||void 0===t?void 0:t.length)>0})))||void 0===n?void 0:n.length)>0}(a),y=function(e){var t,n,r=(0,$.select)(ec).getNodeTypeByName(null==e||null===(t=e.data)||void 0===t?void 0:t.name);return(null==r||null===(n=r.outputSchema)||void 0===n?void 0:n.length)>0}(a),w=gc(a),_=(null==s?void 0:s.outputSchema)||[],E=[];return _.length>0&&_.forEach((function(e){var t;"input"===e.type?E=E.concat(w):E.push(Bx(Bx({},e),{},{name:"".concat(null==a||null===(t=a.data)||void 0===t?void 0:t.slug,".").concat(e.name)}))})),Jb(f,".interface-interface-skeleton__sidebar"),React.createElement("div",{ref:f},0===o&&React.createElement(ry,null,(0,L.__)("No element selected.","post-expirator")),o>1&&!p&&!h&&React.createElement(ry,null,(0,L.__)("Multiple and different elements selected.","post-expirator")),p&&o>1&&React.createElement(ty,{title:(0,L.sprintf)((0,L.__)("%d steps selected","post-expirator"),o),description:(0,L.__)("Multiple steps selected.","post-expirator"),icon:React.createElement(Mx,{size:24})}),h&&o>1&&React.createElement(ty,{title:(0,L.sprintf)((0,L.__)("%d connections selected","post-expirator"),o),description:(0,L.__)("Multiple connections selected.","post-expirator"),icon:React.createElement($x,{size:24})}),p&&1===o&&React.createElement(React.Fragment,null,React.createElement(ny,{node:a}),m&&React.createElement(Dx,{node:a}),React.createElement(Tx,{errors:l}),d&&(g||y)&&React.createElement(jx,{inputSchema:w,outputSchema:E}),u&&React.createElement(zx,{node:a,nodeType:s}),React.createElement("div",{className:"components-tools-panel"})),h&&1===o&&i&&React.createElement(React.Fragment,null,React.createElement(ty,{title:(0,L.__)("Connection","post-expirator"),description:(0,L.__)("The connection between nodes in the workflow. Signifies the path along which data or control flow one node to another.","post-expirator"),icon:React.createElement($x,{size:24}),id:i.id}),React.createElement("div",{className:"components-tools-panel"})))};const Ux=function(){var e=(0,$.useSelect)((function(e){return{showQueries:e(yf).getEditedWorkflowAttribute("debugRayShowQueries"),showEmails:e(yf).getEditedWorkflowAttribute("debugRayShowEmails"),showWordPressErrors:e(yf).getEditedWorkflowAttribute("debugRayShowWordPressErrors"),showCurrentRunningStep:e(yf).getEditedWorkflowAttribute("debugRayShowCurrentRunningStep"),isLoadingWorkflow:e(yf).isLoadingWorkflow()}})),t=e.showQueries,n=e.showEmails,r=e.showWordPressErrors,o=e.showCurrentRunningStep,a=e.isLoadingWorkflow,i=(0,$.useDispatch)(yf).setEditedWorkflowAttribute,l=(0,T.useCallback)((function(e){i("debugRayShowQueries",e)})),s=(0,T.useCallback)((function(e){i("debugRayShowEmails",e)})),c=(0,T.useCallback)((function(e){i("debugRayShowWordPressErrors",e)})),u=(0,T.useCallback)((function(e){i("debugRayShowCurrentRunningStep",e)}));return React.createElement("div",null,React.createElement(Qb,{className:"edit-post-post-status workflow-editor-dev-panel",title:(0,L.__)("Ray Debug","post-expirator"),initialOpen:!0,disabled:a},React.createElement(M.PanelRow,null,React.createElement("p",null,(0,L.__)("Enable or disable the different types of debug information that is shown in Ray when this workflow is activated.","post-expirator"))),React.createElement(M.PanelRow,null,React.createElement(M.ToggleControl,{label:(0,L.__)("Show Queries","post-expirator"),checked:t,onChange:l})),React.createElement(M.PanelRow,null,React.createElement(M.ToggleControl,{label:(0,L.__)("Show Emails","post-expirator"),checked:n,onChange:s})),React.createElement(M.PanelRow,null,React.createElement(M.ToggleControl,{label:(0,L.__)("Show WordPress Errors","post-expirator"),checked:r,onChange:c})),React.createElement(M.PanelRow,null,React.createElement(M.ToggleControl,{label:(0,L.__)("Show current running step","post-expirator"),checked:o,onChange:u}))))};var qx=T.Platform.select({web:!0,native:!1}),Xx=function(){var e=(0,$.useSelect)((function(e){var t=e(Ug).getShortcutRepresentation(nb);return{sidebarName:e("core/interface").getActiveComplementaryArea(k),keyboardShortcut:t}})),t=e.sidebarName,n=e.keyboardShortcut,r=(0,$.useSelect)((function(e){return{isDeveloperModeEnabled:e(ec).isFeatureActive(b),isRayDebugInstalled:e(ec).isRayDebugInstalled()}})),o=r.isDeveloperModeEnabled,a=r.isRayDebugInstalled;return React.createElement(Bb,{identifier:t,header:React.createElement(Vb,{sidebarName:t}),closeLabel:(0,L.__)("Close settings","post-expirator"),headerClassName:"edit-post-sidebar__panel-tabs",className:"edit-post-sidebar__panel",title:(0,L.__)("Settings","post-expirator"),toggleShortcut:n,icon:zb,isActiveByDefault:qx},t===mp&&React.createElement(React.Fragment,null,React.createElement(ey,null),o&&a&&React.createElement(React.Fragment,null,React.createElement(Ux,null))),t===gp&&React.createElement(React.Fragment,null,React.createElement(Hx,null)))},Yx=function(e){return futureWorkflowEditor.assetsUrl+"/images/workflow-welcome-guide/"+e+"?v="+futureWorkflowEditor.pluginVersion};const Kx=function(){var e=(0,$.useDispatch)(ec).disableFeature,t=futureWorkflowEditor.welcomeGuidePages;return React.createElement(M.Guide,{className:"workflow-editor-welcome-guide",contentLabel:(0,L.__)("Welcome to the workflow editor","post-expirator"),finishButtonText:(0,L.__)("Get started","post-expirator"),onFinish:function(){e(y)},pages:t.map((function(e){var t=e.title,n=e.content,r=e.image;return{content:React.createElement(React.Fragment,null,React.createElement("h1",{className:"edit-post-welcome-guide__heading"},t),React.createElement("p",{className:"edit-post-welcome-guide__text"},n)),image:React.createElement("picture",{className:"edit-post-welcome-guide__image"},React.createElement("source",{srcSet:Yx(r+".png"),media:"(prefers-reduced-motion: reduce)"}),React.createElement("img",{src:Yx(r+".gif"),width:"312",height:"240",alt:""}))}}))})};function Qx(){var e=(0,$.useSelect)((function(e){return{isFullscreenActive:e(ec).isFeatureActive(h),isInserterOpened:e(ec).isFeatureActive(g),isWelcomeGuideActive:e(ec).isFeatureActive(y),isPro:e(ec).isPro()}})),t=e.isFullscreenActive,n=e.isInserterOpened,r=e.isWelcomeGuideActive,o=e.isPro,a=ft()("edit-post-layout editor-editor-interface",{"is-inserter-opened":n});return(0,T.useEffect)((function(){var e=["workflow-editor"];return e.push(o?"is-pro":"is-free"),e.forEach((function(e){return function(e){document.body.classList.contains(e)||document.body.classList.add(e)}(e)})),function(){!function(e){e.forEach((function(e){return function(e){document.body.classList.contains(e)&&document.body.classList.remove(e)}(e)}))}(e)}}),[]),React.createElement(M.SlotFillProvider,null,React.createElement(Is,null,React.createElement(Je,{isActive:t}),React.createElement(ab,null),React.createElement(Xx,null),React.createElement(Tg,{className:a,secondarySidebar:function(){return n?React.createElement(Fb,null):null}}),r&&React.createElement(Kx,null)),React.createElement(Le.PluginArea,{scope:"future-workflow-editor"}))}var Zx=i(3133),Jx={};Jx.styleTagTransform=mx(),Jx.setAttributes=dx(),Jx.insert=cx().bind(null,"head"),Jx.domAPI=lx(),Jx.insertStyleElement=px(),ax()(Zx.A,Jx),Zx.A&&Zx.A.locals&&Zx.A.locals;var ek=i(2672),tk={};tk.styleTagTransform=mx(),tk.setAttributes=dx(),tk.insert=cx().bind(null,"head"),tk.domAPI=lx(),tk.insertStyleElement=px(),ax()(ek.A,tk),ek.A&&ek.A.locals&&ek.A.locals;var nk=window.futureWorkflowEditor,rk=nk.workflowId,ok=nk.nodeTypeCategories,ak=nk.nodeTypes;function ik(){var e=(0,$.useDispatch)(yf),t=e.setupEditor,n=e.setDataTypes,r=(0,$.useDispatch)(ec),o=r.setTriggerNodes,a=r.setTriggerCategories,i=r.setActionCategories,l=r.setActionNodes,s=r.setAdvancedCategories,c=r.setAdvancedNodes;return(0,T.useEffect)((function(){t(rk),o(ak.triggers),l(ak.actions),c(ak.advanced),a(ok),i(ok),s(ok),n([{name:"post",label:"Post",type:"object",objectType:"post",propertiesSchema:[{name:"post_title",type:"string",label:"Title"},{name:"post_content",type:"string",label:"Content"},{name:"post_content_text",type:"string",label:"Content (Plain Text)"},{name:"post_excerpt",type:"string",label:"Excerpt"},{name:"post_status",type:"string",label:"Post Status"},{name:"post_type",type:"string",label:"Post Type"},{name:"id",type:"integer",label:"ID"},{name:"post_date",type:"datetime",label:"Publish Date"},{name:"post_modified",type:"datetime",label:"Modification Date"},{name:"permalink",type:"string",label:"Permalink"}]},{name:"boolean",label:"Boolean",type:"boolean"},{name:"datetime",label:"Datetime",type:"datetime"},{name:"integer",label:"Integer",type:"integer"},{name:"string",label:"String",type:"string"},{name:"email",label:"Email",type:"email"},{name:"input",label:"Step input",type:"input"},{name:"workflow",label:"Future Workflow",type:"object",objectType:"workflow",propertiesSchema:[{name:"id",type:"integer",label:"ID"},{name:"title",type:"string",label:"Title"},{name:"description",type:"string",label:"Description"},{name:"modified_at",type:"datetime",label:"Modification Date"},{name:"steps",type:"node",label:"Steps"}]},{name:"user",label:"User",type:"object",objectType:"user",propertiesSchema:[{name:"ID",type:"integer",label:"ID"},{name:"user_email",type:"email",label:"Email"},{name:"user_login",type:"string",label:"User Login"},{name:"display_name",type:"string",label:"Display Name"},{name:"roles",type:"array",label:"Roles"},{name:"caps",type:"object",label:"Capabilities"},{name:"user_registered",type:"datetime",label:"Registration Date"}]},{name:"site",label:"Site",type:"object",objectType:"site",propertiesSchema:[{name:"name",type:"string",label:"Name"},{name:"description",type:"string",label:"Description"},{name:"url",type:"string",label:"Site URL"},{name:"home_url",type:"string",label:"Home URL"},{name:"admin_email",type:"email",label:"Admin Email"}]},{name:"node",label:"Workflow Node",type:"object",objectType:"node",propertiesSchema:[{name:"id",type:"integer",label:"ID"},{name:"name",type:"string",label:"Name"},{name:"slug",type:"string",label:"Slug"},{name:"label",type:"string",label:"Label"},{name:"activation_timestamp",type:"string",label:"Activation Time"}]},{name:"array",label:"Array",type:"array"}])}),[rk]),React.createElement(T.StrictMode,null,React.createElement(Qx,null))}var lk=document.getElementById("future-workflow-editor");lk&&(0,D.H)(lk).render(React.createElement(ik,null))})()})(); \ No newline at end of file +(()=>{var e,t,n,r,o={3018:(e,t,n)=>{"use strict";n.d(t,{Ml:()=>i,qj:()=>r,rx:()=>a,wD:()=>o});var r="RIGHT",o="DOWN",a=o,i="publishpress_future_workflow_editor_auto_layout"},2158:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,'.block-editor-block-types-list > [role="presentation"] {\n\toverflow: hidden;\n\tdisplay: flex;\n\tflex-wrap: wrap;\n}\n',""]);const l=i},217:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".edit-post-sidebar__panel .condition-natural-language {\n margin-top: 12px;\n font-family: monospace, monospace;\n background-color: #f0f0f1;\n padding: 12px;\n border-radius: 4px;\n border: 1px solid #e0e0e1;\n}\n\n.condition-pro-features-notice {\n font-style: italic;\n margin-top: 12px;\n}\n\n.ruleGroup {\n margin: none;\n background: none;\n border: none;\n}\n\n.block-editor-inspector-popover-header__heading {\n font-size: 13px !important;\n margin-bottom: 16px !important;\n}\n",""]);const l=i},6943:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".components-button svg {\n height: 100%;\n}\n\n#wpfooter {\n display: none !important;\n}\n\n.react-flow {\n width: 100% !important;\n}\n\n.components-menu-items__item-icon.has-icon-right {\n width: 24px !important;\n height: 24px !important;\n}\n\n.react-flow__node-default.selectable.selected,\n.react-flow__node-default.selectable:focus,\n.react-flow__node-default.selectable:focus-visible,\n.react-flow__node-input.selectable.selected,\n.react-flow__node-input.selectable:focus,\n.react-flow__node-input.selectable:focus-visible,\n.react-flow__node-output.selectable.selected,\n.react-flow__node-output.selectable:focus,\n.react-flow__node-output.selectable:focus-visible,\n.react-flow__node-group.selectable.selected,\n.react-flow__node-group.selectable:focus,\n.react-flow__node-group.selectable:focus-visible {\n box-shadow: 0 0 0 2px #1a192b;\n}\n\n/* .react-flow {\n background-color: #e1e1e1 !important;\n} */\n\n.settings-field-description {\n font-size: 12px;\n color: #666;\n margin-bottom: 15px;\n}\n\n.settings-field-help-popover {\n font-size: 12px;\n color: #666;\n width: 320px;\n padding: 16px;\n position: relative;\n padding-top: 50px;\n}\n\n.settings-field-help-popover button {\n position: absolute;\n top: 10px;\n right: 10px;\n}\n\n.workflow-editor-inspector-card__handles-schema {\n display: flex;\n flex-direction: column;\n flex-wrap: nowrap;\n justify-content: flex-start;\n align-items: flex-start;\n}\n\n.workflow-editor-inspector-card__handles-schema code {\n padding: 3px 6px;\n border-radius: 4px;\n font-size: 12px;\n background: #ebebeb;\n color: #696969;\n}\n\n.workflow-editor-inspector-card__handles-schema h3 {\n margin-bottom: 4px !important;\n}\n\n.workflow-editor-global-variables-description {\n font-size: 12px;\n color: #666;\n margin-bottom: 15px;\n}\n\n.workflow-editor-global-variables-label {\n font-size: 11px;\n font-weight: 500;\n line-height: 1.4;\n text-transform: uppercase;\n display: inline-block;\n margin-bottom: calc(8px);\n padding: 0px;\n}\n.workflow-editor-global-var-list {\n margin: 0;\n padding: 5px;\n border: 1px solid var(--wp-components-color-gray-600, #949494);\n}\n\n.workflow-editor-global-var-list ul {\n list-style: disc;\n margin-left: 30px;\n}\n\n.workflow-editor-global-var-list ul li {\n margin-bottom: 0;\n}\n\n.edit-post-editor__inserter-panel-content {\n height: 100%;\n}\n\n.block-editor-inserter__content {\n display: flex;\n flex-direction: column;\n gap: 16px;\n height: 100%;\n overflow-y: hidden;\n position: relative;\n}\n\n.block-editor-inserter__panel-content {\n overflow-y: auto;\n}\n\n.interface-interface-skeleton__footer {\n min-height: 25px;\n padding: 3px 20px;\n box-sizing: border-box;\n}\n\n.interface-interface-skeleton__secondary-sidebar {\n box-shadow: 1px 1px 0 0 rgba(0, 0, 0, .133);\n outline: 1px solid #0000;\n}\n\n.editor-inserter-sidebar *, .editor-inserter-sidebar :after, .editor-inserter-sidebar :before {\n box-sizing: inherit;\n}\n",""]);const l=i},8565:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".workflow-editor-dev-info-panel .components-panel__row {\n overflow: scroll;\n}\n\n.workflow-editor-dev-info-wrapper {\n min-width: 1000px;\n}\n\n.workflow-editor-dev-panel {\n background-color: #fffaf1;\n}\n",""]);const l=i},7860:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".components-guide__container {\n max-width: 312px;\n}\n",""]);const l=i},7448:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".edit-post-editor__inserter-panel-header {\n display: flex;\n\tjustify-content: flex-end;\n}\n\n@media (min-width: 782px) {\n .editor-inserter-sidebar__header {\n display: none;\n }\n}\n\n.edit-post-header-toolbar .editor-document-tools__left > .edit-post-header-toolbar__inserter-toggle.is-pressed svg {\n transform: rotate(45deg);\n}\n\n",""]);const l=i},4259:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".edit-post-post-status .components-base-control {\n flex: auto;\n}\n\n.editor-post-title__panel,\n.editor-post-description__panel {\n padding-top: 8px;\n}\n\n.editor-post-status__panel {\n margin-top: 16px;\n gap: 16px !important;\n}\n\n.editor-post-status__panel button {\n flex-grow: 1;\n justify-content: center;\n}\n\n.workflow-editor-element-inspector__warning {\n background: #fff;\n display: block;\n font-size: 13px;\n padding: 32px 36px;\n text-align: center;\n flex-grow: 1;\n justify-content: center;\n}\n\n\n.workflow-editor-inspector-card {\n align-items: flex-start;\n color: #1e1e1e;\n display: flex;\n padding: 16px;\n}\n\n.workflow-editor-inspector-card {\n align-items: flex-start;\n color: #1e1e1e;\n display: flex;\n padding: 16px;\n}\n\n.workflow-editor-inspector-icon {\n align-items: center;\n display: flex;\n height: 24px;\n justify-content: center;\n width: 24px;\n}\n\n.workflow-editor-inspector-card .workflow-editor-inspector-icon {\n flex: 0 0 24px;\n height: 24px;\n margin-left: 0;\n margin-right: 12px;\n width: 24px;\n}\n\n.workflow-editor-inspector-card {\n align-items: flex-start;\n color: #1e1e1e;\n display: flex;\n padding: 16px;\n}\n\n.workflow-editor-inspector-card__content {\n flex-grow: 1;\n}\n\n.workflow-editor-inspector-inspector h2, .workflow-editor-inspector-inspector h3 {\n color: #1e1e1e;\n font-size: 13px;\n margin-bottom: 1.5em;\n}\n\n.interface-complementary-area h2 {\n color: #1e1e1e;\n font-size: 13px;\n margin-bottom: 1.5em;\n}\n\n.workflow-editor-inspector-card__title.workflow-editor-inspector-card__title {\n font-size: 13px;\n line-height: 1.4;\n margin: 0;\n padding: 3px 0;\n}\n\n\n.workflow-editor-inspector-card__description {\n display: block;\n font-size: 13px;\n line-height: 1.4;\n margin-top: 4px;\n}\n\n.workflow-editor-inspector-icon.has-colors svg {\n fill: currentColor;\n}\n\n.workflow-editor-inspector-icon svg {\n max-height: 24px;\n max-width: 24px;\n min-height: 20px;\n min-width: 20px;\n}\n\n.workflow-editor-validation-notification {\n display: flex;\n flex-direction: row;\n align-items: flex-start;\n justify-content: flex-start;\n}\n\n.workflow-editor-validation-panel .node-icon {\n margin-right: 5px;\n}\n\n.workflow-editor-validation-notification.workflow-editor-success .node-icon * {\n color: #46b450;\n}\n\n.workflow-editor-validation-notification.workflow-editor-error .node-icon * {\n color: #d90f0f;\n}\n\n.edit-post-sidebar__panel .components-h-stack {\n width: 100%;\n}\n\n.workflow-editor-inspector-card__content table {\n width: 100%;\n border-collapse: collapse;\n border-spacing: 0;\n margin-top: 20px;\n}\n\n.workflow-editor-inspector-card__content table th,\n.workflow-editor-inspector-card__content table td {\n padding: 2px 3px;\n border: 1px solid #e1e1e1;\n text-align: left;\n}\n\n.workflow-editor-data-flow-variable ul {\n margin-left: 40px;\n margin-top: 6px;\n margin-bottom: 11px;\n padding: 2px;\n}\n\n.workflow-editor-data-flow-variable ul li {\n margin-bottom: 2px;\n list-style: disc;\n line-height: 16px;\n}\n\n.workflow-editor-data-flow-variable ul code {\n max-width: 204px;\n display: inline-block;\n overflow: auto;\n text-wrap: wrap;\n}\n",""]);const l=i},1578:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".react-flow__node {\n max-width: 170px;\n}\n\n.react-flow__node-body {\n border-radius: 8px;\n color: #171717;\n font-size: 10px;\n min-width: 140px;\n box-sizing: border-box;\n border: 1px solid transparent;\n cursor: pointer;\n}\n\n.react-flow__node-inner-body {\n padding: 6px;\n box-sizing: border-box;\n}\n\n.react-flow__node-header {\n text-align: center;\n width: 100%;\n position: relative;\n text-align: left;\n}\n\n.react-flow__node-header .react-flow__node-label {\n margin-left: 22px;\n}\n\n.react-flow__node-header .dashicon {\n margin-right: 4px;\n position: absolute;\n left: 2px;\n top: 2px;\n}\n\n.react-flow__node-header .node-icon {\n margin-right: 4px;\n position: absolute;\n top: 1px;\n left: 2px;\n}\n\n.react-flow__node-slug {\n font-size: 8px;\n display: inline-block;\n height: 6px;\n line-height: 6px;\n padding: 2px;\n position: absolute;\n top: 45px;\n left: 27px;\n}\n\n.react-flow__handle {\n width: 8px !important;\n height: 8px !important;\n box-sizing: border-box;\n}\n\n.react-flow__handle.react-flow__handle-bottom {\n bottom: -4px !important;\n}\n\n.react-flow__handle.react-flow__handle-top {\n top: -4px !important;\n}\n\n.react-flow__node-top {\n font-size: 8px;\n padding: 0 8px;\n border-top-left-radius: 8px;\n border-top-right-radius: 8px;\n border-bottom: 1px solid silver;\n position: relative;\n padding-left: 18px;\n}\n\n.react-flow__node-top .publishpress-icon {\n margin-right: 4px;\n position: absolute;\n top: 1px;\n left: 8px;\n}\n\n/* PLACEHOLDER FOR EMPTY FLOW */\n.react-flow__node-triggerPlaceholderNode {\n background-color: #fff;\n border: 1px dashed #d2d2d2;\n cursor: pointer;\n}\n\n.react-flow__node-triggerPlaceholderNode .react-flow__node-header {\n display: flex;\n align-items: center;\n}\n\n.react-flow__node-triggerPlaceholderNode .react-flow__node-header .icon {\n color: #fff;\n background-color: #d2d2d2;\n padding: 2px;\n display: inline-block;\n width: 12px;\n height: 12px;\n box-sizing: border-box;\n position: relative;\n border-radius: 1px;\n margin-right: 6px;\n}\n\n.react-flow__node-triggerPlaceholderNode .react-flow__node-header .icon svg {\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n width: 12px;\n height: 12px;\n}\n\n.react-flow__node-triggerPlaceholderNode .react-flow__node-header .react-flow__node-label {\n color: #d2d2d2\n}\n\n.react-flow__node-triggerPlaceholderNode .react-flow__node-header {\n padding-left: 0;\n}\n\n.react-flow__node-triggerPlaceholderNode:hover {\n border: 1px dashed #aeaeae;\n}\n\n.react-flow__node-triggerPlaceholderNode:hover .react-flow__node-header .icon {\n background-color: #aeaeae;\n}\n\n.react-flow__node-triggerPlaceholderNode:hover .react-flow__node-header .react-flow__node-label {\n color: #aeaeae;\n}\n\n.react-flow__node-inserter-popover .components-popover__content {\n width: 350px;\n}\n\n.react-flow__node-inserter-popover {\n display: flex;\n flex-direction: column;\n position: relative;\n}\n\n.react-flow__node-inserter-popover-content {\n height: 100%;\n overflow-y: auto;\n height: 340px;\n}\n\n.react-flow__node-inserter-popover-close {\n cursor: pointer;\n background-color: #000;\n color: #fff;\n display: block;\n width: 100%;\n padding: 6px;\n height: 44px;\n}\n\n.react-flow__node-inserter-popover .components-popover__content {\n height: ;\n}\n\n/* GENERIC NODE */\n\n.react-flow__node-genericNode {\n background-color: #b2b2c9;\n border: 1px solid #b2b2c9;\n}\n\n.react-flow__node-genericNode .react-flow__handle {\n background-color: #fff;\n border: 1px solid #b2b2c9;\n}\n\n.react-flow__node-genericNode .react-flow__node-top {\n border-bottom: 1px solid #b2b2c9;\n}\n\n.react-flow__node-genericNode .react-flow__node-slug {\n color: #b2b2c9;\n}\n\n/* TRIGGER */\n\n.react-flow__node-genericTrigger {\n background-color: #dce5df;\n border: 1px solid #b9c0bb;\n}\n\n.react-flow__node-genericTrigger .react-flow__handle {\n background-color: #fff;\n border: 1px solid #B594B6;\n}\n\n.react-flow__node-genericTrigger .react-flow__node-slug {\n color: #939895;\n}\n\n.react-flow__node-genericTrigger .react-flow__node-top {\n border-bottom: 1px solid #b9c0bb;\n}\n\n.react-flow__node-genericTrigger .react-flow__node-slug {\n color: #808882;\n}\n\n/* GENERIC ACTION */\n\n.react-flow__node-genericAction {\n background-color: #89bae4;\n border: 1px solid #7199bc;\n}\n\n.react-flow__node-genericAction .react-flow__handle {\n background-color: #fff;\n border: 1px solid #7199bc;\n}\n\n.react-flow__node-genericAction .react-flow__node-slug {\n color: #8a62be;\n}\n\n.react-flow__node-genericAction .react-flow__node-top {\n border-bottom: 1px solid #7199bc;\n}\n\n.react-flow__node-genericAction .react-flow__node-slug {\n color: #526e87;\n}\n\n/* GENERIC ADVANCED */\n\n.react-flow__node-genericAdvanced {\n background-color: #f8ddad;\n border: 1px solid #d3bc94;\n}\n\n.react-flow__node-genericAdvanced .react-flow__handle {\n background-color: #fff;\n border: 1px solid #d3bc94;\n}\n\n.react-flow__node-genericAdvanced .react-flow__node-slug {\n color: #b19f80;\n}\n\n.react-flow__node-genericAdvanced .react-flow__node-top {\n border-bottom: 1px solid #d3bc94;\n}\n\n.react-flow__node-genericAdvanced .react-flow__node-slug {\n color: #908065;\n}\n\n/* QUERY ACTION */\n\n.react-flow__node-queryAction {\n background-color: #d8b6f2;\n border: 1px solid #b891c2;\n}\n\n.react-flow__node-queryAction .react-flow__handle {\n background-color: #fff;\n border: 1px solid #b891c2;\n}\n\n.react-flow__node-queryAction .react-flow__node-slug {\n color: #9079a1;\n}\n\n.react-flow__node-queryAction .react-flow__node-top {\n border-bottom: 1px solid #b891c2;\n}\n\n.react-flow__node-queryAction .react-flow__node-slug {\n color: rgb(110, 110, 125);\n}\n\n/* DEBUG ACTION */\n\n.react-flow__node-debugAction {\n background-color: #f0aec6;\n border: 1px solid #cf96ab;\n}\n\n.react-flow__node-debugAction .react-flow__handle {\n background-color: #fff;\n border: 1px solid #cf96ab;\n}\n\n.react-flow__node-debugAction .react-flow__node-slug {\n color: #916877;\n}\n\n.react-flow__node-debugAction .react-flow__node-top {\n border-bottom: 1px solid #cf96ab;\n}\n\n\n/* SELECTED NODES */\n\n.react-flow__node.selected .react-flow__node-body {\n border: 1px solid #555;\n}\n\n.react-flow__node-genericNode .react-flow__node-slug {\n color: #b2b2c9;\n}\n\n/* HANDLE AREA */\n\n.react-flow__node-handle-area {\n font-size: 6px;\n background-color: #fff;\n border-bottom-left-radius: 8px;\n border-bottom-right-radius: 8px;\n display: flex;\n flex-direction: row;\n}\n\n.react-flow__node-handle-name {\n padding: 4px 2px 6px 2px;\n text-align: center;\n line-height: 100%;\n flex: 1;\n border-left: 1px solid silver;\n}\n\n.react-flow__node-handle-name:first-child {\n border-left: 0;\n}\n\n/* Node Content */\n.react-flow__node-content {\n font-size: 6px;\n margin-top: 6px;\n}\n\n.react-flow__node-content table {\n border-spacing: 0;\n width: 100%;\n}\n\n.react-flow__node-content table th {\n text-align: left;\n}\n\n.react-flow__node-content table th,\n.react-flow__node-content table td {\n padding: 0 6px;\n font-size: 6px;\n border: 1px solid rgba(0, 0, 0, 0.1);\n}\n\n/* Node Markers */\n.react-flow__node-marker-wrapper {\n position: absolute;\n top: -17px;\n right: 0;\n display: flex;\n flex-direction: row;\n gap: 2px;\n justify-content: right;\n}\n\n.react-flow__node-error,\n.react-flow__node-pro-badge {\n display: flex;\n border-radius: 100%;\n width: 14px;\n height: 14px;\n box-sizing: border-box;\n justify-content: center;\n vertical-align: middle;\n}\n\n.react-flow__node-pro-badge {\n background-color: #ffb200;\n color: #000;\n}\n\n.react-flow__node-pro-badge .node-icon {\n margin-top: -2px;\n}\n\n.react-flow__node-error {\n background-color: #d90f0f;\n color: #fff;\n font-size: 10px;\n text-align: center;\n line-height: 12px;\n font-family: monospace;\n font-weight: 900;\n padding-left: 0px;\n}\n\n.react-flow__node-error .node-icon {\n margin-top: 2px;\n}\n\nbody.workflow-editor.is-free .react-flow__node-handle-name {\n color: #cacaca;\n}\n\nbody.workflow-editor.is-free .react-flow__node-handle-name.handle-area-source-output,\nbody.workflow-editor.is-free .react-flow__node-handle-name.handle-area-source-true {\n color: #000;\n}\n",""]);const l=i},4143:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".workflow-editor-notices__snackbar-list {\n position: fixed;\n bottom: 35px;\n left: 220px;\n}\n\n.folded .workflow-editor-notices__snackbar-list {\n left: 92px;\n}\n\n.is-fullscreen-mode .workflow-editor-notices__snackbar-list {\n left: 60px;\n}\n",""]);const l=i},8501:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".block-editor-block-types-list__item-pro-badge {\n background-color: #ffb200;\n color: #000;\n padding: 3px 8px;\n border-radius: 4px;\n font-size: 10px;\n font-weight: 600;\n width: 100%;\n}\n.workflow-editor-inspector-card__pro-badge,\n.block-editor-block-card__pro-badge {\n background-color: #ffb200;\n color: #000;\n padding: 3px 8px;\n border-radius: 4px;\n font-size: 10px;\n font-weight: 600;\n}\n\n.workflow-editor-inspector-card__pro-badge,\n.components-popover__content .block-editor-block-card__pro-badge {\n margin-left: 8px;\n}\n\n.workflow-editor-inspector-card__pro-instructions,\n.block-editor-block-card__pro-instructions {\n font-size: 12px;\n color: #757575;\n margin-top: 8px;\n line-height: 1.5;\n font-style: italic;\n font-weight: 400;\n border-top: 1px solid #e0e0e0;\n padding-top: 8px;\n}\n\n.edit-post-header-toolbar__buy-pro {\n background-color: #ffb200;\n color: #000;\n padding: 4px 10px !important;\n border-radius: 4px;\n}\n\n.edit-post-header-toolbar__buy-pro .publishpress-icon {\n width: 18px !important;\n height: 18px !important;\n margin-right: 4px;\n}\n",""]);const l=i},269:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,"/* .react-flow__node-toolbar {\n position: absolute;\n top: -40px;\n left: 0;\n}\n\n.react-flow__node-toolbar .components-toolbar {\n height: 30px !important;\n min-height: 20px;\n}\n\n.react-flow__node-toolbar .components-toolbar > div {\n min-width: 30px;\n}\n\n.react-flow__node-toolbar button.components-button.components-toolbar__control.has-icon {\n min-width: 30px !important;\n height: 30px !important;\n} */\n",""]);const l=i},1461:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,".publishpress-future-date-preview .publishpress-future-date-preview-value {\n font-family: monospace;\n background-color: #e7e7e7;\n padding: 2px 4px;\n}\n\n.publishpress-future-date-preview.compact .publishpress-future-date-preview-label {\n display: block;\n}\n\n.publishpress-future-date-preview.compact {\n margin-bottom: 8px;\n}\n\n.publishpress-future-date-preview.compact h4 {\n font-size: 11px;\n font-weight: 500;\n line-height: 1.4;\n text-transform: uppercase;\n display: inline-block;\n margin-bottom: calc(8px);\n padding: 0px;\n flex-shrink: 0;\n margin-right: 12px;\n max-width: 75%;\n margin-top: 0;\n}\n\n.publishpress-future-notice.publishpress-future-notice-error {\n color: #dc3232;\n}\n",""]);const l=i},3133:(e,t,n)=>{"use strict";n.d(t,{A:()=>v});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a),l=n(6943),s=n(2158),c=n(7448),u=n(4259),d=n(1578),f=n(8565),p=n(7860),h=n(269),m=n(4143),g=n(8501),b=n(217),y=i()(o());y.i(l.A),y.i(s.A),y.i(c.A),y.i(u.A),y.i(d.A),y.i(f.A),y.i(p.A),y.i(h.A),y.i(m.A),y.i(g.A),y.i(b.A),y.push([e.id,".reactflow-wrapper {\n height: 100%;\n}\n\n.components-notice {\n padding: 0 12px;\n}\n\n.components-notice-list .components-notice__dismiss {\n margin-top: 12px;\n}\n",""]);const v=y},6241:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,'.ruleGroup{display:flex;flex-direction:column;gap:.5rem;padding:.5rem;border-width:1px}.ruleGroup .ruleGroup-body{display:flex;flex-direction:column;gap:.5rem}.ruleGroup .ruleGroup-body:empty{display:none}.ruleGroup .ruleGroup-header,.ruleGroup .rule{display:flex;gap:.5rem;align-items:center}.ruleGroup .rule .rule-value:has(.rule-value-list-item){display:flex;gap:.5rem;align-items:baseline}.ruleGroup .betweenRules{display:flex}.ruleGroup .shiftActions{display:flex;flex-direction:column}.ruleGroup .shiftActions>*{padding:0}.dndOver.rule,.dndOver.ruleGroup-header{padding-bottom:.5rem}.dndOver.betweenRules{padding-top:.5rem}.queryBuilder-branches .ruleGroup-body{margin-left:calc(2*0.5rem)}.queryBuilder-branches .rule,.queryBuilder-branches .ruleGroup .ruleGroup{position:relative}.queryBuilder-branches .rule::before,.queryBuilder-branches .rule::after,.queryBuilder-branches .ruleGroup .ruleGroup::before,.queryBuilder-branches .ruleGroup .ruleGroup::after{content:"";width:.5rem;left:calc(-0.5rem - 1px);border-radius:0;position:absolute}.queryBuilder-branches .rule::before,.queryBuilder-branches .ruleGroup .ruleGroup::before{top:-0.5rem;height:calc(50% + 0.5rem);border-width:0 0 1px 1px}.queryBuilder-branches .rule::after,.queryBuilder-branches .ruleGroup .ruleGroup::after{top:50%;height:50%;border-width:0 0 0 1px}.queryBuilder-branches .rule:last-child::after,.queryBuilder-branches .ruleGroup .ruleGroup:last-child::after{display:none}.queryBuilder-branches .ruleGroup .ruleGroup::before,.queryBuilder-branches .ruleGroup .ruleGroup::after{left:calc(-0.5rem - 1px - 1px)}.queryBuilder-branches .ruleGroup .ruleGroup::before{top:calc(-0.5rem - 1px);height:calc(50% + 0.5rem + 1px)}.queryBuilder-branches .ruleGroup .ruleGroup::after{height:calc(50% + 1px)}.queryBuilder-branches .betweenRules{position:relative}.queryBuilder-branches .betweenRules::before{content:"";width:.5rem;left:calc(-0.5rem - 1px);border-radius:0;position:absolute;top:-0.5rem;height:calc(100% + 0.5rem);border-width:0 0 0 1px}.ruleGroup{border-color:#8081a2;border-style:solid;border-radius:.25rem;background:rgba(0,75,183,.2)}.ruleGroup .shiftActions>*{background-color:rgba(0,0,0,0);border:none;cursor:pointer}.dndOver.rule,.dndOver.ruleGroup-header{border-bottom-width:2px;border-bottom-style:dashed;border-bottom-color:#639}.dndOver.rule.dndCopy,.dndOver.ruleGroup-header.dndCopy{border-bottom-color:#693}.dndOver.betweenRules{border-top-width:2px;border-top-style:dashed;border-top-color:#639}.dndOver.betweenRules.dndCopy{border-top-color:#693}.ruleGroup.dndDragging,.rule.dndDragging{opacity:.5}.ruleGroup .queryBuilder-dragHandle,.rule .queryBuilder-dragHandle{cursor:move}.queryBuilder-branches .rule::before,.queryBuilder-branches .rule::after,.queryBuilder-branches .ruleGroup .ruleGroup::before,.queryBuilder-branches .ruleGroup .ruleGroup::after{border-color:#8081a2;border-style:solid}.queryBuilder-branches .rule:last-child::before,.queryBuilder-branches .ruleGroup .ruleGroup:last-child::before{border-bottom-left-radius:.25rem}.queryBuilder-branches .betweenRules{position:relative}.queryBuilder-branches .betweenRules::before{border-color:#8081a2;border-style:solid}',""]);const l=i},2672:(e,t,n)=>{"use strict";n.d(t,{A:()=>l});var r=n(1601),o=n.n(r),a=n(6314),i=n.n(a)()(o());i.push([e.id,"/* this gets exported as style.css and can be used for the default theming */\n/* these are the necessary styles for React Flow, they get used by base.css and style.css */\n.react-flow {\n direction: ltr;\n}\n.react-flow__container {\n position: absolute;\n width: 100%;\n height: 100%;\n top: 0;\n left: 0;\n}\n.react-flow__pane {\n z-index: 1;\n cursor: -webkit-grab;\n cursor: grab;\n}\n.react-flow__pane.selection {\n cursor: pointer;\n }\n.react-flow__pane.dragging {\n cursor: -webkit-grabbing;\n cursor: grabbing;\n }\n.react-flow__viewport {\n transform-origin: 0 0;\n z-index: 2;\n pointer-events: none;\n}\n.react-flow__renderer {\n z-index: 4;\n}\n.react-flow__selection {\n z-index: 6;\n}\n.react-flow__nodesselection-rect:focus,\n.react-flow__nodesselection-rect:focus-visible {\n outline: none;\n}\n.react-flow .react-flow__edges {\n pointer-events: none;\n overflow: visible;\n}\n.react-flow__edge-path,\n.react-flow__connection-path {\n stroke: #b1b1b7;\n stroke-width: 1;\n fill: none;\n}\n.react-flow__edge {\n pointer-events: visibleStroke;\n cursor: pointer;\n}\n.react-flow__edge.animated path {\n stroke-dasharray: 5;\n -webkit-animation: dashdraw 0.5s linear infinite;\n animation: dashdraw 0.5s linear infinite;\n }\n.react-flow__edge.animated path.react-flow__edge-interaction {\n stroke-dasharray: none;\n -webkit-animation: none;\n animation: none;\n }\n.react-flow__edge.inactive {\n pointer-events: none;\n }\n.react-flow__edge.selected,\n .react-flow__edge:focus,\n .react-flow__edge:focus-visible {\n outline: none;\n }\n.react-flow__edge.selected .react-flow__edge-path,\n .react-flow__edge:focus .react-flow__edge-path,\n .react-flow__edge:focus-visible .react-flow__edge-path {\n stroke: #555;\n }\n.react-flow__edge-textwrapper {\n pointer-events: all;\n }\n.react-flow__edge-textbg {\n fill: white;\n }\n.react-flow__edge .react-flow__edge-text {\n pointer-events: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none;\n }\n.react-flow__connection {\n pointer-events: none;\n}\n.react-flow__connection .animated {\n stroke-dasharray: 5;\n -webkit-animation: dashdraw 0.5s linear infinite;\n animation: dashdraw 0.5s linear infinite;\n }\n.react-flow__connectionline {\n z-index: 1001;\n}\n.react-flow__nodes {\n pointer-events: none;\n transform-origin: 0 0;\n}\n.react-flow__node {\n position: absolute;\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none;\n pointer-events: all;\n transform-origin: 0 0;\n box-sizing: border-box;\n cursor: -webkit-grab;\n cursor: grab;\n}\n.react-flow__node.dragging {\n cursor: -webkit-grabbing;\n cursor: grabbing;\n }\n.react-flow__nodesselection {\n z-index: 3;\n transform-origin: left top;\n pointer-events: none;\n}\n.react-flow__nodesselection-rect {\n position: absolute;\n pointer-events: all;\n cursor: -webkit-grab;\n cursor: grab;\n }\n.react-flow__handle {\n position: absolute;\n pointer-events: none;\n min-width: 5px;\n min-height: 5px;\n width: 6px;\n height: 6px;\n background: #1a192b;\n border: 1px solid white;\n border-radius: 100%;\n}\n.react-flow__handle.connectionindicator {\n pointer-events: all;\n cursor: crosshair;\n }\n.react-flow__handle-bottom {\n top: auto;\n left: 50%;\n bottom: -4px;\n transform: translate(-50%, 0);\n }\n.react-flow__handle-top {\n left: 50%;\n top: -4px;\n transform: translate(-50%, 0);\n }\n.react-flow__handle-left {\n top: 50%;\n left: -4px;\n transform: translate(0, -50%);\n }\n.react-flow__handle-right {\n right: -4px;\n top: 50%;\n transform: translate(0, -50%);\n }\n.react-flow__edgeupdater {\n cursor: move;\n pointer-events: all;\n}\n.react-flow__panel {\n position: absolute;\n z-index: 5;\n margin: 15px;\n}\n.react-flow__panel.top {\n top: 0;\n }\n.react-flow__panel.bottom {\n bottom: 0;\n }\n.react-flow__panel.left {\n left: 0;\n }\n.react-flow__panel.right {\n right: 0;\n }\n.react-flow__panel.center {\n left: 50%;\n transform: translateX(-50%);\n }\n.react-flow__attribution {\n font-size: 10px;\n background: rgba(255, 255, 255, 0.5);\n padding: 2px 3px;\n margin: 0;\n}\n.react-flow__attribution a {\n text-decoration: none;\n color: #999;\n }\n@-webkit-keyframes dashdraw {\n from {\n stroke-dashoffset: 10;\n }\n}\n@keyframes dashdraw {\n from {\n stroke-dashoffset: 10;\n }\n}\n.react-flow__edgelabel-renderer {\n position: absolute;\n width: 100%;\n height: 100%;\n pointer-events: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none;\n}\n.react-flow__edge.updating .react-flow__edge-path {\n stroke: #777;\n }\n.react-flow__edge-text {\n font-size: 10px;\n }\n.react-flow__node.selectable:focus,\n .react-flow__node.selectable:focus-visible {\n outline: none;\n }\n.react-flow__node-default,\n.react-flow__node-input,\n.react-flow__node-output,\n.react-flow__node-group {\n padding: 10px;\n border-radius: 3px;\n width: 150px;\n font-size: 12px;\n color: #222;\n text-align: center;\n border-width: 1px;\n border-style: solid;\n border-color: #1a192b;\n background-color: white;\n}\n.react-flow__node-default.selectable:hover, .react-flow__node-input.selectable:hover, .react-flow__node-output.selectable:hover, .react-flow__node-group.selectable:hover {\n box-shadow: 0 1px 4px 1px rgba(0, 0, 0, 0.08);\n }\n.react-flow__node-default.selectable.selected,\n .react-flow__node-default.selectable:focus,\n .react-flow__node-default.selectable:focus-visible,\n .react-flow__node-input.selectable.selected,\n .react-flow__node-input.selectable:focus,\n .react-flow__node-input.selectable:focus-visible,\n .react-flow__node-output.selectable.selected,\n .react-flow__node-output.selectable:focus,\n .react-flow__node-output.selectable:focus-visible,\n .react-flow__node-group.selectable.selected,\n .react-flow__node-group.selectable:focus,\n .react-flow__node-group.selectable:focus-visible {\n box-shadow: 0 0 0 0.5px #1a192b;\n }\n.react-flow__node-group {\n background-color: rgba(240, 240, 240, 0.25);\n}\n.react-flow__nodesselection-rect,\n.react-flow__selection {\n background: rgba(0, 89, 220, 0.08);\n border: 1px dotted rgba(0, 89, 220, 0.8);\n}\n.react-flow__nodesselection-rect:focus,\n .react-flow__nodesselection-rect:focus-visible,\n .react-flow__selection:focus,\n .react-flow__selection:focus-visible {\n outline: none;\n }\n.react-flow__controls {\n box-shadow: 0 0 2px 1px rgba(0, 0, 0, 0.08);\n}\n.react-flow__controls-button {\n border: none;\n background: #fefefe;\n border-bottom: 1px solid #eee;\n box-sizing: content-box;\n display: flex;\n justify-content: center;\n align-items: center;\n width: 16px;\n height: 16px;\n cursor: pointer;\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none;\n padding: 5px;\n }\n.react-flow__controls-button:hover {\n background: #f4f4f4;\n }\n.react-flow__controls-button svg {\n width: 100%;\n max-width: 12px;\n max-height: 12px;\n }\n.react-flow__controls-button:disabled {\n pointer-events: none;\n }\n.react-flow__controls-button:disabled svg {\n fill-opacity: 0.4;\n }\n.react-flow__minimap {\n background-color: #fff;\n}\n.react-flow__minimap svg {\n display: block;\n}\n.react-flow__resize-control {\n position: absolute;\n}\n.react-flow__resize-control.left,\n.react-flow__resize-control.right {\n cursor: ew-resize;\n}\n.react-flow__resize-control.top,\n.react-flow__resize-control.bottom {\n cursor: ns-resize;\n}\n.react-flow__resize-control.top.left,\n.react-flow__resize-control.bottom.right {\n cursor: nwse-resize;\n}\n.react-flow__resize-control.bottom.left,\n.react-flow__resize-control.top.right {\n cursor: nesw-resize;\n}\n/* handle styles */\n.react-flow__resize-control.handle {\n width: 4px;\n height: 4px;\n border: 1px solid #fff;\n border-radius: 1px;\n background-color: #3367d9;\n transform: translate(-50%, -50%);\n}\n.react-flow__resize-control.handle.left {\n left: 0;\n top: 50%;\n}\n.react-flow__resize-control.handle.right {\n left: 100%;\n top: 50%;\n}\n.react-flow__resize-control.handle.top {\n left: 50%;\n top: 0;\n}\n.react-flow__resize-control.handle.bottom {\n left: 50%;\n top: 100%;\n}\n.react-flow__resize-control.handle.top.left {\n left: 0;\n}\n.react-flow__resize-control.handle.bottom.left {\n left: 0;\n}\n.react-flow__resize-control.handle.top.right {\n left: 100%;\n}\n.react-flow__resize-control.handle.bottom.right {\n left: 100%;\n}\n/* line styles */\n.react-flow__resize-control.line {\n border-color: #3367d9;\n border-width: 0;\n border-style: solid;\n}\n.react-flow__resize-control.line.left,\n.react-flow__resize-control.line.right {\n width: 1px;\n transform: translate(-50%, 0);\n top: 0;\n height: 100%;\n}\n.react-flow__resize-control.line.left {\n left: 0;\n border-left-width: 1px;\n}\n.react-flow__resize-control.line.right {\n left: 100%;\n border-right-width: 1px;\n}\n.react-flow__resize-control.line.top,\n.react-flow__resize-control.line.bottom {\n height: 1px;\n transform: translate(0, -50%);\n left: 0;\n width: 100%;\n}\n.react-flow__resize-control.line.top {\n top: 0;\n border-top-width: 1px;\n}\n.react-flow__resize-control.line.bottom {\n border-bottom-width: 1px;\n top: 100%;\n}\n",""]);const l=i},6314:e=>{"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",r=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),r&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),r&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,r,o,a){"string"==typeof e&&(e=[[null,e,void 0]]);var i={};if(r)for(var l=0;l0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=a),n&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=n):u[2]=n),o&&(u[4]?(u[1]="@supports (".concat(u[4],") {").concat(u[1],"}"),u[4]=o):u[4]="".concat(o)),t.push(u))}},t}},1601:e=>{"use strict";e.exports=function(e){return e[1]}},124:e=>{"use strict";var t,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,o=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,i={};((e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})})(i,{Immer:()=>Y,applyPatches:()=>ie,castDraft:()=>ce,castImmutable:()=>ue,createDraft:()=>le,current:()=>Q,enableMapSet:()=>ee,enablePatches:()=>J,finishDraft:()=>se,freeze:()=>R,immerable:()=>s,isDraft:()=>f,isDraftable:()=>p,nothing:()=>l,original:()=>g,produce:()=>ne,produceWithPatches:()=>re,setAutoFreeze:()=>oe,setUseStrictShallowCopy:()=>ae}),e.exports=(t=i,((e,t,i,l)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of o(t))!a.call(e,i)&&undefined!==i&&n(e,i,{get:()=>t[i],enumerable:!(l=r(t,i))||l.enumerable});return e})(n({},"__esModule",{value:!0}),t));var l=Symbol.for("immer-nothing"),s=Symbol.for("immer-draftable"),c=Symbol.for("immer-state");function u(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var d=Object.getPrototypeOf;function f(e){return!!e&&!!e[c]}function p(e){return!!e&&(m(e)||Array.isArray(e)||!!e[s]||!!e.constructor?.[s]||E(e)||x(e))}var h=Object.prototype.constructor.toString();function m(e){if(!e||"object"!=typeof e)return!1;let t=d(e);if(null===t)return!0;let n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return n===Object||"function"==typeof n&&Function.toString.call(n)===h}function g(e){return f(e)||u(15),e[c].t}function b(e,t){0===y(e)?Reflect.ownKeys(e).forEach((n=>{t(n,e[n],e)})):e.forEach(((n,r)=>t(r,n,e)))}function y(e){let t=e[c];return t?t.o:Array.isArray(e)?1:E(e)?2:x(e)?3:0}function v(e,t){return 2===y(e)?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function w(e,t){return 2===y(e)?e.get(t):e[t]}function _(e,t,n){let r=y(e);2===r?e.set(t,n):3===r?e.add(n):e[t]=n}function E(e){return e instanceof Map}function x(e){return e instanceof Set}function S(e){return e.e||e.t}function k(e,t){if(E(e))return new Map(e);if(x(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);let n=m(e);if(!0===t||"class_only"===t&&!n){let t=Object.getOwnPropertyDescriptors(e);delete t[c];let n=Reflect.ownKeys(t);for(let r=0;r1&&(e.set=e.add=e.clear=e.delete=N),Object.freeze(e),t&&Object.entries(e).forEach((([e,t])=>R(t,!0)))),e}function N(){u(2)}function C(e){return Object.isFrozen(e)}var O,A={};function P(e){let t=A[e];return t||u(0),t}function D(e,t){A[e]||(A[e]=t)}function T(){return O}function I(e,t){t&&(P("Patches"),e.f=[],e.h=[],e.b=t)}function j(e){M(e),e.a.forEach(L),e.a=null}function M(e){e===O&&(O=e.i)}function $(e){return O=function(e,t){return{a:[],i:e,p:t,P:!0,d:0}}(O,e)}function L(e){let t=e[c];0===t.o||1===t.o?t.x():t.m=!0}function z(e,t){t.d=t.a.length;let n=t.a[0];return void 0!==e&&e!==n?(n[c].s&&(j(t),u(4)),p(e)&&(e=F(t,e),t.i||G(t,e)),t.f&&P("Patches").T(n[c].t,e,t.f,t.h)):e=F(t,n,[]),j(t),t.f&&t.b(t.f,t.h),e!==l?e:void 0}function F(e,t,n){if(C(t))return t;let r=t[c];if(!r)return b(t,((o,a)=>W(e,r,t,o,a,n))),t;if(r.n!==e)return t;if(!r.s)return G(e,r.t,!0),r.t;if(!r.c){r.c=!0,r.n.d--;let t=r.e,o=t,a=!1;3===r.o&&(o=new Set(t),t.clear(),a=!0),b(o,((o,i)=>W(e,r,t,o,i,n,a))),G(e,t,!1),n&&e.f&&P("Patches").g(r,n,e.f,e.h)}return r.e}function W(e,t,n,r,o,a,i){if(f(o)){let i=F(e,o,a&&t&&3!==t.o&&!v(t.r,r)?a.concat(r):void 0);if(_(n,r,i),!f(i))return;e.P=!1}else i&&n.add(o);if(p(o)&&!C(o)){if(!e.p.y&&e.d<1)return;F(e,o),(!t||!t.n.i)&&"symbol"!=typeof r&&Object.prototype.propertyIsEnumerable.call(n,r)&&G(e,o)}}function G(e,t,n=!1){!e.i&&e.p.y&&e.P&&R(t,n)}var B={get(e,t){if(t===c)return e;let n=S(e);if(!v(n,t))return function(e,t,n){let r=U(t,n);return r?"value"in r?r.value:r.get?.call(e.u):void 0}(e,n,t);let r=n[t];return e.c||!p(r)?r:r===H(e.t,t)?(X(e),e.e[t]=K(r,e)):r},has:(e,t)=>t in S(e),ownKeys:e=>Reflect.ownKeys(S(e)),set(e,t,n){let r=U(S(e),t);if(r?.set)return r.set.call(e.u,n),!0;if(!e.s){let r=H(S(e),t),o=r?.[c];if(o&&o.t===n)return e.e[t]=n,e.r[t]=!1,!0;if(function(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}(n,r)&&(void 0!==n||v(e.t,t)))return!0;X(e),q(e)}return e.e[t]===n&&(void 0!==n||t in e.e)||Number.isNaN(n)&&Number.isNaN(e.e[t])||(e.e[t]=n,e.r[t]=!0),!0},deleteProperty:(e,t)=>(void 0!==H(e.t,t)||t in e.t?(e.r[t]=!1,X(e),q(e)):delete e.r[t],e.e&&delete e.e[t],!0),getOwnPropertyDescriptor(e,t){let n=S(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{writable:!0,configurable:1!==e.o||"length"!==t,enumerable:r.enumerable,value:n[t]}},defineProperty(){u(11)},getPrototypeOf:e=>d(e.t),setPrototypeOf(){u(12)}},V={};function H(e,t){let n=e[c];return(n?S(n):e)[t]}function U(e,t){if(!(t in e))return;let n=d(e);for(;n;){let e=Object.getOwnPropertyDescriptor(n,t);if(e)return e;n=d(n)}}function q(e){e.s||(e.s=!0,e.i&&q(e.i))}function X(e){e.e||(e.e=k(e.t,e.n.p.S))}b(B,((e,t)=>{V[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}})),V.deleteProperty=function(e,t){return V.set.call(this,e,t,void 0)},V.set=function(e,t,n){return B.set.call(this,e[0],t,n,e[0])};var Y=class{constructor(e){this.y=!0,this.S=!1,this.produce=(e,t,n)=>{if("function"==typeof e&&"function"!=typeof t){let n=t;t=e;let r=this;return function(e=n,...o){return r.produce(e,(e=>t.call(this,e,...o)))}}let r;if("function"!=typeof t&&u(6),void 0!==n&&"function"!=typeof n&&u(7),p(e)){let o=$(this),a=K(e,void 0),i=!0;try{r=t(a),i=!1}finally{i?j(o):M(o)}return I(o,n),z(r,o)}if(!e||"object"!=typeof e){if(r=t(e),void 0===r&&(r=e),r===l&&(r=void 0),this.y&&R(r,!0),n){let t=[],o=[];P("Patches").T(e,r,t,o),n(t,o)}return r}u(1)},this.produceWithPatches=(e,t)=>{if("function"==typeof e)return(t,...n)=>this.produceWithPatches(t,(t=>e(t,...n)));let n,r;return[this.produce(e,t,((e,t)=>{n=e,r=t})),n,r]},"boolean"==typeof e?.autoFreeze&&this.setAutoFreeze(e.autoFreeze),"boolean"==typeof e?.useStrictShallowCopy&&this.setUseStrictShallowCopy(e.useStrictShallowCopy)}createDraft(e){p(e)||u(8),f(e)&&(e=Q(e));let t=$(this),n=K(e,void 0);return n[c].l=!0,M(t),n}finishDraft(e,t){let n=e&&e[c];(!n||!n.l)&&u(9);let{n:r}=n;return I(r,t),z(void 0,r)}setAutoFreeze(e){this.y=e}setUseStrictShallowCopy(e){this.S=e}applyPatches(e,t){let n;for(n=t.length-1;n>=0;n--){let r=t[n];if(0===r.path.length&&"replace"===r.op){e=r.value;break}}n>-1&&(t=t.slice(n+1));let r=P("Patches").A;return f(e)?r(e,t):this.produce(e,(e=>r(e,t)))}};function K(e,t){let n=E(e)?P("MapSet").I(e,t):x(e)?P("MapSet").D(e,t):function(e,t){let n=Array.isArray(e),r={o:n?1:0,n:t?t.n:T(),s:!1,c:!1,r:{},i:t,t:e,u:null,e:null,x:null,l:!1},o=r,a=B;n&&(o=[r],a=V);let{revoke:i,proxy:l}=Proxy.revocable(o,a);return r.u=l,r.x=i,l}(e,t);return(t?t.n:T()).a.push(n),n}function Q(e){return f(e)||u(10),Z(e)}function Z(e){if(!p(e)||C(e))return e;let t,n=e[c];if(n){if(!n.s)return n.t;n.c=!0,t=k(e,n.n.p.S)}else t=k(e,!0);return b(t,((e,n)=>{_(t,e,Z(n))})),n&&(n.c=!1),t}function J(){let e="replace",t="add",n="remove";function r(e){if(!p(e))return e;if(Array.isArray(e))return e.map(r);if(E(e))return new Map(Array.from(e.entries()).map((([e,t])=>[e,r(t)])));if(x(e))return new Set(Array.from(e).map(r));let t=Object.create(d(e));for(let n in e)t[n]=r(e[n]);return v(e,s)&&(t[s]=e[s]),t}function o(e){return f(e)?r(e):e}D("Patches",{A:function(o,a){return a.forEach((a=>{let{path:i,op:l}=a,s=o;for(let e=0;e{let d=w(s,r),f=w(c,r),p=u?v(s,r)?e:t:n;if(d===f&&p===e)return;let h=a.concat(r);i.push(p===n?{op:p,path:h}:{op:p,path:h,value:f}),l.push(p===t?{op:n,path:h}:p===n?{op:t,path:h,value:o(d)}:{op:e,path:h,value:o(d)})}))}(r,a,i,l);case 1:return function(r,a,i,l){let{t:s,r:c}=r,u=r.e;u.length{if(!l.has(e)){let i=r.concat([s]);o.push({op:n,path:i,value:e}),a.unshift({op:t,path:i,value:e})}s++})),s=0,l.forEach((e=>{if(!i.has(e)){let i=r.concat([s]);o.push({op:t,path:i,value:e}),a.unshift({op:n,path:i,value:e})}s++}))}(r,a,i,l)}},T:function(t,n,r,o){r.push({op:e,path:[],value:n===l?void 0:n}),o.push({op:e,path:[],value:t})}})}function ee(){class e extends Map{constructor(e,t){super(),this[c]={o:2,i:t,n:t?t.n:T(),s:!1,c:!1,e:void 0,r:void 0,t:e,u:this,l:!1,m:!1}}get size(){return S(this[c]).size}has(e){return S(this[c]).has(e)}set(e,n){let r=this[c];return o(r),(!S(r).has(e)||S(r).get(e)!==n)&&(t(r),q(r),r.r.set(e,!0),r.e.set(e,n),r.r.set(e,!0)),this}delete(e){if(!this.has(e))return!1;let n=this[c];return o(n),t(n),q(n),n.t.has(e)?n.r.set(e,!1):n.r.delete(e),n.e.delete(e),!0}clear(){let e=this[c];o(e),S(e).size&&(t(e),q(e),e.r=new Map,b(e.t,(t=>{e.r.set(t,!1)})),e.e.clear())}forEach(e,t){S(this[c]).forEach(((n,r,o)=>{e.call(t,this.get(r),r,this)}))}get(e){let n=this[c];o(n);let r=S(n).get(e);if(n.c||!p(r)||r!==n.t.get(e))return r;let a=K(r,n);return t(n),n.e.set(e,a),a}keys(){return S(this[c]).keys()}values(){let e=this.keys();return{[Symbol.iterator]:()=>this.values(),next:()=>{let t=e.next();return t.done?t:{done:!1,value:this.get(t.value)}}}}entries(){let e=this.keys();return{[Symbol.iterator]:()=>this.entries(),next:()=>{let t=e.next();if(t.done)return t;let n=this.get(t.value);return{done:!1,value:[t.value,n]}}}}[Symbol.iterator](){return this.entries()}}function t(e){e.e||(e.r=new Map,e.e=new Map(e.t))}class n extends Set{constructor(e,t){super(),this[c]={o:3,i:t,n:t?t.n:T(),s:!1,c:!1,e:void 0,t:e,u:this,a:new Map,m:!1,l:!1}}get size(){return S(this[c]).size}has(e){let t=this[c];return o(t),t.e?!!(t.e.has(e)||t.a.has(e)&&t.e.has(t.a.get(e))):t.t.has(e)}add(e){let t=this[c];return o(t),this.has(e)||(r(t),q(t),t.e.add(e)),this}delete(e){if(!this.has(e))return!1;let t=this[c];return o(t),r(t),q(t),t.e.delete(e)||!!t.a.has(e)&&t.e.delete(t.a.get(e))}clear(){let e=this[c];o(e),S(e).size&&(r(e),q(e),e.e.clear())}values(){let e=this[c];return o(e),r(e),e.e.values()}entries(){let e=this[c];return o(e),r(e),e.e.entries()}keys(){return this.values()}[Symbol.iterator](){return this.values()}forEach(e,t){let n=this.values(),r=n.next();for(;!r.done;)e.call(t,r.value,r.value,this),r=n.next()}}function r(e){e.e||(e.e=new Set,e.t.forEach((t=>{if(p(t)){let n=K(t,e);e.a.set(t,n),e.e.add(n)}else e.e.add(t)})))}function o(e){e.m&&u(3,JSON.stringify(S(e)))}D("MapSet",{I:function(t,n){return new e(t,n)},D:function(e,t){return new n(e,t)}})}var te=new Y,ne=te.produce,re=te.produceWithPatches.bind(te),oe=te.setAutoFreeze.bind(te),ae=te.setUseStrictShallowCopy.bind(te),ie=te.applyPatches.bind(te),le=te.createDraft.bind(te),se=te.finishDraft.bind(te);function ce(e){return e}function ue(e){return e}},9407:(e,t,n)=>{"use strict";e.exports=n(124)},5580:(e,t,n)=>{var r=n(6110)(n(9325),"DataView");e.exports=r},1549:(e,t,n)=>{var r=n(2032),o=n(3862),a=n(6721),i=n(2749),l=n(5749);function s(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t{var r=n(9344),o=n(4033);function a(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=4294967295,this.__views__=[]}a.prototype=r(o.prototype),a.prototype.constructor=a,e.exports=a},79:(e,t,n)=>{var r=n(3702),o=n(80),a=n(4739),i=n(1036),l=n(1175);function s(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t{var r=n(9344),o=n(4033);function a(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=void 0}a.prototype=r(o.prototype),a.prototype.constructor=a,e.exports=a},8223:(e,t,n)=>{var r=n(6110)(n(9325),"Map");e.exports=r},3661:(e,t,n)=>{var r=n(3040),o=n(7670),a=n(289),i=n(4509),l=n(2949);function s(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t{var r=n(6110)(n(9325),"Promise");e.exports=r},6545:(e,t,n)=>{var r=n(6110)(n(9325),"Set");e.exports=r},8859:(e,t,n)=>{var r=n(3661),o=n(1380),a=n(1459);function i(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new r;++t{var r=n(79),o=n(1420),a=n(938),i=n(3605),l=n(9817),s=n(945);function c(e){var t=this.__data__=new r(e);this.size=t.size}c.prototype.clear=o,c.prototype.delete=a,c.prototype.get=i,c.prototype.has=l,c.prototype.set=s,e.exports=c},1873:(e,t,n)=>{var r=n(9325).Symbol;e.exports=r},7828:(e,t,n)=>{var r=n(9325).Uint8Array;e.exports=r},8303:(e,t,n)=>{var r=n(6110)(n(9325),"WeakMap");e.exports=r},1033:e=>{e.exports=function(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}},3945:e=>{e.exports=function(e,t,n,r){for(var o=-1,a=null==e?0:e.length;++o{e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length;++n{e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length,o=0,a=[];++n{var r=n(6131);e.exports=function(e,t){return!(null==e||!e.length)&&r(e,t,0)>-1}},9905:e=>{e.exports=function(e,t,n){for(var r=-1,o=null==e?0:e.length;++r{var r=n(8096),o=n(2428),a=n(6449),i=n(3656),l=n(361),s=n(7167),c=Object.prototype.hasOwnProperty;e.exports=function(e,t){var n=a(e),u=!n&&o(e),d=!n&&!u&&i(e),f=!n&&!u&&!d&&s(e),p=n||u||d||f,h=p?r(e.length,String):[],m=h.length;for(var g in e)!t&&!c.call(e,g)||p&&("length"==g||d&&("offset"==g||"parent"==g)||f&&("buffer"==g||"byteLength"==g||"byteOffset"==g)||l(g,m))||h.push(g);return h}},4932:e=>{e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length,o=Array(r);++n{e.exports=function(e,t){for(var n=-1,r=t.length,o=e.length;++n{e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length;++n{var t=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;e.exports=function(e){return e.match(t)||[]}},6025:(e,t,n)=>{var r=n(5288);e.exports=function(e,t){for(var n=e.length;n--;)if(r(e[n][0],t))return n;return-1}},2429:(e,t,n)=>{var r=n(909);e.exports=function(e,t,n,o){return r(e,(function(e,r,a){t(o,e,n(e),a)})),o}},3360:(e,t,n)=>{var r=n(3243);e.exports=function(e,t,n){"__proto__"==t&&r?r(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}},9344:(e,t,n)=>{var r=n(3805),o=Object.create,a=function(){function e(){}return function(t){if(!r(t))return{};if(o)return o(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();e.exports=a},3915:(e,t,n)=>{var r=n(8859),o=n(5325),a=n(9905),i=n(4932),l=n(7301),s=n(9219);e.exports=function(e,t,n,c){var u=-1,d=o,f=!0,p=e.length,h=[],m=t.length;if(!p)return h;n&&(t=i(t,l(n))),c?(d=a,f=!1):t.length>=200&&(d=s,f=!1,t=new r(t));e:for(;++u{var r=n(641),o=n(8329)(r);e.exports=o},6574:(e,t,n)=>{var r=n(909);e.exports=function(e,t){var n=[];return r(e,(function(e,r,o){t(e,r,o)&&n.push(e)})),n}},2523:e=>{e.exports=function(e,t,n,r){for(var o=e.length,a=n+(r?1:-1);r?a--:++a{var r=n(4528),o=n(5891);e.exports=function e(t,n,a,i,l){var s=-1,c=t.length;for(a||(a=o),l||(l=[]);++s0&&a(u)?n>1?e(u,n-1,a,i,l):r(l,u):i||(l[l.length]=u)}return l}},6649:(e,t,n)=>{var r=n(3221)();e.exports=r},641:(e,t,n)=>{var r=n(6649),o=n(5950);e.exports=function(e,t){return e&&r(e,t,o)}},7422:(e,t,n)=>{var r=n(1769),o=n(7797);e.exports=function(e,t){for(var n=0,a=(t=r(t,e)).length;null!=e&&n{var r=n(4528),o=n(6449);e.exports=function(e,t,n){var a=t(e);return o(e)?a:r(a,n(e))}},2552:(e,t,n)=>{var r=n(1873),o=n(659),a=n(9350),i=r?r.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":i&&i in Object(e)?o(e):a(e)}},8077:e=>{e.exports=function(e,t){return null!=e&&t in Object(e)}},6131:(e,t,n)=>{var r=n(2523),o=n(5463),a=n(6959);e.exports=function(e,t,n){return t==t?a(e,t,n):r(e,o,n)}},7534:(e,t,n)=>{var r=n(2552),o=n(346);e.exports=function(e){return o(e)&&"[object Arguments]"==r(e)}},270:(e,t,n)=>{var r=n(7068),o=n(346);e.exports=function e(t,n,a,i,l){return t===n||(null==t||null==n||!o(t)&&!o(n)?t!=t&&n!=n:r(t,n,a,i,e,l))}},7068:(e,t,n)=>{var r=n(7217),o=n(5911),a=n(1986),i=n(689),l=n(5861),s=n(6449),c=n(3656),u=n(7167),d="[object Arguments]",f="[object Array]",p="[object Object]",h=Object.prototype.hasOwnProperty;e.exports=function(e,t,n,m,g,b){var y=s(e),v=s(t),w=y?f:l(e),_=v?f:l(t),E=(w=w==d?p:w)==p,x=(_=_==d?p:_)==p,S=w==_;if(S&&c(e)){if(!c(t))return!1;y=!0,E=!1}if(S&&!E)return b||(b=new r),y||u(e)?o(e,t,n,m,g,b):a(e,t,w,n,m,g,b);if(!(1&n)){var k=E&&h.call(e,"__wrapped__"),R=x&&h.call(t,"__wrapped__");if(k||R){var N=k?e.value():e,C=R?t.value():t;return b||(b=new r),g(N,C,n,m,b)}}return!!S&&(b||(b=new r),i(e,t,n,m,g,b))}},1799:(e,t,n)=>{var r=n(7217),o=n(270);e.exports=function(e,t,n,a){var i=n.length,l=i,s=!a;if(null==e)return!l;for(e=Object(e);i--;){var c=n[i];if(s&&c[2]?c[1]!==e[c[0]]:!(c[0]in e))return!1}for(;++i{e.exports=function(e){return e!=e}},5083:(e,t,n)=>{var r=n(1882),o=n(7296),a=n(3805),i=n(7473),l=/^\[object .+?Constructor\]$/,s=Function.prototype,c=Object.prototype,u=s.toString,d=c.hasOwnProperty,f=RegExp("^"+u.call(d).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=function(e){return!(!a(e)||o(e))&&(r(e)?f:l).test(i(e))}},4901:(e,t,n)=>{var r=n(2552),o=n(294),a=n(346),i={};i["[object Float32Array]"]=i["[object Float64Array]"]=i["[object Int8Array]"]=i["[object Int16Array]"]=i["[object Int32Array]"]=i["[object Uint8Array]"]=i["[object Uint8ClampedArray]"]=i["[object Uint16Array]"]=i["[object Uint32Array]"]=!0,i["[object Arguments]"]=i["[object Array]"]=i["[object ArrayBuffer]"]=i["[object Boolean]"]=i["[object DataView]"]=i["[object Date]"]=i["[object Error]"]=i["[object Function]"]=i["[object Map]"]=i["[object Number]"]=i["[object Object]"]=i["[object RegExp]"]=i["[object Set]"]=i["[object String]"]=i["[object WeakMap]"]=!1,e.exports=function(e){return a(e)&&o(e.length)&&!!i[r(e)]}},5389:(e,t,n)=>{var r=n(3663),o=n(7978),a=n(3488),i=n(6449),l=n(583);e.exports=function(e){return"function"==typeof e?e:null==e?a:"object"==typeof e?i(e)?o(e[0],e[1]):r(e):l(e)}},8984:(e,t,n)=>{var r=n(5527),o=n(3650),a=Object.prototype.hasOwnProperty;e.exports=function(e){if(!r(e))return o(e);var t=[];for(var n in Object(e))a.call(e,n)&&"constructor"!=n&&t.push(n);return t}},4033:e=>{e.exports=function(){}},5128:(e,t,n)=>{var r=n(909),o=n(4894);e.exports=function(e,t){var n=-1,a=o(e)?Array(e.length):[];return r(e,(function(e,r,o){a[++n]=t(e,r,o)})),a}},3663:(e,t,n)=>{var r=n(1799),o=n(776),a=n(7197);e.exports=function(e){var t=o(e);return 1==t.length&&t[0][2]?a(t[0][0],t[0][1]):function(n){return n===e||r(n,e,t)}}},7978:(e,t,n)=>{var r=n(270),o=n(8156),a=n(631),i=n(8586),l=n(756),s=n(7197),c=n(7797);e.exports=function(e,t){return i(e)&&l(t)?s(c(e),t):function(n){var i=o(n,e);return void 0===i&&i===t?a(n,e):r(t,i,3)}}},6155:(e,t,n)=>{var r=n(4932),o=n(7422),a=n(5389),i=n(5128),l=n(3937),s=n(7301),c=n(3714),u=n(3488),d=n(6449);e.exports=function(e,t,n){t=t.length?r(t,(function(e){return d(e)?function(t){return o(t,1===e.length?e[0]:e)}:e})):[u];var f=-1;t=r(t,s(a));var p=i(e,(function(e,n,o){return{criteria:r(t,(function(t){return t(e)})),index:++f,value:e}}));return l(p,(function(e,t){return c(e,t,n)}))}},7237:e=>{e.exports=function(e){return function(t){return null==t?void 0:t[e]}}},7255:(e,t,n)=>{var r=n(7422);e.exports=function(e){return function(t){return r(t,e)}}},4552:e=>{e.exports=function(e){return function(t){return null==e?void 0:e[t]}}},9302:(e,t,n)=>{var r=n(3488),o=n(6757),a=n(2865);e.exports=function(e,t){return a(o(e,t,r),e+"")}},8882:(e,t,n)=>{var r=n(3488),o=n(8152),a=o?function(e,t){return o.set(e,t),e}:r;e.exports=a},9570:(e,t,n)=>{var r=n(7334),o=n(3243),a=n(3488),i=o?function(e,t){return o(e,"toString",{configurable:!0,enumerable:!1,value:r(t),writable:!0})}:a;e.exports=i},3937:e=>{e.exports=function(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}},8096:e=>{e.exports=function(e,t){for(var n=-1,r=Array(e);++n{var r=n(1873),o=n(4932),a=n(6449),i=n(4394),l=r?r.prototype:void 0,s=l?l.toString:void 0;e.exports=function e(t){if("string"==typeof t)return t;if(a(t))return o(t,e)+"";if(i(t))return s?s.call(t):"";var n=t+"";return"0"==n&&1/t==-1/0?"-0":n}},4128:(e,t,n)=>{var r=n(1800),o=/^\s+/;e.exports=function(e){return e?e.slice(0,r(e)+1).replace(o,""):e}},7301:e=>{e.exports=function(e){return function(t){return e(t)}}},9219:e=>{e.exports=function(e,t){return e.has(t)}},1769:(e,t,n)=>{var r=n(6449),o=n(8586),a=n(1802),i=n(3222);e.exports=function(e,t){return r(e)?e:o(e,t)?[e]:a(i(e))}},3730:(e,t,n)=>{var r=n(4394);e.exports=function(e,t){if(e!==t){var n=void 0!==e,o=null===e,a=e==e,i=r(e),l=void 0!==t,s=null===t,c=t==t,u=r(t);if(!s&&!u&&!i&&e>t||i&&l&&c&&!s&&!u||o&&l&&c||!n&&c||!a)return 1;if(!o&&!i&&!u&&e{var r=n(3730);e.exports=function(e,t,n){for(var o=-1,a=e.criteria,i=t.criteria,l=a.length,s=n.length;++o=s?c:c*("desc"==n[o]?-1:1)}return e.index-t.index}},1596:e=>{var t=Math.max;e.exports=function(e,n,r,o){for(var a=-1,i=e.length,l=r.length,s=-1,c=n.length,u=t(i-l,0),d=Array(c+u),f=!o;++s{var t=Math.max;e.exports=function(e,n,r,o){for(var a=-1,i=e.length,l=-1,s=r.length,c=-1,u=n.length,d=t(i-s,0),f=Array(d+u),p=!o;++a{e.exports=function(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n{var r=n(9325)["__core-js_shared__"];e.exports=r},8523:e=>{e.exports=function(e,t){for(var n=e.length,r=0;n--;)e[n]===t&&++r;return r}},2e3:(e,t,n)=>{var r=n(3945),o=n(2429),a=n(5389),i=n(6449);e.exports=function(e,t){return function(n,l){var s=i(n)?r:o,c=t?t():{};return s(n,e,a(l,2),c)}}},8329:(e,t,n)=>{var r=n(4894);e.exports=function(e,t){return function(n,o){if(null==n)return n;if(!r(n))return e(n,o);for(var a=n.length,i=t?a:-1,l=Object(n);(t?i--:++i{e.exports=function(e){return function(t,n,r){for(var o=-1,a=Object(t),i=r(t),l=i.length;l--;){var s=i[e?l:++o];if(!1===n(a[s],s,a))break}return t}}},1842:(e,t,n)=>{var r=n(2819),o=n(9325);e.exports=function(e,t,n){var a=1&t,i=r(e);return function t(){return(this&&this!==o&&this instanceof t?i:e).apply(a?n:this,arguments)}}},2819:(e,t,n)=>{var r=n(9344),o=n(3805);e.exports=function(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var n=r(e.prototype),a=e.apply(n,t);return o(a)?a:n}}},7078:(e,t,n)=>{var r=n(1033),o=n(2819),a=n(7471),i=n(8073),l=n(1287),s=n(6306),c=n(9325);e.exports=function(e,t,n){var u=o(e);return function o(){for(var d=arguments.length,f=Array(d),p=d,h=l(o);p--;)f[p]=arguments[p];var m=d<3&&f[0]!==h&&f[d-1]!==h?[]:s(f,h);return(d-=m.length){var r=n(5389),o=n(4894),a=n(5950);e.exports=function(e){return function(t,n,i){var l=Object(t);if(!o(t)){var s=r(n,3);t=a(t),n=function(e){return s(l[e],e,l)}}var c=e(t,n,i);return c>-1?l[s?t[c]:c]:void 0}}},6929:(e,t,n)=>{var r=n(6017),o=n(8816),a=n(7381),i=n(2284),l=n(6449),s=n(5087);e.exports=function(e){return o((function(t){var n=t.length,o=n,c=r.prototype.thru;for(e&&t.reverse();o--;){var u=t[o];if("function"!=typeof u)throw new TypeError("Expected a function");if(c&&!d&&"wrapper"==i(u))var d=new r([],!0)}for(o=d?o:n;++o{var r=n(1596),o=n(3320),a=n(8523),i=n(2819),l=n(8073),s=n(1287),c=n(8294),u=n(6306),d=n(9325);e.exports=function e(t,n,f,p,h,m,g,b,y,v){var w=128&n,_=1&n,E=2&n,x=24&n,S=512&n,k=E?void 0:i(t);return function R(){for(var N=arguments.length,C=Array(N),O=N;O--;)C[O]=arguments[O];if(x)var A=s(R),P=a(C,A);if(p&&(C=r(C,p,h,x)),m&&(C=o(C,m,g,x)),N-=P,x&&N1&&C.reverse(),w&&y{var r=n(1033),o=n(2819),a=n(9325);e.exports=function(e,t,n,i){var l=1&t,s=o(e);return function t(){for(var o=-1,c=arguments.length,u=-1,d=i.length,f=Array(d+c),p=this&&this!==a&&this instanceof t?s:e;++u{var r=n(5087),o=n(4641),a=n(981);e.exports=function(e,t,n,i,l,s,c,u,d,f){var p=8&t;t|=p?32:64,4&(t&=~(p?64:32))||(t&=-4);var h=[e,t,l,p?s:void 0,p?c:void 0,p?void 0:s,p?void 0:c,u,d,f],m=n.apply(void 0,h);return r(e)&&o(m,h),m.placeholder=i,a(m,e,t)}},6977:(e,t,n)=>{var r=n(8882),o=n(1842),a=n(7078),i=n(7471),l=n(4168),s=n(7381),c=n(3209),u=n(4641),d=n(981),f=n(1489),p=Math.max;e.exports=function(e,t,n,h,m,g,b,y){var v=2&t;if(!v&&"function"!=typeof e)throw new TypeError("Expected a function");var w=h?h.length:0;if(w||(t&=-97,h=m=void 0),b=void 0===b?b:p(f(b),0),y=void 0===y?y:f(y),w-=m?m.length:0,64&t){var _=h,E=m;h=m=void 0}var x=v?void 0:s(e),S=[e,t,n,h,m,_,E,g,b,y];if(x&&c(S,x),e=S[0],t=S[1],n=S[2],h=S[3],m=S[4],!(y=S[9]=void 0===S[9]?v?0:e.length:p(S[9]-w,0))&&24&t&&(t&=-25),t&&1!=t)k=8==t||16==t?a(e,t,y):32!=t&&33!=t||m.length?i.apply(void 0,S):l(e,t,n,h);else var k=o(e,t,n);return d((x?r:u)(k,S),e,t)}},4647:(e,t,n)=>{var r=n(4552)({À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"});e.exports=r},3243:(e,t,n)=>{var r=n(6110),o=function(){try{var e=r(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();e.exports=o},5911:(e,t,n)=>{var r=n(8859),o=n(4248),a=n(9219);e.exports=function(e,t,n,i,l,s){var c=1&n,u=e.length,d=t.length;if(u!=d&&!(c&&d>u))return!1;var f=s.get(e),p=s.get(t);if(f&&p)return f==t&&p==e;var h=-1,m=!0,g=2&n?new r:void 0;for(s.set(e,t),s.set(t,e);++h{var r=n(1873),o=n(7828),a=n(5288),i=n(5911),l=n(317),s=n(4247),c=r?r.prototype:void 0,u=c?c.valueOf:void 0;e.exports=function(e,t,n,r,c,d,f){switch(n){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":return!(e.byteLength!=t.byteLength||!d(new o(e),new o(t)));case"[object Boolean]":case"[object Date]":case"[object Number]":return a(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var p=l;case"[object Set]":var h=1&r;if(p||(p=s),e.size!=t.size&&!h)return!1;var m=f.get(e);if(m)return m==t;r|=2,f.set(e,t);var g=i(p(e),p(t),r,c,d,f);return f.delete(e),g;case"[object Symbol]":if(u)return u.call(e)==u.call(t)}return!1}},689:(e,t,n)=>{var r=n(2),o=Object.prototype.hasOwnProperty;e.exports=function(e,t,n,a,i,l){var s=1&n,c=r(e),u=c.length;if(u!=r(t).length&&!s)return!1;for(var d=u;d--;){var f=c[d];if(!(s?f in t:o.call(t,f)))return!1}var p=l.get(e),h=l.get(t);if(p&&h)return p==t&&h==e;var m=!0;l.set(e,t),l.set(t,e);for(var g=s;++d{var r=n(5970),o=n(6757),a=n(2865);e.exports=function(e){return a(o(e,void 0,r),e+"")}},4840:(e,t,n)=>{var r="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g;e.exports=r},2:(e,t,n)=>{var r=n(2199),o=n(4664),a=n(5950);e.exports=function(e){return r(e,a,o)}},7381:(e,t,n)=>{var r=n(8152),o=n(3950),a=r?function(e){return r.get(e)}:o;e.exports=a},2284:(e,t,n)=>{var r=n(4629),o=Object.prototype.hasOwnProperty;e.exports=function(e){for(var t=e.name+"",n=r[t],a=o.call(r,t)?n.length:0;a--;){var i=n[a],l=i.func;if(null==l||l==e)return i.name}return t}},1287:e=>{e.exports=function(e){return e.placeholder}},2651:(e,t,n)=>{var r=n(4218);e.exports=function(e,t){var n=e.__data__;return r(t)?n["string"==typeof t?"string":"hash"]:n.map}},776:(e,t,n)=>{var r=n(756),o=n(5950);e.exports=function(e){for(var t=o(e),n=t.length;n--;){var a=t[n],i=e[a];t[n]=[a,i,r(i)]}return t}},6110:(e,t,n)=>{var r=n(5083),o=n(392);e.exports=function(e,t){var n=o(e,t);return r(n)?n:void 0}},659:(e,t,n)=>{var r=n(1873),o=Object.prototype,a=o.hasOwnProperty,i=o.toString,l=r?r.toStringTag:void 0;e.exports=function(e){var t=a.call(e,l),n=e[l];try{e[l]=void 0;var r=!0}catch(e){}var o=i.call(e);return r&&(t?e[l]=n:delete e[l]),o}},4664:(e,t,n)=>{var r=n(9770),o=n(3345),a=Object.prototype.propertyIsEnumerable,i=Object.getOwnPropertySymbols,l=i?function(e){return null==e?[]:(e=Object(e),r(i(e),(function(t){return a.call(e,t)})))}:o;e.exports=l},5861:(e,t,n)=>{var r=n(5580),o=n(8223),a=n(2804),i=n(6545),l=n(8303),s=n(2552),c=n(7473),u="[object Map]",d="[object Promise]",f="[object Set]",p="[object WeakMap]",h="[object DataView]",m=c(r),g=c(o),b=c(a),y=c(i),v=c(l),w=s;(r&&w(new r(new ArrayBuffer(1)))!=h||o&&w(new o)!=u||a&&w(a.resolve())!=d||i&&w(new i)!=f||l&&w(new l)!=p)&&(w=function(e){var t=s(e),n="[object Object]"==t?e.constructor:void 0,r=n?c(n):"";if(r)switch(r){case m:return h;case g:return u;case b:return d;case y:return f;case v:return p}return t}),e.exports=w},392:e=>{e.exports=function(e,t){return null==e?void 0:e[t]}},5251:e=>{var t=/\{\n\/\* \[wrapped with (.+)\] \*/,n=/,? & /;e.exports=function(e){var r=e.match(t);return r?r[1].split(n):[]}},9326:(e,t,n)=>{var r=n(1769),o=n(2428),a=n(6449),i=n(361),l=n(294),s=n(7797);e.exports=function(e,t,n){for(var c=-1,u=(t=r(t,e)).length,d=!1;++c{var t=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;e.exports=function(e){return t.test(e)}},2032:(e,t,n)=>{var r=n(1042);e.exports=function(){this.__data__=r?r(null):{},this.size=0}},3862:e=>{e.exports=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}},6721:(e,t,n)=>{var r=n(1042),o=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;if(r){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return o.call(t,e)?t[e]:void 0}},2749:(e,t,n)=>{var r=n(1042),o=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;return r?void 0!==t[e]:o.call(t,e)}},5749:(e,t,n)=>{var r=n(1042);e.exports=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=r&&void 0===t?"__lodash_hash_undefined__":t,this}},2060:e=>{var t=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/;e.exports=function(e,n){var r=n.length;if(!r)return e;var o=r-1;return n[o]=(r>1?"& ":"")+n[o],n=n.join(r>2?", ":" "),e.replace(t,"{\n/* [wrapped with "+n+"] */\n")}},5891:(e,t,n)=>{var r=n(1873),o=n(2428),a=n(6449),i=r?r.isConcatSpreadable:void 0;e.exports=function(e){return a(e)||o(e)||!!(i&&e&&e[i])}},361:e=>{var t=/^(?:0|[1-9]\d*)$/;e.exports=function(e,n){var r=typeof e;return!!(n=null==n?9007199254740991:n)&&("number"==r||"symbol"!=r&&t.test(e))&&e>-1&&e%1==0&&e{var r=n(6449),o=n(4394),a=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,i=/^\w*$/;e.exports=function(e,t){if(r(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!o(e))||i.test(e)||!a.test(e)||null!=t&&e in Object(t)}},4218:e=>{e.exports=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}},5087:(e,t,n)=>{var r=n(980),o=n(7381),a=n(2284),i=n(3758);e.exports=function(e){var t=a(e),n=i[t];if("function"!=typeof n||!(t in r.prototype))return!1;if(e===n)return!0;var l=o(n);return!!l&&e===l[0]}},7296:(e,t,n)=>{var r,o=n(5481),a=(r=/[^.]+$/.exec(o&&o.keys&&o.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"";e.exports=function(e){return!!a&&a in e}},5527:e=>{var t=Object.prototype;e.exports=function(e){var n=e&&e.constructor;return e===("function"==typeof n&&n.prototype||t)}},756:(e,t,n)=>{var r=n(3805);e.exports=function(e){return e==e&&!r(e)}},3702:e=>{e.exports=function(){this.__data__=[],this.size=0}},80:(e,t,n)=>{var r=n(6025),o=Array.prototype.splice;e.exports=function(e){var t=this.__data__,n=r(t,e);return!(n<0||(n==t.length-1?t.pop():o.call(t,n,1),--this.size,0))}},4739:(e,t,n)=>{var r=n(6025);e.exports=function(e){var t=this.__data__,n=r(t,e);return n<0?void 0:t[n][1]}},1036:(e,t,n)=>{var r=n(6025);e.exports=function(e){return r(this.__data__,e)>-1}},1175:(e,t,n)=>{var r=n(6025);e.exports=function(e,t){var n=this.__data__,o=r(n,e);return o<0?(++this.size,n.push([e,t])):n[o][1]=t,this}},3040:(e,t,n)=>{var r=n(1549),o=n(79),a=n(8223);e.exports=function(){this.size=0,this.__data__={hash:new r,map:new(a||o),string:new r}}},7670:(e,t,n)=>{var r=n(2651);e.exports=function(e){var t=r(this,e).delete(e);return this.size-=t?1:0,t}},289:(e,t,n)=>{var r=n(2651);e.exports=function(e){return r(this,e).get(e)}},4509:(e,t,n)=>{var r=n(2651);e.exports=function(e){return r(this,e).has(e)}},2949:(e,t,n)=>{var r=n(2651);e.exports=function(e,t){var n=r(this,e),o=n.size;return n.set(e,t),this.size+=n.size==o?0:1,this}},317:e=>{e.exports=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n}},7197:e=>{e.exports=function(e,t){return function(n){return null!=n&&n[e]===t&&(void 0!==t||e in Object(n))}}},2224:(e,t,n)=>{var r=n(104);e.exports=function(e){var t=r(e,(function(e){return 500===n.size&&n.clear(),e})),n=t.cache;return t}},3209:(e,t,n)=>{var r=n(1596),o=n(3320),a=n(6306),i="__lodash_placeholder__",l=Math.min;e.exports=function(e,t){var n=e[1],s=t[1],c=n|s,u=c<131,d=128==s&&8==n||128==s&&256==n&&e[7].length<=t[8]||384==s&&t[7].length<=t[8]&&8==n;if(!u&&!d)return e;1&s&&(e[2]=t[2],c|=1&n?0:4);var f=t[3];if(f){var p=e[3];e[3]=p?r(p,f,t[4]):f,e[4]=p?a(e[3],i):t[4]}return(f=t[5])&&(p=e[5],e[5]=p?o(p,f,t[6]):f,e[6]=p?a(e[5],i):t[6]),(f=t[7])&&(e[7]=f),128&s&&(e[8]=null==e[8]?t[8]:l(e[8],t[8])),null==e[9]&&(e[9]=t[9]),e[0]=t[0],e[1]=c,e}},8152:(e,t,n)=>{var r=n(8303),o=r&&new r;e.exports=o},1042:(e,t,n)=>{var r=n(6110)(Object,"create");e.exports=r},3650:(e,t,n)=>{var r=n(4335)(Object.keys,Object);e.exports=r},6009:(e,t,n)=>{e=n.nmd(e);var r=n(4840),o=t&&!t.nodeType&&t,a=o&&e&&!e.nodeType&&e,i=a&&a.exports===o&&r.process,l=function(){try{return a&&a.require&&a.require("util").types||i&&i.binding&&i.binding("util")}catch(e){}}();e.exports=l},9350:e=>{var t=Object.prototype.toString;e.exports=function(e){return t.call(e)}},4335:e=>{e.exports=function(e,t){return function(n){return e(t(n))}}},6757:(e,t,n)=>{var r=n(1033),o=Math.max;e.exports=function(e,t,n){return t=o(void 0===t?e.length-1:t,0),function(){for(var a=arguments,i=-1,l=o(a.length-t,0),s=Array(l);++i{e.exports={}},8294:(e,t,n)=>{var r=n(3007),o=n(361),a=Math.min;e.exports=function(e,t){for(var n=e.length,i=a(t.length,n),l=r(e);i--;){var s=t[i];e[i]=o(s,n)?l[s]:void 0}return e}},6306:e=>{var t="__lodash_placeholder__";e.exports=function(e,n){for(var r=-1,o=e.length,a=0,i=[];++r{var r=n(4840),o="object"==typeof self&&self&&self.Object===Object&&self,a=r||o||Function("return this")();e.exports=a},1380:e=>{e.exports=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this}},1459:e=>{e.exports=function(e){return this.__data__.has(e)}},4641:(e,t,n)=>{var r=n(8882),o=n(1811)(r);e.exports=o},4247:e=>{e.exports=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n}},2865:(e,t,n)=>{var r=n(9570),o=n(1811)(r);e.exports=o},981:(e,t,n)=>{var r=n(5251),o=n(2060),a=n(2865),i=n(5948);e.exports=function(e,t,n){var l=t+"";return a(e,o(l,i(r(l),n)))}},1811:e=>{var t=Date.now;e.exports=function(e){var n=0,r=0;return function(){var o=t(),a=16-(o-r);if(r=o,a>0){if(++n>=800)return arguments[0]}else n=0;return e.apply(void 0,arguments)}}},1420:(e,t,n)=>{var r=n(79);e.exports=function(){this.__data__=new r,this.size=0}},938:e=>{e.exports=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}},3605:e=>{e.exports=function(e){return this.__data__.get(e)}},9817:e=>{e.exports=function(e){return this.__data__.has(e)}},945:(e,t,n)=>{var r=n(79),o=n(8223),a=n(3661);e.exports=function(e,t){var n=this.__data__;if(n instanceof r){var i=n.__data__;if(!o||i.length<199)return i.push([e,t]),this.size=++n.size,this;n=this.__data__=new a(i)}return n.set(e,t),this.size=n.size,this}},6959:e=>{e.exports=function(e,t,n){for(var r=n-1,o=e.length;++r{var r=n(2224),o=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,a=/\\(\\)?/g,i=r((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(o,(function(e,n,r,o){t.push(r?o.replace(a,"$1"):n||e)})),t}));e.exports=i},7797:(e,t,n)=>{var r=n(4394);e.exports=function(e){if("string"==typeof e||r(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}},7473:e=>{var t=Function.prototype.toString;e.exports=function(e){if(null!=e){try{return t.call(e)}catch(e){}try{return e+""}catch(e){}}return""}},1800:e=>{var t=/\s/;e.exports=function(e){for(var n=e.length;n--&&t.test(e.charAt(n)););return n}},2225:e=>{var t="\\ud800-\\udfff",n="\\u2700-\\u27bf",r="a-z\\xdf-\\xf6\\xf8-\\xff",o="A-Z\\xc0-\\xd6\\xd8-\\xde",a="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",i="["+a+"]",l="\\d+",s="["+n+"]",c="["+r+"]",u="[^"+t+a+l+n+r+o+"]",d="(?:\\ud83c[\\udde6-\\uddff]){2}",f="[\\ud800-\\udbff][\\udc00-\\udfff]",p="["+o+"]",h="(?:"+c+"|"+u+")",m="(?:"+p+"|"+u+")",g="(?:['’](?:d|ll|m|re|s|t|ve))?",b="(?:['’](?:D|LL|M|RE|S|T|VE))?",y="(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?",v="[\\ufe0e\\ufe0f]?",w=v+y+"(?:\\u200d(?:"+["[^"+t+"]",d,f].join("|")+")"+v+y+")*",_="(?:"+[s,d,f].join("|")+")"+w,E=RegExp([p+"?"+c+"+"+g+"(?="+[i,p,"$"].join("|")+")",m+"+"+b+"(?="+[i,p+h,"$"].join("|")+")",p+"?"+h+"+"+g,p+"+"+b,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",l,_].join("|"),"g");e.exports=function(e){return e.match(E)||[]}},5948:(e,t,n)=>{var r=n(3729),o=n(5325),a=[["ary",128],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",32],["partialRight",64],["rearg",256]];e.exports=function(e,t){return r(a,(function(n){var r="_."+n[0];t&n[1]&&!o(e,r)&&e.push(r)})),e.sort()}},257:(e,t,n)=>{var r=n(980),o=n(6017),a=n(3007);e.exports=function(e){if(e instanceof r)return e.clone();var t=new o(e.__wrapped__,e.__chain__);return t.__actions__=a(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t}},7334:e=>{e.exports=function(e){return function(){return e}}},828:(e,t,n)=>{var r=n(4647),o=n(3222),a=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,i=RegExp("[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]","g");e.exports=function(e){return(e=o(e))&&e.replace(a,r).replace(i,"")}},4889:(e,t,n)=>{var r=n(3915),o=n(3120),a=n(9302),i=n(3693),l=n(8090),s=a((function(e,t){var n=l(t);return i(n)&&(n=void 0),i(e)?r(e,o(t,1,i,!0),void 0,n):[]}));e.exports=s},5288:e=>{e.exports=function(e,t){return e===t||e!=e&&t!=t}},7612:(e,t,n)=>{var r=n(9770),o=n(6574),a=n(5389),i=n(6449);e.exports=function(e,t){return(i(e)?r:o)(e,a(t,3))}},7309:(e,t,n)=>{var r=n(2006)(n(4713));e.exports=r},4713:(e,t,n)=>{var r=n(2523),o=n(5389),a=n(1489),i=Math.max;e.exports=function(e,t,n){var l=null==e?0:e.length;if(!l)return-1;var s=null==n?0:a(n);return s<0&&(s=i(l+s,0)),r(e,o(t,3),s)}},5970:(e,t,n)=>{var r=n(3120);e.exports=function(e){return null!=e&&e.length?r(e,1):[]}},9870:(e,t,n)=>{var r=n(6929)();e.exports=r},8156:(e,t,n)=>{var r=n(7422);e.exports=function(e,t,n){var o=null==e?void 0:r(e,t);return void 0===o?n:o}},2013:(e,t,n)=>{var r=n(3360),o=n(2e3),a=Object.prototype.hasOwnProperty,i=o((function(e,t,n){a.call(e,n)?e[n].push(t):r(e,n,[t])}));e.exports=i},631:(e,t,n)=>{var r=n(8077),o=n(9326);e.exports=function(e,t){return null!=e&&o(e,t,r)}},3488:e=>{e.exports=function(e){return e}},2428:(e,t,n)=>{var r=n(7534),o=n(346),a=Object.prototype,i=a.hasOwnProperty,l=a.propertyIsEnumerable,s=r(function(){return arguments}())?r:function(e){return o(e)&&i.call(e,"callee")&&!l.call(e,"callee")};e.exports=s},6449:e=>{var t=Array.isArray;e.exports=t},4894:(e,t,n)=>{var r=n(1882),o=n(294);e.exports=function(e){return null!=e&&o(e.length)&&!r(e)}},3693:(e,t,n)=>{var r=n(4894),o=n(346);e.exports=function(e){return o(e)&&r(e)}},3656:(e,t,n)=>{e=n.nmd(e);var r=n(9325),o=n(9935),a=t&&!t.nodeType&&t,i=a&&e&&!e.nodeType&&e,l=i&&i.exports===a?r.Buffer:void 0,s=(l?l.isBuffer:void 0)||o;e.exports=s},2193:(e,t,n)=>{var r=n(8984),o=n(5861),a=n(2428),i=n(6449),l=n(4894),s=n(3656),c=n(5527),u=n(7167),d=Object.prototype.hasOwnProperty;e.exports=function(e){if(null==e)return!0;if(l(e)&&(i(e)||"string"==typeof e||"function"==typeof e.splice||s(e)||u(e)||a(e)))return!e.length;var t=o(e);if("[object Map]"==t||"[object Set]"==t)return!e.size;if(c(e))return!r(e).length;for(var n in e)if(d.call(e,n))return!1;return!0}},1882:(e,t,n)=>{var r=n(2552),o=n(3805);e.exports=function(e){if(!o(e))return!1;var t=r(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}},294:e=>{e.exports=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991}},3805:e=>{e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},346:e=>{e.exports=function(e){return null!=e&&"object"==typeof e}},4394:(e,t,n)=>{var r=n(2552),o=n(346);e.exports=function(e){return"symbol"==typeof e||o(e)&&"[object Symbol]"==r(e)}},7167:(e,t,n)=>{var r=n(4901),o=n(7301),a=n(6009),i=a&&a.isTypedArray,l=i?o(i):r;e.exports=l},5950:(e,t,n)=>{var r=n(695),o=n(8984),a=n(4894);e.exports=function(e){return a(e)?r(e):o(e)}},8090:e=>{e.exports=function(e){var t=null==e?0:e.length;return t?e[t-1]:void 0}},5378:(e,t,n)=>{var r=n(4932),o=n(5389),a=n(5128),i=n(6449);e.exports=function(e,t){return(i(e)?r:a)(e,o(t,3))}},104:(e,t,n)=>{var r=n(3661);function o(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var r=arguments,o=t?t.apply(this,r):r[0],a=n.cache;if(a.has(o))return a.get(o);var i=e.apply(this,r);return n.cache=a.set(o,i)||a,i};return n.cache=new(o.Cache||r),n}o.Cache=r,e.exports=o},3950:e=>{e.exports=function(){}},2877:(e,t,n)=>{var r=n(6155),o=n(6449);e.exports=function(e,t,n,a){return null==e?[]:(o(t)||(t=null==t?[]:[t]),o(n=a?void 0:n)||(n=null==n?[]:[n]),r(e,t,n))}},9181:(e,t,n)=>{var r=n(9302),o=n(6977),a=n(1287),i=n(6306),l=r((function(e,t){var n=i(t,a(l));return o(e,32,void 0,t,n)}));l.placeholder={},e.exports=l},583:(e,t,n)=>{var r=n(7237),o=n(7255),a=n(8586),i=n(7797);e.exports=function(e){return a(e)?r(i(e)):o(e)}},3345:e=>{e.exports=function(){return[]}},9935:e=>{e.exports=function(){return!1}},7400:(e,t,n)=>{var r=n(9374),o=1/0;e.exports=function(e){return e?(e=r(e))===o||e===-1/0?17976931348623157e292*(e<0?-1:1):e==e?e:0:0===e?e:0}},1489:(e,t,n)=>{var r=n(7400);e.exports=function(e){var t=r(e),n=t%1;return t==t?n?t-n:t:0}},9374:(e,t,n)=>{var r=n(4128),o=n(3805),a=n(4394),i=/^[-+]0x[0-9a-f]+$/i,l=/^0b[01]+$/i,s=/^0o[0-7]+$/i,c=parseInt;e.exports=function(e){if("number"==typeof e)return e;if(a(e))return NaN;if(o(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=o(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=r(e);var n=l.test(e);return n||s.test(e)?c(e.slice(2),n?2:8):i.test(e)?NaN:+e}},3222:(e,t,n)=>{var r=n(7556);e.exports=function(e){return null==e?"":r(e)}},6645:(e,t,n)=>{var r=n(1733),o=n(5434),a=n(3222),i=n(2225);e.exports=function(e,t,n){return e=a(e),void 0===(t=n?void 0:t)?o(e)?i(e):r(e):e.match(t)||[]}},3758:(e,t,n)=>{var r=n(980),o=n(6017),a=n(4033),i=n(6449),l=n(346),s=n(257),c=Object.prototype.hasOwnProperty;function u(e){if(l(e)&&!i(e)&&!(e instanceof r)){if(e instanceof o)return e;if(c.call(e,"__wrapped__"))return s(e)}return new o(e)}u.prototype=a.prototype,u.prototype.constructor=u,e.exports=u},814:(e,t,n)=>{"use strict";e.exports=n(3258)},3258:e=>{"use strict";var t,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,o=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,i={};((e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})})(i,{defaultOptions:()=>m,numericQuantity:()=>y,numericRegex:()=>s,numericRegexWithTrailingInvalid:()=>c,parseRomanNumerals:()=>g,romanNumeralRegex:()=>h,romanNumeralUnicodeRegex:()=>p,romanNumeralUnicodeToAsciiMap:()=>f,romanNumeralValues:()=>d,vulgarFractionToAsciiMap:()=>l,vulgarFractionsRegex:()=>u}),e.exports=(t=i,((e,t,i,l)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of o(t))!a.call(e,i)&&undefined!==i&&n(e,i,{get:()=>t[i],enumerable:!(l=r(t,i))||l.enumerable});return e})(n({},"__esModule",{value:!0}),t));var l={"¼":"1/4","½":"1/2","¾":"3/4","⅐":"1/7","⅑":"1/9","⅒":"1/10","⅓":"1/3","⅔":"2/3","⅕":"1/5","⅖":"2/5","⅗":"3/5","⅘":"4/5","⅙":"1/6","⅚":"5/6","⅛":"1/8","⅜":"3/8","⅝":"5/8","⅞":"7/8","⅟":"1/"},s=/^(?=-?\s*\.\d|-?\s*\d)(-)?\s*((?:\d(?:[\d,_]*\d)?)*)(([eE][+-]?\d(?:[\d,_]*\d)?)?|\.\d(?:[\d,_]*\d)?([eE][+-]?\d(?:[\d,_]*\d)?)?|(\s+\d(?:[\d,_]*\d)?\s*)?\s*\/\s*\d(?:[\d,_]*\d)?)?$/,c=new RegExp(s.source.replace(/\$$/,"(?:\\s*[^\\.\\d\\/].*)?")),u=new RegExp(`(${Object.keys(l).join("|")})`),d={MMM:3e3,MM:2e3,M:1e3,CM:900,DCCC:800,DCC:700,DC:600,D:500,CD:400,CCC:300,CC:200,C:100,XC:90,LXXX:80,LXX:70,LX:60,L:50,XL:40,XXX:30,XX:20,XII:12,XI:11,X:10,IX:9,VIII:8,VII:7,VI:6,V:5,IV:4,III:3,II:2,I:1},f={Ⅰ:"I",Ⅱ:"II",Ⅲ:"III",Ⅳ:"IV",Ⅴ:"V",Ⅵ:"VI",Ⅶ:"VII",Ⅷ:"VIII",Ⅸ:"IX",Ⅹ:"X",Ⅺ:"XI",Ⅻ:"XII",Ⅼ:"L",Ⅽ:"C",Ⅾ:"D",Ⅿ:"M",ⅰ:"I",ⅱ:"II",ⅲ:"III",ⅳ:"IV",ⅴ:"V",ⅵ:"VI",ⅶ:"VII",ⅷ:"VIII",ⅸ:"IX",ⅹ:"X",ⅺ:"XI",ⅻ:"XII",ⅼ:"L",ⅽ:"C",ⅾ:"D",ⅿ:"M"},p=new RegExp(`(${Object.keys(f).join("|")})`,"gi"),h=/^(?=[MDCLXVI])(M{0,3})(C[MD]|D?C{0,3})(X[CL]|L?X{0,3})(I[XV]|V?I{0,3})$/i,m={round:3,allowTrailingInvalid:!1,romanNumerals:!1},g=e=>{let t=`${e}`.replace(p,((e,t)=>f[t])).toUpperCase(),n=h.exec(t);if(!n)return NaN;let[,r,o,a,i]=n;return(d[r]??0)+(d[o]??0)+(d[a]??0)+(d[i]??0)},b=/^\s*\//,y=(e,t=m)=>{if("number"==typeof e||"bigint"==typeof e)return e;let n=NaN,r=`${e}`.replace(u,((e,t)=>` ${l[t]}`)).replace("⁄","/").trim();if(0===r.length)return NaN;let o={...m,...t},a=(o.allowTrailingInvalid?c:s).exec(r);if(!a)return o.romanNumerals?g(r):NaN;let[,i,d,f]=a,p=d.replace(/[,_]/g,""),h=null==f?void 0:f.replace(/[,_]/g,"");if(n=!p&&h&&h.startsWith(".")?0:parseInt(p),!h)return i?-1*n:n;let y=!1===o.round?NaN:parseFloat(`1e${Math.floor(Math.max(0,o.round))}`);if(h.startsWith(".")||h.startsWith("e")||h.startsWith("E")){let e=parseFloat(`${n}${h}`);n=isNaN(y)?e:Math.round(e*y)/y}else if(b.test(h)){let e=parseInt(p),t=parseInt(h.replace("/",""));n=isNaN(y)?e/t:Math.round(e*y/t)/y}else{let e=h.split("/"),[t,r]=e.map((e=>parseInt(e)));n+=isNaN(y)?t/r:Math.round(t*y/r)/y}return i?-1*n:n}},5338:(e,t,n)=>{"use strict";var r=n(5206);t.H=r.createRoot,r.hydrateRoot},840:(e,t,n)=>{"use strict";var r,o=Object.defineProperty,a=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,l=Object.prototype.hasOwnProperty,s={};((e,t)=>{for(var n in t)o(e,n,{get:t[n],enumerable:!0})})(s,{parseJsonLogic:()=>X}),e.exports=(r=s,((e,t,n,r)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let n of i(t))l.call(e,n)||undefined===n||o(e,n,{get:()=>t[n],enumerable:!(r=a(t,n))||r.enumerable});return e})(o({},"__esModule",{value:!0}),r));var c={"=":"!=","!=":"=","<":">=","<=":">",">":"<=",">=":"<",beginsWith:"doesNotBeginWith",doesNotBeginWith:"beginsWith",endsWith:"doesNotEndWith",doesNotEndWith:"endsWith",contains:"doesNotContain",doesNotContain:"contains",between:"notBetween",notBetween:"between",in:"notIn",notIn:"in",notNull:"null",null:"notNull"},u=(e,t=",")=>e.map((e=>`${e??""}`.replaceAll(t[0],`\\${t[0]}`))).join(t),d=n(814),f=(new RegExp(d.numericRegex.source.replace(/^\^/,String.raw`^\s*`).replace(/\$$/,String.raw`\s*$`)),e=>null!==e&&"object"==typeof e&&Object.getPrototypeOf(e)===Object.prototype),p=e=>f(e)&&Array.isArray(e.rules),h=e=>p(e)&&"string"==typeof e.combinator,m=e=>{if((e=>p(e)&&void 0===e.combinator)(e))return e;const{combinator:t,...n}=e,r=[],{length:o}=e.rules;for(const[n,a]of e.rules.entries())p(a)?r.push(m(a)):r.push(a),t&&nf(e)&&"name"in e&&"string"==typeof e.name,v=e=>f(e)&&"value"in e&&"string"==typeof e.value;function w(e,t){return(0,b.produce)((e=>{const n={};let r=!!t;if(y(e)&&!v(e)?(n.value=e.name,r=!0):!y(e)&&v(e)&&(n.name=e.value,r=!0),r)return Object.assign({},t,e,n)}))(e)}var _=e=>{if(Array.isArray(e))for(const t of e)if(f(t)&&"options"in t)for(const e of t.options)return!(!f(e)||!("name"in e)&&!("value"in e));return!1},E=(e,t,n)=>{const r=w(e),o=w(n);return r.value!==o.value&&("string"==typeof r.comparator?r[r.comparator]===o[r.comparator]:r.comparator?.(o,t)??!1)},x=(e,t,n)=>{if(!e.comparator){const n=t=>(t.value??t.name)!==(e.value??e.name);return _(t)?t.map((e=>({...e,options:e.options.filter((e=>n(e)))}))):t.filter((e=>n(e)))}return _(t)?t.map((t=>({...t,options:t.options.filter((t=>E(e,n,t)))}))).filter((e=>e.options.length>0)):t.filter((t=>E(e,n,t)))},S=["value"],k={name:"name",value:"name",valueSources:null,label:"label"},R=(e,t,n)=>{const r=e?w(e):k;if(r.valueSources)return"function"==typeof r.valueSources?r.valueSources(t):r.valueSources;if(n){const e=n(r.value,t,{fieldData:w(r)});if(e)return e}return S},N=e=>{const t=e?Array.isArray(e)?e:Object.keys(e).map((t=>({...e[t],name:t}))).sort(((e,t)=>e.label.localeCompare(t.label))):[];return(e=>{const t=new Set,n=[];for(const r of e)t.has(r.value??r.name)||(t.add(r.value??r.name),n.push(r));return e.length===n.length?e:n})((e=>Array.isArray(e)&&e.length>0&&f(e[0])&&"options"in e[0]&&Array.isArray(e[0].options))(n=t)?n.flatMap((e=>e.options)):n);var n},C=e=>(e=>f(e)&&"var"in e)(e)&&"string"==typeof e.var,O=e=>f(e)&&"=="in e,A=e=>f(e)&&"==="in e,P=e=>f(e)&&"!="in e,D=e=>f(e)&&"!=="in e,T=e=>f(e)&&"!"in e,I=e=>f(e)&&"!!"in e,j=e=>f(e)&&"or"in e,M=e=>f(e)&&"and"in e,$=e=>f(e)&&">"in e,L=e=>f(e)&&">="in e,z=e=>f(e)&&"<"in e&&2===e["<"].length,F=e=>f(e)&&"<="in e&&2===e["<="].length,W=e=>f(e)&&"in"in e&&Array.isArray(e.in[1]),G=e=>f(e)&&"in"in e&&!Array.isArray(e.in[1]),B=e=>f(e)&&"<"in e&&Array.isArray(e["<"])&&3===e["<"].length,V=e=>f(e)&&"<="in e&&Array.isArray(e["<="])&&3===e["<="].length,H=e=>f(e)&&"startsWith"in e,U=e=>f(e)&&"endsWith"in e,q={combinator:"and",rules:[]};function X(e,t={}){const n=N(t.fields),{getValueSources:r,listsAsArrays:o,jsonLogicOperations:a}=t,i=(e,t,o)=>function(e){const{fieldsFlat:t,fieldName:n,operator:r,subordinateFieldName:o,getValueSources:a}=e;if(0===t.length)return!0;let i=!1;const l=w(t.find((e=>e.name===n)));return l&&(i=!(!o&&"notNull"!==r&&"null"!==r&&!R(l,r,a).includes("value")),i&&o)&&(R(l,r,a).includes("field")&&n!==o&&x(l,t,r).some((e=>e.name===o))||(i=!1)),i}({fieldName:e,fieldsFlat:n,operator:t,subordinateFieldName:o,getValueSources:r});let l=e;if("string"==typeof e)try{l=JSON.parse(e)}catch{return q}const s=function e(t,n){if(n&&!f(t))return!1;const[r,l]=Object.entries(t)?.[0]??[];if(a&&g(a).includes(r)){const e=a[r](l);return!!e&&(n&&!p(e)?{combinator:"and",rules:[e]}:e)}if(M(t))return{combinator:"and",rules:t.and.map((t=>e(t))).filter(Boolean)};if(j(t))return{combinator:"or",rules:t.or.map((t=>e(t))).filter(Boolean)};if(T(t)){const r=e(t["!"]);if(r){if(!(h(r)||"between"!==r.operator&&"in"!==r.operator&&"contains"!==r.operator&&"beginsWith"!==r.operator&&"endsWith"!==r.operator)){const e={...r,operator:c[r.operator]};return n?{combinator:"and",rules:[e]}:e}return B(t["!"])||h(r)?{...r,not:!0}:{combinator:"and",rules:[r],not:!0}}return!1}if(I(t))return e(t["!!"])||!1;let s,d=!1,m="",b="=",y="";if(O(t)||A(t)||P(t)||D(t)||$(t)||L(t)||z(t)||F(t)||G(t)||H(t)||U(t)){const[e,n]=l;if(C(e)&&!f(n))m=e.var,y=n;else if(!f(e)&&C(n))m=n.var,y=e;else{if(!C(e)||!C(n))return!1;m=e.var,y=n.var,s="field"}b=O(t)||A(t)?null===y?"null":"=":P(t)||D(t)?null===y?"notNull":"!=":G(t)?"contains":H(t)?"beginsWith":U(t)?"endsWith":r,i(m,b,"field"===s?y:void 0)&&(d={field:m,operator:b,value:y,valueSource:s})}else if(B(t)&&C(t["<"][1])){m=t["<"][1].var;const n=[t["<"][0],t["<"][2]];if(n.every((e=>C(e)))||n.every((e=>"string"==typeof e))||n.every((e=>"number"==typeof e))||n.every((e=>"boolean"==typeof e)))return e({and:[{">":[{var:m},n[0]]},{"<":[{var:m},n[1]]}]})||!1}else if(V(t)&&C(t["<="][1])){m=t["<="][1].var,b="between";const e=[t["<="][0],t["<="][2]];if(t["<="].every((e=>C(e)))){s="field";const t=e.map((e=>e.var)).filter((e=>i(m,b,e)));y=o?t:u(t,",")}else(e.every((e=>"string"==typeof e))||e.every((e=>"number"==typeof e))||e.every((e=>"boolean"==typeof e)))&&(y=o?e:u(e.map((e=>`${e}`)),","));i(m,b)&&y.length>=2&&(d={field:m,operator:b,value:y,valueSource:s})}else if(W(t)&&C(l[0])){if(m=l[0].var,b="in",t.in[1].every((e=>C(e)))){s="field";const e=t.in[1].map((e=>e.var)).filter((e=>i(m,b,e)));y=o?e:u(e,",")}else(t.in[1].every((e=>"string"==typeof e))||t.in[1].every((e=>"number"==typeof e))||t.in[1].every((e=>"boolean"==typeof e)))&&(y=o?t.in[1]:u(t.in[1].map((e=>`${e}`)),","));y.length>0&&(d={field:m,operator:b,value:y,valueSource:s})}return!!d&&(n?{combinator:"and",rules:[d]}:d)}(l,!0)||q;return t.independentCombinators?m(s):s}},1020:(e,t,n)=>{"use strict";var r=n(1594),o=Symbol.for("react.element"),a=Symbol.for("react.fragment"),i=Object.prototype.hasOwnProperty,l=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,s={key:!0,ref:!0,__self:!0,__source:!0};function c(e,t,n){var r,a={},c=null,u=null;for(r in void 0!==n&&(c=""+n),void 0!==t.key&&(c=""+t.key),void 0!==t.ref&&(u=t.ref),t)i.call(t,r)&&!s.hasOwnProperty(r)&&(a[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps)void 0===a[r]&&(a[r]=t[r]);return{$$typeof:o,type:e,key:c,ref:u,props:a,_owner:l.current}}t.Fragment=a,t.jsx=c,t.jsxs=c},4848:(e,t,n)=>{"use strict";e.exports=n(1020)},8939:(e,t,n)=>{var r,o;void 0===(o="function"==typeof(r=function(){"use strict";var e,t,r,o,a,i,l,s,c="undefined"!=typeof window?window:null!=typeof n.g?n.g:this||{},u=c.cancelRequestAnimationFrame&&c.requestAnimationFrame||setTimeout,d=c.cancelRequestAnimationFrame||clearTimeout,f=[],p=0,h=!1,m=7,g=35,b=125,y=0,v=0,w=0,_={get didTimeout(){return!1},timeRemaining:function(){var e=m-(Date.now()-v);return e<0?0:e}},E=(a=function(){m=22,b=66,g=0},s=function(){var e=Date.now()-l;e<99?i=setTimeout(s,99-e):(i=null,a())},function(){l=Date.now(),i||(i=setTimeout(s,99))});function x(){125!=b&&(m=7,b=125,g=35,h&&(h&&(o&&d(o),r&&clearTimeout(r),h=!1),R())),E()}function S(){o=null,r=setTimeout(N,0)}function k(){r=null,u(S)}function R(){h||(t=b-(Date.now()-v),e=Date.now(),h=!0,g&&t9?r=setTimeout(k,t):(t=0,k()))}function N(){var n,o,a,i=m>9?9:1;if(v=Date.now(),h=!1,r=null,p>2||v-t-50i;o++)n=f.shift(),w++,n&&n(_);f.length?R():p=0}function C(e){return y++,f.push(e),R(),y}function O(e){var t=e-1-w;f[t]&&(f[t]=null)}if(c.requestIdleCallback&&c.cancelIdleCallback)try{c.requestIdleCallback((function(){}),{timeout:0})}catch(e){!function(e){var t,n;if(c.requestIdleCallback=function(t,n){return n&&"number"==typeof n.timeout?e(t,n.timeout):e(t)},c.IdleCallbackDeadline&&(t=IdleCallbackDeadline.prototype)){if(!(n=Object.getOwnPropertyDescriptor(t,"timeRemaining"))||!n.configurable||!n.get)return;Object.defineProperty(t,"timeRemaining",{value:function(){return n.get.call(this)},enumerable:!0,configurable:!0})}}(c.requestIdleCallback)}else c.requestIdleCallback=C,c.cancelIdleCallback=O,c.document&&document.addEventListener&&(c.addEventListener("scroll",x,!0),c.addEventListener("resize",x),document.addEventListener("focus",x,!0),document.addEventListener("mouseover",x,!0),["click","keypress","touchstart","mousedown"].forEach((function(e){document.addEventListener(e,x,{capture:!0,passive:!0})})),c.MutationObserver&&new MutationObserver(x).observe(document.documentElement,{childList:!0,subtree:!0,attributes:!0}));return{request:C,cancel:O}})?r.apply(t,[]):r)||(e.exports=o)},9922:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>b});var r=n(5072),o=n.n(r),a=n(7825),i=n.n(a),l=n(7659),s=n.n(l),c=n(5056),u=n.n(c),d=n(540),f=n.n(d),p=n(1113),h=n.n(p),m=n(1461),g={};g.styleTagTransform=h(),g.setAttributes=u(),g.insert=s().bind(null,"head"),g.domAPI=i(),g.insertStyleElement=f(),o()(m.A,g);const b=m.A&&m.A.locals?m.A.locals:void 0},5072:e=>{"use strict";var t=[];function n(e){for(var n=-1,r=0;r{"use strict";var t={};e.exports=function(e,n){var r=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}},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}},5056:(e,t,n)=>{"use strict";e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},7825:e=>{"use strict";e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var r="";n.supports&&(r+="@supports (".concat(n.supports,") {")),n.media&&(r+="@media ".concat(n.media," {"));var o=void 0!==n.layer;o&&(r+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),r+=n.css,o&&(r+="}"),n.media&&(r+="}"),n.supports&&(r+="}");var a=n.sourceMap;a&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(a))))," */")),t.styleTagTransform(r,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},1113: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))}}},1063:(e,t,n)=>{"use strict";var r=n(1594),o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},a=r.useState,i=r.useEffect,l=r.useLayoutEffect,s=r.useDebugValue;function c(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!o(e,n)}catch(e){return!0}}var u="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var n=t(),r=a({inst:{value:n,getSnapshot:t}}),o=r[0].inst,u=r[1];return l((function(){o.value=n,o.getSnapshot=t,c(o)&&u({inst:o})}),[e,n,t]),i((function(){return c(o)&&u({inst:o}),e((function(){c(o)&&u({inst:o})}))}),[e]),s(n),n};t.useSyncExternalStore=void 0!==r.useSyncExternalStore?r.useSyncExternalStore:u},8940:(e,t,n)=>{"use strict";var r=n(1594),o=n(9888),a="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},i=o.useSyncExternalStore,l=r.useRef,s=r.useEffect,c=r.useMemo,u=r.useDebugValue;t.useSyncExternalStoreWithSelector=function(e,t,n,r,o){var d=l(null);if(null===d.current){var f={hasValue:!1,value:null};d.current=f}else f=d.current;d=c((function(){function e(e){if(!s){if(s=!0,i=e,e=r(e),void 0!==o&&f.hasValue){var t=f.value;if(o(t,e))return l=t}return l=e}if(t=l,a(i,e))return t;var n=r(e);return void 0!==o&&o(t,n)?t:(i=e,l=n)}var i,l,s=!1,c=void 0===n?null:n;return[function(){return e(t())},null===c?void 0:function(){return e(c())}]}),[t,n,r,o]);var p=i(e,d[0],d[1]);return s((function(){f.hasValue=!0,f.value=p}),[p]),u(p),p}},7154:(e,t,n)=>{"use strict";var r=n(1594),o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},a=r.useSyncExternalStore,i=r.useRef,l=r.useEffect,s=r.useMemo,c=r.useDebugValue;t.useSyncExternalStoreWithSelector=function(e,t,n,r,u){var d=i(null);if(null===d.current){var f={hasValue:!1,value:null};d.current=f}else f=d.current;d=s((function(){function e(e){if(!l){if(l=!0,a=e,e=r(e),void 0!==u&&f.hasValue){var t=f.value;if(u(t,e))return i=t}return i=e}if(t=i,o(a,e))return t;var n=r(e);return void 0!==u&&u(t,n)?t:(a=e,i=n)}var a,i,l=!1,s=void 0===n?null:n;return[function(){return e(t())},null===s?void 0:function(){return e(s())}]}),[t,n,r,u]);var p=a(e,d[0],d[1]);return l((function(){f.hasValue=!0,f.value=p}),[p]),c(p),p}},9888:(e,t,n)=>{"use strict";e.exports=n(1063)},9242:(e,t,n)=>{"use strict";e.exports=n(8940)},8418:(e,t,n)=>{"use strict";e.exports=n(7154)},6255:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var n,r;(0,o.default)(e),"object"===a(t)?(n=t.min||0,r=t.max):(n=arguments[1],r=arguments[2]);var i=encodeURI(e).split(/%..|./).length-1;return i>=n&&(void 0===r||i<=r)};var r,o=(r=n(3399))&&r.__esModule?r:{default:r};function a(e){return a="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},a(e)}e.exports=t.default,e.exports.default=t.default},9517:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if((0,r.default)(e),(t=(0,l.default)(t,c)).require_display_name||t.allow_display_name){var n=e.match(u);if(n){var s=n[1];if(e=e.replace(s,"").replace(/(^<|>$)/g,""),s.endsWith(" ")&&(s=s.slice(0,-1)),!function(e){var t=e.replace(/^"(.+)"$/,"$1");if(!t.trim())return!1;if(/[\.";<>]/.test(t)){if(t===e)return!1;if(t.split('"').length!==t.split('\\"').length)return!1}return!0}(s))return!1}else if(t.require_display_name)return!1}if(!t.ignore_max_length&&e.length>g)return!1;var b=e.split("@"),y=b.pop(),v=y.toLowerCase();if(t.host_blacklist.includes(v))return!1;if(t.host_whitelist.length>0&&!t.host_whitelist.includes(v))return!1;var w=b.join("@");if(t.domain_specific_validation&&("gmail.com"===v||"googlemail.com"===v)){var _=(w=w.toLowerCase()).split("+")[0];if(!(0,o.default)(_.replace(/\./g,""),{min:6,max:30}))return!1;for(var E=_.split("."),x=0;x{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){(0,r.default)(e),(t=(0,o.default)(t,i)).allow_trailing_dot&&"."===e[e.length-1]&&(e=e.substring(0,e.length-1)),!0===t.allow_wildcard&&0===e.indexOf("*.")&&(e=e.substring(2));var n=e.split("."),a=n[n.length-1];if(t.require_tld){if(n.length<2)return!1;if(!t.allow_numeric_tld&&!/^([a-z\u00A1-\u00A8\u00AA-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]{2,}|xn[a-z0-9-]{2,})$/i.test(a))return!1;if(/\s/.test(a))return!1}return!(!t.allow_numeric_tld&&/^\d+$/.test(a))&&n.every((function(e){return!(e.length>63&&!t.ignore_max_length||!/^[a-z_\u00a1-\uffff0-9-]+$/i.test(e)||/[\uff01-\uff5e]/.test(e)||/^-|-$/.test(e)||!t.allow_underscores&&/_/.test(e))}))};var r=a(n(3399)),o=a(n(3610));function a(e){return e&&e.__esModule?e:{default:e}}var i={require_tld:!0,allow_underscores:!1,allow_trailing_dot:!1,allow_numeric_tld:!1,allow_wildcard:!1,ignore_max_length:!1};e.exports=t.default,e.exports.default=t.default},5372:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return(0,o.default)(t),(n=String(n))?"4"===n?l.test(t):"6"===n&&c.test(t):e(t,4)||e(t,6)};var r,o=(r=n(3399))&&r.__esModule?r:{default:r},a="(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])",i="(".concat(a,"[.]){3}").concat(a),l=new RegExp("^".concat(i,"$")),s="(?:[0-9a-fA-F]{1,4})",c=new RegExp("^("+"(?:".concat(s,":){7}(?:").concat(s,"|:)|")+"(?:".concat(s,":){6}(?:").concat(i,"|:").concat(s,"|:)|")+"(?:".concat(s,":){5}(?::").concat(i,"|(:").concat(s,"){1,2}|:)|")+"(?:".concat(s,":){4}(?:(:").concat(s,"){0,1}:").concat(i,"|(:").concat(s,"){1,3}|:)|")+"(?:".concat(s,":){3}(?:(:").concat(s,"){0,2}:").concat(i,"|(:").concat(s,"){1,4}|:)|")+"(?:".concat(s,":){2}(?:(:").concat(s,"){0,3}:").concat(i,"|(:").concat(s,"){1,5}|:)|")+"(?:".concat(s,":){1}(?:(:").concat(s,"){0,4}:").concat(i,"|(:").concat(s,"){1,6}|:)|")+"(?::((?::".concat(s,"){0,5}:").concat(i,"|(?::").concat(s,"){1,7}|:))")+")(%[0-9a-zA-Z-.:]{1,})?$");e.exports=t.default,e.exports.default=t.default},6084:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){(0,o.default)(e);var n=!1===(t=t||{}).allow_leading_zeroes?a:i,r=!t.hasOwnProperty("min")||e>=t.min,l=!t.hasOwnProperty("max")||e<=t.max,s=!t.hasOwnProperty("lt")||et.gt;return n.test(e)&&r&&l&&s&&c};var r,o=(r=n(3399))&&r.__esModule?r:{default:r},a=/^(?:[-+]?(?:0|[1-9][0-9]*))$/,i=/^[-+]?[0-9]+$/;e.exports=t.default,e.exports.default=t.default},3399:(e,t)=>{"use strict";function n(e){return n="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},n(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){if(!("string"==typeof e||e instanceof String)){var t=n(e);throw null===e?t="null":"object"===t&&(t=e.constructor.name),new TypeError("Expected a string but received a ".concat(t))}},e.exports=t.default,e.exports.default=t.default},3610:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;for(var n in t)void 0===e[n]&&(e[n]=t[n]);return e},e.exports=t.default,e.exports.default=t.default},1594:e=>{"use strict";e.exports=React},5206:e=>{"use strict";e.exports=ReactDOM},6942:(e,t)=>{var n;!function(){"use strict";var r={}.hasOwnProperty;function o(){for(var e="",t=0;t{var t=e&&e.__esModule?()=>e.default:()=>e;return i.d(t,{a:t}),t},t=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,i.t=function(n,r){if(1&r&&(n=this(n)),8&r)return n;if("object"==typeof n&&n){if(4&r&&n.__esModule)return n;if(16&r&&"function"==typeof n.then)return n}var o=Object.create(null);i.r(o);var a={};e=e||[null,t({}),t([]),t(t)];for(var l=2&r&&n;"object"==typeof l&&!~e.indexOf(l);l=t(l))Object.getOwnPropertyNames(l).forEach((e=>a[e]=()=>n[e]));return a.default=()=>n,i.d(o,a),o},i.d=(e,t)=>{for(var n in t)i.o(t,n)&&!i.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},i.f={},i.e=e=>Promise.all(Object.keys(i.f).reduce(((t,n)=>(i.f[n](e,t),t)),[])),i.u=e=>e+".min.js",i.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),i.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n={},r="post-expirator:",i.l=(e,t,o,a)=>{if(n[e])n[e].push(t);else{var l,s;if(void 0!==o)for(var c=document.getElementsByTagName("script"),u=0;u{l.onerror=l.onload=null,clearTimeout(p);var o=n[e];if(delete n[e],l.parentNode&&l.parentNode.removeChild(l),o&&o.forEach((e=>e(r))),t)return t(r)},p=setTimeout(f.bind(null,void 0,{type:"timeout",target:l}),12e4);l.onerror=f.bind(null,l.onerror),l.onload=f.bind(null,l.onload),s&&document.head.appendChild(l)}},i.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),(()=>{var e;i.g.importScripts&&(e=i.g.location+"");var t=i.g.document;if(!e&&t&&(t.currentScript&&"SCRIPT"===t.currentScript.tagName.toUpperCase()&&(e=t.currentScript.src),!e)){var n=t.getElementsByTagName("script");if(n.length)for(var r=n.length-1;r>-1&&(!e||!/^http(s?):/.test(e));)e=n[r--].src}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),i.p=e})(),(()=>{var e={155:0};i.f.j=(t,n)=>{var r=i.o(e,t)?e[t]:void 0;if(0!==r)if(r)n.push(r[2]);else{var o=new Promise(((n,o)=>r=e[t]=[n,o]));n.push(r[2]=o);var a=i.p+i.u(t),l=new Error;i.l(a,(n=>{if(i.o(e,t)&&(0!==(r=e[t])&&(e[t]=void 0),r)){var o=n&&("load"===n.type?"missing":n.type),a=n&&n.target&&n.target.src;l.message="Loading chunk "+t+" failed.\n("+o+": "+a+")",l.name="ChunkLoadError",l.type=o,l.request=a,r[1](l)}}),"chunk-"+t,t)}};var t=(t,n)=>{var r,o,[a,l,s]=n,c=0;if(a.some((t=>0!==e[t]))){for(r in l)i.o(l,r)&&(i.m[r]=l[r]);s&&s(i)}for(t&&t(n);c{"use strict";var e={};i.r(e),i.d(e,{setIsMatching:()=>U});var t={};i.r(t),i.d(t,{isViewportMatch:()=>q});var n={};i.r(n),i.d(n,{set:()=>Z,setDefaults:()=>J,setPersistenceLayer:()=>ee,toggle:()=>Q});var r={};i.r(r),i.d(r,{get:()=>re});var o={};i.r(o),i.d(o,{closeModal:()=>Ae,disableComplementaryArea:()=>xe,enableComplementaryArea:()=>Ee,openModal:()=>Oe,pinItem:()=>Se,setDefaultComplementaryArea:()=>_e,setFeatureDefaults:()=>Ce,setFeatureValue:()=>Ne,toggleFeature:()=>Re,unpinItem:()=>ke});var a={};i.r(a),i.d(a,{getActiveComplementaryArea:()=>Pe,isComplementaryAreaLoading:()=>De,isFeatureActive:()=>Ie,isItemPinned:()=>Te,isModalActive:()=>je});var l={};i.r(l),i.d(l,{getBaseSlugCounts:()=>Su,getDataTypeByName:()=>yu,getDataTypes:()=>bu,getDraggingFromHandle:()=>Ru,getEdgeById:()=>Uc,getEdges:()=>Vc,getEditedWorkflow:()=>ru,getEditedWorkflowAttribute:()=>eu,getEditedWorkflowAttributes:()=>Jc,getGlobalVariable:()=>Eu,getGlobalVariables:()=>_u,getInitialViewport:()=>lu,getNodeById:()=>Hc,getNodeErrors:()=>ku,getNodes:()=>Bc,getPostType:()=>Gc,getRayDebugShowEmails:()=>Ou,getRayDebugShowQueries:()=>Cu,getRayDebugShowWordPressErrors:()=>Au,getSelectedEdges:()=>Xc,getSelectedEdgesCount:()=>gu,getSelectedElementsCount:()=>hu,getSelectedNodes:()=>qc,getSelectedNodesCount:()=>mu,getTaxonomyTerms:()=>xu,getWorkflow:()=>Zc,getWorkflowStatus:()=>Qc,hasSelectedEdges:()=>Kc,hasSelectedNodes:()=>Yc,isAutosavingWorkflow:()=>du,isConnectingNodes:()=>Nu,isCreatingWorkflow:()=>nu,isCurrentWorkflowPublished:()=>pu,isDeletingWorkflow:()=>uu,isEditedWorkflowDirty:()=>ou,isEditedWorkflowSaveable:()=>fu,isLoadingWorkflow:()=>tu,isNewWorkflow:()=>iu,isPublishedWorkflow:()=>cu,isSavingWorkflow:()=>su,isWorkflowFlowEmpty:()=>au,takeScreenshot:()=>vu});var s={};i.r(s),i.d(s,{addDataType:()=>xd,addNode:()=>Td,addNodeError:()=>Cd,deleteWorkflow:()=>wd,fetchTaxonomyTerms:()=>kd,incrementBaseSlugCounts:()=>Rd,publishWorkflow:()=>cd,removeEdge:()=>Dd,removeNode:()=>Pd,removeNodeError:()=>Od,removePlaceholderNodes:()=>Id,resetNodeErrors:()=>Ad,saveAsCurrentStatus:()=>sd,saveAsDraft:()=>ld,setDataTypes:()=>Ed,setDraggingFromHandle:()=>jd,setEdges:()=>hd,setEditedWorkflowAttribute:()=>vd,setFlow:()=>dd,setGlobalVariable:()=>Sd,setInitialViewport:()=>md,setIsConnectingNodes:()=>Md,setNodes:()=>pd,setPostType:()=>fd,setSelectedEdges:()=>yd,setSelectedNodes:()=>gd,setupEditor:()=>id,switchToDraft:()=>ud,unselectAll:()=>bd,updateBaseSlugCounts:()=>Nd,updateNode:()=>_d});var c={};i.r(c),i.d(c,{find:()=>Em});var u={};i.r(u),i.d(u,{find:()=>Om,findNext:()=>Pm,findPrevious:()=>Am,isTabbableIndex:()=>Sm});var d={};i.r(d),i.d(d,{registerShortcut:()=>ag,unregisterShortcut:()=>ig});var f={};i.r(f),i.d(f,{getAllShortcutKeyCombinations:()=>hg,getAllShortcutRawKeyCombinations:()=>mg,getCategoryShortcuts:()=>gg,getShortcutAliases:()=>pg,getShortcutDescription:()=>fg,getShortcutKeyCombination:()=>ug,getShortcutRepresentation:()=>dg});var p="ppfuture_workflow",h="fullscreenMode",m="showIconLabels",g="inserter",b="developerMode",y="welcomeGuide",v="advancedSettings",w="miniMap",_="controls",E="triggers",x="actions",S="advanced",k="publishpress-future/edit-workflow",R="application/future-workflow-editor-node",N="trigger",C="action",O="advanced",A="placeholder",P="source",D=i(5338);const T=wp.element;function I(e){var t,n,r="";if("string"==typeof e||"number"==typeof e)r+=e;else if("object"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;t(0,T.createElement)("path",e),W=(0,T.forwardRef)((({className:e,isPressed:t,...n},r)=>{const o={...n,className:j(e,{"is-pressed":t})||void 0,"aria-hidden":!0,focusable:!1};return(0,z.jsx)("svg",{...o,ref:r})}));W.displayName="SVG";const G=(0,z.jsx)(W,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,z.jsx)(F,{d:"M16.7 7.1l-6.3 8.5-3.3-2.5-.9 1.2 4.5 3.4L17.9 8z"})}),B=(0,z.jsx)(W,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,z.jsx)(F,{d:"M11.776 4.454a.25.25 0 01.448 0l2.069 4.192a.25.25 0 00.188.137l4.626.672a.25.25 0 01.139.426l-3.348 3.263a.25.25 0 00-.072.222l.79 4.607a.25.25 0 01-.362.263l-4.138-2.175a.25.25 0 00-.232 0l-4.138 2.175a.25.25 0 01-.363-.263l.79-4.607a.25.25 0 00-.071-.222L4.754 9.881a.25.25 0 01.139-.426l4.626-.672a.25.25 0 00.188-.137l2.069-4.192z"})}),V=(0,z.jsx)(W,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,z.jsx)(F,{fillRule:"evenodd",d:"M9.706 8.646a.25.25 0 01-.188.137l-4.626.672a.25.25 0 00-.139.427l3.348 3.262a.25.25 0 01.072.222l-.79 4.607a.25.25 0 00.362.264l4.138-2.176a.25.25 0 01.233 0l4.137 2.175a.25.25 0 00.363-.263l-.79-4.607a.25.25 0 01.072-.222l3.347-3.262a.25.25 0 00-.139-.427l-4.626-.672a.25.25 0 01-.188-.137l-2.069-4.192a.25.25 0 00-.448 0L9.706 8.646zM12 7.39l-.948 1.921a1.75 1.75 0 01-1.317.957l-2.12.308 1.534 1.495c.412.402.6.982.503 1.55l-.362 2.11 1.896-.997a1.75 1.75 0 011.629 0l1.895.997-.362-2.11a1.75 1.75 0 01.504-1.55l1.533-1.495-2.12-.308a1.75 1.75 0 01-1.317-.957L12 7.39z",clipRule:"evenodd"})}),H=(e,t,n)=>{let r,o,a,i,l,s=0,c=0,u=!1,d=!1,f=!0;function p(t){const n=r,i=o;return r=void 0,o=void 0,c=t,a=e.apply(i,n),a}function h(e,t){i=setTimeout(e,t)}function m(e){return e-(l||0)}function g(e){const n=m(e);return void 0===l||n>=t||n<0||d&&e-c>=s}function b(){const e=Date.now();if(g(e))return v(e);h(b,function(e){const n=m(e),r=e-c,o=t-n;return d?Math.min(o,s-r):o}(e))}function y(){i=void 0}function v(e){return y(),f&&r?p(e):(r=o=void 0,a)}function w(){return void 0!==i}function _(...e){const n=Date.now(),i=g(n);if(r=e,o=this,l=n,i){if(!w())return function(e){return c=e,h(b,t),u?p(e):a}(l);if(d)return h(b,t),p(l)}return w()||h(b,t),a}return n&&(u=!!n.leading,d="maxWait"in n,void 0!==n.maxWait&&(s=Math.max(n.maxWait,t)),f="trailing"in n?!!n.trailing:f),_.cancel=function(){void 0!==i&&clearTimeout(i),c=0,y(),r=l=o=void 0},_.flush=function(){return w()?v(Date.now()):a},_.pending=w,_};function U(e){return{type:"SET_IS_MATCHING",values:e}}function q(e,t){return-1===t.indexOf(" ")&&(t=">= "+t),!!e[t]}const X=(0,$.createReduxStore)("core/viewport",{reducer:function(e={},t){return"SET_IS_MATCHING"===t.type?t.values:e},actions:e,selectors:t});(0,$.register)(X);((e,t)=>{const n=H((()=>{const e=Object.fromEntries(o.map((([e,t])=>[e,t.matches])));(0,$.dispatch)(X).setIsMatching(e)}),0,{leading:!0}),r=Object.entries(t),o=Object.entries(e).flatMap((([e,t])=>r.map((([r,o])=>{const a=window.matchMedia(`(${o}: ${t}px)`);return a.addEventListener("change",n),[`${r} ${e}`,a]}))));window.addEventListener("orientationchange",n),n(),n.flush()})({huge:1440,wide:1280,large:960,medium:782,small:600,mobile:480},{"<":"max-width",">=":"min-width"});const Y=function(){let e;return(t,n)=>{if("SET_PERSISTENCE_LAYER"===n.type){const{persistenceLayer:t,persistedData:r}=n;return e=t,r}const r=((e={},t)=>{if("SET_PREFERENCE_VALUE"===t.type){const{scope:n,name:r,value:o}=t;return{...e,[n]:{...e[n],[r]:o}}}return e})(t,n);return"SET_PREFERENCE_VALUE"===n.type&&e?.set(r),r}}(),K=(0,$.combineReducers)({defaults:function(e={},t){if("SET_PREFERENCE_DEFAULTS"===t.type){const{scope:n,defaults:r}=t;return{...e,[n]:{...e[n],...r}}}return e},preferences:Y});function Q(e,t){return function({select:n,dispatch:r}){const o=n.get(e,t);r.set(e,t,!o)}}function Z(e,t,n){return{type:"SET_PREFERENCE_VALUE",scope:e,name:t,value:n}}function J(e,t){return{type:"SET_PREFERENCE_DEFAULTS",scope:e,defaults:t}}async function ee(e){const t=await e.get();return{type:"SET_PERSISTENCE_LAYER",persistenceLayer:e,persistedData:t}}const te=wp.hooks,ne=Object.create(null),re=(oe=(e,t,n)=>{const r=e.preferences[t]?.[n];return void 0!==r?r:e.defaults[t]?.[n]},(e,t,n)=>["allowRightClickOverrides","distractionFree","editorMode","fixedToolbar","focusMode","hiddenBlockTypes","inactivePanels","keepCaretInsideBlock","mostUsedBlocks","openPanels","showBlockBreadcrumbs","showIconLabels","showListViewByDefault","isPublishSidebarEnabled","isComplementaryAreaVisible","pinnedItems"].includes(n)&&["core/edit-post","core/edit-site"].includes(t)?(function(e,t={}){const{since:n,version:r,alternative:o,plugin:a,link:i,hint:l}=t,s=`${e} is deprecated${n?` since version ${n}`:""}${r?` and will be removed${a?` from ${a}`:""} in version ${r}`:""}.${o?` Please use ${o} instead.`:""}${i?` See: ${i}`:""}${l?` Note: ${l}`:""}`;s in ne||((0,te.doAction)("deprecated",e,t,s),console.warn(s),ne[s]=!0)}(`wp.data.select( 'core/preferences' ).get( '${t}', '${n}' )`,{since:"6.5",alternative:`wp.data.select( 'core/preferences' ).get( 'core', '${n}' )`}),oe(e,"core",n)):oe(e,t,n));var oe;const ae=(0,$.createReduxStore)("core/preferences",{reducer:K,actions:n,selectors:r});(0,$.register)(ae);const ie=new Map;function le(e){const t=(0,T.useMemo)((()=>{const t=function(e){if(!e)return null;let t=ie.get(e);return t||("undefined"!=typeof window&&"function"==typeof window.matchMedia?(t=window.matchMedia(e),ie.set(e,t),t):null)}(e);return{subscribe:e=>t?(t.addEventListener?.("change",e),()=>{t.removeEventListener?.("change",e)}):()=>{},getValue(){var e;return null!==(e=t?.matches)&&void 0!==e&&e}}}),[e]);return(0,T.useSyncExternalStore)(t.subscribe,t.getValue,(()=>!1))}const se=()=>le("(prefers-reduced-motion: reduce)"),ce={xhuge:1920,huge:1440,wide:1280,xlarge:1080,large:960,medium:782,small:600,mobile:480},ue={">=":"min-width","<":"max-width"},de={">=":(e,t)=>t>=e,"<":(e,t)=>t=")=>{const n=(0,T.useContext)(fe),r=le(!n&&`(${ue[t]}: ${ce[e]}px)`||void 0);return n?de[t](ce[e],n):r};pe.__experimentalWidthProvider=fe.Provider;const he=pe;function me(e){const t=(0,T.useRef)();return(0,T.useEffect)((()=>{t.current=e}),[e]),t.current}const ge=(0,z.jsx)(W,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,z.jsx)(F,{d:"M12 13.06l3.712 3.713 1.061-1.06L13.061 12l3.712-3.712-1.06-1.06L12 10.938 8.288 7.227l-1.061 1.06L10.939 12l-3.712 3.712 1.06 1.061L12 13.061z"})}),be=Object.create(null);function ye(e,t={}){const{since:n,version:r,alternative:o,plugin:a,link:i,hint:l}=t,s=`${e} is deprecated${n?` since version ${n}`:""}${r?` and will be removed${a?` from ${a}`:""} in version ${r}`:""}.${o?` Please use ${o} instead.`:""}${i?` See: ${i}`:""}${l?` Note: ${l}`:""}`;s in be||((0,te.doAction)("deprecated",e,t,s),console.warn(s),be[s]=!0)}function ve(e){return["core/edit-post","core/edit-site"].includes(e)?(ye(`${e} interface scope`,{alternative:"core interface scope",hint:"core/edit-post and core/edit-site are merging.",version:"6.6"}),"core"):e}function we(e,t){return"core"===e&&"edit-site/template"===t?(ye("edit-site/template sidebar",{alternative:"edit-post/document",version:"6.6"}),"edit-post/document"):"core"===e&&"edit-site/block-inspector"===t?(ye("edit-site/block-inspector sidebar",{alternative:"edit-post/block",version:"6.6"}),"edit-post/block"):t}const _e=(e,t)=>({type:"SET_DEFAULT_COMPLEMENTARY_AREA",scope:e=ve(e),area:t=we(e,t)}),Ee=(e,t)=>({registry:n,dispatch:r})=>{t&&(e=ve(e),t=we(e,t),n.select(ae).get(e,"isComplementaryAreaVisible")||n.dispatch(ae).set(e,"isComplementaryAreaVisible",!0),r({type:"ENABLE_COMPLEMENTARY_AREA",scope:e,area:t}))},xe=e=>({registry:t})=>{e=ve(e),t.select(ae).get(e,"isComplementaryAreaVisible")&&t.dispatch(ae).set(e,"isComplementaryAreaVisible",!1)},Se=(e,t)=>({registry:n})=>{if(!t)return;e=ve(e),t=we(e,t);const r=n.select(ae).get(e,"pinnedItems");!0!==r?.[t]&&n.dispatch(ae).set(e,"pinnedItems",{...r,[t]:!0})},ke=(e,t)=>({registry:n})=>{if(!t)return;e=ve(e),t=we(e,t);const r=n.select(ae).get(e,"pinnedItems");n.dispatch(ae).set(e,"pinnedItems",{...r,[t]:!1})};function Re(e,t){return function({registry:n}){ye("dispatch( 'core/interface' ).toggleFeature",{since:"6.0",alternative:"dispatch( 'core/preferences' ).toggle"}),n.dispatch(ae).toggle(e,t)}}function Ne(e,t,n){return function({registry:r}){ye("dispatch( 'core/interface' ).setFeatureValue",{since:"6.0",alternative:"dispatch( 'core/preferences' ).set"}),r.dispatch(ae).set(e,t,!!n)}}function Ce(e,t){return function({registry:n}){ye("dispatch( 'core/interface' ).setFeatureDefaults",{since:"6.0",alternative:"dispatch( 'core/preferences' ).setDefaults"}),n.dispatch(ae).setDefaults(e,t)}}function Oe(e){return{type:"OPEN_MODAL",name:e}}function Ae(){return{type:"CLOSE_MODAL"}}const Pe=(0,$.createRegistrySelector)((e=>(t,n)=>{n=ve(n);const r=e(ae).get(n,"isComplementaryAreaVisible");if(void 0!==r)return!1===r?null:t?.complementaryAreas?.[n]})),De=(0,$.createRegistrySelector)((e=>(t,n)=>{n=ve(n);const r=e(ae).get(n,"isComplementaryAreaVisible"),o=t?.complementaryAreas?.[n];return r&&void 0===o})),Te=(0,$.createRegistrySelector)((e=>(t,n,r)=>{var o;r=we(n=ve(n),r);const a=e(ae).get(n,"pinnedItems");return null===(o=a?.[r])||void 0===o||o})),Ie=(0,$.createRegistrySelector)((e=>(t,n,r)=>(ye("select( 'core/interface' ).isFeatureActive( scope, featureName )",{since:"6.0",alternative:"select( 'core/preferences' ).get( scope, featureName )"}),!!e(ae).get(n,r))));function je(e,t){return e.activeModal===t}const Me=(0,$.combineReducers)({complementaryAreas:function(e={},t){switch(t.type){case"SET_DEFAULT_COMPLEMENTARY_AREA":{const{scope:n,area:r}=t;return e[n]?e:{...e,[n]:r}}case"ENABLE_COMPLEMENTARY_AREA":{const{scope:n,area:r}=t;return{...e,[n]:r}}}return e},activeModal:function(e=null,t){switch(t.type){case"OPEN_MODAL":return t.name;case"CLOSE_MODAL":return null}return e}}),$e=(0,$.createReduxStore)("core/interface",{reducer:Me,actions:o,selectors:a});(0,$.register)($e);const Le=wp.plugins,ze=(0,Le.withPluginContext)(((e,t)=>({icon:t.icon||e.icon,identifier:t.identifier||`${e.name}/${t.name}`}))),Fe=ze((function({as:e=M.Button,scope:t,identifier:n,icon:r,selectedIcon:o,name:a,shortcut:i,...l}){const s=e,c=(0,$.useSelect)((e=>e($e).getActiveComplementaryArea(t)===n),[n,t]),{enableComplementaryArea:u,disableComplementaryArea:d}=(0,$.useDispatch)($e);return(0,z.jsx)(s,{icon:o&&c?o:r,"aria-controls":n.replace("/",":"),"aria-checked":(f=l.role,["checkbox","option","radio","switch","menuitemcheckbox","menuitemradio","treeitem"].includes(f)?c:void 0),onClick:()=>{c?d(t):u(t,n)},shortcut:i,...l});var f})),We=({smallScreenTitle:e,children:t,className:n,toggleButtonProps:r})=>{const o=(0,z.jsx)(Fe,{icon:ge,...r});return(0,z.jsxs)(z.Fragment,{children:[(0,z.jsxs)("div",{className:"components-panel__header interface-complementary-area-header__small",children:[e&&(0,z.jsx)("h2",{className:"interface-complementary-area-header__small-title",children:e}),o]}),(0,z.jsxs)("div",{className:j("components-panel__header","interface-complementary-area-header",n),tabIndex:-1,children:[t,o]})]})},Ge=()=>{};function Be({name:e,as:t=M.Button,onClick:n,...r}){return(0,z.jsx)(M.Fill,{name:e,children:({onClick:e})=>(0,z.jsx)(t,{onClick:n||e?(...t)=>{(n||Ge)(...t),(e||Ge)(...t)}:void 0,...r})})}Be.Slot=function({name:e,as:t=M.ButtonGroup,fillProps:n={},bubblesVirtually:r,...o}){return(0,z.jsx)(M.Slot,{name:e,bubblesVirtually:r,fillProps:n,children:e=>{if(!T.Children.toArray(e).length)return null;const n=[];T.Children.forEach(e,(({props:{__unstableExplicitMenuItem:e,__unstableTarget:t}})=>{t&&e&&n.push(t)}));const r=T.Children.map(e,(e=>!e.props.__unstableExplicitMenuItem&&n.includes(e.props.__unstableTarget)?null:e));return(0,z.jsx)(t,{...o,children:r})}})};const Ve=Be,He=({__unstableExplicitMenuItem:e,__unstableTarget:t,...n})=>(0,z.jsx)(M.MenuItem,{...n});function Ue({scope:e,target:t,__unstableExplicitMenuItem:n,...r}){return(0,z.jsx)(Fe,{as:r=>(0,z.jsx)(Ve,{__unstableExplicitMenuItem:n,__unstableTarget:`${e}/${t}`,as:He,name:`${e}/plugin-more-menu`,...r}),role:"menuitemcheckbox",selectedIcon:G,name:t,scope:e,...r})}function qe({scope:e,...t}){return(0,z.jsx)(M.Fill,{name:`PinnedItems/${e}`,...t})}qe.Slot=function({scope:e,className:t,...n}){return(0,z.jsx)(M.Slot,{name:`PinnedItems/${e}`,...n,children:e=>e?.length>0&&(0,z.jsx)("div",{className:j(t,"interface-pinned-items"),children:e})})};const Xe=qe,Ye={open:{width:280},closed:{width:0},mobileOpen:{width:"100vw"}};function Ke({activeArea:e,isActive:t,scope:n,children:r,className:o,id:a}){const i=se(),l=he("medium","<"),s=me(e),c=me(t),[,u]=(0,T.useState)({});(0,T.useEffect)((()=>{u({})}),[t]);const d={type:"tween",duration:i||l||s&&e&&e!==s?0:.3,ease:[.6,0,.4,1]};return(0,z.jsx)(M.Fill,{name:`ComplementaryArea/${n}`,children:(0,z.jsx)(M.__unstableAnimatePresence,{initial:!1,children:(c||t)&&(0,z.jsx)(M.__unstableMotion.div,{variants:Ye,initial:"closed",animate:l?"mobileOpen":"open",exit:"closed",transition:d,className:"interface-complementary-area__fill",children:(0,z.jsx)("div",{id:a,className:o,style:{width:l?"100vw":280},children:r})})})})}const Qe=ze((function({children:e,className:t,closeLabel:n=(0,L.__)("Close plugin"),identifier:r,header:o,headerClassName:a,icon:i,isPinnable:l=!0,panelClassName:s,scope:c,name:u,smallScreenTitle:d,title:f,toggleShortcut:p,isActiveByDefault:h}){const[m,g]=(0,T.useState)(!1),{isLoading:b,isActive:y,isPinned:v,activeArea:w,isSmall:_,isLarge:E,showIconLabels:x}=(0,$.useSelect)((e=>{const{getActiveComplementaryArea:t,isComplementaryAreaLoading:n,isItemPinned:o}=e($e),{get:a}=e(ae),i=t(c);return{isLoading:n(c),isActive:i===r,isPinned:o(c,r),activeArea:i,isSmall:e(X).isViewportMatch("< medium"),isLarge:e(X).isViewportMatch("large"),showIconLabels:a("core","showIconLabels")}}),[r,c]);!function(e,t,n,r,o){const a=(0,T.useRef)(!1),i=(0,T.useRef)(!1),{enableComplementaryArea:l,disableComplementaryArea:s}=(0,$.useDispatch)($e);(0,T.useEffect)((()=>{r&&o&&!a.current?(s(e),i.current=!0):i.current&&!o&&a.current?(i.current=!1,l(e,t)):i.current&&n&&n!==t&&(i.current=!1),o!==a.current&&(a.current=o)}),[r,o,e,t,n,s,l])}(c,r,w,y,_);const{enableComplementaryArea:S,disableComplementaryArea:k,pinItem:R,unpinItem:N}=(0,$.useDispatch)($e);if((0,T.useEffect)((()=>{h&&void 0===w&&!_?S(c,r):void 0===w&&_&&k(c,r),g(!0)}),[w,h,c,r,_,S,k]),m)return(0,z.jsxs)(z.Fragment,{children:[l&&(0,z.jsx)(Xe,{scope:c,children:v&&(0,z.jsx)(Fe,{scope:c,identifier:r,isPressed:y&&(!x||E),"aria-expanded":y,"aria-disabled":b,label:f,icon:x?G:i,showTooltip:!x,variant:x?"tertiary":void 0,size:"compact",shortcut:p})}),u&&l&&(0,z.jsx)(Ue,{target:u,scope:c,icon:i,children:f}),(0,z.jsxs)(Ke,{activeArea:w,isActive:y,className:j("interface-complementary-area",t),scope:c,id:r.replace("/",":"),children:[(0,z.jsx)(We,{className:a,closeLabel:n,onClose:()=>k(c),smallScreenTitle:d,toggleButtonProps:{label:n,size:"small",shortcut:p,scope:c,identifier:r},children:o||(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)("h2",{className:"interface-complementary-area-header__title",children:f}),l&&(0,z.jsx)(M.Button,{className:"interface-complementary-area__pin-unpin-item",icon:v?B:V,label:v?(0,L.__)("Unpin from toolbar"):(0,L.__)("Pin to toolbar"),onClick:()=>(v?N:R)(c,r),isPressed:v,"aria-expanded":v,size:"compact"})]})}),(0,z.jsx)(M.Panel,{className:s,children:e})]})]})}));Qe.Slot=function({scope:e,...t}){return(0,z.jsx)(M.Slot,{name:`ComplementaryArea/${e}`,...t})};const Ze=Qe,Je=({isActive:e})=>((0,T.useEffect)((()=>{let e=!1;return document.body.classList.contains("sticky-menu")&&(e=!0,document.body.classList.remove("sticky-menu")),()=>{e&&document.body.classList.add("sticky-menu")}}),[]),(0,T.useEffect)((()=>(e?document.body.classList.add("is-fullscreen-mode"):document.body.classList.remove("is-fullscreen-mode"),()=>{e&&document.body.classList.remove("is-fullscreen-mode")})),[e]),null);function et(e){const t=(0,T.useRef)((()=>{throw new Error("Callbacks created with `useEvent` cannot be called during rendering.")}));return(0,T.useInsertionEffect)((()=>{t.current=e})),(0,T.useCallback)(((...e)=>t.current?.(...e)),[])}function tt(e,t={}){const n=et(e),r=(0,T.useRef)(),o=(0,T.useRef)();return et((e=>{var a;if(e===r.current)return;null!==(a=o.current)&&void 0!==a||(o.current=new ResizeObserver(n));const{current:i}=o;r.current&&i.unobserve(r.current),r.current=e,e&&i.observe(e,t)}))}const nt={position:"absolute",top:0,left:0,right:0,bottom:0,pointerEvents:"none",opacity:0,overflow:"hidden",zIndex:-1};function rt({onResize:e}){const t=tt((t=>{const n=(e=>{let t;if(e.contentBoxSize)if(e.contentBoxSize[0]){const n=e.contentBoxSize[0];t=[n.inlineSize,n.blockSize]}else{const n=e.contentBoxSize;t=[n.inlineSize,n.blockSize]}else t=[e.contentRect.width,e.contentRect.height];const[n,r]=t.map((e=>Math.round(e)));return{width:n,height:r}})(t.at(-1));e(n)}));return(0,z.jsx)("div",{ref:t,style:nt,"aria-hidden":"true"})}const ot={width:null,height:null};function at(e,t){"function"==typeof e?e(t):e&&e.hasOwnProperty("current")&&(e.current=t)}function it(e){const t=(0,T.useRef)(),n=(0,T.useRef)(!1),r=(0,T.useRef)(!1),o=(0,T.useRef)([]),a=(0,T.useRef)(e);return a.current=e,(0,T.useLayoutEffect)((()=>{!1===r.current&&!0===n.current&&e.forEach(((e,n)=>{const r=o.current[n];e!==r&&(at(r,null),at(e,t.current))})),o.current=e}),e),(0,T.useLayoutEffect)((()=>{r.current=!1})),(0,T.useCallback)((e=>{at(t,e),r.current=!0,n.current=null!==e;const i=e?a.current:o.current;for(const t of i)at(t,e)}),[])}function lt({children:e,className:t,ariaLabel:n,as:r="div",...o}){return(0,z.jsx)(r,{className:j("interface-navigable-region",t),"aria-label":n,role:"region",tabIndex:"-1",...o,children:e})}const st={type:"tween",duration:.25,ease:[.6,0,.4,1]},ct={hidden:{opacity:1,marginTop:-60},visible:{opacity:1,marginTop:0},distractionFreeHover:{opacity:1,marginTop:0,transition:{...st,delay:.2,delayChildren:.2}},distractionFreeHidden:{opacity:0,marginTop:-60},distractionFreeDisabled:{opacity:0,marginTop:0,transition:{...st,delay:.8,delayChildren:.8}}},ut=(0,T.forwardRef)((function({isDistractionFree:e,footer:t,header:n,editorNotices:r,sidebar:o,secondarySidebar:a,content:i,actions:l,labels:s,className:c,enableRegionNavigation:u=!0,shortcuts:d},f){const[p,h]=function(e,t={}){return e?tt(e,t):function(){const[e,t]=(0,T.useState)(ot),n=(0,T.useRef)(ot),r=(0,T.useCallback)((e=>{var r,o;o=e,((r=n.current).width!==o.width||r.height!==o.height)&&(n.current=e,t(e))}),[]);return[(0,z.jsx)(rt,{onResize:r}),e]}()}(),m=he("medium","<"),g={type:"tween",duration:se()?0:.25,ease:[.6,0,.4,1]},b=(0,M.__unstableUseNavigateRegions)(d);!function(e){(0,T.useEffect)((()=>{const t=document&&document.querySelector(`html:not(.${e})`);if(t)return t.classList.toggle(e),()=>{t.classList.toggle(e)}}),[e])}("interface-interface-skeleton__html-container");const y={header:(0,L._x)("Header","header landmark area"),body:(0,L.__)("Content"),secondarySidebar:(0,L.__)("Block Library"),sidebar:(0,L.__)("Settings"),actions:(0,L.__)("Publish"),footer:(0,L.__)("Footer"),...s};return(0,z.jsxs)("div",{...u?b:{},ref:it([f,u?b.ref:void 0]),className:j(c,"interface-interface-skeleton",b.className,!!t&&"has-footer"),children:[(0,z.jsxs)("div",{className:"interface-interface-skeleton__editor",children:[(0,z.jsx)(M.__unstableAnimatePresence,{initial:!1,children:!!n&&(0,z.jsx)(lt,{as:M.__unstableMotion.div,className:"interface-interface-skeleton__header","aria-label":y.header,initial:e&&!m?"distractionFreeHidden":"hidden",whileHover:e&&!m?"distractionFreeHover":"visible",animate:e&&!m?"distractionFreeDisabled":"visible",exit:e&&!m?"distractionFreeHidden":"hidden",variants:ct,transition:g,children:n})}),e&&(0,z.jsx)("div",{className:"interface-interface-skeleton__header",children:r}),(0,z.jsxs)("div",{className:"interface-interface-skeleton__body",children:[(0,z.jsx)(M.__unstableAnimatePresence,{initial:!1,children:!!a&&(0,z.jsx)(lt,{className:"interface-interface-skeleton__secondary-sidebar",ariaLabel:y.secondarySidebar,as:M.__unstableMotion.div,initial:"closed",animate:"open",exit:"closed",variants:{open:{width:h.width},closed:{width:0}},transition:g,children:(0,z.jsxs)(M.__unstableMotion.div,{style:{position:"absolute",width:m?"100vw":"fit-content",height:"100%",left:0},variants:{open:{x:0},closed:{x:"-100%"}},transition:g,children:[p,a]})})}),(0,z.jsx)(lt,{className:"interface-interface-skeleton__content",ariaLabel:y.body,children:i}),!!o&&(0,z.jsx)(lt,{className:"interface-interface-skeleton__sidebar",ariaLabel:y.sidebar,children:o}),!!l&&(0,z.jsx)(lt,{className:"interface-interface-skeleton__actions",ariaLabel:y.actions,children:l})]})]}),!!t&&(0,z.jsx)(lt,{className:"interface-interface-skeleton__footer",ariaLabel:y.footer,children:t})]})}));var dt=i(6942),ft=i.n(dt),pt="publishpress-future/workflow",ht=i(1594);function mt(e){if("string"==typeof e||"number"==typeof e)return""+e;let t="";if(Array.isArray(e))for(let n,r=0;r{let t;const n=new Set,r=(e,r)=>{const o="function"==typeof e?e(t):e;if(!Object.is(o,t)){const e=t;t=(null!=r?r:"object"!=typeof o||null===o)?o:Object.assign({},t,o),n.forEach((n=>n(t,e)))}},o=()=>t,a={setState:r,getState:o,getInitialState:()=>i,subscribe:e=>(n.add(e),()=>n.delete(e)),destroy:()=>{console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),n.clear()}},i=t=e(r,o,a);return a},{useDebugValue:yt}=ht,{useSyncExternalStoreWithSelector:vt}=gt,wt=e=>e;function _t(e,t=wt,n){const r=vt(e.subscribe,e.getState,e.getServerState||e.getInitialState,t,n);return yt(r),r}const Et=(e,t)=>{const n=(e=>e?bt(e):bt)(e),r=(e,r=t)=>_t(n,e,r);return Object.assign(r,n),r};function xt(e,t){if(Object.is(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;if(e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(const[n,r]of e)if(!Object.is(r,t.get(n)))return!1;return!0}if(e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(const n of e)if(!t.has(n))return!1;return!0}const n=Object.keys(e);if(n.length!==Object.keys(t).length)return!1;for(const r of n)if(!Object.prototype.hasOwnProperty.call(t,r)||!Object.is(e[r],t[r]))return!1;return!0}var St={value:()=>{}};function kt(){for(var e,t=0,n=arguments.length,r={};t=0&&(t=e.slice(n+1),e=e.slice(0,n)),e&&!r.hasOwnProperty(e))throw new Error("unknown type: "+e);return{type:e,name:t}}))),i=-1,l=a.length;if(!(arguments.length<2)){if(null!=t&&"function"!=typeof t)throw new Error("invalid callback: "+t);for(;++i0)for(var n,r,o=new Array(n),a=0;at?1:e>=t?0:NaN}Wt.prototype={constructor:Wt,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};var qt="http://www.w3.org/1999/xhtml";const Xt={svg:"http://www.w3.org/2000/svg",xhtml:qt,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Yt(e){var t=e+="",n=t.indexOf(":");return n>=0&&"xmlns"!==(t=e.slice(0,n))&&(e=e.slice(n+1)),Xt.hasOwnProperty(t)?{space:Xt[t],local:e}:e}function Kt(e){return function(){this.removeAttribute(e)}}function Qt(e){return function(){this.removeAttributeNS(e.space,e.local)}}function Zt(e,t){return function(){this.setAttribute(e,t)}}function Jt(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function en(e,t){return function(){var n=t.apply(this,arguments);null==n?this.removeAttribute(e):this.setAttribute(e,n)}}function tn(e,t){return function(){var n=t.apply(this,arguments);null==n?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,n)}}function nn(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function rn(e){return function(){this.style.removeProperty(e)}}function on(e,t,n){return function(){this.style.setProperty(e,t,n)}}function an(e,t,n){return function(){var r=t.apply(this,arguments);null==r?this.style.removeProperty(e):this.style.setProperty(e,r,n)}}function ln(e,t){return e.style.getPropertyValue(t)||nn(e).getComputedStyle(e,null).getPropertyValue(t)}function sn(e){return function(){delete this[e]}}function cn(e,t){return function(){this[e]=t}}function un(e,t){return function(){var n=t.apply(this,arguments);null==n?delete this[e]:this[e]=n}}function dn(e){return e.trim().split(/^|\s+/)}function fn(e){return e.classList||new pn(e)}function pn(e){this._node=e,this._names=dn(e.getAttribute("class")||"")}function hn(e,t){for(var n=fn(e),r=-1,o=t.length;++r=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};var zn=[null];function Fn(e,t){this._groups=e,this._parents=t}function Wn(){return new Fn([[document.documentElement]],zn)}Fn.prototype=Wn.prototype={constructor:Fn,select:function(e){"function"!=typeof e&&(e=Pt(e));for(var t=this._groups,n=t.length,r=new Array(n),o=0;o=_&&(_=w+1);!(v=b[_])&&++_=0;)(r=o[a])&&(i&&4^r.compareDocumentPosition(i)&&i.parentNode.insertBefore(r,i),i=r);return this},sort:function(e){function t(t,n){return t&&n?e(t.__data__,n.__data__):!t-!n}e||(e=Ut);for(var n=this._groups,r=n.length,o=new Array(r),a=0;a1?this.each((null==t?rn:"function"==typeof t?an:on)(e,t,null==n?"":n)):ln(this.node(),e)},property:function(e,t){return arguments.length>1?this.each((null==t?sn:"function"==typeof t?un:cn)(e,t)):this.node()[e]},classed:function(e,t){var n=dn(e+"");if(arguments.length<2){for(var r=fn(this.node()),o=-1,a=n.length;++o=0&&(t=e.slice(n+1),e=e.slice(0,n)),{type:e,name:t}}))}(e+""),i=a.length;if(!(arguments.length<2)){for(l=t?jn:In,r=0;r=0&&t._call.call(void 0,e),t=t._next;--tr}()}finally{tr=0,function(){for(var e,t,n=Jn,r=1/0;n;)n._call?(r>n._time&&(r=n._time),e=n,n=n._next):(t=n._next,n._next=null,n=e?e._next=t:Jn=t);er=e,mr(r)}(),ar=0}}function hr(){var e=lr.now(),t=e-or;t>1e3&&(ir-=t,or=e)}function mr(e){tr||(nr&&(nr=clearTimeout(nr)),e-ar>24?(e<1/0&&(nr=setTimeout(pr,e-lr.now()-ir)),rr&&(rr=clearInterval(rr))):(rr||(or=lr.now(),rr=setInterval(hr,1e3)),tr=1,sr(pr)))}function gr(e,t,n){var r=new dr;return t=null==t?0:+t,r.restart((n=>{r.stop(),e(n+t)}),t,n),r}dr.prototype=fr.prototype={constructor:dr,restart:function(e,t,n){if("function"!=typeof e)throw new TypeError("callback is not a function");n=(null==n?cr():+n)+(null==t?0:+t),this._next||er===this||(er?er._next=this:Jn=this,er=this),this._call=e,this._time=n,mr()},stop:function(){this._call&&(this._call=null,this._time=1/0,mr())}};var br=Ot("start","end","cancel","interrupt"),yr=[];function vr(e,t,n,r,o,a){var i=e.__transition;if(i){if(n in i)return}else e.__transition={};!function(e,t,n){var r,o=e.__transition;function a(s){var c,u,d,f;if(1!==n.state)return l();for(c in o)if((f=o[c]).name===n.name){if(3===f.state)return gr(a);4===f.state?(f.state=6,f.timer.stop(),f.on.call("interrupt",e,e.__data__,f.index,f.group),delete o[c]):+c0)throw new Error("too late; already scheduled");return n}function _r(e,t){var n=Er(e,t);if(n.state>3)throw new Error("too late; already running");return n}function Er(e,t){var n=e.__transition;if(!n||!(n=n[t]))throw new Error("transition not found");return n}function xr(e,t){var n,r,o,a=e.__transition,i=!0;if(a){for(o in t=null==t?null:t+"",a)(n=a[o]).name===t?(r=n.state>2&&n.state<5,n.state=6,n.timer.stop(),n.on.call(r?"interrupt":"cancel",e,e.__data__,n.index,n.group),delete a[o]):i=!1;i&&delete e.__transition}}function Sr(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}var kr,Rr=180/Math.PI,Nr={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Cr(e,t,n,r,o,a){var i,l,s;return(i=Math.sqrt(e*e+t*t))&&(e/=i,t/=i),(s=e*n+t*r)&&(n-=e*s,r-=t*s),(l=Math.sqrt(n*n+r*r))&&(n/=l,r/=l,s/=l),e*r180?t+=360:t-e>180&&(e+=360),a.push({i:n.push(o(n)+"rotate(",null,r)-2,x:Sr(e,t)})):t&&n.push(o(n)+"rotate("+t+r)}(a.rotate,i.rotate,l,s),function(e,t,n,a){e!==t?a.push({i:n.push(o(n)+"skewX(",null,r)-2,x:Sr(e,t)}):t&&n.push(o(n)+"skewX("+t+r)}(a.skewX,i.skewX,l,s),function(e,t,n,r,a,i){if(e!==n||t!==r){var l=a.push(o(a)+"scale(",null,",",null,")");i.push({i:l-4,x:Sr(e,n)},{i:l-2,x:Sr(t,r)})}else 1===n&&1===r||a.push(o(a)+"scale("+n+","+r+")")}(a.scaleX,a.scaleY,i.scaleX,i.scaleY,l,s),a=i=null,function(e){for(var t,n=-1,r=s.length;++n>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===n?to(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===n?to(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=Vr.exec(e))?new ro(t[1],t[2],t[3],1):(t=Hr.exec(e))?new ro(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=Ur.exec(e))?to(t[1],t[2],t[3],t[4]):(t=qr.exec(e))?to(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=Xr.exec(e))?co(t[1],t[2]/100,t[3]/100,1):(t=Yr.exec(e))?co(t[1],t[2]/100,t[3]/100,t[4]):Kr.hasOwnProperty(e)?eo(Kr[e]):"transparent"===e?new ro(NaN,NaN,NaN,0):null}function eo(e){return new ro(e>>16&255,e>>8&255,255&e,1)}function to(e,t,n,r){return r<=0&&(e=t=n=NaN),new ro(e,t,n,r)}function no(e,t,n,r){return 1===arguments.length?((o=e)instanceof $r||(o=Jr(o)),o?new ro((o=o.rgb()).r,o.g,o.b,o.opacity):new ro):new ro(e,t,n,null==r?1:r);var o}function ro(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function oo(){return`#${so(this.r)}${so(this.g)}${so(this.b)}`}function ao(){const e=io(this.opacity);return`${1===e?"rgb(":"rgba("}${lo(this.r)}, ${lo(this.g)}, ${lo(this.b)}${1===e?")":`, ${e})`}`}function io(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function lo(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function so(e){return((e=lo(e))<16?"0":"")+e.toString(16)}function co(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new fo(e,t,n,r)}function uo(e){if(e instanceof fo)return new fo(e.h,e.s,e.l,e.opacity);if(e instanceof $r||(e=Jr(e)),!e)return new fo;if(e instanceof fo)return e;var t=(e=e.rgb()).r/255,n=e.g/255,r=e.b/255,o=Math.min(t,n,r),a=Math.max(t,n,r),i=NaN,l=a-o,s=(a+o)/2;return l?(i=t===a?(n-r)/l+6*(n0&&s<1?0:i,new fo(i,l,s,e.opacity)}function fo(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function po(e){return(e=(e||0)%360)<0?e+360:e}function ho(e){return Math.max(0,Math.min(1,e||0))}function mo(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}function go(e,t,n,r,o){var a=e*e,i=a*e;return((1-3*e+3*a-i)*t+(4-6*a+3*i)*n+(1+3*e+3*a-3*i)*r+i*o)/6}jr($r,Jr,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Qr,formatHex:Qr,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return uo(this).formatHsl()},formatRgb:Zr,toString:Zr}),jr(ro,no,Mr($r,{brighter(e){return e=null==e?zr:Math.pow(zr,e),new ro(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=null==e?Lr:Math.pow(Lr,e),new ro(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new ro(lo(this.r),lo(this.g),lo(this.b),io(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:oo,formatHex:oo,formatHex8:function(){return`#${so(this.r)}${so(this.g)}${so(this.b)}${so(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:ao,toString:ao})),jr(fo,(function(e,t,n,r){return 1===arguments.length?uo(e):new fo(e,t,n,null==r?1:r)}),Mr($r,{brighter(e){return e=null==e?zr:Math.pow(zr,e),new fo(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=null==e?Lr:Math.pow(Lr,e),new fo(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,o=2*n-r;return new ro(mo(e>=240?e-240:e+120,o,r),mo(e,o,r),mo(e<120?e+240:e-120,o,r),this.opacity)},clamp(){return new fo(po(this.h),ho(this.s),ho(this.l),io(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=io(this.opacity);return`${1===e?"hsl(":"hsla("}${po(this.h)}, ${100*ho(this.s)}%, ${100*ho(this.l)}%${1===e?")":`, ${e})`}`}}));const bo=e=>()=>e;function yo(e,t){var n=t-e;return n?function(e,t){return function(n){return e+n*t}}(e,n):bo(isNaN(e)?t:e)}const vo=function e(t){var n=function(e){return 1==(e=+e)?yo:function(t,n){return n-t?function(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}(t,n,e):bo(isNaN(t)?n:t)}}(t);function r(e,t){var r=n((e=no(e)).r,(t=no(t)).r),o=n(e.g,t.g),a=n(e.b,t.b),i=yo(e.opacity,t.opacity);return function(t){return e.r=r(t),e.g=o(t),e.b=a(t),e.opacity=i(t),e+""}}return r.gamma=e,r}(1);function wo(e){return function(t){var n,r,o=t.length,a=new Array(o),i=new Array(o),l=new Array(o);for(n=0;n=1?(n=1,t-1):Math.floor(n*t),o=e[r],a=e[r+1],i=r>0?e[r-1]:2*o-a,l=ra&&(o=t.slice(a,o),l[i]?l[i]+=o:l[++i]=o),(n=n[0])===(r=r[0])?l[i]?l[i]+=r:l[++i]=r:(l[++i]=null,s.push({i,x:Sr(n,r)})),a=Eo.lastIndex;return a=0&&(e=e.slice(0,t)),!e||"start"===e}))}(t)?wr:_r;return function(){var i=a(this,e),l=i.on;l!==r&&(o=(r=l).copy()).on(t,n),i.on=o}}(n,e,t))},attr:function(e,t){var n=Yt(e),r="transform"===n?Pr:So;return this.attrTween(e,"function"==typeof t?(n.local?Ao:Oo)(n,r,Ir(this,"attr."+e,t)):null==t?(n.local?Ro:ko)(n):(n.local?Co:No)(n,r,t))},attrTween:function(e,t){var n="attr."+e;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(null==t)return this.tween(n,null);if("function"!=typeof t)throw new Error;var r=Yt(e);return this.tween(n,(r.local?Po:Do)(r,t))},style:function(e,t,n){var r="transform"==(e+="")?Ar:So;return null==t?this.styleTween(e,function(e,t){var n,r,o;return function(){var a=ln(this,e),i=(this.style.removeProperty(e),ln(this,e));return a===i?null:a===n&&i===r?o:o=t(n=a,r=i)}}(e,r)).on("end.style."+e,Lo(e)):"function"==typeof t?this.styleTween(e,function(e,t,n){var r,o,a;return function(){var i=ln(this,e),l=n(this),s=l+"";return null==l&&(this.style.removeProperty(e),s=l=ln(this,e)),i===s?null:i===r&&s===o?a:(o=s,a=t(r=i,l))}}(e,r,Ir(this,"style."+e,t))).each(function(e,t){var n,r,o,a,i="style."+t,l="end."+i;return function(){var s=_r(this,e),c=s.on,u=null==s.value[i]?a||(a=Lo(t)):void 0;c===n&&o===u||(r=(n=c).copy()).on(l,o=u),s.on=r}}(this._id,e)):this.styleTween(e,function(e,t,n){var r,o,a=n+"";return function(){var i=ln(this,e);return i===a?null:i===r?o:o=t(r=i,n)}}(e,r,t),n).on("end.style."+e,null)},styleTween:function(e,t,n){var r="style."+(e+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(null==t)return this.tween(r,null);if("function"!=typeof t)throw new Error;return this.tween(r,function(e,t,n){var r,o;function a(){var a=t.apply(this,arguments);return a!==o&&(r=(o=a)&&function(e,t,n){return function(r){this.style.setProperty(e,t.call(this,r),n)}}(e,a,n)),r}return a._value=t,a}(e,t,null==n?"":n))},text:function(e){return this.tween("text","function"==typeof e?function(e){return function(){var t=e(this);this.textContent=null==t?"":t}}(Ir(this,"text",e)):function(e){return function(){this.textContent=e}}(null==e?"":e+""))},textTween:function(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(null==e)return this.tween(t,null);if("function"!=typeof e)throw new Error;return this.tween(t,function(e){var t,n;function r(){var r=e.apply(this,arguments);return r!==n&&(t=(n=r)&&function(e){return function(t){this.textContent=e.call(this,t)}}(r)),t}return r._value=e,r}(e))},remove:function(){return this.on("end.remove",function(e){return function(){var t=this.parentNode;for(var n in this.__transition)if(+n!==e)return;t&&t.removeChild(this)}}(this._id))},tween:function(e,t){var n=this._id;if(e+="",arguments.length<2){for(var r,o=Er(this.node(),n).tween,a=0,i=o.length;a()=>e;function Uo(e,{sourceEvent:t,target:n,transform:r,dispatch:o}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},transform:{value:r,enumerable:!0,configurable:!0},_:{value:o}})}function qo(e,t,n){this.k=e,this.x=t,this.y=n}qo.prototype={constructor:qo,scale:function(e){return 1===e?this:new qo(this.k*e,this.x,this.y)},translate:function(e,t){return 0===e&0===t?this:new qo(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var Xo=new qo(1,0,0);function Yo(e){e.stopImmediatePropagation()}function Ko(e){e.preventDefault(),e.stopImmediatePropagation()}function Qo(e){return!(e.ctrlKey&&"wheel"!==e.type||e.button)}function Zo(){var e=this;return e instanceof SVGElement?(e=e.ownerSVGElement||e).hasAttribute("viewBox")?[[(e=e.viewBox.baseVal).x,e.y],[e.x+e.width,e.y+e.height]]:[[0,0],[e.width.baseVal.value,e.height.baseVal.value]]:[[0,0],[e.clientWidth,e.clientHeight]]}function Jo(){return this.__zoom||Xo}function ea(e){return-e.deltaY*(1===e.deltaMode?.05:e.deltaMode?1:.002)*(e.ctrlKey?10:1)}function ta(){return navigator.maxTouchPoints||"ontouchstart"in this}function na(e,t,n){var r=e.invertX(t[0][0])-n[0][0],o=e.invertX(t[1][0])-n[1][0],a=e.invertY(t[0][1])-n[0][1],i=e.invertY(t[1][1])-n[1][1];return e.translate(o>r?(r+o)/2:Math.min(0,r)||Math.max(0,o),i>a?(a+i)/2:Math.min(0,a)||Math.max(0,i))}function ra(){var e,t,n,r=Qo,o=Zo,a=na,i=ea,l=ta,s=[0,1/0],c=[[-1/0,-1/0],[1/0,1/0]],u=250,d=Qn,f=Ot("start","zoom","end"),p=0,h=10;function m(e){e.property("__zoom",Jo).on("wheel.zoom",E,{passive:!1}).on("mousedown.zoom",x).on("dblclick.zoom",S).filter(l).on("touchstart.zoom",k).on("touchmove.zoom",R).on("touchend.zoom touchcancel.zoom",N).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function g(e,t){return(t=Math.max(s[0],Math.min(s[1],t)))===e.k?e:new qo(t,e.x,e.y)}function b(e,t,n){var r=t[0]-n[0]*e.k,o=t[1]-n[1]*e.k;return r===e.x&&o===e.y?e:new qo(e.k,r,o)}function y(e){return[(+e[0][0]+ +e[1][0])/2,(+e[0][1]+ +e[1][1])/2]}function v(e,t,n,r){e.on("start.zoom",(function(){w(this,arguments).event(r).start()})).on("interrupt.zoom end.zoom",(function(){w(this,arguments).event(r).end()})).tween("zoom",(function(){var e=this,a=arguments,i=w(e,a).event(r),l=o.apply(e,a),s=null==n?y(l):"function"==typeof n?n.apply(e,a):n,c=Math.max(l[1][0]-l[0][0],l[1][1]-l[0][1]),u=e.__zoom,f="function"==typeof t?t.apply(e,a):t,p=d(u.invert(s).concat(c/u.k),f.invert(s).concat(c/f.k));return function(e){if(1===e)e=f;else{var t=p(e),n=c/t[2];e=new qo(n,s[0]-t[0]*n,s[1]-t[1]*n)}i.zoom(null,e)}}))}function w(e,t,n){return!n&&e.__zooming||new _(e,t)}function _(e,t){this.that=e,this.args=t,this.active=0,this.sourceEvent=null,this.extent=o.apply(e,t),this.taps=0}function E(e,...t){if(r.apply(this,arguments)){var n=w(this,t).event(e),o=this.__zoom,l=Math.max(s[0],Math.min(s[1],o.k*Math.pow(2,i.apply(this,arguments)))),u=Zn(e);if(n.wheel)n.mouse[0][0]===u[0]&&n.mouse[0][1]===u[1]||(n.mouse[1]=o.invert(n.mouse[0]=u)),clearTimeout(n.wheel);else{if(o.k===l)return;n.mouse=[u,o.invert(u)],xr(this),n.start()}Ko(e),n.wheel=setTimeout((function(){n.wheel=null,n.end()}),150),n.zoom("mouse",a(b(g(o,l),n.mouse[0],n.mouse[1]),n.extent,c))}}function x(e,...t){if(!n&&r.apply(this,arguments)){var o=e.currentTarget,i=w(this,t,!0).event(e),l=Bn(e.view).on("mousemove.zoom",(function(e){if(Ko(e),!i.moved){var t=e.clientX-u,n=e.clientY-d;i.moved=t*t+n*n>p}i.event(e).zoom("mouse",a(b(i.that.__zoom,i.mouse[0]=Zn(e,o),i.mouse[1]),i.extent,c))}),!0).on("mouseup.zoom",(function(e){l.on("mousemove.zoom mouseup.zoom",null),Yn(e.view,i.moved),Ko(e),i.event(e).end()}),!0),s=Zn(e,o),u=e.clientX,d=e.clientY;Xn(e.view),Yo(e),i.mouse=[s,this.__zoom.invert(s)],xr(this),i.start()}}function S(e,...t){if(r.apply(this,arguments)){var n=this.__zoom,i=Zn(e.changedTouches?e.changedTouches[0]:e,this),l=n.invert(i),s=n.k*(e.shiftKey?.5:2),d=a(b(g(n,s),i,l),o.apply(this,t),c);Ko(e),u>0?Bn(this).transition().duration(u).call(v,d,i,e):Bn(this).call(m.transform,d,i,e)}}function k(n,...o){if(r.apply(this,arguments)){var a,i,l,s,c=n.touches,u=c.length,d=w(this,o,n.changedTouches.length===u).event(n);for(Yo(n),i=0;i()=>e;function aa(e,{sourceEvent:t,subject:n,target:r,identifier:o,active:a,x:i,y:l,dx:s,dy:c,dispatch:u}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},subject:{value:n,enumerable:!0,configurable:!0},target:{value:r,enumerable:!0,configurable:!0},identifier:{value:o,enumerable:!0,configurable:!0},active:{value:a,enumerable:!0,configurable:!0},x:{value:i,enumerable:!0,configurable:!0},y:{value:l,enumerable:!0,configurable:!0},dx:{value:s,enumerable:!0,configurable:!0},dy:{value:c,enumerable:!0,configurable:!0},_:{value:u}})}function ia(e){return!e.ctrlKey&&!e.button}function la(){return this.parentNode}function sa(e,t){return null==t?{x:e.x,y:e.y}:t}function ca(){return navigator.maxTouchPoints||"ontouchstart"in this}aa.prototype.on=function(){var e=this._.on.apply(this._,arguments);return e===this._?this:e};var ua=i(5206);const da=(0,ht.createContext)(null),fa=da.Provider,pa="[React Flow]: Seems like you have not used zustand provider as an ancestor. Help: https://reactflow.dev/error#001";function ha(e,t){const n=(0,ht.useContext)(da);if(null===n)throw new Error(pa);return _t(n,e,t)}const ma=()=>{const e=(0,ht.useContext)(da);if(null===e)throw new Error(pa);return(0,ht.useMemo)((()=>({getState:e.getState,setState:e.setState,subscribe:e.subscribe,destroy:e.destroy})),[e])},ga=e=>e.userSelectionActive?"none":"all";function ba({position:e,children:t,className:n,style:r,...o}){const a=ha(ga),i=`${e}`.split("-");return ht.createElement("div",{className:mt(["react-flow__panel",n,...i]),style:{...r,pointerEvents:a},...o},t)}function ya({proOptions:e,position:t="bottom-right"}){return e?.hideAttribution?null:ht.createElement(ba,{position:t,className:"react-flow__attribution","data-message":"Please only hide this attribution when you are subscribed to React Flow Pro: https://reactflow.dev/pro"},ht.createElement("a",{href:"https://reactflow.dev",target:"_blank",rel:"noopener noreferrer","aria-label":"React Flow attribution"},"React Flow"))}var va=(0,ht.memo)((({x:e,y:t,label:n,labelStyle:r={},labelShowBg:o=!0,labelBgStyle:a={},labelBgPadding:i=[2,4],labelBgBorderRadius:l=2,children:s,className:c,...u})=>{const d=(0,ht.useRef)(null),[f,p]=(0,ht.useState)({x:0,y:0,width:0,height:0}),h=mt(["react-flow__edge-textwrapper",c]);return(0,ht.useEffect)((()=>{if(d.current){const e=d.current.getBBox();p({x:e.x,y:e.y,width:e.width,height:e.height})}}),[n]),void 0!==n&&n?ht.createElement("g",{transform:`translate(${e-f.width/2} ${t-f.height/2})`,className:h,visibility:f.width?"visible":"hidden",...u},o&&ht.createElement("rect",{width:f.width+2*i[0],x:-i[0],y:-i[1],height:f.height+2*i[1],className:"react-flow__edge-textbg",style:a,rx:l,ry:l}),ht.createElement("text",{className:"react-flow__edge-text",y:f.height/2,dy:"0.3em",ref:d,style:r},n),s):null}));const wa=e=>({width:e.offsetWidth,height:e.offsetHeight}),_a=(e,t=0,n=1)=>Math.min(Math.max(e,t),n),Ea=(e={x:0,y:0},t)=>({x:_a(e.x,t[0][0],t[1][0]),y:_a(e.y,t[0][1],t[1][1])}),xa=(e,t,n)=>en?-_a(Math.abs(e-n),1,50)/50:0,Sa=(e,t)=>[20*xa(e.x,35,t.width-35),20*xa(e.y,35,t.height-35)],ka=e=>e.getRootNode?.()||window?.document,Ra=(e,t)=>({x:Math.min(e.x,t.x),y:Math.min(e.y,t.y),x2:Math.max(e.x2,t.x2),y2:Math.max(e.y2,t.y2)}),Na=({x:e,y:t,width:n,height:r})=>({x:e,y:t,x2:e+n,y2:t+r}),Ca=({x:e,y:t,x2:n,y2:r})=>({x:e,y:t,width:n-e,height:r-t}),Oa=e=>({...e.positionAbsolute||{x:0,y:0},width:e.width||0,height:e.height||0}),Aa=(e,t)=>{const n=Math.max(0,Math.min(e.x+e.width,t.x+t.width)-Math.max(e.x,t.x)),r=Math.max(0,Math.min(e.y+e.height,t.y+t.height)-Math.max(e.y,t.y));return Math.ceil(n*r)},Pa=e=>!isNaN(e)&&isFinite(e),Da=Symbol.for("internals"),Ta=["Enter"," ","Escape"],Ia=(e,t)=>{};function ja(e){const t=(e=>"nativeEvent"in e)(e)?e.nativeEvent:e,n=t.composedPath?.()?.[0]||e.target;return["INPUT","SELECT","TEXTAREA"].includes(n?.nodeName)||n?.hasAttribute("contenteditable")||!!n?.closest(".nokey")}const Ma=e=>"clientX"in e,$a=(e,t)=>{const n=Ma(e),r=n?e.clientX:e.touches?.[0].clientX,o=n?e.clientY:e.touches?.[0].clientY;return{x:r-(t?.left??0),y:o-(t?.top??0)}},La=()=>"undefined"!=typeof navigator&&navigator?.userAgent?.indexOf("Mac")>=0,za=({id:e,path:t,labelX:n,labelY:r,label:o,labelStyle:a,labelShowBg:i,labelBgStyle:l,labelBgPadding:s,labelBgBorderRadius:c,style:u,markerEnd:d,markerStart:f,interactionWidth:p=20})=>ht.createElement(ht.Fragment,null,ht.createElement("path",{id:e,style:u,d:t,fill:"none",className:"react-flow__edge-path",markerEnd:d,markerStart:f}),p&&ht.createElement("path",{d:t,fill:"none",strokeOpacity:0,strokeWidth:p,className:"react-flow__edge-interaction"}),o&&Pa(n)&&Pa(r)?ht.createElement(va,{x:n,y:r,label:o,labelStyle:a,labelShowBg:i,labelBgStyle:l,labelBgPadding:s,labelBgBorderRadius:c}):null);function Fa(e,t,n){return void 0===n?n:r=>{const o=t().edges.find((t=>t.id===e));o&&n(r,{...o})}}function Wa({sourceX:e,sourceY:t,targetX:n,targetY:r}){const o=Math.abs(n-e)/2,a=n{const[g,b,y]=Ka({sourceX:e,sourceY:t,sourcePosition:o,targetX:n,targetY:r,targetPosition:a});return ht.createElement(za,{path:g,labelX:b,labelY:y,label:i,labelStyle:l,labelShowBg:s,labelBgStyle:c,labelBgPadding:u,labelBgBorderRadius:d,style:f,markerEnd:p,markerStart:h,interactionWidth:m})}));Qa.displayName="SimpleBezierEdge";const Za={[Xa.Left]:{x:-1,y:0},[Xa.Right]:{x:1,y:0},[Xa.Top]:{x:0,y:-1},[Xa.Bottom]:{x:0,y:1}},Ja=(e,t)=>Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2));function ei({sourceX:e,sourceY:t,sourcePosition:n=Xa.Bottom,targetX:r,targetY:o,targetPosition:a=Xa.Top,borderRadius:i=5,centerX:l,centerY:s,offset:c=20}){const[u,d,f,p,h]=function({source:e,sourcePosition:t=Xa.Bottom,target:n,targetPosition:r=Xa.Top,center:o,offset:a}){const i=Za[t],l=Za[r],s={x:e.x+i.x*a,y:e.y+i.y*a},c={x:n.x+l.x*a,y:n.y+l.y*a},u=(({source:e,sourcePosition:t=Xa.Bottom,target:n})=>t===Xa.Left||t===Xa.Right?e.xe[d]?-1:1)*r:b[d]=(c[d]>n[d]?-1:1)*r}}if(t!==r){const e="x"===d?"y":"x",t=i[d]===l[e],n=s[e]>c[e],r=s[e]=Math.max(Math.abs(y.y-m[0].y),Math.abs(v.y-m[0].y))?(p=(y.x+v.x)/2,h=m[0].y):(p=m[0].x,h=(y.y+v.y)/2)}return[[e,{x:s.x+g.x,y:s.y+g.y},...m,{x:c.x+b.x,y:c.y+b.y},n],p,h,w,_]}({source:{x:e,y:t},sourcePosition:n,target:{x:r,y:o},targetPosition:a,center:{x:l,y:s},offset:c});return[u.reduce(((e,t,n)=>{let r="";return r=n>0&&n{const[b,y,v]=ei({sourceX:e,sourceY:t,sourcePosition:d,targetX:n,targetY:r,targetPosition:f,borderRadius:m?.borderRadius,offset:m?.offset});return ht.createElement(za,{path:b,labelX:y,labelY:v,label:o,labelStyle:a,labelShowBg:i,labelBgStyle:l,labelBgPadding:s,labelBgBorderRadius:c,style:u,markerEnd:p,markerStart:h,interactionWidth:g})}));ti.displayName="SmoothStepEdge";const ni=(0,ht.memo)((e=>ht.createElement(ti,{...e,pathOptions:(0,ht.useMemo)((()=>({borderRadius:0,offset:e.pathOptions?.offset})),[e.pathOptions?.offset])})));ni.displayName="StepEdge";const ri=(0,ht.memo)((({sourceX:e,sourceY:t,targetX:n,targetY:r,label:o,labelStyle:a,labelShowBg:i,labelBgStyle:l,labelBgPadding:s,labelBgBorderRadius:c,style:u,markerEnd:d,markerStart:f,interactionWidth:p})=>{const[h,m,g]=function({sourceX:e,sourceY:t,targetX:n,targetY:r}){const[o,a,i,l]=Wa({sourceX:e,sourceY:t,targetX:n,targetY:r});return[`M ${e},${t}L ${n},${r}`,o,a,i,l]}({sourceX:e,sourceY:t,targetX:n,targetY:r});return ht.createElement(za,{path:h,labelX:m,labelY:g,label:o,labelStyle:a,labelShowBg:i,labelBgStyle:l,labelBgPadding:s,labelBgBorderRadius:c,style:u,markerEnd:d,markerStart:f,interactionWidth:p})}));function oi(e,t){return e>=0?.5*e:25*t*Math.sqrt(-e)}function ai({pos:e,x1:t,y1:n,x2:r,y2:o,c:a}){switch(e){case Xa.Left:return[t-oi(t-r,a),n];case Xa.Right:return[t+oi(r-t,a),n];case Xa.Top:return[t,n-oi(n-o,a)];case Xa.Bottom:return[t,n+oi(o-n,a)]}}function ii({sourceX:e,sourceY:t,sourcePosition:n=Xa.Bottom,targetX:r,targetY:o,targetPosition:a=Xa.Top,curvature:i=.25}){const[l,s]=ai({pos:n,x1:e,y1:t,x2:r,y2:o,c:i}),[c,u]=ai({pos:a,x1:r,y1:o,x2:e,y2:t,c:i}),[d,f,p,h]=Ga({sourceX:e,sourceY:t,targetX:r,targetY:o,sourceControlX:l,sourceControlY:s,targetControlX:c,targetControlY:u});return[`M${e},${t} C${l},${s} ${c},${u} ${r},${o}`,d,f,p,h]}ri.displayName="StraightEdge";const li=(0,ht.memo)((({sourceX:e,sourceY:t,targetX:n,targetY:r,sourcePosition:o=Xa.Bottom,targetPosition:a=Xa.Top,label:i,labelStyle:l,labelShowBg:s,labelBgStyle:c,labelBgPadding:u,labelBgBorderRadius:d,style:f,markerEnd:p,markerStart:h,pathOptions:m,interactionWidth:g})=>{const[b,y,v]=ii({sourceX:e,sourceY:t,sourcePosition:o,targetX:n,targetY:r,targetPosition:a,curvature:m?.curvature});return ht.createElement(za,{path:b,labelX:y,labelY:v,label:i,labelStyle:l,labelShowBg:s,labelBgStyle:c,labelBgPadding:u,labelBgBorderRadius:d,style:f,markerEnd:p,markerStart:h,interactionWidth:g})}));li.displayName="BezierEdge";const si=(0,ht.createContext)(null),ci=si.Provider;si.Consumer;const ui=e=>"id"in e&&!("source"in e)&&!("target"in e),di=({source:e,sourceHandle:t,target:n,targetHandle:r})=>`reactflow__edge-${e}${t||""}-${n}${r||""}`,fi=(e,t)=>void 0===e?"":"string"==typeof e?e:`${t?`${t}__`:""}${Object.keys(e).sort().map((t=>`${t}=${e[t]}`)).join("&")}`,pi=(e,t)=>{if(!e.source||!e.target)return t;let n;var r;return n="id"in(r=e)&&"source"in r&&"target"in r?{...e}:{...e,id:di(e)},((e,t)=>t.some((t=>!(t.source!==e.source||t.target!==e.target||t.sourceHandle!==e.sourceHandle&&(t.sourceHandle||e.sourceHandle)||t.targetHandle!==e.targetHandle&&(t.targetHandle||e.targetHandle)))))(n,t)?t:t.concat(n)},hi=({x:e,y:t},[n,r,o],a,[i,l])=>{const s={x:(e-n)/o,y:(t-r)/o};return a?{x:i*Math.round(s.x/i),y:l*Math.round(s.y/l)}:s},mi=({x:e,y:t},[n,r,o])=>({x:e*o+n,y:t*o+r}),gi=(e,t=[0,0])=>{if(!e)return{x:0,y:0,positionAbsolute:{x:0,y:0}};const n=(e.width??0)*t[0],r=(e.height??0)*t[1],o={x:e.position.x-n,y:e.position.y-r};return{...o,positionAbsolute:e.positionAbsolute?{x:e.positionAbsolute.x-n,y:e.positionAbsolute.y-r}:o}},bi=(e,t=[0,0])=>{if(0===e.length)return{x:0,y:0,width:0,height:0};const n=e.reduce(((e,n)=>{const{x:r,y:o}=gi(n,t).positionAbsolute;return Ra(e,Na({x:r,y:o,width:n.width||0,height:n.height||0}))}),{x:1/0,y:1/0,x2:-1/0,y2:-1/0});return Ca(n)},yi=(e,t,[n,r,o]=[0,0,1],a=!1,i=!1,l=[0,0])=>{const s={x:(t.x-n)/o,y:(t.y-r)/o,width:t.width/o,height:t.height/o},c=[];return e.forEach((e=>{const{width:t,height:n,selectable:r=!0,hidden:o=!1}=e;if(i&&!r||o)return!1;const{positionAbsolute:u}=gi(e,l),d={x:u.x,y:u.y,width:t||0,height:n||0},f=Aa(s,d);(void 0===t||void 0===n||null===t||null===n||a&&f>0||f>=(t||0)*(n||0)||e.dragging)&&c.push(e)})),c},vi=(e,t)=>{const n=e.map((e=>e.id));return t.filter((e=>n.includes(e.source)||n.includes(e.target)))},wi=(e,t,n,r,o,a=.1)=>{const i=t/(e.width*(1+a)),l=n/(e.height*(1+a)),s=Math.min(i,l),c=_a(s,r,o);return{x:t/2-(e.x+e.width/2)*c,y:n/2-(e.y+e.height/2)*c,zoom:c}},_i=(e,t=0)=>e.transition().duration(t);function Ei(e,t,n,r){return(t[n]||[]).reduce(((t,o)=>(`${e.id}-${o.id}-${n}`!==r&&t.push({id:o.id||null,type:n,nodeId:e.id,x:(e.positionAbsolute?.x??0)+o.x+o.width/2,y:(e.positionAbsolute?.y??0)+o.y+o.height/2}),t)),[])}const xi={source:null,target:null,sourceHandle:null,targetHandle:null},Si=()=>({handleDomNode:null,isValid:!1,connection:xi,endHandle:null});function ki(e,t,n,r,o,a,i){const l="target"===o,s=i.querySelector(`.react-flow__handle[data-id="${e?.nodeId}-${e?.id}-${e?.type}"]`),c={...Si(),handleDomNode:s};if(s){const e=Ri(void 0,s),o=s.getAttribute("data-nodeid"),i=s.getAttribute("data-handleid"),u=s.classList.contains("connectable"),d=s.classList.contains("connectableend"),f={source:l?o:n,sourceHandle:l?i:r,target:l?n:o,targetHandle:l?r:i};c.connection=f,u&&d&&(t===Ba.Strict?l&&"source"===e||!l&&"target"===e:o!==n||i!==r)&&(c.endHandle={nodeId:o,handleId:i,type:e},c.isValid=a(f))}return c}function Ri(e,t){return e||(t?.classList.contains("target")?"target":t?.classList.contains("source")?"source":null)}function Ni(e){e?.classList.remove("valid","connecting","react-flow__handle-valid","react-flow__handle-connecting")}function Ci(e,t){let n=null;return t?n="valid":e&&!t&&(n="invalid"),n}function Oi({event:e,handleId:t,nodeId:n,onConnect:r,isTarget:o,getState:a,setState:i,isValidConnection:l,edgeUpdaterType:s,onReconnectEnd:c}){const u=ka(e.target),{connectionMode:d,domNode:f,autoPanOnConnect:p,connectionRadius:h,onConnectStart:m,panBy:g,getNodes:b,cancelConnection:y}=a();let v,w=0;const{x:_,y:E}=$a(e),x=u?.elementFromPoint(_,E),S=Ri(s,x),k=f?.getBoundingClientRect();if(!k||!S)return;let R,N=$a(e,k),C=!1,O=null,A=!1,P=null;const D=function({nodes:e,nodeId:t,handleId:n,handleType:r}){return e.reduce(((e,o)=>{if(o[Da]){const{handleBounds:a}=o[Da];let i=[],l=[];a&&(i=Ei(o,a,"source",`${t}-${n}-${r}`),l=Ei(o,a,"target",`${t}-${n}-${r}`)),e.push(...i,...l)}return e}),[])}({nodes:b(),nodeId:n,handleId:t,handleType:S}),T=()=>{if(!p)return;const[e,t]=Sa(N,k);g({x:e,y:t}),w=requestAnimationFrame(T)};function I(e){const{transform:r}=a();N=$a(e,k);const{handle:s,validHandleResult:c}=function(e,t,n,r,o,a){const{x:i,y:l}=$a(e),s=t.elementsFromPoint(i,l).find((e=>e.classList.contains("react-flow__handle")));if(s){const e=s.getAttribute("data-nodeid");if(e){const t=Ri(void 0,s),r=s.getAttribute("data-handleid"),i=a({nodeId:e,id:r,type:t});if(i){const a=o.find((n=>n.nodeId===e&&n.type===t&&n.id===r));return{handle:{id:r,type:t,nodeId:e,x:a?.x||n.x,y:a?.y||n.y},validHandleResult:i}}}}let c=[],u=1/0;if(o.forEach((e=>{const t=Math.sqrt((e.x-n.x)**2+(e.y-n.y)**2);if(t<=r){const n=a(e);t<=u&&(te.isValid)),f=c.some((({handle:e})=>"target"===e.type));return c.find((({handle:e,validHandleResult:t})=>f?"target"===e.type:!d||t.isValid))||c[0]}(e,u,hi(N,r,!1,[1,1]),h,D,(e=>ki(e,d,n,t,o?"target":"source",l,u)));if(v=s,C||(T(),C=!0),P=c.handleDomNode,O=c.connection,A=c.isValid,i({connectionPosition:v&&A?mi({x:v.x,y:v.y},r):N,connectionStatus:Ci(!!v,A),connectionEndHandle:c.endHandle}),!v&&!A&&!P)return Ni(R);O.source!==O.target&&P&&(Ni(R),R=P,P.classList.add("connecting","react-flow__handle-connecting"),P.classList.toggle("valid",A),P.classList.toggle("react-flow__handle-valid",A))}function j(e){(v||P)&&O&&A&&r?.(O),a().onConnectEnd?.(e),s&&c?.(e),Ni(R),y(),cancelAnimationFrame(w),C=!1,A=!1,O=null,P=null,u.removeEventListener("mousemove",I),u.removeEventListener("mouseup",j),u.removeEventListener("touchmove",I),u.removeEventListener("touchend",j)}i({connectionPosition:N,connectionStatus:null,connectionNodeId:n,connectionHandleId:t,connectionHandleType:S,connectionStartHandle:{nodeId:n,handleId:t,type:S},connectionEndHandle:null}),m?.(e,{nodeId:n,handleId:t,handleType:S}),u.addEventListener("mousemove",I),u.addEventListener("mouseup",j),u.addEventListener("touchmove",I),u.addEventListener("touchend",j)}const Ai=()=>!0,Pi=e=>({connectionStartHandle:e.connectionStartHandle,connectOnClick:e.connectOnClick,noPanClassName:e.noPanClassName}),Di=(0,ht.forwardRef)((({type:e="source",position:t=Xa.Top,isValidConnection:n,isConnectable:r=!0,isConnectableStart:o=!0,isConnectableEnd:a=!0,id:i,onConnect:l,children:s,className:c,onMouseDown:u,onTouchStart:d,...f},p)=>{const h=i||null,m="target"===e,g=ma(),b=(0,ht.useContext)(si),{connectOnClick:y,noPanClassName:v}=ha(Pi,xt),{connecting:w,clickConnecting:_}=ha(((e,t,n)=>r=>{const{connectionStartHandle:o,connectionEndHandle:a,connectionClickStartHandle:i}=r;return{connecting:o?.nodeId===e&&o?.handleId===t&&o?.type===n||a?.nodeId===e&&a?.handleId===t&&a?.type===n,clickConnecting:i?.nodeId===e&&i?.handleId===t&&i?.type===n}})(b,h,e),xt);b||g.getState().onError?.("010","Handle: No node id found. Make sure to only use a Handle inside a custom Node.");const E=e=>{const{defaultEdgeOptions:t,onConnect:n,hasDefaultEdges:r}=g.getState(),o={...t,...e};if(r){const{edges:e,setEdges:t}=g.getState();t(pi(o,e))}n?.(o),l?.(o)},x=e=>{if(!b)return;const t=Ma(e);o&&(t&&0===e.button||!t)&&Oi({event:e,handleId:h,nodeId:b,onConnect:E,isTarget:m,getState:g.getState,setState:g.setState,isValidConnection:n||g.getState().isValidConnection||Ai}),t?u?.(e):d?.(e)};return ht.createElement("div",{"data-handleid":h,"data-nodeid":b,"data-handlepos":t,"data-id":`${b}-${h}-${e}`,className:mt(["react-flow__handle",`react-flow__handle-${t}`,"nodrag",v,c,{source:!m,target:m,connectable:r,connectablestart:o,connectableend:a,connecting:_,connectionindicator:r&&(o&&!w||a&&w)}]),onMouseDown:x,onTouchStart:x,onClick:y?t=>{const{onClickConnectStart:r,onClickConnectEnd:a,connectionClickStartHandle:i,connectionMode:l,isValidConnection:s}=g.getState();if(!b||!i&&!o)return;if(!i)return r?.(t,{nodeId:b,handleId:h,handleType:e}),void g.setState({connectionClickStartHandle:{nodeId:b,type:e,handleId:h}});const c=ka(t.target),u=n||s||Ai,{connection:d,isValid:f}=ki({nodeId:b,id:h,type:e},l,i.nodeId,i.handleId||null,i.type,u,c);f&&E(d),a?.(t),g.setState({connectionClickStartHandle:null})}:void 0,ref:p,...f},s)}));Di.displayName="Handle";var Ti=(0,ht.memo)(Di);const Ii=({data:e,isConnectable:t,targetPosition:n=Xa.Top,sourcePosition:r=Xa.Bottom})=>ht.createElement(ht.Fragment,null,ht.createElement(Ti,{type:"target",position:n,isConnectable:t}),e?.label,ht.createElement(Ti,{type:"source",position:r,isConnectable:t}));Ii.displayName="DefaultNode";var ji=(0,ht.memo)(Ii);const Mi=({data:e,isConnectable:t,sourcePosition:n=Xa.Bottom})=>ht.createElement(ht.Fragment,null,e?.label,ht.createElement(Ti,{type:"source",position:n,isConnectable:t}));Mi.displayName="InputNode";var $i=(0,ht.memo)(Mi);const Li=({data:e,isConnectable:t,targetPosition:n=Xa.Top})=>ht.createElement(ht.Fragment,null,ht.createElement(Ti,{type:"target",position:n,isConnectable:t}),e?.label);Li.displayName="OutputNode";var zi=(0,ht.memo)(Li);const Fi=()=>null;Fi.displayName="GroupNode";const Wi=e=>({selectedNodes:e.getNodes().filter((e=>e.selected)),selectedEdges:e.edges.filter((e=>e.selected)).map((e=>({...e})))}),Gi=e=>e.id;function Bi(e,t){return xt(e.selectedNodes.map(Gi),t.selectedNodes.map(Gi))&&xt(e.selectedEdges.map(Gi),t.selectedEdges.map(Gi))}const Vi=(0,ht.memo)((({onSelectionChange:e})=>{const t=ma(),{selectedNodes:n,selectedEdges:r}=ha(Wi,Bi);return(0,ht.useEffect)((()=>{const o={nodes:n,edges:r};e?.(o),t.getState().onSelectionChange.forEach((e=>e(o)))}),[n,r,e]),null}));Vi.displayName="SelectionListener";const Hi=e=>!!e.onSelectionChange;function Ui({onSelectionChange:e}){const t=ha(Hi);return e||t?ht.createElement(Vi,{onSelectionChange:e}):null}const qi=e=>({setNodes:e.setNodes,setEdges:e.setEdges,setDefaultNodesAndEdges:e.setDefaultNodesAndEdges,setMinZoom:e.setMinZoom,setMaxZoom:e.setMaxZoom,setTranslateExtent:e.setTranslateExtent,setNodeExtent:e.setNodeExtent,reset:e.reset});function Xi(e,t){(0,ht.useEffect)((()=>{void 0!==e&&t(e)}),[e])}function Yi(e,t,n){(0,ht.useEffect)((()=>{void 0!==t&&n({[e]:t})}),[t])}const Ki=({nodes:e,edges:t,defaultNodes:n,defaultEdges:r,onConnect:o,onConnectStart:a,onConnectEnd:i,onClickConnectStart:l,onClickConnectEnd:s,nodesDraggable:c,nodesConnectable:u,nodesFocusable:d,edgesFocusable:f,edgesUpdatable:p,elevateNodesOnSelect:h,minZoom:m,maxZoom:g,nodeExtent:b,onNodesChange:y,onEdgesChange:v,elementsSelectable:w,connectionMode:_,snapGrid:E,snapToGrid:x,translateExtent:S,connectOnClick:k,defaultEdgeOptions:R,fitView:N,fitViewOptions:C,onNodesDelete:O,onEdgesDelete:A,onNodeDrag:P,onNodeDragStart:D,onNodeDragStop:T,onSelectionDrag:I,onSelectionDragStart:j,onSelectionDragStop:M,noPanClassName:$,nodeOrigin:L,rfId:z,autoPanOnConnect:F,autoPanOnNodeDrag:W,onError:G,connectionRadius:B,isValidConnection:V,nodeDragThreshold:H})=>{const{setNodes:U,setEdges:q,setDefaultNodesAndEdges:X,setMinZoom:Y,setMaxZoom:K,setTranslateExtent:Q,setNodeExtent:Z,reset:J}=ha(qi,xt),ee=ma();return(0,ht.useEffect)((()=>{const e=r?.map((e=>({...e,...R})));return X(n,e),()=>{J()}}),[]),Yi("defaultEdgeOptions",R,ee.setState),Yi("connectionMode",_,ee.setState),Yi("onConnect",o,ee.setState),Yi("onConnectStart",a,ee.setState),Yi("onConnectEnd",i,ee.setState),Yi("onClickConnectStart",l,ee.setState),Yi("onClickConnectEnd",s,ee.setState),Yi("nodesDraggable",c,ee.setState),Yi("nodesConnectable",u,ee.setState),Yi("nodesFocusable",d,ee.setState),Yi("edgesFocusable",f,ee.setState),Yi("edgesUpdatable",p,ee.setState),Yi("elementsSelectable",w,ee.setState),Yi("elevateNodesOnSelect",h,ee.setState),Yi("snapToGrid",x,ee.setState),Yi("snapGrid",E,ee.setState),Yi("onNodesChange",y,ee.setState),Yi("onEdgesChange",v,ee.setState),Yi("connectOnClick",k,ee.setState),Yi("fitViewOnInit",N,ee.setState),Yi("fitViewOnInitOptions",C,ee.setState),Yi("onNodesDelete",O,ee.setState),Yi("onEdgesDelete",A,ee.setState),Yi("onNodeDrag",P,ee.setState),Yi("onNodeDragStart",D,ee.setState),Yi("onNodeDragStop",T,ee.setState),Yi("onSelectionDrag",I,ee.setState),Yi("onSelectionDragStart",j,ee.setState),Yi("onSelectionDragStop",M,ee.setState),Yi("noPanClassName",$,ee.setState),Yi("nodeOrigin",L,ee.setState),Yi("rfId",z,ee.setState),Yi("autoPanOnConnect",F,ee.setState),Yi("autoPanOnNodeDrag",W,ee.setState),Yi("onError",G,ee.setState),Yi("connectionRadius",B,ee.setState),Yi("isValidConnection",V,ee.setState),Yi("nodeDragThreshold",H,ee.setState),Xi(e,U),Xi(t,q),Xi(m,Y),Xi(g,K),Xi(S,Q),Xi(b,Z),null},Qi={display:"none"},Zi={position:"absolute",width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0px, 0px, 0px, 0px)",clipPath:"inset(100%)"},Ji="react-flow__node-desc",el="react-flow__edge-desc",tl=e=>e.ariaLiveMessage;function nl({rfId:e}){const t=ha(tl);return ht.createElement("div",{id:`react-flow__aria-live-${e}`,"aria-live":"assertive","aria-atomic":"true",style:Zi},t)}function rl({rfId:e,disableKeyboardA11y:t}){return ht.createElement(ht.Fragment,null,ht.createElement("div",{id:`${Ji}-${e}`,style:Qi},"Press enter or space to select a node.",!t&&"You can then use the arrow keys to move the node around."," Press delete to remove it and escape to cancel."," "),ht.createElement("div",{id:`${el}-${e}`,style:Qi},"Press enter or space to select an edge. You can then press delete to remove it or escape to cancel."),!t&&ht.createElement(nl,{rfId:e}))}var ol=(e=null,t={actInsideInputWithModifier:!0})=>{const[n,r]=(0,ht.useState)(!1),o=(0,ht.useRef)(!1),a=(0,ht.useRef)(new Set([])),[i,l]=(0,ht.useMemo)((()=>{if(null!==e){const t=(Array.isArray(e)?e:[e]).filter((e=>"string"==typeof e)).map((e=>e.split("+"))),n=t.reduce(((e,t)=>e.concat(...t)),[]);return[t,n]}return[[],[]]}),[e]);return(0,ht.useEffect)((()=>{const n="undefined"!=typeof document?document:null,s=t?.target||n;if(null!==e){const e=e=>{if(o.current=e.ctrlKey||e.metaKey||e.shiftKey,(!o.current||o.current&&!t.actInsideInputWithModifier)&&ja(e))return!1;const n=il(e.code,l);a.current.add(e[n]),al(i,a.current,!1)&&(e.preventDefault(),r(!0))},n=e=>{if((!o.current||o.current&&!t.actInsideInputWithModifier)&&ja(e))return!1;const n=il(e.code,l);al(i,a.current,!0)?(r(!1),a.current.clear()):a.current.delete(e[n]),"Meta"===e.key&&a.current.clear(),o.current=!1},c=()=>{a.current.clear(),r(!1)};return s?.addEventListener("keydown",e),s?.addEventListener("keyup",n),window.addEventListener("blur",c),()=>{s?.removeEventListener("keydown",e),s?.removeEventListener("keyup",n),window.removeEventListener("blur",c)}}}),[e,r]),n};function al(e,t,n){return e.filter((e=>n||e.length===t.size)).some((e=>e.every((e=>t.has(e)))))}function il(e,t){return t.includes(e)?"code":"key"}function ll(e,t,n,r){const o=e.parentNode||e.parentId;if(!o)return n;const a=t.get(o),i=gi(a,r);return ll(a,t,{x:(n.x??0)+i.x,y:(n.y??0)+i.y,z:(a[Da]?.z??0)>(n.z??0)?a[Da]?.z??0:n.z??0},r)}function sl(e,t,n){e.forEach((r=>{const o=r.parentNode||r.parentId;if(o&&!e.has(o))throw new Error(`Parent node ${o} not found`);if(o||n?.[r.id]){const{x:o,y:a,z:i}=ll(r,e,{...r.position,z:r[Da]?.z??0},t);r.positionAbsolute={x:o,y:a},r[Da].z=i,n?.[r.id]&&(r[Da].isParent=!0)}}))}function cl(e,t,n,r){const o=new Map,a={},i=r?1e3:0;return e.forEach((e=>{const n=(Pa(e.zIndex)?e.zIndex:0)+(e.selected?i:0),r=t.get(e.id),l={...e,positionAbsolute:{x:e.position.x,y:e.position.y}},s=e.parentNode||e.parentId;s&&(a[s]=!0);const c=r?.type&&r?.type!==e.type;Object.defineProperty(l,Da,{enumerable:!1,value:{handleBounds:c?void 0:r?.[Da]?.handleBounds,z:n}}),o.set(e.id,l)})),sl(o,n,a),o}function ul(e,t={}){const{getNodes:n,width:r,height:o,minZoom:a,maxZoom:i,d3Zoom:l,d3Selection:s,fitViewOnInitDone:c,fitViewOnInit:u,nodeOrigin:d}=e(),f=t.initial&&!c&&u;if(l&&s&&(f||!t.initial)){const e=n().filter((e=>{const n=t.includeHiddenNodes?e.width&&e.height:!e.hidden;return t.nodes?.length?n&&t.nodes.some((t=>t.id===e.id)):n})),c=e.every((e=>e.width&&e.height));if(e.length>0&&c){const n=bi(e,d),{x:c,y:u,zoom:f}=wi(n,r,o,t.minZoom??a,t.maxZoom??i,t.padding??.1),p=Xo.translate(c,u).scale(f);return"number"==typeof t.duration&&t.duration>0?l.transform(_i(s,t.duration),p):l.transform(s,p),!0}}return!1}function dl(e,t){return e.forEach((e=>{const n=t.get(e.id);n&&t.set(n.id,{...n,[Da]:n[Da],selected:e.selected})})),new Map(t)}function fl(e,t){return t.map((t=>{const n=e.find((e=>e.id===t.id));return n&&(t.selected=n.selected),t}))}function pl({changedNodes:e,changedEdges:t,get:n,set:r}){const{nodeInternals:o,edges:a,onNodesChange:i,onEdgesChange:l,hasDefaultNodes:s,hasDefaultEdges:c}=n();e?.length&&(s&&r({nodeInternals:dl(e,o)}),i?.(e)),t?.length&&(c&&r({edges:fl(t,a)}),l?.(t))}const hl=()=>{},ml={zoomIn:hl,zoomOut:hl,zoomTo:hl,getZoom:()=>1,setViewport:hl,getViewport:()=>({x:0,y:0,zoom:1}),fitView:()=>!1,setCenter:hl,fitBounds:hl,project:e=>e,screenToFlowPosition:e=>e,flowToScreenPosition:e=>e,viewportInitialized:!1},gl=e=>({d3Zoom:e.d3Zoom,d3Selection:e.d3Selection});function bl(){const e=(()=>{const e=ma(),{d3Zoom:t,d3Selection:n}=ha(gl,xt),r=(0,ht.useMemo)((()=>n&&t?{zoomIn:e=>t.scaleBy(_i(n,e?.duration),1.2),zoomOut:e=>t.scaleBy(_i(n,e?.duration),1/1.2),zoomTo:(e,r)=>t.scaleTo(_i(n,r?.duration),e),getZoom:()=>e.getState().transform[2],setViewport:(r,o)=>{const[a,i,l]=e.getState().transform,s=Xo.translate(r.x??a,r.y??i).scale(r.zoom??l);t.transform(_i(n,o?.duration),s)},getViewport:()=>{const[t,n,r]=e.getState().transform;return{x:t,y:n,zoom:r}},fitView:t=>ul(e.getState,t),setCenter:(r,o,a)=>{const{width:i,height:l,maxZoom:s}=e.getState(),c=void 0!==a?.zoom?a.zoom:s,u=i/2-r*c,d=l/2-o*c,f=Xo.translate(u,d).scale(c);t.transform(_i(n,a?.duration),f)},fitBounds:(r,o)=>{const{width:a,height:i,minZoom:l,maxZoom:s}=e.getState(),{x:c,y:u,zoom:d}=wi(r,a,i,l,s,o?.padding??.1),f=Xo.translate(c,u).scale(d);t.transform(_i(n,o?.duration),f)},project:t=>{const{transform:n,snapToGrid:r,snapGrid:o}=e.getState();return console.warn("[DEPRECATED] `project` is deprecated. Instead use `screenToFlowPosition`. There is no need to subtract the react flow bounds anymore! https://reactflow.dev/api-reference/types/react-flow-instance#screen-to-flow-position"),hi(t,n,r,o)},screenToFlowPosition:t=>{const{transform:n,snapToGrid:r,snapGrid:o,domNode:a}=e.getState();if(!a)return t;const{x:i,y:l}=a.getBoundingClientRect(),s={x:t.x-i,y:t.y-l};return hi(s,n,r,o)},flowToScreenPosition:t=>{const{transform:n,domNode:r}=e.getState();if(!r)return t;const{x:o,y:a}=r.getBoundingClientRect(),i=mi(t,n);return{x:i.x+o,y:i.y+a}},viewportInitialized:!0}:ml),[t,n]);return r})(),t=ma(),n=(0,ht.useCallback)((()=>t.getState().getNodes().map((e=>({...e})))),[]),r=(0,ht.useCallback)((e=>t.getState().nodeInternals.get(e)),[]),o=(0,ht.useCallback)((()=>{const{edges:e=[]}=t.getState();return e.map((e=>({...e})))}),[]),a=(0,ht.useCallback)((e=>{const{edges:n=[]}=t.getState();return n.find((t=>t.id===e))}),[]),i=(0,ht.useCallback)((e=>{const{getNodes:n,setNodes:r,hasDefaultNodes:o,onNodesChange:a}=t.getState(),i=n(),l="function"==typeof e?e(i):e;if(o)r(l);else if(a){a(0===l.length?i.map((e=>({type:"remove",id:e.id}))):l.map((e=>({item:e,type:"reset"}))))}}),[]),l=(0,ht.useCallback)((e=>{const{edges:n=[],setEdges:r,hasDefaultEdges:o,onEdgesChange:a}=t.getState(),i="function"==typeof e?e(n):e;o?r(i):a&&a(0===i.length?n.map((e=>({type:"remove",id:e.id}))):i.map((e=>({item:e,type:"reset"}))))}),[]),s=(0,ht.useCallback)((e=>{const n=Array.isArray(e)?e:[e],{getNodes:r,setNodes:o,hasDefaultNodes:a,onNodesChange:i}=t.getState();if(a)o([...r(),...n]);else if(i){i(n.map((e=>({item:e,type:"add"}))))}}),[]),c=(0,ht.useCallback)((e=>{const n=Array.isArray(e)?e:[e],{edges:r=[],setEdges:o,hasDefaultEdges:a,onEdgesChange:i}=t.getState();a?o([...r,...n]):i&&i(n.map((e=>({item:e,type:"add"}))))}),[]),u=(0,ht.useCallback)((()=>{const{getNodes:e,edges:n=[],transform:r}=t.getState(),[o,a,i]=r;return{nodes:e().map((e=>({...e}))),edges:n.map((e=>({...e}))),viewport:{x:o,y:a,zoom:i}}}),[]),d=(0,ht.useCallback)((({nodes:e,edges:n})=>{const{nodeInternals:r,getNodes:o,edges:a,hasDefaultNodes:i,hasDefaultEdges:l,onNodesDelete:s,onEdgesDelete:c,onNodesChange:u,onEdgesChange:d}=t.getState(),f=(e||[]).map((e=>e.id)),p=(n||[]).map((e=>e.id)),h=o().reduce(((e,t)=>{const n=t.parentNode||t.parentId,r=!f.includes(t.id)&&n&&e.find((e=>e.id===n));return("boolean"!=typeof t.deletable||t.deletable)&&(f.includes(t.id)||r)&&e.push(t),e}),[]),m=a.filter((e=>"boolean"!=typeof e.deletable||e.deletable)),g=m.filter((e=>p.includes(e.id)));if(h||g){const e=vi(h,m),n=[...g,...e],o=n.reduce(((e,t)=>(e.includes(t.id)||e.push(t.id),e)),[]);(l||i)&&(l&&t.setState({edges:a.filter((e=>!o.includes(e.id)))}),i&&(h.forEach((e=>{r.delete(e.id)})),t.setState({nodeInternals:new Map(r)}))),o.length>0&&(c?.(n),d&&d(o.map((e=>({id:e,type:"remove"}))))),h.length>0&&(s?.(h),u)&&u(h.map((e=>({id:e.id,type:"remove"}))))}}),[]),f=(0,ht.useCallback)((e=>{const n=Pa((r=e).width)&&Pa(r.height)&&Pa(r.x)&&Pa(r.y);var r;const o=n?null:t.getState().nodeInternals.get(e.id);return n||o?[n?e:Oa(o),o,n]:[null,null,n]}),[]),p=(0,ht.useCallback)(((e,n=!0,r)=>{const[o,a,i]=f(e);return o?(r||t.getState().getNodes()).filter((e=>{if(!(i||e.id!==a.id&&e.positionAbsolute))return!1;const t=Oa(e),r=Aa(t,o);return n&&r>0||r>=o.width*o.height})):[]}),[]),h=(0,ht.useCallback)(((e,t,n=!0)=>{const[r]=f(e);if(!r)return!1;const o=Aa(r,t);return n&&o>0||o>=r.width*r.height}),[]);return(0,ht.useMemo)((()=>({...e,getNodes:n,getNode:r,getEdges:o,getEdge:a,setNodes:i,setEdges:l,addNodes:s,addEdges:c,toObject:u,deleteElements:d,getIntersectingNodes:p,isNodeIntersecting:h})),[e,n,r,o,a,i,l,s,c,u,d,p,h])}const yl={actInsideInputWithModifier:!1},vl={position:"absolute",width:"100%",height:"100%",top:0,left:0},wl=e=>({x:e.x,y:e.y,zoom:e.k}),_l=(e,t)=>e.target.closest(`.${t}`),El=(e,t)=>2===t&&Array.isArray(e)&&e.includes(2),xl=e=>{const t=e.ctrlKey&&La()?10:1;return-e.deltaY*(1===e.deltaMode?.05:e.deltaMode?1:.002)*t},Sl=e=>({d3Zoom:e.d3Zoom,d3Selection:e.d3Selection,d3ZoomHandler:e.d3ZoomHandler,userSelectionActive:e.userSelectionActive}),kl=({onMove:e,onMoveStart:t,onMoveEnd:n,onPaneContextMenu:r,zoomOnScroll:o=!0,zoomOnPinch:a=!0,panOnScroll:i=!1,panOnScrollSpeed:l=.5,panOnScrollMode:s=Va.Free,zoomOnDoubleClick:c=!0,elementsSelectable:u,panOnDrag:d=!0,defaultViewport:f,translateExtent:p,minZoom:h,maxZoom:m,zoomActivationKeyCode:g,preventScrolling:b=!0,children:y,noWheelClassName:v,noPanClassName:w})=>{const _=(0,ht.useRef)(),E=ma(),x=(0,ht.useRef)(!1),S=(0,ht.useRef)(!1),k=(0,ht.useRef)(null),R=(0,ht.useRef)({x:0,y:0,zoom:0}),{d3Zoom:N,d3Selection:C,d3ZoomHandler:O,userSelectionActive:A}=ha(Sl,xt),P=ol(g),D=(0,ht.useRef)(0),T=(0,ht.useRef)(!1),I=(0,ht.useRef)();return function(e){const t=ma();(0,ht.useEffect)((()=>{let n;const r=()=>{if(!e.current)return;const n=wa(e.current);0!==n.height&&0!==n.width||t.getState().onError?.("004","The React Flow parent container needs a width and a height to render the graph."),t.setState({width:n.width||500,height:n.height||500})};return r(),window.addEventListener("resize",r),e.current&&(n=new ResizeObserver((()=>r())),n.observe(e.current)),()=>{window.removeEventListener("resize",r),n&&e.current&&n.unobserve(e.current)}}),[])}(k),(0,ht.useEffect)((()=>{if(k.current){const e=k.current.getBoundingClientRect(),t=ra().scaleExtent([h,m]).translateExtent(p),n=Bn(k.current).call(t),r=Xo.translate(f.x,f.y).scale(_a(f.zoom,h,m)),o=[[0,0],[e.width,e.height]],a=t.constrain()(r,o,p);t.transform(n,a),t.wheelDelta(xl),E.setState({d3Zoom:t,d3Selection:n,d3ZoomHandler:n.on("wheel.zoom"),transform:[a.x,a.y,a.k],domNode:k.current.closest(".react-flow")})}}),[]),(0,ht.useEffect)((()=>{C&&N&&(!i||P||A?void 0!==O&&C.on("wheel.zoom",(function(e,t){if(!b&&"wheel"===e.type&&!e.ctrlKey||_l(e,v))return null;e.preventDefault(),O.call(this,e,t)}),{passive:!1}):C.on("wheel.zoom",(r=>{if(_l(r,v))return!1;r.preventDefault(),r.stopImmediatePropagation();const o=C.property("__zoom").k||1;if(r.ctrlKey&&a){const e=Zn(r),t=xl(r),n=o*Math.pow(2,t);return void N.scaleTo(C,n,e,r)}const i=1===r.deltaMode?20:1;let c=s===Va.Vertical?0:r.deltaX*i,u=s===Va.Horizontal?0:r.deltaY*i;!La()&&r.shiftKey&&s!==Va.Vertical&&(c=r.deltaY*i,u=0),N.translateBy(C,-c/o*l,-u/o*l,{internal:!0});const d=wl(C.property("__zoom")),{onViewportChangeStart:f,onViewportChange:p,onViewportChangeEnd:h}=E.getState();clearTimeout(I.current),T.current||(T.current=!0,t?.(r,d),f?.(d)),T.current&&(e?.(r,d),p?.(d),I.current=setTimeout((()=>{n?.(r,d),h?.(d),T.current=!1}),150))}),{passive:!1}))}),[A,i,s,C,N,O,P,a,b,v,t,e,n]),(0,ht.useEffect)((()=>{N&&N.on("start",(e=>{if(!e.sourceEvent||e.sourceEvent.internal)return null;D.current=e.sourceEvent?.button;const{onViewportChangeStart:n}=E.getState(),r=wl(e.transform);x.current=!0,R.current=r,"mousedown"===e.sourceEvent?.type&&E.setState({paneDragging:!0}),n?.(r),t?.(e.sourceEvent,r)}))}),[N,t]),(0,ht.useEffect)((()=>{N&&(A&&!x.current?N.on("zoom",null):A||N.on("zoom",(t=>{const{onViewportChange:n}=E.getState();if(E.setState({transform:[t.transform.x,t.transform.y,t.transform.k]}),S.current=!(!r||!El(d,D.current??0)),(e||n)&&!t.sourceEvent?.internal){const r=wl(t.transform);n?.(r),e?.(t.sourceEvent,r)}})))}),[A,N,e,d,r]),(0,ht.useEffect)((()=>{N&&N.on("end",(e=>{if(!e.sourceEvent||e.sourceEvent.internal)return null;const{onViewportChangeEnd:t}=E.getState();if(x.current=!1,E.setState({paneDragging:!1}),r&&El(d,D.current??0)&&!S.current&&r(e.sourceEvent),S.current=!1,(n||t)&&(o=R.current,a=e.transform,o.x!==a.x||o.y!==a.y||o.zoom!==a.k)){const r=wl(e.transform);R.current=r,clearTimeout(_.current),_.current=setTimeout((()=>{t?.(r),n?.(e.sourceEvent,r)}),i?150:0)}var o,a}))}),[N,i,d,n,r]),(0,ht.useEffect)((()=>{N&&N.filter((e=>{const t=P||o,n=a&&e.ctrlKey;if((!0===d||Array.isArray(d)&&d.includes(1))&&1===e.button&&"mousedown"===e.type&&(_l(e,"react-flow__node")||_l(e,"react-flow__edge")))return!0;if(!(d||t||i||c||a))return!1;if(A)return!1;if(!c&&"dblclick"===e.type)return!1;if(_l(e,v)&&"wheel"===e.type)return!1;if(_l(e,w)&&("wheel"!==e.type||i&&"wheel"===e.type&&!P))return!1;if(!a&&e.ctrlKey&&"wheel"===e.type)return!1;if(!t&&!i&&!n&&"wheel"===e.type)return!1;if(!d&&("mousedown"===e.type||"touchstart"===e.type))return!1;if(Array.isArray(d)&&!d.includes(e.button)&&"mousedown"===e.type)return!1;const r=Array.isArray(d)&&d.includes(e.button)||!e.button||e.button<=1;return(!e.ctrlKey||"wheel"===e.type)&&r}))}),[A,N,o,a,i,c,d,u,P]),ht.createElement("div",{className:"react-flow__renderer",ref:k,style:vl},y)},Rl=e=>({userSelectionActive:e.userSelectionActive,userSelectionRect:e.userSelectionRect});function Nl(){const{userSelectionActive:e,userSelectionRect:t}=ha(Rl,xt);return e&&t?ht.createElement("div",{className:"react-flow__selection react-flow__container",style:{width:t.width,height:t.height,transform:`translate(${t.x}px, ${t.y}px)`}}):null}function Cl(e,t){const n=t.parentNode||t.parentId,r=e.find((e=>e.id===n));if(r){const e=t.position.x+t.width-r.width,n=t.position.y+t.height-r.height;if(e>0||n>0||t.position.x<0||t.position.y<0){if(r.style={...r.style}||{},r.style.width=r.style.width??r.width,r.style.height=r.style.height??r.height,e>0&&(r.style.width+=e),n>0&&(r.style.height+=n),t.position.x<0){const e=Math.abs(t.position.x);r.position.x=r.position.x-e,r.style.width+=e,t.position.x=0}if(t.position.y<0){const e=Math.abs(t.position.y);r.position.y=r.position.y-e,r.style.height+=e,t.position.y=0}r.width=r.style.width,r.height=r.style.height}}}function Ol(e,t){if(e.some((e=>"reset"===e.type)))return e.filter((e=>"reset"===e.type)).map((e=>e.item));const n=e.filter((e=>"add"===e.type)).map((e=>e.item));return t.reduce(((t,n)=>{const r=e.filter((e=>e.id===n.id));if(0===r.length)return t.push(n),t;const o={...n};for(const e of r)if(e)switch(e.type){case"select":o.selected=e.selected;break;case"position":void 0!==e.position&&(o.position=e.position),void 0!==e.positionAbsolute&&(o.positionAbsolute=e.positionAbsolute),void 0!==e.dragging&&(o.dragging=e.dragging),o.expandParent&&Cl(t,o);break;case"dimensions":void 0!==e.dimensions&&(o.width=e.dimensions.width,o.height=e.dimensions.height),void 0!==e.updateStyle&&(o.style={...o.style||{},...e.dimensions}),"boolean"==typeof e.resizing&&(o.resizing=e.resizing),o.expandParent&&Cl(t,o);break;case"remove":return t}return t.push(o),t}),n)}function Al(e,t){return Ol(e,t)}function Pl(e,t){return Ol(e,t)}const Dl=(e,t)=>({id:e,type:"select",selected:t});function Tl(e,t){return e.reduce(((e,n)=>{const r=t.includes(n.id);return!n.selected&&r?(n.selected=!0,e.push(Dl(n.id,!0))):n.selected&&!r&&(n.selected=!1,e.push(Dl(n.id,!1))),e}),[])}const Il=(e,t)=>n=>{n.target===t.current&&e?.(n)},jl=e=>({userSelectionActive:e.userSelectionActive,elementsSelectable:e.elementsSelectable,dragging:e.paneDragging}),Ml=(0,ht.memo)((({isSelecting:e,selectionMode:t=Ha.Full,panOnDrag:n,onSelectionStart:r,onSelectionEnd:o,onPaneClick:a,onPaneContextMenu:i,onPaneScroll:l,onPaneMouseEnter:s,onPaneMouseMove:c,onPaneMouseLeave:u,children:d})=>{const f=(0,ht.useRef)(null),p=ma(),h=(0,ht.useRef)(0),m=(0,ht.useRef)(0),g=(0,ht.useRef)(),{userSelectionActive:b,elementsSelectable:y,dragging:v}=ha(jl,xt),w=()=>{p.setState({userSelectionActive:!1,userSelectionRect:null}),h.current=0,m.current=0},_=e=>{a?.(e),p.getState().resetSelectedElements(),p.setState({nodesSelectionActive:!1})},E=l?e=>l(e):void 0,x=y&&(e||b);return ht.createElement("div",{className:mt(["react-flow__pane",{dragging:v,selection:e}]),onClick:x?void 0:Il(_,f),onContextMenu:Il((e=>{Array.isArray(n)&&n?.includes(2)?e.preventDefault():i?.(e)}),f),onWheel:Il(E,f),onMouseEnter:x?void 0:s,onMouseDown:x?t=>{const{resetSelectedElements:n,domNode:o}=p.getState();if(g.current=o?.getBoundingClientRect(),!y||!e||0!==t.button||t.target!==f.current||!g.current)return;const{x:a,y:i}=$a(t,g.current);n(),p.setState({userSelectionRect:{width:0,height:0,startX:a,startY:i,x:a,y:i}}),r?.(t)}:void 0,onMouseMove:x?n=>{const{userSelectionRect:r,nodeInternals:o,edges:a,transform:i,onNodesChange:l,onEdgesChange:s,nodeOrigin:c,getNodes:u}=p.getState();if(!e||!g.current||!r)return;p.setState({userSelectionActive:!0,nodesSelectionActive:!1});const d=$a(n,g.current),f=r.startX??0,b=r.startY??0,y={...r,x:d.xe.id)),E=w.map((e=>e.id));if(h.current!==E.length){h.current=E.length;const e=Tl(v,E);e.length&&l?.(e)}if(m.current!==_.length){m.current=_.length;const e=Tl(a,_);e.length&&s?.(e)}p.setState({userSelectionRect:y})}:c,onMouseUp:x?e=>{if(0!==e.button)return;const{userSelectionRect:t}=p.getState();!b&&t&&e.target===f.current&&_?.(e),p.setState({nodesSelectionActive:h.current>0}),w(),o?.(e)}:void 0,onMouseLeave:x?e=>{b&&(p.setState({nodesSelectionActive:h.current>0}),o?.(e)),w()}:u,ref:f,style:vl},d,ht.createElement(Nl,null))}));function $l(e,t){const n=e.parentNode||e.parentId;if(!n)return!1;const r=t.get(n);return!!r&&(!!r.selected||$l(r,t))}function Ll(e,t,n){let r=e;do{if(r?.matches(t))return!0;if(r===n.current)return!1;r=r.parentElement}while(r);return!1}function zl(e,t,n,r){return Array.from(e.values()).filter((n=>(n.selected||n.id===r)&&(!n.parentNode||n.parentId||!$l(n,e))&&(n.draggable||t&&void 0===n.draggable))).map((e=>({id:e.id,position:e.position||{x:0,y:0},positionAbsolute:e.positionAbsolute||{x:0,y:0},distance:{x:n.x-(e.positionAbsolute?.x??0),y:n.y-(e.positionAbsolute?.y??0)},delta:{x:0,y:0},extent:e.extent,parentNode:e.parentNode||e.parentId,parentId:e.parentNode||e.parentId,width:e.width,height:e.height,expandParent:e.expandParent})))}function Fl(e,t,n,r,o=[0,0],a){const i=function(e,t){return t&&"parent"!==t?[t[0],[t[1][0]-(e.width||0),t[1][1]-(e.height||0)]]:t}(e,e.extent||r);let l=i;const s=e.parentNode||e.parentId;if("parent"!==e.extent||e.expandParent){if(e.extent&&s&&"parent"!==e.extent){const t=n.get(s),{x:r,y:a}=gi(t,o).positionAbsolute;l=[[e.extent[0][0]+r,e.extent[0][1]+a],[e.extent[1][0]+r,e.extent[1][1]+a]]}}else if(s&&e.width&&e.height){const t=n.get(s),{x:r,y:a}=gi(t,o).positionAbsolute;l=t&&Pa(r)&&Pa(a)&&Pa(t.width)&&Pa(t.height)?[[r+e.width*o[0],a+e.height*o[1]],[r+t.width-e.width+e.width*o[0],a+t.height-e.height+e.height*o[1]]]:l}else a?.("005","Only child nodes can use a parent extent."),l=i;let c={x:0,y:0};if(s){const e=n.get(s);c=gi(e,o).positionAbsolute}const u=l&&"parent"!==l?Ea(t,l):t;return{position:{x:u.x-c.x,y:u.y-c.y},positionAbsolute:u}}function Wl({nodeId:e,dragItems:t,nodeInternals:n}){const r=t.map((e=>({...n.get(e.id),position:e.position,positionAbsolute:e.positionAbsolute})));return[e?r.find((t=>t.id===e)):r[0],r]}Ml.displayName="Pane";const Gl=(e,t,n,r)=>{const o=t.querySelectorAll(e);if(!o||!o.length)return null;const a=Array.from(o),i=t.getBoundingClientRect(),l=i.width*r[0],s=i.height*r[1];return a.map((e=>{const t=e.getBoundingClientRect();return{id:e.getAttribute("data-handleid"),position:e.getAttribute("data-handlepos"),x:(t.left-i.left-l)/n,y:(t.top-i.top-s)/n,...wa(e)}}))};function Bl(e,t,n){return void 0===n?n:r=>{const o=t().nodeInternals.get(e);o&&n(r,{...o})}}function Vl({id:e,store:t,unselect:n=!1,nodeRef:r}){const{addSelectedNodes:o,unselectNodesAndEdges:a,multiSelectionActive:i,nodeInternals:l,onError:s}=t.getState(),c=l.get(e);c?(t.setState({nodesSelectionActive:!1}),c.selected?(n||c.selected&&i)&&(a({nodes:[c],edges:[]}),requestAnimationFrame((()=>r?.current?.blur()))):o([e])):s?.("012",(e=>`Node with id "${e}" does not exist, it may have been removed. This can happen when a node is deleted before the "onNodeClick" handler is called.`)(e))}function Hl(e){return(t,n,r)=>e?.(t,r)}function Ul({nodeRef:e,disabled:t=!1,noDragClassName:n,handleSelector:r,nodeId:o,isSelectable:a,selectNodesOnDrag:i}){const l=ma(),[s,c]=(0,ht.useState)(!1),u=(0,ht.useRef)([]),d=(0,ht.useRef)({x:null,y:null}),f=(0,ht.useRef)(0),p=(0,ht.useRef)(null),h=(0,ht.useRef)({x:0,y:0}),m=(0,ht.useRef)(null),g=(0,ht.useRef)(!1),b=(0,ht.useRef)(!1),y=(0,ht.useRef)(!1),v=function(){const e=ma();return(0,ht.useCallback)((({sourceEvent:t})=>{const{transform:n,snapGrid:r,snapToGrid:o}=e.getState(),a=t.touches?t.touches[0].clientX:t.clientX,i=t.touches?t.touches[0].clientY:t.clientY,l={x:(a-n[0])/n[2],y:(i-n[1])/n[2]};return{xSnapped:o?r[0]*Math.round(l.x/r[0]):l.x,ySnapped:o?r[1]*Math.round(l.y/r[1]):l.y,...l}}),[])}();return(0,ht.useEffect)((()=>{if(e?.current){const s=Bn(e.current),w=({x:e,y:t})=>{const{nodeInternals:n,onNodeDrag:r,onSelectionDrag:a,updateNodePositions:i,nodeExtent:s,snapGrid:f,snapToGrid:p,nodeOrigin:h,onError:g}=l.getState();d.current={x:e,y:t};let b=!1,y={x:0,y:0,x2:0,y2:0};if(u.current.length>1&&s){const e=bi(u.current,h);y=Na(e)}if(u.current=u.current.map((r=>{const o={x:e-r.distance.x,y:t-r.distance.y};p&&(o.x=f[0]*Math.round(o.x/f[0]),o.y=f[1]*Math.round(o.y/f[1]));const a=[[s[0][0],s[0][1]],[s[1][0],s[1][1]]];u.current.length>1&&s&&!r.extent&&(a[0][0]=r.positionAbsolute.x-y.x+s[0][0],a[1][0]=r.positionAbsolute.x+(r.width??0)-y.x2+s[1][0],a[0][1]=r.positionAbsolute.y-y.y+s[0][1],a[1][1]=r.positionAbsolute.y+(r.height??0)-y.y2+s[1][1]);const i=Fl(r,o,n,a,h,g);return b=b||r.position.x!==i.position.x||r.position.y!==i.position.y,r.position=i.position,r.positionAbsolute=i.positionAbsolute,r})),!b)return;i(u.current,!0,!0),c(!0);const v=o?r:Hl(a);if(v&&m.current){const[e,t]=Wl({nodeId:o,dragItems:u.current,nodeInternals:n});v(m.current,e,t)}},_=()=>{if(!p.current)return;const[e,t]=Sa(h.current,p.current);if(0!==e||0!==t){const{transform:n,panBy:r}=l.getState();d.current.x=(d.current.x??0)-e/n[2],d.current.y=(d.current.y??0)-t/n[2],r({x:e,y:t})&&w(d.current)}f.current=requestAnimationFrame(_)},E=t=>{const{nodeInternals:n,multiSelectionActive:r,nodesDraggable:s,unselectNodesAndEdges:c,onNodeDragStart:f,onSelectionDragStart:p}=l.getState();b.current=!0;const h=o?f:Hl(p);i&&a||r||!o||n.get(o)?.selected||c(),o&&a&&i&&Vl({id:o,store:l,nodeRef:e});const m=v(t);if(d.current=m,u.current=zl(n,s,m,o),h&&u.current){const[e,r]=Wl({nodeId:o,dragItems:u.current,nodeInternals:n});h(t.sourceEvent,e,r)}};if(!t){const t=function(){var e,t,n,r,o=ia,a=la,i=sa,l=ca,s={},c=Ot("start","drag","end"),u=0,d=0;function f(e){e.on("mousedown.drag",p).filter(l).on("touchstart.drag",g).on("touchmove.drag",b,Vn).on("touchend.drag touchcancel.drag",y).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function p(i,l){if(!r&&o.call(this,i,l)){var s=v(this,a.call(this,i,l),i,l,"mouse");s&&(Bn(i.view).on("mousemove.drag",h,Hn).on("mouseup.drag",m,Hn),Xn(i.view),Un(i),n=!1,e=i.clientX,t=i.clientY,s("start",i))}}function h(r){if(qn(r),!n){var o=r.clientX-e,a=r.clientY-t;n=o*o+a*a>d}s.mouse("drag",r)}function m(e){Bn(e.view).on("mousemove.drag mouseup.drag",null),Yn(e.view,n),qn(e),s.mouse("end",e)}function g(e,t){if(o.call(this,e,t)){var n,r,i=e.changedTouches,l=a.call(this,e,t),s=i.length;for(n=0;n{const{domNode:t,nodeDragThreshold:n}=l.getState();0===n&&E(e),y.current=!1;const r=v(e);d.current=r,p.current=t?.getBoundingClientRect()||null,h.current=$a(e.sourceEvent,p.current)})).on("drag",(e=>{const t=v(e),{autoPanOnNodeDrag:n,nodeDragThreshold:r}=l.getState();if("touchmove"===e.sourceEvent.type&&e.sourceEvent.touches.length>1&&(y.current=!0),!y.current){if(!g.current&&b.current&&n&&(g.current=!0,_()),!b.current){const n=t.xSnapped-(d?.current?.x??0),o=t.ySnapped-(d?.current?.y??0);Math.sqrt(n*n+o*o)>r&&E(e)}(d.current.x!==t.xSnapped||d.current.y!==t.ySnapped)&&u.current&&b.current&&(m.current=e.sourceEvent,h.current=$a(e.sourceEvent,p.current),w(t))}})).on("end",(e=>{if(b.current&&!y.current&&(c(!1),g.current=!1,b.current=!1,cancelAnimationFrame(f.current),u.current)){const{updateNodePositions:t,nodeInternals:n,onNodeDragStop:r,onSelectionDragStop:a}=l.getState(),i=o?r:Hl(a);if(t(u.current,!1,!1),i){const[t,r]=Wl({nodeId:o,dragItems:u.current,nodeInternals:n});i(e.sourceEvent,t,r)}}})).filter((t=>{const o=t.target;return!t.button&&(!n||!Ll(o,`.${n}`,e))&&(!r||Ll(o,r,e))}));return s.call(t),()=>{s.on(".drag",null)}}s.on(".drag",null)}}),[e,t,n,r,a,l,o,i,v]),s}function ql(){const e=ma(),t=(0,ht.useCallback)((t=>{const{nodeInternals:n,nodeExtent:r,updateNodePositions:o,getNodes:a,snapToGrid:i,snapGrid:l,onError:s,nodesDraggable:c}=e.getState(),u=a().filter((e=>e.selected&&(e.draggable||c&&void 0===e.draggable))),d=i?l[0]:5,f=i?l[1]:5,p=t.isShiftPressed?4:1,h=t.x*d*p,m=t.y*f*p;o(u.map((e=>{if(e.positionAbsolute){const t={x:e.positionAbsolute.x+h,y:e.positionAbsolute.y+m};i&&(t.x=l[0]*Math.round(t.x/l[0]),t.y=l[1]*Math.round(t.y/l[1]));const{positionAbsolute:o,position:a}=Fl(e,t,n,r,void 0,s);e.position=a,e.positionAbsolute=o}return e})),!0,!1)}),[]);return t}const Xl={ArrowUp:{x:0,y:-1},ArrowDown:{x:0,y:1},ArrowLeft:{x:-1,y:0},ArrowRight:{x:1,y:0}};var Yl=e=>{const t=({id:t,type:n,data:r,xPos:o,yPos:a,xPosOrigin:i,yPosOrigin:l,selected:s,onClick:c,onMouseEnter:u,onMouseMove:d,onMouseLeave:f,onContextMenu:p,onDoubleClick:h,style:m,className:g,isDraggable:b,isSelectable:y,isConnectable:v,isFocusable:w,selectNodesOnDrag:_,sourcePosition:E,targetPosition:x,hidden:S,resizeObserver:k,dragHandle:R,zIndex:N,isParent:C,noDragClassName:O,noPanClassName:A,initialized:P,disableKeyboardA11y:D,ariaLabel:T,rfId:I,hasHandleBounds:j})=>{const M=ma(),$=(0,ht.useRef)(null),L=(0,ht.useRef)(null),z=(0,ht.useRef)(E),F=(0,ht.useRef)(x),W=(0,ht.useRef)(n),G=y||b||c||u||d||f,B=ql(),V=Bl(t,M.getState,u),H=Bl(t,M.getState,d),U=Bl(t,M.getState,f),q=Bl(t,M.getState,p),X=Bl(t,M.getState,h);(0,ht.useEffect)((()=>()=>{L.current&&(k?.unobserve(L.current),L.current=null)}),[]),(0,ht.useEffect)((()=>{if($.current&&!S){const e=$.current;P&&j&&L.current===e||(L.current&&k?.unobserve(L.current),k?.observe(e),L.current=e)}}),[S,P,j]),(0,ht.useEffect)((()=>{const e=W.current!==n,r=z.current!==E,o=F.current!==x;$.current&&(e||r||o)&&(e&&(W.current=n),r&&(z.current=E),o&&(F.current=x),M.getState().updateNodeDimensions([{id:t,nodeElement:$.current,forceUpdate:!0}]))}),[t,n,E,x]);const Y=Ul({nodeRef:$,disabled:S||!b,noDragClassName:O,handleSelector:R,nodeId:t,isSelectable:y,selectNodesOnDrag:_});return S?null:ht.createElement("div",{className:mt(["react-flow__node",`react-flow__node-${n}`,{[A]:b},g,{selected:s,selectable:y,parent:C,dragging:Y}]),ref:$,style:{zIndex:N,transform:`translate(${i}px,${l}px)`,pointerEvents:G?"all":"none",visibility:P?"visible":"hidden",...m},"data-id":t,"data-testid":`rf__node-${t}`,onMouseEnter:V,onMouseMove:H,onMouseLeave:U,onContextMenu:q,onClick:e=>{const{nodeDragThreshold:n}=M.getState();if(y&&(!_||!b||n>0)&&Vl({id:t,store:M,nodeRef:$}),c){const n=M.getState().nodeInternals.get(t);n&&c(e,{...n})}},onDoubleClick:X,onKeyDown:w?e=>{if(!ja(e)&&!D)if(Ta.includes(e.key)&&y){const n="Escape"===e.key;Vl({id:t,store:M,unselect:n,nodeRef:$})}else b&&s&&Object.prototype.hasOwnProperty.call(Xl,e.key)&&(M.setState({ariaLiveMessage:`Moved selected node ${e.key.replace("Arrow","").toLowerCase()}. New position, x: ${~~o}, y: ${~~a}`}),B({x:Xl[e.key].x,y:Xl[e.key].y,isShiftPressed:e.shiftKey}))}:void 0,tabIndex:w?0:void 0,role:w?"button":void 0,"aria-describedby":D?void 0:`${Ji}-${I}`,"aria-label":T},ht.createElement(ci,{value:t},ht.createElement(e,{id:t,data:r,type:n,xPos:o,yPos:a,selected:s,isConnectable:v,sourcePosition:E,targetPosition:x,dragging:Y,dragHandle:R,zIndex:N})))};return t.displayName="NodeWrapper",(0,ht.memo)(t)};const Kl=e=>{const t=e.getNodes().filter((e=>e.selected));return{...bi(t,e.nodeOrigin),transformString:`translate(${e.transform[0]}px,${e.transform[1]}px) scale(${e.transform[2]})`,userSelectionActive:e.userSelectionActive}};var Ql=(0,ht.memo)((function({onSelectionContextMenu:e,noPanClassName:t,disableKeyboardA11y:n}){const r=ma(),{width:o,height:a,x:i,y:l,transformString:s,userSelectionActive:c}=ha(Kl,xt),u=ql(),d=(0,ht.useRef)(null);if((0,ht.useEffect)((()=>{n||d.current?.focus({preventScroll:!0})}),[n]),Ul({nodeRef:d}),c||!o||!a)return null;const f=e?t=>{const n=r.getState().getNodes().filter((e=>e.selected));e(t,n)}:void 0;return ht.createElement("div",{className:mt(["react-flow__nodesselection","react-flow__container",t]),style:{transform:s}},ht.createElement("div",{ref:d,className:"react-flow__nodesselection-rect",onContextMenu:f,tabIndex:n?void 0:-1,onKeyDown:n?void 0:e=>{Object.prototype.hasOwnProperty.call(Xl,e.key)&&u({x:Xl[e.key].x,y:Xl[e.key].y,isShiftPressed:e.shiftKey})},style:{width:o,height:a,top:l,left:i}}))}));const Zl=e=>e.nodesSelectionActive,Jl=({children:e,onPaneClick:t,onPaneMouseEnter:n,onPaneMouseMove:r,onPaneMouseLeave:o,onPaneContextMenu:a,onPaneScroll:i,deleteKeyCode:l,onMove:s,onMoveStart:c,onMoveEnd:u,selectionKeyCode:d,selectionOnDrag:f,selectionMode:p,onSelectionStart:h,onSelectionEnd:m,multiSelectionKeyCode:g,panActivationKeyCode:b,zoomActivationKeyCode:y,elementsSelectable:v,zoomOnScroll:w,zoomOnPinch:_,panOnScroll:E,panOnScrollSpeed:x,panOnScrollMode:S,zoomOnDoubleClick:k,panOnDrag:R,defaultViewport:N,translateExtent:C,minZoom:O,maxZoom:A,preventScrolling:P,onSelectionContextMenu:D,noWheelClassName:T,noPanClassName:I,disableKeyboardA11y:j})=>{const M=ha(Zl),$=ol(d),L=ol(b),z=L||R,F=L||E,W=$||f&&!0!==z;return(({deleteKeyCode:e,multiSelectionKeyCode:t})=>{const n=ma(),{deleteElements:r}=bl(),o=ol(e,yl),a=ol(t);(0,ht.useEffect)((()=>{if(o){const{edges:e,getNodes:t}=n.getState(),o=t().filter((e=>e.selected)),a=e.filter((e=>e.selected));r({nodes:o,edges:a}),n.setState({nodesSelectionActive:!1})}}),[o]),(0,ht.useEffect)((()=>{n.setState({multiSelectionActive:a})}),[a])})({deleteKeyCode:l,multiSelectionKeyCode:g}),ht.createElement(kl,{onMove:s,onMoveStart:c,onMoveEnd:u,onPaneContextMenu:a,elementsSelectable:v,zoomOnScroll:w,zoomOnPinch:_,panOnScroll:F,panOnScrollSpeed:x,panOnScrollMode:S,zoomOnDoubleClick:k,panOnDrag:!$&&z,defaultViewport:N,translateExtent:C,minZoom:O,maxZoom:A,zoomActivationKeyCode:y,preventScrolling:P,noWheelClassName:T,noPanClassName:I},ht.createElement(Ml,{onSelectionStart:h,onSelectionEnd:m,onPaneClick:t,onPaneMouseEnter:n,onPaneMouseMove:r,onPaneMouseLeave:o,onPaneContextMenu:a,onPaneScroll:i,panOnDrag:z,isSelecting:!!W,selectionMode:p},e,M&&ht.createElement(Ql,{onSelectionContextMenu:D,noPanClassName:I,disableKeyboardA11y:j})))};Jl.displayName="FlowRenderer";var es=(0,ht.memo)(Jl);function ts(e){return{input:Yl(e.input||$i),default:Yl(e.default||ji),output:Yl(e.output||zi),group:Yl(e.group||Fi),...Object.keys(e).filter((e=>!["input","default","output","group"].includes(e))).reduce(((t,n)=>(t[n]=Yl(e[n]||ji),t)),{})}}const ns=e=>({nodesDraggable:e.nodesDraggable,nodesConnectable:e.nodesConnectable,nodesFocusable:e.nodesFocusable,elementsSelectable:e.elementsSelectable,updateNodeDimensions:e.updateNodeDimensions,onError:e.onError}),rs=e=>{const{nodesDraggable:t,nodesConnectable:n,nodesFocusable:r,elementsSelectable:o,updateNodeDimensions:a,onError:i}=ha(ns,xt),l=(s=e.onlyRenderVisibleElements,ha((0,ht.useCallback)((e=>s?yi(e.nodeInternals,{x:0,y:0,width:e.width,height:e.height},e.transform,!0):e.getNodes()),[s])));var s;const c=(0,ht.useRef)(),u=(0,ht.useMemo)((()=>{if("undefined"==typeof ResizeObserver)return null;const e=new ResizeObserver((e=>{const t=e.map((e=>({id:e.target.getAttribute("data-id"),nodeElement:e.target,forceUpdate:!0})));a(t)}));return c.current=e,e}),[]);return(0,ht.useEffect)((()=>()=>{c?.current?.disconnect()}),[]),ht.createElement("div",{className:"react-flow__nodes",style:vl},l.map((a=>{let l=a.type||"default";e.nodeTypes[l]||(i?.("003",(e=>`Node type "${e}" not found. Using fallback type "default".`)(l)),l="default");const s=e.nodeTypes[l]||e.nodeTypes.default,c=!!(a.draggable||t&&void 0===a.draggable),d=!!(a.selectable||o&&void 0===a.selectable),f=!!(a.connectable||n&&void 0===a.connectable),p=!!(a.focusable||r&&void 0===a.focusable),h=e.nodeExtent?Ea(a.positionAbsolute,e.nodeExtent):a.positionAbsolute,m=h?.x??0,g=h?.y??0,b=(({x:e,y:t,width:n,height:r,origin:o})=>n&&r?o[0]<0||o[1]<0||o[0]>1||o[1]>1?{x:e,y:t}:{x:e-n*o[0],y:t-r*o[1]}:{x:e,y:t})({x:m,y:g,width:a.width??0,height:a.height??0,origin:e.nodeOrigin});return ht.createElement(s,{key:a.id,id:a.id,className:a.className,style:a.style,type:l,data:a.data,sourcePosition:a.sourcePosition||Xa.Bottom,targetPosition:a.targetPosition||Xa.Top,hidden:a.hidden,xPos:m,yPos:g,xPosOrigin:b.x,yPosOrigin:b.y,selectNodesOnDrag:e.selectNodesOnDrag,onClick:e.onNodeClick,onMouseEnter:e.onNodeMouseEnter,onMouseMove:e.onNodeMouseMove,onMouseLeave:e.onNodeMouseLeave,onContextMenu:e.onNodeContextMenu,onDoubleClick:e.onNodeDoubleClick,selected:!!a.selected,isDraggable:c,isSelectable:d,isConnectable:f,isFocusable:p,resizeObserver:u,dragHandle:a.dragHandle,zIndex:a[Da]?.z??0,isParent:!!a[Da]?.isParent,noDragClassName:e.noDragClassName,noPanClassName:e.noPanClassName,initialized:!!a.width&&!!a.height,rfId:e.rfId,disableKeyboardA11y:e.disableKeyboardA11y,ariaLabel:a.ariaLabel,hasHandleBounds:!!a[Da]?.handleBounds})})))};rs.displayName="NodeRenderer";var os=(0,ht.memo)(rs);const as=(e,t,n)=>n===Xa.Left?e-t:n===Xa.Right?e+t:e,is=(e,t,n)=>n===Xa.Top?e-t:n===Xa.Bottom?e+t:e,ls="react-flow__edgeupdater",ss=({position:e,centerX:t,centerY:n,radius:r=10,onMouseDown:o,onMouseEnter:a,onMouseOut:i,type:l})=>ht.createElement("circle",{onMouseDown:o,onMouseEnter:a,onMouseOut:i,className:mt([ls,`${ls}-${l}`]),cx:as(t,r,e),cy:is(n,r,e),r,stroke:"transparent",fill:"transparent"}),cs=()=>!0;var us=e=>{const t=({id:t,className:n,type:r,data:o,onClick:a,onEdgeDoubleClick:i,selected:l,animated:s,label:c,labelStyle:u,labelShowBg:d,labelBgStyle:f,labelBgPadding:p,labelBgBorderRadius:h,style:m,source:g,target:b,sourceX:y,sourceY:v,targetX:w,targetY:_,sourcePosition:E,targetPosition:x,elementsSelectable:S,hidden:k,sourceHandleId:R,targetHandleId:N,onContextMenu:C,onMouseEnter:O,onMouseMove:A,onMouseLeave:P,reconnectRadius:D,onReconnect:T,onReconnectStart:I,onReconnectEnd:j,markerEnd:M,markerStart:$,rfId:L,ariaLabel:z,isFocusable:F,isReconnectable:W,pathOptions:G,interactionWidth:B,disableKeyboardA11y:V})=>{const H=(0,ht.useRef)(null),[U,q]=(0,ht.useState)(!1),[X,Y]=(0,ht.useState)(!1),K=ma(),Q=(0,ht.useMemo)((()=>`url('#${fi($,L)}')`),[$,L]),Z=(0,ht.useMemo)((()=>`url('#${fi(M,L)}')`),[M,L]);if(k)return null;const J=Fa(t,K.getState,i),ee=Fa(t,K.getState,C),te=Fa(t,K.getState,O),ne=Fa(t,K.getState,A),re=Fa(t,K.getState,P),oe=(e,n)=>{if(0!==e.button)return;const{edges:r,isValidConnection:o}=K.getState(),a=n?b:g,i=(n?N:R)||null,l=n?"target":"source",s=o||cs,c=n,u=r.find((e=>e.id===t));Y(!0),I?.(e,u,l),Oi({event:e,handleId:i,nodeId:a,onConnect:e=>T?.(u,e),isTarget:c,getState:K.getState,setState:K.setState,isValidConnection:s,edgeUpdaterType:l,onReconnectEnd:e=>{Y(!1),j?.(e,u,l)}})},ae=()=>q(!0),ie=()=>q(!1),le=!S&&!a;return ht.createElement("g",{className:mt(["react-flow__edge",`react-flow__edge-${r}`,n,{selected:l,animated:s,inactive:le,updating:U}]),onClick:e=>{const{edges:n,addSelectedEdges:r,unselectNodesAndEdges:o,multiSelectionActive:i}=K.getState(),l=n.find((e=>e.id===t));l&&(S&&(K.setState({nodesSelectionActive:!1}),l.selected&&i?(o({nodes:[],edges:[l]}),H.current?.blur()):r([t])),a&&a(e,l))},onDoubleClick:J,onContextMenu:ee,onMouseEnter:te,onMouseMove:ne,onMouseLeave:re,onKeyDown:F?e=>{if(!V&&Ta.includes(e.key)&&S){const{unselectNodesAndEdges:n,addSelectedEdges:r,edges:o}=K.getState();"Escape"===e.key?(H.current?.blur(),n({edges:[o.find((e=>e.id===t))]})):r([t])}}:void 0,tabIndex:F?0:void 0,role:F?"button":"img","data-testid":`rf__edge-${t}`,"aria-label":null===z?void 0:z||`Edge from ${g} to ${b}`,"aria-describedby":F?`${el}-${L}`:void 0,ref:H},!X&&ht.createElement(e,{id:t,source:g,target:b,selected:l,animated:s,label:c,labelStyle:u,labelShowBg:d,labelBgStyle:f,labelBgPadding:p,labelBgBorderRadius:h,data:o,style:m,sourceX:y,sourceY:v,targetX:w,targetY:_,sourcePosition:E,targetPosition:x,sourceHandleId:R,targetHandleId:N,markerStart:Q,markerEnd:Z,pathOptions:G,interactionWidth:B}),W&&ht.createElement(ht.Fragment,null,("source"===W||!0===W)&&ht.createElement(ss,{position:E,centerX:y,centerY:v,radius:D,onMouseDown:e=>oe(e,!0),onMouseEnter:ae,onMouseOut:ie,type:"source"}),("target"===W||!0===W)&&ht.createElement(ss,{position:x,centerX:w,centerY:_,radius:D,onMouseDown:e=>oe(e,!1),onMouseEnter:ae,onMouseOut:ie,type:"target"})))};return t.displayName="EdgeWrapper",(0,ht.memo)(t)};function ds(e){return{default:us(e.default||li),straight:us(e.bezier||ri),step:us(e.step||ni),smoothstep:us(e.step||ti),simplebezier:us(e.simplebezier||Qa),...Object.keys(e).filter((e=>!["default","bezier"].includes(e))).reduce(((t,n)=>(t[n]=us(e[n]||li),t)),{})}}function fs(e,t,n=null){const r=(n?.x||0)+t.x,o=(n?.y||0)+t.y,a=n?.width||t.width,i=n?.height||t.height;switch(e){case Xa.Top:return{x:r+a/2,y:o};case Xa.Right:return{x:r+a,y:o+i/2};case Xa.Bottom:return{x:r+a/2,y:o+i};case Xa.Left:return{x:r,y:o+i/2}}}function ps(e,t){return e?1!==e.length&&t?t&&e.find((e=>e.id===t))||null:e[0]:null}function hs(e){const t=e?.[Da]?.handleBounds||null,n=t&&e?.width&&e?.height&&void 0!==e?.positionAbsolute?.x&&void 0!==e?.positionAbsolute?.y;return[{x:e?.positionAbsolute?.x||0,y:e?.positionAbsolute?.y||0,width:e?.width||0,height:e?.height||0},t,!!n]}const ms=[{level:0,isMaxLevel:!0,edges:[]}];const gs={[qa.Arrow]:({color:e="none",strokeWidth:t=1})=>ht.createElement("polyline",{style:{stroke:e,strokeWidth:t},strokeLinecap:"round",strokeLinejoin:"round",fill:"none",points:"-5,-4 0,0 -5,4"}),[qa.ArrowClosed]:({color:e="none",strokeWidth:t=1})=>ht.createElement("polyline",{style:{stroke:e,fill:e,strokeWidth:t},strokeLinecap:"round",strokeLinejoin:"round",points:"-5,-4 0,0 -5,4 -5,-4"})},bs=({id:e,type:t,color:n,width:r=12.5,height:o=12.5,markerUnits:a="strokeWidth",strokeWidth:i,orient:l="auto-start-reverse"})=>{const s=function(e){const t=ma();return(0,ht.useMemo)((()=>Object.prototype.hasOwnProperty.call(gs,e)?gs[e]:(t.getState().onError?.("009",(e=>`Marker type "${e}" doesn't exist.`)(e)),null)),[e])}(t);return s?ht.createElement("marker",{className:"react-flow__arrowhead",id:e,markerWidth:`${r}`,markerHeight:`${o}`,viewBox:"-10 -10 20 20",markerUnits:a,orient:l,refX:"0",refY:"0"},ht.createElement(s,{color:n,strokeWidth:i})):null},ys=({defaultColor:e,rfId:t})=>{const n=ha((0,ht.useCallback)((({defaultColor:e,rfId:t})=>n=>{const r=[];return n.edges.reduce(((n,o)=>([o.markerStart,o.markerEnd].forEach((o=>{if(o&&"object"==typeof o){const a=fi(o,t);r.includes(a)||(n.push({id:a,color:o.color||e,...o}),r.push(a))}})),n)),[]).sort(((e,t)=>e.id.localeCompare(t.id)))})({defaultColor:e,rfId:t}),[e,t]),((e,t)=>!(e.length!==t.length||e.some(((e,n)=>e.id!==t[n].id)))));return ht.createElement("defs",null,n.map((e=>ht.createElement(bs,{id:e.id,key:e.id,type:e.type,color:e.color,width:e.width,height:e.height,markerUnits:e.markerUnits,strokeWidth:e.strokeWidth,orient:e.orient}))))};ys.displayName="MarkerDefinitions";var vs=(0,ht.memo)(ys);const ws=e=>({nodesConnectable:e.nodesConnectable,edgesFocusable:e.edgesFocusable,edgesUpdatable:e.edgesUpdatable,elementsSelectable:e.elementsSelectable,width:e.width,height:e.height,connectionMode:e.connectionMode,nodeInternals:e.nodeInternals,onError:e.onError}),_s=({defaultMarkerColor:e,onlyRenderVisibleElements:t,elevateEdgesOnSelect:n,rfId:r,edgeTypes:o,noPanClassName:a,onEdgeContextMenu:i,onEdgeMouseEnter:l,onEdgeMouseMove:s,onEdgeMouseLeave:c,onEdgeClick:u,onEdgeDoubleClick:d,onReconnect:f,onReconnectStart:p,onReconnectEnd:h,reconnectRadius:m,children:g,disableKeyboardA11y:b})=>{const{edgesFocusable:y,edgesUpdatable:v,elementsSelectable:w,width:_,height:E,connectionMode:x,nodeInternals:S,onError:k}=ha(ws,xt),R=function(e,t,n){return function(e,t,n=!1){let r=-1;const o=e.reduce(((e,o)=>{const a=Pa(o.zIndex);let i=a?o.zIndex:0;if(n){const e=t.get(o.target),n=t.get(o.source),r=o.selected||e?.selected||n?.selected,l=Math.max(n?.[Da]?.z||0,e?.[Da]?.z||0,1e3);i=(a?o.zIndex:0)+(r?l:0)}return e[i]?e[i].push(o):e[i]=[o],r=i>r?i:r,e}),{}),a=Object.entries(o).map((([e,t])=>{const n=+e;return{edges:t,level:n,isMaxLevel:n===r}}));return 0===a.length?ms:a}(ha((0,ht.useCallback)((n=>e?n.edges.filter((e=>{const r=t.get(e.source),o=t.get(e.target);return r?.width&&r?.height&&o?.width&&o?.height&&function({sourcePos:e,targetPos:t,sourceWidth:n,sourceHeight:r,targetWidth:o,targetHeight:a,width:i,height:l,transform:s}){const c={x:Math.min(e.x,t.x),y:Math.min(e.y,t.y),x2:Math.max(e.x+n,t.x+o),y2:Math.max(e.y+r,t.y+a)};c.x===c.x2&&(c.x2+=1),c.y===c.y2&&(c.y2+=1);const u=Na({x:(0-s[0])/s[2],y:(0-s[1])/s[2],width:i/s[2],height:l/s[2]}),d=Math.max(0,Math.min(u.x2,c.x2)-Math.max(u.x,c.x)),f=Math.max(0,Math.min(u.y2,c.y2)-Math.max(u.y,c.y));return Math.ceil(d*f)>0}({sourcePos:r.positionAbsolute||{x:0,y:0},targetPos:o.positionAbsolute||{x:0,y:0},sourceWidth:r.width,sourceHeight:r.height,targetWidth:o.width,targetHeight:o.height,width:n.width,height:n.height,transform:n.transform})})):n.edges),[e,t])),t,n)}(t,S,n);return _?ht.createElement(ht.Fragment,null,R.map((({level:t,edges:n,isMaxLevel:g})=>ht.createElement("svg",{key:t,style:{zIndex:t},width:_,height:E,className:"react-flow__edges react-flow__container"},g&&ht.createElement(vs,{defaultColor:e,rfId:r}),ht.createElement("g",null,n.map((e=>{const[t,n,g]=hs(S.get(e.source)),[_,E,R]=hs(S.get(e.target));if(!g||!R)return null;let N=e.type||"default";o[N]||(k?.("011",(e=>`Edge type "${e}" not found. Using fallback type "default".`)(N)),N="default");const C=o[N]||o.default,O=x===Ba.Strict?E.target:(E.target??[]).concat(E.source??[]),A=ps(n.source,e.sourceHandle),P=ps(O,e.targetHandle),D=A?.position||Xa.Bottom,T=P?.position||Xa.Top,I=!!(e.focusable||y&&void 0===e.focusable),j=e.reconnectable||e.updatable,M=void 0!==f&&(j||v&&void 0===j);if(!A||!P)return k?.("008",((e,t)=>`Couldn't create edge for ${e?"target":"source"} handle id: "${e?t.targetHandle:t.sourceHandle}", edge id: ${t.id}.`)(A,e)),null;const{sourceX:$,sourceY:L,targetX:z,targetY:F}=((e,t,n,r,o,a)=>{const i=fs(n,e,t),l=fs(a,r,o);return{sourceX:i.x,sourceY:i.y,targetX:l.x,targetY:l.y}})(t,A,D,_,P,T);return ht.createElement(C,{key:e.id,id:e.id,className:mt([e.className,a]),type:N,data:e.data,selected:!!e.selected,animated:!!e.animated,hidden:!!e.hidden,label:e.label,labelStyle:e.labelStyle,labelShowBg:e.labelShowBg,labelBgStyle:e.labelBgStyle,labelBgPadding:e.labelBgPadding,labelBgBorderRadius:e.labelBgBorderRadius,style:e.style,source:e.source,target:e.target,sourceHandleId:e.sourceHandle,targetHandleId:e.targetHandle,markerEnd:e.markerEnd,markerStart:e.markerStart,sourceX:$,sourceY:L,targetX:z,targetY:F,sourcePosition:D,targetPosition:T,elementsSelectable:w,onContextMenu:i,onMouseEnter:l,onMouseMove:s,onMouseLeave:c,onClick:u,onEdgeDoubleClick:d,onReconnect:f,onReconnectStart:p,onReconnectEnd:h,reconnectRadius:m,rfId:r,ariaLabel:e.ariaLabel,isFocusable:I,isReconnectable:M,pathOptions:"pathOptions"in e?e.pathOptions:void 0,interactionWidth:e.interactionWidth,disableKeyboardA11y:b})})))))),g):null};_s.displayName="EdgeRenderer";var Es=(0,ht.memo)(_s);const xs=e=>`translate(${e.transform[0]}px,${e.transform[1]}px) scale(${e.transform[2]})`;function Ss({children:e}){const t=ha(xs);return ht.createElement("div",{className:"react-flow__viewport react-flow__container",style:{transform:t}},e)}const ks={[Xa.Left]:Xa.Right,[Xa.Right]:Xa.Left,[Xa.Top]:Xa.Bottom,[Xa.Bottom]:Xa.Top},Rs=({nodeId:e,handleType:t,style:n,type:r=Ua.Bezier,CustomComponent:o,connectionStatus:a})=>{const{fromNode:i,handleId:l,toX:s,toY:c,connectionMode:u}=ha((0,ht.useCallback)((t=>({fromNode:t.nodeInternals.get(e),handleId:t.connectionHandleId,toX:(t.connectionPosition.x-t.transform[0])/t.transform[2],toY:(t.connectionPosition.y-t.transform[1])/t.transform[2],connectionMode:t.connectionMode})),[e]),xt),d=i?.[Da]?.handleBounds;let f=d?.[t];if(u===Ba.Loose&&(f=f||d?.["source"===t?"target":"source"]),!i||!f)return null;const p=l?f.find((e=>e.id===l)):f[0],h=p?p.x+p.width/2:(i.width??0)/2,m=p?p.y+p.height/2:i.height??0,g=(i.positionAbsolute?.x??0)+h,b=(i.positionAbsolute?.y??0)+m,y=p?.position,v=y?ks[y]:null;if(!y||!v)return null;if(o)return ht.createElement(o,{connectionLineType:r,connectionLineStyle:n,fromNode:i,fromHandle:p,fromX:g,fromY:b,toX:s,toY:c,fromPosition:y,toPosition:v,connectionStatus:a});let w="";const _={sourceX:g,sourceY:b,sourcePosition:y,targetX:s,targetY:c,targetPosition:v};return r===Ua.Bezier?[w]=ii(_):r===Ua.Step?[w]=ei({..._,borderRadius:0}):r===Ua.SmoothStep?[w]=ei(_):r===Ua.SimpleBezier?[w]=Ka(_):w=`M${g},${b} ${s},${c}`,ht.createElement("path",{d:w,fill:"none",className:"react-flow__connection-path",style:n})};Rs.displayName="ConnectionLine";const Ns=e=>({nodeId:e.connectionNodeId,handleType:e.connectionHandleType,nodesConnectable:e.nodesConnectable,connectionStatus:e.connectionStatus,width:e.width,height:e.height});function Cs({containerStyle:e,style:t,type:n,component:r}){const{nodeId:o,handleType:a,nodesConnectable:i,width:l,height:s,connectionStatus:c}=ha(Ns,xt);return o&&a&&l&&i?ht.createElement("svg",{style:e,width:l,height:s,className:"react-flow__edges react-flow__connectionline react-flow__container"},ht.createElement("g",{className:mt(["react-flow__connection",c])},ht.createElement(Rs,{nodeId:o,handleType:a,style:t,type:n,CustomComponent:r,connectionStatus:c}))):null}function Os(e,t){return(0,ht.useRef)(null),ma(),(0,ht.useMemo)((()=>t(e)),[e])}const As=({nodeTypes:e,edgeTypes:t,onMove:n,onMoveStart:r,onMoveEnd:o,onInit:a,onNodeClick:i,onEdgeClick:l,onNodeDoubleClick:s,onEdgeDoubleClick:c,onNodeMouseEnter:u,onNodeMouseMove:d,onNodeMouseLeave:f,onNodeContextMenu:p,onSelectionContextMenu:h,onSelectionStart:m,onSelectionEnd:g,connectionLineType:b,connectionLineStyle:y,connectionLineComponent:v,connectionLineContainerStyle:w,selectionKeyCode:_,selectionOnDrag:E,selectionMode:x,multiSelectionKeyCode:S,panActivationKeyCode:k,zoomActivationKeyCode:R,deleteKeyCode:N,onlyRenderVisibleElements:C,elementsSelectable:O,selectNodesOnDrag:A,defaultViewport:P,translateExtent:D,minZoom:T,maxZoom:I,preventScrolling:j,defaultMarkerColor:M,zoomOnScroll:$,zoomOnPinch:L,panOnScroll:z,panOnScrollSpeed:F,panOnScrollMode:W,zoomOnDoubleClick:G,panOnDrag:B,onPaneClick:V,onPaneMouseEnter:H,onPaneMouseMove:U,onPaneMouseLeave:q,onPaneScroll:X,onPaneContextMenu:Y,onEdgeContextMenu:K,onEdgeMouseEnter:Q,onEdgeMouseMove:Z,onEdgeMouseLeave:J,onReconnect:ee,onReconnectStart:te,onReconnectEnd:ne,reconnectRadius:re,noDragClassName:oe,noWheelClassName:ae,noPanClassName:ie,elevateEdgesOnSelect:le,disableKeyboardA11y:se,nodeOrigin:ce,nodeExtent:ue,rfId:de})=>{const fe=Os(e,ts),pe=Os(t,ds);return function(e){const t=bl(),n=(0,ht.useRef)(!1);(0,ht.useEffect)((()=>{!n.current&&t.viewportInitialized&&e&&(setTimeout((()=>e(t)),1),n.current=!0)}),[e,t.viewportInitialized])}(a),ht.createElement(es,{onPaneClick:V,onPaneMouseEnter:H,onPaneMouseMove:U,onPaneMouseLeave:q,onPaneContextMenu:Y,onPaneScroll:X,deleteKeyCode:N,selectionKeyCode:_,selectionOnDrag:E,selectionMode:x,onSelectionStart:m,onSelectionEnd:g,multiSelectionKeyCode:S,panActivationKeyCode:k,zoomActivationKeyCode:R,elementsSelectable:O,onMove:n,onMoveStart:r,onMoveEnd:o,zoomOnScroll:$,zoomOnPinch:L,zoomOnDoubleClick:G,panOnScroll:z,panOnScrollSpeed:F,panOnScrollMode:W,panOnDrag:B,defaultViewport:P,translateExtent:D,minZoom:T,maxZoom:I,onSelectionContextMenu:h,preventScrolling:j,noDragClassName:oe,noWheelClassName:ae,noPanClassName:ie,disableKeyboardA11y:se},ht.createElement(Ss,null,ht.createElement(Es,{edgeTypes:pe,onEdgeClick:l,onEdgeDoubleClick:c,onlyRenderVisibleElements:C,onEdgeContextMenu:K,onEdgeMouseEnter:Q,onEdgeMouseMove:Z,onEdgeMouseLeave:J,onReconnect:ee,onReconnectStart:te,onReconnectEnd:ne,reconnectRadius:re,defaultMarkerColor:M,noPanClassName:ie,elevateEdgesOnSelect:!!le,disableKeyboardA11y:se,rfId:de},ht.createElement(Cs,{style:y,type:b,component:v,containerStyle:w})),ht.createElement("div",{className:"react-flow__edgelabel-renderer"}),ht.createElement(os,{nodeTypes:fe,onNodeClick:i,onNodeDoubleClick:s,onNodeMouseEnter:u,onNodeMouseMove:d,onNodeMouseLeave:f,onNodeContextMenu:p,selectNodesOnDrag:A,onlyRenderVisibleElements:C,noPanClassName:ie,noDragClassName:oe,disableKeyboardA11y:se,nodeOrigin:ce,nodeExtent:ue,rfId:de})))};As.displayName="GraphView";var Ps=(0,ht.memo)(As);const Ds=[[Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY],[Number.POSITIVE_INFINITY,Number.POSITIVE_INFINITY]],Ts={rfId:"1",width:0,height:0,transform:[0,0,1],nodeInternals:new Map,edges:[],onNodesChange:null,onEdgesChange:null,hasDefaultNodes:!1,hasDefaultEdges:!1,d3Zoom:null,d3Selection:null,d3ZoomHandler:void 0,minZoom:.5,maxZoom:2,translateExtent:Ds,nodeExtent:Ds,nodesSelectionActive:!1,userSelectionActive:!1,userSelectionRect:null,connectionNodeId:null,connectionHandleId:null,connectionHandleType:"source",connectionPosition:{x:0,y:0},connectionStatus:null,connectionMode:Ba.Strict,domNode:null,paneDragging:!1,noPanClassName:"nopan",nodeOrigin:[0,0],nodeDragThreshold:0,snapGrid:[15,15],snapToGrid:!1,nodesDraggable:!0,nodesConnectable:!0,nodesFocusable:!0,edgesFocusable:!0,edgesUpdatable:!0,elementsSelectable:!0,elevateNodesOnSelect:!0,fitViewOnInit:!1,fitViewOnInitDone:!1,fitViewOnInitOptions:void 0,onSelectionChange:[],multiSelectionActive:!1,connectionStartHandle:null,connectionEndHandle:null,connectionClickStartHandle:null,connectOnClick:!0,ariaLiveMessage:"",autoPanOnConnect:!0,autoPanOnNodeDrag:!0,connectionRadius:20,onError:Ia,isValidConnection:void 0},Is=({children:e})=>{const t=(0,ht.useRef)(null);return t.current||(t.current=(n=(e,t)=>({...Ts,setNodes:n=>{const{nodeInternals:r,nodeOrigin:o,elevateNodesOnSelect:a}=t();e({nodeInternals:cl(n,r,o,a)})},getNodes:()=>Array.from(t().nodeInternals.values()),setEdges:n=>{const{defaultEdgeOptions:r={}}=t();e({edges:n.map((e=>({...r,...e})))})},setDefaultNodesAndEdges:(n,r)=>{const o=void 0!==n,a=void 0!==r,i=o?cl(n,new Map,t().nodeOrigin,t().elevateNodesOnSelect):new Map;e({nodeInternals:i,edges:a?r:[],hasDefaultNodes:o,hasDefaultEdges:a})},updateNodeDimensions:n=>{const{onNodesChange:r,nodeInternals:o,fitViewOnInit:a,fitViewOnInitDone:i,fitViewOnInitOptions:l,domNode:s,nodeOrigin:c}=t(),u=s?.querySelector(".react-flow__viewport");if(!u)return;const d=window.getComputedStyle(u),{m22:f}=new window.DOMMatrixReadOnly(d.transform),p=n.reduce(((e,t)=>{const n=o.get(t.id);if(n?.hidden)o.set(n.id,{...n,[Da]:{...n[Da],handleBounds:void 0}});else if(n){const r=wa(t.nodeElement);r.width&&r.height&&(n.width!==r.width||n.height!==r.height||t.forceUpdate)&&(o.set(n.id,{...n,[Da]:{...n[Da],handleBounds:{source:Gl(".source",t.nodeElement,f,c),target:Gl(".target",t.nodeElement,f,c)}},...r}),e.push({id:n.id,type:"dimensions",dimensions:r}))}return e}),[]);sl(o,c);const h=i||a&&!i&&ul(t,{initial:!0,...l});e({nodeInternals:new Map(o),fitViewOnInitDone:h}),p?.length>0&&r?.(p)},updateNodePositions:(e,n=!0,r=!1)=>{const{triggerNodeChanges:o}=t();o(e.map((e=>{const t={id:e.id,type:"position",dragging:r};return n&&(t.positionAbsolute=e.positionAbsolute,t.position=e.position),t})))},triggerNodeChanges:n=>{const{onNodesChange:r,nodeInternals:o,hasDefaultNodes:a,nodeOrigin:i,getNodes:l,elevateNodesOnSelect:s}=t();if(n?.length){if(a){const t=cl(Al(n,l()),o,i,s);e({nodeInternals:t})}r?.(n)}},addSelectedNodes:n=>{const{multiSelectionActive:r,edges:o,getNodes:a}=t();let i,l=null;r?i=n.map((e=>Dl(e,!0))):(i=Tl(a(),n),l=Tl(o,[])),pl({changedNodes:i,changedEdges:l,get:t,set:e})},addSelectedEdges:n=>{const{multiSelectionActive:r,edges:o,getNodes:a}=t();let i,l=null;r?i=n.map((e=>Dl(e,!0))):(i=Tl(o,n),l=Tl(a(),[])),pl({changedNodes:l,changedEdges:i,get:t,set:e})},unselectNodesAndEdges:({nodes:n,edges:r}={})=>{const{edges:o,getNodes:a}=t(),i=r||o;pl({changedNodes:(n||a()).map((e=>(e.selected=!1,Dl(e.id,!1)))),changedEdges:i.map((e=>Dl(e.id,!1))),get:t,set:e})},setMinZoom:n=>{const{d3Zoom:r,maxZoom:o}=t();r?.scaleExtent([n,o]),e({minZoom:n})},setMaxZoom:n=>{const{d3Zoom:r,minZoom:o}=t();r?.scaleExtent([o,n]),e({maxZoom:n})},setTranslateExtent:n=>{t().d3Zoom?.translateExtent(n),e({translateExtent:n})},resetSelectedElements:()=>{const{edges:n,getNodes:r}=t();pl({changedNodes:r().filter((e=>e.selected)).map((e=>Dl(e.id,!1))),changedEdges:n.filter((e=>e.selected)).map((e=>Dl(e.id,!1))),get:t,set:e})},setNodeExtent:n=>{const{nodeInternals:r}=t();r.forEach((e=>{e.positionAbsolute=Ea(e.position,n)})),e({nodeExtent:n,nodeInternals:new Map(r)})},panBy:e=>{const{transform:n,width:r,height:o,d3Zoom:a,d3Selection:i,translateExtent:l}=t();if(!a||!i||!e.x&&!e.y)return!1;const s=Xo.translate(n[0]+e.x,n[1]+e.y).scale(n[2]),c=[[0,0],[r,o]],u=a?.constrain()(s,c,l);return a.transform(i,u),n[0]!==u.x||n[1]!==u.y||n[2]!==u.k},cancelConnection:()=>e({connectionNodeId:Ts.connectionNodeId,connectionHandleId:Ts.connectionHandleId,connectionHandleType:Ts.connectionHandleType,connectionStatus:Ts.connectionStatus,connectionStartHandle:Ts.connectionStartHandle,connectionEndHandle:Ts.connectionEndHandle}),reset:()=>e({...Ts})}),r=Object.is,n?Et(n,r):Et)),ht.createElement(fa,{value:t.current},e);var n,r};Is.displayName="ReactFlowProvider";const js=({children:e})=>(0,ht.useContext)(da)?ht.createElement(ht.Fragment,null,e):ht.createElement(Is,null,e);js.displayName="ReactFlowWrapper";const Ms={input:$i,default:ji,output:zi,group:Fi},$s={default:li,straight:ri,step:ni,smoothstep:ti,simplebezier:Qa},Ls=[0,0],zs=[15,15],Fs={x:0,y:0,zoom:1},Ws={width:"100%",height:"100%",overflow:"hidden",position:"relative",zIndex:0},Gs=(0,ht.forwardRef)((({nodes:e,edges:t,defaultNodes:n,defaultEdges:r,className:o,nodeTypes:a=Ms,edgeTypes:i=$s,onNodeClick:l,onEdgeClick:s,onInit:c,onMove:u,onMoveStart:d,onMoveEnd:f,onConnect:p,onConnectStart:h,onConnectEnd:m,onClickConnectStart:g,onClickConnectEnd:b,onNodeMouseEnter:y,onNodeMouseMove:v,onNodeMouseLeave:w,onNodeContextMenu:_,onNodeDoubleClick:E,onNodeDragStart:x,onNodeDrag:S,onNodeDragStop:k,onNodesDelete:R,onEdgesDelete:N,onSelectionChange:C,onSelectionDragStart:O,onSelectionDrag:A,onSelectionDragStop:P,onSelectionContextMenu:D,onSelectionStart:T,onSelectionEnd:I,connectionMode:j=Ba.Strict,connectionLineType:M=Ua.Bezier,connectionLineStyle:$,connectionLineComponent:L,connectionLineContainerStyle:z,deleteKeyCode:F="Backspace",selectionKeyCode:W="Shift",selectionOnDrag:G=!1,selectionMode:B=Ha.Full,panActivationKeyCode:V="Space",multiSelectionKeyCode:H=(La()?"Meta":"Control"),zoomActivationKeyCode:U=(La()?"Meta":"Control"),snapToGrid:q=!1,snapGrid:X=zs,onlyRenderVisibleElements:Y=!1,selectNodesOnDrag:K=!0,nodesDraggable:Q,nodesConnectable:Z,nodesFocusable:J,nodeOrigin:ee=Ls,edgesFocusable:te,edgesUpdatable:ne,elementsSelectable:re,defaultViewport:oe=Fs,minZoom:ae=.5,maxZoom:ie=2,translateExtent:le=Ds,preventScrolling:se=!0,nodeExtent:ce,defaultMarkerColor:ue="#b1b1b7",zoomOnScroll:de=!0,zoomOnPinch:fe=!0,panOnScroll:pe=!1,panOnScrollSpeed:he=.5,panOnScrollMode:me=Va.Free,zoomOnDoubleClick:ge=!0,panOnDrag:be=!0,onPaneClick:ye,onPaneMouseEnter:ve,onPaneMouseMove:we,onPaneMouseLeave:_e,onPaneScroll:Ee,onPaneContextMenu:xe,children:Se,onEdgeContextMenu:ke,onEdgeDoubleClick:Re,onEdgeMouseEnter:Ne,onEdgeMouseMove:Ce,onEdgeMouseLeave:Oe,onEdgeUpdate:Ae,onEdgeUpdateStart:Pe,onEdgeUpdateEnd:De,onReconnect:Te,onReconnectStart:Ie,onReconnectEnd:je,reconnectRadius:Me=10,edgeUpdaterRadius:$e=10,onNodesChange:Le,onEdgesChange:ze,noDragClassName:Fe="nodrag",noWheelClassName:We="nowheel",noPanClassName:Ge="nopan",fitView:Be=!1,fitViewOptions:Ve,connectOnClick:He=!0,attributionPosition:Ue,proOptions:qe,defaultEdgeOptions:Xe,elevateNodesOnSelect:Ye=!0,elevateEdgesOnSelect:Ke=!1,disableKeyboardA11y:Qe=!1,autoPanOnConnect:Ze=!0,autoPanOnNodeDrag:Je=!0,connectionRadius:et=20,isValidConnection:tt,onError:nt,style:rt,id:ot,nodeDragThreshold:at,...it},lt)=>{const st=ot||"1";return ht.createElement("div",{...it,style:{...rt,...Ws},ref:lt,className:mt(["react-flow",o]),"data-testid":"rf__wrapper",id:ot},ht.createElement(js,null,ht.createElement(Ps,{onInit:c,onMove:u,onMoveStart:d,onMoveEnd:f,onNodeClick:l,onEdgeClick:s,onNodeMouseEnter:y,onNodeMouseMove:v,onNodeMouseLeave:w,onNodeContextMenu:_,onNodeDoubleClick:E,nodeTypes:a,edgeTypes:i,connectionLineType:M,connectionLineStyle:$,connectionLineComponent:L,connectionLineContainerStyle:z,selectionKeyCode:W,selectionOnDrag:G,selectionMode:B,deleteKeyCode:F,multiSelectionKeyCode:H,panActivationKeyCode:V,zoomActivationKeyCode:U,onlyRenderVisibleElements:Y,selectNodesOnDrag:K,defaultViewport:oe,translateExtent:le,minZoom:ae,maxZoom:ie,preventScrolling:se,zoomOnScroll:de,zoomOnPinch:fe,zoomOnDoubleClick:ge,panOnScroll:pe,panOnScrollSpeed:he,panOnScrollMode:me,panOnDrag:be,onPaneClick:ye,onPaneMouseEnter:ve,onPaneMouseMove:we,onPaneMouseLeave:_e,onPaneScroll:Ee,onPaneContextMenu:xe,onSelectionContextMenu:D,onSelectionStart:T,onSelectionEnd:I,onEdgeContextMenu:ke,onEdgeDoubleClick:Re,onEdgeMouseEnter:Ne,onEdgeMouseMove:Ce,onEdgeMouseLeave:Oe,onReconnect:Te??Ae,onReconnectStart:Ie??Pe,onReconnectEnd:je??De,reconnectRadius:Me??$e,defaultMarkerColor:ue,noDragClassName:Fe,noWheelClassName:We,noPanClassName:Ge,elevateEdgesOnSelect:Ke,rfId:st,disableKeyboardA11y:Qe,nodeOrigin:ee,nodeExtent:ce}),ht.createElement(Ki,{nodes:e,edges:t,defaultNodes:n,defaultEdges:r,onConnect:p,onConnectStart:h,onConnectEnd:m,onClickConnectStart:g,onClickConnectEnd:b,nodesDraggable:Q,nodesConnectable:Z,nodesFocusable:J,edgesFocusable:te,edgesUpdatable:ne,elementsSelectable:re,elevateNodesOnSelect:Ye,minZoom:ae,maxZoom:ie,nodeExtent:ce,onNodesChange:Le,onEdgesChange:ze,snapToGrid:q,snapGrid:X,connectionMode:j,translateExtent:le,connectOnClick:He,defaultEdgeOptions:Xe,fitView:Be,fitViewOptions:Ve,onNodesDelete:R,onEdgesDelete:N,onNodeDragStart:x,onNodeDrag:S,onNodeDragStop:k,onSelectionDrag:A,onSelectionDragStart:O,onSelectionDragStop:P,noPanClassName:Ge,nodeOrigin:ee,rfId:st,autoPanOnConnect:Ze,autoPanOnNodeDrag:Je,onError:nt,connectionRadius:et,isValidConnection:tt,nodeDragThreshold:at}),ht.createElement(Ui,{onSelectionChange:C}),Se,ht.createElement(ya,{proOptions:qe,position:Ue}),ht.createElement(rl,{rfId:st,disableKeyboardA11y:Qe})))}));Gs.displayName="ReactFlow";const Bs=e=>e.domNode?.querySelector(".react-flow__edgelabel-renderer");function Vs({children:e}){const t=ha(Bs);return t?(0,ua.createPortal)(e,t):null}function Hs(e){return t=>{const[n,r]=(0,ht.useState)(t),o=(0,ht.useCallback)((t=>r((n=>e(t,n)))),[]);return[n,r,o]}}function Us(e){return Us="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},Us(e)}function qs(e){return function(e){if(Array.isArray(e))return Xs(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return Xs(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)?Xs(e,t):void 0}}(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 Xs(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n0&&void 0!==arguments[0]?arguments[0]:Js,n=arguments.length>1?arguments[1]:void 0;switch(n.type){case"SET_ACTIVE_FEATURES":return n.payload.forEach((function(e){nc.includes(e)&&ic(e,!0)})),null===(e=n.payload.includes(g)?null:t.activeSidebarName)&&(0,$.dispatch)("core/interface").disableComplementaryArea(k),Ks(Ks({},t),{},{activeFeatures:n.payload,activeSidebarName:e});case"TOGGLE_FEATURE":var r=n.payload,o=qs(t.activeFeatures);return o.includes(r)?o=o.filter((function(e){return e!==r})):o.push(r),nc.forEach((function(e){o.includes(e)?ic(e,!0):ic(e,!1)})),null===(e=o.includes(g)?null:t.activeSidebarName)&&(0,$.dispatch)("core/interface").disableComplementaryArea(k),Ks(Ks({},t),{},{activeFeatures:o,activeSidebarName:e});case"ENABLE_FEATURE":var a=n.payload;nc.includes(a)&&ic(a,!0);var i=[].concat(qs(t.activeFeatures),[a]);return null===(e=i.includes(g)?null:t.activeSidebarName)&&(0,$.dispatch)("core/interface").disableComplementaryArea(k),Ks(Ks({},t),{},{activeFeatures:i,activeSidebarName:e});case"DISABLE_FEATURE":var l=n.payload;return nc.includes(l)&&ic(l,!1),Ks(Ks({},t),{},{activeFeatures:t.activeFeatures.filter((function(e){return e!==l}))});case"SET_CURRENT_INSERTER_TAB":return Ks(Ks({},t),{},{currentInserterTab:n.payload});case"SET_TRIGGER_CATEGORIES":return Ks(Ks({},t),{},{triggerCategories:n.payload});case"SET_TRIGGER_NODES":return Ks(Ks({},t),{},{triggerNodes:n.payload});case"SET_ACTION_CATEGORIES":return Ks(Ks({},t),{},{actionCategories:n.payload});case"SET_ACTION_NODES":return Ks(Ks({},t),{},{actionNodes:n.payload});case"SET_ADVANCED_CATEGORIES":return Ks(Ks({},t),{},{advancedCategories:n.payload});case"SET_ADVANCED_NODES":return Ks(Ks({},t),{},{advancedNodes:n.payload});case"CLOSE_GENERAL_SIDEBAR":return Ks(Ks({},t),{},{activeSidebarName:null});case"OPEN_GENERAL_SIDEBAR":return Ks(Ks({},t),{},{activeSidebarName:n.payload,activeFeatures:t.activeFeatures.filter((function(e){return e!==g}))});case"SET_HOVERED_ITEM":return Ks(Ks({},t),{},{hoveredItem:n.payload});case"SET_PANEL_BODY_STATE":var s=Ks(Ks({},t),{},{panelBodyStates:Ks(Ks({},t.panelBodyStates),{},Qs({},n.payload.panel,n.payload.state))});return lc(n.payload.panel,n.payload.state),s}return t},actions:{setActiveFeatures:function(e){return{type:"SET_ACTIVE_FEATURES",payload:e}},toggleFeature:function(e){return{type:"TOGGLE_FEATURE",payload:e}},disableFeature:function(e){return{type:"DISABLE_FEATURE",payload:e}},enableFeature:function(e){return{type:"ENABLE_FEATURE",payload:e}},setCurrentInserterTab:function(e){return{type:"SET_CURRENT_INSERTER_TAB",payload:e}},setTriggerCategories:function(e){return{type:"SET_TRIGGER_CATEGORIES",payload:e}},setTriggerNodes:function(e){return{type:"SET_TRIGGER_NODES",payload:e}},setActionCategories:function(e){return{type:"SET_ACTION_CATEGORIES",payload:e}},setActionNodes:function(e){return{type:"SET_ACTION_NODES",payload:e}},setAdvancedCategories:function(e){return{type:"SET_ADVANCED_CATEGORIES",payload:e}},setAdvancedNodes:function(e){return{type:"SET_ADVANCED_NODES",payload:e}},closeGeneralSidebar:function(){return(0,$.dispatch)("core/interface").disableComplementaryArea(k),{type:"CLOSE_GENERAL_SIDEBAR",payload:null}},openGeneralSidebar:function(e){return(0,$.dispatch)("core/interface").enableComplementaryArea(k,e),{type:"OPEN_GENERAL_SIDEBAR",payload:e}},openInserter:function(){return{type:"ENABLE_FEATURE",payload:g}},closeInserter:function(){return{type:"DISABLE_FEATURE",payload:g}},setHoveredItem:function(e){return{type:"SET_HOVERED_ITEM",payload:e}},setPanelBodyState:function(e,t){return{type:"SET_PANEL_BODY_STATE",payload:{panel:e,state:t}}}},selectors:{getActiveFeatures:function(e){return e.activeFeatures},isFeatureActive:function(e,t){return e.activeFeatures.includes(t)},getCurrentInserterTab:function(e){return e.currentInserterTab},getTriggerCategories:function(e){return e.triggerCategories},getTriggerNodes:function(e){return e.triggerNodes},getActionCategories:function(e){return e.actionCategories},getActionNodes:function(e){return e.actionNodes},getAdvancedCategories:function(e){return e.advancedCategories},getAdvancedNodes:function(e){return e.advancedNodes},getHoveredItem:function(e){return e.hoveredItem},getPanelBodyState:function(e,t){return e.panelBodyStates[t]},getAllNodes:function(e){return e.triggerNodes.concat(e.actionNodes,e.advancedNodes)},getNodeTypeByName:function(e,t){return e.triggerNodes.concat(e.actionNodes,e.advancedNodes).find((function(e){return e.name===t}))||{}},isRayDebugInstalled:function(e){return e.advancedNodes.some((function(e){return"advanced/ray.debug"===e.name}))},isPro:function(e){return e.isPro}}});(0,$.register)(ec);var tc="FUTURE_PRO_WORKFLOW_PREFERENCES_"+futureWorkflowEditor.currentUserId,nc=[h,b,y,v,w,_];null===localStorage.getItem(tc)&&localStorage.setItem(tc,JSON.stringify({persistentFeatures:{},panelBodyStates:{}}));var rc=function(){return JSON.parse(localStorage.getItem(tc))},oc=function(e){localStorage.setItem(tc,JSON.stringify(e))},ac=function(e){var t;return null===(t=rc().persistentFeatures)||void 0===t?void 0:t[e]},ic=function(e,t){var n=rc();n.persistentFeatures||(n.persistentFeatures={}),n.persistentFeatures[e]=t,oc(n)},lc=function(e,t){var n=rc();n.panelBodyStates||(n.panelBodyStates={}),n.panelBodyStates[e]=t,oc(n)};null==ac(h)&&ic(h,!0),null==ac(y)&&ic(y,!0),null==ac(_)&&ic(_,!0),nc.forEach((function(e){ac(e)?(0,$.dispatch)(ec).enableFeature(e):(0,$.dispatch)(ec).disableFeature(e)}));var sc=rc().panelBodyStates||{};function cc(e){return cc="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},cc(e)}function uc(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 dc(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:window).navigator.platform;return-1!==e.indexOf("Mac")||["iPad","iPhone"].includes(e)}function hc(e){var t=(0,$.select)(Gd).getNodes(),n=(0,$.select)(Gd).getEdges();return e?((e,t,n)=>{if(!ui(e))return[];const r=n.filter((t=>t.target===e.id)).map((e=>e.source));return t.filter((e=>r.includes(e.id)))})(e,t,n):[]}function mc(e){var t=hc(e);if(!t.length)return[];var n=t;return t.forEach((function(e){var t=mc(e);n=n.concat(t)})),n}function gc(e){var t=(0,$.select)(ec).getNodeTypeByName,n=hc(e),r=[];n.forEach((function(e){var n,o,a=t(null===(n=e.data)||void 0===n?void 0:n.name);null!=a&&null!==(o=a.outputSchema)&&void 0!==o&&o.length&&a.outputSchema.forEach((function(t){"input"===t.type?gc(e).map((function(e){r.push(dc(dc({},e),{},{name:"".concat(e.name),type:e.type,nodeLabel:a.label}))})):r.push(dc(dc({},t),{},{name:"".concat(e.data.slug,".").concat(t.name),type:t.type,nodeLabel:a.label}))}))}));var o=r.filter((function(e,t,n){return t===n.findIndex((function(t){return t.name===e.name}))}));return o.sort((function(e,t){return e.namet.name?1:0})),o}function bc(e){var t=(0,(0,$.select)(Gd).getDataTypeByName)(e.type),n={id:e.name,name:e.label,children:[],type:null==e?void 0:e.type,itemsType:null==e?void 0:e.itemsType};return"object"===t.type&&(n.children=t.propertiesSchema.map((function(t){return{id:e.name+"."+t.name,name:e.label+" -> "+t.label}}))),n}function yc(e,t){var n=!0;return null!=t&&t.length&&(n=t.includes(null==e?void 0:e.type),"object"!==(null==e?void 0:e.type)||n||(n=t.includes(null==e?void 0:e.objectType))),n}function vc(e,t){var n=(0,$.select)(Gd).getDataTypeByName,r=[];return e.forEach((function(e){var o=n(e.type),a=null==e?void 0:e.itemsType,i=yc(o,t);if("array"===e.type&&a&&!i){var l=t.map((function(e){return e.startsWith("array:")?e.replace("array:",""):null}));i=yc(n(a),l)}var s=null,c=[];"object"===o.type?(o.propertiesSchema.forEach((function(r){yc(n(r.type),t)&&c.push({id:e.id+"."+r.name,name:e.name+" -> "+r.label})})),s={id:e.id,name:e.name,children:c,type:e.type},i?r.push(s):c.length&&(r=r.concat(c))):i&&r.push(e)})),r}sc&&Object.keys(sc).forEach((function(e){(0,$.dispatch)(ec).setPanelBodyState(e,sc[e])}));var wc=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"node",t=((new Date).getTime()-new Date("2024-01-01 00:00:00").getTime()).toString(32);return"".concat(e,"_").concat(t)};function _c(e){var t,n=e.item,r=e.position,o=e.reactFlowInstance,a=function(e){var t=(0,$.select)(ec).getNodeTypeByName(e.name),n=(0,$.select)(Gd).getBaseSlugCounts(),r=t.baseSlug;r||(r="node"),(0,$.dispatch)(Gd).incrementBaseSlugCounts(r);var o=n[r]||0;return"".concat(r).concat(o+1)}(n),i=(0,$.select)(Gd).getNodes(),l=null!==(t=n.baseSlug)&&void 0!==t?t:"node",s={id:wc(l),type:n.type,position:r,data:{name:n.name,elementaryType:n.elementaryType,version:n.version,slug:a,settings:{}}};return n.settingsSchema&&n.settingsSchema.forEach((function(e){e.fields.forEach((function(e){void 0!==e.default&&(s.data.settings[e.name]=e.default)}))})),i=i.filter((function(e){return e.data.elementaryType!==A})),(0,$.dispatch)(Gd).setNodes(i.concat(s)),function(e){setTimeout((function(){(0,$.dispatch)(Gd).setEditedWorkflowAttribute("flow",e.toObject())}),400)}(o),s}var Ec=function(){return{id:wc("triggerPlaceholder"),type:"triggerPlaceholder",position:{x:0,y:0},data:{name:"placeholder/trigger",elementaryType:A,version:1,slug:"triggerPlaceholder1"}}};function xc(e){return xc="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},xc(e)}function Sc(e){return function(e){if(Array.isArray(e))return kc(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return kc(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)?kc(e,t):void 0}}(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 kc(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);nr?o:r}(e,n),a=null==r?void 0:r.baseSlug;return a&&o?Nc(Nc({},e),{},{baseSlugCounts:Nc(Nc({},e.baseSlugCounts),{},Cc({},a,o))}):e};function Mc(){Mc=function(){return t};var e,t={},n=Object.prototype,r=n.hasOwnProperty,o=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",l=a.asyncIterator||"@@asyncIterator",s=a.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(e){c=function(e,t,n){return e[t]=n}}function u(e,t,n,r){var a=t&&t.prototype instanceof b?t:b,i=Object.create(a.prototype),l=new A(r||[]);return o(i,"_invoke",{value:R(e,n,l)}),i}function d(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}t.wrap=u;var f="suspendedStart",p="suspendedYield",h="executing",m="completed",g={};function b(){}function y(){}function v(){}var w={};c(w,i,(function(){return this}));var _=Object.getPrototypeOf,E=_&&_(_(P([])));E&&E!==n&&r.call(E,i)&&(w=E);var x=v.prototype=b.prototype=Object.create(w);function S(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function k(e,t){function n(o,a,i,l){var s=d(e[o],e,a);if("throw"!==s.type){var c=s.arg,u=c.value;return u&&"object"==$c(u)&&r.call(u,"__await")?t.resolve(u.__await).then((function(e){n("next",e,i,l)}),(function(e){n("throw",e,i,l)})):t.resolve(u).then((function(e){c.value=e,i(c)}),(function(e){return n("throw",e,i,l)}))}l(s.arg)}var a;o(this,"_invoke",{value:function(e,r){function o(){return new t((function(t,o){n(e,r,t,o)}))}return a=a?a.then(o,o):o()}})}function R(t,n,r){var o=f;return function(a,i){if(o===h)throw Error("Generator is already running");if(o===m){if("throw"===a)throw i;return{value:e,done:!0}}for(r.method=a,r.arg=i;;){var l=r.delegate;if(l){var s=N(l,r);if(s){if(s===g)continue;return s}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(o===f)throw o=m,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);o=h;var c=d(t,n,r);if("normal"===c.type){if(o=r.done?m:p,c.arg===g)continue;return{value:c.arg,done:r.done}}"throw"===c.type&&(o=m,r.method="throw",r.arg=c.arg)}}}function N(t,n){var r=n.method,o=t.iterator[r];if(o===e)return n.delegate=null,"throw"===r&&t.iterator.return&&(n.method="return",n.arg=e,N(t,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),g;var a=d(o,t.iterator,n.arg);if("throw"===a.type)return n.method="throw",n.arg=a.arg,n.delegate=null,g;var i=a.arg;return i?i.done?(n[t.resultName]=i.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=e),n.delegate=null,g):i:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,g)}function C(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function O(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function A(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(C,this),this.reset(!0)}function P(t){if(t||""===t){var n=t[i];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,a=function n(){for(;++o=0;--a){var i=this.tryEntries[a],l=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var s=r.call(i,"catchLoc"),c=r.call(i,"finallyLoc");if(s&&c){if(this.prev=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),O(n),g}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;O(n)}return o}}throw Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:P(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),g}},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 Lc(e,t,n,r,o,a,i){try{var l=e[a](i),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(r,o)}function zc(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 Fc(e){for(var t=1;t0},Kc=function(e){return e.selectedEdges.length>0},Qc=function(e){return e.workflow.status},Zc=function(e){return e.workflow},Jc=function(e){return e.editedWorkflowAttributes},eu=function(e,t){return e.editedWorkflowAttributes.hasOwnProperty(t)?e.editedWorkflowAttributes[t]:e.workflow[t]},tu=function(e){return!!e.isLoadingWorkflow},nu=function(e){return!!e.isCreatingWorkflow},ru=function(e){return Fc(Fc({},e.workflow),e.editedWorkflowAttributes)},ou=function(e){return Object.keys(e.editedWorkflowAttributes).length>0},au=function(e){return""===e.workflow.flow.trim()},iu=function(e){return!!e.isNewWorkflow},lu=function(e){return e.initialViewport},su=function(e){return!!e.isSavingWorkflow},cu=function(e){return"publish"===e.workflow.status},uu=function(e){return!!e.isDeletingWorkflow},du=function(e){return!!e.isAutosavingWorkflow},fu=function(e){var t;return t=e.editedWorkflowAttributes.hasOwnProperty("title")?e.editedWorkflowAttributes.title:e.workflow.title,Object.keys(e.editedWorkflowAttributes).length>0&&!e.isSavingWorkflow&&!e.isAutosavingWorkflow&&""!==String(t).trim()},pu=function(e){return e.isCurrentWorkflowPublished},hu=function(e){return e.selectedNodes.length+e.selectedEdges.length},mu=function(e){return e.selectedNodes.length},gu=function(e){return e.selectedEdges.length},bu=function(e){return e.dataTypes},yu=function(e,t){return e.dataTypes.find((function(e){return e.name===t}))};function vu(){return wu.apply(this,arguments)}function wu(){var e;return e=Mc().mark((function e(){var t,n;return Mc().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(futureWorkflowEditor.enableWorkflowScreenshot){e.next=3;break}return e.abrupt("return",null);case 3:return e.prev=3,e.next=6,i.e(777).then(i.bind(i,777));case 6:return t=e.sent,n=t.toPng,e.next=10,n(document.querySelector(".react-flow"),{filter:function(e){var t,n,r;return!(null!=e&&null!==(t=e.classList)&&void 0!==t&&t.contains("react-flow__minimap")||null!=e&&null!==(n=e.classList)&&void 0!==n&&n.contains("react-flow__controls")||null!=e&&null!==(r=e.classList)&&void 0!==r&&r.contains("pwe-node-edit-button"))}});case 10:return e.abrupt("return",e.sent);case 13:return e.prev=13,e.t0=e.catch(3),console.error("Error loading html-to-image:",e.t0),e.abrupt("return",null);case 17:case"end":return e.stop()}}),e,null,[[3,13]])})),wu=function(){var t=this,n=arguments;return new Promise((function(r,o){var a=e.apply(t,n);function i(e){Lc(a,r,o,i,l,"next",e)}function l(e){Lc(a,r,o,i,l,"throw",e)}i(void 0)}))},wu.apply(this,arguments)}function _u(e){return e.globalVariables}function Eu(e,t){return e.globalVariables.find((function(e){return e.name===t}))}function xu(e,t){return e.taxonomyTerms[t]||[]}function Su(e){return e.baseSlugCounts}function ku(e,t){return e.nodeErrors[t]||[]}function Ru(e){return e.draggingFromHandle}function Nu(e){return!!e.isConnectingNodes}function Cu(e){return e.rayDebug.showQueries}function Ou(e){return e.rayDebug.showEmails}function Au(e){return e.rayDebug.showWordPressErrors}const Pu=(e,t)=>{let n,r,o=e.path;return"string"==typeof e.namespace&&"string"==typeof e.endpoint&&(n=e.namespace.replace(/^\/|\/$/g,""),r=e.endpoint.replace(/^\//,""),o=r?n+"/"+r:n),delete e.namespace,delete e.endpoint,t({...e,path:o})},Du=wp.url;function Tu(e,t){return Promise.resolve(t?e.body:new window.Response(JSON.stringify(e.body),{status:200,statusText:"OK",headers:e.headers}))}const Iu=({path:e,url:t,...n},r)=>({...n,url:t&&(0,Du.addQueryArgs)(t,r),path:e&&(0,Du.addQueryArgs)(e,r)}),ju=e=>e.json?e.json():Promise.reject(e),Mu=e=>{const{next:t}=(e=>{if(!e)return{};const t=e.match(/<([^>]+)>; rel="next"/);return t?{next:t[1]}:{}})(e.headers.get("link"));return t},$u=async(e,t)=>{if(!1===e.parse)return t(e);if(!(e=>{const t=!!e.path&&-1!==e.path.indexOf("per_page=-1"),n=!!e.url&&-1!==e.url.indexOf("per_page=-1");return t||n})(e))return t(e);const n=await Xu({...Iu(e,{per_page:100}),parse:!1}),r=await ju(n);if(!Array.isArray(r))return r;let o=Mu(n);if(!o)return r;let a=[].concat(r);for(;o;){const t=await Xu({...e,path:void 0,url:o,parse:!1}),n=await ju(t);a=a.concat(n),o=Mu(t)}return a},Lu=new Set(["PATCH","PUT","DELETE"]),zu="GET",Fu=(e,t=!0)=>Promise.resolve(((e,t=!0)=>t?204===e.status?null:e.json?e.json():Promise.reject(e):e)(e,t)).catch((e=>Wu(e,t)));function Wu(e,t=!0){if(!t)throw e;return(e=>{const t={code:"invalid_json",message:(0,L.__)("The response is not a valid JSON response.")};if(!e||!e.json)throw t;return e.json().catch((()=>{throw t}))})(e).then((e=>{const t={code:"unknown_error",message:(0,L.__)("An unknown error occurred.")};throw e||t}))}const Gu={Accept:"application/json, */*;q=0.1"},Bu={credentials:"include"},Vu=[(e,t)=>("string"!=typeof e.url||(0,Du.hasQueryArg)(e.url,"_locale")||(e.url=(0,Du.addQueryArgs)(e.url,{_locale:"user"})),"string"!=typeof e.path||(0,Du.hasQueryArg)(e.path,"_locale")||(e.path=(0,Du.addQueryArgs)(e.path,{_locale:"user"})),t(e)),Pu,(e,t)=>{const{method:n=zu}=e;return Lu.has(n.toUpperCase())&&(e={...e,headers:{...e.headers,"X-HTTP-Method-Override":n,"Content-Type":"application/json"},method:"POST"}),t(e)},$u],Hu=e=>{if(e.status>=200&&e.status<300)return e;throw e};let Uu=e=>{const{url:t,path:n,data:r,parse:o=!0,...a}=e;let{body:i,headers:l}=e;return l={...Gu,...l},r&&(i=JSON.stringify(r),l["Content-Type"]="application/json"),window.fetch(t||n||window.location.href,{...Bu,...a,body:i,headers:l}).then((e=>Promise.resolve(e).then(Hu).catch((e=>Wu(e,o))).then((e=>Fu(e,o)))),(e=>{if(e&&"AbortError"===e.name)throw e;throw{code:"fetch_error",message:(0,L.__)("You are probably offline.")}}))};function qu(e){return Vu.reduceRight(((e,t)=>n=>t(n,e)),Uu)(e).catch((t=>"rest_cookie_invalid_nonce"!==t.code?Promise.reject(t):window.fetch(qu.nonceEndpoint).then(Hu).then((e=>e.text())).then((t=>(qu.nonceMiddleware.nonce=t,qu(e))))))}qu.use=function(e){Vu.unshift(e)},qu.setFetchHandler=function(e){Uu=e},qu.createNonceMiddleware=function(e){const t=(e,n)=>{const{headers:r={}}=e;for(const o in r)if("x-wp-nonce"===o.toLowerCase()&&r[o]===t.nonce)return n(e);return n({...e,headers:{...r,"X-WP-Nonce":t.nonce}})};return t.nonce=e,t},qu.createPreloadingMiddleware=function(e){const t=Object.fromEntries(Object.entries(e).map((([e,t])=>[(0,Du.normalizePath)(e),t])));return(e,n)=>{const{parse:r=!0}=e;let o=e.path;if(!o&&e.url){const{rest_route:t,...n}=(0,Du.getQueryArgs)(e.url);"string"==typeof t&&(o=(0,Du.addQueryArgs)(t,n))}if("string"!=typeof o)return n(e);const a=e.method||"GET",i=(0,Du.normalizePath)(o);if("GET"===a&&t[i]){const e=t[i];return delete t[i],Tu(e,!!r)}if("OPTIONS"===a&&t[a]&&t[a][i]){const e=t[a][i];return delete t[a][i],Tu(e,!!r)}return n(e)}},qu.createRootURLMiddleware=e=>(t,n)=>Pu(t,(t=>{let r,o=t.url,a=t.path;return"string"==typeof a&&(r=e,-1!==e.indexOf("?")&&(a=a.replace("?","&")),a=a.replace(/^\//,""),"string"==typeof r&&-1!==r.indexOf("?")&&(a=a.replace("?","&")),o=r+a),n({...t,url:o})})),qu.fetchAllMiddleware=$u,qu.mediaUploadMiddleware=(e,t)=>{if(!function(e){const t=!!e.method&&"POST"===e.method;return(!!e.path&&-1!==e.path.indexOf("/wp/v2/media")||!!e.url&&-1!==e.url.indexOf("/wp/v2/media"))&&t}(e))return t(e);let n=0;const r=e=>(n++,t({path:`/wp/v2/media/${e}/post-process`,method:"POST",data:{action:"create-image-subsizes"},parse:!1}).catch((()=>n<5?r(e):(t({path:`/wp/v2/media/${e}?force=true`,method:"DELETE"}),Promise.reject()))));return t({...e,parse:!1}).catch((t=>{const n=t.headers.get("x-wp-upload-attachment-id");return t.status>=500&&t.status<600&&n?r(n).catch((()=>!1!==e.parse?Promise.reject({code:"post_process",message:(0,L.__)("Media upload failed. If this is a photo or a large image, please scale it down and try again.")}):Promise.reject(t))):Wu(t,e.parse)})).then((t=>Fu(t,e.parse)))},qu.createThemePreviewMiddleware=e=>(t,n)=>{if("string"==typeof t.url){const n=(0,Du.getQueryArg)(t.url,"wp_theme_preview");void 0===n?t.url=(0,Du.addQueryArgs)(t.url,{wp_theme_preview:e}):""===n&&(t.url=(0,Du.removeQueryArgs)(t.url,"wp_theme_preview"))}if("string"==typeof t.path){const n=(0,Du.getQueryArg)(t.path,"wp_theme_preview");void 0===n?t.path=(0,Du.addQueryArgs)(t.path,{wp_theme_preview:e}):""===n&&(t.path=(0,Du.removeQueryArgs)(t.path,"wp_theme_preview"))}return n(t)};const Xu=qu;function Yu(e){return{type:"API_FETCH",request:e}}const Ku={AWAIT_PROMISE:({promise:e})=>e,API_FETCH:({request:e})=>Xu(e)};function Qu(e){return Qu="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},Qu(e)}function Zu(){Zu=function(){return t};var e,t={},n=Object.prototype,r=n.hasOwnProperty,o=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",l=a.asyncIterator||"@@asyncIterator",s=a.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(e){c=function(e,t,n){return e[t]=n}}function u(e,t,n,r){var a=t&&t.prototype instanceof b?t:b,i=Object.create(a.prototype),l=new A(r||[]);return o(i,"_invoke",{value:R(e,n,l)}),i}function d(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}t.wrap=u;var f="suspendedStart",p="suspendedYield",h="executing",m="completed",g={};function b(){}function y(){}function v(){}var w={};c(w,i,(function(){return this}));var _=Object.getPrototypeOf,E=_&&_(_(P([])));E&&E!==n&&r.call(E,i)&&(w=E);var x=v.prototype=b.prototype=Object.create(w);function S(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function k(e,t){function n(o,a,i,l){var s=d(e[o],e,a);if("throw"!==s.type){var c=s.arg,u=c.value;return u&&"object"==Qu(u)&&r.call(u,"__await")?t.resolve(u.__await).then((function(e){n("next",e,i,l)}),(function(e){n("throw",e,i,l)})):t.resolve(u).then((function(e){c.value=e,i(c)}),(function(e){return n("throw",e,i,l)}))}l(s.arg)}var a;o(this,"_invoke",{value:function(e,r){function o(){return new t((function(t,o){n(e,r,t,o)}))}return a=a?a.then(o,o):o()}})}function R(t,n,r){var o=f;return function(a,i){if(o===h)throw Error("Generator is already running");if(o===m){if("throw"===a)throw i;return{value:e,done:!0}}for(r.method=a,r.arg=i;;){var l=r.delegate;if(l){var s=N(l,r);if(s){if(s===g)continue;return s}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(o===f)throw o=m,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);o=h;var c=d(t,n,r);if("normal"===c.type){if(o=r.done?m:p,c.arg===g)continue;return{value:c.arg,done:r.done}}"throw"===c.type&&(o=m,r.method="throw",r.arg=c.arg)}}}function N(t,n){var r=n.method,o=t.iterator[r];if(o===e)return n.delegate=null,"throw"===r&&t.iterator.return&&(n.method="return",n.arg=e,N(t,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),g;var a=d(o,t.iterator,n.arg);if("throw"===a.type)return n.method="throw",n.arg=a.arg,n.delegate=null,g;var i=a.arg;return i?i.done?(n[t.resultName]=i.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=e),n.delegate=null,g):i:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,g)}function C(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function O(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function A(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(C,this),this.reset(!0)}function P(t){if(t||""===t){var n=t[i];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,a=function n(){for(;++o=0;--a){var i=this.tryEntries[a],l=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var s=r.call(i,"catchLoc"),c=r.call(i,"finallyLoc");if(s&&c){if(this.prev=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),O(n),g}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;O(n)}return o}}throw Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:P(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),g}},t}var Ju=Zu().mark(id),ed=Zu().mark(wd),td=Zu().mark(kd),nd=window.futureWorkflowEditor,rd=nd.apiUrl,od=nd.nonce,ad=["title","description","flow","status","debugRayShowQueries","debugRayShowEmails","debugRayShowWordPressErrors","debugRayShowCurrentRunningStep"];function id(e){var t,n;return Zu().wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,{type:"LOAD_WORKFLOW_START"};case 2:if(0!=(e=parseInt(e,10))){r.next=19;break}return r.next=6,{type:"CREATE_WORKFLOW_START"};case 6:return r.prev=6,r.next=9,Yu({path:"".concat(rd,"/workflows"),method:"POST",headers:{"X-WP-Nonce":od}});case 9:return t=r.sent,r.next=12,{type:"CREATE_WORKFLOW_SUCCESS",payload:t};case 12:r.next=19;break;case 14:return r.prev=14,r.t0=r.catch(6),(0,$.dispatch)("core/notices").createErrorNotice((0,L.__)("Unable to create a new workflow. Please try again.","post-expirator")),r.next=19,{type:"CREATE_WORKFLOW_FAILURE"};case 19:if(!(e>0)){r.next=33;break}return r.prev=20,r.next=23,Yu({path:"".concat(rd,"/workflows/").concat(e),headers:{"X-WP-Nonce":od}});case 23:return n=r.sent,r.next=26,{type:"LOAD_WORKFLOW_SUCCESS",payload:n};case 26:r.next=33;break;case 28:return r.prev=28,r.t1=r.catch(20),(0,$.dispatch)("core/notices").createErrorNotice((0,L.__)("Unable to load the workflow. Please try again.","post-expirator")),r.next=33,{type:"LOAD_WORKFLOW_FAILURE"};case 33:case"end":return r.stop()}}),Ju,null,[[6,14],[20,28]])}function ld(){var e=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}).screenshot;return Zu().mark((function t(){var n,r,o;return Zu().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,{type:"SAVE_AS_DRAFT_START"};case 2:return t.prev=2,t.next=5,(0,$.select)(pt).isNewWorkflow();case 5:return n=t.sent,t.next=8,(0,$.dispatch)(pt).setEditedWorkflowAttribute("status","draft");case 8:return t.next=10,(0,$.select)(pt).getEditedWorkflow();case 10:return r=t.sent,e&&(r.screenshot=e),t.next=14,Yu({path:"".concat(rd,"/workflows/").concat(parseInt(r.id)),method:"PUT",headers:{"X-WP-Nonce":od},body:JSON.stringify(r)});case 14:return o=t.sent,n&&window.history.pushState({},"","?page=future_workflow_editor&workflow=".concat(parseInt(o.id))),t.next=18,{type:"SAVE_AS_DRAFT_SUCCESS",payload:o};case 18:(0,$.dispatch)("core/notices").createSuccessNotice((0,L.__)("Workflow saved as draft.","post-expirator"),{type:"snackbar",isDismissible:!0}),t.next=26;break;case 21:return t.prev=21,t.t0=t.catch(2),(0,$.dispatch)("core/notices").createErrorNotice((0,L.__)("Unable to save workflow. Please, try again.","post-expirator")),t.next=26,{type:"SAVE_AS_DRAFT_FAILURE"};case 26:case"end":return t.stop()}}),t,null,[[2,21]])}))()}function sd(){var e=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}).screenshot;return Zu().mark((function t(){var n,r;return Zu().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,{type:"SAVE_AS_CURRENT_STATUS_START"};case 2:return t.prev=2,t.next=5,(0,$.select)(pt).getEditedWorkflow();case 5:return n=t.sent,e&&(n.screenshot=e),t.next=9,Yu({path:"".concat(rd,"/workflows/").concat(parseInt(n.id)),method:"PUT",headers:{"X-WP-Nonce":od},body:JSON.stringify(n)});case 9:return r=t.sent,t.next=12,{type:"SAVE_AS_CURRENT_STATUS_SUCCESS",payload:r};case 12:(0,$.dispatch)("core/notices").createSuccessNotice((0,L.__)("Workflow saved.","post-expirator"),{type:"snackbar",isDismissible:!0}),t.next=20;break;case 15:return t.prev=15,t.t0=t.catch(2),(0,$.dispatch)("core/notices").createErrorNotice((0,L.__)("Unable to save workflow. Please, try again.","post-expirator")),t.next=20,{type:"SAVE_AS_CURRENT_STATUS_FAILURE"};case 20:case"end":return t.stop()}}),t,null,[[2,15]])}))()}function cd(){var e=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}).screenshot;return Zu().mark((function t(){var n,r,o;return Zu().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,{type:"PUBLISH_WORKFLOW_START"};case 2:return t.prev=2,t.next=5,(0,$.select)(pt).isNewWorkflow();case 5:return n=t.sent,t.next=8,(0,$.dispatch)(pt).setEditedWorkflowAttribute("status","publish");case 8:return t.next=10,(0,$.select)(pt).getEditedWorkflow();case 10:return r=t.sent,e&&(r.screenshot=e),t.next=14,Yu({path:"".concat(rd,"/workflows/").concat(parseInt(r.id)),method:"PUT",headers:{"X-WP-Nonce":od},body:JSON.stringify(r)});case 14:return o=t.sent,n&&window.history.pushState({},"","?page=future_workflow_editor&workflow=".concat(parseInt(o.id))),t.next=18,{type:"PUBLISH_WORKFLOW_SUCCESS",payload:o};case 18:(0,$.dispatch)("core/notices").createSuccessNotice((0,L.__)("Workflow published.","post-expirator"),{type:"snackbar",isDismissible:!0}),t.next=26;break;case 21:return t.prev=21,t.t0=t.catch(2),(0,$.dispatch)("core/notices").createErrorNotice((0,L.__)("Unable to publish the workflow. Please, try again.","post-expirator")),t.next=26,{type:"PUBLISH_WORKFLOW_FAILURE"};case 26:case"end":return t.stop()}}),t,null,[[2,21]])}))()}function ud(){var e=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}).screenshot;return Zu().mark((function t(){var n,r,o;return Zu().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,{type:"SWITCH_TO_DRAFT_START"};case 2:return t.prev=2,t.next=5,(0,$.select)(pt).isNewWorkflow();case 5:return n=t.sent,t.next=8,(0,$.dispatch)(pt).setEditedWorkflowAttribute("status","draft");case 8:return t.next=10,(0,$.select)(pt).getEditedWorkflow();case 10:return r=t.sent,e&&(r.screenshot=e),t.next=14,Yu({path:"".concat(rd,"/workflows/").concat(parseInt(r.id)),method:"PUT",headers:{"X-WP-Nonce":od},body:JSON.stringify(r)});case 14:return o=t.sent,n&&window.history.pushState({},"","?page=future_workflow_editor&workflow=".concat(parseInt(o.id))),t.next=18,{type:"SWITCH_TO_DRAFT_SUCCESS",payload:o};case 18:(0,$.dispatch)("core/notices").createSuccessNotice((0,L.__)("Workflow switched to draft.","post-expirator"),{type:"snackbar",isDismissible:!0}),t.next=26;break;case 21:return t.prev=21,t.t0=t.catch(2),(0,$.dispatch)("core/notices").createErrorNotice((0,L.__)("Unable to switch workflow to draft. Please, try again.","post-expirator")),t.next=26,{type:"SWITCH_TO_DRAFT_FAILURE"};case 26:case"end":return t.stop()}}),t,null,[[2,21]])}))()}var dd=function(e){return{type:"SET_FLOW",payload:e}},fd=function(e){return{type:"SET_POST_TYPE",payload:e}},pd=function(e){return{type:"SET_NODES",payload:e}},hd=function(e){return{type:"SET_EDGES",payload:e}},md=function(e){return{type:"SET_INITIAL_VIEWPORT",payload:e}},gd=function(e){return{type:"SET_SELECTED_NODES",payload:e}},bd=function(){return{type:"UNSELECT_ALL"}},yd=function(e){return{type:"SET_SELECTED_EDGES",payload:e}},vd=function(e,t){if(!ad.includes(e))throw new Error('The workflow attribute "'.concat(e,'" is not editable.'));return{type:"SET_EDITED_WORKFLOW_ATTRIBUTE",payload:{key:e,value:t}}};function wd(){var e,t;return Zu().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,{type:"DELETE_WORKFLOW_START"};case 2:return n.next=4,(0,$.select)(pt).getEditedWorkflow();case 4:return e=n.sent,n.prev=5,n.next=8,Yu({path:"".concat(rd,"/workflows/").concat(parseInt(e.id)),method:"DELETE",headers:{"X-WP-Nonce":od}});case 8:return t=n.sent,n.next=11,{type:"DELETE_WORKFLOW_SUCCESS",payload:t};case 11:(0,$.dispatch)("core/notices").createSuccessNotice((0,L.__)("Workflow deleted. Redirecting...","post-expirator"),{type:"snackbar",isDismissible:!0}),window.location.href="edit.php?post_type=ppfuture_workflow",n.next=20;break;case 15:return n.prev=15,n.t0=n.catch(5),(0,$.dispatch)("core/notices").createErrorNotice((0,L.__)("Unable to delete the workflow. Please, try again.","post-expirator")),n.next=20,{type:"DELETE_WORKFLOW_FAILURE"};case 20:case"end":return n.stop()}}),ed,null,[[5,15]])}function _d(e){return{type:"UPDATE_NODE",payload:e}}function Ed(e){return{type:"SET_DATA_TYPES",payload:e}}function xd(e){return{type:"ADD_DATA_TYPE",payload:e}}function Sd(e){return{type:"SET_GLOBAL_VARIABLE",payload:e}}function kd(e){var t;return Zu().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,{type:"FETCH_TAXONOMY_TERMS_START"};case 2:return n.prev=2,n.next=5,Yu({path:"".concat(rd,"/terms/").concat(e),headers:{"X-WP-Nonce":od}});case 5:return t=n.sent,n.next=8,{type:"FETCH_TAXONOMY_TERMS_SUCCESS",payload:{taxonomy:e,result:t}};case 8:n.next=14;break;case 10:return n.prev=10,n.t0=n.catch(2),n.next=14,{type:"FETCH_TAXONOMY_TERMS_FAILURE"};case 14:case"end":return n.stop()}}),td,null,[[2,10]])}function Rd(e){return{type:"INCREMENT_BASE_SLUG_COUNTS",payload:e}}function Nd(e){return{type:"UPDATE_BASE_SLUG_COUNTS",payload:e}}function Cd(e,t,n){return{type:"ADD_NODE_ERROR",payload:{nodeId:e,error:t,message:n}}}function Od(e,t){return{type:"REMOVE_NODE_ERROR",payload:{nodeId:e,error:t}}}function Ad(e){return{type:"RESET_NODE_ERRORS",payload:e}}function Pd(e){return{type:"REMOVE_NODE",payload:e}}function Dd(e){return{type:"REMOVE_EDGE",payload:e}}function Td(e){return{type:"ADD_NODE",payload:e}}function Id(){return{type:"REMOVE_PLACEHOLDER_NODES"}}function jd(e){return{type:"SET_DRAGGING_FROM_HANDLE",payload:{sourceId:e.sourceId,handleId:e.handleId,handleType:e.handleType}}}function Md(e){return{type:"SET_IS_CONNECTING_NODES",payload:e}}function $d(e){return $d="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},$d(e)}function Ld(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 zd(e,t,n){return(t=function(e){var t=function(e){if("object"!=$d(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=$d(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==$d(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Fd=function(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:Oc,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"CREATE_WORKFLOW_START":return function(e){return Nc(Nc({},e),{},{isCreatingWorkflow:!0,isLoadingWorkflow:!0})}(e);case"CREATE_WORKFLOW_SUCCESS":return function(e,t){var n=t.payload,r=[Ec()];return Nc(Nc({},e=Pc(e)),{},{nodes:r,isCreatingWorkflow:!1,isLoadingWorkflow:!1,workflow:n,editedWorkflowAttributes:{},isNewWorkflow:"auto-draft"===n.status,isEditedWorkflowEmpty:0===e.edges.length&&0===e.nodes.length,isCurrentWorkflowPublished:"publish"===n.status})}(e,t);case"CREATE_WORKFLOW_FAILURE":return function(e){return Nc(Nc({},e),{},{isCreatingWorkflow:!1,isLoadingWorkflow:!1})}(e);case"LOAD_WORKFLOW_START":return function(e){return Nc(Nc({},e),{},{isLoadingWorkflow:!0})}(e);case"LOAD_WORKFLOW_SUCCESS":return function(e,t){var n,r,o,a=t.payload,i=(null===(n=a.flow)||void 0===n?void 0:n.nodes)||[],l=(null===(r=a.flow)||void 0===r?void 0:r.edges)||[],s=(null===(o=a.flow)||void 0===o?void 0:o.viewport)||Oc.viewport;return i.map((function(t){var n,r=null==t||null===(n=t.data)||void 0===n?void 0:n.slug;r&&(e=jc(e,{payload:r}))})),i.length||(i=[Ec()]),l=function(e,t){return t.filter((function(t){var n=e.find((function(e){return e.id===t.source})),r=e.find((function(e){return e.id===t.target}));return!(!n||!r)}))}(i,l=Ac(l)),e=Pc(e),Dc(),Nc(Nc({},e),{},{isLoadingWorkflow:!1,workflow:a,editedWorkflowAttributes:{},isNewWorkflow:"auto-draft"===a.status,nodes:i,edges:l,initialViewport:s,isEditedWorkflowEmpty:0===e.edges.length&&0===e.nodes.length,isCurrentWorkflowPublished:"publish"===a.status})}(e,t);case"LOAD_WORKFLOW_FAILURE":return function(e){return Nc(Nc({},e),{},{isLoadingWorkflow:!1})}(e);case"SAVE_AS_DRAFT_START":case"SWITCH_TO_DRAFT_START":case"SAVE_AS_CURRENT_STATUS_START":case"PUBLISH_WORKFLOW_START":return function(e){return Nc(Nc({},e),{},{isSavingWorkflow:!0})}(e);case"SAVE_AS_DRAFT_SUCCESS":return function(e,t){var n=t.payload;return Nc(Nc({},e),{},{isSavingWorkflow:!1,workflow:n,editedWorkflowAttributes:{},isNewWorkflow:"auto-draft"===n.status,isEditedWorkflowEmpty:0===e.edges.length&&0===e.nodes.length,isCurrentWorkflowPublished:"publish"===n.status})}(e,t);case"SAVE_AS_DRAFT_FAILURE":case"SWITCH_TO_DRAFT_FAILURE":case"SAVE_AS_CURRENT_STATUS_FAILURE":case"PUBLISH_WORKFLOW_FAILURE":return function(e){return Nc(Nc({},e),{},{isSavingWorkflow:!1})}(e);case"SWITCH_TO_DRAFT_SUCCESS":return function(e,t){var n=t.payload,r=Nc(Nc({},e.workflow),{},{status:n.status});return Nc(Nc({},e),{},{isSavingWorkflow:!1,workflow:r,isNewWorkflow:!1,isEditedWorkflowEmpty:0===e.edges.length&&0===e.nodes.length,isCurrentWorkflowPublished:"publish"===r.status})}(e,t);case"SAVE_AS_CURRENT_STATUS_SUCCESS":return function(e,t){var n=t.payload,r=Nc(Nc({},e.workflow),{},{status:n.status});return Nc(Nc({},e),{},{isSavingWorkflow:!1,workflow:r,isNewWorkflow:!1,isEditedWorkflowEmpty:0===e.edges.length&&0===e.nodes.length,isCurrentWorkflowPublished:"publish"===r.status})}(e,t);case"PUBLISH_WORKFLOW_SUCCESS":return function(e,t){var n=t.payload,r=Nc(Nc({},e.workflow),{},{status:n.status});return Nc(Nc({},e),{},{isSavingWorkflow:!1,workflow:r,isNewWorkflow:!1,isEditedWorkflowEmpty:0===e.edges.length&&0===e.nodes.length,isCurrentWorkflowPublished:"publish"===r.status})}(e,t);case"SET_EDITED_WORKFLOW_ATTRIBUTE":return function(e,t){var n=t.payload,r=n.key,o=n.value;return Nc(Nc({},e),{},{editedWorkflowAttributes:Nc(Nc({},e.editedWorkflowAttributes),{},Cc({},r,o)),isEditedWorkflowEmpty:0===e.edges.length&&0===e.nodes.length})}(e,t);case"SET_POST_TYPE":return function(e,t){var n=t.payload;return Nc(Nc({},e),{},{postType:n})}(e,t);case"SET_NODES":return function(e,t){var n=t.payload;return Nc(Nc({},e),{},{nodes:n})}(e,t);case"ADD_NODE":return function(e,t){var n=t.payload,r=[].concat(Sc(e.nodes),[n]);return Nc(Nc({},e),{},{nodes:r})}(e,t);case"SET_EDGES":return function(e,t){var n=t.payload,r=Ac(n);return Nc(Nc({},e),{},{edges:r})}(e,t);case"ADD_EDGE":return addEdge(e,t);case"SET_INITIAL_VIEWPORT":return function(e,t){var n=t.payload;return Nc(Nc({},e),{},{viewport:n})}(e,t);case"SET_SELECTED_NODES":return function(e,t){var n=t.payload;return Nc(Nc({},e),{},{selectedNodes:n})}(e,t);case"SET_SELECTED_EDGES":return function(e,t){var n=t.payload;return Nc(Nc({},e),{},{selectedEdges:n})}(e,t);case"UNSELECT_ALL":return Dc(e);case"DELETE_WORKFLOW_START":return function(e){return Nc(Nc({},e),{},{isDeletingWorkflow:!0})}(e);case"DELETE_WORKFLOW_SUCCESS":case"DELETE_WORKFLOW_FAILURE":return function(e){return Nc(Nc({},e),{},{isDeletingWorkflow:!1})}(e);case"UPDATE_NODE":return function(e,t){var n=t.payload,r=e.nodes.map((function(e){return e.id===n.id?Nc({},n):e}));return Nc(Nc({},e),{},{nodes:r})}(e,t);case"SET_DATA_TYPES":return function(e,t){var n=t.payload;return Nc(Nc({},e),{},{dataTypes:n})}(e,t);case"ADD_DATA_TYPE":return function(e,t){var n=t.payload.payload;return Nc(Nc({},e),{},{dataTypes:[].concat(Sc(e.dataTypes),[n])})}(e,t);case"SET_GLOBAL_VARIABLE":return Tc(e,t);case"FETCH_TAXONOMY_TERMS_START":return function(e){return Nc(Nc({},e),{},{isFetchingTaxonomyTerms:!0})}(e);case"FETCH_TAXONOMY_TERMS_SUCCESS":return function(e,t){var n,r=t.payload,o=r.taxonomy,a=r.result,i=(null==a||null===(n=a.terms)||void 0===n?void 0:n.map((function(e){return{value:e.id,label:e.name}})))||[],l=Nc(Nc({},e.taxonomyTerms),{},Cc({},o,i));return Nc(Nc({},e),{},{isFetchingTaxonomyTerms:!1,taxonomyTerms:l})}(e,t);case"FETCH_TAXONOMY_TERMS_FAILURE":return function(e){return Nc(Nc({},e),{},{isFetchingTaxonomyTerms:!1})}(e);case"INCREMENT_BASE_SLUG_COUNTS":return function(e,t){var n=t.payload,r=Nc(Nc({},e.baseSlugCounts),{},Cc({},n,(e.baseSlugCounts[n]||0)+1));return Nc(Nc({},e),{},{baseSlugCounts:r})}(e,t);case"UPDATE_BASE_SLUG_COUNTS":return jc(e,t);case"ADD_NODE_ERROR":return function(e,t){var n=t.payload,r=e.nodeErrors[n.nodeId]||{};r[n.error]={error:n.error,message:n.message};var o=Nc(Nc({},e.nodeErrors),{},Cc({},n.nodeId,r));return Nc(Nc({},e),{},{nodeErrors:o})}(e,t);case"REMOVE_NODE_ERROR":return function(e,t){var n=t.payload,r=Nc({},e.nodeErrors);return r[n.nodeId]?(delete r[n.nodeId][n.error],Nc(Nc({},e),{},{nodeErrors:r})):e}(e,t);case"RESET_NODE_ERRORS":return function(e,t){var n=t.payload,r=Nc({},e.nodeErrors);return delete r[n],Nc(Nc({},e),{},{nodeErrors:r})}(e,t);case"REMOVE_NODE":return function(e,t){var n=t.payload,r=e.edges.filter((function(e){return e.source!==n&&e.target!==n})),o=e.nodes.filter((function(e){return e.id!==n}));return Nc(Nc({},e),{},{nodes:o,edges:r,selectedNodes:[],selectedEdges:[]})}(e,t);case"REMOVE_EDGE":return function(e,t){var n=t.payload,r=e.edges.filter((function(e){return e.id!==n}));return Nc(Nc({},e),{},{edges:r,selectedNodes:[],selectedEdges:[]})}(e,t);case"REMOVE_PLACEHOLDER_NODES":return function(e){var t=e.nodes.filter((function(e){return e.data.elementaryType!==A}));return Nc(Nc({},e),{},{nodes:t})}(e);case"SET_DRAGGING_FROM_HANDLE":return function(e,t){var n=t.payload,r=n.sourceId,o=n.handleId,a=n.handleType;return Nc(Nc({},e),{},{draggingFromHandle:{sourceId:r,handleId:o,handleType:a}})}(e,t);case"SET_IS_CONNECTING_NODES":return function(e,t){return Nc(Nc({},e),{},{isConnectingNodes:t.payload})}(e,t)}return e},actions:s,selectors:l,controls:Wd});(0,$.register)(Gd);const Bd=({id:e,x:t,y:n,width:r,height:o,style:a,color:i,strokeColor:l,strokeWidth:s,className:c,borderRadius:u,shapeRendering:d,onClick:f,selected:p})=>{const{background:h,backgroundColor:m}=a||{},g=i||h||m;return ht.createElement("rect",{className:mt(["react-flow__minimap-node",{selected:p},c]),x:t,y:n,rx:u,ry:u,width:r,height:o,fill:g,stroke:l,strokeWidth:s,shapeRendering:d,onClick:f?t=>f(t,e):void 0})};Bd.displayName="MiniMapNode";var Vd=(0,ht.memo)(Bd);const Hd=e=>e.nodeOrigin,Ud=e=>e.getNodes().filter((e=>!e.hidden&&e.width&&e.height)),qd=e=>e instanceof Function?e:()=>e;var Xd=(0,ht.memo)((function({nodeStrokeColor:e="transparent",nodeColor:t="#e2e2e2",nodeClassName:n="",nodeBorderRadius:r=5,nodeStrokeWidth:o=2,nodeComponent:a=Vd,onClick:i}){const l=ha(Ud,xt),s=ha(Hd),c=qd(t),u=qd(e),d=qd(n),f="undefined"==typeof window||window.chrome?"crispEdges":"geometricPrecision";return ht.createElement(ht.Fragment,null,l.map((e=>{const{x:t,y:n}=gi(e,s).positionAbsolute;return ht.createElement(a,{key:e.id,x:t,y:n,width:e.width,height:e.height,style:e.style,selected:e.selected,className:d(e),color:c(e),borderRadius:r,strokeColor:u(e),strokeWidth:o,shapeRendering:f,onClick:i,id:e.id})})))}));const Yd=e=>{const t=e.getNodes(),n={x:-e.transform[0]/e.transform[2],y:-e.transform[1]/e.transform[2],width:e.width/e.transform[2],height:e.height/e.transform[2]};return{viewBB:n,boundingRect:t.length>0?(r=bi(t,e.nodeOrigin),o=n,Ca(Ra(Na(r),Na(o)))):n,rfId:e.rfId};var r,o};function Kd({style:e,className:t,nodeStrokeColor:n="transparent",nodeColor:r="#e2e2e2",nodeClassName:o="",nodeBorderRadius:a=5,nodeStrokeWidth:i=2,nodeComponent:l,maskColor:s="rgb(240, 240, 240, 0.6)",maskStrokeColor:c="none",maskStrokeWidth:u=1,position:d="bottom-right",onClick:f,onNodeClick:p,pannable:h=!1,zoomable:m=!1,ariaLabel:g="React Flow mini map",inversePan:b=!1,zoomStep:y=10,offsetScale:v=5}){const w=ma(),_=(0,ht.useRef)(null),{boundingRect:E,viewBB:x,rfId:S}=ha(Yd,xt),k=e?.width??200,R=e?.height??150,N=E.width/k,C=E.height/R,O=Math.max(N,C),A=O*k,P=O*R,D=v*O,T=E.x-(A-E.width)/2-D,I=E.y-(P-E.height)/2-D,j=A+2*D,M=P+2*D,$=`react-flow__minimap-desc-${S}`,L=(0,ht.useRef)(0);L.current=O,(0,ht.useEffect)((()=>{if(_.current){const e=Bn(_.current),t=e=>{const{transform:t,d3Selection:n,d3Zoom:r}=w.getState();if("wheel"!==e.sourceEvent.type||!n||!r)return;const o=-e.sourceEvent.deltaY*(1===e.sourceEvent.deltaMode?.05:e.sourceEvent.deltaMode?1:.002)*y,a=t[2]*Math.pow(2,o);r.scaleTo(n,a)},n=e=>{const{transform:t,d3Selection:n,d3Zoom:r,translateExtent:o,width:a,height:i}=w.getState();if("mousemove"!==e.sourceEvent.type||!n||!r)return;const l=L.current*Math.max(1,t[2])*(b?-1:1),s={x:t[0]-e.sourceEvent.movementX*l,y:t[1]-e.sourceEvent.movementY*l},c=[[0,0],[a,i]],u=Xo.translate(s.x,s.y).scale(t[2]),d=r.constrain()(u,c,o);r.transform(n,d)},r=ra().on("zoom",h?n:null).on("zoom.wheel",m?t:null);return e.call(r),()=>{e.on("zoom",null)}}}),[h,m,b,y]);const z=f?e=>{const t=Zn(e);f(e,{x:t[0],y:t[1]})}:void 0,F=p?(e,t)=>{const n=w.getState().nodeInternals.get(t);p(e,n)}:void 0;return ht.createElement(ba,{position:d,style:e,className:mt(["react-flow__minimap",t]),"data-testid":"rf__minimap"},ht.createElement("svg",{width:k,height:R,viewBox:`${T} ${I} ${j} ${M}`,role:"img","aria-labelledby":$,ref:_,onClick:z},g&&ht.createElement("title",{id:$},g),ht.createElement(Xd,{onClick:F,nodeColor:r,nodeStrokeColor:n,nodeBorderRadius:a,nodeClassName:o,nodeStrokeWidth:i,nodeComponent:l}),ht.createElement("path",{className:"react-flow__minimap-mask",d:`M${T-D},${I-D}h${j+2*D}v${M+2*D}h${-j-2*D}z\n M${x.x},${x.y}h${x.width}v${x.height}h${-x.width}z`,fill:s,fillRule:"evenodd",stroke:c,strokeWidth:u,pointerEvents:"none"})))}Kd.displayName="MiniMap";var Qd=(0,ht.memo)(Kd);function Zd(){return ht.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32"},ht.createElement("path",{d:"M32 18.133H18.133V32h-4.266V18.133H0v-4.266h13.867V0h4.266v13.867H32z"}))}function Jd(){return ht.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 5"},ht.createElement("path",{d:"M0 0h32v4.2H0z"}))}function ef(){return ht.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 30"},ht.createElement("path",{d:"M3.692 4.63c0-.53.4-.938.939-.938h5.215V0H4.708C2.13 0 0 2.054 0 4.63v5.216h3.692V4.631zM27.354 0h-5.2v3.692h5.17c.53 0 .984.4.984.939v5.215H32V4.631A4.624 4.624 0 0027.354 0zm.954 24.83c0 .532-.4.94-.939.94h-5.215v3.768h5.215c2.577 0 4.631-2.13 4.631-4.707v-5.139h-3.692v5.139zm-23.677.94c-.531 0-.939-.4-.939-.94v-5.138H0v5.139c0 2.577 2.13 4.707 4.708 4.707h5.138V25.77H4.631z"}))}function tf(){return ht.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 32"},ht.createElement("path",{d:"M21.333 10.667H19.81V7.619C19.81 3.429 16.38 0 12.19 0 8 0 4.571 3.429 4.571 7.619v3.048H3.048A3.056 3.056 0 000 13.714v15.238A3.056 3.056 0 003.048 32h18.285a3.056 3.056 0 003.048-3.048V13.714a3.056 3.056 0 00-3.048-3.047zM12.19 24.533a3.056 3.056 0 01-3.047-3.047 3.056 3.056 0 013.047-3.048 3.056 3.056 0 013.048 3.048 3.056 3.056 0 01-3.048 3.047zm4.724-13.866H7.467V7.619c0-2.59 2.133-4.724 4.723-4.724 2.591 0 4.724 2.133 4.724 4.724v3.048z"}))}function nf(){return ht.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 32"},ht.createElement("path",{d:"M21.333 10.667H19.81V7.619C19.81 3.429 16.38 0 12.19 0c-4.114 1.828-1.37 2.133.305 2.438 1.676.305 4.42 2.59 4.42 5.181v3.048H3.047A3.056 3.056 0 000 13.714v15.238A3.056 3.056 0 003.048 32h18.285a3.056 3.056 0 003.048-3.048V13.714a3.056 3.056 0 00-3.048-3.047zM12.19 24.533a3.056 3.056 0 01-3.047-3.047 3.056 3.056 0 013.047-3.048 3.056 3.056 0 013.048 3.048 3.056 3.056 0 01-3.048 3.047z"}))}const rf=({children:e,className:t,...n})=>ht.createElement("button",{type:"button",className:mt(["react-flow__controls-button",t]),...n},e);rf.displayName="ControlButton";const of=e=>({isInteractive:e.nodesDraggable||e.nodesConnectable||e.elementsSelectable,minZoomReached:e.transform[2]<=e.minZoom,maxZoomReached:e.transform[2]>=e.maxZoom}),af=({style:e,showZoom:t=!0,showFitView:n=!0,showInteractive:r=!0,fitViewOptions:o,onZoomIn:a,onZoomOut:i,onFitView:l,onInteractiveChange:s,className:c,children:u,position:d="bottom-left"})=>{const f=ma(),[p,h]=(0,ht.useState)(!1),{isInteractive:m,minZoomReached:g,maxZoomReached:b}=ha(of,xt),{zoomIn:y,zoomOut:v,fitView:w}=bl();return(0,ht.useEffect)((()=>{h(!0)}),[]),p?ht.createElement(ba,{className:mt(["react-flow__controls",c]),position:d,style:e,"data-testid":"rf__controls"},t&&ht.createElement(ht.Fragment,null,ht.createElement(rf,{onClick:()=>{y(),a?.()},className:"react-flow__controls-zoomin",title:"zoom in","aria-label":"zoom in",disabled:b},ht.createElement(Zd,null)),ht.createElement(rf,{onClick:()=>{v(),i?.()},className:"react-flow__controls-zoomout",title:"zoom out","aria-label":"zoom out",disabled:g},ht.createElement(Jd,null))),n&&ht.createElement(rf,{className:"react-flow__controls-fitview",onClick:()=>{w(o),l?.()},title:"fit view","aria-label":"fit view"},ht.createElement(ef,null)),r&&ht.createElement(rf,{className:"react-flow__controls-interactive",onClick:()=>{f.setState({nodesDraggable:!m,nodesConnectable:!m,elementsSelectable:!m}),s?.(!m)},title:"toggle interactivity","aria-label":"toggle interactivity"},m?ht.createElement(nf,null):ht.createElement(tf,null)),u):null};af.displayName="Controls";var lf,sf=(0,ht.memo)(af);function cf({color:e,dimensions:t,lineWidth:n}){return ht.createElement("path",{stroke:e,strokeWidth:n,d:`M${t[0]/2} 0 V${t[1]} M0 ${t[1]/2} H${t[0]}`})}function uf({color:e,radius:t}){return ht.createElement("circle",{cx:t,cy:t,r:t,fill:e})}!function(e){e.Lines="lines",e.Dots="dots",e.Cross="cross"}(lf||(lf={}));const df={[lf.Dots]:"#91919a",[lf.Lines]:"#eee",[lf.Cross]:"#e2e2e2"},ff={[lf.Dots]:1,[lf.Lines]:1,[lf.Cross]:6},pf=e=>({transform:e.transform,patternId:`pattern-${e.rfId}`});function hf({id:e,variant:t=lf.Dots,gap:n=20,size:r,lineWidth:o=1,offset:a=2,color:i,style:l,className:s}){const c=(0,ht.useRef)(null),{transform:u,patternId:d}=ha(pf,xt),f=i||df[t],p=r||ff[t],h=t===lf.Dots,m=t===lf.Cross,g=Array.isArray(n)?n:[n,n],b=[g[0]*u[2]||1,g[1]*u[2]||1],y=p*u[2],v=m?[y,y]:b,w=h?[y/a,y/a]:[v[0]/a,v[1]/a];return ht.createElement("svg",{className:mt(["react-flow__background",s]),style:{...l,position:"absolute",width:"100%",height:"100%",top:0,left:0},ref:c,"data-testid":"rf__background"},ht.createElement("pattern",{id:d+e,x:u[0]%b[0],y:u[1]%b[1],width:b[0],height:b[1],patternUnits:"userSpaceOnUse",patternTransform:`translate(-${w[0]},-${w[1]})`},h?ht.createElement(uf,{color:f,radius:y/a}):ht.createElement(cf,{dimensions:v,color:f,lineWidth:o})),ht.createElement("rect",{x:"0",y:"0",width:"100%",height:"100%",fill:`url(#${d+e})`}))}hf.displayName="Background";var mf=(0,ht.memo)(hf);const gf=e=>(0,T.createElement)("path",e),bf=(0,T.forwardRef)((({className:e,isPressed:t,...n},r)=>{const o={...n,className:j(e,{"is-pressed":t})||void 0,"aria-hidden":!0,focusable:!1};return(0,T.createElement)("svg",{...o,ref:r})}));bf.displayName="SVG";const yf=(0,ht.createElement)(bf,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,ht.createElement)(gf,{d:"M19 8h-1V6h-5v2h-2V6H6v2H5c-1.1 0-2 .9-2 2v8c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-8c0-1.1-.9-2-2-2zm.5 10c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5v-8c0-.3.2-.5.5-.5h14c.3 0 .5.2.5.5v8z"}));function vf(e){var t=e.children,n=e.size;return React.createElement("span",{className:"publishpress-icon",style:{width:"".concat(n,"px"),height:"".concat(n,"px"),display:"inline-block"}},t)}function wf(e){var t=e.size,n=void 0===t?24:t;return React.createElement(vf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",role:"img",viewBox:"0 0 24 24",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M2.227 4.857A2.228 2.228 0 000 7.094v7.457c0 1.236 1.001 2.237 2.237 2.237h9.253l4.229 2.355-.962-2.355h7.006c1.236 0 2.237-1 2.237-2.237V7.094c0-1.236-1-2.237-2.237-2.237zm8.08 1.311c.194.002.372.071.535.2a.769.769 0 01.304.56.851.851 0 01-.098.47c-.382.707-.696 1.894-.951 3.542-.246 1.6-.334 2.846-.275 3.739.02.245-.02.46-.118.647a.632.632 0 01-.52.353c-.255.02-.52-.098-.775-.362-.913-.933-1.639-2.326-2.169-4.18a184.085 184.085 0 00-1.413 2.825c-.578 1.11-1.069 1.678-1.481 1.708-.265.02-.49-.206-.687-.677-.5-1.286-1.04-3.768-1.619-7.448-.03-.255.02-.48.157-.657.137-.186.344-.284.618-.304.5-.04.785.196.854.706.304 2.051.638 3.788.991 5.21L5.809 8.41c.196-.373.441-.57.736-.589.431-.03.696.245.804.824.246 1.305.56 2.414.932 3.356.255-2.492.687-4.288 1.295-5.397.148-.274.363-.412.648-.431a.866.866 0 01.084-.004zm3.734 1.063c.167 0 .343.02.53.06.687.146 1.216.52 1.57 1.137.314.53.47 1.168.47 1.933 0 1.011-.254 1.933-.765 2.777-.588.981-1.354 1.472-2.305 1.472-.167 0-.344-.02-.53-.059-.697-.147-1.217-.52-1.57-1.138-.314-.54-.471-1.187-.471-1.943 0-1.01.255-1.933.765-2.767.599-.981 1.364-1.472 2.306-1.472zm6.152 0c.167 0 .343.02.53.06.696.146 1.216.52 1.57 1.137.314.53.47 1.168.47 1.933 0 1.011-.254 1.933-.765 2.777-.588.981-1.354 1.472-2.305 1.472-.167 0-.344-.02-.53-.059-.697-.147-1.217-.52-1.57-1.138-.314-.54-.471-1.187-.471-1.943 0-1.01.255-1.933.765-2.767.599-.981 1.364-1.472 2.306-1.472zm-6.107 1.645c-.307-.002-.606.201-.889.622a3.173 3.173 0 00-.52 1.168c-.05.225-.069.47-.069.716 0 .284.06.589.177.893.147.382.343.589.579.638.245.049.51-.06.795-.315.363-.323.608-.804.745-1.452.05-.225.069-.47.069-.726a2.49 2.49 0 00-.176-.893c-.148-.382-.344-.588-.58-.637a.714.714 0 00-.131-.014zm6.152 0c-.307-.002-.606.201-.889.622a3.173 3.173 0 00-.52 1.168c-.049.225-.069.47-.069.716 0 .284.06.589.177.893.147.382.344.589.579.638.245.049.51-.06.795-.315.363-.323.608-.804.745-1.452.04-.225.07-.47.07-.726a2.49 2.49 0 00-.177-.893c-.148-.382-.344-.588-.58-.637a.714.714 0 00-.131-.014Z"})))}function _f(e){var t=e.size,n=void 0===t?24:t;return React.createElement(vf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 448 512",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M224 256c70.7 0 128-57.3 128-128S294.7 0 224 0 96 57.3 96 128s57.3 128 128 128zm89.6 32h-16.7c-22.2 10.2-46.9 16-72.9 16s-50.6-5.8-72.9-16h-16.7C60.2 288 0 348.2 0 422.4V464c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48v-41.6c0-74.2-60.2-134.4-134.4-134.4z"})))}function Ef(e){var t=e.size,n=void 0===t?24:t;return React.createElement(vf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 512 512",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M256 0c53 0 96 43 96 96v3.6c0 15.7-12.7 28.4-28.4 28.4H188.4c-15.7 0-28.4-12.7-28.4-28.4V96c0-53 43-96 96-96zM41.4 105.4c12.5-12.5 32.8-12.5 45.3 0l64 64c.7 .7 1.3 1.4 1.9 2.1c14.2-7.3 30.4-11.4 47.5-11.4H312c17.1 0 33.2 4.1 47.5 11.4c.6-.7 1.2-1.4 1.9-2.1l64-64c12.5-12.5 32.8-12.5 45.3 0s12.5 32.8 0 45.3l-64 64c-.7 .7-1.4 1.3-2.1 1.9c6.2 12 10.1 25.3 11.1 39.5H480c17.7 0 32 14.3 32 32s-14.3 32-32 32H416c0 24.6-5.5 47.8-15.4 68.6c2.2 1.3 4.2 2.9 6 4.8l64 64c12.5 12.5 12.5 32.8 0 45.3s-32.8 12.5-45.3 0l-63.1-63.1c-24.5 21.8-55.8 36.2-90.3 39.6V240c0-8.8-7.2-16-16-16s-16 7.2-16 16V479.2c-34.5-3.4-65.8-17.8-90.3-39.6L86.6 502.6c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3l64-64c1.9-1.9 3.9-3.4 6-4.8C101.5 367.8 96 344.6 96 320H32c-17.7 0-32-14.3-32-32s14.3-32 32-32H96.3c1.1-14.1 5-27.5 11.1-39.5c-.7-.6-1.4-1.2-2.1-1.9l-64-64c-12.5-12.5-12.5-32.8 0-45.3z"})))}function xf(e){var t=e.size,n=void 0===t?24:t;return React.createElement(vf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",version:"1.1",viewBox:"0 0 16 16",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M8 0c-4.418 0-8 1.119-8 2.5v2c0 1.381 3.582 2.5 8 2.5s8-1.119 8-2.5v-2c0-1.381-3.582-2.5-8-2.5z"}),React.createElement("path",{d:"M8 8.5c-4.418 0-8-1.119-8-2.5v3c0 1.381 3.582 2.5 8 2.5s8-1.119 8-2.5v-3c0 1.381-3.582 2.5-8 2.5z"}),React.createElement("path",{d:"M8 13c-4.418 0-8-1.119-8-2.5v3c0 1.381 3.582 2.5 8 2.5s8-1.119 8-2.5v-3c0 1.381-3.582 2.5-8 2.5z"})))}function Sf(e){var t=e.size,n=void 0===t?24:t;return React.createElement(vf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"none",strokeWidth:"2",viewBox:"0 0 24 24",strokeLinecap:"round",strokeLinejoin:"round",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M16 3h5v5"}),React.createElement("path",{d:"M8 3h-5v5"}),React.createElement("path",{d:"M21 3l-7.536 7.536a5 5 0 0 0 -1.464 3.534v6.93"}),React.createElement("path",{d:"M6 6.01v-.01"}),React.createElement("path",{d:"M8 8.02v-.01"}),React.createElement("path",{d:"M10 10v.01"})))}function kf(e){var t=e.size,n=void 0===t?24:t;return React.createElement(vf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 512 512",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M437.332 80H74.668C51.199 80 32 99.198 32 122.667v266.666C32 412.802 51.199 432 74.668 432h362.664C460.801 432 480 412.802 480 389.333V122.667C480 99.198 460.801 80 437.332 80zM432 170.667L256 288 80 170.667V128l176 117.333L432 128v42.667z"})))}function Rf(e){var t=e.size,n=void 0===t?24:t;return React.createElement(vf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 24 24",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M20 2H4c-1.103 0-2 .894-2 1.992v12.016C2 17.106 2.897 18 4 18h3v4l6.351-4H20c1.103 0 2-.894 2-1.992V3.992A1.998 1.998 0 0 0 20 2zm-6 11H7v-2h7v2zm3-4H7V7h10v2z"})))}function Nf(e){var t=e.size,n=void 0===t?24:t;return React.createElement(vf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 512 512",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M32 464h448L256 48 32 464zm248-64h-48v-48h48v48zm0-80h-48v-96h48v96z"})))}function Cf(e){var t=e.size,n=void 0===t?24:t;return React.createElement(vf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 24 24",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{fill:"none",d:"M0 0h24v24H0z"}),React.createElement("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),React.createElement("path",{d:"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"})))}function Of(e){var t=e.size,n=void 0===t?24:t;return React.createElement(vf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 20 20","aria-hidden":"true",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{fillRule:"evenodd",d:"M4.5 2A1.5 1.5 0 0 0 3 3.5v13A1.5 1.5 0 0 0 4.5 18h11a1.5 1.5 0 0 0 1.5-1.5V7.621a1.5 1.5 0 0 0-.44-1.06l-4.12-4.122A1.5 1.5 0 0 0 11.378 2H4.5Zm2.25 8.5a.75.75 0 0 0 0 1.5h6.5a.75.75 0 0 0 0-1.5h-6.5Zm0 3a.75.75 0 0 0 0 1.5h6.5a.75.75 0 0 0 0-1.5h-6.5Z",clipRule:"evenodd"})))}function Af(e){var t=e.size,n=void 0===t?24:t;return React.createElement(vf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"none",strokeWidth:"0",viewBox:"0 0 24 24",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M14 7C13.4477 7 13 7.44772 13 8V16C13 16.5523 13.4477 17 14 17H18C18.5523 17 19 16.5523 19 16V8C19 7.44772 18.5523 7 18 7H14ZM17 9H15V15H17V9Z",fill:"currentColor"}),React.createElement("path",{d:"M6 7C5.44772 7 5 7.44772 5 8C5 8.55228 5.44772 9 6 9H10C10.5523 9 11 8.55228 11 8C11 7.44772 10.5523 7 10 7H6Z",fill:"currentColor"}),React.createElement("path",{d:"M6 11C5.44772 11 5 11.4477 5 12C5 12.5523 5.44772 13 6 13H10C10.5523 13 11 12.5523 11 12C11 11.4477 10.5523 11 10 11H6Z",fill:"currentColor"}),React.createElement("path",{d:"M5 16C5 15.4477 5.44772 15 6 15H10C10.5523 15 11 15.4477 11 16C11 16.5523 10.5523 17 10 17H6C5.44772 17 5 16.5523 5 16Z",fill:"currentColor"}),React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M4 3C2.34315 3 1 4.34315 1 6V18C1 19.6569 2.34315 21 4 21H20C21.6569 21 23 19.6569 23 18V6C23 4.34315 21.6569 3 20 3H4ZM20 5H4C3.44772 5 3 5.44772 3 6V18C3 18.5523 3.44772 19 4 19H20C20.5523 19 21 18.5523 21 18V6C21 5.44772 20.5523 5 20 5Z",fill:"currentColor"})))}function Pf(e){var t=e.size,n=void 0===t?24:t;return React.createElement(vf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 192 512",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M176 432c0 44.112-35.888 80-80 80s-80-35.888-80-80 35.888-80 80-80 80 35.888 80 80zM25.26 25.199l13.6 272C39.499 309.972 50.041 320 62.83 320h66.34c12.789 0 23.331-10.028 23.97-22.801l13.6-272C167.425 11.49 156.496 0 142.77 0H49.23C35.504 0 24.575 11.49 25.26 25.199z"})))}function Df(e){var t=e.size,n=void 0===t?24:t;return React.createElement(vf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 448 512",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M400 224h-24v-72C376 68.2 307.8 0 224 0S72 68.2 72 152v72H48c-26.5 0-48 21.5-48 48v192c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V272c0-26.5-21.5-48-48-48zm-104 0H152v-72c0-39.7 32.3-72 72-72s72 32.3 72 72v72z"})))}function Tf(e){var t=e.size,n=void 0===t?24:t;return React.createElement(vf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 576 512",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M528.12 301.319l47.273-208C578.806 78.301 567.391 64 551.99 64H159.208l-9.166-44.81C147.758 8.021 137.93 0 126.529 0H24C10.745 0 0 10.745 0 24v16c0 13.255 10.745 24 24 24h69.883l70.248 343.435C147.325 417.1 136 435.222 136 456c0 30.928 25.072 56 56 56s56-25.072 56-56c0-15.674-6.447-29.835-16.824-40h209.647C430.447 426.165 424 440.326 424 456c0 30.928 25.072 56 56 56s56-25.072 56-56c0-22.172-12.888-41.332-31.579-50.405l5.517-24.276c3.413-15.018-8.002-29.319-23.403-29.319H218.117l-6.545-32h293.145c11.206 0 20.92-7.754 23.403-18.681z"})))}function If(e){return If="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},If(e)}function jf(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 Mf(e){for(var t=1;t0,isAdvancedSettingsEnabled:!0,isSingularElementSelected:1===r,getNodeTypeByName:e(ec).getNodeTypeByName,isPro:e(ec).isPro()}})),l=(i.nodeErrors,i.nodeHasErrors),s=i.isAdvancedSettingsEnabled,c=i.isSingularElementSelected,u=i.getNodeTypeByName,d=i.isPro,f=(0,$.useDispatch)(Gd).removeNode,p=(0,$.useDispatch)(ec).openGeneralSidebar,h=u(n.name),m=h.label||n.label||(0,L.__)("Node","post-expirator"),g=(null==h?void 0:h.className)||"react-flow__node-genericNode",b=null;h.handleSchema&&h.handleSchema.target&&(b=h.handleSchema.target.map((function(e){return React.createElement(Ti,{key:e.id+"_target",type:"target",position:Xa.Top,id:e.id,style:{left:e.left},isConnectable:r,className:"handle-target-"+e.id})})));var y=null,v=null;h.handleSchema&&h.handleSchema.source&&(y=h.handleSchema.source.map((function(e){return React.createElement(Ti,{key:e.id+"_source",type:"source",position:Xa.Bottom,id:e.id,style:{left:e.left},isConnectable:r,className:"handle-source-"+e.id})})),v=h.handleSchema.source.map((function(e){return React.createElement("div",{key:e.id+"handleArea",className:"react-flow__node-handle-name handle-area-source-"+e.id},e.label)})));var w=(0,L.__)("Step","post-expirator");"action"===n.elementaryType?w=(0,L.__)("Action","post-expirator"):"advanced"===n.elementaryType?w=(0,L.__)("Advanced","post-expirator"):"trigger"===n.elementaryType&&(w=(0,L.__)("Trigger","post-expirator"));var _=[];return a||(a=React.createElement(zf,{size:8})),React.createElement(React.Fragment,null,o&&c&&React.createElement(React.Fragment,null,React.createElement(M.Popover,{placement:"top-start",offset:14},React.createElement(M.Toolbar,{className:"components-accessible-toolbar block-editor-block-contextual-toolbar react-flow__node-toolbar"},React.createElement(M.ToolbarGroup,null,React.createElement(M.ToolbarButton,{icon:"trash",label:(0,L.__)("Delete","post-expirator"),onClick:function(){f(t)}}))))),React.createElement("div",{className:"react-flow__node-body "+g,onDoubleClick:function(){c&&p(Wf)}},b,React.createElement("div",{className:"react-flow__node-top"},a,w),React.createElement("div",{className:"react-flow__node-inner-body"},(l||h.isProFeature&&!d)&&React.createElement("div",{className:"react-flow__node-marker-wrapper"},h.isProFeature&&!d&&React.createElement("div",{className:"react-flow__node-pro-badge",title:(0,L.__)("Currently this step is being skipped. Upgrade to Pro to unlock this feature.","post-expirator")},React.createElement(Lf,{icon:"lock",size:8})),l&&React.createElement("div",{className:"react-flow__node-error",title:(0,L.__)("This node has errors","post-expirator")},React.createElement(Lf,{icon:"exclamation",size:8}))),React.createElement("div",{className:"react-flow__node-header"},React.createElement(Lf,{icon:h.icon.src,size:14}),React.createElement("div",{className:"react-flow__node-label"},m)),s&&_.length>0&&React.createElement("div",{className:"react-flow__node-content"},React.createElement("table",null,React.createElement("tbody",null,_.map((function(e){return React.createElement("tr",{key:"attribute_"+e.id},React.createElement("th",null,e.label),React.createElement("td",null,e.value))})))))),React.createElement("div",{className:"react-flow__node-handle-area"},v),y))}));const Bf=Gf;var Vf=i(3018);function Hf(e){var t=e.size,n=void 0===t?24:t;return React.createElement(vf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 24 24",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("polygon",{fill:"none",strokeWidth:"2",points:"4 14 10 14 7 23 9 23 20 9 14 9 18 1 7 1"})))}function Uf(){return Uf=Object.assign?Object.assign.bind():function(e){for(var t=1;t0})(e)||i(e.id,"no-incomers",(0,L.__)("This step requires a connection from a previous step.","post-expirator"));break;case"hasOutgoingConnection":(function(e){var t=function(e){var t=(0,$.select)(Gd).getNodes(),n=(0,$.select)(Gd).getEdges();return e?((e,t,n)=>{if(!ui(e))return[];const r=n.filter((t=>t.source===e.id)).map((e=>e.target));return t.filter((e=>r.includes(e.id)))})(e,t,n):[]}(e);return(null==t?void 0:t.length)>0})(e)||i(e.id,"no-outgoers",(0,L.__)("This step requires a connection to a following step.","post-expirator"));break;case"hasIncomerOfName":var n=mc(e),r=!1;if(0===n.length)r=!0;else{var o=!1;n.forEach((function(e){var n;(null===(n=e.data)||void 0===n?void 0:n.name)===t.name&&(o=!0)})),r=!o}r&&i(e.id,"parent-name",t.message)}})),null!=d&&null!==(a=d.settings)&&void 0!==a&&a.rules&&d.settings.rules.forEach((function(t){for(var n,r=t.rule,o=(null==t?void 0:t.field)||"",a=(null==o?void 0:o.split("."))||[],l=(null==t?void 0:t.label)||(null===(n=u.find((function(e){return null==e?void 0:e.fields.find((function(e){return e.name===a[0]}))})))||void 0===n?void 0:n.label),s=c,d=0;de.length)&&(t=e.length);for(var n=0,r=Array(t);n{setTimeout((()=>e(Date.now())),0)}:window.requestIdleCallback;function mp(e=null){if(!e){if("undefined"==typeof window)return!1;e=window}const{platform:t}=e.navigator;return-1!==t.indexOf("Mac")||["iPad","iPhone"].includes(t)}const gp="alt",bp="ctrl",yp="meta",vp="shift";function _p(e){return e.length<2?e.toUpperCase():e.charAt(0).toUpperCase()+e.slice(1)}function Ep(e,t){return Object.fromEntries(Object.entries(e).map((([e,n])=>[e,t(n)])))}const xp={primary:e=>e()?[yp]:[bp],primaryShift:e=>e()?[vp,yp]:[bp,vp],primaryAlt:e=>e()?[gp,yp]:[bp,gp],secondary:e=>e()?[vp,gp,yp]:[bp,vp,gp],access:e=>e()?[bp,gp]:[vp,gp],ctrl:()=>[bp],alt:()=>[gp],ctrlShift:()=>[bp,vp],shift:()=>[vp],shiftAlt:()=>[vp,gp],undefined:()=>[]},Sp=Ep(xp,(e=>(t,n=mp)=>[...e(n),t.toLowerCase()].join("+"))),kp=Ep(xp,(e=>(t,n=mp)=>{const r=n(),o={[gp]:r?"⌥":"Alt",[bp]:r?"⌃":"Ctrl",[yp]:"⌘",[vp]:r?"⇧":"Shift"};return[...e(n).reduce(((e,t)=>{var n;const a=null!==(n=o[t])&&void 0!==n?n:t;return r?[...e,a]:[...e,a,"+"]}),[]),_p(t)]})),Rp=Ep(kp,(e=>(t,n=mp)=>e(t,n).join(""))),Np=Ep(xp,(e=>(t,n=mp)=>{const r=n(),o={[vp]:"Shift",[yp]:r?"Command":"Control",[bp]:"Control",[gp]:r?"Option":"Alt",",":(0,L.__)("Comma"),".":(0,L.__)("Period"),"`":(0,L.__)("Backtick"),"~":(0,L.__)("Tilde")};return[...e(n),t].map((e=>{var t;return _p(null!==(t=o[e])&&void 0!==t?t:e)})).join(r?" ":" + ")})),Cp=Ep(xp,(e=>(t,n,r=mp)=>{const o=e(r),a=function(e){return[gp,bp,yp,vp].filter((t=>e[`${t}Key`]))}(t),i={Comma:",",Backslash:"\\",IntlRo:"\\",IntlYen:"\\"},l=o.filter((e=>!a.includes(e))),s=a.filter((e=>!o.includes(e)));if(l.length>0||s.length>0)return!1;let c=t.key.toLowerCase();return n?(t.altKey&&1===n.length&&(c=String.fromCharCode(t.keyCode).toLowerCase()),t.shiftKey&&1===n.length&&i[t.code]&&(c=i[t.code]),"del"===n&&(n="delete"),c===n.toLowerCase()):o.includes(c)}));function Op(e="polite"){const t=document.createElement("div");t.id=`a11y-speak-${e}`,t.className="a11y-speak-region",t.setAttribute("style","position: absolute;margin: -1px;padding: 0;height: 1px;width: 1px;overflow: hidden;clip: rect(1px, 1px, 1px, 1px);-webkit-clip-path: inset(50%);clip-path: inset(50%);border: 0;word-wrap: normal !important;"),t.setAttribute("aria-live",e),t.setAttribute("aria-relevant","additions text"),t.setAttribute("aria-atomic","true");const{body:n}=document;return n&&n.appendChild(t),t}let Ap="";var Pp;function Dp(e,t){!function(){const e=document.getElementsByClassName("a11y-speak-region"),t=document.getElementById("a11y-speak-intro-text");for(let t=0;t]+>/g," "),Ap===e&&(e+=" "),Ap=e,e}(e);const n=document.getElementById("a11y-speak-intro-text"),r=document.getElementById("a11y-speak-assertive"),o=document.getElementById("a11y-speak-polite");r&&"assertive"===t?r.textContent=e:o&&(o.textContent=e),n&&n.removeAttribute("hidden")}function Tp(){return Tp=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=Array(t);n{let t=function(e,t){const n=[];for(let r=0;r{const e=new Map;let t=!1;const n=r=>{for(const[t,n]of e)if(e.delete(t),n(),"number"==typeof r||r.timeRemaining()<=0)break;0!==e.size?hp(n):t=!1};return{add:(r,o)=>{e.set(r,o),t||(t=!0,hp(n))},flush:t=>{const n=e.get(t);return void 0!==n&&(e.delete(t),n(),!0)},cancel:t=>e.delete(t),reset:()=>{e.clear(),t=!1}}})();for(let r=t.length;r{(0,T.flushSync)((()=>{o((t=>[...t,...e.slice(r,r+n)]))}))}));return()=>a.reset()}),[e]),r}(n);return React.createElement(Hp,null,React.createElement("div",null,a&&i.length>0&&React.createElement(Zp,{title:(0,L._x)("Most used","nodes","post-expirator")},React.createElement(Qp,{items:i,onSelect:s,onHover:o,label:(0,L._x)("Most used","nodes","post-expirator")})),lp()(c,(function(e){var t=l[e.name];return t&&t.length?React.createElement(Zp,{key:e.name,title:e.label,icon:e.icon},React.createElement(Qp,{items:t,onSelect:s,onHover:o,label:e.label})):null}))))},eh=i(2193),th=i.n(eh);const nh=(e,t,n)=>{let r,o,a,i,l,s=0,c=0,u=!1,d=!1,f=!0;function p(t){const n=r,i=o;return r=void 0,o=void 0,c=t,a=e.apply(i,n),a}function h(e,t){i=setTimeout(e,t)}function m(e){return e-(l||0)}function g(e){const n=m(e);return void 0===l||n>=t||n<0||d&&e-c>=s}function b(){const e=Date.now();if(g(e))return v(e);h(b,function(e){const n=m(e),r=e-c,o=t-n;return d?Math.min(o,s-r):o}(e))}function y(){i=void 0}function v(e){return y(),f&&r?p(e):(r=o=void 0,a)}function w(){return void 0!==i}function _(...e){const n=Date.now(),i=g(n);if(r=e,o=this,l=n,i){if(!w())return function(e){return c=e,h(b,t),u?p(e):a}(l);if(d)return h(b,t),p(l)}return w()||h(b,t),a}return n&&(u=!!n.leading,d="maxWait"in n,void 0!==n.maxWait&&(s=Math.max(n.maxWait,t)),f="trailing"in n?!!n.trailing:f),_.cancel=function(){void 0!==i&&clearTimeout(i),c=0,y(),r=l=o=void 0},_.flush=function(){return w()?v(Date.now()):a},_.pending=w,_};var rh=i(828),oh=i.n(rh),ah=i(4889),ih=i.n(ah),lh=i(7309),sh=i.n(lh),ch=i(6645),uh=i.n(ch);function dh(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,l=[],s=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return l}}(e,t)||fh(e,t)||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.")}()}function fh(e,t){if(e){if("string"==typeof e)return ph(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)?ph(e,t):void 0}}function ph(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n0&&void 0!==arguments[0]?arguments[0]:"";return(e=(e=oh()(e)).replace(/^\//,"")).toLowerCase()}var wh=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return uh()(vh(e))};function _h(e,t){var n,r,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},a=o.getName,i=void 0===a?hh:a,l=o.getTitle,s=void 0===l?mh:l,c=o.getDescription,u=void 0===c?gh:c,d=o.getKeywords,f=void 0===d?bh:d,p=o.getCategory,h=void 0===p?yh:p,m=i(e),g=s(e),b=u(e),y=f(e),v=h(e),w=vh(t),_=vh(g),E=0;if(w===_)E+=30;else if(_.startsWith(w))E+=20;else{var x=[m,g,b].concat(function(e){return function(e){if(Array.isArray(e))return ph(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||fh(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.")}()}(y),[v]).join(" ");0===(n=uh()(w),r=x,ih()(n,wh(r),(function(e,t){return t.includes(e)}))).length&&(E+=10)}return 0!==E&&m.startsWith("core/")&&E++,E}const Eh=(0,T.forwardRef)((function({icon:e,size:t=24,...n},r){return(0,T.cloneElement)(e,{width:t,height:t,...n,ref:r})}));function xh(){return React.createElement("div",{className:"block-editor-inserter__no-results"},React.createElement(Eh,{className:"block-editor-inserter__no-results-icon",icon:yf}),React.createElement("p",null,(0,L.__)("No results found.","post-expirator")))}function Sh(e){return function(e){if(Array.isArray(e))return kh(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return kh(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)?kh(e,t):void 0}}(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 kh(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);nnh(e,500,n),a=[e,500,n],i=(0,ht.useState)((function(){return{inputs:a,result:o()}}))[0],l=(0,ht.useRef)(!0),s=(0,ht.useRef)(i),c=l.current||Boolean(a&&s.current.inputs&&function(e,t){if(e.length!==t.length)return!1;for(var n=0;n()=>r.cancel()),[r]),r}(Dp),c=(0,$.useSelect)((function(e){var t=e(ec).getActionNodes(),n=e(ec).getActionCategories(),r=e(ec).getTriggerNodes(),o=e(ec).getTriggerCategories(),a=e(ec).getAdvancedNodes(),i=e(ec).getAdvancedCategories();return{nodeTypes:l&&l.length?[].concat(Sh(t.filter((function(e){return l.includes(e.elementaryType)}))),Sh(r.filter((function(e){return l.includes(e.elementaryType)}))),Sh(a.filter((function(e){return l.includes(e.elementaryType)})))):[].concat(Sh(r),Sh(t),Sh(a)),nodeTypeCategories:[].concat(Sh(n),Sh(o),Sh(i))}})),u=c.nodeTypes,d=c.nodeTypeCategories,f=(0,T.useMemo)((function(){var e,n,r,a=(e=pp()(u,["frecency"],["desc"]),n=d,0===wh(r=t).length?e:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(0===wh(t).length)return e;var r=e.map((function(e){return[e,_h(e,t,n)]})).filter((function(e){return dh(e,2)[1]>0}));return r.sort((function(e,t){var n=dh(e,2)[1];return dh(t,2)[1]-n})),r.map((function(e){return dh(e,1)[0]}))}(e,r,{getCategory:function(e){var t;return null===(t=sh()(n,{name:e.category}))||void 0===t?void 0:t.label},getName:function(e){return e.name},getTitle:function(e){return e.label},getDescription:function(e){return e.description},getKeywords:function(e){return e.keywords||[]}}));return void 0!==o?a.slice(0,o):a}),[t,u,d,o]);(0,T.useEffect)((function(){if(t){var e=f.length,n=(0,L.sprintf)((0,L._n)("%d result found.","%d results found.",e,"post-expirator"),e);s(n)}}),[t,s,f]);var p=!th()(f);return React.createElement(Hp,null,!p&&React.createElement(xh,null),!!p&&React.createElement(Zp,{title:React.createElement(M.VisuallyHidden,null,(0,L.__)("Nodes","post-expirator"))},React.createElement(Qp,{items:f,onSelect:n,onHover:r,label:(0,L.__)("Nodes","post-expirator"),isDraggable:i})))};function Nh(e){var t=e.size,n=void 0===t?24:t;return React.createElement(vf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"none",strokeWidth:"2",viewBox:"0 0 24 24",strokeLinecap:"round",strokeLinejoin:"round",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("line",{x1:"12",y1:"5",x2:"12",y2:"19"}),React.createElement("line",{x1:"5",y1:"12",x2:"19",y2:"12"})))}function Ch(e){return function(e){if(Array.isArray(e))return Ph(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Ah(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 Oh(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,l=[],s=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return l}}(e,t)||Ah(e,t)||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.")}()}function Ah(e,t){if(e){if("string"==typeof e)return Ph(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)?Ph(e,t):void 0}}function Ph(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n{r.setState({onViewportChangeStart:e})}),[e]),(0,ht.useEffect)((()=>{r.setState({onViewportChange:t})}),[t]),(0,ht.useEffect)((()=>{r.setState({onViewportChangeEnd:n})}),[n])}({onEnd:function(){F()}}),(0,T.useEffect)((function(){c&&I(c)}),[c]);var W=(0,T.useCallback)((function(e){m(Al(e,n)),F()}),[n]),G=(0,T.useCallback)((function(e){g(Pl(e,r)),F()}),[r]),B=(0,T.useCallback)((function(e,t){g(((e,t,n,r={shouldReplaceId:!0})=>(console.warn("[DEPRECATED] `updateEdge` is deprecated. Instead use `reconnectEdge` https://reactflow.dev/api-reference/utils/reconnect-edge"),((e,t,n,r={shouldReplaceId:!0})=>{const{id:o,...a}=e;if(!t.source||!t.target)return n;if(!n.find((e=>e.id===o)))return n;const i={...a,id:r.shouldReplaceId?di(t):o,source:t.source,target:t.target,sourceHandle:t.sourceHandle,targetHandle:t.targetHandle};return n.filter((e=>e.id!==o)).concat(i)})(e,t,n,r)))(e,t,r)),F()}),[r]),V=(0,T.useCallback)((function(e){e.source!==e.target&&(e=Wh(Wh({},e),{},{type:"genericEdge",id:"".concat(e.source,"-").concat(e.sourceHandle,"-").concat(e.target,"-").concat(e.targetHandle),markerEnd:{type:qa.ArrowClosed}}),g(pi(e,r)),F())}),[r]),H=(0,T.useCallback)((function(e,t){var n=t.nodeId,r=t.handleId,o=t.handleType;j.current=n,S({sourceId:n,handleId:r,handleType:o})}),[]),U=(0,T.useCallback)((function(e){if(e.stopPropagation(),j.current){if(e.target.classList.contains("react-flow__pane")&&!p){var t=e.target.offsetWidth,n=D.screenToFlowPosition({x:t/2,y:0}),r=D.screenToFlowPosition({x:e.clientX-n.x,y:e.clientY}),o={id:wc(),type:"nodePlaceholder",data:{name:"core/node-placeholder",elementaryType:A},position:r};b(o)}N(!1)}}),[D.screenToFlowPosition,p,b]),q=(0,T.useCallback)((function(e){return N(!0),!0}),[]),X=(0,T.useCallback)((function(e){e.preventDefault(),e.dataTransfer.dropEffect="move"}),[]),Y=(0,T.useCallback)((function(e){e.preventDefault();var t=D.screenToFlowPosition({x:e.clientX,y:e.clientY}),n=e.dataTransfer.getData(R);_c({item:JSON.parse(n),position:t,reactFlowInstance:D}),x()}),[D,n]),K=(0,T.useCallback)((function(){F()})),Q=(0,T.useCallback)((function(){F()})),Z=(0,T.useCallback)((function(){D.fitView()}),[D]);!function({onChange:e}){const t=ma();(0,ht.useEffect)((()=>{const n=[...t.getState().onSelectionChange,e];return t.setState({onSelectionChange:n}),()=>{const n=t.getState().onSelectionChange.filter((t=>t!==e));t.setState({onSelectionChange:n})}}),[e])}({onChange:function(e){var t=e.nodes,n=e.edges;if(t.length>0&&"triggerPlaceholder"===t[0].type)return y([]),void v([]);y(t.map((function(e){return e.id}))),v(n.map((function(e){return e.id}))),l&&(0===t.length&&0===n.length&&C(Ff),(t.length>0||n.length>0)&&C(Wf))}});var J=(0,T.useCallback)((function(){O((0,L.__)("Applying auto layout.","post-expirator"),{isDismissible:!0,type:"snackbar"}),Promise.all([i.e(845),i.e(251)]).then(i.bind(i,7632)).then((function(e){(0,e.useLayoutedElements)({nodes:n,edges:r,onLayout:function(e,t){m(e),g(t)},onAnimationFrame:function(){Z(),F()}})({direction:Vf.rx}),O((0,L.__)("Auto layout applied.","post-expirator"),{isDismissible:!0,type:"snackbar"})}))}),[n,r,Z,F]);return(0,T.useEffect)((function(){T.Platform.select({web:!0,native:!1})&&C(Ff)}),[]),(0,T.useEffect)((function(){if("null/undefined"===s){var e=o.length>0||a.length>0?Wf:Ff;C(e)}}),[s,a,o]),React.createElement("div",{className:"reactflow-wrapper",ref:P},React.createElement(Lh,{onLayout:J}),!f&&React.createElement(Gs,{nodes:n,edges:r,onNodesChange:W,onEdgesChange:G,onEdgeUpdate:B,onConnectStart:H,onConnectEnd:U,onConnect:V,isValidConnection:q,onDrop:Y,onDragOver:X,nodesDraggable:!0,proOptions:{hideAttribution:!1},fitView:Z,style:{backgroundColor:"#ffffff"},snapToGrid:!0,snapGrid:[10,10],nodeTypes:M,edgeTypes:z,onNodesDelete:K,onEdgesDelete:Q,connectionLineStyle:{stroke:"#c2c2c2",strokeWidth:2,strokeDasharray:"3,4"}},u&&React.createElement(Qd,{pannable:!0,zoomable:!0,nodeColor:function(e){if("generic"===e.type)return"#FFCC00"}}),d&&React.createElement(sf,null),React.createElement(mf,{variant:"dots",color:"#ccc",gap:10})),React.createElement(Jf,null))},Vh=i(7612),Hh=i.n(Vh);function Uh(){var e=(0,$.useDispatch)("core/notices").removeNotice,t=(0,$.useSelect)((function(e){return e("core/notices").getNotices()}),[]),n=Hh()(t,{isDismissible:!0,type:"default"}),r=Hh()(t,{isDismissible:!1,type:"default"}),o=Hh()(t,{type:"snackbar"});return React.createElement(React.Fragment,null,React.createElement(M.NoticeList,{notices:r,className:"workflow-editor-notices__notice-list"}),React.createElement(M.NoticeList,{notices:n,className:"workflow-editor-notices__notice-list",onRemove:e}),React.createElement(M.SnackbarList,{notices:o,className:"workflow-editor-notices__snackbar-list",onRemove:e}))}var qh=function(e){return React.createElement(React.Fragment,null,React.createElement(Uh,null),React.createElement(Bh,null))},Xh=function(e){return React.createElement("div",null,"PublishPress Future Workflow Editor")};const Yh=new Map;const Kh={huge:1440,wide:1280,large:960,medium:782,small:600,mobile:480},Qh={">=":"min-width","<":"max-width"},Zh={">=":(e,t)=>t>=e,"<":(e,t)=>t=")=>{const n=(0,T.useContext)(Jh),r=function(e){const t=(0,T.useMemo)((()=>{const t=function(e){if(!e)return null;let t=Yh.get(e);return t||("undefined"!=typeof window&&"function"==typeof window.matchMedia?(t=window.matchMedia(e),Yh.set(e,t),t):null)}(e);return{subscribe:e=>t?(t.addEventListener?.("change",e),()=>{t.removeEventListener?.("change",e)}):()=>{},getValue(){var e;return null!==(e=t?.matches)&&void 0!==e&&e}}}),[e]);return(0,T.useSyncExternalStore)(t.subscribe,t.getValue,(()=>!1))}(!n&&`(${Qh[t]}: ${Kh[e]}px)`||void 0);return n?Zh[t](Kh[e],n):r};em.__experimentalWidthProvider=Jh.Provider;const tm=em,nm=(0,ht.createElement)(bf,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,ht.createElement)(gf,{d:"M11 12.5V17.5H12.5V12.5H17.5V11H12.5V6H11V11H6V12.5H11Z"})),rm=(0,ht.createElement)(bf,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,ht.createElement)(gf,{d:"M18 5.5H6a.5.5 0 00-.5.5v3h13V6a.5.5 0 00-.5-.5zm.5 5H10v8h8a.5.5 0 00.5-.5v-7.5zm-10 0h-3V18a.5.5 0 00.5.5h2.5v-8zM6 4h12a2 2 0 012 2v12a2 2 0 01-2 2H6a2 2 0 01-2-2V6a2 2 0 012-2z"})),om=(0,ht.createElement)(bf,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24"},(0,ht.createElement)(gf,{d:"M20 10c0-5.51-4.49-10-10-10C4.48 0 0 4.49 0 10c0 5.52 4.48 10 10 10 5.51 0 10-4.48 10-10zM7.78 15.37L4.37 6.22c.55-.02 1.17-.08 1.17-.08.5-.06.44-1.13-.06-1.11 0 0-1.45.11-2.37.11-.18 0-.37 0-.58-.01C4.12 2.69 6.87 1.11 10 1.11c2.33 0 4.45.87 6.05 2.34-.68-.11-1.65.39-1.65 1.58 0 .74.45 1.36.9 2.1.35.61.55 1.36.55 2.46 0 1.49-1.4 5-1.4 5l-3.03-8.37c.54-.02.82-.17.82-.17.5-.05.44-1.25-.06-1.22 0 0-1.44.12-2.38.12-.87 0-2.33-.12-2.33-.12-.5-.03-.56 1.2-.06 1.22l.92.08 1.26 3.41zM17.41 10c.24-.64.74-1.87.43-4.25.7 1.29 1.05 2.71 1.05 4.25 0 3.29-1.73 6.24-4.4 7.78.97-2.59 1.94-5.2 2.92-7.78zM6.1 18.09C3.12 16.65 1.11 13.53 1.11 10c0-1.3.23-2.48.72-3.59C3.25 10.3 4.67 14.2 6.1 18.09zm4.03-6.63l2.58 6.98c-.86.29-1.76.45-2.71.45-.79 0-1.57-.11-2.29-.33.81-2.38 1.62-4.74 2.42-7.1z"}));function am(e){var t=e.showTooltip,n=(0,$.useSelect)((function(e){var t=e(Gd).getPostType;return{isActive:(0,e(ec).isFeatureActive)("fullscreenMode"),postType:t()}}),[]),r=n.isActive,o=n.postType;if(!r||!o)return null;var a=React.createElement(M.Icon,{size:"36px",icon:om});return React.createElement(M.__unstableMotion.div,{whileHover:"expand",className:"editor-header__back-button"},React.createElement(M.Button,{className:"edit-post-fullscreen-mode-close",href:(0,Du.addQueryArgs)("edit.php",{post_type:p}),label:(0,L.__)("Back","post-expirator"),showTooltip:t},a))}const im=(0,ht.createElement)(bf,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,ht.createElement)(gf,{d:"M13 19h-2v-2h2v2zm0-6h-2v-2h2v2zm0-6h-2V5h2v2z"}));function lm(e){return lm="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},lm(e)}function sm(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 cm(e){for(var t=1;t0||e.offsetHeight>0||e.getClientRects().length>0}function Em(e,{sequential:t=!1}={}){const n=e.querySelectorAll(function(e){return[e?'[tabindex]:not([tabindex^="-"])':"[tabindex]","a[href]","button:not([disabled])",'input:not([type="hidden"]):not([disabled])',"select:not([disabled])","textarea:not([disabled])",'iframe:not([tabindex^="-"])',"object","embed","area[href]","[contenteditable]:not([contenteditable=false])"].join(",")}(t));return Array.from(n).filter((e=>{if(!_m(e))return!1;const{nodeName:t}=e;return"AREA"!==t||function(e){const t=e.closest("map[name]");if(!t)return!1;const n=e.ownerDocument.querySelector('img[usemap="#'+t.name+'"]');return!!n&&_m(n)}(e)}))}function xm(e){const t=e.getAttribute("tabindex");return null===t?0:parseInt(t,10)}function Sm(e){return-1!==xm(e)}function km(e,t){return{element:e,index:t}}function Rm(e){return e.element}function Nm(e,t){const n=xm(e.element),r=xm(t.element);return n===r?e.index-t.index:n-r}function Cm(e){return e.filter(Sm).map(km).sort(Nm).map(Rm).reduce(function(){const e={};return function(t,n){const{nodeName:r,type:o,checked:a,name:i}=n;if("INPUT"!==r||"radio"!==o||!i)return t.concat(n);const l=e.hasOwnProperty(i);if(!a&&l)return t;if(l){const n=e[i];t=t.filter((e=>e!==n))}return e[i]=n,t.concat(n)}}(),[])}function Om(e){return Cm(Em(e))}function Am(e){return Cm(Em(e.ownerDocument.body)).reverse().find((t=>e.compareDocumentPosition(t)&e.DOCUMENT_POSITION_PRECEDING))}function Pm(e){return Cm(Em(e.ownerDocument.body)).find((t=>e.compareDocumentPosition(t)&e.DOCUMENT_POSITION_FOLLOWING))}const Dm={focusable:c,tabbable:u};var Tm=["children","focusOnMount","__experimentalInitialIndex","__experimentalOnIndexChange"];function Im(){return Im=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=Array(t);n{t.current=e}),[e]),t.current}(0,T.forwardRef)((function(e,t){var n=(0,$.useSelect)((function(e){return!1}),[]),r=(0,$.useDispatch)(Gd).undo;return React.createElement(M.Button,Wm({},e,{ref:t,icon:(0,L.isRTL)()?Fm:zm,label:(0,L.__)("Undo","post-expirator"),shortcut:Rp.primary("z"),"aria-disabled":!n,onClick:n?r:void 0,className:"editor-history__undo"}))})),(0,T.forwardRef)((function(e,t){var n=(0,$.useSelect)((function(e){return!1}),[]),r=(0,$.useDispatch)(Gd).redo;return React.createElement(M.Button,Gm({},e,{ref:t,icon:(0,L.isRTL)()?zm:Fm,label:(0,L.__)("Redo","post-expirator"),shortcut:Rp.primaryShift("z"),"aria-disabled":!n,onClick:n?r:void 0,className:"editor-history__redo"}))}));const Vm=(0,ht.createElement)(bf,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,ht.createElement)(gf,{d:"M17.3 10.1c0-2.5-2.1-4.4-4.8-4.4-2.2 0-4.1 1.4-4.6 3.3h-.2C5.7 9 4 10.7 4 12.8c0 2.1 1.7 3.8 3.7 3.8h9c1.8 0 3.2-1.5 3.2-3.3.1-1.6-1.1-2.9-2.6-3.2zm-.5 5.1h-4v-2.4L14 14l1-1-3-3-3 3 1 1 1.2-1.2v2.4H7.7c-1.2 0-2.2-1.1-2.2-2.3s1-2.4 2.2-2.4H9l.3-1.1c.4-1.3 1.7-2.2 3.2-2.2 1.8 0 3.3 1.3 3.3 2.9v1.3l1.3.2c.8.1 1.4.9 1.4 1.8 0 1-.8 1.8-1.7 1.8z"})),Hm=(0,ht.createElement)(bf,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,ht.createElement)(gf,{d:"M17.3 10.1c0-2.5-2.1-4.4-4.8-4.4-2.2 0-4.1 1.4-4.6 3.3h-.2C5.7 9 4 10.7 4 12.8c0 2.1 1.7 3.8 3.7 3.8h9c1.8 0 3.2-1.5 3.2-3.3.1-1.6-1.1-2.9-2.6-3.2zm-.5 5.1h-9c-1.2 0-2.2-1.1-2.2-2.3s1-2.4 2.2-2.4h1.3l.3-1.1c.4-1.3 1.7-2.2 3.2-2.2 1.8 0 3.3 1.3 3.3 2.9v1.3l1.3.2c.8.1 1.4.9 1.4 1.8-.1 1-.9 1.8-1.8 1.8z"}));function Um(e){return Um="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},Um(e)}function qm(e,t,n){return(t=function(e){var t=function(e){if("object"!=Um(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Um(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Um(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Xm(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);ne.length)&&(t=e.length);for(var n=0,r=Array(t);n[ug(e,t),...pg(e,t)].filter(Boolean)),((e,t)=>[e[t]])),mg=(0,$.createSelector)(((e,t)=>hg(e,t).map((e=>cg(e,"raw")))),((e,t)=>[e[t]])),gg=(0,$.createSelector)(((e,t)=>Object.entries(e).filter((([,e])=>e.category===t)).map((([e])=>e))),(e=>[e])),bg=(0,$.createReduxStore)("core/keyboard-shortcuts",{reducer:function(e={},t){switch(t.type){case"REGISTER_SHORTCUT":return{...e,[t.name]:{category:t.category,keyCombination:t.keyCombination,aliases:t.aliases,description:t.description}};case"UNREGISTER_SHORTCUT":const{[t.name]:n,...r}=e;return r}return e},actions:d,selectors:f});(0,$.register)(bg);const yg=new Set,vg=e=>{for(const t of yg)t(e)},wg=(0,T.createContext)({add:e=>{0===yg.size&&document.addEventListener("keydown",vg),yg.add(e)},delete:e=>{yg.delete(e),0===yg.size&&document.removeEventListener("keydown",vg)}});function _g(e,t,{isDisabled:n=!1}={}){const r=(0,T.useContext)(wg),o=function(){const{getAllShortcutKeyCombinations:e}=(0,$.useSelect)(bg);return function(t,n){return e(t).some((({modifier:e,character:t})=>Cp[e](n,t)))}}(),a=(0,T.useRef)();(0,T.useEffect)((()=>{a.current=t}),[t]),(0,T.useEffect)((()=>{if(!n)return r.add(t),()=>{r.delete(t)};function t(t){o(e,t)&&a.current(t)}}),[e,n,r])}const{Provider:Eg}=wg;var xg="publishpress-future/workflow-editor/toggle-fullscreen",Sg="publishpress-future/workflow-editor/fit-view",kg="publishpress-future/workflow-editor/toggle-inserter",Rg="publishpress-future/workflow-editor/auto-layout",Ng="publishpress-future/workflow-editor/toggle-sidebar",Cg="publishpress-future/workflow-editor/toggle-developer-mode",Og="publishpress-future/workflow-editor/toggle-advanced-settings",Ag=function(){var e=(0,$.useDispatch)(bg).registerShortcut,t=(0,$.useDispatch)(ec).toggleFeature;(0,T.useEffect)((function(){e({name:xg,category:"global",description:"Toggle fullscreen mode",keyCombination:{modifier:"secondary",character:"f"}}),e({name:Cg,category:"global",description:"Toggle developer mode",keyCombination:{modifier:"secondary",character:"d"}}),e({name:Og,category:"global",description:"Toggle advanced settings",keyCombination:{modifier:"secondary",character:"a"}}),e({name:Sg,category:"global",description:"Fit view",keyCombination:{modifier:"secondary",character:"v"}}),e({name:kg,category:"global",description:"Toggle inserter",keyCombination:{modifier:"secondary",character:"i"}}),e({name:Rg,category:"global",description:"Auto layout",keyCombination:{modifier:"secondary",character:"l"}}),e({name:Ng,category:"global",description:"Toggle sidebar",keyCombination:{modifier:"secondary",character:"s"}})}),[]),_g(xg,(function(){t(h)})),_g(Cg,(function(){t(b)}));var n=bl();return _g(Sg,(function(){n.fitView()})),_g(kg,(function(){t(g)})),_g(Rg,(function(){var e=new CustomEvent(Vf.Ml,{detail:{direction:Vf.wD}});document.dispatchEvent(e)})),_g(Ng,(function(){})),_g(Og,(function(){t(v)})),null};const Pg=(0,ht.createElement)(bf,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,ht.createElement)(gf,{d:"M13 11.8l6.1-6.3-1-1-6.1 6.2-6.1-6.2-1 1 6.1 6.3-6.5 6.7 1 1 6.5-6.6 6.5 6.6 1-1z"})),Dg=function(){return function(){const e=(0,T.useRef)();return(0,T.useCallback)((t=>{t?e.current=(e=>{function t(t){const{key:n,shiftKey:r,target:o}=t;if("Tab"!==n)return;const a=r?"findPrevious":"findNext",i=Dm.tabbable[a](o)||null;if(o.contains(i))return t.preventDefault(),void i?.focus();if(e.contains(i))return;const l=r?"append":"prepend",{ownerDocument:s}=e,c=s.createElement("div");c.tabIndex=-1,e[l](c),c.addEventListener("blur",(()=>e.removeChild(c))),c.focus()}return e.addEventListener("keydown",t),()=>{e.removeEventListener("keydown",t)}})(t):e.current&&e.current()}),[])}()};let Tg=null;const Ig=["button","submit"];function jg(e,t){"function"==typeof e?e(t):e&&e.hasOwnProperty("current")&&(e.current=t)}function Mg(e){const t=(0,T.useRef)(),n=(0,T.useRef)(!1),r=(0,T.useRef)(!1),o=(0,T.useRef)([]),a=(0,T.useRef)(e);return a.current=e,(0,T.useLayoutEffect)((()=>{!1===r.current&&!0===n.current&&e.forEach(((e,n)=>{const r=o.current[n];e!==r&&(jg(r,null),jg(e,t.current))})),o.current=e}),e),(0,T.useLayoutEffect)((()=>{r.current=!1})),(0,T.useCallback)((e=>{jg(t,e),r.current=!0,n.current=null!==e;const i=e?a.current:o.current;for(const t of i)jg(t,e)}),[])}const $g=function(e){const t=(0,T.useRef)(),{constrainTabbing:n=!1!==e.focusOnMount}=e;(0,T.useEffect)((()=>{t.current=e}),Object.values(e));const r=Dg(),o=function(e="firstElement"){const t=(0,T.useRef)(e),n=e=>{e.focus({preventScroll:!0})},r=(0,T.useRef)();return(0,T.useEffect)((()=>{t.current=e}),[e]),(0,T.useEffect)((()=>()=>{r.current&&clearTimeout(r.current)}),[]),(0,T.useCallback)((e=>{var o;e&&!1!==t.current&&(e.contains(null!==(o=e.ownerDocument?.activeElement)&&void 0!==o?o:null)||("firstElement"!==t.current?n(e):r.current=setTimeout((()=>{const t=Dm.tabbable.find(e)[0];t&&n(t)}),0)))}),[])}(e.focusOnMount),a=function(e){const t=(0,T.useRef)(null),n=(0,T.useRef)(null),r=(0,T.useRef)(e);return(0,T.useEffect)((()=>{r.current=e}),[e]),(0,T.useCallback)((e=>{if(e){if(t.current=e,n.current)return;n.current=e.ownerDocument.activeElement}else if(n.current){const e=t.current?.contains(t.current?.ownerDocument.activeElement);var o;if(t.current?.isConnected&&!e)return void(null!==(o=Tg)&&void 0!==o||(Tg=n.current));r.current?r.current():(n.current.isConnected?n.current:Tg)?.focus(),Tg=null}}),[])}(),i=function(e){const t=(0,T.useRef)(e);(0,T.useEffect)((()=>{t.current=e}),[e]);const n=(0,T.useRef)(!1),r=(0,T.useRef)(),o=(0,T.useCallback)((()=>{clearTimeout(r.current)}),[]);(0,T.useEffect)((()=>()=>o()),[]),(0,T.useEffect)((()=>{e||o()}),[e,o]);const a=(0,T.useCallback)((e=>{const{type:t,target:r}=e;["mouseup","touchend"].includes(t)?n.current=!1:function(e){if(!(e instanceof window.HTMLElement))return!1;switch(e.nodeName){case"A":case"BUTTON":return!0;case"INPUT":return Ig.includes(e.type)}return!1}(r)&&(n.current=!0)}),[]),i=(0,T.useCallback)((e=>{if(e.persist(),n.current)return;const o=e.target.getAttribute("data-unstable-ignore-focus-outside-for-relatedtarget");o&&e.relatedTarget?.closest(o)||(r.current=setTimeout((()=>{document.hasFocus()?"function"==typeof t.current&&t.current(e):e.preventDefault()}),0))}),[]);return{onFocus:o,onMouseDown:a,onMouseUp:a,onTouchStart:a,onTouchEnd:a,onBlur:i}}((e=>{t.current?.__unstableOnClose?t.current.__unstableOnClose("focus-outside",e):t.current?.onClose&&t.current.onClose()})),l=(0,T.useCallback)((e=>{e&&e.addEventListener("keydown",(e=>{27===e.keyCode&&!e.defaultPrevented&&t.current?.onClose&&(e.preventDefault(),t.current.onClose())}))}),[]);return[Mg([n?r:null,!1!==e.focusOnMount?a:null,!1!==e.focusOnMount?o:null,l]),{...i,tabIndex:-1}]};var Lg=i(3950),zg=i.n(Lg);function Fg(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);ncmd and clicking on each step in the workflow.","post-expirator"),{kbd:React.createElement("kbd",null)}),(0,L.__)("Drag steps from the inserter and drop them directly into your workflow for easy customization.","post-expirator"),(0,L.__)("Simply double-click any step to bring up the settings sidebar for quick adjustments.","post-expirator"),(0,L.__)("Double-click the workflow pane to increase the zoom level for a closer look.","post-expirator"),(0,T.createInterpolateElement)((0,L.__)("Hold down the shift key and double-click the workflow pane to decrease the zoom level.","post-expirator"),{kbd:React.createElement("kbd",null)}),(0,L.__)("Easily add new steps by clicking on a step's handle and dragging it. Drop it in the workflow pane to see a floating inserter where you can type and search for the step you need.","post-expirator")];function Gg(){var e=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,l=[],s=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Fg(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)?Fg(e,t):void 0}}(e,t)||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.")}()}((0,T.useState)(Math.floor(Math.random()*Wg.length)),1)[0];return React.createElement(M.Tip,null,Wg[e])}var Bg=i(9181),Vg=i.n(Bg);const Hg=new WeakMap;function Ug(e){return Ug="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},Ug(e)}var qg=["tabId","onClick","children","selected"];function Xg(e,t,n){return(t=function(e){var t=function(e){if("object"!=Ug(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Ug(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Ug(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Yg(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n{if(o)return o;const e=function(e){const t=Hg.get(e)||0;return Hg.set(e,t+1),t}(n);return r?`${r}-${e}`:e}),[n,o,r])),g=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,l=[],s=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Yg(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)?Yg(e,t):void 0}}(e,t)||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.")}()}((0,T.useState)(null),2),b=g[0],y=g[1],v=function(e){y(e),h(e)},w=sh()(l,{name:b}),_="".concat(m,"-").concat(null!==(t=null==w?void 0:w.name)&&void 0!==t?t:"none");return(0,T.useEffect)((function(){sh()(l,{name:b})||y(s||(l.length>0?l[0].name:null))}),[l]),(0,T.useEffect)((function(){y(s||l[0].name)}),[s]),React.createElement("div",{className:a},React.createElement(M.NavigableMenu,{role:"tablist",orientation:u,onNavigate:function(e,t){t.click()},className:"components-tab-panel__tabs block-editor-inserter__tablist-and-close-button"},l.map((function(e){return React.createElement(Qg,{className:ft()("components-tab-panel__tabs-item",e.className,Xg({},f,e.name===b)),tabId:"".concat(m,"-").concat(e.name),"aria-controls":"".concat(m,"-").concat(e.name,"-view"),selected:e.name===b,key:e.name,onClick:Vg()(v,e.name)},e.title)}))),w&&React.createElement("div",{key:_,"aria-labelledby":_,role:"tabpanel",id:"".concat(_,"-view"),className:"components-tab-panel__tab-content block-editor-inserter__tabpanel"},i(w)))}var Jg={name:E,title:(0,L.__)("Triggers","post-expirator")},eb={name:x,title:(0,L.__)("Actions","post-expirator")},tb={name:S,title:(0,L.__)("Advanced","post-expirator")};const nb=function(e){var t=e.children,n=e.onSelect,r=e.initialTabName,o=void 0===r?E:r,a=(0,T.useMemo)((function(){return[Jg,eb,tb]}),[Jg,eb,tb]);return React.createElement(Zg,{className:"block-editor-inserter__tabs",tabs:a,onSelect:n,initialTabName:o},t)};function rb(e){var t=e.node,n=(0,$.useSelect)((function(e){return{isPro:e(ec).isPro()}})).isPro;return React.createElement("div",{className:"block-editor-block-card"},React.createElement(Lf,{icon:t.icon,showColors:!0,className:"block-editor-block-icon"}),React.createElement("div",{className:"block-editor-block-card__content"},React.createElement("h2",{className:"block-editor-block-card__title"},t.label,t.isProFeature&&!n&&React.createElement("span",{className:"block-editor-block-card__pro-badge"},(0,L.__)("Pro","post-expirator"))),t.description&&React.createElement("span",{className:"block-editor-block-card__description"},t.description),t.isProFeature&&!n&&React.createElement("div",{className:"block-editor-block-card__pro-instructions"},(0,L.__)("Currently this step is being skipped. Upgrade to Pro to unlock this feature.","post-expirator")," ",(0,L.__)("Drag this node to preview its options in your workflow.","post-expirator"))))}const ob=function(e){var t=e.item;return React.createElement("div",{className:"block-editor-inserter__preview-container"},React.createElement(rb,{node:t}))};function ab(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);ne.length)&&(t=e.length);for(var n=0,r=Array(t);n0&&React.createElement(React.Fragment,null,React.createElement("table",null,React.createElement("tbody",null,d.map((function(e){return React.createElement("tr",{key:"attribute_"+e.id},React.createElement("th",null,e.label),React.createElement("td",null,e.value))})))))))},Nb=function(e){var t,n,r,o=e.node,a=(0,(0,$.useSelect)((function(e){return{getNodeTypeByName:e(ec).getNodeTypeByName}})).getNodeTypeByName)(null==o||null===(t=o.data)||void 0===t?void 0:t.name),i=a.label||(null==o?void 0:o.data.label)||(0,L.__)("Node","post-expirator"),l=a.description||(null==o?void 0:o.data.description)||(0,L.__)("No description","post-expirator"),s=(null===(n=a.icon)||void 0===n?void 0:n.src)||"media-document",c=null==o?void 0:o.id,u=null==o||null===(r=o.data)||void 0===r?void 0:r.slug,d=React.createElement(Lf,{icon:s});return React.createElement(Rb,{title:i,description:l,id:c,icon:d,slug:u,isProFeature:a.isProFeature})},Cb=function(e){var t=e.children;return React.createElement("span",{className:"workflow-editor-element-inspector__warning"},t)};function Ob(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,l=[],s=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Ab(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)?Ab(e,t):void 0}}(e,t)||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.")}()}function Ab(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);ne.length)&&(t=e.length);for(var n=0,r=Array(t);ne.length)&&(t=e.length);for(var n=0,r=Array(t);ne.length)&&(t=e.length);for(var n=0,r=Array(t);n","","","","","","","")}})))))),!k&&React.createElement(qb,{link:"https://publishpress.com/links/future-workflow-inspector"},React.createElement(Ub,{label:(0,L.__)("Repeating Action","post-expirator"),disabled:!0})),React.createElement(M.Slot,{name:"DateOffsetAfterDateSourceField",fillProps:{onChangeSetting:p,defaultValue:r}}),u&&React.createElement(React.Fragment,null,!S&&React.createElement(M.PanelRow,null,React.createElement(M.TextControl,{label:(0,L.__)("Unique ID Expression","post-expirator"),value:null!==(t=r.uniqueIdExpression)&&void 0!==t?t:"",onChange:function(e){return p({settingName:"uniqueIdExpression",value:e})},help:(0,L.__)("Define a custom expression for a unique task ID. Use placeholders like {{onSavePost1.post.ID}}, {{global.user.ID}} or {{global.execution_id}} to make sure the ID is unique.","post-expirator")})),React.createElement(M.TextControl,{label:(0,L.__)("Priority","post-expirator"),value:r.priority||10,onChange:function(e){return p({settingName:"priority",value:e})},help:(0,L.__)("Sets the execution priority of the scheduled step. Lower numbers indicate higher priority and are executed first.","post-expirator")}))))}function ny(e){return ny="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},ny(e)}function ry(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 oy(e,t,n){return(t=function(e){var t=function(e){if("object"!=ny(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=ny(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==ny(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const ay=function(e){var t=e.name,n=(e.label,e.defaultValue),r=e.onChange,o=e.variables,a=void 0===o?[]:o,i=[{name:(0,L.__)("All received input","post-expirator"),id:"all-input"}];a.length>0&&a.forEach((function(e){i.push({name:e.name,id:e.id,children:e.children})})),i.push({name:(0,L.__)("Custom data","post-expirator"),id:"custom-data"});var l=function(e){var o=e.settingName,a=e.value,i=function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=Array(t);ne.length)&&(t=e.length);for(var n=0,r=Array(t);ne.length)&&(t=e.length);for(var n=0,r=Array(t);ne.length)&&(t=e.length);for(var n=0,r=Array(t);n{throw new Error("uSES not initialized!")},Wy=(e,t)=>e===t;Symbol.for("react.element"),Symbol.for("react.portal"),Symbol.for("react.fragment"),Symbol.for("react.strict_mode"),Symbol.for("react.profiler"),Symbol.for("react.provider"),Symbol.for("react.context"),Symbol.for("react.server_context"),Symbol.for("react.forward_ref"),Symbol.for("react.suspense"),Symbol.for("react.suspense_list"),Symbol.for("react.memo"),Symbol.for("react.lazy"),Symbol.for("react.offscreen"),Symbol.for("react.client.reference");var Gy={notify(){},get:()=>[]};var By=!("undefined"==typeof window||void 0===window.document||void 0===window.document.createElement),Vy="undefined"!=typeof navigator&&"ReactNative"===navigator.product,Hy=By||Vy?Ty.useLayoutEffect:Ty.useEffect;Object.defineProperty,Object.getOwnPropertyNames,Object.getOwnPropertySymbols,Object.getOwnPropertyDescriptor,Object.getPrototypeOf,Object.prototype;var Uy=function({store:e,context:t,children:n,serverState:r,stabilityCheck:o="once",identityFunctionCheck:a="once"}){const i=Ty.useMemo((()=>{const t=function(e,t){let n,r=Gy,o=0,a=!1;function i(){c.onStateChange&&c.onStateChange()}function l(){o++,n||(n=t?t.addNestedSub(i):e.subscribe(i),r=function(){let e=null,t=null;return{clear(){e=null,t=null},notify(){!function(e){e()}((()=>{let t=e;for(;t;)t.callback(),t=t.next}))},get(){const t=[];let n=e;for(;n;)t.push(n),n=n.next;return t},subscribe(n){let r=!0;const o=t={callback:n,next:null,prev:t};return o.prev?o.prev.next=o:e=o,function(){r&&null!==e&&(r=!1,o.next?o.next.prev=o.prev:t=o.prev,o.prev?o.prev.next=o.next:e=o.next)}}}}())}function s(){o--,n&&0===o&&(n(),n=void 0,r.clear(),r=Gy)}const c={addNestedSub:function(e){l();const t=r.subscribe(e);let n=!1;return()=>{n||(n=!0,t(),s())}},notifyNestedSubs:function(){r.notify()},handleChangeWrapper:i,isSubscribed:function(){return a},trySubscribe:function(){a||(a=!0,l())},tryUnsubscribe:function(){a&&(a=!1,s())},getListeners:()=>r};return c}(e);return{store:e,subscription:t,getServerState:r?()=>r:void 0,stabilityCheck:o,identityFunctionCheck:a}}),[e,r,o,a]),l=Ty.useMemo((()=>e.getState()),[e]);Hy((()=>{const{subscription:t}=i;return t.onStateChange=t.notifyNestedSubs,t.trySubscribe(),l!==e.getState()&&t.notifyNestedSubs(),()=>{t.tryUnsubscribe(),t.onStateChange=void 0}}),[i,l]);const s=t||$y;return Ty.createElement(s.Provider,{value:i},n)};function qy(e=$y){const t=e===$y?zy:Ly(e),n=()=>{const{store:e}=t();return e};return Object.assign(n,{withTypes:()=>n}),n}var Xy,Yy=qy();function Ky(e){return`Minified Redux error #${e}; visit https://redux.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}Xy=Dy.useSyncExternalStoreWithSelector,Fy=Xy,ht.useSyncExternalStore;var Qy=(()=>"function"==typeof Symbol&&Symbol.observable||"@@observable")(),Zy=()=>Math.random().toString(36).substring(7).split("").join("."),Jy={INIT:`@@redux/INIT${Zy()}`,REPLACE:`@@redux/REPLACE${Zy()}`,PROBE_UNKNOWN_ACTION:()=>`@@redux/PROBE_UNKNOWN_ACTION${Zy()}`};function ev(e){if("object"!=typeof e||null===e)return!1;let t=e;for(;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t||null===Object.getPrototypeOf(e)}function tv(e,t,n){if("function"!=typeof e)throw new Error(Ky(2));if("function"==typeof t&&"function"==typeof n||"function"==typeof n&&"function"==typeof arguments[3])throw new Error(Ky(0));if("function"==typeof t&&void 0===n&&(n=t,t=void 0),void 0!==n){if("function"!=typeof n)throw new Error(Ky(1));return n(tv)(e,t)}let r=e,o=t,a=new Map,i=a,l=0,s=!1;function c(){i===a&&(i=new Map,a.forEach(((e,t)=>{i.set(t,e)})))}function u(){if(s)throw new Error(Ky(3));return o}function d(e){if("function"!=typeof e)throw new Error(Ky(4));if(s)throw new Error(Ky(5));let t=!0;c();const n=l++;return i.set(n,e),function(){if(t){if(s)throw new Error(Ky(6));t=!1,c(),i.delete(n),a=null}}}function f(e){if(!ev(e))throw new Error(Ky(7));if(void 0===e.type)throw new Error(Ky(8));if("string"!=typeof e.type)throw new Error(Ky(17));if(s)throw new Error(Ky(9));try{s=!0,o=r(o,e)}finally{s=!1}return(a=i).forEach((e=>{e()})),e}return f({type:Jy.INIT}),{dispatch:f,subscribe:d,getState:u,replaceReducer:function(e){if("function"!=typeof e)throw new Error(Ky(10));r=e,f({type:Jy.REPLACE})},[Qy]:function(){const e=d;return{subscribe(t){if("object"!=typeof t||null===t)throw new Error(Ky(11));function n(){const e=t;e.next&&e.next(u())}return n(),{unsubscribe:e(n)}},[Qy](){return this}}}}}function nv(...e){return 0===e.length?e=>e:1===e.length?e[0]:e.reduce(((e,t)=>(...n)=>e(t(...n))))}function rv(e){return({dispatch:t,getState:n})=>r=>o=>"function"==typeof o?o(t,n,e):r(o)}var ov=rv(),av=rv,iv=Symbol.for("immer-nothing"),lv=Symbol.for("immer-draftable"),sv=Symbol.for("immer-state");function cv(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var uv=Object.getPrototypeOf;function dv(e){return!!e&&!!e[sv]}function fv(e){return!!e&&(hv(e)||Array.isArray(e)||!!e[lv]||!!e.constructor?.[lv]||vv(e)||wv(e))}var pv=Object.prototype.constructor.toString();function hv(e){if(!e||"object"!=typeof e)return!1;const t=uv(e);if(null===t)return!0;const n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return n===Object||"function"==typeof n&&Function.toString.call(n)===pv}function mv(e,t){0===gv(e)?Reflect.ownKeys(e).forEach((n=>{t(n,e[n],e)})):e.forEach(((n,r)=>t(r,n,e)))}function gv(e){const t=e[sv];return t?t.type_:Array.isArray(e)?1:vv(e)?2:wv(e)?3:0}function bv(e,t){return 2===gv(e)?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function yv(e,t,n){const r=gv(e);2===r?e.set(t,n):3===r?e.add(n):e[t]=n}function vv(e){return e instanceof Map}function wv(e){return e instanceof Set}function _v(e){return e.copy_||e.base_}function Ev(e,t){if(vv(e))return new Map(e);if(wv(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);const n=hv(e);if(!0===t||"class_only"===t&&!n){const t=Object.getOwnPropertyDescriptors(e);delete t[sv];let n=Reflect.ownKeys(t);for(let r=0;r1&&(e.set=e.add=e.clear=e.delete=Sv),Object.freeze(e),t&&Object.entries(e).forEach((([e,t])=>xv(t,!0)))),e}function Sv(){cv(2)}function kv(e){return Object.isFrozen(e)}var Rv,Nv={};function Cv(e){const t=Nv[e];return t||cv(0),t}function Ov(){return Rv}function Av(e,t){t&&(Cv("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function Pv(e){Dv(e),e.drafts_.forEach(Iv),e.drafts_=null}function Dv(e){e===Rv&&(Rv=e.parent_)}function Tv(e){return Rv={drafts_:[],parent_:Rv,immer_:e,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function Iv(e){const t=e[sv];0===t.type_||1===t.type_?t.revoke_():t.revoked_=!0}function jv(e,t){t.unfinalizedDrafts_=t.drafts_.length;const n=t.drafts_[0];return void 0!==e&&e!==n?(n[sv].modified_&&(Pv(t),cv(4)),fv(e)&&(e=Mv(t,e),t.parent_||Lv(t,e)),t.patches_&&Cv("Patches").generateReplacementPatches_(n[sv].base_,e,t.patches_,t.inversePatches_)):e=Mv(t,n,[]),Pv(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==iv?e:void 0}function Mv(e,t,n){if(kv(t))return t;const r=t[sv];if(!r)return mv(t,((o,a)=>$v(e,r,t,o,a,n))),t;if(r.scope_!==e)return t;if(!r.modified_)return Lv(e,r.base_,!0),r.base_;if(!r.finalized_){r.finalized_=!0,r.scope_.unfinalizedDrafts_--;const t=r.copy_;let o=t,a=!1;3===r.type_&&(o=new Set(t),t.clear(),a=!0),mv(o,((o,i)=>$v(e,r,t,o,i,n,a))),Lv(e,t,!1),n&&e.patches_&&Cv("Patches").generatePatches_(r,n,e.patches_,e.inversePatches_)}return r.copy_}function $v(e,t,n,r,o,a,i){if(dv(o)){const i=Mv(e,o,a&&t&&3!==t.type_&&!bv(t.assigned_,r)?a.concat(r):void 0);if(yv(n,r,i),!dv(i))return;e.canAutoFreeze_=!1}else i&&n.add(o);if(fv(o)&&!kv(o)){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1)return;Mv(e,o),t&&t.scope_.parent_||"symbol"==typeof r||!Object.prototype.propertyIsEnumerable.call(n,r)||Lv(e,o)}}function Lv(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&xv(t,n)}var zv={get(e,t){if(t===sv)return e;const n=_v(e);if(!bv(n,t))return function(e,t,n){const r=Gv(t,n);return r?"value"in r?r.value:r.get?.call(e.draft_):void 0}(e,n,t);const r=n[t];return e.finalized_||!fv(r)?r:r===Wv(e.base_,t)?(Vv(e),e.copy_[t]=Hv(r,e)):r},has:(e,t)=>t in _v(e),ownKeys:e=>Reflect.ownKeys(_v(e)),set(e,t,n){const r=Gv(_v(e),t);if(r?.set)return r.set.call(e.draft_,n),!0;if(!e.modified_){const r=Wv(_v(e),t),i=r?.[sv];if(i&&i.base_===n)return e.copy_[t]=n,e.assigned_[t]=!1,!0;if(((o=n)===(a=r)?0!==o||1/o==1/a:o!=o&&a!=a)&&(void 0!==n||bv(e.base_,t)))return!0;Vv(e),Bv(e)}var o,a;return e.copy_[t]===n&&(void 0!==n||t in e.copy_)||Number.isNaN(n)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=n,e.assigned_[t]=!0),!0},deleteProperty:(e,t)=>(void 0!==Wv(e.base_,t)||t in e.base_?(e.assigned_[t]=!1,Vv(e),Bv(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0),getOwnPropertyDescriptor(e,t){const n=_v(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r?{writable:!0,configurable:1!==e.type_||"length"!==t,enumerable:r.enumerable,value:n[t]}:r},defineProperty(){cv(11)},getPrototypeOf:e=>uv(e.base_),setPrototypeOf(){cv(12)}},Fv={};function Wv(e,t){const n=e[sv];return(n?_v(n):e)[t]}function Gv(e,t){if(!(t in e))return;let n=uv(e);for(;n;){const e=Object.getOwnPropertyDescriptor(n,t);if(e)return e;n=uv(n)}}function Bv(e){e.modified_||(e.modified_=!0,e.parent_&&Bv(e.parent_))}function Vv(e){e.copy_||(e.copy_=Ev(e.base_,e.scope_.immer_.useStrictShallowCopy_))}function Hv(e,t){const n=vv(e)?Cv("MapSet").proxyMap_(e,t):wv(e)?Cv("MapSet").proxySet_(e,t):function(e,t){const n=Array.isArray(e),r={type_:n?1:0,scope_:t?t.scope_:Ov(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let o=r,a=zv;n&&(o=[r],a=Fv);const{revoke:i,proxy:l}=Proxy.revocable(o,a);return r.draft_=l,r.revoke_=i,l}(e,t);return(t?t.scope_:Ov()).drafts_.push(n),n}function Uv(e){if(!fv(e)||kv(e))return e;const t=e[sv];let n;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=Ev(e,t.scope_.immer_.useStrictShallowCopy_)}else n=Ev(e,!0);return mv(n,((e,t)=>{yv(n,e,Uv(t))})),t&&(t.finalized_=!1),n}mv(zv,((e,t)=>{Fv[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}})),Fv.deleteProperty=function(e,t){return Fv.set.call(this,e,t,void 0)},Fv.set=function(e,t,n){return zv.set.call(this,e[0],t,n,e[0])};var qv=new class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.produce=(e,t,n)=>{if("function"==typeof e&&"function"!=typeof t){const n=t;t=e;const r=this;return function(e=n,...o){return r.produce(e,(e=>t.call(this,e,...o)))}}let r;if("function"!=typeof t&&cv(6),void 0!==n&&"function"!=typeof n&&cv(7),fv(e)){const o=Tv(this),a=Hv(e,void 0);let i=!0;try{r=t(a),i=!1}finally{i?Pv(o):Dv(o)}return Av(o,n),jv(r,o)}if(!e||"object"!=typeof e){if(r=t(e),void 0===r&&(r=e),r===iv&&(r=void 0),this.autoFreeze_&&xv(r,!0),n){const t=[],o=[];Cv("Patches").generateReplacementPatches_(e,r,t,o),n(t,o)}return r}cv(1)},this.produceWithPatches=(e,t)=>{if("function"==typeof e)return(t,...n)=>this.produceWithPatches(t,(t=>e(t,...n)));let n,r;return[this.produce(e,t,((e,t)=>{n=e,r=t})),n,r]},"boolean"==typeof e?.autoFreeze&&this.setAutoFreeze(e.autoFreeze),"boolean"==typeof e?.useStrictShallowCopy&&this.setUseStrictShallowCopy(e.useStrictShallowCopy)}createDraft(e){var t;fv(e)||cv(8),dv(e)&&(dv(t=e)||cv(10),e=Uv(t));const n=Tv(this),r=Hv(e,void 0);return r[sv].isManual_=!0,Dv(n),r}finishDraft(e,t){const n=e&&e[sv];n&&n.isManual_||cv(9);const{scope_:r}=n;return Av(r,t),jv(void 0,r)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}applyPatches(e,t){let n;for(n=t.length-1;n>=0;n--){const r=t[n];if(0===r.path.length&&"replace"===r.op){e=r.value;break}}n>-1&&(t=t.slice(n+1));const r=Cv("Patches").applyPatches_;return dv(e)?r(e,t):this.produce(e,(e=>r(e,t)))}},Xv=qv.produce;qv.produceWithPatches.bind(qv),qv.setAutoFreeze.bind(qv),qv.setUseStrictShallowCopy.bind(qv),qv.applyPatches.bind(qv),qv.createDraft.bind(qv),qv.finishDraft.bind(qv);var Yv="undefined"!=typeof window&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(0!==arguments.length)return"object"==typeof arguments[0]?nv:nv.apply(null,arguments)};function Kv(e,t){function n(...n){if(t){let r=t(...n);if(!r)throw new Error(uw(0));return{type:e,payload:r.payload,..."meta"in r&&{meta:r.meta},..."error"in r&&{error:r.error}}}return{type:e,payload:n[0]}}return n.toString=()=>`${e}`,n.type=e,n.match=t=>function(e){return ev(e)&&"type"in e&&"string"==typeof e.type}(t)&&t.type===e,n}"undefined"!=typeof window&&window.__REDUX_DEVTOOLS_EXTENSION__&&window.__REDUX_DEVTOOLS_EXTENSION__;var Qv=class e extends Array{constructor(...t){super(...t),Object.setPrototypeOf(this,e.prototype)}static get[Symbol.species](){return e}concat(...e){return super.concat.apply(this,e)}prepend(...t){return 1===t.length&&Array.isArray(t[0])?new e(...t[0].concat(this)):new e(...t.concat(this))}};function Zv(e){return fv(e)?Xv(e,(()=>{})):e}function Jv(e,t,n){if(e.has(t)){let r=e.get(t);return n.update&&(r=n.update(r,t,e),e.set(t,r)),r}if(!n.insert)throw new Error(uw(10));const r=n.insert(t,e);return e.set(t,r),r}var ew=e=>t=>{setTimeout(t,e)},tw="undefined"!=typeof window&&window.requestAnimationFrame?window.requestAnimationFrame:ew(10);function nw(e){const t={},n=[];let r;const o={addCase(e,n){const r="string"==typeof e?e:e.type;if(!r)throw new Error(uw(28));if(r in t)throw new Error(uw(29));return t[r]=n,o},addMatcher:(e,t)=>(n.push({matcher:e,reducer:t}),o),addDefaultCase:e=>(r=e,o)};return e(o),[t,n,r]}var rw=Symbol.for("rtk-slice-createasyncthunk");function ow(e,t){return`${e}/${t}`}function aw({creators:e}={}){const t=e?.asyncThunk?.[rw];return function(e){const{name:n,reducerPath:r=n}=e;if(!n)throw new Error(uw(11));const o=("function"==typeof e.reducers?e.reducers(function(){function e(e,t){return{_reducerDefinitionType:"asyncThunk",payloadCreator:e,...t}}return e.withTypes=()=>e,{reducer:e=>Object.assign({[e.name]:(...t)=>e(...t)}[e.name],{_reducerDefinitionType:"reducer"}),preparedReducer:(e,t)=>({_reducerDefinitionType:"reducerWithPrepare",prepare:e,reducer:t}),asyncThunk:e}}()):e.reducers)||{},a=Object.keys(o),i={sliceCaseReducersByName:{},sliceCaseReducersByType:{},actionCreators:{},sliceMatchers:[]},l={addCase(e,t){const n="string"==typeof e?e:e.type;if(!n)throw new Error(uw(12));if(n in i.sliceCaseReducersByType)throw new Error(uw(13));return i.sliceCaseReducersByType[n]=t,l},addMatcher:(e,t)=>(i.sliceMatchers.push({matcher:e,reducer:t}),l),exposeAction:(e,t)=>(i.actionCreators[e]=t,l),exposeCaseReducer:(e,t)=>(i.sliceCaseReducersByName[e]=t,l)};function s(){const[t={},n=[],r]="function"==typeof e.extraReducers?nw(e.extraReducers):[e.extraReducers],o={...t,...i.sliceCaseReducersByType};return function(e){let t,[a,l,s]=nw((e=>{for(let t in o)e.addCase(t,o[t]);for(let t of i.sliceMatchers)e.addMatcher(t.matcher,t.reducer);for(let t of n)e.addMatcher(t.matcher,t.reducer);r&&e.addDefaultCase(r)}));if("function"==typeof e)t=()=>Zv(e());else{const n=Zv(e);t=()=>n}function c(e=t(),n){let r=[a[n.type],...l.filter((({matcher:e})=>e(n))).map((({reducer:e})=>e))];return 0===r.filter((e=>!!e)).length&&(r=[s]),r.reduce(((e,t)=>{if(t){if(dv(e)){const r=t(e,n);return void 0===r?e:r}if(fv(e))return Xv(e,(e=>t(e,n)));{const r=t(e,n);if(void 0===r){if(null===e)return e;throw Error("A case reducer on a non-draftable value must not return undefined")}return r}}return e}),e)}return c.getInitialState=t,c}(e.initialState)}a.forEach((r=>{const a=o[r],i={reducerName:r,type:ow(n,r),createNotation:"function"==typeof e.reducers};!function(e){return"asyncThunk"===e._reducerDefinitionType}(a)?function({type:e,reducerName:t,createNotation:n},r,o){let a,i;if("reducer"in r){if(n&&!function(e){return"reducerWithPrepare"===e._reducerDefinitionType}(r))throw new Error(uw(17));a=r.reducer,i=r.prepare}else a=r;o.addCase(e,a).exposeCaseReducer(t,a).exposeAction(t,i?Kv(e,i):Kv(e))}(i,a,l):function({type:e,reducerName:t},n,r,o){if(!o)throw new Error(uw(18));const{payloadCreator:a,fulfilled:i,pending:l,rejected:s,settled:c,options:u}=n,d=o(e,a,u);r.exposeAction(t,d),i&&r.addCase(d.fulfilled,i),l&&r.addCase(d.pending,l),s&&r.addCase(d.rejected,s),c&&r.addMatcher(d.settled,c),r.exposeCaseReducer(t,{fulfilled:i||sw,pending:l||sw,rejected:s||sw,settled:c||sw})}(i,a,l,t)}));const c=e=>e,u=new Map;let d;function f(e,t){return d||(d=s()),d(e,t)}function p(){return d||(d=s()),d.getInitialState()}function h(t,n=!1){function r(e){let r=e[t];return void 0===r&&n&&(r=p()),r}function o(t=c){const r=Jv(u,n,{insert:()=>new WeakMap});return Jv(r,t,{insert:()=>{const r={};for(const[o,a]of Object.entries(e.selectors??{}))r[o]=iw(a,t,p,n);return r}})}return{reducerPath:t,getSelectors:o,get selectors(){return o(r)},selectSlice:r}}const m={name:n,reducer:f,actions:i.actionCreators,caseReducers:i.sliceCaseReducersByName,getInitialState:p,...h(r),injectInto(e,{reducerPath:t,...n}={}){const o=t??r;return e.inject({reducerPath:o,reducer:f},n),{...m,...h(o,!0)}}};return m}}function iw(e,t,n,r){function o(o,...a){let i=t(o);return void 0===i&&r&&(i=n()),e(i,...a)}return o.unwrapped=e,o}var lw=aw();function sw(){}var{assign:cw}=Object;function uw(e){return`Minified Redux Toolkit error #${e}; visit https://redux-toolkit.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}Symbol.for("rtk-state-proxy-original");var dw={"¼":"1/4","½":"1/2","¾":"3/4","⅐":"1/7","⅑":"1/9","⅒":"1/10","⅓":"1/3","⅔":"2/3","⅕":"1/5","⅖":"2/5","⅗":"3/5","⅘":"4/5","⅙":"1/6","⅚":"5/6","⅛":"1/8","⅜":"3/8","⅝":"5/8","⅞":"7/8","⅟":"1/"},fw=/^(?=-?\s*\.\d|-?\s*\d)(-)?\s*((?:\d(?:[\d,_]*\d)?)*)(([eE][+-]?\d(?:[\d,_]*\d)?)?|\.\d(?:[\d,_]*\d)?([eE][+-]?\d(?:[\d,_]*\d)?)?|(\s+\d(?:[\d,_]*\d)?\s*)?\s*\/\s*\d(?:[\d,_]*\d)?)?$/,pw=new RegExp(fw.source.replace(/\$$/,"(?:\\s*[^\\.\\d\\/].*)?")),hw=new RegExp(`(${Object.keys(dw).join("|")})`),mw={MMM:3e3,MM:2e3,M:1e3,CM:900,DCCC:800,DCC:700,DC:600,D:500,CD:400,CCC:300,CC:200,C:100,XC:90,LXXX:80,LXX:70,LX:60,L:50,XL:40,XXX:30,XX:20,XII:12,XI:11,X:10,IX:9,VIII:8,VII:7,VI:6,V:5,IV:4,III:3,II:2,I:1},gw={Ⅰ:"I",Ⅱ:"II",Ⅲ:"III",Ⅳ:"IV",Ⅴ:"V",Ⅵ:"VI",Ⅶ:"VII",Ⅷ:"VIII",Ⅸ:"IX",Ⅹ:"X",Ⅺ:"XI",Ⅻ:"XII",Ⅼ:"L",Ⅽ:"C",Ⅾ:"D",Ⅿ:"M",ⅰ:"I",ⅱ:"II",ⅲ:"III",ⅳ:"IV",ⅴ:"V",ⅵ:"VI",ⅶ:"VII",ⅷ:"VIII",ⅸ:"IX",ⅹ:"X",ⅺ:"XI",ⅻ:"XII",ⅼ:"L",ⅽ:"C",ⅾ:"D",ⅿ:"M"},bw=new RegExp(`(${Object.keys(gw).join("|")})`,"gi"),yw=/^(?=[MDCLXVI])(M{0,3})(C[MD]|D?C{0,3})(X[CL]|L?X{0,3})(I[XV]|V?I{0,3})$/i,vw={round:3,allowTrailingInvalid:!1,romanNumerals:!1},ww=/^\s*\//,_w=e=>ht.createElement("button",{type:"button","data-testid":e.testID,disabled:e.disabled&&!e.disabledTranslation,className:e.className,title:e.disabledTranslation&&e.disabled?e.disabledTranslation.title:e.title,onClick:t=>e.handleOnClick(t)},e.disabledTranslation&&e.disabled?e.disabledTranslation.label:e.label),Ew=(0,ht.forwardRef)(((e,t)=>ht.createElement("span",{"data-testid":e.testID,ref:t,className:e.className,title:e.title},e.label))),xw="------",Sw={fields:{title:"Fields",placeholderName:"~",placeholderLabel:xw,placeholderGroupLabel:xw},operators:{title:"Operators",placeholderName:"~",placeholderLabel:xw,placeholderGroupLabel:xw},value:{title:"Value"},removeRule:{label:"⨯",title:"Remove rule"},removeGroup:{label:"⨯",title:"Remove group"},addRule:{label:"+ Rule",title:"Add rule"},addGroup:{label:"+ Group",title:"Add group"},combinators:{title:"Combinators"},notToggle:{label:"Not",title:"Invert this group"},cloneRule:{label:"⧉",title:"Clone rule"},cloneRuleGroup:{label:"⧉",title:"Clone group"},shiftActionUp:{label:"˄",title:"Shift up"},shiftActionDown:{label:"˅",title:"Shift down"},dragHandle:{label:"⁞⁞",title:"Drag handle"},lockRule:{label:"🔓",title:"Lock rule"},lockGroup:{label:"🔓",title:"Lock group"},lockRuleDisabled:{label:"🔒",title:"Unlock rule"},lockGroupDisabled:{label:"🔒",title:"Unlock group"},valueSourceSelector:{title:"Value source"}},kw=[{name:"=",value:"=",label:"="},{name:"!=",value:"!=",label:"!="},{name:"<",value:"<",label:"<"},{name:">",value:">",label:">"},{name:"<=",value:"<=",label:"<="},{name:">=",value:">=",label:">="},{name:"contains",value:"contains",label:"contains"},{name:"beginsWith",value:"beginsWith",label:"begins with"},{name:"endsWith",value:"endsWith",label:"ends with"},{name:"doesNotContain",value:"doesNotContain",label:"does not contain"},{name:"doesNotBeginWith",value:"doesNotBeginWith",label:"does not begin with"},{name:"doesNotEndWith",value:"doesNotEndWith",label:"does not end with"},{name:"null",value:"null",label:"is null"},{name:"notNull",value:"notNull",label:"is not null"},{name:"in",value:"in",label:"in"},{name:"notIn",value:"notIn",label:"not in"},{name:"between",value:"between",label:"between"},{name:"notBetween",value:"notBetween",label:"not between"}],Rw=[{name:"and",value:"and",label:"AND"},{name:"or",value:"or",label:"OR"}],Nw="queryBuilder-valid",Cw="queryBuilder-invalid",Ow="shiftActions",Aw="dndDragging",Pw="dndOver",Dw="dndCopy",Tw="queryBuilder-dragHandle",Iw="queryBuilder-disabled",jw="rule-value-list-item",Mw={queryBuilder:"",ruleGroup:"",header:"",body:"",combinators:"",addRule:"",addGroup:"",cloneRule:"",cloneGroup:"",removeGroup:"",notToggle:"",rule:"",fields:"",operators:"",value:"",removeRule:"",shiftActions:"",dragHandle:"",lockRule:"",lockGroup:"",valueSource:"",actionElement:"",valueSelector:"",betweenRules:"",valid:"",invalid:"",dndDragging:"",dndOver:"",dndCopy:"",disabled:"",valueListItem:"",branches:""},$w="rule",Lw="rule-group",zw="inline-combinator",Fw="add-group",Ww="remove-group",Gw="clone-group",Bw="add-rule",Vw="combinators",Hw="not-toggle",Uw="shift-actions",qw="drag-handle",Xw="lock-group",Yw="action aborted: parent path disabled",Kw="action aborted: path is disabled",Qw="rule or group added";function Zw(e){let t,n,r="";if("string"==typeof e||"number"==typeof e)r+=e;else if("object"==typeof e)if(Array.isArray(e)){const o=e.length;for(t=0;t{e[t]=n}},selectors:{getQuerySelectorById:(e,t)=>e[t]}}),u_=lw({name:"warnings",initialState:{[t_]:!1,[n_]:!1,[r_]:!1,[o_]:!1,[a_]:!1,[i_]:!1,[l_]:!1,[s_]:!1},reducers:{rqbWarn:(e,{payload:t})=>{e[t]||(console.error(t),e[t]=!0)}}}),d_={queries:c_.getInitialState(),warnings:u_.getInitialState()},f_=function(e){const t=function(e){const{thunk:t=!0,immutableCheck:n=!0,serializableCheck:r=!0,actionCreatorCheck:o=!0}=e??{};let a=new Qv;return t&&("boolean"==typeof t?a.push(ov):a.push(av(t.extraArgument))),a},{reducer:n,middleware:r,devTools:o=!0,preloadedState:a,enhancers:i}=e||{};let l,s;if("function"==typeof n)l=n;else{if(!ev(n))throw new Error(uw(1));l=function(e){const t=Object.keys(e),n={};for(let r=0;r{const n=e[t];if(void 0===n(void 0,{type:Jy.INIT}))throw new Error(Ky(12));if(void 0===n(void 0,{type:Jy.PROBE_UNKNOWN_ACTION()}))throw new Error(Ky(13))}))}(n)}catch(e){o=e}return function(e={},t){if(o)throw o;let a=!1;const i={};for(let o=0;o(n,r)=>{const o=t(n,r);let a=()=>{throw new Error(Ky(15))};const i={getState:o.getState,dispatch:(e,...t)=>a(e,...t)},l=e.map((e=>e(i)));return a=nv(...l)(o.dispatch),{...o,dispatch:a}}}(...s),d=(e=>function(t){const{autoBatch:n=!0}=t??{};let r=new Qv(e);return n&&r.push(((e={type:"raf"})=>t=>(...n)=>{const r=t(...n);let o=!0,a=!1,i=!1;const l=new Set,s="tick"===e.type?queueMicrotask:"raf"===e.type?tw:"callback"===e.type?e.queueNotification:ew(e.timeout),c=()=>{i=!1,a&&(a=!1,l.forEach((e=>e())))};return Object.assign({},r,{subscribe(e){const t=r.subscribe((()=>o&&e()));return l.add(e),()=>{t(),l.delete(e)}},dispatch(e){try{return o=!e?.meta?.RTK_autoBatch,a=!o,a&&(i||(i=!0,s(c))),r.dispatch(e)}finally{o=!0}}})})("object"==typeof n?n:void 0)),r})(u);return tv(l,a,c(..."function"==typeof i?i(d):d()))}({reducer:{queries:c_.reducer,warnings:u_.reducer},preloadedState:d_,middleware:e=>e({serializableCheck:{ignoredActions:["queries/setQueryState"],ignoredPaths:[/^queries\b.*\.rules\.\d+\.value$/]}})}),p_=ht.createContext(null),h_=function(e=$y){const t=e===$y?zy:Ly(e),n=(e,n={})=>{const{equalityFn:r=Wy,devModeChecks:o={}}="function"==typeof n?{equalityFn:n}:n,{store:a,subscription:i,getServerState:l,stabilityCheck:s,identityFunctionCheck:c}=t(),u=(Ty.useRef(!0),Ty.useCallback({[e.name]:t=>e(t)}[e.name],[e,s,o.stabilityCheck])),d=Fy(i.addNestedSub,a.getState,l||a.getState,u,r);return Ty.useDebugValue(d),d};return Object.assign(n,{withTypes:()=>n}),n}(p_),m_=e=>t=>c_.selectors.getQuerySelectorById({queries:t.queries},e),g_=({payload:e,onQueryChange:t})=>n=>{n(c_.actions.setQueryState(e)),"function"==typeof t&&t(e.query)},b_=function(e=$y){const t=e===$y?Yy:qy(e),n=()=>t().dispatch;return Object.assign(n,{withTypes:()=>n}),n}(p_),y_=qy(p_),{rqbWarn:v_}=u_.actions;function w_(e,t,n){b_()}var __=(e,t=",")=>"string"==typeof e?e.split(`\\${t}`).map((e=>e.split(t))).reduce(((e,n,r)=>0===r?n:[...e.slice(0,-1),`${e.at(-1)}${t}${n[0]}`,...n.slice(1)]),[]):[],E_=(e,t=",")=>e.map((e=>`${e??""}`.replaceAll(t[0],`\\${t[0]}`))).join(t),x_=e=>"string"==typeof e?e.trim():e,S_=(e,{retainEmptyStrings:t}={})=>Array.isArray(e)?e.map((e=>x_(e))):"string"==typeof e?__(e,",").filter(t?()=>!0:e=>!/^\s*$/.test(e)).map((e=>e.trim())):"number"==typeof e?[e]:[],k_=new RegExp(fw.source.replace(/^\^/,String.raw`^\s*`).replace(/\$$/,String.raw`\s*$`)),R_=e=>null!==e&&"object"==typeof e&&Object.getPrototypeOf(e)===Object.prototype,N_=e=>R_(e)&&Array.isArray(e.rules),C_=e=>N_(e)&&"string"==typeof e.combinator,O_=e=>N_(e)&&void 0===e.combinator,A_=e=>N_(e)?P_(e):e,P_=e=>{const t=[],n=e=>t.push(A_(e));let r=0;for(let o=0;oA_(e)))}),o-=2}else"or"===e.rules[o+1]&&(0===o||o===e.rules.length-3?(0!==o&&"or"!==e.rules[o-1]||n(e.rules[o]),n(e.rules[o+1]),o===e.rules.length-3&&n(e.rules[o+2])):("and"===e.rules[o-1]||n(e.rules[o]),n(e.rules[o+1])));return 1===t.length&&"object"==typeof t[0]&&N_(t[0])?{...e,...t[0]}:{...e,rules:t}},D_=e=>{if(C_(e))return e;const t=P_(e),n=t.rules.map((e=>"string"!=typeof e&&N_(e)?D_(e):e)),r=n.length<2?"and":n[1],o=n.filter((e=>"string"!=typeof e));return{...t,combinator:r,rules:o}},T_=e=>R_(e)&&"name"in e&&"string"==typeof e.name,I_=e=>R_(e)&&"value"in e&&"string"==typeof e.value;function j_(e,t){return Xv((e=>{const n={};let r=!!t;if(T_(e)&&!I_(e)?(n.value=e.name,r=!0):!T_(e)&&I_(e)&&(n.name=e.value,r=!0),r)return Object.assign({},t,e,n)}))(e)}function M_(e,t){return Array.isArray(e)?Xv((e=>{if(W_(e))for(const n of e)for(const[e,r]of n.options.entries())n.options[e]=j_(r,t);else for(const[n,r]of e.entries())e[n]=j_(r,t)}))(e):[]}function $_(e,t){return Object.fromEntries(Object.entries(e).map((([e,n])=>[e,j_(n,t)])))}var L_=e=>{const t=new Set,n=[];for(const r of e)t.has(r.value??r.name)||(t.add(r.value??r.name),n.push(r));return e.length===n.length?e:n},z_=e=>{const t=new Set,n=new Set,r=[];for(const o of e)if(!t.has(o.label)){t.add(o.label);const e=[];for(const t of o.options)n.has(t.value??t.name)||(n.add(t.value??t.name),e.push(j_(t)));r.push({...o,options:e})}return r},F_=e=>Array.isArray(e)&&e.length>0&&R_(e[0])&&"options"in e[0]&&Array.isArray(e[0].options),W_=e=>{if(Array.isArray(e))for(const t of e)if(R_(t)&&"options"in t)for(const e of t.options)return!(!R_(e)||!("name"in e)&&!("value"in e));return!1},G_=(e,t)=>(F_(e)?e.flatMap((e=>e.options)):e).find((e=>e.value===t||e.name===t)),B_=e=>{if(!Array.isArray(e)||0===e.length)return null;if(W_(e)){for(const t of e)if(t.options.length>0)return t.options[0].value??t.options[0].name;return null}return e[0].value??e[0].name},V_=(e,t,n)=>{const r=j_(e),o=j_(n);return r.value!==o.value&&("string"==typeof r.comparator?r[r.comparator]===o[r.comparator]:r.comparator?.(o,t)??!1)},H_=(e,t,n)=>{if(!e.comparator){const n=t=>(t.value??t.name)!==(e.value??e.name);return W_(t)?t.map((e=>({...e,options:e.options.filter((e=>n(e)))}))):t.filter((e=>n(e)))}return W_(t)?t.map((t=>({...t,options:t.options.filter((t=>V_(e,n,t)))}))).filter((e=>e.options.length>0)):t.filter((t=>V_(e,n,t)))},U_=(e,{parseNumbers:t}={})=>{if(!t||"bigint"==typeof e||"number"==typeof e)return e;if("native"===t)return parseFloat(e);const n=((e,t=vw)=>{if("number"==typeof e||"bigint"==typeof e)return e;let n=NaN;const r=`${e}`.replace(hw,((e,t)=>` ${dw[t]}`)).replace("⁄","/").trim();if(0===r.length)return NaN;const o={...vw,...t},a=(o.allowTrailingInvalid?pw:fw).exec(r);if(!a)return o.romanNumerals?(e=>{const t=`${e}`.replace(bw,((e,t)=>gw[t])).toUpperCase(),n=yw.exec(t);if(!n)return NaN;const[,r,o,a,i]=n;return(mw[r]??0)+(mw[o]??0)+(mw[a]??0)+(mw[i]??0)})(r):NaN;const[,i,l,s]=a,c=l.replace(/[,_]/g,""),u=null==s?void 0:s.replace(/[,_]/g,"");if(n=!c&&u&&u.startsWith(".")?0:parseInt(c),!u)return i?-1*n:n;const d=!1===o.round?NaN:parseFloat(`1e${Math.floor(Math.max(0,o.round))}`);if(u.startsWith(".")||u.startsWith("e")||u.startsWith("E")){const e=parseFloat(`${n}${u}`);n=isNaN(d)?e:Math.round(e*d)/d}else if(ww.test(u)){const e=parseInt(c),t=parseInt(u.replace("/",""));n=isNaN(d)?e/t:Math.round(e*d/t)/d}else{const e=u.split("/"),[t,r]=e.map((e=>parseInt(e)));n+=isNaN(d)?t/r:Math.round(t*d/r)/d}return i?-1*n:n})(e,{allowTrailingInvalid:"enhanced"===t,romanNumerals:!1,round:!1});return isNaN(n)?e:n},q_=e=>{switch(e.toLowerCase()){case"null":return"is null";case"notnull":return"is not null";case"notin":return"not in";case"notbetween":return"not between";case"contains":case"beginswith":case"endswith":return"like";case"doesnotcontain":case"doesnotbeginwith":case"doesnotendwith":return"not like";default:return e}},X_={"=":"$eq","!=":"$ne","<":"$lt","<=":"$lte",">":"$gt",">=":"$gte",in:"$in",notIn:"$nin"},Y_={and:"&&",or:"||"},K_=e=>({...e,rules:e.rules.map((e=>{if("string"==typeof e)return e;if(N_(e))return K_(e);if(Array.isArray(e.value))return{...e,value:e.value.map((e=>U_(e,{parseNumbers:!0})))};const t=S_(e.value,{retainEmptyStrings:!0}).map((e=>U_(e,{parseNumbers:!0})));if(t.every((e=>"number"==typeof e))){if(t.length>1)return{...e,value:t};if(1===t.length)return{...e,value:t[0]}}return e}))}),Q_=e=>"string"==typeof e&&e.length>0||"number"==typeof e&&!isNaN(e)||"string"!=typeof e&&"number"!=typeof e,Z_=(e,t)=>t&&("number"==typeof e||"bigint"==typeof e||"string"==typeof e&&k_.test(e)),J_=(e=["",""])=>Array.isArray(e)?e:"string"==typeof e?[e,e]:e??["",""],eE=(e,{quoteFieldNamesWith:t,fieldIdentifierSeparator:n})=>{const[r,o]=J_(t);return"string"==typeof n&&n.length>0?E_(__(e,n).map((e=>`${r}${e}${o}`)),n):`${r}${e}${o}`},tE=e=>null==e||""===e,nE=e=>/^(does)?not/i.test(e),rE=(e,t)=>"string"==typeof e&&t?e.replaceAll('"','\\"'):e,oE=({field:e,operator:t,value:n,valueSource:r},{escapeQuotes:o,parseNumbers:a}={})=>{const i="field"===r,l=t.replace(/^=$/,"=="),s="number"==typeof n||"boolean"==typeof n||"bigint"==typeof n||Z_(n,a);switch(l){case"<":case"<=":case"==":case"!=":case">":case">=":return`${e} ${l} ${i||s?x_(n):`"${rE(n,o)}"`}`;case"contains":case"doesNotContain":return`${nE(l)?"!":""}${e}.contains(${i?x_(n):`"${rE(n,o)}"`})`;case"beginsWith":case"doesNotBeginWith":return`${nE(l)?"!":""}${e}.startsWith(${i?x_(n):`"${rE(n,o)}"`})`;case"endsWith":case"doesNotEndWith":return`${nE(l)?"!":""}${e}.endsWith(${i?x_(n):`"${rE(n,o)}"`})`;case"null":return`${e} == null`;case"notNull":return`${e} != null`;case"in":case"notIn":{const t=nE(l);return`${t?"!(":""}${e} in [${S_(n).map((e=>i||Z_(e,a)?`${x_(e)}`:`"${rE(e,o)}"`)).join(", ")}]${t?")":""}`}case"between":case"notBetween":{const r=S_(n);if(r.length>=2&&!tE(r[0])&&!tE(r[1])){const[n,a]=r,l=Z_(n,!0)?U_(n,{parseNumbers:!0}):NaN,s=Z_(a,!0)?U_(a,{parseNumbers:!0}):NaN;let c=isNaN(l)?i?`${n}`:`"${rE(n,o)}"`:l,u=isNaN(s)?i?`${a}`:`"${rE(a,o)}"`:s;return c===l&&u===s&&s= ${c} && ${e} <= ${u})`:`(${e} < ${c} || ${e} > ${u})`}return""}}return""},aE=JSON.stringify,iE=({field:e,operator:t,value:n,valueSource:r},{parseNumbers:o}={})=>{const a="field"===r;if("="===t&&!a)return aE({[e]:Z_(n,o)?U_(n,{parseNumbers:"strict"}):n});switch(t){case"<":case"<=":case"=":case"!=":case">":case">=":{const r=X_[t];return aE(a?{$expr:{[r]:[`$${e}`,`$${n}`]}}:{[e]:{[r]:Z_(n,o)?U_(n,{parseNumbers:"strict"}):n}})}case"contains":return aE(a?{$where:`this.${e}.includes(this.${n})`}:{[e]:{$regex:n}});case"beginsWith":return aE(a?{$where:`this.${e}.startsWith(this.${n})`}:{[e]:{$regex:`^${n}`}});case"endsWith":return aE(a?{$where:`this.${e}.endsWith(this.${n})`}:{[e]:{$regex:`${n}$`}});case"doesNotContain":return aE(a?{$where:`!this.${e}.includes(this.${n})`}:{[e]:{$not:{$regex:n}}});case"doesNotBeginWith":return aE(a?{$where:`!this.${e}.startsWith(this.${n})`}:{[e]:{$not:{$regex:`^${n}`}}});case"doesNotEndWith":return aE(a?{$where:`!this.${e}.endsWith(this.${n})`}:{[e]:{$not:{$regex:`${n}$`}}});case"null":return aE({[e]:null});case"notNull":return aE({[e]:{$ne:null}});case"in":case"notIn":{const r=S_(n);return aE(a?{$where:`${"notIn"===t?"!":""}[${r.map((e=>`this.${e}`)).join(",")}].includes(this.${e})`}:{[e]:{[X_[t]]:r.map((e=>Z_(e,o)?U_(e,{parseNumbers:"strict"}):e))}})}case"between":case"notBetween":{const r=S_(n);if(r.length>=2&&Q_(r[0])&&Q_(r[1])){const[n,o]=r,i=Z_(n,!0)?U_(n,{parseNumbers:"strict"}):NaN,l=Z_(o,!0)?U_(o,{parseNumbers:"strict"}):NaN,s=a||isNaN(i)?n:i,c=a||isNaN(l)?o:l;return aE("between"===t?a?{$and:[{$expr:{$gte:[`$${e}`,`$${s}`]}},{$expr:{$lte:[`$${e}`,`$${c}`]}}]}:{[e]:{$gte:s,$lte:c}}:a?{$or:[{$expr:{$lt:[`$${e}`,`$${s}`]}},{$expr:{$gt:[`$${e}`,`$${c}`]}}]}:{$or:[{[e]:{$lt:s}},{[e]:{$gt:c}}]})}return""}}return""},lE=e=>/^(does)?not/i.test(e),sE=(e,t)=>t?`!(${e})`:`${e}`,cE=(e,t)=>"string"==typeof e&&t?e.replaceAll("'","\\'"):e,uE=({field:e,operator:t,value:n,valueSource:r},{escapeQuotes:o,parseNumbers:a}={})=>{const i="field"===r,l=t.replace(/^=$/,"=="),s="number"==typeof n||"boolean"==typeof n||"bigint"==typeof n||Z_(n,a);switch(l){case"<":case"<=":case"==":case"!=":case">":case">=":return`${e} ${l} ${i||s?x_(n):`'${cE(n,o)}'`}`;case"contains":case"doesNotContain":return sE(`${e} matches ${i||s?x_(n):`'${cE(n,o)}'`}`,lE(l));case"beginsWith":case"doesNotBeginWith":{const t=i?`'^'.concat(${x_(n)})`:`'${"string"==typeof n&&!n.startsWith("^")||s?"^":""}${cE(n,o)}'`;return sE(`${e} matches ${t}`,lE(l))}case"endsWith":case"doesNotEndWith":{const t=i?`${x_(n)}.concat('$')`:`'${cE(n,o)}${"string"==typeof n&&!n.endsWith("$")||s?"$":""}'`;return sE(`${e} matches ${t}`,lE(l))}case"null":return`${e} == null`;case"notNull":return`${e} != null`;case"in":case"notIn":{const t=lE(l)?"!":"",r=S_(n);return r.length>0?`${t}(${r.map((t=>`${e} == ${i||Z_(t,a)?`${x_(t)}`:`'${cE(t,o)}'`}`)).join(" or ")})`:""}case"between":case"notBetween":{const r=S_(n);if(r.length>=2&&!tE(r[0])&&!tE(r[1])){const[n,a]=r,l=Z_(n,!0)?U_(n,{parseNumbers:!0}):NaN,s=Z_(a,!0)?U_(a,{parseNumbers:!0}):NaN;let c=isNaN(l)?i?`${n}`:`'${cE(n,o)}'`:l,u=isNaN(s)?i?`${a}`:`'${cE(a,o)}'`:s;return c===l&&u===s&&s= ${c} and ${e} <= ${u})`:`(${e} < ${c} or ${e} > ${u})`}return""}}return""},dE=({operator:e,value:t,valueSource:n},{escapeQuotes:r,parseNumbers:o,quoteFieldNamesWith:a,quoteValuesWith:i,concatOperator:l="||",fieldIdentifierSeparator:s}={})=>{const c="field"===n,u=e.toLowerCase(),d=i||"'",f=e=>`${d}${e}${d}`,p=e=>((e,t,n)=>n&&"string"==typeof e?e.replaceAll(`${t}`,`${t}${t}`):e)(e,d,r),h=e=>f(p(e)),m=e=>eE(e,{quoteFieldNamesWith:a,fieldIdentifierSeparator:s}),g=(...e)=>"CONCAT"===l.toUpperCase()?`CONCAT(${e.join(", ")})`:e.join(` ${l} `);switch(u){case"null":case"notnull":return"";case"in":case"notin":{const e=S_(t);return e.length>0?`(${e.map((e=>c?m(e):Z_(e,o)?`${x_(e)}`:`${h(e)}`)).join(", ")})`:""}case"between":case"notbetween":{const e=S_(t,{retainEmptyStrings:!0});if(e.length>=2&&Q_(e[0])&&Q_(e[1])){const[t,n]=e,r=Z_(t,o)?U_(t,{parseNumbers:"strict"}):NaN,a=Z_(n,o)?U_(n,{parseNumbers:"strict"}):NaN,i=isNaN(r)?c?`${t}`:t:r,l=isNaN(a)?c?`${n}`:n:a,s=[i,l];return i===r&&l===a&&am(e))):s.every((e=>Z_(e,o)))?s.map((e=>U_(e,{parseNumbers:"strict"}))):s.map((e=>h(e)))).join(" and ")}return""}case"contains":case"doesnotcontain":return c?g(f("%"),m(t),f("%")):f(`%${p(t)}%`);case"beginswith":case"doesnotbeginwith":return c?g(m(t),f("%")):f(`${p(t)}%`);case"endswith":case"doesnotendwith":return c?g(f("%"),m(t)):f(`%${p(t)}`)}return"boolean"==typeof t?t?"TRUE":"FALSE":c?m(t):Z_(t,o)?`${x_(t)}`:`${h(t)}`},fE={"<":"lt","<=":"lte",">":"gt",">=":"gte"},pE=(e,t)=>/^(does)?not/i.test(e)?{bool:{must_not:t}}:t,hE=e=>e?.replace(/('|\\)/g,"\\$1"),mE={beginsWith:"startsWith",doesNotContain:"contains",doesNotBeginWith:"startsWith",doesNotEndWith:"endsWith"},gE=(e,t)=>"boolean"==typeof e?e:Z_(e,t)?U_(e,{parseNumbers:t}):e,bE=({field:e,operator:t,value:n,valueSource:r},{parseNumbers:o}={})=>{if("field"===r){if(S_(n).some((e=>"string"!=typeof e)))return!1;const r=hE(e);switch(t){case"=":case"!=":case">":case">=":case"<":case"<=":{const e="="===t?"==":t,o=hE(n);return!!o&&{bool:{filter:{script:{script:`doc['${r}'] ${e} doc['${o}']`}}}}}case"in":case"notIn":{const e=S_(n);if(e.length>0){const n=e.map((e=>({bool:{filter:{script:{script:`doc['${r}'] == doc['${e}']`}}}})));return{bool:"in"===t?{should:n}:{must_not:n}}}return!1}case"between":case"notBetween":{const e=S_(n);if(e.length>=2&&e[0]&&e[1]){const n=`doc['${r}'] >= doc['${e[0]}'] && doc['${r}'] <= doc['${e[1]}']`;return{bool:{filter:{script:{script:"notBetween"===t?`!(${n})`:n}}}}}return!1}case"contains":case"doesNotContain":case"beginsWith":case"doesNotBeginWith":case"endsWith":case"doesNotEndWith":{const e=hE(n);return!!e&&{bool:{filter:{script:{script:((e,t,n)=>{const r=`doc['${e}'].${mE[t]??t}(doc['${n}'])`;return t.startsWith("d")?`!${r}`:r})(r,t,e)}}}}}}}switch(t){case"<":case"<=":case">":case">=":return{range:{[e]:{[fE[t]]:gE(n,o)}}};case"=":return{term:{[e]:gE(n,o)}};case"!=":return{bool:{must_not:{term:{[e]:gE(n,o)}}}};case"null":return{bool:{must_not:{exists:{field:e}}}};case"notNull":return{exists:{field:e}};case"in":case"notIn":{const r=S_(n).map((e=>gE(e,o)));if(r.length>0){const n=r.map((t=>({term:{[e]:gE(t,o)}})));return{bool:"in"===t?{should:n}:{must_not:n}}}return!1}case"between":case"notBetween":{const r=S_(n);if(r.length>=2&&Q_(r[0])&&Q_(r[1])){let[n,o]=r;if(Z_(n,!0)&&Z_(o,!0)){const e=U_(n,{parseNumbers:!0}),t=U_(o,{parseNumbers:!0});t/^(does)?not/i.test(e),vE=(e,t)=>`"${"string"==typeof e&&t?e.replaceAll('"','\\"'):e}"`,wE=(e,t)=>t?`$not(${e})`:`${e}`,_E=e=>`${e}`.replaceAll(/[$()*+.?[\\\]^{|}]/g,String.raw`\$&`).replaceAll("-",String.raw`\x2d`),EE=({field:e,operator:t,value:n,valueSource:r},{escapeQuotes:o,parseNumbers:a=!0,quoteFieldNamesWith:i=["",""],fieldIdentifierSeparator:l=""}={})=>{const s="field"===r,c="number"==typeof n||"boolean"==typeof n||"bigint"==typeof n||Z_(n,a),u=e=>eE(e,{quoteFieldNamesWith:i,fieldIdentifierSeparator:l});switch(t){case"<":case"<=":case"=":case"!=":case">":case">=":return`${u(e)} ${t} ${s?u(x_(n)):c?x_(n):vE(n,o)}`;case"contains":case"doesNotContain":return wE(`$contains(${u(e)}, ${s?u(x_(n)):vE(n,o)})`,yE(t));case"beginsWith":case"doesNotBeginWith":return wE(s?`$substring(${u(e)}, 0, $length(${u(x_(n))})) = ${u(x_(n))}`:`$contains(${u(e)}, /^${_E(n)}/)`,yE(t));case"endsWith":case"doesNotEndWith":return wE(s?`$substring(${u(e)}, $length(${u(e)}) - $length(${u(x_(n))})) = ${u(x_(n))}`:`$contains(${u(e)}, /${_E(n)}$/)`,yE(t));case"null":return`${u(e)} = null`;case"notNull":return`${u(e)} != null`;case"in":case"notIn":{const r=S_(n);return wE(`${u(e)} in [${r.map((e=>s?`${u(x_(e))}`:Z_(e,a)?`${x_(e)}`:vE(e,o))).join(", ")}]`,yE(t))}case"between":case"notBetween":{const r=S_(n);if(r.length>=2&&!tE(r[0])&&!tE(r[1])){const[n,i]=r,l=Z_(n,!0)?U_(n,{parseNumbers:!0}):NaN,c=Z_(i,!0)?U_(i,{parseNumbers:!0}):NaN;let d=isNaN(l)?s?`${n}`:n:l,f=isNaN(c)?s?`${i}`:i:c;d===l&&f===c&&c= ${s?u(n):p?d:vE(d,o)} and ${u(e)} <= ${s?u(i):p?f:vE(f,o)}`;return"between"===t?`(${h})`:wE(h,!0)}return""}}return""},xE=e=>e.replace(/^(=)$/,"$1=").replace(/^notnull$/i,"!=").replace(/^null$/i,"=="),SE=(e,t)=>/^(does)?not/i.test(e)?{"!":t}:t,kE=({field:e,operator:t,value:n,valueSource:r},{parseNumbers:o}={})=>{const a="field"===r,i={var:e},l=e=>a?{var:`${e}`}:Z_(e,o)?U_(e,{parseNumbers:o}):e;switch(t){case"<":case"<=":case"=":case"!=":case">":case">=":return{[xE(t)]:[i,l(n)]};case"null":case"notNull":return{[("notNull"===t?"!":"=")+"="]:[i,null]};case"in":case"notIn":{const e=S_(n).map((e=>l(e)));return SE(t,{in:[i,e]})}case"between":case"notBetween":{const e=S_(n);if(e.length>=2&&Q_(e[0])&&Q_(e[1])){let[n,r]=e;if(!a&&Z_(n,!0)&&Z_(r,!0)){const e=U_(n,{parseNumbers:!0}),t=U_(r,{parseNumbers:!0});t{const{fieldData:r,format:o,getNextNamedParam:a,parseNumbers:i,paramPrefix:l,paramsKeepPrefix:s,numberedParams:c,quoteFieldNamesWith:u=["",""],concatOperator:d,valueProcessor:f=dE}=t??{},{processedParams:p=[]}=n??{},h="parameterized"===o,m=[],g={},b=e=>h?{sql:e,params:m}:{sql:e,params:g},y=f(e,{parseNumbers:i,quoteFieldNamesWith:u,concatOperator:d,fieldData:r,format:o}),v=q_(e.operator),w=v.toLowerCase(),[_,E]=u;if(!("in"!==w&&"not in"!==w&&"between"!==w&&"not between"!==w||y))return b("");if("is null"===w||"is not null"===w)return b(`${_}${e.field}${E} ${v}`);if("field"===e.valueSource)return b(`${_}${e.field}${E} ${v} ${y}`.trim());if("in"===w||"not in"===w){const t=S_(e.value);if(h){for(const e of t)m.push(Z_(e,i)?U_(e,{parseNumbers:i}):e);return b(`${_}${e.field}${E} ${v} (${t.map(((e,n)=>c?`${l}${p.length+1+t.length-(t.length-n)}`:"?")).join(", ")})`)}const n=[];for(const r of t){const t=a(e.field);n.push(`${l}${t}`),g[`${s?l:""}${t}`]=Z_(r,i)?U_(r,{parseNumbers:i}):r}return b(`${_}${e.field}${E} ${v} (${n.join(", ")})`)}if("between"===w||"not between"===w){const t=S_(e.value,{retainEmptyStrings:!0}),[n,r]=t.slice(0,2).map((e=>Z_(e,i)?U_(e,{parseNumbers:i}):e));if(h)return m.push(n,r),b(`${_}${e.field}${E} ${v} ${c?`${l}${p.length+1}`:"?"} and ${c?`${l}${p.length+2}`:"?"}`);const o=a(e.field),u=a(e.field);return g[`${s?l:""}${o}`]=n,g[`${s?l:""}${u}`]=r,b(`${_}${e.field}${E} ${v} ${l}${o} and ${l}${u}`)}let x=e.value;"string"==typeof e.value&&(x=Z_(e.value,i)?U_(e.value,{parseNumbers:i}):/^'.*'$/g.test(y)?y.replaceAll(/(^'|'$)/g,""):y);let S="";return h?m.push(x):(S=a(e.field),g[`${s?l:""}${S}`]=x),b(`${_}${e.field}${E} ${v} ${h?c?`${l}${p.length+1}`:"?":`${l}${S}`}`.trim())},NE=e=>R_(e)&&"boolean"==typeof e.valid,CE=(e,t,n)=>{if("boolean"==typeof t)return t;if(NE(t))return t.valid;if("function"==typeof n&&!N_(e)){const t=n(e);if("boolean"==typeof t)return t;if(NE(t))return t.valid}return!0},OE=(e,t={})=>{const{escapeQuotes:n,fields:r,parseNumbers:o,quoteFieldNamesWith:a,quoteValuesWith:i,fieldIdentifierSeparator:l}=t,s="field"===e.valueSource,c=e.operator.toLowerCase(),u=i||"'",d=e=>(e=>`${u}${e}${u}`)((e=>((e,t,n)=>n&&"string"==typeof e?e.replaceAll(`${t}`,`${t}${t}`):e)(e,u,n))(e)),f=e=>eE(e,{quoteFieldNamesWith:a,fieldIdentifierSeparator:l});switch(c){case"null":case"notnull":return"";case"between":case"notbetween":return dE(e,t);case"in":case"notin":{const t=S_(e.value);if(0===t.length)return"";const n=t.map((t=>s?f(G_(r??[],e.value)?.label??t):Z_(t,o)?`${x_(t)}`:`${d(t)}`));return n.length<=2?n.join(" or "):`${n.slice(0,-1).join(", ")}, or ${n.at(-1)}`}}return"boolean"==typeof e.value?e.value?"true":"false":s?f(G_(r??[],e.value)?.label??e.value):Z_(e.value,o)?`${x_(e.value)}`:`${d(e.value)}`},AE=(e,t)=>{const{fields:n,fieldData:r,parseNumbers:o,escapeQuotes:a,quoteFieldNamesWith:i=["",""],fieldIdentifierSeparator:l="",quoteValuesWith:s="'",valueProcessor:c=OE,concatOperator:u="||",getOperators:d=()=>[]}=t??{},f=c(e,{fields:n,parseNumbers:o,escapeQuotes:a,quoteFieldNamesWith:i,fieldIdentifierSeparator:l,quoteValuesWith:s,concatOperator:u}),p=e.operator.toLowerCase();return"in"!==p&&"notin"!==p&&"between"!==p&&"notbetween"!==p||f?`${eE(r?.label??e.field,{quoteFieldNamesWith:i,fieldIdentifierSeparator:l})} ${((e,t="value")=>{switch(e.value.toLowerCase()){case"=":return"field"===t?"is the same as the value in":"is";case"!=":return"field"===t?"is not the same as the value in":"is not";case"<":return"field"===t?"is less than the value in":"is less than";case">":return"field"===t?"is greater than the value in":"is greater than";case"<=":return"field"===t?"is less than or equal to the value in":"is less than or equal to";case">=":return"field"===t?"is greater than or equal to the value in":"is greater than or equal to";case"contains":return"field"===t?"contains the value in":"contains";case"beginswith":return"field"===t?"starts with the value in":"starts with";case"endswith":return"field"===t?"ends with the value in":"ends with";case"doesnotcontain":return"field"===t?"does not contain the value in":"does not contain";case"doesnotbeginwith":return"field"===t?"does not start with the value in":"does not start with";case"doesnotendwith":return"field"===t?"does not end with the value in":"does not end with";case"null":return"is null";case"notnull":return"is not null";case"in":return"field"===t?"is the same as a value in":"is one of the values";case"notin":return"field"===t?"is not the same as any value in":"is not one of the values";case"between":return"field"===t?"is between the values in":"is between";case"notbetween":return"field"===t?"is not between the values in":"is not between";default:return e.label}})(G_(M_(d(e.field,{fieldData:r??{name:e.field,value:e.field,label:e.field}})??[]),e.operator)??{name:e.operator,value:e.operator,label:e.operator},e.valueSource)} ${f}`.trim():""},PE={ansi:{},sqlite:{paramsKeepPrefix:!0},oracle:{},mssql:{concatOperator:"+",quoteFieldNamesWith:["[","]"],fieldIdentifierSeparator:"."},mysql:{concatOperator:"CONCAT"},postgresql:{quoteFieldNamesWith:'"',numberedParams:!0,paramPrefix:"$"}};function DE(e,t={}){let n="json",r=dE,o=null,a=["",""],i="",l=()=>!0,s=[],c=()=>[],u={},d="",f=":",p=!1,h=!1,m=!1,g="~",b="~",y="'",v="||";if("string"==typeof t)switch(n=t.toLowerCase(),n){case"natural_language":o=AE;break;case"mongodb":o=iE;break;case"parameterized":case"parameterized_named":o=RE;break;case"cel":o=oE;break;case"spel":o=uE;break;case"jsonlogic":o=kE;break;case"elasticsearch":o=bE;break;case"jsonata":o=EE}else{const e={...PE[t.preset??"ansi"]??null,...t};n=(e.format??"json").toLowerCase();const{valueProcessor:u=null,ruleProcessor:w=null}=e;"function"==typeof w&&(o=w),r="function"==typeof u?(e,t)=>u.length>=3?u(e.field,e.operator,e.value,e.valueSource):u(e,t):"natural_language"===n?OE:"mongodb"===n?o??iE:"cel"===n?o??oE:"spel"===n?o??uE:"jsonlogic"===n?o??kE:"elasticsearch"===n?o??bE:"jsonata"===n?o??EE:dE,a=J_(e.quoteFieldNamesWith),i=e.fieldIdentifierSeparator??"",l=e.validator??(()=>!0),s=M_(e.fields??[]),c=(t,n)=>M_(e.getOperators?.(t,n)??[]),d=e.fallbackExpression??"",f=e.paramPrefix??":",p=!!e.paramsKeepPrefix,h=!!e.numberedParams,m=!!e.parseNumbers,g=e.placeholderFieldName??"~",b=e.placeholderOperatorName??"~",y=e.quoteValuesWith??"'",v=e.concatOperator??"||"}if(d||(d="mongodb"===n?'"$and":[{"$expr":true}]':"cel"===n||"spel"===n?"1 == 1":"natural_language"===n?"1 is 1":"(1 = 1)"),"json"===n||"json_without_ids"===n){const t=m?Xv(e,K_):e;return"json_without_ids"===n?JSON.stringify(t,((e,t)=>"id"===e||"path"===e?void 0:t)):JSON.stringify(t,null,2)}if("function"==typeof l){const t=l(e);if("boolean"==typeof t){if(!1===t)return"parameterized"===n?{sql:d,params:[]}:"parameterized_named"===n?{sql:d,params:{}}:"mongodb"===n?`{${d}}`:"jsonlogic"!==n&&("elasticsearch"===n?{}:d)}else u=t}const w={},_=L_(F_(E=s)?E.flatMap((e=>e.options)):E);var E;for(const e of _)"function"==typeof e.validator&&(w[e.value??e.name]=e.validator);const x=e=>{let t,n;if(e.id&&(t=u[e.id]),_.length>0){const t=_.filter((t=>t.name===e.field));if(t.length>0){const e=t[0];"function"==typeof e.validator&&(n=e.validator)}}return[t,n]};if("sql"===n){const t=(e,l)=>{if(!CE(e,u[e.id??""]))return l?d:"";const c=e.rules.map((l=>{if("string"==typeof l)return l;if(N_(l))return t(l,1===e.rules.length);const[c,u]=x(l);if(!CE(l,c,u)||l.field===g||l.operator===b)return"";const d="value"===(l.valueSource??"value"),f=G_(s,l.field);return"function"==typeof o?o(l,{parseNumbers:m,escapeQuotes:d,quoteFieldNamesWith:a,fieldIdentifierSeparator:i,fieldData:f,format:n,quoteValuesWith:y,concatOperator:v}):((e,t)=>{const{parseNumbers:n,escapeQuotes:r,quoteFieldNamesWith:o=["",""],fieldIdentifierSeparator:a="",quoteValuesWith:i="'",valueProcessor:l=dE,concatOperator:s="||"}=t??{},c=l(e,{parseNumbers:n,escapeQuotes:r,quoteFieldNamesWith:o,fieldIdentifierSeparator:a,quoteValuesWith:i,concatOperator:s}),u=q_(e.operator),d=u.toLowerCase();return"in"!==d&&"not in"!==d&&"between"!==d&&"not between"!==d||c?`${eE(e.field,{quoteFieldNamesWith:o,fieldIdentifierSeparator:a})} ${u} ${c}`.trim():""})(l,{parseNumbers:m,escapeQuotes:d,valueProcessor:r,quoteFieldNamesWith:a,fieldIdentifierSeparator:i,fieldData:f,format:n,quoteValuesWith:y,concatOperator:v})}));return 0===c.length?d:`${e.not?"NOT ":""}(${c.filter(Boolean).join(C_(e)?` ${e.combinator} `:" ")})`};return t(e,!0)}if("parameterized"===n||"parameterized_named"===n){const t="parameterized"===n,c=[],y={},w=new Map,_=e=>{w.has(e)||w.set(e,new Set);const t=`${e}_${w.get(e).size+1}`;return w.get(e).add(t),t},E=e=>{const[t,u]=x(e);if(!CE(e,t,u)||e.field===g||e.operator===b)return"";const E=G_(s,e.field),S=Object.fromEntries([...w.entries()].map((([e,t])=>[e,[...t]]))),k=("function"==typeof o?o:RE)(e,{getNextNamedParam:_,fieldParamNames:S,parseNumbers:m,quoteFieldNamesWith:a,concatOperator:v,fieldIdentifierSeparator:i,fieldData:E,format:n,paramPrefix:f,paramsKeepPrefix:p,numberedParams:h,fallbackExpression:d,valueProcessor:r,fields:s,placeholderFieldName:g,placeholderOperatorName:b,validator:l},{processedParams:c});if(!R_(k))return"";const{sql:R,params:N}=k;if("string"!=typeof R||!R)return"";if("parameterized"===n&&Array.isArray(N))c.push(...N);else if("parameterized_named"===n&&R_(N)){Object.assign(y,N);for(const t of Object.keys(N))w.get(e.field)?.add(t)}return R},S=(e,t)=>{if(!CE(e,u[e.id??""]))return t?d:"";const n=e.rules.map((t=>"string"==typeof t?t:N_(t)?S(t,1===e.rules.length):E(t)));return 0===n.length?d:`${e.not?"NOT ":""}(${n.filter(Boolean).join(C_(e)?` ${e.combinator} `:" ")})`};return t?{sql:S(e,!0),params:c}:{sql:S(e,!0),params:y}}if("mongodb"===n){const t=(e,a)=>{if(!CE(e,u[e.id??""]))return a?d:"";const i=`"$${e.combinator.toLowerCase()}"`;let l=!1;const c=e.rules.map((e=>{if(N_(e)){const n=t(e);return n?(l=!0,/^{.+}$/.test(n)?n:`{${n}}`):""}const[a,i]=x(e);if(!CE(e,a,i)||e.field===g||e.operator===b)return"";const c=G_(s,e.field);return(o??r)(e,{parseNumbers:m,fieldData:c,format:n})})).filter(Boolean);return c.length>0?1!==c.length||l?`${i}:[${c.join(",")}]`:c[0]:d},a=C_(e)?e:D_(e),i=t(a,!0);return/^{.+}$/.test(i)?i:`{${i}}`}if("cel"===n){const t=(e,a)=>{if(!CE(e,u[e.id??""]))return a?d:"";const i=e.rules.map((e=>{if("string"==typeof e)return Y_[e];if(N_(e))return t(e);const[a,i]=x(e);if(!CE(e,a,i)||e.field===g||e.operator===b)return"";const l=G_(s,e.field);return(o??r)(e,{parseNumbers:m,escapeQuotes:"value"===(e.valueSource??"value"),fieldData:l,format:n})})).filter(Boolean).join(C_(e)?` ${Y_[e.combinator]} `:" "),[l,c]=e.not||!a?[(e.not?"!":"")+"(",")"]:["",""];return i?`${l}${i}${c}`:d};return t(e,!0)}if("spel"===n){const t=(e,a)=>{if(!CE(e,u[e.id??""]))return a?d:"";const i=e.rules.map((e=>{if("string"==typeof e)return e;if(N_(e))return t(e);const[a,i]=x(e);if(!CE(e,a,i)||e.field===g||e.operator===b)return"";const l=G_(s,e.field);return(o??r)(e,{parseNumbers:m,escapeQuotes:"value"===(e.valueSource??"value"),fieldData:l,format:n})})).filter(Boolean).join(C_(e)?` ${e.combinator} `:" "),[l,c]=e.not||!a?[(e.not?"!":"")+"(",")"]:["",""];return i?`${l}${i}${c}`:d};return t(e,!0)}if("jsonata"===n){const t=(e,l)=>{if(!CE(e,u[e.id??""]))return l?d:"";const c=e.rules.map((e=>{if("string"==typeof e)return e;if(N_(e))return t(e);const[l,c]=x(e);if(!CE(e,l,c)||e.field===g||e.operator===b)return"";const u=G_(s,e.field);return(o??r)(e,{parseNumbers:m,escapeQuotes:"value"===(e.valueSource??"value"),fieldData:u,format:n,quoteFieldNamesWith:a,fieldIdentifierSeparator:i})})).filter(Boolean).join(C_(e)?` ${e.combinator} `:" "),[f,p]=e.not||!l?[(e.not?"$not":"")+"(",")"]:["",""];return c?`${f}${c}${p}`:d};return t(e,!0)}if("jsonlogic"===n){const t=C_(e)?e:D_(e),a=(e,t)=>{if(!CE(e,u[e.id??""]))return!1;const i=e.rules.map((e=>{if(N_(e))return a(e);const[t,i]=x(e);if(!CE(e,t,i)||e.field===g||e.operator===b)return!1;const l=G_(s,e.field);return(o??r)(e,{parseNumbers:m,fieldData:l,format:n})})).filter(Boolean);if(0===i.length)return!1;const l={[e.combinator]:i};return e.not?{"!":l}:l};return a(t,!0)}if("elasticsearch"===n){const t=C_(e)?e:D_(e),a=e=>{if(!CE(e,u[e.id??""]))return!1;const t=e.rules.map((e=>{if(N_(e))return a(e);const[t,i]=x(e);if(!CE(e,t,i)||e.field===g||e.operator===b)return!1;const l=G_(s,e.field);return(o??r)(e,{parseNumbers:m,fieldData:l,format:n})})).filter(Boolean);return 0!==t.length&&{bool:e.not?{must_not:"or"===e.combinator?{bool:{should:t}}:t}:{["or"===e.combinator?"should":"must"]:t}}},i=a(t);return!1===i?{}:i}if("natural_language"===n){const t=(e,l)=>{if(!CE(e,u[e.id??""]))return l?d:"";const f=e.rules.map((l=>{if("string"==typeof l)return`, ${l} `;if(N_(l))return t(l,1===e.rules.length);const[u,d]=x(l);if(!CE(l,u,d)||l.field===g||l.operator===b)return"";const f="value"===(l.valueSource??"value"),p=G_(s,l.field);return"function"==typeof o?o(l,{fields:s,parseNumbers:m,escapeQuotes:f,quoteFieldNamesWith:a,fieldIdentifierSeparator:i,fieldData:p,format:n,quoteValuesWith:y,concatOperator:v,getOperators:c}):AE(l,{fields:s,parseNumbers:m,escapeQuotes:f,valueProcessor:r,quoteFieldNamesWith:a,fieldIdentifierSeparator:i,fieldData:p,format:n,quoteValuesWith:y,concatOperator:v,getOperators:c})}));if(0===f.length)return d;const p=e.not||!l?"(":"",h=e.not||!l?`) is${e.not?" not":""} true`:"";return`${p}${f.filter(Boolean).join(C_(e)?`, ${e.combinator} `:"")}${h}`};return t(e,!0)}return""}var TE={default:dE,mongodb:iE,cel:oE,spel:uE},IE=e=>(t,n,r,o)=>TE[e]({field:t,operator:n,value:r,valueSource:o},{parseNumbers:!1}),jE=(IE("default"),IE("mongodb"),IE("cel"),IE("spel"),(e,t)=>{let n=t,r=0;for(;re.slice(0,-1),$E=(e,t)=>e.length===t.length&&e.every(((e,n)=>e===t[n])),LE=(e,t)=>{let n=!!t.disabled,r=t,o=0;for(;o$E([],e.path)?"Query builder":`Rule group at path ${e.path.join("-")}`,FE=globalThis.crypto,WE=()=>"00-0-4-2-000".replaceAll(/[^-]/g,(e=>(65536*(Math.random()+Math.trunc(e))>>parseInt(e)).toString(16).padStart(4,"0")));if(FE)if("function"==typeof FE.randomUUID)WE=()=>FE.randomUUID();else if("function"==typeof FE.getRandomValues){const e="89ab",t=new Uint32Array(32);WE=()=>{FE.getRandomValues(t);let n=(t[0]%16).toString(16);for(let r=1;r<32;r++)n=12===r?`${n}4`:16===r?`${n}${e[t[17]%4]}`:`${n}${(t[r]%16).toString(16)}`,7!==r&&11!==r&&15!==r&&19!==r||(n=`${n}-`);return n}}var GE=e=>{const t="boolean"==typeof e?e:"object"==typeof e&&null!==e?e.valid:null;return"boolean"==typeof t?t?Nw:Cw:""},BE=["value"],VE={name:"name",value:"name",valueSources:null,label:"label"},HE=(e,t)=>Jw(t.map((t=>Jw(t?.[e])))),UE=Object.keys,qE=Object.entries,XE=(e,t,n)=>{const r=qE(t).map((([t,[r,o]])=>[t,r??o??(n?Sw:{})[e]?.[t]])).filter((e=>!!e[1]));return r.length>0?{[e]:Object.fromEntries(r)}:void 0},YE=(e,{idGenerator:t=WE}={})=>Xv(e,(e=>{e.id||(e.id=t())})),KE=(e,{idGenerator:t=WE}={})=>Xv(e,(e=>{e.id||(e.id=t()),e.rules=e.rules.map((e=>"string"==typeof e?e:N_(e)?KE(e,{idGenerator:t}):YE(e,{idGenerator:t})))})),QE=(e,{idGenerator:t=WE}={})=>structuredClone({...e,id:t()}),ZE=(e,{idGenerator:t=WE}={})=>{if(!R_(e))return e;if(!N_(e))return structuredClone({...e,id:t()});if(C_(e)){const n=e.rules.map((e=>N_(e)?ZE(e,{idGenerator:t}):QE(e,{idGenerator:t})));return{...e,id:t(),rules:n}}const n=e.rules.map((e=>"string"==typeof e?e:N_(e)?ZE(e,{idGenerator:t}):QE(e,{idGenerator:t})));return{...e,id:t(),rules:n}},JE=(e,t,n,{combinators:r=Rw,combinatorPreceding:o,idGenerator:a=WE}={})=>Xv(e,(e=>{const i=jE(n,e);if(i&&N_(i)){if(O_(i)&&i.rules.length>0){const e=i.rules.at(-2);i.rules.push(o??("string"==typeof e?e:B_(r)))}i.rules.push(((e,{idGenerator:t=WE}={})=>N_(e)?KE(e,{idGenerator:t}):YE(e,{idGenerator:t}))(t,{idGenerator:a}))}})),ex=(e,t,n)=>((e,t,n)=>e?((e,t)=>!1!==e&&(!!e||!1!==t))(t,n):((e,t)=>!!e||!1!==e&&!!t)(t,n))(e,t,n),tx=()=>null,nx=(0,ht.forwardRef)(tx),rx={},ox={},ax={},ix=[],lx={},sx=()=>null,cx=()=>"",ux=()=>!0,dx=(...e)=>{console.log(...e)};function fx(e,t){const{query:n,defaultQuery:r,getValueEditorSeparator:o=sx,getRuleClassname:a=cx,getRuleGroupClassname:i=cx,onAddRule:l=ux,onAddGroup:s=ux,onMoveRule:c=ux,onMoveGroup:u=ux,onRemove:d=ux,onQueryChange:f,showCombinatorsBetweenRules:p=!1,showNotToggle:h=!1,showShiftActions:m=!1,showCloneButtons:g=!1,showLockButtons:b=!1,suppressStandardClassnames:y=!1,resetOnFieldChange:v=!0,resetOnOperatorChange:w=!1,autoSelectField:_=!0,autoSelectOperator:E=!0,addRuleToNewGroups:x=!1,listsAsArrays:S=!1,parseNumbers:k=!1,disabled:R=!1,validator:N,onLog:C=dx,idGenerator:O,accessibleDescriptionGenerator:A=zE}=e,{qbId:P,rqbContext:D,fields:T,fieldMap:I,combinators:j,getOperatorsMain:M,getRuleDefaultOperator:$,getValueEditorTypeMain:L,getValueSourcesMain:z,getValuesMain:F,getRuleDefaultValue:W,getInputTypeMain:G,createRule:B,createRuleGroup:V}=t,{controlClassnames:H,controlElements:U,debugMode:q,enableDragAndDrop:X,enableMountQueryChange:Y,translations:K}=D,Q=!!p,Z=!!h,J=!!m,ee=!!g,te=!!b,ne=!!v,re=!!w,oe=!!_,ae=!!E,ie=!!x,le=!!S,se=!!y,ce=(0,ht.useCallback)(((...e)=>{q&&C(...e)}),[q,C]);(e=>{b_();const{defaultQuery:t,queryProp:n}=e;(e=>{const t=(0,ht.useRef)({value:e,prev:null}),n=t.current.value;e!==n&&(t.current={value:e,prev:n}),t.current.prev})(!!n)})({defaultQuery:r,queryProp:n});const ue=y_(),de=b_(),fe=(0,ht.useMemo)((()=>m_(P)),[P]),pe=(e=>{const t=ht.useContext(gx);return h_(e,void 0)??t?.initialQuery})(fe),he=(0,ht.useCallback)((()=>fe(ue.getState())),[ue,fe]),me=(0,ht.useMemo)((()=>V()),[V]),ge=n??pe??r??me,be=ge.id?ge:KE(ge,{idGenerator:O}),[ye]=(0,ht.useState)(be),ve=(0,ht.useMemo)((()=>({...D,initialQuery:ye})),[D,ye]);(0,ht.useEffect)((()=>{n&&!Object.is(n,pe)&&de(g_({payload:{qbId:P,query:n},onQueryChange:void 0}))}),[n,P,pe,de]);const we=(0,ht.useMemo)((()=>O_(be)),[be]),_e=!!e.independentCombinators&&!we;w_(0,_e||!_e&&e.independentCombinators);const Ee=(0,ht.useRef)(!1);(0,ht.useEffect)((()=>{Ee.current||(Ee.current=!0,de(g_({payload:{qbId:P,query:be},onQueryChange:Y&&"function"==typeof f?f:void 0})))}),[Y,f,P,de,be]);const xe=(0,ht.useCallback)((e=>{de(g_({payload:{qbId:P,query:e},onQueryChange:f}))}),[f,P,de]),Se=(0,ht.useMemo)((()=>Array.isArray(R)&&R||ix),[R]),ke=!0===R,Re=(0,ht.useMemo)((()=>be.disabled||Se.some((e=>0===e.length))),[Se,be.disabled]),Ne=(0,ht.useCallback)(((e,t,n)=>{const r=m_(P)(ue.getState());if(!r)return;if(LE(t,r)||ke)return void ce({qbId:P,type:Yw,rule:e,parentPath:t,query:r});const o=l(e,t,r,n);if(!o)return void ce({qbId:P,type:"onAddRule callback returned false",rule:e,parentPath:t,query:r});const a=!0===o?e:o,i=JE(r,a,t,{combinators:j,combinatorPreceding:a.combinatorPreceding??void 0});ce({qbId:P,type:Qw,query:r,newQuery:i,newRule:a,parentPath:t}),xe(i)}),[P,ue,ke,l,j,xe,ce]),Ce=(0,ht.useCallback)(((e,t,n)=>{const r=m_(P)(ue.getState());if(!r)return;if(LE(t,r)||ke)return void ce({qbId:P,type:Yw,ruleGroup:e,parentPath:t,query:r});const o=s(e,t,r,n);if(!o)return void ce({qbId:P,type:"onAddGroup callback returned false",ruleGroup:e,parentPath:t,query:r});const a=!0===o?e:o,i=JE(r,a,t,{combinators:j,combinatorPreceding:a.combinatorPreceding??void 0});ce({qbId:P,type:Qw,query:r,newQuery:i,newGroup:a,parentPath:t}),xe(i)}),[P,ue,ke,s,j,ce,xe]),Oe=(0,ht.useCallback)(((e,t,n)=>{const r=m_(P)(ue.getState());if(!r)return;if(LE(n,r)&&"disabled"!==e||ke)return void ce({qbId:P,type:Kw,path:n,prop:e,value:t,query:r});const o=((e,t,n,r,{resetOnFieldChange:o=!0,resetOnOperatorChange:a=!1,getRuleDefaultOperator:i=()=>"=",getValueSources:l=()=>["value"],getRuleDefaultValue:s=()=>""}={})=>Xv(e,(e=>{if("combinator"===t&&!C_(e)){const t=jE(ME(r),e).rules;return void(r.at(-1)%2==1&&(t[r.at(-1)]=n))}const c=jE(r,e);if(!c)return;const u=N_(c);if(c[t]===n)return;if("valueSource"!==t&&(c[t]=n),u)return;let d=!1,f=!1;o&&"field"===t&&(c.operator=i(n),d=!0,f=!0),a&&"operator"===t&&(d=!0,f=!0);const p=l(c.field,c.operator)[0];(d&&c.valueSource&&p!==c.valueSource||"valueSource"===t&&n!==c.valueSource)&&(f=!!c.valueSource||!c.valueSource&&n!==p,c.valueSource=d?p:n),f&&(c.value=s(c))})))(r,e,t,n,{resetOnFieldChange:ne,resetOnOperatorChange:re,getRuleDefaultOperator:$,getValueSources:z,getRuleDefaultValue:W});ce({qbId:P,type:"rule or group updated",query:r,newQuery:o,prop:e,value:t,path:n}),xe(o)}),[P,ue,ke,ne,re,$,z,W,ce,xe]),Ae=(0,ht.useCallback)(((e,t)=>{const n=m_(P)(ue.getState());if(!n)return;if(LE(e,n)||ke)return void ce({qbId:P,type:Kw,path:e,query:n});const r=jE(e,n);if(r)if(d(r,e,n,t)){const t=((e,t)=>0===t.length||!C_(e)&&!jE(t,e)?e:Xv(e,(e=>{const n=t.at(-1),r=jE(ME(t),e);if(r&&N_(r))if(!C_(r)&&r.rules.length>1){const e=0===n?0:n-1;r.rules.splice(e,2)}else r.rules.splice(n,1)})))(n,e);ce({qbId:P,type:"rule or group removed",query:n,newQuery:t,path:e,ruleOrGroup:r}),xe(t)}else ce({qbId:P,type:"onRemove callback returned false",ruleOrGroup:r,path:e,query:n})}),[P,ue,ke,ce,d,xe]),Pe=(0,ht.useCallback)(((e,t,n,r)=>{const o=m_(P)(ue.getState());if(!o)return;if(LE(e,o)||ke)return void ce({qbId:P,type:Kw,oldPath:e,newPath:t,query:o});const a=((e,t,n,{clone:r=!1,combinators:o=Rw,idGenerator:a=WE}={})=>{const i=((e,t,n)=>{if(Array.isArray(n))return n;const r=O_(e);if("up"===n){if($E(t,[0]))return t;if(0===t.at(-1)){const e=ME(t);return[...ME(e),Math.max(0,e.at(-1)-(r?1:0))]}{const n=[...ME(t),Math.max(0,t.at(-1)-(r?2:1))],o=jE(n,e);return N_(o)?[...n,o.rules.length]:[...ME(t),Math.max(0,t.at(-1)-(r?3:1))]}}if("down"===n){if($E([e.rules.length-1],t))return t;if(t.at(-1)===jE(ME(t),e).rules.length-1){const e=ME(t);return[...ME(e),e.at(-1)+1]}{const n=[...ME(t),t.at(-1)+(r?2:1)],o=jE(n,e);return N_(o)?[...n,0]:[...ME(t),t.at(-1)+(r?3:2)]}}return t})(e,t,n);if(0===t.length||$E(t,i)||!jE(ME(i),e))return e;const l=jE(t,e);if(!l)return e;const s=r?ZE(l,{idGenerator:a}):l;return Xv(e,(e=>{const n=O_(e),a=jE(ME(t),e),l=t.at(-1),c=n&&l>0?a.rules[l-1]:null,u=n&&l{const n=[],r=ME(e),o=ME(t);let a=0;for(;at[f.length]&&(d[f.length]-=n?2:1);const p=ME(d),h=jE(p,e),m=d.at(-1),g=(...e)=>h.rules.splice(m,0,...e);if(0!==h.rules.length&&n)if(0===m)if(0===l&&u)g(s,u);else{const e=h.rules[1]??c??B_(o);g(s,e)}else g(c||(h.rules[m-2]??u??B_(o)),s);else g(s)}))})(o,e,t,{clone:n,combinators:j}),i=jE(e,o),l=N_(i),s=(l?u:c)(i,e,t,o,a,{clone:n,combinators:j},r);if(!s)return void ce({qbId:P,type:l?"onMoveGroup callback returned false":"onMoveRule callback returned false",ruleOrGroup:i,oldPath:e,newPath:t,clone:n,query:o,nextQuery:a});const d=N_(s)?s:a;ce({qbId:P,type:"rule or group moved",query:o,newQuery:d,oldPath:e,newPath:t,clone:n}),xe(d)}),[P,ue,ke,j,u,c,ce,xe]),{validationResult:De,validationMap:Te}=(0,ht.useMemo)((()=>{const e="function"==typeof N&&be?N(be):ox;return{validationResult:e,validationMap:"boolean"==typeof e?ax:e}}),[be,N]),Ie=(0,ht.useMemo)((()=>X?"enabled":"disabled"),[X]),je=(0,ht.useMemo)((()=>we||Q?"enabled":"disabled"),[we,Q]),Me=(0,ht.useMemo)((()=>"string"==typeof be.combinator?{combinator:be.combinator}:lx),[be.combinator]),$e=(0,ht.useMemo)((()=>Jw(se||"queryBuilder",Jw(H.queryBuilder),ke&&H.disabled,"boolean"==typeof De&&De&&H.valid,"boolean"==typeof De&&!De&&H.invalid,se||{[Iw]:ke,[Nw]:"boolean"==typeof De&&De,[Cw]:"boolean"==typeof De&&!De})),[H.disabled,H.invalid,H.queryBuilder,H.valid,ke,se,De]),Le=(0,ht.useMemo)((()=>({addRuleToNewGroups:ie,accessibleDescriptionGenerator:A,autoSelectField:oe,autoSelectOperator:ae,classNames:H,combinators:j,controls:U,createRule:B,createRuleGroup:V,disabledPaths:Se,enableDragAndDrop:X,fieldMap:I,fields:T,dispatchQuery:xe,getQuery:he,getInputType:G,getOperators:M,getRuleClassname:a,getRuleGroupClassname:i,getValueEditorSeparator:o,getValueEditorType:L,getValues:F,getValueSources:z,independentCombinators:we,listsAsArrays:le,parseNumbers:k,qbId:P,showCloneButtons:ee,showCombinatorsBetweenRules:Q,showLockButtons:te,showNotToggle:Z,showShiftActions:J,suppressStandardClassnames:se,validationMap:Te})),[A,ie,oe,ae,j,H,U,B,V,Se,xe,X,I,T,G,M,he,a,i,o,L,F,z,we,le,k,P,ee,Q,te,Z,J,se,Te]);return{actions:(0,ht.useMemo)((()=>({moveRule:Pe,onGroupAdd:Ce,onGroupRemove:Ae,onPropChange:Oe,onRuleAdd:Ne,onRuleRemove:Ae})),[Pe,Ce,Oe,Ne,Ae]),rootGroup:be,rootGroupDisabled:Re,queryDisabled:ke,rqbContext:ve,schema:Le,translations:K,wrapperClassName:$e,dndEnabledAttr:Ie,inlineCombinatorsAttr:je,combinatorPropObject:Me}}var px=(e,t,n)=>{const r=B_(e);if("between"===t.operator||"notBetween"===t.operator){const e=[r,r];return n?e:E_(e.map((e=>e??"")),",")}return r},hx=e=>{const[t]=(0,ht.useState)(WE),{fields:n,baseField:r,operators:o,baseOperator:a,combinators:i=Rw,baseCombinator:l,translations:s,enableMountQueryChange:c=!0,controlClassnames:u,controlElements:d,getDefaultField:f,getDefaultOperator:p,getDefaultValue:h,getOperators:m,getValueEditorType:g,getValueSources:b,getInputType:y,getValues:v,autoSelectField:w=!0,autoSelectOperator:_=!0,addRuleToNewGroups:E=!1,enableDragAndDrop:x,listsAsArrays:S=!1,debugMode:k=!1,idGenerator:R=WE}=e,N=o??kw,[C]=(0,ht.useState)(e.query??e.defaultQuery),O=(({finalize:e,...t})=>{const n=(0,ht.useContext)(gx),r=ex(!1,t.debugMode,n.debugMode),o=e?r:t.debugMode??n.debugMode,a=ex(!0,t.enableMountQueryChange,n.enableMountQueryChange),i=e?a:t.enableMountQueryChange??n.enableMountQueryChange,l=ex(!1,t.enableDragAndDrop,n.enableDragAndDrop)&&!1!==n.enableDragAndDrop,s=e?l:t.enableDragAndDrop??n.enableDragAndDrop,c=(0,ht.useMemo)((()=>((...e)=>({queryBuilder:HE("queryBuilder",e),ruleGroup:HE("ruleGroup",e),header:HE("header",e),body:HE("body",e),combinators:HE("combinators",e),addRule:HE("addRule",e),addGroup:HE("addGroup",e),cloneRule:HE("cloneRule",e),cloneGroup:HE("cloneGroup",e),removeGroup:HE("removeGroup",e),rule:HE("rule",e),fields:HE("fields",e),operators:HE("operators",e),value:HE("value",e),removeRule:HE("removeRule",e),notToggle:HE("notToggle",e),shiftActions:HE("shiftActions",e),dragHandle:HE("dragHandle",e),lockRule:HE("lockRule",e),lockGroup:HE("lockGroup",e),valueSource:HE("valueSource",e),actionElement:HE("actionElement",e),valueSelector:HE("valueSelector",e),betweenRules:HE("betweenRules",e),valid:HE("valid",e),invalid:HE("invalid",e),dndDragging:HE("dndDragging",e),dndOver:HE("dndOver",e),dndCopy:HE("dndCopy",e),disabled:HE("disabled",e),valueListItem:HE("valueListItem",e),branches:HE("branches",e)}))(e?Object.assign({},Mw):rx,n.controlClassnames,t.controlClassnames)),[n.controlClassnames,t.controlClassnames,e]),u=(0,ht.useMemo)((()=>({actionElement:c.actionElement,addGroup:c.addGroup,addRule:c.addRule,body:c.body,cloneGroup:c.cloneGroup,cloneRule:c.cloneRule,combinators:c.combinators,dragHandle:c.dragHandle,fields:c.fields,header:c.header,lockGroup:c.lockGroup,lockRule:c.lockRule,notToggle:c.notToggle,operators:c.operators,queryBuilder:c.queryBuilder,removeGroup:c.removeGroup,removeRule:c.removeRule,rule:c.rule,ruleGroup:c.ruleGroup,shiftActions:c.shiftActions,value:c.value,valueSelector:c.valueSelector,valueSource:c.valueSource,betweenRules:c.betweenRules,valid:c.valid,invalid:c.invalid,dndDragging:c.dndDragging,dndOver:c.dndOver,dndCopy:c.dndCopy,disabled:c.disabled,valueListItem:c.valueListItem,branches:c.branches})),[c.actionElement,c.addGroup,c.addRule,c.betweenRules,c.body,c.branches,c.cloneGroup,c.cloneRule,c.combinators,c.disabled,c.dndCopy,c.dndDragging,c.dndOver,c.dragHandle,c.fields,c.header,c.invalid,c.lockGroup,c.lockRule,c.notToggle,c.operators,c.queryBuilder,c.removeGroup,c.removeRule,c.rule,c.ruleGroup,c.shiftActions,c.valid,c.value,c.valueListItem,c.valueSelector,c.valueSource]),d=n.controlElements??rx,f=t.controlElements??rx,p=(0,ht.useCallback)(((t,n,r)=>{const o="dragHandle"===t?nx:tx,a=(t.endsWith("Action")&&f.actionElement?f.actionElement:void 0)??(t.endsWith("Selector")&&f.valueSelector?f.valueSelector:void 0),i=(t.endsWith("Action")&&d.actionElement?d.actionElement:void 0)??(t.endsWith("Selector")&&d.valueSelector?d.valueSelector:void 0),l=null===n?o:n??(e?a:void 0)??(null===r?o:r??(e?i:void 0));return l?{[t]:l}:e?{[t]:Nx[t]}:rx}),[d.actionElement,d.valueSelector,e,f.actionElement,f.valueSelector]),h=(0,ht.useMemo)((()=>Object.assign({},p("addGroupAction",f.addGroupAction,d.addGroupAction),p("addRuleAction",f.addRuleAction,d.addRuleAction),p("cloneGroupAction",f.cloneGroupAction,d.cloneGroupAction),p("cloneRuleAction",f.cloneRuleAction,d.cloneRuleAction),p("combinatorSelector",f.combinatorSelector,d.combinatorSelector),p("dragHandle",f.dragHandle,d.dragHandle),p("fieldSelector",f.fieldSelector,d.fieldSelector),p("inlineCombinator",f.inlineCombinator,d.inlineCombinator),p("lockGroupAction",f.lockGroupAction,d.lockGroupAction),p("lockRuleAction",f.lockRuleAction,d.lockRuleAction),p("notToggle",f.notToggle,d.notToggle),p("operatorSelector",f.operatorSelector,d.operatorSelector),p("removeGroupAction",f.removeGroupAction,d.removeGroupAction),p("removeRuleAction",f.removeRuleAction,d.removeRuleAction),p("shiftActions",f.shiftActions,d.shiftActions),{valueEditor:null===f.valueEditor?tx:f.valueEditor??(null===d.valueEditor?tx:d.valueEditor)??Nx.valueEditor},p("valueSourceSelector",f.valueSourceSelector,d.valueSourceSelector),p("rule",f.rule,d.rule),p("ruleGroup",f.ruleGroup,d.ruleGroup),p("ruleGroupBodyElements",f.ruleGroupBodyElements,d.ruleGroupBodyElements),p("ruleGroupHeaderElements",f.ruleGroupHeaderElements,d.ruleGroupHeaderElements),{actionElement:f.actionElement??d.actionElement??(e?Nx.actionElement:void 0)},{valueSelector:f.valueSelector??d.valueSelector??(e?Nx.valueSelector:void 0)})),[d.actionElement,d.addGroupAction,d.addRuleAction,d.cloneGroupAction,d.cloneRuleAction,d.combinatorSelector,d.dragHandle,d.fieldSelector,d.inlineCombinator,d.lockGroupAction,d.lockRuleAction,d.notToggle,d.operatorSelector,d.removeGroupAction,d.removeRuleAction,d.rule,d.ruleGroup,d.ruleGroupBodyElements,d.ruleGroupHeaderElements,d.shiftActions,d.valueEditor,d.valueSelector,d.valueSourceSelector,p,e,f.actionElement,f.addGroupAction,f.addRuleAction,f.cloneGroupAction,f.cloneRuleAction,f.combinatorSelector,f.dragHandle,f.fieldSelector,f.inlineCombinator,f.lockGroupAction,f.lockRuleAction,f.notToggle,f.operatorSelector,f.removeGroupAction,f.removeRuleAction,f.rule,f.ruleGroup,f.ruleGroupBodyElements,f.ruleGroupHeaderElements,f.shiftActions,f.valueEditor,f.valueSelector,f.valueSourceSelector]),m=t.translations??rx,g=n.translations??rx;return{controlClassnames:u,controlElements:h,debugMode:o,enableDragAndDrop:s,enableMountQueryChange:i,translations:(0,ht.useMemo)((()=>Object.assign(e?Object.assign({},Sw):{},XE("addGroup",{label:[m.addGroup?.label,g.addGroup?.label],title:[m.addGroup?.title,g.addGroup?.title]},e),XE("addRule",{label:[m.addRule?.label,g.addRule?.label],title:[m.addRule?.title,g.addRule?.title]},e),XE("cloneRule",{label:[m.cloneRule?.label,g.cloneRule?.label],title:[m.cloneRule?.title,g.cloneRule?.title]},e),XE("cloneRuleGroup",{label:[m.cloneRuleGroup?.label,g.cloneRuleGroup?.label],title:[m.cloneRuleGroup?.title,g.cloneRuleGroup?.title]},e),XE("combinators",{title:[m.combinators?.title,g.combinators?.title]},e),XE("dragHandle",{label:[m.dragHandle?.label,g.dragHandle?.label],title:[m.dragHandle?.title,g.dragHandle?.title]},e),XE("fields",{placeholderGroupLabel:[m.fields?.placeholderGroupLabel,g.fields?.placeholderGroupLabel],placeholderLabel:[m.fields?.placeholderLabel,g.fields?.placeholderLabel],placeholderName:[m.fields?.placeholderName,g.fields?.placeholderName],title:[m.fields?.title,g.fields?.title]},e),XE("lockGroup",{label:[m.lockGroup?.label,g.lockGroup?.label],title:[m.lockGroup?.title,g.lockGroup?.title]},e),XE("lockGroupDisabled",{label:[m.lockGroupDisabled?.label,g.lockGroupDisabled?.label],title:[m.lockGroupDisabled?.title,g.lockGroupDisabled?.title]},e),XE("lockRule",{label:[m.lockRule?.label,g.lockRule?.label],title:[m.lockRule?.title,g.lockRule?.title]},e),XE("lockRuleDisabled",{label:[m.lockRuleDisabled?.label,g.lockRuleDisabled?.label],title:[m.lockRuleDisabled?.title,g.lockRuleDisabled?.title]},e),XE("notToggle",{label:[m.notToggle?.label,g.notToggle?.label],title:[m.notToggle?.title,g.notToggle?.title]},e),XE("operators",{placeholderGroupLabel:[m.operators?.placeholderGroupLabel,g.operators?.placeholderGroupLabel],placeholderLabel:[m.operators?.placeholderLabel,g.operators?.placeholderLabel],placeholderName:[m.operators?.placeholderName,g.operators?.placeholderName],title:[m.operators?.title,g.operators?.title]},e),XE("removeGroup",{label:[m.removeGroup?.label,g.removeGroup?.label],title:[m.removeGroup?.title,g.removeGroup?.title]},e),XE("removeRule",{label:[m.removeRule?.label,g.removeRule?.label],title:[m.removeRule?.title,g.removeRule?.title]},e),XE("shiftActionDown",{label:[m.shiftActionDown?.label,g.shiftActionDown?.label],title:[m.shiftActionDown?.title,g.shiftActionDown?.title]},e),XE("shiftActionUp",{label:[m.shiftActionUp?.label,g.shiftActionUp?.label],title:[m.shiftActionUp?.title,g.shiftActionUp?.title]},e),XE("value",{title:[m.value?.title,g.value?.title]},e),XE("valueSourceSelector",{title:[m.valueSourceSelector?.title,g.valueSourceSelector?.title]},e))),[m.addGroup?.label,m.addGroup?.title,m.addRule?.label,m.addRule?.title,m.cloneRule?.label,m.cloneRule?.title,m.cloneRuleGroup?.label,m.cloneRuleGroup?.title,m.combinators?.title,m.dragHandle?.label,m.dragHandle?.title,m.fields?.placeholderGroupLabel,m.fields?.placeholderLabel,m.fields?.placeholderName,m.fields?.title,m.lockGroup?.label,m.lockGroup?.title,m.lockGroupDisabled?.label,m.lockGroupDisabled?.title,m.lockRule?.label,m.lockRule?.title,m.lockRuleDisabled?.label,m.lockRuleDisabled?.title,m.notToggle?.label,m.notToggle?.title,m.operators?.placeholderGroupLabel,m.operators?.placeholderLabel,m.operators?.placeholderName,m.operators?.title,m.removeGroup?.label,m.removeGroup?.title,m.removeRule?.label,m.removeRule?.title,m.shiftActionDown?.label,m.shiftActionDown?.title,m.shiftActionUp?.label,m.shiftActionUp?.title,m.value?.title,m.valueSourceSelector?.title,e,g.addGroup?.label,g.addGroup?.title,g.addRule?.label,g.addRule?.title,g.cloneRule?.label,g.cloneRule?.title,g.cloneRuleGroup?.label,g.cloneRuleGroup?.title,g.combinators?.title,g.dragHandle?.label,g.dragHandle?.title,g.fields?.placeholderGroupLabel,g.fields?.placeholderLabel,g.fields?.placeholderName,g.fields?.title,g.lockGroup?.label,g.lockGroup?.title,g.lockGroupDisabled?.label,g.lockGroupDisabled?.title,g.lockRule?.label,g.lockRule?.title,g.lockRuleDisabled?.label,g.lockRuleDisabled?.title,g.notToggle?.label,g.notToggle?.title,g.operators?.placeholderGroupLabel,g.operators?.placeholderLabel,g.operators?.placeholderName,g.operators?.title,g.removeGroup?.label,g.removeGroup?.title,g.removeRule?.label,g.removeRule?.title,g.shiftActionDown?.label,g.shiftActionDown?.title,g.shiftActionUp?.label,g.shiftActionUp?.title,g.value?.title,g.valueSourceSelector?.title]),initialQuery:t.initialQuery,qbId:t.qbId}})({controlClassnames:u,controlElements:d,debugMode:k,enableDragAndDrop:x,enableMountQueryChange:c,translations:s,initialQuery:C,qbId:t,finalize:!0}),{translations:A}=O,P=(0,ht.useMemo)((()=>({id:A.fields.placeholderName,name:A.fields.placeholderName,value:A.fields.placeholderName,label:A.fields.placeholderLabel})),[A.fields.placeholderLabel,A.fields.placeholderName]),D=(0,ht.useMemo)((()=>n??[P]),[P,n]),T=(0,ht.useMemo)((()=>{const e=Array.isArray(D)?M_(D,r):UE($_(D,r)).map((e=>({...D[e],name:e,value:e}))).sort(((e,t)=>e.label.localeCompare(t.label)));return W_(e)?z_(w?e:[{label:A.fields.placeholderGroupLabel,options:[P]},...e]):L_(w?e:[P,...e])}),[w,r,P,D,A.fields.placeholderGroupLabel]),I=(0,ht.useMemo)((()=>{if(!Array.isArray(D)){const e=$_(D,r);return w?e:{...e,[A.fields.placeholderName]:P}}const e={};if(W_(T))for(const t of T)for(const n of t.options)e[n.value??n.name]=j_(n,r);else for(const t of T)e[t.value??t.name]=j_(t,r);return e}),[w,r,P,T,D,A.fields.placeholderName]),j=(0,ht.useMemo)((()=>M_(i,l)),[l,i]),M=(0,ht.useMemo)((()=>({id:A.operators.placeholderName,name:A.operators.placeholderName,value:A.operators.placeholderName,label:A.operators.placeholderLabel})),[A.operators.placeholderLabel,A.operators.placeholderName]),$=(0,ht.useCallback)(((e,{fieldData:t})=>{let n=M_(N,a);if(t?.operators)n=M_(t.operators,a);else if(m){const r=m(e,{fieldData:t});r&&(n=M_(r,a))}return _||(n=W_(n)?[{label:A.operators.placeholderGroupLabel,options:[M]},...n]:[M,...n]),W_(r=n)?z_(r):L_(r.map((e=>j_(e))));var r}),[_,a,M,m,N,A.operators.placeholderGroupLabel]),L=(0,ht.useCallback)((e=>{const t=I[e];if(t?.defaultOperator)return t.defaultOperator;if(p)return"function"==typeof p?p(e,{fieldData:t}):p;const n=$(e,{fieldData:t})??[];return B_(n)??""}),[I,p,$]),z=(0,ht.useCallback)(((e,t,{fieldData:n})=>n.valueEditorType?"function"==typeof n.valueEditorType?n.valueEditorType(t):n.valueEditorType:g?.(e,t,{fieldData:n})??"text"),[g]),F=(0,ht.useCallback)(((e,t)=>((e,t,n)=>{const r=e?j_(e):VE;if(r.valueSources)return"function"==typeof r.valueSources?r.valueSources(t):r.valueSources;if(n){const e=n(r.value,t,{fieldData:j_(r)});if(e)return e}return BE})(I[e],t,b)),[I,b]),W=(0,ht.useCallback)(((e,t,{fieldData:n})=>n?.values?M_(n.values):v?M_(v(e,t,{fieldData:n})):[]),[v]),G=(0,ht.useCallback)((e=>{const t=I[e.field]??{};if(void 0!==t?.defaultValue&&null!==t.defaultValue)return t.defaultValue;if(h)return h(e,{fieldData:t});let n="";const r=W(e.field,e.operator,{fieldData:t});if("field"===e.valueSource){const r=H_(t,T,e.operator);n=r.length>0?px(r,e,S):""}else if(r.length>0){const o=z(e.field,e.operator,{fieldData:t});"multiselect"===o?n=S?[]:"":"select"!==o&&"radio"!==o||(n=px(r,e,S))}else"checkbox"===z(e.field,e.operator,{fieldData:t})&&(n=!1);return n}),[I,T,h,z,W,S]),B=(0,ht.useCallback)(((e,t,{fieldData:n})=>{if(y){const r=y(e,t,{fieldData:n});if(r)return r}return"text"}),[y]),V=(0,ht.useCallback)((()=>{let e="";const t=T;if(t?.length>0&&t[0]){const n=B_(t);n&&(e=n)}if(f)if("function"==typeof f){const n=f(t);n&&(e=n)}else e=f;const n=L(e),r=F(e,n)[0]??"value",o={id:R(),field:e,operator:n,valueSource:r,value:""},a=G(o);return{...o,value:a}}),[T,f,L,G,F,R]),H=(0,ht.useCallback)((e=>e?{id:R(),rules:E?[V()]:[],not:!1}:{id:R(),rules:E?[V()]:[],combinator:B_(j)??"",not:!1}),[E,j,V,R]);return{qbId:t,rqbContext:O,fields:T,fieldMap:I,combinators:j,getOperatorsMain:$,getRuleDefaultOperator:L,getValueEditorTypeMain:z,getValueSourcesMain:F,getValuesMain:W,getRuleDefaultValue:G,getInputTypeMain:B,createRule:V,createRuleGroup:H}},mx=e=>(0,ht.useCallback)(((t,n)=>{t?.preventDefault(),t?.stopPropagation(),e(t,n)}),[e]),gx=(0,ht.createContext)({}),bx=[],yx=e=>ht.createElement(Uy,{context:p_,store:f_},e.children),vx=({props:e})=>{const t=(e=>fx(e,hx(e)))(e),n=t.schema.controls.ruleGroup,r=gx;return ht.createElement(r.Provider,{key:t.dndEnabledAttr,value:t.rqbContext},ht.createElement("div",{role:"form",className:t.wrapperClassName,"data-dnd":t.dndEnabledAttr,"data-inlinecombinators":t.inlineCombinatorsAttr},ht.createElement(n,{translations:t.translations,ruleGroup:t.rootGroup,rules:t.rootGroup.rules,...t.combinatorPropObject,not:!!t.rootGroup.not,schema:t.schema,actions:t.actions,id:t.rootGroup.id,path:bx,disabled:t.rootGroupDisabled,shiftUpDisabled:!0,shiftDownDisabled:!0,parentDisabled:t.queryDisabled,context:e.context})))},wx=e=>ht.createElement(yx,null,ht.createElement(vx,{props:e})),_x=ht.memo((e=>{const t=(e=>{const{id:t,path:n,rule:r,schema:{classNames:o,fields:a,fieldMap:i,getInputType:l,getOperators:s,getValueEditorType:c,getValueEditorSeparator:u,getValueSources:d,getValues:f,validationMap:p,enableDragAndDrop:h,getRuleClassname:m,suppressStandardClassnames:g},actions:{moveRule:b,onPropChange:y,onRuleRemove:v},disabled:w,parentDisabled:_,shiftUpDisabled:E,shiftDownDisabled:x,field:S,operator:k,value:R,valueSource:N,dropEffect:C="move",dragMonitorId:O="",dropMonitorId:A="",dndRef:P=null,dragRef:D=null,isDragging:T=!1,isOver:I=!1}=e;w_();const j=!!_||!!w,M=(0,ht.useMemo)((()=>r??{id:t,field:S??"",operator:k??"",value:R,valueSource:N}),[S,t,k,r,R,N]),$=(0,ht.useMemo)((()=>({shiftActions:Jw(g||Ow,o.shiftActions),dragHandle:Jw(g||Tw,o.dragHandle),fields:Jw(g||"rule-fields",o.valueSelector,o.fields),operators:Jw(g||"rule-operators",o.valueSelector,o.operators),valueSource:Jw(g||"rule-valueSource",o.valueSelector,o.valueSource),value:Jw(g||"rule-value",o.value),cloneRule:Jw(g||"rule-cloneRule",o.actionElement,o.cloneRule),lockRule:Jw(g||"rule-lock",o.actionElement,o.lockRule),removeRule:Jw(g||"rule-remove",o.actionElement,o.removeRule),valueListItem:Jw(g||jw,o.valueListItem)})),[o.shiftActions,o.dragHandle,o.valueSelector,o.fields,o.operators,o.valueSource,o.value,o.actionElement,o.cloneRule,o.lockRule,o.removeRule,o.valueListItem,g]),L=(0,ht.useCallback)((e=>(t,r)=>{j||y(e,t,n)}),[j,y,n]),z=(0,ht.useCallback)((()=>{if(!j){const e=[...ME(n),n.at(-1)+1];b(n,e,!0)}}),[j,b,n]),F=(0,ht.useCallback)(((e,t)=>{y("disabled",!j,n)}),[j,y,n]),W=(0,ht.useCallback)(((e,t)=>{j||v(n)}),[j,v,n]),G=(0,ht.useCallback)(((e,t)=>{j||E||b(n,"up",e?.altKey)}),[j,b,n,E]),B=(0,ht.useCallback)(((e,t)=>{j||x||b(n,"down",e?.altKey)}),[j,b,n,x]),V=(0,ht.useMemo)((()=>i?.[M.field]??{name:M.field,value:M.field,label:M.field}),[i,M.field]),H=(0,ht.useMemo)((()=>V.inputType??l(M.field,M.operator,{fieldData:V})),[V,l,M.field,M.operator]),U=(0,ht.useMemo)((()=>s(M.field,{fieldData:V})),[V,s,M.field]),q=(0,ht.useMemo)((()=>G_(U,M.operator)),[U,M.operator]),X=q?.arity,Y="string"==typeof X&&"unary"===X||"number"==typeof X&&X<2,K=(0,ht.useMemo)((()=>"function"==typeof V.valueSources?V.valueSources(M.operator):V.valueSources??d(M.field,M.operator,{fieldData:V})),[V,d,M.field,M.operator]),Q=(0,ht.useMemo)((()=>"field"===M.valueSource?"select":c(M.field,M.operator,{fieldData:V})),[V,c,M.field,M.operator,M.valueSource]),Z=(0,ht.useMemo)((()=>u(M.field,M.operator,{fieldData:V})),[V,u,M.field,M.operator]),J=(0,ht.useMemo)((()=>"field"===M.valueSource?H_(V,a,M.operator):V.values??f(M.field,M.operator,{fieldData:V})),[V,a,f,M.field,M.operator,M.valueSource]),ee=(0,ht.useMemo)((()=>K.map((e=>({name:e,value:e,label:e})))),[K]),te=(0,ht.useMemo)((()=>p[t??""]??("function"==typeof V.validator?V.validator(M):null)),[V,t,M,p]),ne=(0,ht.useMemo)((()=>GE(te)),[te]),re=(0,ht.useMemo)((()=>V?.className??""),[V?.className]),oe=(0,ht.useMemo)((()=>q?.className??""),[q?.className]),ae=(0,ht.useMemo)((()=>Jw(m(M,{fieldData:V}),re,oe,g||"rule",o.rule,j&&o.disabled,T&&o.dndDragging,I&&o.dndOver,I&&"copy"===C&&o.dndCopy,g||{[Iw]:j,[Aw]:T,[Pw]:I,[Dw]:I&&"copy"===C},ne)),[o.disabled,o.dndCopy,o.dndDragging,o.dndOver,o.rule,j,C,re,V,m,T,I,oe,M,g,ne]);return{...e,classNames:$,cloneRule:z,disabled:j,dndRef:P,dragMonitorId:O,dragRef:D,dropMonitorId:A,fieldData:V,generateOnChangeHandler:L,hideValueControls:Y,inputType:H,operators:U,outerClassName:ae,removeRule:W,rule:M,shiftRuleUp:G,shiftRuleDown:B,toggleLockRule:F,validationResult:te,valueEditorSeparator:Z,valueEditorType:Q,values:J,valueSourceOptions:ee,valueSources:K}})(e),n=mx(t.cloneRule),r=mx(t.toggleLockRule),o=mx(t.removeRule),a=mx(t.shiftRuleUp),i=mx(t.shiftRuleDown);return ht.createElement("div",{ref:t.dndRef,"data-testid":$w,"data-dragmonitorid":t.dragMonitorId,"data-dropmonitorid":t.dropMonitorId,className:t.outerClassName,"data-rule-id":t.id,"data-level":t.path.length,"data-path":JSON.stringify(t.path)},ht.createElement(Ex,{...t,cloneRule:n,toggleLockRule:r,removeRule:o,shiftRuleUp:a,shiftRuleDown:i}))})),Ex=ht.memo((e=>{const{schema:{controls:{shiftActions:t,dragHandle:n,fieldSelector:r,operatorSelector:o,valueSourceSelector:a,valueEditor:i,cloneRuleAction:l,lockRuleAction:s,removeRuleAction:c}}}=e;return ht.createElement(ht.Fragment,null,e.schema.showShiftActions&&ht.createElement(t,{testID:Uw,level:e.path.length,path:e.path,titles:{shiftUp:e.translations.shiftActionUp.title,shiftDown:e.translations.shiftActionDown.title},labels:{shiftUp:e.translations.shiftActionUp.label,shiftDown:e.translations.shiftActionDown.label},className:e.classNames.shiftActions,disabled:e.disabled,shiftUp:e.shiftRuleUp,shiftDown:e.shiftRuleDown,shiftUpDisabled:e.shiftUpDisabled,shiftDownDisabled:e.shiftDownDisabled,context:e.context,validation:e.validationResult,schema:e.schema,ruleOrGroup:e.rule}),e.schema.enableDragAndDrop&&ht.createElement(n,{testID:qw,ref:e.dragRef,level:e.path.length,path:e.path,title:e.translations.dragHandle.title,label:e.translations.dragHandle.label,className:e.classNames.dragHandle,disabled:e.disabled,context:e.context,validation:e.validationResult,schema:e.schema,ruleOrGroup:e.rule}),ht.createElement(r,{testID:"fields",options:e.schema.fields,title:e.translations.fields.title,value:e.rule.field,operator:e.rule.operator,className:e.classNames.fields,handleOnChange:e.generateOnChangeHandler("field"),level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,schema:e.schema,rule:e.rule}),(e.schema.autoSelectField||e.rule.field!==e.translations.fields.placeholderName)&&ht.createElement(ht.Fragment,null,ht.createElement(o,{testID:"operators",field:e.rule.field,fieldData:e.fieldData,title:e.translations.operators.title,options:e.operators,value:e.rule.operator,className:e.classNames.operators,handleOnChange:e.generateOnChangeHandler("operator"),level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,schema:e.schema,rule:e.rule}),(e.schema.autoSelectOperator||e.rule.operator!==e.translations.operators.placeholderName)&&!e.hideValueControls&&ht.createElement(ht.Fragment,null,!["null","notNull"].includes(e.rule.operator)&&e.valueSources.length>1&&ht.createElement(a,{testID:"value-source-selector",field:e.rule.field,fieldData:e.fieldData,title:e.translations.valueSourceSelector.title,options:e.valueSourceOptions,value:e.rule.valueSource??"value",className:e.classNames.valueSource,handleOnChange:e.generateOnChangeHandler("valueSource"),level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,schema:e.schema,rule:e.rule}),ht.createElement(i,{testID:"value-editor",field:e.rule.field,fieldData:e.fieldData,title:e.translations.value.title,operator:e.rule.operator,value:e.rule.value,valueSource:e.rule.valueSource??"value",type:e.valueEditorType,inputType:e.inputType,values:e.values,listsAsArrays:e.schema.listsAsArrays,parseNumbers:e.schema.parseNumbers,separator:e.valueEditorSeparator,className:e.classNames.value,handleOnChange:e.generateOnChangeHandler("value"),level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,schema:e.schema,rule:e.rule}))),e.schema.showCloneButtons&&ht.createElement(l,{testID:"clone-rule",label:e.translations.cloneRule.label,title:e.translations.cloneRule.title,className:e.classNames.cloneRule,handleOnClick:e.cloneRule,level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,ruleOrGroup:e.rule,schema:e.schema}),e.schema.showLockButtons&&ht.createElement(s,{testID:"lock-rule",label:e.translations.lockRule.label,title:e.translations.lockRule.title,className:e.classNames.lockRule,handleOnClick:e.toggleLockRule,level:e.path.length,path:e.path,disabled:e.disabled,disabledTranslation:e.parentDisabled?void 0:e.translations.lockRuleDisabled,context:e.context,validation:e.validationResult,ruleOrGroup:e.rule,schema:e.schema}),ht.createElement(c,{testID:"remove-rule",label:e.translations.removeRule.label,title:e.translations.removeRule.title,className:e.classNames.removeRule,handleOnClick:e.removeRule,level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,ruleOrGroup:e.rule,schema:e.schema}))})),xx=ht.memo((e=>{const t=(e=>{const{id:t,path:n,ruleGroup:r,schema:{qbId:o,accessibleDescriptionGenerator:a,classNames:i,combinators:l,createRule:s,createRuleGroup:c,disabledPaths:u,independentCombinators:d,validationMap:f,enableDragAndDrop:p,getRuleGroupClassname:h,suppressStandardClassnames:m},actions:{onGroupAdd:g,onGroupRemove:b,onPropChange:y,onRuleAdd:v,moveRule:w},disabled:_,parentDisabled:E,shiftUpDisabled:x,shiftDownDisabled:S,combinator:k,rules:R,not:N,dropEffect:C="move",dragMonitorId:O="",dropMonitorId:A="",previewRef:P=null,dragRef:D=null,dropRef:T=null,isDragging:I=!1,isOver:j=!1}=e;w_();const M=!!E||!!_,$=(0,ht.useMemo)((()=>r&&C_(r)?r.combinator:r?B_(l):k??B_(l)),[k,l,r]),L=(0,ht.useMemo)((()=>{if(r){if(r.combinator===$||d)return r;const e=structuredClone(r);return e.combinator=$,e}return{rules:R,not:N}}),[$,d,N,r,R]),z=(0,ht.useMemo)((()=>({header:Jw(m||"ruleGroup-header",i.header,j&&"copy"===C&&i.dndCopy,m||{[Pw]:j,[Dw]:j&&"copy"===C}),shiftActions:Jw(m||Ow,i.shiftActions),dragHandle:Jw(m||Tw,i.dragHandle),combinators:Jw(m||"ruleGroup-combinators",i.valueSelector,i.combinators),notToggle:Jw(m||"ruleGroup-notToggle",i.notToggle),addRule:Jw(m||"ruleGroup-addRule",i.actionElement,i.addRule),addGroup:Jw(m||"ruleGroup-addGroup",i.actionElement,i.addGroup),cloneGroup:Jw(m||"ruleGroup-cloneGroup",i.actionElement,i.cloneGroup),lockGroup:Jw(m||"ruleGroup-lock",i.actionElement,i.lockGroup),removeGroup:Jw(m||"ruleGroup-remove",i.actionElement,i.removeGroup),body:Jw(m||"ruleGroup-body",i.body)})),[i.actionElement,i.addGroup,i.addRule,i.body,i.cloneGroup,i.combinators,i.dndCopy,i.dragHandle,i.header,i.lockGroup,i.notToggle,i.removeGroup,i.shiftActions,i.valueSelector,C,j,m]),F=(0,ht.useCallback)((e=>{M||y("combinator",e,n)}),[M,y,n]),W=(0,ht.useCallback)(((e,t,r)=>{M||y("combinator",e,[...n,t])}),[M,y,n]),G=(0,ht.useCallback)(((e,t)=>{M||y("not",e,n)}),[M,y,n]),B=(0,ht.useCallback)(((e,t)=>{if(!M){const e=s();v(e,n,t)}}),[s,M,v,n]),V=(0,ht.useCallback)(((e,t)=>{if(!M){const e=c(d);g(e,n,t)}}),[c,M,d,g,n]),H=(0,ht.useCallback)((()=>{if(!M){const e=[...ME(n),n.at(-1)+1];w(n,e,!0)}}),[M,w,n]),U=(0,ht.useCallback)(((e,t)=>{M||x||w(n,"up",e?.altKey)}),[M,w,n,x]),q=(0,ht.useCallback)(((e,t)=>{M||S||w(n,"down",e?.altKey)}),[M,w,n,S]),X=(0,ht.useCallback)((()=>{y("disabled",!M,n)}),[M,y,n]),Y=(0,ht.useCallback)((()=>{M||b(n)}),[M,b,n]),K=(0,ht.useMemo)((()=>f[t??""]),[t,f]),Q=(0,ht.useMemo)((()=>GE(K)),[K]),Z=(0,ht.useMemo)((()=>d?null:G_(l,$)?.className??""),[$,l,d]),J=(0,ht.useMemo)((()=>h(L)),[h,L]),ee=(0,ht.useMemo)((()=>Jw(J,Z,m||"ruleGroup",i.ruleGroup,M&&i.disabled,I&&i.dndDragging,m||{[Iw]:M,[Aw]:I},Q)),[i.disabled,i.dndDragging,i.ruleGroup,Z,M,I,J,m,Q]),te=(0,ht.useMemo)((()=>{const e=[];for(let t=0;t$E(r,e)))}}return e}),[M,n,L.rules.length,u]),ne=(0,ht.useMemo)((()=>a({path:n,qbId:o})),[a,n,o]);return{...e,addGroup:V,addRule:B,accessibleDescription:ne,classNames:z,cloneGroup:H,combinator:$,disabled:M,dragMonitorId:O,dragRef:D,dropMonitorId:A,dropRef:T,isDragging:I,isOver:j,onCombinatorChange:F,onGroupAdd:g,onIndependentCombinatorChange:W,onNotToggleChange:G,outerClassName:ee,parentDisabled:E,pathsMemo:te,previewRef:P,removeGroup:Y,ruleGroup:L,shiftGroupUp:U,shiftGroupDown:q,toggleLockGroup:X,validationClassName:Q,validationResult:K}})(e),{schema:{controls:{ruleGroupBodyElements:n,ruleGroupHeaderElements:r}}}=t,o=mx(t.addRule),a=mx(t.addGroup),i=mx(t.cloneGroup),l=mx(t.toggleLockGroup),s=mx(t.removeGroup),c=mx(t.shiftGroupUp),u=mx(t.shiftGroupDown);return ht.createElement("div",{ref:t.previewRef,title:t.accessibleDescription,className:t.outerClassName,"data-testid":Lw,"data-dragmonitorid":t.dragMonitorId,"data-dropmonitorid":t.dropMonitorId,"data-rule-group-id":t.id,"data-level":t.path.length,"data-path":JSON.stringify(t.path)},ht.createElement("div",{ref:t.dropRef,className:t.classNames.header},ht.createElement(r,{...t,addRule:o,addGroup:a,cloneGroup:i,toggleLockGroup:l,removeGroup:s,shiftGroupUp:c,shiftGroupDown:u})),ht.createElement("div",{className:t.classNames.body},ht.createElement(n,{...t,addRule:o,addGroup:a,cloneGroup:i,toggleLockGroup:l,removeGroup:s,shiftGroupUp:c,shiftGroupDown:u})))})),Sx=ht.memo((e=>{const{schema:{controls:{shiftActions:t,dragHandle:n,combinatorSelector:r,notToggle:o,addRuleAction:a,addGroupAction:i,cloneGroupAction:l,lockGroupAction:s,removeGroupAction:c}}}=e;return ht.createElement(ht.Fragment,null,e.schema.showShiftActions&&e.path.length>0&&ht.createElement(t,{key:Uw,testID:Uw,level:e.path.length,path:e.path,titles:{shiftUp:e.translations.shiftActionUp.title,shiftDown:e.translations.shiftActionDown.title},labels:{shiftUp:e.translations.shiftActionUp.label,shiftDown:e.translations.shiftActionDown.label},className:e.classNames.shiftActions,disabled:e.disabled,shiftUp:e.shiftGroupUp,shiftDown:e.shiftGroupDown,shiftUpDisabled:e.shiftUpDisabled,shiftDownDisabled:e.shiftDownDisabled,context:e.context,validation:e.validationResult,schema:e.schema,ruleOrGroup:e.ruleGroup}),e.path.length>0&&e.schema.enableDragAndDrop&&ht.createElement(n,{key:qw,testID:qw,ref:e.dragRef,level:e.path.length,path:e.path,title:e.translations.dragHandle.title,label:e.translations.dragHandle.label,className:e.classNames.dragHandle,disabled:e.disabled,context:e.context,validation:e.validationResult,schema:e.schema,ruleOrGroup:e.ruleGroup}),!e.schema.showCombinatorsBetweenRules&&!e.schema.independentCombinators&&ht.createElement(r,{key:Vw,testID:Vw,options:e.schema.combinators,value:e.combinator,title:e.translations.combinators.title,className:e.classNames.combinators,handleOnChange:e.onCombinatorChange,rules:e.ruleGroup.rules,level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,schema:e.schema}),e.schema.showNotToggle&&ht.createElement(o,{key:Hw,testID:Hw,className:e.classNames.notToggle,title:e.translations.notToggle.title,label:e.translations.notToggle.label,checked:e.ruleGroup.not,handleOnChange:e.onNotToggleChange,level:e.path.length,disabled:e.disabled,path:e.path,context:e.context,validation:e.validationResult,schema:e.schema,ruleGroup:e.ruleGroup}),ht.createElement(a,{key:Bw,testID:Bw,label:e.translations.addRule.label,title:e.translations.addRule.title,className:e.classNames.addRule,handleOnClick:e.addRule,rules:e.ruleGroup.rules,level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,ruleOrGroup:e.ruleGroup,schema:e.schema}),ht.createElement(i,{key:Fw,testID:Fw,label:e.translations.addGroup.label,title:e.translations.addGroup.title,className:e.classNames.addGroup,handleOnClick:e.addGroup,rules:e.ruleGroup.rules,level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,ruleOrGroup:e.ruleGroup,schema:e.schema}),e.schema.showCloneButtons&&e.path.length>0&&ht.createElement(l,{key:Gw,testID:Gw,label:e.translations.cloneRuleGroup.label,title:e.translations.cloneRuleGroup.title,className:e.classNames.cloneGroup,handleOnClick:e.cloneGroup,rules:e.ruleGroup.rules,level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,ruleOrGroup:e.ruleGroup,schema:e.schema}),e.schema.showLockButtons&&ht.createElement(s,{key:Xw,testID:Xw,label:e.translations.lockGroup.label,title:e.translations.lockGroup.title,className:e.classNames.lockGroup,handleOnClick:e.toggleLockGroup,rules:e.ruleGroup.rules,level:e.path.length,path:e.path,disabled:e.disabled,disabledTranslation:e.parentDisabled?void 0:e.translations.lockGroupDisabled,context:e.context,validation:e.validationResult,ruleOrGroup:e.ruleGroup,schema:e.schema}),e.path.length>0&&ht.createElement(c,{key:Ww,testID:Ww,label:e.translations.removeGroup.label,title:e.translations.removeGroup.title,className:e.classNames.removeGroup,handleOnClick:e.removeGroup,rules:e.ruleGroup.rules,level:e.path.length,path:e.path,disabled:e.disabled,context:e.context,validation:e.validationResult,ruleOrGroup:e.ruleGroup,schema:e.schema}))})),kx=ht.memo((e=>{const{schema:{controls:{combinatorSelector:t,inlineCombinator:n,ruleGroup:r,rule:o}}}=e;return e.ruleGroup.rules.map(((a,i,{length:l})=>{const s=e.pathsMemo[i],c=s.path,u=s.disabled||"string"!=typeof a&&a.disabled,d=$E([0],c),f=0===e.path.length&&i===l-1,p="string"==typeof a?[...c,a].join("-"):a.id;return ht.createElement(ht.Fragment,{key:p},i>0&&!e.schema.independentCombinators&&e.schema.showCombinatorsBetweenRules&&ht.createElement(n,{key:zw,options:e.schema.combinators,value:e.combinator,title:e.translations.combinators.title,className:e.classNames.combinators,handleOnChange:e.onCombinatorChange,rules:e.ruleGroup.rules,level:e.path.length,context:e.context,validation:e.validationResult,component:t,path:c,disabled:e.disabled,schema:e.schema}),"string"==typeof a?ht.createElement(n,{key:`${zw}-independent`,options:e.schema.combinators,value:a,title:e.translations.combinators.title,className:e.classNames.combinators,handleOnChange:t=>e.onIndependentCombinatorChange(t,i),rules:e.ruleGroup.rules,level:e.path.length,context:e.context,validation:e.validationResult,component:t,path:c,disabled:u,schema:e.schema}):N_(a)?ht.createElement(r,{key:Lw,id:a.id,schema:e.schema,actions:e.actions,path:c,translations:e.translations,ruleGroup:a,rules:a.rules,combinator:C_(a)?a.combinator:void 0,not:!!a.not,disabled:u,parentDisabled:e.parentDisabled||e.disabled,shiftUpDisabled:d,shiftDownDisabled:f,context:e.context}):ht.createElement(o,{key:$w,id:a.id,rule:a,field:a.field,operator:a.operator,value:a.value,valueSource:a.valueSource,schema:e.schema,actions:e.actions,path:c,disabled:u,parentDisabled:e.parentDisabled||e.disabled,translations:e.translations,shiftUpDisabled:d,shiftDownDisabled:f,context:e.context}))}))})),Rx=e=>{const{onChange:t,val:n}=(e=>{const{handleOnChange:t,listsAsArrays:n=!1,multiple:r=!1,value:o}=e;return{onChange:(0,ht.useCallback)((e=>{if(r){const r=S_(e);t(n?r:E_(r,","))}else t(e)}),[t,n,r]),val:(0,ht.useMemo)((()=>r?S_(o):o),[r,o])}})(e),r=(e=>{const{multiple:t,onChange:n}=e;return(0,ht.useMemo)((()=>t?e=>n(Array.from(e.target.selectedOptions).map((e=>e.value))):e=>n(e.target.value)),[t,n])})({multiple:e.multiple,onChange:t});return ht.createElement("select",{"data-testid":e.testID,className:e.className,value:n,title:e.title,disabled:e.disabled,multiple:!!e.multiple,onChange:r},(o=e.options,F_(o)?o.map((e=>ht.createElement("optgroup",{key:e.label,label:e.label},e.options.map((e=>ht.createElement("option",{key:e.name,value:e.name,disabled:e.disabled},e.label)))))):Array.isArray(o)?o.map((e=>ht.createElement("option",{key:e.name,value:e.name,disabled:e.disabled},e.label))):null));var o},Nx={actionElement:_w,addGroupAction:_w,addRuleAction:_w,cloneGroupAction:_w,cloneRuleAction:_w,combinatorSelector:Rx,dragHandle:Ew,fieldSelector:Rx,inlineCombinator:e=>{const{component:t,...n}=e,r=Jw(n.schema.suppressStandardClassnames||"betweenRules",n.schema.classNames.betweenRules);return ht.createElement("div",{className:r,"data-testid":zw},ht.createElement(t,{...n,testID:Vw}))},lockGroupAction:_w,lockRuleAction:_w,notToggle:e=>ht.createElement("label",{"data-testid":e.testID,className:e.className,title:e.title},ht.createElement("input",{type:"checkbox",onChange:t=>e.handleOnChange(t.target.checked),checked:!!e.checked,disabled:e.disabled}),e.label),operatorSelector:Rx,removeGroupAction:_w,removeRuleAction:_w,rule:_x,ruleGroup:xx,ruleGroupBodyElements:kx,ruleGroupHeaderElements:Sx,shiftActions:e=>ht.createElement("div",{"data-testid":e.testID,className:e.className},ht.createElement("button",{disabled:e.disabled||e.shiftUpDisabled,onClick:e.shiftUp,title:e.titles?.shiftUp},e.labels?.shiftUp),ht.createElement("button",{disabled:e.disabled||e.shiftDownDisabled,onClick:e.shiftDown,title:e.titles?.shiftDown},e.labels?.shiftDown)),valueEditor:e=>{const{operator:t,value:n,handleOnChange:r,title:o,className:a,type:i="text",inputType:l="text",values:s=[],listsAsArrays:c,fieldData:u,disabled:d,separator:f=null,testID:p,selectorComponent:h=e.schema.controls.valueSelector,...m}=e,{valueAsArray:g,multiValueHandler:b,parseNumberMethod:y,valueListItemClassName:v}=(e=>{const{handleOnChange:t,inputType:n,operator:r,value:o,listsAsArrays:a,parseNumbers:i,values:l,type:s,skipHook:c,schema:{classNames:u,suppressStandardClassnames:d}}=e;(0,ht.useEffect)((()=>{c||"multiselect"===s||["between","notBetween","in","notIn"].includes(r)||!(Array.isArray(o)||"number"===n&&"string"==typeof o&&o.includes(","))||t(S_(o,{retainEmptyStrings:!0})[0]??"")}),[t,n,r,c,s,o]);const f=(0,ht.useMemo)((()=>S_(o,{retainEmptyStrings:!0})),[o]),p=(0,ht.useMemo)((()=>{if("string"==typeof i){const[e,t]=i.split("-");return"limited"===t?"number"===n&&e:e}return!!i&&"strict"}),[n,i]),h=(0,ht.useCallback)(((e,n)=>{const o=Xv(f,(t=>{t[n]=U_(e,{parseNumbers:p}),0!==n||"between"!==r&&"notBetween"!==r||!(t.length<2||void 0===t[1])||(t[1]=B_(l))}));t(a?o:E_(o,","))}),[t,a,r,p,f,l]),m=e_(d||jw,u?.valueListItem);return{valueAsArray:f,multiValueHandler:h,parseNumberMethod:p,valueListItemClassName:m}})(e);if("null"===t||"notNull"===t)return null;const w=u?.placeholder??"",_=["in","notIn"].includes(t)?"text":l||"text";if(!("between"!==t&&"notBetween"!==t||"select"!==i&&"text"!==i)){const t=["from","to"].map(((t,n)=>"text"===i?ht.createElement("input",{key:t,type:_,placeholder:w,value:g[n]??"",className:v,disabled:d,onChange:e=>b(e.target.value,n)}):ht.createElement(h,{key:t,...m,schema:e.schema,className:v,handleOnChange:e=>b(e,n),disabled:d,value:g[n]??B_(s),options:s,listsAsArrays:c})));return ht.createElement("span",{"data-testid":p,className:a,title:o},t[0],f,t[1])}switch(i){case"select":case"multiselect":return ht.createElement(h,{...m,schema:e.schema,testID:p,className:a,title:o,handleOnChange:r,disabled:d,value:n,options:s,multiple:"multiselect"===i,listsAsArrays:c});case"textarea":return ht.createElement("textarea",{"data-testid":p,placeholder:w,value:n,title:o,className:a,disabled:d,onChange:e=>r(e.target.value)});case"switch":case"checkbox":return ht.createElement("input",{"data-testid":p,type:"checkbox",className:a,title:o,onChange:e=>r(e.target.checked),checked:!!n,disabled:d});case"radio":return ht.createElement("span",{"data-testid":p,className:a,title:o},s.map((e=>ht.createElement("label",{key:e.name},ht.createElement("input",{type:"radio",value:e.name,disabled:d,checked:n===e.name,onChange:e=>r(e.target.value)}),e.label))))}return ht.createElement("input",{"data-testid":p,type:_,placeholder:w,value:n,title:o,className:a,disabled:d,onChange:e=>r(U_(e.target.value,{parseNumbers:y}))})},valueSelector:Rx,valueSourceSelector:Rx},Cx=i(840),Ox=i(5072),Ax=i.n(Ox),Px=i(7825),Dx=i.n(Px),Tx=i(7659),Ix=i.n(Tx),jx=i(5056),Mx=i.n(jx),$x=i(540),Lx=i.n($x),zx=i(1113),Fx=i.n(zx),Wx=i(6241),Gx={};function Bx(e){return Bx="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},Bx(e)}function Vx(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 Hx(e,t,n){return(t=function(e){var t=function(e){if("object"!=Bx(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Bx(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Bx(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ux(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=Xx(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},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 a,i=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return i=e.done,e},e:function(e){l=!0,a=e},f:function(){try{i||null==n.return||n.return()}finally{if(l)throw a}}}}function qx(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,l=[],s=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return l}}(e,t)||Xx(e,t)||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.")}()}function Xx(e,t){if(e){if("string"==typeof e)return Yx(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)?Yx(e,t):void 0}}function Yx(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n0;return React.createElement(Eb,{title:(0,L.__)("Validation","post-expirator"),className:"workflow-editor-validation-panel"},o&&React.createElement(React.Fragment,null,r.map((function(e,t){return React.createElement(M.PanelRow,{key:"".concat(e.error,"-").concat(t),className:"workflow-editor-validation-notification workflow-editor-error"},React.createElement(Lf,{icon:"error",size:18}),e.message)}))),!o&&React.createElement(M.PanelRow,{className:"workflow-editor-validation-notification workflow-editor-success"},React.createElement(Lf,{icon:"yes-alt",size:18}),(0,L.__)("All checks have passed for this step.","post-expirator")))};function aS(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n0&&React.createElement(React.Fragment,null,React.createElement("div",null,(0,L.__)("This step receives the following input from previous step:","post-expirator")),React.createElement("ul",null,n.map((function(e,t){return React.createElement("li",{key:"input-".concat(e.name,"-").concat(t)},React.createElement(u,{schemaItem:e}))})))),0===n.length&&(0,L.__)("This step does not receive any input from previous step.","post-expirator"))),React.createElement(M.PanelRow,{className:"workflow-editor-inspector-card__handles-schema"},React.createElement("h3",null,(0,L.__)("Outputs","post-expirator")),React.createElement("div",null,o.length>0&&React.createElement(React.Fragment,null,React.createElement("div",null,(0,L.__)("This step outputs the following data:","post-expirator")),React.createElement("ul",null,o.map((function(e,t){return React.createElement("li",{key:"output-".concat(e.name,"-").concat(t)},React.createElement(u,{schemaItem:e}))})))),0===o.length&&(0,L.__)("This step does not output any data.","post-expirator"))),React.createElement(M.PanelRow,{className:"workflow-editor-inspector-card__handles-schema"},React.createElement("h3",null,(0,L.__)("Global Variables","post-expirator")),React.createElement("div",null,!i&&0===c.length&&React.createElement("div",null,(0,L.__)("No global variables are declared","post-expirator")),!i&&c.length>0&&React.createElement("ul",null,c.map((function(e){return React.createElement("li",{key:"global-".concat(e)},React.createElement(u,{schemaItem:s[e],prefix:"global."}))}))))))};function lS(e){var t=e.size,n=void 0===t?24:t;return React.createElement(vf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 24 24",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{fill:"none",strokeWidth:"2",d:"M1,1 L4,1 L4,4 L1,4 L1,1 Z M20,1 L23,1 L23,4 L20,4 L20,1 Z M4,2 L20,2 M4,22 L20,22 M1,20 L4,20 L4,23 L1,23 L1,20 Z M20,20 L23,20 L23,23 L20,23 L20,20 Z M2,4 L2,20 M22,4 L22,20 M7,7 L14,7 L14,13 L7,13 L7,7 Z M17,10 L17,17 L10,17 L10,15"})))}function sS(e){var t=e.size,n=void 0===t?24:t;return React.createElement(vf,{size:n},React.createElement("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 384 512",height:"100%",width:"100%",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{d:"M190.4 74.1c5.6-16.8-3.5-34.9-20.2-40.5s-34.9 3.5-40.5 20.2l-128 384c-5.6 16.8 3.5 34.9 20.2 40.5s34.9-3.5 40.5-20.2l128-384zm70.9-41.7c-17.4-2.9-33.9 8.9-36.8 26.3l-64 384c-2.9 17.4 8.9 33.9 26.3 36.8s33.9-8.9 36.8-26.3l64-384c2.9-17.4-8.9-33.9-26.3-36.8zM352 32c-17.7 0-32 14.3-32 32V448c0 17.7 14.3 32 32 32s32-14.3 32-32V64c0-17.7-14.3-32-32-32z"})))}function cS(){return cS=Object.assign?Object.assign.bind():function(e){for(var t=1;t0&&0===r.length,h=0===n.length&&r.length>0,m=(null==s||null===(e=s.settingsSchema)||void 0===e?void 0:e.length)>0,g=function(e){var t,n,r=(0,$.select)(ec).getNodeTypeByName(null==e||null===(t=e.data)||void 0===t?void 0:t.name),o=hc(e);return(null==o?void 0:o.length)>0&&(null===(n=o.filter((function(e){var t;return(null==r||null===(t=r.outputSchema)||void 0===t?void 0:t.length)>0})))||void 0===n?void 0:n.length)>0}(a),y=function(e){var t,n,r=(0,$.select)(ec).getNodeTypeByName(null==e||null===(t=e.data)||void 0===t?void 0:t.name);return(null==r||null===(n=r.outputSchema)||void 0===n?void 0:n.length)>0}(a),w=gc(a),_=(null==s?void 0:s.outputSchema)||[],E=[];return _.length>0&&_.forEach((function(e){var t;"input"===e.type?E=E.concat(w):E.push(hS(hS({},e),{},{name:"".concat(null==a||null===(t=a.data)||void 0===t?void 0:t.slug,".").concat(e.name)}))})),Sb(f,".interface-interface-skeleton__sidebar"),React.createElement("div",{ref:f},0===o&&React.createElement(Cb,null,(0,L.__)("No element selected.","post-expirator")),o>1&&!p&&!h&&React.createElement(Cb,null,(0,L.__)("Multiple and different elements selected.","post-expirator")),p&&o>1&&React.createElement(Rb,{title:(0,L.sprintf)((0,L.__)("%d steps selected","post-expirator"),o),description:(0,L.__)("Multiple steps selected.","post-expirator"),icon:React.createElement(lS,{size:24})}),h&&o>1&&React.createElement(Rb,{title:(0,L.sprintf)((0,L.__)("%d connections selected","post-expirator"),o),description:(0,L.__)("Multiple connections selected.","post-expirator"),icon:React.createElement(sS,{size:24})}),p&&1===o&&React.createElement(React.Fragment,null,React.createElement(Nb,{node:a}),m&&React.createElement(rS,{node:a}),React.createElement(oS,{errors:l}),d&&(g||y)&&React.createElement(iS,{inputSchema:w,outputSchema:E}),u&&React.createElement(dS,{node:a,nodeType:s}),React.createElement("div",{className:"components-tools-panel"})),h&&1===o&&i&&React.createElement(React.Fragment,null,React.createElement(Rb,{title:(0,L.__)("Connection","post-expirator"),description:(0,L.__)("The connection between nodes in the workflow. Signifies the path along which data or control flow one node to another.","post-expirator"),icon:React.createElement(sS,{size:24}),id:i.id}),React.createElement("div",{className:"components-tools-panel"})))};const bS=function(){var e=(0,$.useSelect)((function(e){return{showQueries:e(Gd).getEditedWorkflowAttribute("debugRayShowQueries"),showEmails:e(Gd).getEditedWorkflowAttribute("debugRayShowEmails"),showWordPressErrors:e(Gd).getEditedWorkflowAttribute("debugRayShowWordPressErrors"),showCurrentRunningStep:e(Gd).getEditedWorkflowAttribute("debugRayShowCurrentRunningStep"),isLoadingWorkflow:e(Gd).isLoadingWorkflow()}})),t=e.showQueries,n=e.showEmails,r=e.showWordPressErrors,o=e.showCurrentRunningStep,a=e.isLoadingWorkflow,i=(0,$.useDispatch)(Gd).setEditedWorkflowAttribute,l=(0,T.useCallback)((function(e){i("debugRayShowQueries",e)})),s=(0,T.useCallback)((function(e){i("debugRayShowEmails",e)})),c=(0,T.useCallback)((function(e){i("debugRayShowWordPressErrors",e)})),u=(0,T.useCallback)((function(e){i("debugRayShowCurrentRunningStep",e)}));return React.createElement("div",null,React.createElement(Eb,{className:"edit-post-post-status workflow-editor-dev-panel",title:(0,L.__)("Ray Debug","post-expirator"),initialOpen:!0,disabled:a},React.createElement(M.PanelRow,null,React.createElement("p",null,(0,L.__)("Enable or disable the different types of debug information that is shown in Ray when this workflow is activated.","post-expirator"))),React.createElement(M.PanelRow,null,React.createElement(M.ToggleControl,{label:(0,L.__)("Show Queries","post-expirator"),checked:t,onChange:l})),React.createElement(M.PanelRow,null,React.createElement(M.ToggleControl,{label:(0,L.__)("Show Emails","post-expirator"),checked:n,onChange:s})),React.createElement(M.PanelRow,null,React.createElement(M.ToggleControl,{label:(0,L.__)("Show WordPress Errors","post-expirator"),checked:r,onChange:c})),React.createElement(M.PanelRow,null,React.createElement(M.ToggleControl,{label:(0,L.__)("Show current running step","post-expirator"),checked:o,onChange:u}))))};var yS=T.Platform.select({web:!0,native:!1}),vS=function(){var e=(0,$.useSelect)((function(e){var t=e(bg).getShortcutRepresentation(Ng);return{sidebarName:e("core/interface").getActiveComplementaryArea(k),keyboardShortcut:t}})),t=e.sidebarName,n=e.keyboardShortcut,r=(0,$.useSelect)((function(e){return{isDeveloperModeEnabled:e(ec).isFeatureActive(b),isRayDebugInstalled:e(ec).isRayDebugInstalled()}})),o=r.isDeveloperModeEnabled,a=r.isRayDebugInstalled;return React.createElement(hb,{identifier:t,header:React.createElement(mb,{sidebarName:t}),closeLabel:(0,L.__)("Close settings","post-expirator"),headerClassName:"edit-post-sidebar__panel-tabs",className:"edit-post-sidebar__panel",title:(0,L.__)("Settings","post-expirator"),toggleShortcut:n,icon:db,isActiveByDefault:yS},t===Ff&&React.createElement(React.Fragment,null,React.createElement(kb,null),o&&a&&React.createElement(React.Fragment,null,React.createElement(bS,null))),t===Wf&&React.createElement(React.Fragment,null,React.createElement(gS,null)))},wS=function(e){return futureWorkflowEditor.assetsUrl+"/images/workflow-welcome-guide/"+e+"?v="+futureWorkflowEditor.pluginVersion};const _S=function(){var e=(0,$.useDispatch)(ec).disableFeature,t=futureWorkflowEditor.welcomeGuidePages;return React.createElement(M.Guide,{className:"workflow-editor-welcome-guide",contentLabel:(0,L.__)("Welcome to the workflow editor","post-expirator"),finishButtonText:(0,L.__)("Get started","post-expirator"),onFinish:function(){e(y)},pages:t.map((function(e){var t=e.title,n=e.content,r=e.image;return{content:React.createElement(React.Fragment,null,React.createElement("h1",{className:"edit-post-welcome-guide__heading"},t),React.createElement("p",{className:"edit-post-welcome-guide__text"},n)),image:React.createElement("picture",{className:"edit-post-welcome-guide__image"},React.createElement("source",{srcSet:wS(r+".png"),media:"(prefers-reduced-motion: reduce)"}),React.createElement("img",{src:wS(r+".gif"),width:"312",height:"240",alt:""}))}}))})};function ES(){var e=(0,$.useSelect)((function(e){return{isFullscreenActive:e(ec).isFeatureActive(h),isInserterOpened:e(ec).isFeatureActive(g),isWelcomeGuideActive:e(ec).isFeatureActive(y),isPro:e(ec).isPro()}})),t=e.isFullscreenActive,n=e.isInserterOpened,r=e.isWelcomeGuideActive,o=e.isPro,a=ft()("edit-post-layout editor-editor-interface",{"is-inserter-opened":n});return(0,T.useEffect)((function(){var e=["workflow-editor"];return e.push(o?"is-pro":"is-free"),e.forEach((function(e){return function(e){document.body.classList.contains(e)||document.body.classList.add(e)}(e)})),function(){!function(e){e.forEach((function(e){return function(e){document.body.classList.contains(e)&&document.body.classList.remove(e)}(e)}))}(e)}}),[]),React.createElement(M.SlotFillProvider,null,React.createElement(Is,null,React.createElement(Je,{isActive:t}),React.createElement(Ag,null),React.createElement(vS,null),React.createElement(og,{className:a,secondarySidebar:function(){return n?React.createElement(ub,null):null}}),r&&React.createElement(_S,null)),React.createElement(Le.PluginArea,{scope:"future-workflow-editor"}))}var xS=i(3133),SS={};SS.styleTagTransform=Fx(),SS.setAttributes=Mx(),SS.insert=Ix().bind(null,"head"),SS.domAPI=Dx(),SS.insertStyleElement=Lx(),Ax()(xS.A,SS),xS.A&&xS.A.locals&&xS.A.locals;var kS=i(2672),RS={};RS.styleTagTransform=Fx(),RS.setAttributes=Mx(),RS.insert=Ix().bind(null,"head"),RS.domAPI=Dx(),RS.insertStyleElement=Lx(),Ax()(kS.A,RS),kS.A&&kS.A.locals&&kS.A.locals;var NS=window.futureWorkflowEditor,CS=NS.workflowId,OS=NS.nodeTypeCategories,AS=NS.nodeTypes;function PS(){var e=(0,$.useDispatch)(Gd),t=e.setupEditor,n=e.setDataTypes,r=(0,$.useDispatch)(ec),o=r.setTriggerNodes,a=r.setTriggerCategories,i=r.setActionCategories,l=r.setActionNodes,s=r.setAdvancedCategories,c=r.setAdvancedNodes;return(0,T.useEffect)((function(){t(CS),o(AS.triggers),l(AS.actions),c(AS.advanced),a(OS),i(OS),s(OS),n([{name:"post",label:"Post",type:"object",objectType:"post",propertiesSchema:[{name:"post_title",type:"string",label:"Title"},{name:"post_content",type:"string",label:"Content"},{name:"post_content_text",type:"string",label:"Content (Plain Text)"},{name:"post_excerpt",type:"string",label:"Excerpt"},{name:"post_status",type:"string",label:"Post Status"},{name:"post_type",type:"string",label:"Post Type"},{name:"id",type:"integer",label:"ID"},{name:"post_date",type:"datetime",label:"Publish Date"},{name:"post_modified",type:"datetime",label:"Modification Date"},{name:"permalink",type:"string",label:"Permalink"},{name:"meta",type:"object",label:"Metadata"}]},{name:"boolean",label:"Boolean",type:"boolean"},{name:"datetime",label:"Datetime",type:"datetime"},{name:"integer",label:"Integer",type:"integer"},{name:"string",label:"String",type:"string"},{name:"email",label:"Email",type:"email"},{name:"input",label:"Step input",type:"input"},{name:"workflow",label:"Future Workflow",type:"object",objectType:"workflow",propertiesSchema:[{name:"id",type:"integer",label:"ID"},{name:"title",type:"string",label:"Title"},{name:"description",type:"string",label:"Description"},{name:"modified_at",type:"datetime",label:"Modification Date"},{name:"steps",type:"node",label:"Steps"},{name:"meta",type:"object",label:"Metadata"}]},{name:"user",label:"User",type:"object",objectType:"user",propertiesSchema:[{name:"ID",type:"integer",label:"ID"},{name:"user_email",type:"email",label:"Email"},{name:"user_login",type:"string",label:"User Login"},{name:"display_name",type:"string",label:"Display Name"},{name:"roles",type:"array",label:"Roles"},{name:"caps",type:"object",label:"Capabilities"},{name:"user_registered",type:"datetime",label:"Registration Date"},{name:"meta",type:"object",label:"Metadata"}]},{name:"site",label:"Site",type:"object",objectType:"site",propertiesSchema:[{name:"id",type:"integer",label:"ID"},{name:"name",type:"string",label:"Name"},{name:"description",type:"string",label:"Description"},{name:"url",type:"string",label:"Site URL"},{name:"home_url",type:"string",label:"Home URL"},{name:"admin_email",type:"email",label:"Admin Email"},{name:"meta",type:"object",label:"Metadata"}]},{name:"node",label:"Workflow Node",type:"object",objectType:"node",propertiesSchema:[{name:"id",type:"integer",label:"ID"},{name:"name",type:"string",label:"Name"},{name:"slug",type:"string",label:"Slug"},{name:"label",type:"string",label:"Label"},{name:"activation_timestamp",type:"string",label:"Activation Time"}]},{name:"array",label:"Array",type:"array"}])}),[CS]),React.createElement(T.StrictMode,null,React.createElement(ES,null))}var DS=document.getElementById("future-workflow-editor");DS&&(0,D.H)(DS).render(React.createElement(PS,null))})()})(); \ No newline at end of file diff --git a/assets/js/workflowManualSelectionBlockEditor.js b/assets/js/workflowManualSelectionBlockEditor.js index 008e06393..006e9e9ad 100644 --- a/assets/js/workflowManualSelectionBlockEditor.js +++ b/assets/js/workflowManualSelectionBlockEditor.js @@ -1448,6 +1448,473 @@ var getWorkflowsEnabledForPost = function getWorkflowsEnabledForPost(state) { /***/ }), +/***/ "./node_modules/css-loader/dist/cjs.js!./node_modules/postcss-loader/dist/cjs.js!./assets/jsx/workflow-manual-selection/block-editor/css/style.css": +/*!*********************************************************************************************************************************************************!*\ + !*** ./node_modules/css-loader/dist/cjs.js!./node_modules/postcss-loader/dist/cjs.js!./assets/jsx/workflow-manual-selection/block-editor/css/style.css ***! + \*********************************************************************************************************************************************************/ +/***/ ((module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__) +/* harmony export */ }); +/* harmony import */ var _node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ "./node_modules/css-loader/dist/runtime/sourceMaps.js"); +/* harmony import */ var _node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ "./node_modules/css-loader/dist/runtime/api.js"); +/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__); +// Imports + + +var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default()((_node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default())); +// Module +___CSS_LOADER_EXPORT___.push([module.id, `#publishpress-future-block-editor .components-checkbox-control__label { + max-width: 100%; +} +`, "",{"version":3,"sources":["webpack://./assets/jsx/workflow-manual-selection/block-editor/css/style.css"],"names":[],"mappings":"AAAA;IACI,eAAe;AACnB","sourcesContent":["#publishpress-future-block-editor .components-checkbox-control__label {\n max-width: 100%;\n}\n"],"sourceRoot":""}]); +// Exports +/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___); + + +/***/ }), + +/***/ "./node_modules/css-loader/dist/runtime/api.js": +/*!*****************************************************!*\ + !*** ./node_modules/css-loader/dist/runtime/api.js ***! + \*****************************************************/ +/***/ ((module) => { + + + +/* + MIT License http://www.opensource.org/licenses/mit-license.php + Author Tobias Koppers @sokra +*/ +module.exports = function (cssWithMappingToString) { + var list = []; + + // return the list of modules as css string + list.toString = function toString() { + return this.map(function (item) { + var content = ""; + var needLayer = typeof item[5] !== "undefined"; + if (item[4]) { + content += "@supports (".concat(item[4], ") {"); + } + if (item[2]) { + content += "@media ".concat(item[2], " {"); + } + if (needLayer) { + content += "@layer".concat(item[5].length > 0 ? " ".concat(item[5]) : "", " {"); + } + content += cssWithMappingToString(item); + if (needLayer) { + content += "}"; + } + if (item[2]) { + content += "}"; + } + if (item[4]) { + content += "}"; + } + return content; + }).join(""); + }; + + // import a list of modules into the list + list.i = function i(modules, media, dedupe, supports, layer) { + if (typeof modules === "string") { + modules = [[null, modules, undefined]]; + } + var alreadyImportedModules = {}; + if (dedupe) { + for (var k = 0; k < this.length; k++) { + var id = this[k][0]; + if (id != null) { + alreadyImportedModules[id] = true; + } + } + } + for (var _k = 0; _k < modules.length; _k++) { + var item = [].concat(modules[_k]); + if (dedupe && alreadyImportedModules[item[0]]) { + continue; + } + if (typeof layer !== "undefined") { + if (typeof item[5] === "undefined") { + item[5] = layer; + } else { + item[1] = "@layer".concat(item[5].length > 0 ? " ".concat(item[5]) : "", " {").concat(item[1], "}"); + item[5] = layer; + } + } + if (media) { + if (!item[2]) { + item[2] = media; + } else { + item[1] = "@media ".concat(item[2], " {").concat(item[1], "}"); + item[2] = media; + } + } + if (supports) { + if (!item[4]) { + item[4] = "".concat(supports); + } else { + item[1] = "@supports (".concat(item[4], ") {").concat(item[1], "}"); + item[4] = supports; + } + } + list.push(item); + } + }; + return list; +}; + +/***/ }), + +/***/ "./node_modules/css-loader/dist/runtime/sourceMaps.js": +/*!************************************************************!*\ + !*** ./node_modules/css-loader/dist/runtime/sourceMaps.js ***! + \************************************************************/ +/***/ ((module) => { + + + +module.exports = function (item) { + var content = item[1]; + var cssMapping = item[3]; + if (!cssMapping) { + return content; + } + if (typeof btoa === "function") { + var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(cssMapping)))); + var data = "sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(base64); + var sourceMapping = "/*# ".concat(data, " */"); + return [content].concat([sourceMapping]).join("\n"); + } + return [content].join("\n"); +}; + +/***/ }), + +/***/ "./assets/jsx/workflow-manual-selection/block-editor/css/style.css": +/*!*************************************************************************!*\ + !*** ./assets/jsx/workflow-manual-selection/block-editor/css/style.css ***! + \*************************************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__) +/* harmony export */ }); +/* harmony import */ var _node_modules_style_loader_dist_runtime_injectStylesIntoStyleTag_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! !../../../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js */ "./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js"); +/* harmony import */ var _node_modules_style_loader_dist_runtime_injectStylesIntoStyleTag_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_injectStylesIntoStyleTag_js__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _node_modules_style_loader_dist_runtime_styleDomAPI_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! !../../../../../node_modules/style-loader/dist/runtime/styleDomAPI.js */ "./node_modules/style-loader/dist/runtime/styleDomAPI.js"); +/* harmony import */ var _node_modules_style_loader_dist_runtime_styleDomAPI_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_styleDomAPI_js__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _node_modules_style_loader_dist_runtime_insertBySelector_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! !../../../../../node_modules/style-loader/dist/runtime/insertBySelector.js */ "./node_modules/style-loader/dist/runtime/insertBySelector.js"); +/* harmony import */ var _node_modules_style_loader_dist_runtime_insertBySelector_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_insertBySelector_js__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _node_modules_style_loader_dist_runtime_setAttributesWithoutAttributes_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! !../../../../../node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js */ "./node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js"); +/* harmony import */ var _node_modules_style_loader_dist_runtime_setAttributesWithoutAttributes_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_setAttributesWithoutAttributes_js__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _node_modules_style_loader_dist_runtime_insertStyleElement_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! !../../../../../node_modules/style-loader/dist/runtime/insertStyleElement.js */ "./node_modules/style-loader/dist/runtime/insertStyleElement.js"); +/* harmony import */ var _node_modules_style_loader_dist_runtime_insertStyleElement_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_insertStyleElement_js__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var _node_modules_style_loader_dist_runtime_styleTagTransform_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! !../../../../../node_modules/style-loader/dist/runtime/styleTagTransform.js */ "./node_modules/style-loader/dist/runtime/styleTagTransform.js"); +/* harmony import */ var _node_modules_style_loader_dist_runtime_styleTagTransform_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_styleTagTransform_js__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var _node_modules_css_loader_dist_cjs_js_node_modules_postcss_loader_dist_cjs_js_style_css__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! !!../../../../../node_modules/css-loader/dist/cjs.js!../../../../../node_modules/postcss-loader/dist/cjs.js!./style.css */ "./node_modules/css-loader/dist/cjs.js!./node_modules/postcss-loader/dist/cjs.js!./assets/jsx/workflow-manual-selection/block-editor/css/style.css"); + + + + + + + + + + + +var options = {}; + +options.styleTagTransform = (_node_modules_style_loader_dist_runtime_styleTagTransform_js__WEBPACK_IMPORTED_MODULE_5___default()); +options.setAttributes = (_node_modules_style_loader_dist_runtime_setAttributesWithoutAttributes_js__WEBPACK_IMPORTED_MODULE_3___default()); +options.insert = _node_modules_style_loader_dist_runtime_insertBySelector_js__WEBPACK_IMPORTED_MODULE_2___default().bind(null, "head"); +options.domAPI = (_node_modules_style_loader_dist_runtime_styleDomAPI_js__WEBPACK_IMPORTED_MODULE_1___default()); +options.insertStyleElement = (_node_modules_style_loader_dist_runtime_insertStyleElement_js__WEBPACK_IMPORTED_MODULE_4___default()); + +var update = _node_modules_style_loader_dist_runtime_injectStylesIntoStyleTag_js__WEBPACK_IMPORTED_MODULE_0___default()(_node_modules_css_loader_dist_cjs_js_node_modules_postcss_loader_dist_cjs_js_style_css__WEBPACK_IMPORTED_MODULE_6__["default"], options); + + + + + /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (_node_modules_css_loader_dist_cjs_js_node_modules_postcss_loader_dist_cjs_js_style_css__WEBPACK_IMPORTED_MODULE_6__["default"] && _node_modules_css_loader_dist_cjs_js_node_modules_postcss_loader_dist_cjs_js_style_css__WEBPACK_IMPORTED_MODULE_6__["default"].locals ? _node_modules_css_loader_dist_cjs_js_node_modules_postcss_loader_dist_cjs_js_style_css__WEBPACK_IMPORTED_MODULE_6__["default"].locals : undefined); + + +/***/ }), + +/***/ "./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js": +/*!****************************************************************************!*\ + !*** ./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js ***! + \****************************************************************************/ +/***/ ((module) => { + + + +var stylesInDOM = []; +function getIndexByIdentifier(identifier) { + var result = -1; + for (var i = 0; i < stylesInDOM.length; i++) { + if (stylesInDOM[i].identifier === identifier) { + result = i; + break; + } + } + return result; +} +function modulesToDom(list, options) { + var idCountMap = {}; + var identifiers = []; + for (var i = 0; i < list.length; i++) { + var item = list[i]; + var id = options.base ? item[0] + options.base : item[0]; + var count = idCountMap[id] || 0; + var identifier = "".concat(id, " ").concat(count); + idCountMap[id] = count + 1; + var indexByIdentifier = getIndexByIdentifier(identifier); + var obj = { + css: item[1], + media: item[2], + sourceMap: item[3], + supports: item[4], + layer: item[5] + }; + if (indexByIdentifier !== -1) { + stylesInDOM[indexByIdentifier].references++; + stylesInDOM[indexByIdentifier].updater(obj); + } else { + var updater = addElementStyle(obj, options); + options.byIndex = i; + stylesInDOM.splice(i, 0, { + identifier: identifier, + updater: updater, + references: 1 + }); + } + identifiers.push(identifier); + } + return identifiers; +} +function addElementStyle(obj, options) { + var api = options.domAPI(options); + api.update(obj); + var updater = function updater(newObj) { + if (newObj) { + if (newObj.css === obj.css && newObj.media === obj.media && newObj.sourceMap === obj.sourceMap && newObj.supports === obj.supports && newObj.layer === obj.layer) { + return; + } + api.update(obj = newObj); + } else { + api.remove(); + } + }; + return updater; +} +module.exports = function (list, options) { + options = options || {}; + list = list || []; + var lastIdentifiers = modulesToDom(list, options); + return function update(newList) { + newList = newList || []; + for (var i = 0; i < lastIdentifiers.length; i++) { + var identifier = lastIdentifiers[i]; + var index = getIndexByIdentifier(identifier); + stylesInDOM[index].references--; + } + var newLastIdentifiers = modulesToDom(newList, options); + for (var _i = 0; _i < lastIdentifiers.length; _i++) { + var _identifier = lastIdentifiers[_i]; + var _index = getIndexByIdentifier(_identifier); + if (stylesInDOM[_index].references === 0) { + stylesInDOM[_index].updater(); + stylesInDOM.splice(_index, 1); + } + } + lastIdentifiers = newLastIdentifiers; + }; +}; + +/***/ }), + +/***/ "./node_modules/style-loader/dist/runtime/insertBySelector.js": +/*!********************************************************************!*\ + !*** ./node_modules/style-loader/dist/runtime/insertBySelector.js ***! + \********************************************************************/ +/***/ ((module) => { + + + +var memo = {}; + +/* istanbul ignore next */ +function getTarget(target) { + if (typeof memo[target] === "undefined") { + var styleTarget = document.querySelector(target); + + // Special case to return head of iframe instead of iframe itself + if (window.HTMLIFrameElement && styleTarget instanceof window.HTMLIFrameElement) { + try { + // This will throw an exception if access to iframe is blocked + // due to cross-origin restrictions + styleTarget = styleTarget.contentDocument.head; + } catch (e) { + // istanbul ignore next + styleTarget = null; + } + } + memo[target] = styleTarget; + } + return memo[target]; +} + +/* istanbul ignore next */ +function insertBySelector(insert, style) { + var target = getTarget(insert); + if (!target) { + throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid."); + } + target.appendChild(style); +} +module.exports = insertBySelector; + +/***/ }), + +/***/ "./node_modules/style-loader/dist/runtime/insertStyleElement.js": +/*!**********************************************************************!*\ + !*** ./node_modules/style-loader/dist/runtime/insertStyleElement.js ***! + \**********************************************************************/ +/***/ ((module) => { + + + +/* istanbul ignore next */ +function insertStyleElement(options) { + var element = document.createElement("style"); + options.setAttributes(element, options.attributes); + options.insert(element, options.options); + return element; +} +module.exports = insertStyleElement; + +/***/ }), + +/***/ "./node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js": +/*!**********************************************************************************!*\ + !*** ./node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js ***! + \**********************************************************************************/ +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + + + +/* istanbul ignore next */ +function setAttributesWithoutAttributes(styleElement) { + var nonce = true ? __webpack_require__.nc : 0; + if (nonce) { + styleElement.setAttribute("nonce", nonce); + } +} +module.exports = setAttributesWithoutAttributes; + +/***/ }), + +/***/ "./node_modules/style-loader/dist/runtime/styleDomAPI.js": +/*!***************************************************************!*\ + !*** ./node_modules/style-loader/dist/runtime/styleDomAPI.js ***! + \***************************************************************/ +/***/ ((module) => { + + + +/* istanbul ignore next */ +function apply(styleElement, options, obj) { + var css = ""; + if (obj.supports) { + css += "@supports (".concat(obj.supports, ") {"); + } + if (obj.media) { + css += "@media ".concat(obj.media, " {"); + } + var needLayer = typeof obj.layer !== "undefined"; + if (needLayer) { + css += "@layer".concat(obj.layer.length > 0 ? " ".concat(obj.layer) : "", " {"); + } + css += obj.css; + if (needLayer) { + css += "}"; + } + if (obj.media) { + css += "}"; + } + if (obj.supports) { + css += "}"; + } + var sourceMap = obj.sourceMap; + if (sourceMap && typeof btoa !== "undefined") { + css += "\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))), " */"); + } + + // For old IE + /* istanbul ignore if */ + options.styleTagTransform(css, styleElement, options.options); +} +function removeStyleElement(styleElement) { + // istanbul ignore if + if (styleElement.parentNode === null) { + return false; + } + styleElement.parentNode.removeChild(styleElement); +} + +/* istanbul ignore next */ +function domAPI(options) { + if (typeof document === "undefined") { + return { + update: function update() {}, + remove: function remove() {} + }; + } + var styleElement = options.insertStyleElement(options); + return { + update: function update(obj) { + apply(styleElement, options, obj); + }, + remove: function remove() { + removeStyleElement(styleElement); + } + }; +} +module.exports = domAPI; + +/***/ }), + +/***/ "./node_modules/style-loader/dist/runtime/styleTagTransform.js": +/*!*********************************************************************!*\ + !*** ./node_modules/style-loader/dist/runtime/styleTagTransform.js ***! + \*********************************************************************/ +/***/ ((module) => { + + + +/* istanbul ignore next */ +function styleTagTransform(css, styleElement) { + if (styleElement.styleSheet) { + styleElement.styleSheet.cssText = css; + } else { + while (styleElement.firstChild) { + styleElement.removeChild(styleElement.firstChild); + } + styleElement.appendChild(document.createTextNode(css)); + } +} +module.exports = styleTagTransform; + +/***/ }), + /***/ "react": /*!************************!*\ !*** external "React" ***! @@ -1542,7 +2009,7 @@ module.exports = wp.url; /******/ } /******/ // Create a new module (and put it into the cache) /******/ var module = __webpack_module_cache__[moduleId] = { -/******/ // no module.id needed +/******/ id: moduleId, /******/ // no module.loaded needed /******/ exports: {} /******/ }; @@ -1595,6 +2062,11 @@ module.exports = wp.url; /******/ }; /******/ })(); /******/ +/******/ /* webpack/runtime/nonce */ +/******/ (() => { +/******/ __webpack_require__.nc = undefined; +/******/ })(); +/******/ /************************************************************************/ var __webpack_exports__ = {}; // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. @@ -1613,6 +2085,8 @@ __webpack_require__.r(__webpack_exports__); /* harmony import */ var _wordpress_plugins__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_wordpress_plugins__WEBPACK_IMPORTED_MODULE_4__); /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! react */ "react"); /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var _css_style_css__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./css/style.css */ "./assets/jsx/workflow-manual-selection/block-editor/css/style.css"); + diff --git a/assets/js/workflowManualSelectionBlockEditor.min.js b/assets/js/workflowManualSelectionBlockEditor.min.js index cf0591f04..31cc7dafa 100644 --- a/assets/js/workflowManualSelectionBlockEditor.min.js +++ b/assets/js/workflowManualSelectionBlockEditor.min.js @@ -1 +1 @@ -(()=>{"use strict";var e={d:(r,t)=>{for(var o in t)e.o(t,o)&&!e.o(r,o)&&Object.defineProperty(r,o,{enumerable:!0,get:t[o]})},o:(e,r)=>Object.prototype.hasOwnProperty.call(e,r),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},r={};e.r(r),e.d(r,{getWorkflowsEnabledForPost:()=>f,getWorkflowsWithManualTrigger:()=>p});var t={};e.r(t),e.d(t,{setWorkflowsEnabledForPost:()=>w,setWorkflowsWithManualTrigger:()=>d,updateWorkflowsEnabledForPost:()=>h});const o=wp.data;function n(e){return n="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},n(e)}function a(e){return function(e){if(Array.isArray(e))return i(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,r){if(e){if("string"==typeof e)return i(e,r);var t={}.toString.call(e).slice(8,-1);return"Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t?Array.from(e):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?i(e,r):void 0}}(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 i(e,r){(null==r||r>e.length)&&(r=e.length);for(var t=0,o=Array(r);t{let t,o,n=e.path;return"string"==typeof e.namespace&&"string"==typeof e.endpoint&&(t=e.namespace.replace(/^\/|\/$/g,""),o=e.endpoint.replace(/^\//,""),n=o?t+"/"+o:t),delete e.namespace,delete e.endpoint,r({...e,path:n})},m=wp.url;function b(e,r){return Promise.resolve(r?e.body:new window.Response(JSON.stringify(e.body),{status:200,statusText:"OK",headers:e.headers}))}const O=({path:e,url:r,...t},o)=>({...t,url:r&&(0,m.addQueryArgs)(r,o),path:e&&(0,m.addQueryArgs)(e,o)}),_=e=>e.json?e.json():Promise.reject(e),P=e=>{const{next:r}=(e=>{if(!e)return{};const r=e.match(/<([^>]+)>; rel="next"/);return r?{next:r[1]}:{}})(e.headers.get("link"));return r},v=async(e,r)=>{if(!1===e.parse)return r(e);if(!(e=>{const r=!!e.path&&-1!==e.path.indexOf("per_page=-1"),t=!!e.url&&-1!==e.url.indexOf("per_page=-1");return r||t})(e))return r(e);const t=await x({...O(e,{per_page:100}),parse:!1}),o=await _(t);if(!Array.isArray(o))return o;let n=P(t);if(!n)return o;let a=[].concat(o);for(;n;){const r=await x({...e,path:void 0,url:n,parse:!1}),t=await _(r);a=a.concat(t),n=P(r)}return a},E=new Set(["PATCH","PUT","DELETE"]),k="GET",S=(e,r=!0)=>Promise.resolve(((e,r=!0)=>r?204===e.status?null:e.json?e.json():Promise.reject(e):e)(e,r)).catch((e=>j(e,r)));function j(e,r=!0){if(!r)throw e;return(e=>{const r={code:"invalid_json",message:(0,g.__)("The response is not a valid JSON response.")};if(!e||!e.json)throw r;return e.json().catch((()=>{throw r}))})(e).then((e=>{const r={code:"unknown_error",message:(0,g.__)("An unknown error occurred.")};throw e||r}))}const T={Accept:"application/json, */*;q=0.1"},W={credentials:"include"},A=[(e,r)=>("string"!=typeof e.url||(0,m.hasQueryArg)(e.url,"_locale")||(e.url=(0,m.addQueryArgs)(e.url,{_locale:"user"})),"string"!=typeof e.path||(0,m.hasQueryArg)(e.path,"_locale")||(e.path=(0,m.addQueryArgs)(e.path,{_locale:"user"})),r(e)),y,(e,r)=>{const{method:t=k}=e;return E.has(t.toUpperCase())&&(e={...e,headers:{...e.headers,"X-HTTP-Method-Override":t,"Content-Type":"application/json"},method:"POST"}),r(e)},v],F=e=>{if(e.status>=200&&e.status<300)return e;throw e};let M=e=>{const{url:r,path:t,data:o,parse:n=!0,...a}=e;let{body:i,headers:s}=e;return s={...T,...s},o&&(i=JSON.stringify(o),s["Content-Type"]="application/json"),window.fetch(r||t||window.location.href,{...W,...a,body:i,headers:s}).then((e=>Promise.resolve(e).then(F).catch((e=>j(e,n))).then((e=>S(e,n)))),(e=>{if(e&&"AbortError"===e.name)throw e;throw{code:"fetch_error",message:(0,g.__)("You are probably offline.")}}))};function R(e){return A.reduceRight(((e,r)=>t=>r(t,e)),M)(e).catch((r=>"rest_cookie_invalid_nonce"!==r.code?Promise.reject(r):window.fetch(R.nonceEndpoint).then(F).then((e=>e.text())).then((r=>(R.nonceMiddleware.nonce=r,R(e))))))}R.use=function(e){A.unshift(e)},R.setFetchHandler=function(e){M=e},R.createNonceMiddleware=function(e){const r=(e,t)=>{const{headers:o={}}=e;for(const n in o)if("x-wp-nonce"===n.toLowerCase()&&o[n]===r.nonce)return t(e);return t({...e,headers:{...o,"X-WP-Nonce":r.nonce}})};return r.nonce=e,r},R.createPreloadingMiddleware=function(e){const r=Object.fromEntries(Object.entries(e).map((([e,r])=>[(0,m.normalizePath)(e),r])));return(e,t)=>{const{parse:o=!0}=e;let n=e.path;if(!n&&e.url){const{rest_route:r,...t}=(0,m.getQueryArgs)(e.url);"string"==typeof r&&(n=(0,m.addQueryArgs)(r,t))}if("string"!=typeof n)return t(e);const a=e.method||"GET",i=(0,m.normalizePath)(n);if("GET"===a&&r[i]){const e=r[i];return delete r[i],b(e,!!o)}if("OPTIONS"===a&&r[a]&&r[a][i]){const e=r[a][i];return delete r[a][i],b(e,!!o)}return t(e)}},R.createRootURLMiddleware=e=>(r,t)=>y(r,(r=>{let o,n=r.url,a=r.path;return"string"==typeof a&&(o=e,-1!==e.indexOf("?")&&(a=a.replace("?","&")),a=a.replace(/^\//,""),"string"==typeof o&&-1!==o.indexOf("?")&&(a=a.replace("?","&")),n=o+a),t({...r,url:n})})),R.fetchAllMiddleware=v,R.mediaUploadMiddleware=(e,r)=>{if(!function(e){const r=!!e.method&&"POST"===e.method;return(!!e.path&&-1!==e.path.indexOf("/wp/v2/media")||!!e.url&&-1!==e.url.indexOf("/wp/v2/media"))&&r}(e))return r(e);let t=0;const o=e=>(t++,r({path:`/wp/v2/media/${e}/post-process`,method:"POST",data:{action:"create-image-subsizes"},parse:!1}).catch((()=>t<5?o(e):(r({path:`/wp/v2/media/${e}?force=true`,method:"DELETE"}),Promise.reject()))));return r({...e,parse:!1}).catch((r=>{const t=r.headers.get("x-wp-upload-attachment-id");return r.status>=500&&r.status<600&&t?o(t).catch((()=>!1!==e.parse?Promise.reject({code:"post_process",message:(0,g.__)("Media upload failed. If this is a photo or a large image, please scale it down and try again.")}):Promise.reject(r))):j(r,e.parse)})).then((r=>S(r,e.parse)))},R.createThemePreviewMiddleware=e=>(r,t)=>{if("string"==typeof r.url){const t=(0,m.getQueryArg)(r.url,"wp_theme_preview");void 0===t?r.url=(0,m.addQueryArgs)(r.url,{wp_theme_preview:e}):""===t&&(r.url=(0,m.removeQueryArgs)(r.url,"wp_theme_preview"))}if("string"==typeof r.path){const t=(0,m.getQueryArg)(r.path,"wp_theme_preview");void 0===t?r.path=(0,m.addQueryArgs)(r.path,{wp_theme_preview:e}):""===t&&(r.path=(0,m.removeQueryArgs)(r.path,"wp_theme_preview"))}return t(r)};const x=R;function I(e){return I="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},I(e)}function D(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r&&(o=o.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),t.push.apply(t,o)}return t}function L(e,r,t){return(r=function(e){var r=function(e){if("object"!=I(e)||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var t=r.call(e,"string");if("object"!=I(t))return t;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==I(r)?r:r+""}(r))in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}const N=function(e){for(var r=1;re,API_FETCH:({request:e})=>x(e)});var Q=(0,o.createReduxStore)("publishpress-future/manual-post-trigger",{reducer:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:c,r=arguments.length>1?arguments[1]:void 0;switch(r.type){case"SET_WORKFLOWS_WITH_MANUAL_TRIGGER":return function(e,r){return l(l({},e),{},{workflowsWithManualTrigger:a(r.payload)})}(e,r);case"SET_WORKFLOWS_ENABLED_FOR_POST":return function(e,r){return l(l({},e),{},{workflowsEnabledForPost:a(r.payload)})}(e,r);case"UPDATE_WORKFLOWS_ENABLED_FOR_POST":return function(e,r){var t=r.payload,o=t.workflowId,n=t.enabled,i=a(e.workflowsEnabledForPost);return n&&!i.includes(o)&&i.push(o),!n&&i.includes(o)&&i.splice(i.indexOf(o),1),l(l({},e),{},{workflowsEnabledForPost:i})}(e,r)}return e},actions:t,selectors:r,controls:N});(0,o.register)(Q);const U=wp.components,C=wp.element;function G(e){var r=e.context,t=e.postId,n=e.apiUrl,a=e.nonce,i=e.onChange,s=(0,o.useSelect)((function(e){return{workflowsWithManualTrigger:e(Q).getWorkflowsWithManualTrigger(),workflowsEnabledForPost:e(Q).getWorkflowsEnabledForPost()}})),l=s.workflowsWithManualTrigger,u=s.workflowsEnabledForPost,c=(0,o.useDispatch)(Q),p=c.updateWorkflowsEnabledForPost,f=c.setWorkflowsWithManualTrigger,d=c.setWorkflowsEnabledForPost;(0,C.useEffect)((function(){f([]),d([]),x({url:"".concat(n,"/posts/workflow-settings/").concat(t),headers:{"X-WP-Nonce":a}}).then((function(e){f(e.workflowsWithManualTrigger),d(e.manuallyEnabledWorkflows)}))}),[t]);var w=Object.keys(l).map((function(e){var r=l[e],t=u.includes(r.workflowId);return React.createElement(U.CheckboxControl,{key:"manual-workflow-trigger-"+e,label:r.label,name:"future_workflow_manual_trigger[]",checked:t,value:r.workflowId,onChange:function(e){return function(e,r){p(e,r),i&&i(e,r)}(r.workflowId,e)}})}));return React.createElement(React.Fragment,null,w.length>0&&React.createElement("div",{id:"post-expirator-".concat(r,"-wrapper")},React.createElement("input",{type:"hidden",name:"future_workflow_view",value:r}),w))}const K=wp.plugins,H=React;(0,K.registerPlugin)("publishpress-future-workflow-manual-trigger",{render:function(){var e=wp.editPost.PluginDocumentSettingPanel,r=(0,o.useSelect)((function(e){return{workflowsEnabledForPost:e(Q).getWorkflowsEnabledForPost()}})).workflowsEnabledForPost,t=(0,o.useDispatch)("core/editor").editPost;(0,H.useEffect)((function(){n(r)}),[r]);var n=function(e){var r={publishpress_future_workflow_manual_trigger:{enabledWorkflows:[]}};r.publishpress_future_workflow_manual_trigger={enabledWorkflows:e},t(r)},a=window.futureWorkflowManualSelection.apiUrl,i=window.futureWorkflowManualSelection.nonce,s=window.futureWorkflowManualSelection.postId;return React.createElement(e,{name:"publishpress-future-workflow-manual-trigger",title:(0,g.__)("Action Workflows","post-expirator"),initialOpen:!0,className:"future-workflow-manual-trigger"},React.createElement(G,{context:"block-editor",postId:s,apiUrl:a,nonce:i}))}})})(); \ No newline at end of file +(()=>{"use strict";var e={3788:(e,t,r)=>{r.d(t,{A:()=>s});var n=r(1601),o=r.n(n),a=r(6314),i=r.n(a)()(o());i.push([e.id,"#publishpress-future-block-editor .components-checkbox-control__label {\n max-width: 100%;\n}\n",""]);const s=i},6314:e=>{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,a){"string"==typeof e&&(e=[[null,e,void 0]]);var i={};if(n)for(var s=0;s0?" ".concat(l[5]):""," {").concat(l[1],"}")),l[5]=a),r&&(l[2]?(l[1]="@media ".concat(l[2]," {").concat(l[1],"}"),l[2]=r):l[2]=r),o&&(l[4]?(l[1]="@supports (".concat(l[4],") {").concat(l[1],"}"),l[4]=o):l[4]="".concat(o)),t.push(l))}},t}},1601:e=>{e.exports=function(e){return e[1]}},5072:e=>{var t=[];function r(e){for(var r=-1,n=0;n{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=>{e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},5056:(e,t,r)=>{e.exports=function(e){var t=r.nc;t&&e.setAttribute("nonce",t)}},7825:e=>{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 a=r.sourceMap;a&&"undefined"!=typeof btoa&&(n+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(a))))," */")),t.styleTagTransform(n,e,t.options)}(t,e,r)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},1113:e=>{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 a=t[n]={id:n,exports:{}};return e[n](a,a.exports,r),a.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.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.nc=void 0;var n={};r.r(n),r.d(n,{getWorkflowsEnabledForPost:()=>w,getWorkflowsWithManualTrigger:()=>d});var o={};r.r(o),r.d(o,{setWorkflowsEnabledForPost:()=>m,setWorkflowsWithManualTrigger:()=>h,updateWorkflowsEnabledForPost:()=>y});const a=wp.data;function i(e){return i="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},i(e)}function s(e){return function(e){if(Array.isArray(e))return c(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return c(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?c(e,t):void 0}}(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 c(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r{let r,n,o=e.path;return"string"==typeof e.namespace&&"string"==typeof e.endpoint&&(r=e.namespace.replace(/^\/|\/$/g,""),n=e.endpoint.replace(/^\//,""),o=n?r+"/"+n:r),delete e.namespace,delete e.endpoint,t({...e,path:o})},v=wp.url;function O(e,t){return Promise.resolve(t?e.body:new window.Response(JSON.stringify(e.body),{status:200,statusText:"OK",headers:e.headers}))}const _=({path:e,url:t,...r},n)=>({...r,url:t&&(0,v.addQueryArgs)(t,n),path:e&&(0,v.addQueryArgs)(e,n)}),P=e=>e.json?e.json():Promise.reject(e),E=e=>{const{next:t}=(e=>{if(!e)return{};const t=e.match(/<([^>]+)>; rel="next"/);return t?{next:t[1]}:{}})(e.headers.get("link"));return t},S=async(e,t)=>{if(!1===e.parse)return t(e);if(!(e=>{const t=!!e.path&&-1!==e.path.indexOf("per_page=-1"),r=!!e.url&&-1!==e.url.indexOf("per_page=-1");return t||r})(e))return t(e);const r=await D({..._(e,{per_page:100}),parse:!1}),n=await P(r);if(!Array.isArray(n))return n;let o=E(r);if(!o)return n;let a=[].concat(n);for(;o;){const t=await D({...e,path:void 0,url:o,parse:!1}),r=await P(t);a=a.concat(r),o=E(t)}return a},k=new Set(["PATCH","PUT","DELETE"]),T="GET",j=(e,t=!0)=>Promise.resolve(((e,t=!0)=>t?204===e.status?null:e.json?e.json():Promise.reject(e):e)(e,t)).catch((e=>A(e,t)));function A(e,t=!0){if(!t)throw e;return(e=>{const t={code:"invalid_json",message:(0,g.__)("The response is not a valid JSON response.")};if(!e||!e.json)throw t;return e.json().catch((()=>{throw t}))})(e).then((e=>{const t={code:"unknown_error",message:(0,g.__)("An unknown error occurred.")};throw e||t}))}const W={Accept:"application/json, */*;q=0.1"},x={credentials:"include"},M=[(e,t)=>("string"!=typeof e.url||(0,v.hasQueryArg)(e.url,"_locale")||(e.url=(0,v.addQueryArgs)(e.url,{_locale:"user"})),"string"!=typeof e.path||(0,v.hasQueryArg)(e.path,"_locale")||(e.path=(0,v.addQueryArgs)(e.path,{_locale:"user"})),t(e)),b,(e,t)=>{const{method:r=T}=e;return k.has(r.toUpperCase())&&(e={...e,headers:{...e.headers,"X-HTTP-Method-Override":r,"Content-Type":"application/json"},method:"POST"}),t(e)},S],F=e=>{if(e.status>=200&&e.status<300)return e;throw e};let R=e=>{const{url:t,path:r,data:n,parse:o=!0,...a}=e;let{body:i,headers:s}=e;return s={...W,...s},n&&(i=JSON.stringify(n),s["Content-Type"]="application/json"),window.fetch(t||r||window.location.href,{...x,...a,body:i,headers:s}).then((e=>Promise.resolve(e).then(F).catch((e=>A(e,o))).then((e=>j(e,o)))),(e=>{if(e&&"AbortError"===e.name)throw e;throw{code:"fetch_error",message:(0,g.__)("You are probably offline.")}}))};function I(e){return M.reduceRight(((e,t)=>r=>t(r,e)),R)(e).catch((t=>"rest_cookie_invalid_nonce"!==t.code?Promise.reject(t):window.fetch(I.nonceEndpoint).then(F).then((e=>e.text())).then((t=>(I.nonceMiddleware.nonce=t,I(e))))))}I.use=function(e){M.unshift(e)},I.setFetchHandler=function(e){R=e},I.createNonceMiddleware=function(e){const t=(e,r)=>{const{headers:n={}}=e;for(const o in n)if("x-wp-nonce"===o.toLowerCase()&&n[o]===t.nonce)return r(e);return r({...e,headers:{...n,"X-WP-Nonce":t.nonce}})};return t.nonce=e,t},I.createPreloadingMiddleware=function(e){const t=Object.fromEntries(Object.entries(e).map((([e,t])=>[(0,v.normalizePath)(e),t])));return(e,r)=>{const{parse:n=!0}=e;let o=e.path;if(!o&&e.url){const{rest_route:t,...r}=(0,v.getQueryArgs)(e.url);"string"==typeof t&&(o=(0,v.addQueryArgs)(t,r))}if("string"!=typeof o)return r(e);const a=e.method||"GET",i=(0,v.normalizePath)(o);if("GET"===a&&t[i]){const e=t[i];return delete t[i],O(e,!!n)}if("OPTIONS"===a&&t[a]&&t[a][i]){const e=t[a][i];return delete t[a][i],O(e,!!n)}return r(e)}},I.createRootURLMiddleware=e=>(t,r)=>b(t,(t=>{let n,o=t.url,a=t.path;return"string"==typeof a&&(n=e,-1!==e.indexOf("?")&&(a=a.replace("?","&")),a=a.replace(/^\//,""),"string"==typeof n&&-1!==n.indexOf("?")&&(a=a.replace("?","&")),o=n+a),r({...t,url:o})})),I.fetchAllMiddleware=S,I.mediaUploadMiddleware=(e,t)=>{if(!function(e){const t=!!e.method&&"POST"===e.method;return(!!e.path&&-1!==e.path.indexOf("/wp/v2/media")||!!e.url&&-1!==e.url.indexOf("/wp/v2/media"))&&t}(e))return t(e);let r=0;const n=e=>(r++,t({path:`/wp/v2/media/${e}/post-process`,method:"POST",data:{action:"create-image-subsizes"},parse:!1}).catch((()=>r<5?n(e):(t({path:`/wp/v2/media/${e}?force=true`,method:"DELETE"}),Promise.reject()))));return t({...e,parse:!1}).catch((t=>{const r=t.headers.get("x-wp-upload-attachment-id");return t.status>=500&&t.status<600&&r?n(r).catch((()=>!1!==e.parse?Promise.reject({code:"post_process",message:(0,g.__)("Media upload failed. If this is a photo or a large image, please scale it down and try again.")}):Promise.reject(t))):A(t,e.parse)})).then((t=>j(t,e.parse)))},I.createThemePreviewMiddleware=e=>(t,r)=>{if("string"==typeof t.url){const r=(0,v.getQueryArg)(t.url,"wp_theme_preview");void 0===r?t.url=(0,v.addQueryArgs)(t.url,{wp_theme_preview:e}):""===r&&(t.url=(0,v.removeQueryArgs)(t.url,"wp_theme_preview"))}if("string"==typeof t.path){const r=(0,v.getQueryArg)(t.path,"wp_theme_preview");void 0===r?t.path=(0,v.addQueryArgs)(t.path,{wp_theme_preview:e}):""===r&&(t.path=(0,v.removeQueryArgs)(t.path,"wp_theme_preview"))}return r(t)};const D=I;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 L(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function N(e,t,r){return(t=function(e){var t=function(e){if("object"!=C(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=C(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==C(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const Q=function(e){for(var t=1;te,API_FETCH:({request:e})=>D(e)});var U=(0,a.createReduxStore)("publishpress-future/manual-post-trigger",{reducer:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:f,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"SET_WORKFLOWS_WITH_MANUAL_TRIGGER":return function(e,t){return l(l({},e),{},{workflowsWithManualTrigger:s(t.payload)})}(e,t);case"SET_WORKFLOWS_ENABLED_FOR_POST":return function(e,t){return l(l({},e),{},{workflowsEnabledForPost:s(t.payload)})}(e,t);case"UPDATE_WORKFLOWS_ENABLED_FOR_POST":return function(e,t){var r=t.payload,n=r.workflowId,o=r.enabled,a=s(e.workflowsEnabledForPost);return o&&!a.includes(n)&&a.push(n),!o&&a.includes(n)&&a.splice(a.indexOf(n),1),l(l({},e),{},{workflowsEnabledForPost:a})}(e,t)}return e},actions:o,selectors:n,controls:Q});(0,a.register)(U);const H=wp.components,G=wp.element;function K(e){var t=e.context,r=e.postId,n=e.apiUrl,o=e.nonce,i=e.onChange,s=(0,a.useSelect)((function(e){return{workflowsWithManualTrigger:e(U).getWorkflowsWithManualTrigger(),workflowsEnabledForPost:e(U).getWorkflowsEnabledForPost()}})),c=s.workflowsWithManualTrigger,u=s.workflowsEnabledForPost,l=(0,a.useDispatch)(U),p=l.updateWorkflowsEnabledForPost,f=l.setWorkflowsWithManualTrigger,d=l.setWorkflowsEnabledForPost;(0,G.useEffect)((function(){f([]),d([]),D({url:"".concat(n,"/posts/workflow-settings/").concat(r),headers:{"X-WP-Nonce":o}}).then((function(e){f(e.workflowsWithManualTrigger),d(e.manuallyEnabledWorkflows)}))}),[r]);var w=Object.keys(c).map((function(e){var t=c[e],r=u.includes(t.workflowId);return React.createElement(H.CheckboxControl,{key:"manual-workflow-trigger-"+e,label:t.label,name:"future_workflow_manual_trigger[]",checked:r,value:t.workflowId,onChange:function(e){return function(e,t){p(e,t),i&&i(e,t)}(t.workflowId,e)}})}));return React.createElement(React.Fragment,null,w.length>0&&React.createElement("div",{id:"post-expirator-".concat(t,"-wrapper")},React.createElement("input",{type:"hidden",name:"future_workflow_view",value:t}),w))}const B=wp.plugins,J=React;var $=r(5072),q=r.n($),z=r(7825),X=r.n(z),Y=r(7659),V=r.n(Y),Z=r(5056),ee=r.n(Z),te=r(540),re=r.n(te),ne=r(1113),oe=r.n(ne),ae=r(3788),ie={};ie.styleTagTransform=oe(),ie.setAttributes=ee(),ie.insert=V().bind(null,"head"),ie.domAPI=X(),ie.insertStyleElement=re(),q()(ae.A,ie),ae.A&&ae.A.locals&&ae.A.locals,(0,B.registerPlugin)("publishpress-future-workflow-manual-trigger",{render:function(){var e=wp.editPost.PluginDocumentSettingPanel,t=(0,a.useSelect)((function(e){return{workflowsEnabledForPost:e(U).getWorkflowsEnabledForPost()}})).workflowsEnabledForPost,r=(0,a.useDispatch)("core/editor").editPost;(0,J.useEffect)((function(){n(t)}),[t]);var n=function(e){var t={publishpress_future_workflow_manual_trigger:{enabledWorkflows:[]}};t.publishpress_future_workflow_manual_trigger={enabledWorkflows:e},r(t)},o=window.futureWorkflowManualSelection.apiUrl,i=window.futureWorkflowManualSelection.nonce,s=window.futureWorkflowManualSelection.postId;return React.createElement(e,{name:"publishpress-future-workflow-manual-trigger",title:(0,g.__)("Action Workflows","post-expirator"),initialOpen:!0,className:"future-workflow-manual-trigger"},React.createElement(K,{context:"block-editor",postId:s,apiUrl:o,nonce:i}))}})})(); \ No newline at end of file diff --git a/assets/js/workflowManualSelectionClassicEditor.js b/assets/js/workflowManualSelectionClassicEditor.js index 02b767508..bc3339d3a 100644 --- a/assets/js/workflowManualSelectionClassicEditor.js +++ b/assets/js/workflowManualSelectionClassicEditor.js @@ -1448,6 +1448,154 @@ var getWorkflowsEnabledForPost = function getWorkflowsEnabledForPost(state) { /***/ }), +/***/ "./node_modules/css-loader/dist/cjs.js!./node_modules/postcss-loader/dist/cjs.js!./assets/jsx/workflow-manual-selection/classic-editor/css/style.css": +/*!***********************************************************************************************************************************************************!*\ + !*** ./node_modules/css-loader/dist/cjs.js!./node_modules/postcss-loader/dist/cjs.js!./assets/jsx/workflow-manual-selection/classic-editor/css/style.css ***! + \***********************************************************************************************************************************************************/ +/***/ ((module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__) +/* harmony export */ }); +/* harmony import */ var _node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ "./node_modules/css-loader/dist/runtime/sourceMaps.js"); +/* harmony import */ var _node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ "./node_modules/css-loader/dist/runtime/api.js"); +/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__); +// Imports + + +var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default()((_node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default())); +// Module +___CSS_LOADER_EXPORT___.push([module.id, `#publishpress-future-classic-editor .components-checkbox-control__label { + max-width: 100%; +} +`, "",{"version":3,"sources":["webpack://./assets/jsx/workflow-manual-selection/classic-editor/css/style.css"],"names":[],"mappings":"AAAA;IACI,eAAe;AACnB","sourcesContent":["#publishpress-future-classic-editor .components-checkbox-control__label {\n max-width: 100%;\n}\n"],"sourceRoot":""}]); +// Exports +/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___); + + +/***/ }), + +/***/ "./node_modules/css-loader/dist/runtime/api.js": +/*!*****************************************************!*\ + !*** ./node_modules/css-loader/dist/runtime/api.js ***! + \*****************************************************/ +/***/ ((module) => { + + + +/* + MIT License http://www.opensource.org/licenses/mit-license.php + Author Tobias Koppers @sokra +*/ +module.exports = function (cssWithMappingToString) { + var list = []; + + // return the list of modules as css string + list.toString = function toString() { + return this.map(function (item) { + var content = ""; + var needLayer = typeof item[5] !== "undefined"; + if (item[4]) { + content += "@supports (".concat(item[4], ") {"); + } + if (item[2]) { + content += "@media ".concat(item[2], " {"); + } + if (needLayer) { + content += "@layer".concat(item[5].length > 0 ? " ".concat(item[5]) : "", " {"); + } + content += cssWithMappingToString(item); + if (needLayer) { + content += "}"; + } + if (item[2]) { + content += "}"; + } + if (item[4]) { + content += "}"; + } + return content; + }).join(""); + }; + + // import a list of modules into the list + list.i = function i(modules, media, dedupe, supports, layer) { + if (typeof modules === "string") { + modules = [[null, modules, undefined]]; + } + var alreadyImportedModules = {}; + if (dedupe) { + for (var k = 0; k < this.length; k++) { + var id = this[k][0]; + if (id != null) { + alreadyImportedModules[id] = true; + } + } + } + for (var _k = 0; _k < modules.length; _k++) { + var item = [].concat(modules[_k]); + if (dedupe && alreadyImportedModules[item[0]]) { + continue; + } + if (typeof layer !== "undefined") { + if (typeof item[5] === "undefined") { + item[5] = layer; + } else { + item[1] = "@layer".concat(item[5].length > 0 ? " ".concat(item[5]) : "", " {").concat(item[1], "}"); + item[5] = layer; + } + } + if (media) { + if (!item[2]) { + item[2] = media; + } else { + item[1] = "@media ".concat(item[2], " {").concat(item[1], "}"); + item[2] = media; + } + } + if (supports) { + if (!item[4]) { + item[4] = "".concat(supports); + } else { + item[1] = "@supports (".concat(item[4], ") {").concat(item[1], "}"); + item[4] = supports; + } + } + list.push(item); + } + }; + return list; +}; + +/***/ }), + +/***/ "./node_modules/css-loader/dist/runtime/sourceMaps.js": +/*!************************************************************!*\ + !*** ./node_modules/css-loader/dist/runtime/sourceMaps.js ***! + \************************************************************/ +/***/ ((module) => { + + + +module.exports = function (item) { + var content = item[1]; + var cssMapping = item[3]; + if (!cssMapping) { + return content; + } + if (typeof btoa === "function") { + var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(cssMapping)))); + var data = "sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(base64); + var sourceMapping = "/*# ".concat(data, " */"); + return [content].concat([sourceMapping]).join("\n"); + } + return [content].join("\n"); +}; + +/***/ }), + /***/ "./node_modules/react-dom/client.js": /*!******************************************!*\ !*** ./node_modules/react-dom/client.js ***! @@ -1478,6 +1626,325 @@ if (false) {} else { } +/***/ }), + +/***/ "./assets/jsx/workflow-manual-selection/classic-editor/css/style.css": +/*!***************************************************************************!*\ + !*** ./assets/jsx/workflow-manual-selection/classic-editor/css/style.css ***! + \***************************************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__) +/* harmony export */ }); +/* harmony import */ var _node_modules_style_loader_dist_runtime_injectStylesIntoStyleTag_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! !../../../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js */ "./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js"); +/* harmony import */ var _node_modules_style_loader_dist_runtime_injectStylesIntoStyleTag_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_injectStylesIntoStyleTag_js__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _node_modules_style_loader_dist_runtime_styleDomAPI_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! !../../../../../node_modules/style-loader/dist/runtime/styleDomAPI.js */ "./node_modules/style-loader/dist/runtime/styleDomAPI.js"); +/* harmony import */ var _node_modules_style_loader_dist_runtime_styleDomAPI_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_styleDomAPI_js__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _node_modules_style_loader_dist_runtime_insertBySelector_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! !../../../../../node_modules/style-loader/dist/runtime/insertBySelector.js */ "./node_modules/style-loader/dist/runtime/insertBySelector.js"); +/* harmony import */ var _node_modules_style_loader_dist_runtime_insertBySelector_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_insertBySelector_js__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _node_modules_style_loader_dist_runtime_setAttributesWithoutAttributes_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! !../../../../../node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js */ "./node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js"); +/* harmony import */ var _node_modules_style_loader_dist_runtime_setAttributesWithoutAttributes_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_setAttributesWithoutAttributes_js__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _node_modules_style_loader_dist_runtime_insertStyleElement_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! !../../../../../node_modules/style-loader/dist/runtime/insertStyleElement.js */ "./node_modules/style-loader/dist/runtime/insertStyleElement.js"); +/* harmony import */ var _node_modules_style_loader_dist_runtime_insertStyleElement_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_insertStyleElement_js__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var _node_modules_style_loader_dist_runtime_styleTagTransform_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! !../../../../../node_modules/style-loader/dist/runtime/styleTagTransform.js */ "./node_modules/style-loader/dist/runtime/styleTagTransform.js"); +/* harmony import */ var _node_modules_style_loader_dist_runtime_styleTagTransform_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_node_modules_style_loader_dist_runtime_styleTagTransform_js__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var _node_modules_css_loader_dist_cjs_js_node_modules_postcss_loader_dist_cjs_js_style_css__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! !!../../../../../node_modules/css-loader/dist/cjs.js!../../../../../node_modules/postcss-loader/dist/cjs.js!./style.css */ "./node_modules/css-loader/dist/cjs.js!./node_modules/postcss-loader/dist/cjs.js!./assets/jsx/workflow-manual-selection/classic-editor/css/style.css"); + + + + + + + + + + + +var options = {}; + +options.styleTagTransform = (_node_modules_style_loader_dist_runtime_styleTagTransform_js__WEBPACK_IMPORTED_MODULE_5___default()); +options.setAttributes = (_node_modules_style_loader_dist_runtime_setAttributesWithoutAttributes_js__WEBPACK_IMPORTED_MODULE_3___default()); +options.insert = _node_modules_style_loader_dist_runtime_insertBySelector_js__WEBPACK_IMPORTED_MODULE_2___default().bind(null, "head"); +options.domAPI = (_node_modules_style_loader_dist_runtime_styleDomAPI_js__WEBPACK_IMPORTED_MODULE_1___default()); +options.insertStyleElement = (_node_modules_style_loader_dist_runtime_insertStyleElement_js__WEBPACK_IMPORTED_MODULE_4___default()); + +var update = _node_modules_style_loader_dist_runtime_injectStylesIntoStyleTag_js__WEBPACK_IMPORTED_MODULE_0___default()(_node_modules_css_loader_dist_cjs_js_node_modules_postcss_loader_dist_cjs_js_style_css__WEBPACK_IMPORTED_MODULE_6__["default"], options); + + + + + /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (_node_modules_css_loader_dist_cjs_js_node_modules_postcss_loader_dist_cjs_js_style_css__WEBPACK_IMPORTED_MODULE_6__["default"] && _node_modules_css_loader_dist_cjs_js_node_modules_postcss_loader_dist_cjs_js_style_css__WEBPACK_IMPORTED_MODULE_6__["default"].locals ? _node_modules_css_loader_dist_cjs_js_node_modules_postcss_loader_dist_cjs_js_style_css__WEBPACK_IMPORTED_MODULE_6__["default"].locals : undefined); + + +/***/ }), + +/***/ "./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js": +/*!****************************************************************************!*\ + !*** ./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js ***! + \****************************************************************************/ +/***/ ((module) => { + + + +var stylesInDOM = []; +function getIndexByIdentifier(identifier) { + var result = -1; + for (var i = 0; i < stylesInDOM.length; i++) { + if (stylesInDOM[i].identifier === identifier) { + result = i; + break; + } + } + return result; +} +function modulesToDom(list, options) { + var idCountMap = {}; + var identifiers = []; + for (var i = 0; i < list.length; i++) { + var item = list[i]; + var id = options.base ? item[0] + options.base : item[0]; + var count = idCountMap[id] || 0; + var identifier = "".concat(id, " ").concat(count); + idCountMap[id] = count + 1; + var indexByIdentifier = getIndexByIdentifier(identifier); + var obj = { + css: item[1], + media: item[2], + sourceMap: item[3], + supports: item[4], + layer: item[5] + }; + if (indexByIdentifier !== -1) { + stylesInDOM[indexByIdentifier].references++; + stylesInDOM[indexByIdentifier].updater(obj); + } else { + var updater = addElementStyle(obj, options); + options.byIndex = i; + stylesInDOM.splice(i, 0, { + identifier: identifier, + updater: updater, + references: 1 + }); + } + identifiers.push(identifier); + } + return identifiers; +} +function addElementStyle(obj, options) { + var api = options.domAPI(options); + api.update(obj); + var updater = function updater(newObj) { + if (newObj) { + if (newObj.css === obj.css && newObj.media === obj.media && newObj.sourceMap === obj.sourceMap && newObj.supports === obj.supports && newObj.layer === obj.layer) { + return; + } + api.update(obj = newObj); + } else { + api.remove(); + } + }; + return updater; +} +module.exports = function (list, options) { + options = options || {}; + list = list || []; + var lastIdentifiers = modulesToDom(list, options); + return function update(newList) { + newList = newList || []; + for (var i = 0; i < lastIdentifiers.length; i++) { + var identifier = lastIdentifiers[i]; + var index = getIndexByIdentifier(identifier); + stylesInDOM[index].references--; + } + var newLastIdentifiers = modulesToDom(newList, options); + for (var _i = 0; _i < lastIdentifiers.length; _i++) { + var _identifier = lastIdentifiers[_i]; + var _index = getIndexByIdentifier(_identifier); + if (stylesInDOM[_index].references === 0) { + stylesInDOM[_index].updater(); + stylesInDOM.splice(_index, 1); + } + } + lastIdentifiers = newLastIdentifiers; + }; +}; + +/***/ }), + +/***/ "./node_modules/style-loader/dist/runtime/insertBySelector.js": +/*!********************************************************************!*\ + !*** ./node_modules/style-loader/dist/runtime/insertBySelector.js ***! + \********************************************************************/ +/***/ ((module) => { + + + +var memo = {}; + +/* istanbul ignore next */ +function getTarget(target) { + if (typeof memo[target] === "undefined") { + var styleTarget = document.querySelector(target); + + // Special case to return head of iframe instead of iframe itself + if (window.HTMLIFrameElement && styleTarget instanceof window.HTMLIFrameElement) { + try { + // This will throw an exception if access to iframe is blocked + // due to cross-origin restrictions + styleTarget = styleTarget.contentDocument.head; + } catch (e) { + // istanbul ignore next + styleTarget = null; + } + } + memo[target] = styleTarget; + } + return memo[target]; +} + +/* istanbul ignore next */ +function insertBySelector(insert, style) { + var target = getTarget(insert); + if (!target) { + throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid."); + } + target.appendChild(style); +} +module.exports = insertBySelector; + +/***/ }), + +/***/ "./node_modules/style-loader/dist/runtime/insertStyleElement.js": +/*!**********************************************************************!*\ + !*** ./node_modules/style-loader/dist/runtime/insertStyleElement.js ***! + \**********************************************************************/ +/***/ ((module) => { + + + +/* istanbul ignore next */ +function insertStyleElement(options) { + var element = document.createElement("style"); + options.setAttributes(element, options.attributes); + options.insert(element, options.options); + return element; +} +module.exports = insertStyleElement; + +/***/ }), + +/***/ "./node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js": +/*!**********************************************************************************!*\ + !*** ./node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js ***! + \**********************************************************************************/ +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + + + +/* istanbul ignore next */ +function setAttributesWithoutAttributes(styleElement) { + var nonce = true ? __webpack_require__.nc : 0; + if (nonce) { + styleElement.setAttribute("nonce", nonce); + } +} +module.exports = setAttributesWithoutAttributes; + +/***/ }), + +/***/ "./node_modules/style-loader/dist/runtime/styleDomAPI.js": +/*!***************************************************************!*\ + !*** ./node_modules/style-loader/dist/runtime/styleDomAPI.js ***! + \***************************************************************/ +/***/ ((module) => { + + + +/* istanbul ignore next */ +function apply(styleElement, options, obj) { + var css = ""; + if (obj.supports) { + css += "@supports (".concat(obj.supports, ") {"); + } + if (obj.media) { + css += "@media ".concat(obj.media, " {"); + } + var needLayer = typeof obj.layer !== "undefined"; + if (needLayer) { + css += "@layer".concat(obj.layer.length > 0 ? " ".concat(obj.layer) : "", " {"); + } + css += obj.css; + if (needLayer) { + css += "}"; + } + if (obj.media) { + css += "}"; + } + if (obj.supports) { + css += "}"; + } + var sourceMap = obj.sourceMap; + if (sourceMap && typeof btoa !== "undefined") { + css += "\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))), " */"); + } + + // For old IE + /* istanbul ignore if */ + options.styleTagTransform(css, styleElement, options.options); +} +function removeStyleElement(styleElement) { + // istanbul ignore if + if (styleElement.parentNode === null) { + return false; + } + styleElement.parentNode.removeChild(styleElement); +} + +/* istanbul ignore next */ +function domAPI(options) { + if (typeof document === "undefined") { + return { + update: function update() {}, + remove: function remove() {} + }; + } + var styleElement = options.insertStyleElement(options); + return { + update: function update(obj) { + apply(styleElement, options, obj); + }, + remove: function remove() { + removeStyleElement(styleElement); + } + }; +} +module.exports = domAPI; + +/***/ }), + +/***/ "./node_modules/style-loader/dist/runtime/styleTagTransform.js": +/*!*********************************************************************!*\ + !*** ./node_modules/style-loader/dist/runtime/styleTagTransform.js ***! + \*********************************************************************/ +/***/ ((module) => { + + + +/* istanbul ignore next */ +function styleTagTransform(css, styleElement) { + if (styleElement.styleSheet) { + styleElement.styleSheet.cssText = css; + } else { + while (styleElement.firstChild) { + styleElement.removeChild(styleElement.firstChild); + } + styleElement.appendChild(document.createTextNode(css)); + } +} +module.exports = styleTagTransform; + /***/ }), /***/ "react-dom": @@ -1564,7 +2031,7 @@ module.exports = wp.url; /******/ } /******/ // Create a new module (and put it into the cache) /******/ var module = __webpack_module_cache__[moduleId] = { -/******/ // no module.id needed +/******/ id: moduleId, /******/ // no module.loaded needed /******/ exports: {} /******/ }; @@ -1617,6 +2084,11 @@ module.exports = wp.url; /******/ }; /******/ })(); /******/ +/******/ /* webpack/runtime/nonce */ +/******/ (() => { +/******/ __webpack_require__.nc = undefined; +/******/ })(); +/******/ /************************************************************************/ var __webpack_exports__ = {}; // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. @@ -1631,6 +2103,8 @@ __webpack_require__.r(__webpack_exports__); /* harmony import */ var _store__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../store */ "./assets/jsx/workflow-manual-selection/store/index.jsx"); /* harmony import */ var _fieldset__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../fieldset */ "./assets/jsx/workflow-manual-selection/fieldset/index.jsx"); /* harmony import */ var _wordpress_api_fetch__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @wordpress/api-fetch */ "./node_modules/@wordpress/api-fetch/build-module/index.js"); +/* harmony import */ var _css_style_css__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./css/style.css */ "./assets/jsx/workflow-manual-selection/classic-editor/css/style.css"); + diff --git a/assets/js/workflowManualSelectionClassicEditor.min.js b/assets/js/workflowManualSelectionClassicEditor.min.js index 9a86cb809..4a582d24f 100644 --- a/assets/js/workflowManualSelectionClassicEditor.min.js +++ b/assets/js/workflowManualSelectionClassicEditor.min.js @@ -1 +1 @@ -(()=>{"use strict";var e={5338:(e,r,t)=>{var o=t(5206);r.H=o.createRoot,o.hydrateRoot},5206:e=>{e.exports=ReactDOM}},r={};function t(o){var n=r[o];if(void 0!==n)return n.exports;var a=r[o]={exports:{}};return e[o](a,a.exports,t),a.exports}t.d=(e,r)=>{for(var o in r)t.o(r,o)&&!t.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:r[o]})},t.o=(e,r)=>Object.prototype.hasOwnProperty.call(e,r),t.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var o={};t.r(o),t.d(o,{getWorkflowsEnabledForPost:()=>h,getWorkflowsWithManualTrigger:()=>w});var n={};t.r(n),t.d(n,{setWorkflowsEnabledForPost:()=>g,setWorkflowsWithManualTrigger:()=>y,updateWorkflowsEnabledForPost:()=>m});const a=wp.data;var i=t(5338);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 c(e){return function(e){if(Array.isArray(e))return l(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,r){if(e){if("string"==typeof e)return l(e,r);var t={}.toString.call(e).slice(8,-1);return"Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t?Array.from(e):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?l(e,r):void 0}}(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 l(e,r){(null==r||r>e.length)&&(r=e.length);for(var t=0,o=Array(r);t{let t,o,n=e.path;return"string"==typeof e.namespace&&"string"==typeof e.endpoint&&(t=e.namespace.replace(/^\/|\/$/g,""),o=e.endpoint.replace(/^\//,""),n=o?t+"/"+o:t),delete e.namespace,delete e.endpoint,r({...e,path:n})},O=wp.url;function P(e,r){return Promise.resolve(r?e.body:new window.Response(JSON.stringify(e.body),{status:200,statusText:"OK",headers:e.headers}))}const _=({path:e,url:r,...t},o)=>({...t,url:r&&(0,O.addQueryArgs)(r,o),path:e&&(0,O.addQueryArgs)(e,o)}),E=e=>e.json?e.json():Promise.reject(e),S=e=>{const{next:r}=(e=>{if(!e)return{};const r=e.match(/<([^>]+)>; rel="next"/);return r?{next:r[1]}:{}})(e.headers.get("link"));return r},k=async(e,r)=>{if(!1===e.parse)return r(e);if(!(e=>{const r=!!e.path&&-1!==e.path.indexOf("per_page=-1"),t=!!e.url&&-1!==e.url.indexOf("per_page=-1");return r||t})(e))return r(e);const t=await L({..._(e,{per_page:100}),parse:!1}),o=await E(t);if(!Array.isArray(o))return o;let n=S(t);if(!n)return o;let a=[].concat(o);for(;n;){const r=await L({...e,path:void 0,url:n,parse:!1}),t=await E(r);a=a.concat(t),n=S(r)}return a},j=new Set(["PATCH","PUT","DELETE"]),T="GET",W=(e,r=!0)=>Promise.resolve(((e,r=!0)=>r?204===e.status?null:e.json?e.json():Promise.reject(e):e)(e,r)).catch((e=>A(e,r)));function A(e,r=!0){if(!r)throw e;return(e=>{const r={code:"invalid_json",message:(0,b.__)("The response is not a valid JSON response.")};if(!e||!e.json)throw r;return e.json().catch((()=>{throw r}))})(e).then((e=>{const r={code:"unknown_error",message:(0,b.__)("An unknown error occurred.")};throw e||r}))}const M={Accept:"application/json, */*;q=0.1"},R={credentials:"include"},F=[(e,r)=>("string"!=typeof e.url||(0,O.hasQueryArg)(e.url,"_locale")||(e.url=(0,O.addQueryArgs)(e.url,{_locale:"user"})),"string"!=typeof e.path||(0,O.hasQueryArg)(e.path,"_locale")||(e.path=(0,O.addQueryArgs)(e.path,{_locale:"user"})),r(e)),v,(e,r)=>{const{method:t=T}=e;return j.has(t.toUpperCase())&&(e={...e,headers:{...e.headers,"X-HTTP-Method-Override":t,"Content-Type":"application/json"},method:"POST"}),r(e)},k],x=e=>{if(e.status>=200&&e.status<300)return e;throw e};let I=e=>{const{url:r,path:t,data:o,parse:n=!0,...a}=e;let{body:i,headers:s}=e;return s={...M,...s},o&&(i=JSON.stringify(o),s["Content-Type"]="application/json"),window.fetch(r||t||window.location.href,{...R,...a,body:i,headers:s}).then((e=>Promise.resolve(e).then(x).catch((e=>A(e,n))).then((e=>W(e,n)))),(e=>{if(e&&"AbortError"===e.name)throw e;throw{code:"fetch_error",message:(0,b.__)("You are probably offline.")}}))};function D(e){return F.reduceRight(((e,r)=>t=>r(t,e)),I)(e).catch((r=>"rest_cookie_invalid_nonce"!==r.code?Promise.reject(r):window.fetch(D.nonceEndpoint).then(x).then((e=>e.text())).then((r=>(D.nonceMiddleware.nonce=r,D(e))))))}D.use=function(e){F.unshift(e)},D.setFetchHandler=function(e){I=e},D.createNonceMiddleware=function(e){const r=(e,t)=>{const{headers:o={}}=e;for(const n in o)if("x-wp-nonce"===n.toLowerCase()&&o[n]===r.nonce)return t(e);return t({...e,headers:{...o,"X-WP-Nonce":r.nonce}})};return r.nonce=e,r},D.createPreloadingMiddleware=function(e){const r=Object.fromEntries(Object.entries(e).map((([e,r])=>[(0,O.normalizePath)(e),r])));return(e,t)=>{const{parse:o=!0}=e;let n=e.path;if(!n&&e.url){const{rest_route:r,...t}=(0,O.getQueryArgs)(e.url);"string"==typeof r&&(n=(0,O.addQueryArgs)(r,t))}if("string"!=typeof n)return t(e);const a=e.method||"GET",i=(0,O.normalizePath)(n);if("GET"===a&&r[i]){const e=r[i];return delete r[i],P(e,!!o)}if("OPTIONS"===a&&r[a]&&r[a][i]){const e=r[a][i];return delete r[a][i],P(e,!!o)}return t(e)}},D.createRootURLMiddleware=e=>(r,t)=>v(r,(r=>{let o,n=r.url,a=r.path;return"string"==typeof a&&(o=e,-1!==e.indexOf("?")&&(a=a.replace("?","&")),a=a.replace(/^\//,""),"string"==typeof o&&-1!==o.indexOf("?")&&(a=a.replace("?","&")),n=o+a),t({...r,url:n})})),D.fetchAllMiddleware=k,D.mediaUploadMiddleware=(e,r)=>{if(!function(e){const r=!!e.method&&"POST"===e.method;return(!!e.path&&-1!==e.path.indexOf("/wp/v2/media")||!!e.url&&-1!==e.url.indexOf("/wp/v2/media"))&&r}(e))return r(e);let t=0;const o=e=>(t++,r({path:`/wp/v2/media/${e}/post-process`,method:"POST",data:{action:"create-image-subsizes"},parse:!1}).catch((()=>t<5?o(e):(r({path:`/wp/v2/media/${e}?force=true`,method:"DELETE"}),Promise.reject()))));return r({...e,parse:!1}).catch((r=>{const t=r.headers.get("x-wp-upload-attachment-id");return r.status>=500&&r.status<600&&t?o(t).catch((()=>!1!==e.parse?Promise.reject({code:"post_process",message:(0,b.__)("Media upload failed. If this is a photo or a large image, please scale it down and try again.")}):Promise.reject(r))):A(r,e.parse)})).then((r=>W(r,e.parse)))},D.createThemePreviewMiddleware=e=>(r,t)=>{if("string"==typeof r.url){const t=(0,O.getQueryArg)(r.url,"wp_theme_preview");void 0===t?r.url=(0,O.addQueryArgs)(r.url,{wp_theme_preview:e}):""===t&&(r.url=(0,O.removeQueryArgs)(r.url,"wp_theme_preview"))}if("string"==typeof r.path){const t=(0,O.getQueryArg)(r.path,"wp_theme_preview");void 0===t?r.path=(0,O.addQueryArgs)(r.path,{wp_theme_preview:e}):""===t&&(r.path=(0,O.removeQueryArgs)(r.path,"wp_theme_preview"))}return t(r)};const L=D;function N(e){return N="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},N(e)}function Q(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r&&(o=o.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),t.push.apply(t,o)}return t}function U(e,r,t){return(r=function(e){var r=function(e){if("object"!=N(e)||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var t=r.call(e,"string");if("object"!=N(t))return t;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==N(r)?r:r+""}(r))in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}const C=function(e){for(var r=1;re,API_FETCH:({request:e})=>L(e)});var H=(0,a.createReduxStore)("publishpress-future/manual-post-trigger",{reducer:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:d,r=arguments.length>1?arguments[1]:void 0;switch(r.type){case"SET_WORKFLOWS_WITH_MANUAL_TRIGGER":return function(e,r){return p(p({},e),{},{workflowsWithManualTrigger:c(r.payload)})}(e,r);case"SET_WORKFLOWS_ENABLED_FOR_POST":return function(e,r){return p(p({},e),{},{workflowsEnabledForPost:c(r.payload)})}(e,r);case"UPDATE_WORKFLOWS_ENABLED_FOR_POST":return function(e,r){var t=r.payload,o=t.workflowId,n=t.enabled,a=c(e.workflowsEnabledForPost);return n&&!a.includes(o)&&a.push(o),!n&&a.includes(o)&&a.splice(a.indexOf(o),1),p(p({},e),{},{workflowsEnabledForPost:a})}(e,r)}return e},actions:n,selectors:o,controls:C});(0,a.register)(H);const G=wp.components,K=wp.element;function B(e){var r=e.context,t=e.postId,o=e.apiUrl,n=e.nonce,i=e.onChange,s=(0,a.useSelect)((function(e){return{workflowsWithManualTrigger:e(H).getWorkflowsWithManualTrigger(),workflowsEnabledForPost:e(H).getWorkflowsEnabledForPost()}})),c=s.workflowsWithManualTrigger,l=s.workflowsEnabledForPost,u=(0,a.useDispatch)(H),p=u.updateWorkflowsEnabledForPost,f=u.setWorkflowsWithManualTrigger,d=u.setWorkflowsEnabledForPost;(0,K.useEffect)((function(){f([]),d([]),L({url:"".concat(o,"/posts/workflow-settings/").concat(t),headers:{"X-WP-Nonce":n}}).then((function(e){f(e.workflowsWithManualTrigger),d(e.manuallyEnabledWorkflows)}))}),[t]);var w=Object.keys(c).map((function(e){var r=c[e],t=l.includes(r.workflowId);return React.createElement(G.CheckboxControl,{key:"manual-workflow-trigger-"+e,label:r.label,name:"future_workflow_manual_trigger[]",checked:t,value:r.workflowId,onChange:function(e){return function(e,r){p(e,r),i&&i(e,r)}(r.workflowId,e)}})}));return React.createElement(React.Fragment,null,w.length>0&&React.createElement("div",{id:"post-expirator-".concat(r,"-wrapper")},React.createElement("input",{type:"hidden",name:"future_workflow_view",value:r}),w))}var X=document.getElementById("post-expirator-classic-editor");if(X){var $=(0,i.H)(X),q=document.querySelector(".inline-edit-save .save");q&&(q.onclick=function(){setTimeout((function(){$.unmount()}),1e3)});var z=window.futureWorkflowManualSelection.apiUrl,J=window.futureWorkflowManualSelection.nonce,Y=window.futureWorkflowManualSelection.postId;(0,a.dispatch)(H).setWorkflowsWithManualTrigger([]),(0,a.dispatch)(H).setWorkflowsEnabledForPost([]),L({url:"".concat(z,"/posts/workflow-settings/").concat(Y),headers:{"X-WP-Nonce":J}}).then((function(e){(0,a.dispatch)(H).setWorkflowsWithManualTrigger(e.workflowsWithManualTrigger),(0,a.dispatch)(H).setWorkflowsEnabledForPost(e.manuallyEnabledWorkflows)}));var V=React.createElement(B,{context:"classic-editor",postId:Y,apiUrl:z,nonce:J});$.render(V)}})(); \ No newline at end of file +(()=>{"use strict";var e={7873:(e,t,r)=>{r.d(t,{A:()=>s});var n=r(1601),o=r.n(n),a=r(6314),i=r.n(a)()(o());i.push([e.id,"#publishpress-future-classic-editor .components-checkbox-control__label {\n max-width: 100%;\n}\n",""]);const s=i},6314:e=>{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,a){"string"==typeof e&&(e=[[null,e,void 0]]);var i={};if(n)for(var s=0;s0?" ".concat(l[5]):""," {").concat(l[1],"}")),l[5]=a),r&&(l[2]?(l[1]="@media ".concat(l[2]," {").concat(l[1],"}"),l[2]=r):l[2]=r),o&&(l[4]?(l[1]="@supports (".concat(l[4],") {").concat(l[1],"}"),l[4]=o):l[4]="".concat(o)),t.push(l))}},t}},1601:e=>{e.exports=function(e){return e[1]}},5338:(e,t,r)=>{var n=r(5206);t.H=n.createRoot,n.hydrateRoot},5072:e=>{var t=[];function r(e){for(var r=-1,n=0;n{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=>{e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},5056:(e,t,r)=>{e.exports=function(e){var t=r.nc;t&&e.setAttribute("nonce",t)}},7825:e=>{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 a=r.sourceMap;a&&"undefined"!=typeof btoa&&(n+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(a))))," */")),t.styleTagTransform(n,e,t.options)}(t,e,r)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},1113:e=>{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))}}},5206:e=>{e.exports=ReactDOM}},t={};function r(n){var o=t[n];if(void 0!==o)return o.exports;var a=t[n]={id:n,exports:{}};return e[n](a,a.exports,r),a.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.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.nc=void 0;var n={};r.r(n),r.d(n,{getWorkflowsEnabledForPost:()=>w,getWorkflowsWithManualTrigger:()=>h});var o={};r.r(o),r.d(o,{setWorkflowsEnabledForPost:()=>m,setWorkflowsWithManualTrigger:()=>y,updateWorkflowsEnabledForPost:()=>g});const a=wp.data;var i=r(5338);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 c(e){return function(e){if(Array.isArray(e))return u(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return u(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?u(e,t):void 0}}(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 u(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r{let r,n,o=e.path;return"string"==typeof e.namespace&&"string"==typeof e.endpoint&&(r=e.namespace.replace(/^\/|\/$/g,""),n=e.endpoint.replace(/^\//,""),o=n?r+"/"+n:r),delete e.namespace,delete e.endpoint,t({...e,path:o})},O=wp.url;function P(e,t){return Promise.resolve(t?e.body:new window.Response(JSON.stringify(e.body),{status:200,statusText:"OK",headers:e.headers}))}const _=({path:e,url:t,...r},n)=>({...r,url:t&&(0,O.addQueryArgs)(t,n),path:e&&(0,O.addQueryArgs)(e,n)}),E=e=>e.json?e.json():Promise.reject(e),S=e=>{const{next:t}=(e=>{if(!e)return{};const t=e.match(/<([^>]+)>; rel="next"/);return t?{next:t[1]}:{}})(e.headers.get("link"));return t},T=async(e,t)=>{if(!1===e.parse)return t(e);if(!(e=>{const t=!!e.path&&-1!==e.path.indexOf("per_page=-1"),r=!!e.url&&-1!==e.url.indexOf("per_page=-1");return t||r})(e))return t(e);const r=await D({..._(e,{per_page:100}),parse:!1}),n=await E(r);if(!Array.isArray(n))return n;let o=S(r);if(!o)return n;let a=[].concat(n);for(;o;){const t=await D({...e,path:void 0,url:o,parse:!1}),r=await E(t);a=a.concat(r),o=S(t)}return a},k=new Set(["PATCH","PUT","DELETE"]),j="GET",A=(e,t=!0)=>Promise.resolve(((e,t=!0)=>t?204===e.status?null:e.json?e.json():Promise.reject(e):e)(e,t)).catch((e=>W(e,t)));function W(e,t=!0){if(!t)throw e;return(e=>{const t={code:"invalid_json",message:(0,v.__)("The response is not a valid JSON response.")};if(!e||!e.json)throw t;return e.json().catch((()=>{throw t}))})(e).then((e=>{const t={code:"unknown_error",message:(0,v.__)("An unknown error occurred.")};throw e||t}))}const M={Accept:"application/json, */*;q=0.1"},x={credentials:"include"},R=[(e,t)=>("string"!=typeof e.url||(0,O.hasQueryArg)(e.url,"_locale")||(e.url=(0,O.addQueryArgs)(e.url,{_locale:"user"})),"string"!=typeof e.path||(0,O.hasQueryArg)(e.path,"_locale")||(e.path=(0,O.addQueryArgs)(e.path,{_locale:"user"})),t(e)),b,(e,t)=>{const{method:r=j}=e;return k.has(r.toUpperCase())&&(e={...e,headers:{...e.headers,"X-HTTP-Method-Override":r,"Content-Type":"application/json"},method:"POST"}),t(e)},T],F=e=>{if(e.status>=200&&e.status<300)return e;throw e};let I=e=>{const{url:t,path:r,data:n,parse:o=!0,...a}=e;let{body:i,headers:s}=e;return s={...M,...s},n&&(i=JSON.stringify(n),s["Content-Type"]="application/json"),window.fetch(t||r||window.location.href,{...x,...a,body:i,headers:s}).then((e=>Promise.resolve(e).then(F).catch((e=>W(e,o))).then((e=>A(e,o)))),(e=>{if(e&&"AbortError"===e.name)throw e;throw{code:"fetch_error",message:(0,v.__)("You are probably offline.")}}))};function C(e){return R.reduceRight(((e,t)=>r=>t(r,e)),I)(e).catch((t=>"rest_cookie_invalid_nonce"!==t.code?Promise.reject(t):window.fetch(C.nonceEndpoint).then(F).then((e=>e.text())).then((t=>(C.nonceMiddleware.nonce=t,C(e))))))}C.use=function(e){R.unshift(e)},C.setFetchHandler=function(e){I=e},C.createNonceMiddleware=function(e){const t=(e,r)=>{const{headers:n={}}=e;for(const o in n)if("x-wp-nonce"===o.toLowerCase()&&n[o]===t.nonce)return r(e);return r({...e,headers:{...n,"X-WP-Nonce":t.nonce}})};return t.nonce=e,t},C.createPreloadingMiddleware=function(e){const t=Object.fromEntries(Object.entries(e).map((([e,t])=>[(0,O.normalizePath)(e),t])));return(e,r)=>{const{parse:n=!0}=e;let o=e.path;if(!o&&e.url){const{rest_route:t,...r}=(0,O.getQueryArgs)(e.url);"string"==typeof t&&(o=(0,O.addQueryArgs)(t,r))}if("string"!=typeof o)return r(e);const a=e.method||"GET",i=(0,O.normalizePath)(o);if("GET"===a&&t[i]){const e=t[i];return delete t[i],P(e,!!n)}if("OPTIONS"===a&&t[a]&&t[a][i]){const e=t[a][i];return delete t[a][i],P(e,!!n)}return r(e)}},C.createRootURLMiddleware=e=>(t,r)=>b(t,(t=>{let n,o=t.url,a=t.path;return"string"==typeof a&&(n=e,-1!==e.indexOf("?")&&(a=a.replace("?","&")),a=a.replace(/^\//,""),"string"==typeof n&&-1!==n.indexOf("?")&&(a=a.replace("?","&")),o=n+a),r({...t,url:o})})),C.fetchAllMiddleware=T,C.mediaUploadMiddleware=(e,t)=>{if(!function(e){const t=!!e.method&&"POST"===e.method;return(!!e.path&&-1!==e.path.indexOf("/wp/v2/media")||!!e.url&&-1!==e.url.indexOf("/wp/v2/media"))&&t}(e))return t(e);let r=0;const n=e=>(r++,t({path:`/wp/v2/media/${e}/post-process`,method:"POST",data:{action:"create-image-subsizes"},parse:!1}).catch((()=>r<5?n(e):(t({path:`/wp/v2/media/${e}?force=true`,method:"DELETE"}),Promise.reject()))));return t({...e,parse:!1}).catch((t=>{const r=t.headers.get("x-wp-upload-attachment-id");return t.status>=500&&t.status<600&&r?n(r).catch((()=>!1!==e.parse?Promise.reject({code:"post_process",message:(0,v.__)("Media upload failed. If this is a photo or a large image, please scale it down and try again.")}):Promise.reject(t))):W(t,e.parse)})).then((t=>A(t,e.parse)))},C.createThemePreviewMiddleware=e=>(t,r)=>{if("string"==typeof t.url){const r=(0,O.getQueryArg)(t.url,"wp_theme_preview");void 0===r?t.url=(0,O.addQueryArgs)(t.url,{wp_theme_preview:e}):""===r&&(t.url=(0,O.removeQueryArgs)(t.url,"wp_theme_preview"))}if("string"==typeof t.path){const r=(0,O.getQueryArg)(t.path,"wp_theme_preview");void 0===r?t.path=(0,O.addQueryArgs)(t.path,{wp_theme_preview:e}):""===r&&(t.path=(0,O.removeQueryArgs)(t.path,"wp_theme_preview"))}return r(t)};const D=C;function L(e){return L="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},L(e)}function N(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Q(e,t,r){return(t=function(e){var t=function(e){if("object"!=L(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=L(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==L(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const U=function(e){for(var t=1;te,API_FETCH:({request:e})=>D(e)});var H=(0,a.createReduxStore)("publishpress-future/manual-post-trigger",{reducer:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:d,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"SET_WORKFLOWS_WITH_MANUAL_TRIGGER":return function(e,t){return p(p({},e),{},{workflowsWithManualTrigger:c(t.payload)})}(e,t);case"SET_WORKFLOWS_ENABLED_FOR_POST":return function(e,t){return p(p({},e),{},{workflowsEnabledForPost:c(t.payload)})}(e,t);case"UPDATE_WORKFLOWS_ENABLED_FOR_POST":return function(e,t){var r=t.payload,n=r.workflowId,o=r.enabled,a=c(e.workflowsEnabledForPost);return o&&!a.includes(n)&&a.push(n),!o&&a.includes(n)&&a.splice(a.indexOf(n),1),p(p({},e),{},{workflowsEnabledForPost:a})}(e,t)}return e},actions:o,selectors:n,controls:U});(0,a.register)(H);const G=wp.components,K=wp.element;function B(e){var t=e.context,r=e.postId,n=e.apiUrl,o=e.nonce,i=e.onChange,s=(0,a.useSelect)((function(e){return{workflowsWithManualTrigger:e(H).getWorkflowsWithManualTrigger(),workflowsEnabledForPost:e(H).getWorkflowsEnabledForPost()}})),c=s.workflowsWithManualTrigger,u=s.workflowsEnabledForPost,l=(0,a.useDispatch)(H),p=l.updateWorkflowsEnabledForPost,f=l.setWorkflowsWithManualTrigger,d=l.setWorkflowsEnabledForPost;(0,K.useEffect)((function(){f([]),d([]),D({url:"".concat(n,"/posts/workflow-settings/").concat(r),headers:{"X-WP-Nonce":o}}).then((function(e){f(e.workflowsWithManualTrigger),d(e.manuallyEnabledWorkflows)}))}),[r]);var h=Object.keys(c).map((function(e){var t=c[e],r=u.includes(t.workflowId);return React.createElement(G.CheckboxControl,{key:"manual-workflow-trigger-"+e,label:t.label,name:"future_workflow_manual_trigger[]",checked:r,value:t.workflowId,onChange:function(e){return function(e,t){p(e,t),i&&i(e,t)}(t.workflowId,e)}})}));return React.createElement(React.Fragment,null,h.length>0&&React.createElement("div",{id:"post-expirator-".concat(t,"-wrapper")},React.createElement("input",{type:"hidden",name:"future_workflow_view",value:t}),h))}var q=r(5072),J=r.n(q),X=r(7825),$=r.n(X),z=r(7659),Y=r.n(z),V=r(5056),Z=r.n(V),ee=r(540),te=r.n(ee),re=r(1113),ne=r.n(re),oe=r(7873),ae={};ae.styleTagTransform=ne(),ae.setAttributes=Z(),ae.insert=Y().bind(null,"head"),ae.domAPI=$(),ae.insertStyleElement=te(),J()(oe.A,ae),oe.A&&oe.A.locals&&oe.A.locals;var ie=document.getElementById("post-expirator-classic-editor");if(ie){var se=(0,i.H)(ie),ce=document.querySelector(".inline-edit-save .save");ce&&(ce.onclick=function(){setTimeout((function(){se.unmount()}),1e3)});var ue=window.futureWorkflowManualSelection.apiUrl,le=window.futureWorkflowManualSelection.nonce,pe=window.futureWorkflowManualSelection.postId;(0,a.dispatch)(H).setWorkflowsWithManualTrigger([]),(0,a.dispatch)(H).setWorkflowsEnabledForPost([]),D({url:"".concat(ue,"/posts/workflow-settings/").concat(pe),headers:{"X-WP-Nonce":le}}).then((function(e){(0,a.dispatch)(H).setWorkflowsWithManualTrigger(e.workflowsWithManualTrigger),(0,a.dispatch)(H).setWorkflowsEnabledForPost(e.manuallyEnabledWorkflows)}));var fe=React.createElement(B,{context:"classic-editor",postId:pe,apiUrl:ue,nonce:le});se.render(fe)}})(); \ No newline at end of file diff --git a/assets/js/workflowManualSelectionQuickEdit.js b/assets/js/workflowManualSelectionQuickEdit.js index 854d15018..55950530f 100644 --- a/assets/js/workflowManualSelectionQuickEdit.js +++ b/assets/js/workflowManualSelectionQuickEdit.js @@ -1478,8 +1478,13 @@ ___CSS_LOADER_EXPORT___.push([module.id, `#publishpress-future-quick-edit { #publishpress-future-quick-edit label { display: inline-block; max-width: 100%; + line-height: 12px; } -`, "",{"version":3,"sources":["webpack://./assets/jsx/workflow-manual-selection/quick-edit/css/style.css"],"names":[],"mappings":"AAAA;IACI,gBAAgB;IAChB,aAAa;IACb,sBAAsB;IACtB,mBAAmB;AACvB;;;AAGA;IACI,qBAAqB;IACrB,eAAe;AACnB","sourcesContent":["#publishpress-future-quick-edit {\n max-width: 340px;\n padding: 14px;\n border: 1px solid #ddd;\n margin-bottom: 20px;\n}\n\n\n#publishpress-future-quick-edit label {\n display: inline-block;\n max-width: 100%;\n}\n"],"sourceRoot":""}]); + +#post-expirator-quick-edit-wrapper .components-checkbox-control__label { + line-height: 12px; +} +`, "",{"version":3,"sources":["webpack://./assets/jsx/workflow-manual-selection/quick-edit/css/style.css"],"names":[],"mappings":"AAAA;IACI,gBAAgB;IAChB,aAAa;IACb,sBAAsB;IACtB,mBAAmB;AACvB;;;AAGA;IACI,qBAAqB;IACrB,eAAe;IACf,iBAAiB;AACrB;;AAEA;IACI,iBAAiB;AACrB","sourcesContent":["#publishpress-future-quick-edit {\n max-width: 340px;\n padding: 14px;\n border: 1px solid #ddd;\n margin-bottom: 20px;\n}\n\n\n#publishpress-future-quick-edit label {\n display: inline-block;\n max-width: 100%;\n line-height: 12px;\n}\n\n#post-expirator-quick-edit-wrapper .components-checkbox-control__label {\n line-height: 12px;\n}\n"],"sourceRoot":""}]); // Exports /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___); diff --git a/assets/js/workflowManualSelectionQuickEdit.min.js b/assets/js/workflowManualSelectionQuickEdit.min.js index 8644d3fde..8b0ee6933 100644 --- a/assets/js/workflowManualSelectionQuickEdit.min.js +++ b/assets/js/workflowManualSelectionQuickEdit.min.js @@ -1 +1 @@ -(()=>{"use strict";var e={3657:(e,t,r)=>{r.d(t,{A:()=>s});var n=r(1601),o=r.n(n),a=r(6314),i=r.n(a)()(o());i.push([e.id,"#publishpress-future-pro-quick-edit-wrapper {\n max-width: 340px;\n padding: 14px;\n border: 1px solid #ddd;\n margin-bottom: 20px;\n}\n\n\n#publishpress-future-pro-quick-edit-wrapper label {\n display: inline-block;\n max-width: 100%;\n}\n",""]);const s=i},6314:e=>{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,a){"string"==typeof e&&(e=[[null,e,void 0]]);var i={};if(n)for(var s=0;s0?" ".concat(l[5]):""," {").concat(l[1],"}")),l[5]=a),r&&(l[2]?(l[1]="@media ".concat(l[2]," {").concat(l[1],"}"),l[2]=r):l[2]=r),o&&(l[4]?(l[1]="@supports (".concat(l[4],") {").concat(l[1],"}"),l[4]=o):l[4]="".concat(o)),t.push(l))}},t}},1601:e=>{e.exports=function(e){return e[1]}},5338:(e,t,r)=>{var n=r(5206);t.H=n.createRoot,n.hydrateRoot},5072:e=>{var t=[];function r(e){for(var r=-1,n=0;n{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=>{e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},5056:(e,t,r)=>{e.exports=function(e){var t=r.nc;t&&e.setAttribute("nonce",t)}},7825:e=>{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 a=r.sourceMap;a&&"undefined"!=typeof btoa&&(n+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(a))))," */")),t.styleTagTransform(n,e,t.options)}(t,e,r)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},1113:e=>{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))}}},5206:e=>{e.exports=ReactDOM}},t={};function r(n){var o=t[n];if(void 0!==o)return o.exports;var a=t[n]={id:n,exports:{}};return e[n](a,a.exports,r),a.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.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.nc=void 0;var n={};r.r(n),r.d(n,{getWorkflowsEnabledForPost:()=>w,getWorkflowsWithManualTrigger:()=>y});var o={};r.r(o),r.d(o,{setWorkflowsEnabledForPost:()=>g,setWorkflowsWithManualTrigger:()=>m,updateWorkflowsEnabledForPost:()=>v});var a=r(5338);const i=wp.data,s=wp.components;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){return function(e){if(Array.isArray(e))return l(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return l(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?l(e,t):void 0}}(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 l(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r{let r,n,o=e.path;return"string"==typeof e.namespace&&"string"==typeof e.endpoint&&(r=e.namespace.replace(/^\/|\/$/g,""),n=e.endpoint.replace(/^\//,""),o=n?r+"/"+n:r),delete e.namespace,delete e.endpoint,t({...e,path:o})},P=wp.url;function _(e,t){return Promise.resolve(t?e.body:new window.Response(JSON.stringify(e.body),{status:200,statusText:"OK",headers:e.headers}))}const E=({path:e,url:t,...r},n)=>({...r,url:t&&(0,P.addQueryArgs)(t,n),path:e&&(0,P.addQueryArgs)(e,n)}),S=e=>e.json?e.json():Promise.reject(e),T=e=>{const{next:t}=(e=>{if(!e)return{};const t=e.match(/<([^>]+)>; rel="next"/);return t?{next:t[1]}:{}})(e.headers.get("link"));return t},j=async(e,t)=>{if(!1===e.parse)return t(e);if(!(e=>{const t=!!e.path&&-1!==e.path.indexOf("per_page=-1"),r=!!e.url&&-1!==e.url.indexOf("per_page=-1");return t||r})(e))return t(e);const r=await L({...E(e,{per_page:100}),parse:!1}),n=await S(r);if(!Array.isArray(n))return n;let o=T(r);if(!o)return n;let a=[].concat(n);for(;o;){const t=await L({...e,path:void 0,url:o,parse:!1}),r=await S(t);a=a.concat(r),o=T(t)}return a},k=new Set(["PATCH","PUT","DELETE"]),A="GET",x=(e,t=!0)=>Promise.resolve(((e,t=!0)=>t?204===e.status?null:e.json?e.json():Promise.reject(e):e)(e,t)).catch((e=>W(e,t)));function W(e,t=!0){if(!t)throw e;return(e=>{const t={code:"invalid_json",message:(0,b.__)("The response is not a valid JSON response.")};if(!e||!e.json)throw t;return e.json().catch((()=>{throw t}))})(e).then((e=>{const t={code:"unknown_error",message:(0,b.__)("An unknown error occurred.")};throw e||t}))}const M={Accept:"application/json, */*;q=0.1"},R={credentials:"include"},F=[(e,t)=>("string"!=typeof e.url||(0,P.hasQueryArg)(e.url,"_locale")||(e.url=(0,P.addQueryArgs)(e.url,{_locale:"user"})),"string"!=typeof e.path||(0,P.hasQueryArg)(e.path,"_locale")||(e.path=(0,P.addQueryArgs)(e.path,{_locale:"user"})),t(e)),O,(e,t)=>{const{method:r=A}=e;return k.has(r.toUpperCase())&&(e={...e,headers:{...e.headers,"X-HTTP-Method-Override":r,"Content-Type":"application/json"},method:"POST"}),t(e)},j],I=e=>{if(e.status>=200&&e.status<300)return e;throw e};let C=e=>{const{url:t,path:r,data:n,parse:o=!0,...a}=e;let{body:i,headers:s}=e;return s={...M,...s},n&&(i=JSON.stringify(n),s["Content-Type"]="application/json"),window.fetch(t||r||window.location.href,{...R,...a,body:i,headers:s}).then((e=>Promise.resolve(e).then(I).catch((e=>W(e,o))).then((e=>x(e,o)))),(e=>{if(e&&"AbortError"===e.name)throw e;throw{code:"fetch_error",message:(0,b.__)("You are probably offline.")}}))};function D(e){return F.reduceRight(((e,t)=>r=>t(r,e)),C)(e).catch((t=>"rest_cookie_invalid_nonce"!==t.code?Promise.reject(t):window.fetch(D.nonceEndpoint).then(I).then((e=>e.text())).then((t=>(D.nonceMiddleware.nonce=t,D(e))))))}D.use=function(e){F.unshift(e)},D.setFetchHandler=function(e){C=e},D.createNonceMiddleware=function(e){const t=(e,r)=>{const{headers:n={}}=e;for(const o in n)if("x-wp-nonce"===o.toLowerCase()&&n[o]===t.nonce)return r(e);return r({...e,headers:{...n,"X-WP-Nonce":t.nonce}})};return t.nonce=e,t},D.createPreloadingMiddleware=function(e){const t=Object.fromEntries(Object.entries(e).map((([e,t])=>[(0,P.normalizePath)(e),t])));return(e,r)=>{const{parse:n=!0}=e;let o=e.path;if(!o&&e.url){const{rest_route:t,...r}=(0,P.getQueryArgs)(e.url);"string"==typeof t&&(o=(0,P.addQueryArgs)(t,r))}if("string"!=typeof o)return r(e);const a=e.method||"GET",i=(0,P.normalizePath)(o);if("GET"===a&&t[i]){const e=t[i];return delete t[i],_(e,!!n)}if("OPTIONS"===a&&t[a]&&t[a][i]){const e=t[a][i];return delete t[a][i],_(e,!!n)}return r(e)}},D.createRootURLMiddleware=e=>(t,r)=>O(t,(t=>{let n,o=t.url,a=t.path;return"string"==typeof a&&(n=e,-1!==e.indexOf("?")&&(a=a.replace("?","&")),a=a.replace(/^\//,""),"string"==typeof n&&-1!==n.indexOf("?")&&(a=a.replace("?","&")),o=n+a),r({...t,url:o})})),D.fetchAllMiddleware=j,D.mediaUploadMiddleware=(e,t)=>{if(!function(e){const t=!!e.method&&"POST"===e.method;return(!!e.path&&-1!==e.path.indexOf("/wp/v2/media")||!!e.url&&-1!==e.url.indexOf("/wp/v2/media"))&&t}(e))return t(e);let r=0;const n=e=>(r++,t({path:`/wp/v2/media/${e}/post-process`,method:"POST",data:{action:"create-image-subsizes"},parse:!1}).catch((()=>r<5?n(e):(t({path:`/wp/v2/media/${e}?force=true`,method:"DELETE"}),Promise.reject()))));return t({...e,parse:!1}).catch((t=>{const r=t.headers.get("x-wp-upload-attachment-id");return t.status>=500&&t.status<600&&r?n(r).catch((()=>!1!==e.parse?Promise.reject({code:"post_process",message:(0,b.__)("Media upload failed. If this is a photo or a large image, please scale it down and try again.")}):Promise.reject(t))):W(t,e.parse)})).then((t=>x(t,e.parse)))},D.createThemePreviewMiddleware=e=>(t,r)=>{if("string"==typeof t.url){const r=(0,P.getQueryArg)(t.url,"wp_theme_preview");void 0===r?t.url=(0,P.addQueryArgs)(t.url,{wp_theme_preview:e}):""===r&&(t.url=(0,P.removeQueryArgs)(t.url,"wp_theme_preview"))}if("string"==typeof t.path){const r=(0,P.getQueryArg)(t.path,"wp_theme_preview");void 0===r?t.path=(0,P.addQueryArgs)(t.path,{wp_theme_preview:e}):""===r&&(t.path=(0,P.removeQueryArgs)(t.path,"wp_theme_preview"))}return r(t)};const L=D;function N(e){return N="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},N(e)}function Q(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function U(e,t,r){return(t=function(e){var t=function(e){if("object"!=N(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=N(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==N(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const H=function(e){for(var t=1;te,API_FETCH:({request:e})=>L(e)});var q=(0,i.createReduxStore)("publishpress-future/manual-post-trigger",{reducer:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:h,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"SET_WORKFLOWS_WITH_MANUAL_TRIGGER":return function(e,t){return f(f({},e),{},{workflowsWithManualTrigger:u(t.payload)})}(e,t);case"SET_WORKFLOWS_ENABLED_FOR_POST":return function(e,t){return f(f({},e),{},{workflowsEnabledForPost:u(t.payload)})}(e,t);case"UPDATE_WORKFLOWS_ENABLED_FOR_POST":return function(e,t){var r=t.payload,n=r.workflowId,o=r.enabled,a=u(e.workflowsEnabledForPost);return o&&!a.includes(n)&&a.push(n),!o&&a.includes(n)&&a.splice(a.indexOf(n),1),f(f({},e),{},{workflowsEnabledForPost:a})}(e,t)}return e},actions:o,selectors:n,controls:H});(0,i.register)(q);const G=wp.element;function K(e){var t=e.context,r=e.postId,n=e.apiUrl,o=e.nonce,a=e.onChange,c=(0,i.useSelect)((function(e){return{workflowsWithManualTrigger:e(q).getWorkflowsWithManualTrigger(),workflowsEnabledForPost:e(q).getWorkflowsEnabledForPost()}})),u=c.workflowsWithManualTrigger,l=c.workflowsEnabledForPost,p=(0,i.useDispatch)(q),f=p.updateWorkflowsEnabledForPost,d=p.setWorkflowsWithManualTrigger,h=p.setWorkflowsEnabledForPost;(0,G.useEffect)((function(){d([]),h([]),L({url:"".concat(n,"/posts/workflow-settings/").concat(r),headers:{"X-WP-Nonce":o}}).then((function(e){d(e.workflowsWithManualTrigger),h(e.manuallyEnabledWorkflows)}))}),[r]);var y=Object.keys(u).map((function(e){var t=u[e],r=l.includes(t.workflowId);return React.createElement(s.CheckboxControl,{key:"manual-workflow-trigger-"+e,label:t.label,name:"future_workflow_manual_trigger[]",checked:r,value:t.workflowId,onChange:function(e){return function(e,t){f(e,t),a&&a(e,t)}(t.workflowId,e)}})}));return React.createElement(React.Fragment,null,y.length>0&&React.createElement("div",{id:"post-expirator-".concat(t,"-wrapper")},React.createElement("input",{type:"hidden",name:"future_workflow_view",value:t}),y))}var B=r(5072),J=r.n(B),$=r(7825),z=r.n($),X=r(7659),Y=r.n(X),V=r(5056),Z=r.n(V),ee=r(540),te=r.n(ee),re=r(1113),ne=r.n(re),oe=r(3657),ae={};ae.styleTagTransform=ne(),ae.setAttributes=Z(),ae.insert=Y().bind(null,"head"),ae.domAPI=z(),ae.insertStyleElement=te(),J()(oe.A,ae),oe.A&&oe.A.locals&&oe.A.locals;var ie=window.inlineEditPost.edit,se=window.inlineEditPost.revert;window.inlineEditPost.edit=function(e,t){ie.apply(this,arguments);var r=function(e){return"string"==typeof e||"number"==typeof e?e:e.closest("tr").id.split("-")[1]}(e),n=document.getElementById("post-expirator-quick-edit");if(n){var o=(0,a.H)(n),i=document.querySelector(".inline-edit-save .save");i&&(i.onclick=function(){setTimeout((function(){o.unmount()}),1e3)});var s=window.futureWorkflowManualSelection.apiUrl,c=window.futureWorkflowManualSelection.nonce,u=React.createElement(K,{context:"quick-edit",postId:r,apiUrl:s,nonce:c});o.render(u),window.inlineEditPost.revert=function(){o.unmount(),se.apply(this,arguments)}}}})(); \ No newline at end of file +(()=>{"use strict";var e={3657:(e,t,r)=>{r.d(t,{A:()=>s});var n=r(1601),o=r.n(n),a=r(6314),i=r.n(a)()(o());i.push([e.id,"#publishpress-future-quick-edit {\n max-width: 340px;\n padding: 14px;\n border: 1px solid #ddd;\n margin-bottom: 20px;\n}\n\n\n#publishpress-future-quick-edit label {\n display: inline-block;\n max-width: 100%;\n line-height: 12px;\n}\n\n#post-expirator-quick-edit-wrapper .components-checkbox-control__label {\n line-height: 12px;\n}\n",""]);const s=i},6314:e=>{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,a){"string"==typeof e&&(e=[[null,e,void 0]]);var i={};if(n)for(var s=0;s0?" ".concat(l[5]):""," {").concat(l[1],"}")),l[5]=a),r&&(l[2]?(l[1]="@media ".concat(l[2]," {").concat(l[1],"}"),l[2]=r):l[2]=r),o&&(l[4]?(l[1]="@supports (".concat(l[4],") {").concat(l[1],"}"),l[4]=o):l[4]="".concat(o)),t.push(l))}},t}},1601:e=>{e.exports=function(e){return e[1]}},5338:(e,t,r)=>{var n=r(5206);t.H=n.createRoot,n.hydrateRoot},5072:e=>{var t=[];function r(e){for(var r=-1,n=0;n{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=>{e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},5056:(e,t,r)=>{e.exports=function(e){var t=r.nc;t&&e.setAttribute("nonce",t)}},7825:e=>{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 a=r.sourceMap;a&&"undefined"!=typeof btoa&&(n+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(a))))," */")),t.styleTagTransform(n,e,t.options)}(t,e,r)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},1113:e=>{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))}}},5206:e=>{e.exports=ReactDOM}},t={};function r(n){var o=t[n];if(void 0!==o)return o.exports;var a=t[n]={id:n,exports:{}};return e[n](a,a.exports,r),a.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.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.nc=void 0;var n={};r.r(n),r.d(n,{getWorkflowsEnabledForPost:()=>w,getWorkflowsWithManualTrigger:()=>y});var o={};r.r(o),r.d(o,{setWorkflowsEnabledForPost:()=>g,setWorkflowsWithManualTrigger:()=>m,updateWorkflowsEnabledForPost:()=>v});var a=r(5338);const i=wp.data,s=wp.components;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){return function(e){if(Array.isArray(e))return l(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return l(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?l(e,t):void 0}}(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 l(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r{let r,n,o=e.path;return"string"==typeof e.namespace&&"string"==typeof e.endpoint&&(r=e.namespace.replace(/^\/|\/$/g,""),n=e.endpoint.replace(/^\//,""),o=n?r+"/"+n:r),delete e.namespace,delete e.endpoint,t({...e,path:o})},P=wp.url;function _(e,t){return Promise.resolve(t?e.body:new window.Response(JSON.stringify(e.body),{status:200,statusText:"OK",headers:e.headers}))}const E=({path:e,url:t,...r},n)=>({...r,url:t&&(0,P.addQueryArgs)(t,n),path:e&&(0,P.addQueryArgs)(e,n)}),S=e=>e.json?e.json():Promise.reject(e),T=e=>{const{next:t}=(e=>{if(!e)return{};const t=e.match(/<([^>]+)>; rel="next"/);return t?{next:t[1]}:{}})(e.headers.get("link"));return t},j=async(e,t)=>{if(!1===e.parse)return t(e);if(!(e=>{const t=!!e.path&&-1!==e.path.indexOf("per_page=-1"),r=!!e.url&&-1!==e.url.indexOf("per_page=-1");return t||r})(e))return t(e);const r=await L({...E(e,{per_page:100}),parse:!1}),n=await S(r);if(!Array.isArray(n))return n;let o=T(r);if(!o)return n;let a=[].concat(n);for(;o;){const t=await L({...e,path:void 0,url:o,parse:!1}),r=await S(t);a=a.concat(r),o=T(t)}return a},k=new Set(["PATCH","PUT","DELETE"]),A="GET",x=(e,t=!0)=>Promise.resolve(((e,t=!0)=>t?204===e.status?null:e.json?e.json():Promise.reject(e):e)(e,t)).catch((e=>W(e,t)));function W(e,t=!0){if(!t)throw e;return(e=>{const t={code:"invalid_json",message:(0,b.__)("The response is not a valid JSON response.")};if(!e||!e.json)throw t;return e.json().catch((()=>{throw t}))})(e).then((e=>{const t={code:"unknown_error",message:(0,b.__)("An unknown error occurred.")};throw e||t}))}const M={Accept:"application/json, */*;q=0.1"},R={credentials:"include"},F=[(e,t)=>("string"!=typeof e.url||(0,P.hasQueryArg)(e.url,"_locale")||(e.url=(0,P.addQueryArgs)(e.url,{_locale:"user"})),"string"!=typeof e.path||(0,P.hasQueryArg)(e.path,"_locale")||(e.path=(0,P.addQueryArgs)(e.path,{_locale:"user"})),t(e)),O,(e,t)=>{const{method:r=A}=e;return k.has(r.toUpperCase())&&(e={...e,headers:{...e.headers,"X-HTTP-Method-Override":r,"Content-Type":"application/json"},method:"POST"}),t(e)},j],I=e=>{if(e.status>=200&&e.status<300)return e;throw e};let C=e=>{const{url:t,path:r,data:n,parse:o=!0,...a}=e;let{body:i,headers:s}=e;return s={...M,...s},n&&(i=JSON.stringify(n),s["Content-Type"]="application/json"),window.fetch(t||r||window.location.href,{...R,...a,body:i,headers:s}).then((e=>Promise.resolve(e).then(I).catch((e=>W(e,o))).then((e=>x(e,o)))),(e=>{if(e&&"AbortError"===e.name)throw e;throw{code:"fetch_error",message:(0,b.__)("You are probably offline.")}}))};function D(e){return F.reduceRight(((e,t)=>r=>t(r,e)),C)(e).catch((t=>"rest_cookie_invalid_nonce"!==t.code?Promise.reject(t):window.fetch(D.nonceEndpoint).then(I).then((e=>e.text())).then((t=>(D.nonceMiddleware.nonce=t,D(e))))))}D.use=function(e){F.unshift(e)},D.setFetchHandler=function(e){C=e},D.createNonceMiddleware=function(e){const t=(e,r)=>{const{headers:n={}}=e;for(const o in n)if("x-wp-nonce"===o.toLowerCase()&&n[o]===t.nonce)return r(e);return r({...e,headers:{...n,"X-WP-Nonce":t.nonce}})};return t.nonce=e,t},D.createPreloadingMiddleware=function(e){const t=Object.fromEntries(Object.entries(e).map((([e,t])=>[(0,P.normalizePath)(e),t])));return(e,r)=>{const{parse:n=!0}=e;let o=e.path;if(!o&&e.url){const{rest_route:t,...r}=(0,P.getQueryArgs)(e.url);"string"==typeof t&&(o=(0,P.addQueryArgs)(t,r))}if("string"!=typeof o)return r(e);const a=e.method||"GET",i=(0,P.normalizePath)(o);if("GET"===a&&t[i]){const e=t[i];return delete t[i],_(e,!!n)}if("OPTIONS"===a&&t[a]&&t[a][i]){const e=t[a][i];return delete t[a][i],_(e,!!n)}return r(e)}},D.createRootURLMiddleware=e=>(t,r)=>O(t,(t=>{let n,o=t.url,a=t.path;return"string"==typeof a&&(n=e,-1!==e.indexOf("?")&&(a=a.replace("?","&")),a=a.replace(/^\//,""),"string"==typeof n&&-1!==n.indexOf("?")&&(a=a.replace("?","&")),o=n+a),r({...t,url:o})})),D.fetchAllMiddleware=j,D.mediaUploadMiddleware=(e,t)=>{if(!function(e){const t=!!e.method&&"POST"===e.method;return(!!e.path&&-1!==e.path.indexOf("/wp/v2/media")||!!e.url&&-1!==e.url.indexOf("/wp/v2/media"))&&t}(e))return t(e);let r=0;const n=e=>(r++,t({path:`/wp/v2/media/${e}/post-process`,method:"POST",data:{action:"create-image-subsizes"},parse:!1}).catch((()=>r<5?n(e):(t({path:`/wp/v2/media/${e}?force=true`,method:"DELETE"}),Promise.reject()))));return t({...e,parse:!1}).catch((t=>{const r=t.headers.get("x-wp-upload-attachment-id");return t.status>=500&&t.status<600&&r?n(r).catch((()=>!1!==e.parse?Promise.reject({code:"post_process",message:(0,b.__)("Media upload failed. If this is a photo or a large image, please scale it down and try again.")}):Promise.reject(t))):W(t,e.parse)})).then((t=>x(t,e.parse)))},D.createThemePreviewMiddleware=e=>(t,r)=>{if("string"==typeof t.url){const r=(0,P.getQueryArg)(t.url,"wp_theme_preview");void 0===r?t.url=(0,P.addQueryArgs)(t.url,{wp_theme_preview:e}):""===r&&(t.url=(0,P.removeQueryArgs)(t.url,"wp_theme_preview"))}if("string"==typeof t.path){const r=(0,P.getQueryArg)(t.path,"wp_theme_preview");void 0===r?t.path=(0,P.addQueryArgs)(t.path,{wp_theme_preview:e}):""===r&&(t.path=(0,P.removeQueryArgs)(t.path,"wp_theme_preview"))}return r(t)};const L=D;function N(e){return N="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},N(e)}function Q(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function U(e,t,r){return(t=function(e){var t=function(e){if("object"!=N(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=N(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==N(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const H=function(e){for(var t=1;te,API_FETCH:({request:e})=>L(e)});var q=(0,i.createReduxStore)("publishpress-future/manual-post-trigger",{reducer:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:h,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case"SET_WORKFLOWS_WITH_MANUAL_TRIGGER":return function(e,t){return d(d({},e),{},{workflowsWithManualTrigger:u(t.payload)})}(e,t);case"SET_WORKFLOWS_ENABLED_FOR_POST":return function(e,t){return d(d({},e),{},{workflowsEnabledForPost:u(t.payload)})}(e,t);case"UPDATE_WORKFLOWS_ENABLED_FOR_POST":return function(e,t){var r=t.payload,n=r.workflowId,o=r.enabled,a=u(e.workflowsEnabledForPost);return o&&!a.includes(n)&&a.push(n),!o&&a.includes(n)&&a.splice(a.indexOf(n),1),d(d({},e),{},{workflowsEnabledForPost:a})}(e,t)}return e},actions:o,selectors:n,controls:H});(0,i.register)(q);const G=wp.element;function K(e){var t=e.context,r=e.postId,n=e.apiUrl,o=e.nonce,a=e.onChange,c=(0,i.useSelect)((function(e){return{workflowsWithManualTrigger:e(q).getWorkflowsWithManualTrigger(),workflowsEnabledForPost:e(q).getWorkflowsEnabledForPost()}})),u=c.workflowsWithManualTrigger,l=c.workflowsEnabledForPost,p=(0,i.useDispatch)(q),d=p.updateWorkflowsEnabledForPost,f=p.setWorkflowsWithManualTrigger,h=p.setWorkflowsEnabledForPost;(0,G.useEffect)((function(){f([]),h([]),L({url:"".concat(n,"/posts/workflow-settings/").concat(r),headers:{"X-WP-Nonce":o}}).then((function(e){f(e.workflowsWithManualTrigger),h(e.manuallyEnabledWorkflows)}))}),[r]);var y=Object.keys(u).map((function(e){var t=u[e],r=l.includes(t.workflowId);return React.createElement(s.CheckboxControl,{key:"manual-workflow-trigger-"+e,label:t.label,name:"future_workflow_manual_trigger[]",checked:r,value:t.workflowId,onChange:function(e){return function(e,t){d(e,t),a&&a(e,t)}(t.workflowId,e)}})}));return React.createElement(React.Fragment,null,y.length>0&&React.createElement("div",{id:"post-expirator-".concat(t,"-wrapper")},React.createElement("input",{type:"hidden",name:"future_workflow_view",value:t}),y))}var B=r(5072),J=r.n(B),$=r(7825),z=r.n($),X=r(7659),Y=r.n(X),V=r(5056),Z=r.n(V),ee=r(540),te=r.n(ee),re=r(1113),ne=r.n(re),oe=r(3657),ae={};ae.styleTagTransform=ne(),ae.setAttributes=Z(),ae.insert=Y().bind(null,"head"),ae.domAPI=z(),ae.insertStyleElement=te(),J()(oe.A,ae),oe.A&&oe.A.locals&&oe.A.locals;var ie=window.inlineEditPost.edit,se=window.inlineEditPost.revert;window.inlineEditPost.edit=function(e,t){ie.apply(this,arguments);var r=function(e){return"string"==typeof e||"number"==typeof e?e:e.closest("tr").id.split("-")[1]}(e),n=document.getElementById("post-expirator-quick-edit");if(n){var o=(0,a.H)(n),i=document.querySelector(".inline-edit-save .save");i&&(i.onclick=function(){setTimeout((function(){o.unmount()}),1e3)});var s=window.futureWorkflowManualSelection.apiUrl,c=window.futureWorkflowManualSelection.nonce,u=React.createElement(K,{context:"quick-edit",postId:r,apiUrl:s,nonce:c});o.render(u),window.inlineEditPost.revert=function(){o.unmount(),se.apply(this,arguments)}}}})(); \ No newline at end of file diff --git a/assets/jsx/backup-panel/components/backup-panel.jsx b/assets/jsx/backup-panel/components/backup-panel.jsx new file mode 100644 index 000000000..2a41dae73 --- /dev/null +++ b/assets/jsx/backup-panel/components/backup-panel.jsx @@ -0,0 +1,36 @@ +import { __ } from '@wordpress/i18n'; +import { useState } from '@wordpress/element'; + +import ImportTab from './tabs-content/import'; +import ExportTab from './tabs-content/export'; +import TabbedWindow from './tabbed-window'; + +const BackupPanel = () => { + const [activeTab, setActiveTab] = useState(); + + const tabs = [ + { + label: __('Export', 'post-expirator'), + value: 'export', + }, + { + label: __('Import', 'post-expirator'), + value: 'import', + }, + ]; + + return ( + <> + + {activeTab === 'import' && } + {activeTab === 'export' && } + + + ); +}; + +export default BackupPanel; diff --git a/assets/jsx/backup-panel/components/fieldset/index.jsx b/assets/jsx/backup-panel/components/fieldset/index.jsx new file mode 100644 index 000000000..aadf99d61 --- /dev/null +++ b/assets/jsx/backup-panel/components/fieldset/index.jsx @@ -0,0 +1,5 @@ +const Fieldset = ({ children }) => { + return
{children}
; +}; + +export default Fieldset; diff --git a/assets/jsx/backup-panel/components/selectable-list/index.jsx b/assets/jsx/backup-panel/components/selectable-list/index.jsx new file mode 100644 index 000000000..4208608d6 --- /dev/null +++ b/assets/jsx/backup-panel/components/selectable-list/index.jsx @@ -0,0 +1,51 @@ +import { __ } from '@wordpress/i18n'; +import { Button, CheckboxControl } from '@wordpress/components'; + +export const SelectableList = ({ items, selectedItems, onSelect }) => { + const handleSelectAll = () => { + onSelect(items.map((item) => item.id)); + }; + + const handleUnselectAll = () => { + onSelect([]); + }; + + return ( + <> +
+ + | + + +
+ +
    + {items.map((item) => ( +
  • + + {item.title} + + {item.status && ( + [{item.status}] + )} + + )} + checked={selectedItems.includes(item.id)} + onChange={(value) => { + if (value) { + onSelect([...selectedItems, item.id]); + } else { + onSelect(selectedItems.filter((id) => id !== item.id)); + } + }} + /> +
  • + ))} +
+ + ); +}; + +export default SelectableList; diff --git a/assets/jsx/backup-panel/components/settings-tab/index.jsx b/assets/jsx/backup-panel/components/settings-tab/index.jsx new file mode 100644 index 000000000..77f79e0c8 --- /dev/null +++ b/assets/jsx/backup-panel/components/settings-tab/index.jsx @@ -0,0 +1,17 @@ +export const SettingsTab = ({ + title, + description, + children, +}) => { + return ( +
+

{title}

+ +

{description}

+ + {children} +
+ ); +}; + +export default SettingsTab; diff --git a/assets/jsx/backup-panel/components/tabbed-window/index.jsx b/assets/jsx/backup-panel/components/tabbed-window/index.jsx new file mode 100644 index 000000000..22dc650cf --- /dev/null +++ b/assets/jsx/backup-panel/components/tabbed-window/index.jsx @@ -0,0 +1,97 @@ +import { __ } from '@wordpress/i18n'; +import { useState, useEffect } from '@wordpress/element'; +import { SnackbarList } from '@wordpress/components'; +import { useSelect, useDispatch } from '@wordpress/data'; + +const TabbedWindow = ({ + defaultTab = '', + tabs = [ + { + label: 'Tab 1', + value: 'tab1', + }, + { + label: 'Tab 2', + value: 'tab2', + }, + ], + onChange = () => {}, + children, + noticeAutoDismissTimeout = 5000, +}) => { + const getCurrentTabFromUrl = () => { + const hash = window.location.hash.replace('#', ''); + const theTab = tabs.find((tab) => tab.value === hash) || defaultTab; + + if (typeof theTab === 'object') { + return theTab.value; + } + + return theTab; + }; + + const [activeTab, setActiveTab] = useState(getCurrentTabFromUrl()); + + const notices = useSelect(select => select('core/notices').getNotices()); + + const { removeNotice } = useDispatch('core/notices'); + + // Listen for hash changes + useEffect(() => { + const handleHashChange = () => { + const newTab = getCurrentTabFromUrl(); + setActiveTab(newTab); + }; + + window.addEventListener('hashchange', handleHashChange); + return () => window.removeEventListener('hashchange', handleHashChange); + }, []); + + //Autodismiss notices + useEffect(() => { + notices.forEach((notice) => { + setTimeout(() => { + removeNotice(notice.id); + }, noticeAutoDismissTimeout); + }); + }, [notices]); + + useEffect(() => { + window.history.replaceState(null, '', `#${activeTab}`); + + onChange(activeTab); + }, [activeTab]); + + return ( + <> + + { + removeNotice(noticeId); + }} + /> + + ); +}; + +export default TabbedWindow; diff --git a/assets/jsx/backup-panel/components/tabs-content/export.jsx b/assets/jsx/backup-panel/components/tabs-content/export.jsx new file mode 100644 index 000000000..22557a010 --- /dev/null +++ b/assets/jsx/backup-panel/components/tabs-content/export.jsx @@ -0,0 +1,214 @@ +import { addQueryArgs } from '@wordpress/url'; +import { __ } from '@wordpress/i18n'; +import { CheckboxControl, Button, ToggleControl, Dashicon } from '@wordpress/components'; +import { useState, useRef, useEffect } from '@wordpress/element'; +import { useDispatch } from '@wordpress/data'; +const { apiFetch } = wp; +import { SelectableList } from '../selectable-list'; +import { SettingsTab } from '../settings-tab'; + +const ExportTab = () => { + const [exportActionWorkflows, setExportActionWorkflows] = useState(true); + const [exportActionSettings, setExportActionSettings] = useState(true); + const [includeScreenshots, setIncludeScreenshots] = useState(false); + const [isExporting, setIsExporting] = useState(false); + const [workflows, setWorkflows] = useState([]); + const [selectedWorkflows, setSelectedWorkflows] = useState([]); + const [selectedSettings, setSelectedSettings] = useState(['postTypesDefaults', 'general', 'notifications', 'display', 'advanced']); + + const apiRequestControllerRef = useRef(new AbortController()); + + const { enableWorkflowScreenshot } = futureBackupPanelData; + + const settingsOptions = [ + { + title: __('Post Types', 'post-expirator'), + id: 'postTypesDefaults', + }, + { + title: __('General', 'post-expirator'), + id: 'general', + }, + { + title: __('Notifications', 'post-expirator'), + id: 'notifications', + }, + { + title: __('Display', 'post-expirator'), + id: 'display', + }, + { + title: __('Advanced', 'post-expirator'), + id: 'advanced', + }, + ]; + + const { createSuccessNotice, createErrorNotice } = useDispatch('core/notices'); + + useEffect(() => { + apiFetch({ + path: addQueryArgs(`publishpress-future/v1/backup/workflows`), + }).then((result) => { + setWorkflows(result.workflows); + setSelectedWorkflows(result.workflows.map((workflow) => workflow.id)); + }); + }, []); + + const handleJsonDataDownload = (resultData) => { + // Create a blob with the JSON data + const jsonData = JSON.stringify(resultData, null, 2); + const blob = new Blob([jsonData], { type: 'application/json' }); + + // Create download link and trigger click + const downloadUrl = URL.createObjectURL(blob); + const date = new Date().toISOString().replace(':', '-').split('.')[0]; + const link = document.createElement('a'); + link.href = downloadUrl; + link.download = `publishpress-future-backup-${date}.json`; + document.body.appendChild(link); + link.click(); + document.body.removeChild(link); + + // Clean up the URL object + URL.revokeObjectURL(downloadUrl); + }; + + const handleExport = async () => { + setIsExporting(true); + + const controller = apiRequestControllerRef.current; + + if (controller) { + controller.abort(); + } + + apiRequestControllerRef.current = new AbortController(); + const { signal } = apiRequestControllerRef.current; + + apiFetch({ + path: addQueryArgs(`publishpress-future/v1/backup/export`), + method: 'POST', + data: { + exportActionWorkflows: exportActionWorkflows, + exportActionSettings: exportActionSettings, + workflows: selectedWorkflows, + includeScreenshots: includeScreenshots, + settings: selectedSettings, + }, + signal, + }).then((result) => { + setIsExporting(false); + handleJsonDataDownload(result.data); + + createSuccessNotice( + __('Settings exported successfully.', 'post-expirator'), + { + type: 'snackbar', + isDismissible: true, + actions: [ + { + label: __('Download', 'post-expirator'), + onClick: () => { + handleJsonDataDownload(result.data); + }, + }, + ], + icon: , + autoDismiss: true, + explicitDismiss: true, + } + ); + }).catch((error) => { + if (error.name === 'AbortError') { + return; + } + + createErrorNotice( + error.message || __('Failed to export settings.', 'post-expirator'), + { + type: 'snackbar', + isDismissible: true, + actions: [], + icon: , + autoDismiss: true, + explicitDismiss: true, + } + ); + + setIsExporting(false); + }); + }; + + const handleExportCancel = () => { + const controller = apiRequestControllerRef.current; + + if (controller) { + controller.abort(); + } + }; + + const handleSelectAllSettings = () => { + setSelectedSettings(settingsOptions.map((option) => option.value)); + }; + + const handleUnselectAllSettings = () => { + setSelectedSettings([]); + }; + + return ( + +
    +
  • + 0} + onChange={(value) => setExportActionWorkflows(value)} + disabled={workflows.length === 0} + /> + + {exportActionWorkflows && workflows.length > 0 && ( +
    + {enableWorkflowScreenshot && ( +
    + setIncludeScreenshots(value)} + /> +
    + )} + + +
    + )} +
  • +
  • + setExportActionSettings(value)} + /> + + {exportActionSettings && ( +
    + +
    + )} +
  • +
+ + {(exportActionWorkflows || exportActionSettings) && ( + + )} + + {isExporting && } +
+ ); +}; + +export default ExportTab; diff --git a/assets/jsx/backup-panel/components/tabs-content/import.jsx b/assets/jsx/backup-panel/components/tabs-content/import.jsx new file mode 100644 index 000000000..9cc00d913 --- /dev/null +++ b/assets/jsx/backup-panel/components/tabs-content/import.jsx @@ -0,0 +1,159 @@ +import { __ } from '@wordpress/i18n'; +import { Button, FormFileUpload, Dashicon } from '@wordpress/components'; +import { useState } from '@wordpress/element'; +import { useDispatch } from '@wordpress/data'; +import { SettingsTab } from '../settings-tab'; + +const formatFileSize = (bytes) => { + if (bytes === 0) return '0 Bytes'; + + const k = 1024; + const sizes = ['Bytes', 'KB', 'MB', 'GB']; + const i = Math.floor(Math.log(bytes) / Math.log(k)); + + return `${parseFloat((bytes / Math.pow(k, i)).toFixed(2))} ${sizes[i]}`; +}; + +const ImportTab = () => { + const [isImporting, setIsImporting] = useState(false); + const [file, setFile] = useState(null); + const [validFile, setValidFile] = useState(false); + const [validationError, setValidationError] = useState(null); + const [isDragging, setIsDragging] = useState(false); + + const { createSuccessNotice, createErrorNotice } = useDispatch('core/notices'); + + const handleImport = () => { + setIsImporting(true); + + // Create FormData object + const formData = new FormData(); + formData.append('backupFile', file); + + const wpNonce = wp.apiFetch.nonceMiddleware ? wp.apiFetch.nonceMiddleware.nonce : ''; + + fetch(`${futureBackupPanelData.apiRoot}publishpress-future/v1/backup/import`, { + method: 'POST', + headers: { + 'X-WP-Nonce': wpNonce + }, + body: formData, + credentials: 'same-origin' + }) + .then(response => response.json()) + .then(response => { + if (response.ok) { + setIsImporting(false); + createSuccessNotice( + response.message || __('Settings imported successfully.', 'post-expirator'), + { + type: 'snackbar', + isDismissible: true, + actions: [], + autoDismiss: true, + explicitDismiss: true, + icon: , + } + ); + } else { + throw new Error(response.message); + } + }) + .catch(error => { + setIsImporting(false); + createErrorNotice( + error || __('Failed to import settings.', 'post-expirator'), + { + type: 'snackbar', + isDismissible: true, + actions: [], + autoDismiss: true, + explicitDismiss: true, + icon: , + } + ); + }); + }; + + const validateFile = (fileToValidate) => { + const fileExtension = fileToValidate.name.split('.').pop(); + + if (fileExtension !== 'json') { + setValidFile(false); + setValidationError(__('Invalid file type. Please upload a .json file.', 'post-expirator')); + + return; + } + + setValidFile(true); + setValidationError(null); + }; + + return ( + +
+
{ + e.preventDefault(); + const droppedFile = e.dataTransfer.files[0]; + setFile(droppedFile); + validateFile(droppedFile); + }} + onDragOver={(e) => { + e.preventDefault(); + }} + onDragEnter={(e) => { + e.preventDefault(); + setIsDragging(true); + }} + onDragLeave={(e) => { + e.preventDefault(); + if (e.currentTarget === e.target) { + setIsDragging(false); + } + }} + > +

{__('Drop your .json file here', 'post-expirator')}

+

{__('or', 'post-expirator')}

+ + { + setFile( event.currentTarget.files[0] ); + validateFile( event.currentTarget.files[0] ); + } } + className="is-primary" + > + {__('Select a .json file', 'post-expirator')} + + + {file && ( +
+

{__('Selected file', 'post-expirator')}: {file.name}

+

{__('File size', 'post-expirator')}: {formatFileSize(file.size)}

+
+ )} +
+
+ + + {validFile && ( + + )} + + {validationError && ( +

{validationError}

+ )} +
+ ); +}; + +export default ImportTab; diff --git a/assets/jsx/backup-panel/css/general.css b/assets/jsx/backup-panel/css/general.css new file mode 100644 index 000000000..6f61d8d4f --- /dev/null +++ b/assets/jsx/backup-panel/css/general.css @@ -0,0 +1,70 @@ +ul#export-actions { + margin-bottom: 20px; +} + +ul#export-actions li ul { + margin-top: 10px; + border: 1px solid #e0e0e0e5; + padding: 10px; + background-color: #fff; +} + +ul#export-actions span { + display: inline-block; +} + +.pe-settings-tab__backup-status { + margin-left: 5px; +} + +.pe-settings-tab__backup-actions button { + margin-left: 5px !important; +} + +.pe-settings-tab__backup-container { + margin-left: 30px; +} + +.pe-settings-tab__export-cancel-button { + margin-left: 10px !important; +} + +.components-snackbar-list { + position: fixed !important; + bottom: 20px; + left: 182px; + transform: none; + z-index: 100000; +} + +.components-snackbar { + margin-bottom: 10px; +} + +.wp-admin.folded .components-snackbar-list { + left: 58px; +} + +.pe-settings-tab__import-file-upload { + margin-bottom: 20px; +} + +.pe-settings-tab__import-file-upload-info { + margin-top: 10px; + font-size: 14px; +} + +.pe-dropzone { + border: 3px dashed #ccc; + padding: 20px; + text-align: center; +} + +.pe-dropzone--active { + border-color: #0073aa; +} + +.pe-dropzone p { + margin: 0; +} + diff --git a/assets/jsx/backup-panel/index.jsx b/assets/jsx/backup-panel/index.jsx new file mode 100644 index 000000000..1bc730401 --- /dev/null +++ b/assets/jsx/backup-panel/index.jsx @@ -0,0 +1,13 @@ +import { createRoot } from 'react-dom/client'; + +import BackupPanel from './components/backup-panel'; + +import './css/general.css'; + +const container = document.getElementById("backup-panel"); + +if (container) { + const component = (); + + createRoot(container).render(component); +} diff --git a/assets/jsx/components/FutureActionPanel.jsx b/assets/jsx/components/FutureActionPanel.jsx index 16c7fde6d..8228b4b22 100644 --- a/assets/jsx/components/FutureActionPanel.jsx +++ b/assets/jsx/components/FutureActionPanel.jsx @@ -357,7 +357,7 @@ export const FutureActionPanel = (props) => { )} {props.showTitle && ( -
{props.strings.futureActions}
+
{props.strings.panelTitle}
)} diff --git a/assets/jsx/future-actions.jsx b/assets/jsx/future-actions.jsx index e920d52f9..78c389863 100644 --- a/assets/jsx/future-actions.jsx +++ b/assets/jsx/future-actions.jsx @@ -15,8 +15,10 @@ jQuery(document).ready(function ($) { $("a.publishpres-future-view-log").on('click', function (e) { e.preventDefault(); + const id = $(this).data('id'); + const logElement = $.find(`.publishpress-future-log-${id}`); - $(".publishpress-future-log-" + id).dialog("open"); + $(logElement).dialog("open"); }); }); diff --git a/assets/jsx/workflow-editor/components/data-fields/date-offset.jsx b/assets/jsx/workflow-editor/components/data-fields/date-offset.jsx index faf5478d1..9c93b1fd7 100644 --- a/assets/jsx/workflow-editor/components/data-fields/date-offset.jsx +++ b/assets/jsx/workflow-editor/components/data-fields/date-offset.jsx @@ -230,7 +230,7 @@ export function DateOffset({ name, label, defaultValue, onChange, variables = [] label={__("Unique ID Expression", "post-expirator")} value={defaultValue.uniqueIdExpression ?? ''} onChange={(value) => onChangeSetting({ settingName: "uniqueIdExpression", value })} - help={__("Define a custom expression for a unique task ID. Use placeholders like {{onSavePost1.post.ID}} or {{global.user.ID}} to make sure the ID is unique.", "post-expirator")} + help={__("Define a custom expression for a unique task ID. Use placeholders like {{onSavePost1.post.ID}}, {{global.user.ID}} or {{global.execution_id}} to make sure the ID is unique.", "post-expirator")} /> )} diff --git a/assets/jsx/workflow-editor/components/data-fields/debug-data.jsx b/assets/jsx/workflow-editor/components/data-fields/debug-data.jsx index 58f0d7a67..a0c1afef6 100644 --- a/assets/jsx/workflow-editor/components/data-fields/debug-data.jsx +++ b/assets/jsx/workflow-editor/components/data-fields/debug-data.jsx @@ -1,5 +1,5 @@ import { __ } from "@wordpress/i18n"; -import { TreeSelect } from "@wordpress/components"; +import { TreeSelect, TextareaControl } from "@wordpress/components"; import { __experimentalVStack as VStack } from "@wordpress/components"; export function DebugData({ name, label, defaultValue, onChange, variables = [] }) { @@ -17,6 +17,12 @@ export function DebugData({ name, label, defaultValue, onChange, variables = [] }); } + // Add a new option to output custom data + debugOptions.push({ + name: __("Custom data", "post-expirator"), + id: "custom-data", + }); + const defaultDebugOption = "all-input"; const onChangeSetting = ({ settingName, value }) => { @@ -37,6 +43,14 @@ export function DebugData({ name, label, defaultValue, onChange, variables = [] selectedId={defaultValue?.dataToOutput || defaultDebugOption} onChange={(value) => onChangeSetting({ settingName: "dataToOutput", value })} /> + + {defaultValue?.dataToOutput === "custom-data" && ( + onChangeSetting({ settingName: "customData", value })} + /> + )} ); diff --git a/assets/jsx/workflow-editor/components/data-fields/email-recipient.jsx b/assets/jsx/workflow-editor/components/data-fields/email-recipient.jsx index 444a866b6..0bcdcbce9 100644 --- a/assets/jsx/workflow-editor/components/data-fields/email-recipient.jsx +++ b/assets/jsx/workflow-editor/components/data-fields/email-recipient.jsx @@ -1,6 +1,6 @@ import { __ } from "@wordpress/i18n"; import { VariablesTreeSelect } from "../variables-tree-select"; -import { TextControl } from "@wordpress/components"; +import { TextareaControl } from "@wordpress/components"; import { __experimentalVStack as VStack } from "@wordpress/components"; import { filterVariableOptionsByDataType } from "../../utils"; @@ -9,9 +9,8 @@ export function EmailRecipient({ name, label, defaultValue, onChange, settings, variables = filterVariableOptionsByDataType(variables, ['email']); let recipientOptions = [ - { name: '', id: '' }, - { name: __("Custom Addresses", "post-expirator"), id: "custom" }, - ...variables + ...variables, + { name: __("Custom Addresses", "post-expirator"), id: "custom" } ]; const onChangeSetting = ({ settingName, value }) => { @@ -38,7 +37,7 @@ export function EmailRecipient({ name, label, defaultValue, onChange, settings, /> {defaultValue?.recipient === "custom" && ( - onChangeSetting({ settingName: "custom", value })} diff --git a/assets/jsx/workflow-editor/components/data-fields/post-query.jsx b/assets/jsx/workflow-editor/components/data-fields/post-query.jsx index cdae1897e..a0c2c0f54 100644 --- a/assets/jsx/workflow-editor/components/data-fields/post-query.jsx +++ b/assets/jsx/workflow-editor/components/data-fields/post-query.jsx @@ -5,7 +5,13 @@ import { InlineMultiSelect } from "../inline-multi-select"; import { __experimentalVStack as VStack } from "@wordpress/components"; -export function PostQuery({ name, label, defaultValue, onChange, settings }) { +export function PostQuery({ + name, + label, + defaultValue, + onChange, + settings +}) { const postTypes = futureWorkflowEditor.postTypes; const postStatuses = futureWorkflowEditor.postStatuses; @@ -19,6 +25,7 @@ export function PostQuery({ name, label, defaultValue, onChange, settings }) { } const acceptsInput = settings && settings?.acceptsInput === true; + const isPostTypeRequired = settings && settings?.isPostTypeRequired === true; const defaultPostSource =acceptsInput ? 'input' : 'custom'; const showCustomQueryFields = defaultValue?.postSource === 'custom' || ! acceptsInput; @@ -36,6 +43,8 @@ export function PostQuery({ name, label, defaultValue, onChange, settings }) { } }, []); + const postTypeFieldLabel = isPostTypeRequired ? __('Post Type', 'post-expirator') + ' *' : __('Post Type', 'post-expirator'); + return ( <> @@ -56,7 +65,7 @@ export function PostQuery({ name, label, defaultValue, onChange, settings }) { {showCustomQueryFields && ( <> onChangeSetting({ settingName: "postId", value })} /> @@ -80,6 +89,10 @@ export function PostQuery({ name, label, defaultValue, onChange, settings }) { /> )} + + {isPostTypeRequired && ( +

{__('* Required field', 'post-expirator')}

+ )}
); diff --git a/assets/jsx/workflow-editor/components/data-types/post.jsx b/assets/jsx/workflow-editor/components/data-types/post.jsx index b87088d89..0a987bbc8 100644 --- a/assets/jsx/workflow-editor/components/data-types/post.jsx +++ b/assets/jsx/workflow-editor/components/data-types/post.jsx @@ -54,7 +54,12 @@ export function PostData() { name: "permalink", type: "string", label: "Permalink", - } + }, + { + name: "meta", + type: "object", + label: "Metadata", + }, ], }; } diff --git a/assets/jsx/workflow-editor/components/data-types/site.jsx b/assets/jsx/workflow-editor/components/data-types/site.jsx index 32813f355..7ebcd38ff 100644 --- a/assets/jsx/workflow-editor/components/data-types/site.jsx +++ b/assets/jsx/workflow-editor/components/data-types/site.jsx @@ -5,6 +5,11 @@ export function SiteData() { type: "object", objectType: "site", propertiesSchema: [ + { + name: "id", + type: "integer", + label: "ID", + }, { name: "name", type: "string", @@ -30,6 +35,11 @@ export function SiteData() { type: "email", label: "Admin Email", }, + { + name: "meta", + type: "object", + label: "Metadata", + }, ], }; } diff --git a/assets/jsx/workflow-editor/components/data-types/user.jsx b/assets/jsx/workflow-editor/components/data-types/user.jsx index 9db9d58cf..0e4674bbd 100644 --- a/assets/jsx/workflow-editor/components/data-types/user.jsx +++ b/assets/jsx/workflow-editor/components/data-types/user.jsx @@ -39,7 +39,12 @@ export function UserData() { name: "user_registered", type: "datetime", label: "Registration Date", - } + }, + { + name: "meta", + type: "object", + label: "Metadata", + }, ], }; } diff --git a/assets/jsx/workflow-editor/components/data-types/workflow.jsx b/assets/jsx/workflow-editor/components/data-types/workflow.jsx index 7bd2907c1..704940bd9 100644 --- a/assets/jsx/workflow-editor/components/data-types/workflow.jsx +++ b/assets/jsx/workflow-editor/components/data-types/workflow.jsx @@ -29,7 +29,12 @@ export function WorkflowData() { name: "steps", type: "node", label: "Steps", - } + }, + { + name: "meta", + type: "object", + label: "Metadata", + }, ], }; } diff --git a/assets/jsx/workflow-editor/components/layout/header.jsx b/assets/jsx/workflow-editor/components/layout/header.jsx index 83041f3f7..8149ae983 100644 --- a/assets/jsx/workflow-editor/components/layout/header.jsx +++ b/assets/jsx/workflow-editor/components/layout/header.jsx @@ -41,8 +41,6 @@ export const LayoutHeader = () => { hasReducedUI, showIconLabels, isLoadingWorkflow, - isEditedWorkflowDirty, - takeScreenshot, isPro } = useSelect((select) => { return { @@ -51,8 +49,6 @@ export const LayoutHeader = () => { isInserterOpened: select(editorStore).isFeatureActive(FEATURE_INSERTER), showIconLabels: select(editorStore).isFeatureActive(FEATURE_SHOW_ICON_LABELS), isLoadingWorkflow: select(workflowStore).isLoadingWorkflow(), - isEditedWorkflowDirty: select(workflowStore).isEditedWorkflowDirty(), - takeScreenshot: select(workflowStore).takeScreenshot, isPro: select(editorStore).isPro(), } }); diff --git a/assets/jsx/workflow-editor/components/workflow-publish-button/index.jsx b/assets/jsx/workflow-editor/components/workflow-publish-button/index.jsx index 1c5d04b80..21adfc18a 100644 --- a/assets/jsx/workflow-editor/components/workflow-publish-button/index.jsx +++ b/assets/jsx/workflow-editor/components/workflow-publish-button/index.jsx @@ -65,6 +65,8 @@ export function WorkflowPublishButton({ const wasSaving = usePrevious(isSaving); + const { enableWorkflowScreenshot } = futureWorkflowEditor; + useEffect(() => { let timeoutId; @@ -104,13 +106,21 @@ export function WorkflowPublishButton({ return; } - takeScreenshot().then((dataUrl) => { + if (enableWorkflowScreenshot) { + takeScreenshot().then((dataUrl) => { + if (isPublished) { + saveAsCurrentStatus({screenshot: dataUrl}); + } else { + publishWorkflow({screenshot: dataUrl}); + } + }); + } else { if (isPublished) { - saveAsCurrentStatus({screenshot: dataUrl}); + saveAsCurrentStatus(); } else { - publishWorkflow({screenshot: dataUrl}); + publishWorkflow(); } - }); + } } // Use common Button instance for all saved states so that focus is not diff --git a/assets/jsx/workflow-editor/components/workflow-save-draft-button/index.jsx b/assets/jsx/workflow-editor/components/workflow-save-draft-button/index.jsx index fc93e8849..de3659402 100644 --- a/assets/jsx/workflow-editor/components/workflow-save-draft-button/index.jsx +++ b/assets/jsx/workflow-editor/components/workflow-save-draft-button/index.jsx @@ -64,6 +64,8 @@ export function WorkflowSaveDraftButton({ const wasSaving = usePrevious(isSaving); + const { enableWorkflowScreenshot } = futureWorkflowEditor; + useEffect(() => { let timeoutId; @@ -104,12 +106,15 @@ export function WorkflowSaveDraftButton({ } const onClick = () => { - takeScreenshot().then((screenshot) => { - saveAsDraft({ screenshot }); - }); + if (enableWorkflowScreenshot) { + takeScreenshot().then((screenshot) => { + saveAsDraft({ screenshot }); + }); + } else { + saveAsDraft(); + } }; - // Use common Button instance for all saved states so that focus is not // lost. return ( diff --git a/assets/jsx/workflow-editor/components/workflow-store/actions.jsx b/assets/jsx/workflow-editor/components/workflow-store/actions.jsx index 62c9b658d..6a8cf4463 100644 --- a/assets/jsx/workflow-editor/components/workflow-store/actions.jsx +++ b/assets/jsx/workflow-editor/components/workflow-store/actions.jsx @@ -53,7 +53,7 @@ export function* setupEditor(workflowId) { } }; -export function* saveAsDraft({ screenshot }) { +export function* saveAsDraft({ screenshot } = {}) { yield {type: 'SAVE_AS_DRAFT_START'}; try { @@ -99,7 +99,7 @@ export function* saveAsDraft({ screenshot }) { } } -export function* saveAsCurrentStatus({ screenshot }) { +export function* saveAsCurrentStatus({ screenshot } = {}) { yield {type: 'SAVE_AS_CURRENT_STATUS_START'}; try { @@ -136,7 +136,7 @@ export function* saveAsCurrentStatus({ screenshot }) { } } -export function* publishWorkflow({ screenshot }) { +export function* publishWorkflow({ screenshot } = {}) { yield {type: 'PUBLISH_WORKFLOW_START'}; try { @@ -145,6 +145,7 @@ export function* publishWorkflow({ screenshot }) { yield dispatch(STORE_NAME).setEditedWorkflowAttribute('status', 'publish'); const editedWorkflow = yield select(STORE_NAME).getEditedWorkflow(); + if (screenshot) { editedWorkflow.screenshot = screenshot; } @@ -181,7 +182,7 @@ export function* publishWorkflow({ screenshot }) { } } -export function* switchToDraft({ screenshot }) { +export function* switchToDraft({ screenshot } = {}) { yield {type: 'SWITCH_TO_DRAFT_START'}; try { @@ -190,6 +191,7 @@ export function* switchToDraft({ screenshot }) { yield dispatch(STORE_NAME).setEditedWorkflowAttribute('status', 'draft'); const editedWorkflow = yield select(STORE_NAME).getEditedWorkflow(); + if (screenshot) { editedWorkflow.screenshot = screenshot; } diff --git a/assets/jsx/workflow-editor/components/workflow-store/reducer.jsx b/assets/jsx/workflow-editor/components/workflow-store/reducer.jsx index a34cea8aa..67afc21ac 100644 --- a/assets/jsx/workflow-editor/components/workflow-store/reducer.jsx +++ b/assets/jsx/workflow-editor/components/workflow-store/reducer.jsx @@ -132,6 +132,15 @@ function _setInitialStateForGlobalVariables(state, workflow = {}) { } }); + state = setGlobalVariable(state, { + payload: { + name: 'execution_id', + label: 'Execution ID', + type: 'string', + runtimeOnly: true, + } + }); + return state; } diff --git a/assets/jsx/workflow-editor/components/workflow-store/selectors.jsx b/assets/jsx/workflow-editor/components/workflow-store/selectors.jsx index 8a49748e4..81a591f0e 100644 --- a/assets/jsx/workflow-editor/components/workflow-store/selectors.jsx +++ b/assets/jsx/workflow-editor/components/workflow-store/selectors.jsx @@ -1,6 +1,3 @@ -// import { createRegistrySelector } from '@wordpress/data'; -import { toPng } from 'html-to-image'; - export const getPostType = (state) => { return state.postType; }; @@ -145,33 +142,31 @@ export const getDataTypeByName = (state, name) => { return state.dataTypes.find(dataType => dataType.name === name); } -export function takeScreenshot() { - return new Promise((resolve, reject) => { - try { - toPng(document.querySelector('.react-flow'), { - filter: (node) => { - // We don't want to add the minimap and the controls to the image - if ( - node?.classList?.contains('react-flow__minimap') || - node?.classList?.contains('react-flow__controls') || - node?.classList?.contains('pwe-node-edit-button') - ) { - return false; - } - - return true; - }, - }) - .then((dataUrl) => { - resolve(dataUrl); // Resolve with the image dataUrl - }) - .catch((error) => { - reject(error); // Reject with the error - }); - } catch (error) { - reject(error); // Reject with the error - } - }); +export async function takeScreenshot() { + const { enableWorkflowScreenshot } = futureWorkflowEditor; + + if (!enableWorkflowScreenshot) { + return null; + } + + try { + const { toPng } = await import('html-to-image'); + return await toPng(document.querySelector('.react-flow'), { + filter: (node) => { + if ( + node?.classList?.contains('react-flow__minimap') || + node?.classList?.contains('react-flow__controls') || + node?.classList?.contains('pwe-node-edit-button') + ) { + return false; + } + return true; + }, + }); + } catch (error) { + console.error('Error loading html-to-image:', error); + return null; + } } export function getGlobalVariables(state) { diff --git a/assets/jsx/workflow-editor/components/workflow-switch-to-draft-button/index.jsx b/assets/jsx/workflow-editor/components/workflow-switch-to-draft-button/index.jsx index ded5bb4a6..0ef2e12bd 100644 --- a/assets/jsx/workflow-editor/components/workflow-switch-to-draft-button/index.jsx +++ b/assets/jsx/workflow-editor/components/workflow-switch-to-draft-button/index.jsx @@ -28,6 +28,8 @@ export function WorkflowSwitchToDraftButton() { return null; } + const { enableWorkflowScreenshot } = futureWorkflowEditor; + const onSwitch = () => { let alertMessage; @@ -40,9 +42,13 @@ export function WorkflowSwitchToDraftButton() { } if (window.confirm(alertMessage)) { - takeScreenshot().then((dataUrl) => { - switchToDraft({ screenshot: dataUrl }); - }); + if (enableWorkflowScreenshot) { + takeScreenshot().then((dataUrl) => { + switchToDraft({ screenshot: dataUrl }); + }); + } else { + switchToDraft(); + } } }; diff --git a/assets/jsx/workflow-manual-selection/block-editor/css/style.css b/assets/jsx/workflow-manual-selection/block-editor/css/style.css new file mode 100644 index 000000000..5eca91b96 --- /dev/null +++ b/assets/jsx/workflow-manual-selection/block-editor/css/style.css @@ -0,0 +1,3 @@ +#publishpress-future-block-editor .components-checkbox-control__label { + max-width: 100%; +} diff --git a/assets/jsx/workflow-manual-selection/block-editor/index.jsx b/assets/jsx/workflow-manual-selection/block-editor/index.jsx index 8a0f8fcf8..be8fab366 100644 --- a/assets/jsx/workflow-manual-selection/block-editor/index.jsx +++ b/assets/jsx/workflow-manual-selection/block-editor/index.jsx @@ -6,6 +6,8 @@ import { __ } from '@wordpress/i18n'; import { registerPlugin } from '@wordpress/plugins'; import { useEffect } from 'react'; +import './css/style.css'; + function BlockEditorWorkflowManualTrigger() { const { PluginDocumentSettingPanel } = wp.editPost; diff --git a/assets/jsx/workflow-manual-selection/classic-editor/css/style.css b/assets/jsx/workflow-manual-selection/classic-editor/css/style.css new file mode 100644 index 000000000..9553fc234 --- /dev/null +++ b/assets/jsx/workflow-manual-selection/classic-editor/css/style.css @@ -0,0 +1,3 @@ +#publishpress-future-classic-editor .components-checkbox-control__label { + max-width: 100%; +} diff --git a/assets/jsx/workflow-manual-selection/classic-editor/index.jsx b/assets/jsx/workflow-manual-selection/classic-editor/index.jsx index 013a7732c..c0bf8b6fa 100644 --- a/assets/jsx/workflow-manual-selection/classic-editor/index.jsx +++ b/assets/jsx/workflow-manual-selection/classic-editor/index.jsx @@ -4,6 +4,7 @@ import { store } from '../store'; import { Fieldset } from '../fieldset'; import apiFetch from '@wordpress/api-fetch'; +import './css/style.css'; const container = document.getElementById("post-expirator-classic-editor"); diff --git a/assets/jsx/workflow-manual-selection/quick-edit/css/style.css b/assets/jsx/workflow-manual-selection/quick-edit/css/style.css index 8bcc2d440..bc5ee5f1f 100644 --- a/assets/jsx/workflow-manual-selection/quick-edit/css/style.css +++ b/assets/jsx/workflow-manual-selection/quick-edit/css/style.css @@ -9,4 +9,9 @@ #publishpress-future-quick-edit label { display: inline-block; max-width: 100%; + line-height: 12px; +} + +#post-expirator-quick-edit-wrapper .components-checkbox-control__label { + line-height: 12px; } diff --git a/composer.json b/composer.json index eeb2c3561..5995d7617 100644 --- a/composer.json +++ b/composer.json @@ -110,7 +110,6 @@ ], "check:php": [ "@check:php-5.6", - "@check:php-7.2", "@check:php-7.4", "@check:php-8.0", "@check:php-8.1", @@ -118,7 +117,6 @@ "@check:php-8.3" ], "check:php-5.6": "phpcs --standard=.phpcs-php-compatibility.xml --runtime-set testVersion 5.6 ./post-expirator.php", - "check:php-7.2": "phpcs --standard=.phpcs-php-compatibility.xml --runtime-set testVersion 7.2", "check:php-7.4": "phpcs --standard=.phpcs-php-compatibility.xml --runtime-set testVersion 7.4", "check:php-8.0": "phpcs --standard=.phpcs-php-compatibility.xml --runtime-set testVersion 8.0", "check:php-8.1": "phpcs --standard=.phpcs-php-compatibility.xml --runtime-set testVersion 8.1", @@ -203,7 +201,6 @@ "check": "Runs all the checks.", "check:php": "Checks the PHP compatibility for all versions.", "check:php-5.6": "Checks the PHP compatibility for PHP 5.6 in the main file only.", - "check:php-7.2": "Checks the PHP compatibility for PHP 7.2.", "check:php-7.4": "Checks the PHP compatibility for PHP 7.4.", "check:php-8.0": "Checks the PHP compatibility for PHP 8.0.", "check:php-8.1": "Checks the PHP compatibility for PHP 8.1.", diff --git a/composer.lock b/composer.lock index d1f08f4ad..dbb0674d4 100644 --- a/composer.lock +++ b/composer.lock @@ -151,25 +151,25 @@ }, { "name": "behat/gherkin", - "version": "v4.10.0", + "version": "v4.11.0", "source": { "type": "git", "url": "https://github.com/Behat/Gherkin.git", - "reference": "cbb83c4c435dd8d05a161f2a5ae322e61b2f4db6" + "reference": "32821a17b12620951e755b5d49328a6421a5b5b5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Behat/Gherkin/zipball/cbb83c4c435dd8d05a161f2a5ae322e61b2f4db6", - "reference": "cbb83c4c435dd8d05a161f2a5ae322e61b2f4db6", + "url": "https://api.github.com/repos/Behat/Gherkin/zipball/32821a17b12620951e755b5d49328a6421a5b5b5", + "reference": "32821a17b12620951e755b5d49328a6421a5b5b5", "shasum": "" }, "require": { - "php": "~7.2|~8.0" + "php": "8.1.* || 8.2.* || 8.3.* || 8.4.*" }, "require-dev": { "cucumber/cucumber": "dev-gherkin-24.1.0", - "phpunit/phpunit": "~8|~9", - "symfony/yaml": "~3|~4|~5|~6|~7" + "phpunit/phpunit": "^9.6", + "symfony/yaml": "^5.4 || ^6.4 || ^7.0" }, "suggest": { "symfony/yaml": "If you want to parse features, represented in YAML files" @@ -208,9 +208,9 @@ ], "support": { "issues": "https://github.com/Behat/Gherkin/issues", - "source": "https://github.com/Behat/Gherkin/tree/v4.10.0" + "source": "https://github.com/Behat/Gherkin/tree/v4.11.0" }, - "time": "2024-10-19T14:46:06+00:00" + "time": "2024-12-06T10:07:25+00:00" }, { "name": "behat/transliterator", @@ -1309,16 +1309,16 @@ }, { "name": "composer/ca-bundle", - "version": "1.5.3", + "version": "1.5.4", "source": { "type": "git", "url": "https://github.com/composer/ca-bundle.git", - "reference": "3b1fc3f0be055baa7c6258b1467849c3e8204eb2" + "reference": "bc0593537a463e55cadf45fd938d23b75095b7e1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/ca-bundle/zipball/3b1fc3f0be055baa7c6258b1467849c3e8204eb2", - "reference": "3b1fc3f0be055baa7c6258b1467849c3e8204eb2", + "url": "https://api.github.com/repos/composer/ca-bundle/zipball/bc0593537a463e55cadf45fd938d23b75095b7e1", + "reference": "bc0593537a463e55cadf45fd938d23b75095b7e1", "shasum": "" }, "require": { @@ -1365,7 +1365,7 @@ "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/ca-bundle/issues", - "source": "https://github.com/composer/ca-bundle/tree/1.5.3" + "source": "https://github.com/composer/ca-bundle/tree/1.5.4" }, "funding": [ { @@ -1381,20 +1381,20 @@ "type": "tidelift" } ], - "time": "2024-11-04T10:15:26+00:00" + "time": "2024-11-27T15:35:25+00:00" }, { "name": "composer/class-map-generator", - "version": "1.4.0", + "version": "1.5.0", "source": { "type": "git", "url": "https://github.com/composer/class-map-generator.git", - "reference": "98bbf6780e56e0fd2404fe4b82eb665a0f93b783" + "reference": "4b0a223cf5be7c9ee7e0ef1bc7db42b4a97c9915" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/class-map-generator/zipball/98bbf6780e56e0fd2404fe4b82eb665a0f93b783", - "reference": "98bbf6780e56e0fd2404fe4b82eb665a0f93b783", + "url": "https://api.github.com/repos/composer/class-map-generator/zipball/4b0a223cf5be7c9ee7e0ef1bc7db42b4a97c9915", + "reference": "4b0a223cf5be7c9ee7e0ef1bc7db42b4a97c9915", "shasum": "" }, "require": { @@ -1403,10 +1403,10 @@ "symfony/finder": "^4.4 || ^5.3 || ^6 || ^7" }, "require-dev": { - "phpstan/phpstan": "^1.6", - "phpstan/phpstan-deprecation-rules": "^1", - "phpstan/phpstan-phpunit": "^1", - "phpstan/phpstan-strict-rules": "^1.1", + "phpstan/phpstan": "^1.12 || ^2", + "phpstan/phpstan-deprecation-rules": "^1 || ^2", + "phpstan/phpstan-phpunit": "^1 || ^2", + "phpstan/phpstan-strict-rules": "^1.1 || ^2", "phpunit/phpunit": "^8", "symfony/filesystem": "^5.4 || ^6" }, @@ -1438,7 +1438,7 @@ ], "support": { "issues": "https://github.com/composer/class-map-generator/issues", - "source": "https://github.com/composer/class-map-generator/tree/1.4.0" + "source": "https://github.com/composer/class-map-generator/tree/1.5.0" }, "funding": [ { @@ -1454,7 +1454,7 @@ "type": "tidelift" } ], - "time": "2024-10-03T18:14:00+00:00" + "time": "2024-11-25T16:11:06+00:00" }, { "name": "composer/composer", @@ -1511,13 +1511,13 @@ ], "type": "library", "extra": { - "branch-alias": { - "dev-main": "2.8-dev" - }, "phpstan": { "includes": [ "phpstan/rules.neon" ] + }, + "branch-alias": { + "dev-main": "2.8-dev" } }, "autoload": { @@ -2255,16 +2255,16 @@ }, { "name": "friendsofphp/php-cs-fixer", - "version": "v3.64.0", + "version": "v3.65.0", "source": { "type": "git", "url": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer.git", - "reference": "58dd9c931c785a79739310aef5178928305ffa67" + "reference": "79d4f3e77b250a7d8043d76c6af8f0695e8a469f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/PHP-CS-Fixer/PHP-CS-Fixer/zipball/58dd9c931c785a79739310aef5178928305ffa67", - "reference": "58dd9c931c785a79739310aef5178928305ffa67", + "url": "https://api.github.com/repos/PHP-CS-Fixer/PHP-CS-Fixer/zipball/79d4f3e77b250a7d8043d76c6af8f0695e8a469f", + "reference": "79d4f3e77b250a7d8043d76c6af8f0695e8a469f", "shasum": "" }, "require": { @@ -2274,7 +2274,7 @@ "ext-filter": "*", "ext-json": "*", "ext-tokenizer": "*", - "fidry/cpu-core-counter": "^1.0", + "fidry/cpu-core-counter": "^1.2", "php": "^7.4 || ^8.0", "react/child-process": "^0.6.5", "react/event-loop": "^1.0", @@ -2294,18 +2294,18 @@ "symfony/stopwatch": "^5.4 || ^6.0 || ^7.0" }, "require-dev": { - "facile-it/paraunit": "^1.3 || ^2.3", - "infection/infection": "^0.29.5", - "justinrainbow/json-schema": "^5.2", + "facile-it/paraunit": "^1.3.1 || ^2.4", + "infection/infection": "^0.29.8", + "justinrainbow/json-schema": "^5.3 || ^6.0", "keradus/cli-executor": "^2.1", - "mikey179/vfsstream": "^1.6.11", + "mikey179/vfsstream": "^1.6.12", "php-coveralls/php-coveralls": "^2.7", "php-cs-fixer/accessible-object": "^1.1", "php-cs-fixer/phpunit-constraint-isidenticalstring": "^1.5", "php-cs-fixer/phpunit-constraint-xmlmatchesxsd": "^1.5", - "phpunit/phpunit": "^9.6.19 || ^10.5.21 || ^11.2", - "symfony/var-dumper": "^5.4 || ^6.0 || ^7.0", - "symfony/yaml": "^5.4 || ^6.0 || ^7.0" + "phpunit/phpunit": "^9.6.21 || ^10.5.38 || ^11.4.3", + "symfony/var-dumper": "^5.4.47 || ^6.4.15 || ^7.1.8", + "symfony/yaml": "^5.4.45 || ^6.4.13 || ^7.1.6" }, "suggest": { "ext-dom": "For handling output formats in XML", @@ -2346,7 +2346,7 @@ ], "support": { "issues": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues", - "source": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/tree/v3.64.0" + "source": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/tree/v3.65.0" }, "funding": [ { @@ -2354,7 +2354,7 @@ "type": "github" } ], - "time": "2024-08-30T23:09:38+00:00" + "time": "2024-11-25T00:39:24+00:00" }, { "name": "gettext/gettext", @@ -3053,16 +3053,16 @@ }, { "name": "lucatume/wp-browser", - "version": "4.3.7", + "version": "4.4.0", "source": { "type": "git", "url": "https://github.com/lucatume/wp-browser.git", - "reference": "f89ea80ed718e4ffe5026b432c215664ea0a69e9" + "reference": "52a60fa5b9f95bda2f4694ddc0f751dfecd6612a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/lucatume/wp-browser/zipball/f89ea80ed718e4ffe5026b432c215664ea0a69e9", - "reference": "f89ea80ed718e4ffe5026b432c215664ea0a69e9", + "url": "https://api.github.com/repos/lucatume/wp-browser/zipball/52a60fa5b9f95bda2f4694ddc0f751dfecd6612a", + "reference": "52a60fa5b9f95bda2f4694ddc0f751dfecd6612a", "shasum": "" }, "require": { @@ -3089,7 +3089,7 @@ }, "require-dev": { "gumlet/php-image-resize": "^1.6", - "lucatume/codeception-snapshot-assertions": "^1.0.0", + "lucatume/codeception-snapshot-assertions": "^1.3.0", "phpstan/extension-installer": "^1.3", "phpstan/phpstan": "1.10.56", "phpstan/phpstan-symfony": "^1.3", @@ -3141,7 +3141,7 @@ ], "support": { "issues": "https://github.com/lucatume/wp-browser/issues", - "source": "https://github.com/lucatume/wp-browser/tree/4.3.7" + "source": "https://github.com/lucatume/wp-browser/tree/4.4.0" }, "funding": [ { @@ -3149,7 +3149,7 @@ "type": "github" } ], - "time": "2024-11-08T10:15:16+00:00" + "time": "2024-12-08T11:39:06+00:00" }, { "name": "masterminds/html5", @@ -3596,20 +3596,20 @@ ], "type": "library", "extra": { - "bamarni-bin": { - "bin-links": true, - "target-directory": "vendor-bin", - "forward-command": true - }, "hooks": { + "pre-push": [ + "composer qa:check" + ], "pre-commit": [ "composer style:fix", "composer code:check" - ], - "pre-push": [ - "composer qa:check" ] }, + "bamarni-bin": { + "bin-links": true, + "forward-command": true, + "target-directory": "vendor-bin" + }, "branch-alias": { "dev-main": "9.4.x-dev" } @@ -4273,16 +4273,16 @@ }, { "name": "php-stubs/wordpress-stubs", - "version": "v6.6.2", + "version": "v6.7.1", "source": { "type": "git", "url": "https://github.com/php-stubs/wordpress-stubs.git", - "reference": "f50fd7ed45894d036e4fef9ab7e5bbbaff6a30cc" + "reference": "83448e918bf06d1ed3d67ceb6a985fc266a02fd1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-stubs/wordpress-stubs/zipball/f50fd7ed45894d036e4fef9ab7e5bbbaff6a30cc", - "reference": "f50fd7ed45894d036e4fef9ab7e5bbbaff6a30cc", + "url": "https://api.github.com/repos/php-stubs/wordpress-stubs/zipball/83448e918bf06d1ed3d67ceb6a985fc266a02fd1", + "reference": "83448e918bf06d1ed3d67ceb6a985fc266a02fd1", "shasum": "" }, "require-dev": { @@ -4291,9 +4291,9 @@ "php": "^7.4 || ^8.0", "php-stubs/generator": "^0.8.3", "phpdocumentor/reflection-docblock": "^5.4.1", - "phpstan/phpstan": "^1.10.49", + "phpstan/phpstan": "^1.11", "phpunit/phpunit": "^9.5", - "szepeviktor/phpcs-psr-12-neutron-hybrid-ruleset": "^1.0", + "szepeviktor/phpcs-psr-12-neutron-hybrid-ruleset": "^1.1.1", "wp-coding-standards/wpcs": "3.1.0 as 2.3.0" }, "suggest": { @@ -4315,9 +4315,9 @@ ], "support": { "issues": "https://github.com/php-stubs/wordpress-stubs/issues", - "source": "https://github.com/php-stubs/wordpress-stubs/tree/v6.6.2" + "source": "https://github.com/php-stubs/wordpress-stubs/tree/v6.7.1" }, - "time": "2024-09-30T07:10:48+00:00" + "time": "2024-11-24T03:57:09+00:00" }, { "name": "php-webdriver/webdriver", @@ -4821,16 +4821,16 @@ }, { "name": "phpstan/phpstan", - "version": "1.12.11", + "version": "1.12.12", "source": { "type": "git", "url": "https://github.com/phpstan/phpstan.git", - "reference": "0d1fc20a962a91be578bcfe7cf939e6e1a2ff733" + "reference": "b5ae1b88f471d3fd4ba1aa0046234b5ca3776dd0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpstan/phpstan/zipball/0d1fc20a962a91be578bcfe7cf939e6e1a2ff733", - "reference": "0d1fc20a962a91be578bcfe7cf939e6e1a2ff733", + "url": "https://api.github.com/repos/phpstan/phpstan/zipball/b5ae1b88f471d3fd4ba1aa0046234b5ca3776dd0", + "reference": "b5ae1b88f471d3fd4ba1aa0046234b5ca3776dd0", "shasum": "" }, "require": { @@ -4875,7 +4875,7 @@ "type": "github" } ], - "time": "2024-11-17T14:08:01+00:00" + "time": "2024-11-28T22:13:23+00:00" }, { "name": "phpunit/php-code-coverage", @@ -5663,16 +5663,16 @@ }, { "name": "psy/psysh", - "version": "v0.12.4", + "version": "v0.12.6", "source": { "type": "git", "url": "https://github.com/bobthecow/psysh.git", - "reference": "2fd717afa05341b4f8152547f142cd2f130f6818" + "reference": "3b5ea0efaa791cd1c65ecc493aec3e2aa55ff57c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/bobthecow/psysh/zipball/2fd717afa05341b4f8152547f142cd2f130f6818", - "reference": "2fd717afa05341b4f8152547f142cd2f130f6818", + "url": "https://api.github.com/repos/bobthecow/psysh/zipball/3b5ea0efaa791cd1c65ecc493aec3e2aa55ff57c", + "reference": "3b5ea0efaa791cd1c65ecc493aec3e2aa55ff57c", "shasum": "" }, "require": { @@ -5699,12 +5699,12 @@ ], "type": "library", "extra": { - "branch-alias": { - "dev-main": "0.12.x-dev" - }, "bamarni-bin": { "bin-links": false, "forward-command": false + }, + "branch-alias": { + "dev-main": "0.12.x-dev" } }, "autoload": { @@ -5736,9 +5736,9 @@ ], "support": { "issues": "https://github.com/bobthecow/psysh/issues", - "source": "https://github.com/bobthecow/psysh/tree/v0.12.4" + "source": "https://github.com/bobthecow/psysh/tree/v0.12.6" }, - "time": "2024-06-10T01:18:23+00:00" + "time": "2024-12-07T20:08:52+00:00" }, { "name": "publishpress/publishpress-phpcs-standards", @@ -7633,16 +7633,16 @@ }, { "name": "sirbrillig/phpcs-variable-analysis", - "version": "v2.11.19", + "version": "v2.11.21", "source": { "type": "git", "url": "https://github.com/sirbrillig/phpcs-variable-analysis.git", - "reference": "bc8d7e30e2005bce5c59018b7cdb08e9fb45c0d1" + "reference": "eb2b351927098c24860daa7484e290d3eed693be" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sirbrillig/phpcs-variable-analysis/zipball/bc8d7e30e2005bce5c59018b7cdb08e9fb45c0d1", - "reference": "bc8d7e30e2005bce5c59018b7cdb08e9fb45c0d1", + "url": "https://api.github.com/repos/sirbrillig/phpcs-variable-analysis/zipball/eb2b351927098c24860daa7484e290d3eed693be", + "reference": "eb2b351927098c24860daa7484e290d3eed693be", "shasum": "" }, "require": { @@ -7653,9 +7653,9 @@ "dealerdirect/phpcodesniffer-composer-installer": "^0.7 || ^1.0", "phpcsstandards/phpcsdevcs": "^1.1", "phpstan/phpstan": "^1.7", - "phpunit/phpunit": "^4.8.36 || ^5.7.21 || ^6.5 || ^7.0 || ^8.0 || ^9.0", + "phpunit/phpunit": "^4.8.36 || ^5.7.21 || ^6.5 || ^7.0 || ^8.0 || ^9.0 || ^10.5.32 || ^11.3.3", "sirbrillig/phpcs-import-detection": "^1.1", - "vimeo/psalm": "^0.2 || ^0.3 || ^1.1 || ^4.24 || ^5.0@beta" + "vimeo/psalm": "^0.2 || ^0.3 || ^1.1 || ^4.24 || ^5.0" }, "type": "phpcodesniffer-standard", "autoload": { @@ -7687,7 +7687,7 @@ "source": "https://github.com/sirbrillig/phpcs-variable-analysis", "wiki": "https://github.com/sirbrillig/phpcs-variable-analysis/wiki" }, - "time": "2024-06-26T20:08:34+00:00" + "time": "2024-12-02T16:37:49+00:00" }, { "name": "softcreatr/jsonpath", @@ -7760,27 +7760,27 @@ }, { "name": "spatie/backtrace", - "version": "1.6.3", + "version": "1.7.1", "source": { "type": "git", "url": "https://github.com/spatie/backtrace.git", - "reference": "7c18db2bc667ac84e5d7c18e33f16c38ff2d8838" + "reference": "0f2477c520e3729de58e061b8192f161c99f770b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/spatie/backtrace/zipball/7c18db2bc667ac84e5d7c18e33f16c38ff2d8838", - "reference": "7c18db2bc667ac84e5d7c18e33f16c38ff2d8838", + "url": "https://api.github.com/repos/spatie/backtrace/zipball/0f2477c520e3729de58e061b8192f161c99f770b", + "reference": "0f2477c520e3729de58e061b8192f161c99f770b", "shasum": "" }, "require": { - "php": "^7.3|^8.0" + "php": "^7.3 || ^8.0" }, "require-dev": { "ext-json": "*", - "laravel/serializable-closure": "^1.3", - "phpunit/phpunit": "^9.3", - "spatie/phpunit-snapshot-assertions": "^4.2", - "symfony/var-dumper": "^5.1" + "laravel/serializable-closure": "^1.3 || ^2.0", + "phpunit/phpunit": "^9.3 || ^11.4.3", + "spatie/phpunit-snapshot-assertions": "^4.2 || ^5.1.6", + "symfony/var-dumper": "^5.1 || ^6.0 || ^7.0" }, "type": "library", "autoload": { @@ -7807,7 +7807,7 @@ "spatie" ], "support": { - "source": "https://github.com/spatie/backtrace/tree/1.6.3" + "source": "https://github.com/spatie/backtrace/tree/1.7.1" }, "funding": [ { @@ -7819,7 +7819,7 @@ "type": "other" } ], - "time": "2024-11-18T14:58:58+00:00" + "time": "2024-12-02T13:28:15+00:00" }, { "name": "spatie/macroable", @@ -7873,35 +7873,35 @@ }, { "name": "spatie/ray", - "version": "1.41.2", + "version": "1.41.4", "source": { "type": "git", "url": "https://github.com/spatie/ray.git", - "reference": "c44f8cfbf82c69909b505de61d8d3f2d324e93fc" + "reference": "c5dbda0548c1881b30549ccc0b6d485f7471aaa5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/spatie/ray/zipball/c44f8cfbf82c69909b505de61d8d3f2d324e93fc", - "reference": "c44f8cfbf82c69909b505de61d8d3f2d324e93fc", + "url": "https://api.github.com/repos/spatie/ray/zipball/c5dbda0548c1881b30549ccc0b6d485f7471aaa5", + "reference": "c5dbda0548c1881b30549ccc0b6d485f7471aaa5", "shasum": "" }, "require": { "ext-curl": "*", "ext-json": "*", - "php": "^7.3|^8.0", - "ramsey/uuid": "^3.0|^4.1", + "php": "^7.4 || ^8.0", + "ramsey/uuid": "^3.0 || ^4.1", "spatie/backtrace": "^1.1", - "spatie/macroable": "^1.0|^2.0", - "symfony/stopwatch": "^4.0|^5.1|^6.0|^7.0", - "symfony/var-dumper": "^4.2|^5.1|^6.0|^7.0.3" + "spatie/macroable": "^1.0 || ^2.0", + "symfony/stopwatch": "^4.2 || ^5.1 || ^6.0 || ^7.0", + "symfony/var-dumper": "^4.2 || ^5.1 || ^6.0 || ^7.0.3" }, "require-dev": { - "illuminate/support": "6.x|^8.18|^9.0", + "illuminate/support": "^7.20 || ^8.18 || ^9.0 || ^10.0 || ^11.0", "nesbot/carbon": "^2.63", "pestphp/pest": "^1.22", - "phpstan/phpstan": "^1.10", + "phpstan/phpstan": "^1.10.57 || ^2.0.2", "phpunit/phpunit": "^9.5", - "rector/rector": "^0.19.2", + "rector/rector": "dev-main", "spatie/phpunit-snapshot-assertions": "^4.2", "spatie/test-time": "^1.2" }, @@ -7942,7 +7942,7 @@ ], "support": { "issues": "https://github.com/spatie/ray/issues", - "source": "https://github.com/spatie/ray/tree/1.41.2" + "source": "https://github.com/spatie/ray/tree/1.41.4" }, "funding": [ { @@ -7954,7 +7954,7 @@ "type": "other" } ], - "time": "2024-04-24T14:21:46+00:00" + "time": "2024-12-09T11:32:15+00:00" }, { "name": "squizlabs/php_codesniffer", @@ -8038,16 +8038,16 @@ }, { "name": "symfony/browser-kit", - "version": "v7.1.6", + "version": "v7.2.0", "source": { "type": "git", "url": "https://github.com/symfony/browser-kit.git", - "reference": "714becc9ba9b20115ffededc58f6b7172dc394cf" + "reference": "8d64d17e198082f8f198d023a6b634e7b5fdda94" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/browser-kit/zipball/714becc9ba9b20115ffededc58f6b7172dc394cf", - "reference": "714becc9ba9b20115ffededc58f6b7172dc394cf", + "url": "https://api.github.com/repos/symfony/browser-kit/zipball/8d64d17e198082f8f198d023a6b634e7b5fdda94", + "reference": "8d64d17e198082f8f198d023a6b634e7b5fdda94", "shasum": "" }, "require": { @@ -8086,7 +8086,7 @@ "description": "Simulates the behavior of a web browser, allowing you to make requests, click on links and submit forms programmatically", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/browser-kit/tree/v7.1.6" + "source": "https://github.com/symfony/browser-kit/tree/v7.2.0" }, "funding": [ { @@ -8102,20 +8102,20 @@ "type": "tidelift" } ], - "time": "2024-10-25T15:11:02+00:00" + "time": "2024-10-25T15:15:23+00:00" }, { "name": "symfony/cache", - "version": "v7.1.7", + "version": "v7.2.0", "source": { "type": "git", "url": "https://github.com/symfony/cache.git", - "reference": "23b61c9592ee72233c31625f0ae805dd1571e928" + "reference": "2c926bc348184b4b235f2200fcbe8fcf3c8c5b8a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/cache/zipball/23b61c9592ee72233c31625f0ae805dd1571e928", - "reference": "23b61c9592ee72233c31625f0ae805dd1571e928", + "url": "https://api.github.com/repos/symfony/cache/zipball/2c926bc348184b4b235f2200fcbe8fcf3c8c5b8a", + "reference": "2c926bc348184b4b235f2200fcbe8fcf3c8c5b8a", "shasum": "" }, "require": { @@ -8143,6 +8143,7 @@ "doctrine/dbal": "^3.6|^4", "predis/predis": "^1.1|^2.0", "psr/simple-cache": "^1.0|^2.0|^3.0", + "symfony/clock": "^6.4|^7.0", "symfony/config": "^6.4|^7.0", "symfony/dependency-injection": "^6.4|^7.0", "symfony/filesystem": "^6.4|^7.0", @@ -8183,7 +8184,7 @@ "psr6" ], "support": { - "source": "https://github.com/symfony/cache/tree/v7.1.7" + "source": "https://github.com/symfony/cache/tree/v7.2.0" }, "funding": [ { @@ -8199,20 +8200,20 @@ "type": "tidelift" } ], - "time": "2024-11-05T15:34:55+00:00" + "time": "2024-11-25T15:21:05+00:00" }, { "name": "symfony/cache-contracts", - "version": "v3.5.0", + "version": "v3.5.1", "source": { "type": "git", "url": "https://github.com/symfony/cache-contracts.git", - "reference": "df6a1a44c890faded49a5fca33c2d5c5fd3c2197" + "reference": "15a4f8e5cd3bce9aeafc882b1acab39ec8de2c1b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/cache-contracts/zipball/df6a1a44c890faded49a5fca33c2d5c5fd3c2197", - "reference": "df6a1a44c890faded49a5fca33c2d5c5fd3c2197", + "url": "https://api.github.com/repos/symfony/cache-contracts/zipball/15a4f8e5cd3bce9aeafc882b1acab39ec8de2c1b", + "reference": "15a4f8e5cd3bce9aeafc882b1acab39ec8de2c1b", "shasum": "" }, "require": { @@ -8259,7 +8260,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/cache-contracts/tree/v3.5.0" + "source": "https://github.com/symfony/cache-contracts/tree/v3.5.1" }, "funding": [ { @@ -8275,7 +8276,7 @@ "type": "tidelift" } ], - "time": "2024-04-18T09:32:20+00:00" + "time": "2024-09-25T14:20:29+00:00" }, { "name": "symfony/config", @@ -8354,16 +8355,16 @@ }, { "name": "symfony/console", - "version": "v7.1.8", + "version": "v7.2.0", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "ff04e5b5ba043d2badfb308197b9e6b42883fcd5" + "reference": "23c8aae6d764e2bae02d2a99f7532a7f6ed619cf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/ff04e5b5ba043d2badfb308197b9e6b42883fcd5", - "reference": "ff04e5b5ba043d2badfb308197b9e6b42883fcd5", + "url": "https://api.github.com/repos/symfony/console/zipball/23c8aae6d764e2bae02d2a99f7532a7f6ed619cf", + "reference": "23c8aae6d764e2bae02d2a99f7532a7f6ed619cf", "shasum": "" }, "require": { @@ -8427,7 +8428,7 @@ "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/v7.1.8" + "source": "https://github.com/symfony/console/tree/v7.2.0" }, "funding": [ { @@ -8443,20 +8444,20 @@ "type": "tidelift" } ], - "time": "2024-11-06T14:23:19+00:00" + "time": "2024-11-06T14:24:19+00:00" }, { "name": "symfony/css-selector", - "version": "v7.1.6", + "version": "v7.2.0", "source": { "type": "git", "url": "https://github.com/symfony/css-selector.git", - "reference": "4aa4f6b3d6749c14d3aa815eef8226632e7bbc66" + "reference": "601a5ce9aaad7bf10797e3663faefce9e26c24e2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/css-selector/zipball/4aa4f6b3d6749c14d3aa815eef8226632e7bbc66", - "reference": "4aa4f6b3d6749c14d3aa815eef8226632e7bbc66", + "url": "https://api.github.com/repos/symfony/css-selector/zipball/601a5ce9aaad7bf10797e3663faefce9e26c24e2", + "reference": "601a5ce9aaad7bf10797e3663faefce9e26c24e2", "shasum": "" }, "require": { @@ -8492,7 +8493,7 @@ "description": "Converts CSS selectors to XPath expressions", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/css-selector/tree/v7.1.6" + "source": "https://github.com/symfony/css-selector/tree/v7.2.0" }, "funding": [ { @@ -8508,20 +8509,20 @@ "type": "tidelift" } ], - "time": "2024-09-25T14:20:29+00:00" + "time": "2024-09-25T14:21:43+00:00" }, { "name": "symfony/dependency-injection", - "version": "v7.1.8", + "version": "v7.2.0", "source": { "type": "git", "url": "https://github.com/symfony/dependency-injection.git", - "reference": "e4d13f0f394f4d02a041ff76acd31c5a20a5f70b" + "reference": "a475747af1a1c98272a5471abc35f3da81197c5d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/dependency-injection/zipball/e4d13f0f394f4d02a041ff76acd31c5a20a5f70b", - "reference": "e4d13f0f394f4d02a041ff76acd31c5a20a5f70b", + "url": "https://api.github.com/repos/symfony/dependency-injection/zipball/a475747af1a1c98272a5471abc35f3da81197c5d", + "reference": "a475747af1a1c98272a5471abc35f3da81197c5d", "shasum": "" }, "require": { @@ -8572,7 +8573,7 @@ "description": "Allows you to standardize and centralize the way objects are constructed in your application", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/dependency-injection/tree/v7.1.8" + "source": "https://github.com/symfony/dependency-injection/tree/v7.2.0" }, "funding": [ { @@ -8588,20 +8589,20 @@ "type": "tidelift" } ], - "time": "2024-11-09T09:16:45+00:00" + "time": "2024-11-25T15:45:00+00:00" }, { "name": "symfony/deprecation-contracts", - "version": "v3.5.0", + "version": "v3.5.1", "source": { "type": "git", "url": "https://github.com/symfony/deprecation-contracts.git", - "reference": "0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1" + "reference": "74c71c939a79f7d5bf3c1ce9f5ea37ba0114c6f6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1", - "reference": "0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/74c71c939a79f7d5bf3c1ce9f5ea37ba0114c6f6", + "reference": "74c71c939a79f7d5bf3c1ce9f5ea37ba0114c6f6", "shasum": "" }, "require": { @@ -8639,7 +8640,7 @@ "description": "A generic function and convention to trigger deprecation notices", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/deprecation-contracts/tree/v3.5.0" + "source": "https://github.com/symfony/deprecation-contracts/tree/v3.5.1" }, "funding": [ { @@ -8655,20 +8656,20 @@ "type": "tidelift" } ], - "time": "2024-04-18T09:32:20+00:00" + "time": "2024-09-25T14:20:29+00:00" }, { "name": "symfony/dom-crawler", - "version": "v7.1.6", + "version": "v7.2.0", "source": { "type": "git", "url": "https://github.com/symfony/dom-crawler.git", - "reference": "794ddd5481ba15d8a04132c95e211cd5656e09fb" + "reference": "b176e1f1f550ef44c94eb971bf92488de08f7c6b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/dom-crawler/zipball/794ddd5481ba15d8a04132c95e211cd5656e09fb", - "reference": "794ddd5481ba15d8a04132c95e211cd5656e09fb", + "url": "https://api.github.com/repos/symfony/dom-crawler/zipball/b176e1f1f550ef44c94eb971bf92488de08f7c6b", + "reference": "b176e1f1f550ef44c94eb971bf92488de08f7c6b", "shasum": "" }, "require": { @@ -8706,7 +8707,7 @@ "description": "Eases DOM navigation for HTML and XML documents", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/dom-crawler/tree/v7.1.6" + "source": "https://github.com/symfony/dom-crawler/tree/v7.2.0" }, "funding": [ { @@ -8722,20 +8723,20 @@ "type": "tidelift" } ], - "time": "2024-10-25T15:11:02+00:00" + "time": "2024-11-13T16:15:23+00:00" }, { "name": "symfony/event-dispatcher", - "version": "v7.1.6", + "version": "v7.2.0", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "87254c78dd50721cfd015b62277a8281c5589702" + "reference": "910c5db85a5356d0fea57680defec4e99eb9c8c1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/87254c78dd50721cfd015b62277a8281c5589702", - "reference": "87254c78dd50721cfd015b62277a8281c5589702", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/910c5db85a5356d0fea57680defec4e99eb9c8c1", + "reference": "910c5db85a5356d0fea57680defec4e99eb9c8c1", "shasum": "" }, "require": { @@ -8786,7 +8787,7 @@ "description": "Provides tools that allow your application components to communicate with each other by dispatching events and listening to them", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/event-dispatcher/tree/v7.1.6" + "source": "https://github.com/symfony/event-dispatcher/tree/v7.2.0" }, "funding": [ { @@ -8802,20 +8803,20 @@ "type": "tidelift" } ], - "time": "2024-09-25T14:20:29+00:00" + "time": "2024-09-25T14:21:43+00:00" }, { "name": "symfony/event-dispatcher-contracts", - "version": "v3.5.0", + "version": "v3.5.1", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher-contracts.git", - "reference": "8f93aec25d41b72493c6ddff14e916177c9efc50" + "reference": "7642f5e970b672283b7823222ae8ef8bbc160b9f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher-contracts/zipball/8f93aec25d41b72493c6ddff14e916177c9efc50", - "reference": "8f93aec25d41b72493c6ddff14e916177c9efc50", + "url": "https://api.github.com/repos/symfony/event-dispatcher-contracts/zipball/7642f5e970b672283b7823222ae8ef8bbc160b9f", + "reference": "7642f5e970b672283b7823222ae8ef8bbc160b9f", "shasum": "" }, "require": { @@ -8862,7 +8863,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/event-dispatcher-contracts/tree/v3.5.0" + "source": "https://github.com/symfony/event-dispatcher-contracts/tree/v3.5.1" }, "funding": [ { @@ -8878,7 +8879,7 @@ "type": "tidelift" } ], - "time": "2024-04-18T09:32:20+00:00" + "time": "2024-09-25T14:20:29+00:00" }, { "name": "symfony/filesystem", @@ -8948,16 +8949,16 @@ }, { "name": "symfony/finder", - "version": "v7.1.6", + "version": "v7.2.0", "source": { "type": "git", "url": "https://github.com/symfony/finder.git", - "reference": "2cb89664897be33f78c65d3d2845954c8d7a43b8" + "reference": "6de263e5868b9a137602dd1e33e4d48bfae99c49" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/2cb89664897be33f78c65d3d2845954c8d7a43b8", - "reference": "2cb89664897be33f78c65d3d2845954c8d7a43b8", + "url": "https://api.github.com/repos/symfony/finder/zipball/6de263e5868b9a137602dd1e33e4d48bfae99c49", + "reference": "6de263e5868b9a137602dd1e33e4d48bfae99c49", "shasum": "" }, "require": { @@ -8992,7 +8993,7 @@ "description": "Finds files and directories via an intuitive fluent interface", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/finder/tree/v7.1.6" + "source": "https://github.com/symfony/finder/tree/v7.2.0" }, "funding": [ { @@ -9008,30 +9009,31 @@ "type": "tidelift" } ], - "time": "2024-10-01T08:31:23+00:00" + "time": "2024-10-23T06:56:12+00:00" }, { "name": "symfony/http-client", - "version": "v7.1.8", + "version": "v7.2.0", "source": { "type": "git", "url": "https://github.com/symfony/http-client.git", - "reference": "c30d91a1deac0dc3ed5e604683cf2e1dfc635b8a" + "reference": "955e43336aff03df1e8a8e17daefabb0127a313b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-client/zipball/c30d91a1deac0dc3ed5e604683cf2e1dfc635b8a", - "reference": "c30d91a1deac0dc3ed5e604683cf2e1dfc635b8a", + "url": "https://api.github.com/repos/symfony/http-client/zipball/955e43336aff03df1e8a8e17daefabb0127a313b", + "reference": "955e43336aff03df1e8a8e17daefabb0127a313b", "shasum": "" }, "require": { "php": ">=8.2", "psr/log": "^1|^2|^3", "symfony/deprecation-contracts": "^2.5|^3", - "symfony/http-client-contracts": "^3.4.1", + "symfony/http-client-contracts": "~3.4.3|^3.5.1", "symfony/service-contracts": "^2.5|^3" }, "conflict": { + "amphp/amp": "<2.5", "php-http/discovery": "<1.15", "symfony/http-foundation": "<6.4" }, @@ -9042,14 +9044,14 @@ "symfony/http-client-implementation": "3.0" }, "require-dev": { - "amphp/amp": "^2.5", - "amphp/http-client": "^4.2.1", - "amphp/http-tunnel": "^1.0", + "amphp/http-client": "^4.2.1|^5.0", + "amphp/http-tunnel": "^1.0|^2.0", "amphp/socket": "^1.1", "guzzlehttp/promises": "^1.4|^2.0", "nyholm/psr7": "^1.0", "php-http/httplug": "^1.0|^2.0", "psr/http-client": "^1.0", + "symfony/amphp-http-client-meta": "^1.0|^2.0", "symfony/dependency-injection": "^6.4|^7.0", "symfony/http-kernel": "^6.4|^7.0", "symfony/messenger": "^6.4|^7.0", @@ -9086,7 +9088,7 @@ "http" ], "support": { - "source": "https://github.com/symfony/http-client/tree/v7.1.8" + "source": "https://github.com/symfony/http-client/tree/v7.2.0" }, "funding": [ { @@ -9102,20 +9104,20 @@ "type": "tidelift" } ], - "time": "2024-11-13T13:40:27+00:00" + "time": "2024-11-29T08:22:02+00:00" }, { "name": "symfony/http-client-contracts", - "version": "v3.5.0", + "version": "v3.5.1", "source": { "type": "git", "url": "https://github.com/symfony/http-client-contracts.git", - "reference": "20414d96f391677bf80078aa55baece78b82647d" + "reference": "c2f3ad828596624ca39ea40f83617ef51ca8bbf9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-client-contracts/zipball/20414d96f391677bf80078aa55baece78b82647d", - "reference": "20414d96f391677bf80078aa55baece78b82647d", + "url": "https://api.github.com/repos/symfony/http-client-contracts/zipball/c2f3ad828596624ca39ea40f83617ef51ca8bbf9", + "reference": "c2f3ad828596624ca39ea40f83617ef51ca8bbf9", "shasum": "" }, "require": { @@ -9123,12 +9125,12 @@ }, "type": "library", "extra": { + "thanks": { + "url": "https://github.com/symfony/contracts", + "name": "symfony/contracts" + }, "branch-alias": { "dev-main": "3.5-dev" - }, - "thanks": { - "name": "symfony/contracts", - "url": "https://github.com/symfony/contracts" } }, "autoload": { @@ -9164,7 +9166,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/http-client-contracts/tree/v3.5.0" + "source": "https://github.com/symfony/http-client-contracts/tree/v3.5.1" }, "funding": [ { @@ -9180,20 +9182,20 @@ "type": "tidelift" } ], - "time": "2024-04-18T09:32:20+00:00" + "time": "2024-11-25T12:02:18+00:00" }, { "name": "symfony/options-resolver", - "version": "v7.1.6", + "version": "v7.2.0", "source": { "type": "git", "url": "https://github.com/symfony/options-resolver.git", - "reference": "85e95eeede2d41cd146146e98c9c81d9214cae85" + "reference": "7da8fbac9dcfef75ffc212235d76b2754ce0cf50" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/options-resolver/zipball/85e95eeede2d41cd146146e98c9c81d9214cae85", - "reference": "85e95eeede2d41cd146146e98c9c81d9214cae85", + "url": "https://api.github.com/repos/symfony/options-resolver/zipball/7da8fbac9dcfef75ffc212235d76b2754ce0cf50", + "reference": "7da8fbac9dcfef75ffc212235d76b2754ce0cf50", "shasum": "" }, "require": { @@ -9231,7 +9233,7 @@ "options" ], "support": { - "source": "https://github.com/symfony/options-resolver/tree/v7.1.6" + "source": "https://github.com/symfony/options-resolver/tree/v7.2.0" }, "funding": [ { @@ -9247,7 +9249,7 @@ "type": "tidelift" } ], - "time": "2024-09-25T14:20:29+00:00" + "time": "2024-11-20T11:17:29+00:00" }, { "name": "symfony/polyfill-ctype", @@ -9275,8 +9277,8 @@ "type": "library", "extra": { "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" + "url": "https://github.com/symfony/polyfill", + "name": "symfony/polyfill" } }, "autoload": { @@ -9351,8 +9353,8 @@ "type": "library", "extra": { "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" + "url": "https://github.com/symfony/polyfill", + "name": "symfony/polyfill" } }, "autoload": { @@ -9429,8 +9431,8 @@ "type": "library", "extra": { "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" + "url": "https://github.com/symfony/polyfill", + "name": "symfony/polyfill" } }, "autoload": { @@ -9587,8 +9589,8 @@ "type": "library", "extra": { "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" + "url": "https://github.com/symfony/polyfill", + "name": "symfony/polyfill" } }, "autoload": { @@ -9663,8 +9665,8 @@ "type": "library", "extra": { "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" + "url": "https://github.com/symfony/polyfill", + "name": "symfony/polyfill" } }, "autoload": { @@ -9743,8 +9745,8 @@ "type": "library", "extra": { "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" + "url": "https://github.com/symfony/polyfill", + "name": "symfony/polyfill" } }, "autoload": { @@ -9862,16 +9864,16 @@ }, { "name": "symfony/service-contracts", - "version": "v3.5.0", + "version": "v3.5.1", "source": { "type": "git", "url": "https://github.com/symfony/service-contracts.git", - "reference": "bd1d9e59a81d8fa4acdcea3f617c581f7475a80f" + "reference": "e53260aabf78fb3d63f8d79d69ece59f80d5eda0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/service-contracts/zipball/bd1d9e59a81d8fa4acdcea3f617c581f7475a80f", - "reference": "bd1d9e59a81d8fa4acdcea3f617c581f7475a80f", + "url": "https://api.github.com/repos/symfony/service-contracts/zipball/e53260aabf78fb3d63f8d79d69ece59f80d5eda0", + "reference": "e53260aabf78fb3d63f8d79d69ece59f80d5eda0", "shasum": "" }, "require": { @@ -9925,7 +9927,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/service-contracts/tree/v3.5.0" + "source": "https://github.com/symfony/service-contracts/tree/v3.5.1" }, "funding": [ { @@ -9941,20 +9943,20 @@ "type": "tidelift" } ], - "time": "2024-04-18T09:32:20+00:00" + "time": "2024-09-25T14:20:29+00:00" }, { "name": "symfony/stopwatch", - "version": "v7.1.6", + "version": "v7.2.0", "source": { "type": "git", "url": "https://github.com/symfony/stopwatch.git", - "reference": "8b4a434e6e7faf6adedffb48783a5c75409a1a05" + "reference": "696f418b0d722a4225e1c3d95489d262971ca924" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/stopwatch/zipball/8b4a434e6e7faf6adedffb48783a5c75409a1a05", - "reference": "8b4a434e6e7faf6adedffb48783a5c75409a1a05", + "url": "https://api.github.com/repos/symfony/stopwatch/zipball/696f418b0d722a4225e1c3d95489d262971ca924", + "reference": "696f418b0d722a4225e1c3d95489d262971ca924", "shasum": "" }, "require": { @@ -9987,7 +9989,7 @@ "description": "Provides a way to profile code", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/stopwatch/tree/v7.1.6" + "source": "https://github.com/symfony/stopwatch/tree/v7.2.0" }, "funding": [ { @@ -10003,20 +10005,20 @@ "type": "tidelift" } ], - "time": "2024-09-25T14:20:29+00:00" + "time": "2024-09-25T14:21:43+00:00" }, { "name": "symfony/string", - "version": "v7.1.8", + "version": "v7.2.0", "source": { "type": "git", "url": "https://github.com/symfony/string.git", - "reference": "591ebd41565f356fcd8b090fe64dbb5878f50281" + "reference": "446e0d146f991dde3e73f45f2c97a9faad773c82" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/string/zipball/591ebd41565f356fcd8b090fe64dbb5878f50281", - "reference": "591ebd41565f356fcd8b090fe64dbb5878f50281", + "url": "https://api.github.com/repos/symfony/string/zipball/446e0d146f991dde3e73f45f2c97a9faad773c82", + "reference": "446e0d146f991dde3e73f45f2c97a9faad773c82", "shasum": "" }, "require": { @@ -10074,7 +10076,7 @@ "utf8" ], "support": { - "source": "https://github.com/symfony/string/tree/v7.1.8" + "source": "https://github.com/symfony/string/tree/v7.2.0" }, "funding": [ { @@ -10090,24 +10092,25 @@ "type": "tidelift" } ], - "time": "2024-11-13T13:31:21+00:00" + "time": "2024-11-13T13:31:26+00:00" }, { "name": "symfony/translation", - "version": "v7.1.6", + "version": "v7.2.0", "source": { "type": "git", "url": "https://github.com/symfony/translation.git", - "reference": "b9f72ab14efdb6b772f85041fa12f820dee8d55f" + "reference": "dc89e16b44048ceecc879054e5b7f38326ab6cc5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/translation/zipball/b9f72ab14efdb6b772f85041fa12f820dee8d55f", - "reference": "b9f72ab14efdb6b772f85041fa12f820dee8d55f", + "url": "https://api.github.com/repos/symfony/translation/zipball/dc89e16b44048ceecc879054e5b7f38326ab6cc5", + "reference": "dc89e16b44048ceecc879054e5b7f38326ab6cc5", "shasum": "" }, "require": { "php": ">=8.2", + "symfony/deprecation-contracts": "^2.5|^3", "symfony/polyfill-mbstring": "~1.0", "symfony/translation-contracts": "^2.5|^3.0" }, @@ -10168,7 +10171,7 @@ "description": "Provides tools to internationalize your application", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/translation/tree/v7.1.6" + "source": "https://github.com/symfony/translation/tree/v7.2.0" }, "funding": [ { @@ -10184,20 +10187,20 @@ "type": "tidelift" } ], - "time": "2024-09-28T12:35:13+00:00" + "time": "2024-11-12T20:47:56+00:00" }, { "name": "symfony/translation-contracts", - "version": "v3.5.0", + "version": "v3.5.1", "source": { "type": "git", "url": "https://github.com/symfony/translation-contracts.git", - "reference": "b9d2189887bb6b2e0367a9fc7136c5239ab9b05a" + "reference": "4667ff3bd513750603a09c8dedbea942487fb07c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/translation-contracts/zipball/b9d2189887bb6b2e0367a9fc7136c5239ab9b05a", - "reference": "b9d2189887bb6b2e0367a9fc7136c5239ab9b05a", + "url": "https://api.github.com/repos/symfony/translation-contracts/zipball/4667ff3bd513750603a09c8dedbea942487fb07c", + "reference": "4667ff3bd513750603a09c8dedbea942487fb07c", "shasum": "" }, "require": { @@ -10246,7 +10249,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/translation-contracts/tree/v3.5.0" + "source": "https://github.com/symfony/translation-contracts/tree/v3.5.1" }, "funding": [ { @@ -10262,20 +10265,20 @@ "type": "tidelift" } ], - "time": "2024-04-18T09:32:20+00:00" + "time": "2024-09-25T14:20:29+00:00" }, { "name": "symfony/var-dumper", - "version": "v7.1.8", + "version": "v7.2.0", "source": { "type": "git", "url": "https://github.com/symfony/var-dumper.git", - "reference": "7bb01a47b1b00428d32b5e7b4d3b2d1aa58d3db8" + "reference": "c6a22929407dec8765d6e2b6ff85b800b245879c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/var-dumper/zipball/7bb01a47b1b00428d32b5e7b4d3b2d1aa58d3db8", - "reference": "7bb01a47b1b00428d32b5e7b4d3b2d1aa58d3db8", + "url": "https://api.github.com/repos/symfony/var-dumper/zipball/c6a22929407dec8765d6e2b6ff85b800b245879c", + "reference": "c6a22929407dec8765d6e2b6ff85b800b245879c", "shasum": "" }, "require": { @@ -10291,7 +10294,7 @@ "symfony/http-kernel": "^6.4|^7.0", "symfony/process": "^6.4|^7.0", "symfony/uid": "^6.4|^7.0", - "twig/twig": "^3.0.4" + "twig/twig": "^3.12" }, "bin": [ "Resources/bin/var-dump-server" @@ -10329,7 +10332,7 @@ "dump" ], "support": { - "source": "https://github.com/symfony/var-dumper/tree/v7.1.8" + "source": "https://github.com/symfony/var-dumper/tree/v7.2.0" }, "funding": [ { @@ -10345,20 +10348,20 @@ "type": "tidelift" } ], - "time": "2024-11-08T15:46:42+00:00" + "time": "2024-11-08T15:48:14+00:00" }, { "name": "symfony/var-exporter", - "version": "v7.1.6", + "version": "v7.2.0", "source": { "type": "git", "url": "https://github.com/symfony/var-exporter.git", - "reference": "90173ef89c40e7c8c616653241048705f84130ef" + "reference": "1a6a89f95a46af0f142874c9d650a6358d13070d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/var-exporter/zipball/90173ef89c40e7c8c616653241048705f84130ef", - "reference": "90173ef89c40e7c8c616653241048705f84130ef", + "url": "https://api.github.com/repos/symfony/var-exporter/zipball/1a6a89f95a46af0f142874c9d650a6358d13070d", + "reference": "1a6a89f95a46af0f142874c9d650a6358d13070d", "shasum": "" }, "require": { @@ -10405,7 +10408,7 @@ "serialize" ], "support": { - "source": "https://github.com/symfony/var-exporter/tree/v7.1.6" + "source": "https://github.com/symfony/var-exporter/tree/v7.2.0" }, "funding": [ { @@ -10421,24 +10424,25 @@ "type": "tidelift" } ], - "time": "2024-09-25T14:20:29+00:00" + "time": "2024-10-18T07:58:17+00:00" }, { "name": "symfony/yaml", - "version": "v7.1.6", + "version": "v7.2.0", "source": { "type": "git", "url": "https://github.com/symfony/yaml.git", - "reference": "3ced3f29e4f0d6bce2170ff26719f1fe9aacc671" + "reference": "099581e99f557e9f16b43c5916c26380b54abb22" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/yaml/zipball/3ced3f29e4f0d6bce2170ff26719f1fe9aacc671", - "reference": "3ced3f29e4f0d6bce2170ff26719f1fe9aacc671", + "url": "https://api.github.com/repos/symfony/yaml/zipball/099581e99f557e9f16b43c5916c26380b54abb22", + "reference": "099581e99f557e9f16b43c5916c26380b54abb22", "shasum": "" }, "require": { "php": ">=8.2", + "symfony/deprecation-contracts": "^2.5|^3.0", "symfony/polyfill-ctype": "^1.8" }, "conflict": { @@ -10476,7 +10480,7 @@ "description": "Loads and dumps YAML files", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/yaml/tree/v7.1.6" + "source": "https://github.com/symfony/yaml/tree/v7.2.0" }, "funding": [ { @@ -10492,7 +10496,7 @@ "type": "tidelift" } ], - "time": "2024-09-25T14:20:29+00:00" + "time": "2024-10-23T06:56:12+00:00" }, { "name": "szepeviktor/phpstan-wordpress", @@ -11666,9 +11670,6 @@ }, "type": "wp-cli-package", "extra": { - "branch-alias": { - "dev-main": "2.x-dev" - }, "bundled": true, "commands": [ "i18n", @@ -11677,7 +11678,10 @@ "i18n make-mo", "i18n make-php", "i18n update-po" - ] + ], + "branch-alias": { + "dev-main": "2.x-dev" + } }, "autoload": { "files": [ diff --git a/dev-workspace/scripts/lang-constants.sh b/dev-workspace/scripts/lang-constants.sh index e0f8bf821..b47d5e046 100644 --- a/dev-workspace/scripts/lang-constants.sh +++ b/dev-workspace/scripts/lang-constants.sh @@ -8,4 +8,4 @@ export LANG_DIR="languages" export LANG_LOCALES="pt_BR it_IT es_ES fr_FR nl_NL" # Space separated list of script handlers that the plugin provides -export LANG_SCRIPT_HANDLERS="future_workflow_editor_script" +export LANG_SCRIPT_HANDLERS="future_workflow_editor_script future_backup_panel" diff --git a/dev-workspace/scripts/lang-make-pot-js.sh b/dev-workspace/scripts/lang-make-pot-js.sh index 765849a2b..96bd2ba2c 100644 --- a/dev-workspace/scripts/lang-make-pot-js.sh +++ b/dev-workspace/scripts/lang-make-pot-js.sh @@ -2,7 +2,7 @@ source /project/dev-workspace/scripts/lang-constants.sh -export JSX_SCRIPTS="workflow-editor/future_workflow_editor_script" +export JSX_SCRIPTS="workflow-editor/future_workflow_editor_script backup-panel/future_backup_panel" for locale in $LANG_LOCALES do diff --git a/docs/translate-js-scripts.md b/docs/translate-js-scripts.md new file mode 100644 index 000000000..f68e0edaf --- /dev/null +++ b/docs/translate-js-scripts.md @@ -0,0 +1,19 @@ +# Translate JS scripts + +* Edit the `dev-workspace/scripts/lang-constants.sh` file adding the script handle to the `LANG_SCRIPT_HANDLERS` variable. +* Edit the `dev-workspace/scripts/lang-make-pot-js.sh` file adding the script path to the `JSX_SCRIPTS` variable. +* Enqueue the `wp-i18n` script in the `enqueueAdminScripts` method. +* Add the `wp-i18n` as a dependency to the script that needs translation. +* Import the `__` function and use it to translate the strings: `import { __ } from '@wordpress/i18n'; +* Run the command `composer build:lang` to generate/update the language files. +* Pay attention on using the correct text domain. + +## Language files + +* `languages/-_script.pot` +* `languages/--.po` +* `languages/--.json` +* `languages/--.I10n.php` + +`.mo` files are generated but deleted since they are not used. For scripts, `json` and `I10n.php` (this one I'm not sure about) files are used instead. + diff --git a/languages/post-expirator-es_ES-future_backup_panel.json b/languages/post-expirator-es_ES-future_backup_panel.json new file mode 100644 index 000000000..d20431cf4 --- /dev/null +++ b/languages/post-expirator-es_ES-future_backup_panel.json @@ -0,0 +1 @@ +{"domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"","plural_forms":""},"Backup":[""]}}} \ No newline at end of file diff --git a/languages/post-expirator-es_ES-future_backup_panel.l10n.php b/languages/post-expirator-es_ES-future_backup_panel.l10n.php new file mode 100644 index 000000000..e4d7cd784 --- /dev/null +++ b/languages/post-expirator-es_ES-future_backup_panel.l10n.php @@ -0,0 +1,2 @@ +NULL,'plural-forms'=>NULL,'language'=>'','project-id-version'=>'','pot-creation-date'=>'2024-11-27T18:46:33+00:00','po-revision-date'=>'2024-11-27T18:46:33+00:00','messages'=>[]]; \ No newline at end of file diff --git a/languages/post-expirator-es_ES-future_backup_panel.po b/languages/post-expirator-es_ES-future_backup_panel.po new file mode 100644 index 000000000..5432aff94 --- /dev/null +++ b/languages/post-expirator-es_ES-future_backup_panel.po @@ -0,0 +1,16 @@ +msgid "" +msgstr "" +"Project-Id-Version: \n" +"Report-Msgid-Bugs-To: \n" +"Last-Translator: \n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"POT-Creation-Date: 2024-11-27T18:46:33+00:00\n" +"PO-Revision-Date: 2024-11-27T18:46:33+00:00\n" +"Language: \n" + +#: components/BackupPanel.jsx:6 +msgid "Backup" +msgstr "" diff --git a/languages/post-expirator-es_ES.l10n.php b/languages/post-expirator-es_ES.l10n.php index 501f28b83..b940a2804 100644 --- a/languages/post-expirator-es_ES.l10n.php +++ b/languages/post-expirator-es_ES.l10n.php @@ -1,2 +1,2 @@ NULL,'plural-forms'=>'nplurals=2; plural=n != 1;','language'=>'es','project-id-version'=>'Plugins - PublishPress Future: Automatically Unpublish WordPress Posts - Stable (latest release)','pot-creation-date'=>'2024-11-19T15:23:53+00:00','po-revision-date'=>'2024-11-20 22:50+0100','x-generator'=>'Poedit 3.4.4','messages'=>['PublishPress Future'=>'PublishPress Future','http://wordpress.org/extend/plugins/post-expirator/'=>'https://es.wordpress.org/plugins/post-expirator/','PublishPress Future allows you to schedule automatic changes to posts, pages and other content types.'=>'PublishPress Future te permite programar cambios automáticos en entradas, páginas y otros tipos de contenido.','PublishPress'=>'PublishPress','http://publishpress.com'=>'https://publishpress.com','You do not have permission to configure PublishPress Future.'=>'No tienes permisos para configurar PublishPress Future.','Debug is disabled'=>'Depuración desactivada','Debugging Disabled'=>'Depuración desactivada','Debugging Enabled'=>'Depuración activada','Debugging Table Emptied'=>'Tabla de depuración vaciada','The legacy future actions migration has been enqueued and will run asynchronously.'=>'La migración de acciones Future heredadas se ha puesto en cola y se ejecutará de forma asíncrona.','The legacy actions arguments restoration has been enqueued and will run asynchronously.'=>'La restauración de los argumentos de las acciones heredadas se ha puesto en cola y se ejecutará de forma asíncrona.','The database schema was fixed.'=>'Se ha corregido el esquema de la base de datos.','The database schema could not be fixed. Please, contact the support team.'=>'No se ha podido corregir el esquema de la base de datos. Por favor, contacta con el equipo de soporte.','Saved Options!'=>'¡Opciones guardadas!','If you like %1$s, please leave us a %2$s rating. Thank you!'=>'Si te gusta %1$s, por favor, déjanos una valoración de %2$s. ¡Gracias!','About PublishPress Future'=>'Acerca de PublishPress Future','About'=>'Acerca de','Future Documentation'=>'Documentación de Future','Documentation'=>'Documentación','Contact the PublishPress team'=>'Contacta con el equipo de PublishPress','Contact'=>'Contacto','No taxonomies found'=>'No se han encontrado taxonomías','l F jS, Y'=>'l, j F Y','g:ia'=>'g:ia','Post expires at EXPIRATIONTIME on ACTIONDATE'=>'La entrada caduca en EXPIRATIONTIME el ACTIONDATE','The table %s does not exist.'=>'La tabla %s no existe.','The table indexes are invalid: '=>'Los índices de la tabla no son válidos: ','Invalid date time offset.'=>'Desplazamiento de fecha y hora no válido.','You do not have sufficient permissions to access this page.'=>'No tienes permisos suficientes para acceder a esta página.','Invalid nonce.'=>'Nonce no válido.','Categories'=>'Categorìas','Future Actions'=>'Acciones Future','Enable Future Action'=>'Activar caducidad de la entrada','Action'=>'Acción','Loading'=>'Cargando','Show Calendar'=>'Muestra el calendario','Hide Calendar'=>'Oculta el calendario','Timezone is controlled by the {WordPress Settings}.'=>'La zona horaria se controla mediante los {Ajustes de WordPress}.','No %s found.'=>'No se ha encontrado %s.','You must assign a taxonomy to this post type to use this feature.'=>'Debe asignar una taxonomía a este tipo de entrada para utilizar esta función.','New %s'=>'Nuevo %s','%s to remove'=>'%s a eliminar','%s to add'=>'%s a añadir','Search for %s'=>'Búsqueda por %s','Select an action'=>'Selecciona una acción','Select a date'=>'Selecciona una fecha','Date cannot be in the past'=>'La fecha no puede estar en el pasado','Please select one or more %s'=>'Por favor, selecciona uno o más %s','New status'=>'Nuevo estado','No posts selected. Unable to sync Future Actions.'=>'No hay entradas seleccionadas. No se pueden sincronizar las acciones de Future.','Future Actions successfully synced with Post Metadata.'=>'Acciones de Future sincronizadas correctamente con los metadatos de la entrada.','Update Future Actions from Post Metadata'=>'Actualiza las acciones de Future a partir de los metadatos de la entrada','Future Action Update'=>'Actualizaciòn de las acciones de Future','— No Change —'=>'— Sin cambios —','Add or update action for posts'=>'Añade o actualiza la acción para las entradas','Add action if none exists for posts'=>'Añade una acción si no hay ninguna para las entradas','Update the existing actions for posts'=>'Actualiza las acciones existentes para las entradas','Remove action from posts'=>'Quitar acción de las entradas','Category'=>'Categorìa','Settings'=>'Ajustes','Future Action'=>'Acción Future','Future'=>'Future','Action Settings'=>'Ajustes de las acciones','Scheduled Actions'=>'Acciones programadas','Log format'=>'Formato del registro','List'=>'Lista','Popup'=>'Ventana emergente','Successfully executed action: %s'=>'Acción ejecutada correctamente: %s','Executed workflow scheduled step'=>'Paso programado del flujo de trabajo ejecutado','Cleaned up completed scheduled steps older than %d days'=>'Se han limpiado los pasos programados completados de más de %d días','Cleaned up orphan workflow scheduled step arguments'=>'Se han limpiado los argumentos huérfanos de los pasos programados del flujo de trabajo','The shortcode [futureaction] must be used inside the loop or with the post_id attribute.'=>'El shortcode [futureaction] debe utilizarse dentro del bucle o con el atributo post_id.','The column args length was not updated to 1000.'=>'La longitud de la columna de argumentos no se actualizó a 1000.','Status didn\'t change.'=>'El estado no ha cambiado.','Status has been successfully changed from "%1$s" to "%2$s".'=>'El estado se ha cambiado correctamente de «%1$s» a «%2$s».','Change status'=>'Cambiar estado','%s was not deleted.'=>'%s no ha sido borrado.','%s has been successfully deleted.'=>'%s ha sido borrado correctamente.','Delete'=>'Borrar','No terms were added to the %s.'=>'No se han añadido términos a la %s.','The following terms (%1$s) were added to the %2$s: "%3$s". The full list of terms on the post is: %4$s.'=>'Los siguientes términos (%1$s) fueron añadidos a la %2$s: «%3$s». La lista completa de términos en la entrada es: %4$s.','Add extra %s'=>'Añadir extra %s','No terms were removed from the %s.'=>'No se han eliminado términos de la %s.','The following terms (%1$s) were removed from the %2$s: %3$s. The new list of terms on the post is: %4$s.'=>'Los siguientes términos (%1$s) fueron eliminados de la %2$s: «%3$s». La nueva lista de términos en la entrada es: %4$s.','Remove selected %s'=>'Eliminar %s seleccionados','The following terms (%1$s) were removed from the %2$s: %3$s.'=>'Los siguientes términos (%1$s) fueron eliminados de la %2$s: «%3$s».','Remove all %s'=>'Eliminar todo %s','No terms were changed on the %s.'=>'No se han modificado los términos en la %s.','The following terms (%1$s) were set to the %2$s: "%3$s". The old list of terms on the post was: %4$s.'=>'Los siguientes términos (%1$s) se establecieron en la %2$s: «%3$s». La antigua lista de términos de la entrada era: %4$s.','Replace all %s'=>'Sustituir todo %s','Change status to %s'=>'Cambia el estado a %s','%s didn\'t change.'=>'%s no ha cambiado.','%s has been added to stickies list.'=>'%s ha sido añadido a la lista de fijos.','Stick'=>'Fijar','%s has been removed from stickies list.'=>'%s ha sido quitado de la lista de fijos.','Unstick'=>'No fijar','Email is disabled.'=>'Correo electrónico desactivado.','Email sent.'=>'Correo electrónico enviado.','Email not sent.'=>'Correo electrónico no enviado.','%1$s. %2$s on %3$s. The post link is %4$s'=>'%1$s. %2$s el día %3$s. El enlace de la entrada es %4$s','Future Action Complete "%s"'=>'Caducidad de la entrada completada «%s»','[%1$s] %2$s'=>'[%1$s] %2$s','Invalid date/time offset "%s" for post type "%s". Please ensure you use only English terms for the date/time offset, such as "3 months" or "1 week".'=>'Desplazamiento fecha/hora «%s» no válido para el tipo de entrada «%s». Asegúrate de utilizar únicamente términos en inglés para el desfase fecha/hora, como «3 months» o «1 week».','Status'=>'Estado','Arguments'=>'Argumentos','Logs'=>'Registros','Scheduled Date'=>'Fecha programada','Recurrence'=>'Recurrente','Run'=>'Ejecutar','Process the action now'=>'Ejecuta la acción ahora','Cancel'=>'Cancelar','Cancel the action. This will prevent the action from running in the future'=>'Cancela la acción. Esto evitará que la acción se ejecute en el futuro','%s year'=>'%s año' . "\0" . '%s años','%s month'=>'%s mes' . "\0" . '%s meses','%s week'=>'%s semana' . "\0" . '%s semanas','%s day'=>'%s día' . "\0" . '%s días','%s hour'=>'%s hora' . "\0" . '%s horas','%s minute'=>'%s minuto' . "\0" . '%s minutos','%s second'=>'%s segundo' . "\0" . '%s segundos','Action Logs'=>'Registro de eventos','Uninitialized'=>'Sin inicializar','Scheduled'=>'Programado','Complete'=>'Completar','Failed'=>'Fallido','Canceled'=>'Cancelado','Running'=>'En curso','All'=>'Todos','Search hook, args and claim ID'=>'Buscar gancho, argumentos e ID de reclamación','Completed'=>'Completado','%1$s: [%2$d] %3$s%4$s%5$s'=>'%1$s: [%2$d] %3$s%4$s%5$s','New Status: %s'=>'Nuevo estado: %s','Terms: %s'=>'Términos: %s','View log'=>'Ver registro','Action: '=>'Acción: ','Status: '=>'Estado: ','Arguments: '=>'Argumentos: ','Scheduled date: '=>'Fecha programada: ','Date'=>'Fecha','Message'=>'Mensaje','Async'=>'Asíncrona',' (%s ago)'=>' (hace %s)',' (%s)'=>' (%s)','Now!'=>'¡Ahora!','Every %s'=>'Cada %s','Non-repeating'=>'No-repetir','No Scheduled Actions.'=>'No hay acciones programadas.','Set the offset to use for the default action date and time. For information on formatting, see %1$s. For example, you could enter %2$s+1 month%3$s or %2$s+1 week 2 days 4 hours 2 seconds%3$s or %2$snext Thursday%3$s. Please, use only terms in English.'=>'Establece el desplazamiento que se utilizará para la fecha y hora de la acción por defecto. Para obtener información sobre el formato, consulta %1$s. Por ejemplo, puedes introducir %2$s+1 month%3$s or %2$s+1 week 2 days 4 hours 2 seconds%3$s or %2$snext Thursday%3$s. Por favor, introduce solo términos en inglés.','Default Values'=>'Valores por defecto','Use the values below to set the default actions/values to be used for each for the corresponding post types. These values can all be overwritten when creating/editing the post/page.'=>'Utiliza los siguientes valores para establecer las acciones/valores por defecto que se utilizarán para cada uno de los tipos de contenido correspondientes. Estos valores se pueden sobrescribir al crear/editar la publicación/página.','Active'=>'Activa','Activate the PublishPress Future actions for this post type'=>'Activa las acciones de PublishPress Future para este tipo de contenido','Default Action'=>'Acción por defecto','Select the default action for the post type.'=>'Elige la acción de caducidad por defecto para el tipo de contenido.','Select the taxonomy to be used for actions.'=>'Selecciona la taxonomía que se utilizará para las acciones.','Auto-enable'=>'Activación automática','Enabled for all new posts'=>'Activado para todas las nuevas entradas','Taxonomy'=>'Taxonomía','No taxonomies found for this post type. Taxonomy actions will not be available.'=>'No se han encontrado taxonomías para este tipo de entrada. Las acciones de taxonomía no estarán disponibles.','Who to Notify'=>'A quién avisar','Enter a comma separated list of emails that you would like to be notified when the action runs.'=>'Introduce una lista de correos electrónicos separada por comas a los que te gustaría avisar cuando caduque la entrada.','Default Date/Time Offset'=>'Duración por defecto de fecha/hora','PHP strtotime function'=>'Función strtotime de PHP','Default terms:'=>'Términos por defecto:','Save changes'=>'Guardar los cambios','Wait for the validation...'=>'Espera la validación…','Date Preview'=>'Vista previa de la fecha','Current Date'=>'Fecha actual','Computed Date'=>'Fecha calculada','Error'=>'Error','Scheduled Workflow Steps Cleanup'=>'Limpieza de pasos programados del flujo de trabajo','Automatically remove scheduled workflow steps'=>'Eliminar automáticamente los pasos programados del flujo de trabajo','Automatically remove scheduled workflow steps that have been marked as failed, completed, or cancelled.'=>'Eliminar automáticamente los pasos programados del flujo de trabajo que se hayan marcado como fallidos, completados o anulados.','Retain all scheduled workflow steps'=>'Retener todos los pasos programados del flujo de trabajo','Retain all scheduled workflow steps indefinitely, including those marked as failed, completed, or cancelled. This may impact database performance over time.'=>'Retener indefinidamente todos los pasos de flujo de trabajo programados, incluidos los marcados como fallidos, completados o cancelados. Esto puede afectar al rendimiento de la base de datos con el tiempo.','Retention'=>'Retención','The duration, in days, for which completed, failed, and canceled scheduled workflow steps will be preserved before automatic removal.'=>'La duración, en días, durante la cual se conservarán los pasos de flujo de trabajo programados completados, fallidos y anulados antes de su eliminación automática.','days'=>'días','Form Validation Failure: Sorry, your nonce did not verify.'=>'Fallo de validación del formulario: Lo sentimos, tu nonce no ha podido verificarse.','You\'re using PublishPress Future Free. The Pro version has more features and support. %1$sUpgrade to Pro%2$s'=>'Estás usando PublishPress Future Free. La versión Pro tiene más características y soporte. %1$sActualizar a Pro%2$s','Upgrade to Pro'=>'Actualizar a Pro','Workflow Manual Trigger'=>'Disparador del flujo de trabajo','Action Workflows'=>'Flujos de trabajo de acción','Future Workflow'=>'Flujo de trabajo de Future','Add New'=>'Añadir nuevo','Add New Workflow'=>'Añadir nuevo flujo de trabajo','Edit Workflow'=>'Editar flujo de trabajo','New Workflow'=>'Nuevo flujo de trabajo','View Workflow'=>'Ver flujo de trabajo','Search Workflows'=>'Buscar flujos de trabajos','No Workflows found'=>'No se han encontrado flujos de trabajo','No Workflows found in Trash'=>'No se han encontrado flujos de trabajo en la papelera','Parent Workflow:'=>'Flujo de trabajo principal:','All Workflows'=>'Todos los flujos de trabajos','Workflow Archives'=>'Archivos de flujo de trabajo','Insert into workflow'=>'Insertar en el flujo de trabajo','Uploaded to this workflow'=>'Subido a este flujo de trabajo','Filter workflows list'=>'Filtrar la lista de los flujos de trabajos','Workflows list navigation'=>'Navegación de la lista de flujos de trabajos','Action Workflows list'=>'Lista de los flujos de trabajos de acción','Workflow published.'=>'Flujo de trabajo publicado.','Workflow published privately.'=>'Flujo de trabajo publicado como privado.','Workflow reverted to draft.'=>'Flujo de trabajo revertido a borrador.','Workflow scheduled.'=>'Flujo de trabajo programado.','Workflow updated.'=>'Flujo de trabajo actualizado.','Notify when a post is updated'=>'Avisar cuando una entrada está actualizada','Notify the site admin when a post is updated.'=>'Avisar al administrador del sitio cuando una entrada está actualizada.','Unpublish to Draft after a week'=>'Anular la publicación a «Borrador» después de una semana','Change the post status to Draft a week after it was published.'=>'Cambia el estado de la entrada a «Borrador» una semana después de su publicación.','Unpublish and change category after one week'=>'Anular la publicación y cambiar de categoría después de una semana','Move the post to draft and add a category after 15 days.'=>'Mueve la entrada a borrador y añade una categoría después de 15 días.','Add extra categories one month after publishing'=>'Añade categorías adicionales un mes después de la publicación','Sample workflow to add extra categories one month after publishing'=>'Ejemplo de flujo de trabajo para añadir categorías adicionales un mes después de la publicación','Workflow repeating scheduled step'=>'Paso programado de repetición del flujo de trabajo','Workflow scheduled step'=>'Paso programado del flujo de trabajo','Unschedule workflow recurring scheduled step'=>'Desprograma la acción programada recurrente del flujo de trabajo','Cleanup orphan workflow scheduled step arguments'=>'Limpiar argumentos huérfanos del paso programado del flujo de trabajo','Clean up completed scheduled steps older than %d days'=>'Limpiar pasos programados completados de más de %d días','Step not found in workflow.'=>'Paso no encontrado en el flujo de trabajo.','Workflow:'=>'Flujo de trabajo:','Step:'=>'Paso:','Trigger: '=>'Disparador:','Post:'=>'Entrada:','Steps:'=>'Pasos:','Workflow recurring scheduled action'=>'Acción programada recurrente de flujo de trabajo','%1$s until %2$s'=>'%1$s hasta %2$s','%1$s for %2$d times'=>'%1$s por %2$d veces','[%1$s/%2$d]'=>'[%1$s/%2$d]','Welcome to the workflow editor'=>'Bienvenido al editor de flujos de trabajo','In the PublishPress Workflow Editor, each workflow step is presented as a distinct \'node\' in the workflow.'=>'En el editor de flujo de trabajo de PublishPress, cada paso del flujo de trabajo se presenta como un «nodo» distinto en el flujo de trabajo.','Use your imagination'=>'Usa tu imaginación','You\'re free to create very distinct workflows in your site, according to your needs.'=>'Eres libre de crear flujos de trabajo muy distintos en tu sitio, según tus necesidades.','A basic workflow'=>'Un flujo de trabajo básico','Every workflow requires at least two steps connected to each other: one trigger and one action.'=>'Todo flujo de trabajo requiere al menos dos pasos conectados entre sí: un disparador y una acción.','Add steps to your workflow'=>'Añadir pasos a tu flujo de trabajo','Drag and drop steps to add them to your workflow. Connect the steps to create a workflow.'=>'Arrastra y suelta los pasos para añadirlos a tu flujo de trabajo. Conecta los pasos para crear un flujo de trabajo.','Output and input'=>'Salida y entrada','Linked steps can pass data forward as input to the next step.'=>'Los pasos enlazados pueden pasar datos como entrada al siguiente paso.','Customize the workflow'=>'Personalizar el flujo de trabajo','Click on a step to customize it. You can change the step\'s settings in the right sidebar.'=>'Haz clic en un paso para personalizarlo. Puedes cambiar la configuración del paso en la barra lateral derecha.','Workflow validation'=>'Validación del flujo de trabajo','Error messages will appear for any unfilled required settings, missed connections, or invalid values. Select the step to view the corresponding error in the sidebar.'=>'Aparecerán mensajes de error para cualquier ajuste obligatorio sin rellenar, conexiones perdidas o valores no válidos. Selecciona el paso para ver el error correspondiente en la barra lateral.','Publish your workflow'=>'Publica tu flujo de trabajo','When you\'re ready, click the publish button to make your workflow live.'=>'Cuando estés listo, haz clic en el botón «Publicar» para activar tu flujo de trabajo.','Need help?'=>'¿Necesitas ayuda?','If you have any questions or need help, click the help button in the top right corner to access the support resources.'=>'Si tienes alguna duda o necesitas ayuda, haz clic en el botón de ayuda de la esquina superior derecha para acceder a los recursos de soporte.','Triggers'=>'Disparadores','Preview'=>'Vista previa','—'=>'—','No screenshot'=>'Sin captura de pantalla','Activate'=>'Activar','Deactivate'=>'Desactivar','Action Workflow Editor'=>'Editor de flujo de trabajo de acciones','Post Query'=>'Consulta de entrada','A query to select posts'=>'Una consulta para seleccionar las entradas','Yes'=>'Sí','No'=>'No','The workflow was not triggered.'=>'El flujo de trabajo no se ha desencadenado.','The workflow was triggered by the legacy action'=>'El flujo de trabajo se desencadenó por la acción heredada','Trigger workflow'=>'Disparar flujo de trabajo','Move post to status'=>'Mover la entrada a estado','This step transitions a post to a different status.'=>'Este paso mueve una entrada a un estado diferente.','Post'=>'Publicación','The post to update.'=>'La entrada de actualizar.','Select the variable that contains the post to update. It can be a post instance or the post ID.'=>'Selecciona la variable que contiene la entrada a actualizar. Puede ser una instancia de entrada o el ID de la entrada.','The new status that the post will be moved to.'=>'El nuevo estado al que se moverá la entrada.','Step input'=>'Entrada del paso','The input data for this step.'=>'Los datos de entrada para este paso.','Next'=>'Siguiente','Deactivate Workflow for Post'=>'Desactiva el flujo de trabajo para la entrada','This step enables you to deactivate the "Manually enabled via checkbox" workflow after use.'=>'Este paso te permite desactivar el flujo de trabajo «Activado manualmente mediante casilla de verificación» después del uso.','Workflow'=>'Flujo de trabajo','Select the manually enabling workflow that will be deactivated for the selected post.'=>'Selecciona el flujo de trabajo de activación manual que se activará para la entrada seleccionada.','Delete post'=>'Borrar entrada','This step deletes a post.'=>'Este paso borra una entrada.','Stick post'=>'Fijar entrada','This step sticks a post.'=>'Este paso fija una entrada.','The Stick Post action must be part of a Schedule flow'=>'La acción «Fijar entrada» debe formar parte de un flujo de programación.','Add extra terms to post'=>'Añade términos extras a la entrada','This step keeps the current taxonomy terms and adds additional terms.'=>'Este paso mantiene los términos actuales de la taxonomía y añade términos adicionales.','Extra terms'=>'Términos extra','The terms that will be added to the posts.'=>'Los términos que se añadirán a las entradas.','Terms'=>'Términos','Remove terms from the post'=>'Eliminar los términos de la entrada','This step removes current taxonomy terms.'=>'Este paso elimina los términos actuales de la taxonomía.','Terms to remove'=>'Términos de eliminar','The terms that will be removed from the posts.'=>'Los términos que se eliminarán de las entradas.','Remove all terms'=>'Eliminar todos los términos','Replace all terms on the post'=>'Reemplazar todos los términos en la entrada','This step removes the current taxonomy terms and adds new terms.'=>'Este paso elimina los términos actuales de la taxonomía y añade nuevos términos.','New terms'=>'Nuevos términos','The terms that will be added to the posts after removing all the others.'=>'Los términos que se añadirán a las entradas después de remover los otros.','Unstick post'=>'Desvincular entrada','This step unsticks a post.'=>'Este paso desvincula una entrada.','PublishPress Workflow: {{global.workflow.title}}'=>'Flujo de trabajo de PublishPress: {{global.workflow.title}}','This is a message sent by PublishPress Workflow: {{global.workflow.title}}.'=>'Este es un mensaje enviado por el flujo de trabajo de PublishPress: {{global.workflow.title}}.','Send email'=>'Enviar correo electrónico','This step dispatches a message via email.'=>'Este paso envía un mensaje por correo electrónico.','The email message'=>'El mensaje del correo electrónico','Recipient'=>'Destinatario','Subject'=>'Asunto','Email Recipient'=>'Correo electrónico del destinatario','Custom Email Address'=>'Dirección de correo electrónico personalizada','Conditional Split'=>'División condicional','This step allows you to create a conditional branch.'=>'Este paso te permite crear una rama condicional.','Conditions'=>'Condiciones','The conditions that must be met for deciding which branch to take.'=>'Las condiciones que deben cumplirse para decidir qué rama tomar.','Branch'=>'Rama','The current branch on this step.'=>'La rama actual de este paso.','True'=>'Verdadero','False'=>'Falso','Query posts'=>'Consulta de entradas','This step defines the posts that will be passed to the next step in the workflow.'=>'Este paso define las entradas que se pasarán a la acción siguiente en el flujo de trabajo.','Post query'=>'Consulta de entrada','The query defines the posts that will be retrieved by this action.'=>'La consulta define las entradas que serán recuperadas por esta acción.','Post Type'=>'Tipo de entrada','Post ID'=>'ID de la entrada','Array of queried post IDs'=>'Array de IDs de las entradas consultadas','The posts found following the criteria of the query.'=>'Las entradas encontradas siguiendo los criterios de la consulta.','Schedule'=>'Programar','This step enables actions to be scheduled. You can choose when to run the next step.'=>'Este paso permite programar acciones. Puedes elegir cuándo ejecutar el siguiente paso.','A scheduled delay between steps.'=>'Un retraso programado entre pasos.','Date offset'=>'Cambio de fecha','Log - Add'=>'Registro - añadir','This step transmits the flow\'s data to the debug log.'=>'Este paso transmite los datos del flujo al registro de depuración.','Debug output'=>'Salida de la depuración','The message to be sent to the debug log.'=>'El mensaje que se enviará al registro de depuración.','Level'=>'Nivel','Ray - Debug'=>'Depuración Ray','This step transmits the flow\'s data to Ray Debug.'=>'Este paso transmite los datos del flujo a la depuración Ray.','The data to be sent to Ray.'=>'Los datos de enviar a Ray.','Data'=>'Datos','Label'=>'Etiqueta','Color'=>'Color','On admin init'=>'Al inicializar la administración','This trigger activates upon the initialization of the admin site.'=>'Este disparador se activa al inicializar el sitio de administración.','On cron schedule'=>'Con la programación cron','This trigger activates upon a cron schedule, allowing recurrency.'=>'Este disparador se activa según una programación cron, lo que permite la recurrencia.','A schedule to activate the workflow.'=>'Un programa para activar el flujo de trabajo.','On site init'=>'Al inicializar el sitio','This trigger activates upon site initialization.'=>'Este disparador se activa al inicializar el sitio.','Manually enabled via checkbox'=>'Activado manualmente mediante casilla de verificación','This trigger activates when the option is manually enabled. It can be enabled via the post editing screen or the Quick Edit panel.'=>'Este disparador se activa con la opción activada manualmente. Puede activarse a través de la pantalla de edición de entradas o del panel de edición rápida.','Settings for the trigger.'=>'Ajustes para el disparador.','Checkbox label'=>'Etiqueta de casilla de verificación','The label of the checkbox that enables the trigger.'=>'La etiqueta de la casilla de verificación que activa el disparador.','Specify the criteria for posts that will trigger this action. Leave blank to include all posts.'=>'Especifica los criterios para las entradas que activarán esta acción. Déjalo en blanco para incluir todas las entradas.','The query defines the posts that will trigger this action.'=>'La consulta define las entradas que dispararán esta acción.','Saved post'=>'Entrada guardada','The post that was saved, with the new properties.'=>'La entrada se ha guardado con las nuevas propriedades.','Post is updated'=>'Entrada actualizada','This trigger activates when an existing post is updated.'=>'Este disparador se activa cuando se actualiza una entrada existente.','Post Before Update'=>'La entrada antes de la actualización','The post that was saved, with the old properties.'=>'La entrada se ha guardado con las viejas propriedades.','Post After Update'=>'La entrada después de la actualización','Post is saved'=>'Entrada guardada','This trigger activates whenever a post is saved, regardless of whether it\'s newly created, imported, or updated.'=>'Este disparador se activa siempre al guardar una entrada, independientemente de si se acaba de crear, importar o actualizar.','Manually enabled via Future Actions box'=>'Activado manualmente mediante la caja de acciones de Future','This trigger allows users to choose the workflow from the dropdown menu in the Future Actions options.'=>'Este disparador permite a los usuarios elegir el flujo de trabajo en el menú desplegable de las opciones de «Acciones de Future».','Action Post'=>'Entrada de la acción','The post that was saved triggering the action.'=>'La entrada que se guardó y que disparó la acción.','Site'=>'Sitio','Flow Control'=>'Control de flujo','Asynchronous'=>'Asíncrona','Debug'=>'Depurar','Data Query'=>'Consulta de datos','Messages'=>'Mensajes','The ID of the workflow'=>'El ID del flujo de trabajo','The taxonomy name'=>'El nombre de la taxonomía','The post ID'=>'El ID de la entrada','Workflow not found'=>'Flujo de trabajo no encontrado','Loading the workflow editor...'=>'Espera, cargando el editor de flujo de trabajo…','Screenshot'=>'Captura de pantalla','Upgrade to PublishPress Future Pro'=>'Actualizar a PublishPress Future Pro','Enhance the power of PublishPress Future with the Pro version:'=>'Mejora la potencia de PublishPress Future con la versión Pro:','Design custom workflows with multiple actions'=>'Diseña flujo de trabajo con acciones múltiples','Schedule actions based on the post\'s publishing date'=>'Programa la fecha de la acción en función de la fecha de publicación de la entrada','Move posts to custom statuses'=>'Mover entradas a estados personalizados','Use other plugins to control Future Actions'=>'Usa otros plugins para controlar las acciones de "Future"','Enjoy fast and professional support'=>'Disfruta de un soporte rápido y profesional','Need PublishPress Future Support?'=>'¿Necesitas soporte para PublishPress Future?','If you need help or have a new feature request, let us know.'=>'Si necesitas ayuda o tienes una petición de nueva característica, háznoslo saber.','Request Support'=>'Solicitar soporte','Detailed documentation is also available on the plugin website.'=>'También hay disponible una documentación detallada en la web del plugin.','View Knowledge Base'=>'Ver la base de conocimiento','%1$s%2$s%3$s on %5$s%4$s%6$s'=>'%1$s%2$s%3$s el %5$s%4$s%6$s','Action was not scheduled due to a configuration issue. Please attempt to schedule it again.'=>'No se ha podido programar la acción debido a un problema de configuración. Intenta programarla de nuevo.','No future action'=>'Ninguna acción Future','Advanced Options'=>'Opciones avanzadas','Workflow Step Schedule\'s Arguments Compression'=>'Compresión de los argumentos del programa de pasos del flujo de trabajo','Compress the arguments'=>'Comprimir los argumentos','Compress the arguments of the step schedule to save memory in the database, saving them as binary data.'=>'Comprime los argumentos del programa de pasos para ahorrar memoria en la base de datos, guardándolos como datos binarios.','Do not compress the arguments'=>'No comprimir los argumentos','Do not compress the arguments of the step schedule, storing them as plain text.'=>'No comprimir los argumentos del programa de pasos, almacenándolos como texto plano.','Experimental Features'=>'Características experimentales','Enable experimental features'=>'Activar las características experimentales','Enable experimental features that are still in development and may not be fully functional.'=>'Activar las características experimentales que aún están en desarrollo y pueden no ser completamente funcionales.','Preserve Data After Deactivating the Plugin'=>'Preservar datos después de desactivar el plugin','Preserve data'=>'Preservar datos','Delete data'=>'Borrar datos','Toggle between preserving or deleting data after the plugin is deactivated.'=>'Alterna entre preservar o guardar los datos después de desactivar el plugin.','Save Changes'=>'Guardar los cambios','Below is a dump of the debugging table, this should be useful for troubleshooting.'=>'A continuación tienes un volcado de la tabla de depuración, esto debería ser útil para solucionar problemas.','Debugging table is currently empty.'=>'La tabla de depuración está vacía.','Number of logs to display:'=>'Número de registros a visualizar:','Showing the latest %d of %d results. The approximate size of the log is %s.'=>'Mostrando los ultimos %d de %d resultados. El tamaño aproximado del registro es %s.','Showing all %d results. The approximate size of the log is %s.'=>'Mostrando los %d resultados. El tamaño aproximado del registro es %s.','Copy Debug Log'=>'Copiar el registro de depuración','Download Entire Log'=>'Descarga el registro completo','Debug log copied to clipboard!'=>'¡Registro de depuración copiado en el portapapeles!','Advanced Diagnostics and Tools'=>'Herramientas y diagnósticos avanzados','WP-Cron Status Check'=>'Comprobación del estado de WP-Cron','Passed'=>'Aprobado','WP Cron Disabled'=>'WP Cron desactivado','Database Schema Check'=>'Comprobación del esquema de la base de datos','Error found on the database schema:'=>'Se ha detectado un error en el esquema de la base de datos:' . "\0" . 'Se han detectado unos errores en el esquema de la base de datos:','Try to Fix Database'=>'Intentar corregir la base de datos','Debug Logging'=>'Registro de depuración','Enabled'=>'Activado','Disable Debugging'=>'Desactivar depuración','Purge Debug Log'=>'Purgar el registro de depuración','View Debug Logs'=>'Ver registro de depuración','Disabled'=>'Desactivado','Enable Debugging'=>'Activar depuración','Migrate Legacy Future Actions'=>'Migrar las acciones heredadas de Future','Run Migration'=>'Ejecutar migración','Migrate legacy future actions from WP Cron to the new Action Scheduler. This will run in the background and may take a while.'=>'Migrar las acciones heredadas de Future de WP Cron al nuevo Programador de acciones. Esto se ejecutará en segundo plano y puede tomar un tiempo.','Restore Legacy Action Arguments'=>'Restaura los argumentos de acción heredados','Run Data Restoration'=>'Ejecutar la restauración de datos','Restore legacy action arguments as Post Meta. This is useful if you have issues with 3rd party plugins that read that data. This will run in the background and may take a while.'=>'Restaura los argumentos de acción heredados como meta de la entrada. Útil si tienes problemas con plugins de terceros que leen esos datos. Esto se ejecutará en segundo plano y puede tomar un tiempo.','Legacy Cron Schedule'=>'Programación de Cron heredado','The below table will show all currently scheduled cron events for the plugin with the next run time.'=>'La siguiente tabla mostrará todos los eventos cron actualmente programados para el plugin con la próxima hora de ejecución.','Event'=>'Evento','Posts and expiration settings'=>'Ajustes de entradas y caducidad','This is a legacy feature and will be removed in a future version.'=>'Se trata de una característica heredada que se eliminará en una versión futura.','Default Formats'=>'Formatos por defecto','Date Format'=>'Formato de fecha','The default format to use when displaying the action date within a post using the shortcode or within the footer. For information on valid formatting options, see: %s.'=>'El formato por defecto a usar cuando se muestre la fecha de caducidad dentro de una entrada usando el shortcode o dentro del pie de página. Para información sobre las opciones de formato válidas, consulta: %s.','PHP Date Function'=>'Función de fecha PHP','Time Format'=>'Formato de hora','The default format to use when displaying the action time within a post using the shortcode or within the footer. For information on valid formatting options, see: %s.'=>'El formato por defecto a usar cuando se muestre la hora de caducidad dentro de una entrada usando el shortcode o dentro del pie de página. Para información sobre las opciones de formato válidas, consulta: %s.','Future actions column'=>'Columna de acciones de Future','Future Action Column Style'=>'Estilo de columna de «Acción Future»','Detailed'=>'Detallado','Displays all information in the Future Action column.'=>'Muestra toda la información de la columna «Acción de Future».','Simplified'=>'Simplificado','Displays only the icon and date/time.'=>'Muestra solo el icono y la fecha/hora.','Future actions editor'=>'Editor de acciones de Future','Time format in the date picker'=>'Formato de hora en el selector de fecha','Inherit from Site Settings'=>'Heredar desde los ajustes del sitio','24 hours'=>'24 horas','AM/PM'=>'AM/PM','Post Footer Display'=>'Mostrar pie de pagina de la entrada','Enabling this below will display the action date automatically at the end of any post which is set to run an action.'=>'Se mostrará la fecha de caducidad de forma automática al final de cualquier entrada que esté a punto de caducar.','Show in Post Footer?'=>'¿Mostrar en el pie de página de la entrada?','This will enable or disable displaying the future action date in the post footer.'=>'Esto activa o desactiva la visualización de la fecha de caducidad en pie de página.','Footer Contents'=>'Contenidos del pie de página','Enter the text you would like to appear at the bottom of every post which has an action scheduled. The following placeholders will be replaced with the future action date in the following format:'=>'Introduce el texto que deseas que aparezca en la parte inferior de cada entrada con caducidad. Los siguientes marcadores de posición se reemplazarán por la fecha de vencimiento de la entrada en el siguiente formato:','Footer Style'=>'Estilo del pie de página','The inline css which will be used to style the footer text.'=>'El css incrustado que se utilizará para dar estilo al texto del pie de página.','Example: '=>'Ejemplo: ','Shortcode'=>'Shortcode','Valid %s attributes:'=>'Atributos válidos de %s:','%1$stype%2$s - valid options are %1$sfull%2$s (default), %1$sdate%2$s, %1$stime%2$s'=>'%1$stype%2$s - Las opciones válidas son %1$sfull%2$s (por defecto), %1$sdate%2$s y %1$stime%2$s','%s - format set here will override the value set on the settings page'=>'%s - el formato establecido aquí anulará el valor establecido en la página de ajustes','Defaults'=>'Valores por defecto','Calendar Visibility'=>'Visibilidad del calendario','Remember last state'=>'Recordar el último estado','Shows or hides the calendar based on the last user interaction.'=>'Muestra u oculta el calendario en función de la última interacción del usuario.','Always hidden'=>'Siempre ocultado','The calendar is always hidden by default.'=>'El calendario está siempre ocultado por defecto.','Permissions'=>'Permisos','Choose Which User Roles Can Use PublishPress Future'=>'Elige qué perfiles pueden usar PublishPress Fruture','Email Notification'=>'Correo electrónico para notificación del vencimiento','Whenever an action runs, an email can be sent to alert users.'=>'Cuando caduca un post, puede enviarse un correo electrónico alertando a los usuarios del vencimiento.','Enable Email Notification?'=>'¿Activar la notificación por correo electrónico?','This will enable or disable the send of email notification on future action.'=>'Esto activará o desactivará el envío de la notificación por correo electrónico después del vencimiento.','Include Blog Administrators?'=>'¿Incluir a administradores de blog?','This will include all users with the role of "Administrator" in the email.'=>'Esto incluirá a todos los usuarios con el perfil de «Administrador» en el correo electrónico de caducidad de la entrada.','Enter a comma separate list of emails that you would like to be notified when the action runs. This will be applied to ALL post types. You can set post type specific emails on the Defaults tab.'=>'Introduce una lista de correos electrónicos separada por comas a los que te gustaría avisar cuando caduque la entrada. Esto se aplicará a TODOS los tipos de contenido. Puedes establecer correos electrónicos específicos de tipo de contenido en la pestaña de los valores por defecto.','Post Types'=>'Tipos de contenido','General'=>'General','Display'=>'Visualización','Advanced'=>'Avanzado','Diagnostics and Tools'=>'Diagnóstico y herramientas']]; \ No newline at end of file +return ['domain'=>NULL,'plural-forms'=>'nplurals=2; plural=n != 1;','language'=>'es','project-id-version'=>'Plugins - PublishPress Future: Automatically Unpublish WordPress Posts - Stable (latest release)','pot-creation-date'=>'2024-11-19T15:23:53+00:00','po-revision-date'=>'2024-11-20 22:50+0100','x-generator'=>'Poedit 3.4.4','messages'=>['PublishPress Future'=>'PublishPress Future','http://wordpress.org/extend/plugins/post-expirator/'=>'https://es.wordpress.org/plugins/post-expirator/','PublishPress Future allows you to schedule automatic changes to posts, pages and other content types.'=>'PublishPress Future te permite programar cambios automáticos en entradas, páginas y otros tipos de contenido.','PublishPress'=>'PublishPress','http://publishpress.com'=>'https://publishpress.com','You do not have permission to configure PublishPress Future.'=>'No tienes permisos para configurar PublishPress Future.','Debug is disabled'=>'Depuración desactivada','Debugging Disabled'=>'Depuración desactivada','Debugging Enabled'=>'Depuración activada','Debugging Table Emptied'=>'Tabla de depuración vaciada','The legacy future actions migration has been enqueued and will run asynchronously.'=>'La migración de acciones Future heredadas se ha puesto en cola y se ejecutará de forma asíncrona.','The legacy actions arguments restoration has been enqueued and will run asynchronously.'=>'La restauración de los argumentos de las acciones heredadas se ha puesto en cola y se ejecutará de forma asíncrona.','The database schema was fixed.'=>'Se ha corregido el esquema de la base de datos.','The database schema could not be fixed. Please, contact the support team.'=>'No se ha podido corregir el esquema de la base de datos. Por favor, contacta con el equipo de soporte.','Saved Options!'=>'¡Opciones guardadas!','If you like %1$s, please leave us a %2$s rating. Thank you!'=>'Si te gusta %1$s, por favor, déjanos una valoración de %2$s. ¡Gracias!','About PublishPress Future'=>'Acerca de PublishPress Future','About'=>'Acerca de','Future Documentation'=>'Documentación de Future','Documentation'=>'Documentación','Contact the PublishPress team'=>'Contacta con el equipo de PublishPress','Contact'=>'Contacto','No taxonomies found'=>'No se han encontrado taxonomías','l F jS, Y'=>'l, j F Y','g:ia'=>'g:ia','Post expires at EXPIRATIONTIME on ACTIONDATE'=>'La entrada caduca en EXPIRATIONTIME el ACTIONDATE','The table %s does not exist.'=>'La tabla %s no existe.','The table indexes are invalid: '=>'Los índices de la tabla no son válidos: ','Invalid date time offset.'=>'Desplazamiento de fecha y hora no válido.','You do not have sufficient permissions to access this page.'=>'No tienes permisos suficientes para acceder a esta página.','Invalid nonce.'=>'Nonce no válido.','Categories'=>'Categorìas','Future Actions'=>'Acciones Future','Enable Future Action'=>'Activar caducidad de la entrada','Action'=>'Acción','Loading'=>'Cargando','Show Calendar'=>'Muestra el calendario','Hide Calendar'=>'Oculta el calendario','Timezone is controlled by the {WordPress Settings}.'=>'La zona horaria se controla mediante los {Ajustes de WordPress}.','No %s found.'=>'No se ha encontrado %s.','You must assign a taxonomy to this post type to use this feature.'=>'Debe asignar una taxonomía a este tipo de entrada para utilizar esta función.','New %s'=>'Nuevo %s','%s to remove'=>'%s a eliminar','%s to add'=>'%s a añadir','Search for %s'=>'Búsqueda por %s','Select an action'=>'Selecciona una acción','Select a date'=>'Selecciona una fecha','Date cannot be in the past'=>'La fecha no puede estar en el pasado','Please select one or more %s'=>'Por favor, selecciona uno o más %s','New status'=>'Nuevo estado','No posts selected. Unable to sync Future Actions.'=>'No hay entradas seleccionadas. No se pueden sincronizar las acciones de Future.','Future Actions successfully synced with Post Metadata.'=>'Acciones de Future sincronizadas correctamente con los metadatos de la entrada.','Update Future Actions from Post Metadata'=>'Actualiza las acciones de Future a partir de los metadatos de la entrada','Future Action Update'=>'Actualizaciòn de las acciones de Future','— No Change —'=>'— Sin cambios —','Add or update action for posts'=>'Añade o actualiza la acción para las entradas','Add action if none exists for posts'=>'Añade una acción si no hay ninguna para las entradas','Update the existing actions for posts'=>'Actualiza las acciones existentes para las entradas','Remove action from posts'=>'Quitar acción de las entradas','Category'=>'Categorìa','Settings'=>'Ajustes','Future Action'=>'Acción Future','Future'=>'Future','Action Settings'=>'Ajustes de las acciones','Scheduled Actions'=>'Acciones programadas','Log format'=>'Formato del registro','List'=>'Lista','Popup'=>'Ventana emergente','Successfully executed action: %s'=>'Acción ejecutada correctamente: %s','Executed workflow scheduled step'=>'Paso programado del flujo de trabajo ejecutado','Cleaned up completed scheduled steps older than %d days'=>'Se han limpiado los pasos programados completados de más de %d días','Cleaned up orphan workflow scheduled step arguments'=>'Se han limpiado los argumentos huérfanos de los pasos programados del flujo de trabajo','The shortcode [futureaction] must be used inside the loop or with the post_id attribute.'=>'El shortcode [futureaction] debe utilizarse dentro del bucle o con el atributo post_id.','The column args length was not updated to 1000.'=>'La longitud de la columna de argumentos no se actualizó a 1000.','Status didn\'t change.'=>'El estado no ha cambiado.','Status has been successfully changed from "%1$s" to "%2$s".'=>'El estado se ha cambiado correctamente de «%1$s» a «%2$s».','Change status'=>'Cambiar estado','%s was not deleted.'=>'%s no ha sido borrado.','%s has been successfully deleted.'=>'%s ha sido borrado correctamente.','Delete'=>'Borrar','No terms were added to the %s.'=>'No se han añadido términos a la %s.','The following terms (%1$s) were added to the %2$s: "%3$s". The full list of terms on the post is: %4$s.'=>'Los siguientes términos (%1$s) fueron añadidos a la %2$s: «%3$s». La lista completa de términos en la entrada es: %4$s.','Add extra %s'=>'Añadir extra %s','No terms were removed from the %s.'=>'No se han eliminado términos de la %s.','The following terms (%1$s) were removed from the %2$s: %3$s. The new list of terms on the post is: %4$s.'=>'Los siguientes términos (%1$s) fueron eliminados de la %2$s: «%3$s». La nueva lista de términos en la entrada es: %4$s.','Remove selected %s'=>'Eliminar %s seleccionados','The following terms (%1$s) were removed from the %2$s: %3$s.'=>'Los siguientes términos (%1$s) fueron eliminados de la %2$s: «%3$s».','Remove all %s'=>'Eliminar todo %s','No terms were changed on the %s.'=>'No se han modificado los términos en la %s.','The following terms (%1$s) were set to the %2$s: "%3$s". The old list of terms on the post was: %4$s.'=>'Los siguientes términos (%1$s) se establecieron en la %2$s: «%3$s». La antigua lista de términos de la entrada era: %4$s.','Replace all %s'=>'Sustituir todo %s','Change status to %s'=>'Cambia el estado a %s','%s didn\'t change.'=>'%s no ha cambiado.','%s has been added to stickies list.'=>'%s ha sido añadido a la lista de fijos.','Stick'=>'Fijar','%s has been removed from stickies list.'=>'%s ha sido quitado de la lista de fijos.','Unstick'=>'No fijar','Email is disabled.'=>'Correo electrónico desactivado.','Email sent.'=>'Correo electrónico enviado.','Email not sent.'=>'Correo electrónico no enviado.','%1$s. %2$s on %3$s. The post link is %4$s'=>'%1$s. %2$s el día %3$s. El enlace de la entrada es %4$s','Future Action Complete "%s"'=>'Caducidad de la entrada completada «%s»','[%1$s] %2$s'=>'[%1$s] %2$s','Invalid date/time offset "%s" for post type "%s". Please ensure you use only English terms for the date/time offset, such as "3 months" or "1 week".'=>'Desplazamiento fecha/hora «%s» no válido para el tipo de entrada «%s». Asegúrate de utilizar únicamente términos en inglés para el desfase fecha/hora, como «3 months» o «1 week».','Status'=>'Estado','Arguments'=>'Argumentos','Logs'=>'Registros','Scheduled Date'=>'Fecha programada','Recurrence'=>'Recurrente','Run'=>'Ejecutar','Process the action now'=>'Ejecuta la acción ahora','Cancel'=>'Cancelar','Cancel the action. This will prevent the action from running in the future'=>'Cancela la acción. Esto evitará que la acción se ejecute en el futuro','%s year'=>'%s año' . "\0" . '%s años','%s month'=>'%s mes' . "\0" . '%s meses','%s week'=>'%s semana' . "\0" . '%s semanas','%s day'=>'%s día' . "\0" . '%s días','%s hour'=>'%s hora' . "\0" . '%s horas','%s minute'=>'%s minuto' . "\0" . '%s minutos','%s second'=>'%s segundo' . "\0" . '%s segundos','Action Logs'=>'Registro de eventos','Uninitialized'=>'Sin inicializar','Scheduled'=>'Programado','Complete'=>'Completar','Failed'=>'Fallido','Canceled'=>'Cancelado','Running'=>'En curso','All'=>'Todos','Search hook, args and claim ID'=>'Buscar gancho, argumentos e ID de reclamación','Completed'=>'Completado','%1$s: [%2$d] %3$s%4$s%5$s'=>'%1$s: [%2$d] %3$s%4$s%5$s','New Status: %s'=>'Nuevo estado: %s','Terms: %s'=>'Términos: %s','View log'=>'Ver registro','Action: '=>'Acción: ','Status: '=>'Estado: ','Arguments: '=>'Argumentos: ','Scheduled date: '=>'Fecha programada: ','Date'=>'Fecha','Message'=>'Mensaje','Async'=>'Asíncrona',' (%s ago)'=>' (hace %s)',' (%s)'=>' (%s)','Now!'=>'¡Ahora!','Every %s'=>'Cada %s','Non-repeating'=>'No-repetir','No Scheduled Actions.'=>'No hay acciones programadas.','Set the offset to use for the default action date and time. For information on formatting, see %1$s. For example, you could enter %2$s+1 month%3$s or %2$s+1 week 2 days 4 hours 2 seconds%3$s or %2$snext Thursday%3$s. Please, use only terms in English.'=>'Establece el desplazamiento que se utilizará para la fecha y hora de la acción por defecto. Para obtener información sobre el formato, consulta %1$s. Por ejemplo, puedes introducir %2$s+1 month%3$s or %2$s+1 week 2 days 4 hours 2 seconds%3$s or %2$snext Thursday%3$s. Por favor, introduce solo términos en inglés.','Default Values'=>'Valores por defecto','Use the values below to set the default actions/values to be used for each for the corresponding post types. These values can all be overwritten when creating/editing the post/page.'=>'Utiliza los siguientes valores para establecer las acciones/valores por defecto que se utilizarán para cada uno de los tipos de contenido correspondientes. Estos valores se pueden sobrescribir al crear/editar la publicación/página.','Active'=>'Activa','Activate the PublishPress Future actions for this post type'=>'Activa las acciones de PublishPress Future para este tipo de contenido','Default Action'=>'Acción por defecto','Select the default action for the post type.'=>'Elige la acción de caducidad por defecto para el tipo de contenido.','Select the taxonomy to be used for actions.'=>'Selecciona la taxonomía que se utilizará para las acciones.','Auto-enable'=>'Activación automática','Enabled for all new posts'=>'Activado para todas las nuevas entradas','Taxonomy'=>'Taxonomía','No taxonomies found for this post type. Taxonomy actions will not be available.'=>'No se han encontrado taxonomías para este tipo de entrada. Las acciones de taxonomía no estarán disponibles.','Who to Notify'=>'A quién avisar','Enter a comma separated list of emails that you would like to be notified when the action runs.'=>'Introduce una lista de correos electrónicos separada por comas a los que te gustaría avisar cuando caduque la entrada.','Default Date/Time Offset'=>'Duración por defecto de fecha/hora','PHP strtotime function'=>'Función strtotime de PHP','Default terms:'=>'Términos por defecto:','Save changes'=>'Guardar los cambios','Wait for the validation...'=>'Espera la validación…','Date Preview'=>'Vista previa de la fecha','Current Date'=>'Fecha actual','Computed Date'=>'Fecha calculada','Error'=>'Error','Scheduled Workflow Steps Cleanup'=>'Limpieza de pasos programados del flujo de trabajo','Automatically remove scheduled workflow steps'=>'Eliminar automáticamente los pasos programados del flujo de trabajo','Automatically remove scheduled workflow steps that have been marked as failed, completed, or cancelled.'=>'Eliminar automáticamente los pasos programados del flujo de trabajo que se hayan marcado como fallidos, completados o anulados.','Retain all scheduled workflow steps'=>'Retener todos los pasos programados del flujo de trabajo','Retain all scheduled workflow steps indefinitely, including those marked as failed, completed, or cancelled. This may impact database performance over time.'=>'Retener indefinidamente todos los pasos de flujo de trabajo programados, incluidos los marcados como fallidos, completados o cancelados. Esto puede afectar al rendimiento de la base de datos con el tiempo.','Retention'=>'Retención','The duration, in days, for which completed, failed, and canceled scheduled workflow steps will be preserved before automatic removal.'=>'La duración, en días, durante la cual se conservarán los pasos de flujo de trabajo programados completados, fallidos y anulados antes de su eliminación automática.','days'=>'días','Form Validation Failure: Sorry, your nonce did not verify.'=>'Fallo de validación del formulario: Lo sentimos, tu nonce no ha podido verificarse.','You\'re using PublishPress Future Free. The Pro version has more features and support. %1$sUpgrade to Pro%2$s'=>'Estás usando PublishPress Future Free. La versión Pro tiene más características y soporte. %1$sActualizar a Pro%2$s','Upgrade to Pro'=>'Actualizar a Pro','Workflow Manual Trigger'=>'Disparador del flujo de trabajo','Action Workflows'=>'Flujos de trabajo de acción','Future Workflow'=>'Flujo de trabajo de Future','Add New'=>'Añadir nuevo','Add New Workflow'=>'Añadir nuevo flujo de trabajo','Edit Workflow'=>'Editar flujo de trabajo','New Workflow'=>'Nuevo flujo de trabajo','View Workflow'=>'Ver flujo de trabajo','Search Workflows'=>'Buscar flujos de trabajos','No Workflows found'=>'No se han encontrado flujos de trabajo','No Workflows found in Trash'=>'No se han encontrado flujos de trabajo en la papelera','Parent Workflow:'=>'Flujo de trabajo principal:','All Workflows'=>'Todos los flujos de trabajos','Workflow Archives'=>'Archivos de flujo de trabajo','Insert into workflow'=>'Insertar en el flujo de trabajo','Uploaded to this workflow'=>'Subido a este flujo de trabajo','Filter workflows list'=>'Filtrar la lista de los flujos de trabajos','Workflows list navigation'=>'Navegación de la lista de flujos de trabajos','Action Workflows list'=>'Lista de los flujos de trabajos de acción','Workflow published.'=>'Flujo de trabajo publicado.','Workflow published privately.'=>'Flujo de trabajo publicado como privado.','Workflow reverted to draft.'=>'Flujo de trabajo revertido a borrador.','Workflow scheduled.'=>'Flujo de trabajo programado.','Workflow updated.'=>'Flujo de trabajo actualizado.','Notify when a post is updated'=>'Avisar cuando una entrada está actualizada','Notify the site admin when a post is updated.'=>'Avisar al administrador del sitio cuando una entrada está actualizada.','Unpublish to Draft after a week'=>'Anular la publicación a «Borrador» después de una semana','Change the post status to Draft a week after it was published.'=>'Cambia el estado de la entrada a «Borrador» una semana después de su publicación.','Unpublish and change category after one week'=>'Anular la publicación y cambiar de categoría después de una semana','Move the post to draft and add a category after 15 days.'=>'Mueve la entrada a borrador y añade una categoría después de 15 días.','Add extra categories one month after publishing'=>'Añade categorías adicionales un mes después de la publicación','Sample workflow to add extra categories one month after publishing'=>'Ejemplo de flujo de trabajo para añadir categorías adicionales un mes después de la publicación','Workflow repeating scheduled step'=>'Paso programado de repetición del flujo de trabajo','Workflow scheduled step'=>'Paso programado del flujo de trabajo','Unschedule workflow recurring scheduled step'=>'Desprograma la acción programada recurrente del flujo de trabajo','Cleanup orphan workflow scheduled step arguments'=>'Limpiar argumentos huérfanos del paso programado del flujo de trabajo','Clean up completed scheduled steps older than %d days'=>'Limpiar pasos programados completados de más de %d días','Step not found in workflow.'=>'Paso no encontrado en el flujo de trabajo.','Workflow:'=>'Flujo de trabajo:','Step:'=>'Paso:','Trigger: '=>'Disparador:','Post:'=>'Entrada:','Steps:'=>'Pasos:','Workflow recurring scheduled action'=>'Acción programada recurrente de flujo de trabajo','%1$s until %2$s'=>'%1$s hasta %2$s','%1$s for %2$d times'=>'%1$s por %2$d veces','[%1$s/%2$d]'=>'[%1$s/%2$d]','Welcome to the workflow editor'=>'Bienvenido al editor de flujos de trabajo','In the PublishPress Workflow Editor, each workflow step is presented as a distinct \'node\' in the workflow.'=>'En el editor de flujo de trabajo de PublishPress, cada paso del flujo de trabajo se presenta como un «nodo» distinto en el flujo de trabajo.','Use your imagination'=>'Usa tu imaginación','You\'re free to create very distinct workflows in your site, according to your needs.'=>'Eres libre de crear flujos de trabajo muy distintos en tu sitio, según tus necesidades.','A basic workflow'=>'Un flujo de trabajo básico','Every workflow requires at least two steps connected to each other: one trigger and one action.'=>'Todo flujo de trabajo requiere al menos dos pasos conectados entre sí: un disparador y una acción.','Add steps to your workflow'=>'Añadir pasos a tu flujo de trabajo','Drag and drop steps to add them to your workflow. Connect the steps to create a workflow.'=>'Arrastra y suelta los pasos para añadirlos a tu flujo de trabajo. Conecta los pasos para crear un flujo de trabajo.','Output and input'=>'Salida y entrada','Linked steps can pass data forward as input to the next step.'=>'Los pasos enlazados pueden pasar datos como entrada al siguiente paso.','Customize the workflow'=>'Personalizar el flujo de trabajo','Click on a step to customize it. You can change the step\'s settings in the right sidebar.'=>'Haz clic en un paso para personalizarlo. Puedes cambiar la configuración del paso en la barra lateral derecha.','Workflow validation'=>'Validación del flujo de trabajo','Error messages will appear for any unfilled required settings, missed connections, or invalid values. Select the step to view the corresponding error in the sidebar.'=>'Aparecerán mensajes de error para cualquier ajuste obligatorio sin rellenar, conexiones perdidas o valores no válidos. Selecciona el paso para ver el error correspondiente en la barra lateral.','Publish your workflow'=>'Publica tu flujo de trabajo','When you\'re ready, click the publish button to make your workflow live.'=>'Cuando estés listo, haz clic en el botón «Publicar» para activar tu flujo de trabajo.','Need help?'=>'¿Necesitas ayuda?','If you have any questions or need help, click the help button in the top right corner to access the support resources.'=>'Si tienes alguna duda o necesitas ayuda, haz clic en el botón de ayuda de la esquina superior derecha para acceder a los recursos de soporte.','Triggers'=>'Disparadores','Preview'=>'Vista previa','—'=>'—','No screenshot'=>'Sin captura de pantalla','Activate'=>'Activar','Deactivate'=>'Desactivar','Action Workflow Editor'=>'Editor de flujo de trabajo de acciones','Post Query'=>'Consulta de entrada','A query to select posts'=>'Una consulta para seleccionar las entradas','Yes'=>'Sí','No'=>'No','The workflow was not triggered.'=>'El flujo de trabajo no se ha desencadenado.','The workflow was triggered by the legacy action'=>'El flujo de trabajo se desencadenó por la acción heredada','Trigger workflow'=>'Disparar flujo de trabajo','Move post to status'=>'Mover la entrada a estado','This step transitions a post to a different status.'=>'Este paso mueve una entrada a un estado diferente.','Post'=>'Publicación','The post to update.'=>'La entrada de actualizar.','Select the variable that contains the post to update. It can be a post instance or the post ID.'=>'Selecciona la variable que contiene la entrada a actualizar. Puede ser una instancia de entrada o el ID de la entrada.','The new status that the post will be moved to.'=>'El nuevo estado al que se moverá la entrada.','Step input'=>'Entrada del paso','The input data for this step.'=>'Los datos de entrada para este paso.','Next'=>'Siguiente','Deactivate Workflow for Post'=>'Desactiva el flujo de trabajo para la entrada','This step enables you to deactivate the "Manually enabled via checkbox" workflow after use.'=>'Este paso te permite desactivar el flujo de trabajo «Activado manualmente mediante casilla de verificación» después del uso.','Workflow'=>'Flujo de trabajo','Select the manually enabling workflow that will be deactivated for the selected post.'=>'Selecciona el flujo de trabajo de activación manual que se activará para la entrada seleccionada.','Delete post'=>'Borrar entrada','This step deletes a post.'=>'Este paso borra una entrada.','Stick post'=>'Fijar entrada','This step sticks a post.'=>'Este paso fija una entrada.','The Stick Post action must be part of a Schedule flow'=>'La acción «Fijar entrada» debe formar parte de un flujo de programación.','Add extra terms to post'=>'Añade términos extras a la entrada','This step keeps the current taxonomy terms and adds additional terms.'=>'Este paso mantiene los términos actuales de la taxonomía y añade términos adicionales.','Extra terms'=>'Términos extra','The terms that will be added to the posts.'=>'Los términos que se añadirán a las entradas.','Terms'=>'Términos','Remove terms from the post'=>'Eliminar los términos de la entrada','This step removes current taxonomy terms.'=>'Este paso elimina los términos actuales de la taxonomía.','Terms to remove'=>'Términos de eliminar','The terms that will be removed from the posts.'=>'Los términos que se eliminarán de las entradas.','Remove all terms'=>'Eliminar todos los términos','Replace all terms on the post'=>'Reemplazar todos los términos en la entrada','This step removes the current taxonomy terms and adds new terms.'=>'Este paso elimina los términos actuales de la taxonomía y añade nuevos términos.','New terms'=>'Nuevos términos','The terms that will be added to the posts after removing all the others.'=>'Los términos que se añadirán a las entradas después de remover los otros.','Unstick post'=>'Desvincular entrada','This step unsticks a post.'=>'Este paso desvincula una entrada.','PublishPress Workflow: {{global.workflow.title}}'=>'Flujo de trabajo de PublishPress: {{global.workflow.title}}','This is a message sent by PublishPress Workflow: {{global.workflow.title}}.'=>'Este es un mensaje enviado por el flujo de trabajo de PublishPress: {{global.workflow.title}}.','Send email'=>'Enviar correo electrónico','This step dispatches a message via email.'=>'Este paso envía un mensaje por correo electrónico.','The email message'=>'El mensaje del correo electrónico','Recipient'=>'Destinatario','Subject'=>'Asunto','Email Recipient'=>'Correo electrónico del destinatario','Custom Email Address'=>'Dirección de correo electrónico personalizada','Conditional Split'=>'División condicional','This step allows you to create a conditional branch.'=>'Este paso te permite crear una rama condicional.','Conditions'=>'Condiciones','The conditions that must be met for deciding which branch to take.'=>'Las condiciones que deben cumplirse para decidir qué rama tomar.','Branch'=>'Rama','The current branch on this step.'=>'La rama actual de este paso.','True'=>'Verdadero','False'=>'Falso','Query posts'=>'Consulta de entradas','This step defines the posts that will be passed to the next step in the workflow.'=>'Este paso define las entradas que se pasarán a la acción siguiente en el flujo de trabajo.','Post query'=>'Consulta de entrada','The query defines the posts that will be retrieved by this action.'=>'La consulta define las entradas que serán recuperadas por esta acción.','Post Type'=>'Tipo de entrada','Post ID'=>'ID de la entrada','Array of queried post IDs'=>'Array de IDs de las entradas consultadas','The posts found following the criteria of the query.'=>'Las entradas encontradas siguiendo los criterios de la consulta.','Schedule'=>'Programar','This step enables actions to be scheduled. You can choose when to run the next step.'=>'Este paso permite programar acciones. Puedes elegir cuándo ejecutar el siguiente paso.','A scheduled delay between steps.'=>'Un retraso programado entre pasos.','Date offset'=>'Cambio de fecha','Log - Add'=>'Registro - añadir','This step transmits the flow\'s data to the debug log.'=>'Este paso transmite los datos del flujo al registro de depuración.','Debug output'=>'Salida de la depuración','The message to be sent to the debug log.'=>'El mensaje que se enviará al registro de depuración.','Level'=>'Nivel','Ray - Debug'=>'Depuración Ray','This step transmits the flow\'s data to Ray Debug.'=>'Este paso transmite los datos del flujo a la depuración Ray.','The data to be sent to Ray.'=>'Los datos de enviar a Ray.','Data'=>'Datos','Label'=>'Etiqueta','Color'=>'Color','On admin init'=>'Al inicializar la administración','This trigger activates upon the initialization of the admin site.'=>'Este disparador se activa al inicializar el sitio de administración.','On cron schedule'=>'Con la programación cron','This trigger activates upon a cron schedule, allowing recurrency.'=>'Este disparador se activa según una programación cron, lo que permite la recurrencia.','A schedule to activate the workflow.'=>'Un programa para activar el flujo de trabajo.','On site init'=>'Al inicializar el sitio','This trigger activates upon site initialization.'=>'Este disparador se activa al inicializar el sitio.','Manually enabled via checkbox'=>'Activado manualmente mediante casilla de verificación','This trigger activates when the option is manually enabled. It can be enabled via the post editing screen or the Quick Edit panel.'=>'Este disparador se activa con la opción activada manualmente. Puede activarse a través de la pantalla de edición de entradas o del panel de edición rápida.','Settings for the trigger.'=>'Ajustes para el disparador.','Checkbox label'=>'Etiqueta de casilla de verificación','The label of the checkbox that enables the trigger.'=>'La etiqueta de la casilla de verificación que activa el disparador.','Specify the criteria for posts that will trigger this action. Leave blank to include all posts.'=>'Especifica los criterios para las entradas que activarán esta acción. Déjalo en blanco para incluir todas las entradas.','The query defines the posts that will trigger this action.'=>'La consulta define las entradas que dispararán esta acción.','Saved post'=>'Entrada guardada','The post that was saved, with the new properties.'=>'La entrada se ha guardado con las nuevas propriedades.','Post is updated'=>'Entrada actualizada','This trigger activates when an existing post is updated.'=>'Este disparador se activa cuando se actualiza una entrada existente.','Post Before Update'=>'La entrada antes de la actualización','The post that was saved, with the old properties.'=>'La entrada se ha guardado con las viejas propriedades.','Post After Update'=>'La entrada después de la actualización','Post is saved'=>'Entrada guardada','This trigger activates whenever a post is saved, regardless of whether it\'s newly created, imported, or updated.'=>'Este disparador se activa siempre al guardar una entrada, independientemente de si se acaba de crear, importar o actualizar.','Manually enabled via Future Actions box'=>'Activado manualmente mediante la caja de acciones de Future','This trigger allows users to choose the workflow from the dropdown menu in the Future Actions options.'=>'Este disparador permite a los usuarios elegir el flujo de trabajo en el menú desplegable de las opciones de «Acciones de Future».','Action Post'=>'Entrada de la acción','The post that was saved triggering the action.'=>'La entrada que se guardó y que disparó la acción.','Site'=>'Sitio','Flow Control'=>'Control de flujo','Asynchronous'=>'Asíncrona','Debug'=>'Depurar','Data Query'=>'Consulta de datos','Messages'=>'Mensajes','The ID of the workflow'=>'El ID del flujo de trabajo','The taxonomy name'=>'El nombre de la taxonomía','The post ID'=>'El ID de la entrada','Workflow not found'=>'Flujo de trabajo no encontrado','Loading the workflow editor...'=>'Espera, cargando el editor de flujo de trabajo…','Screenshot'=>'Captura de pantalla','Upgrade to PublishPress Future Pro'=>'Actualizar a PublishPress Future Pro','Enhance the power of PublishPress Future with the Pro version:'=>'Mejora la potencia de PublishPress Future con la versión Pro:','Design custom workflows with multiple actions'=>'Diseña flujo de trabajo con acciones múltiples','Schedule actions based on the post\'s publishing date'=>'Programa la fecha de la acción en función de la fecha de publicación de la entrada','Move posts to custom statuses'=>'Mover entradas a estados personalizados','Use other plugins to control Future Actions'=>'Usa otros plugins para controlar las acciones de "Future"','Enjoy fast and professional support'=>'Disfruta de un soporte rápido y profesional','Need PublishPress Future Support?'=>'¿Necesitas soporte para PublishPress Future?','If you need help or have a new feature request, let us know.'=>'Si necesitas ayuda o tienes una petición de nueva característica, háznoslo saber.','Request Support'=>'Solicitar soporte','Detailed documentation is also available on the plugin website.'=>'También hay disponible una documentación detallada en la web del plugin.','View Knowledge Base'=>'Ver la base de conocimiento','%1$s%2$s%3$s on %5$s%4$s%6$s'=>'%1$s%2$s%3$s el %5$s%4$s%6$s','Action was not scheduled due to a configuration issue. Please attempt to schedule it again.'=>'No se ha podido programar la acción debido a un problema de configuración. Intenta programarla de nuevo.','No future action'=>'Ninguna acción Future','Advanced Options'=>'Opciones avanzadas','Workflow Step Schedule\'s Arguments Compression'=>'Compresión de los argumentos del programa de pasos del flujo de trabajo','Compress the arguments'=>'Comprimir los argumentos','Compress the arguments of the step schedule to save memory in the database, saving them as binary data.'=>'Comprime los argumentos del programa de pasos para ahorrar memoria en la base de datos, guardándolos como datos binarios.','Do not compress the arguments'=>'No comprimir los argumentos','Do not compress the arguments of the step schedule, storing them as plain text.'=>'No comprimir los argumentos del programa de pasos, almacenándolos como texto plano.','Experimental Features'=>'Características experimentales','Enable experimental features'=>'Activar las características experimentales','Enable experimental features that are still in development and may not be fully functional.'=>'Activar las características experimentales que aún están en desarrollo y pueden no ser completamente funcionales.','Preserve Data After Deactivating the Plugin'=>'Preservar datos después de desactivar el plugin','Preserve data'=>'Preservar datos','Delete data'=>'Borrar datos','Toggle between preserving or deleting data after the plugin is deactivated.'=>'Alterna entre preservar o guardar los datos después de desactivar el plugin.','Save Changes'=>'Guardar los cambios','Below is a dump of the debugging table, this should be useful for troubleshooting.'=>'A continuación tienes un volcado de la tabla de depuración, esto debería ser útil para solucionar problemas.','Debugging table is currently empty.'=>'La tabla de depuración está vacía.','Number of logs to display:'=>'Número de registros a visualizar:','Showing the latest %d of %d results. The approximate size of the log is %s.'=>'Mostrando los ultimos %d de %d resultados. El tamaño aproximado del registro es %s.','Showing all %d results. The approximate size of the log is %s.'=>'Mostrando los %d resultados. El tamaño aproximado del registro es %s.','Copy Debug Log'=>'Copiar el registro de depuración','Download Entire Log'=>'Descarga el registro completo','Debug log copied to clipboard!'=>'¡Registro de depuración copiado en el portapapeles!','Advanced Diagnostics and Tools'=>'Herramientas y diagnósticos avanzados','WP-Cron Status Check'=>'Comprobación del estado de WP-Cron','Passed'=>'Aprobado','WP Cron Disabled'=>'WP Cron desactivado','Database Schema Check'=>'Comprobación del esquema de la base de datos','Error found on the database schema:'=>'Se ha detectado un error en el esquema de la base de datos:' . "\0" . 'Se han detectado unos errores en el esquema de la base de datos:','Try to Fix Database'=>'Intentar corregir la base de datos','Debug Logging'=>'Registro de depuración','Enabled'=>'Activado','Disable Debugging'=>'Desactivar depuración','Purge Debug Log'=>'Purgar el registro de depuración','View Debug Logs'=>'Ver registro de depuración','Disabled'=>'Desactivado','Enable Debugging'=>'Activar depuración','Migrate Legacy Future Actions'=>'Migrar las acciones heredadas de Future','Run Migration'=>'Ejecutar migración','Migrate legacy future actions from WP Cron to the new Action Scheduler. This will run in the background and may take a while.'=>'Migrar las acciones heredadas de Future de WP Cron al nuevo Programador de acciones. Esto se ejecutará en segundo plano y puede tomar un tiempo.','Restore Legacy Action Arguments'=>'Restaura los argumentos de acción heredados','Run Data Restoration'=>'Ejecutar la restauración de datos','Restore legacy action arguments as Post Meta. This is useful if you have issues with 3rd party plugins that read that data. This will run in the background and may take a while.'=>'Restaura los argumentos de acción heredados como meta de la entrada. Útil si tienes problemas con plugins de terceros que leen esos datos. Esto se ejecutará en segundo plano y puede tomar un tiempo.','Legacy Cron Schedule'=>'Programación de Cron heredado','The below table will show all currently scheduled cron events for the plugin with the next run time.'=>'La siguiente tabla mostrará todos los eventos cron actualmente programados para el plugin con la próxima hora de ejecución.','Event'=>'Evento','Posts and expiration settings'=>'Ajustes de entradas y caducidad','This is a legacy feature and will be removed in a future version.'=>'Se trata de una característica heredada que se eliminará en una versión futura.','Default Formats'=>'Formatos por defecto','Date Format'=>'Formato de fecha','The default format to use when displaying the action date within a post using the shortcode or within the footer. For information on valid formatting options, see: %s.'=>'El formato por defecto a usar cuando se muestre la fecha de caducidad dentro de una entrada usando el shortcode o dentro del pie de página. Para información sobre las opciones de formato válidas, consulta: %s.','PHP Date Function'=>'Función de fecha PHP','Time Format'=>'Formato de hora','The default format to use when displaying the action time within a post using the shortcode or within the footer. For information on valid formatting options, see: %s.'=>'El formato por defecto a usar cuando se muestre la hora de caducidad dentro de una entrada usando el shortcode o dentro del pie de página. Para información sobre las opciones de formato válidas, consulta: %s.','Future Actions Column'=>'Columna de acciones de Future','Future Action Column Style'=>'Estilo de columna de «Acción Future»','Detailed'=>'Detallado','Displays all information in the Future Action column.'=>'Muestra toda la información de la columna «Acción de Future».','Simplified'=>'Simplificado','Displays only the icon and date/time.'=>'Muestra solo el icono y la fecha/hora.','Future Actions Editor'=>'Editor de acciones de Future','Time format in the date picker'=>'Formato de hora en el selector de fecha','Inherit from Site Settings'=>'Heredar desde los ajustes del sitio','24 hours'=>'24 horas','AM/PM'=>'AM/PM','Post Footer Display'=>'Mostrar pie de pagina de la entrada','Enabling this below will display the action date automatically at the end of any post which is set to run an action.'=>'Se mostrará la fecha de caducidad de forma automática al final de cualquier entrada que esté a punto de caducar.','Show in Post Footer?'=>'¿Mostrar en el pie de página de la entrada?','This will enable or disable displaying the future action date in the post footer.'=>'Esto activa o desactiva la visualización de la fecha de caducidad en pie de página.','Footer Contents'=>'Contenidos del pie de página','Enter the text you would like to appear at the bottom of every post which has an action scheduled. The following placeholders will be replaced with the future action date in the following format:'=>'Introduce el texto que deseas que aparezca en la parte inferior de cada entrada con caducidad. Los siguientes marcadores de posición se reemplazarán por la fecha de vencimiento de la entrada en el siguiente formato:','Footer Style'=>'Estilo del pie de página','The inline css which will be used to style the footer text.'=>'El css incrustado que se utilizará para dar estilo al texto del pie de página.','Example: '=>'Ejemplo: ','Shortcode'=>'Shortcode','Valid %s attributes:'=>'Atributos válidos de %s:','%1$stype%2$s - valid options are %1$sfull%2$s (default), %1$sdate%2$s, %1$stime%2$s'=>'%1$stype%2$s - Las opciones válidas son %1$sfull%2$s (por defecto), %1$sdate%2$s y %1$stime%2$s','%s - format set here will override the value set on the settings page'=>'%s - el formato establecido aquí anulará el valor establecido en la página de ajustes','Defaults'=>'Valores por defecto','Calendar Visibility'=>'Visibilidad del calendario','Remember last state'=>'Recordar el último estado','Shows or hides the calendar based on the last user interaction.'=>'Muestra u oculta el calendario en función de la última interacción del usuario.','Always hidden'=>'Siempre ocultado','The calendar is always hidden by default.'=>'El calendario está siempre ocultado por defecto.','Permissions'=>'Permisos','Choose Which User Roles Can Use PublishPress Future'=>'Elige qué perfiles pueden usar PublishPress Fruture','Email Notification'=>'Correo electrónico para notificación del vencimiento','Whenever an action runs, an email can be sent to alert users.'=>'Cuando caduca un post, puede enviarse un correo electrónico alertando a los usuarios del vencimiento.','Enable Email Notification?'=>'¿Activar la notificación por correo electrónico?','This will enable or disable the send of email notification on future action.'=>'Esto activará o desactivará el envío de la notificación por correo electrónico después del vencimiento.','Include Blog Administrators?'=>'¿Incluir a administradores de blog?','This will include all users with the role of "Administrator" in the email.'=>'Esto incluirá a todos los usuarios con el perfil de «Administrador» en el correo electrónico de caducidad de la entrada.','Enter a comma separate list of emails that you would like to be notified when the action runs. This will be applied to ALL post types. You can set post type specific emails on the Defaults tab.'=>'Introduce una lista de correos electrónicos separada por comas a los que te gustaría avisar cuando caduque la entrada. Esto se aplicará a TODOS los tipos de contenido. Puedes establecer correos electrónicos específicos de tipo de contenido en la pestaña de los valores por defecto.','Post Types'=>'Tipos de contenido','General'=>'General','Display'=>'Visualización','Advanced'=>'Avanzado','Diagnostics and Tools'=>'Diagnóstico y herramientas']]; \ No newline at end of file diff --git a/languages/post-expirator-es_ES.mo b/languages/post-expirator-es_ES.mo index 2098961a80adfc5e9c7ab4902806d552b7ce578c..d2b031eede830d7d3981afa65ad6549caf10d1e0 100644 GIT binary patch delta 146 zcmaFylptF1v0-^ zF)+vgY0+v127e%J1f(T^bQ6%40@AZLD~g_!m2u9`Db3Aea4Rh-ElO2zOfJdH&ns4N hP01|DFPePID0XwQ@f7#T)z#LMzgM+v-d1g74gfx5CgT7A delta 161 zcmaFyl|p-S2Hk30qF!FEeoWpfwT;ep1E03^rY-$F=JnCx6+c*qEv;%D{cS) diff --git a/languages/post-expirator-es_ES.po b/languages/post-expirator-es_ES.po index a4389a17f..8d668e59e 100644 --- a/languages/post-expirator-es_ES.po +++ b/languages/post-expirator-es_ES.po @@ -2325,7 +2325,7 @@ msgstr "" "información sobre las opciones de formato válidas, consulta: %s." #: src/Views/menu-display.php:80 -msgid "Future actions column" +msgid "Future Actions Column" msgstr "Columna de acciones de Future" #: src/Views/menu-display.php:84 @@ -2349,7 +2349,7 @@ msgid "Displays only the icon and date/time." msgstr "Muestra solo el icono y la fecha/hora." #: src/Views/menu-display.php:123 -msgid "Future actions editor" +msgid "Future Actions Editor" msgstr "Editor de acciones de Future" #: src/Views/menu-display.php:127 diff --git a/languages/post-expirator-fr_FR-future_backup_panel.json b/languages/post-expirator-fr_FR-future_backup_panel.json new file mode 100644 index 000000000..d20431cf4 --- /dev/null +++ b/languages/post-expirator-fr_FR-future_backup_panel.json @@ -0,0 +1 @@ +{"domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"","plural_forms":""},"Backup":[""]}}} \ No newline at end of file diff --git a/languages/post-expirator-fr_FR-future_backup_panel.l10n.php b/languages/post-expirator-fr_FR-future_backup_panel.l10n.php new file mode 100644 index 000000000..a87d71a20 --- /dev/null +++ b/languages/post-expirator-fr_FR-future_backup_panel.l10n.php @@ -0,0 +1,2 @@ +NULL,'plural-forms'=>NULL,'language'=>'','project-id-version'=>'','pot-creation-date'=>'2024-11-27T18:46:34+00:00','po-revision-date'=>'2024-11-27T18:46:34+00:00','messages'=>[]]; \ No newline at end of file diff --git a/languages/post-expirator-fr_FR-future_backup_panel.po b/languages/post-expirator-fr_FR-future_backup_panel.po new file mode 100644 index 000000000..15296d543 --- /dev/null +++ b/languages/post-expirator-fr_FR-future_backup_panel.po @@ -0,0 +1,16 @@ +msgid "" +msgstr "" +"Project-Id-Version: \n" +"Report-Msgid-Bugs-To: \n" +"Last-Translator: \n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"POT-Creation-Date: 2024-11-27T18:46:34+00:00\n" +"PO-Revision-Date: 2024-11-27T18:46:34+00:00\n" +"Language: \n" + +#: components/BackupPanel.jsx:6 +msgid "Backup" +msgstr "" diff --git a/languages/post-expirator-fr_FR.l10n.php b/languages/post-expirator-fr_FR.l10n.php index 02edd630c..94979c7d2 100644 --- a/languages/post-expirator-fr_FR.l10n.php +++ b/languages/post-expirator-fr_FR.l10n.php @@ -1,2 +1,2 @@ NULL,'plural-forms'=>'nplurals=2; plural=n > 1;','language'=>'fr','project-id-version'=>'Plugins - PublishPress Future: Automatically Unpublish WordPress Posts - Stable (latest release)','pot-creation-date'=>'2024-11-19T15:23:53+00:00','po-revision-date'=>'2024-11-20 22:57+0100','x-generator'=>'Poedit 3.4.4','messages'=>['PublishPress Future'=>'PublishPress Future','http://wordpress.org/extend/plugins/post-expirator/'=>'http://wordpress.org/extend/plugins/post-expirator/','PublishPress Future allows you to schedule automatic changes to posts, pages and other content types.'=>'PublishPress Future vous permet de planifier des changements automatiques sur les publications, les pages et d’autres types de publication.','PublishPress'=>'PublishPress','http://publishpress.com'=>'http://publishpress.com','You do not have permission to configure PublishPress Future.'=>'Vous n’avez pas les droits nécessaires pour configurer PublishPress Future.','Debug is disabled'=>'Débogage désactivé','Debugging Disabled'=>'Débogage désactivé','Debugging Enabled'=>'Débogage activé','Debugging Table Emptied'=>'Table de débogage vidée','The legacy future actions migration has been enqueued and will run asynchronously.'=>'La migration des actions Future héritées a été mise en file d’attente et s’exécutera de manière asynchrone.','The legacy actions arguments restoration has been enqueued and will run asynchronously.'=>'La restauration des arguments des actions héritées a été mise en file d’attente et s’exécutera de manière asynchrone.','The database schema was fixed.'=>'Le schéma de la base de données a été corrigé.','The database schema could not be fixed. Please, contact the support team.'=>'Le schéma de la base de données n’a pas pu être corrigé. Veuillez contacter l’équipe de support.','Saved Options!'=>'Options enregistrées !','If you like %1$s, please leave us a %2$s rating. Thank you!'=>'Si vous appréciez %1$s, veuillez nous laisser une note de %2$s. Merci !','About PublishPress Future'=>'À propos de PublishPress Future','About'=>'À propos','Future Documentation'=>'Documentation de Future','Documentation'=>'Documentation','Contact the PublishPress team'=>'Contacter l’équipe PublishPress','Contact'=>'Contact','No taxonomies found'=>'Aucune taxonomie trouvée','l F jS, Y'=>'I j F Y','g:ia'=>'g\\hia','Post expires at EXPIRATIONTIME on ACTIONDATE'=>'La publication expire à la date d’expiration (EXPIRATIONTIME) de la date d’action (ACTIONDATE).','The table %s does not exist.'=>'La table %s n’existe pas.','The table indexes are invalid: '=>'Les index de table sont invalides : ','Invalid date time offset.'=>'Décalage de la date et de l’heure invalide.','You do not have sufficient permissions to access this page.'=>'Vous n’avez pas les droits suffisants pour accéder à cette page.','Invalid nonce.'=>'Nonce invalid.','Categories'=>'Catégories','Future Actions'=>'Actions Future','Enable Future Action'=>'Activer l’action Future','Action'=>'Action','Loading'=>'Chargement','Show Calendar'=>'Afficher le calendrier','Hide Calendar'=>'Masquer le calendrier','Timezone is controlled by the {WordPress Settings}.'=>'Le fuseau horaire est contrôlé par les {Reglages de WordPress}.','No %s found.'=>'Aucune %s trouvée','You must assign a taxonomy to this post type to use this feature.'=>'Vous devez assigner une taxonomie à ce type de publication pour utiliser cette fonctionnalité.','New %s'=>'Nouveau %s','%s to remove'=>'%s à retirer','%s to add'=>'%s à ajouter','Search for %s'=>'Recherche pour %s','Select an action'=>'Sélectionner une action','Select a date'=>'Sélectionner la date','Date cannot be in the past'=>'La date ne peut pas être dans le passé','Please select one or more %s'=>'Veuillez sélectionner un ou plusieurs %s','New status'=>'Nouvel état','No posts selected. Unable to sync Future Actions.'=>'Aucune publication n’a été sélectionnée. Impossible de synchroniser les actions de Future.','Future Actions successfully synced with Post Metadata.'=>'Les actions de Future ont été bien synchronisées avec les métadonnées de la publication.','Update Future Actions from Post Metadata'=>'Mettre à jour les actions de Future à partir des métadonnées de la publication','Future Action Update'=>'Mise à jour des actions Future','— No Change —'=>'— Aucune modification —','Add or update action for posts'=>'Ajouter ou mettre à jour l’action pour les publications','Add action if none exists for posts'=>'Ajouter une action si aucune n’existe pour les publications','Update the existing actions for posts'=>'Mise à jour des actions existantes pour les publications','Remove action from posts'=>'Retirer l’action de las publications','Category'=>'Catégoria','Settings'=>'Réglages','Future Action'=>'Action Future','Future'=>'Future','Action Settings'=>'Réglages des actions','Scheduled Actions'=>'Actions planifiées','Log format'=>'Format du journal','List'=>'Liste','Popup'=>'Fenêtre surgissante','Successfully executed action: %s'=>'L’action a bien été exécutée : %s','Executed workflow scheduled step'=>'Étape planifiée du flux de travail exécutée','Cleaned up completed scheduled steps older than %d days'=>'Nettoyage des étapes programmées terminées depuis plus de %d jours','Cleaned up orphan workflow scheduled step arguments'=>'Nettoyage des arguments d’étapes planifiées orphelines du flux de travail','The shortcode [futureaction] must be used inside the loop or with the post_id attribute.'=>'Le code court [futureaction] doit être utilisé à l’intérieur de la boucle ou avec l’attribut post_id.','The column args length was not updated to 1000.'=>'La longueur de la colonne des arguments n’a pas été mise à jour à 1000.','Status didn\'t change.'=>'L’état n’a pas été modifié.','Status has been successfully changed from "%1$s" to "%2$s".'=>'L’état a bien été modifié de « %1$s » à « %2$s ».','Change status'=>'Modifier l’état','%s was not deleted.'=>'%s n’a pas été supprimée.','%s has been successfully deleted.'=>'%s a bien été supprimée.','Delete'=>'Supprimer','No terms were added to the %s.'=>'Aucun terme n’a été ajouté à la %s.','The following terms (%1$s) were added to the %2$s: "%3$s". The full list of terms on the post is: %4$s.'=>'Les termes suivants (%1$s) ont été ajoutés aux %2$s : « %3$s ». La liste complète des termes de la publication est la suivante : %4$s.','Add extra %s'=>'Ajouter des %s supplémentaires','No terms were removed from the %s.'=>'Aucun terme n’a été supprimé des %s.','The following terms (%1$s) were removed from the %2$s: %3$s. The new list of terms on the post is: %4$s.'=>'Les termes suivants (%1$s) ont été retirés des %2$s : %3$s. La nouvelle liste de termes dans la publication est la suivante : %4$s.','Remove selected %s'=>'Retirer les %s sélectionnés','The following terms (%1$s) were removed from the %2$s: %3$s.'=>'Les termes suivants (%1$s) ont été retirés des %2$s : %3$s.','Remove all %s'=>'Supprimer tous les %s','No terms were changed on the %s.'=>'Aucun terme n’a été modifié dans la %s.','The following terms (%1$s) were set to the %2$s: "%3$s". The old list of terms on the post was: %4$s.'=>'Les termes suivants (%1$s) ont été définis dans les %2$s : %3$s. L’ancienne liste de termes de la publication était : %4$s.','Replace all %s'=>'Remplacer tous les %s','Change status to %s'=>'Modifier l’état en %s','%s didn\'t change.'=>'%s n’a pas été modifié.','%s has been added to stickies list.'=>'%s a été ajoutée à la liste des épinglées.','Stick'=>'Épingler','%s has been removed from stickies list.'=>'%s a été retirée de la liste des épinglées.','Unstick'=>'Ne plus épingler','Email is disabled.'=>'L’e-mail est désactivé','Email sent.'=>'E-mail envoyé.','Email not sent.'=>'E-mail non envoyé.','%1$s. %2$s on %3$s. The post link is %4$s'=>'%1$s. %2$s le %3$s. Le lien de la publication est %s','Future Action Complete "%s"'=>'Action Future terminée « %s »','[%1$s] %2$s'=>'[%1$s] %2$s','Invalid date/time offset "%s" for post type "%s". Please ensure you use only English terms for the date/time offset, such as "3 months" or "1 week".'=>'Le décalage de date/heure « %s » est invalide pour le type de publication « %s ». Veuillez vous assurer que vous utilisez uniquement des termes anglais pour le décalage de date/heure, tels que « 3 months » (3 mois) ou « 1 week » (1 semaine).','Status'=>'État','Arguments'=>'Arguments','Logs'=>'Journaux','Scheduled Date'=>'Date planifiée','Recurrence'=>'Récurrence','Run'=>'Exécuter','Process the action now'=>'Traiter l’action maintenant','Cancel'=>'Anuler','Cancel the action. This will prevent the action from running in the future'=>'Annuler l’action. Cela empêchera l’exécution de l’action à l’avenir','%s year'=>'%s année' . "\0" . '%s années','%s month'=>'%s mois' . "\0" . '%s mois','%s week'=>'%s semaine' . "\0" . '%s semaines','%s day'=>'%s jour' . "\0" . '%s jours','%s hour'=>'%s heure' . "\0" . '%s heures','%s minute'=>'%s minute' . "\0" . '%s minutes','%s second'=>'%s seconde' . "\0" . '%s secondes','Action Logs'=>'Journaux des actions','Uninitialized'=>'Non initialisé','Scheduled'=>'Planifié','Complete'=>'Complet','Failed'=>'Échec','Canceled'=>'Anulé','Running'=>'En cours d’exécution','All'=>'Tout','Search hook, args and claim ID'=>'Rechercher le crochet, les arguments et l’ID de la demande','Completed'=>'Terminé','%1$s: [%2$d] %3$s%4$s%5$s'=>'%s : [%2$d] %3$s%4$s%5$s','New Status: %s'=>'Nouvel état : %s','Terms: %s'=>'Termes : %s','View log'=>'Voir le journal','Action: '=>'Action : ','Status: '=>'État : ','Arguments: '=>'Arguments : ','Scheduled date: '=>'Date planifiée : ','Date'=>'Date','Message'=>'Message','Async'=>'Asynchrone',' (%s ago)'=>' (il y a %s)',' (%s)'=>' (%s)','Now!'=>'Maintenant !','Every %s'=>'Tous les %s','Non-repeating'=>'Pas de répétition','No Scheduled Actions.'=>'Aucune action planifiée.','Set the offset to use for the default action date and time. For information on formatting, see %1$s. For example, you could enter %2$s+1 month%3$s or %2$s+1 week 2 days 4 hours 2 seconds%3$s or %2$snext Thursday%3$s. Please, use only terms in English.'=>'Définir le décalage à utiliser pour la date et l’heure de l’action par défaut. Pour plus d’informations sur le formatage, voir %1$s. Par exemple, vous pouvez saisir %2$s + 1 mois%3$s ou %2$s + 1 semaine 2 jours 4 heures 2 secondes%3$s ou %2$sprochain jeudi%3$s. Pour ces valeurs, veuillez utiliser uniquement des termes en anglais.','Default Values'=>'Valeurs par défaut','Use the values below to set the default actions/values to be used for each for the corresponding post types. These values can all be overwritten when creating/editing the post/page.'=>'Utilisez les valeurs ci-dessous pour définir les actions/valeurs par défaut à utiliser pour chaque type de publication correspondant. Ces valeurs peuvent toutes être remplacées lors de la création/modification de la publication/page.','Active'=>'Actif','Activate the PublishPress Future actions for this post type'=>'Activer les actions de PublishPress Future pour ce type de publication','Default Action'=>'Action par défaut','Select the default action for the post type.'=>'Sélectionner l’action par défaut pour le type de publication.','Select the taxonomy to be used for actions.'=>'Sélectionner la taxonomie à utiliser pour les actions.','Auto-enable'=>'Activer automatiquement','Enabled for all new posts'=>'Activé pour tous les nouvelles publications','Taxonomy'=>'Taxonomie','No taxonomies found for this post type. Taxonomy actions will not be available.'=>'Aucune taxonomie n’a été trouvée pour ce type de publication. Les actions de taxonomie ne seront pas disponibles.','Who to Notify'=>'Personne à notifier','Enter a comma separated list of emails that you would like to be notified when the action runs.'=>'Saisir une liste d’e-mails séparés par des virgules que vous souhaitez voir notifiés lorsque l’action est exécutée.','Default Date/Time Offset'=>'Décalage date/heure par défaut','PHP strtotime function'=>'Fonction strtotime de PHP','Default terms:'=>'Termes par défaut :','Save changes'=>'Enregistrer les modifications','Wait for the validation...'=>'Attendre la validation…','Date Preview'=>'Aperçu de la date','Current Date'=>'Date actuelle','Computed Date'=>'Date calculée','Error'=>'Erreur','Scheduled Workflow Steps Cleanup'=>'Nettoyage des étapes planifiées du flux de travail','Automatically remove scheduled workflow steps'=>'Supprimer automatiquement les étapes planifiées du flux de travail','Automatically remove scheduled workflow steps that have been marked as failed, completed, or cancelled.'=>'Supprimer automatiquement les étapes du flux de travail planifiées qui ont été marquées comme ayant échoué, terminé ou annulé.','Retain all scheduled workflow steps'=>'Conserver toutes les étapes planifiées du flux de travail','Retain all scheduled workflow steps indefinitely, including those marked as failed, completed, or cancelled. This may impact database performance over time.'=>'Conserver indéfiniment toutes les étapes planifiées du flux de travail, y compris celles qui sont marquées comme ayant échoué, terminé ou annulé. Ceci peut avoir un impact sur les performances de la base de données au fil du temps.','Retention'=>'Conservation','The duration, in days, for which completed, failed, and canceled scheduled workflow steps will be preserved before automatic removal.'=>'La durée, en jours, pendant laquelle les étapes du flux de travail planifié terminées, échouées et annulées seront conservées avant d’être supprimées automatiquement.','days'=>'jours','Form Validation Failure: Sorry, your nonce did not verify.'=>'Échec de la validation du formulaire : Désolé, votre nonce n’a pas été vérifié.','You\'re using PublishPress Future Free. The Pro version has more features and support. %1$sUpgrade to Pro%2$s'=>'Vous utilisez PublishPress Future Free. La version Pro offre plus de fonctionnalités et de support. %1$sPasser à la version Pro%2$s','Upgrade to Pro'=>'Passez à la version Pro','Workflow Manual Trigger'=>'Déclencheur manuel du flux de travail','Action Workflows'=>'Flux de travail d’action','Future Workflow'=>'Flux de travail de Future','Add New'=>'Ajouter','Add New Workflow'=>'Ajouter un nouveau flux de travail','Edit Workflow'=>'Modifier le flux de travail','New Workflow'=>'Nouveau flux de travail','View Workflow'=>'Voir le flux de travail','Search Workflows'=>'Recherche de flux de travail','No Workflows found'=>'Aucun flux de travail trouvé','No Workflows found in Trash'=>'Aucun flux de travail trouvé dans la corbeille','Parent Workflow:'=>'Flux de travail parent :','All Workflows'=>'Tous les flux de travail','Workflow Archives'=>'Archives des flux de travail','Insert into workflow'=>'Insérer dans le flux de travail','Uploaded to this workflow'=>'Téléversé dans ce flux de travail','Filter workflows list'=>'Filtrer la liste des flux de travail','Workflows list navigation'=>'Navigation dans la liste des flux de travail','Action Workflows list'=>'Liste de flux de travail d’action','Workflow published.'=>'Flux de travail publié.','Workflow published privately.'=>'Flux de travail publié en privé.','Workflow reverted to draft.'=>'Le flux de travail a été rétabli à l’état de brouillon.','Workflow scheduled.'=>'Flux de travail planifié.','Workflow updated.'=>'Flux de travail mis à jour.','Notify when a post is updated'=>'Notifier lorsqu’une publication est mise à jour','Notify the site admin when a post is updated.'=>'Notifier l’administrateur/administratrice du site lorsqu’une publication est mise à jour.','Unpublish to Draft after a week'=>'Dépublier au brouillon après une semaine','Change the post status to Draft a week after it was published.'=>'Modifier l’état de la publication en « Brouillon » une semaine après sa publication.','Unpublish and change category after one week'=>'Dépublier et changer de catégorie après une semaine','Move the post to draft and add a category after 15 days.'=>'Déplacer la publication vers le brouillon et ajouter une catégorie après 15 jours.','Add extra categories one month after publishing'=>'Ajouter des catégories supplémentaires un mois après la publication','Sample workflow to add extra categories one month after publishing'=>'Exemple de flux de travail pour ajouter des catégories supplémentaires un mois après la publication','Workflow repeating scheduled step'=>'Étape planifiée répétée dans le flux de travail','Workflow scheduled step'=>'Étape planifiée du flux de travail','Unschedule workflow recurring scheduled step'=>'Déplanifier l’action récurrente planifiée d’un flux de travail','Cleanup orphan workflow scheduled step arguments'=>'Nettoyer les arguments des étapes planifiées orphelines du flux de travail','Clean up completed scheduled steps older than %d days'=>'Nettoyer les étapes planifiées terminées depuis plus de %d jours','Step not found in workflow.'=>'Étape non trouvée dans le flux de travail.','Workflow:'=>'Flux de travail :','Step:'=>'Étape :','Trigger: '=>'Déclencheur : ','Post:'=>'Publication :','Steps:'=>'Étapes :','Workflow recurring scheduled action'=>'Action récurrente planifiée du flux de travail','%1$s until %2$s'=>'%1$s jusqu’à %2$s','%1$s for %2$d times'=>'%1$s pour %2$d fois','[%1$s/%2$d]'=>'[%1$s/%2$d]','Welcome to the workflow editor'=>'Bienvenue dans l’éditeur de flux de travail','In the PublishPress Workflow Editor, each workflow step is presented as a distinct \'node\' in the workflow.'=>'Dans l’éditeur de flux de travail de PublishPress, chaque étape du flux de travail est présentée comme un « nœud » distinct dans le flux de travail.','Use your imagination'=>'Utilisez votre imagination','You\'re free to create very distinct workflows in your site, according to your needs.'=>'Vous êtes libre de créer des flux de travail très distincts dans votre site, en fonction de vos besoins.','A basic workflow'=>'Un flux de travail de base','Every workflow requires at least two steps connected to each other: one trigger and one action.'=>'Chaque flux de travail nécessite au moins deux étapes reliées entre elles : un déclencheur et une action.','Add steps to your workflow'=>'Ajouter des étapes à votre flux de travail','Drag and drop steps to add them to your workflow. Connect the steps to create a workflow.'=>'Glisser-déposer des étapes pour les ajouter à votre flux de travail. Relier les étapes pour créer un flux de travail.','Output and input'=>'Sortie et entrée','Linked steps can pass data forward as input to the next step.'=>'Les étapes liées peuvent transmettre des données à l’étape suivante.','Customize the workflow'=>'Personnaliser le flux de travail','Click on a step to customize it. You can change the step\'s settings in the right sidebar.'=>'Cliquer sur une étape pour la personnaliser. Vous pouvez modifier les réglages de l’étape dans la barre latérale droite.','Workflow validation'=>'Validation du flux de travail','Error messages will appear for any unfilled required settings, missed connections, or invalid values. Select the step to view the corresponding error in the sidebar.'=>'Des messages d’erreur s’affichent pour tout réglage obligatoire non effectué, toute connexion manquée ou toute valeur invalide. Sélectionner l’étape pour afficher l’erreur correspondante dans la barre latérale.','Publish your workflow'=>'Publier votre flux de travail','When you\'re ready, click the publish button to make your workflow live.'=>'Lorsque vous êtes prêt, cliquez sur le bouton « Publier » pour mettre votre flux de travail en ligne.','Need help?'=>'Besoin d’aide ?','If you have any questions or need help, click the help button in the top right corner to access the support resources.'=>'Si vous avez des questions ou si vous avez besoin d’aide, cliquez sur le bouton d’aide dans le coin supérieur droit pour accéder aux ressources de support.','Triggers'=>'Déclencheurs','Preview'=>'Aperçu','—'=>'—','No screenshot'=>'Aucune capture d’écran','Activate'=>'Activer','Deactivate'=>'Désactiver','Action Workflow Editor'=>'Éditeur de flux de travail d’action','Post Query'=>'Requête de publication','A query to select posts'=>'Une requête pour sélectionner les publications','Yes'=>'Oui','No'=>'Non','The workflow was not triggered.'=>'Le flux de travail n’a pas été déclenché.','The workflow was triggered by the legacy action'=>'Le flux de travail a été déclenché par l’ancienne action','Trigger workflow'=>'Déclencher le flux de travail','Move post to status'=>'Déplacer la publication vers l’état','This step transitions a post to a different status.'=>'Cette étape fait passer une publication à un état différent.','Post'=>'Publication','The post to update.'=>'La publication à mettre à jour.','Select the variable that contains the post to update. It can be a post instance or the post ID.'=>'Sélectionner la variable qui contient la publication à mettre à jour. Il peut s’agir d’une instance de publication ou de l’ID de la publication.','The new status that the post will be moved to.'=>'Le nouvel état dans lequel la publication sera déplacée.','Step input'=>'Entrée par étapes','The input data for this step.'=>'Les données d’entrée pour cette étape.','Next'=>'Suivante','Deactivate Workflow for Post'=>'Désactiver le flux de travail pour la publication','This step enables you to deactivate the "Manually enabled via checkbox" workflow after use.'=>'Cette étape vous permet désactiver le flux de travail « Activé manuellement via une case à cocher » après l’utilisation.','Workflow'=>'Flux de travail','Select the manually enabling workflow that will be deactivated for the selected post.'=>'Sélectionner le flux de travail d’activation manuelle qui sera activé pour la publication sélectionnée.','Delete post'=>'Supprimer la publication','This step deletes a post.'=>'Cette étape supprime une publication.','Stick post'=>'Épingler la publication','This step sticks a post.'=>'Cette étape épingle une publication.','The Stick Post action must be part of a Schedule flow'=>'L’action « Épingler la publication » doit faire partie d’un flux de planification.','Add extra terms to post'=>'Ajouter des termes supplémentaires à la publication','This step keeps the current taxonomy terms and adds additional terms.'=>'Cette étape maintient les termes de la taxonomie actuelle et ajoute des termes supplémentaires.','Extra terms'=>'Termes supplémentaires','The terms that will be added to the posts.'=>'Les termes qui seront ajoutés aux publications.','Terms'=>'Termes','Remove terms from the post'=>'Retirer les termes de la publication','This step removes current taxonomy terms.'=>'Cette étape retire les termes de la taxonomie actuelle.','Terms to remove'=>'Termes à retirer','The terms that will be removed from the posts.'=>'Les termes qui seront retirés des publications.','Remove all terms'=>'Retirer tous les termes','Replace all terms on the post'=>'Remplacer tous les termes de la publication','This step removes the current taxonomy terms and adds new terms.'=>'Cette étape retire les termes de la taxonomie actuelle et en ajoute de nouveaux.','New terms'=>'Nouveaux termes','The terms that will be added to the posts after removing all the others.'=>'Les termes qui seront ajoutés aux publications après avoir retiré tous les autres.','Unstick post'=>'Ne plus épingler','This step unsticks a post.'=>'Cette étape désépingle une publication.','PublishPress Workflow: {{global.workflow.title}}'=>'Flux de travail de PublishPress : {{global.workflow.title}}','This is a message sent by PublishPress Workflow: {{global.workflow.title}}.'=>'Ceci est un message envoyé par le flux de travail de PublishPress : {{global.workflow.title}}.','Send email'=>'Envoyer e-mail','This step dispatches a message via email.'=>'Cette étape envoie un message par e-mail.','The email message'=>'Le message de l’e-mail','Recipient'=>'Destinataire','Subject'=>'Sujet','Email Recipient'=>'E-mail du destinataire','Custom Email Address'=>'Adresse e-mail personnalisée','Conditional Split'=>'Division conditionnelle','This step allows you to create a conditional branch.'=>'Cette étape permet de créer une branche conditionnelle.','Conditions'=>'Conditions','The conditions that must be met for deciding which branch to take.'=>'Les conditions qui doivent être satisfaites pour décider de la branche à prendre.','Branch'=>'Branche','The current branch on this step.'=>'La branche actuelle sur cette étape.','True'=>'Vrai','False'=>'Échec','Query posts'=>'Requête de publications','This step defines the posts that will be passed to the next step in the workflow.'=>'Cette étape définit les publications qui seront transmises à l’action suivante dans le flux de travail.','Post query'=>'Requête de publication','The query defines the posts that will be retrieved by this action.'=>'La requête définit les publications qui seront récupérées par cette action.','Post Type'=>'Type de publication','Post ID'=>'ID de la publication','Array of queried post IDs'=>'Tableau d’ID des publications requêtées','The posts found following the criteria of the query.'=>'Les publications trouvées suivant les critères de la requête.','Schedule'=>'Planifier','This step enables actions to be scheduled. You can choose when to run the next step.'=>'Cette étape permet de planifier des actions. Vous pouvez choisir le moment de l’exécution de l’étape suivante.','A scheduled delay between steps.'=>'Un délai planifié entre les étapes.','Date offset'=>'Décalage de date','Log - Add'=>'Journal - ajouter','This step transmits the flow\'s data to the debug log.'=>'Cette étape transmet les données du flux au journal de débogage.','Debug output'=>'Résultats de débogage','The message to be sent to the debug log.'=>'Le message à envoyer au journal de débogage.','Level'=>'Niveau','Ray - Debug'=>'Débogage - Ray','This step transmits the flow\'s data to Ray Debug.'=>'Cette étape transmet les données du flux au débogage de Ray.','The data to be sent to Ray.'=>'Les données à envoyer à Ray.','Data'=>'Données','Label'=>'Libellé','Color'=>'Couleur','On admin init'=>'Lors de l’initialisation de l’administration','This trigger activates upon the initialization of the admin site.'=>'Ce déclencheur s’active lors de l’initialisation du site d’administration.','On cron schedule'=>'Selon le plan cron','This trigger activates upon a cron schedule, allowing recurrency.'=>'Ce déclencheur s’active selon un plan cron, ce qui permet la récurrence.','A schedule to activate the workflow.'=>'Un plan pour activer le flux de travail.','On site init'=>'Lors de l’initialisation du site','This trigger activates upon site initialization.'=>'Ce déclencheur est activé lors de l’initialisation du site.','Manually enabled via checkbox'=>'Activée manuellement par une case à cocher','This trigger activates when the option is manually enabled. It can be enabled via the post editing screen or the Quick Edit panel.'=>'Ce déclencheur s’active lorsque l’option est activée manuellement. Il peut être activé à partir de l’écran de modification de la publication ou du panneau de « Modification rapide ».','Settings for the trigger.'=>'Réglages pour le déclencheur.','Checkbox label'=>'Libellé de la case à cocher','The label of the checkbox that enables the trigger.'=>'Le libellé de la case à cocher qui active le déclencheur.','Specify the criteria for posts that will trigger this action. Leave blank to include all posts.'=>'Spécifier les critères pour les publications qui déclencheront cette action. Laisser vide pour inclure tous les publications.','The query defines the posts that will trigger this action.'=>'La requête définit les publications qui déclencheront cette action.','Saved post'=>'Publication enregistrée','The post that was saved, with the new properties.'=>'La publication qui a été enregistrée avec les nouvelles propriétés.','Post is updated'=>'La publication a été mise a jour','This trigger activates when an existing post is updated.'=>'Ce déclencheur s’active lorsqu’une publication existante est mise à jour.','Post Before Update'=>'La publication avant la mis à jour','The post that was saved, with the old properties.'=>'La publication qui a été enregistrée avec les vieilles propriétés.','Post After Update'=>'La publication après la mis à jour','Post is saved'=>'La publication a été enregistrée','This trigger activates whenever a post is saved, regardless of whether it\'s newly created, imported, or updated.'=>'Ce déclencheur s’active à chaque fois qu’une publication est enregistrée, qu’elle soit nouvellement créée, importée ou mise à jour.','Manually enabled via Future Actions box'=>'Activée manuellement par la boîte des actions de Future','This trigger allows users to choose the workflow from the dropdown menu in the Future Actions options.'=>'Ce déclencheur permet aux utilisateurs/utilisatrices de choisir le flux de travail dans le menu déroulant des options « Actions de Future ».','Action Post'=>'Publication de l’action','The post that was saved triggering the action.'=>'La publication qui a été enregistrée et qui a déclenché l’action.','Site'=>'Site','Flow Control'=>'Contrôler le flux','Asynchronous'=>'Asynchrone','Debug'=>'Débogage','Data Query'=>'Requête de données','Messages'=>'Messages','The ID of the workflow'=>'L’ID du flux de travail','The taxonomy name'=>'Le nom de la taxonomie','The post ID'=>'L’ID de la publication','Workflow not found'=>'Flux de travail non trouvé','Loading the workflow editor...'=>'Chargement de l’éditeur de flux de travail en cours…','Screenshot'=>'Capture d’écran','Upgrade to PublishPress Future Pro'=>'Passez à PublishPress Future Pro','Enhance the power of PublishPress Future with the Pro version:'=>'Augmentez la puissance de PublishPress Future avec la version Pro :','Design custom workflows with multiple actions'=>'Créer des flux de travail personnalisés avec des actions multiples','Schedule actions based on the post\'s publishing date'=>'Planifier les actions en fonction de la date de publication de la publication','Move posts to custom statuses'=>'Déplacer les publications vers des états personnalisés','Use other plugins to control Future Actions'=>'Utiliser les autres extensions pour contrôler les actions de « Future »','Enjoy fast and professional support'=>'Bénéficier du support rapide et professionnel','Need PublishPress Future Support?'=>'Vous avez besoin du support de PublishPress Future ?','If you need help or have a new feature request, let us know.'=>'Si vous avez besoin d’aide ou si vous avez une nouvelle demande de fonctionnalité, faites-le nous savoir.','Request Support'=>'Demande de support','Detailed documentation is also available on the plugin website.'=>'Une documentation détaillée est également disponible sur le site de l’extension.','View Knowledge Base'=>'Voir la base de connaissances','%1$s%2$s%3$s on %5$s%4$s%6$s'=>'%1$s%2$s%3$s sur %5$s%4$s%6$s','Action was not scheduled due to a configuration issue. Please attempt to schedule it again.'=>'L’action n’a pas pu être planifiée en raison d’un problème de configuration. Veuillez essayer de la replanifier.','No future action'=>'Aucune action future','Advanced Options'=>'Options avancées','Workflow Step Schedule\'s Arguments Compression'=>'Comprimer les arguments de l’étape planifiée du flux de travail','Compress the arguments'=>'Comprimer les arguments','Compress the arguments of the step schedule to save memory in the database, saving them as binary data.'=>'Comprimer les arguments du plan d’étapes pour économiser de la mémoire dans la base de données, en les enregistrant sous forme de données binaires.','Do not compress the arguments'=>'Ne pas comprimer les arguments','Do not compress the arguments of the step schedule, storing them as plain text.'=>'Ne pas comprimer les arguments du plan d’action, mais les stocker en texte simple.','Experimental Features'=>'Fonctionnalités expérimentales','Enable experimental features'=>'Activer les fonctionnalités expérimentales','Enable experimental features that are still in development and may not be fully functional.'=>'Activer les fonctionnalités expérimentales qui sont encore en cours de développement et qui peuvent ne pas être totalement fonctionnelles.','Preserve Data After Deactivating the Plugin'=>'Conserver les données après la désactivation de l’extension','Preserve data'=>'Conserver les données','Delete data'=>'Supprimer les données','Toggle between preserving or deleting data after the plugin is deactivated.'=>'Permutez entre la conservation ou la suppression des données après la désactivation de l’extension.','Save Changes'=>'Enregistrer les modifications','Below is a dump of the debugging table, this should be useful for troubleshooting.'=>'Ci-dessous une extraction de la table de débogage, cela devrait vous aider.','Debugging table is currently empty.'=>'La table de débogage est actuellement vide.','Number of logs to display:'=>'Nombre de journaux à afficher :','Showing the latest %d of %d results. The approximate size of the log is %s.'=>'Affichage des derniers %d de %d résultats. La taille approximative du journal est %s.','Showing all %d results. The approximate size of the log is %s.'=>'Affichage de tous les %d résultats. La taille approximative du journal est %s.','Copy Debug Log'=>'Copier le journal de débogage','Download Entire Log'=>'Télécharger le journal complet','Debug log copied to clipboard!'=>'Le journal de débogage est copié dans le presse-papiers !','Advanced Diagnostics and Tools'=>'Diagnostics et outils avancés','WP-Cron Status Check'=>'Vérification de l’état de WP-Cron','Passed'=>'Succès','WP Cron Disabled'=>'WP Cron désactivé','Database Schema Check'=>'Vérification du schéma de la base de données','Error found on the database schema:'=>'Erreur détectée dans le schéma de la base de données :' . "\0" . 'Erreurs détectées dans le schéma de la base de données :','Try to Fix Database'=>'Essayer de corriger la base de données','Debug Logging'=>'Journalisation de débogage','Enabled'=>'Activé','Disable Debugging'=>'Désactiver le débogage','Purge Debug Log'=>'Purge le log de débogage','View Debug Logs'=>'Voir les logs de déboguage','Disabled'=>'Désactivé','Enable Debugging'=>'Activer le débogage','Migrate Legacy Future Actions'=>'Migrer les actions Future héritées','Run Migration'=>'Exécuter la migration','Migrate legacy future actions from WP Cron to the new Action Scheduler. This will run in the background and may take a while.'=>'Migrer les actions futures héritées de WP Cron vers le nouveau planificateur d’actions. Cette opération s’effectuera en arrière-plan et peut prendre un certain temps.','Restore Legacy Action Arguments'=>'Restaurer les arguments d’action hérités','Run Data Restoration'=>'Exécuter la restauration des données','Restore legacy action arguments as Post Meta. This is useful if you have issues with 3rd party plugins that read that data. This will run in the background and may take a while.'=>'Restaure les arguments d’action hérités en tant que métas de la publication. Cela est utile si vous avez des problèmes avec des extensions tierces qui lisent ces données. Ceci est effectué en arrière-plan et peut prendre un certain temps.','Legacy Cron Schedule'=>'Calendrier Cron hérité','The below table will show all currently scheduled cron events for the plugin with the next run time.'=>'Le tableau ci-dessous affiche tous les évènements cron actuellement planifiés pour l’extension avec la prochaine date d’exécution.','Event'=>'Évènement','Posts and expiration settings'=>'Réglages des publications et de l’expiration','This is a legacy feature and will be removed in a future version.'=>'Il s’agit d’une fonctionnalité héritée du passé qui sera supprimée dans une prochaine version.','Default Formats'=>'Formats par défaut','Date Format'=>'Format de date','The default format to use when displaying the action date within a post using the shortcode or within the footer. For information on valid formatting options, see: %s.'=>'Format par défaut à utiliser pour afficher la date de l’action dans une publication à l’aide du code court ou dans le pied de page. Pour plus d’informations sur les options de formatage valides, voir : %s.','PHP Date Function'=>'Fonction date de PHP','Time Format'=>'Format d’heure','The default format to use when displaying the action time within a post using the shortcode or within the footer. For information on valid formatting options, see: %s.'=>'Format par défaut à utiliser pour afficher l’heure de l’action dans une publication à l’aide du code court ou dans le pied de page. Pour plus d’informations sur les options de formatage valides, voir : %s.','Future actions column'=>'Colonne d’actions Future','Future Action Column Style'=>'Style de colonne de l’action Future','Detailed'=>'Détaillé','Displays all information in the Future Action column.'=>'Affiche toutes les informations de la colonne « Action de Future ».','Simplified'=>'Simplifié','Displays only the icon and date/time.'=>'Affiche uniquement l’icône et la date/heure.','Future actions editor'=>'Éditeur d’actions Future','Time format in the date picker'=>'Format de l’heure dans le sélecteur de date','Inherit from Site Settings'=>'Hérite de réglages du site','24 hours'=>'24 heurs','AM/PM'=>'AM/PM','Post Footer Display'=>'Affichage dans le pied de page','Enabling this below will display the action date automatically at the end of any post which is set to run an action.'=>'En activant cette option ci-dessous, la date de l’action s’affichera automatiquement à la fin de toutes les publications qui sont configurées pour exécuter une action.','Show in Post Footer?'=>'Afficher dans le pied de page de la publication ?','This will enable or disable displaying the future action date in the post footer.'=>'Cette option permet d’activer ou de désactiver l’affichage de la date de l’action Future dans le pied de page de la publication.','Footer Contents'=>'Contenus du pied de page','Enter the text you would like to appear at the bottom of every post which has an action scheduled. The following placeholders will be replaced with the future action date in the following format:'=>'Saisissez le texte que vous souhaitez voir apparaître au bas de chaque publication pour laquelle une action a été programmée. Les espaces réservés suivants seront remplacés par la date de l’action future dans le format suivant :','Footer Style'=>'Style du pied de page','The inline css which will be used to style the footer text.'=>'Les CSS en ligne qui seront utilisées pour styler le texte de pied de page.','Example: '=>'Exemple : ','Shortcode'=>'Code court','Valid %s attributes:'=>'Attributs %s valides :','%1$stype%2$s - valid options are %1$sfull%2$s (default), %1$sdate%2$s, %1$stime%2$s'=>'%1$stype%2$s - les options valides sont %1$sfull%2$s (par défaut), %1$sdate%2$s, %1$stime%2$s','%s - format set here will override the value set on the settings page'=>'%s - le format défini ici remplacera la valeur définie sur la page des réglages.','Defaults'=>'Défaut','Calendar Visibility'=>'Visibilité du calendrier','Remember last state'=>'Se souvenir du dernier état','Shows or hides the calendar based on the last user interaction.'=>'Affiche ou masque le calendrier en fonction de la dernière interaction de l’utilisateur/utilisatrice.','Always hidden'=>'Toujours caché','The calendar is always hidden by default.'=>'Le calendrier est toujours caché par défaut.','Permissions'=>'Droits','Choose Which User Roles Can Use PublishPress Future'=>'Choisissez les rôles pouvant utiliser PublishPress Future','Email Notification'=>'Notification par e-mail','Whenever an action runs, an email can be sent to alert users.'=>'Chaque fois qu’une action est exécutée, un e-mail peut être envoyé pour alerter les utilisateurs/utilisatrices.','Enable Email Notification?'=>'Activer la notification par e-mail ?','This will enable or disable the send of email notification on future action.'=>'Ceci vous permet d’activer ou de désactiver l’envoi d’une notification par e-mail pour les actions Future.','Include Blog Administrators?'=>'Inclure les Admins ?','This will include all users with the role of "Administrator" in the email.'=>'Tous les utilisateurs et utilisatrices ayant le rôle d’administrateur ou administratrice seront inclus dans l’e-mail.','Enter a comma separate list of emails that you would like to be notified when the action runs. This will be applied to ALL post types. You can set post type specific emails on the Defaults tab.'=>'Saisissez une liste d’e-mails séparés par des virgules que vous souhaitez voir notifiés lorsque l’action est exécutée. Cette liste sera appliquée à tous les types de publication. Vous pouvez définir des e-mails spécifiques à chaque type de publication dans l’onglet Valeurs par défaut.','Post Types'=>'Types de publication','General'=>'Général','Display'=>'Afficher','Advanced'=>'Avancé','Diagnostics and Tools'=>'Diagnostics et outils']]; \ No newline at end of file +return ['domain'=>NULL,'plural-forms'=>'nplurals=2; plural=n > 1;','language'=>'fr','project-id-version'=>'Plugins - PublishPress Future: Automatically Unpublish WordPress Posts - Stable (latest release)','pot-creation-date'=>'2024-11-19T15:23:53+00:00','po-revision-date'=>'2024-11-20 22:57+0100','x-generator'=>'Poedit 3.4.4','messages'=>['PublishPress Future'=>'PublishPress Future','http://wordpress.org/extend/plugins/post-expirator/'=>'http://wordpress.org/extend/plugins/post-expirator/','PublishPress Future allows you to schedule automatic changes to posts, pages and other content types.'=>'PublishPress Future vous permet de planifier des changements automatiques sur les publications, les pages et d’autres types de publication.','PublishPress'=>'PublishPress','http://publishpress.com'=>'http://publishpress.com','You do not have permission to configure PublishPress Future.'=>'Vous n’avez pas les droits nécessaires pour configurer PublishPress Future.','Debug is disabled'=>'Débogage désactivé','Debugging Disabled'=>'Débogage désactivé','Debugging Enabled'=>'Débogage activé','Debugging Table Emptied'=>'Table de débogage vidée','The legacy future actions migration has been enqueued and will run asynchronously.'=>'La migration des actions Future héritées a été mise en file d’attente et s’exécutera de manière asynchrone.','The legacy actions arguments restoration has been enqueued and will run asynchronously.'=>'La restauration des arguments des actions héritées a été mise en file d’attente et s’exécutera de manière asynchrone.','The database schema was fixed.'=>'Le schéma de la base de données a été corrigé.','The database schema could not be fixed. Please, contact the support team.'=>'Le schéma de la base de données n’a pas pu être corrigé. Veuillez contacter l’équipe de support.','Saved Options!'=>'Options enregistrées !','If you like %1$s, please leave us a %2$s rating. Thank you!'=>'Si vous appréciez %1$s, veuillez nous laisser une note de %2$s. Merci !','About PublishPress Future'=>'À propos de PublishPress Future','About'=>'À propos','Future Documentation'=>'Documentation de Future','Documentation'=>'Documentation','Contact the PublishPress team'=>'Contacter l’équipe PublishPress','Contact'=>'Contact','No taxonomies found'=>'Aucune taxonomie trouvée','l F jS, Y'=>'I j F Y','g:ia'=>'g\\hia','Post expires at EXPIRATIONTIME on ACTIONDATE'=>'La publication expire à la date d’expiration (EXPIRATIONTIME) de la date d’action (ACTIONDATE).','The table %s does not exist.'=>'La table %s n’existe pas.','The table indexes are invalid: '=>'Les index de table sont invalides : ','Invalid date time offset.'=>'Décalage de la date et de l’heure invalide.','You do not have sufficient permissions to access this page.'=>'Vous n’avez pas les droits suffisants pour accéder à cette page.','Invalid nonce.'=>'Nonce invalid.','Categories'=>'Catégories','Future Actions'=>'Actions Future','Enable Future Action'=>'Activer l’action Future','Action'=>'Action','Loading'=>'Chargement','Show Calendar'=>'Afficher le calendrier','Hide Calendar'=>'Masquer le calendrier','Timezone is controlled by the {WordPress Settings}.'=>'Le fuseau horaire est contrôlé par les {Reglages de WordPress}.','No %s found.'=>'Aucune %s trouvée','You must assign a taxonomy to this post type to use this feature.'=>'Vous devez assigner une taxonomie à ce type de publication pour utiliser cette fonctionnalité.','New %s'=>'Nouveau %s','%s to remove'=>'%s à retirer','%s to add'=>'%s à ajouter','Search for %s'=>'Recherche pour %s','Select an action'=>'Sélectionner une action','Select a date'=>'Sélectionner la date','Date cannot be in the past'=>'La date ne peut pas être dans le passé','Please select one or more %s'=>'Veuillez sélectionner un ou plusieurs %s','New status'=>'Nouvel état','No posts selected. Unable to sync Future Actions.'=>'Aucune publication n’a été sélectionnée. Impossible de synchroniser les actions de Future.','Future Actions successfully synced with Post Metadata.'=>'Les actions de Future ont été bien synchronisées avec les métadonnées de la publication.','Update Future Actions from Post Metadata'=>'Mettre à jour les actions de Future à partir des métadonnées de la publication','Future Action Update'=>'Mise à jour des actions Future','— No Change —'=>'— Aucune modification —','Add or update action for posts'=>'Ajouter ou mettre à jour l’action pour les publications','Add action if none exists for posts'=>'Ajouter une action si aucune n’existe pour les publications','Update the existing actions for posts'=>'Mise à jour des actions existantes pour les publications','Remove action from posts'=>'Retirer l’action de las publications','Category'=>'Catégoria','Settings'=>'Réglages','Future Action'=>'Action Future','Future'=>'Future','Action Settings'=>'Réglages des actions','Scheduled Actions'=>'Actions planifiées','Log format'=>'Format du journal','List'=>'Liste','Popup'=>'Fenêtre surgissante','Successfully executed action: %s'=>'L’action a bien été exécutée : %s','Executed workflow scheduled step'=>'Étape planifiée du flux de travail exécutée','Cleaned up completed scheduled steps older than %d days'=>'Nettoyage des étapes programmées terminées depuis plus de %d jours','Cleaned up orphan workflow scheduled step arguments'=>'Nettoyage des arguments d’étapes planifiées orphelines du flux de travail','The shortcode [futureaction] must be used inside the loop or with the post_id attribute.'=>'Le code court [futureaction] doit être utilisé à l’intérieur de la boucle ou avec l’attribut post_id.','The column args length was not updated to 1000.'=>'La longueur de la colonne des arguments n’a pas été mise à jour à 1000.','Status didn\'t change.'=>'L’état n’a pas été modifié.','Status has been successfully changed from "%1$s" to "%2$s".'=>'L’état a bien été modifié de « %1$s » à « %2$s ».','Change status'=>'Modifier l’état','%s was not deleted.'=>'%s n’a pas été supprimée.','%s has been successfully deleted.'=>'%s a bien été supprimée.','Delete'=>'Supprimer','No terms were added to the %s.'=>'Aucun terme n’a été ajouté à la %s.','The following terms (%1$s) were added to the %2$s: "%3$s". The full list of terms on the post is: %4$s.'=>'Les termes suivants (%1$s) ont été ajoutés aux %2$s : « %3$s ». La liste complète des termes de la publication est la suivante : %4$s.','Add extra %s'=>'Ajouter des %s supplémentaires','No terms were removed from the %s.'=>'Aucun terme n’a été supprimé des %s.','The following terms (%1$s) were removed from the %2$s: %3$s. The new list of terms on the post is: %4$s.'=>'Les termes suivants (%1$s) ont été retirés des %2$s : %3$s. La nouvelle liste de termes dans la publication est la suivante : %4$s.','Remove selected %s'=>'Retirer les %s sélectionnés','The following terms (%1$s) were removed from the %2$s: %3$s.'=>'Les termes suivants (%1$s) ont été retirés des %2$s : %3$s.','Remove all %s'=>'Supprimer tous les %s','No terms were changed on the %s.'=>'Aucun terme n’a été modifié dans la %s.','The following terms (%1$s) were set to the %2$s: "%3$s". The old list of terms on the post was: %4$s.'=>'Les termes suivants (%1$s) ont été définis dans les %2$s : %3$s. L’ancienne liste de termes de la publication était : %4$s.','Replace all %s'=>'Remplacer tous les %s','Change status to %s'=>'Modifier l’état en %s','%s didn\'t change.'=>'%s n’a pas été modifié.','%s has been added to stickies list.'=>'%s a été ajoutée à la liste des épinglées.','Stick'=>'Épingler','%s has been removed from stickies list.'=>'%s a été retirée de la liste des épinglées.','Unstick'=>'Ne plus épingler','Email is disabled.'=>'L’e-mail est désactivé','Email sent.'=>'E-mail envoyé.','Email not sent.'=>'E-mail non envoyé.','%1$s. %2$s on %3$s. The post link is %4$s'=>'%1$s. %2$s le %3$s. Le lien de la publication est %s','Future Action Complete "%s"'=>'Action Future terminée « %s »','[%1$s] %2$s'=>'[%1$s] %2$s','Invalid date/time offset "%s" for post type "%s". Please ensure you use only English terms for the date/time offset, such as "3 months" or "1 week".'=>'Le décalage de date/heure « %s » est invalide pour le type de publication « %s ». Veuillez vous assurer que vous utilisez uniquement des termes anglais pour le décalage de date/heure, tels que « 3 months » (3 mois) ou « 1 week » (1 semaine).','Status'=>'État','Arguments'=>'Arguments','Logs'=>'Journaux','Scheduled Date'=>'Date planifiée','Recurrence'=>'Récurrence','Run'=>'Exécuter','Process the action now'=>'Traiter l’action maintenant','Cancel'=>'Anuler','Cancel the action. This will prevent the action from running in the future'=>'Annuler l’action. Cela empêchera l’exécution de l’action à l’avenir','%s year'=>'%s année' . "\0" . '%s années','%s month'=>'%s mois' . "\0" . '%s mois','%s week'=>'%s semaine' . "\0" . '%s semaines','%s day'=>'%s jour' . "\0" . '%s jours','%s hour'=>'%s heure' . "\0" . '%s heures','%s minute'=>'%s minute' . "\0" . '%s minutes','%s second'=>'%s seconde' . "\0" . '%s secondes','Action Logs'=>'Journaux des actions','Uninitialized'=>'Non initialisé','Scheduled'=>'Planifié','Complete'=>'Complet','Failed'=>'Échec','Canceled'=>'Anulé','Running'=>'En cours d’exécution','All'=>'Tout','Search hook, args and claim ID'=>'Rechercher le crochet, les arguments et l’ID de la demande','Completed'=>'Terminé','%1$s: [%2$d] %3$s%4$s%5$s'=>'%s : [%2$d] %3$s%4$s%5$s','New Status: %s'=>'Nouvel état : %s','Terms: %s'=>'Termes : %s','View log'=>'Voir le journal','Action: '=>'Action : ','Status: '=>'État : ','Arguments: '=>'Arguments : ','Scheduled date: '=>'Date planifiée : ','Date'=>'Date','Message'=>'Message','Async'=>'Asynchrone',' (%s ago)'=>' (il y a %s)',' (%s)'=>' (%s)','Now!'=>'Maintenant !','Every %s'=>'Tous les %s','Non-repeating'=>'Pas de répétition','No Scheduled Actions.'=>'Aucune action planifiée.','Set the offset to use for the default action date and time. For information on formatting, see %1$s. For example, you could enter %2$s+1 month%3$s or %2$s+1 week 2 days 4 hours 2 seconds%3$s or %2$snext Thursday%3$s. Please, use only terms in English.'=>'Définir le décalage à utiliser pour la date et l’heure de l’action par défaut. Pour plus d’informations sur le formatage, voir %1$s. Par exemple, vous pouvez saisir %2$s + 1 mois%3$s ou %2$s + 1 semaine 2 jours 4 heures 2 secondes%3$s ou %2$sprochain jeudi%3$s. Pour ces valeurs, veuillez utiliser uniquement des termes en anglais.','Default Values'=>'Valeurs par défaut','Use the values below to set the default actions/values to be used for each for the corresponding post types. These values can all be overwritten when creating/editing the post/page.'=>'Utilisez les valeurs ci-dessous pour définir les actions/valeurs par défaut à utiliser pour chaque type de publication correspondant. Ces valeurs peuvent toutes être remplacées lors de la création/modification de la publication/page.','Active'=>'Actif','Activate the PublishPress Future actions for this post type'=>'Activer les actions de PublishPress Future pour ce type de publication','Default Action'=>'Action par défaut','Select the default action for the post type.'=>'Sélectionner l’action par défaut pour le type de publication.','Select the taxonomy to be used for actions.'=>'Sélectionner la taxonomie à utiliser pour les actions.','Auto-enable'=>'Activer automatiquement','Enabled for all new posts'=>'Activé pour tous les nouvelles publications','Taxonomy'=>'Taxonomie','No taxonomies found for this post type. Taxonomy actions will not be available.'=>'Aucune taxonomie n’a été trouvée pour ce type de publication. Les actions de taxonomie ne seront pas disponibles.','Who to Notify'=>'Personne à notifier','Enter a comma separated list of emails that you would like to be notified when the action runs.'=>'Saisir une liste d’e-mails séparés par des virgules que vous souhaitez voir notifiés lorsque l’action est exécutée.','Default Date/Time Offset'=>'Décalage date/heure par défaut','PHP strtotime function'=>'Fonction strtotime de PHP','Default terms:'=>'Termes par défaut :','Save changes'=>'Enregistrer les modifications','Wait for the validation...'=>'Attendre la validation…','Date Preview'=>'Aperçu de la date','Current Date'=>'Date actuelle','Computed Date'=>'Date calculée','Error'=>'Erreur','Scheduled Workflow Steps Cleanup'=>'Nettoyage des étapes planifiées du flux de travail','Automatically remove scheduled workflow steps'=>'Supprimer automatiquement les étapes planifiées du flux de travail','Automatically remove scheduled workflow steps that have been marked as failed, completed, or cancelled.'=>'Supprimer automatiquement les étapes du flux de travail planifiées qui ont été marquées comme ayant échoué, terminé ou annulé.','Retain all scheduled workflow steps'=>'Conserver toutes les étapes planifiées du flux de travail','Retain all scheduled workflow steps indefinitely, including those marked as failed, completed, or cancelled. This may impact database performance over time.'=>'Conserver indéfiniment toutes les étapes planifiées du flux de travail, y compris celles qui sont marquées comme ayant échoué, terminé ou annulé. Ceci peut avoir un impact sur les performances de la base de données au fil du temps.','Retention'=>'Conservation','The duration, in days, for which completed, failed, and canceled scheduled workflow steps will be preserved before automatic removal.'=>'La durée, en jours, pendant laquelle les étapes du flux de travail planifié terminées, échouées et annulées seront conservées avant d’être supprimées automatiquement.','days'=>'jours','Form Validation Failure: Sorry, your nonce did not verify.'=>'Échec de la validation du formulaire : Désolé, votre nonce n’a pas été vérifié.','You\'re using PublishPress Future Free. The Pro version has more features and support. %1$sUpgrade to Pro%2$s'=>'Vous utilisez PublishPress Future Free. La version Pro offre plus de fonctionnalités et de support. %1$sPasser à la version Pro%2$s','Upgrade to Pro'=>'Passez à la version Pro','Workflow Manual Trigger'=>'Déclencheur manuel du flux de travail','Action Workflows'=>'Flux de travail d’action','Future Workflow'=>'Flux de travail de Future','Add New'=>'Ajouter','Add New Workflow'=>'Ajouter un nouveau flux de travail','Edit Workflow'=>'Modifier le flux de travail','New Workflow'=>'Nouveau flux de travail','View Workflow'=>'Voir le flux de travail','Search Workflows'=>'Recherche de flux de travail','No Workflows found'=>'Aucun flux de travail trouvé','No Workflows found in Trash'=>'Aucun flux de travail trouvé dans la corbeille','Parent Workflow:'=>'Flux de travail parent :','All Workflows'=>'Tous les flux de travail','Workflow Archives'=>'Archives des flux de travail','Insert into workflow'=>'Insérer dans le flux de travail','Uploaded to this workflow'=>'Téléversé dans ce flux de travail','Filter workflows list'=>'Filtrer la liste des flux de travail','Workflows list navigation'=>'Navigation dans la liste des flux de travail','Action Workflows list'=>'Liste de flux de travail d’action','Workflow published.'=>'Flux de travail publié.','Workflow published privately.'=>'Flux de travail publié en privé.','Workflow reverted to draft.'=>'Le flux de travail a été rétabli à l’état de brouillon.','Workflow scheduled.'=>'Flux de travail planifié.','Workflow updated.'=>'Flux de travail mis à jour.','Notify when a post is updated'=>'Notifier lorsqu’une publication est mise à jour','Notify the site admin when a post is updated.'=>'Notifier l’administrateur/administratrice du site lorsqu’une publication est mise à jour.','Unpublish to Draft after a week'=>'Dépublier au brouillon après une semaine','Change the post status to Draft a week after it was published.'=>'Modifier l’état de la publication en « Brouillon » une semaine après sa publication.','Unpublish and change category after one week'=>'Dépublier et changer de catégorie après une semaine','Move the post to draft and add a category after 15 days.'=>'Déplacer la publication vers le brouillon et ajouter une catégorie après 15 jours.','Add extra categories one month after publishing'=>'Ajouter des catégories supplémentaires un mois après la publication','Sample workflow to add extra categories one month after publishing'=>'Exemple de flux de travail pour ajouter des catégories supplémentaires un mois après la publication','Workflow repeating scheduled step'=>'Étape planifiée répétée dans le flux de travail','Workflow scheduled step'=>'Étape planifiée du flux de travail','Unschedule workflow recurring scheduled step'=>'Déplanifier l’action récurrente planifiée d’un flux de travail','Cleanup orphan workflow scheduled step arguments'=>'Nettoyer les arguments des étapes planifiées orphelines du flux de travail','Clean up completed scheduled steps older than %d days'=>'Nettoyer les étapes planifiées terminées depuis plus de %d jours','Step not found in workflow.'=>'Étape non trouvée dans le flux de travail.','Workflow:'=>'Flux de travail :','Step:'=>'Étape :','Trigger: '=>'Déclencheur : ','Post:'=>'Publication :','Steps:'=>'Étapes :','Workflow recurring scheduled action'=>'Action récurrente planifiée du flux de travail','%1$s until %2$s'=>'%1$s jusqu’à %2$s','%1$s for %2$d times'=>'%1$s pour %2$d fois','[%1$s/%2$d]'=>'[%1$s/%2$d]','Welcome to the workflow editor'=>'Bienvenue dans l’éditeur de flux de travail','In the PublishPress Workflow Editor, each workflow step is presented as a distinct \'node\' in the workflow.'=>'Dans l’éditeur de flux de travail de PublishPress, chaque étape du flux de travail est présentée comme un « nœud » distinct dans le flux de travail.','Use your imagination'=>'Utilisez votre imagination','You\'re free to create very distinct workflows in your site, according to your needs.'=>'Vous êtes libre de créer des flux de travail très distincts dans votre site, en fonction de vos besoins.','A basic workflow'=>'Un flux de travail de base','Every workflow requires at least two steps connected to each other: one trigger and one action.'=>'Chaque flux de travail nécessite au moins deux étapes reliées entre elles : un déclencheur et une action.','Add steps to your workflow'=>'Ajouter des étapes à votre flux de travail','Drag and drop steps to add them to your workflow. Connect the steps to create a workflow.'=>'Glisser-déposer des étapes pour les ajouter à votre flux de travail. Relier les étapes pour créer un flux de travail.','Output and input'=>'Sortie et entrée','Linked steps can pass data forward as input to the next step.'=>'Les étapes liées peuvent transmettre des données à l’étape suivante.','Customize the workflow'=>'Personnaliser le flux de travail','Click on a step to customize it. You can change the step\'s settings in the right sidebar.'=>'Cliquer sur une étape pour la personnaliser. Vous pouvez modifier les réglages de l’étape dans la barre latérale droite.','Workflow validation'=>'Validation du flux de travail','Error messages will appear for any unfilled required settings, missed connections, or invalid values. Select the step to view the corresponding error in the sidebar.'=>'Des messages d’erreur s’affichent pour tout réglage obligatoire non effectué, toute connexion manquée ou toute valeur invalide. Sélectionner l’étape pour afficher l’erreur correspondante dans la barre latérale.','Publish your workflow'=>'Publier votre flux de travail','When you\'re ready, click the publish button to make your workflow live.'=>'Lorsque vous êtes prêt, cliquez sur le bouton « Publier » pour mettre votre flux de travail en ligne.','Need help?'=>'Besoin d’aide ?','If you have any questions or need help, click the help button in the top right corner to access the support resources.'=>'Si vous avez des questions ou si vous avez besoin d’aide, cliquez sur le bouton d’aide dans le coin supérieur droit pour accéder aux ressources de support.','Triggers'=>'Déclencheurs','Preview'=>'Aperçu','—'=>'—','No screenshot'=>'Aucune capture d’écran','Activate'=>'Activer','Deactivate'=>'Désactiver','Action Workflow Editor'=>'Éditeur de flux de travail d’action','Post Query'=>'Requête de publication','A query to select posts'=>'Une requête pour sélectionner les publications','Yes'=>'Oui','No'=>'Non','The workflow was not triggered.'=>'Le flux de travail n’a pas été déclenché.','The workflow was triggered by the legacy action'=>'Le flux de travail a été déclenché par l’ancienne action','Trigger workflow'=>'Déclencher le flux de travail','Move post to status'=>'Déplacer la publication vers l’état','This step transitions a post to a different status.'=>'Cette étape fait passer une publication à un état différent.','Post'=>'Publication','The post to update.'=>'La publication à mettre à jour.','Select the variable that contains the post to update. It can be a post instance or the post ID.'=>'Sélectionner la variable qui contient la publication à mettre à jour. Il peut s’agir d’une instance de publication ou de l’ID de la publication.','The new status that the post will be moved to.'=>'Le nouvel état dans lequel la publication sera déplacée.','Step input'=>'Entrée par étapes','The input data for this step.'=>'Les données d’entrée pour cette étape.','Next'=>'Suivante','Deactivate Workflow for Post'=>'Désactiver le flux de travail pour la publication','This step enables you to deactivate the "Manually enabled via checkbox" workflow after use.'=>'Cette étape vous permet désactiver le flux de travail « Activé manuellement via une case à cocher » après l’utilisation.','Workflow'=>'Flux de travail','Select the manually enabling workflow that will be deactivated for the selected post.'=>'Sélectionner le flux de travail d’activation manuelle qui sera activé pour la publication sélectionnée.','Delete post'=>'Supprimer la publication','This step deletes a post.'=>'Cette étape supprime une publication.','Stick post'=>'Épingler la publication','This step sticks a post.'=>'Cette étape épingle une publication.','The Stick Post action must be part of a Schedule flow'=>'L’action « Épingler la publication » doit faire partie d’un flux de planification.','Add extra terms to post'=>'Ajouter des termes supplémentaires à la publication','This step keeps the current taxonomy terms and adds additional terms.'=>'Cette étape maintient les termes de la taxonomie actuelle et ajoute des termes supplémentaires.','Extra terms'=>'Termes supplémentaires','The terms that will be added to the posts.'=>'Les termes qui seront ajoutés aux publications.','Terms'=>'Termes','Remove terms from the post'=>'Retirer les termes de la publication','This step removes current taxonomy terms.'=>'Cette étape retire les termes de la taxonomie actuelle.','Terms to remove'=>'Termes à retirer','The terms that will be removed from the posts.'=>'Les termes qui seront retirés des publications.','Remove all terms'=>'Retirer tous les termes','Replace all terms on the post'=>'Remplacer tous les termes de la publication','This step removes the current taxonomy terms and adds new terms.'=>'Cette étape retire les termes de la taxonomie actuelle et en ajoute de nouveaux.','New terms'=>'Nouveaux termes','The terms that will be added to the posts after removing all the others.'=>'Les termes qui seront ajoutés aux publications après avoir retiré tous les autres.','Unstick post'=>'Ne plus épingler','This step unsticks a post.'=>'Cette étape désépingle une publication.','PublishPress Workflow: {{global.workflow.title}}'=>'Flux de travail de PublishPress : {{global.workflow.title}}','This is a message sent by PublishPress Workflow: {{global.workflow.title}}.'=>'Ceci est un message envoyé par le flux de travail de PublishPress : {{global.workflow.title}}.','Send email'=>'Envoyer e-mail','This step dispatches a message via email.'=>'Cette étape envoie un message par e-mail.','The email message'=>'Le message de l’e-mail','Recipient'=>'Destinataire','Subject'=>'Sujet','Email Recipient'=>'E-mail du destinataire','Custom Email Address'=>'Adresse e-mail personnalisée','Conditional Split'=>'Division conditionnelle','This step allows you to create a conditional branch.'=>'Cette étape permet de créer une branche conditionnelle.','Conditions'=>'Conditions','The conditions that must be met for deciding which branch to take.'=>'Les conditions qui doivent être satisfaites pour décider de la branche à prendre.','Branch'=>'Branche','The current branch on this step.'=>'La branche actuelle sur cette étape.','True'=>'Vrai','False'=>'Échec','Query posts'=>'Requête de publications','This step defines the posts that will be passed to the next step in the workflow.'=>'Cette étape définit les publications qui seront transmises à l’action suivante dans le flux de travail.','Post query'=>'Requête de publication','The query defines the posts that will be retrieved by this action.'=>'La requête définit les publications qui seront récupérées par cette action.','Post Type'=>'Type de publication','Post ID'=>'ID de la publication','Array of queried post IDs'=>'Tableau d’ID des publications requêtées','The posts found following the criteria of the query.'=>'Les publications trouvées suivant les critères de la requête.','Schedule'=>'Planifier','This step enables actions to be scheduled. You can choose when to run the next step.'=>'Cette étape permet de planifier des actions. Vous pouvez choisir le moment de l’exécution de l’étape suivante.','A scheduled delay between steps.'=>'Un délai planifié entre les étapes.','Date offset'=>'Décalage de date','Log - Add'=>'Journal - ajouter','This step transmits the flow\'s data to the debug log.'=>'Cette étape transmet les données du flux au journal de débogage.','Debug output'=>'Résultats de débogage','The message to be sent to the debug log.'=>'Le message à envoyer au journal de débogage.','Level'=>'Niveau','Ray - Debug'=>'Débogage - Ray','This step transmits the flow\'s data to Ray Debug.'=>'Cette étape transmet les données du flux au débogage de Ray.','The data to be sent to Ray.'=>'Les données à envoyer à Ray.','Data'=>'Données','Label'=>'Libellé','Color'=>'Couleur','On admin init'=>'Lors de l’initialisation de l’administration','This trigger activates upon the initialization of the admin site.'=>'Ce déclencheur s’active lors de l’initialisation du site d’administration.','On cron schedule'=>'Selon le plan cron','This trigger activates upon a cron schedule, allowing recurrency.'=>'Ce déclencheur s’active selon un plan cron, ce qui permet la récurrence.','A schedule to activate the workflow.'=>'Un plan pour activer le flux de travail.','On site init'=>'Lors de l’initialisation du site','This trigger activates upon site initialization.'=>'Ce déclencheur est activé lors de l’initialisation du site.','Manually enabled via checkbox'=>'Activée manuellement par une case à cocher','This trigger activates when the option is manually enabled. It can be enabled via the post editing screen or the Quick Edit panel.'=>'Ce déclencheur s’active lorsque l’option est activée manuellement. Il peut être activé à partir de l’écran de modification de la publication ou du panneau de « Modification rapide ».','Settings for the trigger.'=>'Réglages pour le déclencheur.','Checkbox label'=>'Libellé de la case à cocher','The label of the checkbox that enables the trigger.'=>'Le libellé de la case à cocher qui active le déclencheur.','Specify the criteria for posts that will trigger this action. Leave blank to include all posts.'=>'Spécifier les critères pour les publications qui déclencheront cette action. Laisser vide pour inclure tous les publications.','The query defines the posts that will trigger this action.'=>'La requête définit les publications qui déclencheront cette action.','Saved post'=>'Publication enregistrée','The post that was saved, with the new properties.'=>'La publication qui a été enregistrée avec les nouvelles propriétés.','Post is updated'=>'La publication a été mise a jour','This trigger activates when an existing post is updated.'=>'Ce déclencheur s’active lorsqu’une publication existante est mise à jour.','Post Before Update'=>'La publication avant la mis à jour','The post that was saved, with the old properties.'=>'La publication qui a été enregistrée avec les vieilles propriétés.','Post After Update'=>'La publication après la mis à jour','Post is saved'=>'La publication a été enregistrée','This trigger activates whenever a post is saved, regardless of whether it\'s newly created, imported, or updated.'=>'Ce déclencheur s’active à chaque fois qu’une publication est enregistrée, qu’elle soit nouvellement créée, importée ou mise à jour.','Manually enabled via Future Actions box'=>'Activée manuellement par la boîte des actions de Future','This trigger allows users to choose the workflow from the dropdown menu in the Future Actions options.'=>'Ce déclencheur permet aux utilisateurs/utilisatrices de choisir le flux de travail dans le menu déroulant des options « Actions de Future ».','Action Post'=>'Publication de l’action','The post that was saved triggering the action.'=>'La publication qui a été enregistrée et qui a déclenché l’action.','Site'=>'Site','Flow Control'=>'Contrôler le flux','Asynchronous'=>'Asynchrone','Debug'=>'Débogage','Data Query'=>'Requête de données','Messages'=>'Messages','The ID of the workflow'=>'L’ID du flux de travail','The taxonomy name'=>'Le nom de la taxonomie','The post ID'=>'L’ID de la publication','Workflow not found'=>'Flux de travail non trouvé','Loading the workflow editor...'=>'Chargement de l’éditeur de flux de travail en cours…','Screenshot'=>'Capture d’écran','Upgrade to PublishPress Future Pro'=>'Passez à PublishPress Future Pro','Enhance the power of PublishPress Future with the Pro version:'=>'Augmentez la puissance de PublishPress Future avec la version Pro :','Design custom workflows with multiple actions'=>'Créer des flux de travail personnalisés avec des actions multiples','Schedule actions based on the post\'s publishing date'=>'Planifier les actions en fonction de la date de publication de la publication','Move posts to custom statuses'=>'Déplacer les publications vers des états personnalisés','Use other plugins to control Future Actions'=>'Utiliser les autres extensions pour contrôler les actions de « Future »','Enjoy fast and professional support'=>'Bénéficier du support rapide et professionnel','Need PublishPress Future Support?'=>'Vous avez besoin du support de PublishPress Future ?','If you need help or have a new feature request, let us know.'=>'Si vous avez besoin d’aide ou si vous avez une nouvelle demande de fonctionnalité, faites-le nous savoir.','Request Support'=>'Demande de support','Detailed documentation is also available on the plugin website.'=>'Une documentation détaillée est également disponible sur le site de l’extension.','View Knowledge Base'=>'Voir la base de connaissances','%1$s%2$s%3$s on %5$s%4$s%6$s'=>'%1$s%2$s%3$s sur %5$s%4$s%6$s','Action was not scheduled due to a configuration issue. Please attempt to schedule it again.'=>'L’action n’a pas pu être planifiée en raison d’un problème de configuration. Veuillez essayer de la replanifier.','No future action'=>'Aucune action future','Advanced Options'=>'Options avancées','Workflow Step Schedule\'s Arguments Compression'=>'Comprimer les arguments de l’étape planifiée du flux de travail','Compress the arguments'=>'Comprimer les arguments','Compress the arguments of the step schedule to save memory in the database, saving them as binary data.'=>'Comprimer les arguments du plan d’étapes pour économiser de la mémoire dans la base de données, en les enregistrant sous forme de données binaires.','Do not compress the arguments'=>'Ne pas comprimer les arguments','Do not compress the arguments of the step schedule, storing them as plain text.'=>'Ne pas comprimer les arguments du plan d’action, mais les stocker en texte simple.','Experimental Features'=>'Fonctionnalités expérimentales','Enable experimental features'=>'Activer les fonctionnalités expérimentales','Enable experimental features that are still in development and may not be fully functional.'=>'Activer les fonctionnalités expérimentales qui sont encore en cours de développement et qui peuvent ne pas être totalement fonctionnelles.','Preserve Data After Deactivating the Plugin'=>'Conserver les données après la désactivation de l’extension','Preserve data'=>'Conserver les données','Delete data'=>'Supprimer les données','Toggle between preserving or deleting data after the plugin is deactivated.'=>'Permutez entre la conservation ou la suppression des données après la désactivation de l’extension.','Save Changes'=>'Enregistrer les modifications','Below is a dump of the debugging table, this should be useful for troubleshooting.'=>'Ci-dessous une extraction de la table de débogage, cela devrait vous aider.','Debugging table is currently empty.'=>'La table de débogage est actuellement vide.','Number of logs to display:'=>'Nombre de journaux à afficher :','Showing the latest %d of %d results. The approximate size of the log is %s.'=>'Affichage des derniers %d de %d résultats. La taille approximative du journal est %s.','Showing all %d results. The approximate size of the log is %s.'=>'Affichage de tous les %d résultats. La taille approximative du journal est %s.','Copy Debug Log'=>'Copier le journal de débogage','Download Entire Log'=>'Télécharger le journal complet','Debug log copied to clipboard!'=>'Le journal de débogage est copié dans le presse-papiers !','Advanced Diagnostics and Tools'=>'Diagnostics et outils avancés','WP-Cron Status Check'=>'Vérification de l’état de WP-Cron','Passed'=>'Succès','WP Cron Disabled'=>'WP Cron désactivé','Database Schema Check'=>'Vérification du schéma de la base de données','Error found on the database schema:'=>'Erreur détectée dans le schéma de la base de données :' . "\0" . 'Erreurs détectées dans le schéma de la base de données :','Try to Fix Database'=>'Essayer de corriger la base de données','Debug Logging'=>'Journalisation de débogage','Enabled'=>'Activé','Disable Debugging'=>'Désactiver le débogage','Purge Debug Log'=>'Purge le log de débogage','View Debug Logs'=>'Voir les logs de déboguage','Disabled'=>'Désactivé','Enable Debugging'=>'Activer le débogage','Migrate Legacy Future Actions'=>'Migrer les actions Future héritées','Run Migration'=>'Exécuter la migration','Migrate legacy future actions from WP Cron to the new Action Scheduler. This will run in the background and may take a while.'=>'Migrer les actions futures héritées de WP Cron vers le nouveau planificateur d’actions. Cette opération s’effectuera en arrière-plan et peut prendre un certain temps.','Restore Legacy Action Arguments'=>'Restaurer les arguments d’action hérités','Run Data Restoration'=>'Exécuter la restauration des données','Restore legacy action arguments as Post Meta. This is useful if you have issues with 3rd party plugins that read that data. This will run in the background and may take a while.'=>'Restaure les arguments d’action hérités en tant que métas de la publication. Cela est utile si vous avez des problèmes avec des extensions tierces qui lisent ces données. Ceci est effectué en arrière-plan et peut prendre un certain temps.','Legacy Cron Schedule'=>'Calendrier Cron hérité','The below table will show all currently scheduled cron events for the plugin with the next run time.'=>'Le tableau ci-dessous affiche tous les évènements cron actuellement planifiés pour l’extension avec la prochaine date d’exécution.','Event'=>'Évènement','Posts and expiration settings'=>'Réglages des publications et de l’expiration','This is a legacy feature and will be removed in a future version.'=>'Il s’agit d’une fonctionnalité héritée du passé qui sera supprimée dans une prochaine version.','Default Formats'=>'Formats par défaut','Date Format'=>'Format de date','The default format to use when displaying the action date within a post using the shortcode or within the footer. For information on valid formatting options, see: %s.'=>'Format par défaut à utiliser pour afficher la date de l’action dans une publication à l’aide du code court ou dans le pied de page. Pour plus d’informations sur les options de formatage valides, voir : %s.','PHP Date Function'=>'Fonction date de PHP','Time Format'=>'Format d’heure','The default format to use when displaying the action time within a post using the shortcode or within the footer. For information on valid formatting options, see: %s.'=>'Format par défaut à utiliser pour afficher l’heure de l’action dans une publication à l’aide du code court ou dans le pied de page. Pour plus d’informations sur les options de formatage valides, voir : %s.','Future Actions Column'=>'Colonne d’actions Future','Future Action Column Style'=>'Style de colonne de l’action Future','Detailed'=>'Détaillé','Displays all information in the Future Action column.'=>'Affiche toutes les informations de la colonne « Action de Future ».','Simplified'=>'Simplifié','Displays only the icon and date/time.'=>'Affiche uniquement l’icône et la date/heure.','Future Actions Aditor'=>'Éditeur d’actions Future','Time format in the date picker'=>'Format de l’heure dans le sélecteur de date','Inherit from Site Settings'=>'Hérite de réglages du site','24 hours'=>'24 heurs','AM/PM'=>'AM/PM','Post Footer Display'=>'Affichage dans le pied de page','Enabling this below will display the action date automatically at the end of any post which is set to run an action.'=>'En activant cette option ci-dessous, la date de l’action s’affichera automatiquement à la fin de toutes les publications qui sont configurées pour exécuter une action.','Show in Post Footer?'=>'Afficher dans le pied de page de la publication ?','This will enable or disable displaying the future action date in the post footer.'=>'Cette option permet d’activer ou de désactiver l’affichage de la date de l’action Future dans le pied de page de la publication.','Footer Contents'=>'Contenus du pied de page','Enter the text you would like to appear at the bottom of every post which has an action scheduled. The following placeholders will be replaced with the future action date in the following format:'=>'Saisissez le texte que vous souhaitez voir apparaître au bas de chaque publication pour laquelle une action a été programmée. Les espaces réservés suivants seront remplacés par la date de l’action future dans le format suivant :','Footer Style'=>'Style du pied de page','The inline css which will be used to style the footer text.'=>'Les CSS en ligne qui seront utilisées pour styler le texte de pied de page.','Example: '=>'Exemple : ','Shortcode'=>'Code court','Valid %s attributes:'=>'Attributs %s valides :','%1$stype%2$s - valid options are %1$sfull%2$s (default), %1$sdate%2$s, %1$stime%2$s'=>'%1$stype%2$s - les options valides sont %1$sfull%2$s (par défaut), %1$sdate%2$s, %1$stime%2$s','%s - format set here will override the value set on the settings page'=>'%s - le format défini ici remplacera la valeur définie sur la page des réglages.','Defaults'=>'Défaut','Calendar Visibility'=>'Visibilité du calendrier','Remember last state'=>'Se souvenir du dernier état','Shows or hides the calendar based on the last user interaction.'=>'Affiche ou masque le calendrier en fonction de la dernière interaction de l’utilisateur/utilisatrice.','Always hidden'=>'Toujours caché','The calendar is always hidden by default.'=>'Le calendrier est toujours caché par défaut.','Permissions'=>'Droits','Choose Which User Roles Can Use PublishPress Future'=>'Choisissez les rôles pouvant utiliser PublishPress Future','Email Notification'=>'Notification par e-mail','Whenever an action runs, an email can be sent to alert users.'=>'Chaque fois qu’une action est exécutée, un e-mail peut être envoyé pour alerter les utilisateurs/utilisatrices.','Enable Email Notification?'=>'Activer la notification par e-mail ?','This will enable or disable the send of email notification on future action.'=>'Ceci vous permet d’activer ou de désactiver l’envoi d’une notification par e-mail pour les actions Future.','Include Blog Administrators?'=>'Inclure les Admins ?','This will include all users with the role of "Administrator" in the email.'=>'Tous les utilisateurs et utilisatrices ayant le rôle d’administrateur ou administratrice seront inclus dans l’e-mail.','Enter a comma separate list of emails that you would like to be notified when the action runs. This will be applied to ALL post types. You can set post type specific emails on the Defaults tab.'=>'Saisissez une liste d’e-mails séparés par des virgules que vous souhaitez voir notifiés lorsque l’action est exécutée. Cette liste sera appliquée à tous les types de publication. Vous pouvez définir des e-mails spécifiques à chaque type de publication dans l’onglet Valeurs par défaut.','Post Types'=>'Types de publication','General'=>'Général','Display'=>'Afficher','Advanced'=>'Avancé','Diagnostics and Tools'=>'Diagnostics et outils']]; \ No newline at end of file diff --git a/languages/post-expirator-fr_FR.mo b/languages/post-expirator-fr_FR.mo index 84a075b1dd6975c601cd2bde66156f2ef72df13c..347e614ca899a6b00b021172540a0ba40428b6a6 100644 GIT binary patch delta 150 zcmeDE%+&jtX~P*-RZ#{8hTBFA3?TX=kTwI-?8XcXB0$;>Nb>{f;LRUdx%pM4fy_hI z3=C30`W}#u1=2r(v^bCsuVG-21k(AN6-7_V$~dNEmgE;PxRsWa7NsgUCYNO9=M^hB l=jW8>=1sn36uUXuINoD&ZjH?3pc?7PhpH!R?yO<41pv(bC-VRR delta 165 zcmeDE%+&jtX~P*-RWk+#hTBFA3?e{U$e4kFA4sbMX;C0;4yAoJe`Mw6SB(V<9jazv z5C_r\n" +"Language-Team: LANGUAGE \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"POT-Creation-Date: 2024-12-09T15:08:10+00:00\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"X-Generator: WP-CLI 2.11.0\n" +"X-Domain: post-expirator\n" + +#: components/backup-panel.jsx:13 +#: components/tabs-content/export.jsx:205 +msgid "Export" +msgstr "" + +#: components/backup-panel.jsx:17 +#: components/tabs-content/import.jsx:148 +msgid "Import" +msgstr "" + +#: components/selectable-list/index.jsx:17 +msgid "Select all" +msgstr "" + +#: components/selectable-list/index.jsx:18 +msgid "Unselect all" +msgstr "" + +#: components/tabs-content/export.jsx:25 +msgid "Post Types" +msgstr "" + +#: components/tabs-content/export.jsx:29 +msgid "General" +msgstr "" + +#: components/tabs-content/export.jsx:33 +msgid "Notifications" +msgstr "" + +#: components/tabs-content/export.jsx:37 +msgid "Display" +msgstr "" + +#: components/tabs-content/export.jsx:41 +msgid "Advanced" +msgstr "" + +#: components/tabs-content/export.jsx:104 +msgid "Settings exported successfully." +msgstr "" + +#: components/tabs-content/export.jsx:110 +msgid "Download" +msgstr "" + +#: components/tabs-content/export.jsx:127 +msgid "Failed to export settings." +msgstr "" + +#: components/tabs-content/export.jsx:160 +msgid "Export Settings" +msgstr "" + +#: components/tabs-content/export.jsx:161 +msgid "Export the plugin settings and workflows to a .json file. This file can be imported later to restore the data or migrate to another site." +msgstr "" + +#: components/tabs-content/export.jsx:166 +msgid "Action Workflows" +msgstr "" + +#: components/tabs-content/export.jsx:177 +msgid "Include screenshots" +msgstr "" + +#: components/tabs-content/export.jsx:190 +msgid "Action Settings" +msgstr "" + +#: components/tabs-content/export.jsx:205 +msgid "Exporting..." +msgstr "" + +#: components/tabs-content/export.jsx:209 +msgid "Cancel" +msgstr "" + +#: components/tabs-content/import.jsx:48 +msgid "Settings imported successfully." +msgstr "" + +#: components/tabs-content/import.jsx:65 +msgid "Failed to import settings." +msgstr "" + +#: components/tabs-content/import.jsx:83 +msgid "Invalid file type. Please upload a .json file." +msgstr "" + +#: components/tabs-content/import.jsx:94 +msgid "Import Settings" +msgstr "" + +#: components/tabs-content/import.jsx:95 +msgid "Import the plugin settings or workflows from a .json file." +msgstr "" + +#: components/tabs-content/import.jsx:122 +msgid "Drop your .json file here" +msgstr "" + +#: components/tabs-content/import.jsx:123 +msgid "or" +msgstr "" + +#: components/tabs-content/import.jsx:133 +msgid "Select a .json file" +msgstr "" + +#: components/tabs-content/import.jsx:138 +msgid "Selected file" +msgstr "" + +#: components/tabs-content/import.jsx:139 +msgid "File size" +msgstr "" diff --git a/languages/post-expirator-future_workflow_editor_script.pot b/languages/post-expirator-future_workflow_editor_script.pot index f805810a7..cf133a570 100644 --- a/languages/post-expirator-future_workflow_editor_script.pot +++ b/languages/post-expirator-future_workflow_editor_script.pot @@ -7,7 +7,7 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"POT-Creation-Date: 2024-11-21T14:06:03+00:00\n" +"POT-Creation-Date: 2024-12-09T15:08:10+00:00\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "X-Generator: WP-CLI 2.11.0\n" "X-Domain: post-expirator\n" @@ -101,7 +101,7 @@ msgid "Unique ID Expression" msgstr "" #: components/data-fields/date-offset.jsx:233 -msgid "Define a custom expression for a unique task ID. Use placeholders like {{onSavePost1.post.ID}} or {{global.user.ID}} to make sure the ID is unique." +msgid "Define a custom expression for a unique task ID. Use placeholders like {{onSavePost1.post.ID}}, {{global.user.ID}} or {{global.execution_id}} to make sure the ID is unique." msgstr "" #: components/data-fields/date-offset.jsx:239 @@ -116,7 +116,12 @@ msgstr "" msgid "All received input" msgstr "" -#: components/data-fields/debug-data.jsx:35 +#: components/data-fields/debug-data.jsx:22 +#: components/data-fields/debug-data.jsx:49 +msgid "Custom data" +msgstr "" + +#: components/data-fields/debug-data.jsx:41 msgid "Data to output" msgstr "" @@ -156,34 +161,42 @@ msgstr "" msgid "Custom Addresses" msgstr "" -#: components/data-fields/email-recipient.jsx:35 +#: components/data-fields/email-recipient.jsx:34 msgid "Email Recipient" msgstr "" -#: components/data-fields/email-recipient.jsx:42 +#: components/data-fields/email-recipient.jsx:41 msgid "Custom Email Addresses" msgstr "" -#: components/data-fields/post-query.jsx:44 +#: components/data-fields/post-query.jsx:46 +msgid "Post Type" +msgstr "" + +#: components/data-fields/post-query.jsx:53 msgid "Post selection" msgstr "" -#: components/data-fields/post-query.jsx:47 +#: components/data-fields/post-query.jsx:56 msgid "Post received as input" msgstr "" -#: components/data-fields/post-query.jsx:48 +#: components/data-fields/post-query.jsx:57 msgid "Custom query" msgstr "" -#: components/data-fields/post-query.jsx:59 -msgid "Post Type" +#: components/data-fields/post-query.jsx:77 +msgid "Post ID" msgstr "" -#: components/data-fields/post-query.jsx:74 +#: components/data-fields/post-query.jsx:83 msgid "Post Status" msgstr "" +#: components/data-fields/post-query.jsx:94 +msgid "* Required field" +msgstr "" + #: components/data-fields/post-status.jsx:40 msgid "New Status" msgstr "" @@ -264,26 +277,26 @@ msgstr "" msgid "Currently this step is being skipped. Upgrade to Pro to unlock this feature." msgstr "" -#: components/layout/header.jsx:133 +#: components/layout/header.jsx:129 msgid "Add" msgstr "" -#: components/layout/header.jsx:133 +#: components/layout/header.jsx:129 msgid "Close" msgstr "" #. translators: button label text should, if possible, be under 16 characters. -#: components/layout/header.jsx:144 -#: components/layout/header.jsx:149 +#: components/layout/header.jsx:140 +#: components/layout/header.jsx:145 msgid "Auto Layout" msgstr "" #. translators: button label text should, if possible, be under 16 characters. -#: components/layout/header.jsx:161 +#: components/layout/header.jsx:157 msgid "Upgrade to Pro and unlock more features" msgstr "" -#: components/layout/header.jsx:164 +#: components/layout/header.jsx:160 msgid "Upgrade to Pro" msgstr "" @@ -733,45 +746,45 @@ msgid "Move to trash" msgstr "" #. translators: button label text should, if possible, be under 16 characters. -#: components/workflow-publish-button/index.jsx:82 +#: components/workflow-publish-button/index.jsx:84 msgid "Publish" msgstr "" -#: components/workflow-publish-button/index.jsx:82 +#: components/workflow-publish-button/index.jsx:84 msgid "Update" msgstr "" -#: components/workflow-publish-button/index.jsx:93 +#: components/workflow-publish-button/index.jsx:95 msgid "Autosaving..." msgstr "" -#: components/workflow-publish-button/index.jsx:93 +#: components/workflow-publish-button/index.jsx:95 msgid "Updating..." msgstr "" -#: components/workflow-publish-button/index.jsx:95 +#: components/workflow-publish-button/index.jsx:97 msgid "Updated" msgstr "" #. translators: button label text should, if possible, be under 16 characters. -#: components/workflow-save-draft-button/index.jsx:85 +#: components/workflow-save-draft-button/index.jsx:87 msgid "Save draft" msgstr "" #. translators: button label text should, if possible, be under 16 characters. -#: components/workflow-save-draft-button/index.jsx:88 +#: components/workflow-save-draft-button/index.jsx:90 msgid "Save" msgstr "" -#: components/workflow-save-draft-button/index.jsx:97 +#: components/workflow-save-draft-button/index.jsx:99 msgid "Autosaving" msgstr "" -#: components/workflow-save-draft-button/index.jsx:97 +#: components/workflow-save-draft-button/index.jsx:99 msgid "Saving" msgstr "" -#: components/workflow-save-draft-button/index.jsx:99 +#: components/workflow-save-draft-button/index.jsx:101 msgid "Saved" msgstr "" @@ -796,27 +809,27 @@ msgstr "" msgid "Workflow saved." msgstr "" -#: components/workflow-store/actions.jsx:169 +#: components/workflow-store/actions.jsx:170 msgid "Workflow published." msgstr "" -#: components/workflow-store/actions.jsx:177 +#: components/workflow-store/actions.jsx:178 msgid "Unable to publish the workflow. Please, try again." msgstr "" -#: components/workflow-store/actions.jsx:214 +#: components/workflow-store/actions.jsx:216 msgid "Workflow switched to draft." msgstr "" -#: components/workflow-store/actions.jsx:222 +#: components/workflow-store/actions.jsx:224 msgid "Unable to switch workflow to draft. Please, try again." msgstr "" -#: components/workflow-store/actions.jsx:312 +#: components/workflow-store/actions.jsx:314 msgid "Workflow deleted. Redirecting..." msgstr "" -#: components/workflow-store/actions.jsx:323 +#: components/workflow-store/actions.jsx:325 msgid "Unable to delete the workflow. Please, try again." msgstr "" @@ -832,14 +845,14 @@ msgstr "" msgid "Description" msgstr "" -#: components/workflow-switch-to-draft-button/index.jsx:35 +#: components/workflow-switch-to-draft-button/index.jsx:37 msgid "Are you sure you want to unpublish this workflow?" msgstr "" -#: components/workflow-switch-to-draft-button/index.jsx:56 +#: components/workflow-switch-to-draft-button/index.jsx:62 msgid "Draft" msgstr "" -#: components/workflow-switch-to-draft-button/index.jsx:56 +#: components/workflow-switch-to-draft-button/index.jsx:62 msgid "Switch to draft" msgstr "" diff --git a/languages/post-expirator-it_IT-future_backup_panel.json b/languages/post-expirator-it_IT-future_backup_panel.json new file mode 100644 index 000000000..d20431cf4 --- /dev/null +++ b/languages/post-expirator-it_IT-future_backup_panel.json @@ -0,0 +1 @@ +{"domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"","plural_forms":""},"Backup":[""]}}} \ No newline at end of file diff --git a/languages/post-expirator-it_IT-future_backup_panel.l10n.php b/languages/post-expirator-it_IT-future_backup_panel.l10n.php new file mode 100644 index 000000000..e4d7cd784 --- /dev/null +++ b/languages/post-expirator-it_IT-future_backup_panel.l10n.php @@ -0,0 +1,2 @@ +NULL,'plural-forms'=>NULL,'language'=>'','project-id-version'=>'','pot-creation-date'=>'2024-11-27T18:46:33+00:00','po-revision-date'=>'2024-11-27T18:46:33+00:00','messages'=>[]]; \ No newline at end of file diff --git a/languages/post-expirator-it_IT-future_backup_panel.po b/languages/post-expirator-it_IT-future_backup_panel.po new file mode 100644 index 000000000..5432aff94 --- /dev/null +++ b/languages/post-expirator-it_IT-future_backup_panel.po @@ -0,0 +1,16 @@ +msgid "" +msgstr "" +"Project-Id-Version: \n" +"Report-Msgid-Bugs-To: \n" +"Last-Translator: \n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"POT-Creation-Date: 2024-11-27T18:46:33+00:00\n" +"PO-Revision-Date: 2024-11-27T18:46:33+00:00\n" +"Language: \n" + +#: components/BackupPanel.jsx:6 +msgid "Backup" +msgstr "" diff --git a/languages/post-expirator-it_IT.l10n.php b/languages/post-expirator-it_IT.l10n.php index c32348d2e..6ce9ee026 100644 --- a/languages/post-expirator-it_IT.l10n.php +++ b/languages/post-expirator-it_IT.l10n.php @@ -1,2 +1,2 @@ NULL,'plural-forms'=>'nplurals=2; plural=n != 1;','language'=>'it','project-id-version'=>'Plugins - PublishPress Future: Automatically Unpublish WordPress Posts - Stable (latest release)','pot-creation-date'=>'2024-11-19T15:23:53+00:00','po-revision-date'=>'2024-11-20 22:34+0100','x-generator'=>'Poedit 3.4.4','messages'=>['PublishPress Future'=>'PublishPress Future','http://wordpress.org/extend/plugins/post-expirator/'=>'http://wordpress.org/extend/plugins/post-expirator/','PublishPress Future allows you to schedule automatic changes to posts, pages and other content types.'=>'PublishPress Future permette di programmare modifiche automatiche ad articoli, pagine e altri tipi di contenuto.','PublishPress'=>'PublishPress','http://publishpress.com'=>'http://publishpress.com','You do not have permission to configure PublishPress Future.'=>'Non hai i permessi per configurare PublishPress Future.','Debug is disabled'=>'Il debug è disabilitato','Debugging Disabled'=>'Debug disabilitato','Debugging Enabled'=>'Debug abilitato','Debugging Table Emptied'=>'Tabella di debug svuotata','The legacy future actions migration has been enqueued and will run asynchronously.'=>'La migrazione delle azioni Future legacy è stata messa in coda e verrà eseguita in modo asincrono.','The legacy actions arguments restoration has been enqueued and will run asynchronously.'=>'Il ripristino degli argomenti delle azioni legacy è stato messo in coda e verrà eseguito in modo asincrono.','The database schema was fixed.'=>'Lo schema del database è stato corretto.','The database schema could not be fixed. Please, contact the support team.'=>'Non è stato possibile correggere lo schema del database. Contattare il team di assistenza.','Saved Options!'=>'Opzioni salvate!','If you like %1$s, please leave us a %2$s rating. Thank you!'=>'Se ti piace %1$s, lasciaci una valutazione di %2$s. Grazie!','About PublishPress Future'=>'Informazioni su PublishPress Future','About'=>'Chi siamo','Future Documentation'=>'Documentazione di Future','Documentation'=>'Documentazione','Contact the PublishPress team'=>'Contatta il team di PublishPress','Contact'=>'Contatto','No taxonomies found'=>'Nessuna tassonomia trovata','l F jS, Y'=>'l j F Y','g:ia'=>'G:i','Post expires at EXPIRATIONTIME on ACTIONDATE'=>'L\'articolo scade alle EXPIRATIONTIME del ACTIONDATE','The table %s does not exist.'=>'La tabella %s non esiste.','The table indexes are invalid: '=>'Gli indici della tabella non sono validi: ','Invalid date time offset.'=>'Offset della data non valido.','You do not have sufficient permissions to access this page.'=>'Non hai i permessi necessari per accedere a questa pagina.','Invalid nonce.'=>'Nonce non valido.','Categories'=>'Categorie','Future Actions'=>'Azioni Future','Enable Future Action'=>'Abilita scadenza articolo','Action'=>'Come applicare la scadenza','Loading'=>'Caricamento in corso','Show Calendar'=>'Mostra il calendario','Hide Calendar'=>'Nascondi il calendario','Timezone is controlled by the {WordPress Settings}.'=>'Il fuso orario è controllato dalle {Impostazioni di WordPress}.','No %s found.'=>'Nessun %s trovato.','You must assign a taxonomy to this post type to use this feature.'=>'Devi assegnare una tassonomia a questo tipo di contenuto per usare questa caratteristica.','New %s'=>'Nuovo %s','%s to remove'=>'%s da rimuovere','%s to add'=>'%s da aggiungere','Search for %s'=>'Ricerca per %s','Select an action'=>'Seleziona un\'azione','Select a date'=>'Seleziona una data','Date cannot be in the past'=>'La data non può essere già passata','Please select one or more %s'=>'Seleziona uno o più %s','New status'=>'Nuovo stato','No posts selected. Unable to sync Future Actions.'=>'Nessun articolo selezionato. Impossibile sincronizzare le azioni di Future.','Future Actions successfully synced with Post Metadata.'=>'Azioni di Future sincronizzate correttamente con metadati articoli.','Update Future Actions from Post Metadata'=>'Aggiorna le azioni di Future dai metadati degli articoli','Future Action Update'=>'Aggiornamento azioni Future','— No Change —'=>'— Non cambiare —','Add or update action for posts'=>'Aggiungi o aggiorna azione per gli articoli','Add action if none exists for posts'=>'Aggiungi un\'azione se non ne esistono per gli articoli','Update the existing actions for posts'=>'Aggiorna le azioni esistenti per gli articoli','Remove action from posts'=>'Rimuovi l\'azione dagli articoli','Category'=>'Categoria','Settings'=>'Impostazioni','Future Action'=>'Azione Future','Future'=>'Future','Action Settings'=>'Impostazioni delle azioni','Scheduled Actions'=>'Azioni programmate','Log format'=>'Formato del registro','List'=>'Elenco','Popup'=>'Popup','Successfully executed action: %s'=>'L\'azione è stata eseguita con successo: %s','Executed workflow scheduled step'=>'Passaggio programmato del flusso di lavoro eseguito','Cleaned up completed scheduled steps older than %d days'=>'I passaggi programmati completati più vecchi di %d giorni sono stati cancellati','Cleaned up orphan workflow scheduled step arguments'=>'Cancellati gli argomenti dei passaggi programmati dei flussi di lavoro orfani','The shortcode [futureaction] must be used inside the loop or with the post_id attribute.'=>'Lo shortcode [futureaction] deve essere utilizzato dentro il loop o con l\'attributo post_id.','The column args length was not updated to 1000.'=>'La lunghezza degli argomenti della colonna non sono stati aggiornati a 1000.','Status didn\'t change.'=>'Lo stato non è cambiato.','Status has been successfully changed from "%1$s" to "%2$s".'=>'Lo stato è stato cambiado con successo da "%1$s" a "%2$s".','Change status'=>'Cambia stato','%s was not deleted.'=>'%s non è stato eliminato.','%s has been successfully deleted.'=>'%s è stato eliminato correttamente.','Delete'=>'Elimina','No terms were added to the %s.'=>'Nessun termine è stato aggiunto a %s.','The following terms (%1$s) were added to the %2$s: "%3$s". The full list of terms on the post is: %4$s.'=>'I seguenti (%1$s) termini sono stati aggiunti nell\'%2$s: "%3$s". La lista completa dei termini nell\'articolo è: %4$s.','Add extra %s'=>'Aggiungi %s extra','No terms were removed from the %s.'=>'Nessun termine è stato rimosso da %s.','The following terms (%1$s) were removed from the %2$s: %3$s. The new list of terms on the post is: %4$s.'=>'I seguenti (%1$s) termini sono stati rimossi dall\'%2$s: "%3$s". La nuova lista dei termini nell\'articolo è: %4$s.','Remove selected %s'=>'Rimuovi i %s selezionati','The following terms (%1$s) were removed from the %2$s: %3$s.'=>'I seguenti (%1$s) termini sono stati rimossi dall\'%2$s: %3$s.','Remove all %s'=>'Rimuovi tutte le %s','No terms were changed on the %s.'=>'Nessun termine è stato modificato nel %s.','The following terms (%1$s) were set to the %2$s: "%3$s". The old list of terms on the post was: %4$s.'=>'I seguenti termini (%1$s) sono stati impostati su %2$s: "%3$s". La vecchia lista dei termini nell\'articolo era: %4$s.','Replace all %s'=>'Sostituisci tutti i %s','Change status to %s'=>'Cambia lo stato in %s','%s didn\'t change.'=>'%s non è cambiato','%s has been added to stickies list.'=>'%s è stato aggiunto alla lista in evidenza.','Stick'=>'Metti in evidenza','%s has been removed from stickies list.'=>'%s è stato rimosso dalla lista in evidenza.','Unstick'=>'Rimuovi in evidenza','Email is disabled.'=>'L\'email è disabilitata','Email sent.'=>'Email inviata.','Email not sent.'=>'Email non inviata.','%1$s. %2$s on %3$s. The post link is %4$s'=>'%1$s. %2$s il %3$s. Il link dell\'articolo è %4$s','Future Action Complete "%s"'=>'Scadenza articolo completata "%s"','[%1$s] %2$s'=>'[%1$s] %2$s','Invalid date/time offset "%s" for post type "%s". Please ensure you use only English terms for the date/time offset, such as "3 months" or "1 week".'=>'Scostamento data/ora "%s" non valido per il tipo di articolo "%s". Assicurati di utilizzare solo termini inglesi per lo scostamento di data/ora, come "3 months" (3 mesi) o "1 week" (1 settimana).','Status'=>'Stato','Arguments'=>'Argomenti','Logs'=>'Registri','Scheduled Date'=>'Data programmata','Recurrence'=>'Ricorrenza','Run'=>'Esegui','Process the action now'=>'Elabora ora l\'azione','Cancel'=>'Annulla','Cancel the action. This will prevent the action from running in the future'=>'Annulla l\'azione adesso per evitare che venga avviata in seguito','%s year'=>'%s anno' . "\0" . '%s anni','%s month'=>'%s mese' . "\0" . '%s mesi','%s week'=>'%s settimana' . "\0" . '%s settimane','%s day'=>'%s giorno' . "\0" . '%s giorni','%s hour'=>'%s ora' . "\0" . '%s ore','%s minute'=>'%s minuto' . "\0" . '%s minuti','%s second'=>'%s secondo' . "\0" . '%s secondi','Action Logs'=>'Registri delle azioni','Uninitialized'=>'Non inizializzato','Scheduled'=>'Programmato','Complete'=>'Completo','Failed'=>'Fallito','Canceled'=>'Annullato','Running'=>'In esecuzione','All'=>'Tutto','Search hook, args and claim ID'=>'Cerca hook, argomenti e ID richiesta','Completed'=>'Completato','%1$s: [%2$d] %3$s%4$s%5$s'=>'%1$s: [%2$d] %3$s%4$s%5$s','New Status: %s'=>'Nuovo stato: %s','Terms: %s'=>'Termini: %s','View log'=>'Visualizza registro','Action: '=>'Azione: ','Status: '=>'Stato: ','Arguments: '=>'Argomenti: ','Scheduled date: '=>'Data programmata: ','Date'=>'Data','Message'=>'Messaggio','Async'=>'Asincrono',' (%s ago)'=>' (%s fa)',' (%s)'=>' (%s)','Now!'=>'Adesso!','Every %s'=>'Ogni %s','Non-repeating'=>'Non ripetibile','No Scheduled Actions.'=>'Nessuna azione programmata.','Set the offset to use for the default action date and time. For information on formatting, see %1$s. For example, you could enter %2$s+1 month%3$s or %2$s+1 week 2 days 4 hours 2 seconds%3$s or %2$snext Thursday%3$s. Please, use only terms in English.'=>'Imposta lo scostamento da utilizzare per la data e l\'ora delle azioni predefinite. Per informazioni sulla formattazione, vedere %1$s. Ad esempio, si può inserire %2$s+1 month%3$s o %2$s+1 week 2 days 4 hours 2 seconds%3$s o %2$snext Thursday%3$s. Comunque ricordati che puoi inserire solo valori in inglese.','Default Values'=>'Valori predefiniti','Use the values below to set the default actions/values to be used for each for the corresponding post types. These values can all be overwritten when creating/editing the post/page.'=>'Utilizza i seguenti valori per impostare azioni/valori predefiniti da utilizzare per ciascuno dei tipi di contenuto corrispondenti. Questi valori possono essere tutti sovrascritti in fase di creazione/modifica di ciascun articolo/pagina.','Active'=>'Attivo','Activate the PublishPress Future actions for this post type'=>'Abilita le azioni PublishPress Future per questo tipo di contenuto','Default Action'=>'Azione predefinita','Select the default action for the post type.'=>'Seleziona l\'azione di scadenza predefinita per il tipo di contenuto.','Select the taxonomy to be used for actions.'=>'Seleziona la tassonomia da utilizzare per le azioni.','Auto-enable'=>'Abilitazione automatica','Enabled for all new posts'=>'Abilitato per tutti i nuovi articoli','Taxonomy'=>'Tassonomia','No taxonomies found for this post type. Taxonomy actions will not be available.'=>'Non sono state trovate tassonomie per questo tipo di contenuto. Le azioni della tassonomia non saranno disponibili.','Who to Notify'=>'Chi avvisare','Enter a comma separated list of emails that you would like to be notified when the action runs.'=>'Inserisci un elenco di email separate da virgola a cui vuoi inviare una notifica quando l\'azione è in esecuzione.','Default Date/Time Offset'=>'Offset data/ora predefinito','PHP strtotime function'=>'Funzione PHP strtotime','Default terms:'=>'Termini predefiniti:','Save changes'=>'Salva modifiche','Wait for the validation...'=>'Aspetta, validazione in corso…','Date Preview'=>'Anteprima della data','Current Date'=>'Data attuale','Computed Date'=>'Data calcolata','Error'=>'Errore','Scheduled Workflow Steps Cleanup'=>'Pulizia dei passaggi programmati del flusso di lavoro','Automatically remove scheduled workflow steps'=>'Rimuovi automaticamente i passaggi del flusso di lavoro programmati','Automatically remove scheduled workflow steps that have been marked as failed, completed, or cancelled.'=>'Rimuovi automaticamente i passaggi del flusso di lavoro programmati che sono stati contrassegnati come falliti, completati o annullati.','Retain all scheduled workflow steps'=>'Mantieni tutti i passaggi programmati del flusso di lavoro','Retain all scheduled workflow steps indefinitely, including those marked as failed, completed, or cancelled. This may impact database performance over time.'=>'Mantieni tutti i passaggi programmati del flusso di lavoro a tempo indefinito, incluso quelli contrassegnati come falliti, completati o annullati. Questo nel tempo potrebbe influenzare la prestazione del database.','Retention'=>'Mantieni','The duration, in days, for which completed, failed, and canceled scheduled workflow steps will be preserved before automatic removal.'=>'La durata, in giorni, per la quale i passaggi del flusso di lavoro programmati completati, non riusciti e annullati saranno conservati prima della rimozione automatica.','days'=>'giorni','Form Validation Failure: Sorry, your nonce did not verify.'=>'Errore di convalida del modulo: il nonce non è stato verificato.','You\'re using PublishPress Future Free. The Pro version has more features and support. %1$sUpgrade to Pro%2$s'=>'Stai utilizzando PublishPress Future Free. La versione Pro ha più caratteristiche e supporto. %1$sAggiorna a Pro%2$s','Upgrade to Pro'=>'Aggiorna a Pro','Workflow Manual Trigger'=>'Trigger manuale del flusso di lavoro','Action Workflows'=>'Flussi di lavoro di azione','Future Workflow'=>'Flusso di lavoro di Future','Add New'=>'Aggiungi nuovo','Add New Workflow'=>'Aggiungi nuovo flusso di lavoro','Edit Workflow'=>'Modifica flusso di lavoro','New Workflow'=>'Nuovo flusso di lavoro','View Workflow'=>'Visualizza flusso di lavoro','Search Workflows'=>'Cerca flussi di lavoro','No Workflows found'=>'Nessun flusso di lavoro trovato.','No Workflows found in Trash'=>'Nessun flusso di lavoro trovato nel cestino.','Parent Workflow:'=>'Flusso di lavoro genitore:','All Workflows'=>'Tutti i flussi di lavoro','Workflow Archives'=>'Archivi del flusso di lavoro','Insert into workflow'=>'Inserisci nel flusso di lavoro','Uploaded to this workflow'=>'Caricato in questo flusso di lavoro','Filter workflows list'=>'Filtra l\'elenco dei flussi di lavoro','Workflows list navigation'=>'Navigazione elenco flussi di lavoro','Action Workflows list'=>'Elenco dei flusso di lavoro delle azioni','Workflow published.'=>'Flusso di lavoro pubblicato.','Workflow published privately.'=>'Flusso di lavoro pubblicato come privato.','Workflow reverted to draft.'=>'Flusso di lavoro ripristinato a bozza.','Workflow scheduled.'=>'Flusso di lavoro programmato.','Workflow updated.'=>'Flusso di lavoro aggiornato.','Notify when a post is updated'=>'Notifica quando un articolo viene aggiornato','Notify the site admin when a post is updated.'=>'Notifica all\'amministratore del sito quando un articolo viene aggiornato.','Unpublish to Draft after a week'=>'Converti in bozza dopo una settimana','Change the post status to Draft a week after it was published.'=>'Modifica lo stato dell\'articolo in bozza dopo una settimana che è stato pubblicato.','Unpublish and change category after one week'=>'Non pubblicare e cambia categoria dopo una settimana','Move the post to draft and add a category after 15 days.'=>'Sposta l\'articolo in bozza e aggiungi una categoria dopo 15 giorni.','Add extra categories one month after publishing'=>'Aggiungi categorie extra un mese dopo la pubblicazione','Sample workflow to add extra categories one month after publishing'=>'Flusso di lavoro di esempio per aggiungere categorie extra un mese dopo la pubblicazione','Workflow repeating scheduled step'=>'Passaggio programmato che si ripete nel flusso di lavoro','Workflow scheduled step'=>'Passaggio programmato del flusso di lavoro','Unschedule workflow recurring scheduled step'=>'Annullamento dell\'azione ricorrente programmata del flusso di lavoro','Cleanup orphan workflow scheduled step arguments'=>'Cancella gli argomenti dei passaggi programmati dei flussi di lavoro orfani','Clean up completed scheduled steps older than %d days'=>'Cancella i passaggi programmati completati più vecchi di %d giorni','Step not found in workflow.'=>'Passaggio non trovato nel flusso di lavoro.','Workflow:'=>'Flusso di lavoro:','Step:'=>'Passaggio:','Trigger: '=>'Trigger: ','Post:'=>'Articolo:','Steps:'=>'Passaggi:','Workflow recurring scheduled action'=>'Azione ricorrente programmata del flusso di lavoro','%1$s until %2$s'=>'%1$s fino a %2$s','%1$s for %2$d times'=>'%1$s per %2$d volte','[%1$s/%2$d]'=>'[%1$s/%2$d]','Welcome to the workflow editor'=>'Benvenuto nell\'editor del flusso di lavoro','In the PublishPress Workflow Editor, each workflow step is presented as a distinct \'node\' in the workflow.'=>'Nell\'editor del flusso di lavoro di PublishPress, ogni passaggio del flusso di lavoro viene presentato come un “nodo” distinto del flusso di lavoro.','Use your imagination'=>'Usa la tua fantasia','You\'re free to create very distinct workflows in your site, according to your needs.'=>'Sei libero di creare flussi di lavoro molto distinti nel tuo sito, in base alle tue esigenze.','A basic workflow'=>'Un flusso di lavoro di base','Every workflow requires at least two steps connected to each other: one trigger and one action.'=>'Ogni flusso di lavoro richiede almeno due passaggi collegati tra loro: un\'attivazione e un\'azione.','Add steps to your workflow'=>'Aggiungi passaggi al tuo flusso di lavoro','Drag and drop steps to add them to your workflow. Connect the steps to create a workflow.'=>'Trascina e rilascia i passaggi per aggiungerli al tuo flusso di lavoro. Collega i passaggi per creare un flusso di lavoro.','Output and input'=>'Uscita e ingresso','Linked steps can pass data forward as input to the next step.'=>'I passaggi collegati possono trasferire i dati come input al passaggio successivo.','Customize the workflow'=>'Personalizza il flusso di lavoro','Click on a step to customize it. You can change the step\'s settings in the right sidebar.'=>'Fai clic su un passaggio per personalizzarlo. Puoi modificare le impostazioni del passaggio nella barra laterale destra.','Workflow validation'=>'Convalida del flusso di lavoro','Error messages will appear for any unfilled required settings, missed connections, or invalid values. Select the step to view the corresponding error in the sidebar.'=>'I messaggi di errore vengono visualizzati per tutte le impostazioni richieste non compilate, le connessioni mancate o i valori non validi. Seleziona il passaggio per visualizzare l\'errore corrispondente nella barra laterale.','Publish your workflow'=>'Pubblica il tuo flusso di lavoro','When you\'re ready, click the publish button to make your workflow live.'=>'Quando sei pronto, fai clic sul pulsante "Pubblica" per rendere attivo il tuo flusso di lavoro.','Need help?'=>'Hai bisogno di aiuto?','If you have any questions or need help, click the help button in the top right corner to access the support resources.'=>'Se hai domande o hai bisogno di aiuto, fai clic sul pulsante "Aiuto" nell\'angolo in alto a destra per accedere alle risorse di supporto.','Triggers'=>'Trigger: ','Preview'=>'Anteprima','—'=>'—','No screenshot'=>'Nessun screenshot','Activate'=>'Attiva','Deactivate'=>'Disattiva','Action Workflow Editor'=>'Editor dei flusso di lavoro delle azioni','Post Query'=>'Query articolo','A query to select posts'=>'Una query per selezionare gli articoli','Yes'=>'Sì','No'=>'No','The workflow was not triggered.'=>'Il flusso di lavoro non è stato innescato.','The workflow was triggered by the legacy action'=>'Il flusso di lavoro è stato innescato da una azione legacy','Trigger workflow'=>'Trigger del flusso di lavoro','Move post to status'=>'Sposta l\'articolo nello stato','This step transitions a post to a different status.'=>'Questo passaggio sposta un articolo in uno stato differente.','Post'=>'Articolo','The post to update.'=>'L\'articolo da aggiornare.','Select the variable that contains the post to update. It can be a post instance or the post ID.'=>'Selezionare la variabile che contiene l\'articolo da aggiornare. Può essere un\'istanza dell\'articolo o l\'ID dell\'articolo.','The new status that the post will be moved to.'=>'Il nuovo stato in cui verrà spostato l\'articolo.','Step input'=>'Input passaggio','The input data for this step.'=>'I dati di input per questo passaggio.','Next'=>'Successivo','Deactivate Workflow for Post'=>'Disattiva flusso di lavoro per l\'articolo','This step enables you to deactivate the "Manually enabled via checkbox" workflow after use.'=>'Questo passaggio ti consente di disabilitare dopo l\'uso il flusso di lavoro "Abilitato manualmente tramite checkbox".','Workflow'=>'Flusso di lavoro','Select the manually enabling workflow that will be deactivated for the selected post.'=>'Selezionare il flusso di lavoro ad abilitazione manuale che verrà disattivato per l\'articolo selezionato.','Delete post'=>'Elimina articolo','This step deletes a post.'=>'Questo passaggio elimina un articolo.','Stick post'=>'Metti l\'articolo in evidenza','This step sticks a post.'=>'Questo passaggio mette in evidenza un articolo.','The Stick Post action must be part of a Schedule flow'=>'L\'azione dell\'articolo in evidenza deve essere parte di un flusso di programma','Add extra terms to post'=>'Aggiungi termini extra all\'articolo','This step keeps the current taxonomy terms and adds additional terms.'=>'Questo passaggio mantiene i termini della tassonomia attuale e aggiunge dei termini supplementari.','Extra terms'=>'Termini extra','The terms that will be added to the posts.'=>'I termini che saranno aggiunti agli articoli.','Terms'=>'Termini','Remove terms from the post'=>'Rimuovi i termini dall\'articolo','This step removes current taxonomy terms.'=>'Questo passaggio rimuove i termini della tassonomia attuale.','Terms to remove'=>'Termini da rimuovere','The terms that will be removed from the posts.'=>'I termini che saranno rimossi dagli articoli.','Remove all terms'=>'Rimuovi tutti i termini','Replace all terms on the post'=>'Sostituisci tutti i termini dell\'articolo','This step removes the current taxonomy terms and adds new terms.'=>'Questo passaggio rimuove i termini della tassonomia attuale e aggiunge nuovi termini.','New terms'=>'Nuovi termini','The terms that will be added to the posts after removing all the others.'=>'I termini che saranno aggiunti agli articoli dopo aver rimosso gli altri.','Unstick post'=>'Rimuovi l\'articolo da in evidenza','This step unsticks a post.'=>'Questo passaggio rimuove un articolo da in evidenza.','PublishPress Workflow: {{global.workflow.title}}'=>'Flusso di lavoro di PublishPress: {{global.workflow.title}}','This is a message sent by PublishPress Workflow: {{global.workflow.title}}.'=>'Questo è un messaggio inviato dal flusso di lavoro di PublishPress: {{global.workflow.title}}.','Send email'=>'Invia email','This step dispatches a message via email.'=>'Questo passaggio invia un messaggio via email.','The email message'=>'Il messaggio email','Recipient'=>'Destinatario','Subject'=>'Oggetto','Email Recipient'=>'Email destinatario','Custom Email Address'=>'Indirizzo email personalizzato','Conditional Split'=>'Divisione condizionale','This step allows you to create a conditional branch.'=>'Questo passaggio ti consente di creare una diramazione condizionale.','Conditions'=>'Condizioni','The conditions that must be met for deciding which branch to take.'=>'Le condizioni che devono essere soddisfatte per decidere quale ramo prendere.','Branch'=>'Ramo','The current branch on this step.'=>'Il ramo attuale di questo passaggio.','True'=>'Vero','False'=>'Falso','Query posts'=>'Query articoli','This step defines the posts that will be passed to the next step in the workflow.'=>'Questo passaggio definisce gli articoli che passeranno al prossimo passaggio del flusso di lavoro.','Post query'=>'Query articolo','The query defines the posts that will be retrieved by this action.'=>'La query definisce gli articoli che saranno recuperati da questa azione.','Post Type'=>'Tipo di contenuto','Post ID'=>'ID articolo','Array of queried post IDs'=>'Array degli ID degli articoli richiesti','The posts found following the criteria of the query.'=>'L\'articolo trovato secondo i criteri della query.','Schedule'=>'Programma','This step enables actions to be scheduled. You can choose when to run the next step.'=>'Questo passaggio consente di programmare le azioni. Puoi scegliere quando eseguire il passaggio successivo.','A scheduled delay between steps.'=>'Un ritardo programmato tra i passaggi.','Date offset'=>'Scostamento della data','Log - Add'=>'Registro - aggiungi','This step transmits the flow\'s data to the debug log.'=>'Questo passaggio trasmette i dati del flusso al registro di debug.','Debug output'=>'Risultato del debug','The message to be sent to the debug log.'=>'Il messaggio da inviare al registro di debug.','Level'=>'Livello','Ray - Debug'=>'Ray - Debug','This step transmits the flow\'s data to Ray Debug.'=>'Questo passaggio trasmette i dati del flusso a Ray Debug.','The data to be sent to Ray.'=>'I dati che devono essere inviati a Ray.','Data'=>'Dati','Label'=>'Etichetta','Color'=>'Colore','On admin init'=>'All\'inizializzazione dell\'amministrazione','This trigger activates upon the initialization of the admin site.'=>'Questo trigger si attiva dopo l\'inizializzazione del sito dell\'ammistratore.','On cron schedule'=>'Con la programmazione cron','This trigger activates upon a cron schedule, allowing recurrency.'=>'Questo trigger si attiva in base a una programmazione cron, consentendo la ricorrenza.','A schedule to activate the workflow.'=>'Un programma per attivare flusso di lavoro.','On site init'=>'All\'inizializzazione del sito','This trigger activates upon site initialization.'=>'Questo trigger si attiva dopo l\'inizializzazione del sito.','Manually enabled via checkbox'=>'Abilitato manualmente tramite checkbox','This trigger activates when the option is manually enabled. It can be enabled via the post editing screen or the Quick Edit panel.'=>'Questo trigger si attiva quando l\'opzione è abilitata manualmente. Può essere abilitata dalla schermata di modifica dell\'articolo o dal pannello "Modifica rapida".','Settings for the trigger.'=>'Impostazioni per il trigger.','Checkbox label'=>'Etichetta checkbox','The label of the checkbox that enables the trigger.'=>'L\'etichetta del checkbox che attiva il trigger.','Specify the criteria for posts that will trigger this action. Leave blank to include all posts.'=>'Specifica i criteri per gli articoli che attiveranno quest\'azione. Lascia vuoto per includere tutti gli articoli.','The query defines the posts that will trigger this action.'=>'La query definisce gli articoli che saranno recuperati da questa azione.','Saved post'=>'Articolo salvato','The post that was saved, with the new properties.'=>'L\'articolo salvato con le nuove proprietà.','Post is updated'=>'Articolo aggiornato','This trigger activates when an existing post is updated.'=>'Questo trigger si attiva quando un articolo esistente viene aggiornato.','Post Before Update'=>'Articolo prima dell\'aggiornamento','The post that was saved, with the old properties.'=>'L\'articolo salvato con le vecchie proprietà.','Post After Update'=>'Articolo dopo l\'aggiornamento','Post is saved'=>'Articolo salvato','This trigger activates whenever a post is saved, regardless of whether it\'s newly created, imported, or updated.'=>'Questo trigger si attiva quando un articolo viene salvato, indipendentemente dal fatto che sia stato creato, importato o aggiornato.','Manually enabled via Future Actions box'=>'Abilitato manualmente tramite il riquadro delle azioni di Future','This trigger allows users to choose the workflow from the dropdown menu in the Future Actions options.'=>'Questo trigger consente agli utenti di scegliere il flusso di lavoro dal menu a discesa delle opzioni per le "Azioni Future".','Action Post'=>'Articolo d\'azione','The post that was saved triggering the action.'=>'L\'articolo salvato che ha innescato l\'azione.','Site'=>'Sito','Flow Control'=>'Controlla flusso','Asynchronous'=>'Asincrono','Debug'=>'Debug','Data Query'=>'Query dei dati','Messages'=>'Messaggi','The ID of the workflow'=>'L\'ID del flusso di lavoro','The taxonomy name'=>'Il nome della tassonomia','The post ID'=>'L\'ID dell\'articolo','Workflow not found'=>'Flusso di lavoro non trovato','Loading the workflow editor...'=>'Caricamento dell\'editor del flusso di lavoro in corso…','Screenshot'=>'Screenshot','Upgrade to PublishPress Future Pro'=>'Aggiorna a PublishPress Future Pro','Enhance the power of PublishPress Future with the Pro version:'=>'Aumenta le potenzialità di PublishPress Future con la versione Pro:','Design custom workflows with multiple actions'=>'Disegna flussi di lavoro personalizzati con azioni multiple','Schedule actions based on the post\'s publishing date'=>'Programma la data dell\'azione basata sulla data di pubblicazione dell\'articolo','Move posts to custom statuses'=>'Sposta gli articoli negli stati personalizzati','Use other plugins to control Future Actions'=>'Utilizza gli altri plugin per controllare le azioni di "Future"','Enjoy fast and professional support'=>'Godi di un supporto rapido e professionale','Need PublishPress Future Support?'=>'Hai bisogno del supporto di PublishPress Future?','If you need help or have a new feature request, let us know.'=>'Se hai bisogno di aiuto o hai delle richieste di funzionalità, faccelo sapere.','Request Support'=>'Rchiesta di supporto','Detailed documentation is also available on the plugin website.'=>'Una documentazione dettagliata è anche disponibile sul sito web del plugin.','View Knowledge Base'=>'Vedi la documentazione','%1$s%2$s%3$s on %5$s%4$s%6$s'=>'%1$s%2$s%3$s il %5$s%4$s%6$s','Action was not scheduled due to a configuration issue. Please attempt to schedule it again.'=>'L\'azione non può essere programmata a causa di un problema di configurazione. Prova a riprogrammarla nuovamente.','No future action'=>'Nessuna azione Future','Advanced Options'=>'Opzioni avanzate','Workflow Step Schedule\'s Arguments Compression'=>'Passaggio del flusso di lavoro della compressione programmata degli argomenti','Compress the arguments'=>'Comprimi gli argomenti','Compress the arguments of the step schedule to save memory in the database, saving them as binary data.'=>'Comprimi gli argomenti del passaggio programmato per risparmiare memoria nel database, salvandoli come dati binari.','Do not compress the arguments'=>'Non comprimere gli argomenti','Do not compress the arguments of the step schedule, storing them as plain text.'=>'Non comprimere gli argomenti del passaggio programmato, immagazzinali come testo semplice.','Experimental Features'=>'Caratteristiche sperimentali','Enable experimental features'=>'Abilita le caratteristiche sperimentali','Enable experimental features that are still in development and may not be fully functional.'=>'Abilita le caratteristiche sperimentali che sono ancora in fase di sviluppo e potrebbero non funzionare correttamente.','Preserve Data After Deactivating the Plugin'=>'Conserva i dati dopo la disattivazione del plugin','Preserve data'=>'Conserva i dati','Delete data'=>'Elimina i dati','Toggle between preserving or deleting data after the plugin is deactivated.'=>'Attiva/disattiva la conservazione o l\'eliminazione dei dati dopo la disattivazione del plugin.','Save Changes'=>'Salva modifiche','Below is a dump of the debugging table, this should be useful for troubleshooting.'=>'Di seguito è riportato un dump della tabella di debug, questo dovrebbe essere utile per la risoluzione dei problemi.','Debugging table is currently empty.'=>'La tabella di debug è attualmente vuota.','Number of logs to display:'=>'Numero di registrazioni da visualizzare:','Showing the latest %d of %d results. The approximate size of the log is %s.'=>'Visualizzazione degli ultimi risultati %d di %d. La dimensione approssimativa del registro è %s.','Showing all %d results. The approximate size of the log is %s.'=>'Visualizzazione di tutti i risultati %d. La dimensione approssimativa del registro è %s.','Copy Debug Log'=>'Copiaa il registro di debug','Download Entire Log'=>'Scarica il registro completo','Debug log copied to clipboard!'=>'Registro di debug copiato negli appunti!','Advanced Diagnostics and Tools'=>'Diagnostica e strumenti avanzati','WP-Cron Status Check'=>'Controllo stato di WP-Cron','Passed'=>'Approvato','WP Cron Disabled'=>'WP Cron disabilitato','Database Schema Check'=>'Controllo schema database','Error found on the database schema:'=>'Trovato un errore nello schema del database:' . "\0" . 'Trovati degli errori nello schema del database:','Try to Fix Database'=>'Cerca di correggere il database','Debug Logging'=>'Registrazione di debug','Enabled'=>'Abilitato','Disable Debugging'=>'Disattiva il debugging','Purge Debug Log'=>'Svuota il registro di debug','View Debug Logs'=>'Visualizza i log di debug','Disabled'=>'Disabilitato','Enable Debugging'=>'Attiva il debugging','Migrate Legacy Future Actions'=>'Migrare le azioni Future legacy','Run Migration'=>'Esegui migrazione','Migrate legacy future actions from WP Cron to the new Action Scheduler. This will run in the background and may take a while.'=>'Migrare le azioni Future legacy da WP Cron al nuovo Programmatore di azioni. Questa operazione verrà eseguita in background e potrebbe richiedere un po\' di tempo.','Restore Legacy Action Arguments'=>'Ripristina gli argomenti delle azioni precedenti','Run Data Restoration'=>'Avvia il ripristino del database','Restore legacy action arguments as Post Meta. This is useful if you have issues with 3rd party plugins that read that data. This will run in the background and may take a while.'=>'Ripristina gli argomenti delle azioni legacy come meta degli articoli. Utile se si hanno problemi con i plugin di terze parti che leggono questi dati. L\'esecuzione averrà in background e potrebbe richiedere un po\' di tempo.','Legacy Cron Schedule'=>'Programma di Cron Legacy','The below table will show all currently scheduled cron events for the plugin with the next run time.'=>'La tabella seguente mostra tutti gli eventi cron attualmente programmati per il plugin con il prossimo orario di esecuzione.','Event'=>'Evento','Posts and expiration settings'=>'Impostazioni degli articoli e della scadenza','This is a legacy feature and will be removed in a future version.'=>'Questa è una funzionalità legacy che sarà rimossa in una prossima versione.','Default Formats'=>'Formati predefiniti','Date Format'=>'Formato data','The default format to use when displaying the action date within a post using the shortcode or within the footer. For information on valid formatting options, see: %s.'=>'Il formato predefinito da utilizzare quando si visualizza la data di scadenza all\'interno di un articolo utilizzando lo shortcode o nel footer. Per informazioni sulle opzioni di formattazione valide, vedere: %s.','PHP Date Function'=>'Funzione data PHP','Time Format'=>'Formato ora','The default format to use when displaying the action time within a post using the shortcode or within the footer. For information on valid formatting options, see: %s.'=>'Il formato predefinito da utilizzare quando si visualizza l\'ora di scadenza all\'interno di un articolo utilizzando lo shortcode o nel footer. Per informazioni sulle opzioni di formattazione valide, vedere: %s.','Future actions column'=>'Colonna azioni Future','Future Action Column Style'=>'Stile colonna delle azioni Future','Detailed'=>'Dettagliate','Displays all information in the Future Action column.'=>'Visualizza tutte le informazioni nella colonna "Azioni di Future".','Simplified'=>'Semplificate','Displays only the icon and date/time.'=>'Visualizza solo l\'icona, la data e l\'ora.','Future actions editor'=>'Editor azioni Future','Time format in the date picker'=>'Formato dell\'ora nel selezionatore di data','Inherit from Site Settings'=>'Eredita dalle impostazioni del sito','24 hours'=>'24 ore','AM/PM'=>'AM/PM','Post Footer Display'=>'Visualizzazione nel footer','Enabling this below will display the action date automatically at the end of any post which is set to run an action.'=>'Abilitando l\'opzione seguente verrà mostrata automaticamente la data di scadenza alla fine di ogni articolo che è impostato per scadere.','Show in Post Footer?'=>'Mostrare nel footer dell\'articolo?','This will enable or disable displaying the future action date in the post footer.'=>'Questo abiliterà o disabiliterà la visualizzazione della data di scadenza dell\'articolo nel footer dello stesso.','Footer Contents'=>'Contenuto del footer','Enter the text you would like to appear at the bottom of every post which has an action scheduled. The following placeholders will be replaced with the future action date in the following format:'=>'Inserisci il testo che vorresti far apparire in fondo a ogni articolo impostato con una scadenza. I seguenti segnaposto verranno sostituiti con la data di scadenza nel modo indicato:','Footer Style'=>'Stile del footer','The inline css which will be used to style the footer text.'=>'Il css inline che verrà utilizzato per definire lo stile del testo del footer.','Example: '=>'Esempio: ','Shortcode'=>'Shortcode','Valid %s attributes:'=>'Attributi %s validi:','%1$stype%2$s - valid options are %1$sfull%2$s (default), %1$sdate%2$s, %1$stime%2$s'=>'%1$stipo%2$s - le opzioni valide sono %1$scompleta%2$s (predefinito), %1$sdata%2$s, %1$sora%2$s','%s - format set here will override the value set on the settings page'=>'%s - il formato impostato qui sovrascrive il valore configurato nella pagina delle impostazioni','Defaults'=>'Valori predefiniti','Calendar Visibility'=>'Visibilità del calendario','Remember last state'=>'Ricorda l\'ultimo stato','Shows or hides the calendar based on the last user interaction.'=>'Mostra o nasconde il calendario in funzione dell\'ultima interazione dell\'utente.','Always hidden'=>'Sempre nascosto','The calendar is always hidden by default.'=>'Il calendario è sempre nascosto per impostazione predefinita.','Permissions'=>'Autorizzazioni','Choose Which User Roles Can Use PublishPress Future'=>'Scegli quali ruoli utente possono utilizzare PublishPress Future','Email Notification'=>'Email di notifica scadenza','Whenever an action runs, an email can be sent to alert users.'=>'Ogni volta che un articolo scade, un\'email può essere spedita per avvisare gli utenti della scadenza.','Enable Email Notification?'=>'Abilita notifica email?','This will enable or disable the send of email notification on future action.'=>'Questo abiliterà o disabiliterà l\'invio della notifica via email alla scadenza dell\'articolo.','Include Blog Administrators?'=>'Includere gli amministratori del blog?','This will include all users with the role of "Administrator" in the email.'=>'Ciò includerà tutti gli utenti con il ruolo di "Amministratore" nell\'email di scadenza dell\'articolo.','Enter a comma separate list of emails that you would like to be notified when the action runs. This will be applied to ALL post types. You can set post type specific emails on the Defaults tab.'=>'Inserisci un elenco di email separate da virgole a cui ti piacerebbe inviare una notifica quando scade l\'articolo. Questo sarà applicato a tutti i tipi di contenuto. È possibile impostare email specifiche per un tipo di contenuto nella scheda "Valori predefiniti".','Post Types'=>'Tipi di contenuto','General'=>'Generale','Display'=>'Visualizza','Advanced'=>'Avanzate','Diagnostics and Tools'=>'Diagnostica e strumenti']]; \ No newline at end of file +return ['domain'=>NULL,'plural-forms'=>'nplurals=2; plural=n != 1;','language'=>'it','project-id-version'=>'Plugins - PublishPress Future: Automatically Unpublish WordPress Posts - Stable (latest release)','pot-creation-date'=>'2024-11-19T15:23:53+00:00','po-revision-date'=>'2024-11-20 22:34+0100','x-generator'=>'Poedit 3.4.4','messages'=>['PublishPress Future'=>'PublishPress Future','http://wordpress.org/extend/plugins/post-expirator/'=>'http://wordpress.org/extend/plugins/post-expirator/','PublishPress Future allows you to schedule automatic changes to posts, pages and other content types.'=>'PublishPress Future permette di programmare modifiche automatiche ad articoli, pagine e altri tipi di contenuto.','PublishPress'=>'PublishPress','http://publishpress.com'=>'http://publishpress.com','You do not have permission to configure PublishPress Future.'=>'Non hai i permessi per configurare PublishPress Future.','Debug is disabled'=>'Il debug è disabilitato','Debugging Disabled'=>'Debug disabilitato','Debugging Enabled'=>'Debug abilitato','Debugging Table Emptied'=>'Tabella di debug svuotata','The legacy future actions migration has been enqueued and will run asynchronously.'=>'La migrazione delle azioni Future legacy è stata messa in coda e verrà eseguita in modo asincrono.','The legacy actions arguments restoration has been enqueued and will run asynchronously.'=>'Il ripristino degli argomenti delle azioni legacy è stato messo in coda e verrà eseguito in modo asincrono.','The database schema was fixed.'=>'Lo schema del database è stato corretto.','The database schema could not be fixed. Please, contact the support team.'=>'Non è stato possibile correggere lo schema del database. Contattare il team di assistenza.','Saved Options!'=>'Opzioni salvate!','If you like %1$s, please leave us a %2$s rating. Thank you!'=>'Se ti piace %1$s, lasciaci una valutazione di %2$s. Grazie!','About PublishPress Future'=>'Informazioni su PublishPress Future','About'=>'Chi siamo','Future Documentation'=>'Documentazione di Future','Documentation'=>'Documentazione','Contact the PublishPress team'=>'Contatta il team di PublishPress','Contact'=>'Contatto','No taxonomies found'=>'Nessuna tassonomia trovata','l F jS, Y'=>'l j F Y','g:ia'=>'G:i','Post expires at EXPIRATIONTIME on ACTIONDATE'=>'L\'articolo scade alle EXPIRATIONTIME del ACTIONDATE','The table %s does not exist.'=>'La tabella %s non esiste.','The table indexes are invalid: '=>'Gli indici della tabella non sono validi: ','Invalid date time offset.'=>'Offset della data non valido.','You do not have sufficient permissions to access this page.'=>'Non hai i permessi necessari per accedere a questa pagina.','Invalid nonce.'=>'Nonce non valido.','Categories'=>'Categorie','Future Actions'=>'Azioni Future','Enable Future Action'=>'Abilita scadenza articolo','Action'=>'Come applicare la scadenza','Loading'=>'Caricamento in corso','Show Calendar'=>'Mostra il calendario','Hide Calendar'=>'Nascondi il calendario','Timezone is controlled by the {WordPress Settings}.'=>'Il fuso orario è controllato dalle {Impostazioni di WordPress}.','No %s found.'=>'Nessun %s trovato.','You must assign a taxonomy to this post type to use this feature.'=>'Devi assegnare una tassonomia a questo tipo di contenuto per usare questa caratteristica.','New %s'=>'Nuovo %s','%s to remove'=>'%s da rimuovere','%s to add'=>'%s da aggiungere','Search for %s'=>'Ricerca per %s','Select an action'=>'Seleziona un\'azione','Select a date'=>'Seleziona una data','Date cannot be in the past'=>'La data non può essere già passata','Please select one or more %s'=>'Seleziona uno o più %s','New status'=>'Nuovo stato','No posts selected. Unable to sync Future Actions.'=>'Nessun articolo selezionato. Impossibile sincronizzare le azioni di Future.','Future Actions successfully synced with Post Metadata.'=>'Azioni di Future sincronizzate correttamente con metadati articoli.','Update Future Actions from Post Metadata'=>'Aggiorna le azioni di Future dai metadati degli articoli','Future Action Update'=>'Aggiornamento azioni Future','— No Change —'=>'— Non cambiare —','Add or update action for posts'=>'Aggiungi o aggiorna azione per gli articoli','Add action if none exists for posts'=>'Aggiungi un\'azione se non ne esistono per gli articoli','Update the existing actions for posts'=>'Aggiorna le azioni esistenti per gli articoli','Remove action from posts'=>'Rimuovi l\'azione dagli articoli','Category'=>'Categoria','Settings'=>'Impostazioni','Future Action'=>'Azione Future','Future'=>'Future','Action Settings'=>'Impostazioni delle azioni','Scheduled Actions'=>'Azioni programmate','Log format'=>'Formato del registro','List'=>'Elenco','Popup'=>'Popup','Successfully executed action: %s'=>'L\'azione è stata eseguita con successo: %s','Executed workflow scheduled step'=>'Passaggio programmato del flusso di lavoro eseguito','Cleaned up completed scheduled steps older than %d days'=>'I passaggi programmati completati più vecchi di %d giorni sono stati cancellati','Cleaned up orphan workflow scheduled step arguments'=>'Cancellati gli argomenti dei passaggi programmati dei flussi di lavoro orfani','The shortcode [futureaction] must be used inside the loop or with the post_id attribute.'=>'Lo shortcode [futureaction] deve essere utilizzato dentro il loop o con l\'attributo post_id.','The column args length was not updated to 1000.'=>'La lunghezza degli argomenti della colonna non sono stati aggiornati a 1000.','Status didn\'t change.'=>'Lo stato non è cambiato.','Status has been successfully changed from "%1$s" to "%2$s".'=>'Lo stato è stato cambiado con successo da "%1$s" a "%2$s".','Change status'=>'Cambia stato','%s was not deleted.'=>'%s non è stato eliminato.','%s has been successfully deleted.'=>'%s è stato eliminato correttamente.','Delete'=>'Elimina','No terms were added to the %s.'=>'Nessun termine è stato aggiunto a %s.','The following terms (%1$s) were added to the %2$s: "%3$s". The full list of terms on the post is: %4$s.'=>'I seguenti (%1$s) termini sono stati aggiunti nell\'%2$s: "%3$s". La lista completa dei termini nell\'articolo è: %4$s.','Add extra %s'=>'Aggiungi %s extra','No terms were removed from the %s.'=>'Nessun termine è stato rimosso da %s.','The following terms (%1$s) were removed from the %2$s: %3$s. The new list of terms on the post is: %4$s.'=>'I seguenti (%1$s) termini sono stati rimossi dall\'%2$s: "%3$s". La nuova lista dei termini nell\'articolo è: %4$s.','Remove selected %s'=>'Rimuovi i %s selezionati','The following terms (%1$s) were removed from the %2$s: %3$s.'=>'I seguenti (%1$s) termini sono stati rimossi dall\'%2$s: %3$s.','Remove all %s'=>'Rimuovi tutte le %s','No terms were changed on the %s.'=>'Nessun termine è stato modificato nel %s.','The following terms (%1$s) were set to the %2$s: "%3$s". The old list of terms on the post was: %4$s.'=>'I seguenti termini (%1$s) sono stati impostati su %2$s: "%3$s". La vecchia lista dei termini nell\'articolo era: %4$s.','Replace all %s'=>'Sostituisci tutti i %s','Change status to %s'=>'Cambia lo stato in %s','%s didn\'t change.'=>'%s non è cambiato','%s has been added to stickies list.'=>'%s è stato aggiunto alla lista in evidenza.','Stick'=>'Metti in evidenza','%s has been removed from stickies list.'=>'%s è stato rimosso dalla lista in evidenza.','Unstick'=>'Rimuovi in evidenza','Email is disabled.'=>'L\'email è disabilitata','Email sent.'=>'Email inviata.','Email not sent.'=>'Email non inviata.','%1$s. %2$s on %3$s. The post link is %4$s'=>'%1$s. %2$s il %3$s. Il link dell\'articolo è %4$s','Future Action Complete "%s"'=>'Scadenza articolo completata "%s"','[%1$s] %2$s'=>'[%1$s] %2$s','Invalid date/time offset "%s" for post type "%s". Please ensure you use only English terms for the date/time offset, such as "3 months" or "1 week".'=>'Scostamento data/ora "%s" non valido per il tipo di articolo "%s". Assicurati di utilizzare solo termini inglesi per lo scostamento di data/ora, come "3 months" (3 mesi) o "1 week" (1 settimana).','Status'=>'Stato','Arguments'=>'Argomenti','Logs'=>'Registri','Scheduled Date'=>'Data programmata','Recurrence'=>'Ricorrenza','Run'=>'Esegui','Process the action now'=>'Elabora ora l\'azione','Cancel'=>'Annulla','Cancel the action. This will prevent the action from running in the future'=>'Annulla l\'azione adesso per evitare che venga avviata in seguito','%s year'=>'%s anno' . "\0" . '%s anni','%s month'=>'%s mese' . "\0" . '%s mesi','%s week'=>'%s settimana' . "\0" . '%s settimane','%s day'=>'%s giorno' . "\0" . '%s giorni','%s hour'=>'%s ora' . "\0" . '%s ore','%s minute'=>'%s minuto' . "\0" . '%s minuti','%s second'=>'%s secondo' . "\0" . '%s secondi','Action Logs'=>'Registri delle azioni','Uninitialized'=>'Non inizializzato','Scheduled'=>'Programmato','Complete'=>'Completo','Failed'=>'Fallito','Canceled'=>'Annullato','Running'=>'In esecuzione','All'=>'Tutto','Search hook, args and claim ID'=>'Cerca hook, argomenti e ID richiesta','Completed'=>'Completato','%1$s: [%2$d] %3$s%4$s%5$s'=>'%1$s: [%2$d] %3$s%4$s%5$s','New Status: %s'=>'Nuovo stato: %s','Terms: %s'=>'Termini: %s','View log'=>'Visualizza registro','Action: '=>'Azione: ','Status: '=>'Stato: ','Arguments: '=>'Argomenti: ','Scheduled date: '=>'Data programmata: ','Date'=>'Data','Message'=>'Messaggio','Async'=>'Asincrono',' (%s ago)'=>' (%s fa)',' (%s)'=>' (%s)','Now!'=>'Adesso!','Every %s'=>'Ogni %s','Non-repeating'=>'Non ripetibile','No Scheduled Actions.'=>'Nessuna azione programmata.','Set the offset to use for the default action date and time. For information on formatting, see %1$s. For example, you could enter %2$s+1 month%3$s or %2$s+1 week 2 days 4 hours 2 seconds%3$s or %2$snext Thursday%3$s. Please, use only terms in English.'=>'Imposta lo scostamento da utilizzare per la data e l\'ora delle azioni predefinite. Per informazioni sulla formattazione, vedere %1$s. Ad esempio, si può inserire %2$s+1 month%3$s o %2$s+1 week 2 days 4 hours 2 seconds%3$s o %2$snext Thursday%3$s. Comunque ricordati che puoi inserire solo valori in inglese.','Default Values'=>'Valori predefiniti','Use the values below to set the default actions/values to be used for each for the corresponding post types. These values can all be overwritten when creating/editing the post/page.'=>'Utilizza i seguenti valori per impostare azioni/valori predefiniti da utilizzare per ciascuno dei tipi di contenuto corrispondenti. Questi valori possono essere tutti sovrascritti in fase di creazione/modifica di ciascun articolo/pagina.','Active'=>'Attivo','Activate the PublishPress Future actions for this post type'=>'Abilita le azioni PublishPress Future per questo tipo di contenuto','Default Action'=>'Azione predefinita','Select the default action for the post type.'=>'Seleziona l\'azione di scadenza predefinita per il tipo di contenuto.','Select the taxonomy to be used for actions.'=>'Seleziona la tassonomia da utilizzare per le azioni.','Auto-enable'=>'Abilitazione automatica','Enabled for all new posts'=>'Abilitato per tutti i nuovi articoli','Taxonomy'=>'Tassonomia','No taxonomies found for this post type. Taxonomy actions will not be available.'=>'Non sono state trovate tassonomie per questo tipo di contenuto. Le azioni della tassonomia non saranno disponibili.','Who to Notify'=>'Chi avvisare','Enter a comma separated list of emails that you would like to be notified when the action runs.'=>'Inserisci un elenco di email separate da virgola a cui vuoi inviare una notifica quando l\'azione è in esecuzione.','Default Date/Time Offset'=>'Offset data/ora predefinito','PHP strtotime function'=>'Funzione PHP strtotime','Default terms:'=>'Termini predefiniti:','Save changes'=>'Salva modifiche','Wait for the validation...'=>'Aspetta, validazione in corso…','Date Preview'=>'Anteprima della data','Current Date'=>'Data attuale','Computed Date'=>'Data calcolata','Error'=>'Errore','Scheduled Workflow Steps Cleanup'=>'Pulizia dei passaggi programmati del flusso di lavoro','Automatically remove scheduled workflow steps'=>'Rimuovi automaticamente i passaggi del flusso di lavoro programmati','Automatically remove scheduled workflow steps that have been marked as failed, completed, or cancelled.'=>'Rimuovi automaticamente i passaggi del flusso di lavoro programmati che sono stati contrassegnati come falliti, completati o annullati.','Retain all scheduled workflow steps'=>'Mantieni tutti i passaggi programmati del flusso di lavoro','Retain all scheduled workflow steps indefinitely, including those marked as failed, completed, or cancelled. This may impact database performance over time.'=>'Mantieni tutti i passaggi programmati del flusso di lavoro a tempo indefinito, incluso quelli contrassegnati come falliti, completati o annullati. Questo nel tempo potrebbe influenzare la prestazione del database.','Retention'=>'Mantieni','The duration, in days, for which completed, failed, and canceled scheduled workflow steps will be preserved before automatic removal.'=>'La durata, in giorni, per la quale i passaggi del flusso di lavoro programmati completati, non riusciti e annullati saranno conservati prima della rimozione automatica.','days'=>'giorni','Form Validation Failure: Sorry, your nonce did not verify.'=>'Errore di convalida del modulo: il nonce non è stato verificato.','You\'re using PublishPress Future Free. The Pro version has more features and support. %1$sUpgrade to Pro%2$s'=>'Stai utilizzando PublishPress Future Free. La versione Pro ha più caratteristiche e supporto. %1$sAggiorna a Pro%2$s','Upgrade to Pro'=>'Aggiorna a Pro','Workflow Manual Trigger'=>'Trigger manuale del flusso di lavoro','Action Workflows'=>'Flussi di lavoro di azione','Future Workflow'=>'Flusso di lavoro di Future','Add New'=>'Aggiungi nuovo','Add New Workflow'=>'Aggiungi nuovo flusso di lavoro','Edit Workflow'=>'Modifica flusso di lavoro','New Workflow'=>'Nuovo flusso di lavoro','View Workflow'=>'Visualizza flusso di lavoro','Search Workflows'=>'Cerca flussi di lavoro','No Workflows found'=>'Nessun flusso di lavoro trovato.','No Workflows found in Trash'=>'Nessun flusso di lavoro trovato nel cestino.','Parent Workflow:'=>'Flusso di lavoro genitore:','All Workflows'=>'Tutti i flussi di lavoro','Workflow Archives'=>'Archivi del flusso di lavoro','Insert into workflow'=>'Inserisci nel flusso di lavoro','Uploaded to this workflow'=>'Caricato in questo flusso di lavoro','Filter workflows list'=>'Filtra l\'elenco dei flussi di lavoro','Workflows list navigation'=>'Navigazione elenco flussi di lavoro','Action Workflows list'=>'Elenco dei flusso di lavoro delle azioni','Workflow published.'=>'Flusso di lavoro pubblicato.','Workflow published privately.'=>'Flusso di lavoro pubblicato come privato.','Workflow reverted to draft.'=>'Flusso di lavoro ripristinato a bozza.','Workflow scheduled.'=>'Flusso di lavoro programmato.','Workflow updated.'=>'Flusso di lavoro aggiornato.','Notify when a post is updated'=>'Notifica quando un articolo viene aggiornato','Notify the site admin when a post is updated.'=>'Notifica all\'amministratore del sito quando un articolo viene aggiornato.','Unpublish to Draft after a week'=>'Converti in bozza dopo una settimana','Change the post status to Draft a week after it was published.'=>'Modifica lo stato dell\'articolo in bozza dopo una settimana che è stato pubblicato.','Unpublish and change category after one week'=>'Non pubblicare e cambia categoria dopo una settimana','Move the post to draft and add a category after 15 days.'=>'Sposta l\'articolo in bozza e aggiungi una categoria dopo 15 giorni.','Add extra categories one month after publishing'=>'Aggiungi categorie extra un mese dopo la pubblicazione','Sample workflow to add extra categories one month after publishing'=>'Flusso di lavoro di esempio per aggiungere categorie extra un mese dopo la pubblicazione','Workflow repeating scheduled step'=>'Passaggio programmato che si ripete nel flusso di lavoro','Workflow scheduled step'=>'Passaggio programmato del flusso di lavoro','Unschedule workflow recurring scheduled step'=>'Annullamento dell\'azione ricorrente programmata del flusso di lavoro','Cleanup orphan workflow scheduled step arguments'=>'Cancella gli argomenti dei passaggi programmati dei flussi di lavoro orfani','Clean up completed scheduled steps older than %d days'=>'Cancella i passaggi programmati completati più vecchi di %d giorni','Step not found in workflow.'=>'Passaggio non trovato nel flusso di lavoro.','Workflow:'=>'Flusso di lavoro:','Step:'=>'Passaggio:','Trigger: '=>'Trigger: ','Post:'=>'Articolo:','Steps:'=>'Passaggi:','Workflow recurring scheduled action'=>'Azione ricorrente programmata del flusso di lavoro','%1$s until %2$s'=>'%1$s fino a %2$s','%1$s for %2$d times'=>'%1$s per %2$d volte','[%1$s/%2$d]'=>'[%1$s/%2$d]','Welcome to the workflow editor'=>'Benvenuto nell\'editor del flusso di lavoro','In the PublishPress Workflow Editor, each workflow step is presented as a distinct \'node\' in the workflow.'=>'Nell\'editor del flusso di lavoro di PublishPress, ogni passaggio del flusso di lavoro viene presentato come un “nodo” distinto del flusso di lavoro.','Use your imagination'=>'Usa la tua fantasia','You\'re free to create very distinct workflows in your site, according to your needs.'=>'Sei libero di creare flussi di lavoro molto distinti nel tuo sito, in base alle tue esigenze.','A basic workflow'=>'Un flusso di lavoro di base','Every workflow requires at least two steps connected to each other: one trigger and one action.'=>'Ogni flusso di lavoro richiede almeno due passaggi collegati tra loro: un\'attivazione e un\'azione.','Add steps to your workflow'=>'Aggiungi passaggi al tuo flusso di lavoro','Drag and drop steps to add them to your workflow. Connect the steps to create a workflow.'=>'Trascina e rilascia i passaggi per aggiungerli al tuo flusso di lavoro. Collega i passaggi per creare un flusso di lavoro.','Output and input'=>'Uscita e ingresso','Linked steps can pass data forward as input to the next step.'=>'I passaggi collegati possono trasferire i dati come input al passaggio successivo.','Customize the workflow'=>'Personalizza il flusso di lavoro','Click on a step to customize it. You can change the step\'s settings in the right sidebar.'=>'Fai clic su un passaggio per personalizzarlo. Puoi modificare le impostazioni del passaggio nella barra laterale destra.','Workflow validation'=>'Convalida del flusso di lavoro','Error messages will appear for any unfilled required settings, missed connections, or invalid values. Select the step to view the corresponding error in the sidebar.'=>'I messaggi di errore vengono visualizzati per tutte le impostazioni richieste non compilate, le connessioni mancate o i valori non validi. Seleziona il passaggio per visualizzare l\'errore corrispondente nella barra laterale.','Publish your workflow'=>'Pubblica il tuo flusso di lavoro','When you\'re ready, click the publish button to make your workflow live.'=>'Quando sei pronto, fai clic sul pulsante "Pubblica" per rendere attivo il tuo flusso di lavoro.','Need help?'=>'Hai bisogno di aiuto?','If you have any questions or need help, click the help button in the top right corner to access the support resources.'=>'Se hai domande o hai bisogno di aiuto, fai clic sul pulsante "Aiuto" nell\'angolo in alto a destra per accedere alle risorse di supporto.','Triggers'=>'Trigger: ','Preview'=>'Anteprima','—'=>'—','No screenshot'=>'Nessun screenshot','Activate'=>'Attiva','Deactivate'=>'Disattiva','Action Workflow Editor'=>'Editor dei flusso di lavoro delle azioni','Post Query'=>'Query articolo','A query to select posts'=>'Una query per selezionare gli articoli','Yes'=>'Sì','No'=>'No','The workflow was not triggered.'=>'Il flusso di lavoro non è stato innescato.','The workflow was triggered by the legacy action'=>'Il flusso di lavoro è stato innescato da una azione legacy','Trigger workflow'=>'Trigger del flusso di lavoro','Move post to status'=>'Sposta l\'articolo nello stato','This step transitions a post to a different status.'=>'Questo passaggio sposta un articolo in uno stato differente.','Post'=>'Articolo','The post to update.'=>'L\'articolo da aggiornare.','Select the variable that contains the post to update. It can be a post instance or the post ID.'=>'Selezionare la variabile che contiene l\'articolo da aggiornare. Può essere un\'istanza dell\'articolo o l\'ID dell\'articolo.','The new status that the post will be moved to.'=>'Il nuovo stato in cui verrà spostato l\'articolo.','Step input'=>'Input passaggio','The input data for this step.'=>'I dati di input per questo passaggio.','Next'=>'Successivo','Deactivate Workflow for Post'=>'Disattiva flusso di lavoro per l\'articolo','This step enables you to deactivate the "Manually enabled via checkbox" workflow after use.'=>'Questo passaggio ti consente di disabilitare dopo l\'uso il flusso di lavoro "Abilitato manualmente tramite checkbox".','Workflow'=>'Flusso di lavoro','Select the manually enabling workflow that will be deactivated for the selected post.'=>'Selezionare il flusso di lavoro ad abilitazione manuale che verrà disattivato per l\'articolo selezionato.','Delete post'=>'Elimina articolo','This step deletes a post.'=>'Questo passaggio elimina un articolo.','Stick post'=>'Metti l\'articolo in evidenza','This step sticks a post.'=>'Questo passaggio mette in evidenza un articolo.','The Stick Post action must be part of a Schedule flow'=>'L\'azione dell\'articolo in evidenza deve essere parte di un flusso di programma','Add extra terms to post'=>'Aggiungi termini extra all\'articolo','This step keeps the current taxonomy terms and adds additional terms.'=>'Questo passaggio mantiene i termini della tassonomia attuale e aggiunge dei termini supplementari.','Extra terms'=>'Termini extra','The terms that will be added to the posts.'=>'I termini che saranno aggiunti agli articoli.','Terms'=>'Termini','Remove terms from the post'=>'Rimuovi i termini dall\'articolo','This step removes current taxonomy terms.'=>'Questo passaggio rimuove i termini della tassonomia attuale.','Terms to remove'=>'Termini da rimuovere','The terms that will be removed from the posts.'=>'I termini che saranno rimossi dagli articoli.','Remove all terms'=>'Rimuovi tutti i termini','Replace all terms on the post'=>'Sostituisci tutti i termini dell\'articolo','This step removes the current taxonomy terms and adds new terms.'=>'Questo passaggio rimuove i termini della tassonomia attuale e aggiunge nuovi termini.','New terms'=>'Nuovi termini','The terms that will be added to the posts after removing all the others.'=>'I termini che saranno aggiunti agli articoli dopo aver rimosso gli altri.','Unstick post'=>'Rimuovi l\'articolo da in evidenza','This step unsticks a post.'=>'Questo passaggio rimuove un articolo da in evidenza.','PublishPress Workflow: {{global.workflow.title}}'=>'Flusso di lavoro di PublishPress: {{global.workflow.title}}','This is a message sent by PublishPress Workflow: {{global.workflow.title}}.'=>'Questo è un messaggio inviato dal flusso di lavoro di PublishPress: {{global.workflow.title}}.','Send email'=>'Invia email','This step dispatches a message via email.'=>'Questo passaggio invia un messaggio via email.','The email message'=>'Il messaggio email','Recipient'=>'Destinatario','Subject'=>'Oggetto','Email Recipient'=>'Email destinatario','Custom Email Address'=>'Indirizzo email personalizzato','Conditional Split'=>'Divisione condizionale','This step allows you to create a conditional branch.'=>'Questo passaggio ti consente di creare una diramazione condizionale.','Conditions'=>'Condizioni','The conditions that must be met for deciding which branch to take.'=>'Le condizioni che devono essere soddisfatte per decidere quale ramo prendere.','Branch'=>'Ramo','The current branch on this step.'=>'Il ramo attuale di questo passaggio.','True'=>'Vero','False'=>'Falso','Query posts'=>'Query articoli','This step defines the posts that will be passed to the next step in the workflow.'=>'Questo passaggio definisce gli articoli che passeranno al prossimo passaggio del flusso di lavoro.','Post query'=>'Query articolo','The query defines the posts that will be retrieved by this action.'=>'La query definisce gli articoli che saranno recuperati da questa azione.','Post Type'=>'Tipo di contenuto','Post ID'=>'ID articolo','Array of queried post IDs'=>'Array degli ID degli articoli richiesti','The posts found following the criteria of the query.'=>'L\'articolo trovato secondo i criteri della query.','Schedule'=>'Programma','This step enables actions to be scheduled. You can choose when to run the next step.'=>'Questo passaggio consente di programmare le azioni. Puoi scegliere quando eseguire il passaggio successivo.','A scheduled delay between steps.'=>'Un ritardo programmato tra i passaggi.','Date offset'=>'Scostamento della data','Log - Add'=>'Registro - aggiungi','This step transmits the flow\'s data to the debug log.'=>'Questo passaggio trasmette i dati del flusso al registro di debug.','Debug output'=>'Risultato del debug','The message to be sent to the debug log.'=>'Il messaggio da inviare al registro di debug.','Level'=>'Livello','Ray - Debug'=>'Ray - Debug','This step transmits the flow\'s data to Ray Debug.'=>'Questo passaggio trasmette i dati del flusso a Ray Debug.','The data to be sent to Ray.'=>'I dati che devono essere inviati a Ray.','Data'=>'Dati','Label'=>'Etichetta','Color'=>'Colore','On admin init'=>'All\'inizializzazione dell\'amministrazione','This trigger activates upon the initialization of the admin site.'=>'Questo trigger si attiva dopo l\'inizializzazione del sito dell\'ammistratore.','On cron schedule'=>'Con la programmazione cron','This trigger activates upon a cron schedule, allowing recurrency.'=>'Questo trigger si attiva in base a una programmazione cron, consentendo la ricorrenza.','A schedule to activate the workflow.'=>'Un programma per attivare flusso di lavoro.','On site init'=>'All\'inizializzazione del sito','This trigger activates upon site initialization.'=>'Questo trigger si attiva dopo l\'inizializzazione del sito.','Manually enabled via checkbox'=>'Abilitato manualmente tramite checkbox','This trigger activates when the option is manually enabled. It can be enabled via the post editing screen or the Quick Edit panel.'=>'Questo trigger si attiva quando l\'opzione è abilitata manualmente. Può essere abilitata dalla schermata di modifica dell\'articolo o dal pannello "Modifica rapida".','Settings for the trigger.'=>'Impostazioni per il trigger.','Checkbox label'=>'Etichetta checkbox','The label of the checkbox that enables the trigger.'=>'L\'etichetta del checkbox che attiva il trigger.','Specify the criteria for posts that will trigger this action. Leave blank to include all posts.'=>'Specifica i criteri per gli articoli che attiveranno quest\'azione. Lascia vuoto per includere tutti gli articoli.','The query defines the posts that will trigger this action.'=>'La query definisce gli articoli che saranno recuperati da questa azione.','Saved post'=>'Articolo salvato','The post that was saved, with the new properties.'=>'L\'articolo salvato con le nuove proprietà.','Post is updated'=>'Articolo aggiornato','This trigger activates when an existing post is updated.'=>'Questo trigger si attiva quando un articolo esistente viene aggiornato.','Post Before Update'=>'Articolo prima dell\'aggiornamento','The post that was saved, with the old properties.'=>'L\'articolo salvato con le vecchie proprietà.','Post After Update'=>'Articolo dopo l\'aggiornamento','Post is saved'=>'Articolo salvato','This trigger activates whenever a post is saved, regardless of whether it\'s newly created, imported, or updated.'=>'Questo trigger si attiva quando un articolo viene salvato, indipendentemente dal fatto che sia stato creato, importato o aggiornato.','Manually enabled via Future Actions box'=>'Abilitato manualmente tramite il riquadro delle azioni di Future','This trigger allows users to choose the workflow from the dropdown menu in the Future Actions options.'=>'Questo trigger consente agli utenti di scegliere il flusso di lavoro dal menu a discesa delle opzioni per le "Azioni Future".','Action Post'=>'Articolo d\'azione','The post that was saved triggering the action.'=>'L\'articolo salvato che ha innescato l\'azione.','Site'=>'Sito','Flow Control'=>'Controlla flusso','Asynchronous'=>'Asincrono','Debug'=>'Debug','Data Query'=>'Query dei dati','Messages'=>'Messaggi','The ID of the workflow'=>'L\'ID del flusso di lavoro','The taxonomy name'=>'Il nome della tassonomia','The post ID'=>'L\'ID dell\'articolo','Workflow not found'=>'Flusso di lavoro non trovato','Loading the workflow editor...'=>'Caricamento dell\'editor del flusso di lavoro in corso…','Screenshot'=>'Screenshot','Upgrade to PublishPress Future Pro'=>'Aggiorna a PublishPress Future Pro','Enhance the power of PublishPress Future with the Pro version:'=>'Aumenta le potenzialità di PublishPress Future con la versione Pro:','Design custom workflows with multiple actions'=>'Disegna flussi di lavoro personalizzati con azioni multiple','Schedule actions based on the post\'s publishing date'=>'Programma la data dell\'azione basata sulla data di pubblicazione dell\'articolo','Move posts to custom statuses'=>'Sposta gli articoli negli stati personalizzati','Use other plugins to control Future Actions'=>'Utilizza gli altri plugin per controllare le azioni di "Future"','Enjoy fast and professional support'=>'Godi di un supporto rapido e professionale','Need PublishPress Future Support?'=>'Hai bisogno del supporto di PublishPress Future?','If you need help or have a new feature request, let us know.'=>'Se hai bisogno di aiuto o hai delle richieste di funzionalità, faccelo sapere.','Request Support'=>'Rchiesta di supporto','Detailed documentation is also available on the plugin website.'=>'Una documentazione dettagliata è anche disponibile sul sito web del plugin.','View Knowledge Base'=>'Vedi la documentazione','%1$s%2$s%3$s on %5$s%4$s%6$s'=>'%1$s%2$s%3$s il %5$s%4$s%6$s','Action was not scheduled due to a configuration issue. Please attempt to schedule it again.'=>'L\'azione non può essere programmata a causa di un problema di configurazione. Prova a riprogrammarla nuovamente.','No future action'=>'Nessuna azione Future','Advanced Options'=>'Opzioni avanzate','Workflow Step Schedule\'s Arguments Compression'=>'Passaggio del flusso di lavoro della compressione programmata degli argomenti','Compress the arguments'=>'Comprimi gli argomenti','Compress the arguments of the step schedule to save memory in the database, saving them as binary data.'=>'Comprimi gli argomenti del passaggio programmato per risparmiare memoria nel database, salvandoli come dati binari.','Do not compress the arguments'=>'Non comprimere gli argomenti','Do not compress the arguments of the step schedule, storing them as plain text.'=>'Non comprimere gli argomenti del passaggio programmato, immagazzinali come testo semplice.','Experimental Features'=>'Caratteristiche sperimentali','Enable experimental features'=>'Abilita le caratteristiche sperimentali','Enable experimental features that are still in development and may not be fully functional.'=>'Abilita le caratteristiche sperimentali che sono ancora in fase di sviluppo e potrebbero non funzionare correttamente.','Preserve Data After Deactivating the Plugin'=>'Conserva i dati dopo la disattivazione del plugin','Preserve data'=>'Conserva i dati','Delete data'=>'Elimina i dati','Toggle between preserving or deleting data after the plugin is deactivated.'=>'Attiva/disattiva la conservazione o l\'eliminazione dei dati dopo la disattivazione del plugin.','Save Changes'=>'Salva modifiche','Below is a dump of the debugging table, this should be useful for troubleshooting.'=>'Di seguito è riportato un dump della tabella di debug, questo dovrebbe essere utile per la risoluzione dei problemi.','Debugging table is currently empty.'=>'La tabella di debug è attualmente vuota.','Number of logs to display:'=>'Numero di registrazioni da visualizzare:','Showing the latest %d of %d results. The approximate size of the log is %s.'=>'Visualizzazione degli ultimi risultati %d di %d. La dimensione approssimativa del registro è %s.','Showing all %d results. The approximate size of the log is %s.'=>'Visualizzazione di tutti i risultati %d. La dimensione approssimativa del registro è %s.','Copy Debug Log'=>'Copiaa il registro di debug','Download Entire Log'=>'Scarica il registro completo','Debug log copied to clipboard!'=>'Registro di debug copiato negli appunti!','Advanced Diagnostics and Tools'=>'Diagnostica e strumenti avanzati','WP-Cron Status Check'=>'Controllo stato di WP-Cron','Passed'=>'Approvato','WP Cron Disabled'=>'WP Cron disabilitato','Database Schema Check'=>'Controllo schema database','Error found on the database schema:'=>'Trovato un errore nello schema del database:' . "\0" . 'Trovati degli errori nello schema del database:','Try to Fix Database'=>'Cerca di correggere il database','Debug Logging'=>'Registrazione di debug','Enabled'=>'Abilitato','Disable Debugging'=>'Disattiva il debugging','Purge Debug Log'=>'Svuota il registro di debug','View Debug Logs'=>'Visualizza i log di debug','Disabled'=>'Disabilitato','Enable Debugging'=>'Attiva il debugging','Migrate Legacy Future Actions'=>'Migrare le azioni Future legacy','Run Migration'=>'Esegui migrazione','Migrate legacy future actions from WP Cron to the new Action Scheduler. This will run in the background and may take a while.'=>'Migrare le azioni Future legacy da WP Cron al nuovo Programmatore di azioni. Questa operazione verrà eseguita in background e potrebbe richiedere un po\' di tempo.','Restore Legacy Action Arguments'=>'Ripristina gli argomenti delle azioni precedenti','Run Data Restoration'=>'Avvia il ripristino del database','Restore legacy action arguments as Post Meta. This is useful if you have issues with 3rd party plugins that read that data. This will run in the background and may take a while.'=>'Ripristina gli argomenti delle azioni legacy come meta degli articoli. Utile se si hanno problemi con i plugin di terze parti che leggono questi dati. L\'esecuzione averrà in background e potrebbe richiedere un po\' di tempo.','Legacy Cron Schedule'=>'Programma di Cron Legacy','The below table will show all currently scheduled cron events for the plugin with the next run time.'=>'La tabella seguente mostra tutti gli eventi cron attualmente programmati per il plugin con il prossimo orario di esecuzione.','Event'=>'Evento','Posts and expiration settings'=>'Impostazioni degli articoli e della scadenza','This is a legacy feature and will be removed in a future version.'=>'Questa è una funzionalità legacy che sarà rimossa in una prossima versione.','Default Formats'=>'Formati predefiniti','Date Format'=>'Formato data','The default format to use when displaying the action date within a post using the shortcode or within the footer. For information on valid formatting options, see: %s.'=>'Il formato predefinito da utilizzare quando si visualizza la data di scadenza all\'interno di un articolo utilizzando lo shortcode o nel footer. Per informazioni sulle opzioni di formattazione valide, vedere: %s.','PHP Date Function'=>'Funzione data PHP','Time Format'=>'Formato ora','The default format to use when displaying the action time within a post using the shortcode or within the footer. For information on valid formatting options, see: %s.'=>'Il formato predefinito da utilizzare quando si visualizza l\'ora di scadenza all\'interno di un articolo utilizzando lo shortcode o nel footer. Per informazioni sulle opzioni di formattazione valide, vedere: %s.','Future Actions Column'=>'Colonna azioni Future','Future Action Column Style'=>'Stile colonna delle azioni Future','Detailed'=>'Dettagliate','Displays all information in the Future Action column.'=>'Visualizza tutte le informazioni nella colonna "Azioni di Future".','Simplified'=>'Semplificate','Displays only the icon and date/time.'=>'Visualizza solo l\'icona, la data e l\'ora.','Future Actions Editor'=>'Editor azioni Future','Time format in the date picker'=>'Formato dell\'ora nel selezionatore di data','Inherit from Site Settings'=>'Eredita dalle impostazioni del sito','24 hours'=>'24 ore','AM/PM'=>'AM/PM','Post Footer Display'=>'Visualizzazione nel footer','Enabling this below will display the action date automatically at the end of any post which is set to run an action.'=>'Abilitando l\'opzione seguente verrà mostrata automaticamente la data di scadenza alla fine di ogni articolo che è impostato per scadere.','Show in Post Footer?'=>'Mostrare nel footer dell\'articolo?','This will enable or disable displaying the future action date in the post footer.'=>'Questo abiliterà o disabiliterà la visualizzazione della data di scadenza dell\'articolo nel footer dello stesso.','Footer Contents'=>'Contenuto del footer','Enter the text you would like to appear at the bottom of every post which has an action scheduled. The following placeholders will be replaced with the future action date in the following format:'=>'Inserisci il testo che vorresti far apparire in fondo a ogni articolo impostato con una scadenza. I seguenti segnaposto verranno sostituiti con la data di scadenza nel modo indicato:','Footer Style'=>'Stile del footer','The inline css which will be used to style the footer text.'=>'Il css inline che verrà utilizzato per definire lo stile del testo del footer.','Example: '=>'Esempio: ','Shortcode'=>'Shortcode','Valid %s attributes:'=>'Attributi %s validi:','%1$stype%2$s - valid options are %1$sfull%2$s (default), %1$sdate%2$s, %1$stime%2$s'=>'%1$stipo%2$s - le opzioni valide sono %1$scompleta%2$s (predefinito), %1$sdata%2$s, %1$sora%2$s','%s - format set here will override the value set on the settings page'=>'%s - il formato impostato qui sovrascrive il valore configurato nella pagina delle impostazioni','Defaults'=>'Valori predefiniti','Calendar Visibility'=>'Visibilità del calendario','Remember last state'=>'Ricorda l\'ultimo stato','Shows or hides the calendar based on the last user interaction.'=>'Mostra o nasconde il calendario in funzione dell\'ultima interazione dell\'utente.','Always hidden'=>'Sempre nascosto','The calendar is always hidden by default.'=>'Il calendario è sempre nascosto per impostazione predefinita.','Permissions'=>'Autorizzazioni','Choose Which User Roles Can Use PublishPress Future'=>'Scegli quali ruoli utente possono utilizzare PublishPress Future','Email Notification'=>'Email di notifica scadenza','Whenever an action runs, an email can be sent to alert users.'=>'Ogni volta che un articolo scade, un\'email può essere spedita per avvisare gli utenti della scadenza.','Enable Email Notification?'=>'Abilita notifica email?','This will enable or disable the send of email notification on future action.'=>'Questo abiliterà o disabiliterà l\'invio della notifica via email alla scadenza dell\'articolo.','Include Blog Administrators?'=>'Includere gli amministratori del blog?','This will include all users with the role of "Administrator" in the email.'=>'Ciò includerà tutti gli utenti con il ruolo di "Amministratore" nell\'email di scadenza dell\'articolo.','Enter a comma separate list of emails that you would like to be notified when the action runs. This will be applied to ALL post types. You can set post type specific emails on the Defaults tab.'=>'Inserisci un elenco di email separate da virgole a cui ti piacerebbe inviare una notifica quando scade l\'articolo. Questo sarà applicato a tutti i tipi di contenuto. È possibile impostare email specifiche per un tipo di contenuto nella scheda "Valori predefiniti".','Post Types'=>'Tipi di contenuto','General'=>'Generale','Display'=>'Visualizza','Advanced'=>'Avanzate','Diagnostics and Tools'=>'Diagnostica e strumenti']]; \ No newline at end of file diff --git a/languages/post-expirator-it_IT.mo b/languages/post-expirator-it_IT.mo index 1b4a5cb21f585c997311f72e64839d06edf2f7df..3a30d5816cce7a77a2d0759bb5735dbfb8b382c4 100644 GIT binary patch delta 146 zcmccni0SSlrVVFURYe&X7;YOeFo5WfK-vsQvl}xohyZCjAk7b?gExO<<>m(~T~G;; z+6JVZfl{Y|v;>gmuVP@30@50r6-7_V$~foel;-9!xRsWa7NsgUCYNO9=M^isrev1n c7frrp6uUXu*w$^bM3wgB1(g+>ovWnG0UfX;<^TWy delta 161 zcmccni0SSlrVVFURm~U}7;YOeFo*zYA!7yxeju$5q(y|oW0n$=H`Y(_MDV3;#7@@aWQS_wjWHDo3ZMV{r(xOy_#N?99{Jdg?NULL,'plural-forms'=>NULL,'language'=>'','project-id-version'=>'','pot-creation-date'=>'2024-11-27T18:46:35+00:00','po-revision-date'=>'2024-11-27T18:46:35+00:00','messages'=>[]]; \ No newline at end of file diff --git a/languages/post-expirator-nl_NL-future_backup_panel.po b/languages/post-expirator-nl_NL-future_backup_panel.po new file mode 100644 index 000000000..b62138043 --- /dev/null +++ b/languages/post-expirator-nl_NL-future_backup_panel.po @@ -0,0 +1,16 @@ +msgid "" +msgstr "" +"Project-Id-Version: \n" +"Report-Msgid-Bugs-To: \n" +"Last-Translator: \n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"POT-Creation-Date: 2024-11-27T18:46:35+00:00\n" +"PO-Revision-Date: 2024-11-27T18:46:35+00:00\n" +"Language: \n" + +#: components/BackupPanel.jsx:6 +msgid "Backup" +msgstr "" diff --git a/languages/post-expirator-pt_BR-future_backup_panel.json b/languages/post-expirator-pt_BR-future_backup_panel.json new file mode 100644 index 000000000..e23de90a5 --- /dev/null +++ b/languages/post-expirator-pt_BR-future_backup_panel.json @@ -0,0 +1 @@ +{"domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"","plural_forms":""},"Backup":["Backup"]}}} \ No newline at end of file diff --git a/languages/post-expirator-pt_BR-future_backup_panel.l10n.php b/languages/post-expirator-pt_BR-future_backup_panel.l10n.php new file mode 100644 index 000000000..f254160ea --- /dev/null +++ b/languages/post-expirator-pt_BR-future_backup_panel.l10n.php @@ -0,0 +1,2 @@ +NULL,'plural-forms'=>NULL,'language'=>'','project-id-version'=>'','pot-creation-date'=>'2024-11-27T18:46:32+00:00','po-revision-date'=>'2024-11-27T18:46:32+00:00','messages'=>['Backup'=>'Backup']]; \ No newline at end of file diff --git a/languages/post-expirator-pt_BR-future_backup_panel.po b/languages/post-expirator-pt_BR-future_backup_panel.po new file mode 100644 index 000000000..b590d9808 --- /dev/null +++ b/languages/post-expirator-pt_BR-future_backup_panel.po @@ -0,0 +1,16 @@ +msgid "" +msgstr "" +"Project-Id-Version: \n" +"Report-Msgid-Bugs-To: \n" +"Last-Translator: \n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"POT-Creation-Date: 2024-11-27T18:46:32+00:00\n" +"PO-Revision-Date: 2024-11-27T18:46:32+00:00\n" +"Language: \n" + +#: components/BackupPanel.jsx:6 +msgid "Backup" +msgstr "Backup" diff --git a/languages/post-expirator-pt_BR.l10n.php b/languages/post-expirator-pt_BR.l10n.php index 781de5207..81b4bce21 100644 --- a/languages/post-expirator-pt_BR.l10n.php +++ b/languages/post-expirator-pt_BR.l10n.php @@ -1,2 +1,2 @@ NULL,'plural-forms'=>'nplurals=2; plural=(n > 1);','language'=>'pt_BR','project-id-version'=>'Post Expirator 2.4.4','pot-creation-date'=>'2024-11-18T16:43:30+00:00','po-revision-date'=>'','x-generator'=>'Poedit 3.5','messages'=>['PublishPress Future'=>'PublishPress Future','http://wordpress.org/extend/plugins/post-expirator/'=>'http://wordpress.org/extend/plugins/post-expirator/','PublishPress Future allows you to schedule automatic changes to posts, pages and other content types.'=>'O PublishPress Future permite que você programe alterações automáticas em posts, páginas e outros tipos de conteúdo.','PublishPress'=>'PublishPress','http://publishpress.com'=>'http://publishpress.com','You do not have permission to configure PublishPress Future.'=>'Você não tem permissão para configuar o PublishPress Future.','Debug is disabled'=>'Depuração Desativada','Debugging Disabled'=>'Depuração Desativada','Debugging Enabled'=>'Depuração Ativada','Debugging Table Emptied'=>'Tabela de Depuração Esvaziada','The legacy future actions migration has been enqueued and will run asynchronously.'=>'A migração de ações futuras legadas foi enfileirada e será executada de forma assíncrona.','The legacy actions arguments restoration has been enqueued and will run asynchronously.'=>'A restauração dos argumentos de ações legadas foi enfileirada e será executada de forma assíncrona.','The database schema was fixed.'=>'A estrutura do banco de dados foi corrigida.','The database schema could not be fixed. Please, contact the support team.'=>'A estrutura do banco de dados não pode ser corrigida. Por favor, entre em contaot com o suporte.','Saved Options!'=>'Configurações salvas!','If you like %1$s, please leave us a %2$s rating. Thank you!'=>'Se você gosta do %s, por favor deixe uma avaliação %s. Obrigado!','About PublishPress Future'=>'Sobre PublishPress Future','About'=>'Sobre','Future Documentation'=>'Documentação','Documentation'=>'Documentação','Contact the PublishPress team'=>'Entre em contato com a equipe PublishPress','Contact'=>'Contato','No taxonomies found'=>'Não foram encontradas taxonomias','l F jS, Y'=>'l F jS, Y','g:ia'=>'g:ia','Post expires at EXPIRATIONTIME on ACTIONDATE'=>'O post expira às EXPIRATIONTIME do dia ACTIONDATE','The table %s does not exist.'=>'A tabela %s não existe.','The table indexes are invalid: '=>'Os índices da tabela são inválidos: ','Invalid date time offset.'=>'Deslocamento padrão de data/hora.','You do not have sufficient permissions to access this page.'=>'Você não tem permissão suficientes para acessar esta página.','Invalid nonce.'=>'Nonce inválido.','Categories'=>'Categorias','Future Actions'=>'Ações Futuras','Enable Future Action'=>'Habilitar Ação Futura','Action'=>'Ação','Loading'=>'Carregando','Show Calendar'=>'Mostrar Calendario','Hide Calendar'=>'Ocultar Calendário','Timezone is controlled by the {WordPress Settings}.'=>'O fuso horário é controlado pelas {Configurações do WordPress}.','No %s found.'=>'Não existem %s.','You must assign a taxonomy to this post type to use this feature.'=>'Você deve atribuir uma taxonomia a esse tipo de post para usar esse recurso.','New %s'=>'Novo %s','%s to remove'=>'%s para remover','%s to add'=>'%s para adicionar','Search for %s'=>'Buscar por %s','Select an action'=>'Selecionar uma ação','Select a date'=>'Selecione uma data','Date cannot be in the past'=>'A data não pode estar no passado','Please select one or more %s'=>'Selecione um ou mais %s','New status'=>'Novo status','No posts selected. Unable to sync Future Actions.'=>'Nenhuma postagem selecionada. Não é possível sincronizar as ações futuras.','Future Actions successfully synced with Post Metadata.'=>'As ações futuras foram sincronizadas com sucesso com os metadados do post.','Update Future Actions from Post Metadata'=>'Atualizar ações futuras dos metadados do post','Future Action Update'=>'Atualização de ações futuras','— No Change —'=>'— Nenhuma Alteração —','Add or update action for posts'=>'Adicionar ou atualizar ações para postagens','Add action if none exists for posts'=>'Adicionar ação se não houver nenhuma para os posts','Update the existing actions for posts'=>'Atualizar as ações existentes para postagens','Remove action from posts'=>'Remover ação das postagens','Category'=>'Categoria','Settings'=>'Configurações','Future Action'=>'Ação Futura','Future'=>'Future','Action Settings'=>'Configurações de ações','Scheduled Actions'=>'Ações Agendadas','Log format'=>'Formato de registro','List'=>'Lista','Popup'=>'Popup','Successfully executed action: %s'=>'Ação executada com sucesso: %s','Executed workflow scheduled step'=>'Etapa agendada do fluxo de trabalho executada','Cleaned up completed scheduled steps older than %d days'=>'Limpar etapas agendadas concluídas com mais de %d dias','Cleaned up orphan workflow scheduled step arguments'=>'Limpar argumentos órfãos das etapas agendadas de fluxos de trabalho','The shortcode [futureaction] must be used inside the loop or with the post_id attribute.'=>'O shortcode [futureaction] precisa ser usado dentro do loop ou com o atributo “post_id”.','The column args length was not updated to 1000.'=>'O comprimento da coluna args não foi atualizado para 1000.','Status didn\'t change.'=>'O estado não mudou.','Status has been successfully changed from "%1$s" to "%2$s".'=>'O estado foi alterado com êxito de "%s" para "%s".','Change status'=>'Alterar status','%s was not deleted.'=>'%s não foi excluído.','%s has been successfully deleted.'=>'%s foi excluído com sucesso.','Delete'=>'Excluir','No terms were added to the %s.'=>'Nenhum termo foi adicionado à %s.','The following terms (%1$s) were added to the %2$s: "%3$s". The full list of terms on the post is: %4$s.'=>'Os seguintes termos (%1$s) foram adicionados ao %2$s: “%3$s". A lista completa de termos na postagem é: %4$s.','Add extra %s'=>'Adicionar mais %s','No terms were removed from the %s.'=>'Nenhum termo foi removido de %s.','The following terms (%1$s) were removed from the %2$s: %3$s. The new list of terms on the post is: %4$s.'=>'Os seguintes termos (%1$s) foram removidos de %2$s: %3$s. A nova lista de termos no post é: %4$s.','Remove selected %s'=>'Remover %s selecionado(a)','The following terms (%1$s) were removed from the %2$s: %3$s.'=>'Os seguintes termos (%1$s) foram removidos do(a) %2$s: %3$s.','Remove all %s'=>'Remover todos(as) %s','No terms were changed on the %s.'=>'Nenhum termo foi alterado no %s.','The following terms (%1$s) were set to the %2$s: "%3$s". The old list of terms on the post was: %4$s.'=>'Os seguintes termos (%1$s) foram definidos para %2$s: “%3$s". A lista antiga de termos na postagem era: %4$s.','Replace all %s'=>'Substituir todos(as) %s','Change status to %s'=>'Alterar o estado para %s','%s didn\'t change.'=>'%s não foi alterado(a).','%s has been added to stickies list.'=>'%s foi adicionado(a) à lista de fixados.','Stick'=>'Fixar','%s has been removed from stickies list.'=>'%s foi removido da lista de fixados.','Unstick'=>'Desafixar','Email is disabled.'=>'O e-mail está desativado.','Email sent.'=>'Email enviado.','Email not sent.'=>'E-mail não enviado.','%1$s. %2$s on %3$s. The post link is %4$s'=>'%1$s. %2$s em %3$s. O link da postagem é %4$s','Future Action Complete "%s"'=>'Ação Futura Completa “%s”','[%1$s] %2$s'=>'[%1$s] %2$s','Invalid date/time offset "%s" for post type "%s". Please ensure you use only English terms for the date/time offset, such as "3 months" or "1 week".'=>'Deslocamento de data/hora "%s" inválido para o tipo de post "%s". Certifique-se de usar apenas termos em inglês para o deslocamento de data/hora, como "3 months" ou "1 week".','Status'=>'Estado','Arguments'=>'Argumentos','Logs'=>'Registros','Scheduled Date'=>'Data Programada','Recurrence'=>'Recorrência','Run'=>'Executar','Process the action now'=>'Processar a ação agora','Cancel'=>'Cancelar','Cancel the action. This will prevent the action from running in the future'=>'Cancelar a ação. Isso impedirá que a ação seja executada no futuro','%s year'=>'%s ano' . "\0" . '%s anos','%s month'=>'%s mês' . "\0" . '%s meses','%s week'=>'%s semana' . "\0" . '%s semanas','%s day'=>'%s dia' . "\0" . '%s dias','%s hour'=>'%s hora' . "\0" . '%s horas','%s minute'=>'%s minuto' . "\0" . '%s minutos','%s second'=>'%s segundo' . "\0" . '%s segundos','Action Logs'=>'Registros de Ações','Uninitialized'=>'Não inicializado','Scheduled'=>'Agendado','Complete'=>'Completo','Failed'=>'Falhou','Canceled'=>'Cancelado','Running'=>'Em Andamento','All'=>'Todos','Search hook, args and claim ID'=>'Pesquise ganchos, args e ID','Completed'=>'Executado','%1$s: [%2$d] %3$s%4$s%5$s'=>'%1$s: [%2$d] %3$s%4$s%5$s','New Status: %s'=>'Novo status: %s','Terms: %s'=>'Termos: %s','View log'=>'Visualizar o registro','Action: '=>'Ação: ','Status: '=>'Status: ','Arguments: '=>'Argumentos: ','Scheduled date: '=>'Data programada: ','Date'=>'Data','Message'=>'Mensagem','Async'=>'Assíncrono',' (%s ago)'=>' (%s atrás)',' (%s)'=>' (%s)','Now!'=>'Agora!','Every %s'=>'A cada %s','Non-repeating'=>'Sem Repetição','No Scheduled Actions.'=>'Nenhuma ação agendada.','Set the offset to use for the default action date and time. For information on formatting, see %1$s. For example, you could enter %2$s+1 month%3$s or %2$s+1 week 2 days 4 hours 2 seconds%3$s or %2$snext Thursday%3$s. Please, use only terms in English.'=>'Defina o deslocamento a ser usado para a data e hora da ação padrão. Para obter informações sobre formatação, consulte %1$s. Por exemplo, você poderia inserir %2$s+1 month%3$s ou %2$s+1 week 2 days 4 hours 2 seconds%3$s ou %2$snext Thursday%3$s. Por favor, use apenas termos em inglês.','Default Values'=>'Valores Padrão','Use the values below to set the default actions/values to be used for each for the corresponding post types. These values can all be overwritten when creating/editing the post/page.'=>'Use os valores abaixo para definir as ações/valores padrão a serem usados para cada um para os tipos de postagem correspondentes. Todos esses valores podem ser substituídos ao criar/editar o post/página.','Active'=>'Ativar','Activate the PublishPress Future actions for this post type'=>'Ative as ações do PublishPress Future para este tipo de post','Default Action'=>'Ação Padrão','Select the default action for the post type.'=>'Selecione a ação padrão para o tipo de postagem.','Select the taxonomy to be used for actions.'=>'Selecione a taxonomia a ser usada para as ações.','Auto-enable'=>'Ativação automática','Enabled for all new posts'=>'Ativado para todas as novas postagens','Taxonomy'=>'Taxonomia','No taxonomies found for this post type. Taxonomy actions will not be available.'=>'Não foram encontradas taxonomias para esse tipo de postagem. As ações de taxonomia não estarão disponíveis.','Who to Notify'=>'A quem notificar','Enter a comma separated list of emails that you would like to be notified when the action runs.'=>'Insira uma lista separada por vírgulas de e-mails que você gostaria de ser notificado quando a ação for executada.','Default Date/Time Offset'=>'Deslocamento padrão de data/hora','PHP strtotime function'=>'Função strtotime do PHP','Default terms:'=>'Termos padrão:','Save changes'=>'Salvar alterações','Wait for the validation...'=>'Aguarde a validação...','Date Preview'=>'Pré-visualização da data','Current Date'=>'Data atual','Computed Date'=>'Data calculada','Error'=>'Erro','Scheduled Workflow Steps Cleanup'=>'Limpeza das etapas agendadas do fluxo de trabalho','Automatically remove scheduled workflow steps'=>'Remover automaticamente etapas agendadas do fluxo de trabalho','Automatically remove scheduled workflow steps that have been marked as failed, completed, or cancelled.'=>'Remova automaticamente as etapas do fluxo de trabalho agendado que foram marcadas como falhas, concluídas ou canceladas.','Retain all scheduled workflow steps'=>'Reter todas as etapas agendadas do fluxo de trabalho','Retain all scheduled workflow steps indefinitely, including those marked as failed, completed, or cancelled. This may impact database performance over time.'=>'Retenha todas as etapas agendadas do fluxo de trabalho indefinidamente, inclusive aquelas marcadas como falhas, concluídas ou canceladas. Isso pode afetar o desempenho do banco de dados ao longo do tempo.','Retention'=>'Retenção','The duration, in days, for which completed, failed, and canceled scheduled workflow steps will be preserved before automatic removal.'=>'A duração, em dias, pela qual as etapas de fluxo de trabalho agendadas concluídas, falhas e canceladas serão preservadas antes da remoção automática.','days'=>'dias','Form Validation Failure: Sorry, your nonce did not verify.'=>'Falha na validação do formulário: Desculpe, seu nonce é inválido.','You\'re using PublishPress Future Free. The Pro version has more features and support. %1$sUpgrade to Pro%2$s'=>'Você está usando o PublishPress Future gratuito. A versão Pro tem mais recursos e melhor suporte. %1$sAtualize para a versão Pro%2$s','Upgrade to Pro'=>'Atualizar para Pro','Workflow Manual Trigger'=>'Acionador Manual de Fluxo de Trabalho','Action Workflows'=>'Fluxos de trabalho','Future Workflow'=>'Fluxo de Trabalho Futuro','Add New'=>'Adicionar Novo','Add New Workflow'=>'Novo Fluxo de Trabalho','Edit Workflow'=>'Editar fluxo de trabalho','New Workflow'=>'Novo fluxo de trabalho','View Workflow'=>'Ver fluxo de trabalho','Search Workflows'=>'Pesquisar fluxos de trabalho','No Workflows found'=>'Nenhum fluxo de trabalho encontrado','No Workflows found in Trash'=>'Nenhum fluxo de trabalho encontrado na lixeira','Parent Workflow:'=>'Fluxo de trabalho principal (ascendente):','All Workflows'=>'Todos','Workflow Archives'=>'Arquivos do fluxo de trabalho','Insert into workflow'=>'Inserir no fluxo de trabalho','Uploaded to this workflow'=>'Enviado para este fluxo de trabalho','Filter workflows list'=>'Filtrar a lista de fluxos de trabalho','Workflows list navigation'=>'Navegação na lista de fluxos de trabalho','Action Workflows list'=>'Lista de fluxos de trabalho','Workflow published.'=>'Fluxo de trabalho publicado.','Workflow published privately.'=>'Fluxo de trabalho publicado em particular.','Workflow reverted to draft.'=>'O fluxo de trabalho foi revertido para rascunho.','Workflow scheduled.'=>'Fluxo de trabalho agendado.','Workflow updated.'=>'Fluxo de trabalho atualizado.','Notify when a post is updated'=>'Notificar quando um post for atualizado','Notify the site admin when a post is updated.'=>'Notifique o administrador do site quando um post for atualizado.','Unpublish to Draft after a week'=>'Cancelar publicação para Rascunho após uma semana','Change the post status to Draft a week after it was published.'=>'Altere o status do post para Rascunho, uma semana após a publicação.','Unpublish and change category after one week'=>'Cancelar a publicação e alterar a categoria após uma semana','Move the post to draft and add a category after 15 days.'=>'Mova o post para rascunho, e adicione uma categoria após 15 dias.','Add extra categories one month after publishing'=>'Adicionar categorias adicionais, um mês após a publicação','Sample workflow to add extra categories one month after publishing'=>'Exemplo de fluxo de trabalho para adicionar categorias adicionais, um mês após a publicação','Workflow repeating scheduled step'=>'Repetição da etapa agendada do fluxo de trabalho','Workflow scheduled step'=>'Etapa agendada do fluxo de trabalho','Unschedule workflow recurring scheduled step'=>'Cancelar o agendamento da etapa recorrente agendada do fluxo de trabalho','Cleanup orphan workflow scheduled step arguments'=>'Limpar argumentos órfãos da etapa agendada do fluxo de trabalho','Clean up completed scheduled steps older than %d days'=>'Limpar etapas agendadas concluídas, com mais de %d dias','Step not found in workflow.'=>'Etapa não encontrada no fluxo de trabalho.','Workflow:'=>'Fluxo de trabalho:','Step:'=>'Etapa:','Trigger: '=>'Gatilho acionador: ','Post:'=>'Post:','Steps:'=>'Etapas:','Workflow recurring scheduled action'=>'Ação agendada recorrente do fluxo de trabalho','%1$s until %2$s'=>'%1$s até %2$s','%1$s for %2$d times'=>'%1$s por %2$d vezes','[%1$s/%2$d]'=>'[%1$s/%2$d]','Welcome to the workflow editor'=>'Boas-vindas ao editor de fluxo de trabalho','In the PublishPress Workflow Editor, each workflow step is presented as a distinct \'node\' in the workflow.'=>'No editor de fluxo de trabalho do PublishPress, cada etapa do fluxo é apresentada como um "nó" distinto no fluxo de trabalho.','Use your imagination'=>'Use sua imaginação','You\'re free to create very distinct workflows in your site, according to your needs.'=>'Você tem liberdade para criar fluxos de trabalho bem distintos no seu site, de acordo com suas necessidades.','A basic workflow'=>'Um fluxo de trabalho básico','Every workflow requires at least two steps connected to each other: one trigger and one action.'=>'Todo fluxo de trabalho requer pelo menos duas etapas conectadas entre si: um gatilho acionador e uma ação.','Add steps to your workflow'=>'Adicione etapas ao seu fluxo de trabalho','Drag and drop steps to add them to your workflow. Connect the steps to create a workflow.'=>'Arraste e solte etapas para adicioná-las ao seu fluxo de trabalho. Conecte as etapas para criar um fluxo de trabalho.','Output and input'=>'Saída e entrada','Linked steps can pass data forward as input to the next step.'=>'As etapas vinculadas podem passar dados adiante, como entrada para a próxima etapa.','Customize the workflow'=>'Personalizar o fluxo de trabalho','Click on a step to customize it. You can change the step\'s settings in the right sidebar.'=>'Clique em uma etapa para personalizar. Você pode alterar as configurações da etapa na barra lateral direita.','Workflow validation'=>'Validação do fluxo de trabalho','Error messages will appear for any unfilled required settings, missed connections, or invalid values. Select the step to view the corresponding error in the sidebar.'=>'Mensagens de erro aparecerão para quaisquer configurações obrigatórias não preenchidas, conexões perdidas ou valores inválidos. Selecione a etapa para visualizar o erro correspondente na barra lateral.','Publish your workflow'=>'Publique seu fluxo de trabalho','When you\'re ready, click the publish button to make your workflow live.'=>'Quando estiver pronto, clique no botão "Publicar" para ativar seu fluxo de trabalho.','Need help?'=>'Precisa de ajuda?','If you have any questions or need help, click the help button in the top right corner to access the support resources.'=>'Se você tiver alguma dúvida ou precisar de ajuda, clique no botão de ajuda, no canto superior direito, para acessar os recursos de suporte.','Triggers'=>'Gatilhos','Preview'=>'Visualização','—'=>'—','No screenshot'=>'Nenhuma captura de tela','Activate'=>'Ativar','Deactivate'=>'Desativar','Action Workflow Editor'=>'Editor de fluxo de trabalho','Post Query'=>'Consulta de Posts','A query to select posts'=>'Uma consulta para selecionar posts','Yes'=>'Sim','No'=>'Não','The workflow was not triggered.'=>'O fluxo de trabalho não foi acionado.','The workflow was triggered by the legacy action'=>'O fluxo de trabalho foi acionado pela ação legada','Trigger workflow'=>'Acionar fluxo de trabalho','Move post to status'=>'Mover post para status','This step transitions a post to a different status.'=>'Esta etapa faz a transição de um post para um status diferente.','Post'=>'Post','The post to update.'=>'O post a ser atualizado.','Select the variable that contains the post to update. It can be a post instance or the post ID.'=>'Selecione a variável que contém o post a ser atualizado. Pode ser uma instância do post ou o ID do post.','The new status that the post will be moved to.'=>'O novo status para o qual o post será movido.','Step input'=>'Entrada da etapa','The input data for this step.'=>'Os dados de entrada para esta etapa.','Next'=>'Próximo','Deactivate Workflow for Post'=>'Desativar o fluxo de trabalho para o post','This step enables you to deactivate the "Manually enabled via checkbox" workflow after use.'=>'Esta etapa permite que você desative o fluxo de trabalho "Ativado manualmente através da caixa de seleção" após o uso.','Workflow'=>'Fluxo de trabalho','Select the manually enabling workflow that will be deactivated for the selected post.'=>'Selecione o fluxo de trabalho de ativação manual que será desativado para o post selecionado.','Delete post'=>'Excluir post','This step deletes a post.'=>'Esta etapa exclui um post.','Stick post'=>'Fixar post','This step sticks a post.'=>'Esta etapa fixa um post.','The Stick Post action must be part of a Schedule flow'=>'A ação “Fixar post” precisa fazer parte de um fluxo de agendamento','Add extra terms to post'=>'Adicionar termos extras ao post','This step keeps the current taxonomy terms and adds additional terms.'=>'Esta etapa mantém os termos da taxonomia atual e adiciona termos adicionais.','Extra terms'=>'Termos adicionais','The terms that will be added to the posts.'=>'Os termos que serão adicionados aos posts.','Terms'=>'Termos','Remove terms from the post'=>'Remover termos do post','This step removes current taxonomy terms.'=>'Esta etapa remove os termos da taxonomia atual.','Terms to remove'=>'Termos a serem removidos','The terms that will be removed from the posts.'=>'Os termos que serão removidos dos posts.','Remove all terms'=>'Remover todos os termos','Replace all terms on the post'=>'Substituir todos os termos do post','This step removes the current taxonomy terms and adds new terms.'=>'Esta etapa remove os termos da taxonomia atual e adiciona novos termos.','New terms'=>'Novos termos','The terms that will be added to the posts after removing all the others.'=>'Os termos que serão adicionados aos posts após a remoção de todos os outros.','Unstick post'=>'Desafixar post','This step unsticks a post.'=>'Esta etapa desafixa um post.','PublishPress Workflow: {{global.workflow.title}}'=>'Fluxo de trabalho do PublishPress Future: {{global.workflow.title}}','This is a message sent by PublishPress Workflow: {{global.workflow.title}}.'=>'Esta é uma mensagem enviada pelo fluxo de trabalho do PublishPress Future: {{global.workflow.title}}.','Send email'=>'Enviar e-mail','This step dispatches a message via email.'=>'Esta etapa envia uma mensagem por e-mail.','The email message'=>'A mensagem do e-mail','Recipient'=>'Destinatário','Subject'=>'Assunto','Email Recipient'=>'Destinatário do e-mail','Custom Email Address'=>'E-mail Personalizado','Conditional Split'=>'Divisão condicional','This step allows you to create a conditional branch.'=>'Esta etapa permite que você crie uma ramificação condicional.','Conditions'=>'Condições','The conditions that must be met for deciding which branch to take.'=>'As condições que precisam ser atendidas para decidir qual ramificação seguir.','Branch'=>'Ramificação','The current branch on this step.'=>'A ramificação atual nesta etapa.','True'=>'Verdadeiro','False'=>'Falso','Query posts'=>'Consultar posts','This step defines the posts that will be passed to the next step in the workflow.'=>'Esta etapa define os posts que serão passados para a próxima etapa do fluxo de trabalho.','Post query'=>'Consulta de posts','The query defines the posts that will be retrieved by this action.'=>'A consulta define os posts que serão recuperados por esta ação.','Post Type'=>'Tipo de Post','Post ID'=>'ID do Post','Array of queried post IDs'=>'Array de IDs dos posts consultados','The posts found following the criteria of the query.'=>'Os posts encontrados de acordo com os critérios da consulta.','Schedule'=>'Agendar','This step enables actions to be scheduled. You can choose when to run the next step.'=>'Esta etapa permite que as ações sejam agendadas. Você pode escolher quando executar a próxima etapa.','A scheduled delay between steps.'=>'Um atraso agendado entre as etapas.','Date offset'=>'Deslocamento da data','Log - Add'=>'Registro - Adicionar','This step transmits the flow\'s data to the debug log.'=>'Esta etapa transmite os dados do fluxo para o registro de depuração.','Debug output'=>'Saída de depuração','The message to be sent to the debug log.'=>'A mensagem a ser enviada para o registro de depuração.','Level'=>'Nível','Ray - Debug'=>'Ray - Depuração','This step transmits the flow\'s data to Ray Debug.'=>'Esta etapa transmite os dados do fluxo para a depuração do Ray.','The data to be sent to Ray.'=>'Os dados a serem enviados ao Ray.','Data'=>'Dados','Label'=>'Rótulo','Color'=>'Cor','On admin init'=>'Na inicialização do painel administrativo','This trigger activates upon the initialization of the admin site.'=>'Este gatilho acionador é ativado na inicialização do painel administrativo do site.','On cron schedule'=>'No agendamento do cron','This trigger activates upon a cron schedule, allowing recurrency.'=>'Este gatilho acionador é ativado em um agendamento cron, permitindo a recorrência.','A schedule to activate the workflow.'=>'Um agendamento para ativar o fluxo de trabalho.','On site init'=>'Na inicialização do site','This trigger activates upon site initialization.'=>'Este gatilho acionador é ativado na inicialização do site.','Manually enabled via checkbox'=>'Ativado manualmente através da caixa de seleção','This trigger activates when the option is manually enabled. It can be enabled via the post editing screen or the Quick Edit panel.'=>'Este gatilho acionador é ativado quando a opção for ativada manualmente. Ela pode ser ativada através da tela de edição do post ou do painel de edição rápida.','Settings for the trigger.'=>'Configurações do gatilho acionador.','Checkbox label'=>'Rótulo de caixa de seleção','The label of the checkbox that enables the trigger.'=>'O rótulo da caixa de seleção que ativa o acionador.','Specify the criteria for posts that will trigger this action. Leave blank to include all posts.'=>'Especifique os critérios para os posts que irão acionar esta ação. Deixe em branco para incluir todos os posts.','The query defines the posts that will trigger this action.'=>'A consulta define os posts que irão acionar esta ação.','Saved post'=>'Post salvo','The post that was saved, with the new properties.'=>'O post que foi salvo, com as novas propriedades.','Post is updated'=>'Post atualizado','This trigger activates when an existing post is updated.'=>'Este gatilho acionador é ativado quando um post existente for atualizado.','Post Before Update'=>'Publicar antes de atualizar','The post that was saved, with the old properties.'=>'O post que foi salvo, com as propriedades antigas.','Post After Update'=>'Post após a atualização','Post is saved'=>'Post salvo','This trigger activates whenever a post is saved, regardless of whether it\'s newly created, imported, or updated.'=>'Esse gatilho é ativado sempre que um post é salvo, seja recém criado, importado ou atualizado.','Manually enabled via Future Actions box'=>'Ativado manualmente através da caixa "Ações futuras"','This trigger allows users to choose the workflow from the dropdown menu in the Future Actions options.'=>'Este gatilho acionador permite que os usuários escolham o fluxo de trabalho no menu suspenso, nas opções de ações futuras.','Action Post'=>'Post da ação','The post that was saved triggering the action.'=>'O post que foi salvo, acionando a ação.','Site'=>'Site','Flow Control'=>'Controle do fluxo','Asynchronous'=>'Asincrono','Debug'=>'Depuração','Data Query'=>'Consulta de Dados','Messages'=>'Mensagens','The ID of the workflow'=>'O ID do fluxo de trabalho','The taxonomy name'=>'O nome da taxonomia','The post ID'=>'O ID do post','Workflow not found'=>'Fluxo de trabalho não encontrado','Loading the workflow editor...'=>'Carregando o editor do fluxo de trabalho...','Screenshot'=>'Captura de tela','Upgrade to PublishPress Future Pro'=>'Faça upgrade para o PublishPress Future Pro','Enhance the power of PublishPress Future with the Pro version:'=>'Aumente o poder do PublishPress Future com a versão Pro:','Design custom workflows with multiple actions'=>'Crie fluxos de trabalho personalizados com várias ações','Schedule actions based on the post\'s publishing date'=>'Agende ações com base na data de publicação do post','Move posts to custom statuses'=>'Mover postagens para status personalizados','Use other plugins to control Future Actions'=>'Use outros plugins para controlar as ações futuras','Enjoy fast and professional support'=>'Conte com um suporte rápido e profissional','Need PublishPress Future Support?'=>'Precisa de suporte para PublishPress Future?','If you need help or have a new feature request, let us know.'=>'Se precisar de ajuda ou tiver uma solicitação de novo recurso, entre em contato conosco.','Request Support'=>'Solicitar Suporte','Detailed documentation is also available on the plugin website.'=>'A documentação detalhada também está disponível no site do plugin.','View Knowledge Base'=>'Ver Base de Conhecimento','%1$s%2$s%3$s on %5$s%4$s%6$s'=>'%1$s%2$s%3$s em %5$s%4$s%6$s','Action was not scheduled due to a configuration issue. Please attempt to schedule it again.'=>'A ação não foi agendada devido a um problema de configuração. Tente agendá-la novamente.','No future action'=>'Nenhuma ação futura','Advanced Options'=>'Opções avançadas','Workflow Step Schedule\'s Arguments Compression'=>'Compactação dos argumentos do agendamento da etapa do fluxo de trabalho','Compress the arguments'=>'Compactar os argumentos','Compress the arguments of the step schedule to save memory in the database, saving them as binary data.'=>'Compacte os argumentos do agendamento da etapa, para economizar memória no banco de dados, salvando-os como dados binários.','Do not compress the arguments'=>'Não compactar os argumentos','Do not compress the arguments of the step schedule, storing them as plain text.'=>'Não compacte os argumentos do agendamento da etapa, armazenando-os como texto simples.','Experimental Features'=>'Recursos experimentais','Enable experimental features'=>'Ativar recursos experimentais','Enable experimental features that are still in development and may not be fully functional.'=>'Ative recursos experimentais que ainda estão em desenvolvimento e podem não estar totalmente funcionais.','Preserve Data After Deactivating the Plugin'=>'Preservar Dados Após Desativar o Plug-in','Preserve data'=>'Preservar dados','Delete data'=>'Excluir dados','Toggle between preserving or deleting data after the plugin is deactivated.'=>'Alternar entre preservar ou excluir dados depois que o plug-in for desativado.','Save Changes'=>'Salvar Alterações','Below is a dump of the debugging table, this should be useful for troubleshooting.'=>'Abaixo está o conteúdo da tabela de depuração, isso pode ser útil para a solução de problemas.','Debugging table is currently empty.'=>'A tabela de depuração está atualmente vazia.','Number of logs to display:'=>'Número de registros a serem exibidos:','Showing the latest %d of %d results. The approximate size of the log is %s.'=>'Exibindo os últimos %d de %d resultados. O tamanho aproximado do registro é %s.','Showing all %d results. The approximate size of the log is %s.'=>'Exibindo todos os %d resultados. O tamanho aproximado do registro é %s.','Copy Debug Log'=>'Copiar registro de depuração','Download Entire Log'=>'Baixar o registro completo','Debug log copied to clipboard!'=>'O registro de depuração foi copiado para a área de transferência!','Advanced Diagnostics and Tools'=>'Diagnósticos Avançados e Ferramentas','WP-Cron Status Check'=>'Verificação do status do WP-Cron','Passed'=>'Aprovado','WP Cron Disabled'=>'WP Cron desativado','Database Schema Check'=>'Verificação da Estrutura do Banco de Dados','Error found on the database schema:'=>'Erro encontrado no esquema do banco de dados:' . "\0" . 'Erros encontrados no esquema do banco de dados:','Try to Fix Database'=>'Tentar corrigir o banco de dados','Debug Logging'=>'Registro de depuração','Enabled'=>'Habilitar','Disable Debugging'=>'Desativar a depuração','Purge Debug Log'=>'Limpar registro de depuração','View Debug Logs'=>'Exibir registros de depuração','Disabled'=>'Desabilitar','Enable Debugging'=>'Habilitar Depuração','Migrate Legacy Future Actions'=>'Migrar Ações Futuras Legadas','Run Migration'=>'Executar a Migração','Migrate legacy future actions from WP Cron to the new Action Scheduler. This will run in the background and may take a while.'=>'Migre as ações futuras legadas do WP Cron para o novo Action Scheduler. Isso será executado em segundo plano e pode demorar um pouco.','Restore Legacy Action Arguments'=>'Restaurar Argumentos de Ações Legados','Run Data Restoration'=>'Executar Restauração de Dados','Restore legacy action arguments as Post Meta. This is useful if you have issues with 3rd party plugins that read that data. This will run in the background and may take a while.'=>'Restaurar argumentos de ação legados como Post Meta. Isso é útil se você tiver problemas com plug-ins de terceiros que leem esses dados. Isso será executado em segundo plano e pode demorar um pouco.','Legacy Cron Schedule'=>'Lista de Eventos Cron Legados','The below table will show all currently scheduled cron events for the plugin with the next run time.'=>'A tabela abaixo mostrará todos os eventos cron atualmente agendados para o plug-in com o próximo tempo de execução.','Event'=>'Evento','Posts and expiration settings'=>'Configurações de postagens e expiração','This is a legacy feature and will be removed in a future version.'=>'Esse é um recurso legado e será removido em uma versão futura.','Default Formats'=>'Formatos Padrões','Date Format'=>'Formato da Data','The default format to use when displaying the action date within a post using the shortcode or within the footer. For information on valid formatting options, see: %s.'=>'O formato padrão a ser usado ao exibir a data da ação em uma postagem usando o shortcode ou no rodapé. Para obter informações sobre as opções de formatação válidas, consulte: %s.','PHP Date Function'=>'Função de Data do PHP','Time Format'=>'Formato da Hora','The default format to use when displaying the action time within a post using the shortcode or within the footer. For information on valid formatting options, see: %s.'=>'O formato padrão a ser usado ao exibir a hora da ação em uma postagem usando o shortcode ou no rodapé. Para obter informações sobre as opções de formatação válidas, consulte: %s.','Future actions column'=>'Coluna de ações futuras','Future Action Column Style'=>'Estilo de Coluna de Ações Futuras','Detailed'=>'Detalhado','Displays all information in the Future Action column.'=>'Exibe todas as informações da coluna Ação futura.','Simplified'=>'Simplificado','Displays only the icon and date/time.'=>'Exibe apenas o ícone e a data/hora.','Future actions editor'=>'Editor de ações futuras','Time format in the date picker'=>'Formato de hora no seletor de data','Inherit from Site Settings'=>'Herdar das configurações do site','24 hours'=>'24 horas','AM/PM'=>'AM/PM','Post Footer Display'=>'Exibição no Rodapé do Post','Enabling this below will display the action date automatically at the end of any post which is set to run an action.'=>'A ativação da opção abaixo exibirá a data da ação automaticamente no final de qualquer postagem definida para executar uma ação.','Show in Post Footer?'=>'Mostrar no Rodapé do Post?','This will enable or disable displaying the future action date in the post footer.'=>'Isso ativará ou desativará a exibição da data da ação futura no rodapé da postagem.','Footer Contents'=>'Conteúdo do Rodapé','Enter the text you would like to appear at the bottom of every post which has an action scheduled. The following placeholders will be replaced with the future action date in the following format:'=>'Digite o texto que você deseja que apareça na parte inferior de cada postagem que tenha uma ação programada. Os seguintes espaços reservados serão substituídos pela data da ação futura no seguinte formato:','Footer Style'=>'Estilo de Rodapé','The inline css which will be used to style the footer text.'=>'O css em linha que será usado para estilizar o texto do rodapé.','Example: '=>'Exemplo: ','Shortcode'=>'Shortcode','Valid %s attributes:'=>'Atributos válidos %s:','%1$stype%2$s - valid options are %1$sfull%2$s (default), %1$sdate%2$s, %1$stime%2$s'=>'%1$stype%2$s - as opções válidas são %1$sfull%2$s (padrão), %1$sdate%2$s, %1$stime%2$s','%s - format set here will override the value set on the settings page'=>'%s - o formato definido aqui substituirá o valor definido na página de configurações','Defaults'=>'Padrões','Calendar Visibility'=>'Visibilidade do calendário','Remember last state'=>'Lembrar do último estado','Shows or hides the calendar based on the last user interaction.'=>'Mostra ou oculta o calendário, com base na última interação do usuário.','Always hidden'=>'Sempre oculto','The calendar is always hidden by default.'=>'O calendário fica sempre oculto por padrão.','Permissions'=>'Permissões','Choose Which User Roles Can Use PublishPress Future'=>'Escolha quais funções de usuário podem usar o PublishPress Future','Email Notification'=>'Notificação por Email','Whenever an action runs, an email can be sent to alert users.'=>'Sempre que uma ação é executada, um e-mail pode ser enviado para alertar os usuários.','Enable Email Notification?'=>'Habilitar a Notificação por E-mail?','This will enable or disable the send of email notification on future action.'=>'Isso ativará ou desativará o envio de notificações por e-mail sobre ações futuras.','Include Blog Administrators?'=>'Incluir Administradores do Blog?','This will include all users with the role of "Administrator" in the email.'=>'Isso incluirá no e-mail todos os usuários com a função de "Administrador".','Enter a comma separate list of emails that you would like to be notified when the action runs. This will be applied to ALL post types. You can set post type specific emails on the Defaults tab.'=>'Insira uma lista separada por vírgulas de e-mails que você gostaria de ser notificado quando a ação for executada. Isso será aplicado a TODOS os tipos de postagem. Você pode definir e-mails específicos para cada tipo de postagem na guia Defaults (Padrões).','Post Types'=>'Tipos de Post','General'=>'Geral','Display'=>'Exibição','Advanced'=>'Avançado','Diagnostics and Tools'=>'Diagnósticos e Ferramentas']]; \ No newline at end of file +return ['domain'=>NULL,'plural-forms'=>'nplurals=2; plural=(n > 1);','language'=>'pt_BR','project-id-version'=>'Post Expirator 2.4.4','pot-creation-date'=>'2024-11-18T16:43:30+00:00','po-revision-date'=>'','x-generator'=>'Poedit 3.5','messages'=>['PublishPress Future'=>'PublishPress Future','http://wordpress.org/extend/plugins/post-expirator/'=>'http://wordpress.org/extend/plugins/post-expirator/','PublishPress Future allows you to schedule automatic changes to posts, pages and other content types.'=>'O PublishPress Future permite que você programe alterações automáticas em posts, páginas e outros tipos de conteúdo.','PublishPress'=>'PublishPress','http://publishpress.com'=>'http://publishpress.com','You do not have permission to configure PublishPress Future.'=>'Você não tem permissão para configuar o PublishPress Future.','Debug is disabled'=>'Depuração Desativada','Debugging Disabled'=>'Depuração Desativada','Debugging Enabled'=>'Depuração Ativada','Debugging Table Emptied'=>'Tabela de Depuração Esvaziada','The legacy future actions migration has been enqueued and will run asynchronously.'=>'A migração de ações futuras legadas foi enfileirada e será executada de forma assíncrona.','The legacy actions arguments restoration has been enqueued and will run asynchronously.'=>'A restauração dos argumentos de ações legadas foi enfileirada e será executada de forma assíncrona.','The database schema was fixed.'=>'A estrutura do banco de dados foi corrigida.','The database schema could not be fixed. Please, contact the support team.'=>'A estrutura do banco de dados não pode ser corrigida. Por favor, entre em contaot com o suporte.','Saved Options!'=>'Configurações salvas!','If you like %1$s, please leave us a %2$s rating. Thank you!'=>'Se você gosta do %s, por favor deixe uma avaliação %s. Obrigado!','About PublishPress Future'=>'Sobre PublishPress Future','About'=>'Sobre','Future Documentation'=>'Documentação','Documentation'=>'Documentação','Contact the PublishPress team'=>'Entre em contato com a equipe PublishPress','Contact'=>'Contato','No taxonomies found'=>'Não foram encontradas taxonomias','l F jS, Y'=>'l F jS, Y','g:ia'=>'g:ia','Post expires at EXPIRATIONTIME on ACTIONDATE'=>'O post expira às EXPIRATIONTIME do dia ACTIONDATE','The table %s does not exist.'=>'A tabela %s não existe.','The table indexes are invalid: '=>'Os índices da tabela são inválidos: ','Invalid date time offset.'=>'Deslocamento padrão de data/hora.','You do not have sufficient permissions to access this page.'=>'Você não tem permissão suficientes para acessar esta página.','Invalid nonce.'=>'Nonce inválido.','Categories'=>'Categorias','Future Actions'=>'Ações Futuras','Enable Future Action'=>'Habilitar Ação Futura','Action'=>'Ação','Loading'=>'Carregando','Show Calendar'=>'Mostrar Calendario','Hide Calendar'=>'Ocultar Calendário','Timezone is controlled by the {WordPress Settings}.'=>'O fuso horário é controlado pelas {Configurações do WordPress}.','No %s found.'=>'Não existem %s.','You must assign a taxonomy to this post type to use this feature.'=>'Você deve atribuir uma taxonomia a esse tipo de post para usar esse recurso.','New %s'=>'Novo %s','%s to remove'=>'%s para remover','%s to add'=>'%s para adicionar','Search for %s'=>'Buscar por %s','Select an action'=>'Selecionar uma ação','Select a date'=>'Selecione uma data','Date cannot be in the past'=>'A data não pode estar no passado','Please select one or more %s'=>'Selecione um ou mais %s','New status'=>'Novo status','No posts selected. Unable to sync Future Actions.'=>'Nenhuma postagem selecionada. Não é possível sincronizar as ações futuras.','Future Actions successfully synced with Post Metadata.'=>'As ações futuras foram sincronizadas com sucesso com os metadados do post.','Update Future Actions from Post Metadata'=>'Atualizar ações futuras dos metadados do post','Future Action Update'=>'Atualização de ações futuras','— No Change —'=>'— Nenhuma Alteração —','Add or update action for posts'=>'Adicionar ou atualizar ações para postagens','Add action if none exists for posts'=>'Adicionar ação se não houver nenhuma para os posts','Update the existing actions for posts'=>'Atualizar as ações existentes para postagens','Remove action from posts'=>'Remover ação das postagens','Category'=>'Categoria','Settings'=>'Configurações','Future Action'=>'Ação Futura','Future'=>'Future','Action Settings'=>'Configurações de ações','Scheduled Actions'=>'Ações Agendadas','Log format'=>'Formato de registro','List'=>'Lista','Popup'=>'Popup','Successfully executed action: %s'=>'Ação executada com sucesso: %s','Executed workflow scheduled step'=>'Etapa agendada do fluxo de trabalho executada','Cleaned up completed scheduled steps older than %d days'=>'Limpar etapas agendadas concluídas com mais de %d dias','Cleaned up orphan workflow scheduled step arguments'=>'Limpar argumentos órfãos das etapas agendadas de fluxos de trabalho','The shortcode [futureaction] must be used inside the loop or with the post_id attribute.'=>'O shortcode [futureaction] precisa ser usado dentro do loop ou com o atributo “post_id”.','The column args length was not updated to 1000.'=>'O comprimento da coluna args não foi atualizado para 1000.','Status didn\'t change.'=>'O estado não mudou.','Status has been successfully changed from "%1$s" to "%2$s".'=>'O estado foi alterado com êxito de "%s" para "%s".','Change status'=>'Alterar status','%s was not deleted.'=>'%s não foi excluído.','%s has been successfully deleted.'=>'%s foi excluído com sucesso.','Delete'=>'Excluir','No terms were added to the %s.'=>'Nenhum termo foi adicionado à %s.','The following terms (%1$s) were added to the %2$s: "%3$s". The full list of terms on the post is: %4$s.'=>'Os seguintes termos (%1$s) foram adicionados ao %2$s: “%3$s". A lista completa de termos na postagem é: %4$s.','Add extra %s'=>'Adicionar mais %s','No terms were removed from the %s.'=>'Nenhum termo foi removido de %s.','The following terms (%1$s) were removed from the %2$s: %3$s. The new list of terms on the post is: %4$s.'=>'Os seguintes termos (%1$s) foram removidos de %2$s: %3$s. A nova lista de termos no post é: %4$s.','Remove selected %s'=>'Remover %s selecionado(a)','The following terms (%1$s) were removed from the %2$s: %3$s.'=>'Os seguintes termos (%1$s) foram removidos do(a) %2$s: %3$s.','Remove all %s'=>'Remover todos(as) %s','No terms were changed on the %s.'=>'Nenhum termo foi alterado no %s.','The following terms (%1$s) were set to the %2$s: "%3$s". The old list of terms on the post was: %4$s.'=>'Os seguintes termos (%1$s) foram definidos para %2$s: “%3$s". A lista antiga de termos na postagem era: %4$s.','Replace all %s'=>'Substituir todos(as) %s','Change status to %s'=>'Alterar o estado para %s','%s didn\'t change.'=>'%s não foi alterado(a).','%s has been added to stickies list.'=>'%s foi adicionado(a) à lista de fixados.','Stick'=>'Fixar','%s has been removed from stickies list.'=>'%s foi removido da lista de fixados.','Unstick'=>'Desafixar','Email is disabled.'=>'O e-mail está desativado.','Email sent.'=>'Email enviado.','Email not sent.'=>'E-mail não enviado.','%1$s. %2$s on %3$s. The post link is %4$s'=>'%1$s. %2$s em %3$s. O link da postagem é %4$s','Future Action Complete "%s"'=>'Ação Futura Completa “%s”','[%1$s] %2$s'=>'[%1$s] %2$s','Invalid date/time offset "%s" for post type "%s". Please ensure you use only English terms for the date/time offset, such as "3 months" or "1 week".'=>'Deslocamento de data/hora "%s" inválido para o tipo de post "%s". Certifique-se de usar apenas termos em inglês para o deslocamento de data/hora, como "3 months" ou "1 week".','Status'=>'Estado','Arguments'=>'Argumentos','Logs'=>'Registros','Scheduled Date'=>'Data Programada','Recurrence'=>'Recorrência','Run'=>'Executar','Process the action now'=>'Processar a ação agora','Cancel'=>'Cancelar','Cancel the action. This will prevent the action from running in the future'=>'Cancelar a ação. Isso impedirá que a ação seja executada no futuro','%s year'=>'%s ano' . "\0" . '%s anos','%s month'=>'%s mês' . "\0" . '%s meses','%s week'=>'%s semana' . "\0" . '%s semanas','%s day'=>'%s dia' . "\0" . '%s dias','%s hour'=>'%s hora' . "\0" . '%s horas','%s minute'=>'%s minuto' . "\0" . '%s minutos','%s second'=>'%s segundo' . "\0" . '%s segundos','Action Logs'=>'Registros de Ações','Uninitialized'=>'Não inicializado','Scheduled'=>'Agendado','Complete'=>'Completo','Failed'=>'Falhou','Canceled'=>'Cancelado','Running'=>'Em Andamento','All'=>'Todos','Search hook, args and claim ID'=>'Pesquise ganchos, args e ID','Completed'=>'Executado','%1$s: [%2$d] %3$s%4$s%5$s'=>'%1$s: [%2$d] %3$s%4$s%5$s','New Status: %s'=>'Novo status: %s','Terms: %s'=>'Termos: %s','View log'=>'Visualizar o registro','Action: '=>'Ação: ','Status: '=>'Status: ','Arguments: '=>'Argumentos: ','Scheduled date: '=>'Data programada: ','Date'=>'Data','Message'=>'Mensagem','Async'=>'Assíncrono',' (%s ago)'=>' (%s atrás)',' (%s)'=>' (%s)','Now!'=>'Agora!','Every %s'=>'A cada %s','Non-repeating'=>'Sem Repetição','No Scheduled Actions.'=>'Nenhuma ação agendada.','Set the offset to use for the default action date and time. For information on formatting, see %1$s. For example, you could enter %2$s+1 month%3$s or %2$s+1 week 2 days 4 hours 2 seconds%3$s or %2$snext Thursday%3$s. Please, use only terms in English.'=>'Defina o deslocamento a ser usado para a data e hora da ação padrão. Para obter informações sobre formatação, consulte %1$s. Por exemplo, você poderia inserir %2$s+1 month%3$s ou %2$s+1 week 2 days 4 hours 2 seconds%3$s ou %2$snext Thursday%3$s. Por favor, use apenas termos em inglês.','Default Values'=>'Valores Padrão','Use the values below to set the default actions/values to be used for each for the corresponding post types. These values can all be overwritten when creating/editing the post/page.'=>'Use os valores abaixo para definir as ações/valores padrão a serem usados para cada um para os tipos de postagem correspondentes. Todos esses valores podem ser substituídos ao criar/editar o post/página.','Active'=>'Ativar','Activate the PublishPress Future actions for this post type'=>'Ative as ações do PublishPress Future para este tipo de post','Default Action'=>'Ação Padrão','Select the default action for the post type.'=>'Selecione a ação padrão para o tipo de postagem.','Select the taxonomy to be used for actions.'=>'Selecione a taxonomia a ser usada para as ações.','Auto-enable'=>'Ativação automática','Enabled for all new posts'=>'Ativado para todas as novas postagens','Taxonomy'=>'Taxonomia','No taxonomies found for this post type. Taxonomy actions will not be available.'=>'Não foram encontradas taxonomias para esse tipo de postagem. As ações de taxonomia não estarão disponíveis.','Who to Notify'=>'A quem notificar','Enter a comma separated list of emails that you would like to be notified when the action runs.'=>'Insira uma lista separada por vírgulas de e-mails que você gostaria de ser notificado quando a ação for executada.','Default Date/Time Offset'=>'Deslocamento padrão de data/hora','PHP strtotime function'=>'Função strtotime do PHP','Default terms:'=>'Termos padrão:','Save changes'=>'Salvar alterações','Wait for the validation...'=>'Aguarde a validação...','Date Preview'=>'Pré-visualização da data','Current Date'=>'Data atual','Computed Date'=>'Data calculada','Error'=>'Erro','Scheduled Workflow Steps Cleanup'=>'Limpeza das etapas agendadas do fluxo de trabalho','Automatically remove scheduled workflow steps'=>'Remover automaticamente etapas agendadas do fluxo de trabalho','Automatically remove scheduled workflow steps that have been marked as failed, completed, or cancelled.'=>'Remova automaticamente as etapas do fluxo de trabalho agendado que foram marcadas como falhas, concluídas ou canceladas.','Retain all scheduled workflow steps'=>'Reter todas as etapas agendadas do fluxo de trabalho','Retain all scheduled workflow steps indefinitely, including those marked as failed, completed, or cancelled. This may impact database performance over time.'=>'Retenha todas as etapas agendadas do fluxo de trabalho indefinidamente, inclusive aquelas marcadas como falhas, concluídas ou canceladas. Isso pode afetar o desempenho do banco de dados ao longo do tempo.','Retention'=>'Retenção','The duration, in days, for which completed, failed, and canceled scheduled workflow steps will be preserved before automatic removal.'=>'A duração, em dias, pela qual as etapas de fluxo de trabalho agendadas concluídas, falhas e canceladas serão preservadas antes da remoção automática.','days'=>'dias','Form Validation Failure: Sorry, your nonce did not verify.'=>'Falha na validação do formulário: Desculpe, seu nonce é inválido.','You\'re using PublishPress Future Free. The Pro version has more features and support. %1$sUpgrade to Pro%2$s'=>'Você está usando o PublishPress Future gratuito. A versão Pro tem mais recursos e melhor suporte. %1$sAtualize para a versão Pro%2$s','Upgrade to Pro'=>'Atualizar para Pro','Workflow Manual Trigger'=>'Acionador Manual de Fluxo de Trabalho','Action Workflows'=>'Fluxos de trabalho','Future Workflow'=>'Fluxo de Trabalho Futuro','Add New'=>'Adicionar Novo','Add New Workflow'=>'Novo Fluxo de Trabalho','Edit Workflow'=>'Editar fluxo de trabalho','New Workflow'=>'Novo fluxo de trabalho','View Workflow'=>'Ver fluxo de trabalho','Search Workflows'=>'Pesquisar fluxos de trabalho','No Workflows found'=>'Nenhum fluxo de trabalho encontrado','No Workflows found in Trash'=>'Nenhum fluxo de trabalho encontrado na lixeira','Parent Workflow:'=>'Fluxo de trabalho principal (ascendente):','All Workflows'=>'Todos','Workflow Archives'=>'Arquivos do fluxo de trabalho','Insert into workflow'=>'Inserir no fluxo de trabalho','Uploaded to this workflow'=>'Enviado para este fluxo de trabalho','Filter workflows list'=>'Filtrar a lista de fluxos de trabalho','Workflows list navigation'=>'Navegação na lista de fluxos de trabalho','Action Workflows list'=>'Lista de fluxos de trabalho','Workflow published.'=>'Fluxo de trabalho publicado.','Workflow published privately.'=>'Fluxo de trabalho publicado em particular.','Workflow reverted to draft.'=>'O fluxo de trabalho foi revertido para rascunho.','Workflow scheduled.'=>'Fluxo de trabalho agendado.','Workflow updated.'=>'Fluxo de trabalho atualizado.','Notify when a post is updated'=>'Notificar quando um post for atualizado','Notify the site admin when a post is updated.'=>'Notifique o administrador do site quando um post for atualizado.','Unpublish to Draft after a week'=>'Cancelar publicação para Rascunho após uma semana','Change the post status to Draft a week after it was published.'=>'Altere o status do post para Rascunho, uma semana após a publicação.','Unpublish and change category after one week'=>'Cancelar a publicação e alterar a categoria após uma semana','Move the post to draft and add a category after 15 days.'=>'Mova o post para rascunho, e adicione uma categoria após 15 dias.','Add extra categories one month after publishing'=>'Adicionar categorias adicionais, um mês após a publicação','Sample workflow to add extra categories one month after publishing'=>'Exemplo de fluxo de trabalho para adicionar categorias adicionais, um mês após a publicação','Workflow repeating scheduled step'=>'Repetição da etapa agendada do fluxo de trabalho','Workflow scheduled step'=>'Etapa agendada do fluxo de trabalho','Unschedule workflow recurring scheduled step'=>'Cancelar o agendamento da etapa recorrente agendada do fluxo de trabalho','Cleanup orphan workflow scheduled step arguments'=>'Limpar argumentos órfãos da etapa agendada do fluxo de trabalho','Clean up completed scheduled steps older than %d days'=>'Limpar etapas agendadas concluídas, com mais de %d dias','Step not found in workflow.'=>'Etapa não encontrada no fluxo de trabalho.','Workflow:'=>'Fluxo de trabalho:','Step:'=>'Etapa:','Trigger: '=>'Gatilho acionador: ','Post:'=>'Post:','Steps:'=>'Etapas:','Workflow recurring scheduled action'=>'Ação agendada recorrente do fluxo de trabalho','%1$s until %2$s'=>'%1$s até %2$s','%1$s for %2$d times'=>'%1$s por %2$d vezes','[%1$s/%2$d]'=>'[%1$s/%2$d]','Welcome to the workflow editor'=>'Boas-vindas ao editor de fluxo de trabalho','In the PublishPress Workflow Editor, each workflow step is presented as a distinct \'node\' in the workflow.'=>'No editor de fluxo de trabalho do PublishPress, cada etapa do fluxo é apresentada como um "nó" distinto no fluxo de trabalho.','Use your imagination'=>'Use sua imaginação','You\'re free to create very distinct workflows in your site, according to your needs.'=>'Você tem liberdade para criar fluxos de trabalho bem distintos no seu site, de acordo com suas necessidades.','A basic workflow'=>'Um fluxo de trabalho básico','Every workflow requires at least two steps connected to each other: one trigger and one action.'=>'Todo fluxo de trabalho requer pelo menos duas etapas conectadas entre si: um gatilho acionador e uma ação.','Add steps to your workflow'=>'Adicione etapas ao seu fluxo de trabalho','Drag and drop steps to add them to your workflow. Connect the steps to create a workflow.'=>'Arraste e solte etapas para adicioná-las ao seu fluxo de trabalho. Conecte as etapas para criar um fluxo de trabalho.','Output and input'=>'Saída e entrada','Linked steps can pass data forward as input to the next step.'=>'As etapas vinculadas podem passar dados adiante, como entrada para a próxima etapa.','Customize the workflow'=>'Personalizar o fluxo de trabalho','Click on a step to customize it. You can change the step\'s settings in the right sidebar.'=>'Clique em uma etapa para personalizar. Você pode alterar as configurações da etapa na barra lateral direita.','Workflow validation'=>'Validação do fluxo de trabalho','Error messages will appear for any unfilled required settings, missed connections, or invalid values. Select the step to view the corresponding error in the sidebar.'=>'Mensagens de erro aparecerão para quaisquer configurações obrigatórias não preenchidas, conexões perdidas ou valores inválidos. Selecione a etapa para visualizar o erro correspondente na barra lateral.','Publish your workflow'=>'Publique seu fluxo de trabalho','When you\'re ready, click the publish button to make your workflow live.'=>'Quando estiver pronto, clique no botão "Publicar" para ativar seu fluxo de trabalho.','Need help?'=>'Precisa de ajuda?','If you have any questions or need help, click the help button in the top right corner to access the support resources.'=>'Se você tiver alguma dúvida ou precisar de ajuda, clique no botão de ajuda, no canto superior direito, para acessar os recursos de suporte.','Triggers'=>'Gatilhos','Preview'=>'Visualização','—'=>'—','No screenshot'=>'Nenhuma captura de tela','Activate'=>'Ativar','Deactivate'=>'Desativar','Action Workflow Editor'=>'Editor de fluxo de trabalho','Post Query'=>'Consulta de Posts','A query to select posts'=>'Uma consulta para selecionar posts','Yes'=>'Sim','No'=>'Não','The workflow was not triggered.'=>'O fluxo de trabalho não foi acionado.','The workflow was triggered by the legacy action'=>'O fluxo de trabalho foi acionado pela ação legada','Trigger workflow'=>'Acionar fluxo de trabalho','Move post to status'=>'Mover post para status','This step transitions a post to a different status.'=>'Esta etapa faz a transição de um post para um status diferente.','Post'=>'Post','The post to update.'=>'O post a ser atualizado.','Select the variable that contains the post to update. It can be a post instance or the post ID.'=>'Selecione a variável que contém o post a ser atualizado. Pode ser uma instância do post ou o ID do post.','The new status that the post will be moved to.'=>'O novo status para o qual o post será movido.','Step input'=>'Entrada da etapa','The input data for this step.'=>'Os dados de entrada para esta etapa.','Next'=>'Próximo','Deactivate Workflow for Post'=>'Desativar o fluxo de trabalho para o post','This step enables you to deactivate the "Manually enabled via checkbox" workflow after use.'=>'Esta etapa permite que você desative o fluxo de trabalho "Ativado manualmente através da caixa de seleção" após o uso.','Workflow'=>'Fluxo de trabalho','Select the manually enabling workflow that will be deactivated for the selected post.'=>'Selecione o fluxo de trabalho de ativação manual que será desativado para o post selecionado.','Delete post'=>'Excluir post','This step deletes a post.'=>'Esta etapa exclui um post.','Stick post'=>'Fixar post','This step sticks a post.'=>'Esta etapa fixa um post.','The Stick Post action must be part of a Schedule flow'=>'A ação “Fixar post” precisa fazer parte de um fluxo de agendamento','Add extra terms to post'=>'Adicionar termos extras ao post','This step keeps the current taxonomy terms and adds additional terms.'=>'Esta etapa mantém os termos da taxonomia atual e adiciona termos adicionais.','Extra terms'=>'Termos adicionais','The terms that will be added to the posts.'=>'Os termos que serão adicionados aos posts.','Terms'=>'Termos','Remove terms from the post'=>'Remover termos do post','This step removes current taxonomy terms.'=>'Esta etapa remove os termos da taxonomia atual.','Terms to remove'=>'Termos a serem removidos','The terms that will be removed from the posts.'=>'Os termos que serão removidos dos posts.','Remove all terms'=>'Remover todos os termos','Replace all terms on the post'=>'Substituir todos os termos do post','This step removes the current taxonomy terms and adds new terms.'=>'Esta etapa remove os termos da taxonomia atual e adiciona novos termos.','New terms'=>'Novos termos','The terms that will be added to the posts after removing all the others.'=>'Os termos que serão adicionados aos posts após a remoção de todos os outros.','Unstick post'=>'Desafixar post','This step unsticks a post.'=>'Esta etapa desafixa um post.','PublishPress Workflow: {{global.workflow.title}}'=>'Fluxo de trabalho do PublishPress Future: {{global.workflow.title}}','This is a message sent by PublishPress Workflow: {{global.workflow.title}}.'=>'Esta é uma mensagem enviada pelo fluxo de trabalho do PublishPress Future: {{global.workflow.title}}.','Send email'=>'Enviar e-mail','This step dispatches a message via email.'=>'Esta etapa envia uma mensagem por e-mail.','The email message'=>'A mensagem do e-mail','Recipient'=>'Destinatário','Subject'=>'Assunto','Email Recipient'=>'Destinatário do e-mail','Custom Email Address'=>'E-mail Personalizado','Conditional Split'=>'Divisão condicional','This step allows you to create a conditional branch.'=>'Esta etapa permite que você crie uma ramificação condicional.','Conditions'=>'Condições','The conditions that must be met for deciding which branch to take.'=>'As condições que precisam ser atendidas para decidir qual ramificação seguir.','Branch'=>'Ramificação','The current branch on this step.'=>'A ramificação atual nesta etapa.','True'=>'Verdadeiro','False'=>'Falso','Query posts'=>'Consultar posts','This step defines the posts that will be passed to the next step in the workflow.'=>'Esta etapa define os posts que serão passados para a próxima etapa do fluxo de trabalho.','Post query'=>'Consulta de posts','The query defines the posts that will be retrieved by this action.'=>'A consulta define os posts que serão recuperados por esta ação.','Post Type'=>'Tipo de Post','Post ID'=>'ID do Post','Array of queried post IDs'=>'Array de IDs dos posts consultados','The posts found following the criteria of the query.'=>'Os posts encontrados de acordo com os critérios da consulta.','Schedule'=>'Agendar','This step enables actions to be scheduled. You can choose when to run the next step.'=>'Esta etapa permite que as ações sejam agendadas. Você pode escolher quando executar a próxima etapa.','A scheduled delay between steps.'=>'Um atraso agendado entre as etapas.','Date offset'=>'Deslocamento da data','Log - Add'=>'Registro - Adicionar','This step transmits the flow\'s data to the debug log.'=>'Esta etapa transmite os dados do fluxo para o registro de depuração.','Debug output'=>'Saída de depuração','The message to be sent to the debug log.'=>'A mensagem a ser enviada para o registro de depuração.','Level'=>'Nível','Ray - Debug'=>'Ray - Depuração','This step transmits the flow\'s data to Ray Debug.'=>'Esta etapa transmite os dados do fluxo para a depuração do Ray.','The data to be sent to Ray.'=>'Os dados a serem enviados ao Ray.','Data'=>'Dados','Label'=>'Rótulo','Color'=>'Cor','On admin init'=>'Na inicialização do painel administrativo','This trigger activates upon the initialization of the admin site.'=>'Este gatilho acionador é ativado na inicialização do painel administrativo do site.','On cron schedule'=>'No agendamento do cron','This trigger activates upon a cron schedule, allowing recurrency.'=>'Este gatilho acionador é ativado em um agendamento cron, permitindo a recorrência.','A schedule to activate the workflow.'=>'Um agendamento para ativar o fluxo de trabalho.','On site init'=>'Na inicialização do site','This trigger activates upon site initialization.'=>'Este gatilho acionador é ativado na inicialização do site.','Manually enabled via checkbox'=>'Ativado manualmente através da caixa de seleção','This trigger activates when the option is manually enabled. It can be enabled via the post editing screen or the Quick Edit panel.'=>'Este gatilho acionador é ativado quando a opção for ativada manualmente. Ela pode ser ativada através da tela de edição do post ou do painel de edição rápida.','Settings for the trigger.'=>'Configurações do gatilho acionador.','Checkbox label'=>'Rótulo de caixa de seleção','The label of the checkbox that enables the trigger.'=>'O rótulo da caixa de seleção que ativa o acionador.','Specify the criteria for posts that will trigger this action. Leave blank to include all posts.'=>'Especifique os critérios para os posts que irão acionar esta ação. Deixe em branco para incluir todos os posts.','The query defines the posts that will trigger this action.'=>'A consulta define os posts que irão acionar esta ação.','Saved post'=>'Post salvo','The post that was saved, with the new properties.'=>'O post que foi salvo, com as novas propriedades.','Post is updated'=>'Post atualizado','This trigger activates when an existing post is updated.'=>'Este gatilho acionador é ativado quando um post existente for atualizado.','Post Before Update'=>'Publicar antes de atualizar','The post that was saved, with the old properties.'=>'O post que foi salvo, com as propriedades antigas.','Post After Update'=>'Post após a atualização','Post is saved'=>'Post salvo','This trigger activates whenever a post is saved, regardless of whether it\'s newly created, imported, or updated.'=>'Esse gatilho é ativado sempre que um post é salvo, seja recém criado, importado ou atualizado.','Manually enabled via Future Actions box'=>'Ativado manualmente através da caixa "Ações futuras"','This trigger allows users to choose the workflow from the dropdown menu in the Future Actions options.'=>'Este gatilho acionador permite que os usuários escolham o fluxo de trabalho no menu suspenso, nas opções de ações futuras.','Action Post'=>'Post da ação','The post that was saved triggering the action.'=>'O post que foi salvo, acionando a ação.','Site'=>'Site','Flow Control'=>'Controle do fluxo','Asynchronous'=>'Asincrono','Debug'=>'Depuração','Data Query'=>'Consulta de Dados','Messages'=>'Mensagens','The ID of the workflow'=>'O ID do fluxo de trabalho','The taxonomy name'=>'O nome da taxonomia','The post ID'=>'O ID do post','Workflow not found'=>'Fluxo de trabalho não encontrado','Loading the workflow editor...'=>'Carregando o editor do fluxo de trabalho...','Screenshot'=>'Captura de tela','Upgrade to PublishPress Future Pro'=>'Faça upgrade para o PublishPress Future Pro','Enhance the power of PublishPress Future with the Pro version:'=>'Aumente o poder do PublishPress Future com a versão Pro:','Design custom workflows with multiple actions'=>'Crie fluxos de trabalho personalizados com várias ações','Schedule actions based on the post\'s publishing date'=>'Agende ações com base na data de publicação do post','Move posts to custom statuses'=>'Mover postagens para status personalizados','Use other plugins to control Future Actions'=>'Use outros plugins para controlar as ações futuras','Enjoy fast and professional support'=>'Conte com um suporte rápido e profissional','Need PublishPress Future Support?'=>'Precisa de suporte para PublishPress Future?','If you need help or have a new feature request, let us know.'=>'Se precisar de ajuda ou tiver uma solicitação de novo recurso, entre em contato conosco.','Request Support'=>'Solicitar Suporte','Detailed documentation is also available on the plugin website.'=>'A documentação detalhada também está disponível no site do plugin.','View Knowledge Base'=>'Ver Base de Conhecimento','%1$s%2$s%3$s on %5$s%4$s%6$s'=>'%1$s%2$s%3$s em %5$s%4$s%6$s','Action was not scheduled due to a configuration issue. Please attempt to schedule it again.'=>'A ação não foi agendada devido a um problema de configuração. Tente agendá-la novamente.','No future action'=>'Nenhuma ação futura','Advanced Options'=>'Opções avançadas','Workflow Step Schedule\'s Arguments Compression'=>'Compactação dos argumentos do agendamento da etapa do fluxo de trabalho','Compress the arguments'=>'Compactar os argumentos','Compress the arguments of the step schedule to save memory in the database, saving them as binary data.'=>'Compacte os argumentos do agendamento da etapa, para economizar memória no banco de dados, salvando-os como dados binários.','Do not compress the arguments'=>'Não compactar os argumentos','Do not compress the arguments of the step schedule, storing them as plain text.'=>'Não compacte os argumentos do agendamento da etapa, armazenando-os como texto simples.','Experimental Features'=>'Recursos experimentais','Enable experimental features'=>'Ativar recursos experimentais','Enable experimental features that are still in development and may not be fully functional.'=>'Ative recursos experimentais que ainda estão em desenvolvimento e podem não estar totalmente funcionais.','Preserve Data After Deactivating the Plugin'=>'Preservar Dados Após Desativar o Plug-in','Preserve data'=>'Preservar dados','Delete data'=>'Excluir dados','Toggle between preserving or deleting data after the plugin is deactivated.'=>'Alternar entre preservar ou excluir dados depois que o plug-in for desativado.','Save Changes'=>'Salvar Alterações','Below is a dump of the debugging table, this should be useful for troubleshooting.'=>'Abaixo está o conteúdo da tabela de depuração, isso pode ser útil para a solução de problemas.','Debugging table is currently empty.'=>'A tabela de depuração está atualmente vazia.','Number of logs to display:'=>'Número de registros a serem exibidos:','Showing the latest %d of %d results. The approximate size of the log is %s.'=>'Exibindo os últimos %d de %d resultados. O tamanho aproximado do registro é %s.','Showing all %d results. The approximate size of the log is %s.'=>'Exibindo todos os %d resultados. O tamanho aproximado do registro é %s.','Copy Debug Log'=>'Copiar registro de depuração','Download Entire Log'=>'Baixar o registro completo','Debug log copied to clipboard!'=>'O registro de depuração foi copiado para a área de transferência!','Advanced Diagnostics and Tools'=>'Diagnósticos Avançados e Ferramentas','WP-Cron Status Check'=>'Verificação do status do WP-Cron','Passed'=>'Aprovado','WP Cron Disabled'=>'WP Cron desativado','Database Schema Check'=>'Verificação da Estrutura do Banco de Dados','Error found on the database schema:'=>'Erro encontrado no esquema do banco de dados:' . "\0" . 'Erros encontrados no esquema do banco de dados:','Try to Fix Database'=>'Tentar corrigir o banco de dados','Debug Logging'=>'Registro de depuração','Enabled'=>'Habilitar','Disable Debugging'=>'Desativar a depuração','Purge Debug Log'=>'Limpar registro de depuração','View Debug Logs'=>'Exibir registros de depuração','Disabled'=>'Desabilitar','Enable Debugging'=>'Habilitar Depuração','Migrate Legacy Future Actions'=>'Migrar Ações Futuras Legadas','Run Migration'=>'Executar a Migração','Migrate legacy future actions from WP Cron to the new Action Scheduler. This will run in the background and may take a while.'=>'Migre as ações futuras legadas do WP Cron para o novo Action Scheduler. Isso será executado em segundo plano e pode demorar um pouco.','Restore Legacy Action Arguments'=>'Restaurar Argumentos de Ações Legados','Run Data Restoration'=>'Executar Restauração de Dados','Restore legacy action arguments as Post Meta. This is useful if you have issues with 3rd party plugins that read that data. This will run in the background and may take a while.'=>'Restaurar argumentos de ação legados como Post Meta. Isso é útil se você tiver problemas com plug-ins de terceiros que leem esses dados. Isso será executado em segundo plano e pode demorar um pouco.','Legacy Cron Schedule'=>'Lista de Eventos Cron Legados','The below table will show all currently scheduled cron events for the plugin with the next run time.'=>'A tabela abaixo mostrará todos os eventos cron atualmente agendados para o plug-in com o próximo tempo de execução.','Event'=>'Evento','Posts and expiration settings'=>'Configurações de postagens e expiração','This is a legacy feature and will be removed in a future version.'=>'Esse é um recurso legado e será removido em uma versão futura.','Default Formats'=>'Formatos Padrões','Date Format'=>'Formato da Data','The default format to use when displaying the action date within a post using the shortcode or within the footer. For information on valid formatting options, see: %s.'=>'O formato padrão a ser usado ao exibir a data da ação em uma postagem usando o shortcode ou no rodapé. Para obter informações sobre as opções de formatação válidas, consulte: %s.','PHP Date Function'=>'Função de Data do PHP','Time Format'=>'Formato da Hora','The default format to use when displaying the action time within a post using the shortcode or within the footer. For information on valid formatting options, see: %s.'=>'O formato padrão a ser usado ao exibir a hora da ação em uma postagem usando o shortcode ou no rodapé. Para obter informações sobre as opções de formatação válidas, consulte: %s.','Future Actions Column'=>'Coluna de Ações Futuras','Future Action Column Style'=>'Estilo de Coluna de Ações Futuras','Detailed'=>'Detalhado','Displays all information in the Future Action column.'=>'Exibe todas as informações da coluna Ação futura.','Simplified'=>'Simplificado','Displays only the icon and date/time.'=>'Exibe apenas o ícone e a data/hora.','Future Actions Editor'=>'Editor de ações futuras','Time format in the date picker'=>'Formato de hora no seletor de data','Inherit from Site Settings'=>'Herdar das configurações do site','24 hours'=>'24 horas','AM/PM'=>'AM/PM','Post Footer Display'=>'Exibição no Rodapé do Post','Enabling this below will display the action date automatically at the end of any post which is set to run an action.'=>'A ativação da opção abaixo exibirá a data da ação automaticamente no final de qualquer postagem definida para executar uma ação.','Show in Post Footer?'=>'Mostrar no Rodapé do Post?','This will enable or disable displaying the future action date in the post footer.'=>'Isso ativará ou desativará a exibição da data da ação futura no rodapé da postagem.','Footer Contents'=>'Conteúdo do Rodapé','Enter the text you would like to appear at the bottom of every post which has an action scheduled. The following placeholders will be replaced with the future action date in the following format:'=>'Digite o texto que você deseja que apareça na parte inferior de cada postagem que tenha uma ação programada. Os seguintes espaços reservados serão substituídos pela data da ação futura no seguinte formato:','Footer Style'=>'Estilo de Rodapé','The inline css which will be used to style the footer text.'=>'O css em linha que será usado para estilizar o texto do rodapé.','Example: '=>'Exemplo: ','Shortcode'=>'Shortcode','Valid %s attributes:'=>'Atributos válidos %s:','%1$stype%2$s - valid options are %1$sfull%2$s (default), %1$sdate%2$s, %1$stime%2$s'=>'%1$stype%2$s - as opções válidas são %1$sfull%2$s (padrão), %1$sdate%2$s, %1$stime%2$s','%s - format set here will override the value set on the settings page'=>'%s - o formato definido aqui substituirá o valor definido na página de configurações','Defaults'=>'Padrões','Calendar Visibility'=>'Visibilidade do calendário','Remember last state'=>'Lembrar do último estado','Shows or hides the calendar based on the last user interaction.'=>'Mostra ou oculta o calendário, com base na última interação do usuário.','Always hidden'=>'Sempre oculto','The calendar is always hidden by default.'=>'O calendário fica sempre oculto por padrão.','Permissions'=>'Permissões','Choose Which User Roles Can Use PublishPress Future'=>'Escolha quais funções de usuário podem usar o PublishPress Future','Email Notification'=>'Notificação por Email','Whenever an action runs, an email can be sent to alert users.'=>'Sempre que uma ação é executada, um e-mail pode ser enviado para alertar os usuários.','Enable Email Notification?'=>'Habilitar a Notificação por E-mail?','This will enable or disable the send of email notification on future action.'=>'Isso ativará ou desativará o envio de notificações por e-mail sobre ações futuras.','Include Blog Administrators?'=>'Incluir Administradores do Blog?','This will include all users with the role of "Administrator" in the email.'=>'Isso incluirá no e-mail todos os usuários com a função de "Administrador".','Enter a comma separate list of emails that you would like to be notified when the action runs. This will be applied to ALL post types. You can set post type specific emails on the Defaults tab.'=>'Insira uma lista separada por vírgulas de e-mails que você gostaria de ser notificado quando a ação for executada. Isso será aplicado a TODOS os tipos de postagem. Você pode definir e-mails específicos para cada tipo de postagem na guia Defaults (Padrões).','Post Types'=>'Tipos de Post','General'=>'Geral','Display'=>'Exibição','Advanced'=>'Avançado','Diagnostics and Tools'=>'Diagnósticos e Ferramentas']]; \ No newline at end of file diff --git a/languages/post-expirator-pt_BR.mo b/languages/post-expirator-pt_BR.mo index 8f678514f9035df6e6a644cc9c9de5ee17983565..9b282a4f5b64a403f7f2babbb53ebb647301697d 100644 GIT binary patch delta 150 zcmZ2^hiT;ptF1Tw!@ zFff2LEeWJ^pmf`2MbVS8lf{gEwcScfN{dnz5|c|Z^Ye-olJj#)bMqL` xL{n2TOY)00CmBz5ovdA1D(nnYm6xcH0@QbS`Qfdp#R_SYxhfSmFR1J^0RTw;F~\n" "Language-Team: LANGUAGE \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"POT-Creation-Date: 2024-11-21T14:06:00+00:00\n" +"POT-Creation-Date: 2024-12-09T15:08:06+00:00\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "X-Generator: WP-CLI 2.11.0\n" "X-Domain: post-expirator\n" @@ -41,73 +41,74 @@ msgstr "" msgid "http://publishpress.com" msgstr "" -#: legacy/classes/Display.class.php:106 +#: legacy/classes/Display.class.php:112 msgid "You do not have permission to configure PublishPress Future." msgstr "" -#: legacy/classes/Display.class.php:120 +#: legacy/classes/Display.class.php:126 msgid "Debug is disabled" msgstr "" -#: legacy/classes/Display.class.php:206 +#: legacy/classes/Display.class.php:214 msgid "Debugging Disabled" msgstr "" -#: legacy/classes/Display.class.php:211 +#: legacy/classes/Display.class.php:219 msgid "Debugging Enabled" msgstr "" -#: legacy/classes/Display.class.php:219 +#: legacy/classes/Display.class.php:227 msgid "Debugging Table Emptied" msgstr "" -#: legacy/classes/Display.class.php:225 +#: legacy/classes/Display.class.php:233 msgid "The legacy future actions migration has been enqueued and will run asynchronously." msgstr "" -#: legacy/classes/Display.class.php:234 +#: legacy/classes/Display.class.php:242 msgid "The legacy actions arguments restoration has been enqueued and will run asynchronously." msgstr "" -#: legacy/classes/Display.class.php:249 +#: legacy/classes/Display.class.php:257 msgid "The database schema was fixed." msgstr "" -#: legacy/classes/Display.class.php:254 +#: legacy/classes/Display.class.php:262 msgid "The database schema could not be fixed. Please, contact the support team." msgstr "" -#: legacy/classes/Display.class.php:349 -#: legacy/classes/Display.class.php:383 +#: legacy/classes/Display.class.php:334 +#: legacy/classes/Display.class.php:371 +#: legacy/classes/Display.class.php:404 msgid "Saved Options!" msgstr "" #. translators: %1$s is the plugin name, %2$s is the star rating markup -#: legacy/classes/Display.class.php:469 +#: legacy/classes/Display.class.php:490 msgid "If you like %1$s, please leave us a %2$s rating. Thank you!" msgstr "" -#: legacy/classes/Display.class.php:484 +#: legacy/classes/Display.class.php:505 msgid "About PublishPress Future" msgstr "" -#: legacy/classes/Display.class.php:486 +#: legacy/classes/Display.class.php:507 msgid "About" msgstr "" -#: legacy/classes/Display.class.php:492 +#: legacy/classes/Display.class.php:513 msgid "Future Documentation" msgstr "" -#: legacy/classes/Display.class.php:494 +#: legacy/classes/Display.class.php:515 msgid "Documentation" msgstr "" -#: legacy/classes/Display.class.php:500 +#: legacy/classes/Display.class.php:521 msgid "Contact the PublishPress team" msgstr "" -#: legacy/classes/Display.class.php:502 +#: legacy/classes/Display.class.php:523 msgid "Contact" msgstr "" @@ -115,18 +116,18 @@ msgstr "" msgid "No taxonomies found" msgstr "" -#: services.php:110 -#: src/Modules/Settings/SettingsFacade.php:110 +#: services.php:111 +#: src/Modules/Settings/SettingsFacade.php:117 msgid "l F jS, Y" msgstr "" -#: services.php:114 -#: src/Modules/Settings/SettingsFacade.php:111 +#: services.php:115 +#: src/Modules/Settings/SettingsFacade.php:118 msgid "g:ia" msgstr "" -#: services.php:115 -#: src/Modules/Settings/SettingsFacade.php:112 +#: services.php:116 +#: src/Modules/Settings/SettingsFacade.php:119 msgid "Post expires at EXPIRATIONTIME on ACTIONDATE" msgstr "" @@ -147,6 +148,22 @@ msgstr "" msgid "Invalid date time offset." msgstr "" +#: src/Modules/Backup/Controllers/BackupRestApi.php:141 +msgid "Failed to get workflows. Check the logs for more details." +msgstr "" + +#: src/Modules/Backup/Controllers/BackupRestApi.php:194 +msgid "Failed to export the file. Check the logs for more details." +msgstr "" + +#: src/Modules/Backup/Controllers/BackupRestApi.php:391 +msgid "Failed to import the file. Check the logs for more details." +msgstr "" + +#: src/Modules/Backup/Views/debug-panel.php:8 +msgid "Export / Import" +msgstr "" + #: src/Modules/Debug/Controllers/Controller.php:72 msgid "You do not have sufficient permissions to access this page." msgstr "" @@ -155,150 +172,148 @@ msgstr "" msgid "Invalid nonce." msgstr "" -#: src/Modules/Expirator/Controllers/BlockEditorController.php:142 -#: src/Modules/Expirator/Controllers/BulkEditController.php:186 -#: src/Modules/Expirator/Controllers/QuickEditController.php:308 -msgid "Categories" -msgstr "" - -#: src/Modules/Expirator/Controllers/BlockEditorController.php:143 -#: src/Modules/Expirator/Controllers/BlockEditorController.php:145 -#: src/Modules/Expirator/Controllers/BulkEditController.php:187 -#: src/Modules/Expirator/Controllers/BulkEditController.php:189 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:154 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:386 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:388 -#: src/Modules/Expirator/Controllers/QuickEditController.php:309 -#: src/Modules/Expirator/Controllers/QuickEditController.php:311 +#: src/Modules/Expirator/Controllers/BlockEditorController.php:125 +#: src/Modules/Expirator/Controllers/BulkEditController.php:167 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:137 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:369 +#: src/Modules/Expirator/Controllers/QuickEditController.php:297 +#: src/Views/menu-display.php:129 msgid "Future Actions" msgstr "" -#: src/Modules/Expirator/Controllers/BlockEditorController.php:144 -#: src/Modules/Expirator/Controllers/BulkEditController.php:188 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:387 -#: src/Modules/Expirator/Controllers/QuickEditController.php:310 +#: src/Modules/Expirator/Controllers/BlockEditorController.php:126 +#: src/Modules/Expirator/Controllers/BulkEditController.php:168 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:370 +#: src/Modules/Expirator/Controllers/QuickEditController.php:298 +#: src/Views/menu-display.php:152 msgid "Enable Future Action" msgstr "" -#: src/Modules/Expirator/Controllers/BlockEditorController.php:146 -#: src/Modules/Expirator/Controllers/BulkEditController.php:190 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:389 -#: src/Modules/Expirator/Controllers/QuickEditController.php:312 +#: src/Modules/Expirator/Controllers/BlockEditorController.php:145 +#: src/Modules/Expirator/Controllers/BulkEditController.php:189 +#: src/Modules/Expirator/Controllers/QuickEditController.php:319 +msgid "Categories" +msgstr "" + +#: src/Modules/Expirator/Controllers/BlockEditorController.php:148 +#: src/Modules/Expirator/Controllers/BulkEditController.php:192 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:393 +#: src/Modules/Expirator/Controllers/QuickEditController.php:322 #: src/Modules/Expirator/Tables/ScheduledActionsTable.php:49 msgid "Action" msgstr "" -#: src/Modules/Expirator/Controllers/BlockEditorController.php:147 -#: src/Modules/Expirator/Controllers/BulkEditController.php:193 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:392 -#: src/Modules/Expirator/Controllers/QuickEditController.php:315 +#: src/Modules/Expirator/Controllers/BlockEditorController.php:149 +#: src/Modules/Expirator/Controllers/BulkEditController.php:195 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:396 +#: src/Modules/Expirator/Controllers/QuickEditController.php:325 msgid "Loading" msgstr "" -#: src/Modules/Expirator/Controllers/BlockEditorController.php:148 -#: src/Modules/Expirator/Controllers/BulkEditController.php:191 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:390 -#: src/Modules/Expirator/Controllers/QuickEditController.php:313 +#: src/Modules/Expirator/Controllers/BlockEditorController.php:150 +#: src/Modules/Expirator/Controllers/BulkEditController.php:193 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:394 +#: src/Modules/Expirator/Controllers/QuickEditController.php:323 msgid "Show Calendar" msgstr "" -#: src/Modules/Expirator/Controllers/BlockEditorController.php:149 -#: src/Modules/Expirator/Controllers/BulkEditController.php:192 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:391 -#: src/Modules/Expirator/Controllers/QuickEditController.php:314 +#: src/Modules/Expirator/Controllers/BlockEditorController.php:151 +#: src/Modules/Expirator/Controllers/BulkEditController.php:194 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:395 +#: src/Modules/Expirator/Controllers/QuickEditController.php:324 msgid "Hide Calendar" msgstr "" #. translators: the text between {} is the link to the settings page. #. translators: the text between {{}} is the link to the settings page. -#: src/Modules/Expirator/Controllers/BlockEditorController.php:151 -#: src/Modules/Expirator/Controllers/BulkEditController.php:195 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:394 -#: src/Modules/Expirator/Controllers/QuickEditController.php:317 +#: src/Modules/Expirator/Controllers/BlockEditorController.php:153 +#: src/Modules/Expirator/Controllers/BulkEditController.php:197 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:398 +#: src/Modules/Expirator/Controllers/QuickEditController.php:327 msgid "Timezone is controlled by the {WordPress Settings}." msgstr "" #. translators: %s is the name of the taxonomy in plural form. -#: src/Modules/Expirator/Controllers/BlockEditorController.php:158 -#: src/Modules/Expirator/Controllers/BulkEditController.php:202 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:401 -#: src/Modules/Expirator/Controllers/QuickEditController.php:321 +#: src/Modules/Expirator/Controllers/BlockEditorController.php:160 +#: src/Modules/Expirator/Controllers/BulkEditController.php:204 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:405 +#: src/Modules/Expirator/Controllers/QuickEditController.php:331 msgid "No %s found." msgstr "" -#: src/Modules/Expirator/Controllers/BlockEditorController.php:161 -#: src/Modules/Expirator/Controllers/BulkEditController.php:206 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:404 -#: src/Modules/Expirator/Controllers/QuickEditController.php:324 +#: src/Modules/Expirator/Controllers/BlockEditorController.php:163 +#: src/Modules/Expirator/Controllers/BulkEditController.php:208 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:408 +#: src/Modules/Expirator/Controllers/QuickEditController.php:334 msgid "You must assign a taxonomy to this post type to use this feature." msgstr "" #. translators: %s is the name of the taxonomy in plural form. -#: src/Modules/Expirator/Controllers/BlockEditorController.php:166 -#: src/Modules/Expirator/Controllers/BulkEditController.php:216 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:409 -#: src/Modules/Expirator/Controllers/QuickEditController.php:326 +#: src/Modules/Expirator/Controllers/BlockEditorController.php:168 +#: src/Modules/Expirator/Controllers/BulkEditController.php:218 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:413 +#: src/Modules/Expirator/Controllers/QuickEditController.php:336 msgid "New %s" msgstr "" #. translators: %s is the name of the taxonomy in plural form. -#: src/Modules/Expirator/Controllers/BlockEditorController.php:168 -#: src/Modules/Expirator/Controllers/BulkEditController.php:218 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:411 -#: src/Modules/Expirator/Controllers/QuickEditController.php:328 +#: src/Modules/Expirator/Controllers/BlockEditorController.php:170 +#: src/Modules/Expirator/Controllers/BulkEditController.php:220 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:415 +#: src/Modules/Expirator/Controllers/QuickEditController.php:338 msgid "%s to remove" msgstr "" #. translators: %s is the name of the taxonomy in plural form. -#: src/Modules/Expirator/Controllers/BlockEditorController.php:170 -#: src/Modules/Expirator/Controllers/BulkEditController.php:220 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:413 -#: src/Modules/Expirator/Controllers/QuickEditController.php:330 +#: src/Modules/Expirator/Controllers/BlockEditorController.php:172 +#: src/Modules/Expirator/Controllers/BulkEditController.php:222 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:417 +#: src/Modules/Expirator/Controllers/QuickEditController.php:340 msgid "%s to add" msgstr "" #. translators: %s is the name of the taxonomy in singular form. -#: src/Modules/Expirator/Controllers/BlockEditorController.php:173 -#: src/Modules/Expirator/Controllers/BulkEditController.php:223 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:416 -#: src/Modules/Expirator/Controllers/QuickEditController.php:332 +#: src/Modules/Expirator/Controllers/BlockEditorController.php:175 +#: src/Modules/Expirator/Controllers/BulkEditController.php:225 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:420 +#: src/Modules/Expirator/Controllers/QuickEditController.php:342 msgid "Search for %s" msgstr "" -#: src/Modules/Expirator/Controllers/BlockEditorController.php:176 -#: src/Modules/Expirator/Controllers/BulkEditController.php:226 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:419 -#: src/Modules/Expirator/Controllers/QuickEditController.php:333 +#: src/Modules/Expirator/Controllers/BlockEditorController.php:178 +#: src/Modules/Expirator/Controllers/BulkEditController.php:228 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:423 +#: src/Modules/Expirator/Controllers/QuickEditController.php:343 msgid "Select an action" msgstr "" -#: src/Modules/Expirator/Controllers/BlockEditorController.php:177 -#: src/Modules/Expirator/Controllers/BulkEditController.php:227 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:420 -#: src/Modules/Expirator/Controllers/QuickEditController.php:334 +#: src/Modules/Expirator/Controllers/BlockEditorController.php:179 +#: src/Modules/Expirator/Controllers/BulkEditController.php:229 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:424 +#: src/Modules/Expirator/Controllers/QuickEditController.php:344 msgid "Select a date" msgstr "" -#: src/Modules/Expirator/Controllers/BlockEditorController.php:178 -#: src/Modules/Expirator/Controllers/BulkEditController.php:228 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:421 -#: src/Modules/Expirator/Controllers/QuickEditController.php:335 +#: src/Modules/Expirator/Controllers/BlockEditorController.php:180 +#: src/Modules/Expirator/Controllers/BulkEditController.php:230 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:425 +#: src/Modules/Expirator/Controllers/QuickEditController.php:345 msgid "Date cannot be in the past" msgstr "" #. translators: %s is the name of the taxonomy in singular form. -#: src/Modules/Expirator/Controllers/BlockEditorController.php:181 -#: src/Modules/Expirator/Controllers/BulkEditController.php:231 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:424 -#: src/Modules/Expirator/Controllers/QuickEditController.php:338 +#: src/Modules/Expirator/Controllers/BlockEditorController.php:183 +#: src/Modules/Expirator/Controllers/BulkEditController.php:233 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:428 +#: src/Modules/Expirator/Controllers/QuickEditController.php:348 #: src/Modules/Settings/Controllers/Controller.php:270 msgid "Please select one or more %s" msgstr "" -#: src/Modules/Expirator/Controllers/BlockEditorController.php:184 -#: src/Modules/Expirator/Controllers/BulkEditController.php:234 -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:427 -#: src/Modules/Expirator/Controllers/QuickEditController.php:341 +#: src/Modules/Expirator/Controllers/BlockEditorController.php:186 +#: src/Modules/Expirator/Controllers/BulkEditController.php:236 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:431 +#: src/Modules/Expirator/Controllers/QuickEditController.php:351 #: src/Modules/Workflows/Domain/NodeTypes/Actions/CorePostChangeStatus.php:79 #: src/Modules/Workflows/Domain/NodeTypes/Actions/CorePostChangeStatus.php:85 msgid "New status" @@ -316,31 +331,31 @@ msgstr "" msgid "Update Future Actions from Post Metadata" msgstr "" -#: src/Modules/Expirator/Controllers/BulkEditController.php:205 +#: src/Modules/Expirator/Controllers/BulkEditController.php:207 msgid "Future Action Update" msgstr "" -#: src/Modules/Expirator/Controllers/BulkEditController.php:210 +#: src/Modules/Expirator/Controllers/BulkEditController.php:212 msgid "— No Change —" msgstr "" -#: src/Modules/Expirator/Controllers/BulkEditController.php:211 +#: src/Modules/Expirator/Controllers/BulkEditController.php:213 msgid "Add or update action for posts" msgstr "" -#: src/Modules/Expirator/Controllers/BulkEditController.php:212 +#: src/Modules/Expirator/Controllers/BulkEditController.php:214 msgid "Add action if none exists for posts" msgstr "" -#: src/Modules/Expirator/Controllers/BulkEditController.php:213 +#: src/Modules/Expirator/Controllers/BulkEditController.php:215 msgid "Update the existing actions for posts" msgstr "" -#: src/Modules/Expirator/Controllers/BulkEditController.php:214 +#: src/Modules/Expirator/Controllers/BulkEditController.php:216 msgid "Remove action from posts" msgstr "" -#: src/Modules/Expirator/Controllers/ClassicEditorController.php:385 +#: src/Modules/Expirator/Controllers/ClassicEditorController.php:390 msgid "Category" msgstr "" @@ -361,8 +376,8 @@ msgstr "" #: src/Modules/Expirator/Controllers/ScheduledActionsController.php:130 #: src/Modules/Expirator/Controllers/ScheduledActionsController.php:131 -#: src/Modules/Settings/Controllers/Controller.php:600 -#: src/Views/tabs.php:59 +#: src/Modules/Settings/Controllers/Controller.php:601 +#: src/Views/tabs.php:64 msgid "Action Settings" msgstr "" @@ -370,7 +385,7 @@ msgstr "" #: src/Modules/Expirator/Controllers/ScheduledActionsController.php:140 #: src/Modules/Expirator/Controllers/ScheduledActionsController.php:337 #: src/Modules/Expirator/Tables/ScheduledActionsTable.php:46 -#: src/Modules/Workflows/Controllers/WorkflowsList.php:439 +#: src/Modules/Workflows/Controllers/WorkflowsList.php:452 msgid "Scheduled Actions" msgstr "" @@ -730,7 +745,7 @@ msgstr "" #: src/Modules/Expirator/Tables/ScheduledActionsTable.php:654 #: src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php:77 -#: src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php:96 +#: src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php:99 #: src/Modules/Workflows/Domain/NodeTypes/Advanced/LogAdd.php:70 msgid "Message" msgstr "" @@ -768,7 +783,7 @@ msgstr "" #. translators: %1$s is the link to the PHP strtotime function documentation, %2$s and %3$s are the opening and closing code tags. Please, do not translate the date format text, since PHP will not be able to calculate using non-english terms. #: src/Modules/Settings/Controllers/Controller.php:224 -#: src/Views/menu-general.php:76 +#: src/Views/menu-general.php:47 msgid "Set the offset to use for the default action date and time. For information on formatting, see %1$s. For example, you could enter %2$s+1 month%3$s or %2$s+1 week 2 days 4 hours 2 seconds%3$s or %2$snext Thursday%3$s. Please, use only terms in English." msgstr "" @@ -818,7 +833,7 @@ msgid "No taxonomies found for this post type. Taxonomy actions will not be avai msgstr "" #: src/Modules/Settings/Controllers/Controller.php:254 -#: src/Views/menu-general.php:223 +#: src/Views/menu-notifications.php:104 msgid "Who to Notify" msgstr "" @@ -827,12 +842,12 @@ msgid "Enter a comma separated list of emails that you would like to be notified msgstr "" #: src/Modules/Settings/Controllers/Controller.php:259 -#: src/Views/menu-general.php:68 +#: src/Views/menu-general.php:39 msgid "Default Date/Time Offset" msgstr "" #: src/Modules/Settings/Controllers/Controller.php:262 -#: src/Views/menu-general.php:83 +#: src/Views/menu-general.php:54 msgid "PHP strtotime function" msgstr "" @@ -900,7 +915,7 @@ msgstr "" msgid "days" msgstr "" -#: src/Modules/Settings/Controllers/Controller.php:480 +#: src/Modules/Settings/Controllers/Controller.php:481 msgid "Form Validation Failure: Sorry, your nonce did not verify." msgstr "" @@ -909,7 +924,7 @@ msgstr "" msgid "You're using PublishPress Future Free. The Pro version has more features and support. %1$sUpgrade to Pro%2$s" msgstr "" -#: src/Modules/VersionNotices/Module.php:129 +#: src/Modules/VersionNotices/Module.php:133 #: src/Views/ad-banner-right-sidebar.php:37 msgid "Upgrade to Pro" msgstr "" @@ -920,7 +935,7 @@ msgstr "" #: src/Modules/Workflows/Controllers/ManualPostTrigger.php:336 #: src/Modules/Workflows/Controllers/PostType.php:48 -#: src/Modules/Workflows/Controllers/WorkflowsList.php:139 +#: src/Modules/Workflows/Controllers/WorkflowsList.php:149 #: src/Modules/Workflows/Views/manual-trigger-quick-edit.html.php:9 msgid "Action Workflows" msgstr "" @@ -942,7 +957,7 @@ msgid "Edit Workflow" msgstr "" #: src/Modules/Workflows/Controllers/PostType.php:53 -#: src/Modules/Workflows/Models/WorkflowModel.php:448 +#: src/Modules/Workflows/Models/WorkflowModel.php:455 msgid "New Workflow" msgstr "" @@ -1111,105 +1126,105 @@ msgstr "" msgid "[%1$s/%2$d]" msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowEditor.php:241 +#: src/Modules/Workflows/Controllers/WorkflowEditor.php:242 msgid "Welcome to the workflow editor" msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowEditor.php:242 +#: src/Modules/Workflows/Controllers/WorkflowEditor.php:243 msgid "In the PublishPress Workflow Editor, each workflow step is presented as a distinct 'node' in the workflow." msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowEditor.php:246 +#: src/Modules/Workflows/Controllers/WorkflowEditor.php:247 msgid "Use your imagination" msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowEditor.php:247 +#: src/Modules/Workflows/Controllers/WorkflowEditor.php:248 msgid "You're free to create very distinct workflows in your site, according to your needs." msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowEditor.php:251 +#: src/Modules/Workflows/Controllers/WorkflowEditor.php:252 msgid "A basic workflow" msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowEditor.php:252 +#: src/Modules/Workflows/Controllers/WorkflowEditor.php:253 msgid "Every workflow requires at least two steps connected to each other: one trigger and one action." msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowEditor.php:256 +#: src/Modules/Workflows/Controllers/WorkflowEditor.php:257 msgid "Add steps to your workflow" msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowEditor.php:257 +#: src/Modules/Workflows/Controllers/WorkflowEditor.php:258 msgid "Drag and drop steps to add them to your workflow. Connect the steps to create a workflow." msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowEditor.php:261 +#: src/Modules/Workflows/Controllers/WorkflowEditor.php:262 msgid "Output and input" msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowEditor.php:262 +#: src/Modules/Workflows/Controllers/WorkflowEditor.php:263 msgid "Linked steps can pass data forward as input to the next step." msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowEditor.php:266 +#: src/Modules/Workflows/Controllers/WorkflowEditor.php:267 msgid "Customize the workflow" msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowEditor.php:267 +#: src/Modules/Workflows/Controllers/WorkflowEditor.php:268 msgid "Click on a step to customize it. You can change the step's settings in the right sidebar." msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowEditor.php:271 +#: src/Modules/Workflows/Controllers/WorkflowEditor.php:272 msgid "Workflow validation" msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowEditor.php:272 +#: src/Modules/Workflows/Controllers/WorkflowEditor.php:273 msgid "Error messages will appear for any unfilled required settings, missed connections, or invalid values. Select the step to view the corresponding error in the sidebar." msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowEditor.php:276 +#: src/Modules/Workflows/Controllers/WorkflowEditor.php:277 msgid "Publish your workflow" msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowEditor.php:277 +#: src/Modules/Workflows/Controllers/WorkflowEditor.php:278 msgid "When you're ready, click the publish button to make your workflow live." msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowEditor.php:281 +#: src/Modules/Workflows/Controllers/WorkflowEditor.php:282 msgid "Need help?" msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowEditor.php:282 +#: src/Modules/Workflows/Controllers/WorkflowEditor.php:283 msgid "If you have any questions or need help, click the help button in the top right corner to access the support resources." msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowsList.php:175 +#: src/Modules/Workflows/Controllers/WorkflowsList.php:185 msgid "Triggers" msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowsList.php:179 +#: src/Modules/Workflows/Controllers/WorkflowsList.php:191 msgid "Preview" msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowsList.php:205 +#: src/Modules/Workflows/Controllers/WorkflowsList.php:218 msgid "—" msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowsList.php:242 +#: src/Modules/Workflows/Controllers/WorkflowsList.php:255 msgid "No screenshot" msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowsList.php:327 -#: src/Modules/Workflows/Controllers/WorkflowsList.php:328 +#: src/Modules/Workflows/Controllers/WorkflowsList.php:340 +#: src/Modules/Workflows/Controllers/WorkflowsList.php:341 msgid "Activate" msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowsList.php:333 -#: src/Modules/Workflows/Controllers/WorkflowsList.php:334 +#: src/Modules/Workflows/Controllers/WorkflowsList.php:346 +#: src/Modules/Workflows/Controllers/WorkflowsList.php:347 msgid "Deactivate" msgstr "" -#: src/Modules/Workflows/Controllers/WorkflowsList.php:412 +#: src/Modules/Workflows/Controllers/WorkflowsList.php:425 msgid "Action Workflow Editor" msgstr "" @@ -1309,9 +1324,9 @@ msgstr "" #: src/Modules/Workflows/Domain/NodeTypes/Actions/CorePostTermsRemove.php:132 #: src/Modules/Workflows/Domain/NodeTypes/Actions/CorePostTermsSet.php:128 #: src/Modules/Workflows/Domain/NodeTypes/Actions/CorePostUnstick.php:116 -#: src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php:150 +#: src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php:153 #: src/Modules/Workflows/Domain/NodeTypes/Advanced/ConditionalSplit.php:103 -#: src/Modules/Workflows/Domain/NodeTypes/Advanced/CorePostQuery.php:133 +#: src/Modules/Workflows/Domain/NodeTypes/Advanced/CorePostQuery.php:136 #: src/Modules/Workflows/Domain/NodeTypes/Advanced/CoreSchedule.php:102 #: src/Modules/Workflows/Domain/NodeTypes/Advanced/LogAdd.php:101 #: src/Modules/Workflows/Domain/NodeTypes/Advanced/RayDebug.php:106 @@ -1326,9 +1341,9 @@ msgstr "" #: src/Modules/Workflows/Domain/NodeTypes/Actions/CorePostTermsRemove.php:133 #: src/Modules/Workflows/Domain/NodeTypes/Actions/CorePostTermsSet.php:129 #: src/Modules/Workflows/Domain/NodeTypes/Actions/CorePostUnstick.php:117 -#: src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php:151 +#: src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php:154 #: src/Modules/Workflows/Domain/NodeTypes/Advanced/ConditionalSplit.php:104 -#: src/Modules/Workflows/Domain/NodeTypes/Advanced/CorePostQuery.php:134 +#: src/Modules/Workflows/Domain/NodeTypes/Advanced/CorePostQuery.php:137 #: src/Modules/Workflows/Domain/NodeTypes/Advanced/CoreSchedule.php:103 #: src/Modules/Workflows/Domain/NodeTypes/Advanced/LogAdd.php:102 #: src/Modules/Workflows/Domain/NodeTypes/Advanced/RayDebug.php:107 @@ -1343,8 +1358,8 @@ msgstr "" #: src/Modules/Workflows/Domain/NodeTypes/Actions/CorePostTermsRemove.php:156 #: src/Modules/Workflows/Domain/NodeTypes/Actions/CorePostTermsSet.php:152 #: src/Modules/Workflows/Domain/NodeTypes/Actions/CorePostUnstick.php:140 -#: src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php:174 -#: src/Modules/Workflows/Domain/NodeTypes/Advanced/CorePostQuery.php:157 +#: src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php:177 +#: src/Modules/Workflows/Domain/NodeTypes/Advanced/CorePostQuery.php:160 #: src/Modules/Workflows/Domain/NodeTypes/Advanced/CoreSchedule.php:126 #: src/Modules/Workflows/Domain/NodeTypes/Advanced/LogAdd.php:125 #: src/Modules/Workflows/Domain/NodeTypes/Advanced/RayDebug.php:130 @@ -1352,8 +1367,8 @@ msgstr "" #: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnCronSchedule.php:116 #: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnInit.php:97 #: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnManuallyEnabledForPost.php:164 -#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnPostUpdated.php:153 -#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnSavePost.php:150 +#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnPostUpdated.php:154 +#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnSavePost.php:151 #: src/Modules/Workflows/Domain/NodeTypes/Triggers/FutureLegacyAction.php:128 msgid "Next" msgstr "" @@ -1492,16 +1507,16 @@ msgstr "" msgid "Recipient" msgstr "" -#: src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php:88 +#: src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php:91 msgid "Subject" msgstr "" -#: src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php:121 +#: src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php:124 msgid "Email Recipient" msgstr "" -#: src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php:126 -#: src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php:135 +#: src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php:129 +#: src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php:138 msgid "Custom Email Address" msgstr "" @@ -1557,25 +1572,25 @@ msgstr "" msgid "The query defines the posts that will be retrieved by this action." msgstr "" -#: src/Modules/Workflows/Domain/NodeTypes/Advanced/CorePostQuery.php:107 +#: src/Modules/Workflows/Domain/NodeTypes/Advanced/CorePostQuery.php:110 #: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnManuallyEnabledForPost.php:119 -#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnPostUpdated.php:102 -#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnSavePost.php:105 +#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnPostUpdated.php:103 +#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnSavePost.php:106 msgid "Post Type" msgstr "" -#: src/Modules/Workflows/Domain/NodeTypes/Advanced/CorePostQuery.php:113 +#: src/Modules/Workflows/Domain/NodeTypes/Advanced/CorePostQuery.php:116 #: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnManuallyEnabledForPost.php:125 -#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnPostUpdated.php:108 -#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnSavePost.php:111 +#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnPostUpdated.php:109 +#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnSavePost.php:112 msgid "Post ID" msgstr "" -#: src/Modules/Workflows/Domain/NodeTypes/Advanced/CorePostQuery.php:127 +#: src/Modules/Workflows/Domain/NodeTypes/Advanced/CorePostQuery.php:130 msgid "Array of queried post IDs" msgstr "" -#: src/Modules/Workflows/Domain/NodeTypes/Advanced/CorePostQuery.php:128 +#: src/Modules/Workflows/Domain/NodeTypes/Advanced/CorePostQuery.php:131 msgid "The posts found following the criteria of the query." msgstr "" @@ -1704,13 +1719,13 @@ msgid "The query defines the posts that will trigger this action." msgstr "" #: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnManuallyEnabledForPost.php:145 -#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnSavePost.php:131 +#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnSavePost.php:132 msgid "Saved post" msgstr "" #: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnManuallyEnabledForPost.php:146 -#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnPostUpdated.php:135 -#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnSavePost.php:132 +#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnPostUpdated.php:136 +#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnSavePost.php:133 msgid "The post that was saved, with the new properties." msgstr "" @@ -1722,15 +1737,15 @@ msgstr "" msgid "This trigger activates when an existing post is updated." msgstr "" -#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnPostUpdated.php:128 +#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnPostUpdated.php:129 msgid "Post Before Update" msgstr "" -#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnPostUpdated.php:129 +#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnPostUpdated.php:130 msgid "The post that was saved, with the old properties." msgstr "" -#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnPostUpdated.php:134 +#: src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnPostUpdated.php:135 msgid "Post After Update" msgstr "" @@ -1771,7 +1786,7 @@ msgid "Asynchronous" msgstr "" #: src/Modules/Workflows/Models/NodeTypesModel.php:117 -#: src/Views/tabs.php:48 +#: src/Views/tabs.php:53 msgid "Debug" msgstr "" @@ -1783,23 +1798,23 @@ msgstr "" msgid "Messages" msgstr "" -#: src/Modules/Workflows/Rest/RestApiV1.php:38 -#: src/Modules/Workflows/Rest/RestApiV1.php:71 -#: src/Modules/Workflows/Rest/RestApiV1.php:91 +#: src/Modules/Workflows/Rest/RestApiV1.php:48 +#: src/Modules/Workflows/Rest/RestApiV1.php:81 +#: src/Modules/Workflows/Rest/RestApiV1.php:101 msgid "The ID of the workflow" msgstr "" -#: src/Modules/Workflows/Rest/RestApiV1.php:111 +#: src/Modules/Workflows/Rest/RestApiV1.php:121 msgid "The taxonomy name" msgstr "" -#: src/Modules/Workflows/Rest/RestApiV1.php:131 +#: src/Modules/Workflows/Rest/RestApiV1.php:141 msgid "The post ID" msgstr "" -#: src/Modules/Workflows/Rest/RestApiV1.php:167 -#: src/Modules/Workflows/Rest/RestApiV1.php:193 -#: src/Modules/Workflows/Rest/RestApiV1.php:258 +#: src/Modules/Workflows/Rest/RestApiV1.php:177 +#: src/Modules/Workflows/Rest/RestApiV1.php:203 +#: src/Modules/Workflows/Rest/RestApiV1.php:268 msgid "Workflow not found" msgstr "" @@ -1925,8 +1940,9 @@ msgid "Toggle between preserving or deleting data after the plugin is deactivate msgstr "" #: src/Views/menu-advanced.php:135 -#: src/Views/menu-display.php:268 -#: src/Views/menu-general.php:241 +#: src/Views/menu-display.php:410 +#: src/Views/menu-general.php:163 +#: src/Views/menu-notifications.php:122 msgid "Save Changes" msgstr "" @@ -2000,9 +2016,9 @@ msgid "Debug Logging" msgstr "" #: src/Views/menu-diagnostics.php:110 -#: src/Views/menu-display.php:178 -#: src/Views/menu-general.php:174 -#: src/Views/menu-general.php:202 +#: src/Views/menu-display.php:275 +#: src/Views/menu-notifications.php:55 +#: src/Views/menu-notifications.php:83 msgid "Enabled" msgstr "" @@ -2019,9 +2035,9 @@ msgid "View Debug Logs" msgstr "" #: src/Views/menu-diagnostics.php:130 -#: src/Views/menu-display.php:184 -#: src/Views/menu-general.php:182 -#: src/Views/menu-general.php:211 +#: src/Views/menu-display.php:286 +#: src/Views/menu-notifications.php:63 +#: src/Views/menu-notifications.php:92 msgid "Disabled" msgstr "" @@ -2073,191 +2089,231 @@ msgstr "" msgid "This is a legacy feature and will be removed in a future version." msgstr "" -#: src/Views/menu-display.php:38 +#: src/Views/menu-display.php:44 msgid "Default Formats" msgstr "" -#: src/Views/menu-display.php:42 +#: src/Views/menu-display.php:49 msgid "Date Format" msgstr "" #. translators: %s is a link to the PHP date function documentation -#: src/Views/menu-display.php:50 +#: src/Views/menu-display.php:67 msgid "The default format to use when displaying the action date within a post using the shortcode or within the footer. For information on valid formatting options, see: %s." msgstr "" -#: src/Views/menu-display.php:54 -#: src/Views/menu-display.php:72 +#: src/Views/menu-display.php:71 +#: src/Views/menu-display.php:102 msgid "PHP Date Function" msgstr "" -#: src/Views/menu-display.php:60 +#: src/Views/menu-display.php:80 msgid "Time Format" msgstr "" #. translators: %s is a link to the PHP date function documentation -#: src/Views/menu-display.php:68 +#: src/Views/menu-display.php:98 msgid "The default format to use when displaying the action time within a post using the shortcode or within the footer. For information on valid formatting options, see: %s." msgstr "" -#: src/Views/menu-display.php:80 -msgid "Future actions column" +#: src/Views/menu-display.php:112 +msgid "Metabox" +msgstr "" + +#: src/Views/menu-display.php:119 +msgid "Metabox Title" +msgstr "" + +#: src/Views/menu-display.php:133 +msgid "The title of the metabox that will be displayed in the post edit screen." +msgstr "" + +#: src/Views/menu-display.php:142 +msgid "Checkbox Field Label" +msgstr "" + +#: src/Views/menu-display.php:155 +msgid "The label of the checkbox field that will be displayed in the metabox." +msgstr "" + +#: src/Views/menu-display.php:163 +msgid "Future Actions Column" msgstr "" -#: src/Views/menu-display.php:84 +#: src/Views/menu-display.php:168 msgid "Future Action Column Style" msgstr "" -#: src/Views/menu-display.php:95 +#: src/Views/menu-display.php:178 msgid "Detailed" msgstr "" -#: src/Views/menu-display.php:97 +#: src/Views/menu-display.php:181 msgid "Displays all information in the Future Action column." msgstr "" -#: src/Views/menu-display.php:109 +#: src/Views/menu-display.php:191 msgid "Simplified" msgstr "" -#: src/Views/menu-display.php:111 +#: src/Views/menu-display.php:193 msgid "Displays only the icon and date/time." msgstr "" -#: src/Views/menu-display.php:123 -msgid "Future actions editor" +#: src/Views/menu-display.php:203 +msgid "Future Actions Editor" msgstr "" -#: src/Views/menu-display.php:127 +#: src/Views/menu-display.php:208 msgid "Time format in the date picker" msgstr "" -#: src/Views/menu-display.php:138 +#: src/Views/menu-display.php:220 msgid "Inherit from Site Settings" msgstr "" -#: src/Views/menu-display.php:146 +#: src/Views/menu-display.php:231 msgid "24 hours" msgstr "" -#: src/Views/menu-display.php:154 +#: src/Views/menu-display.php:242 msgid "AM/PM" msgstr "" -#: src/Views/menu-display.php:163 +#: src/Views/menu-display.php:252 msgid "Post Footer Display" msgstr "" -#: src/Views/menu-display.php:165 +#: src/Views/menu-display.php:254 msgid "Enabling this below will display the action date automatically at the end of any post which is set to run an action." msgstr "" -#: src/Views/menu-display.php:172 +#: src/Views/menu-display.php:263 msgid "Show in Post Footer?" msgstr "" -#: src/Views/menu-display.php:187 +#: src/Views/menu-display.php:290 msgid "This will enable or disable displaying the future action date in the post footer." msgstr "" -#: src/Views/menu-display.php:195 +#: src/Views/menu-display.php:300 msgid "Footer Contents" msgstr "" -#: src/Views/menu-display.php:200 +#: src/Views/menu-display.php:311 msgid "Enter the text you would like to appear at the bottom of every post which has an action scheduled. The following placeholders will be replaced with the future action date in the following format:" msgstr "" -#: src/Views/menu-display.php:218 +#: src/Views/menu-display.php:343 msgid "Footer Style" msgstr "" -#: src/Views/menu-display.php:223 +#: src/Views/menu-display.php:354 msgid "The inline css which will be used to style the footer text." msgstr "" -#: src/Views/menu-display.php:226 +#: src/Views/menu-display.php:358 msgid "Example: " msgstr "" -#: src/Views/menu-display.php:237 +#: src/Views/menu-display.php:370 msgid "Shortcode" msgstr "" #. translators: %s is the shortcode code wrapped in code tags -#: src/Views/menu-display.php:240 +#: src/Views/menu-display.php:373 msgid "Valid %s attributes:" msgstr "" #. translators: %1$s and %2$s are code tags that wrap the shortcode attribute names -#: src/Views/menu-display.php:245 +#: src/Views/menu-display.php:379 msgid "%1$stype%2$s - valid options are %1$sfull%2$s (default), %1$sdate%2$s, %1$stime%2$s" msgstr "" #. translators: %s is a code tag that wraps the shortcode attribute dateformat #. translators: %s is a code tag that wraps the shortcode attribute timeformat -#: src/Views/menu-display.php:255 -#: src/Views/menu-display.php:261 +#: src/Views/menu-display.php:391 +#: src/Views/menu-display.php:399 msgid "%s - format set here will override the value set on the settings page" msgstr "" -#: src/Views/menu-general.php:64 +#: src/Views/menu-general.php:35 msgid "Defaults" msgstr "" -#: src/Views/menu-general.php:94 +#: src/Views/menu-general.php:65 msgid "Calendar Visibility" msgstr "" -#: src/Views/menu-general.php:100 +#: src/Views/menu-general.php:71 msgid "Remember last state" msgstr "" -#: src/Views/menu-general.php:102 +#: src/Views/menu-general.php:73 msgid "Shows or hides the calendar based on the last user interaction." msgstr "" -#: src/Views/menu-general.php:107 +#: src/Views/menu-general.php:78 msgid "Always hidden" msgstr "" -#: src/Views/menu-general.php:109 +#: src/Views/menu-general.php:80 msgid "The calendar is always hidden by default." msgstr "" +#: src/Views/menu-general.php:87 +msgid "Workflow Screenshot" +msgstr "" + +#: src/Views/menu-general.php:99 +msgid "Enable and take screenshots" +msgstr "" + +#: src/Views/menu-general.php:102 +msgid "Enable the feature and take a screenshot of the workflow when saving." +msgstr "" + +#: src/Views/menu-general.php:112 +msgid "Disable and do not take screenshots" +msgstr "" + #: src/Views/menu-general.php:115 +msgid "Disable the feature and do not take screenshots when saving workflows." +msgstr "" + +#: src/Views/menu-general.php:121 msgid "Permissions" msgstr "" -#: src/Views/menu-general.php:120 +#: src/Views/menu-general.php:126 msgid "Choose Which User Roles Can Use PublishPress Future" msgstr "" -#: src/Views/menu-general.php:157 +#: src/Views/menu-notifications.php:38 msgid "Email Notification" msgstr "" -#: src/Views/menu-general.php:159 +#: src/Views/menu-notifications.php:40 msgid "Whenever an action runs, an email can be sent to alert users." msgstr "" -#: src/Views/menu-general.php:166 +#: src/Views/menu-notifications.php:47 msgid "Enable Email Notification?" msgstr "" -#: src/Views/menu-general.php:185 +#: src/Views/menu-notifications.php:66 msgid "This will enable or disable the send of email notification on future action." msgstr "" -#: src/Views/menu-general.php:193 +#: src/Views/menu-notifications.php:74 msgid "Include Blog Administrators?" msgstr "" -#: src/Views/menu-general.php:214 +#: src/Views/menu-notifications.php:95 msgid "This will include all users with the role of \"Administrator\" in the email." msgstr "" -#: src/Views/menu-general.php:230 +#: src/Views/menu-notifications.php:111 msgid "Enter a comma separate list of emails that you would like to be notified when the action runs. This will be applied to ALL post types. You can set post type specific emails on the Defaults tab." msgstr "" @@ -2270,13 +2326,17 @@ msgid "General" msgstr "" #: src/Views/tabs.php:30 -msgid "Display" +msgid "Notifications" msgstr "" #: src/Views/tabs.php:35 -msgid "Advanced" +msgid "Display" msgstr "" #: src/Views/tabs.php:40 +msgid "Advanced" +msgstr "" + +#: src/Views/tabs.php:45 msgid "Diagnostics and Tools" msgstr "" diff --git a/legacy/classes/Display.class.php b/legacy/classes/Display.class.php index 536b24171..901bdefc9 100644 --- a/legacy/classes/Display.class.php +++ b/legacy/classes/Display.class.php @@ -5,10 +5,10 @@ use PublishPress\Future\Modules\Expirator\CapabilitiesAbstract; use PublishPress\Future\Modules\Expirator\Migrations\V30000WPCronToActionsScheduler; use PublishPress\Future\Modules\Expirator\Migrations\V30001RestorePostMeta; -use PublishPress\Future\Modules\Expirator\Schemas\ActionArgsSchema; use PublishPress\Future\Modules\Settings\HooksAbstract as SettingsHooksAbstract; use PublishPress\Future\Modules\Expirator\HooksAbstract as ExpiratorHooksAbstract; use PublishPress\Future\Framework\Database\Interfaces\DBTableSchemaInterface; +use PublishPress\Future\Modules\Settings\SettingsFacade; defined('ABSPATH') or die('Direct access not allowed.'); @@ -42,6 +42,11 @@ class PostExpirator_Display */ private $debugLogSchema; + /** + * @var SettingsFacade + */ + private $settingsFacade; + /** * Constructor. */ @@ -53,6 +58,7 @@ private function __construct() $this->hooks = $container->get(ServicesAbstract::HOOKS); $this->actionArgsSchema = $container->get(ServicesAbstract::DB_TABLE_ACTION_ARGS_SCHEMA); $this->debugLogSchema = $container->get(ServicesAbstract::DB_TABLE_DEBUG_LOG_SCHEMA); + $this->settingsFacade = $container->get(ServicesAbstract::SETTINGS); $this->hooks(); } @@ -109,7 +115,7 @@ public function settings_tabs() // phpcs:ignore WordPress.Security.NonceVerification.Recommended $tab = isset($_GET['tab']) ? sanitize_key($_GET['tab']) : ''; - $allowed_tabs = ['defaults', 'general', 'display', 'advanced', 'diagnostics', 'viewdebug', ]; + $allowed_tabs = ['defaults', 'general', 'display', 'advanced', 'diagnostics', 'viewdebug', 'notifications', ]; $allowed_tabs = $this->hooks->applyFilters(SettingsHooksAbstract::FILTER_ALLOWED_TABS, $allowed_tabs); $debugIsEnabled = (bool)$this->hooks->applyFilters(SettingsHooksAbstract::FILTER_DEBUG_ENABLED, false); @@ -163,13 +169,15 @@ private function menu_display() exit; } else { // phpcs:disable WordPress.Security.ValidatedSanitizedInput.InputNotSanitized, WordPress.Security.ValidatedSanitizedInput.InputNotValidated - update_option('expirationdateDefaultDateFormat', sanitize_text_field($_POST['expired-default-date-format'])); - update_option('expirationdateDefaultTimeFormat', sanitize_text_field($_POST['expired-default-time-format'])); - update_option('expirationdateDisplayFooter', (int)$_POST['expired-display-footer']); - update_option('expirationdateFooterContents', wp_kses($_POST['expired-footer-contents'], [])); - update_option('expirationdateFooterStyle', wp_kses($_POST['expired-footer-style'], [])); - update_option('expirationdateColumnStyle', sanitize_key($_POST['future-action-column-style'])); - update_option('expirationdateTimeFormatForDatePicker', sanitize_key($_POST['future-action-time-format'])); + $this->settingsFacade->setDefaultDateFormat(sanitize_text_field($_POST['expired-default-date-format'])); + $this->settingsFacade->setDefaultTimeFormat(sanitize_text_field($_POST['expired-default-time-format'])); + $this->settingsFacade->setShowInPostFooter((bool)$_POST['expired-display-footer']); + $this->settingsFacade->setFooterContents(wp_kses($_POST['expired-footer-contents'], [])); + $this->settingsFacade->setFooterStyle(wp_kses($_POST['expired-footer-style'], [])); + $this->settingsFacade->setColumnStyle(sanitize_key($_POST['future-action-column-style'])); + $this->settingsFacade->setTimeFormatForDatePicker(sanitize_key($_POST['future-action-time-format'])); + $this->settingsFacade->setMetaboxTitle(sanitize_text_field($_POST['expirationdate-metabox-title'])); + $this->settingsFacade->setMetaboxCheckboxLabel(sanitize_text_field($_POST['expirationdate-metabox-checkbox-label'])); // phpcs:enable } } @@ -304,46 +312,23 @@ private function menu_general() exit; } else { // phpcs:disable WordPress.Security.ValidatedSanitizedInput.InputNotValidated - update_option('expirationdateEmailNotification', sanitize_text_field($_POST['expired-email-notification'])); - update_option('expirationdateEmailNotificationAdmins', sanitize_text_field($_POST['expired-email-notification-admins'])); - update_option('expirationdateEmailNotificationList', trim(sanitize_text_field($_POST['expired-email-notification-list']))); - update_option( - 'expirationdateCategoryDefaults', - // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized - isset($_POST['expirationdate_category']) ? PostExpirator_Util::sanitize_array_of_integers($_POST['expirationdate_category']) : [] + $this->settingsFacade->setGeneralDateTimeOffset( + sanitize_text_field($_POST['expired-custom-expiration-date']) ); - update_option('expirationdateDefaultDate', 'custom'); - - $customExpirationDate = sanitize_text_field($_POST['expired-custom-expiration-date']); - $customExpirationDate = html_entity_decode($customExpirationDate, ENT_QUOTES); - $customExpirationDate = preg_replace('/["\'`]/', '', $customExpirationDate); - update_option('expirationdateDefaultDateCustom', trim($customExpirationDate)); - - $hideCalendarByDefault = isset($_POST['expired-hide-calendar-by-default']) && $_POST['expired-hide-calendar-by-default'] == '1' ? 1 : 0; - update_option('expirationdateHideCalendarByDefault', $hideCalendarByDefault); + $this->settingsFacade->setHideCalendarByDefault( + isset($_POST['expired-hide-calendar-by-default']) && $_POST['expired-hide-calendar-by-default'] == '1' + ); // phpcs:enable if (! isset($_POST['allow-user-roles']) || ! is_array($_POST['allow-user-roles'])) { - $_POST['allow-user-roles'] = array(); + $_POST['allow-user-roles'] = []; } - $user_roles = wp_roles()->get_names(); - - foreach ($user_roles as $role_name => $role_label) { - $role = get_role($role_name); - - if (! is_a($role, WP_Role::class)) { - continue; - } - - // TODO: only allow roles that can edit posts. Filter in the form as well, adding a description. - if ($role_name === 'administrator' || in_array($role_name, $_POST['allow-user-roles'], true)) { - $role->add_cap(CapabilitiesAbstract::EXPIRE_POST); - } else { - $role->remove_cap(CapabilitiesAbstract::EXPIRE_POST); - } - } + $this->settingsFacade->setAllowUserRoles($_POST['allow-user-roles']); + $this->settingsFacade->setWorkflowScreenshotStatus( + isset($_POST['workflow-screenshot']) && $_POST['workflow-screenshot'] == '1' + ); echo "

"; esc_html_e('Saved Options!', 'post-expirator'); @@ -361,6 +346,42 @@ private function menu_general() $this->render_template('menu-general', $params); } + private function menu_notifications() + { + if (isset($_POST['expirationNotificationSave']) && ! empty($_POST['expirationNotificationSave'])) { + if ( + ! isset($_POST['_postExpiratorMenuNotifications_nonce']) || ! wp_verify_nonce( + sanitize_key($_POST['_postExpiratorMenuNotifications_nonce']), + 'postexpirator_menu_notifications' + ) + ) { + print 'Form Validation Failure: Sorry, your nonce did not verify.'; + exit; + } + + $emailList = explode(',', trim(sanitize_text_field($_POST['expired-email-notification-list']))); + + // phpcs:disable WordPress.Security.ValidatedSanitizedInput.InputNotValidated + $this->settingsFacade->setSendEmailNotification((bool)$_POST['expired-email-notification']); + $this->settingsFacade->setSendEmailNotificationToAdmins((bool)$_POST['expired-email-notification-admins']); + $this->settingsFacade->setEmailNotificationAddressesList($emailList); + // phpcs:enable + + echo "

"; + esc_html_e('Saved Options!', 'post-expirator'); + echo '

'; + } + + $params = [ + 'showSideBar' => $this->hooks->applyFilters( + SettingsHooksAbstract::FILTER_SHOW_PRO_BANNER, + ! defined('PUBLISHPRESS_FUTURE_LOADED_BY_PRO') + ), + ]; + + $this->render_template('menu-notifications', $params); + } + /** * Show the Expiration Date options page */ diff --git a/lib/composer.lock b/lib/composer.lock index 81099a024..4cdf5f94c 100644 --- a/lib/composer.lock +++ b/lib/composer.lock @@ -79,36 +79,36 @@ }, "type": "library", "extra": { - "generator": { - "lib-class-test": "class_exists('PublishPress\\Pimple\\Container')", - "action-initialize-priority": "-185", - "action-register-priority": "-200" - }, "strauss": { - "target_directory": "lib", - "namespace_prefix": "PublishPress\\", - "classmap_prefix": "PublishPress_", - "constant_prefix": "PUBLISHPRESS_", - "include_author": "true", - "classmap_output": "true", "packages": [ "pimple/pimple", "psr/container" ], - "override_autoload": [], + "include_author": "true", + "classmap_output": "true", + "classmap_prefix": "PublishPress_", + "constant_prefix": "PUBLISHPRESS_", + "namespace_prefix": "PublishPress\\", + "target_directory": "lib", "exclude_from_copy": { "packages": [], "namespaces": [], "file_patterns": [] }, + "override_autoload": [], + "delete_vendor_files": true, "exclude_from_prefix": { "packages": [], "namespaces": [], "file_patterns": [] }, - "namespace_replacement_patterns": [], "delete_vendor_packages": true, - "delete_vendor_files": true + "namespace_replacement_patterns": [] + }, + "generator": { + "lib-class-test": "class_exists('PublishPress\\Pimple\\Container')", + "action-register-priority": "-200", + "action-initialize-priority": "-185" } }, "autoload": { @@ -176,35 +176,35 @@ }, "type": "library", "extra": { - "generator": { - "lib-class-test": "interface_exists('PublishPress\\Psr\\Container\\ContainerInterface')", - "action-initialize-priority": "-190", - "action-register-priority": "-200" - }, "strauss": { - "target_directory": "lib", - "namespace_prefix": "PublishPress\\", - "classmap_prefix": "PublishPress_", - "constant_prefix": "PUBLISHPRESS_", - "include_author": "true", - "classmap_output": "true", "packages": [ "psr/container" ], - "override_autoload": [], + "include_author": "true", + "classmap_output": "true", + "classmap_prefix": "PublishPress_", + "constant_prefix": "PUBLISHPRESS_", + "namespace_prefix": "PublishPress\\", + "target_directory": "lib", "exclude_from_copy": { "packages": [], "namespaces": [], "file_patterns": [] }, + "override_autoload": [], + "delete_vendor_files": true, "exclude_from_prefix": { "packages": [], "namespaces": [], "file_patterns": [] }, - "namespace_replacement_patterns": [], "delete_vendor_packages": true, - "delete_vendor_files": true + "namespace_replacement_patterns": [] + }, + "generator": { + "lib-class-test": "interface_exists('PublishPress\\Psr\\Container\\ContainerInterface')", + "action-register-priority": "-200", + "action-initialize-priority": "-190" } }, "autoload": { diff --git a/lib/vendor/composer/installed.php b/lib/vendor/composer/installed.php index 664357b6c..7796b56f9 100644 --- a/lib/vendor/composer/installed.php +++ b/lib/vendor/composer/installed.php @@ -3,7 +3,7 @@ 'name' => '__root__', 'pretty_version' => 'dev-develop', 'version' => 'dev-develop', - 'reference' => 'e5b0408d1ac208ccb32b81c26e3dd8ebdfb85730', + 'reference' => '0c9ac73171f587d86eb9bf28707cdb66eb161301', 'type' => 'library', 'install_path' => __DIR__ . '/../../', 'aliases' => array(), @@ -13,7 +13,7 @@ '__root__' => array( 'pretty_version' => 'dev-develop', 'version' => 'dev-develop', - 'reference' => 'e5b0408d1ac208ccb32b81c26e3dd8ebdfb85730', + 'reference' => '0c9ac73171f587d86eb9bf28707cdb66eb161301', 'type' => 'library', 'install_path' => __DIR__ . '/../../', 'aliases' => array(), diff --git a/package.json b/package.json index 0e2a7d069..32f17c95c 100644 --- a/package.json +++ b/package.json @@ -40,7 +40,8 @@ "reactflow": "^11.10.4", "uuid": "^9.0.0", "validator": "^13.12.0", - "web-worker": "^1.3.0" + "web-worker": "^1.3.0", + "node-fetch": "^2.7.0" }, "devDependencies": { "@babel/core": "^7.24.3", @@ -70,7 +71,10 @@ "webpack": "^5.90.0", "webpack-bundle-analyzer": "^4.10.2", "webpack-cli": "^5.1.4", - "ws": "^8.17.1" + "ws": "^8.17.1", + "cross-spawn": "^7.0.5", + "micromatch": "^4.0.8", + "cookie": "^0.7.0" }, "peerDependencies": { "react": "^17.0.2", diff --git a/post-expirator.php b/post-expirator.php index 3f724947b..799a9496f 100644 --- a/post-expirator.php +++ b/post-expirator.php @@ -5,7 +5,7 @@ * Plugin URI: http://wordpress.org/extend/plugins/post-expirator/ * Description: PublishPress Future allows you to schedule automatic changes to posts, pages and other content types. * Author: PublishPress - * Version: 4.1.3 + * Version: 4.2.0 * Author URI: http://publishpress.com * Text Domain: post-expirator * Domain Path: /languages @@ -51,7 +51,7 @@ } if (! defined('PUBLISHPRESS_FUTURE_VERSION')) { - define('PUBLISHPRESS_FUTURE_VERSION', '4.1.3'); + define('PUBLISHPRESS_FUTURE_VERSION', '4.2.0'); } if (! defined('PUBLISHPRESS_FUTURE_PLUGIN_FILE')) { diff --git a/readme.txt b/readme.txt index 1feeaa086..8a3d3a3bc 100644 --- a/readme.txt +++ b/readme.txt @@ -7,7 +7,7 @@ Requires at least: 6.7 Requires PHP: 7.4 Tested up to: 6.7 License: GPLv2 or later -Stable tag: 4.1.3 +Stable tag: 4.2.0 PublishPress Future can make scheduled changes to your content. You can unpublish posts, move posts to a new status, update the categories, and more. @@ -173,6 +173,41 @@ Yes, the PublishPress Future plugin allows you to schedule automatic changes to The full changelog can be found on [GitHub](https://github.com/publishpress/PublishPress-Future/blob/main/CHANGELOG.md). +## [4.2.0] - 09 Dec, 2024 + +### Added + +- Add new admin page to export and import workflows and plugin settings (Issue #704). +- Add global variable `global.execution_id` to the workflow engine to identify the current execution of the workflow. +- Add setting fields to customize the metabox title and checkbox label (Issue #227). +- Add method `disableExpiration` to the class `PublishPress\Future\Modules\Expirator\Models\ExpirablePostModel`. +- Add `*` to indicate required fields in the workflow editor (Issue #974). +- Add new setting to disable/enable the screenshot feature in the workflow editor (Issue #1066). +- Add new Custom Data option to "Ray - Debug step" to debug custom expressions on workflows (Issue #1067). +- Add support to metadata when evaluating expressions in a workflow. Post, site, user and workflow (post) metadata are now available when evaluating expressions (Issue #1069). +- Add support to custom email addresses using the post metadata when sending emails in a workflow (Issue #939). + +### Changed + +- Move notification settings to a specific tab (Issue #190). +- Disable the workflow screenshot feature by default (Issue #1066). +- Changed the Message field in the "Log - Add" step displaying a textarea instead of a text field (Issue #1068). +- Changed the Custom Email Addresses field in the Send Email step to be a textarea (Issue #939). +- Changed the Subject field in the Send Email step to be a textarea (Issue #939). +- Set the default value of Email Recipient on Send Email step to Site Admin (Issue #1071). + +### Fixed + +- Do not remove expiration post meta when clearing the scheduled action (Issue #1053). +- Fix DB error when deleting orphan scheduled steps (Issue #1060). +- Potential fix for DOM text reinterpretation as HTML issue. +- Fix error when a trigger node type is not found. +- Fix warning PHP Deprecated: ltrim(): Passing null to parameter #1 ($string) of type string on the Scheduled Actions table. +- Fix error on table ScheduledActionsTable refactoring calls to `next` instead of `get_date`. +- Fix displaced labels for checkboxes in the Future Actions metabox and manual workflow activation checkbox (Issue #1057). +- Fix translations for user roles in the plugin settings page (Issue #1050). +- Fix error on Post Status filter in the Post Updated trigger (Issue #1074). + ## [4.1.3] - 22 Nov, 2024 ### Added diff --git a/services.php b/services.php index 1b5390c19..03b59213c 100644 --- a/services.php +++ b/services.php @@ -53,6 +53,7 @@ use PublishPress\Future\Modules\Expirator\Models\ExpirationActionsModel; use PublishPress\Future\Modules\Expirator\Models\PostTypeDefaultDataModelFactory; use PublishPress\Future\Modules\Expirator\Module as ModuleExpirator; +use PublishPress\Future\Modules\Backup\Module as ModuleBackup; use PublishPress\Future\Modules\Expirator\Tables\ScheduledActionsTable; use PublishPress\Future\Modules\InstanceProtection\Module as ModuleInstanceProtection; use PublishPress\Future\Modules\Settings\Models\SettingsPostTypesModel; @@ -145,6 +146,7 @@ ServicesAbstract::MODULE_SETTINGS, ServicesAbstract::MODULE_WOOCOMMERCE, ServicesAbstract::MODULE_WORKFLOWS, + ServicesAbstract::MODULE_BACKUP, ]; $modules = []; @@ -395,6 +397,18 @@ ); }, + /** + * @return ModuleInterface + */ + ServicesAbstract::MODULE_BACKUP => static function (ContainerInterface $container) { + return new ModuleBackup( + $container->get(ServicesAbstract::HOOKS), + $container->get(ServicesAbstract::PLUGIN_VERSION), + $container->get(ServicesAbstract::SETTINGS), + $container->get(ServicesAbstract::LOGGER) + ); + }, + /** * @return ModuleInterface */ @@ -702,7 +716,9 @@ }, ServicesAbstract::WORKFLOWS_REST_API_MANAGER => static function (ContainerInterface $container) { - return new RestApiManager(); + return new RestApiManager( + $container->get(ServicesAbstract::SETTINGS) + ); }, ServicesAbstract::NODE_TYPES_MODEL => static function (ContainerInterface $container) { diff --git a/src/Core/DI/ServicesAbstract.php b/src/Core/DI/ServicesAbstract.php index 29c29f8e1..35229fae5 100644 --- a/src/Core/DI/ServicesAbstract.php +++ b/src/Core/DI/ServicesAbstract.php @@ -94,6 +94,8 @@ abstract class ServicesAbstract public const MODULE_WORKFLOWS = 'future.free/module-workflows'; + public const MODULE_BACKUP = 'future.free/module-backup'; + public const POST_MODEL_FACTORY = 'future.free/post-model-factory'; public const TERM_MODEL_FACTORY = 'future.free/term-model-factory'; diff --git a/src/Modules/Backup/Controllers/BackupAdminPage.php b/src/Modules/Backup/Controllers/BackupAdminPage.php new file mode 100644 index 000000000..6a20a38d5 --- /dev/null +++ b/src/Modules/Backup/Controllers/BackupAdminPage.php @@ -0,0 +1,138 @@ +hooks = $hooks; + $this->settingsFacade = $settingsFacade; + } + + public function initialize() + { + $this->hooks->addAction( + HooksAbstract::ACTION_ADMIN_MENU, + [$this, 'addSubmenuPage'], + 14 + ); + + $this->hooks->addAction( + HooksAbstract::ACTION_ADMIN_ENQUEUE_SCRIPTS, + [$this, 'enqueueAdminScripts'] + ); + } + + public function addSubmenuPage() + { + add_submenu_page( + 'publishpress-future', + 'Export / Import', + 'Export / Import', + 'manage_options', + 'future-backup', + [$this, 'renderSubmenuPage'], + ); + } + + public function renderSubmenuPage() + { + $showSideBar = $this->hooks->applyFilters( + SettingsHooksAbstract::FILTER_SHOW_PRO_BANNER, + ! defined('PUBLISHPRESS_FUTURE_LOADED_BY_PRO') + ); + + include __DIR__ . '/../Views/debug-panel.php'; + } + + public function enqueueAdminScripts() + { + if (! function_exists('get_current_screen')) { + return; + } + + $currentScreen = get_current_screen(); + if ($currentScreen->id !== 'future_page_future-backup') { + return; + } + + wp_enqueue_style("wp-components"); + wp_enqueue_style("wp-edit-post"); + wp_enqueue_style("wp-editor"); + wp_enqueue_style("wp-notices"); + + wp_enqueue_script("wp-url"); + wp_enqueue_script("wp-element"); + wp_enqueue_script("wp-components"); + wp_enqueue_script("wp-data"); + wp_enqueue_script("wp-plugins"); + wp_enqueue_script("wp-notices"); + wp_enqueue_script("wp-api-fetch"); + + wp_enqueue_script( + 'future_backup_panel', + Plugin::getScriptUrl('backupPanel'), + [ + 'wp-i18n', + 'wp-components', + 'wp-url', + 'wp-data', + 'wp-element', + 'wp-hooks', + 'wp-api-fetch', + ], + PUBLISHPRESS_FUTURE_VERSION, + true + ); + + wp_localize_script( + 'future_backup_panel', + 'futureBackupPanelData', + [ + 'apiRoot' => esc_url_raw(rest_url()), + 'enableWorkflowScreenshot' => $this->settingsFacade->getWorkflowScreenshotStatus(), + ] + ); + + wp_set_script_translations( + 'future_backup_panel', + 'post-expirator', + PUBLISHPRESS_FUTURE_BASE_PATH . '/languages' + ); + + wp_enqueue_style( + 'pe-footer', + POSTEXPIRATOR_BASEURL . 'assets/css/footer.css', + false, + PUBLISHPRESS_FUTURE_VERSION + ); + + wp_enqueue_style( + 'pe-settings', + POSTEXPIRATOR_BASEURL . 'assets/css/settings.css', + ['pe-footer'], + PUBLISHPRESS_FUTURE_VERSION + ); + + wp_enqueue_style( + 'pp-wordpress-banners-style', + POSTEXPIRATOR_BASEURL . 'assets/vendor/wordpress-banners/css/style.css', + false, + PUBLISHPRESS_FUTURE_VERSION + ); + } +} diff --git a/src/Modules/Backup/Controllers/BackupRestApi.php b/src/Modules/Backup/Controllers/BackupRestApi.php new file mode 100644 index 000000000..2e4ae9501 --- /dev/null +++ b/src/Modules/Backup/Controllers/BackupRestApi.php @@ -0,0 +1,442 @@ +hooks = $hooks; + $this->pluginVersion = $pluginVersion; + $this->settingsFacade = $settingsFacade; + $this->logger = $logger; + } + + public function initialize() + { + $this->hooks->addAction( + HooksAbstract::ACTION_REST_API_INIT, + [$this, 'registerRestRoutes'] + ); + } + + public function registerRestRoutes() + { + $apiNamespace = 'publishpress-future/v1'; + + register_rest_route( + $apiNamespace, + '/backup/workflows', + [ + 'methods' => 'GET', + 'callback' => [$this, 'getWorkflows'], + 'permission_callback' => function () { + return current_user_can('manage_options'); + }, + ] + ); + + register_rest_route( + $apiNamespace, + '/backup/export', + [ + 'methods' => 'POST', + 'callback' => [$this, 'exportBackup'], + 'permission_callback' => function () { + return current_user_can('manage_options'); + }, + 'args' => [ + 'exportActionWorkflows' => [ + 'type' => 'boolean', + ], + 'exportActionSettings' => [ + 'type' => 'boolean', + ], + 'workflows' => [ + 'type' => 'array', + ], + 'includeScreenshots' => [ + 'type' => 'boolean', + ], + 'settings' => [ + 'type' => 'array', + ], + ], + ] + ); + + register_rest_route( + $apiNamespace, + '/backup/import', + [ + 'methods' => 'POST', + 'callback' => [$this, 'importBackup'], + 'permission_callback' => function () { + return current_user_can('manage_options'); + }, + 'accept_file_uploads' => true, + ] + ); + } + + public function getWorkflows(WP_REST_Request $request) + { + try { + /** @var WorkflowsModel $workflowsModel */ + $workflowsModel = new WorkflowsModel(); + + $workflowsIds = $workflowsModel->getAllWorkflowsIds(); + + $workflows = []; + + foreach ($workflowsIds as $workflowId) { + $workflow = new WorkflowModel(); + $workflow->load($workflowId); + + $workflows[] = [ + 'id' => $workflow->getId(), + 'title' => $workflow->getTitle(), + 'status' => $workflow->getStatus(), + ]; + } + + return new WP_REST_Response( + [ + 'workflows' => $workflows, + 'ok' => true, + ], + 200 + ); + } catch (Throwable $e) { + $this->logger->error('Error getting workflows: ' . $e->getMessage()); + + return new WP_REST_Response( + [ + 'message' => __('Failed to get workflows. Check the logs for more details.', 'post-expirator'), + 'ok' => false, + ], + 400 + ); + } + } + + public function exportBackup(WP_REST_Request $request) + { + try { + $exportActionWorkflows = $request->get_param('exportActionWorkflows'); + $exportActionSettings = $request->get_param('exportActionSettings'); + $selectedWorkflows = $request->get_param('workflows'); + $includeScreenshots = $request->get_param('includeScreenshots'); + $selectedSettings = $request->get_param('settings'); + + if (! $exportActionWorkflows && ! $exportActionSettings) { + return new WP_REST_Response( + [ + 'message' => 'No export action selected', + 'ok' => false, + ], + 400 + ); + } + + $exportData = [ + 'version' => $this->pluginVersion, + 'date' => date('Y-m-d H:i:s'), + ]; + + if ($exportActionWorkflows) { + $exportData['workflows'] = $this->exportWorkflows($selectedWorkflows, $includeScreenshots); + } + + if ($exportActionSettings) { + $exportData['settings'] = $this->exportSettings($selectedSettings); + } + + return new WP_REST_Response( + [ + 'message' => 'Exporting backup', + 'data' => $exportData, + 'ok' => true, + ], + 200 + ); + } catch (Throwable $e) { + $this->logger->error('Error exporting backup: ' . $e->getMessage()); + + return new WP_REST_Response( + [ + 'message' => __('Failed to export the file. Check the logs for more details.', 'post-expirator'), + 'ok' => false, + ], + 400 + ); + } + } + + private function exportWorkflows(array $selectedWorkflowIds = [], bool $includeScreenshots = false) + { + /** @var WorkflowsModel $workflowsModel */ + $workflowsModel = new WorkflowsModel(); + + $workflowIds = $workflowsModel->getAllWorkflowsIds(); + + $workflows = []; + + if (empty($selectedWorkflowIds)) { + return []; + } + + foreach ($workflowIds as $workflowId) { + if (! in_array($workflowId, $selectedWorkflowIds)) { + continue; + } + + /** @var WorkflowModel $workflow */ + $workflow = new WorkflowModel(); + $workflow->load($workflowId); + + if ($workflow->getStatus() === 'trash') { + continue; + } + + if ($includeScreenshots) { + $screenshotUrl = $workflow->getScreenshotUrl(); + $screenshotData = @file_get_contents($screenshotUrl); + $screenshotData = 'data:image/png;base64,' . base64_encode($screenshotData); + } else { + $screenshotData = null; + } + + $workflows[] = [ + 'id' => $workflow->getId(), + 'title' => $workflow->getTitle(), + 'description' => $workflow->getDescription(), + 'modified_at' => $workflow->getModifiedAt(), + 'status' => $workflow->getStatus(), + 'flow' => $workflow->getFlow(), + 'screenshot' => $screenshotData, + ]; + } + + return $workflows; + } + + private function exportSettings(array $selectedSettings = []) + { + $settings = []; + + if (empty($selectedSettings)) { + return $settings; + } + + if (in_array('postTypesDefaults', $selectedSettings)) { + $settings = array_merge($settings, $this->getPostTypesSettings()); + } + + if (in_array('general', $selectedSettings)) { + $settings = array_merge($settings, $this->getGeneralSettings()); + } + + if (in_array('notifications', $selectedSettings)) { + $settings = array_merge($settings, $this->getNotificationsSettings()); + } + + if (in_array('display', $selectedSettings)) { + $settings = array_merge($settings, $this->getDisplaySettings()); + } + + if (in_array('advanced', $selectedSettings)) { + $settings = array_merge($settings, $this->getAdvancedSettings()); + } + + $settings = apply_filters(BackupHooksAbstract::FILTER_EXPORTED_SETTINGS, $settings, $selectedSettings); + + return $settings; + } + + private function getPostTypesSettings(): array + { + /** @var SettingsPostTypesModel $settingsPostTypesModel */ + $settingsPostTypesModel = new SettingsPostTypesModel(); + + + $postTypes = $settingsPostTypesModel->getPostTypes(); + $defaults = []; + + foreach ($postTypes as $postType) { + $defaults[$postType] = $this->settingsFacade->getPostTypeDefaults($postType); + } + + return [ + 'postTypesDefaults' => $defaults, + ]; + } + + private function getGeneralSettings(): array + { + return [ + 'general' => $this->settingsFacade->getGeneralSettings(), + ]; + } + + private function getNotificationsSettings(): array + { + return [ + 'notifications' => $this->settingsFacade->getNotificationsSettings(), + ]; + } + + private function getDisplaySettings(): array + { + return [ + 'display' => $this->settingsFacade->getDisplaySettings(), + ]; + } + + private function getAdvancedSettings(): array + { + return [ + 'advanced' => $this->settingsFacade->getAdvancedSettings(), + ]; + } + + public function importBackup(WP_REST_Request $request) + { + $files = $request->get_file_params(); + + $uploadedFile = null; + + $permittedTypes = ['application/json', 'text/json', 'text/plain']; + + if (!empty($files) && !empty($files['backupFile'])) { + $uploadedFile = $files['backupFile']; + } + + try { + if (empty($uploadedFile) || !isset($uploadedFile['tmp_name'])) { + throw new Exception('No backup file uploaded'); + } + + if (! is_uploaded_file($uploadedFile['tmp_name'])) { + throw new Exception('Invalid backup file'); + } + + if ($uploadedFile['error'] !== UPLOAD_ERR_OK) { + throw new Exception('Error uploading backup file'); + } + + $ext = pathinfo($uploadedFile['name'], PATHINFO_EXTENSION); + + if ($ext !== 'json') { + throw new Exception('Invalid file type. Please upload a JSON file.'); + } + + $mimeType = mime_content_type($uploadedFile['tmp_name']); + if (!in_array($uploadedFile['type'], $permittedTypes) + || !in_array($mimeType, $permittedTypes) + ) { + throw new Exception('Invalid mime type'); + } + + // Read and decode the JSON file + $jsonContent = file_get_contents($uploadedFile['tmp_name']); + $backupData = json_decode($jsonContent, true); + + if (isset($backupData['workflows'])) { + $this->importWorkflows($backupData['workflows']); + } + + if (isset($backupData['settings'])) { + $this->importSettings($backupData['settings']); + } + + return new WP_REST_Response( + [ + 'message' => 'Backup imported successfully', + 'ok' => true, + ], + 200 + ); + } catch (Throwable $e) { + $this->logger->error('Error importing backup: ' . $e->getMessage()); + + return new WP_REST_Response( + [ + 'message' => __('Failed to import the file. Check the logs for more details.', 'post-expirator'), + 'ok' => false, + ], + 400 + ); + } + } + + public function importWorkflows($workflows) + { + foreach ($workflows as $workflow) { + $workflowModel = new WorkflowModel(); + $workflowModel->createNew(); + $workflowModel->setTitle($workflow['title']); + $workflowModel->setDescription($workflow['description']); + $workflowModel->setStatus('draft'); + $workflowModel->setFlow($workflow['flow']); + $workflowModel->save(); + + if (isset($workflow['screenshot'])) { + $workflowModel->setScreenshotFromBase64($workflow['screenshot']); + } + } + } + + public function importSettings($settings) + { + if (isset($settings['postTypesDefaults'])) { + foreach ($settings['postTypesDefaults'] as $postType => $default) { + $this->settingsFacade->setPostTypeDefaults($postType, $default); + } + } + + if (isset($settings['general'])) { + $this->settingsFacade->setGeneralSettings($settings['general']); + } + + if (isset($settings['notifications'])) { + $this->settingsFacade->setNotificationsSettings($settings['notifications']); + } + + if (isset($settings['display'])) { + $this->settingsFacade->setDisplaySettings($settings['display']); + } + + if (isset($settings['advanced'])) { + $this->settingsFacade->setAdvancedSettings($settings['advanced']); + } + + do_action(BackupHooksAbstract::ACTION_AFTER_IMPORT_SETTINGS, $settings); + } +} diff --git a/src/Modules/Backup/HooksAbstract.php b/src/Modules/Backup/HooksAbstract.php new file mode 100644 index 000000000..b0a1470c4 --- /dev/null +++ b/src/Modules/Backup/HooksAbstract.php @@ -0,0 +1,11 @@ +hooks = $hooks; + $this->pluginVersion = $pluginVersion; + $this->settingsFacade = $settingsFacade; + $this->logger = $logger; + } + + /** + * @inheritDoc + */ + public function initialize() + { + $controllers = [ + new BackupAdminPage( + $this->hooks, + $this->settingsFacade + ), + new BackupRestApi( + $this->hooks, + $this->pluginVersion, + $this->settingsFacade, + $this->logger + ), + ]; + + foreach ($controllers as $controller) { + $controller->initialize(); + } + } +} diff --git a/src/Modules/Backup/Views/debug-panel.php b/src/Modules/Backup/Views/debug-panel.php new file mode 100644 index 000000000..9ded37538 --- /dev/null +++ b/src/Modules/Backup/Views/debug-panel.php @@ -0,0 +1,33 @@ + +
+

+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ +
+
+publishpress_footer(); diff --git a/src/Modules/Expirator/Controllers/BlockEditorController.php b/src/Modules/Expirator/Controllers/BlockEditorController.php index c4fd579b6..ee4e256f9 100644 --- a/src/Modules/Expirator/Controllers/BlockEditorController.php +++ b/src/Modules/Expirator/Controllers/BlockEditorController.php @@ -122,6 +122,9 @@ public function enqueueBlockEditorAssets() $defaultExpirationDate = $defaultDataModel->getActionDateParts($post->ID); + $metaboxTitle = $settingsFacade->getMetaboxTitle() ?? __('Future Actions', 'post-expirator'); + $metaboxCheckboxLabel = $settingsFacade->getMetaboxCheckboxLabel() ?? __('Enable Future Action', 'post-expirator'); + wp_localize_script( 'postexpirator-block-editor', 'publishpressFutureBlockEditorConfig', @@ -140,9 +143,8 @@ public function enqueueBlockEditorAssets() 'hideCalendarByDefault' => $settingsFacade->getHideCalendarByDefault(), 'strings' => [ 'category' => __('Categories', 'post-expirator'), - 'panelTitle' => __('Future Actions', 'post-expirator'), - 'enablePostExpiration' => __('Enable Future Action', 'post-expirator'), - 'futureActions' => __('Future Actions', 'post-expirator'), + 'panelTitle' => $metaboxTitle, + 'enablePostExpiration' => $metaboxCheckboxLabel, 'action' => __('Action', 'post-expirator'), 'loading' => __('Loading', 'post-expirator'), 'showCalendar' => __('Show Calendar', 'post-expirator'), diff --git a/src/Modules/Expirator/Controllers/BulkEditController.php b/src/Modules/Expirator/Controllers/BulkEditController.php index 229837375..9afe5e44b 100644 --- a/src/Modules/Expirator/Controllers/BulkEditController.php +++ b/src/Modules/Expirator/Controllers/BulkEditController.php @@ -164,6 +164,9 @@ public function enqueueScripts() $defaultExpirationDate = $defaultDataModel->getActionDateParts(); $nonce = wp_create_nonce('__future_action'); + $metaboxTitle = $settingsFacade->getMetaboxTitle() ?? __('Future Actions', 'post-expirator'); + $metaboxCheckboxLabel = $settingsFacade->getMetaboxCheckboxLabel() ?? __('Enable Future Action', 'post-expirator'); + wp_localize_script( 'postexpirator-bulk-edit', 'publishpressFutureBulkEditConfig', @@ -184,9 +187,8 @@ public function enqueueScripts() 'hideCalendarByDefault' => $settingsFacade->getHideCalendarByDefault(), 'strings' => [ 'category' => __('Categories', 'post-expirator'), - 'panelTitle' => __('Future Actions', 'post-expirator'), - 'enablePostExpiration' => __('Enable Future Action', 'post-expirator'), - 'futureActions' => __('Future Actions', 'post-expirator'), + 'panelTitle' => $metaboxTitle, + 'enablePostExpiration' => $metaboxCheckboxLabel, 'action' => __('Action', 'post-expirator'), 'showCalendar' => __('Show Calendar', 'post-expirator'), 'hideCalendar' => __('Hide Calendar', 'post-expirator'), diff --git a/src/Modules/Expirator/Controllers/ClassicEditorController.php b/src/Modules/Expirator/Controllers/ClassicEditorController.php index a2a96390e..3ec6d79b9 100644 --- a/src/Modules/Expirator/Controllers/ClassicEditorController.php +++ b/src/Modules/Expirator/Controllers/ClassicEditorController.php @@ -134,6 +134,8 @@ public function registerClassicEditorMetabox($postType, $post) $defaults = $settingsFacade->getPostTypeDefaults($postType); $hideMetabox = (bool)$this->hooks->applyFilters(HooksAbstract::FILTER_HIDE_METABOX, false, $postType); + $metaboxTitle = $settingsFacade->getMetaboxTitle() ?? __('Future Actions', 'post-expirator'); + // if settings are not configured, show the metabox by default only for posts and pages if ( $hideMetabox === false @@ -151,7 +153,7 @@ public function registerClassicEditorMetabox($postType, $post) ) { add_meta_box( 'expirationdatediv', - __('Future Actions', 'post-expirator'), + $metaboxTitle, [$this, 'renderClassicEditorMetabox'], $postType, 'side', @@ -364,6 +366,9 @@ public function enqueueScripts() $defaultExpirationDate = $defaultDataModel->getActionDateParts(); + $metaboxTitle = $settingsFacade->getMetaboxTitle() ?? __('Future Actions', 'post-expirator'); + $metaboxCheckboxLabel = $settingsFacade->getMetaboxCheckboxLabel() ?? __('Enable Future Action', 'post-expirator'); + wp_localize_script( 'publishpress-future-classic-editor', 'publishpressFutureClassicEditorConfig', @@ -383,9 +388,8 @@ public function enqueueScripts() 'hideCalendarByDefault' => $settingsFacade->getHideCalendarByDefault(), 'strings' => [ 'category' => __('Category', 'post-expirator'), - 'panelTitle' => __('Future Actions', 'post-expirator'), - 'enablePostExpiration' => __('Enable Future Action', 'post-expirator'), - 'futureActions' => __('Future Actions', 'post-expirator'), + 'panelTitle' => $metaboxTitle, + 'enablePostExpiration' => $metaboxCheckboxLabel, 'action' => __('Action', 'post-expirator'), 'showCalendar' => __('Show Calendar', 'post-expirator'), 'hideCalendar' => __('Hide Calendar', 'post-expirator'), diff --git a/src/Modules/Expirator/Controllers/QuickEditController.php b/src/Modules/Expirator/Controllers/QuickEditController.php index b05059395..b5073616c 100644 --- a/src/Modules/Expirator/Controllers/QuickEditController.php +++ b/src/Modules/Expirator/Controllers/QuickEditController.php @@ -19,6 +19,7 @@ use PublishPress\Future\Modules\Expirator\HooksAbstract as ExpiratorHooks; use PublishPress\Future\Modules\Expirator\HooksAbstract; use PublishPress\Future\Modules\Expirator\Models\CurrentUserModel; +use PublishPress\Future\Modules\Settings\SettingsFacade; use Throwable; defined('ABSPATH') or die('Direct access not allowed.'); @@ -40,17 +41,24 @@ class QuickEditController implements InitializableInterface */ private $logger; + /** + * @var SettingsFacade + */ + private $settingsFacade; + /** * @param HookableInterface $hooksFacade */ public function __construct( HookableInterface $hooksFacade, \Closure $currentUserModelFactory, - LoggerInterface $logger + LoggerInterface $logger, + SettingsFacade $settingsFacade ) { $this->hooks = $hooksFacade; $this->currentUserModel = $currentUserModelFactory(); $this->logger = $logger; + $this->settingsFacade = $settingsFacade; } public function initialize() @@ -286,6 +294,9 @@ public function enqueueScripts() $defaultExpirationDate = $defaultDataModel->getActionDateParts(); $nonce = wp_create_nonce('__future_action'); + $metaboxTitle = $this->settingsFacade->getMetaboxTitle() ?? __('Future Actions', 'post-expirator'); + $metaboxCheckboxLabel = $this->settingsFacade->getMetaboxCheckboxLabel() ?? __('Enable Future Action', 'post-expirator'); + wp_localize_script( 'postexpirator-quick-edit', 'publishpressFutureQuickEditConfig', @@ -306,9 +317,8 @@ public function enqueueScripts() 'hideCalendarByDefault' => $settingsFacade->getHideCalendarByDefault(), 'strings' => [ 'category' => __('Categories', 'post-expirator'), - 'panelTitle' => __('Future Actions', 'post-expirator'), - 'enablePostExpiration' => __('Enable Future Action', 'post-expirator'), - 'futureActions' => __('Future Actions', 'post-expirator'), + 'panelTitle' => $metaboxTitle, + 'enablePostExpiration' => $metaboxCheckboxLabel, 'action' => __('Action', 'post-expirator'), 'showCalendar' => __('Show Calendar', 'post-expirator'), 'hideCalendar' => __('Hide Calendar', 'post-expirator'), diff --git a/src/Modules/Expirator/ExpirationScheduler.php b/src/Modules/Expirator/ExpirationScheduler.php index 5c8e6209f..4a357278e 100644 --- a/src/Modules/Expirator/ExpirationScheduler.php +++ b/src/Modules/Expirator/ExpirationScheduler.php @@ -256,14 +256,14 @@ public function unschedule($postId) $this->logger->debug($message); - $this->deleteExpirationPostMeta($postId); + $this->disableExpirationPostMeta($postId); } } - protected function deleteExpirationPostMeta($postId) + protected function disableExpirationPostMeta($postId) { $postModelFactory = $this->postModelFactory; $postModel = $postModelFactory($postId); - $postModel->deleteExpirationPostMeta(); + $postModel->disableExpiration(); } } diff --git a/src/Modules/Expirator/Models/ExpirablePostModel.php b/src/Modules/Expirator/Models/ExpirablePostModel.php index 2b8dfd6c4..ddfe15ac5 100644 --- a/src/Modules/Expirator/Models/ExpirablePostModel.php +++ b/src/Modules/Expirator/Models/ExpirablePostModel.php @@ -827,6 +827,11 @@ public function forceTimestampToUnixtime($timestamp) return $timestamp; } + public function disableExpiration() + { + $this->updateMeta(PostMetaAbstract::EXPIRATION_STATUS, '0'); + } + public function hasActionScheduledInPostMeta() { $timestampInPostMeta = $this->getMeta(PostMetaAbstract::EXPIRATION_TIMESTAMP, true); diff --git a/src/Modules/Expirator/Module.php b/src/Modules/Expirator/Module.php index f75ebedf3..246dd6840 100644 --- a/src/Modules/Expirator/Module.php +++ b/src/Modules/Expirator/Module.php @@ -204,7 +204,8 @@ private function factoryQuickEditController() return new Controllers\QuickEditController( $this->hooks, $this->currentUserModelFactory, - $this->logger + $this->logger, + $this->settingsFacade ); } diff --git a/src/Modules/Expirator/Tables/ScheduledActionsTable.php b/src/Modules/Expirator/Tables/ScheduledActionsTable.php index c8ae235ad..d70f653b2 100644 --- a/src/Modules/Expirator/Tables/ScheduledActionsTable.php +++ b/src/Modules/Expirator/Tables/ScheduledActionsTable.php @@ -464,8 +464,8 @@ private function render_expiration_hook_args(array $row) esc_html__('%1$s: [%2$d] %3$s%4$s%5$s', 'post-expirator'), esc_html($actionData['postTypeLabel']), $actionData['postId'], - '', - esc_html($actionData['postTitle']), + '', + esc_html($actionData['postTitle'] ?? ''), '' ); @@ -688,13 +688,13 @@ protected function get_schedule_display_string(\ActionScheduler_Schedule $schedu return __('Async', 'post-expirator'); } - if (! method_exists($schedule, 'get_date') || ! $schedule->get_date()) { + if (! method_exists($schedule, 'next') || ! $schedule->next()) { return '0000-00-00 00:00:00'; } - $next_timestamp = $schedule->get_date()->getTimestamp(); + $next_timestamp = $schedule->next()->getTimestamp(); - $gmt_schedule_display_string = $schedule->get_date()->format('Y-m-d H:i:s O'); + $gmt_schedule_display_string = $schedule->next()->format('Y-m-d H:i:s O'); $schedule_display_string .= wp_date('Y-m-d H:i:s O', $next_timestamp); $schedule_display_string .= '
'; diff --git a/src/Modules/Settings/Controllers/Controller.php b/src/Modules/Settings/Controllers/Controller.php index b6141eb3b..c9973ecd5 100644 --- a/src/Modules/Settings/Controllers/Controller.php +++ b/src/Modules/Settings/Controllers/Controller.php @@ -392,6 +392,7 @@ private function getCurrentTab() 'defaults', 'general', 'display', + 'notifications', 'diagnostics', 'viewdebug', 'advanced', diff --git a/src/Modules/Settings/HooksAbstract.php b/src/Modules/Settings/HooksAbstract.php index 7cad84338..a47f4c6fe 100644 --- a/src/Modules/Settings/HooksAbstract.php +++ b/src/Modules/Settings/HooksAbstract.php @@ -24,4 +24,14 @@ abstract class HooksAbstract public const ACTION_SETTINGS_TAB_ADVANCED_BEFORE = 'publishpress_future/settings_tab_advanced_before'; public const ACTION_FIX_DB_SCHEMA = 'publishpressfuture_fix_db_schema'; public const FILTER_SCHEMA_IS_HEALTHY = 'publishpressfuture_schema_is_healthy'; + public const FILTER_SETTINGS_GENERAL = 'publishpressfuture_settings_general'; + public const FILTER_SETTINGS_NOTIFICATIONS = 'publishpressfuture_settings_notifications'; + public const FILTER_SETTINGS_DISPLAY = 'publishpressfuture_settings_display'; + public const FILTER_SETTINGS_ADVANCED = 'publishpressfuture_settings_advanced'; + public const FILTER_SETTINGS_POST_TYPE_DEFAULTS = 'publishpressfuture_settings_post_type_defaults'; + public const ACTION_SETTINGS_SET_POST_TYPE_DEFAULTS = 'publishpressfuture_settings_set_post_type_defaults'; + public const ACTION_SETTINGS_SET_GENERAL = 'publishpressfuture_settings_set_general'; + public const ACTION_SETTINGS_SET_NOTIFICATIONS = 'publishpressfuture_settings_set_notifications'; + public const ACTION_SETTINGS_SET_DISPLAY = 'publishpressfuture_settings_set_display'; + public const ACTION_SETTINGS_SET_ADVANCED = 'publishpressfuture_settings_set_advanced'; } diff --git a/src/Modules/Settings/SettingsFacade.php b/src/Modules/Settings/SettingsFacade.php index 76a08209f..c508ca78f 100644 --- a/src/Modules/Settings/SettingsFacade.php +++ b/src/Modules/Settings/SettingsFacade.php @@ -6,11 +6,14 @@ namespace PublishPress\Future\Modules\Settings; +use PostExpirator_Facade; use PublishPress\Future\Core\HookableInterface; use PublishPress\Future\Core\HooksAbstract as CoreHooksAbstract; use PublishPress\Future\Framework\WordPress\Facade\OptionsFacade; +use PublishPress\Future\Modules\Expirator\CapabilitiesAbstract; use PublishPress\Future\Modules\Expirator\ExpirationActions\ChangePostStatus; use PublishPress\Future\Modules\Expirator\ExpirationActionsAbstract; +use WP_Role; defined('ABSPATH') or die('Direct access not allowed.'); @@ -24,6 +27,10 @@ class SettingsFacade public const OPTION_EXPERIMENTAL_ENABLED = 'ppfuture_experimental_status'; + public const OPTION_METABOX_TITLE = 'expirationdateMetaboxTitle'; + + public const OPTION_METABOX_CHECKBOX_LABEL = 'expirationdateMetaboxCheckboxLabel'; + /** * @var HookableInterface */ @@ -137,6 +144,11 @@ public function getSettingPreserveData($default = true) return (bool)$this->options->getOption('expirationdatePreserveData', $default); } + public function setSettingPreserveData(bool $value): void + { + $this->options->updateOption('expirationdatePreserveData', $value); + } + /** * @param bool $default * @return bool @@ -154,6 +166,11 @@ public function getDebugIsEnabled($default = false) return (bool)$this->cache['debugIsEnabled']; } + public function getSendEmailNotification() + { + return (bool)$this->options->getOption('expirationdateEmailNotification', POSTEXPIRATOR_EMAILNOTIFICATION); + } + public function getSendEmailNotificationToAdmins() { return (bool)$this->options->getOption( @@ -248,11 +265,20 @@ public function getPostTypeDefaults($postType) $this->cache['postTypeDefaults'] = []; } + $defaults = apply_filters(HooksAbstract::FILTER_SETTINGS_POST_TYPE_DEFAULTS, $defaults, $postType); + $this->cache['postTypeDefaults'][$postType] = $defaults; return $this->cache['postTypeDefaults'][$postType]; } + public function setPostTypeDefaults(string $postType, array $defaults): void + { + $this->options->updateOption('expirationdateDefaults' . ucfirst($postType), $defaults); + + do_action(HooksAbstract::ACTION_SETTINGS_SET_POST_TYPE_DEFAULTS, $defaults, $postType); + } + /** * @return mixed * @deprecated Use getDefaultDateCustom() instead @@ -286,21 +312,46 @@ public function getGeneralDateTimeOffset() return $defaultDateOffsetOption; } + public function setGeneralDateTimeOffset(string $value): void + { + $value = sanitize_text_field($value); + $value = html_entity_decode($value, ENT_QUOTES); + $value = preg_replace('/["\'`]/', '', $value); + + $this->options->updateOption('expirationdateDefaultDate', 'custom'); + $this->options->updateOption('expirationdateDefaultDateCustom', $value); + } + public function getColumnStyle() { return $this->options->getOption('expirationdateColumnStyle', 'verbose'); } + public function setColumnStyle(string $value): void + { + $this->options->updateOption('expirationdateColumnStyle', $value); + } + public function getTimeFormatForDatePicker() { return $this->options->getOption('expirationdateTimeFormatForDatePicker', 'inherited'); } + public function setTimeFormatForDatePicker(string $value): void + { + $this->options->updateOption('expirationdateTimeFormatForDatePicker', $value); + } + public function getHideCalendarByDefault() { return (bool)$this->options->getOption('expirationdateHideCalendarByDefault', false); } + public function setHideCalendarByDefault(bool $value): void + { + $this->options->updateOption('expirationdateHideCalendarByDefault', $value); + } + public function getStepScheduleCompressedArgsStatus(): bool { return (bool)$this->options->getOption(self::OPTION_STEP_SCHEDULE_COMPRESSED_ARGS, false); @@ -342,4 +393,245 @@ public function setScheduledWorkflowStepsCleanupRetention(int $value): void { $this->options->updateOption(self::OPTION_FINISHED_SCHEDULED_STEP_RETENTION, $value); } + + public function getMetaboxTitle(): ?string + { + return $this->options->getOption(self::OPTION_METABOX_TITLE, null); + } + + public function getMetaboxCheckboxLabel(): ?string + { + return $this->options->getOption(self::OPTION_METABOX_CHECKBOX_LABEL, null); + } + + public function setMetaboxTitle(string $value): void + { + $this->options->updateOption(self::OPTION_METABOX_TITLE, $value); + } + + public function setMetaboxCheckboxLabel(string $value): void + { + $this->options->updateOption(self::OPTION_METABOX_CHECKBOX_LABEL, $value); + } + + public function setSendEmailNotification(bool $value): void + { + $this->options->updateOption('expirationdateEmailNotification', $value); + } + + public function setSendEmailNotificationToAdmins(bool $value): void + { + $this->options->updateOption('expirationdateEmailNotificationAdmins', $value); + } + + public function setEmailNotificationAddressesList(array $value): void + { + $this->options->updateOption('expirationdateEmailNotificationList', implode(',', $value)); + } + + public function getDefaultDateFormat(): string + { + return $this->options->getOption('expirationdateDefaultDateFormat', POSTEXPIRATOR_DATEFORMAT); + } + + public function setDefaultDateFormat(string $value): void + { + $this->options->updateOption('expirationdateDefaultDateFormat', $value); + } + + public function getDefaultTimeFormat(): string + { + return $this->options->getOption('expirationdateDefaultTimeFormat', POSTEXPIRATOR_TIMEFORMAT); + } + + public function setDefaultTimeFormat(string $value): void + { + $this->options->updateOption('expirationdateDefaultTimeFormat', $value); + } + + public function getShowInPostFooter(): bool + { + return (bool)$this->options->getOption('expirationdateDisplayFooter', POSTEXPIRATOR_FOOTERDISPLAY); + } + + public function setShowInPostFooter(bool $value): void + { + $this->options->updateOption('expirationdateDisplayFooter', $value); + } + + public function getFooterContents(): string + { + return $this->options->getOption('expirationdateFooterContents', POSTEXPIRATOR_FOOTERCONTENTS); + } + + public function setFooterContents(string $value): void + { + $this->options->updateOption('expirationdateFooterContents', $value); + } + + public function getFooterStyle(): string + { + return $this->options->getOption('expirationdateFooterStyle', POSTEXPIRATOR_FOOTERSTYLE); + } + + public function setFooterStyle(string $value): void + { + $this->options->updateOption('expirationdateFooterStyle', $value); + } + + public function getAllowUserRoles(): array + { + $userRoles = wp_roles()->get_names(); + + $allowedUserRoles = []; + + $pluginFacade = PostExpirator_Facade::getInstance(); + + foreach ($userRoles as $userRoleName => $userRoleLabel) + { + if ($pluginFacade->user_role_can_expire_posts($userRoleName)) { + $allowedUserRoles[] = $userRoleName; + } + } + + return $allowedUserRoles; + } + + public function setAllowUserRoles(array $value): void + { + $userRoles = array_keys(wp_roles()->get_names()); + $capability = CapabilitiesAbstract::EXPIRE_POST; + + foreach ($userRoles as $roleName) { + $role = get_role($roleName); + + if (! is_a($role, WP_Role::class)) { + continue; + } + + // TODO: only allow roles that can edit posts. Filter in the form as well, adding a description. + if ($roleName === 'administrator' || in_array($roleName, $value, true)) { + $role->add_cap($capability); + continue; + } + + $role->remove_cap($capability); + } + } + + public function getWorkflowScreenshotStatus(): bool + { + return (bool)$this->options->getOption('workflowScreenshot', false); + } + + public function setWorkflowScreenshotStatus(bool $value): void + { + $this->options->updateOption('workflowScreenshot', $value); + } + + public function getGeneralSettings(): array + { + $settings = [ + 'defaultDateTimeOffset' => $this->getGeneralDateTimeOffset(), + 'hideCalendarByDefault' => $this->getHideCalendarByDefault(), + 'allowUserRoles' => $this->getAllowUserRoles(), + 'workflowScreenshot' => $this->getWorkflowScreenshotStatus(), + ]; + + $settings = $this->hooks->applyFilters(HooksAbstract::FILTER_SETTINGS_GENERAL, $settings); + + return $settings; + } + + public function setGeneralSettings(array $settings): void + { + $this->setGeneralDateTimeOffset($settings['defaultDateTimeOffset'] ?? ''); + $this->setHideCalendarByDefault($settings['hideCalendarByDefault'] ?? false); + $this->setAllowUserRoles($settings['allowUserRoles'] ?? []); + $this->setWorkflowScreenshotStatus($settings['workflowScreenshot'] ?? false); + + do_action(HooksAbstract::ACTION_SETTINGS_SET_GENERAL, $settings); + } + + public function getNotificationsSettings(): array + { + $settings = [ + 'enableEmailNotification' => $this->getSendEmailNotification(), + 'enableEmailNotificationToAdmins' => $this->getSendEmailNotificationToAdmins(), + 'emailNotificationAddressesList' => $this->getEmailNotificationAddressesList(), + ]; + + $settings = $this->hooks->applyFilters(HooksAbstract::FILTER_SETTINGS_NOTIFICATIONS, $settings); + + return $settings; + } + + public function setNotificationsSettings(array $settings): void + { + $this->setSendEmailNotification($settings['enableEmailNotification'] ?? false); + $this->setSendEmailNotificationToAdmins($settings['enableEmailNotificationToAdmins'] ?? false); + $this->setEmailNotificationAddressesList($settings['emailNotificationAddressesList'] ?? []); + + do_action(HooksAbstract::ACTION_SETTINGS_SET_NOTIFICATIONS, $settings); + } + + public function getDisplaySettings(): array + { + $settings = [ + 'defaultDateFormat' => $this->getDefaultDateFormat(), + 'defaultTimeFormat' => $this->getDefaultTimeFormat(), + 'metaboxTitle' => $this->getMetaboxTitle(), + 'metaboxCheckboxLabel' => $this->getMetaboxCheckboxLabel(), + 'columnStyle' => $this->getColumnStyle(), + 'timeFormatForDatePicker' => $this->getTimeFormatForDatePicker(), + 'showInPostFooter' => $this->getShowInPostFooter(), + 'footerContents' => $this->getFooterContents(), + 'footerStyle' => $this->getFooterStyle(), + ]; + + $settings = $this->hooks->applyFilters(HooksAbstract::FILTER_SETTINGS_DISPLAY, $settings); + + return $settings; + } + + public function setDisplaySettings(array $settings): void + { + $this->setDefaultDateFormat($settings['defaultDateFormat'] ?? ''); + $this->setDefaultTimeFormat($settings['defaultTimeFormat'] ?? ''); + $this->setMetaboxTitle($settings['metaboxTitle'] ?? ''); + $this->setMetaboxCheckboxLabel($settings['metaboxCheckboxLabel'] ?? ''); + $this->setColumnStyle($settings['columnStyle'] ?? ''); + $this->setTimeFormatForDatePicker($settings['timeFormatForDatePicker'] ?? ''); + $this->setShowInPostFooter($settings['showInPostFooter'] ?? false); + $this->setFooterContents($settings['footerContents'] ?? ''); + $this->setFooterStyle($settings['footerStyle'] ?? ''); + + do_action(HooksAbstract::ACTION_SETTINGS_SET_DISPLAY, $settings); + } + + public function getAdvancedSettings(): array + { + $settings = [ + 'stepScheduleCompressedArgs' => $this->getStepScheduleCompressedArgsStatus(), + 'scheduledWorkflowStepsCleanup' => $this->getScheduledWorkflowStepsCleanupStatus(), + 'scheduledWorkflowStepsCleanupRetention' => $this->getScheduledWorkflowStepsCleanupRetention(), + 'experimentalFeatures' => $this->getExperimentalFeaturesStatus(), + 'preserveDataDeactivating' => $this->getSettingPreserveData(), + ]; + + $settings = $this->hooks->applyFilters(HooksAbstract::FILTER_SETTINGS_ADVANCED, $settings); + + return $settings; + } + + public function setAdvancedSettings(array $settings): void + { + $this->setStepScheduleCompressedArgsStatus($settings['stepScheduleCompressedArgs'] ?? false); + $this->setScheduledWorkflowStepsCleanupStatus($settings['scheduledWorkflowStepsCleanup'] ?? true); + $this->setScheduledWorkflowStepsCleanupRetention($settings['scheduledWorkflowStepsCleanupRetention'] ?? 30); + $this->setExperimentalFeaturesStatus($settings['experimentalFeatures'] ?? false); + $this->setSettingPreserveData($settings['preserveDataDeactivating'] ?? false); + + do_action(HooksAbstract::ACTION_SETTINGS_SET_ADVANCED, $settings); + } } diff --git a/src/Modules/VersionNotices/Module.php b/src/Modules/VersionNotices/Module.php index ee382e2de..833f56d27 100644 --- a/src/Modules/VersionNotices/Module.php +++ b/src/Modules/VersionNotices/Module.php @@ -113,6 +113,10 @@ function ($settings) { [ 'base' => 'admin_page_publishpress-future-scheduled-actions', 'id' => 'admin_page_publishpress-future-scheduled-actions' + ], + [ + 'base' => 'future_page_future-backup', + 'id' => 'future_page_future-backup' ] ] ]; diff --git a/src/Modules/Workflows/Controllers/WorkflowEditor.php b/src/Modules/Workflows/Controllers/WorkflowEditor.php index b06e09300..9604b7ff6 100644 --- a/src/Modules/Workflows/Controllers/WorkflowEditor.php +++ b/src/Modules/Workflows/Controllers/WorkflowEditor.php @@ -227,6 +227,7 @@ public function enqueueScriptsEditor($hook) "welcomeGuidePages" => $this->getWelcomeGuidePages(), "isExperimentalFeaturesEnabled" => $this->settingsFacade->getExperimentalFeaturesStatus(), "isPro" => $isPro, + "enableWorkflowScreenshot" => $this->settingsFacade->getWorkflowScreenshotStatus(), ] ); diff --git a/src/Modules/Workflows/Controllers/WorkflowsList.php b/src/Modules/Workflows/Controllers/WorkflowsList.php index 3e5df1a2e..94767ec00 100644 --- a/src/Modules/Workflows/Controllers/WorkflowsList.php +++ b/src/Modules/Workflows/Controllers/WorkflowsList.php @@ -12,6 +12,7 @@ use PublishPress\Future\Modules\Workflows\Models\WorkflowModel; use PublishPress\Future\Modules\Workflows\Module; use PublishPress\Future\Framework\Logger\LoggerInterface; +use PublishPress\Future\Modules\Settings\SettingsFacade; use Throwable; class WorkflowsList implements InitializableInterface @@ -31,14 +32,21 @@ class WorkflowsList implements InitializableInterface */ private $logger; + /** + * @var SettingsFacade + */ + private $settingsFacade; + public function __construct( HookableInterface $hooks, NodeTypesModelInterface $nodeTypesModel, - LoggerInterface $logger + LoggerInterface $logger, + SettingsFacade $settingsFacade ) { $this->hooks = $hooks; $this->nodeTypesModel = $nodeTypesModel; $this->logger = $logger; + $this->settingsFacade = $settingsFacade; } public function initialize() @@ -78,12 +86,14 @@ public function initialize() 2 ); - $this->hooks->addAction( - "manage_" . Module::POST_TYPE_WORKFLOW . "_posts_custom_column", - [$this, "renderPreviewColumn"], - 10, - 2 - ); + if ($this->settingsFacade->getWorkflowScreenshotStatus()) { + $this->hooks->addAction( + "manage_" . Module::POST_TYPE_WORKFLOW . "_posts_custom_column", + [$this, "renderPreviewColumn"], + 10, + 2 + ); + } $this->hooks->addAction( FutureCoreHooksAbstract::ACTION_ADMIN_INIT, @@ -176,7 +186,10 @@ public function addCustomColumns($columns) "Triggers", "post-expirator" ); - $columns["workflow_preview"] = __("Preview", "post-expirator"); + + if ($this->settingsFacade->getWorkflowScreenshotStatus()) { + $columns["workflow_preview"] = __("Preview", "post-expirator"); + } // Move the date column to the end if (isset($columns["date"])) { diff --git a/src/Modules/Workflows/Domain/Engine/NodeRunnerProcessors/CronStep.php b/src/Modules/Workflows/Domain/Engine/NodeRunnerProcessors/CronStep.php index e74509955..18a697113 100644 --- a/src/Modules/Workflows/Domain/Engine/NodeRunnerProcessors/CronStep.php +++ b/src/Modules/Workflows/Domain/Engine/NodeRunnerProcessors/CronStep.php @@ -163,6 +163,7 @@ public function setup(array $step, callable $actionCallback): void $isSingleAction = self::SCHEDULE_RECURRENCE_SINGLE === $recurrence; $actionUID = $this->getScheduledActionUniqueId($node); + $actionUIDHash = md5($actionUID); $scheduledActionId = 0; $workflowId = $this->variablesHandler->getVariable('global.workflow.id'); @@ -177,7 +178,6 @@ public function setup(array $step, callable $actionCallback): void $compactedArgs = $this->compactArguments($step); - $actionUIDHash = md5($actionUID); $scheduledActionsModel = new ScheduledActionsModel(); $hasFinished = WorkflowScheduledStepModel::getMetaIsFinished($workflowId, $actionUIDHash); @@ -391,19 +391,20 @@ private function getSchedulingTimestamp(array $nodeSettings) return $timestamp; } - private function getScheduledActionUniqueId(array $node) + private function getScheduledActionUniqueId(array $node): string { $uniqueId = [ 'workflowId' => $this->variablesHandler->getVariable('global.workflow.id'), - 'stepId' => $node['id'], - 'custom' => '', + 'stepId' => $node['id'] ]; if (isset($node['data']['settings']['schedule']['uniqueIdExpression'])) { $uniqueIdExpression = $node['data']['settings']['schedule']['uniqueIdExpression']; if (! empty($uniqueIdExpression)) { - $uniqueId['custom'] = $this->variablesHandler->replacePlaceholdersInText($uniqueIdExpression); + $uniqueId = [ + 'custom' => $this->variablesHandler->replacePlaceholdersInText($uniqueIdExpression), + ]; } } diff --git a/src/Modules/Workflows/Domain/Engine/NodeRunners/Advanced/RayDebug.php b/src/Modules/Workflows/Domain/Engine/NodeRunners/Advanced/RayDebug.php index 0f1268bc9..75ac04399 100644 --- a/src/Modules/Workflows/Domain/Engine/NodeRunners/Advanced/RayDebug.php +++ b/src/Modules/Workflows/Domain/Engine/NodeRunners/Advanced/RayDebug.php @@ -53,8 +53,6 @@ function ($step) { $nodeSlug = $this->nodeRunnerProcessor->getSlugFromStep($step); if (! function_exists('ray')) { - $workflowId = $this->variablesHandler->getVariable('global.workflow.id'); - $this->logger->error( $this->nodeRunnerProcessor->prepareLogMessage( 'Ray is not installed. Skipping step %s', @@ -70,6 +68,7 @@ function ($step) { $nodeSettings = $this->nodeRunnerProcessor->getNodeSettings($node); $dataToOutput = $nodeSettings['data']['dataToOutput'] ?? 'all-input'; + $customData = $nodeSettings['data']['customData'] ?? ''; if ($dataToOutput === 'all-input') { $onlyInputVariables = $this->variablesHandler->getAllVariables(); @@ -77,7 +76,11 @@ function ($step) { $output = $onlyInputVariables; } else { - $output = $this->variablesHandler->getVariable($dataToOutput); + if ($dataToOutput === 'custom-data') { + $output = $this->variablesHandler->replacePlaceholdersInText($customData); + } else { + $output = $this->variablesHandler->getVariable($dataToOutput); + } } // phpcs:ignore PublishPressStandards.Debug.DisallowDebugFunctions.FoundRayFunction diff --git a/src/Modules/Workflows/Domain/Engine/NodeRunners/Triggers/CoreOnPostUpdated.php b/src/Modules/Workflows/Domain/Engine/NodeRunners/Triggers/CoreOnPostUpdated.php index b79e1e388..7e2166385 100644 --- a/src/Modules/Workflows/Domain/Engine/NodeRunners/Triggers/CoreOnPostUpdated.php +++ b/src/Modules/Workflows/Domain/Engine/NodeRunners/Triggers/CoreOnPostUpdated.php @@ -112,7 +112,7 @@ function ($step, $postId, $postAfter, $postBefore) { $nodeSlug = $this->nodeRunnerProcessor->getSlugFromStep($step); $postQueryArgs = [ - 'post' => $postBefore, + 'post' => $postAfter, 'node' => $step['node'], ]; diff --git a/src/Modules/Workflows/Domain/Engine/RuntimeVariablesHandler.php b/src/Modules/Workflows/Domain/Engine/RuntimeVariablesHandler.php index c73f8e8fe..a45969b9d 100644 --- a/src/Modules/Workflows/Domain/Engine/RuntimeVariablesHandler.php +++ b/src/Modules/Workflows/Domain/Engine/RuntimeVariablesHandler.php @@ -86,11 +86,22 @@ private function getVariableValueFromNestedVariable(string $variableName, $dataS if (count($variableName) === 1) { return $this->getVariableValue($variableName[0], $dataSource); } else { - if (!isset($dataSource[$variableName[0]])) { + if (is_array($dataSource) && !isset($dataSource[$variableName[0]])) { return ''; } - $currentVariableSource = $dataSource[$variableName[0]]; + if (is_object($dataSource)) { + if (!isset($dataSource->{$variableName[0]})) { + return ''; + } + } + + if (is_array($dataSource)) { + $currentVariableSource = $dataSource[$variableName[0]]; + } else { + $currentVariableSource = $dataSource->{$variableName[0]}; + } + $variableName = array_slice($variableName, 1); return $this->getVariableValueFromNestedVariable( diff --git a/src/Modules/Workflows/Domain/Engine/VariableResolvers/PostMetaResolver.php b/src/Modules/Workflows/Domain/Engine/VariableResolvers/PostMetaResolver.php new file mode 100644 index 000000000..bfb23ffdb --- /dev/null +++ b/src/Modules/Workflows/Domain/Engine/VariableResolvers/PostMetaResolver.php @@ -0,0 +1,65 @@ +postId = $postId; + } + + public function getType(): string + { + return 'post_meta'; + } + + public function getValue(string $name = '') + { + return get_post_meta($this->postId, $name, true); + } + + public function getValueAsString(string $name = ''): string + { + return (string)$this->getValue($name); + } + + public function compact($name = ''): array + { + return $this->getValue($name); + } + + public function getVariable($name = '') + { + return $this->getValue($name); + } + + public function __isset($name): bool + { + return metadata_exists('post', $this->postId, $name); + } + + public function __get($name) + { + return $this->getValue($name); + } + + public function __set($name, $value): void + { + return; + } + + public function __unset($name): void + { + return; + } + + public function __toString(): string + { + return $this->getType(); + } +} diff --git a/src/Modules/Workflows/Domain/Engine/VariableResolvers/PostResolver.php b/src/Modules/Workflows/Domain/Engine/VariableResolvers/PostResolver.php index 25bc57624..7378a5104 100644 --- a/src/Modules/Workflows/Domain/Engine/VariableResolvers/PostResolver.php +++ b/src/Modules/Workflows/Domain/Engine/VariableResolvers/PostResolver.php @@ -84,6 +84,9 @@ public function getValue(string $property = '') case 'permalink': return $this->getPermalink($this->post->ID); + + case 'meta': + return new PostMetaResolver($this->post->ID); } return ''; @@ -130,7 +133,8 @@ public function __isset($name): bool 'post_status', 'post_date', 'post_modified', - 'permalink' + 'permalink', + 'meta', ] ); } diff --git a/src/Modules/Workflows/Domain/Engine/VariableResolvers/SiteMetaResolver.php b/src/Modules/Workflows/Domain/Engine/VariableResolvers/SiteMetaResolver.php new file mode 100644 index 000000000..7e942b8ff --- /dev/null +++ b/src/Modules/Workflows/Domain/Engine/VariableResolvers/SiteMetaResolver.php @@ -0,0 +1,65 @@ +siteId = $siteId; + } + + public function getType(): string + { + return 'site_meta'; + } + + public function getValue(string $name = '') + { + return get_post_meta($this->siteId, $name, true); + } + + public function getValueAsString(string $name = ''): string + { + return (string)$this->getValue($name); + } + + public function compact($name = ''): array + { + return $this->getValue($name); + } + + public function getVariable($name = '') + { + return $this->getValue($name); + } + + public function __isset($name): bool + { + return metadata_exists('site', $this->siteId, $name); + } + + public function __get($name) + { + return $this->getValue($name); + } + + public function __set($name, $value): void + { + return; + } + + public function __unset($name): void + { + return; + } + + public function __toString(): string + { + return $this->getType(); + } +} diff --git a/src/Modules/Workflows/Domain/Engine/VariableResolvers/SiteResolver.php b/src/Modules/Workflows/Domain/Engine/VariableResolvers/SiteResolver.php index ea43dd8a8..c29a0abdc 100644 --- a/src/Modules/Workflows/Domain/Engine/VariableResolvers/SiteResolver.php +++ b/src/Modules/Workflows/Domain/Engine/VariableResolvers/SiteResolver.php @@ -3,7 +3,6 @@ namespace PublishPress\Future\Modules\Workflows\Domain\Engine\VariableResolvers; use PublishPress\Future\Modules\Workflows\Interfaces\VariableResolverInterface; -use WP_Post; class SiteResolver implements VariableResolverInterface { @@ -19,6 +18,10 @@ public function getValue(string $propertyName = '') } switch ($propertyName) { + case 'id': + case 'ID': + return $this->getSiteId(); + case 'name': return $this->getSiteName(); @@ -33,6 +36,9 @@ public function getValue(string $propertyName = '') case 'admin_email': return $this->getAdminEmail(); + + case 'meta': + return new SiteMetaResolver($this->getSiteId()); } return ''; @@ -68,6 +74,11 @@ protected function getAdminEmail() return get_option('admin_email'); } + protected function getSiteId(): int + { + return get_current_blog_id(); + } + public function compact(): array { return [ @@ -86,26 +97,25 @@ public function getVariable() public function __isset($name): bool { - return in_array($name, ['name', 'description', 'url', 'home_url', 'admin_email']); + return in_array( + $name, + [ + 'id', + 'ID', + 'name', + 'description', + 'url', + 'home_url', + 'admin_email', + 'meta', + ] + ); } public function __get($name) { - switch ($name) { - case 'name': - return $this->getSiteName(); - - case 'description': - return $this->getSiteDescription(); - - case 'url': - return $this->getSiteUrl(); - - case 'home_url': - return $this->getHomeUrl(); - - case 'admin_email': - return $this->getAdminEmail(); + if (isset($this->$name)) { + return $this->getValue($name); } return null; diff --git a/src/Modules/Workflows/Domain/Engine/VariableResolvers/UserMetaResolver.php b/src/Modules/Workflows/Domain/Engine/VariableResolvers/UserMetaResolver.php new file mode 100644 index 000000000..b3f47a238 --- /dev/null +++ b/src/Modules/Workflows/Domain/Engine/VariableResolvers/UserMetaResolver.php @@ -0,0 +1,65 @@ +userId = $userId; + } + + public function getType(): string + { + return 'user_meta'; + } + + public function getValue(string $name = '') + { + return get_user_meta($this->userId, $name, true); + } + + public function getValueAsString(string $name = ''): string + { + return (string)$this->getValue($name); + } + + public function compact($name = ''): array + { + return $this->getValue($name); + } + + public function getVariable($name = '') + { + return $this->getValue($name); + } + + public function __isset($name): bool + { + return metadata_exists('user', $this->userId, $name); + } + + public function __get($name) + { + return $this->getValue($name); + } + + public function __set($name, $value): void + { + return; + } + + public function __unset($name): void + { + return; + } + + public function __toString(): string + { + return $this->getType(); + } +} diff --git a/src/Modules/Workflows/Domain/Engine/VariableResolvers/UserResolver.php b/src/Modules/Workflows/Domain/Engine/VariableResolvers/UserResolver.php index db4bae161..6883d9cee 100644 --- a/src/Modules/Workflows/Domain/Engine/VariableResolvers/UserResolver.php +++ b/src/Modules/Workflows/Domain/Engine/VariableResolvers/UserResolver.php @@ -61,6 +61,9 @@ public function getValue(string $property = '') case 'registered': return $this->user->user_registered; + + case 'meta': + return new UserMetaResolver($this->user->ID); } return ''; @@ -95,7 +98,20 @@ public function getVariable() public function __isset($name): bool { - return in_array($name, ['id', 'ID', 'user_login', 'user_email', 'roles', 'caps', 'display_name', 'registered']); + return in_array( + $name, + [ + 'id', + 'ID', + 'user_login', + 'user_email', + 'roles', + 'caps', + 'display_name', + 'registered', + 'meta', + ] + ); } public function __get($name) diff --git a/src/Modules/Workflows/Domain/Engine/VariableResolvers/WorkflowMetaResolver.php b/src/Modules/Workflows/Domain/Engine/VariableResolvers/WorkflowMetaResolver.php new file mode 100644 index 000000000..a68127675 --- /dev/null +++ b/src/Modules/Workflows/Domain/Engine/VariableResolvers/WorkflowMetaResolver.php @@ -0,0 +1,65 @@ +workflowId = $workflowId; + } + + public function getType(): string + { + return 'workflow_meta'; + } + + public function getValue(string $name = '') + { + return get_post_meta($this->workflowId, $name, true); + } + + public function getValueAsString(string $name = ''): string + { + return (string)$this->getValue($name); + } + + public function compact($name = ''): array + { + return $this->getValue($name); + } + + public function getVariable($name = '') + { + return $this->getValue($name); + } + + public function __isset($name): bool + { + return metadata_exists('post', $this->workflowId, $name); + } + + public function __get($name) + { + return $this->getValue($name); + } + + public function __set($name, $value): void + { + return; + } + + public function __unset($name): void + { + return; + } + + public function __toString(): string + { + return $this->getType(); + } +} diff --git a/src/Modules/Workflows/Domain/Engine/VariableResolvers/WorkflowResolver.php b/src/Modules/Workflows/Domain/Engine/VariableResolvers/WorkflowResolver.php index 11abcb780..2a9cae9ee 100644 --- a/src/Modules/Workflows/Domain/Engine/VariableResolvers/WorkflowResolver.php +++ b/src/Modules/Workflows/Domain/Engine/VariableResolvers/WorkflowResolver.php @@ -46,6 +46,9 @@ public function getValue(string $property = '') case 'steps': return (array)$this->workflow['steps']; + + case 'meta': + return new WorkflowMetaResolver($this->workflow['ID']); } return ''; @@ -74,7 +77,18 @@ public function getVariable() public function __isset($name): bool { - return in_array($name, ['id', 'ID', 'title', 'description', 'modified_at', 'steps']); + return in_array( + $name, + [ + 'id', + 'ID', + 'title', + 'description', + 'modified_at', + 'steps', + 'meta', + ] + ); } public function __get($name) diff --git a/src/Modules/Workflows/Domain/Engine/WorkflowEngine.php b/src/Modules/Workflows/Domain/Engine/WorkflowEngine.php index c5b21a7d2..fade9265a 100644 --- a/src/Modules/Workflows/Domain/Engine/WorkflowEngine.php +++ b/src/Modules/Workflows/Domain/Engine/WorkflowEngine.php @@ -169,6 +169,7 @@ public function start() 'steps' => $workflow->getNodes(), ] ), + 'execution_id' => $this->getExecutionId(), ]; foreach ($triggerNodes as $triggerNode) { @@ -176,6 +177,10 @@ public function start() $triggerId = $triggerNode['id']; $nodeType = $this->nodeTypesModel->getNodeType($triggerName); + if (! $nodeType) { + continue; + } + /** @var NodeRunnerInterface $triggerRunner */ $triggerRunner = call_user_func($this->nodeRunnerFactory, $triggerName); @@ -394,4 +399,9 @@ private function getContext(): string return 'frontend'; } + + private function getExecutionId(): string + { + return wp_generate_uuid4(); + } } diff --git a/src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php b/src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php index fde1989d5..f954db416 100644 --- a/src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php +++ b/src/Modules/Workflows/Domain/NodeTypes/Actions/CoreSendEmail.php @@ -81,10 +81,13 @@ public function getSettingsSchema(): array "name" => "recipient", "type" => "emailRecipient", "label" => __("Recipient", "post-expirator"), + "default" => [ + "recipient" => "global.site.admin_email", + ], ], [ "name" => "subject", - "type" => "text", + "type" => "textarea", "label" => __("Subject", "post-expirator"), "settings" => [ "placeholder" => self::getDefaultSubject(), diff --git a/src/Modules/Workflows/Domain/NodeTypes/Advanced/CorePostQuery.php b/src/Modules/Workflows/Domain/NodeTypes/Advanced/CorePostQuery.php index 5fabc5e87..50e5076b1 100644 --- a/src/Modules/Workflows/Domain/NodeTypes/Advanced/CorePostQuery.php +++ b/src/Modules/Workflows/Domain/NodeTypes/Advanced/CorePostQuery.php @@ -80,6 +80,9 @@ public function getSettingsSchema(): array "postId" => [], "postStatus" => [], ], + "settings" => [ + "isPostTypeRequired" => true, + ], ], ] ] diff --git a/src/Modules/Workflows/Domain/NodeTypes/Advanced/LogAdd.php b/src/Modules/Workflows/Domain/NodeTypes/Advanced/LogAdd.php index 201417cf1..f80c4d853 100644 --- a/src/Modules/Workflows/Domain/NodeTypes/Advanced/LogAdd.php +++ b/src/Modules/Workflows/Domain/NodeTypes/Advanced/LogAdd.php @@ -66,7 +66,7 @@ public function getSettingsSchema(): array "fields" => [ [ "name" => "message", - "type" => "text", + "type" => "textarea", "label" => __("Message", "post-expirator"), ], [ diff --git a/src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnPostUpdated.php b/src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnPostUpdated.php index 4a50d8172..a703e408c 100644 --- a/src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnPostUpdated.php +++ b/src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnPostUpdated.php @@ -78,6 +78,7 @@ public function getSettingsSchema(): array ), "settings" => [ "acceptsInput" => false, + "isPostTypeRequired" => true, ], "default" => [ "postSource" => "custom", diff --git a/src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnSavePost.php b/src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnSavePost.php index 546ab5e84..fb584dfa3 100644 --- a/src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnSavePost.php +++ b/src/Modules/Workflows/Domain/NodeTypes/Triggers/CoreOnSavePost.php @@ -81,6 +81,7 @@ public function getSettingsSchema(): array ), "settings" => [ "acceptsInput" => false, + "isPostTypeRequired" => true, ], "default" => [ "postSource" => "custom", diff --git a/src/Modules/Workflows/Models/ScheduledActionsModel.php b/src/Modules/Workflows/Models/ScheduledActionsModel.php index f0cf0e13a..742682443 100644 --- a/src/Modules/Workflows/Models/ScheduledActionsModel.php +++ b/src/Modules/Workflows/Models/ScheduledActionsModel.php @@ -28,7 +28,11 @@ public function deleteOrphanWorkflowArgs(): void // phpcs:ignore WordPress.DB.DirectDatabaseQuery.NoCaching $wpdb->query( $wpdb->prepare( - "DELETE FROM %i AS ssa WHERE ssa.action_id NOT IN (SELECT asa.action_id FROM %i AS asa)", + "DELETE FROM %i AS scheduled_steps + WHERE NOT EXISTS( + SELECT 1 FROM %i AS scheduler_actions + WHERE scheduled_steps.action_id = scheduler_actions.action_id + )", $tableSchema->getTableName(), $wpdb->prefix . 'actionscheduler_actions' ) diff --git a/src/Modules/Workflows/Models/WorkflowModel.php b/src/Modules/Workflows/Models/WorkflowModel.php index de19fe921..31960d05d 100644 --- a/src/Modules/Workflows/Models/WorkflowModel.php +++ b/src/Modules/Workflows/Models/WorkflowModel.php @@ -12,6 +12,7 @@ use PublishPress\Future\Modules\Workflows\Domain\NodeTypes\Triggers\CoreOnManuallyEnabledForPost; use PublishPress\Future\Modules\Workflows\Domain\NodeTypes\Triggers\FutureLegacyAction; use PublishPress\Future\Modules\Workflows\HooksAbstract as WorkflowsHooksAbstract; +use PublishPress\Future\Modules\Settings\SettingsFacade; use WP_Post; use WP_Query; @@ -72,6 +73,11 @@ class WorkflowModel implements WorkflowModelInterface */ private $logger; + /** + * @var SettingsFacade + */ + private $settingsFacade; + public function __construct() { $container = Container::getInstance(); @@ -80,6 +86,7 @@ public function __construct() $this->hooks = $container->get(ServicesAbstract::HOOKS); $this->nodeTypesModel = $container->get(ServicesAbstract::NODE_TYPES_MODEL); $this->logger = $container->get(ServicesAbstract::LOGGER); + $this->settingsFacade = $container->get(ServicesAbstract::SETTINGS); } public function load(int $id): bool @@ -510,6 +517,10 @@ public function convertLegacyScreenshots(): void return; } + if (! $this->settingsFacade->getWorkflowScreenshotStatus()) { + return; + } + $existingScreenshotId = get_post_thumbnail_id($this->post->ID); if ($existingScreenshotId) { @@ -536,6 +547,10 @@ private function createScreenshotThumbnails($screenshotFile) return; } + if (! $this->settingsFacade->getWorkflowScreenshotStatus()) { + return; + } + if (! function_exists('image_make_intermediate_size')) { require_once ABSPATH . 'wp-admin/includes/image.php'; } @@ -582,6 +597,10 @@ public function setScreenshotFromBase64(string $dataImage) return; } + if (! $this->settingsFacade->getWorkflowScreenshotStatus()) { + return; + } + $this->deleteLegacyScreenshotFile(); $this->prepareScreenshotsFolder(); $this->deleteScreenshotFile(); @@ -615,6 +634,10 @@ public function setScreenshotFromBase64(string $dataImage) public function setScreenshotFromFile(string $filePath) { + if (! $this->settingsFacade->getWorkflowScreenshotStatus()) { + return; + } + // phpcs:ignore WordPressVIPMinimum.Performance.FetchingRemoteData.FileGetContentsUnknown $dataImage = 'data:image/png;base64,' . base64_encode(file_get_contents($filePath)); @@ -627,6 +650,10 @@ public function getScreenshotUrl($size = 'full'): string return ''; } + if (! $this->settingsFacade->getWorkflowScreenshotStatus()) { + return ''; + } + $screenshotDir = $this->getScreenshotsFolder(); $screenshotFile = $screenshotDir . $this->getScreenshotFileName(); diff --git a/src/Modules/Workflows/Models/WorkflowsModel.php b/src/Modules/Workflows/Models/WorkflowsModel.php index 6eb74b2a9..43f3fbddb 100644 --- a/src/Modules/Workflows/Models/WorkflowsModel.php +++ b/src/Modules/Workflows/Models/WorkflowsModel.php @@ -25,6 +25,20 @@ public function getPublishedWorkflowsIds($limit = -1): array return $query->posts; } + public function getAllWorkflowsIds(): array + { + $args = [ + 'post_type' => Module::POST_TYPE_WORKFLOW, + 'post_status' => 'any', + 'posts_per_page' => -1, + 'fields' => 'ids', + ]; + + $query = new WP_Query($args); + + return $query->posts; + } + public function getPublishedWorkflowsWithLegacyTriggerAsOptions(): array { return $this->getPublishedWorkflowsWithMetadataAsOptions(WorkflowModel::META_KEY_HAS_LEGACY_TRIGGER, 1); diff --git a/src/Modules/Workflows/Module.php b/src/Modules/Workflows/Module.php index 0cd862636..a39b9585d 100644 --- a/src/Modules/Workflows/Module.php +++ b/src/Modules/Workflows/Module.php @@ -116,7 +116,8 @@ private function initializeControllers() new Controllers\WorkflowsList( $this->hooks, $this->nodeTypesModel, - $this->logger + $this->logger, + $this->settingsFacade ), new Controllers\WorkflowEditor( $this->hooks, diff --git a/src/Modules/Workflows/Rest/RestApiManager.php b/src/Modules/Workflows/Rest/RestApiManager.php index f10742c15..6ec69cec0 100644 --- a/src/Modules/Workflows/Rest/RestApiManager.php +++ b/src/Modules/Workflows/Rest/RestApiManager.php @@ -2,16 +2,29 @@ namespace PublishPress\Future\Modules\Workflows\Rest; +use PublishPress\Future\Modules\Settings\SettingsFacade; use PublishPress\Future\Modules\Workflows\Interfaces\RestApiManagerInterface; class RestApiManager implements RestApiManagerInterface { public const API_BASE = 'publishpress-future'; + /** + * @var SettingsFacade + */ + private SettingsFacade $settingsFacade; + + public function __construct(SettingsFacade $settingsFacade) + { + $this->settingsFacade = $settingsFacade; + } + public function register() { $apiManagers = [ - new RestApiV1() + new RestApiV1( + $this->settingsFacade + ) ]; foreach ($apiManagers as $apiManater) { diff --git a/src/Modules/Workflows/Rest/RestApiV1.php b/src/Modules/Workflows/Rest/RestApiV1.php index 29ca96267..120cd5f41 100644 --- a/src/Modules/Workflows/Rest/RestApiV1.php +++ b/src/Modules/Workflows/Rest/RestApiV1.php @@ -2,12 +2,12 @@ namespace PublishPress\Future\Modules\Workflows\Rest; +use PublishPress\Future\Modules\Settings\SettingsFacade; use WP_Error; use WP_REST_Server; use PublishPress\Future\Modules\Workflows\Interfaces\RestApiManagerInterface; use PublishPress\Future\Modules\Workflows\Models\PostModel; use PublishPress\Future\Modules\Workflows\Models\WorkflowModel; -use PublishPress\Future\Modules\Workflows\Models\WorkflowsModel; class RestApiV1 implements RestApiManagerInterface { @@ -23,6 +23,16 @@ class RestApiV1 implements RestApiManagerInterface public const PERMISSION_DELETE = 'edit_posts'; + /** + * @var SettingsFacade + */ + private SettingsFacade $settingsFacade; + + public function __construct(SettingsFacade $settingsFacade) + { + $this->settingsFacade = $settingsFacade; + } + public function register() { // Read a single workflow @@ -214,7 +224,7 @@ public function updateWorkflow($request) $workflowModel->setStatus($request['status']); } - if (isset($request['screenshot'])) { + if (isset($request['screenshot']) && $this->settingsFacade->getWorkflowScreenshotStatus()) { $workflowModel->setScreenshotFromBase64($request['screenshot']); } diff --git a/src/Views/menu-advanced.php b/src/Views/menu-advanced.php index fb9da968a..4e29eb6eb 100644 --- a/src/Views/menu-advanced.php +++ b/src/Views/menu-advanced.php @@ -9,13 +9,13 @@ // phpcs:disable Generic.Files.LineLength.TooLong // Get Option -$preserveData = (bool)get_option('expirationdatePreserveData', true); -$plugin_facade = PostExpirator_Facade::getInstance(); $container = DIContainer::getInstance(); $hooks = $container->get(ServicesAbstract::HOOKS); $settingsFacade = $container->get(ServicesAbstract::SETTINGS); +$preserveData = $settingsFacade->getSettingPreserveData(); + ?>
diff --git a/src/Views/menu-display.php b/src/Views/menu-display.php index c9ac7a24a..7854e2356 100644 --- a/src/Views/menu-display.php +++ b/src/Views/menu-display.php @@ -9,24 +9,22 @@ $container = Container::getInstance(); $hooks = $container->get(ServicesAbstract::HOOKS); - +$settingsFacade = $container->get(ServicesAbstract::SETTINGS); // phpcs:disable WordPress.NamingConventions.ValidVariableName.InterpolatedVariableNotSnakeCase // phpcs:disable WordPress.PHP.StrictComparisons.LooseComparison -$expireddisplayfooter = get_option('expirationdateDisplayFooter', POSTEXPIRATOR_FOOTERDISPLAY); -$expireddisplayfooterenabled = ''; -$expireddisplayfooterdisabled = ''; -if ($expireddisplayfooter == 0) { - $expireddisplayfooterdisabled = 'checked="checked"'; -} elseif ($expireddisplayfooter == 1) { - $expireddisplayfooterenabled = 'checked="checked"'; -} +$expireddisplayfooter = $settingsFacade->getShowInPostFooter(); +$expirationdateFooterContents = $settingsFacade->getFooterContents(); +$expirationdateFooterStyle = $settingsFacade->getFooterStyle(); + +$expirationdateDefaultDateFormat = $settingsFacade->getDefaultDateFormat(); +$expirationdateDefaultTimeFormat = $settingsFacade->getDefaultTimeFormat(); -$expirationdateFooterContents = get_option('expirationdateFooterContents', POSTEXPIRATOR_FOOTERCONTENTS); -$expirationdateFooterStyle = get_option('expirationdateFooterStyle', POSTEXPIRATOR_FOOTERSTYLE); +$metaboxTitle = $settingsFacade->getMetaboxTitle(); +$metaboxCheckboxLabel = $settingsFacade->getMetaboxCheckboxLabel(); -$expirationdateDefaultDateFormat = get_option('expirationdateDefaultDateFormat', POSTEXPIRATOR_DATEFORMAT); -$expirationdateDefaultTimeFormat = get_option('expirationdateDefaultTimeFormat', POSTEXPIRATOR_TIMEFORMAT); +$timeFormat = $settingsFacade->getTimeFormatForDatePicker(); +$columnStyle = $settingsFacade->getColumnStyle(); ?>
@@ -38,13 +36,24 @@

- + - + + ( + + ) +

+ ' . esc_html__('PHP Date Function', 'post-expirator') . '' + ); ?> +

+
+ + - () -

" + size="25" + /> ( + + ) +

+ ' . esc_html__('PHP Date Function', 'post-expirator') . '' - ); ?>

+ ); ?> +

+ + - () -

' . esc_html__('PHP Date Function', 'post-expirator') . '' - ); ?>

-
+

+ esc_html_e('Metabox', 'post-expirator'); ?> + + + + + + + + + + + +
+ + + +

+ +

+
+ + + +

+ +

+
+ +
+ +

- +
+ + - get(ServicesAbstract::SETTINGS)->getColumnStyle(); - ?>
/> - -

+ echo $columnStyle === 'verbose' ? 'checked' : ''; ?> /> + +

+ +

/> + echo $columnStyle === 'simple' ? 'checked' : ''; ?> /> -

+ esc_html_e('Simplified', 'post-expirator'); ?> +

+ +

-
+

+ esc_html_e('Future Actions Editor', 'post-expirator'); ?> - +
+ + - get(ServicesAbstract::SETTINGS)->getTimeFormatForDatePicker(); - ?>
- /> - + value="inherited" + /> +
- /> - + value="24h" + /> +
- /> - + value="12h" + /> +
-
+

-

+

+ ); ?> +

- + - + - +
+ +
- /> + /> +
- /> + /> +
-

+

+ +

+ + - -

+ +

+ +

    -
  • ACTIONFULL ->

  • -
  • ACTIONDATE ->

  • -
  • ACTIONTIME ->

  • +
  • +

    + ACTIONFULL -> + +

    +
  • +
  • +

    + ACTIONDATE -> + +

    +
  • +
  • +

    + ACTIONTIME -> + +

    +
+ + - -

+ +

+ +


-
applyFilters(ExpiratorHooksAbstract::FILTER_CONTENT_FOOTER, '', true)); ?>
+
+ applyFilters(ExpiratorHooksAbstract::FILTER_CONTENT_FOOTER, '', true)); ?> +
-
+

@@ -239,33 +364,43 @@ // translators: %s is the shortcode code wrapped in code tags echo sprintf(esc_html__('Valid %s attributes:', 'post-expirator'), '[futureaction]'); ?>

    -
  • ', - '' - ); ?>

  • -
  • dateformat' - ); ?>

  • -
  • timeformat' - ); ?>

  • +
  • +

    ', + '' + ); ?>

    +
  • +
  • +

    dateformat' + ); ?>

    +
  • +
  • +

    timeformat' + ); ?>

    +

- +

diff --git a/src/Views/menu-general.php b/src/Views/menu-general.php index 5c9decae5..1362e7e1e 100644 --- a/src/Views/menu-general.php +++ b/src/Views/menu-general.php @@ -1,56 +1,27 @@ get(ServicesAbstract::SETTINGS); -$container = \PublishPress\Future\Core\DI\Container::getInstance(); -$settingsFacade = $container->get(\PublishPress\Future\Core\DI\ServicesAbstract::SETTINGS); +// phpcs:disable Generic.Files.LineLength.TooLong +$expirationdateDefaultDateFormat = $settingsFacade->getDefaultDateFormat(); +$expirationdateDefaultTimeFormat = $settingsFacade->getDefaultTimeFormat(); $expirationdateDefaultDateCustom = $settingsFacade->getGeneralDateTimeOffset(); +$preserveData = $settingsFacade->getSettingPreserveData(); +$expireddisplayfooter = $settingsFacade->getShowInPostFooter(); +$expirationdateFooterContents = $settingsFacade->getFooterContents(); +$expirationdateFooterStyle = $settingsFacade->getFooterStyle(); -$categories = get_option('expirationdateCategoryDefaults'); - -$preserveData = (bool)get_option('expirationdatePreserveData', true); - -$expireddisplayfooter = get_option('expirationdateDisplayFooter', POSTEXPIRATOR_FOOTERDISPLAY); -$expireddisplayfooterenabled = ''; -$expireddisplayfooterdisabled = ''; -if ($expireddisplayfooter == 0) { - $expireddisplayfooterdisabled = 'checked="checked"'; -} elseif ($expireddisplayfooter == 1) { - $expireddisplayfooterenabled = 'checked="checked"'; -} -$expirationdateFooterContents = get_option('expirationdateFooterContents', POSTEXPIRATOR_FOOTERCONTENTS); -$expirationdateFooterStyle = get_option('expirationdateFooterStyle', POSTEXPIRATOR_FOOTERSTYLE); - -$expiredemailnotificationenabled = ''; -$expiredemailnotificationdisabled = ''; -if ($expiredemailnotification == 0) { - $expiredemailnotificationdisabled = 'checked="checked"'; -} elseif ($expiredemailnotification == 1) { - $expiredemailnotificationenabled = 'checked="checked"'; -} +$expireddisplayfooterenabled = $expireddisplayfooter ? '' : 'checked="checked"'; +$expireddisplayfooterdisabled = $expireddisplayfooter ? 'checked="checked"' : ''; -$expiredemailnotificationadminsenabled = ''; -$expiredemailnotificationadminsdisabled = ''; -if ($expiredemailnotificationadmins == 0) { - $expiredemailnotificationadminsdisabled = 'checked="checked"'; -} elseif ($expiredemailnotificationadmins == 1) { - $expiredemailnotificationadminsenabled = 'checked="checked"'; -} - -$calendarHiddenByDefault = (bool) get_option('expirationdateHideCalendarByDefault', false); +$calendarHiddenByDefault = $settingsFacade->getHideCalendarByDefault(); +$workflowScreenshotStatus = $settingsFacade->getWorkflowScreenshotStatus(); $user_roles = wp_roles()->get_names(); $plugin_facade = PostExpirator_Facade::getInstance(); @@ -109,6 +80,41 @@

+ + + + + + +
+ + /> + +
+

+
+ + /> + +
+

+ +

checked="checked" /> - + - -

-

- - - - - - - - - - - - - -
-
- /> -
-
- /> -
-

-
-
- /> -
-
- /> -
-

-
- - -

-
-

+

+
+
+ + +

+

+ + + + + + + + + + + + + +
+
+ /> +
+
+ /> +
+

+
+
+ /> +
+
+ /> +
+

+
+ + +

+
+ +

+ +

+
+
+ + +
+ 'general', 'link' => admin_url($baseLink . 'general'), ], + [ + 'title' => __('Notifications', 'post-expirator'), + 'slug' => 'notifications', + 'link' => admin_url($baseLink . 'notifications'), + ], [ 'title' => __('Display', 'post-expirator'), 'slug' => 'display', diff --git a/webpack.config.js b/webpack.config.js index 29a8d9bea..1da5bc915 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -18,7 +18,8 @@ module.exports = { workflowManualSelectionQuickEdit: "./assets/jsx/workflow-manual-selection/quick-edit/index.jsx", workflowManualSelectionClassicEditor: "./assets/jsx/workflow-manual-selection/classic-editor/index.jsx", workflowManualSelectionBlockEditor: "./assets/jsx/workflow-manual-selection/block-editor/index.jsx", - futureActions: "./assets/jsx/future-actions.jsx" + futureActions: "./assets/jsx/future-actions.jsx", + backupPanel: "./assets/jsx/backup-panel/index.jsx" }, output: { path: path.join(__dirname, "assets", "js"), diff --git a/yarn.lock b/yarn.lock index 5be20c518..e4b5bc8a7 100644 --- a/yarn.lock +++ b/yarn.lock @@ -5374,6 +5374,11 @@ cookie@^0.4.1: resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.4.2.tgz#0e41f24de5ecf317947c82fc789e06a884824432" integrity sha512-aSWTXFzaKWkvHO1Ny/s+ePFpvKsPnjc551iI41v3ny/ow6tBG5Vd+FuqGNhh1LxOmVzOlGUriIlOaokOvhaStA== +cookie@^0.7.0: + version "0.7.2" + resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.7.2.tgz#556369c472a2ba910f2979891b526b3436237ed7" + integrity sha512-yki5XnKuf750l50uGTllt6kKILY4nQ1eNIQatoXEByZ5dWgnKqbnqmTrBE5B4N7lrMJKQ2ytWMiTO2o0v6Ew/w== + copy-descriptor@^0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/copy-descriptor/-/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d" @@ -5496,6 +5501,15 @@ cross-spawn@^7.0.2, cross-spawn@^7.0.3: shebang-command "^2.0.0" which "^2.0.1" +cross-spawn@^7.0.5: + version "7.0.6" + resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-7.0.6.tgz#8a58fe78f00dcd70c370451759dfbfaf03e8ee9f" + integrity sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA== + dependencies: + path-key "^3.1.0" + shebang-command "^2.0.0" + which "^2.0.1" + crypt@0.0.2: version "0.0.2" resolved "https://registry.yarnpkg.com/crypt/-/crypt-0.0.2.tgz#88d7ff7ec0dfb86f713dc87bbb42d044d3e6c41b" @@ -9645,7 +9659,7 @@ micromatch@^3.1.10: snapdragon "^0.8.1" to-regex "^3.0.2" -micromatch@^4.0.2, micromatch@^4.0.4, micromatch@^4.0.5: +micromatch@^4.0.2, micromatch@^4.0.4, micromatch@^4.0.5, micromatch@^4.0.8: version "4.0.8" resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-4.0.8.tgz#d66fa18f3a47076789320b9b1af32bd86d9fa202" integrity sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA== @@ -9903,7 +9917,7 @@ node-fetch@^1.0.1: encoding "^0.1.11" is-stream "^1.0.1" -node-fetch@^2.6.12: +node-fetch@^2.6.12, node-fetch@^2.7.0: version "2.7.0" resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.7.0.tgz#d0f0fa6e3e2dc1d27efcd8ad99d550bda94d187d" integrity sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==