Skip to content

Releases: vega/vega

v5.17.0

01 Oct 10:13
Compare
Choose a tag to compare

Changes from v5.16.1:

vega-canvas

  • Fix browser index route for ES modules. (#2907)

vega-loader

  • Add iterable support to JSON loader. Iterable inputs are expanded to arrays, then ingested.
  • Fix browser index route for ES modules. (#2907)

vega-util

  • Add isIterable utility.

v5.16.1

23 Sep 17:36
Compare
Choose a tag to compare

Changes from v5.16.0:

monorepo

  • Fix rollup config to use umd rather than iife bundles. (#2896)

v5.16.0

23 Sep 08:16
Compare
Choose a tag to compare

Notable Changes

  • The new label transform automatically positions labels without overlapping other marks. (Thanks @chanwutk!)
  • Completes the transition to using vega-datasets 2.0+, including swapping out the Iris dataset for a more adorable Penguins dataset. 🐧
  • Major update of build system to use a centralized rollup configuration. (Thanks @domoritz!)

Changelog

Changes from v5.15.0:

docs

monorepo

  • Complete transition to vega-datasets 2.0.
  • Use centralized rollup config. (thanks @domoritz!)

vega

  • Use centralized rollup config. (thanks @domoritz!)
  • Update and extend test specifications.

vega-canvas

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-crossfilter

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-dataflow

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-encode

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-event-selector

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-expression

  • Use forbidden / allowed, remove blacklist / whitelist (Breaking change)
  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-functions

  • Use centralized rollup config. (thanks @domoritz!)
  • Use argument spread syntax. (thanks @lgrammel!)

vega-force

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-format

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-geo

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-hierarchy

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-interpreter

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-label

  • 1.0.0 release, now integrated into Vega! (thanks @chanwutk!)
  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-loader

  • Fix JSON copy option logic. (#2890, thanks @cytomich!)
  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-parser

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-projection

  • Use centralized rollup config. (thanks @domoritz!)

vega-projection-extended

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-regression

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-runtime

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)
  • Use argument spread syntax. (thanks @lgrammel!)

vega-scale

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-scenegraph

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)
  • Use argument spread syntax. (thanks @lgrammel!)

vega-schema

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-selections

  • Use centralized rollup config. (thanks @domoritz!)
  • Use argument spread syntax. (thanks @lgrammel!)

vega-statistics

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-time

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-transforms

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-typings

vega-util

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-view-transforms

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-view

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

vega-voronoi

  • Use centralized rollup config. (thanks @domoritz!)

vega-wordcloud

  • Fix use of var, prefer const and let. (thanks @lgrammel!)
  • Use centralized rollup config. (thanks @domoritz!)

v5.15.0

31 Aug 13:54
Compare
Choose a tag to compare

Changes from v5.14.0:

monorepo

  • Update dependencies, including use of D3 v6 packages.
  • Refactor all packages for JavaScript modernization. (thanks @domoritz & @lgrammel!)

vega

  • Update vega-core build to use D3 v6.

vega-scale

v5.14.0

18 Aug 12:40
Compare
Choose a tag to compare

Notable Changes

  • Update SVG rendering to produce fully compliant XML. (#2672)
  • Major refactoring of the Vega code to be more lean and modern. The main changes are:
    • Use shorthand property method syntax (e.g., rather than assignment to prototype objects).
    • Use arrow functions rather than function declarations where appropriate.
    • Prefer use of let and const to var.
  • Upgrade the documentation examples to use vega-datasets 2.0+, including swapping out the Iris dataset for a more adorable Penguins dataset. 🐧
  • Various bug fixes, documented below.

Changelog

Changes from v5.13.0:

vega-cli

  • Update SVG test output.

vega-canvas

  • Update to use leaner syntax.

vega-crossfilter

  • Update to use leaner syntax.

vega-dataflow

  • Fix EventStream to support detach method. (#2753)
  • Fix Pulse addAll to clear rem set when applicable. This prevents tuple removal from being invoked on newly instantiated operators that never observed those tuples in the first place. (#2605)
  • Update to use leaner syntax.

vega-encode

  • Update to use leaner syntax.

vega-event-selector

  • Update to use leaner syntax.

vega-expression

  • Update to use leaner syntax.

vega-force

  • Update to use leaner syntax.

vega-format

  • Update to use leaner syntax.

vega-functions

  • Update to use leaner syntax.

vega-geo

  • Update to use leaner syntax.

vega-hierarchy

  • Update to use leaner syntax.

vega-label

  • Update to use leaner syntax.

vega-loader

  • Update to use leaner syntax.

vega-parser

  • Fix production rule support for guides. (#2754)
  • Update to use leaner syntax.

vega-projection

  • Update to use leaner syntax.

vega-regression

  • Update to use leaner syntax.

vega-scale

  • Update to use leaner syntax.

vega-scenegraph

  • Add markup and serializeXML utilities for SVG string output. Ensure proper XML output. (#2672)
  • Fix leaky SVG scaleX/Y transforms on non-path marks. (#2738)
  • Fix bounds calculation for rotated paths. (#2780)
  • Fix canvas picking for clipped groups with corner radius and no fill. (#2797)
  • Fix SVG path parsing: support concatenated decimals and implicit lineTo commands. (#2803)
  • Update tests, add xmllint checks to test conformance of SVG output.
  • Update to use leaner syntax.
  • Internal Breaking Change: Update SVGStringRenderer class methods to use markup utility.
  • Internal Breaking Change: Drop openTag, closeTag utilities.

vega-statistics

  • Update to use leaner syntax.

vega-time

  • Update to use leaner syntax.

vega-transforms

  • Update to use leaner syntax.

vega-view-transforms

  • Update to use leaner syntax.

vega-view

  • Update to use leaner syntax.

vega-util

  • Add members argument to inherits utility.
  • Add ascending comparator utility.
  • Update to use leaner syntax.

vega-voronoi

  • Update to use leaner syntax.

vega-wordcloud

  • Update to use leaner syntax.

v5.13.0

02 Jun 09:54
62565bb
Compare
Choose a tag to compare

Notable Changes

  • Improved Streaming Performance.

    For performance, Vega caches a lot of internal data structures, including calculated tuples, scenegraph items, and SVG DOM nodes. Previously, nested scopes (such as those created for facetted data) that result in vega-runtime subcontexts were never cleaned. If no external View API calls are made, this is fine, and actually improves performance for interaction-driven dynamic filtering. However, when providing streaming data to Vega through the View API, uncleaned caches and subcontexts can result in substantial memory leaks that also eventually degrade performance.

    This version adds mechanisms for clearing caches and detaching subflows to support streaming data within nested specifications. When input data is removed via a View API call or via signal-valued URL, Vega will now by default trigger garbage collection to reclaim resources. This behavior can be disabled by calling clean(false) on a constructed ChangeSet passed to the View API.

  • Improved Cursor Performance.

    Previously Vega updated the cursor style on the HTML document body. This persists cursor settings even during interactions (such as drags) that may leave the Vega View component. However, it also can result in large performance penalties in Chrome, which re-evaluates CSS styles in response. This version changes the default behavior to set the cursor locally on the Vega View component. If a global cursor is desired, the boolean config property events.globalCursor can be set true or the View method globalCursor can be invoked to change the setting at runtime.

  • Optional Expression Interpreter.

    This release adds interpreter support for Vega expressions that is Content Security Policy (CSP) compliant. By default, the Vega parser performs code generation for parsed Vega expressions, and the Vega runtime uses the Function constructor to create JavaScript functions from the generated code. Although the Vega parser includes its own security checks, the runtime generation of functions from source code nevertheless violates security policies designed to prevent cross-site scripting.

    This release provides an interpreter plug-in (the new vega-interpreter package) that evaluates expressions by traversing an Abstract Syntax Tree (AST) for an expression and performing each operation in turn. Use of the interpreter enables compliance with CSP, but can incur a performance penalty. In tests of initial parse and dataflow evaluation times, the interpreter is on average ~10% slower. Interactive updates may incur higher penalties, as they are often more expression-heavy and amortize the one-time cost of Function constructor parsing.

Changelog

Changes from v5.12.3:

vega

  • Update stream.html and stream-nested.html performance test pages.

vega-dataflow

  • Add detach method to Operator to remove adjacent edges (listeners) from the dataflow graph.
  • Add clean setter to ChangeSet, set to true by default if any tuples are removed.
  • Add clean getter/setter to Pulse, propagate value to forked pulses if they share a data source.
  • Update logging calls during Dataflow evaluation.

vega-encode

  • Update DataJoin transform to clean internal map when pulse.clean() is true.
  • Update Scale to include domainMid as an extrema if it exceeds the domain min or max. (#2656)

vega-functions

  • Fix scale function to not special case undefined input. This ensures identical semantics with the internal _scale helper function used by code-generated encoders.

vega-geo

  • Update d3-geo dependency.

vega-interpreter

  • Add new vega-interpreter package.

vega-projection

  • Update d3-geo dependency.

vega-projection-extended

  • Update vega-projection dependency.

vega-runtime

  • Add runtime detach method to remove subcontexts. Export as detachSubflow on the head operator of a generated subflow.
  • Add pluggable expression evaluators.

vega-statistics

  • Fix numbers utility to exclude empty string.

vega-transforms

  • Update Aggregate transform to clean internal map when pulse.clean() is true.
  • Update Facet, PreFacet, and Subflow transforms to prune subflows in response to pulse.clean().
  • Update Load transform to set pulse.clean(true) when removing loaded data.
  • Fix Bin and Extent to treat empty string as a missing value. (thanks @domoritz!)
  • Fix aggregate ops to treat empty string as a missing value.

vega-typings

  • Add eventConfig.globalCursor to config typings.
  • Add dataflow logger to typings.
  • Add parse options to typings.

vega-util

  • Refactor code for fastmap and visitArray utilities.

vega-view

  • Add View constructor option expr to pass in a custom expression evaluator.
  • Add globalCursor method and event configuration.
  • Update to make the Vega view container the default cursor target.

v5.12.3

23 May 10:54
Compare
Choose a tag to compare

Notable Changes

The previous Vega v5.12.0 release introduced changes to how SVG was generated, including the addition of an internal stylesheet. However, this leads to integration issues with downstream tools (including at least one popular SVG optimizer) that do not support stylesheet parsing. In addition, local performance tests indicate faster rendering in Chrome when using presentation attributes instead of CSS styling. This version (v5.12.3) now changes the SVG output to favor presentation attributes (fill="blue") over CSS style (style="fill: blue;").

CSS styles have been removed in all but one case: the use of image-rendering for non-smoothed images, where browser differences require multiple style definitions to appease both Chrome and Firefox, something we can't express with presentation attributes alone. If and when Firefox properly supports image-rendering: pixelated we can consider dropping this last use of CSS.

Note that external stylesheets can still be used to style Vega SVG content, and may now have higher specificity due to the use of attributes.

Changelog

Changes from v5.12.2:

monorepo

  • Update eslint config to flag trailing commas.

vega

  • Add initialization timing to test spec viewer page.
  • Remove dangling commas.
  • Update dev dependencies.

vega-cli

  • Update SVG test cases.

vega-format

  • Remove dangling commas.

vega-geo

  • Remove dangling commas.

vega-hierarchy

  • Remove dangling commas.

vega-parser

  • Fix trailing function argument commas in axis utils. (#2645, thanks @armanozak!)
  • Remove dangling commas.

vega-projections-extended

  • Update dev dependencies.

vega-scenegraph

  • Favor SVG presentation attributes over CSS style. (#2640)
  • Fix clipped group picking for canvas. (#2600)
  • Remove dangling commas, other code clean-up.

vega-schema

  • Remove dangling commas.

vega-time

  • Remove dangling commas.

vega-transforms

  • Remove dangling commas.

v5.12.2

22 May 07:01
Compare
Choose a tag to compare

Changes from v5.12.1:

vega-scenegraph

  • Add canvas handler event listeners necessary for state management. Fixes a regression introduced in v5.12.1. (#2641)

vega-typings

  • Fix typings for locale specification and View API. (thanks @haldenl!)

v5.12.1

19 May 10:23
Compare
Choose a tag to compare

Changes from v5.12.0:

monorepo

  • Switch from Travis CI to GitHub Actions. (thanks @domoritz!)

vega-cli

  • Add tests for vega-cli.

vega-parser

  • Update code style for config constants.

vega-scenegraph

  • Add class to svg root group, localize SVG stylesheet to that class. (#2618)
  • Lazily register CanvasHandler event listeners. By avoiding unneeded listeners, this change avoids a number of passive listener violation warnings. (#2621)

vega-transforms

  • Fix regression of string to number conversion in aggregate sum op. (thanks @haldenl!)

vega-typings

  • Update View typings.
  • Fix missing color schemes in typings. (thanks @domortiz!)

vega-view

  • Code clean up.

v5.12.0

15 May 22:52
Compare
Choose a tag to compare

Notable Additions

  • View-specific locale management for number and date formatting. The View constructor accepts a locale option, and Vega specs support a config.locale property. Locale objects should have number and/or time properties that map to valid d3-format or d3-time-format locale definitions.
  • View toCanvas now accepts an externalContext option to draw into a separately managed canvas instance. For example, one could draw multiple Vega views into the same node-canvas instance for server-side PDF document generation.
  • Initial support for signal-valued axis orient properties. This addition allows the position of an axis (e.g., left versus right) to be dynamically updated at runtime. The feature should be considered experimental; subtle bugs may still arise.
  • Internal refactoring to support content security policy (CSP) in the future. The Vega parser accepts an ast option flag to include generated abstract syntax trees for expressions in the parser output. All Function constructor use for generated code is now consolidated into a single file in the vega-runtime package and could be overridden if an expression AST interpreter is implemented.
  • Bug fixes! See below...

Changelog

Changes from v5.11.1:

vega

  • Update bar-time test specification to test locale config usage.
  • Update budget-forecasts test specification.
  • Update to use refactored runtime context.

vega-cli

  • Update to use locale view constructor option.

vega-dataflow

  • Add locale property to set a dataflow-specific locale for number and date formatting.

vega-encode

  • Update to use centralized locale management. Transforms now access the dataflow-specific locale via the input pulse.

vega-expression

  • Fix handling of this global variable.

vega-format

  • New package for format methods that centralizes locale management.

vega-functions

  • Add centralized locale management. Format functions now access the dataflow-specific locale via the runtime context object, available to expression functions via the this context.
  • Add and export expression parser, support AST export option.
  • Add internal scale functions for use by encoders.
  • Fix scale dependencies: non-literal scale references should depend on all scales.

vega-geo

  • Fix contour, density2D size setter input checks.

vega-loader

  • Add UTC parser parameter to read method.
  • Use the default locale when custom time format parsers are not provided.

vega-parser

  • Internal breaking change: Output runtime specification has changed the encoding of parsed expression functions. Generated code is now wrapped in an object and stored in the code property.
  • Internal breaking change: Generated expression code no longer includes method variable definitions or additional logic. These have been moved to vega-runtime.
  • Add signal support for axis translate property. (Thanks @haldenl!)
  • Add experimental signal support for axis orient property. (Thanks @haldenl!)
  • Add parsing of locale config, include in runtime spec output.
  • Add options argument to parse.
  • Add boolean ast parse option to enable AST output from expression parser.
  • Refactor to use expression parser for synthesized encoder logic.
  • Fix circular dependencies.

vega-runtime

  • Internal breaking change: The runtime now assumes the updated vega-parser output format. All code generation beyond standard expression parser output has now been consolidated into the runtime parsing process.
  • Propagate locale config to runtime context object.
  • Refactor code, add optimized code generation for accessors and comparators.
  • Refactor all non-standard code generation to the runtime context.
  • Fix circular dependencies.

vega-scale

  • Internal breaking change: Update to use centralized locale management. Formatting methods now require a locale parameter as the first argument.
  • Fix valid tick method to sort ticks based on scale range values. (#2579)

vega-scenegraph

  • Add externalContext CanvasRenderer option. (Thanks @pixelspark!)
  • Add resetSVGDefIds to reset gradient and clip id counter. (Thanks @kanitw!)
  • Add SVG style block, set default fill and miter limit values. (#2498)
  • Update SVG test outputs.
  • Update to use centralized locale management. The ARIA caption generators access the dataflow-specific locale via the runtime context object.
  • Update reference to axis orient.
  • Fix SVG radial gradient pattern fill to use style, not fill attribute.
  • Fix ampersand escape in SVG attributes. (#2608)
  • Fix CSS fill inherit for tspan.

vega-schema

  • Add axis translate signal support to schema.
  • Add signal-valued axis orient to schema.

vega-time

  • Internal breaking change: Remove formatting methods, which are now part of vega-format.

vega-transforms

  • Update aggregation ops to no longer use the Function constructor.
  • Update dependencies.

vega-typings

  • Add externalCanvas render option to typings.
  • Add axis translate signal support to typings.
  • Add signal-valued axis orient to typings.

vega-util

  • Update field, key, and compare methods to no longer use the Function constructor.
  • Add optional arguments to inject optimized code generators for accessors and comparators.

vega-view

  • Add locale input options and config handling.
  • Update to use refactored runtime context.

vega-view-transforms

  • Add signal support for axis translate property.
  • Update reference to axis orient.
  • Fix ViewLayout reflow to ensure group bounds are updated. (#2568)
  • Fix grid layout calculations with empty grid input. (#2541)

vega-wordcloud

  • Update dependencies.