mirror of
https://github.com/inventree/InvenTree.git
synced 2025-08-07 04:12:11 +00:00
update to new style
This commit is contained in:
@@ -69,7 +69,12 @@ export function ApiImage(props: ApiImageProps) {
|
|||||||
return (
|
return (
|
||||||
<Stack>
|
<Stack>
|
||||||
{image && image.length > 0 ? (
|
{image && image.length > 0 ? (
|
||||||
<Image {...props} src={image} withPlaceholder fit="contain" />
|
<Image
|
||||||
|
{...props}
|
||||||
|
src={image}
|
||||||
|
//fallbackSrc="https://placehold.co/600x400?text=Placeholder"
|
||||||
|
fit="contain"
|
||||||
|
/>
|
||||||
) : (
|
) : (
|
||||||
<Skeleton h={props?.h ?? props.w} w={props?.w ?? props.h} />
|
<Skeleton h={props?.h ?? props.w} w={props?.w ?? props.h} />
|
||||||
)}
|
)}
|
||||||
|
@@ -28,16 +28,12 @@ export function Thumbnail({
|
|||||||
<Group align={align ?? 'left'} gap="xs" wrap="nowrap">
|
<Group align={align ?? 'left'} gap="xs" wrap="nowrap">
|
||||||
<ApiImage
|
<ApiImage
|
||||||
src={src || backup_image}
|
src={src || backup_image}
|
||||||
alt={alt}
|
aria-label={alt}
|
||||||
width={size}
|
w={size}
|
||||||
fit="contain"
|
fit="contain"
|
||||||
radius="xs"
|
radius="xs"
|
||||||
withPlaceholder
|
//fallbackSrc="https://placehold.co/600x400?text=Placeholder"
|
||||||
imageProps={{
|
style={{ maxHeight: size }}
|
||||||
style: {
|
|
||||||
maxHeight: size
|
|
||||||
}
|
|
||||||
}}
|
|
||||||
/>
|
/>
|
||||||
{text}
|
{text}
|
||||||
</Group>
|
</Group>
|
||||||
|
@@ -86,7 +86,8 @@ export function PartCategoryTree({
|
|||||||
return {
|
return {
|
||||||
dark: {
|
dark: {
|
||||||
text: {
|
text: {
|
||||||
...vars.fontStyles()
|
fontFamily: vars.fontFamily,
|
||||||
|
fontSize: vars.fontSizes.md
|
||||||
},
|
},
|
||||||
nodes: {
|
nodes: {
|
||||||
height: '2.5rem',
|
height: '2.5rem',
|
||||||
@@ -106,7 +107,8 @@ export function PartCategoryTree({
|
|||||||
},
|
},
|
||||||
light: {
|
light: {
|
||||||
text: {
|
text: {
|
||||||
...theme.fn.fontStyles()
|
fontFamily: vars.fontFamily,
|
||||||
|
fontSize: vars.fontSizes.md
|
||||||
},
|
},
|
||||||
nodes: {
|
nodes: {
|
||||||
height: '2.5rem',
|
height: '2.5rem',
|
||||||
|
Reference in New Issue
Block a user