"use strict";(self.webpackChunkcomplianz_gdpr=self.webpackChunkcomplianz_gdpr||[]).push([[880],{20880:(e,t,a)=>{a.r(t),a.d(t,{default:()=>o});var c=a(51609),n=a(96979),l=a(45111),d=a(4219),m=a(27723);const o=e=>{const{saving:t,updateDocument:a}=(0,n.UseDocumentsData)(),{showSavedSettingsNotice:o}=(0,d.default)();let s=!!e.page.page_id;return(0,c.createElement)("div",{className:"cmplz-create-document"},s&&(0,c.createElement)(l.default,{name:"success",color:"green"}),!s&&(0,c.createElement)(l.default,{name:"times"}),(0,c.createElement)("input",{disabled:t,onChange:t=>((e,t)=>{a(t,e.target.value)})(t,e.page.page_id),type:"text",value:e.page.title}),(0,c.createElement)("div",{className:"cmplz-shortcode-container",onClick:t=>((e,t)=>{let a;e.target.classList.add("cmplz-click-animation");let c=document.createElement("input");document.getElementsByTagName("body")[0].appendChild(c),c.value=t,c.select();try{a=document.execCommand("copy")}catch(e){a=!1}c.parentElement.removeChild(c),a&&o((0,m.__)("Copied shortcode","complianz-gdpr"))})(t,e.page.shortcode)},(0,c.createElement)(l.default,{name:"shortcode"})))}}}]);