Alignment
This commit is contained in:
@@ -201,7 +201,10 @@ export function createInput(Component: typeof TextInput) {
|
|||||||
a.text_md,
|
a.text_md,
|
||||||
t.atoms.text,
|
t.atoms.text,
|
||||||
a.px_xs,
|
a.px_xs,
|
||||||
{lineHeight: a.text_md.lineHeight * 1.1875},
|
{
|
||||||
|
lineHeight: a.text_md.lineHeight * 1.1875,
|
||||||
|
textAlignVertical: 'top',
|
||||||
|
},
|
||||||
]}
|
]}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import React from 'react'
|
import React from 'react'
|
||||||
import {Pressable, View, ViewStyle} from 'react-native'
|
import {Pressable, View, ViewStyle} from 'react-native'
|
||||||
|
|
||||||
import {useTheme, atoms as a, web} from '#/alf'
|
import {useTheme, atoms as a, web, native} from '#/alf'
|
||||||
import {Text} from '#/components/Typography'
|
import {Text} from '#/components/Typography'
|
||||||
import {useInteractionState} from '#/components/hooks/useInteractionState'
|
import {useInteractionState} from '#/components/hooks/useInteractionState'
|
||||||
|
|
||||||
@@ -241,6 +241,9 @@ export function Label({children}: React.PropsWithChildren<{}>) {
|
|||||||
userSelect: 'none',
|
userSelect: 'none',
|
||||||
color: disabled ? t.palette.contrast_400 : t.palette.contrast_600,
|
color: disabled ? t.palette.contrast_400 : t.palette.contrast_600,
|
||||||
},
|
},
|
||||||
|
native({
|
||||||
|
paddingTop: 3,
|
||||||
|
}),
|
||||||
]}>
|
]}>
|
||||||
{children}
|
{children}
|
||||||
</Text>
|
</Text>
|
||||||
@@ -345,8 +348,6 @@ export function Checkbox() {
|
|||||||
{
|
{
|
||||||
height: 20,
|
height: 20,
|
||||||
width: 20,
|
width: 20,
|
||||||
backgroundColor: selected ? t.palette.primary_500 : undefined,
|
|
||||||
borderColor: selected ? t.palette.primary_500 : undefined,
|
|
||||||
},
|
},
|
||||||
baseStyles,
|
baseStyles,
|
||||||
hovered || focused ? baseHoverStyles : {},
|
hovered || focused ? baseHoverStyles : {},
|
||||||
@@ -445,8 +446,6 @@ export function Radio() {
|
|||||||
{
|
{
|
||||||
height: 20,
|
height: 20,
|
||||||
width: 20,
|
width: 20,
|
||||||
backgroundColor: selected ? t.palette.primary_500 : undefined,
|
|
||||||
borderColor: selected ? t.palette.primary_500 : undefined,
|
|
||||||
},
|
},
|
||||||
baseStyles,
|
baseStyles,
|
||||||
hovered || focused ? baseHoverStyles : {},
|
hovered || focused ? baseHoverStyles : {},
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import React from 'react'
|
import React from 'react'
|
||||||
import {View, AccessibilityProps, TextStyle, ViewStyle} from 'react-native'
|
import {View, AccessibilityProps, TextStyle, ViewStyle} from 'react-native'
|
||||||
|
|
||||||
import {atoms as a, useTheme} from '#/alf'
|
import {atoms as a, useTheme, native} from '#/alf'
|
||||||
import {Text} from '#/components/Typography'
|
import {Text} from '#/components/Typography'
|
||||||
|
|
||||||
import * as Toggle from '#/components/forms/Toggle'
|
import * as Toggle from '#/components/forms/Toggle'
|
||||||
@@ -91,14 +91,17 @@ function ButtonInner({children}: React.PropsWithChildren<{}>) {
|
|||||||
return (
|
return (
|
||||||
<View
|
<View
|
||||||
style={[
|
style={[
|
||||||
a.px_lg,
|
|
||||||
a.py_md,
|
|
||||||
t.atoms.bg,
|
|
||||||
t.atoms.border,
|
|
||||||
{
|
{
|
||||||
borderLeftWidth: 1,
|
borderLeftWidth: 1,
|
||||||
marginLeft: -1,
|
marginLeft: -1,
|
||||||
},
|
},
|
||||||
|
a.px_lg,
|
||||||
|
a.py_md,
|
||||||
|
native({
|
||||||
|
paddingTop: 14,
|
||||||
|
}),
|
||||||
|
t.atoms.bg,
|
||||||
|
t.atoms.border,
|
||||||
baseStyles,
|
baseStyles,
|
||||||
activeStyles,
|
activeStyles,
|
||||||
(state.hovered || state.focused || state.pressed) && hoverStyles,
|
(state.hovered || state.focused || state.pressed) && hoverStyles,
|
||||||
|
|||||||
Reference in New Issue
Block a user