Front: Prettier

This commit is contained in:
Arthur Jamet 2023-12-09 11:51:26 +01:00 committed by Zoe Roux
parent ba16d7873f
commit db3f03dc6c
4 changed files with 9 additions and 6 deletions

View File

@ -18,4 +18,4 @@
* along with Kyoo. If not, see <https://www.gnu.org/licenses/>. * along with Kyoo. If not, see <https://www.gnu.org/licenses/>.
*/ */
export * from './image-border-radius'; export * from "./image-border-radius";

View File

@ -157,7 +157,10 @@ export const ItemGrid = ({
</PosterBackground> </PosterBackground>
<Skeleton> <Skeleton>
{isLoading || ( {isLoading || (
<P numberOfLines={subtitle ? 1 : 2} {...css([{ marginY: 0, textAlign: "center" }, "title"])}> <P
numberOfLines={subtitle ? 1 : 2}
{...css([{ marginY: 0, textAlign: "center" }, "title"])}
>
{name} {name}
</P> </P>
)} )}

View File

@ -29,7 +29,7 @@ import {
Heading, Heading,
Icon, Icon,
PosterBackground, PosterBackground,
ImageBorderRadius ImageBorderRadius,
} from "@kyoo/primitives"; } from "@kyoo/primitives";
import { useState } from "react"; import { useState } from "react";
import { View } from "react-native"; import { View } from "react-native";

View File

@ -127,7 +127,7 @@ export const ItemDetails = ({
})} })}
> >
<Skeleton {...css({ width: percent(100) })}> <Skeleton {...css({ width: percent(100) })}>
{isLoading || <P {...css([{ m: 0, color: 'white' }, "title"])}>{name}</P>} {isLoading || <P {...css([{ m: 0, color: "white" }, "title"])}>{name}</P>}
</Skeleton> </Skeleton>
{(subtitle || isLoading) && ( {(subtitle || isLoading) && (
<Skeleton {...css({ height: rem(0.8) })}> <Skeleton {...css({ height: rem(0.8) })}>
@ -159,7 +159,7 @@ export const ItemDetails = ({
minHeight: px(50), minHeight: px(50),
})} })}
> >
{( {
<ScrollView horizontal {...css({ alignItems: "center" })}> <ScrollView horizontal {...css({ alignItems: "center" })}>
{(genres ?? Array(3))?.map((x, i) => ( {(genres ?? Array(3))?.map((x, i) => (
<Chip key={x ?? i} size="small" {...css({ mX: ts(0.5) })}> <Chip key={x ?? i} size="small" {...css({ mX: ts(0.5) })}>
@ -167,7 +167,7 @@ export const ItemDetails = ({
</Chip> </Chip>
))} ))}
</ScrollView> </ScrollView>
)} }
{playHref !== null && ( {playHref !== null && (
<IconFab <IconFab
icon={PlayArrow} icon={PlayArrow}