Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
8cb421f
fix inline spacing
yceballost Jun 22, 2026
a255f5d
fix inline spacing
yceballost Jun 23, 2026
1a6520b
fix switch transparent layer misalignment
yceballost Jun 23, 2026
f943854
fix vertical spacing in switches
yceballost Jun 23, 2026
e842fb4
Update inline-cases-story.tsx
yceballost Jun 23, 2026
564dad4
use component text in inline cases story
yceballost Jun 23, 2026
b8f022c
resolve cr comments
yceballost Jun 23, 2026
5a070c7
fix switch in lists
yceballost Jun 30, 2026
99646fa
prettier
yceballost Jun 30, 2026
d1ac62a
Merge branch 'master' into iceballos-fix-inline-spacing
yceballost Jun 30, 2026
820f645
use fallback in inline and remove stretch from progressBar inline
yceballost Jun 30, 2026
068e3d3
fix screenshot
yceballost Jun 30, 2026
f7302f3
fix inline spacing
yceballost Jul 1, 2026
0ecb72e
revert this switch change
yceballost Jul 1, 2026
9258f47
Merge branch 'master' into iceballos-fix-inline-spacing
yceballost Jul 15, 2026
fcefa11
update screenshots
yceballost Jul 15, 2026
d612bb7
Merge branch 'master' into iceballos-fix-inline-spacing
yceballost Jul 15, 2026
59b086a
chore(migration-guide)!: update migration guide (#1652)
brtbrt Jul 15, 2026
35693e5
chore(release): 16.72.0 [skip ci]
semantic-release-bot Jul 15, 2026
253c68d
remove vivo-new screenshots
yceballost Jul 15, 2026
e192822
remove tu screenshots
yceballost Jul 15, 2026
6e9a01c
remove screenshots
yceballost Jul 15, 2026
90d07a8
Merge branch 'master' into iceballos-fix-inline-spacing
yceballost Jul 16, 2026
6a7b617
Merge branch 'master' into iceballos-fix-inline-spacing
yceballost Jul 16, 2026
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
2 changes: 1 addition & 1 deletion src/__private_stories__/inline-cases-story.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ export const Default: StoryComponent = () => {
<ButtonPrimary fake>{shortText}</ButtonPrimary>
<ButtonPrimary fake>{shortText}</ButtonPrimary>
</Inline>{' '}
Inline text
<Text3 regular>Inline text</Text3>
</>
</Stack>

Expand Down

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

music for my eyes

Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is expected, we are showing more space than 8px

Image

11 changes: 11 additions & 0 deletions src/inline.css.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ const verticalSpaceMobile = createVar();
const verticalSpaceTablet = createVar();
const verticalSpaceDesktop = createVar();

const childAlignItems = createVar();
const childDisplay = createVar();

export const vars = {
space,
spaceMobile,
Expand All @@ -20,6 +23,8 @@ export const vars = {
verticalSpaceMobile,
verticalSpaceTablet,
verticalSpaceDesktop,
childAlignItems,
childDisplay,
};

export const marginInline = style({
Expand Down Expand Up @@ -81,10 +86,12 @@ export const fullWidth = style({
export const wrap = style({
display: 'inline-flex',
flexWrap: 'wrap',
verticalAlign: 'bottom',
});

export const noFullWidth = style({
display: ['inline-flex', 'inline-grid'],
verticalAlign: 'bottom',
});

export const stringSpace = style({
Expand Down Expand Up @@ -122,6 +129,10 @@ globalStyle(`${inline} > div`, {
padding: 0, // restore
// negative gap is not supported in flexbox, so we use negative margins instead
margin: `0 0 0 calc(min(${space}, 0px))`,
// Propagate alignItems to wrapper divs so icon SVGs (inline elements) are
// correctly centered within each wrapper, not just the wrappers themselves.
display: fallbackVar(childDisplay, 'block'),
alignItems: fallbackVar(childAlignItems, 'stretch'),
},
},
});
Expand Down
41 changes: 26 additions & 15 deletions src/inline.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ const calcSpaceValue = (space: NumericSpace | FlexSpace) => {

const calcInlineVars = (
space: FlexSpace | ByBreakpoint<NumericSpace>,
verticalSpace?: ByBreakpoint<NumericSpace>
verticalSpace?: ByBreakpoint<NumericSpace>,
alignItems?: Props['alignItems']
) => {
const calcSpaceVars = (
space: FlexSpace | ByBreakpoint<NumericSpace>,
Expand Down Expand Up @@ -50,21 +51,28 @@ const calcInlineVars = (
desktop: styles.vars.spaceDesktop,
});

if (verticalSpace) {
const verticalSpaceVars = calcSpaceVars(verticalSpace, {
default: styles.vars.verticalSpace,
mobile: styles.vars.verticalSpaceMobile,
tablet: styles.vars.verticalSpaceTablet,
desktop: styles.vars.verticalSpaceDesktop,
});
const verticalSpaceVars = verticalSpace
? calcSpaceVars(verticalSpace, {
default: styles.vars.verticalSpace,
mobile: styles.vars.verticalSpaceMobile,
tablet: styles.vars.verticalSpaceTablet,
desktop: styles.vars.verticalSpaceDesktop,
})
: {};

return {
...spaceVars,
...verticalSpaceVars,
};
}
const alignItemsVars =
alignItems !== undefined && alignItems !== 'stretch'
? {
[styles.vars.childDisplay]: 'flex',
[styles.vars.childAlignItems]: alignItems,
}
: {};

return spaceVars;
return {
...spaceVars,
...verticalSpaceVars,
...alignItemsVars,
};
};

type Props = {
Expand Down Expand Up @@ -131,7 +139,10 @@ const Inline = ({
: styles.marginInline,
shouldExpand && styles.expand
)}
style={{...applyCssVars(calcInlineVars(space, verticalSpace)), alignItems}}
style={{
...applyCssVars(calcInlineVars(space, verticalSpace, alignItems)),
alignItems,
}}
role={role}
aria-label={ariaLabel}
aria-labelledby={ariaLabel ? undefined : ariaLabelledBy}
Expand Down
2 changes: 2 additions & 0 deletions src/switch-component.css.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,8 @@ export const container = style([
containerBase,
{
cursor: 'pointer',
display: 'flex',

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image

This change resolve this problem, also improve the ios switch screenshots

flexDirection: 'column',
},
]);
export const containerDisabled = style([
Expand Down
Loading