@wordpress/components
Version:
UI components for WordPress.
49 lines (44 loc) • 866 B
JavaScript
;
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = void 0;
var _utils = require("../utils");
var _hook = require("./hook");
/**
* Internal dependencies
*/
/**
* `HStack` (Horizontal Stack) arranges child elements in a horizontal line.
*
* `HStack` can render anything inside.
*
* @example
* ```jsx
* import { HStack, Text, View } from `@wordpress/components/ui`;
*
* function Example() {
* return (
* <HStack>
* <View>
* <Text>Code</Text>
* </View>
* <View>
* <Text>is</Text>
* </View>
* <View>
* <Text>Poetry</Text>
* </View>
* </HStack>
* );
* }
* ```
*/
const HStack = (0, _utils.createComponent)({
as: 'div',
useHook: _hook.useHStack,
name: 'HStack'
});
var _default = HStack;
exports.default = _default;
//# sourceMappingURL=component.js.map