Skip to content

Commit 75a7158

Browse files
fix(ui): prevent iOS zoom on Mosaic inputs
1 parent 83a2527 commit 75a7158

1 file changed

Lines changed: 12 additions & 3 deletions

File tree

packages/ui/src/mosaic/components/input/input.styles.ts

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -71,21 +71,30 @@ export const sizes = stylex.create({
7171
sm: {
7272
borderRadius: radiusVars['--cl-radius-control'],
7373
paddingInline: space['3'],
74-
fontSize: typeScaleVars['--cl-text-xs-size'],
74+
fontSize: {
75+
default: typeScaleVars['--cl-text-xs-size'],
76+
'@media (pointer: coarse)': `max(1rem, ${typeScaleVars['--cl-text-xs-size']})`,
77+
},
7578
lineHeight: typeScaleVars['--cl-text-xs-leading'],
7679
height: space['7'],
7780
},
7881
md: {
7982
borderRadius: radiusVars['--cl-radius-control'],
8083
paddingInline: space['3'],
81-
fontSize: typeScaleVars['--cl-text-sm-size'],
84+
fontSize: {
85+
default: typeScaleVars['--cl-text-sm-size'],
86+
'@media (pointer: coarse)': `max(1rem, ${typeScaleVars['--cl-text-sm-size']})`,
87+
},
8288
lineHeight: typeScaleVars['--cl-text-sm-leading'],
8389
height: space['8'],
8490
},
8591
lg: {
8692
borderRadius: radiusVars['--cl-radius-element'],
8793
paddingInline: space['3'],
88-
fontSize: typeScaleVars['--cl-text-base-size'],
94+
fontSize: {
95+
default: typeScaleVars['--cl-text-base-size'],
96+
'@media (pointer: coarse)': `max(1rem, ${typeScaleVars['--cl-text-base-size']})`,
97+
},
8998
lineHeight: 1.375,
9099
height: space['9'],
91100
},

0 commit comments

Comments
 (0)