@selectwin/kit 0.1.124 → 0.1.126
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/dist/SelectChartLegend.d.ts +2 -0
- package/dist/SelectLayout.d.ts +7 -1
- package/dist/SelectListCard.d.ts +5 -0
- package/dist/SelectMiniStats.d.ts +5 -0
- package/dist/SelectProgressList.d.ts +6 -1
- package/dist/SelectTileMap.d.ts +31 -0
- package/dist/chartUtils.d.ts +3 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +519 -251
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -6,6 +6,8 @@ export interface SelectChartLegendItem {
|
|
|
6
6
|
color?: string;
|
|
7
7
|
/** Match a `pattern: 'hatch'` series. */
|
|
8
8
|
pattern?: 'hatch';
|
|
9
|
+
/** Um traço no lugar do quadrado — a legenda de um gráfico de LINHAS; `dashed` = a série tracejada (0.1.126). */
|
|
10
|
+
line?: 'solid' | 'dashed';
|
|
9
11
|
/** Instead of a swatch (a total that isn't drawn, e.g. "Cancelados"). */
|
|
10
12
|
icon?: ReactNode;
|
|
11
13
|
}
|
package/dist/SelectLayout.d.ts
CHANGED
|
@@ -19,9 +19,15 @@ type SelectStackOwnProps = {
|
|
|
19
19
|
* extra room lands BETWEEN them instead of as an empty band under the content.
|
|
20
20
|
*/
|
|
21
21
|
fill?: boolean;
|
|
22
|
+
/**
|
|
23
|
+
* The LAST child takes the height left over (0.1.125) — a column of cards beside a taller grid
|
|
24
|
+
* neighbour: the last card grows (its white body box goes to the foot, SelectListCard/SelectSection
|
|
25
|
+
* already flex) instead of the column ending short. Use with `fill`.
|
|
26
|
+
*/
|
|
27
|
+
growLast?: boolean;
|
|
22
28
|
};
|
|
23
29
|
export type SelectStackProps = SelectStackOwnProps & Omit<HTMLAttributes<HTMLElement>, keyof SelectStackOwnProps>;
|
|
24
|
-
export declare function SelectStack({ children, gap, align, inlineAlign, as, className, fill, ...rest }: SelectStackProps): import("react").JSX.Element;
|
|
30
|
+
export declare function SelectStack({ children, gap, align, inlineAlign, as, className, fill, growLast, ...rest }: SelectStackProps): import("react").JSX.Element;
|
|
25
31
|
type SelectInlineOwnProps = {
|
|
26
32
|
children: ReactNode;
|
|
27
33
|
gap?: SelectSpace;
|
package/dist/SelectListCard.d.ts
CHANGED
|
@@ -11,6 +11,11 @@ type SelectListCardOwnProps = {
|
|
|
11
11
|
* (cinco nomes num card de um terço sem esticar a linha inteira).
|
|
12
12
|
*/
|
|
13
13
|
dense?: boolean;
|
|
14
|
+
/**
|
|
15
|
+
* As linhas dividem a altura da caixa (0.1.126): esticado ao lado de um vizinho mais alto, o
|
|
16
|
+
* card não sobra com uma faixa branca embaixo — cada linha cresce igual, o conteúdo no meio.
|
|
17
|
+
*/
|
|
18
|
+
spread?: boolean;
|
|
14
19
|
children: ReactNode;
|
|
15
20
|
};
|
|
16
21
|
export type SelectListCardProps = SelectListCardOwnProps & Omit<ComponentPropsWithoutRef<'div'>, keyof SelectListCardOwnProps>;
|
|
@@ -9,6 +9,11 @@ export interface SelectMiniStat {
|
|
|
9
9
|
type SelectMiniStatsOwnProps = {
|
|
10
10
|
items: SelectMiniStat[];
|
|
11
11
|
order?: 'label-first' | 'value-first';
|
|
12
|
+
/**
|
|
13
|
+
* Colunas FIXAS (0.1.126): 2 = 2×2, 3 = 3×2 — sem o item órfão sozinho na última linha que o
|
|
14
|
+
* encaixe automático deixa com 5 ou 6 números. Em telas estreitas cai para 2 (ou 1).
|
|
15
|
+
*/
|
|
16
|
+
columns?: 2 | 3 | 4;
|
|
12
17
|
};
|
|
13
18
|
export type SelectMiniStatsProps = SelectMiniStatsOwnProps & Omit<ComponentPropsWithoutRef<'dl'>, keyof SelectMiniStatsOwnProps>;
|
|
14
19
|
export declare const SelectMiniStats: import('react').ForwardRefExoticComponent<SelectMiniStatsOwnProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDListElement>, HTMLDListElement>, "ref">, keyof SelectMiniStatsOwnProps> & import('react').RefAttributes<HTMLDListElement>>;
|
|
@@ -14,7 +14,7 @@ export interface SelectProgressItem {
|
|
|
14
14
|
/** Override this row's bar colour. */
|
|
15
15
|
color?: string;
|
|
16
16
|
}
|
|
17
|
-
export declare function SelectProgressList({ items, format, color, emptyText, spread, }: {
|
|
17
|
+
export declare function SelectProgressList({ items, format, color, emptyText, spread, max: fixedMax, }: {
|
|
18
18
|
items: SelectProgressItem[];
|
|
19
19
|
format?: (n: number) => string;
|
|
20
20
|
/** One colour for every bar (else the chart ramp, one hue per row). */
|
|
@@ -26,5 +26,10 @@ export declare function SelectProgressList({ items, format, color, emptyText, sp
|
|
|
26
26
|
* extra room is shared between the rows instead of piling up as an empty band.
|
|
27
27
|
*/
|
|
28
28
|
spread?: boolean;
|
|
29
|
+
/**
|
|
30
|
+
* Escala FIXA (0.1.126): a barra cheia vale `max` — 100 para uma taxa, e 42% de aprovação ocupa
|
|
31
|
+
* 42% do trilho. Sem ele a barra é relativa à MAIOR linha (o ranking de hoje).
|
|
32
|
+
*/
|
|
33
|
+
max?: number;
|
|
29
34
|
}): import("react").JSX.Element;
|
|
30
35
|
export {};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { ComponentPropsWithoutRef, ReactNode } from 'react';
|
|
2
|
+
export interface SelectTile {
|
|
3
|
+
/** Chave estável (a sigla da UF). */
|
|
4
|
+
key: string;
|
|
5
|
+
/** O que o quadrado mostra ("SP"). */
|
|
6
|
+
label: string;
|
|
7
|
+
/** Coluna e linha na grade (a partir de 0). */
|
|
8
|
+
col: number;
|
|
9
|
+
row: number;
|
|
10
|
+
/** O valor que pinta o quadrado; ausente ou 0 = quadrado claro, sem valor. */
|
|
11
|
+
value?: number;
|
|
12
|
+
/** O nome completo, no título do tooltip ("São Paulo"). */
|
|
13
|
+
title?: string;
|
|
14
|
+
}
|
|
15
|
+
type SelectTileMapOwnProps = {
|
|
16
|
+
tiles: SelectTile[];
|
|
17
|
+
/** A cor da escala (padrão: `--select-chart-1`). */
|
|
18
|
+
color?: string;
|
|
19
|
+
/** Lado do quadrado em px (padrão 36). */
|
|
20
|
+
tileSize?: number;
|
|
21
|
+
gap?: number;
|
|
22
|
+
/** Como o valor aparece no tooltip. */
|
|
23
|
+
format?: (n: number) => ReactNode;
|
|
24
|
+
/** A régua "menos → mais" embaixo do mapa. */
|
|
25
|
+
legend?: boolean;
|
|
26
|
+
};
|
|
27
|
+
export type SelectTileMapProps = SelectTileMapOwnProps & Omit<ComponentPropsWithoutRef<'div'>, keyof SelectTileMapOwnProps>;
|
|
28
|
+
export declare const SelectTileMap: import('react').ForwardRefExoticComponent<SelectTileMapOwnProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref">, keyof SelectTileMapOwnProps> & import('react').RefAttributes<HTMLDivElement>>;
|
|
29
|
+
/** Os 27 estados numa grade de 6 × 8, cada um perto de onde fica no mapa. */
|
|
30
|
+
export declare const SELECT_BR_UF_TILES: ReadonlyArray<Omit<SelectTile, 'value'>>;
|
|
31
|
+
export {};
|
package/dist/chartUtils.d.ts
CHANGED
|
@@ -62,6 +62,9 @@ export interface SelectChartSeries {
|
|
|
62
62
|
* gradient — the second encoding for "not happened yet" (scheduled, projected), so the
|
|
63
63
|
* difference never rides on color alone. */
|
|
64
64
|
pattern?: 'hatch';
|
|
65
|
+
/** SelectLineChart: linha tracejada e mais clara, sem área — a COMPARAÇÃO (o período anterior),
|
|
66
|
+
* que fica atrás da série principal sem disputar com ela. Pode ser mais curta que `labels`. */
|
|
67
|
+
dashed?: boolean;
|
|
65
68
|
}
|
|
66
69
|
export interface SelectBarDatum {
|
|
67
70
|
label: string;
|
package/dist/index.d.ts
CHANGED
|
@@ -127,6 +127,7 @@ export type { SelectPaymentCardProps } from './SelectPaymentCard';
|
|
|
127
127
|
export { SelectFunnel } from './SelectFunnel';
|
|
128
128
|
export { SelectGauge } from './SelectGauge';
|
|
129
129
|
export { SelectHeatmap } from './SelectHeatmap';
|
|
130
|
+
export { SelectTileMap, SELECT_BR_UF_TILES } from './SelectTileMap';
|
|
130
131
|
export { SelectProgressList } from './SelectProgressList';
|
|
131
132
|
export { SelectRadialBar } from './SelectRadialBar';
|
|
132
133
|
export { SelectHorizontalBar } from './SelectHorizontalBar';
|
|
@@ -260,6 +261,7 @@ export type { SelectColumnChartProps, SelectColumnTooltip } from './SelectColumn
|
|
|
260
261
|
export type { SelectChartLegendProps, SelectChartLegendItem } from './SelectChartLegend';
|
|
261
262
|
export type { SelectShareBarProps, SelectShareItem } from './SelectShareBar';
|
|
262
263
|
export type { SelectHeatmapRow } from './SelectHeatmap';
|
|
264
|
+
export type { SelectTile, SelectTileMapProps } from './SelectTileMap';
|
|
263
265
|
export type { SelectProgressItem } from './SelectProgressList';
|
|
264
266
|
export type { SelectRadialSeries } from './SelectRadialBar';
|
|
265
267
|
export type { SelectWaterfallStep } from './SelectWaterfall';
|