"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});function y(a,f){if(!a||a.length===0)throw new Error("No data to transform");const{targetkeys:n,transfrom:l,mode:p}=f,[u,c]=l;return p==="comp"?a.map(o=>{if(!c){const r=n.map(t=>o[t]),e={...o};return n.forEach(t=>delete e[t]),{...e,[u]:r}}const s=n.reduce((r,e,t)=>(r[c[t]]=o[e],delete o[e],r),{});return{...o,[u]:s}}):a.map(o=>{const s=o[u],r={...o};return delete r[u],Array.isArray(s)?(n.forEach((e,t)=>{r[e]=s[t]}),r):(n.forEach((e,t)=>{r[e]=s[c[t]]}),r)})}exports.ApTransformDataHelper=y;
