@selectwin/kit 0.1.128 → 0.1.130
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/SelectAvatar.d.ts +6 -0
- package/dist/SelectChipInput.d.ts +22 -0
- package/dist/SelectDataTable.d.ts +3 -0
- package/dist/SelectMiniStats.d.ts +3 -2
- package/dist/SelectSpotlight.d.ts +6 -0
- package/dist/SelectText.d.ts +3 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.js +1457 -1343
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/SelectAvatar.d.ts
CHANGED
|
@@ -7,7 +7,13 @@ type SelectAvatarOwnProps = {
|
|
|
7
7
|
dashed?: boolean;
|
|
8
8
|
/** Circular (with a hairline) — app/logo tiles. */
|
|
9
9
|
round?: boolean;
|
|
10
|
+
/** `md` (2.25rem, rows) or `lg` (3.75rem, page header). */
|
|
11
|
+
size?: 'md' | 'lg';
|
|
12
|
+
/** How many letters stand for the name: 1 (default) or 2 (first + last word). */
|
|
13
|
+
initials?: 1 | 2;
|
|
10
14
|
};
|
|
11
15
|
export type SelectAvatarProps = SelectAvatarOwnProps & Omit<ComponentPropsWithoutRef<'span'>, keyof SelectAvatarOwnProps>;
|
|
12
16
|
export declare const SelectAvatar: import('react').ForwardRefExoticComponent<SelectAvatarOwnProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref">, keyof SelectAvatarOwnProps> & import('react').RefAttributes<HTMLSpanElement>>;
|
|
17
|
+
/** The letters that stand for a name: the first letter, or first + last word's first letters. */
|
|
18
|
+
export declare function avatarInitials(name: string | undefined, count?: 1 | 2): string;
|
|
13
19
|
export {};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { ComponentPropsWithoutRef, ReactNode } from 'react';
|
|
2
|
+
type SelectChipInputOwnProps = {
|
|
3
|
+
label?: ReactNode;
|
|
4
|
+
value: string[];
|
|
5
|
+
onChange: (next: string[]) => void;
|
|
6
|
+
placeholder?: string;
|
|
7
|
+
hint?: ReactNode;
|
|
8
|
+
/** Erro da LISTA inteira (ex.: "Adicione ao menos um IP"). O erro do valor digitado é interno. */
|
|
9
|
+
error?: string;
|
|
10
|
+
disabled?: boolean;
|
|
11
|
+
/** Teto de etiquetas. Cheio: o campo trava e a ajuda diz o limite. */
|
|
12
|
+
max?: number;
|
|
13
|
+
/** Motivo para recusar um valor (ou `undefined` para aceitar). */
|
|
14
|
+
validate?: (candidate: string) => string | undefined;
|
|
15
|
+
/** Etiquetas em fonte monoespaçada (IPs, códigos). */
|
|
16
|
+
mono?: boolean;
|
|
17
|
+
/** Nome acessível do campo quando não há `label` visível. */
|
|
18
|
+
ariaLabel?: string;
|
|
19
|
+
};
|
|
20
|
+
export type SelectChipInputProps = SelectChipInputOwnProps & Omit<ComponentPropsWithoutRef<'div'>, keyof SelectChipInputOwnProps>;
|
|
21
|
+
export declare const SelectChipInput: import('react').ForwardRefExoticComponent<SelectChipInputOwnProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref">, keyof SelectChipInputOwnProps> & import('react').RefAttributes<HTMLDivElement>>;
|
|
22
|
+
export {};
|
|
@@ -54,6 +54,9 @@ export interface SelectDataColumn<T> {
|
|
|
54
54
|
/** Whether the column can be hidden from the `columnsKey` picker. Defaults to "has a
|
|
55
55
|
* title" — untitled columns (actions) are never listed nor hideable. */
|
|
56
56
|
hideable?: boolean;
|
|
57
|
+
/** Deixa o conteúdo QUEBRAR linha em vez de cortar com reticências — para um título com a
|
|
58
|
+
* descrição embaixo (uma matriz de preferências), não para ids e valores. */
|
|
59
|
+
wrap?: boolean;
|
|
57
60
|
}
|
|
58
61
|
/**
|
|
59
62
|
* Page size the user picked for a given table (pair with `pagination.pageSizeOptions`/
|
|
@@ -11,9 +11,10 @@ type SelectMiniStatsOwnProps = {
|
|
|
11
11
|
order?: 'label-first' | 'value-first';
|
|
12
12
|
/**
|
|
13
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.
|
|
14
|
+
* encaixe automático deixa com 5 ou 6 números. 5 = uma linha de cinco (0.1.130). Em telas
|
|
15
|
+
* estreitas cai para 2 (ou 1).
|
|
15
16
|
*/
|
|
16
|
-
columns?: 2 | 3 | 4;
|
|
17
|
+
columns?: 2 | 3 | 4 | 5;
|
|
17
18
|
};
|
|
18
19
|
export type SelectMiniStatsProps = SelectMiniStatsOwnProps & Omit<ComponentPropsWithoutRef<'dl'>, keyof SelectMiniStatsOwnProps>;
|
|
19
20
|
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>>;
|
|
@@ -10,6 +10,12 @@ type SelectSpotlightOwnProps = {
|
|
|
10
10
|
actions?: ReactNode;
|
|
11
11
|
actionsPlacement?: 'below' | 'end';
|
|
12
12
|
aside?: ReactNode;
|
|
13
|
+
/** `md` (padrão, o topo da página) ou `sm` (compacto, dentro de outro card). */
|
|
14
|
+
size?: 'md' | 'sm';
|
|
15
|
+
/** Card estreito: por padrão o `media` fica numa linha e o texto desce. Com `mediaInline` ele
|
|
16
|
+
* continua AO LADO do texto — para um media pequeno (o avatar da pessoa), em que a linha só dele
|
|
17
|
+
* seria espaço perdido. O `aside` desce do mesmo jeito. */
|
|
18
|
+
mediaInline?: boolean;
|
|
13
19
|
children?: ReactNode;
|
|
14
20
|
};
|
|
15
21
|
export type SelectSpotlightProps = SelectSpotlightOwnProps & Omit<ComponentPropsWithoutRef<'section'>, keyof SelectSpotlightOwnProps | 'title'>;
|
package/dist/SelectText.d.ts
CHANGED
|
@@ -15,8 +15,10 @@ type SelectTextOwnProps = {
|
|
|
15
15
|
truncate?: boolean;
|
|
16
16
|
/** Tabular figures (align numbers in tables/amounts). */
|
|
17
17
|
numeric?: boolean;
|
|
18
|
+
/** Fonte monoespaçada — uma chave mascarada, um código, um IP (0.1.130). */
|
|
19
|
+
mono?: boolean;
|
|
18
20
|
className?: string;
|
|
19
21
|
};
|
|
20
22
|
export type SelectTextProps = SelectTextOwnProps & Omit<HTMLAttributes<HTMLElement>, keyof SelectTextOwnProps>;
|
|
21
|
-
export declare function SelectText({ children, as, variant, tone, fontWeight, alignment, truncate, numeric, className, ...rest }: SelectTextProps): import("react").JSX.Element;
|
|
23
|
+
export declare function SelectText({ children, as, variant, tone, fontWeight, alignment, truncate, numeric, mono, className, ...rest }: SelectTextProps): import("react").JSX.Element;
|
|
22
24
|
export {};
|
package/dist/index.d.ts
CHANGED
|
@@ -35,7 +35,9 @@ export { SelectDisclosureButton } from './SelectDisclosureButton';
|
|
|
35
35
|
export { SelectLinkButton } from './SelectLinkButton';
|
|
36
36
|
export { SelectDivider } from './SelectDivider';
|
|
37
37
|
export { SelectAlert } from './SelectAlert';
|
|
38
|
-
export { SelectAvatar } from './SelectAvatar';
|
|
38
|
+
export { SelectAvatar, avatarInitials } from './SelectAvatar';
|
|
39
|
+
export { SelectChipInput } from './SelectChipInput';
|
|
40
|
+
export type { SelectChipInputProps } from './SelectChipInput';
|
|
39
41
|
export { SelectOptionList, SelectOptionRow } from './SelectOptionList';
|
|
40
42
|
export { SelectIdentityFooter } from './SelectIdentityFooter';
|
|
41
43
|
export { SelectOtpInput } from './SelectOtpInput';
|