"use strict";(globalThis.webpackChunk=globalThis.webpackChunk||[]).push([[9972],{9972(e,l,t){t.r(l),t.d(l,{default:()=>u});var a=t(1609),n=t(7723),r=t(6723);const c=({field:e})=>{const l=(0,r.EP)(e.options||"");let t=(0,r.EP)(e.std||"").map(e=>e.value);return(0,a.createElement)(a.Fragment,null,(0,a.createElement)("select",{multiple:!0,value:t,onChange:r.Zi},l.map(e=>(0,a.createElement)("option",{key:e.value,value:e.value},e.label))),e.select_all_none&&(0,a.createElement)("div",{className:"rwmb-select-all-none"},(0,n.__)("Select:","meta-box-builder"),"  ",(0,a.createElement)("a",{href:"#"},(0,n.__)("All","meta-box-builder"))," | ",(0,a.createElement)("a",{href:"#"},(0,n.__)("None","meta-box-builder"))))},o=({field:e})=>{if(e.placeholder)return(0,a.createElement)("select",null,(0,a.createElement)("option",{value:""},e.placeholder));const l=(0,r.EP)(e.options||"");let t=(0,r.EP)(e.std||"").map(e=>e.value);t=t[0];const n=l.find(e=>e.value===t),c=n?n.label:l.length>0?l[0].label:"";return(0,a.createElement)("select",{value:"",onChange:r.Zi},(0,a.createElement)("option",{value:""},c))},u=({field:e})=>e.multiple?(0,a.createElement)(c,{field:e}):(0,a.createElement)(o,{field:e})}}]);