@wordpress/components
Version:
UI components for WordPress.
8 lines (7 loc) • 1.31 kB
Source Map (JSON)
{
"version": 3,
"sources": ["../../src/text/component.tsx"],
"sourcesContent": ["/**\n * Internal dependencies\n */\n\nimport { contextConnect } from '../context';\nimport { View } from '../view';\nimport useText from './hook';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\n/**\n * @param props\n * @param forwardedRef\n */\nfunction UnconnectedText(props, forwardedRef) {\n const textProps = useText(props);\n return /*#__PURE__*/_jsx(View, {\n as: \"span\",\n ...textProps,\n ref: forwardedRef\n });\n}\n\n/**\n * `Text` is a core component that renders text in the library, using the\n * library's typography system.\n *\n * `Text` can be used to render any text-content, like an HTML `p` or `span`.\n *\n * @example\n *\n * ```jsx\n * import { __experimentalText as Text } from `@wordpress/components`;\n *\n * function Example() {\n * \treturn <Text>Code is Poetry</Text>;\n * }\n * ```\n */\nexport const Text = contextConnect(UnconnectedText, 'Text');\nexport default Text;"],
"mappings": ";AAIA,SAAS,sBAAsB;AAC/B,SAAS,YAAY;AACrB,OAAO,aAAa;AACpB,SAAS,OAAO,YAAY;AAK5B,SAAS,gBAAgB,OAAO,cAAc;AAC5C,QAAM,YAAY,QAAQ,KAAK;AAC/B,SAAoB,qBAAK,MAAM;AAAA,IAC7B,IAAI;AAAA,IACJ,GAAG;AAAA,IACH,KAAK;AAAA,EACP,CAAC;AACH;AAkBO,IAAM,OAAO,eAAe,iBAAiB,MAAM;AAC1D,IAAO,oBAAQ;",
"names": []
}