1
0
Fork 0

worked on GarageApp stuff

This commit is contained in:
Techognito 2025-08-25 17:46:11 +02:00
parent 60aaf17af3
commit eb606572b0
51919 changed files with 2168177 additions and 18 deletions

View file

@ -0,0 +1,157 @@
import * as React from 'react';
import { SxProps } from '@mui/system';
import { TypographyProps } from "../Typography/index.js";
import { OverridableComponent, OverrideProps } from "../OverridableComponent/index.js";
import { Theme } from "../styles/index.js";
import { CreateSlotsAndSlotProps, SlotProps } from "../utils/types.js";
import { CardHeaderClasses } from "./cardHeaderClasses.js";
export interface CardHeaderRootSlotPropsOverrides {}
export interface CardHeaderAvatarSlotPropsOverrides {}
export interface CardHeaderActionSlotPropsOverrides {}
export interface CardHeaderContentSlotPropsOverrides {}
export interface CardHeaderTitleSlotPropsOverrides {}
export interface CardHeaderSubheaderSlotPropsOverrides {}
export interface CardHeaderSlots {
/**
* The component that renders the root slot.
* @default 'div'
*/
root: React.ElementType;
/**
* The component that renders the avatar slot.
* @default 'div'
*/
avatar: React.ElementType;
/**
* The component that renders the action slot.
* @default 'div'
*/
action: React.ElementType;
/**
* The component that renders the content slot.
* @default 'div'
*/
content: React.ElementType;
/**
* The component that renders the title slot (as long as disableTypography is not `true`).
* [Follow this guide](https://mui.com/material-ui/api/typography/#props) to learn more about the requirements for this component.
* @default Typography
*/
title: React.ElementType;
/**
* The component that renders the subheader slot (as long as disableTypography is not `true`).
* [Follow this guide](https://mui.com/material-ui/api/typography/#props) to learn more about the requirements for this component.
* @default Typography
*/
subheader: React.ElementType;
}
export type CardHeaderSlotsAndSlotProps = CreateSlotsAndSlotProps<CardHeaderSlots, {
/**
* Props forwarded to the root slot.
* By default, the avaible props are based on the div element.
*/
root: SlotProps<'div', CardHeaderRootSlotPropsOverrides, CardHeaderOwnerState>;
/**
* Props forwarded to the avatar slot.
* By default, the avaible props are based on the div element.
*/
avatar: SlotProps<'div', CardHeaderAvatarSlotPropsOverrides, CardHeaderOwnerState>;
/**
* Props forwarded to the action slot.
* By default, the avaible props are based on the div element.
*/
action: SlotProps<'div', CardHeaderActionSlotPropsOverrides, CardHeaderOwnerState>;
/**
* Props forwarded to the content slot.
* By default, the avaible props are based on the div element.
*/
content: SlotProps<'div', CardHeaderContentSlotPropsOverrides, CardHeaderOwnerState>;
/**
* Props forwarded to the title slot (as long as disableTypography is not `true`).
* By default, the avaible props are based on the [Typography](https://mui.com/material-ui/api/typography/#props) component.
*/
title: SlotProps<React.ElementType<TypographyProps>, CardHeaderTitleSlotPropsOverrides, CardHeaderOwnerState>;
/**
* Props forwarded to the subheader slot (as long as disableTypography is not `true`).
* By default, the avaible props are based on the [Typography](https://mui.com/material-ui/api/typography/#props) component.
*/
subheader: SlotProps<React.ElementType<TypographyProps>, CardHeaderSubheaderSlotPropsOverrides, CardHeaderOwnerState>;
}>;
export interface CardHeaderOwnProps<TitleTypographyComponent extends React.ElementType = 'span', SubheaderTypographyComponent extends React.ElementType = 'span'> {
/**
* The action to display in the card header.
*/
action?: React.ReactNode;
/**
* The Avatar element to display.
*/
avatar?: React.ReactNode;
/**
* Override or extend the styles applied to the component.
*/
classes?: Partial<CardHeaderClasses>;
/**
* If `true`, `subheader` and `title` won't be wrapped by a Typography component.
* This can be useful to render an alternative Typography variant by wrapping
* the `title` text, and optional `subheader` text
* with the Typography component.
* @default false
*/
disableTypography?: boolean;
/**
* The content of the component.
*/
subheader?: React.ReactNode;
/**
* These props will be forwarded to the subheader
* (as long as disableTypography is not `true`).
* @deprecated Use `slotProps.subheader` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
*/
subheaderTypographyProps?: TypographyProps<SubheaderTypographyComponent, {
component?: SubheaderTypographyComponent;
}>;
/**
* The system prop that allows defining system overrides as well as additional CSS styles.
*/
sx?: SxProps<Theme>;
/**
* The content of the component.
*/
title?: React.ReactNode;
/**
* These props will be forwarded to the title
* (as long as disableTypography is not `true`).
* @deprecated Use `slotProps.title` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
*/
titleTypographyProps?: TypographyProps<TitleTypographyComponent, {
component?: TitleTypographyComponent;
}>;
}
export interface CardHeaderOwnerState extends CardHeaderOwnProps {}
export interface CardHeaderTypeMap<AdditionalProps = {}, RootComponent extends React.ElementType = 'div', TitleTypographyComponent extends React.ElementType = 'span', SubheaderTypographyComponent extends React.ElementType = 'span'> {
props: AdditionalProps & CardHeaderOwnProps<TitleTypographyComponent, SubheaderTypographyComponent> & CardHeaderSlotsAndSlotProps;
defaultComponent: RootComponent;
}
/**
*
* Demos:
*
* - [Card](https://mui.com/material-ui/react-card/)
*
* API:
*
* - [CardHeader API](https://mui.com/material-ui/api/card-header/)
*/
declare const CardHeader: OverridableCardHeader;
export interface OverridableCardHeader extends OverridableComponent<CardHeaderTypeMap> {
<RootComponent extends React.ElementType = CardHeaderTypeMap['defaultComponent'], AdditionalProps = {}, TitleTypographyComponent extends React.ElementType = 'span', SubheaderTypographyComponent extends React.ElementType = 'span'>(props: CardHeaderPropsWithComponent<RootComponent, AdditionalProps, TitleTypographyComponent, SubheaderTypographyComponent>): React.JSX.Element;
}
export type CardHeaderProps<RootComponent extends React.ElementType = CardHeaderTypeMap['defaultComponent'], AdditionalProps = {}, TitleTypographyComponent extends React.ElementType = 'span', SubheaderTypographyComponent extends React.ElementType = 'span'> = OverrideProps<CardHeaderTypeMap<AdditionalProps, RootComponent, TitleTypographyComponent, SubheaderTypographyComponent>, RootComponent>;
export type CardHeaderPropsWithComponent<RootComponent extends React.ElementType = CardHeaderTypeMap['defaultComponent'], AdditionalProps = {}, TitleTypographyComponent extends React.ElementType = 'span', SubheaderTypographyComponent extends React.ElementType = 'span'> = {
/**
* The component used for the root node.
* Either a string to use a HTML element or a component.
*/
component?: RootComponent;
} & CardHeaderProps<RootComponent, AdditionalProps, TitleTypographyComponent, SubheaderTypographyComponent>;
export default CardHeader;

264
node_modules/@mui/material/esm/CardHeader/CardHeader.js generated vendored Normal file
View file

@ -0,0 +1,264 @@
'use client';
import * as React from 'react';
import PropTypes from 'prop-types';
import composeClasses from '@mui/utils/composeClasses';
import Typography, { typographyClasses } from "../Typography/index.js";
import { styled } from "../zero-styled/index.js";
import { useDefaultProps } from "../DefaultPropsProvider/index.js";
import cardHeaderClasses, { getCardHeaderUtilityClass } from "./cardHeaderClasses.js";
import useSlot from "../utils/useSlot.js";
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
const useUtilityClasses = ownerState => {
const {
classes
} = ownerState;
const slots = {
root: ['root'],
avatar: ['avatar'],
action: ['action'],
content: ['content'],
title: ['title'],
subheader: ['subheader']
};
return composeClasses(slots, getCardHeaderUtilityClass, classes);
};
const CardHeaderRoot = styled('div', {
name: 'MuiCardHeader',
slot: 'Root',
overridesResolver: (props, styles) => {
return [{
[`& .${cardHeaderClasses.title}`]: styles.title
}, {
[`& .${cardHeaderClasses.subheader}`]: styles.subheader
}, styles.root];
}
})({
display: 'flex',
alignItems: 'center',
padding: 16
});
const CardHeaderAvatar = styled('div', {
name: 'MuiCardHeader',
slot: 'Avatar'
})({
display: 'flex',
flex: '0 0 auto',
marginRight: 16
});
const CardHeaderAction = styled('div', {
name: 'MuiCardHeader',
slot: 'Action'
})({
flex: '0 0 auto',
alignSelf: 'flex-start',
marginTop: -4,
marginRight: -8,
marginBottom: -4
});
const CardHeaderContent = styled('div', {
name: 'MuiCardHeader',
slot: 'Content'
})({
flex: '1 1 auto',
[`.${typographyClasses.root}:where(& .${cardHeaderClasses.title})`]: {
display: 'block'
},
[`.${typographyClasses.root}:where(& .${cardHeaderClasses.subheader})`]: {
display: 'block'
}
});
const CardHeader = /*#__PURE__*/React.forwardRef(function CardHeader(inProps, ref) {
const props = useDefaultProps({
props: inProps,
name: 'MuiCardHeader'
});
const {
action,
avatar,
component = 'div',
disableTypography = false,
subheader: subheaderProp,
subheaderTypographyProps,
title: titleProp,
titleTypographyProps,
slots = {},
slotProps = {},
...other
} = props;
const ownerState = {
...props,
component,
disableTypography
};
const classes = useUtilityClasses(ownerState);
const externalForwardedProps = {
slots,
slotProps: {
title: titleTypographyProps,
subheader: subheaderTypographyProps,
...slotProps
}
};
let title = titleProp;
const [TitleSlot, titleSlotProps] = useSlot('title', {
className: classes.title,
elementType: Typography,
externalForwardedProps,
ownerState,
additionalProps: {
variant: avatar ? 'body2' : 'h5',
component: 'span'
}
});
if (title != null && title.type !== Typography && !disableTypography) {
title = /*#__PURE__*/_jsx(TitleSlot, {
...titleSlotProps,
children: title
});
}
let subheader = subheaderProp;
const [SubheaderSlot, subheaderSlotProps] = useSlot('subheader', {
className: classes.subheader,
elementType: Typography,
externalForwardedProps,
ownerState,
additionalProps: {
variant: avatar ? 'body2' : 'body1',
color: 'textSecondary',
component: 'span'
}
});
if (subheader != null && subheader.type !== Typography && !disableTypography) {
subheader = /*#__PURE__*/_jsx(SubheaderSlot, {
...subheaderSlotProps,
children: subheader
});
}
const [RootSlot, rootSlotProps] = useSlot('root', {
ref,
className: classes.root,
elementType: CardHeaderRoot,
externalForwardedProps: {
...externalForwardedProps,
...other,
component
},
ownerState
});
const [AvatarSlot, avatarSlotProps] = useSlot('avatar', {
className: classes.avatar,
elementType: CardHeaderAvatar,
externalForwardedProps,
ownerState
});
const [ContentSlot, contentSlotProps] = useSlot('content', {
className: classes.content,
elementType: CardHeaderContent,
externalForwardedProps,
ownerState
});
const [ActionSlot, actionSlotProps] = useSlot('action', {
className: classes.action,
elementType: CardHeaderAction,
externalForwardedProps,
ownerState
});
return /*#__PURE__*/_jsxs(RootSlot, {
...rootSlotProps,
children: [avatar && /*#__PURE__*/_jsx(AvatarSlot, {
...avatarSlotProps,
children: avatar
}), /*#__PURE__*/_jsxs(ContentSlot, {
...contentSlotProps,
children: [title, subheader]
}), action && /*#__PURE__*/_jsx(ActionSlot, {
...actionSlotProps,
children: action
})]
});
});
process.env.NODE_ENV !== "production" ? CardHeader.propTypes /* remove-proptypes */ = {
// ┌────────────────────────────── Warning ──────────────────────────────┐
// │ These PropTypes are generated from the TypeScript type definitions. │
// │ To update them, edit the d.ts file and run `pnpm proptypes`. │
// └─────────────────────────────────────────────────────────────────────┘
/**
* The action to display in the card header.
*/
action: PropTypes.node,
/**
* The Avatar element to display.
*/
avatar: PropTypes.node,
/**
* @ignore
*/
children: PropTypes.node,
/**
* Override or extend the styles applied to the component.
*/
classes: PropTypes.object,
/**
* The component used for the root node.
* Either a string to use a HTML element or a component.
*/
component: PropTypes.elementType,
/**
* If `true`, `subheader` and `title` won't be wrapped by a Typography component.
* This can be useful to render an alternative Typography variant by wrapping
* the `title` text, and optional `subheader` text
* with the Typography component.
* @default false
*/
disableTypography: PropTypes.bool,
/**
* The props used for each slot inside.
* @default {}
*/
slotProps: PropTypes.shape({
action: PropTypes.oneOfType([PropTypes.func, PropTypes.object]),
avatar: PropTypes.oneOfType([PropTypes.func, PropTypes.object]),
content: PropTypes.oneOfType([PropTypes.func, PropTypes.object]),
root: PropTypes.oneOfType([PropTypes.func, PropTypes.object]),
subheader: PropTypes.oneOfType([PropTypes.func, PropTypes.object]),
title: PropTypes.oneOfType([PropTypes.func, PropTypes.object])
}),
/**
* The components used for each slot inside.
* @default {}
*/
slots: PropTypes.shape({
action: PropTypes.elementType,
avatar: PropTypes.elementType,
content: PropTypes.elementType,
root: PropTypes.elementType,
subheader: PropTypes.elementType,
title: PropTypes.elementType
}),
/**
* The content of the component.
*/
subheader: PropTypes.node,
/**
* These props will be forwarded to the subheader
* (as long as disableTypography is not `true`).
* @deprecated Use `slotProps.subheader` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
*/
subheaderTypographyProps: PropTypes.object,
/**
* The system prop that allows defining system overrides as well as additional CSS styles.
*/
sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),
/**
* The content of the component.
*/
title: PropTypes.node,
/**
* These props will be forwarded to the title
* (as long as disableTypography is not `true`).
* @deprecated Use `slotProps.title` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
*/
titleTypographyProps: PropTypes.object
} : void 0;
export default CardHeader;

View file

@ -0,0 +1,18 @@
export interface CardHeaderClasses {
/** Styles applied to the root element. */
root: string;
/** Styles applied to the avatar element. */
avatar: string;
/** Styles applied to the action element. */
action: string;
/** Styles applied to the content wrapper element. */
content: string;
/** Styles applied to the title Typography element. */
title: string;
/** Styles applied to the subheader Typography element. */
subheader: string;
}
export type CardHeaderClassKey = keyof CardHeaderClasses;
export declare function getCardHeaderUtilityClass(slot: string): string;
declare const cardHeaderClasses: CardHeaderClasses;
export default cardHeaderClasses;

View file

@ -0,0 +1,7 @@
import generateUtilityClasses from '@mui/utils/generateUtilityClasses';
import generateUtilityClass from '@mui/utils/generateUtilityClass';
export function getCardHeaderUtilityClass(slot) {
return generateUtilityClass('MuiCardHeader', slot);
}
const cardHeaderClasses = generateUtilityClasses('MuiCardHeader', ['root', 'avatar', 'action', 'content', 'title', 'subheader']);
export default cardHeaderClasses;

4
node_modules/@mui/material/esm/CardHeader/index.d.ts generated vendored Normal file
View file

@ -0,0 +1,4 @@
export { default } from "./CardHeader.js";
export * from "./CardHeader.js";
export { default as cardHeaderClasses } from "./cardHeaderClasses.js";
export * from "./cardHeaderClasses.js";

3
node_modules/@mui/material/esm/CardHeader/index.js generated vendored Normal file
View file

@ -0,0 +1,3 @@
export { default } from "./CardHeader.js";
export { default as cardHeaderClasses } from "./cardHeaderClasses.js";
export * from "./cardHeaderClasses.js";