UNPKG

@wordpress/components

Version:
40 lines (34 loc) 765 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.default = void 0; var _utils = require("../utils"); var _hook = require("./hook"); /** * Internal dependencies */ /** * `Surface` is a core component that renders a primary background color. * * In the example below, notice how the `Surface` renders in white (or dark gray if in dark mode). * * ```jsx * import { Surface, Text } from `@wordpress/components/ui`; * * function Example() { * return ( * <Surface> * <Text>Code is Poetry</Text> * </Surface> * ); * } * ``` */ var _default = (0, _utils.createComponent)({ as: 'div', useHook: _hook.useSurface, name: 'Surface' }); exports.default = _default; //# sourceMappingURL=component.js.map