@selfcommunity/react-templates
Version:
React Templates Components to integrate a Community created with SelfCommunity.
33 lines (28 loc) • 2.13 kB
JavaScript
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
import { Typography, CardContent, Skeleton, CardActions, CardMedia, Button, styled } from '@mui/material';
import { Widget } from '@selfcommunity/react-ui';
import { PREFIX } from './constants';
const classes = {
root: `${PREFIX}-prize-item-skeleton-root`,
content: `${PREFIX}-content`,
actions: `${PREFIX}-actions`
};
const Root = styled(Widget, {
name: PREFIX,
slot: 'PrizeItemSkeletonRoot'
})(() => ({}));
/**
* > API documentation for the Community-JS PrizeItemSkeleton Skeleton component. Learn about the available props and the CSS API.
#### Component Name
The name `SCLoyaltyProgramDetailTemplate-prize-item-skeleton-root` can be used when providing style overrides in the theme.
#### CSS
|Rule Name|Global class|Description|
|---|---|---|
|root|.SCLoyaltyProgramDetailTemplate-prize-item-skeleton-root|Styles applied to the root element.|
|content|.SCLoyaltyProgramDetailTemplate-content|Styles applied to the card content section.|
|actions|.SCLoyaltyProgramDetailTemplate-actions|Styles applied to the actions section.|
*
*/
export default function PrizeItemSkeleton() {
return (_jsxs(Root, Object.assign({ className: classes.root }, { children: [_jsx(CardMedia, { children: _jsx(Skeleton, { animation: "wave", variant: "rectangular", width: "100%", height: 137 }) }), _jsx(CardContent, { children: _jsxs(Typography, Object.assign({ className: classes.content }, { children: [_jsx(Skeleton, { animation: "wave", height: 20, width: "80%", variant: "text" }), _jsx(Skeleton, { animation: "wave", height: 10, width: "70%", variant: "text", style: { marginTop: 8 } })] })) }), _jsxs(CardActions, Object.assign({ className: classes.actions }, { children: [_jsx(Button, Object.assign({ disabled: true, variant: 'outlined', size: 'small' }, { children: _jsx(Skeleton, { animation: "wave", height: 10, width: 50, variant: "text" }) })), _jsx(Button, Object.assign({ disabled: true, variant: 'text', size: 'small' }, { children: _jsx(Skeleton, { animation: "wave", height: 20, width: 70, variant: "text" }) }))] }))] })));
}