/*! Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one or more contributor license agreements. * Licensed under the Elastic License 2.0; you may not use this file except in compliance with the Elastic License 2.0. */ (window.lens_bundle_jsonpfunction=window.lens_bundle_jsonpfunction||[]).push([[20],{571:function(n,o,e){"use strict";function r(n,o){if("date_histogram"===(null==n?void 0:n.operationType)){const e=n.sourceField;return o.name.replace(e,n.label)}return n.label}e.r(o),e.d(o,"mapToOriginalColumns",(function(){return t}));const t=(n,{idMap:o})=>{const e=JSON.parse(o);return{...n,rows:n.rows.map((n=>{const o={};return Object.entries(n).forEach((([n,r])=>{n in e?e[n].forEach((({id:n})=>{o[n]=r})):o[n]=r})),o})),columns:n.columns.map((n=>{const o=e[n.id];return o?o.map((o=>({...n,id:o.id,name:r(o,n)}))):n})).flat()}}}}]);