403Webshell
Server IP : 104.21.14.103  /  Your IP : 3.133.154.2
Web Server : LiteSpeed
System : Linux business53.web-hosting.com 4.18.0-553.lve.el8.x86_64 #1 SMP Mon May 27 15:27:34 UTC 2024 x86_64
User : giankuin ( 1871)
PHP Version : 7.4.33
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /proc/self/root/proc/thread-self/root/proc/thread-self/root/home/giankuin/thietke365.net/wp-content/plugins/mailpoet/assets/dist/js/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /proc/self/root/proc/thread-self/root/proc/thread-self/root/home/giankuin/thietke365.net/wp-content/plugins/mailpoet/assets/dist/js//automation.js
"use strict";(globalThis.webpackChunk=globalThis.webpackChunk||[]).push([[916],{43845:(t,e,a)=>{var o={};a.r(o),a.d(o,{deleteAutomation:()=>M,duplicateAutomation:()=>Z,loadAutomations:()=>O,restoreAutomation:()=>P,trashAutomation:()=>U});var i={};a.r(i),a.d(i,{getAutomationCount:()=>H,getAutomations:()=>L});var n=a(70079),s=a(99581),l=a(26952),r=a(33014),u=a(93850),m=a(59216),c=a(10159),d=a(83201),p=a(16184);const h="mailpoet/automation-listing";var _=a(8263),g=a(81433),x=a(710);function j(t,e){switch(e.type){case"SET_AUTOMATIONS":return{...t,automations:e.automations};case"ADD_AUTOMATION":return{...t,automations:[e.automation,...t.automations]};case"UPDATE_AUTOMATION":return{...t,automations:t.automations.map((t=>t.id===e.automation.id?e.automation:t))};case"DELETE_AUTOMATION":return{...t,automations:t.automations.filter((t=>t.id!==e.automation.id))};default:return t}}var b=a(7936),y=a(46824),f=a(8131),v=a(3939),A=a(15312),T=a(17816),w=a(35250);function N(t){let{automation:e,label:a}=t;return(0,w.jsx)(v.ZP,{variant:"link",href:(0,A.f)(T.x.urls.automationEditor,{id:e.id}),children:a??(0,b.__)("Edit","mailpoet")})}var k=a(48405);function S(t){let{automation:e,previousStatus:a}=t;const{restoreAutomation:o}=(0,k.Z)(h);return(0,w.jsx)(v.ZP,{variant:"link",onClick:()=>o(e,a),children:(0,b.__)("Undo","mailpoet")})}const E=(t,e)=>(0,g.dispatch)(y.h).createSuccessNotice(t,e),C=t=>(0,g.dispatch)(y.h).removeNotice(t);function*O(){return{type:"SET_AUTOMATIONS",automations:(yield(0,x.apiFetch)({path:"/automations"})).data}}function*Z(t){const e=yield(0,x.apiFetch)({path:`/automations/${t.id}/duplicate`,method:"POST"});return E((0,b.sprintf)((0,b.__)('Automation "%s" was duplicated.',"mailpoet"),t.name)),{type:"ADD_AUTOMATION",automation:e.data}}function*U(t){const e=yield(0,x.apiFetch)({path:`/automations/${t.id}`,method:"PUT",data:{status:f.b.TRASH}}),a=(0,b.__)("1 automation moved to the Trash.","mailpoet");return E(a,{id:`automation-trashed-${t.id}`,__unstableHTML:(0,w.jsxs)("p",{children:[a," ",(0,w.jsx)(S,{automation:t,previousStatus:t.status})]})}),{type:"UPDATE_AUTOMATION",automation:e.data}}function*P(t,e){const a=yield(0,x.apiFetch)({path:`/automations/${t.id}`,method:"PUT",data:{status:e}});C(`automation-trashed-${t.id}`);const o=(0,b.__)("1 automation restored from the Trash.","mailpoet");return E(o,{__unstableHTML:(0,w.jsxs)("p",{children:[o," ",(0,w.jsx)(N,{automation:t,label:(0,b.__)("Edit automation","mailpoet")})]})}),{type:"UPDATE_AUTOMATION",automation:a.data}}function*M(t){return yield(0,x.apiFetch)({path:`/automations/${t.id}`,method:"DELETE"}),E((0,b.__)("1 automation and all associated data permanently deleted.","mailpoet")),{type:"DELETE_AUTOMATION",automation:t}}var D=a(42163);function L(t){return t.automations}function H(t){return t.automations?t.automations.length:D.automationCount}var I=a(41475),R=a(16951),F=a(92893),$=a(59040),B=a(73478),q=a(66510),z=a(74457),Q=a(67507);const V=t=>{const[e,a]=(0,n.useState)(!1),{deleteAutomation:o}=(0,k.Z)(h);if(t.status===f.b.TRASH)return{key:"delete",control:{title:(0,b.__)("Delete permanently","mailpoet"),icon:null,onClick:()=>a(!0)},slot:(0,w.jsx)(Q.Z,{isOpen:e,title:(0,b.__)("Permanently delete automation","mailpoet"),confirmButtonText:(0,b.__)("Yes, permanently delete","mailpoet"),__experimentalHideHeader:!1,onConfirm:()=>o(t),onCancel:()=>a(!1),children:(0,b.sprintf)((0,b.__)('Are you sure you want to permanently delete "%s" and all associated data? This cannot be undone!',"mailpoet"),t.name)})}},Y=t=>{const{restoreAutomation:e}=(0,k.Z)(h);if(t.status===f.b.TRASH)return{key:"restore",control:{title:(0,b.__)("Restore","mailpoet"),icon:null,onClick:()=>e(t,f.b.DRAFT)}}},K=t=>{const[e,a]=(0,n.useState)(!1),{trashAutomation:o}=(0,k.Z)(h);if(t.status!==f.b.TRASH)return{key:"trash",control:{title:(0,b._x)("Trash","verb","mailpoet"),icon:null,onClick:()=>a(!0)},slot:(0,w.jsx)(Q.Z,{isOpen:e,title:(0,b.__)("Trash automation","mailpoet"),confirmButtonText:(0,b.__)("Yes, move to trash","mailpoet"),__experimentalHideHeader:!1,onConfirm:()=>o(t),onCancel:()=>a(!1),children:(0,b.sprintf)((0,b.__)('Are you sure you want to move the automation "%s" to the Trash?',"mailpoet"),t.name)})}};function W(t){let{automation:e,label:a}=t;return(0,w.jsx)(v.ZP,{variant:"link",href:(0,A.f)(T.x.urls.automationAnalytics,{id:e.id}),children:a??(0,b.__)("Analytics","mailpoet")})}function G(t){let{automation:e}=t;const a=[K(e),Y(e),V(e)].filter((t=>t));return(0,w.jsxs)("div",{className:"mailpoet-automation-listing-cell-actions",children:[(0,w.jsx)(W,{automation:e}),(0,w.jsx)(N,{automation:e}),a.map((t=>{let{control:e,slot:a}=t;return(0,w.jsx)(n.Fragment,{children:a},e.title)})),(0,w.jsx)(q.Z,{className:"mailpoet-automation-listing-more-button",label:(0,b.__)("More","mailpoet"),icon:z.Z,controls:a.map((t=>{let{control:e}=t;return e})),popoverProps:{position:"bottom left"}})]})}function J(t){let{automation:e}=t;return(0,w.jsx)(N,{automation:e,label:e.name})}function X(t){let{automation:e}=t;return(0,w.jsx)("div",{className:"mailpoet-automation-listing-cell-status",children:e.status===f.b.ACTIVE?(0,b.__)("Active","mailpoet"):(0,b.__)("Draft","mailpoet")})}var tt=a(80909);function et(t){let{automation:e}=t;return(0,w.jsx)(tt.g,{labelPosition:"after",items:[{key:"entered",label:(0,b._x)("Entered","automation stats","mailpoet"),value:e.stats.totals.entered},{key:"processing",label:(0,b._x)("Processing","automation stats","mailpoet"),value:e.stats.totals.in_progress},{key:"exited",label:(0,b._x)("Exited","automation stats","mailpoet"),value:e.stats.totals.exited}]})}const at=[{name:"all",title:(0,b.__)("All","mailpoet"),className:"mailpoet-tab-all"},{name:f.b.ACTIVE,title:(0,b.__)("Active","mailpoet"),className:"mailpoet-tab-active"},{name:f.b.DRAFT,title:(0,b._x)("Draft","noun","mailpoet"),className:"mailpoet-tab-draft"},{name:f.b.TRASH,title:(0,b._x)("Trash","noun","mailpoet"),className:"mailpoet-tab-trash"}],ot=[{key:"name",label:(0,b.__)("Name","mailpoet"),cellClassName:"mailpoet-automation-listing-cell-name"},{key:"subscribers",label:(0,b.__)("Subscribers","mailpoet")},{key:"status",label:(0,b.__)("Status","mailpoet")},{key:"actions"}];function it(){return(0,w.jsxs)(R.Z,{className:"mailpoet-automation-listing-heading",children:[(0,w.jsx)("h1",{className:"wp-heading-inline",children:(0,b.__)("Automations","mailpoet")}),(0,w.jsx)(v.ZP,{href:T.x.urls.automationTemplates,icon:B.R,variant:"primary",className:"mailpoet-add-new-button",children:(0,b.__)("New automation","mailpoet")})]})}function nt(){const t=(0,$.k6)(),e=(0,$.TH)(),a=(0,n.useMemo)((()=>new URLSearchParams(e.search)),[e]),o=(0,c.Z)((t=>t(h).getAutomations())),{loadAutomations:i}=(0,k.Z)(h),s=a.get("status");(0,n.useEffect)((()=>{i()}),[i]),(0,n.useLayoutEffect)((()=>{var t;s&&(null===(t=document.querySelector(`.mailpoet-tab-${s}`))||void 0===t||t.focus())}),[s]);const l=(0,n.useCallback)((e=>{const o=new URLSearchParams({...Object.fromEntries(a.entries()),...e}),i=Object.keys(e);(i.includes("status")||i.includes("per_page")||"1"===o.get("paged"))&&o.delete("paged"),t.push({search:o.toString()})}),[a,t]),r=(0,n.useMemo)((()=>{const t={all:[]};return(o??[]).forEach((e=>{t[e.status]||(t[e.status]=[]),t[e.status].push(e),e.status!==f.b.TRASH&&t.all.push(e)})),t}),[o]),u=(0,n.useMemo)((()=>at.map((t=>{const e=(r[t.name]??[]).length;return{name:t.name,title:(0,w.jsxs)(w.Fragment,{children:[(0,w.jsx)("span",{children:t.title}),e>0&&(0,w.jsx)("span",{className:"count",children:e})]}),className:t.className}}))),[r]),m=(0,n.useCallback)((t=>{const e=r[t.name]??[],i=parseInt(a.get("per_page")??"25",10),n=(parseInt(a.get("paged")??"1",10)-1)*i,s=e.map((t=>function(t){return[{id:t.id,value:t.name,display:(0,w.jsx)(J,{automation:t})},{id:t.id,value:null,display:(0,w.jsx)(et,{automation:t})},{id:t.id,value:t.status,display:(0,w.jsx)(X,{automation:t})},{id:t.id,value:null,display:(0,w.jsx)(G,{automation:t})}]}(t))).slice(n,n+i);return(0,w.jsx)(I.Z,{className:"mailpoet-automation-listing",title:"",isLoading:!o,headers:ot,rows:s,rowKey:(t,a)=>e[a].id,rowsPerPage:i,onQueryChange:t=>e=>{l({[t]:e})},totalRows:e.length,query:Object.fromEntries(a),showMenu:!1})}),[o,r,a,l]);return(0,w.jsx)(F.Z,{className:"mailpoet-filter-tab-panel",tabs:u,onSelect:t=>{s!==t&&l({status:t})},initialTabName:s??"all",children:m},s)}var st=a(94055),lt=a(92112),rt=a(97442),ut=a(96328);function mt(t){let{controls:e,title:a,onClick:o,variant:i}=t;const[s,l]=(0,n.useState)(!1),r=Object.values(e).filter((t=>t.slot)),u=s?"mailpoet-option-button-opener is-busy":"mailpoet-option-button-opener";return(0,w.jsxs)("div",{className:"mailpoet-option-button",children:[(0,w.jsx)(v.ZP,{isBusy:s,disabled:s,variant:i,className:"mailpoet-option-button-main",onClick:()=>{l(!0),o(l)},children:a}),r.length>0&&r.map((t=>{let{key:e,slot:a}=t;return(0,w.jsx)(a,{},e)})),Object.values(e).length>0&&(0,w.jsx)(q.Z,{className:u,label:(0,b.__)("More","mailpoet"),icon:ut.Z,controls:Object.values(e).map((t=>({...t.control,onClick:()=>{l(!0),t.control.onClick(l)}}))),popoverProps:{position:"bottom left"}})]})}function ct(){const t=rt.Hooks.applyFilters("mailpoet.automation.hero.actions",{});return(0,w.jsx)("section",{className:"mailpoet-automation-section mailpoet-automation-white-background",children:(0,w.jsxs)("div",{className:"mailpoet-automation-section-content mailpoet-automation-section-hero",children:[(0,w.jsxs)("div",{children:[(0,w.jsx)("span",{className:"mailpoet-automation-preheading",children:(0,b.__)("Automations","mailpoet")}),(0,w.jsx)("h1",{children:(0,b.__)("Better engagement begins with automation","mailpoet")}),(0,w.jsx)("p",{children:(0,b.__)("Send emails that inform, reward, and engage your audience through powerful segmenting, scheduling, and design tools.","mailpoet")}),(0,w.jsx)(mt,{variant:"primary",onClick:()=>{window.location.href=T.x.urls.automationTemplates},title:(0,b.__)("Start with a template","mailpoet"),controls:t})]}),(0,w.jsx)("img",{src:`${T.x.cdnUrl}automation/sections/hero.png`,alt:(0,b.__)("Welcome","mailpoet")})]})})}var dt=a(94143),pt=a(32976);function ht(){const t=dt.U.slice(0,3);return(0,w.jsx)("section",{className:"mailpoet-automation-section",children:(0,w.jsxs)("div",{className:"mailpoet-automation-section-content mailpoet-section-templates",children:[(0,w.jsx)("h2",{children:(0,b.__)("Explore essentials","mailpoet")}),(0,w.jsx)("p",{children:(0,b.__)("Choose from our list of pre-made templates and make it your own.","mailpoet")}),(0,w.jsx)("ul",{className:"mailpoet-section-template-list",children:t.map((t=>(0,w.jsx)(pt.v,{template:t,heading:"h3"},t.slug)))}),(0,w.jsx)(v.ZP,{variant:"link",href:T.x.urls.automationTemplates,children:(0,b.__)("Browse all templates →","mailpoet")})]})})}function _t(){const[t,e]=(0,n.useState)("start-with-a-trigger"),a=[{slug:"start-with-a-trigger",title:(0,b.__)("Start with a trigger","mailpoet"),text:(0,b.__)("Deliver relevant messages to your customers based on who they are and how they interact with your business.","mailpoet"),image:`${T.x.cdnUrl}automation/sections/start-with-a-trigger.png`},{slug:"customize-your-automation",title:(0,b.__)("Customize your automation","mailpoet"),text:(0,b.__)("Choose steps and create a custom journey to best suit your needs.","mailpoet"),image:`${T.x.cdnUrl}automation/sections/customize-your-automation.png`},{slug:"design-your-email",title:(0,b.__)("Design your email","mailpoet"),text:(0,b.__)("Modify one of our pre-made email templates or create your own design.","mailpoet"),image:`${T.x.cdnUrl}automation/sections/design-your-email.png`},{slug:"start-engaging",title:(0,b.__)("Start engaging","mailpoet"),text:(0,b.__)("Activate the automation and start engaging with your customers as they interact with your business.","mailpoet"),image:`${T.x.cdnUrl}automation/sections/start-engaging.png`}],o=a.filter((e=>e.slug===t))[0];return(0,w.jsx)("section",{className:"mailpoet-automation-section mailpoet-automation-white-background",children:(0,w.jsxs)("div",{className:"mailpoet-automation-section-content mailpoet-section-build-your-own",children:[(0,w.jsxs)("div",{children:[(0,w.jsx)("h2",{children:(0,b.__)("Build your own automations","mailpoet")}),(0,w.jsx)("p",{children:(0,b.__)("Create customized email sequences with our new automation editor.","mailpoet")}),(0,w.jsx)("ol",{children:a.map(((a,o)=>(0,w.jsxs)("li",{className:t===a.slug?"open":"",children:[(0,w.jsx)("div",{className:"marker",children:o<10?`0${o+1}`:o+1}),(0,w.jsxs)("div",{children:[(0,w.jsx)("button",{type:"button",onClick:()=>e(a.slug),className:"mailpoet-section-build-list-button",children:a.title}),(0,w.jsx)("p",{children:a.text})]})]},a.slug)))})]}),(0,w.jsx)("img",{src:o.image,alt:o.title})]})})}const gt=()=>{T.x.trackEvent("Automations > Listing viewed")};function xt(){const[t,e]=(0,n.useState)(!0),a=(0,c.Z)((t=>t(h).getAutomationCount()));(0,n.useEffect)((()=>{t&&0!==a&&(gt(),e(!1))}),[t,a]);const o=a>0?(0,w.jsxs)(w.Fragment,{children:[(0,w.jsx)(it,{}),(0,w.jsx)(nt,{})]}):(0,w.jsx)(ct,{});return(0,n.useEffect)((()=>{const t="mailpoet-automation-is-onboarding",e=document.querySelector("body");0!==a||e.classList.contains(t)||e.classList.add(t),a>0&&e.classList.contains(t)&&e.classList.remove(t)}),[a]),(0,w.jsxs)(w.Fragment,{children:[o,(0,w.jsx)(ht,{}),(0,w.jsx)(_t,{})]})}function jt(){return(0,w.jsxs)(w.Fragment,{children:[(0,w.jsx)(r.Q,{}),(0,w.jsx)(lt.w,{}),(0,w.jsx)(xt,{})]})}function bt(){return(0,w.jsx)(u.zt,{children:(0,w.jsxs)(l.BrowserRouter,{children:[(0,w.jsx)(jt,{}),(0,w.jsx)(m.Z.Slot,{})]})})}window.addEventListener("DOMContentLoaded",(()=>{(()=>{const t=(0,_.Z)(h,{actions:o,controls:x.controls,selectors:i,reducer:j,initialState:{automations:void 0}});(0,g.register)(t)})();const t=document.getElementById("mailpoet_automation");t&&((0,d.registerTranslations)(),(0,st.y)(),(0,p.q)(),s.render((0,w.jsx)(bt,{}),t))}))},65311:t=>{t.exports=jQuery}},t=>{t.O(0,[351],(()=>(43845,t(t.s=43845)))),t.O()}]);

Youez - 2016 - github.com/yon3zu
LinuXploit