# elementor/3.5.4/packages/elementor-ui/components/ui/text.js

Elementor Website Builder – more than just a page builder, version 3.5.4. 22 lines.

- Page: https://pluginprobe.com/plugins/elementor/3.5.4/code/packages/elementor-ui/components/ui/text.js
- Raw: https://pluginprobe.com/plugins/elementor/3.5.4/raw/packages/elementor-ui/components/ui/text.js
- Modified: 2021-11-17T08:27:36+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/elementor/3.5.4/code/packages/elementor-ui/components/ui/text.js#L10-L20`.

```javascript
import styled from 'styled-components';
import { getStyle } from 'e-utils';
import styles from 'e-styles/text';

const SharedText = styled.p.attrs( ( props ) => ( { as: props.tag } ) )`${ ( props ) => getStyle( styles, props, 'shared' ) }`;

const Text = styled( SharedText )`${ ( props ) => getStyle( styles, props, 'unique' ) }`;

Text.propTypes = {
	className: PropTypes.string,
	children: PropTypes.any,
	variant: PropTypes.oneOf( [ 'xxs', 'xs', 'sm', 'md', 'lg', 'xl' ] ),
	tag: PropTypes.string,
};

Text.defaultProps = {
	className: '',
	tag: 'p',
};

export default Text;

```
