Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F98167505
createBox.js
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Fri, Jan 10, 15:11
Size
1 KB
Mime Type
text/x-java
Expires
Sun, Jan 12, 15:11 (2 d)
Engine
blob
Format
Raw Data
Handle
23515084
Attached To
rOACCT Open Access Compliance Check Tool (OACCT)
createBox.js
View Options
import
_extends
from
"@babel/runtime/helpers/esm/extends"
;
import
_objectWithoutPropertiesLoose
from
"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose"
;
const
_excluded
=
[
"className"
,
"component"
];
import
*
as
React
from
'react'
;
import
clsx
from
'clsx'
;
import
styled
from
'@mui/styled-engine'
;
import
styleFunctionSx
,
{
extendSxProp
}
from
'./styleFunctionSx'
;
import
useTheme
from
'./useTheme'
;
import
{
jsx
as
_jsx
}
from
"react/jsx-runtime"
;
export
default
function
createBox
(
options
=
{})
{
const
{
defaultTheme
,
defaultClassName
=
'MuiBox-root'
,
generateClassName
}
=
options
;
const
BoxRoot
=
styled
(
'div'
,
{
shouldForwardProp
:
prop
=>
prop
!==
'theme'
&&
prop
!==
'sx'
&&
prop
!==
'as'
})(
styleFunctionSx
);
const
Box
=
/*#__PURE__*/
React
.
forwardRef
(
function
Box
(
inProps
,
ref
)
{
const
theme
=
useTheme
(
defaultTheme
);
const
_extendSxProp
=
extendSxProp
(
inProps
),
{
className
,
component
=
'div'
}
=
_extendSxProp
,
other
=
_objectWithoutPropertiesLoose
(
_extendSxProp
,
_excluded
);
return
/*#__PURE__*/
_jsx
(
BoxRoot
,
_extends
({
as
:
component
,
ref
:
ref
,
className
:
clsx
(
className
,
generateClassName
?
generateClassName
(
defaultClassName
)
:
defaultClassName
),
theme
:
theme
},
other
));
});
return
Box
;
}
Event Timeline
Log In to Comment