paradiego
This commit is contained in:
109
node_modules/@mui/material/Grid2/Grid2.d.ts
generated
vendored
Normal file
109
node_modules/@mui/material/Grid2/Grid2.d.ts
generated
vendored
Normal file
@@ -0,0 +1,109 @@
|
||||
import { SxProps, SystemProps } from '@mui/system';
|
||||
import { OverridableComponent, OverrideProps } from '@mui/types';
|
||||
import { Theme, Breakpoint } from '../styles';
|
||||
export type Grid2Slot = 'root';
|
||||
type ResponsiveStyleValue<T> = T | Array<T | null> | {
|
||||
[key in Breakpoint]?: T | null;
|
||||
};
|
||||
export type GridDirection = 'row' | 'row-reverse' | 'column' | 'column-reverse';
|
||||
export type GridSpacing = number | string;
|
||||
export type GridWrap = 'nowrap' | 'wrap' | 'wrap-reverse';
|
||||
export type GridSize = 'auto' | 'grow' | number | false;
|
||||
export type GridOffset = 'auto' | number;
|
||||
export interface GridBaseProps {
|
||||
/**
|
||||
* The content of the component.
|
||||
*/
|
||||
children?: React.ReactNode;
|
||||
/**
|
||||
* The number of columns.
|
||||
* @default 12
|
||||
*/
|
||||
columns?: ResponsiveStyleValue<number>;
|
||||
/**
|
||||
* Defines the horizontal space between the type `item` components.
|
||||
* It overrides the value of the `spacing` prop.
|
||||
*/
|
||||
columnSpacing?: ResponsiveStyleValue<GridSpacing>;
|
||||
/**
|
||||
* If `true`, the component will have the flex *container* behavior.
|
||||
* You should be wrapping *items* with a *container*.
|
||||
* @default false
|
||||
*/
|
||||
container?: boolean;
|
||||
/**
|
||||
* Defines the `flex-direction` style property.
|
||||
* It is applied for all screen sizes.
|
||||
* @default 'row'
|
||||
*/
|
||||
direction?: ResponsiveStyleValue<GridDirection>;
|
||||
/**
|
||||
* Defines the offset value for the type `item` components.
|
||||
*/
|
||||
offset?: ResponsiveStyleValue<GridOffset>;
|
||||
/**
|
||||
* @internal
|
||||
* The level of the grid starts from `0`
|
||||
* and increases when the grid nests inside another grid regardless of container or item.
|
||||
*
|
||||
* ```js
|
||||
* <Grid> // level 0
|
||||
* <Grid> // level 1
|
||||
* <Grid> // level 2
|
||||
* <Grid> // level 1
|
||||
* ```
|
||||
*
|
||||
* Only consecutive grid is considered nesting.
|
||||
* A grid container will start at `0` if there are non-Grid element above it.
|
||||
*
|
||||
* ```js
|
||||
* <Grid> // level 0
|
||||
* <div>
|
||||
* <Grid> // level 0
|
||||
* <Grid> // level 1
|
||||
* ```
|
||||
*/
|
||||
unstable_level?: number;
|
||||
/**
|
||||
* Defines the vertical space between the type `item` components.
|
||||
* It overrides the value of the `spacing` prop.
|
||||
*/
|
||||
rowSpacing?: ResponsiveStyleValue<GridSpacing>;
|
||||
/**
|
||||
* Defines the size of the the type `item` components.
|
||||
*/
|
||||
size?: ResponsiveStyleValue<GridSize>;
|
||||
/**
|
||||
* Defines the space between the type `item` components.
|
||||
* It can only be used on a type `container` component.
|
||||
* @default 0
|
||||
*/
|
||||
spacing?: ResponsiveStyleValue<GridSpacing> | undefined;
|
||||
/**
|
||||
* Defines the `flex-wrap` style property.
|
||||
* It's applied for all screen sizes.
|
||||
* @default 'wrap'
|
||||
*/
|
||||
wrap?: GridWrap;
|
||||
}
|
||||
export interface Grid2TypeMap<P = {}, D extends React.ElementType = 'div'> {
|
||||
props: P & GridBaseProps & {
|
||||
sx?: SxProps<Theme>;
|
||||
} & SystemProps<Theme>;
|
||||
defaultComponent: D;
|
||||
}
|
||||
export type Grid2Props<D extends React.ElementType = Grid2TypeMap['defaultComponent'], P = {
|
||||
component?: React.ElementType;
|
||||
}> = OverrideProps<Grid2TypeMap<P, D>, D>;
|
||||
/**
|
||||
*
|
||||
* Demos:
|
||||
*
|
||||
* - [Grid version 2](https://mui.com/material-ui/react-grid2/)
|
||||
*
|
||||
* API:
|
||||
*
|
||||
* - [Grid2 API](https://mui.com/material-ui/api/grid-2/)
|
||||
*/
|
||||
declare const Grid2: OverridableComponent<Grid2TypeMap>;
|
||||
export default Grid2;
|
||||
112
node_modules/@mui/material/Grid2/Grid2.js
generated
vendored
Normal file
112
node_modules/@mui/material/Grid2/Grid2.js
generated
vendored
Normal file
@@ -0,0 +1,112 @@
|
||||
'use client';
|
||||
|
||||
import PropTypes from 'prop-types';
|
||||
import { createGrid as createGrid2 } from '@mui/system/Grid';
|
||||
import { styled, useThemeProps } from "../styles/index.js";
|
||||
/**
|
||||
*
|
||||
* Demos:
|
||||
*
|
||||
* - [Grid version 2](https://mui.com/material-ui/react-grid2/)
|
||||
*
|
||||
* API:
|
||||
*
|
||||
* - [Grid2 API](https://mui.com/material-ui/api/grid-2/)
|
||||
*/
|
||||
const Grid2 = createGrid2({
|
||||
createStyledComponent: styled('div', {
|
||||
name: 'MuiGrid2',
|
||||
slot: 'Root',
|
||||
overridesResolver: (props, styles) => styles.root
|
||||
}),
|
||||
componentName: 'MuiGrid2',
|
||||
useThemeProps: inProps => useThemeProps({
|
||||
props: inProps,
|
||||
name: 'MuiGrid2'
|
||||
})
|
||||
});
|
||||
process.env.NODE_ENV !== "production" ? Grid2.propTypes /* remove-proptypes */ = {
|
||||
// ┌────────────────────────────── Warning ──────────────────────────────┐
|
||||
// │ These PropTypes are generated from the TypeScript type definitions. │
|
||||
// │ To update them, edit the TypeScript types and run `pnpm proptypes`. │
|
||||
// └─────────────────────────────────────────────────────────────────────┘
|
||||
/**
|
||||
* The content of the component.
|
||||
*/
|
||||
children: PropTypes.node,
|
||||
/**
|
||||
* The number of columns.
|
||||
* @default 12
|
||||
*/
|
||||
columns: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.arrayOf(PropTypes.number), PropTypes.number, PropTypes.object]),
|
||||
/**
|
||||
* Defines the horizontal space between the type `item` components.
|
||||
* It overrides the value of the `spacing` prop.
|
||||
*/
|
||||
columnSpacing: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.number, PropTypes.string])), PropTypes.number, PropTypes.object, PropTypes.string]),
|
||||
/**
|
||||
* If `true`, the component will have the flex *container* behavior.
|
||||
* You should be wrapping *items* with a *container*.
|
||||
* @default false
|
||||
*/
|
||||
container: PropTypes.bool,
|
||||
/**
|
||||
* Defines the `flex-direction` style property.
|
||||
* It is applied for all screen sizes.
|
||||
* @default 'row'
|
||||
*/
|
||||
direction: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['column-reverse', 'column', 'row-reverse', 'row']), PropTypes.arrayOf(PropTypes.oneOf(['column-reverse', 'column', 'row-reverse', 'row'])), PropTypes.object]),
|
||||
/**
|
||||
* Defines the offset value for the type `item` components.
|
||||
*/
|
||||
offset: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.string, PropTypes.number, PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.string, PropTypes.number])), PropTypes.object]),
|
||||
/**
|
||||
* Defines the vertical space between the type `item` components.
|
||||
* It overrides the value of the `spacing` prop.
|
||||
*/
|
||||
rowSpacing: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.number, PropTypes.string])), PropTypes.number, PropTypes.object, PropTypes.string]),
|
||||
/**
|
||||
* Defines the size of the the type `item` components.
|
||||
*/
|
||||
size: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.string, PropTypes.bool, PropTypes.number, PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.string, PropTypes.bool, PropTypes.number])), PropTypes.object]),
|
||||
/**
|
||||
* Defines the space between the type `item` components.
|
||||
* It can only be used on a type `container` component.
|
||||
* @default 0
|
||||
*/
|
||||
spacing: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.number, PropTypes.string])), PropTypes.number, PropTypes.object, PropTypes.string]),
|
||||
/**
|
||||
* @ignore
|
||||
*/
|
||||
sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),
|
||||
/**
|
||||
* @internal
|
||||
* The level of the grid starts from `0`
|
||||
* and increases when the grid nests inside another grid regardless of container or item.
|
||||
*
|
||||
* ```js
|
||||
* <Grid> // level 0
|
||||
* <Grid> // level 1
|
||||
* <Grid> // level 2
|
||||
* <Grid> // level 1
|
||||
* ```
|
||||
*
|
||||
* Only consecutive grid is considered nesting.
|
||||
* A grid container will start at `0` if there are non-Grid element above it.
|
||||
*
|
||||
* ```js
|
||||
* <Grid> // level 0
|
||||
* <div>
|
||||
* <Grid> // level 0
|
||||
* <Grid> // level 1
|
||||
* ```
|
||||
*/
|
||||
unstable_level: PropTypes.number,
|
||||
/**
|
||||
* Defines the `flex-wrap` style property.
|
||||
* It's applied for all screen sizes.
|
||||
* @default 'wrap'
|
||||
*/
|
||||
wrap: PropTypes.oneOf(['nowrap', 'wrap-reverse', 'wrap'])
|
||||
} : void 0;
|
||||
export default Grid2;
|
||||
5
node_modules/@mui/material/Grid2/grid2Classes.d.ts
generated
vendored
Normal file
5
node_modules/@mui/material/Grid2/grid2Classes.d.ts
generated
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
import { GridClasses } from '@mui/system/Grid';
|
||||
export type Grid2ClassKey = keyof GridClasses;
|
||||
export declare function getGrid2UtilityClass(slot: string): string;
|
||||
declare const grid2Classes: GridClasses;
|
||||
export default grid2Classes;
|
||||
19
node_modules/@mui/material/Grid2/grid2Classes.js
generated
vendored
Normal file
19
node_modules/@mui/material/Grid2/grid2Classes.js
generated
vendored
Normal file
@@ -0,0 +1,19 @@
|
||||
import generateUtilityClasses from '@mui/utils/generateUtilityClasses';
|
||||
import generateUtilityClass from '@mui/utils/generateUtilityClass';
|
||||
export function getGrid2UtilityClass(slot) {
|
||||
return generateUtilityClass('MuiGrid2', slot);
|
||||
}
|
||||
const SPACINGS = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10];
|
||||
const DIRECTIONS = ['column-reverse', 'column', 'row-reverse', 'row'];
|
||||
const WRAPS = ['nowrap', 'wrap-reverse', 'wrap'];
|
||||
const GRID_SIZES = ['auto', true, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12];
|
||||
const grid2Classes = generateUtilityClasses('MuiGrid2', ['root', 'container', 'item', 'zeroMinWidth',
|
||||
// spacings
|
||||
...SPACINGS.map(spacing => `spacing-xs-${spacing}`),
|
||||
// direction values
|
||||
...DIRECTIONS.map(direction => `direction-xs-${direction}`),
|
||||
// wrap values
|
||||
...WRAPS.map(wrap => `wrap-xs-${wrap}`),
|
||||
// grid sizes for all breakpoints
|
||||
...GRID_SIZES.map(size => `grid-xs-${size}`), ...GRID_SIZES.map(size => `grid-sm-${size}`), ...GRID_SIZES.map(size => `grid-md-${size}`), ...GRID_SIZES.map(size => `grid-lg-${size}`), ...GRID_SIZES.map(size => `grid-xl-${size}`)]);
|
||||
export default grid2Classes;
|
||||
4
node_modules/@mui/material/Grid2/index.d.ts
generated
vendored
Normal file
4
node_modules/@mui/material/Grid2/index.d.ts
generated
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
export { default } from './Grid2';
|
||||
export * from './Grid2';
|
||||
export { default as grid2Classes } from './grid2Classes';
|
||||
export * from './grid2Classes';
|
||||
4
node_modules/@mui/material/Grid2/index.js
generated
vendored
Normal file
4
node_modules/@mui/material/Grid2/index.js
generated
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
export { default } from "./Grid2.js";
|
||||
export * from "./Grid2.js";
|
||||
export { default as grid2Classes } from "./grid2Classes.js";
|
||||
export * from "./grid2Classes.js";
|
||||
6
node_modules/@mui/material/Grid2/package.json
generated
vendored
Normal file
6
node_modules/@mui/material/Grid2/package.json
generated
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"sideEffects": false,
|
||||
"module": "./index.js",
|
||||
"main": "../node/Grid2/index.js",
|
||||
"types": "./index.d.ts"
|
||||
}
|
||||
Reference in New Issue
Block a user