"use strict";(self.webpackChunkshopwp=self.webpackChunkshopwp||[]).push([["CartNote-public"],{okCt:function(t,e,a){a.r(e);var n=a("2MD/"),o=a("LpH3"),s=a("V+k2"),r=a("y+oc"),l=a("dVqq"),p=a("bNFS"),i=a("U039"),c={name:"1g49dnu-CartTextareaCSS",styles:"width:100%;color:#121212;display:block;font-size:15px;padding:10px;border-color:#7e7e7e;appearance:none;font-family:inherit;border-radius:5px;min-height:100px;background:transparent;::placeholder,::-webkit-input-placeholder{color:#969696;};label:CartTextareaCSS;"},d={name:"fma5os-CartNotesCSS",styles:"margin-bottom:0.5em;padding:0;font-weight:none;color:#121212;label{font-size:15px;display:block;margin-bottom:5px;};label:CartNotesCSS;"};e.default=function(){var t=wp.element,e=t.useState,a=t.useRef,u=t.useEffect,b=(0,s.v)(),f=(0,s.h)(),h=(0,r.K)(),C=(0,r.d)(),g=a(),m=e(b.cartData.note),w=(0,n.Z)(m,2),S=w[0],k=w[1],x=(0,l.Nr)(S,450),y=(0,n.Z)(x,1)[0],N=(0,i.sc)();u((function(){N||b.cartData.note!==y&&(f({type:"SET_IS_CART_UPDATING",payload:!0}),(0,p.db)(y,b,C,g,f))}),[y]),u((function(){b.cartData.note&&k(b.cartData.note)}),[b.cartData.note]);var D=d,v=c;return(0,o.tZ)("section",{className:"wps-cart-notes",css:D},(0,o.tZ)("label",{htmlFor:"wps-input-notes"},h.settings.notesLabel),(0,o.tZ)("textarea",{css:v,placeholder:h.settings.notesPlaceholder,id:"wps-input-notes",className:"wps-input wps-input-textarea",value:S,onChange:function(t){b.isCartUpdating||k(t.target.value)},ref:g,disabled:b.isCartUpdating}))}}}]);