UNPKG

@porsche-design-system/components-react

Version:

Porsche Design System is a component library designed to help developers create the best experience for software or services distributed by Dr. Ing. h.c. F. Porsche AG.

21 lines (18 loc) 995 B
import { jsxs, Fragment, jsx } from 'react/jsx-runtime'; import { splitChildren } from '../../splitChildren.mjs'; import { Component } from 'react'; import { minifyCss } from '../../minifyCss.mjs'; import { getButtonGroupCss as getComponentCss$1n } from '../../../../../../components/dist/styles/esm/styles-entry.mjs'; /** * @slot {"name": "", "description": "Default slot for the buttons to group." } * @deprecated since v3.32.0, will be removed with next major release. Use simple styles instead. */ class DSRButtonGroup extends Component { host; render() { splitChildren(this.props.children); const style = minifyCss(getComponentCss$1n(this.props.direction)); return (jsxs(Fragment, { children: [jsxs("template", { shadowroot: "open", shadowrootmode: "open", children: [jsx("style", { dangerouslySetInnerHTML: { __html: style } }), jsx("div", { role: "group", children: jsx("slot", {}) })] }), this.props.children] })); } } export { DSRButtonGroup };