| Current Path : /home/users/unlimited/www/whatsapp-crm/public/build/assets/ |
| Current File : /home/users/unlimited/www/whatsapp-crm/public/build/assets/Show-2e336b3e.js |
import{T as h,m as g,h as f,f as d,o as w,a as t,t as r,e as a,u as n,l as v,n as _,g as b}from"./app-43851608.js";import x from"./App-2fea9171.js";import{_ as y}from"./FormInput-4a309017.js";import{Q as k}from"./vue-quill.snow-67e79d8a.js";import"./App-ad5f7ecb.js";import"./Sidebar-7bb6d772.js";import"./Menu-4221d61f.js";import"./ProfileModal-628e5b7c.js";import"./LangToggle-8d05b0dc.js";import"./MobileSidebar-b73cd192.js";import"./index-99011d5f.js";/* empty css */import"./Sidebar-7b5bc85b.js";const $={class:"flex justify-between"},V={class:"text-xl mb-1"},B={class:"mb-6 flex items-center text-sm leading-6 text-gray-600"},C=t("svg",{xmlns:"http://www.w3.org/2000/svg",width:"18",height:"18",viewBox:"0 0 24 24"},[t("path",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M12 11v5m0 5a9 9 0 1 1 0-18a9 9 0 0 1 0 18Zm.05-13v.1h-.1V8h.1Z"})],-1),S={class:"ml-1 mt-1"},H={class:"flex items-center space-x-2"},M=t("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},[t("path",{fill:"black",d:"M19 11H7.14l3.63-4.36a1 1 0 1 0-1.54-1.28l-5 6a1.19 1.19 0 0 0-.09.15c0 .05 0 .08-.07.13A1 1 0 0 0 4 12a1 1 0 0 0 .07.36c0 .05 0 .08.07.13a1.19 1.19 0 0 0 .09.15l5 6A1 1 0 0 0 10 19a1 1 0 0 0 .64-.23a1 1 0 0 0 .13-1.41L7.14 13H19a1 1 0 0 0 0-2"})],-1),z=t("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},[t("path",{fill:"red",d:"M6 19a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2V7H6zM8 9h8v10H8zm7.5-5l-1-1h-5l-1 1H5v2h14V4z"})],-1),j=[z],A={class:"text-sm mb-4 mt-3 rounded-md bg-gray-200 px-1 w-fit"},N={class:"bg-white"},J={__name:"Show",props:{page:Object},setup(p){const l=p,o=h({_method:"put",name:l.page.name,content:l.page.content}),m=async()=>{const s=window.location.pathname;o.put(s,{preserveScroll:!0})},u=async()=>{const s=window.location.pathname;o.delete(s,{onBefore:()=>confirm("Are you sure you want to delete this page?"),preserveScroll:!0})},c=g(()=>o.name.trim().toLowerCase().replace(/\s+/g,"-"));return(s,e)=>(w(),f(x,null,{default:d(()=>[t("div",$,[t("div",null,[t("h2",V,r(s.$t("Frontend pages"))+" | "+r(s.$t("Edit")),1),t("p",B,[C,t("span",S,r(s.$t("Configure pages")),1)])]),t("div",H,[a(n(v),{href:"/admin/settings/pages",class:"hover:bg-white rounded-full p-1"},{default:d(()=>[M]),_:1}),t("button",{onClick:e[0]||(e[0]=i=>u()),class:"hover:bg-white rounded-full p-1"},j),t("button",{onClick:e[1]||(e[1]=i=>m()),class:"rounded-md bg-indigo-600 px-3 py-1 text-sm text-white shadow-sm hover:bg-indigo-500 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-indigo-600"},r(s.$t("Save")),1)])]),t("form",{onSubmit:e[4]||(e[4]=b(i=>m(),["prevent"]))},[a(y,{modelValue:n(o).name,"onUpdate:modelValue":e[2]||(e[2]=i=>n(o).name=i),name:"",error:n(o).errors.name,type:"text",class:_("sm:col-span-6")},null,8,["modelValue","error"]),t("div",A,"Slug: /"+r(c.value),1),t("div",N,[a(n(k),{content:n(o).content,"onUpdate:content":e[3]||(e[3]=i=>n(o).content=i),toolbar:"essential",contentType:"html",theme:"snow"},null,8,["content"])])],32)]),_:1}))}};export{J as default};