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,41 @@
import * as React from 'react';
import { DistributiveOmit } from '@mui/types';
import { StyledComponentProps } from "../styles/index.js";
/**
* A component whose root component can be controlled via a `component` prop.
*
* Adjusts valid props based on the type of `component`.
*/
export interface OverridableComponent<TypeMap extends OverridableTypeMap> {
<RootComponent extends React.ElementType>(props: {
/**
* The component used for the root node.
* Either a string to use a HTML element or a component.
*/
component: RootComponent;
} & OverrideProps<TypeMap, RootComponent>): React.JSX.Element | null;
(props: DefaultComponentProps<TypeMap>): React.JSX.Element | null;
}
/**
* Props of the component if `component={Component}` is used.
*/
export type OverrideProps<TypeMap extends OverridableTypeMap, RootComponent extends React.ElementType> = (BaseProps<TypeMap> & DistributiveOmit<React.ComponentPropsWithRef<RootComponent>, keyof BaseProps<TypeMap>>);
/**
* Props if `component={Component}` is NOT used.
*/
export type DefaultComponentProps<TypeMap extends OverridableTypeMap> = BaseProps<TypeMap> & DistributiveOmit<React.ComponentPropsWithRef<TypeMap['defaultComponent']>, keyof BaseProps<TypeMap>>;
/**
* Props defined on the component (+ common material-ui props).
*/
export type BaseProps<TypeMap extends OverridableTypeMap> = TypeMap['props'] & CommonProps;
/**
* Props that are valid for material-ui components.
*/
export interface CommonProps extends StyledComponentProps<never> {
className?: string;
style?: React.CSSProperties;
}
export interface OverridableTypeMap {
props: {};
defaultComponent: React.ElementType;
}

View file

@ -0,0 +1,5 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});