{"version":3,"sources":["jsdelivr-header.js","/npm/vega-interpreter@2.2.1/src/constants.js","/npm/vega-interpreter@2.2.1/src/ops-binary.js","/npm/vega-interpreter@2.2.1/src/ops-unary.js","/npm/vega-interpreter@2.2.1/src/functions.js","/npm/vega-interpreter@2.2.1/src/interpret.js","/npm/vega-interpreter@2.2.1/src/expression.js","/npm/vega-interpreter@2.2.1/src/adjust-spatial.js"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA,oGCNA,IAAe,EAAA,CACb,IAAY,IACZ,EAAY,KAAK,EACjB,IAAY,KAAK,IACjB,KAAY,KAAK,KACjB,MAAY,KAAK,MACjB,OAAY,KAAK,OACjB,GAAY,KAAK,GACjB,QAAY,KAAK,QACjB,MAAY,KAAK,MACjB,UAAY,OAAO,UACnB,UAAY,OAAO,WCXN,EAAA,CACb,IAAK,CAAC,EAAG,IAAM,EAAI,EACnB,IAAK,CAAC,EAAG,IAAM,EAAI,EACnB,IAAK,CAAC,EAAG,IAAM,EAAI,EACnB,IAAK,CAAC,EAAG,IAAM,EAAI,EACnB,IAAK,CAAC,EAAG,IAAM,EAAI,EACnB,IAAK,CAAC,EAAG,IAAM,EAAI,EACnB,IAAK,CAAC,EAAG,IAAM,EAAI,EACnB,KAAM,CAAC,EAAG,IAAM,GAAK,EACrB,KAAM,CAAC,EAAG,IAAM,GAAK,EACrB,KAAM,CAAC,EAAG,IAAM,GAAK,EACrB,KAAM,CAAC,EAAG,IAAM,GAAK,EACrB,MAAO,CAAC,EAAG,IAAM,IAAM,EACvB,MAAO,CAAC,EAAG,IAAM,IAAM,EACvB,IAAK,CAAC,EAAG,IAAM,EAAI,EACnB,IAAK,CAAC,EAAG,IAAM,EAAI,EACnB,IAAK,CAAC,EAAG,IAAM,EAAI,EACnB,KAAM,CAAC,EAAG,IAAM,GAAK,EACrB,KAAM,CAAC,EAAG,IAAM,GAAK,EACrB,MAAO,CAAC,EAAG,IAAM,IAAM,GCnBV,EAAA,CACb,IAAK,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b,EAAI,GAOR,MAHiB,SAAb,GC7DK,SAAS,EAAM,EAAQ,GACpC,IAAI,EAEA,EAAO,KACL,EAAO,GACL,GAAQ,EAAK,EAAI,EAAK,KACxB,EAAI,EAAK,EACT,EAAK,EAAI,EAAK,GACd,EAAK,GAAK,GAEZ,EAAK,MAAQ,EAAK,GAAK,EAAK,GAE5B,EAAK,EAAI,EAAK,IAAM,EAAK,OAAS,IAIlC,EAAO,KACT,EAAK,EAAI,EAAK,IAAM,EAAK,OAAS,GAAK,GAGrC,EAAO,KACL,EAAO,GACL,GAAQ,EAAK,EAAI,EAAK,KACxB,EAAI,EAAK,EACT,EAAK,EAAI,EAAK,GACd,EAAK,GAAK,GAEZ,EAAK,OAAS,EAAK,GAAK,EAAK,GAE7B,EAAK,EAAI,EAAK,IAAM,EAAK,QAAU,IAInC,EAAO,KACT,EAAK,EAAI,EAAK,IAAM,EAAK,QAAU,GAAK,EAE5C,CD0BQ,CAAc,EAAM,EAAU,GAEzB,CAAC,CAEZ,U","file":"/npm/vega-interpreter@2.2.1/build/vega-interpreter.js/+esm","sourceRoot":"","sourcesContent":["/**\n * Bundled by jsDelivr using Rollup v2.79.2 and Terser v5.39.0.\n * Original file: /npm/vega-interpreter@2.2.1/build/vega-interpreter.js\n *\n * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files\n */\n","export default {\n  NaN:        NaN,\n  E:          Math.E,\n  LN2:        Math.LN2,\n  LN10:       Math.LN10,\n  LOG2E:      Math.LOG2E,\n  LOG10E:     Math.LOG10E,\n  PI:         Math.PI,\n  SQRT1_2:    Math.SQRT1_2,\n  SQRT2:      Math.SQRT2,\n  MIN_VALUE:  Number.MIN_VALUE,\n  MAX_VALUE:  Number.MAX_VALUE\n};\n","export default {\n  '*': (a, b) => a * b,\n  '+': (a, b) => a + b,\n  '-': (a, b) => a - b,\n  '/': (a, b) => a / b,\n  '%': (a, b) => a % b,\n  '>': (a, b) => a > b,\n  '<': (a, b) => a < b,\n  '<=': (a, b) => a <= b,\n  '>=': (a, b) => a >= b,\n  '==': (a, b) => a == b,\n  '!=': (a, b) => a != b,\n  '===': (a, b) => a === b,\n  '!==': (a, b) => a !== b,\n  '&': (a, b) => a & b,\n  '|': (a, b) => a | b,\n  '^': (a, b) => a ^ b,\n  '<<': (a, b) => a << b,\n  '>>': (a, b) => a >> b,\n  '>>>': (a, b) => a >>> b\n};\n","export default {\n  '+': a => +a,\n  '-': a => -a,\n  '~': a => ~a,\n  '!': a => !a\n};\n","import { ascending, isString } from 'vega-util';\n\nconst slice = Array.prototype.slice;\n\nconst apply = (m, args, cast) => {\n  const obj = cast ? cast(args[0]) : args[0];\n  return obj[m].apply(obj, slice.call(args, 1));\n};\n\nconst datetime = (yearOrTimestring, m = 0, d = 1, H = 0, M = 0, S = 0, ms = 0) =>\n   isString(yearOrTimestring)\n     ? new Date(yearOrTimestring)\n     : new Date(yearOrTimestring, m, d, H, M, S, ms);\n\nexport default {\n  // math functions\n  isNaN:     Number.isNaN,\n  isFinite:  Number.isFinite,\n  abs:       Math.abs,\n  acos:      Math.acos,\n  asin:      Math.asin,\n  atan:      Math.atan,\n  atan2:     Math.atan2,\n  ceil:      Math.ceil,\n  cos:       Math.cos,\n  exp:       Math.exp,\n  floor:     Math.floor,\n  log:       Math.log,\n  max:       Math.max,\n  min:       Math.min,\n  pow:       Math.pow,\n  random:    Math.random,\n  round:     Math.round,\n  sin:       Math.sin,\n  sqrt:      Math.sqrt,\n  tan:       Math.tan,\n  clamp:     (a, b, c) => Math.max(b, Math.min(c, a)),\n\n  // date functions\n  now:              Date.now,\n  utc:              Date.UTC,\n  datetime:         datetime,\n  date:             d => new Date(d).getDate(),\n  day:              d => new Date(d).getDay(),\n  year:             d => new Date(d).getFullYear(),\n  month:            d => new Date(d).getMonth(),\n  hours:            d => new Date(d).getHours(),\n  minutes:          d => new Date(d).getMinutes(),\n  seconds:          d => new Date(d).getSeconds(),\n  milliseconds:     d => new Date(d).getMilliseconds(),\n  time:             d => new Date(d).getTime(),\n  timezoneoffset:   d => new Date(d).getTimezoneOffset(),\n  utcdate:          d => new Date(d).getUTCDate(),\n  utcday:           d => new Date(d).getUTCDay(),\n  utcyear:          d => new Date(d).getUTCFullYear(),\n  utcmonth:         d => new Date(d).getUTCMonth(),\n  utchours:         d => new Date(d).getUTCHours(),\n  utcminutes:       d => new Date(d).getUTCMinutes(),\n  utcseconds:       d => new Date(d).getUTCSeconds(),\n  utcmilliseconds:  d => new Date(d).getUTCMilliseconds(),\n\n  // sequence functions\n  length:       x => x.length,\n  join:         function() { return apply('join', arguments); },\n  indexof:      function() { return apply('indexOf', arguments); },\n  lastindexof:  function() { return apply('lastIndexOf', arguments); },\n  slice:        function() { return apply('slice', arguments); },\n  reverse:      x => x.slice().reverse(),\n  sort:         x => x.slice().sort(ascending),\n\n  // string functions\n  parseFloat:   parseFloat,\n  parseInt:     parseInt,\n  upper:        x => String(x).toUpperCase(),\n  lower:        x => String(x).toLowerCase(),\n  substring:    function() { return apply('substring', arguments, String); },\n  split:        function() { return apply('split', arguments, String); },\n  replace:      function() { return apply('replace', arguments, String); },\n  trim:         x => String(x).trim(),\n  // Base64 encode/decode\n  // Convert binary string to base64-encoded ascii\n  btoa:         x => btoa(x),\n  // Convert base64-encoded ascii to binary string\n  atob:         x => atob(x),\n\n  // regexp functions\n  regexp:       RegExp,\n  test:         (r, t) => RegExp(r).test(t)\n};\n","import Constants from './constants.js';\nimport Ops from './ops-binary.js';\nimport Unary from './ops-unary.js';\nimport Functions from './functions.js';\nimport {DisallowedObjectProperties} from 'vega-util';\n\nconst EventFunctions = ['view', 'item', 'group', 'xy', 'x', 'y'];\nconst DisallowedMethods = new Set([\n  Function,\n  eval,\n  setTimeout,\n  setInterval\n]);\n\nif (typeof setImmediate === 'function') DisallowedMethods.add(setImmediate);\n\nconst Visitors = {\n  Literal: ($, n) => n.value,\n\n  Identifier: ($, n) => {\n    const id = n.name;\n    return $.memberDepth > 0 ? id\n      : id === 'datum' ? $.datum\n      : id === 'event' ? $.event\n      : id === 'item' ? $.item\n      : Constants[id] || $.params['$' + id];\n  },\n\n  MemberExpression: ($, n) => {\n    const d = !n.computed,\n          o = $(n.object);\n    if (d) $.memberDepth += 1;\n    const p = $(n.property);\n    if (d) $.memberDepth -= 1;\n    if (DisallowedMethods.has(o[p])) {\n      // eslint-disable-next-line no-console\n      console.error(`Prevented interpretation of member \"${p}\" which could lead to insecure code execution`);\n      return;\n    }\n    return o[p];\n  },\n\n  CallExpression: ($, n) => {\n    const args = n.arguments;\n    let name = n.callee.name;\n\n    // handle special internal functions used by encoders\n    // re-route to corresponding standard function\n    if (name.startsWith('_')) {\n      name = name.slice(1);\n    }\n\n    // special case \"if\" due to conditional evaluation of branches\n    return name === 'if'\n      ? ($(args[0]) ? $(args[1]) : $(args[2]))\n      : ($.fn[name] || Functions[name]).apply($.fn, args.map($));\n  },\n\n  ArrayExpression: ($, n) => n.elements.map($),\n\n  BinaryExpression: ($, n) => Ops[n.operator]($(n.left), $(n.right)),\n\n  UnaryExpression: ($, n) => Unary[n.operator]($(n.argument)),\n\n  ConditionalExpression: ($, n) => $(n.test)\n    ? $(n.consequent)\n    : $(n.alternate),\n\n  LogicalExpression: ($, n) => n.operator === '&&'\n    ? $(n.left) && $(n.right)\n    : $(n.left) || $(n.right),\n\n  ObjectExpression: ($, n) => n.properties.reduce((o, p) => {\n    $.memberDepth += 1;\n    const k = $(p.key);\n    $.memberDepth -= 1;\n    const v = $(p.value);\n    if (DisallowedObjectProperties.has(k)) {      // eslint-disable-next-line no-console\n      console.error(`Prevented interpretation of property \"${k}\" which could lead to insecure code execution`);\n    } else if (DisallowedMethods.has(v)) { // eslint-disable-next-line no-console\n      console.error(`Prevented interpretation of method \"${k}\" which could lead to insecure code execution`);\n    } else {\n      o[k] = v;\n    }\n    return o;\n  }, {})\n};\n\nexport default function(ast, fn, params, datum, event, item) {\n  const $ = n => Visitors[n.type]($, n);\n  $.memberDepth = 0;\n  $.fn = Object.create(fn);\n  $.params = params;\n  $.datum = datum;\n  $.event = event;\n  $.item = item;\n\n  // route event functions to annotated vega event context\n  EventFunctions.forEach(f => $.fn[f] = (...args) => event.vega[f](...args));\n\n  return $(ast);\n}\n","import adjustSpatial from './adjust-spatial.js';\nimport interpret from './interpret.js';\n\nexport default {\n  /**\n   * Parse an expression used to update an operator value.\n   */\n  operator(ctx, expr) {\n    const ast = expr.ast, fn = ctx.functions;\n    return _ => interpret(ast, fn, _);\n  },\n\n  /**\n   * Parse an expression provided as an operator parameter value.\n   */\n  parameter(ctx, expr) {\n    const ast = expr.ast, fn = ctx.functions;\n    return (datum, _) => interpret(ast, fn, _, datum);\n  },\n\n  /**\n   * Parse an expression applied to an event stream.\n   */\n  event(ctx, expr) {\n    const ast = expr.ast, fn = ctx.functions;\n    return event => interpret(ast, fn, undefined, undefined, event);\n  },\n\n  /**\n   * Parse an expression used to handle an event-driven operator update.\n   */\n  handler(ctx, expr) {\n    const ast = expr.ast, fn = ctx.functions;\n    return (_, event) => {\n      const datum = event.item && event.item.datum;\n      return interpret(ast, fn, _, datum, event);\n    };\n  },\n\n  /**\n   * Parse an expression that performs visual encoding.\n   */\n  encode(ctx, encode) {\n    const {marktype, channels} = encode,\n          fn = ctx.functions,\n          swap = marktype === 'group'\n              || marktype === 'image'\n              || marktype === 'rect';\n\n    return (item, _) => {\n      const datum = item.datum;\n      let m = 0, v;\n\n      for (const name in channels) {\n        v = interpret(channels[name].ast, fn, _, datum, undefined, item);\n        if (item[name] !== v) {\n          item[name] = v;\n          m = 1;\n        }\n      }\n\n      if (marktype !== 'rule') {\n        adjustSpatial(item, channels, swap);\n      }\n      return m;\n    };\n  }\n};\n","export default function(item, encode, swap) {\n  let t;\n\n  if (encode.x2) {\n    if (encode.x) {\n      if (swap && item.x > item.x2) {\n        t = item.x;\n        item.x = item.x2;\n        item.x2 = t;\n      }\n      item.width = item.x2 - item.x;\n    } else {\n      item.x = item.x2 - (item.width || 0);\n    }\n  }\n\n  if (encode.xc) {\n    item.x = item.xc - (item.width || 0) / 2;\n  }\n\n  if (encode.y2) {\n    if (encode.y) {\n      if (swap && item.y > item.y2) {\n        t = item.y;\n        item.y = item.y2;\n        item.y2 = t;\n      }\n      item.height = item.y2 - item.y;\n    } else {\n      item.y = item.y2 - (item.height || 0);\n    }\n  }\n\n  if (encode.yc) {\n    item.y = item.yc - (item.height || 0) / 2;\n  }\n}\n"]}