-
Notifications
You must be signed in to change notification settings - Fork 623
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
361 changed files
with
37,867 additions
and
0 deletions.
There are no files selected for viewing
Empty file.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Empty file.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,119 @@ | ||
{ | ||
"name": "vega-lite", | ||
"author": "Jeffrey Heer, Dominik Moritz, Kanit \"Ham\" Wongsuphasawat", | ||
"version": "2.0.0-beta.5", | ||
"collaborators": [ | ||
"Kanit Wongsuphasawat <[email protected]> (http://kanitw.yellowpigz.com)", | ||
"Dominik Moritz <[email protected]> (https://www.domoritz.de)", | ||
"Jeffrey Heer <[email protected]> (http://jheer.org)" | ||
], | ||
"homepage": "https://vega.github.io/vega-lite/", | ||
"description": "Vega-lite provides a higher-level grammar for visual analysis, comparable to ggplot or Tableau, that generates complete Vega specifications.", | ||
"main": "build/src/vl.js", | ||
"types": "build/src/vl.d.ts", | ||
"bin": { | ||
"vl2png": "./bin/vl2png", | ||
"vl2svg": "./bin/vl2svg", | ||
"vl2vg": "./bin/vl2vg" | ||
}, | ||
"directories": { | ||
"test": "test" | ||
}, | ||
"scripts": { | ||
"pretsc": "mkdir -p build && rm -rf build/*/** && cp package.json build/", | ||
"tsc": "tsc", | ||
"prebuild": "mkdir -p build/site build/examples/images build/test-gallery", | ||
"build": "npm run tsc && cp package.json build && browserify src/vl.ts -p tsify -d -s vl | exorcist build/vega-lite.js.map > build/vega-lite.js", | ||
"postbuild": "uglifyjs build/vega-lite.js -cm --source-map content=build/vega-lite.js.map,filename=build/vega-lite.min.js.map -o build/vega-lite.min.js && npm run schema", | ||
"build:examples": "npm run build && npm run build:examples-only", | ||
"build:examples-only": "./scripts/build-examples.sh && rm -rf examples/specs/normalized/* && scripts/build-normalized-examples", | ||
"build:images": "npm run data && scripts/generate-images.sh", | ||
"build:toc": "bundle exec jekyll build -q && scripts/generate-toc", | ||
"build:site": "browserify site/static/main.ts -p [tsify -p site] -d | exorcist build/site/main.js.map > build/site/main.js", | ||
"build:versions": "scripts/update-version.sh", | ||
"build:test-gallery": "browserify test-gallery/main.ts -p [tsify -p test-gallery] -d > build/test-gallery/main.js", | ||
"check:examples": "scripts/check-examples.sh", | ||
"check:schema": "scripts/check-schema.sh", | ||
"clean": "rm -rf build && rm -f vega-lite.* & find -E src test site examples -regex '.*\\.(js|js.map|d.ts|vg.json)' -delete & rm -rf data", | ||
"data": "rsync -r node_modules/vega-datasets/data/* data", | ||
"link": "npm link && npm link vega-lite", | ||
|
||
"deploy": "scripts/deploy.sh", | ||
"deploy:gh": "scripts/deploy-gh.sh", | ||
"deploy:schema": "scripts/deploy-schema.sh", | ||
|
||
"prestart": "npm run data && npm run build && scripts/index-examples", | ||
"start": "nodemon -x 'npm run build:test-gallery' & browser-sync start --server --files 'build/test-gallery/main.js' --index 'test-gallery/index.html'", | ||
"poststart": "rm examples/all-examples.json", | ||
|
||
"preschema": "npm run prebuild", | ||
"schema": "typescript-to-json-schema --path tsconfig.json --type TopLevelExtendedSpec > build/vega-lite-schema.json && npm run renameschema && cp build/vega-lite-schema.json _data/", | ||
"renameschema": "scripts/rename-schema.sh", | ||
"presite": "npm run build && npm run data && npm run build:site && npm run build:toc && npm run build:versions", | ||
"site": "bundle exec jekyll serve", | ||
|
||
"lint": "tslint --project tsconfig.json -c tslint.json --type-check", | ||
"test": "npm run tsc && npm run test:only && npm run lint", | ||
"posttest": "npm run schema && npm run data && npm run mocha:examples", | ||
"test:nocompile": "npm run test:only && npm run lint && npm run mocha:examples", | ||
"test:only": "nyc --reporter=html --reporter=text-summary npm run mocha:test", | ||
"test:debug": "npm run tsc && mocha --recursive --debug-brk --inspect build/test", | ||
"test:debug-examples": "npm run tsc && npm run schema && mocha --recursive --debug-brk --inspect build/examples", | ||
"mocha:test": "mocha --require source-map-support/register --reporter dot --recursive build/test", | ||
"mocha:examples": "mocha --require source-map-support/register --reporter dot --recursive build/examples", | ||
|
||
"codecov": "nyc report --reporter=json && codecov -f coverage/*.json", | ||
"watch:build": "watchify src/vl.ts -p tsify -v -d -s vl -o 'exorcist build/vega-lite.js.map > build/vega-lite.js'", | ||
"watch:tsc": "npm run tsc -- -w", | ||
"watch:test": "nodemon -x 'npm test'", | ||
"watch": "nodemon -x 'npm run build && npm run test:nocompile' # already ran schema in build" | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/vega/vega-lite.git" | ||
}, | ||
"license": "BSD-3-Clause", | ||
"bugs": { | ||
"url": "https://github.com/vega/vega-lite/issues" | ||
}, | ||
"devDependencies": { | ||
"@types/chai": "^4.0.0", | ||
"@types/d3": "^4.9.0", | ||
"@types/highlight.js": "^9.1.9", | ||
"@types/json-stable-stringify": "^1.0.31", | ||
"@types/mocha": "^2.2.41", | ||
"@types/node": "^7.0.28", | ||
"ajv": "5.1.5", | ||
"browser-sync": "^2.18.12", | ||
"browserify": "^14.4.0", | ||
"browserify-shim": "^3.8.14", | ||
"chai": "^4.0.2", | ||
"cheerio": "^1.0.0-rc.1", | ||
"codecov": "^2.2.0", | ||
"d3": "^4.9.1", | ||
"exorcist": "^0.4.0", | ||
"highlight.js": "^9.12.0", | ||
"mocha": "^3.4.2", | ||
"nodemon": "^1.11.0", | ||
"nyc": "^11.0.2", | ||
"source-map-support": "^0.4.15", | ||
"tsify": "^3.0.1", | ||
"tslint": "^5.4.3", | ||
"tslint-eslint-rules": "^4.1.1", | ||
"typescript": "^2.3.4", | ||
"typescript-to-json-schema": "vega/typescript-to-json-schema#v0.5.0", | ||
"uglify-js": "^3.0.15", | ||
"vega": "3.0.0-beta.33", | ||
"vega-datasets": "vega/vega-datasets#gh-pages", | ||
"vega-embed": "3.0.0-beta.17", | ||
"watchify": "^3.9.0", | ||
"yaml-front-matter": "^3.4.0" | ||
}, | ||
"dependencies": { | ||
"json-stable-stringify": "^1.0.1", | ||
"tslib": "^1.7.1", | ||
"vega-event-selector": "^2.0.0-beta", | ||
"vega-util": "^1.3.0", | ||
"yargs": "^8.0.1" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
export declare type AggregateOp = 'argmax' | 'argmin' | 'average' | 'count' | 'distinct' | 'max' | 'mean' | 'median' | 'min' | 'missing' | 'modeskew' | 'q1' | 'q3' | 'ci0' | 'ci1' | 'stdev' | 'stdevp' | 'sum' | 'valid' | 'values' | 'variance' | 'variancep'; | ||
export declare const AGGREGATE_OPS: AggregateOp[]; | ||
export declare const AGGREGATE_OP_INDEX: { | ||
[T: string]: boolean; | ||
}; | ||
/** Additive-based aggregation operations. These can be applied to stack. */ | ||
export declare const SUM_OPS: AggregateOp[]; | ||
/** | ||
* Aggregation operators that always produce values within the range [domainMin, domainMax]. | ||
*/ | ||
export declare const SHARED_DOMAIN_OPS: AggregateOp[]; | ||
export declare const SHARED_DOMAIN_OP_INDEX: { | ||
[T: string]: boolean; | ||
}; |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,114 @@ | ||
import { DateTime } from './datetime'; | ||
import { Guide, GuideEncodingEntry, VlOnlyGuideConfig } from './guide'; | ||
import { VgAxisBase, VgAxisConfig } from './vega.schema'; | ||
export declare type AxisOrient = 'top' | 'right' | 'left' | 'bottom'; | ||
export interface AxisConfig extends VgAxisConfig, VlOnlyGuideConfig { | ||
} | ||
export interface Axis extends VgAxisBase, Guide { | ||
/** | ||
* The padding, in pixels, between axis and text labels. | ||
*/ | ||
labelPadding?: number; | ||
/** | ||
* The orientation of the axis. One of top, bottom, left or right. The orientation can be used to further specialize the axis type (e.g., a y axis oriented for the right edge of the chart). | ||
* | ||
* __Default value:__ `"x"` axis is placed on the bottom, `"y"` axis is placed on the left, `"column"`"s x-axis is placed on the top, `"row"`s y-axis is placed on the right. | ||
*/ | ||
orient?: AxisOrient; | ||
/** | ||
* The offset, in pixels, by which to displace the axis from the edge of the enclosing group or data rectangle. | ||
* | ||
* __Default value:__ derived from [axis config](config.html#facet-scale-config)'s `offset` (`0` by default) | ||
*/ | ||
offset?: number; | ||
/** | ||
* The anchor position of the axis in pixels. For x-axis with top or bottom orientation, this sets the axis group x coordinate. For y-axis with left or right orientation, this sets the axis group y coordinate. | ||
* | ||
* __Default value__: `0` | ||
*/ | ||
position?: number; | ||
/** | ||
* A desired number of ticks, for axes visualizing quantitative scales. The resulting number may be different so that values are "nice" (multiples of 2, 5, 10) and lie within the underlying scale's range. | ||
* @minimum 0 | ||
* @TJS-type integer | ||
*/ | ||
tickCount?: number; | ||
/** | ||
* Explicitly set the visible axis tick values. | ||
*/ | ||
values?: number[] | DateTime[]; | ||
/** | ||
* A non-positive integer indicating z-index of the axis. | ||
* If zindex is 0, axes should be drawn behind all chart elements. | ||
* To put them in front, use `"zindex = 1"`. | ||
* | ||
* __Default value:__ `0` (Behind the marks.) | ||
* | ||
* @TJS-type integer | ||
* @minimum 0 | ||
*/ | ||
zindex?: number; | ||
/** | ||
* Optional mark definitions for custom axis encoding. | ||
*/ | ||
encoding?: AxisEncoding; | ||
} | ||
export interface AxisEncoding { | ||
/** | ||
* Custom encoding for the axis container. | ||
*/ | ||
axis?: GuideEncodingEntry; | ||
/** | ||
* Custom encoding for the axis domain rule mark. | ||
*/ | ||
domain?: GuideEncodingEntry; | ||
/** | ||
* Custom encoding for axis gridline rule marks. | ||
*/ | ||
grid?: GuideEncodingEntry; | ||
/** | ||
* Custom encoding for axis label text marks. | ||
*/ | ||
labels?: GuideEncodingEntry; | ||
/** | ||
* Custom encoding for axis tick rule marks. | ||
*/ | ||
ticks?: GuideEncodingEntry; | ||
/** | ||
* Custom encoding for the axis title text mark. | ||
*/ | ||
title?: GuideEncodingEntry; | ||
} | ||
export declare const AXIS_PROPERTIES: (keyof Axis)[]; | ||
export interface AxisConfigMixins { | ||
/** Generic axis config. */ | ||
axis?: AxisConfig; | ||
/** | ||
* X-axis specific config. | ||
*/ | ||
axisX?: VgAxisConfig; | ||
/** | ||
* Y-axis specific config. | ||
*/ | ||
axisY?: VgAxisConfig; | ||
/** | ||
* Specific axis config for y-axis along the left edge of the chart. | ||
*/ | ||
axisLeft?: VgAxisConfig; | ||
/** | ||
* Specific axis config for y-axis along the right edge of the chart. | ||
*/ | ||
axisRight?: VgAxisConfig; | ||
/** | ||
* Specific axis config for x-axis along the top edge of the chart. | ||
*/ | ||
axisTop?: VgAxisConfig; | ||
/** | ||
* Specific axis config for x-axis along the bottom edge of the chart. | ||
*/ | ||
axisBottom?: VgAxisConfig; | ||
/** | ||
* Specific axis config for axes with "band" scales. | ||
*/ | ||
axisBand?: VgAxisConfig; | ||
} |
Oops, something went wrong.