@fluentui/react-northstar
Version:
A themable React component library.
38 lines (36 loc) • 1.06 kB
JavaScript
import { compose } from '@fluentui/react-bindings';
import * as PropTypes from 'prop-types';
import { commonPropTypes } from '../../utils';
import { Box } from '../Box/Box';
export var skeletonLineClassName = 'ui-skeleton__line';
/**
* A SkeletonLine represents a text line that will be loaded
*/
export var SkeletonLine = /*#__PURE__*/function () {
var SkeletonLine = compose(Box, {
className: skeletonLineClassName,
displayName: 'SkeletonLine',
overrideStyles: true,
shorthandConfig: {},
handledProps: ['width', 'height'],
mapPropsToStylesProps: function mapPropsToStylesProps(_ref) {
var width = _ref.width,
height = _ref.height;
return {
width: width,
height: height
};
}
});
SkeletonLine.propTypes = Object.assign({}, commonPropTypes.createCommon(), {
width: PropTypes.string,
height: PropTypes.string
});
SkeletonLine.defaultProps = {
as: 'span',
width: '100%',
height: '1rem'
};
return SkeletonLine;
}();
//# sourceMappingURL=SkeletonLine.js.map