@botiverse/raft-ui 0.68.0 → 0.69.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/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,12 @@
|
|
|
1
|
+
## [0.69.0](https://github.com/botiverse/raft-design/compare/v0.68.0...v0.69.0) (2026-11-06)
|
|
2
|
+
|
|
3
|
+
### Added
|
|
4
|
+
|
|
5
|
+
- **InputGroup** `size`: `md` for a field in a toolbar or a filter row, `lg` (the default, unchanged) for a field on its own. At `md` the field is the row's button height: 32px on a phone and a touch screen, like the `md` Buttons and PickerTriggerButtons beside it, with its input taking a 44px tap area, 6px past the box above and below; with a mouse it stays the control height, 34px. The root carries `data-size`. A Button in an `md` field's end addon is 20px by touch (22px with a mouse), 6px inside the box. ([#1039](https://github.com/botiverse/raft-design/pull/1039))
|
|
6
|
+
- Why: on a tablet held landscape, a 44px search field beside 32px filter triggers and a view switch read taller and heavier than the rest of the filter row; a field in a row now takes the row's button height.
|
|
7
|
+
- Affects: nothing until a field opts in with `size="md"`; every InputGroup without it renders as before.
|
|
8
|
+
- Docs: https://raft-design.botiverse.build/components/input-group/#sizes
|
|
9
|
+
|
|
1
10
|
## [0.68.0](https://github.com/botiverse/raft-design/compare/v0.67.0...v0.68.0) (2026-11-06)
|
|
2
11
|
|
|
3
12
|
### Changed
|
|
@@ -7,6 +7,12 @@ import { ComponentPropsWithRef } from "react";
|
|
|
7
7
|
import { Input } from "@base-ui/react/input";
|
|
8
8
|
//#region src/components/input-group/input-group.d.ts
|
|
9
9
|
declare const inputGroup: import("tailwind-variants/lite").TVReturnType<{
|
|
10
|
+
size: {
|
|
11
|
+
md: {
|
|
12
|
+
root: string[];
|
|
13
|
+
};
|
|
14
|
+
lg: {};
|
|
15
|
+
};
|
|
10
16
|
align: {
|
|
11
17
|
"inline-start": {
|
|
12
18
|
addon: string;
|
|
@@ -31,6 +37,12 @@ declare const inputGroup: import("tailwind-variants/lite").TVReturnType<{
|
|
|
31
37
|
textInner: string[];
|
|
32
38
|
control: string[];
|
|
33
39
|
}, undefined, {
|
|
40
|
+
size: {
|
|
41
|
+
md: {
|
|
42
|
+
root: string[];
|
|
43
|
+
};
|
|
44
|
+
lg: {};
|
|
45
|
+
};
|
|
34
46
|
align: {
|
|
35
47
|
"inline-start": {
|
|
36
48
|
addon: string;
|
|
@@ -55,6 +67,12 @@ declare const inputGroup: import("tailwind-variants/lite").TVReturnType<{
|
|
|
55
67
|
textInner: string[];
|
|
56
68
|
control: string[];
|
|
57
69
|
}, import("tailwind-variants/lite").TVReturnTypeLike<{
|
|
70
|
+
size: {
|
|
71
|
+
md: {
|
|
72
|
+
root: string[];
|
|
73
|
+
};
|
|
74
|
+
lg: {};
|
|
75
|
+
};
|
|
58
76
|
align: {
|
|
59
77
|
"inline-start": {
|
|
60
78
|
addon: string;
|
|
@@ -79,8 +97,16 @@ declare const inputGroup: import("tailwind-variants/lite").TVReturnType<{
|
|
|
79
97
|
textInner: string[];
|
|
80
98
|
control: string[];
|
|
81
99
|
}>>;
|
|
82
|
-
export type InputGroupProps = ComponentPropsWithRef<"div"
|
|
83
|
-
|
|
100
|
+
export type InputGroupProps = ComponentPropsWithRef<"div"> & {
|
|
101
|
+
/**
|
|
102
|
+
* `lg` (default): the control height, for a field on its own in a form or a
|
|
103
|
+
* dialog. `md`: a field in a toolbar or a filter row, as high as the row's
|
|
104
|
+
* `md` buttons and filter triggers (32px by touch, with a 44px tap area; the
|
|
105
|
+
* control height with a mouse).
|
|
106
|
+
*/
|
|
107
|
+
size?: "md" | "lg";
|
|
108
|
+
};
|
|
109
|
+
export declare function InputGroup({ size, className, ...props }: InputGroupProps): import("react").JSX.Element;
|
|
84
110
|
export type InputGroupAddonProps = ComponentPropsWithRef<"div"> & Pick<VariantProps<typeof inputGroup>, "align" | "variant">;
|
|
85
111
|
declare function InputGroupAddonRoot({ align, variant, className, ...props }: InputGroupAddonProps): import("react").JSX.Element;
|
|
86
112
|
export type InputGroupAddonTextProps = ComponentPropsWithRef<"span"> & Pick<VariantProps<typeof inputGroup>, "align" | "variant">;
|
|
@@ -37,6 +37,18 @@ const inputGroup = tv({
|
|
|
37
37
|
]
|
|
38
38
|
},
|
|
39
39
|
variants: {
|
|
40
|
+
size: {
|
|
41
|
+
md: { root: [
|
|
42
|
+
"h-8 md:pointer-fine:h-control rounded-control overflow-visible",
|
|
43
|
+
"[--ig-hit:calc(--spacing(1.5)+1.5px)] md:pointer-fine:[--ig-hit:0px]",
|
|
44
|
+
"*:data-[slot=input-group-control]:-my-(--ig-hit) *:data-[slot=input-group-control]:h-[calc(100%+2*var(--ig-hit))]",
|
|
45
|
+
"[--control-embedded-size:calc(2rem-2*var(--control-embedded-inset))]",
|
|
46
|
+
"md:pointer-fine:[--control-embedded-size:calc(var(--control-height)-2*var(--control-embedded-inset))]",
|
|
47
|
+
"*:data-[variant=container]:data-[align=inline-start]:rounded-s-[calc(var(--radius-control)-1.5px)]",
|
|
48
|
+
"*:data-[variant=container]:data-[align=inline-end]:rounded-e-[calc(var(--radius-control)-1.5px)]"
|
|
49
|
+
] },
|
|
50
|
+
lg: {}
|
|
51
|
+
},
|
|
40
52
|
align: {
|
|
41
53
|
"inline-start": {
|
|
42
54
|
addon: "order-first",
|
|
@@ -111,14 +123,16 @@ const inputGroup = tv({
|
|
|
111
123
|
}
|
|
112
124
|
],
|
|
113
125
|
defaultVariants: {
|
|
126
|
+
size: "lg",
|
|
114
127
|
align: "inline-start",
|
|
115
128
|
variant: "default"
|
|
116
129
|
}
|
|
117
130
|
});
|
|
118
|
-
function InputGroup({ className, ...props }) {
|
|
119
|
-
const { root } = inputGroup();
|
|
131
|
+
function InputGroup({ size = "lg", className, ...props }) {
|
|
132
|
+
const { root } = inputGroup({ size });
|
|
120
133
|
return /* @__PURE__ */ jsx("div", {
|
|
121
134
|
"data-slot": "input-group",
|
|
135
|
+
"data-size": size,
|
|
122
136
|
className: root({ className }),
|
|
123
137
|
...props
|
|
124
138
|
});
|