@d3plus/core 3.0.4 → 3.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +80 -87
- package/es/src/charts/BoxWhisker.js +0 -4
- package/es/src/charts/Plot.js +1 -3
- package/es/src/charts/Viz.js +1 -1
- package/es/src/components/Axis.js +3 -2
- package/package.json +8 -8
- package/umd/d3plus-core.full.js +6 -7
- package/umd/d3plus-core.full.js.map +1 -1
- package/umd/d3plus-core.full.min.js +9 -9
- package/umd/d3plus-core.js +5 -6
- package/umd/d3plus-core.js.map +1 -1
- package/umd/d3plus-core.min.js +5 -5
|
@@ -89,8 +89,4 @@ var BoxWhisker = /*#__PURE__*/ function(Plot) {
|
|
|
89
89
|
@class BoxWhisker
|
|
90
90
|
@extends Plot
|
|
91
91
|
@desc Creates a simple box and whisker based on an array of data.
|
|
92
|
-
@example <caption>the equivalent of calling:</caption>
|
|
93
|
-
new d3plus.Plot()
|
|
94
|
-
.discrete("x")
|
|
95
|
-
.shape("Box")
|
|
96
92
|
*/ export { BoxWhisker as default };
|
package/es/src/charts/Plot.js
CHANGED
|
@@ -478,9 +478,7 @@ var Plot = /*#__PURE__*/ function(Viz) {
|
|
|
478
478
|
_this._x2Key = "x2";
|
|
479
479
|
_this._x2Axis = new AxisTop().align("start");
|
|
480
480
|
_this._x2Test = new AxisTop().align("start").gridSize(0);
|
|
481
|
-
_this._x2Config = {
|
|
482
|
-
padding: 0
|
|
483
|
-
};
|
|
481
|
+
_this._x2Config = {};
|
|
484
482
|
_this._y = accessor("y");
|
|
485
483
|
_this._yKey = "y";
|
|
486
484
|
_this._yAxis = new AxisLeft().align("start");
|
package/es/src/charts/Viz.js
CHANGED
|
@@ -154,7 +154,7 @@ import { assign, attrize, date, elem, rtl as detectRTL } from "@d3plus/dom";
|
|
|
154
154
|
import { formatAbbreviate, formatDate } from "@d3plus/format";
|
|
155
155
|
import { formatLocale, locale } from "@d3plus/locales";
|
|
156
156
|
import { closest } from "@d3plus/math";
|
|
157
|
-
import { textWrap } from "@d3plus/text";
|
|
157
|
+
import { fontFamily as d3plusFontFamily, textWrap } from "@d3plus/text";
|
|
158
158
|
import { TextBox } from "../components/index.js";
|
|
159
159
|
import * as shapes from "../shapes/index.js";
|
|
160
160
|
import { configPrep, BaseClass, constant } from "../utils/index.js";
|
|
@@ -894,7 +894,8 @@ var Axis = /*#__PURE__*/ function(BaseClass) {
|
|
|
894
894
|
function createTextData() {
|
|
895
895
|
var _this = this;
|
|
896
896
|
var offset = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 1;
|
|
897
|
-
var
|
|
897
|
+
var fontSize = this._shapeConfig.labelConfig.fontSize;
|
|
898
|
+
var fontFamily = this._shapeConfig.labelConfig.fontFamily || d3plusFontFamily;
|
|
898
899
|
var fontPadding = this._shapeConfig.labelConfig.padding;
|
|
899
900
|
/**
|
|
900
901
|
* Calculates the space each label would take up, given
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@d3plus/core",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.5",
|
|
4
4
|
"description": "Data visualization made easy. A javascript library that extends the popular D3.js to enable fast and beautiful visualizations.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -34,13 +34,13 @@
|
|
|
34
34
|
"test": "eslint index.js src/**/*.js && eslint --global=it test && mocha 'test/**/*-test.js'"
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"@d3plus/color": "3.0.
|
|
38
|
-
"@d3plus/data": "3.0.
|
|
39
|
-
"@d3plus/dom": "3.0.
|
|
40
|
-
"@d3plus/format": "3.0.
|
|
41
|
-
"@d3plus/locales": "3.0.
|
|
42
|
-
"@d3plus/math": "3.0.
|
|
43
|
-
"@d3plus/text": "3.0.
|
|
37
|
+
"@d3plus/color": "3.0.5",
|
|
38
|
+
"@d3plus/data": "3.0.5",
|
|
39
|
+
"@d3plus/dom": "3.0.5",
|
|
40
|
+
"@d3plus/format": "3.0.5",
|
|
41
|
+
"@d3plus/locales": "3.0.5",
|
|
42
|
+
"@d3plus/math": "3.0.5",
|
|
43
|
+
"@d3plus/text": "3.0.5",
|
|
44
44
|
"@popperjs/core": "^2.11.8",
|
|
45
45
|
"d3-array": "^3.2.4",
|
|
46
46
|
"d3-brush": "^3.0.0",
|
package/umd/d3plus-core.full.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
@d3plus/core v3.0.
|
|
2
|
+
@d3plus/core v3.0.5
|
|
3
3
|
Data visualization made easy. A javascript library that extends the popular D3.js to enable fast and beautiful visualizations.
|
|
4
4
|
Copyright (c) 2025 D3plus - https://d3plus.org
|
|
5
5
|
@license MIT
|
|
@@ -27030,13 +27030,14 @@
|
|
|
27030
27030
|
}
|
|
27031
27031
|
let textData = [];
|
|
27032
27032
|
function createTextData(offset = 1) {
|
|
27033
|
-
const {
|
|
27033
|
+
const { fontSize } = this._shapeConfig.labelConfig;
|
|
27034
|
+
const fontFamily$1 = this._shapeConfig.labelConfig.fontFamily || fontFamily;
|
|
27034
27035
|
const fontPadding = this._shapeConfig.labelConfig.padding;
|
|
27035
27036
|
/**
|
|
27036
27037
|
* Calculates the space each label would take up, given
|
|
27037
27038
|
* the provided this._space size.
|
|
27038
27039
|
*/ textData = labels.map((d, i)=>{
|
|
27039
|
-
const fF = typeof fontFamily === "function" ? fontFamily(d, i) : fontFamily, fP = typeof fontPadding === "function" ? fontPadding(d, i) : fontPadding, fS = typeof fontSize === "function" ? fontSize(d, i) : fontSize, position = this._getPosition(d);
|
|
27040
|
+
const fF = typeof fontFamily$1 === "function" ? fontFamily$1(d, i) : fontFamily$1, fP = typeof fontPadding === "function" ? fontPadding(d, i) : fontPadding, fS = typeof fontSize === "function" ? fontSize(d, i) : fontSize, position = this._getPosition(d);
|
|
27040
27041
|
const lineHeight = this._shapeConfig.lineHeight ? this._shapeConfig.lineHeight(d, i) : fS * 1.4;
|
|
27041
27042
|
const datum = {
|
|
27042
27043
|
d,
|
|
@@ -34819,7 +34820,7 @@
|
|
|
34819
34820
|
else {
|
|
34820
34821
|
if (!this._aggs[k]) {
|
|
34821
34822
|
this._aggs[k] = (a, c)=>{
|
|
34822
|
-
const v = unique(a.map(c)
|
|
34823
|
+
const v = unique(a.map(c));
|
|
34823
34824
|
return v.length === 1 ? v[0] : v;
|
|
34824
34825
|
};
|
|
34825
34826
|
}
|
|
@@ -37526,9 +37527,7 @@
|
|
|
37526
37527
|
this._x2Key = "x2";
|
|
37527
37528
|
this._x2Axis = new AxisTop().align("start");
|
|
37528
37529
|
this._x2Test = new AxisTop().align("start").gridSize(0);
|
|
37529
|
-
this._x2Config = {
|
|
37530
|
-
padding: 0
|
|
37531
|
-
};
|
|
37530
|
+
this._x2Config = {};
|
|
37532
37531
|
this._y = accessor("y");
|
|
37533
37532
|
this._yKey = "y";
|
|
37534
37533
|
this._yAxis = new AxisLeft().align("start");
|