UNPKG

@kubit-ui-web/react-components

Version:

Kubit React Components is a customizable, accessible library of React web components, designed to enhance your application's user experience

23 lines 1.79 kB
"use strict"; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; Object.defineProperty(exports, "__esModule", { value: true }); exports.LineSeparator = void 0; const jsx_runtime_1 = require("react/jsx-runtime"); const react_1 = __importDefault(require("react")); const useStyles_1 = require("../../hooks/useStyles/useStyles"); const errorBoundary_1 = require("../../provider/errorBoundary/errorBoundary"); const fallbackComponent_1 = require("../../provider/errorBoundary/fallbackComponent"); const lineSeparatorStandAlone_1 = require("./lineSeparatorStandAlone"); const LINE_SEPARATOR_STYLES = 'LINE_SEPARATOR_STYLES'; const LineSeparatorComponent = react_1.default.forwardRef(({ labelVariant, lineVariant, ctv, extraCt, ...props }, ref) => { const labelStyles = (0, useStyles_1.useStyles)(LINE_SEPARATOR_STYLES, labelVariant, ctv); const lineStyles = (0, useStyles_1.useStyles)(LINE_SEPARATOR_STYLES, lineVariant, extraCt); return ((0, jsx_runtime_1.jsx)(lineSeparatorStandAlone_1.LineSeparatorStandAlone, { ...props, ref: ref, labelStyles: labelStyles, lineStyles: lineStyles })); }); LineSeparatorComponent.displayName = 'LineSeparatorComponent'; const LineSeparatorBoundary = (props, ref) => ((0, jsx_runtime_1.jsx)(errorBoundary_1.ErrorBoundary, { fallBackComponent: (0, jsx_runtime_1.jsx)(fallbackComponent_1.FallbackComponent, { children: (0, jsx_runtime_1.jsx)(lineSeparatorStandAlone_1.LineSeparatorStandAlone, { ...props, ref: ref }) }), children: (0, jsx_runtime_1.jsx)(LineSeparatorComponent, { ...props, ref: ref }) })); const LineSeparator = react_1.default.forwardRef(LineSeparatorBoundary); exports.LineSeparator = LineSeparator; //# sourceMappingURL=lineSeparator.js.map