@unovis/ts 1.4.0 → 1.4.1-alpha.0
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/components/bullet-legend/config.d.ts +7 -1
- package/components/bullet-legend/config.js +3 -1
- package/components/bullet-legend/config.js.map +1 -1
- package/components/bullet-legend/index.d.ts +1 -1
- package/components/bullet-legend/index.js +8 -7
- package/components/bullet-legend/index.js.map +1 -1
- package/components/bullet-legend/modules/shape.d.ts +2 -2
- package/components/bullet-legend/modules/shape.js.map +1 -1
- package/components/bullet-legend/style.d.ts +1 -0
- package/components/bullet-legend/style.js +8 -2
- package/components/bullet-legend/style.js.map +1 -1
- package/components/bullet-legend/types.d.ts +4 -0
- package/components/bullet-legend/types.js +7 -2
- package/components/bullet-legend/types.js.map +1 -1
- package/index.js +1 -1
- package/package.json +1 -1
- package/types.js +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { GenericAccessor } from "../../types/accessor";
|
|
2
|
-
import { BulletLegendItemInterface, BulletShape } from './types';
|
|
2
|
+
import { BulletLegendItemInterface, BulletShape, BulletLegendOrientation } from './types';
|
|
3
3
|
export interface BulletLegendConfigInterface {
|
|
4
4
|
/** Legend items. Array of `BulletLegendItemInterface`:
|
|
5
5
|
* ```
|
|
@@ -26,5 +26,11 @@ export interface BulletLegendConfigInterface {
|
|
|
26
26
|
bulletSize?: string | null;
|
|
27
27
|
/** Bullet shape enum value or accessor function. Default: `d => d.shape ?? BulletShape.Circle */
|
|
28
28
|
bulletShape?: GenericAccessor<BulletShape, BulletLegendItemInterface>;
|
|
29
|
+
/** Legend orientation. When set to `BulletLegendOrientation.Horizontal`, each legend item will
|
|
30
|
+
* start on a new line. Default: `BulletLegendOrientation.Horizontal` */
|
|
31
|
+
orientation?: BulletLegendOrientation | string;
|
|
32
|
+
/** If set to true, the legend will be rendered directly into the HTML element provided to the constructor
|
|
33
|
+
* without creating additional `div` element. Default: `false` */
|
|
34
|
+
renderIntoProvidedDomNode?: boolean;
|
|
29
35
|
}
|
|
30
36
|
export declare const BulletLegendDefaultConfig: BulletLegendConfigInterface;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BulletShape } from './types.js';
|
|
1
|
+
import { BulletShape, BulletLegendOrientation } from './types.js';
|
|
2
2
|
|
|
3
3
|
const BulletLegendDefaultConfig = {
|
|
4
4
|
items: [],
|
|
@@ -8,6 +8,8 @@ const BulletLegendDefaultConfig = {
|
|
|
8
8
|
labelMaxWidth: null,
|
|
9
9
|
bulletSize: null,
|
|
10
10
|
bulletShape: d => { var _a; return (_a = d.shape) !== null && _a !== void 0 ? _a : BulletShape.Circle; },
|
|
11
|
+
orientation: BulletLegendOrientation.Horizontal,
|
|
12
|
+
renderIntoProvidedDomNode: false,
|
|
11
13
|
};
|
|
12
14
|
|
|
13
15
|
export { BulletLegendDefaultConfig };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.js","sources":["../../../src/components/bullet-legend/config.ts"],"sourcesContent":["// Local Types\nimport { GenericAccessor } from 'types/accessor'\nimport { BulletLegendItemInterface, BulletShape } from './types'\n\nexport interface BulletLegendConfigInterface {\n /** Legend items. Array of `BulletLegendItemInterface`:\n * ```\n * {\n * name: string | number;\n * color?: string;\n * shape?: BulletShape;\n * inactive?: boolean;\n * hidden?: boolean;\n * pointer?: boolean;\n * }\n * ```\n * Default: `[]` */\n items: BulletLegendItemInterface[];\n /** Apply a specific class to the labels. Default: `''` */\n labelClassName?: string;\n /** Callback function for the legend item click. Default: `undefined` */\n onLegendItemClick?: ((d: BulletLegendItemInterface, i: number) => void);\n /** Label text (<span> element) font-size CSS. Default: `null` */\n labelFontSize?: string | null;\n /** Label text (<span> element) max-width CSS property. Default: `null` */\n labelMaxWidth?: string | null;\n /** Bullet shape size, mapped to the width and height CSS properties. Default: `null` */\n bulletSize?: string | null;\n /** Bullet shape enum value or accessor function. Default: `d => d.shape ?? BulletShape.Circle */\n bulletShape?: GenericAccessor<BulletShape, BulletLegendItemInterface>;\n}\n\nexport const BulletLegendDefaultConfig: BulletLegendConfigInterface = {\n items: [],\n labelClassName: '',\n onLegendItemClick: undefined,\n labelFontSize: null,\n labelMaxWidth: null,\n bulletSize: null,\n bulletShape: d => d.shape ?? BulletShape.Circle,\n}\n"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"config.js","sources":["../../../src/components/bullet-legend/config.ts"],"sourcesContent":["// Local Types\nimport { GenericAccessor } from 'types/accessor'\nimport { BulletLegendItemInterface, BulletShape, BulletLegendOrientation } from './types'\n\nexport interface BulletLegendConfigInterface {\n /** Legend items. Array of `BulletLegendItemInterface`:\n * ```\n * {\n * name: string | number;\n * color?: string;\n * shape?: BulletShape;\n * inactive?: boolean;\n * hidden?: boolean;\n * pointer?: boolean;\n * }\n * ```\n * Default: `[]` */\n items: BulletLegendItemInterface[];\n /** Apply a specific class to the labels. Default: `''` */\n labelClassName?: string;\n /** Callback function for the legend item click. Default: `undefined` */\n onLegendItemClick?: ((d: BulletLegendItemInterface, i: number) => void);\n /** Label text (<span> element) font-size CSS. Default: `null` */\n labelFontSize?: string | null;\n /** Label text (<span> element) max-width CSS property. Default: `null` */\n labelMaxWidth?: string | null;\n /** Bullet shape size, mapped to the width and height CSS properties. Default: `null` */\n bulletSize?: string | null;\n /** Bullet shape enum value or accessor function. Default: `d => d.shape ?? BulletShape.Circle */\n bulletShape?: GenericAccessor<BulletShape, BulletLegendItemInterface>;\n /** Legend orientation. When set to `BulletLegendOrientation.Horizontal`, each legend item will\n * start on a new line. Default: `BulletLegendOrientation.Horizontal` */\n orientation?: BulletLegendOrientation | string;\n /** If set to true, the legend will be rendered directly into the HTML element provided to the constructor\n * without creating additional `div` element. Default: `false` */\n renderIntoProvidedDomNode?: boolean;\n}\n\nexport const BulletLegendDefaultConfig: BulletLegendConfigInterface = {\n items: [],\n labelClassName: '',\n onLegendItemClick: undefined,\n labelFontSize: null,\n labelMaxWidth: null,\n bulletSize: null,\n bulletShape: d => d.shape ?? BulletShape.Circle,\n orientation: BulletLegendOrientation.Horizontal,\n renderIntoProvidedDomNode: false,\n}\n"],"names":[],"mappings":";;AAsCa,MAAA,yBAAyB,GAAgC;AACpE,IAAA,KAAK,EAAE,EAAE;AACT,IAAA,cAAc,EAAE,EAAE;AAClB,IAAA,iBAAiB,EAAE,SAAS;AAC5B,IAAA,aAAa,EAAE,IAAI;AACnB,IAAA,aAAa,EAAE,IAAI;AACnB,IAAA,UAAU,EAAE,IAAI;AAChB,IAAA,WAAW,EAAE,CAAC,cAAI,OAAA,CAAA,EAAA,GAAA,CAAC,CAAC,KAAK,MAAI,IAAA,IAAA,EAAA,KAAA,KAAA,CAAA,GAAA,EAAA,GAAA,WAAW,CAAC,MAAM,CAAA,EAAA;IAC/C,WAAW,EAAE,uBAAuB,CAAC,UAAU;AAC/C,IAAA,yBAAyB,EAAE,KAAK;;;;;"}
|
|
@@ -6,7 +6,7 @@ export declare class BulletLegend {
|
|
|
6
6
|
static selectors: typeof s;
|
|
7
7
|
protected _defaultConfig: BulletLegendConfigInterface;
|
|
8
8
|
config: BulletLegendConfigInterface;
|
|
9
|
-
div: Selection<
|
|
9
|
+
div: Selection<HTMLElement, unknown, null, undefined>;
|
|
10
10
|
element: HTMLElement;
|
|
11
11
|
prevConfig: BulletLegendConfigInterface;
|
|
12
12
|
protected _container: HTMLElement;
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import { select } from 'd3-selection';
|
|
2
|
+
import { cx } from '@emotion/css';
|
|
2
3
|
import { merge } from '../../utils/data.js';
|
|
3
4
|
import { BulletLegendDefaultConfig } from './config.js';
|
|
5
|
+
import { BulletLegendOrientation } from './types.js';
|
|
4
6
|
import { createBullets, updateBullets } from './modules/shape.js';
|
|
5
7
|
import * as style from './style.js';
|
|
6
|
-
import { root, item, clickable, bullet, label } from './style.js';
|
|
8
|
+
import { root, item, itemVertical, clickable, bullet, label } from './style.js';
|
|
7
9
|
|
|
8
10
|
class BulletLegend {
|
|
9
11
|
constructor(element, config) {
|
|
@@ -11,10 +13,8 @@ class BulletLegend {
|
|
|
11
13
|
this.config = this._defaultConfig;
|
|
12
14
|
this._colorAccessor = (d) => d.color;
|
|
13
15
|
this._container = element;
|
|
14
|
-
|
|
15
|
-
this.div
|
|
16
|
-
.append('div')
|
|
17
|
-
.attr('class', root);
|
|
16
|
+
this.div = (config === null || config === void 0 ? void 0 : config.renderIntoProvidedDomNode) ? select(this._container) : select(this._container).append('div');
|
|
17
|
+
this.div.attr('class', root);
|
|
18
18
|
this.element = this.div.node();
|
|
19
19
|
if (config)
|
|
20
20
|
this.update(config);
|
|
@@ -28,7 +28,7 @@ class BulletLegend {
|
|
|
28
28
|
const { config } = this;
|
|
29
29
|
const legendItems = this.div.selectAll(`.${item}`).data(config.items);
|
|
30
30
|
const legendItemsEnter = legendItems.enter().append('div')
|
|
31
|
-
.attr('class', d =>
|
|
31
|
+
.attr('class', d => cx(item, config.orientation === BulletLegendOrientation.Vertical && itemVertical, d.className))
|
|
32
32
|
.on('click', this._onItemClick.bind(this));
|
|
33
33
|
const legendItemsMerged = legendItemsEnter.merge(legendItems);
|
|
34
34
|
legendItemsMerged
|
|
@@ -64,7 +64,8 @@ class BulletLegend {
|
|
|
64
64
|
onLegendItemClick(d, index);
|
|
65
65
|
}
|
|
66
66
|
destroy() {
|
|
67
|
-
this.
|
|
67
|
+
if (this.element !== this._container)
|
|
68
|
+
this.div.remove();
|
|
68
69
|
}
|
|
69
70
|
}
|
|
70
71
|
BulletLegend.selectors = style;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../src/components/bullet-legend/index.ts"],"sourcesContent":["import { select, Selection } from 'd3-selection'\n\n// Utils\nimport { merge } from 'utils/data'\n\n// Config\nimport { BulletLegendDefaultConfig, BulletLegendConfigInterface } from './config'\n\n// Local Types\nimport { BulletLegendItemInterface } from './types'\n\n// Modules\nimport { createBullets, updateBullets } from './modules/shape'\n\n// Styles\nimport * as s from './style'\n\
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../src/components/bullet-legend/index.ts"],"sourcesContent":["import { select, Selection } from 'd3-selection'\nimport { cx } from '@emotion/css'\n\n// Utils\nimport { merge } from 'utils/data'\n\n// Config\nimport { BulletLegendDefaultConfig, BulletLegendConfigInterface } from './config'\n\n// Local Types\nimport { BulletLegendItemInterface, BulletLegendOrientation } from './types'\n\n// Modules\nimport { createBullets, updateBullets } from './modules/shape'\n\n// Styles\nimport * as s from './style'\n\nexport class BulletLegend {\n static selectors = s\n protected _defaultConfig = BulletLegendDefaultConfig as BulletLegendConfigInterface\n public config: BulletLegendConfigInterface = this._defaultConfig\n\n div: Selection<HTMLElement, unknown, null, undefined>\n element: HTMLElement\n prevConfig: BulletLegendConfigInterface\n protected _container: HTMLElement\n\n private _colorAccessor = (d: BulletLegendItemInterface): string => d.color\n\n constructor (element: HTMLElement, config?: BulletLegendConfigInterface) {\n this._container = element\n\n this.div = config?.renderIntoProvidedDomNode ? select(this._container) : select(this._container).append<HTMLElement>('div')\n this.div.attr('class', s.root)\n\n this.element = this.div.node()\n\n if (config) this.update(config)\n }\n\n update (config: BulletLegendConfigInterface): void {\n this.prevConfig = this.config\n this.config = merge(this._defaultConfig, config)\n this.render()\n }\n\n render (): void {\n const { config } = this\n\n const legendItems = this.div.selectAll<HTMLDivElement, unknown>(`.${s.item}`).data(config.items)\n\n const legendItemsEnter = legendItems.enter().append('div')\n .attr('class', d => cx(\n s.item,\n config.orientation === BulletLegendOrientation.Vertical && s.itemVertical,\n d.className)\n )\n .on('click', this._onItemClick.bind(this))\n\n const legendItemsMerged = legendItemsEnter.merge(legendItems)\n legendItemsMerged\n .classed(s.clickable, d => !!config.onLegendItemClick && this._isItemClickable(d))\n .style('display', (d: BulletLegendItemInterface) => d.hidden ? 'none' : null)\n\n // Bullet\n legendItemsEnter.append('span')\n .attr('class', s.bullet)\n .call(createBullets)\n\n legendItemsMerged.select<SVGElement>(`.${s.bullet}`)\n .style('width', config.bulletSize)\n .style('height', config.bulletSize)\n .style('box-sizing', 'content-box')\n .call(updateBullets, this.config, this._colorAccessor)\n\n // Labels\n legendItemsEnter.append('span')\n .attr('class', s.label)\n .classed(config.labelClassName, true)\n .style('max-width', config.labelMaxWidth)\n .style('font-size', config.labelFontSize)\n\n legendItemsMerged.select(`.${s.label}`)\n .text((d: BulletLegendItemInterface) => d.name)\n\n legendItems.exit().remove()\n }\n\n _isItemClickable (item: BulletLegendItemInterface): boolean {\n return item.pointer === undefined ? true : item.pointer\n }\n\n _onItemClick (event: MouseEvent, d: BulletLegendItemInterface): void {\n const { config: { onLegendItemClick } } = this\n\n const legendItems = this.div.selectAll(`.${s.item}`).nodes() as HTMLElement[]\n const index = legendItems.indexOf(event.currentTarget as HTMLElement)\n if (onLegendItemClick) onLegendItemClick(d, index)\n }\n\n public destroy (): void {\n if (this.element !== this._container) this.div.remove()\n }\n}\n"],"names":["s.root","s.item","s.itemVertical","s.clickable","s.bullet","s.label","s"],"mappings":";;;;;;;;;MAkBa,YAAY,CAAA;IAYvB,WAAa,CAAA,OAAoB,EAAE,MAAoC,EAAA;QAV7D,IAAc,CAAA,cAAA,GAAG,yBAAwD,CAAA;AAC5E,QAAA,IAAA,CAAA,MAAM,GAAgC,IAAI,CAAC,cAAc,CAAA;QAOxD,IAAc,CAAA,cAAA,GAAG,CAAC,CAA4B,KAAa,CAAC,CAAC,KAAK,CAAA;AAGxE,QAAA,IAAI,CAAC,UAAU,GAAG,OAAO,CAAA;AAEzB,QAAA,IAAI,CAAC,GAAG,GAAG,CAAA,MAAM,KAAN,IAAA,IAAA,MAAM,KAAN,KAAA,CAAA,GAAA,KAAA,CAAA,GAAA,MAAM,CAAE,yBAAyB,IAAG,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,GAAG,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,MAAM,CAAc,KAAK,CAAC,CAAA;QAC3H,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,OAA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E,EAAE,iBAAiB,EAAE,EAAE,GAAG,IAAI,CAAA;AAE9C,QAAA,MAAM,WAAW,GAAG,IAAI,CAAC,GAAG,CAAC,SAAS,CAAC,CAAI,CAAA,EAAAJ,IAAM,CAAA,CAAE,CAAC,CAAC,KAAK,EAAmB,CAAA;QAC7E,MAAM,KAAK,GAAG,WAAW,CAAC,OAAO,CAAC,KAAK,CAAC,aAA4B,CAAC,CAAA;AACrE,QAAA,IAAI,iBAAiB;AAAE,YAAA,iBAAiB,CAAC,CAAC,EAAE,KAAK,CAAC,CAAA;KACnD;IAEM,OAAO,GAAA;AACZ,QAAA,IAAI,IAAI,CAAC,OAAO,KAAK,IAAI,CAAC,UAAU;AAAE,YAAA,IAAI,CAAC,GAAG,CAAC,MAAM,EAAE,CAAA;KACxD;;AApFM,YAAS,CAAA,SAAA,GAAGK,KAAC;;;;"}
|
|
@@ -2,5 +2,5 @@ import { Selection } from 'd3-selection';
|
|
|
2
2
|
import { ColorAccessor } from "../../../types/accessor";
|
|
3
3
|
import { BulletLegendConfigInterface } from '../config';
|
|
4
4
|
import { BulletLegendItemInterface } from '../types';
|
|
5
|
-
export declare function createBullets(container: Selection<HTMLSpanElement, BulletLegendItemInterface,
|
|
6
|
-
export declare function updateBullets(container: Selection<SVGElement, BulletLegendItemInterface,
|
|
5
|
+
export declare function createBullets(container: Selection<HTMLSpanElement, BulletLegendItemInterface, HTMLElement, unknown>): void;
|
|
6
|
+
export declare function updateBullets(container: Selection<SVGElement, BulletLegendItemInterface, HTMLElement, unknown>, config: BulletLegendConfigInterface, colorAccessor: ColorAccessor<BulletLegendItemInterface>): void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"shape.js","sources":["../../../../src/components/bullet-legend/modules/shape.ts"],"sourcesContent":["import { Selection, select } from 'd3-selection'\nimport { symbol } from 'd3-shape'\n\n// Types\nimport { ColorAccessor } from 'types/accessor'\nimport { Symbol, SymbolType } from 'types/symbol'\n\n// Utils\nimport { getColor } from 'utils/color'\nimport { getString } from 'utils/data'\n\n// Constants\nimport { PATTERN_SIZE_PX } from 'styles/patterns'\n\n// Local types\nimport { BulletLegendConfigInterface } from '../config'\nimport { BulletShape, BulletLegendItemInterface } from '../types'\n\n// Size with respect to the viewBox. We use this to compute path data which is independent of the\n// the configured size.\nconst BULLET_SIZE = PATTERN_SIZE_PX * 3\n\n// Different shapes need different scaling to fit the full size\nconst shapeScale: Record<SymbolType, number> = {\n [BulletShape.Circle]: Math.PI / 4,\n [BulletShape.Cross]: 5 / 9,\n [BulletShape.Diamond]: Math.sqrt(3) / 6,\n [BulletShape.Square]: 1,\n [BulletShape.Star]: 0.3,\n [BulletShape.Triangle]: Math.sqrt(3) / 4,\n [BulletShape.Wye]: 5 / 11,\n}\n\nexport function createBullets (\n container: Selection<HTMLSpanElement, BulletLegendItemInterface,
|
|
1
|
+
{"version":3,"file":"shape.js","sources":["../../../../src/components/bullet-legend/modules/shape.ts"],"sourcesContent":["import { Selection, select } from 'd3-selection'\nimport { symbol } from 'd3-shape'\n\n// Types\nimport { ColorAccessor } from 'types/accessor'\nimport { Symbol, SymbolType } from 'types/symbol'\n\n// Utils\nimport { getColor } from 'utils/color'\nimport { getString } from 'utils/data'\n\n// Constants\nimport { PATTERN_SIZE_PX } from 'styles/patterns'\n\n// Local types\nimport { BulletLegendConfigInterface } from '../config'\nimport { BulletShape, BulletLegendItemInterface } from '../types'\n\n// Size with respect to the viewBox. We use this to compute path data which is independent of the\n// the configured size.\nconst BULLET_SIZE = PATTERN_SIZE_PX * 3\n\n// Different shapes need different scaling to fit the full size\nconst shapeScale: Record<SymbolType, number> = {\n [BulletShape.Circle]: Math.PI / 4,\n [BulletShape.Cross]: 5 / 9,\n [BulletShape.Diamond]: Math.sqrt(3) / 6,\n [BulletShape.Square]: 1,\n [BulletShape.Star]: 0.3,\n [BulletShape.Triangle]: Math.sqrt(3) / 4,\n [BulletShape.Wye]: 5 / 11,\n}\n\nexport function createBullets (\n container: Selection<HTMLSpanElement, BulletLegendItemInterface, HTMLElement, unknown>\n): void {\n container.each((d, i, els) => {\n select(els[i]).append('svg')\n .attr('width', '100%')\n .attr('height', '100%')\n .append('path')\n })\n}\n\nexport function updateBullets (\n container: Selection<SVGElement, BulletLegendItemInterface, HTMLElement, unknown>,\n config: BulletLegendConfigInterface,\n colorAccessor: ColorAccessor<BulletLegendItemInterface>\n): void {\n container.each((d, i, els) => {\n const shape = getString(d, config.bulletShape, i) as BulletShape\n const color = getColor(d, colorAccessor, i)\n const width = BULLET_SIZE\n const height = shape === BulletShape.Line ? BULLET_SIZE / 2.5 : BULLET_SIZE\n\n const selection = select(els[i]).select('svg')\n .attr('viewBox', `0 0 ${width} ${height}`)\n .select<SVGPathElement>('path')\n .attr('stroke', color)\n\n if (shape === BulletShape.Line) {\n selection\n .attr('d', `M0,${height / 2} L${width / 2},${height / 2} L${width},${height / 2}`)\n .attr('transform', null)\n .style('opacity', d.inactive ? 0.4 : 1)\n .style('stroke-width', '3px')\n .style('fill', null)\n .style('fill-opacity', null)\n .style('marker-start', 'none')\n .style('marker-end', 'none')\n } else {\n const symbolGen = symbol()\n .type(Symbol[shape])\n .size(width * height * shapeScale[shape])\n\n const scale = (width - 2) / width\n let dy = height / 2\n switch (shape) {\n case BulletShape.Triangle:\n dy += height / 8\n break\n case BulletShape.Star:\n dy += height / 16\n break\n case BulletShape.Wye:\n dy -= height / 16\n break\n }\n selection\n .attr('d', symbolGen)\n .attr('transform', `translate(${width / 2}, ${Math.round(dy)}) scale(${scale})`)\n .style('stroke-width', '1px')\n .style('opacity', null)\n .style('fill', color)\n .style('fill-opacity', d.inactive ? 0.4 : 1)\n }\n })\n}\n"],"names":[],"mappings":";;;;;;;;AAkBA;AACA;AACA,MAAM,WAAW,GAAG,eAAe,GAAG,CAAC,CAAA;AAEvC;AACA,MAAM,UAAU,GAA+B;IAC7C,CAAC,WAAW,CAAC,MAAM,GAAG,IAAI,CAAC,EAAE,GAAG,CAAC;AACjC,IAAA,CAAC,WAA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,QAAQ,KAAK;gBACX,KAAK,WAAW,CAAC,QAAQ;AACvB,oBAAA,EAAE,IAAI,MAAM,GAAG,CAAC,CAAA;oBAChB,MAAK;gBACP,KAAK,WAAW,CAAC,IAAI;AACnB,oBAAA,EAAE,IAAI,MAAM,GAAG,EAAE,CAAA;oBACjB,MAAK;gBACP,KAAK,WAAW,CAAC,GAAG;AAClB,oBAAA,EAAE,IAAI,MAAM,GAAG,EAAE,CAAA;oBACjB,MAAK;AACR,aAAA;YACD,SAAS;AACN,iBAAA,IAAI,CAAC,GAAG,EAAE,SAAS,CAAC;AACpB,iBAAA,IAAI,CAAC,WAAW,EAAE,CAAa,UAAA,EAAA,KAAK,GAAG,CAAC,CAAA,EAAA,EAAK,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,CAAW,QAAA,EAAA,KAAK,GAAG,CAAC;AAC/E,iBAAA,KAAK,CAAC,cAAc,EAAE,KAAK,CAAC;AAC5B,iBAAA,KAAK,CAAC,SAAS,EAAE,IAAI,CAAC;AACtB,iBAAA,KAAK,CAAC,MAAM,EAAE,KAAK,CAAC;AACpB,iBAAA,KAAK,CAAC,cAAc,EAAE,CAAC,CAAC,QAAQ,GAAG,GAAG,GAAG,CAAC,CAAC,CAAA;AAC/C,SAAA;AACH,KAAC,CAAC,CAAA;AACJ;;;;"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export declare const root: string;
|
|
2
2
|
export declare const variables: void;
|
|
3
3
|
export declare const item: string;
|
|
4
|
+
export declare const itemVertical: string;
|
|
4
5
|
export declare const clickable: string;
|
|
5
6
|
export declare const label: string;
|
|
6
7
|
export declare const bullet: string;
|
|
@@ -38,6 +38,11 @@ const item = css `
|
|
|
38
38
|
white-space: nowrap;
|
|
39
39
|
cursor: default;
|
|
40
40
|
user-select: none;
|
|
41
|
+
max-width: min-content;
|
|
42
|
+
`;
|
|
43
|
+
const itemVertical = css `
|
|
44
|
+
label: legendItemVertical;
|
|
45
|
+
display: flex;
|
|
41
46
|
`;
|
|
42
47
|
const clickable = css `
|
|
43
48
|
cursor: pointer;
|
|
@@ -54,16 +59,17 @@ const label = css `
|
|
|
54
59
|
white-space: nowrap;
|
|
55
60
|
`;
|
|
56
61
|
const bullet = css `
|
|
62
|
+
flex: 0 0 auto;
|
|
57
63
|
label: legendItemBullet;
|
|
58
64
|
margin-right: var(--vis-legend-bullet-label-spacing);
|
|
59
65
|
height: var(--vis-legend-bullet-size);
|
|
60
66
|
width: var(--vis-legend-bullet-size);
|
|
61
|
-
|
|
67
|
+
|
|
62
68
|
svg {
|
|
63
69
|
display: block;
|
|
64
70
|
}
|
|
65
71
|
}
|
|
66
72
|
`;
|
|
67
73
|
|
|
68
|
-
export { bullet, clickable, item, label, root, variables };
|
|
74
|
+
export { bullet, clickable, item, itemVertical, label, root, variables };
|
|
69
75
|
//# sourceMappingURL=style.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"style.js","sources":["../../../src/components/bullet-legend/style.ts"],"sourcesContent":["import { css, injectGlobal } from '@emotion/css'\n\nexport const root = css`\n label: bullet-legend-component;\n`\n\nexport const variables = injectGlobal`\n :root {\n // Undefined by default to allow proper fallback to var(--vis-font-family)\n /* --vis-legend-font-family: */\n\n --vis-legend-label-color: #6c778c;\n --vis-legend-label-max-width: 300px;\n --vis-legend-label-font-size: 12px;\n --vis-legend-bullet-size: 9px;\n --vis-legend-bullet-inactive-color: #eee;\n --vis-legend-item-spacing: 20px;\n --vis-legend-bullet-label-spacing: 8px;\n\n --vis-dark-legend-label-color: #eee;\n --vis-dark-legend-bullet-inactive-color: #6c778c;\n }\n\n body.theme-dark ${`.${root}`} {\n --vis-legend-label-color: var(--vis-dark-legend-label-color);\n --vis-legend-bullet-inactive-color: var(--vis-dark-legend-bullet-inactive-color);\n }\n\n body.theme-patterns {\n --vis-legend-bullet-size: 14px;\n }\n`\n\nexport const item = css`\n label: legendItem;\n display: inline-flex;\n align-items: center;\n font-family: var(--vis-legend-font-family, var(--vis-font-family));\n margin-right: var(--vis-legend-item-spacing);\n white-space: nowrap;\n cursor: default;\n user-select: none;\n`\n\nexport const clickable = css`\n cursor: pointer;\n`\n\nexport const label = css`\n label: legendItemLabel;\n font-size: var(--vis-legend-label-font-size);\n display: inline-block;\n vertical-align: middle;\n color: var(--vis-legend-label-color);\n max-width: var(--vis-legend-label-max-width);\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n`\n\nexport const bullet = css`\n label: legendItemBullet;\n margin-right: var(--vis-legend-bullet-label-spacing);\n height: var(--vis-legend-bullet-size);\n width: var(--vis-legend-bullet-size);\n
|
|
1
|
+
{"version":3,"file":"style.js","sources":["../../../src/components/bullet-legend/style.ts"],"sourcesContent":["import { css, injectGlobal } from '@emotion/css'\n\nexport const root = css`\n label: bullet-legend-component;\n`\n\nexport const variables = injectGlobal`\n :root {\n // Undefined by default to allow proper fallback to var(--vis-font-family)\n /* --vis-legend-font-family: */\n\n --vis-legend-label-color: #6c778c;\n --vis-legend-label-max-width: 300px;\n --vis-legend-label-font-size: 12px;\n --vis-legend-bullet-size: 9px;\n --vis-legend-bullet-inactive-color: #eee;\n --vis-legend-item-spacing: 20px;\n --vis-legend-bullet-label-spacing: 8px;\n\n --vis-dark-legend-label-color: #eee;\n --vis-dark-legend-bullet-inactive-color: #6c778c;\n }\n\n body.theme-dark ${`.${root}`} {\n --vis-legend-label-color: var(--vis-dark-legend-label-color);\n --vis-legend-bullet-inactive-color: var(--vis-dark-legend-bullet-inactive-color);\n }\n\n body.theme-patterns {\n --vis-legend-bullet-size: 14px;\n }\n`\n\nexport const item = css`\n label: legendItem;\n display: inline-flex;\n align-items: center;\n font-family: var(--vis-legend-font-family, var(--vis-font-family));\n margin-right: var(--vis-legend-item-spacing);\n white-space: nowrap;\n cursor: default;\n user-select: none;\n max-width: min-content;\n`\n\nexport const itemVertical = css`\n label: legendItemVertical;\n display: flex;\n`\n\nexport const clickable = css`\n cursor: pointer;\n`\n\nexport const label = css`\n label: legendItemLabel;\n font-size: var(--vis-legend-label-font-size);\n display: inline-block;\n vertical-align: middle;\n color: var(--vis-legend-label-color);\n max-width: var(--vis-legend-label-max-width);\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n`\n\nexport const bullet = css`\n flex: 0 0 auto;\n label: legendItemBullet;\n margin-right: var(--vis-legend-bullet-label-spacing);\n height: var(--vis-legend-bullet-size);\n width: var(--vis-legend-bullet-size);\n\n svg {\n display: block;\n }\n}\n`\n"],"names":[],"mappings":";;AAEO,MAAM,IAAI,GAAG,GAAG,CAAA,CAAA;;EAEtB;AAEM,MAAM,SAAS,GAAG,YAAY,CAAA,CAAA;;;;;;;;;;;;;;;;;AAiBjB,kBAAA,EAAA,CAAA,CAAA,EAAI,IAAI,CAAE,CAAA,CAAA;;;;;;;;EAQ7B;AAEM,MAAM,IAAI,GAAG,GAAG,CAAA,CAAA;;;;;;;;;;EAUtB;AAEM,MAAM,YAAY,GAAG,GAAG,CAAA,CAAA;;;EAG9B;AAEM,MAAM,SAAS,GAAG,GAAG,CAAA,CAAA;;EAE3B;AAEM,MAAM,KAAK,GAAG,GAAG,CAAA,CAAA;;;;;;;;;;EAUvB;AAEM,MAAM,MAAM,GAAG,GAAG,CAAA,CAAA;;;;;;;;;;;;;;;"}
|
|
@@ -19,3 +19,7 @@ export declare const BulletShape: {
|
|
|
19
19
|
readonly Wye: SymbolType.Wye;
|
|
20
20
|
};
|
|
21
21
|
export declare type BulletShape = typeof BulletShape[keyof typeof BulletShape];
|
|
22
|
+
export declare enum BulletLegendOrientation {
|
|
23
|
+
Horizontal = "horizontal",
|
|
24
|
+
Vertical = "vertical"
|
|
25
|
+
}
|
|
@@ -1,7 +1,12 @@
|
|
|
1
1
|
import { SymbolType } from '../../types/symbol.js';
|
|
2
2
|
|
|
3
3
|
/* eslint-disable @typescript-eslint/naming-convention */
|
|
4
|
-
const BulletShape = Object.assign(Object.assign({}, SymbolType), { Line: 'line' });
|
|
4
|
+
const BulletShape = Object.assign(Object.assign({}, SymbolType), { Line: 'line' });
|
|
5
|
+
var BulletLegendOrientation;
|
|
6
|
+
(function (BulletLegendOrientation) {
|
|
7
|
+
BulletLegendOrientation["Horizontal"] = "horizontal";
|
|
8
|
+
BulletLegendOrientation["Vertical"] = "vertical";
|
|
9
|
+
})(BulletLegendOrientation || (BulletLegendOrientation = {}));
|
|
5
10
|
|
|
6
|
-
export { BulletShape };
|
|
11
|
+
export { BulletLegendOrientation, BulletShape };
|
|
7
12
|
//# sourceMappingURL=types.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sources":["../../../src/components/bullet-legend/types.ts"],"sourcesContent":["/* eslint-disable @typescript-eslint/naming-convention */\nimport { SymbolType } from 'types/symbol'\n\nexport interface BulletLegendItemInterface {\n name: string | number;\n color?: string;\n className?: string;\n shape?: BulletShape;\n inactive?: boolean;\n hidden?: boolean;\n pointer?: boolean;\n}\n\nexport const BulletShape = {\n ...SymbolType,\n Line: 'line',\n} as const\n\nexport type BulletShape = typeof BulletShape[keyof typeof BulletShape]\n"],"names":[],"mappings":";;AAAA;AAaa,MAAA,WAAW,GAAG,MAAA,CAAA,MAAA,CAAA,MAAA,CAAA,MAAA,CAAA,EAAA,EACtB,UAAU,CAAA,EAAA,EACb,IAAI,EAAE,MAAM,EAAA;;;;"}
|
|
1
|
+
{"version":3,"file":"types.js","sources":["../../../src/components/bullet-legend/types.ts"],"sourcesContent":["/* eslint-disable @typescript-eslint/naming-convention */\nimport { SymbolType } from 'types/symbol'\n\nexport interface BulletLegendItemInterface {\n name: string | number;\n color?: string;\n className?: string;\n shape?: BulletShape;\n inactive?: boolean;\n hidden?: boolean;\n pointer?: boolean;\n}\n\nexport const BulletShape = {\n ...SymbolType,\n Line: 'line',\n} as const\n\nexport type BulletShape = typeof BulletShape[keyof typeof BulletShape]\n\nexport enum BulletLegendOrientation {\n Horizontal = 'horizontal',\n Vertical = 'vertical',\n}\n"],"names":[],"mappings":";;AAAA;AAaa,MAAA,WAAW,GAAG,MAAA,CAAA,MAAA,CAAA,MAAA,CAAA,MAAA,CAAA,EAAA,EACtB,UAAU,CAAA,EAAA,EACb,IAAI,EAAE,MAAM,EAAA,EACJ;IAIE,wBAGX;AAHD,CAAA,UAAY,uBAAuB,EAAA;AACjC,IAAA,uBAAA,CAAA,YAAA,CAAA,GAAA,YAAyB,CAAA;AACzB,IAAA,uBAAA,CAAA,UAAA,CAAA,GAAA,UAAqB,CAAA;AACvB,CAAC,EAHW,uBAAuB,KAAvB,uBAAuB,GAGlC,EAAA,CAAA,CAAA;;;;"}
|
package/index.js
CHANGED
|
@@ -51,7 +51,7 @@ export { GraphLayoutType, GraphLinkArrowStyle, GraphLinkStyle, GraphNodeShape }
|
|
|
51
51
|
export { SankeyEnterTransitionType, SankeyExitTransitionType, SankeyLayout, SankeyNodeAlign, SankeySubLabelPlacement } from './components/sankey/types.js';
|
|
52
52
|
export { VisControlsOrientation } from './components/vis-controls/types.js';
|
|
53
53
|
export { FreeBrushMode } from './components/free-brush/types.js';
|
|
54
|
-
export { BulletShape } from './components/bullet-legend/types.js';
|
|
54
|
+
export { BulletLegendOrientation, BulletShape } from './components/bullet-legend/types.js';
|
|
55
55
|
export { XYLabelPositioning } from './components/xy-labels/types.js';
|
|
56
56
|
export { NestedDonutDirection, NestedDonutSegmentLabelAlignment } from './components/nested-donut/types.js';
|
|
57
57
|
//# sourceMappingURL=index.js.map
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@unovis/ts",
|
|
3
3
|
"description": "Modular data visualization framework for React, Angular, Svelte, and vanilla TypeScript or JavaScript",
|
|
4
|
-
"version": "1.4.0",
|
|
4
|
+
"version": "1.4.1-alpha.0",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
7
7
|
"url": "https://github.com/f5/unovis.git",
|
package/types.js
CHANGED
|
@@ -22,7 +22,7 @@ export { GraphLayoutType, GraphLinkArrowStyle, GraphLinkStyle, GraphNodeShape }
|
|
|
22
22
|
export { SankeyEnterTransitionType, SankeyExitTransitionType, SankeyLayout, SankeyNodeAlign, SankeySubLabelPlacement } from './components/sankey/types.js';
|
|
23
23
|
export { VisControlsOrientation } from './components/vis-controls/types.js';
|
|
24
24
|
export { FreeBrushMode } from './components/free-brush/types.js';
|
|
25
|
-
export { BulletShape } from './components/bullet-legend/types.js';
|
|
25
|
+
export { BulletLegendOrientation, BulletShape } from './components/bullet-legend/types.js';
|
|
26
26
|
export { XYLabelPositioning } from './components/xy-labels/types.js';
|
|
27
27
|
export { NestedDonutDirection, NestedDonutSegmentLabelAlignment } from './components/nested-donut/types.js';
|
|
28
28
|
import './components/annotations/types.js';
|