UNPKG

@audira/carbon-react-native

Version:

Build React Native apps with component and shared patterns using Carbon

23 lines (22 loc) 720 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.VariantContextProvider = VariantContextProvider; var _react = require("react"); var _index = require("../../_internal/contexts/index.js"); var _variantContext = require("./_variant-context.js"); var _jsxRuntime = require("react/jsx-runtime"); function VariantContextProvider({ color, children }) { const globalConfigContext = (0, _react.useContext)(_index.GlobalConfigContext); return /*#__PURE__*/(0, _jsxRuntime.jsx)(_variantContext.VariantContext.Provider, { value: { color: color ?? globalConfigContext.notificationColor }, children: children }); } //# sourceMappingURL=_VariantContextProvider.js.map