"use strict";(globalThis.webpackChunk=globalThis.webpackChunk||[]).push([[4582],{4582(e,t,n){n.r(t),n.d(t,{default:()=>r});var a=n(1609),u=n(6087),l=n(6723),d=n(9668);const r=({componentId:e,field:t,updateField:n,...r})=>{const c=(0,u.useRef)(),[i,s]=(0,u.useState)(!1);return(0,u.useEffect)(()=>{i||c.current&&c.current.value!==t.name&&(c.current.value=t.name||"")},[i,t.name]),(0,a.createElement)(d.default,{htmlFor:e,...r},(0,a.createElement)("input",{ref:c,type:"text",id:e,defaultValue:t.name||"",onBlur:()=>{s(!1),n("_id_changed",!0)},onChange:e=>{const a=e.target.value;n("name",a),s(!0),!t._new||t._id_changed||["custom_html","divider","heading"].includes(t.type)||n("id",(0,l.ni)(a))}}))}}}]);