Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/red-cows-change.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@rocket.chat/fuselage': patch
---

fix(fuselage): `InputBox` spacing in leading and trailing addons
4 changes: 4 additions & 0 deletions packages/fuselage/fuselage.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -902,6 +902,8 @@ export const Input: ForwardRefExoticComponent<BoxProps & RefAttributes<HTMLInput
// @public (undocumented)
export const InputBox: ForwardRefExoticComponent<BoxProps & {
addon?: ReactNode;
startAddon?: ReactNode;
endAddon?: ReactNode;
input?: ReactNode;
multiple?: boolean;
error?: string;
Expand All @@ -914,6 +916,8 @@ type: "button" | "checkbox" | "color" | "date" | "datetime" | "datetime-local" |
// @public (undocumented)
export type InputBoxProps = BoxProps & {
addon?: ReactNode;
startAddon?: ReactNode;
endAddon?: ReactNode;
input?: ReactNode;
multiple?: boolean;
error?: string;
Expand Down
11 changes: 9 additions & 2 deletions packages/fuselage/src/components/InputBox/InputBox.styles.scss
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,6 @@ $input-border-radius: theme(

outline: 0;

gap: lengths.size(8);

@extend %input;

&:invalid,
Expand All @@ -60,6 +58,14 @@ $input-border-radius: theme(

align-items: flex-start;
flex: 0 0 auto;

&:has(+ .rcx-input-box) {
margin-inline-end: lengths.size(8);
}

.rcx-input-box + & {
margin-inline-start: lengths.size(8);
}
}

.rcx-input-box {
Expand All @@ -69,6 +75,7 @@ $input-border-radius: theme(

flex: 1 0 auto;

width: lengths.size(none);
min-width: lengths.size(128);

user-select: initial;
Expand Down
Loading