Skip to content

Commit

Permalink
Merge pull request #455 from VisActor/release/0.13.2
Browse files Browse the repository at this point in the history
[Auto release] release 0.13.2
  • Loading branch information
xile611 authored May 8, 2024
2 parents 2a75531 + 67a49b5 commit e4fc262
Show file tree
Hide file tree
Showing 21 changed files with 197 additions and 177 deletions.
182 changes: 92 additions & 90 deletions common/config/rush/pnpm-lock.yaml

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion common/config/rush/version-policies.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
[{"definitionName":"lockStepVersion","policyName":"vgrammarMain","version":"0.13.1","mainProject":"@visactor/vgrammar-core","nextBump":"patch"}]
[{"definitionName":"lockStepVersion","policyName":"vgrammarMain","version":"0.13.2","mainProject":"@visactor/vgrammar-core","nextBump":"patch"}]
22 changes: 11 additions & 11 deletions docs/dev-demos/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,24 +11,24 @@
"devDependencies": {
"@internal/eslint-config": "workspace:*",
"@internal/ts-config": "workspace:*",
"@visactor/vutils": "~0.18.5",
"@visactor/vgrammar": "workspace:0.13.1",
"@visactor/vgrammar-core": "workspace:0.13.1",
"@visactor/vgrammar-hierarchy": "workspace:0.13.1",
"@visactor/vgrammar-sankey": "workspace:0.13.1",
"@visactor/vgrammar-projection": "workspace:0.13.1",
"@visactor/vgrammar-wordcloud": "workspace:0.13.1",
"@visactor/vgrammar-wordcloud-shape": "workspace:0.13.1",
"@visactor/vgrammar-plot": "workspace:0.13.1",
"@visactor/vutils": "~0.18.6",
"@visactor/vgrammar": "workspace:0.13.2",
"@visactor/vgrammar-core": "workspace:0.13.2",
"@visactor/vgrammar-hierarchy": "workspace:0.13.2",
"@visactor/vgrammar-sankey": "workspace:0.13.2",
"@visactor/vgrammar-projection": "workspace:0.13.2",
"@visactor/vgrammar-wordcloud": "workspace:0.13.2",
"@visactor/vgrammar-wordcloud-shape": "workspace:0.13.2",
"@visactor/vgrammar-plot": "workspace:0.13.2",
"@visactor/vrender-core": "0.19.0",
"@visactor/vrender-kits": "0.19.0",
"@visactor/vrender": "0.19.0",
"d3-scale-chromatic": "^3.0.0",
"lodash": "4.17.21",
"typescript": "4.9.5",
"vite": "3.2.6",
"@visactor/vgrammar-util": "workspace:0.13.1",
"@visactor/vgrammar-coordinate": "workspace:0.13.1",
"@visactor/vgrammar-util": "workspace:0.13.2",
"@visactor/vgrammar-coordinate": "workspace:0.13.2",
"@vitejs/plugin-react": "3.1.0"
}
}
23 changes: 12 additions & 11 deletions docs/site/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,17 +13,18 @@
},
"dependencies": {
"@arco-design/web-react": "2.46.1",
"@visactor/vutils": "~0.18.5",
"@visactor/vgrammar": "workspace:0.13.1",
"@visactor/vgrammar-core": "workspace:0.13.1",
"@visactor/vgrammar-hierarchy": "workspace:0.13.1",
"@visactor/vgrammar-sankey": "workspace:0.13.1",
"@visactor/vgrammar-projection": "workspace:0.13.1",
"@visactor/vgrammar-wordcloud": "workspace:0.13.1",
"@visactor/vgrammar-wordcloud-shape": "workspace:0.13.1",
"@visactor/vgrammar-plot": "workspace:0.13.1",
"@visactor/vgrammar-util": "workspace:0.13.1",
"@visactor/vgrammar-coordinate": "workspace:0.13.1",
"@visactor/vutils": "~0.18.6",
"@visactor/vgrammar": "workspace:0.13.2",
"@visactor/vgrammar-core": "workspace:0.13.2",
"@visactor/vgrammar-hierarchy": "workspace:0.13.2",
"@visactor/vgrammar-sankey": "workspace:0.13.2",
"@visactor/vgrammar-projection": "workspace:0.13.2",
"@visactor/vgrammar-wordcloud": "workspace:0.13.2",
"@visactor/vgrammar-wordcloud-shape": "workspace:0.13.2",
"@visactor/vgrammar-plot": "workspace:0.13.2",
"@visactor/vgrammar-util": "workspace:0.13.2",
"@visactor/vgrammar-coordinate": "workspace:0.13.2",
"@visactor/vgrammar-venn": "workspace:0.13.2",
"@visactor/vrender-core": "0.19.0",
"@visactor/vrender-kits": "0.19.0",
"@visactor/vrender": "0.19.0",
Expand Down
6 changes: 3 additions & 3 deletions packages/vgrammar-coordinate/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@visactor/vgrammar-coordinate",
"version": "0.13.1",
"version": "0.13.2",
"description": "Coordinates for VGrammar",
"keywords": [
"coordinate",
Expand Down Expand Up @@ -34,8 +34,8 @@
"test-check": "DEBUG=jest jest --forceExit --detectOpenHandles --silent false --verbose false --runInBand"
},
"dependencies": {
"@visactor/vutils": "~0.18.5",
"@visactor/vgrammar-util": "workspace:0.13.1"
"@visactor/vutils": "~0.18.6",
"@visactor/vgrammar-util": "workspace:0.13.2"
},
"devDependencies": {
"@internal/bundler": "workspace:*",
Expand Down
12 changes: 12 additions & 0 deletions packages/vgrammar-core/CHANGELOG.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,18 @@
{
"name": "@visactor/vgrammar-core",
"entries": [
{
"version": "0.13.2",
"tag": "@visactor/vgrammar-core_v0.13.2",
"date": "Wed, 08 May 2024 06:09:28 GMT",
"comments": {
"none": [
{
"comment": "feat: update version of vutils and use `seedRandom`\n\n"
}
]
}
},
{
"version": "0.13.1",
"tag": "@visactor/vgrammar-core_v0.13.1",
Expand Down
11 changes: 10 additions & 1 deletion packages/vgrammar-core/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@
# Change Log - @visactor/vgrammar-core

This log was last generated on Tue, 07 May 2024 07:49:59 GMT and should not be manually modified.
This log was last generated on Wed, 08 May 2024 06:09:28 GMT and should not be manually modified.

## 0.13.2
Wed, 08 May 2024 06:09:28 GMT

### Updates

- feat: update version of vutils and use `seedRandom`



## 0.13.1
Tue, 07 May 2024 07:49:59 GMT
Expand Down
12 changes: 6 additions & 6 deletions packages/vgrammar-core/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@visactor/vgrammar-core",
"version": "0.13.1",
"version": "0.13.2",
"description": "VGrammar is a visual grammar library",
"keywords": [
"grammar",
Expand Down Expand Up @@ -35,11 +35,11 @@
"test-check": "DEBUG=jest jest --forceExit --detectOpenHandles --silent false --verbose false --runInBand"
},
"dependencies": {
"@visactor/vutils": "~0.18.5",
"@visactor/vdataset": "~0.18.5",
"@visactor/vgrammar-coordinate": "workspace:0.13.1",
"@visactor/vgrammar-util": "workspace:0.13.1",
"@visactor/vscale": "~0.18.5",
"@visactor/vutils": "~0.18.6",
"@visactor/vdataset": "~0.18.6",
"@visactor/vgrammar-coordinate": "workspace:0.13.2",
"@visactor/vgrammar-util": "workspace:0.13.2",
"@visactor/vscale": "~0.18.6",
"@visactor/vrender-core": "0.19.0",
"@visactor/vrender-kits": "0.19.0",
"@visactor/vrender-components": "0.19.0"
Expand Down
18 changes: 9 additions & 9 deletions packages/vgrammar-full/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@visactor/vgrammar-full",
"version": "0.13.1",
"version": "0.13.2",
"description": "full packages of vgrammar.",
"keywords": [
"visualization",
Expand Down Expand Up @@ -33,14 +33,14 @@
"test": ""
},
"dependencies": {
"@visactor/vgrammar-core": "workspace:0.13.1",
"@visactor/vgrammar-hierarchy": "workspace:0.13.1",
"@visactor/vgrammar-plot": "workspace:0.13.1",
"@visactor/vgrammar-projection": "workspace:0.13.1",
"@visactor/vgrammar-sankey": "workspace:0.13.1",
"@visactor/vgrammar-wordcloud": "workspace:0.13.1",
"@visactor/vgrammar-wordcloud-shape": "workspace:0.13.1",
"@visactor/vgrammar-venn": "workspace:0.13.1"
"@visactor/vgrammar-core": "workspace:0.13.2",
"@visactor/vgrammar-hierarchy": "workspace:0.13.2",
"@visactor/vgrammar-plot": "workspace:0.13.2",
"@visactor/vgrammar-projection": "workspace:0.13.2",
"@visactor/vgrammar-sankey": "workspace:0.13.2",
"@visactor/vgrammar-wordcloud": "workspace:0.13.2",
"@visactor/vgrammar-wordcloud-shape": "workspace:0.13.2",
"@visactor/vgrammar-venn": "workspace:0.13.2"
},
"devDependencies": {
"d3-array": "1.x",
Expand Down
8 changes: 4 additions & 4 deletions packages/vgrammar-hierarchy/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@visactor/vgrammar-hierarchy",
"version": "0.13.1",
"version": "0.13.2",
"description": "Layout of hierarchical data for VGrammar",
"keywords": [
"hierarchy",
Expand Down Expand Up @@ -38,9 +38,9 @@
"test-check": "DEBUG=jest jest --forceExit --detectOpenHandles --silent false --verbose false --runInBand"
},
"dependencies": {
"@visactor/vutils": "~0.18.5",
"@visactor/vgrammar-core": "workspace:0.13.1",
"@visactor/vgrammar-util": "workspace:0.13.1",
"@visactor/vutils": "~0.18.6",
"@visactor/vgrammar-core": "workspace:0.13.2",
"@visactor/vgrammar-util": "workspace:0.13.2",
"@visactor/vrender-core": "0.19.0",
"@visactor/vrender-kits": "0.19.0"
},
Expand Down
12 changes: 6 additions & 6 deletions packages/vgrammar-plot/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@visactor/vgrammar-plot",
"version": "0.13.1",
"version": "0.13.2",
"description": "Plots of vgrammar.",
"keywords": [
"plot",
Expand Down Expand Up @@ -34,11 +34,11 @@
"test-check": "DEBUG=jest jest --forceExit --detectOpenHandles --silent false --verbose false --runInBand"
},
"dependencies": {
"@visactor/vscale": "~0.18.5",
"@visactor/vutils": "~0.18.5",
"@visactor/vgrammar-util": "workspace:0.13.1",
"@visactor/vgrammar-coordinate": "workspace:0.13.1",
"@visactor/vgrammar-core": "workspace:0.13.1",
"@visactor/vscale": "~0.18.6",
"@visactor/vutils": "~0.18.6",
"@visactor/vgrammar-util": "workspace:0.13.2",
"@visactor/vgrammar-coordinate": "workspace:0.13.2",
"@visactor/vgrammar-core": "workspace:0.13.2",
"@visactor/vrender-components": "0.19.0",
"@visactor/vrender-core": "0.19.0",
"@visactor/vrender-kits": "0.19.0"
Expand Down
8 changes: 4 additions & 4 deletions packages/vgrammar-projection/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@visactor/vgrammar-projection",
"version": "0.13.1",
"version": "0.13.2",
"description": "Projections for map, used in VGrammar.",
"keywords": [
"projection",
Expand Down Expand Up @@ -34,9 +34,9 @@
"test-check": "DEBUG=jest jest --forceExit --detectOpenHandles --silent false --verbose false --runInBand"
},
"dependencies": {
"@visactor/vutils": "~0.18.5",
"@visactor/vgrammar-util": "workspace:0.13.1",
"@visactor/vgrammar-core": "workspace:0.13.1",
"@visactor/vutils": "~0.18.6",
"@visactor/vgrammar-util": "workspace:0.13.2",
"@visactor/vgrammar-core": "workspace:0.13.2",
"d3-geo": "^1.12.1"
},
"devDependencies": {
Expand Down
8 changes: 4 additions & 4 deletions packages/vgrammar-sankey/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@visactor/vgrammar-sankey",
"version": "0.13.1",
"version": "0.13.2",
"description": "Layout of sankey chart, used by VGrammar",
"keywords": [
"sankey",
Expand Down Expand Up @@ -36,9 +36,9 @@
"test-check": "DEBUG=jest jest --forceExit --detectOpenHandles --silent false --verbose false --runInBand"
},
"dependencies": {
"@visactor/vutils": "~0.18.5",
"@visactor/vgrammar-core": "workspace:0.13.1",
"@visactor/vgrammar-util": "workspace:0.13.1",
"@visactor/vutils": "~0.18.6",
"@visactor/vgrammar-core": "workspace:0.13.2",
"@visactor/vgrammar-util": "workspace:0.13.2",
"@visactor/vrender-core": "0.19.0",
"@visactor/vrender-kits": "0.19.0"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/vgrammar-util/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@visactor/vgrammar-util",
"version": "0.13.1",
"version": "0.13.2",
"description": "The common utils functions of VGrammar",
"keywords": [
"utils",
Expand Down Expand Up @@ -34,7 +34,7 @@
"test-check": "DEBUG=jest jest --forceExit --detectOpenHandles --silent false --verbose false --runInBand"
},
"dependencies": {
"@visactor/vutils": "~0.18.5"
"@visactor/vutils": "~0.18.6"
},
"devDependencies": {
"@internal/bundler": "workspace:*",
Expand Down
8 changes: 4 additions & 4 deletions packages/vgrammar-venn/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@visactor/vgrammar-venn",
"version": "0.13.1",
"version": "0.13.2",
"description": "Venn layout transform for VGrammar",
"keywords": [
"venn",
Expand Down Expand Up @@ -34,11 +34,11 @@
"test-check": "DEBUG=jest jest --forceExit --detectOpenHandles --silent false --verbose false --runInBand"
},
"dependencies": {
"@visactor/vgrammar-core": "workspace:0.13.1",
"@visactor/vgrammar-util": "workspace:0.13.1",
"@visactor/vgrammar-core": "workspace:0.13.2",
"@visactor/vgrammar-util": "workspace:0.13.2",
"@visactor/vrender-core": "0.19.0",
"@visactor/vrender-kits": "0.19.0",
"@visactor/vutils": "~0.18.5"
"@visactor/vutils": "~0.18.6"
},
"devDependencies": {
"@internal/bundler": "workspace:*",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @license
*/

import { conjugateGradient, norm2, scale, zeros } from '@visactor/vutils';
import { conjugateGradient, norm2, scale, zeros, seedRandom } from '@visactor/vutils';
import type { VennCircleName, IVennArea, IVennCircle, IVennParams } from '../interface';
import { getDistanceMatrices } from './common';

Expand Down Expand Up @@ -35,8 +35,8 @@ export function constrainedMDSLayout(areas: IVennArea[], params: IVennParams): R
// keep distances bounded, things get messed up otherwise.
// TODO: proper preconditioner?
const norm = norm2(distances.map(norm2)) / distances.length;
distances = distances.map(function (row) {
return row.map(function (value) {
distances = distances.map((row: number[]) => {
return row.map(value => {
return value / norm;
});
});
Expand All @@ -48,7 +48,7 @@ export function constrainedMDSLayout(areas: IVennArea[], params: IVennParams): R
let best;
let current;
for (i = 0; i < restarts; ++i) {
const initial = zeros(distances.length * 2).map(Math.random);
const initial = zeros(distances.length * 2).map((entry: any, i: number) => seedRandom(i));

current = conjugateGradient(obj, initial, params);
if (!best || current.fx < best.fx) {
Expand Down
10 changes: 5 additions & 5 deletions packages/vgrammar-wordcloud-shape/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@visactor/vgrammar-wordcloud-shape",
"version": "0.13.1",
"version": "0.13.2",
"description": "Layout WordCloud in specified shape, this is a transform for VGrammar.",
"keywords": [
"wordcloud",
Expand Down Expand Up @@ -34,10 +34,10 @@
"test-check": "DEBUG=jest jest --forceExit --detectOpenHandles --silent false --verbose false --runInBand"
},
"dependencies": {
"@visactor/vutils": "~0.18.5",
"@visactor/vscale": "~0.18.5",
"@visactor/vgrammar-core": "workspace:0.13.1",
"@visactor/vgrammar-util": "workspace:0.13.1",
"@visactor/vutils": "~0.18.6",
"@visactor/vscale": "~0.18.6",
"@visactor/vgrammar-core": "workspace:0.13.2",
"@visactor/vgrammar-util": "workspace:0.13.2",
"@visactor/vrender-core": "0.19.0",
"@visactor/vrender-kits": "0.19.0"
},
Expand Down
8 changes: 4 additions & 4 deletions packages/vgrammar-wordcloud/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@visactor/vgrammar-wordcloud",
"version": "0.13.1",
"version": "0.13.2",
"description": "WordCloud layout transform for VGrammar",
"keywords": [
"wordcloud",
Expand Down Expand Up @@ -34,9 +34,9 @@
"test-check": "DEBUG=jest jest --forceExit --detectOpenHandles --silent false --verbose false --runInBand"
},
"dependencies": {
"@visactor/vutils": "~0.18.5",
"@visactor/vgrammar-core": "workspace:0.13.1",
"@visactor/vgrammar-util": "workspace:0.13.1",
"@visactor/vutils": "~0.18.6",
"@visactor/vgrammar-core": "workspace:0.13.2",
"@visactor/vgrammar-util": "workspace:0.13.2",
"@visactor/vrender-core": "0.19.0",
"@visactor/vrender-kits": "0.19.0"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/vgrammar-wordcloud/src/base.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { array, degreeToRadian, isFunction, isNil, merge } from '@visactor/vutils';
import { array, degreeToRadian, isFunction, isNil, merge, seedRandom } from '@visactor/vutils';
import type { IProgressiveTransformResult } from '@visactor/vgrammar-core';
import type { IBaseLayoutOptions, TagItemFunction, TagOutputItem } from './interface';
import { getShapeFunction } from './shapes';
import { functor, randomHslColor, seedRandom } from './util';
import { functor, randomHslColor } from './util';

export abstract class BaseLayout<T extends IBaseLayoutOptions> implements IProgressiveTransformResult {
static defaultOptions: Partial<IBaseLayoutOptions> = {
Expand Down
4 changes: 0 additions & 4 deletions packages/vgrammar-wordcloud/src/util.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,3 @@ export function functor(d: any) {
return d;
};
}

export function seedRandom(seed: number) {
return parseFloat('0.' + Math.sin(seed).toString().substring(6));
}
Loading

0 comments on commit e4fc262

Please sign in to comment.