UNPKG

@cerberus-design/react

Version:

The Cerberus Design React component library.

24 lines (19 loc) 1.02 kB
'use strict'; Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); const jsxRuntime = require('react/jsx-runtime'); const show = require('../show/show.cjs'); const parts = require('./parts.cjs'); const decrementTrigger = require('./decrement-trigger.cjs'); const incrementTrigger = require('./increment-trigger.cjs'); function NumberInput(props) { const { scrubber, ...rootProps } = props; return /* @__PURE__ */ jsxRuntime.jsxs(parts.NumberInputParts.Root, { ...rootProps, children: [ /* @__PURE__ */ jsxRuntime.jsx(show.Show, { when: scrubber, children: /* @__PURE__ */ jsxRuntime.jsx(parts.NumberInputParts.Scrubber, {}) }), /* @__PURE__ */ jsxRuntime.jsxs(parts.NumberInputParts.Control, { children: [ /* @__PURE__ */ jsxRuntime.jsx(parts.NumberInputParts.Input, {}), /* @__PURE__ */ jsxRuntime.jsx(incrementTrigger.IncrementTrigger, {}), /* @__PURE__ */ jsxRuntime.jsx(decrementTrigger.DecrementTrigger, {}) ] }) ] }); } exports.NumberInput = NumberInput;