layerchart 0.0.4 → 0.0.8
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 +2 -37
- package/components/Arc.svelte +77 -0
- package/components/Arc.svelte.d.ts +34 -0
- package/components/Area.svelte +19 -10
- package/components/Area.svelte.d.ts +4 -1
- package/components/AreaStack.svelte +3 -0
- package/components/AreaStack.svelte.d.ts +1 -0
- package/components/AxisX.svelte +1 -1
- package/components/AxisY.svelte +1 -4
- package/components/{Bar.svelte → Bars.svelte} +27 -14
- package/components/{Bar.svelte.d.ts → Bars.svelte.d.ts} +10 -4
- package/components/ConnectedPoints.svelte +68 -0
- package/components/ConnectedPoints.svelte.d.ts +18 -0
- package/components/Group.svelte +26 -0
- package/components/Group.svelte.d.ts +21 -0
- package/components/{HighlightBar.svelte → HighlightRect.svelte} +0 -0
- package/components/HighlightRect.svelte.d.ts +18 -0
- package/components/{Label.svelte → Labels.svelte} +0 -0
- package/components/{Label.svelte.d.ts → Labels.svelte.d.ts} +4 -4
- package/components/LinearGradient.svelte +27 -0
- package/components/LinearGradient.svelte.d.ts +27 -0
- package/components/Path.svelte +19 -15
- package/components/Path.svelte.d.ts +4 -2
- package/components/Points.svelte +58 -0
- package/components/Points.svelte.d.ts +19 -0
- package/components/Threshold.svelte +25 -22
- package/components/index.d.ts +8 -5
- package/components/index.js +8 -5
- package/docs/Preview.svelte +7 -3
- package/docs/Preview.svelte.d.ts +2 -0
- package/index.d.ts +2 -2
- package/index.js +2 -2
- package/package.json +17 -10
- package/stores/motionStore.d.ts +2 -2
- package/utils/genData.d.ts +13 -0
- package/utils/genData.js +24 -0
- package/utils/math.d.ts +4 -0
- package/utils/math.js +6 -0
- package/utils/path.d.ts +5 -0
- package/utils/path.js +14 -0
- package/utils/pivot.js +1 -1
- package/utils/stack.d.ts +14 -0
- package/utils/stack.js +69 -0
- package/components/ClevelandDotPlot.svelte +0 -44
- package/components/ClevelandDotPlot.svelte.d.ts +0 -21
- package/components/HighlightBar.svelte.d.ts +0 -18
- package/components/Scatter.svelte +0 -25
- package/components/Scatter.svelte.d.ts +0 -33
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { SvelteComponentTyped } from "svelte";
|
|
2
|
-
declare const __propDef: {
|
|
3
|
-
props: {
|
|
4
|
-
data: any;
|
|
5
|
-
};
|
|
6
|
-
events: {
|
|
7
|
-
click: MouseEvent;
|
|
8
|
-
} & {
|
|
9
|
-
[evt: string]: CustomEvent<any>;
|
|
10
|
-
};
|
|
11
|
-
slots: {};
|
|
12
|
-
};
|
|
13
|
-
export declare type HighlightBarProps = typeof __propDef.props;
|
|
14
|
-
export declare type HighlightBarEvents = typeof __propDef.events;
|
|
15
|
-
export declare type HighlightBarSlots = typeof __propDef.slots;
|
|
16
|
-
export default class HighlightBar extends SvelteComponentTyped<HighlightBarProps, HighlightBarEvents, HighlightBarSlots> {
|
|
17
|
-
}
|
|
18
|
-
export {};
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
<script>
|
|
2
|
-
import { getContext } from 'svelte';
|
|
3
|
-
|
|
4
|
-
const { data, xGet, yGet, xScale, yScale } = getContext('LayerCake');
|
|
5
|
-
|
|
6
|
-
export let r = 5;
|
|
7
|
-
export let fill = '#000';
|
|
8
|
-
export let stroke = '#0cf';
|
|
9
|
-
export let strokeWidth = 0;
|
|
10
|
-
export let dx = 0;
|
|
11
|
-
export let dy = 0;
|
|
12
|
-
</script>
|
|
13
|
-
|
|
14
|
-
<g class="scatter-group">
|
|
15
|
-
{#each $data as d}
|
|
16
|
-
<circle
|
|
17
|
-
cx={$xGet(d) + (typeof dx === 'function' ? dx($xScale) : dx)}
|
|
18
|
-
cy={$yGet(d) + (typeof dy === 'function' ? dy($yScale) : dy)}
|
|
19
|
-
{r}
|
|
20
|
-
{fill}
|
|
21
|
-
{stroke}
|
|
22
|
-
stroke-width={strokeWidth}
|
|
23
|
-
/>
|
|
24
|
-
{/each}
|
|
25
|
-
</g>
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
/** @typedef {typeof __propDef.props} ScatterProps */
|
|
2
|
-
/** @typedef {typeof __propDef.events} ScatterEvents */
|
|
3
|
-
/** @typedef {typeof __propDef.slots} ScatterSlots */
|
|
4
|
-
export default class Scatter extends SvelteComponentTyped<{
|
|
5
|
-
dx?: number;
|
|
6
|
-
dy?: number;
|
|
7
|
-
stroke?: string;
|
|
8
|
-
strokeWidth?: number;
|
|
9
|
-
r?: number;
|
|
10
|
-
fill?: string;
|
|
11
|
-
}, {
|
|
12
|
-
[evt: string]: CustomEvent<any>;
|
|
13
|
-
}, {}> {
|
|
14
|
-
}
|
|
15
|
-
export type ScatterProps = typeof __propDef.props;
|
|
16
|
-
export type ScatterEvents = typeof __propDef.events;
|
|
17
|
-
export type ScatterSlots = typeof __propDef.slots;
|
|
18
|
-
import { SvelteComponentTyped } from "svelte";
|
|
19
|
-
declare const __propDef: {
|
|
20
|
-
props: {
|
|
21
|
-
dx?: number;
|
|
22
|
-
dy?: number;
|
|
23
|
-
stroke?: string;
|
|
24
|
-
strokeWidth?: number;
|
|
25
|
-
r?: number;
|
|
26
|
-
fill?: string;
|
|
27
|
-
};
|
|
28
|
-
events: {
|
|
29
|
-
[evt: string]: CustomEvent<any>;
|
|
30
|
-
};
|
|
31
|
-
slots: {};
|
|
32
|
-
};
|
|
33
|
-
export {};
|