import{k as m,h as f,i as p,r,e as s,o as a,a as v,w as h,F as y,g as _,c as g}from"./vue.esm-bundler.js?ver=1.3.20";const k={class:"input-append"},x={__name:"Categories",props:{field:{type:Object},value:{type:Object},fieldKey:{type:String}},setup(e){const c=m().ctx,o=f([]),d=()=>{c.$get("products/fetch-term").then(l=>{o.value=l.taxonomies["product-categories"].terms}).catch(l=>{}).finally(()=>{})};return p(()=>{d()}),(l,n)=>{const i=r("el-option"),u=r("el-select");return a(),s("div",k,[v(u,{modelValue:e.value[e.fieldKey],"onUpdate:modelValue":n[0]||(n[0]=t=>e.value[e.fieldKey]=t),multiple:"",placeholder:e.field.placeholder,filterable:"",remote:"","reserve-keyword":!1},{default:h(()=>[(a(!0),s(y,null,_(o.value,t=>(a(),g(i,{key:t.term_id,label:t.name,value:t.term_id},null,8,["label","value"]))),128))]),_:1},8,["modelValue","placeholder"])])}}};export{x as default};
