burne-ui 1.3.1 → 1.3.3
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/components/core/Input/inputStyles.d.ts +0 -1
- package/dist/components/core/Input/inputTypes.d.ts +1 -1
- package/dist/components/core/SearchInput/SearchInput.d.ts +1 -1
- package/dist/components/core/Select/selectStyles.d.ts +2 -1
- package/dist/components/core/Switch/Switch.d.ts +1 -2
- package/dist/components/core/Switch/switchAPI.d.ts +1 -0
- package/dist/components/core/TextArea/textAreaStyles.d.ts +0 -1
- package/dist/components/core/TextArea/textAreaTypes.d.ts +1 -1
- package/dist/components/core/TimeField/timeFieldStyles.d.ts +0 -1
- package/dist/components/core/TimeField/timeFieldTypes.d.ts +1 -1
- package/dist/components/core/utils/fieldShellVariant.d.ts +12 -0
- package/dist/components/core/utils/useFieldShellHoverLift.d.ts +2 -1
- package/dist/index.cjs +6 -6
- package/dist/index.js +6825 -6822
- package/dist/ui.css +4 -0
- package/package.json +1 -2
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { ButtonGroupSegment } from '../../composite/ButtonGroup/buttonGroupTypes';
|
|
2
2
|
import { InputSize, InputStatus, InputVariant } from './inputTypes';
|
|
3
|
-
export declare const INPUT_VARIANT_SHELL_CLASS: Record<Exclude<InputVariant, "gloss">, string>;
|
|
4
3
|
export declare const INPUT_STATUS_TINT_SHELL_CLASS: Record<Exclude<InputStatus, "default">, string>;
|
|
5
4
|
export declare const INPUT_STATUS_TINT_AFFIX_CLASS: Record<Exclude<InputStatus, "default">, string>;
|
|
6
5
|
export declare const INPUT_AFFIX_SURFACE_CLASS = "bg-primary-tint";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { HTMLAttributes, InputHTMLAttributes, PointerEventHandler, ReactNode } from 'react';
|
|
2
2
|
import { ButtonGroupSegment } from '../../composite/ButtonGroup/buttonGroupTypes';
|
|
3
3
|
import { ComponentSize } from '../utils/componentSize';
|
|
4
|
-
export type InputVariant = "default" | "outline" | "gloss";
|
|
4
|
+
export type InputVariant = "default" | "outline" | "secondary" | "gloss";
|
|
5
5
|
export type InputStatus = "default" | "danger" | "success" | "warning";
|
|
6
6
|
export type InputSize = ComponentSize;
|
|
7
7
|
export type InputClassNames = {
|
|
@@ -2,7 +2,7 @@ import { InputHTMLAttributes } from 'react';
|
|
|
2
2
|
import { ButtonGroupSegment } from '../../composite/ButtonGroup/buttonGroupTypes';
|
|
3
3
|
import { ComponentSize } from '../utils/componentSize';
|
|
4
4
|
export type SearchInputSize = ComponentSize;
|
|
5
|
-
export type SearchInputVariant = "default" | "gloss";
|
|
5
|
+
export type SearchInputVariant = "default" | "outline" | "secondary" | "gloss";
|
|
6
6
|
export type SearchInputProps = Omit<InputHTMLAttributes<HTMLInputElement>, "size" | "type"> & {
|
|
7
7
|
size?: SearchInputSize;
|
|
8
8
|
variant?: SearchInputVariant;
|
|
@@ -7,7 +7,8 @@ export declare const SELECT_VALUE_BASE_CLASS = "min-w-0 flex-1 truncate bg-trans
|
|
|
7
7
|
export declare const SELECT_VALUE_MUTED_CLASS = "text-muted";
|
|
8
8
|
export declare const SELECT_TRIGGER_BASE_CLASS = "flex shrink-0 origin-center items-center justify-center self-stretch px-small outline-none text-muted hover:text-foreground focus-ring";
|
|
9
9
|
export declare const SELECT_TRIGGER_DISABLED_CLASS = "pointer-events-none";
|
|
10
|
-
|
|
10
|
+
/** Above Dialog/Drawer (`z-[100]`), aligned with Dropdown submenus. */
|
|
11
|
+
export declare const SELECT_POPOVER_CLASS = "z-[110]";
|
|
11
12
|
export declare const SELECT_POPOVER_BODY_CLASS = "gap-0 p-base";
|
|
12
13
|
export declare const SELECT_LISTBOX_CLASS = "overflow-y-auto overflow-x-hidden";
|
|
13
14
|
export declare const SELECT_TRIGGER_GROUP_DISABLED_CLASS = "cursor-not-allowed opacity-55 shadow-token-base";
|
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import { LabelHTMLAttributes } from 'react';
|
|
2
1
|
import { SwitchContent, SwitchControl, SwitchError, SwitchFill, SwitchHint, SwitchIcon, SwitchLabel, SwitchThumb, SwitchTrack } from './switchParts';
|
|
3
2
|
import { SwitchControlProps } from './switchTypes';
|
|
4
3
|
export type { SwitchClassNames, SwitchControlProps, SwitchTrackProps, SwitchFillProps, SwitchThumbProps, SwitchIconProps, SwitchIconWhen, SwitchSize, SwitchLabelPosition, SwitchContentProps, SwitchLabelProps, SwitchHintProps, SwitchErrorProps, SwitchRootProps, SwitchSimpleProps, } from './switchTypes';
|
|
5
4
|
export { SWITCH_LAYOUT } from './switchStyles';
|
|
6
|
-
export declare const SwitchRoot: import('react').ForwardRefExoticComponent<Omit<LabelHTMLAttributes<HTMLLabelElement>, "children" | "onChange" | "onPointerDown" | "htmlFor"> & {
|
|
5
|
+
export declare const SwitchRoot: import('react').ForwardRefExoticComponent<Omit<import('react').LabelHTMLAttributes<HTMLLabelElement>, "children" | "onChange" | "onPointerDown" | "htmlFor"> & {
|
|
7
6
|
children?: import('react').ReactNode;
|
|
8
7
|
label?: import('react').ReactNode;
|
|
9
8
|
hint?: import('react').ReactNode;
|
|
@@ -3,6 +3,7 @@ import { ClassValue } from 'clsx';
|
|
|
3
3
|
export declare function mergeSwitchSlotClass(...parts: ClassValue[]): string;
|
|
4
4
|
export declare function useMergedChecked(checked: boolean | undefined, defaultChecked: boolean | undefined): [boolean, (next: boolean) => void, boolean];
|
|
5
5
|
export declare function compoundUsesInlineMotion(className: string | undefined): boolean;
|
|
6
|
+
export declare function injectSwitchControlProps(children: ReactNode, controlProps: Record<string, unknown>): ReactNode;
|
|
6
7
|
export declare function compoundHasLabel(children: ReactNode): boolean;
|
|
7
8
|
export declare function countSecondaryLines(isCompound: boolean, hasHint: boolean, hasError: boolean, hasCompoundHint: boolean, hasCompoundError: boolean): number;
|
|
8
9
|
export declare function partitionSwitchControlChildren(children: ReactNode): {
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { TextAreaSize, TextAreaStatus, TextAreaVariant } from './textAreaTypes';
|
|
2
|
-
export declare const TEXTAREA_VARIANT_SHELL_CLASS: Record<Exclude<TextAreaVariant, "gloss">, string>;
|
|
3
2
|
export declare const TEXTAREA_STATUS_TINT_SHELL_CLASS: Record<Exclude<TextAreaStatus, "default">, string>;
|
|
4
3
|
export declare const TEXTAREA_MIN_H: Record<TextAreaSize, string>;
|
|
5
4
|
export declare const TEXTAREA_SHELL_LAYOUT_CLASS = "flex flex-col items-stretch";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { HTMLAttributes, PointerEventHandler, ReactNode, TextareaHTMLAttributes } from 'react';
|
|
2
2
|
import { ComponentSize } from '../utils/componentSize';
|
|
3
|
-
export type TextAreaVariant = "default" | "outline" | "gloss";
|
|
3
|
+
export type TextAreaVariant = "default" | "outline" | "secondary" | "gloss";
|
|
4
4
|
export type TextAreaStatus = "default" | "danger" | "success" | "warning";
|
|
5
5
|
export type TextAreaSize = ComponentSize;
|
|
6
6
|
export type TextAreaClassNames = {
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { TimeFieldSize, TimeFieldStatus, TimeFieldVariant } from './timeFieldTypes';
|
|
2
|
-
export declare const TIME_FIELD_VARIANT_SHELL_CLASS: Record<Exclude<TimeFieldVariant, "outline" | "gloss">, string>;
|
|
3
2
|
export declare const TIME_FIELD_STATUS_TINT_SHELL_CLASS: Record<Exclude<TimeFieldStatus, "default">, string>;
|
|
4
3
|
export declare const TIME_FIELD_STATUS_TINT_AFFIX_CLASS: Record<Exclude<TimeFieldStatus, "default">, string>;
|
|
5
4
|
export declare const TIME_FIELD_AFFIX_SURFACE_CLASS = "bg-primary-tint";
|
|
@@ -2,7 +2,7 @@ import { HTMLAttributes, PointerEventHandler, ReactNode } from 'react';
|
|
|
2
2
|
import { ComponentSize } from '../utils/componentSize';
|
|
3
3
|
export type TimeFieldSize = ComponentSize;
|
|
4
4
|
export type TimeFieldStatus = "default" | "danger" | "success" | "warning";
|
|
5
|
-
export type TimeFieldVariant = "default" | "outline" | "segmented" | "gloss";
|
|
5
|
+
export type TimeFieldVariant = "default" | "outline" | "secondary" | "segmented" | "gloss";
|
|
6
6
|
export type TimeFieldFormat = "HH:mm" | "HH:mm:ss";
|
|
7
7
|
export type TimeFieldSegId = "h" | "m" | "s";
|
|
8
8
|
export type TimeFieldHMS = {
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ButtonVariant } from '../Button/buttonTypes';
|
|
2
|
+
/** Shared visual variants for field shells (Input, TextArea, Select, ComboBox, TimeField, SearchInput). */
|
|
3
|
+
export type FieldShellVariant = "default" | "outline" | "secondary" | "gloss";
|
|
4
|
+
export type FieldShellFilledVariant = Exclude<FieldShellVariant, "gloss">;
|
|
5
|
+
export declare const FIELD_SHELL_VARIANT_BG_CLASS: Record<FieldShellFilledVariant, string>;
|
|
6
|
+
export declare function fieldShellHoverVariantForShell(variant: FieldShellFilledVariant): "default" | "secondary";
|
|
7
|
+
export declare function fieldShellVariantFromButtonGroup(groupVariant?: ButtonVariant): FieldShellFilledVariant | "gloss";
|
|
8
|
+
export declare function resolveFieldShellSurfaceClass({ variant, statusTinted, statusTintClass, }: {
|
|
9
|
+
variant: FieldShellVariant;
|
|
10
|
+
statusTinted: boolean;
|
|
11
|
+
statusTintClass: string;
|
|
12
|
+
}): string;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { RefObject } from 'react';
|
|
2
|
+
import { FieldShellFilledVariant } from './fieldShellVariant';
|
|
2
3
|
export type FieldShellStatus = "default" | "danger" | "success" | "warning";
|
|
3
4
|
/** Field shell hover background via `hoverVariant`; `focus-within` — focus on inner control. */
|
|
4
|
-
export declare function fieldShellHoverClass(enabled: boolean, status?: FieldShellStatus): string;
|
|
5
|
+
export declare function fieldShellHoverClass(enabled: boolean, status?: FieldShellStatus, variant?: FieldShellFilledVariant): string;
|
|
5
6
|
/** Shell transition: background, shadow, focus-ring (always, including disabled). */
|
|
6
7
|
export declare const FIELD_SHELL_TRANSITION_CLASS = "field-shell-transition motion-reduce:transition-none";
|
|
7
8
|
/** Outer primary focus ring on shell `:focus-within`. */
|