"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const S=require("../index.js"),r=require("../utils/utils.js"),D=(a,t,i)=>new Promise(function(e,p){if(!a.source.storage){e(r.DataSourceUtils.noneData(t));return}const{getType:n,getField:o}=a.source.storage;if(n===0){e(r.DataSourceUtils.noneData(t));return}if(!o){e(r.DataSourceUtils.noneData(t));return}let s=null;n===1&&(s=localStorage.getItem("Local_"+o)),n===2&&(s=sessionStorage.getItem("Session_"+o));const{filter:c,mapping:u,isUserdata:g}=a.source;S.SHJDatasourceV2.processData(c,s,u,t,a.source.dynamicMapping,i,g).then(l=>{e(l)}).catch(()=>{e(r.DataSourceUtils.noneData(t))})});exports.parseStorage=D;
