[react] feat: Added docs for components/Ux
This commit is contained in:
parent
d8705ecc75
commit
5e5d3a0270
4 changed files with 49 additions and 7 deletions
|
@ -1,8 +1,16 @@
|
|||
import React from 'react'
|
||||
import { CircleIcon } from '@freesewing/react/components/Icon'
|
||||
|
||||
/**
|
||||
* A component to display the UX (control) setting
|
||||
*
|
||||
* @component
|
||||
* @param {object} props - All component props
|
||||
* @param {number} [props.ux = 0] - The value of the ux/control setting
|
||||
* @returns {JSX.Element}
|
||||
*/
|
||||
export const Ux = ({ ux = 0 }) => (
|
||||
<div className="flex flex-row">
|
||||
<div className="tw:flex tw:flex-row">
|
||||
{[0, 1, 2, 3, 4].map((i) => (
|
||||
<CircleIcon
|
||||
key={i}
|
||||
|
@ -14,8 +22,14 @@ export const Ux = ({ ux = 0 }) => (
|
|||
</div>
|
||||
)
|
||||
|
||||
/**
|
||||
* A component to display a mini version of the UX (control) setting
|
||||
*
|
||||
* @component
|
||||
* @param {object} props - All component props
|
||||
* @param {number} [props.ux = 0] - The value of the ux/control setting
|
||||
* @returns {JSX.Element}
|
||||
*/
|
||||
export const UxMini = ({ ux = 0 }) => (
|
||||
<div className="flex flex-row">
|
||||
<CircleIcon className={`tw:w-6 tw:h-6 tw:stroke-secondary tw:fill-secondary/20`} label={ux} />
|
||||
</div>
|
||||
<CircleIcon className={`tw:w-6 tw:h-6 tw:stroke-secondary tw:fill-secondary/20`} label={ux} />
|
||||
)
|
||||
|
|
|
@ -40,3 +40,4 @@ jsdoc -c jsdoc.json components/Tab/* > ../../sites/dev/prebuild/jsdoc/react/comp
|
|||
jsdoc -c jsdoc.json components/Table/* > ../../sites/dev/prebuild/jsdoc/react/components/table.json
|
||||
jsdoc -c jsdoc.json components/Time/* > ../../sites/dev/prebuild/jsdoc/react/components/time.json
|
||||
jsdoc -c jsdoc.json components/Uuid/* > ../../sites/dev/prebuild/jsdoc/react/components/uuid.json
|
||||
jsdoc -c jsdoc.json components/Ux/* > ../../sites/dev/prebuild/jsdoc/react/components/ux.json
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue