import{applyJsonToLayers as a}from"./LayerJson.js";export async function applyJsonToWebMap(o,p,t){const r=(await import("../portal/WebMap.js")).WebMap.applyToEsriApiMap,{operationalLayers:e,...n}=o;await r(n,p,t),await a(e??[],p.layers)}export function webMapToJson(a){return a.toJSON()}