@vitus-labs/rocketstories 1.3.1 → 1.3.2-alpha.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- {"version":3,"file":"index2.d.ts","names":[],"sources":["../src/constants/controls.ts","../src/types.ts","../src/stories/base/renderList.tsx","../src/stories/base/renderMain.tsx","../src/stories/base/renderRender.tsx","../src/stories/rocketstories/renderDimension/index.tsx","../src/stories/rocketstories/renderList.tsx","../src/stories/rocketstories/renderMain.tsx","../src/stories/rocketstories/renderRender.tsx","../src/rocketstories.tsx","../src/init.ts"],"mappings":";;;;;cAAa,aAAA;AAAA,KAmBD,eAAA,WAA0B,aAAA;;;KCJ1B,IAAA,GAAO,MAAA;AAAA,KAEP,YAAA,uBACV,kBAAA,SAA2B,aAAA,iBACvB,MAAA,GACA,kBAAA;AAAA,KAEM,cAAA,WAAyB,EAAA,CAAG,CAAA,IACtC,OAAA;EACE,IAAA,EAAM,MAAA;EACN,QAAA,EAAU,MAAA;EACV,UAAA,EAAY,MAAA;AAAA;AAAA,KAGJ,WAAA,WAAsB,IAAA,oBAC9B,aAAA,CAAc,CAAA,IACd,yBAAA,CAA0B,CAAA;AAAA,KAElB,UAAA,GAAa,mBAAA;EACvB,qBAAA;EACA,mBAAA;EACA,eAAA;EACA,WAAA;AAAA;AAAA,KAGU,YAAA,GAAe,eAAA;AAAA,KAEf,oBAAA;EACV,IAAA,GAAO,eAAA;EACP,KAAA;EACA,SAAA;EACA,WAAA;EACA,KAAA;EACA,OAAA;EACA,OAAA;AAAA;AAAA,KAGU,OAAA,GAAU,oBAAA;AAAA,KAEV,QAAA,GAAW,MAAA,SAAe,OAAA;AAAA,KAE1B,gBAAA;EACV,OAAA;IACE,IAAA;EAAA;EAEF,WAAA;EACA,OAAA;EACA,KAAA;IACE,OAAA;IACA,QAAA;IACA,YAAA;MACE,OAAA;IAAA;IAEF,IAAA;MACE,OAAA;IAAA;EAAA;AAAA;A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B,aAAA,eAC3B,KAAA,EAAO,CAAA,KACJ,CAAA,SAAU,UAAA,GACX,cAAA,CAAe,YAAA,CAAa,CAAA,GAAI,CAAA,2BAChC,cAAA,CAAe,YAAA,CAAa,CAAA;EAIhC,UAAA,aAAuB,aAAA,gBACrB,KAAA,EAAO,CAAA,KACJ,cAAA,CAAe,EAAA,EAAI,EAAA,EAAI,IAAA;AAAA;;;;;;ATpI9B;;KUSY,IAAA,cACA,OAAA,CAAQ,IAAA,CAAK,aAAA,2BAEvB,MAAA,EAAQ,CAAA,gBACM,aAAA,eACd,SAAA,EAAW,CAAA,KACR,CAAA,SAAU,UAAA,GACX,cAAA,CAAe,YAAA,CAAa,CAAA,GAAI,CAAA,2BAChC,cAAA,CAAe,YAAA,CAAa,CAAA;;cAG1B,IAAA,EAAM,IAAA;AVDZ;;;;;AAAA,KUWY,aAAA,cAA2B,aAAA,eACrC,SAAA,EAAW,CAAA,EACX,OAAA,GAAU,OAAA,CAAQ,IAAA,CAAK,aAAA,8BACpB,CAAA,SAAU,UAAA,GACX,cAAA,CAAe,YAAA,CAAa,CAAA,GAAI,CAAA,2BAChC,cAAA,CAAe,YAAA,CAAa,CAAA;;cAI1B,aAAA,EAAe,aAAA"}
1
+ {"version":3,"file":"index2.d.ts","names":[],"sources":["../src/constants/controls.ts","../src/types.ts","../src/stories/base/renderList.tsx","../src/stories/base/renderMain.tsx","../src/stories/base/renderRender.tsx","../src/stories/rocketstories/renderDimension/index.tsx","../src/stories/rocketstories/renderList.tsx","../src/stories/rocketstories/renderMain.tsx","../src/stories/rocketstories/renderRender.tsx","../src/rocketstories.tsx","../src/init.ts"],"mappings":";;;;;cAAa,aAAA;AAAA,KAmBD,eAAA,WAA0B,aAAA;;;KCJ1B,IAAA,GAAO,MAAA;AAAA,KAEP,YAAA,uBACV,kBAAA,SAA2B,aAAA,iBACvB,MAAA,GACA,kBAAA;AAAA,KAEM,cAAA,WAAyB,EAAA,CAAG,CAAA,IACtC,OAAA;EACE,IAA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AA,CAAK,aAAA,8BACpB,CAAA,SAAU,UAAA,GACX,cAAA,CAAe,YAAA,CAAa,CAAA,GAAI,CAAA,2BAChC,cAAA,CAAe,YAAA,CAAa,CAAA;;cAI1B,aAAA,EAAe,aAAA"}
package/lib/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["group","group","group","group","CONTROLS.ELEMENT_CONTROLS","CONTROLS.LIST_CONTROLS","CONTROLS.TEXT_CONTROLS","CONTROLS.OVERLAY_CONTROLS","CONTROLS.ROCKETSTYLE_CONTROLS","StoryHoc","StoryHoc","StoryHoc","element","component","useContext","contextHook","component","useContext","Heading","Item","component","NotFound","Fragment","Heading","PseudoList","Item","RocketStoryHoc","RocketStoryHoc","RocketStoryHoc","rocketstory.renderMain","simplestory.renderMain","rocketstory.renderDimension","rocketstory.renderRender","simplestory.renderRender","rocketstory.renderList","simplestory.renderList"],"sources":["../src/controls/element.ts","../src/controls/list.ts","../src/controls/overlay.ts","../src/controls/rocketstyle.ts","../src/controls/text.ts","../src/utils/controls.ts","../src/internal/StoryHoc.tsx","../src/stories/base/renderList.tsx","../src/stories/base/renderMain.tsx","../src/stories/base/renderRender.tsx","../src/components/base/element.ts","../src/components/base/Heading.ts","../src/components/NotFound.tsx","../src/utils/code.ts","../src/utils/theme.ts","../src/stories/rocketstories/renderDimension/context.tsx","../src/stories/rocketstories/renderDimension/components/Item.tsx","../src/stories/rocketstories/renderDimension/components/PseudoList.tsx","../src/stories/rocketstories/renderDimension/index.tsx","../src/utils/dimensions.ts","../src/internal/RocketStoryHoc.tsx","../src/stories/rocketstories/renderList.tsx","../src/stories/rocketstories/renderMain.tsx","../src/stories/rocketstories/renderRender.tsx","../src/rocketstories.tsx","../src/init.ts","../src/index.ts"],"sourcesContent":["/**\n * Default Storybook control definitions for Element-based components.\n * Covers layout props (direction, alignX, alignY), content slots\n * (beforeContent, afterContent), CSS extension props, and HTML tag selection.\n */\nimport { HTML_TAGS } from '@vitus-labs/core'\n\nconst group = 'Element (Vitus-Labs)'\n\nconst directionType = 'inline | rows | reverseRows | reverseInline'\nconst alignXType = 'left | center | right | block | spaceBetween | spaceAround'\nconst alignYType = 'top | center | block | spaceBetween | spaceAround'\nconst CssType = 'string | (css) => css`` | css``'\n\nconst DIRECTION = {\n group,\n type: 'select',\n options: ['-----', ...directionType.split(' | ')],\n value: 'rows',\n valueType: `${directionType} | Record<string, ${directionType}> | Array<${directionType}`,\n}\n\nconst ALIGN_X = {\n group,\n type: 'select',\n options: alignXType.split(' | '),\n value: 'left',\n valueType: `${alignXType} | Record<string, ${alignXType}> | Array<${alignXType}`,\n}\n\nconst ALIGN_Y = {\n group,\n type: 'select',\n options: alignYType.split(' | '),\n value: 'center',\n valueType: `${alignYType} | Record<string, ${alignYType}> | Array<${alignYType}`,\n}\n\nconst CSS = {\n group,\n type: 'text',\n valueType: `${CssType} | Record<string,${CssType}> | Array<${CssType}>`,\n}\n\nexport default {\n tag: {\n group,\n type: 'select',\n options: HTML_TAGS,\n valueType: 'HTMLTag',\n description: 'A prop which will change **HTML tag** of the element.',\n },\n children: {\n group,\n type: '',\n valueType: 'ReactNode',\n description:\n 'React children. Priorities when rendering are **children** → **content** → **label**, therefore _children_ has the highest priority.',\n },\n content: {\n group,\n type: 'text',\n valueType: 'ReactNode',\n description:\n 'A prop which can be used instead of _children_. Priorities when rendering are **children** → **content** → **label**, therefore _content_ has the middle priority.',\n },\n label: {\n group,\n type: 'text',\n valueType: 'ReactNode',\n description:\n 'A prop which can be used instead of _children_. Priorities when rendering are **children** → **content** → **label**, therefore _label_ has the lowest priority.',\n },\n block: {\n group,\n type: 'boolean',\n valueType: 'boolean | Record<string, boolean> | Array<boolean>',\n description:\n 'Defines whether should behave as **inline** or **block** element.',\n },\n direction: {\n ...DIRECTION,\n value: undefined,\n description:\n 'Define whether element should render **horizontally** or **vertically**.',\n },\n alignX: {\n ...ALIGN_X,\n description:\n 'Define alignment of **beforeContent**, **content**, and **afterContent** with respect to root element on **axis X**.',\n },\n alignY: {\n ...ALIGN_Y,\n description:\n 'Define alignment of **beforeContent**, **content**, and **afterContent** with respect to the root element on **axis Y**.',\n },\n contentDirection: {\n ...DIRECTION,\n description:\n 'Define whether the children in **content** wrapper should be rendered in _line_ or in _rows_.',\n },\n contentAlignX: {\n ...ALIGN_X,\n description:\n 'Define how the children in **content** wrapper should be aligned on **axis X**.',\n },\n contentAlignY: {\n ...ALIGN_Y,\n description:\n 'Define how the children in **content** wrapper should be aligned on **axis Y**.',\n },\n beforeContentDirection: {\n ...DIRECTION,\n description:\n 'Define whether children in **beforeContent** wrapper should be rendered in _line_ or in _rows_.',\n },\n beforeContentAlignX: {\n ...ALIGN_X,\n description:\n 'Define how children in **beforeContent** wrapper should be aligned on **axis X**.',\n },\n beforeContentAlignY: {\n ...ALIGN_Y,\n description:\n 'Define how children in **beforeContent** wrapper should be aligned on **axis Y**.',\n },\n afterContentDirection: {\n ...DIRECTION,\n description:\n 'Define whether children in **afterContent** wrapper should be rendered in _line_ or in _rows_.',\n },\n afterContentAlignX: {\n ...ALIGN_X,\n description:\n 'Define how children in **afterContent** wrapper should be aligned on **axis X**.',\n },\n afterContentAlignY: {\n ...ALIGN_Y,\n description:\n 'Define how children in **afterContent** wrapper should be aligned on **axis Y**.',\n },\n equalCols: {\n type: 'boolean',\n group,\n valueType: 'boolean | Record<string,boolean> | Array<boolean>',\n description:\n 'Whether should all inner elements have the same `width` / `height`.',\n },\n gap: {\n type: 'number',\n group,\n valueType: 'number | Record<string,number> | Array<number>',\n description:\n 'Defines space gap **between** _beforeContent_, _content_ and _afterContent_ if one of _beforeContent_ or _afterContent_ contain _children_ to be rendered.',\n },\n // vertical: {\n // type: 'boolean',\n // group,\n // valueType: 'boolean | Record<string,boolean> | Array<boolean>',\n // description:\n // 'Define whether element should render horizontally or vertically.',\n // },\n beforeContent: {\n group,\n type: '',\n valueType: 'ReactNode',\n description: 'A children to be rendered inside `beforeContent` wrapper.',\n },\n afterContent: {\n group,\n type: '',\n valueType: 'ReactNode',\n description: 'A children to be rendered inside `afterContent` wrapper.',\n },\n css: {\n ...CSS,\n description:\n 'An additional styling prop to enhance the **root** element CSS styles.',\n },\n contentCss: {\n ...CSS,\n description:\n 'An additional styling prop to enhance the **content** element CSS styles.',\n },\n beforeContentCss: {\n ...CSS,\n description:\n 'An additional styling prop to enhance the **beforeContent** element CSS styles.',\n },\n afterContentCss: {\n ...CSS,\n description:\n 'An additional styling prop to enhance the **afterContent** element CSS styles.',\n },\n ref: {\n group,\n description: 'A React ref',\n valueType: 'ForwardedRef<any>',\n },\n innerRef: {\n group,\n description: 'A React ref',\n valueType: 'ForwardedRef<any>',\n },\n dangerouslySetInnerHTML: {\n group,\n type: 'text',\n disable: true,\n valueType: 'any',\n },\n}\n","/**\n * Default Storybook control definitions for List-based components.\n * Covers data input, item/wrap component props, key extraction,\n * and disables label/content controls that do not apply to lists.\n */\nconst group = 'List (@vitus-labs)'\n\nconst itemPropsType = `Record<string, any> | (props, meta) => Record<string,any>`\n\nexport default {\n rootElement: {\n group,\n type: 'boolean',\n valueType: 'boolean',\n description:\n 'Whether a **root** element should be rendered or the output should be just a type of React **Fragment**.',\n },\n data: {\n group,\n type: 'array',\n valueType: 'string[] | number[] | object[]',\n description:\n 'An array of item values to be passed to item component. Data are being passed to _component_ prop element.',\n },\n valueName: {\n group,\n type: 'text',\n valueType: `string`,\n description:\n 'Is required when **data** consists of **strings** or **numbers** to name value being passed as a prop.',\n },\n itemProps: {\n group,\n valueType: itemPropsType,\n description:\n 'A customizable hook for dynamically render props for each **item** component.',\n },\n wrapProps: {\n group,\n valueType: itemPropsType,\n description:\n 'A customizable hook for dynamically render props for each **wrapComponent** when _wrapComponent_ is passed, otherwise ignored.',\n },\n itemKey: {\n group,\n valueType: 'string | `(item, i) => number | string`',\n description:\n \"Prop for defining item key in list. **name** / **value** if default behavior doesn't work out.\",\n },\n component: {\n group,\n type: 'component',\n valueType: 'ComponentType',\n description:\n 'A component to be rendered within the List per item. Receives props from _data_ array props.',\n },\n wrapComponent: {\n group,\n type: 'component',\n valueType: `ComponentType`,\n description:\n 'A component to be used as a wrapper component for each item component.',\n },\n label: {\n disable: true,\n },\n content: {\n disable: true,\n },\n} as const\n","const group = 'Overlay (Vitus-Labs)'\n\nexport default {\n refName: {\n type: 'text',\n value: 'ref',\n description:\n \"Overlay component access **ref** to directly mutate styles when calculation position to prevent re-renders. It's being used for both `trigger`, and `children` element at the same time. Your components must accept refs with the same naming.\",\n group,\n },\n triggerRefName: {\n type: 'text',\n description:\n 'A key name how a **ref** should be passed to trigger component',\n group,\n },\n contentRefName: {\n type: 'text',\n description:\n 'A key name how a **ref** should be passed to content component',\n group,\n },\n isOpen: {\n type: 'boolean',\n value: false,\n description: '',\n group,\n },\n openOn: {\n type: 'select',\n options: ['click', 'hover'],\n value: 'click',\n description: '',\n group,\n },\n closeOn: {\n type: 'select',\n options: ['click', 'triggerClick', 'hover', 'manual'],\n value: 'click',\n description: '',\n group,\n },\n type: {\n type: 'select',\n options: ['dropdown', 'tooltip', 'popover', 'modal'],\n value: 'dropdown',\n description: '',\n group,\n },\n align: {\n type: 'select',\n options: ['top', 'left', 'bottom', 'right'],\n value: 'bottom',\n description: '',\n group,\n },\n alignX: {\n type: 'select',\n options: ['left', 'center', 'right'],\n value: 'left',\n description: '',\n group,\n },\n alignY: {\n type: 'select',\n options: ['top', 'center', 'bottom'],\n value: 'bottom',\n description: '',\n group,\n },\n position: {\n type: 'select',\n options: ['fixed', 'absolute', 'relative', 'static'],\n value: 'fixed',\n description: '',\n group,\n },\n offsetX: {\n type: 'number',\n value: 0,\n description: '',\n group,\n },\n offsetY: {\n type: 'number',\n value: 0,\n description: '',\n group,\n },\n throttleDelay: {\n type: 'number',\n value: 200,\n description: '',\n group,\n },\n children: {\n description: 'A content to be rendered when Overlay is open',\n },\n} as const\n","/**\n * Default Storybook control definitions for rocketstyle pseudo-state props.\n * Provides boolean toggles for hover, active, pressed, and focus states,\n * as well as descriptions for their corresponding mouse/focus event handlers.\n */\nconst group = 'Rocketstyle (Vitus-Labs)'\n\nexport default {\n hover: {\n group,\n type: 'boolean',\n value: false,\n description:\n 'Can be manually triggered **hover** event on the element. Behaves as **:hover** state in _CSS_.',\n },\n active: {\n group,\n type: 'boolean',\n value: false,\n description:\n 'Can be manually triggered **active** event on the element. Can be used to define element as `active`, e.g. _links_.',\n },\n pressed: {\n group,\n type: 'boolean',\n value: false,\n description:\n 'Can be manually triggered **pressed** event on the element. Behaves as `:active` state in _CSS_.',\n },\n focus: {\n group,\n type: 'boolean',\n value: false,\n description:\n 'Can be manually triggered **focus** event on the element. Behaves as `:focus` state in _CSS_.',\n },\n onMouseEnter: {\n group,\n type: 'function',\n description:\n 'The _onMouseEnter_ function can take a `SyntheticMouseEvent`.',\n },\n onMouseLeave: {\n group,\n type: 'function',\n description:\n 'The _onMouseLeave_ function can take a `SyntheticMouseEvent.`',\n },\n onMouseDown: {\n group,\n type: 'function',\n description: 'The _onMouseDown_ function can take a `SyntheticMouseEvent`.',\n },\n onMouseUp: {\n group,\n type: 'function',\n description: 'The _onMouseUp_ function can take a `SyntheticMouseEvent`.',\n },\n onFocus: {\n group,\n type: 'function',\n description: 'The _onFocus_ function can take a `SyntheticFocusEvent`.',\n },\n onBlur: {\n group,\n type: 'function',\n description: 'The _onBlur_ function can take a `SyntheticFocusEvent`.',\n },\n} as const\n","/**\n * Default Storybook control definitions for Text-based components.\n * Provides controls for paragraph mode, HTML tag selection, children/label\n * content, and CSS extension.\n */\nimport { HTML_TAGS } from '@vitus-labs/core'\n\nconst group = 'Text (Vitus-Labs)'\n\nexport default {\n paragraph: {\n group,\n type: 'boolean',\n description:\n 'Changes a behavior of inline text to become **block** text. Also changes HTML **tag** to `p`',\n },\n tag: {\n group,\n type: 'select',\n options: HTML_TAGS,\n },\n children: {\n group,\n type: '',\n valueType: 'ReactNode',\n description:\n 'React children. Priorities when rendering are **children** → **label**, therefore _children_ has the highest priority.',\n },\n label: {\n group,\n type: 'text',\n valueType: 'ReactNode',\n description:\n 'A prop which can be used instead of _children_. Priorities when rendering are **children** → **label**, therefore _label_ has lower priority than _children_.',\n },\n extendCss: {\n group,\n type: 'text',\n description:\n 'An additional styling prop to enhance Text element CSS styles.',\n },\n} as const\n","/**\n * Utilities for creating, converting, and formatting Storybook controls.\n * Handles transformation from rocketstories control definitions to the\n * Storybook argTypes format, including dimension-based select controls\n * and component-specific default controls.\n */\nimport * as CONTROLS from '~/controls'\nimport type {\n ControlConfiguration,\n Controls,\n RocketType,\n StorybookControl,\n} from '~/types'\n\n/** Normalizes user-supplied control shorthand (string or object) into full ControlConfiguration objects. */\nexport const createControls = (props: Record<string, any>) =>\n Object.entries(props).reduce<Record<string, any>>((acc, [key, value]) => {\n if (typeof value === 'string') {\n return {\n ...acc,\n [key]: {\n type: value,\n },\n }\n }\n\n if (typeof value === 'object' && value !== null) {\n return { ...acc, [key]: value }\n }\n\n return acc\n }, {})\n\ntype ConvertDimensionsToControls = ({\n dimensions,\n multiKeys,\n}: {\n dimensions: Record<string, any>\n multiKeys: Record<string, true>\n}) => Controls\n\n/** Converts rocketstyle dimension metadata into select/multi-select Storybook controls. */\nexport const convertDimensionsToControls: ConvertDimensionsToControls = ({\n dimensions,\n multiKeys,\n}) =>\n Object.entries(dimensions).reduce((acc, [key, value]) => {\n const valueKeys = Object.keys(value)\n const isMultiKey = !!multiKeys[key]\n\n const control = {\n type: isMultiKey ? 'multi-select' : 'select',\n options: valueKeys,\n group: 'Dimensions [Rocketstyle (Vitus-Labs)]',\n }\n\n return { ...acc, [key]: control }\n }, {})\n\n// --------------------------------------------------------\n// values to controls\n// --------------------------------------------------------\ntype GetDefaultVitusLabsControls = (component: RocketType) => Controls\n\n/** Returns pre-defined controls based on the component's Vitus Labs type (Element, List, Text, Overlay). */\nexport const getDefaultVitusLabsControls: GetDefaultVitusLabsControls = (\n component,\n) => {\n const { IS_ROCKETSTYLE, VITUS_LABS__COMPONENT } = component\n\n const IS_ELEMENT = VITUS_LABS__COMPONENT === '@vitus-labs/elements/Element'\n const IS_LIST = VITUS_LABS__COMPONENT === '@vitus-labs/elements/List'\n const IS_TEXT = VITUS_LABS__COMPONENT === '@vitus-labs/elements/Text'\n const IS_OVERLAY = VITUS_LABS__COMPONENT === '@vitus-labs/elements/Overlay'\n\n const result = {\n ...(IS_ELEMENT || IS_LIST ? CONTROLS.ELEMENT_CONTROLS : {}),\n\n ...(IS_LIST ? CONTROLS.LIST_CONTROLS : {}),\n\n ...(IS_TEXT ? CONTROLS.TEXT_CONTROLS : {}),\n\n ...(IS_OVERLAY ? CONTROLS.OVERLAY_CONTROLS : {}),\n\n ...(IS_ROCKETSTYLE ? CONTROLS.ROCKETSTYLE_CONTROLS : {}),\n }\n\n return result as Controls\n}\n\n/** Transforms internal control definitions into the Storybook argTypes format with table metadata. */\ntype MakeStorybookControls = (\n obj: Record<string, ControlConfiguration>,\n props: Record<string, any>,\n) => Record<string, StorybookControl>\n\nexport const makeStorybookControls: MakeStorybookControls = (obj, props) =>\n Object.entries(obj).reduce<Record<string, StorybookControl>>(\n (acc, [key, control]) => {\n const defaultValue =\n typeof props[key] !== 'function' ? props[key] : undefined\n\n if (control.disable) {\n // eslint-disable-next-line no-param-reassign\n acc[key] = {\n table: {\n disable: control.disable,\n },\n }\n } else {\n // eslint-disable-next-line no-param-reassign\n acc[key] = {\n control: { type: control.type ?? 'text' },\n description: control.description,\n options: control.options /* || CONTROL_OPTIONS[control.type] */,\n table: {\n defaultValue: {\n summary: defaultValue || control.value,\n },\n disable: control.disable,\n category: control.group /* || CONTROL_TYPES_GROUPS[control.type] */,\n type: {\n summary: control.valueType,\n },\n },\n }\n }\n\n return acc\n },\n {},\n )\n\n// --------------------------------------------------------\n// disableControl\n// --------------------------------------------------------\ntype DisableControl = (\n name: string,\n) => Record<string, { table: { disable: true } }>\n\nconst disableControl: DisableControl = (name) => ({\n [name]: { table: { disable: true } },\n})\n\n/** Produces argType overrides that hide individual dimension value keys from the controls panel. */\ntype DisableDimensionControls = (\n dimensions: Record<string, boolean>,\n name?: string,\n) => any\n\nexport const disableDimensionControls: DisableDimensionControls = (\n dimensions,\n dimensionName,\n) => {\n const result = dimensionName ? disableControl(dimensionName) : {}\n const dimensionKeys = Object.values(dimensions)\n\n return dimensionKeys.reduce((acc, value) => {\n Object.keys(value).forEach((item) => {\n // eslint-disable-next-line no-param-reassign\n acc = { ...acc, ...disableControl(item) }\n })\n\n return acc\n }, result)\n}\n","/**\n * Higher-order component factory for regular (non-rocketstyle) components.\n * Converts user-defined controls into Storybook argTypes and attaches\n * args and argTypes to the returned story component.\n */\nimport type { StoryComponent, StoryConfiguration } from '~/types'\nimport { createControls, makeStorybookControls } from '~/utils/controls'\n\nexport type Story<P = {}> = (\n WrappedComponent: any,\n) => (params: StoryConfiguration) => StoryComponent<P>\n\nconst story: Story =\n (WrappedComponent) =>\n ({ component, attrs, controls }) => {\n // ------------------------------------------------------\n // CONTROLS GENERATION\n // ------------------------------------------------------\n const createdControls = createControls(controls)\n\n const finalControls = createdControls\n const storybookControls = makeStorybookControls(finalControls, attrs)\n\n const Enhanced = WrappedComponent(component)\n\n Enhanced.args = attrs\n Enhanced.argTypes = storybookControls\n\n return Enhanced\n }\n\nexport default story\n","/**\n * Renders a list story for a regular non-rocketstyle component.\n * Accepts list configuration (data, itemKey, etc.) and wraps the component\n * through StoryHoc, rendering it inside a Vitus Labs List element.\n */\n\nimport { List } from '@vitus-labs/elements'\nimport type { ComponentType } from 'react'\nimport StoryHoc from '~/internal/StoryHoc'\nimport type {\n ListStoryOptions,\n RocketStoryConfiguration,\n StoryComponent,\n} from '~/types'\n\nexport type RenderList<P = {}> = (\n render: ListStoryOptions,\n params: RocketStoryConfiguration,\n) => StoryComponent<P>\n\nexport default (list: ListStoryOptions) =>\n StoryHoc((component: ComponentType) => (props: Record<string, unknown>) => (\n <List\n rootElement={false}\n {...list}\n itemProps={props}\n component={component}\n />\n ))\n","/**\n * Renders the main (default) story for a regular non-rocketstyle component.\n * Wraps the component through StoryHoc to attach Storybook controls, then\n * renders it with createElement using the current args.\n */\nimport { type ComponentType, createElement } from 'react'\nimport StoryHoc from '~/internal/StoryHoc'\n\nimport type { RocketStoryConfiguration, StoryComponent } from '~/types'\n\nexport type RenderMain<P = {}> = (\n params: RocketStoryConfiguration,\n) => StoryComponent<P>\n\nexport default StoryHoc(\n (component: ComponentType) => (props: Record<string, unknown>) => (\n <>{createElement(component, props)}</>\n ),\n)\n","import type { FC } from 'react'\nimport StoryHoc from '~/internal/StoryHoc'\nimport type { RocketStoryConfiguration, StoryComponent } from '~/types'\n\nexport type RenderRender<P = {}> = (\n render: FC,\n params: RocketStoryConfiguration,\n) => StoryComponent<P>\n\nexport default (render: FC) => StoryHoc(() => render)\n","/**\n * Base rocketstyle element used internally by rocketstories for\n * layout wrappers and story containers. Applies a default Arial\n * font family via the theme and renders unistyle-based CSS.\n */\nimport { Element } from '@vitus-labs/elements'\nimport rocketstyle from '@vitus-labs/rocketstyle'\nimport { styles } from '@vitus-labs/unistyle'\n\nexport default rocketstyle()({\n component: Element,\n name: 'element',\n})\n .theme({\n fontFamily: 'Arial',\n })\n .styles(\n (css) => css<any>`\n ${({ $rocketstyle }) => {\n const baseTheme = styles({ theme: $rocketstyle, css, rootSize: 16 })\n\n return css`\n ${baseTheme};\n `\n }};\n `,\n )\n","/**\n * Heading component built on the base element. Renders as an h1 tag\n * and provides two size variants: level1 (20px) and level2 (16px).\n * Used for labeling dimension items and pseudo-state groups in stories.\n */\nimport element from './element'\n\nexport default element.attrs({ tag: 'h1', block: true }).sizes({\n level1: {\n fontSize: 20,\n },\n level2: {\n marginTop: 0,\n fontSize: 16,\n },\n})\n","/**\n * Empty placeholder component displayed when a requested dimension\n * has no values or the story cannot be rendered.\n */\nimport { config } from '@vitus-labs/core'\nimport type { FC } from 'react'\n\nconst Wrapper = config.styled.div`\n display: flex;\n font-size: 32px;\n`\n\nconst component: FC = () => <Wrapper>Nothing here</Wrapper>\n\ncomponent.displayName = '@vitus-labs/rocketstories/Empty'\n\nexport default component\n","/* eslint-disable no-param-reassign */\nimport { get } from '@vitus-labs/core'\nimport type { Control, Obj, SimpleValue } from '~/types'\n\n// --------------------------------------------------------\n// parseProps\n// --------------------------------------------------------\ntype ObjValue = Control\n\ntype ParseProps = <\n T extends Record<string, SimpleValue | SimpleValue[] | ObjValue>,\n>(\n props: T,\n) => Record<keyof T, unknown>\n\nconst parseProps: ParseProps = (props) =>\n Object.entries(props).reduce((acc, [key, value]) => {\n if (value === null) return acc\n\n const valueType = typeof value\n\n if (['string', 'number', 'boolean', 'bigint'].includes(valueType)) {\n return { ...acc, [key]: value }\n }\n\n if (Array.isArray(value)) {\n return { ...acc, [key]: value }\n }\n\n if (valueType === 'object') {\n const type = get(value, 'type')\n const options = get(value, 'options')\n const defaultValue = get(value, 'value')\n\n // if has custom knobs configuration\n if (type && options && defaultValue) {\n return { ...acc, [key]: defaultValue || options }\n }\n\n return { ...acc, [key]: value }\n }\n\n return acc\n }, {} as any)\n\n// --------------------------------------------------------\n// stringifyArray\n// --------------------------------------------------------\ntype StringifyArray = (props: unknown[]) => string\n\nconst stringifyArray: StringifyArray = (props) => {\n let result = '['\n\n const arrayLength = props.length\n\n result += props.reduce((acc, value, i) => {\n if (Array.isArray(value)) {\n // TODO: parse arrays\n acc += `${stringifyArray(value)}`\n } else if (typeof value === 'object' && value !== null) {\n acc += `${stringifyObject(value as Record<string, any>)}`\n } else if (['number', 'string'].includes(typeof value)) {\n acc += `\"${value}\"`\n } else {\n acc += `${value}`\n }\n\n // if not last item, add comma and space\n if (arrayLength !== i + 1) {\n acc += `, `\n }\n\n return acc\n }, '')\n\n result += ']'\n\n return result\n}\n\n// --------------------------------------------------------\n// stringifyObject\n// --------------------------------------------------------\ntype StringifyObject = (props: Obj) => string\n\nconst stringifyObject: StringifyObject = (props) => {\n let result = '{ '\n\n const propsArray = Object.entries(props)\n const arrayLength = propsArray.length\n\n result += propsArray.reduce((acc, [key, value], i) => {\n if (Array.isArray(value)) {\n // TODO: parse arrays\n acc += `${key}: ${value}`\n } else if (typeof value === 'object' && value !== null) {\n acc += `${key}: ${stringifyObject(value)}`\n } else if (['string'].includes(typeof value)) {\n acc += `${key}: \"${value}\"`\n } else {\n acc += `${key}: ${value}`\n }\n\n if (arrayLength !== i + 1) {\n acc += `, `\n }\n\n return acc\n }, '')\n\n result += ' }'\n\n return result\n}\n\n// --------------------------------------------------------\n// stringifyObject\n// --------------------------------------------------------\ntype StringifyProps = (props: Obj) => string\n\nconst stringifyProps: StringifyProps = (props) => {\n const parsedProps = parseProps(props)\n const arrayProps = Object.entries(parsedProps)\n const arrayLength = arrayProps.length\n\n return arrayProps.reduce((acc, [key, value], i) => {\n if (typeof value === 'boolean') {\n if (value === true) acc += `${key}`\n else acc += `${key}=${value}`\n } else if (\n ['string', 'number'].includes(typeof value) ||\n value === null ||\n value === undefined\n ) {\n acc += `${key}=\"${value}\"`\n } else if (Array.isArray(value)) {\n acc += `${key}={${stringifyArray(value)}}`\n } else if (typeof value === 'object' && value !== null) {\n acc += `${key}={${stringifyObject(value as Record<string, any>)}}`\n }\n\n if (arrayLength !== i + 1) {\n acc += ' '\n }\n\n return acc\n }, '')\n}\n\nconst parseComponentName = (name: string) => {\n const helper = name.split('/')\n\n if (helper.length > 1) {\n return helper[helper.length - 1]\n }\n\n return name\n}\n\n/**\n * Generates a single self-closing JSX tag string for the given component\n * name and props, e.g. `<Button primary size=\"large\" />`.\n */\ntype CreateJSXCode = (name: string, props: Obj) => string\n\nexport const createJSXCode: CreateJSXCode = (name, props) =>\n `<${parseComponentName(name)} ${stringifyProps(props)} />`\n\n// --------------------------------------------------------\n// createJSXCodeArray\n// --------------------------------------------------------\ntype CreateJSXCodeArray = (\n name: string,\n props: Obj,\n dimensionName: string,\n dimensions: Obj,\n useBooleans: boolean,\n isMultiKey: boolean,\n) => string\n\nexport const createJSXCodeArray: CreateJSXCodeArray = (\n name,\n props,\n dimensionName,\n dimensions,\n useBooleans,\n isMultiKey,\n) => {\n if (!dimensions) return `// nothing here`\n\n let result = ''\n\n const finalProps = { ...props }\n delete finalProps[dimensionName]\n\n result += Object.keys(dimensions).reduce((acc, key) => {\n acc += createJSXCode(name, {\n [dimensionName]: isMultiKey ? [key] : key,\n ...finalProps,\n })\n acc += `\\n`\n return acc\n }, '')\n\n if (useBooleans) {\n result += `\\n\\n`\n result += `// Or alternatively use boolean ${dimensionName} props (${Object.keys(\n dimensions,\n ).toString()})`\n result += `\\n`\n\n result += Object.keys(dimensions).reduce((acc, key) => {\n acc += createJSXCode(name, { [key]: true, ...finalProps })\n acc += `\\n`\n return acc\n }, '')\n }\n\n return result\n}\n\nconst addBooleanCodeComment = (values: string[]) => {\n let result = `\\n\\n`\n result += `// Or alternatively use boolean props (e.g. ${values})`\n result += `\\n`\n\n return result\n}\n\n/**\n * Generates the JSX code snippet shown in the Storybook docs panel for the\n * main story. Includes the primary JSX tag and, when boolean dimension\n * shorthand is available, an alternative boolean-prop usage example.\n */\ntype GenerateMainJSXCode = (params: {\n name: string\n props: Record<string, string>\n dimensions: Record<string, string>\n booleanDimensions: any\n}) => any\n\nexport const generateMainJSXCode: GenerateMainJSXCode = ({\n name,\n props,\n dimensions,\n booleanDimensions,\n}) => {\n let result = createJSXCode(name, { ...dimensions, ...props })\n\n if (booleanDimensions) {\n const keys = Object.keys(booleanDimensions)\n result += addBooleanCodeComment(keys)\n result += createJSXCode(name, { ...booleanDimensions, ...props })\n }\n\n return result\n}\n","/**\n * Retrieves the current theme object from the global\n * `window.__VITUS_LABS_STORIES__` store, which is populated\n * by the Storybook preview configuration at startup.\n */\n/* eslint-disable no-underscore-dangle */\n\ndeclare global {\n interface Window {\n __VITUS_LABS_STORIES__: {\n decorators: {\n theme: Record<string, unknown>\n }\n }\n }\n}\n\ntype GetTheme = () => Record<string, unknown>\nconst getTheme: GetTheme = () => window.__VITUS_LABS_STORIES__.decorators.theme\n\nexport default getTheme\n","/**\n * React context for the dimension story renderer. Provides the wrapped\n * rocketstyle component reference to nested Item and PseudoList components\n * so they can render it without prop-drilling.\n */\nimport {\n type ComponentType,\n useContext as contextHook,\n createContext,\n type FC,\n type ReactNode,\n} from 'react'\n\ntype Context = {\n component: ComponentType\n}\n\nexport const context = createContext<Context>({} as Context)\n\nexport const useContext = () => contextHook(context)\n\nconst ContextProvider = context.Provider\n\nconst Provider: FC<Context & { children: ReactNode }> = ({\n children,\n ...props\n}) => <ContextProvider value={props}>{children}</ContextProvider>\n\nexport default Provider\n","/**\n * Renders a single dimension value item within a dimension story.\n * Retrieves the component from context and renders it with the given\n * props, optionally prefixed by a level2 Heading showing the item title.\n */\nimport { createElement, type FC } from 'react'\nimport { Heading } from '~/components/base'\nimport { useContext } from '../context'\n\ntype Props = {\n title?: string\n} & { [key: string]: any }\n\nconst component: FC<Props> = ({ title, ...props }) => {\n const { component } = useContext()\n\n return (\n <div>\n {title && <Heading level2 label={title} />}\n {createElement(component, props)}\n </div>\n )\n}\n\nexport default component\n","/**\n * Renders a list of pseudo-state variations (base, hover, pressed, active)\n * for a single dimension value. Each pseudo state is rendered as an Item\n * with the corresponding pseudo prop set to true.\n */\nimport type { FC } from 'react'\nimport Item from './Item'\n\nconst pseudo = ['base', 'hover', 'pressed', 'active'] as const\n\ntype Props = {\n itemProps: Record<string, any>\n}\n\nconst component: FC<Props> = ({ itemProps }) => (\n <>\n {pseudo.map((item) => {\n const pseudoProps = { [item]: true }\n\n return <Item key={item} title={item} {...itemProps} {...pseudoProps} />\n })}\n </>\n)\n\nexport default component\n","/**\n * Renders a dimension story for a rocketstyle component. Iterates over all\n * values of the specified dimension and renders each as an Item (or a\n * PseudoList when pseudo-state visualization is enabled). Generates\n * corresponding JSX code snippets and Storybook controls.\n */\n/* eslint-disable @typescript-eslint/ban-ts-comment */\n\nimport { isEmpty, pick } from '@vitus-labs/core'\nimport { Element } from '@vitus-labs/elements'\nimport { Fragment } from 'react'\nimport { Heading } from '~/components/base'\nimport NotFound from '~/components/NotFound'\nimport type {\n RocketDimensions,\n RocketStoryConfiguration,\n StoryComponent,\n} from '~/types'\nimport { createJSXCodeArray } from '~/utils/code'\nimport {\n convertDimensionsToControls,\n createControls,\n disableDimensionControls,\n getDefaultVitusLabsControls,\n makeStorybookControls,\n} from '~/utils/controls'\nimport getTheme from '~/utils/theme'\nimport Item from './components/Item'\nimport PseudoList from './components/PseudoList'\nimport Provider from './context'\n\nexport type RenderDimension<P = {}> = (\n dimension: RocketDimensions,\n params: RocketStoryConfiguration & {\n ignore: any\n },\n) => StoryComponent<P>\n\nconst renderDimension: RenderDimension = (\n dimension,\n { name, component, attrs = {}, controls, storyOptions = {}, ignore = [] },\n) => {\n // ------------------------------------------------------\n // ROCKETSTYLE COMPONENT INFO\n // ------------------------------------------------------\n const theme = getTheme()\n const statics = component.getStaticDimensions(theme)\n const defaultAttrs = component.getDefaultAttrs(attrs, theme, 'light')\n const { dimensions, useBooleans, multiKeys } = statics\n\n const finalAttrs = { ...defaultAttrs, ...attrs }\n\n // ------------------------------------------------------\n // CURRENT ROCKETSTYLE DIMENSION INFO\n // ------------------------------------------------------\n const currentDimension = dimensions[dimension]\n const isMultiKey = !!multiKeys[dimension]\n\n // ------------------------------------------------------\n // RENDER EMPTY PAGE WHEN DIMENSION IS NOT AVAILABLE\n // ------------------------------------------------------\n const DONT_RENDER = isEmpty(currentDimension)\n if (DONT_RENDER) return NotFound\n\n // ------------------------------------------------------\n // CONTROLS GENERATION\n // ------------------------------------------------------\n const createdControls = createControls(controls)\n const dimensionControls = convertDimensionsToControls(statics)\n const vitusLabsControls = getDefaultVitusLabsControls(component)\n\n const finalControls = {\n ...vitusLabsControls,\n ...createdControls,\n ...dimensionControls,\n }\n\n const storybookControls = makeStorybookControls(finalControls, defaultAttrs)\n\n // ------------------------------------------------------\n // CREATE DEFAULT STORY DESCRIPTION\n // ------------------------------------------------------\n const hasPseudo = storyOptions.pseudo === true\n\n let story = `This story renders all _options_ of the **${dimension}** dimension. `\n if (hasPseudo) {\n story += 'Including `pseudo` states.'\n }\n\n // ------------------------------------------------------\n // STORY COMPONENT\n // ------------------------------------------------------\n const revertedDirection =\n storyOptions.direction === 'rows' ? 'inline' : 'rows'\n const hasStoryOptions = !isEmpty(storyOptions)\n const WrapElement = hasStoryOptions ? Element : Fragment\n const wrapperProps = hasStoryOptions\n ? ({\n block: true,\n contentDirection: hasPseudo\n ? revertedDirection\n : storyOptions.direction,\n contentAlignX: storyOptions.alignX,\n contentAlignY: storyOptions.alignY,\n style: { gap: storyOptions.gap },\n } as const)\n : {}\n\n const innerGap = storyOptions.gap ? storyOptions.gap / 2 : 0\n\n const Enhanced: StoryComponent = (props) => (\n <WrapElement {...wrapperProps}>\n {Object.keys(currentDimension).map((item) => {\n const shouldBeIgnored = ignore.includes(item)\n const key = `${dimension}-${item}`\n\n const storyProps = {\n 'data-story': key,\n contentDirection: revertedDirection,\n contentAlignX: storyOptions.alignX,\n contentAlignY: storyOptions.alignY,\n style: { gap: innerGap },\n } as const\n\n // do not render ignored dimension keys\n if (shouldBeIgnored) return null\n\n if (storyOptions.pseudo === true) {\n return (\n <WrapElement key={key} contentDirection=\"rows\" contentAlignY=\"top\">\n <Heading\n level1\n label={item.charAt(0).toUpperCase() + item.slice(1)}\n />\n <WrapElement\n {...storyProps}\n contentDirection={storyOptions.direction}\n contentAlignY=\"top\"\n >\n <Provider component={component}>\n <PseudoList\n itemProps={{\n ...props,\n [dimension]: isMultiKey ? [item] : item,\n }}\n />\n </Provider>\n </WrapElement>\n </WrapElement>\n )\n }\n\n return (\n <WrapElement key={key} {...storyProps}>\n <Provider component={component}>\n <Item\n {...{\n ...props,\n [dimension]: isMultiKey ? [item] : item,\n }}\n />\n </Provider>\n </WrapElement>\n )\n })}\n </WrapElement>\n )\n\n Enhanced.args = finalAttrs\n Enhanced.argTypes = {\n ...storybookControls,\n ...disableDimensionControls(dimensions, dimension),\n }\n\n Enhanced.parameters = {\n docs: {\n description: {\n story,\n },\n source: {\n code: createJSXCodeArray(\n name,\n pick(finalAttrs, Object.keys(attrs)),\n dimension,\n currentDimension,\n useBooleans,\n isMultiKey,\n ),\n },\n },\n }\n\n return Enhanced\n}\n\nexport default renderDimension\n","/**\n * Extracts default boolean shorthand props from rocketstyle dimensions.\n * For each single-key dimension, picks the first value key and maps it\n * to `true`, enabling the boolean prop alternative in code snippets.\n * Returns null when useBooleans is disabled.\n */\ntype ExtractDefaultBooleanProps = (params: {\n dimensions: Record<string, any>\n multiKeys: Record<string, true>\n useBooleans?: boolean\n}) => Record<string, any> | null\n\n// eslint-disable-next-line import/prefer-default-export\nexport const extractDefaultBooleanProps: ExtractDefaultBooleanProps = ({\n dimensions,\n multiKeys,\n useBooleans,\n}) => {\n if (!useBooleans) return null\n\n return Object.entries(dimensions).reduce((acc, [key, value]) => {\n if (!multiKeys[key]) {\n const propName = Object.keys(value)[0] as string\n\n return { ...acc, [propName]: true }\n }\n\n return acc\n }, {})\n}\n","/**\n * Higher-order component factory for rocketstyle components.\n * Extracts dimension metadata and default attributes from the component's\n * static configuration, auto-generates Storybook controls for dimensions\n * and known Vitus Labs props, and attaches args/argTypes/parameters to the story.\n */\nimport { pick } from '@vitus-labs/core'\nimport type { RocketStoryConfiguration, StoryComponent } from '~/types'\nimport { generateMainJSXCode } from '~/utils/code'\nimport {\n convertDimensionsToControls,\n createControls,\n disableDimensionControls,\n getDefaultVitusLabsControls,\n makeStorybookControls,\n} from '~/utils/controls'\nimport { extractDefaultBooleanProps } from '~/utils/dimensions'\nimport getTheme from '~/utils/theme'\n\nexport type RocketStory<P = {}> = (\n WrappedComponent: any,\n) => (params: RocketStoryConfiguration) => StoryComponent<P>\n\nconst rocketStory: RocketStory =\n (WrappedComponent) =>\n ({ name, component, attrs, controls }) => {\n // ------------------------------------------------------\n // ROCKETSTYLE COMPONENT INFO\n // ------------------------------------------------------\n const theme = getTheme()\n const statics = component.getStaticDimensions(theme)\n const defaultAttrs = component.getDefaultAttrs(attrs, theme, 'light')\n const { dimensions, useBooleans, multiKeys } = statics\n\n const finalAttrs = { ...defaultAttrs, ...attrs }\n\n // ------------------------------------------------------\n // CONTROLS GENERATION\n // ------------------------------------------------------\n const createdControls = createControls(controls)\n const dimensionControls = convertDimensionsToControls(statics)\n const vitusLabsControls = getDefaultVitusLabsControls(component)\n\n const finalControls = {\n ...dimensionControls,\n ...vitusLabsControls,\n ...createdControls,\n }\n\n const storybookControls = makeStorybookControls(finalControls, defaultAttrs)\n\n // ------------------------------------------------------\n // CREATE DEFAULT STORY DESCRIPTION\n // ------------------------------------------------------\n const story = `This story is a showcase of a _${name}_ component`\n\n // ------------------------------------------------------\n // PROPS TO BE PASSED TO CODE GENERATION\n // ------------------------------------------------------\n // TODO\n\n // ------------------------------------------------------\n // STORY COMPONENT\n // ------------------------------------------------------\n const Enhanced = WrappedComponent(component)\n\n Enhanced.args = finalAttrs\n Enhanced.argTypes = {\n ...storybookControls,\n ...disableDimensionControls(dimensions),\n }\n\n Enhanced.parameters = {\n docs: {\n description: {\n story,\n },\n source: {\n code: generateMainJSXCode({\n name,\n dimensions: {},\n props: pick(finalAttrs, Object.keys(attrs)),\n booleanDimensions: extractDefaultBooleanProps({\n dimensions,\n multiKeys,\n useBooleans,\n }),\n }),\n },\n },\n }\n\n return Enhanced\n }\n\nexport default rocketStory\n","/**\n * Renders a list story for a rocketstyle component.\n * Accepts list configuration and wraps the component through RocketStoryHoc,\n * rendering it inside a Vitus Labs List element with auto-generated controls.\n */\n\nimport { List } from '@vitus-labs/elements'\nimport type { ComponentType } from 'react'\nimport RocketStoryHoc from '~/internal/RocketStoryHoc'\nimport type {\n ListStoryOptions,\n RocketStoryConfiguration,\n StoryComponent,\n} from '~/types'\n\nexport type RenderList<P = {}> = (\n render: ListStoryOptions,\n params: RocketStoryConfiguration,\n) => StoryComponent<P>\n\nexport default (list: ListStoryOptions) =>\n RocketStoryHoc(\n (component: ComponentType) => (props: Record<string, unknown>) => (\n <List\n rootElement={false}\n itemProps={props}\n {...list}\n component={component}\n />\n ),\n )\n","/**\n * Renders the main (default) story for a rocketstyle component.\n * Wraps the component through RocketStoryHoc to auto-generate dimension\n * controls and Vitus Labs-specific argTypes, then renders it with createElement.\n */\nimport { type ComponentType, createElement } from 'react'\nimport RocketStoryHoc from '~/internal/RocketStoryHoc'\n\nimport type { RocketStoryConfiguration, StoryComponent } from '~/types'\n\nexport type RenderMain<P = {}> = (\n params: RocketStoryConfiguration,\n) => StoryComponent<P>\n\nexport default RocketStoryHoc(\n (component: ComponentType) => (props: Record<string, unknown>) => (\n <>{createElement(component, props)}</>\n ),\n)\n","import type { FC } from 'react'\nimport RocketStoryHoc from '~/internal/RocketStoryHoc'\nimport type { RocketStoryConfiguration, StoryComponent } from '~/types'\n\nexport type RenderRender<P = {}> = (\n render: FC,\n params: RocketStoryConfiguration,\n) => StoryComponent<P>\n\nexport default (render: FC) => RocketStoryHoc(() => render)\n","import { get } from '@vitus-labs/core'\nimport { isRocketComponent } from '@vitus-labs/rocketstyle'\nimport * as simplestory from '~/stories/base'\nimport * as rocketstory from '~/stories/rocketstories'\nimport type {\n Configuration,\n Control,\n ExtractProps,\n ListStoryOptions,\n RenderStoryOptions,\n RocketType,\n TObj,\n} from '~/types'\n\n/**\n * Clones the current configuration, merges in new options,\n * and returns a fresh IRocketStories instance for immutable chaining.\n */\nconst cloneAndEhnance = (\n defaultOptions: Configuration,\n options: Partial<Configuration>,\n) => {\n const result = {\n ...defaultOptions,\n name: defaultOptions.name || options.name,\n prefix: options.prefix || defaultOptions.prefix,\n component: options.component || defaultOptions.component,\n attrs: { ...defaultOptions.attrs, ...options.attrs },\n storyOptions: { ...defaultOptions.storyOptions, ...options.storyOptions },\n controls: { ...defaultOptions.controls, ...options.controls },\n decorators: [\n ...(defaultOptions.decorators || []),\n ...(options.decorators || []),\n ],\n }\n\n const finalName = (result.name ||\n result.component.displayName ||\n get(result.component, 'name')) as string\n\n const finalStoryName = result.prefix\n ? `${result.prefix}/${finalName}`\n : finalName\n\n return createRocketStories({ ...result, name: finalStoryName })\n}\n\n/**\n * Chainable builder interface returned by the rocketstories factory.\n * Provides methods to generate Storybook stories (main, dimension, list, render)\n * and chainable configuration methods (attrs, controls, storyOptions, config, etc.).\n *\n * @typeParam OA - The component's own prop types\n * @typeParam RA - The rocketstyle dimension attributes (unknown for non-rocketstyle components)\n * @typeParam ISRS - Whether the wrapped component is a rocketstyle component\n */\nexport interface IRocketStories<\n OA extends TObj = {},\n RA extends TObj | unknown = unknown,\n ISRS extends boolean = false,\n> {\n CONFIG: Configuration\n\n // MAIN story\n // --------------------------------------------------------\n main: () => ISRS extends true\n ? ReturnType<rocketstory.RenderMain<OA>>\n : ReturnType<simplestory.RenderMain<OA>>\n\n // DIMENSION(S) story\n // --------------------------------------------------------\n dimension: <P extends keyof RA>(\n dimension: ISRS extends true ? P : never,\n options?: Partial<{ ignore: RA[P][] }>,\n ) => ReturnType<rocketstory.RenderDimension<OA>> | null\n\n // RENDER story\n // --------------------------------------------------------\n render: (\n params: RenderStoryOptions<OA>,\n ) => ISRS extends true\n ? ReturnType<rocketstory.RenderRender<OA>>\n : ReturnType<simplestory.RenderRender<OA>>\n\n // RENDER story\n // --------------------------------------------------------\n list: (\n params: ListStoryOptions,\n ) => ISRS extends true\n ? ReturnType<rocketstory.RenderList<OA>>\n : ReturnType<simplestory.RenderList<OA>>\n\n // INIT chaining method\n // --------------------------------------------------------\n init: () => {\n component: Configuration['component']\n title: Configuration['name']\n decorators: Configuration['decorators']\n }\n\n // STORY OPTIONS chaining method\n // --------------------------------------------------------\n storyOptions: (\n options: Configuration['storyOptions'],\n ) => IRocketStories<OA, RA, ISRS>\n\n controls: (\n options: Partial<{ [I in keyof OA]: Control }>,\n ) => IRocketStories<OA, RA, ISRS>\n\n // CONFIG chaining method\n // --------------------------------------------------------\n config: <P extends Partial<Omit<Configuration, 'attrs'>>>(\n params: P,\n ) => IRocketStories<OA, RA, ISRS>\n\n // ATTRS chaining method\n // --------------------------------------------------------\n attrs: <P extends Partial<OA>>(params: P) => IRocketStories<OA, RA, ISRS>\n\n // COMPONENT chaining method\n // --------------------------------------------------------\n replaceComponent: <P extends Configuration['component']>(\n param: P,\n ) => P extends RocketType\n ? IRocketStories<ExtractProps<P>, P['$$rocketstyle'], true>\n : IRocketStories<ExtractProps<P>, unknown, false>\n\n // COMPONENT chaining method\n // --------------------------------------------------------\n decorators: <P extends Configuration['decorators']>(\n param: P,\n ) => IRocketStories<OA, RA, ISRS>\n}\n\n/**\n * Core story generation pipeline. Takes a full Configuration object and returns\n * an IRocketStories builder. Delegates to rocketstory or simplestory renderers\n * depending on whether the component is a rocketstyle component.\n */\ntype CreateRocketStories = (options: Configuration) => IRocketStories\n// @ts-expect-error\nconst createRocketStories: CreateRocketStories = (options) => {\n const isRocket = isRocketComponent(options.component)\n\n return {\n CONFIG: options,\n // output methods\n main: () =>\n isRocket\n ? rocketstory.renderMain({\n ...options,\n component: options.component as RocketType,\n })\n : simplestory.renderMain(options),\n dimension: (dimension, params = {}) => {\n if (!isRocket) return null\n\n const { ignore = [] } = params\n\n return rocketstory.renderDimension(dimension, {\n ...options,\n component: options.component as RocketType,\n ignore,\n })\n },\n\n render: (renderer) =>\n isRocket\n ? rocketstory.renderRender(renderer)({\n ...options,\n component: options.component as RocketType,\n })\n : simplestory.renderRender(renderer)({\n ...options,\n component: options.component as RocketType,\n }),\n\n list: (params) =>\n isRocket\n ? rocketstory.renderList(params)({\n ...options,\n component: options.component as RocketType,\n })\n : simplestory.renderList(params)({\n ...options,\n component: options.component as RocketType,\n }),\n\n init: {\n component: options.component,\n title: options.name,\n decorators: options.decorators,\n },\n\n // chaining methods\n storyOptions: (storyOptions) => cloneAndEhnance(options, { storyOptions }),\n controls: (controls) => cloneAndEhnance(options, { controls }),\n\n config: ({ component, storyOptions, prefix, name, decorators }) =>\n cloneAndEhnance(options, {\n component,\n storyOptions,\n prefix,\n name,\n decorators,\n }),\n\n attrs: (attrs) => cloneAndEhnance(options, { attrs }),\n\n replaceComponent: (component) => cloneAndEhnance(options, { component }),\n\n decorators: (decorators) => cloneAndEhnance(options, { decorators }),\n }\n}\n\nexport default createRocketStories\n","import type { IRocketStories } from '~/rocketstories'\nimport createRocketStories from '~/rocketstories'\nimport type { Configuration, ExtractProps, RocketType } from '~/types'\n\n/**\n * Curried factory that accepts shared configuration options first,\n * then a component, producing a fully configured IRocketStories builder.\n * Useful for pre-configuring decorators or storyOptions across many stories.\n */\nexport type Init = <\n P extends Partial<Omit<Configuration, 'component' | 'attrs'>>,\n>(\n params: P,\n) => <T extends Configuration['component']>(\n component: T,\n) => T extends RocketType\n ? IRocketStories<ExtractProps<T>, T['$$rocketstyle'], true>\n : IRocketStories<ExtractProps<T>, unknown, false>\n\n/** @see {@link Init} */\nconst init: Init =\n ({ decorators = [], storyOptions = {}, ...rest }) =>\n (component) =>\n rocketstories(component, { decorators, storyOptions, ...rest })\n\n/**\n * One-shot factory that takes a component and optional configuration,\n * returning an IRocketStories builder with chainable methods for\n * generating Storybook stories, controls, and dimension showcases.\n */\nexport type Rocketstories = <C extends Configuration['component']>(\n component: C,\n options?: Partial<Omit<Configuration, 'component' | 'attrs'>>,\n) => C extends RocketType\n ? IRocketStories<ExtractProps<C>, C['$$rocketstyle'], true>\n : IRocketStories<ExtractProps<C>, unknown, false>\n\n/** @see {@link Rocketstories} */\n//@ts-expect-error\nconst rocketstories: Rocketstories = (component, options = {}) => {\n const { decorators = [], storyOptions = {} } = options\n\n const result: Configuration = {\n component,\n name: component.displayName || component.name,\n attrs: {},\n storyOptions: {\n gap: 16,\n direction: 'rows',\n alignY: 'top',\n alignX: 'left',\n ...storyOptions,\n },\n decorators,\n controls: {},\n }\n\n return createRocketStories(result)\n}\n\nexport { init, rocketstories }\n","import type { Init, Rocketstories } from '~/init'\nimport { init, rocketstories } from '~/init'\nimport type { IRocketStories } from '~/rocketstories'\nimport type {\n Configuration,\n Control,\n Controls,\n ControlTypes,\n ElementType,\n ExtractDimensions,\n ExtractProps,\n PartialControls,\n RocketStoryConfiguration,\n RocketType,\n StorybookControl,\n StoryComponent,\n StoryConfiguration,\n} from '~/types'\n\nexport type {\n IRocketStories,\n Init,\n Rocketstories,\n ExtractDimensions,\n ExtractProps,\n ElementType,\n StoryComponent,\n StorybookControl,\n RocketType,\n Configuration,\n RocketStoryConfiguration,\n StoryConfiguration,\n Control,\n ControlTypes,\n Controls,\n PartialControls,\n}\n\nexport { rocketstories, init }\nexport default init\n"],"mappings":";;;;;;;;;;;;;AAOA,MAAMA,UAAQ;AAEd,MAAM,gBAAgB;AACtB,MAAM,aAAa;AACnB,MAAM,aAAa;AACnB,MAAM,UAAU;AAEhB,MAAM,YAAY;CAChB;CACA,MAAM;CACN,SAAS,CAAC,SAAS,GAAG,cAAc,MAAM,MAAM,CAAC;CACjD,OAAO;CACP,WAAW,GAAG,cAAc,oBAAoB,cAAc,YAAY;CAC3E;AAED,MAAM,UAAU;CACd;CACA,MAAM;CACN,SAAS,WAAW,MAAM,MAAM;CAChC,OAAO;CACP,WAAW,GAAG,WAAW,oBAAoB,WAAW,YAAY;CACrE;AAED,MAAM,UAAU;CACd;CACA,MAAM;CACN,SAAS,WAAW,MAAM,MAAM;CAChC,OAAO;CACP,WAAW,GAAG,WAAW,oBAAoB,WAAW,YAAY;CACrE;AAED,MAAM,MAAM;CACV;CACA,MAAM;CACN,WAAW,GAAG,QAAQ,mBAAmB,QAAQ,YAAY,QAAQ;CACtE;AAED,wBAAe;CACb,KAAK;EACH;EACA,MAAM;EACN,SAAS;EACT,WAAW;EACX,aAAa;EACd;CACD,UAAU;EACR;EACA,MAAM;EACN,WAAW;EACX,aACE;EACH;CACD,SAAS;EACP;EACA,MAAM;EACN,WAAW;EACX,aACE;EACH;CACD,OAAO;EACL;EACA,MAAM;EACN,WAAW;EACX,aACE;EACH;CACD,OAAO;EACL;EACA,MAAM;EACN,WAAW;EACX,aACE;EACH;CACD,WAAW;EACT,GAAG;EACH,OAAO;EACP,aACE;EACH;CACD,QAAQ;EACN,GAAG;EACH,aACE;EACH;CACD,QAAQ;EACN,GAAG;EACH,aACE;EACH;CACD,kBAAkB;EAChB,GAAG;EACH,aACE;EACH;CACD,eAAe;EACb,GAAG;EACH,aACE;EACH;CACD,eAAe;EACb,GAAG;EACH,aACE;EACH;CACD,wBAAwB;EACtB,GAAG;EACH,aACE;EACH;CACD,qBAAqB;EACnB,GAAG;EACH,aACE;EACH;CACD,qBAAqB;EACnB,GAAG;EACH,aACE;EACH;CACD,uBAAuB;EACrB,GAAG;EACH,aACE;EACH;CACD,oBAAoB;EAClB,GAAG;EACH,aACE;EACH;CACD,oBAAoB;EAClB,GAAG;EACH,aACE;EACH;CACD,WAAW;EACT,MAAM;EACN;EACA,WAAW;EACX,aACE;EACH;CACD,KAAK;EACH,MAAM;EACN;EACA,WAAW;EACX,aACE;EACH;CAQD,eAAe;EACb;EACA,MAAM;EACN,WAAW;EACX,aAAa;EACd;CACD,cAAc;EACZ;EACA,MAAM;EACN,WAAW;EACX,aAAa;EACd;CACD,KAAK;EACH,GAAG;EACH,aACE;EACH;CACD,YAAY;EACV,GAAG;EACH,aACE;EACH;CACD,kBAAkB;EAChB,GAAG;EACH,aACE;EACH;CACD,iBAAiB;EACf,GAAG;EACH,aACE;EACH;CACD,KAAK;EACH;EACA,aAAa;EACb,WAAW;EACZ;CACD,UAAU;EACR;EACA,aAAa;EACb,WAAW;EACZ;CACD,yBAAyB;EACvB;EACA,MAAM;EACN,SAAS;EACT,WAAW;EACZ;CACF;;;;;;;;;AC7MD,MAAMC,UAAQ;AAEd,MAAM,gBAAgB;AAEtB,mBAAe;CACb,aAAa;EACX;EACA,MAAM;EACN,WAAW;EACX,aACE;EACH;CACD,MAAM;EACJ;EACA,MAAM;EACN,WAAW;EACX,aACE;EACH;CACD,WAAW;EACT;EACA,MAAM;EACN,WAAW;EACX,aACE;EACH;CACD,WAAW;EACT;EACA,WAAW;EACX,aACE;EACH;CACD,WAAW;EACT;EACA,WAAW;EACX,aACE;EACH;CACD,SAAS;EACP;EACA,WAAW;EACX,aACE;EACH;CACD,WAAW;EACT;EACA,MAAM;EACN,WAAW;EAC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,CAAC;EAE9D,SAAS,EAAE,WAAW,cAAc,QAAQ,MAAM,iBAChD,gBAAgB,SAAS;GACvB;GACA;GACA;GACA;GACA;GACD,CAAC;EAEJ,QAAQ,UAAU,gBAAgB,SAAS,EAAE,OAAO,CAAC;EAErD,mBAAmB,cAAc,gBAAgB,SAAS,EAAE,WAAW,CAAC;EAExE,aAAa,eAAe,gBAAgB,SAAS,EAAE,YAAY,CAAC;EACrE;;;;;;ACjMH,MAAM,QACH,EAAE,aAAa,EAAE,EAAE,eAAe,EAAE,EAAE,GAAG,YACzC,cACC,cAAc,WAAW;CAAE;CAAY;CAAc,GAAG;CAAM,CAAC;;AAgBnE,MAAM,iBAAgC,WAAW,UAAU,EAAE,KAAK;CAChE,MAAM,EAAE,aAAa,EAAE,EAAE,eAAe,EAAE,KAAK;AAiB/C,QAAO,oBAfuB;EAC5B;EACA,MAAM,UAAU,eAAe,UAAU;EACzC,OAAO,EAAE;EACT,cAAc;GACZ,KAAK;GACL,WAAW;GACX,QAAQ;GACR,QAAQ;GACR,GAAG;GACJ;EACD;EACA,UAAU,EAAE;EACb,CAEiC;;;;;AClBpC,kBAAe"}
1
+ {"version":3,"file":"index.js","names":["group","group","group","group","CONTROLS.ELEMENT_CONTROLS","CONTROLS.LIST_CONTROLS","CONTROLS.TEXT_CONTROLS","CONTROLS.OVERLAY_CONTROLS","CONTROLS.ROCKETSTYLE_CONTROLS","StoryHoc","StoryHoc","StoryHoc","element","component","useContext","contextHook","component","useContext","Heading","Item","component","NotFound","Fragment","Heading","PseudoList","Item","RocketStoryHoc","RocketStoryHoc","RocketStoryHoc","rocketstory.renderMain","simplestory.renderMain","rocketstory.renderDimension","rocketstory.renderRender","simplestory.renderRender","rocketstory.renderList","simplestory.renderList"],"sources":["../src/controls/element.ts","../src/controls/list.ts","../src/controls/overlay.ts","../src/controls/rocketstyle.ts","../src/controls/text.ts","../src/utils/controls.ts","../src/internal/StoryHoc.tsx","../src/stories/base/renderList.tsx","../src/stories/base/renderMain.tsx","../src/stories/base/renderRender.tsx","../src/components/base/element.ts","../src/components/base/Heading.ts","../src/components/NotFound.tsx","../src/utils/code.ts","../src/utils/theme.ts","../src/stories/rocketstories/renderDimension/context.tsx","../src/stories/rocketstories/renderDimension/components/Item.tsx","../src/stories/rocketstories/renderDimension/components/PseudoList.tsx","../src/stories/rocketstories/renderDimension/index.tsx","../src/utils/dimensions.ts","../src/internal/RocketStoryHoc.tsx","../src/stories/rocketstories/renderList.tsx","../src/stories/rocketstories/renderMain.tsx","../src/stories/rocketstories/renderRender.tsx","../src/rocketstories.tsx","../src/init.ts","../src/index.ts"],"sourcesContent":["/**\n * Default Storybook control definitions for Element-based components.\n * Covers layout props (direction, alignX, alignY), content slots\n * (beforeContent, afterContent), CSS extension props, and HTML tag selection.\n */\nimport { HTML_TAGS } from '@vitus-labs/core'\n\nconst group = 'Element (Vitus-Labs)'\n\nconst directionType = 'inline | rows | reverseRows | reverseInline'\nconst alignXType = 'left | center | right | block | spaceBetween | spaceAround'\nconst alignYType = 'top | center | block | spaceBetween | spaceAround'\nconst CssType = 'string | (css) => css`` | css``'\n\nconst DIRECTION = {\n group,\n type: 'select',\n options: ['-----', ...directionType.split(' | ')],\n value: 'rows',\n valueType: `${directionType} | Record<string, ${directionType}> | Array<${directionType}`,\n}\n\nconst ALIGN_X = {\n group,\n type: 'select',\n options: alignXType.split(' | '),\n value: 'left',\n valueType: `${alignXType} | Record<string, ${alignXType}> | Array<${alignXType}`,\n}\n\nconst ALIGN_Y = {\n group,\n type: 'select',\n options: alignYType.split(' | '),\n value: 'center',\n valueType: `${alignYType} | Record<string, ${alignYType}> | Array<${alignYType}`,\n}\n\nconst CSS = {\n group,\n type: 'text',\n valueType: `${CssType} | Record<string,${CssType}> | Array<${CssType}>`,\n}\n\nexport default {\n tag: {\n group,\n type: 'select',\n options: HTML_TAGS,\n valueType: 'HTMLTag',\n description: 'A prop which will change **HTML tag** of the element.',\n },\n children: {\n group,\n type: '',\n valueType: 'ReactNode',\n description:\n 'React children. Priorities when rendering are **children** → **content** → **label**, therefore _children_ has the highest priority.',\n },\n content: {\n group,\n type: 'text',\n valueType: 'ReactNode',\n description:\n 'A prop which can be used instead of _children_. Priorities when rendering are **children** → **content** → **label**, therefore _content_ has the middle priority.',\n },\n label: {\n group,\n type: 'text',\n valueType: 'ReactNode',\n description:\n 'A prop which can be used instead of _children_. Priorities when rendering are **children** → **content** → **label**, therefore _label_ has the lowest priority.',\n },\n block: {\n group,\n type: 'boolean',\n valueType: 'boolean | Record<string, boolean> | Array<boolean>',\n description:\n 'Defines whether should behave as **inline** or **block** element.',\n },\n direction: {\n ...DIRECTION,\n value: undefined,\n description:\n 'Define whether element should render **horizontally** or **vertically**.',\n },\n alignX: {\n ...ALIGN_X,\n description:\n 'Define alignment of **beforeContent**, **content**, and **afterContent** with respect to root element on **axis X**.',\n },\n alignY: {\n ...ALIGN_Y,\n description:\n 'Define alignment of **beforeContent**, **content**, and **afterContent** with respect to the root element on **axis Y**.',\n },\n contentDirection: {\n ...DIRECTION,\n description:\n 'Define whether the children in **content** wrapper should be rendered in _line_ or in _rows_.',\n },\n contentAlignX: {\n ...ALIGN_X,\n description:\n 'Define how the children in **content** wrapper should be aligned on **axis X**.',\n },\n contentAlignY: {\n ...ALIGN_Y,\n description:\n 'Define how the children in **content** wrapper should be aligned on **axis Y**.',\n },\n beforeContentDirection: {\n ...DIRECTION,\n description:\n 'Define whether children in **beforeContent** wrapper should be rendered in _line_ or in _rows_.',\n },\n beforeContentAlignX: {\n ...ALIGN_X,\n description:\n 'Define how children in **beforeContent** wrapper should be aligned on **axis X**.',\n },\n beforeContentAlignY: {\n ...ALIGN_Y,\n description:\n 'Define how children in **beforeContent** wrapper should be aligned on **axis Y**.',\n },\n afterContentDirection: {\n ...DIRECTION,\n description:\n 'Define whether children in **afterContent** wrapper should be rendered in _line_ or in _rows_.',\n },\n afterContentAlignX: {\n ...ALIGN_X,\n description:\n 'Define how children in **afterContent** wrapper should be aligned on **axis X**.',\n },\n afterContentAlignY: {\n ...ALIGN_Y,\n description:\n 'Define how children in **afterContent** wrapper should be aligned on **axis Y**.',\n },\n equalCols: {\n type: 'boolean',\n group,\n valueType: 'boolean | Record<string,boolean> | Array<boolean>',\n description:\n 'Whether should all inner elements have the same `width` / `height`.',\n },\n gap: {\n type: 'number',\n group,\n valueType: 'number | Record<string,number> | Array<number>',\n description:\n 'Defines space gap **between** _beforeContent_, _content_ and _afterContent_ if one of _beforeContent_ or _afterContent_ contain _children_ to be rendered.',\n },\n // vertical: {\n // type: 'boolean',\n // group,\n // valueType: 'boolean | Record<string,boolean> | Array<boolean>',\n // description:\n // 'Define whether element should render horizontally or vertically.',\n // },\n beforeContent: {\n group,\n type: '',\n valueType: 'ReactNode',\n description: 'A children to be rendered inside `beforeContent` wrapper.',\n },\n afterContent: {\n group,\n type: '',\n valueType: 'ReactNode',\n description: 'A children to be rendered inside `afterContent` wrapper.',\n },\n css: {\n ...CSS,\n description:\n 'An additional styling prop to enhance the **root** element CSS styles.',\n },\n contentCss: {\n ...CSS,\n description:\n 'An additional styling prop to enhance the **content** element CSS styles.',\n },\n beforeContentCss: {\n ...CSS,\n description:\n 'An additional styling prop to enhance the **beforeContent** element CSS styles.',\n },\n afterContentCss: {\n ...CSS,\n description:\n 'An additional styling prop to enhance the **afterContent** element CSS styles.',\n },\n ref: {\n group,\n description: 'A React ref',\n valueType: 'ForwardedRef<any>',\n },\n innerRef: {\n group,\n description: 'A React ref',\n valueType: 'ForwardedRef<any>',\n },\n dangerouslySetInnerHTML: {\n group,\n type: 'text',\n disable: true,\n valueType: 'any',\n },\n}\n","/**\n * Default Storybook control definitions for List-based components.\n * Covers data input, item/wrap component props, key extraction,\n * and disables label/content controls that do not apply to lists.\n */\nconst group = 'List (@vitus-labs)'\n\nconst itemPropsType = `Record<string, any> | (props, meta) => Record<string,any>`\n\nexport default {\n rootElement: {\n group,\n type: 'boolean',\n valueType: 'boolean',\n description:\n 'Whether a **root** element should be rendered or the output should be just a type of React **Fragment**.',\n },\n data: {\n group,\n type: 'array',\n valueType: 'string[] | number[] | object[]',\n description:\n 'An array of item values to be passed to item component. Data are being passed to _component_ prop element.',\n },\n valueName: {\n group,\n type: 'text',\n valueType: `string`,\n description:\n 'Is required when **data** consists of **strings** or **numbers** to name value being passed as a prop.',\n },\n itemProps: {\n group,\n valueType: itemPropsType,\n description:\n 'A customizable hook for dynamically render props for each **item** component.',\n },\n wrapProps: {\n group,\n valueType: itemPropsType,\n description:\n 'A customizable hook for dynamically render props for each **wrapComponent** when _wrapComponent_ is passed, otherwise ignored.',\n },\n itemKey: {\n group,\n valueType: 'string | `(item, i) => number | string`',\n description:\n \"Prop for defining item key in list. **name** / **value** if default behavior doesn't work out.\",\n },\n component: {\n group,\n type: 'component',\n valueType: 'ComponentType',\n description:\n 'A component to be rendered within the List per item. Receives props from _data_ array props.',\n },\n wrapComponent: {\n group,\n type: 'component',\n valueType: `ComponentType`,\n description:\n 'A component to be used as a wrapper component for each item component.',\n },\n label: {\n disable: true,\n },\n content: {\n disable: true,\n },\n} as const\n","const group = 'Overlay (Vitus-Labs)'\n\nexport default {\n refName: {\n type: 'text',\n value: 'ref',\n description:\n \"Overlay component access **ref** to directly mutate styles when calculation position to prevent re-renders. It's being used for both `trigger`, and `children` element at the same time. Your components must accept refs with the same naming.\",\n group,\n },\n triggerRefName: {\n type: 'text',\n description:\n 'A key name how a **ref** should be passed to trigger component',\n group,\n },\n contentRefName: {\n type: 'text',\n description:\n 'A key name how a **ref** should be passed to content component',\n group,\n },\n isOpen: {\n type: 'boolean',\n value: false,\n description: '',\n group,\n },\n openOn: {\n type: 'select',\n options: ['click', 'hover'],\n value: 'click',\n description: '',\n group,\n },\n closeOn: {\n type: 'select',\n options: ['click', 'triggerClick', 'hover', 'manual'],\n value: 'click',\n description: '',\n group,\n },\n type: {\n type: 'select',\n options: ['dropdown', 'tooltip', 'popover', 'modal'],\n value: 'dropdown',\n description: '',\n group,\n },\n align: {\n type: 'select',\n options: ['top', 'left', 'bottom', 'right'],\n value: 'bottom',\n description: '',\n group,\n },\n alignX: {\n type: 'select',\n options: ['left', 'center', 'right'],\n value: 'left',\n description: '',\n group,\n },\n alignY: {\n type: 'select',\n options: ['top', 'center', 'bottom'],\n value: 'bottom',\n description: '',\n group,\n },\n position: {\n type: 'select',\n options: ['fixed', 'absolute', 'relative', 'static'],\n value: 'fixed',\n description: '',\n group,\n },\n offsetX: {\n type: 'number',\n value: 0,\n description: '',\n group,\n },\n offsetY: {\n type: 'number',\n value: 0,\n description: '',\n group,\n },\n throttleDelay: {\n type: 'number',\n value: 200,\n description: '',\n group,\n },\n children: {\n description: 'A content to be rendered when Overlay is open',\n },\n} as const\n","/**\n * Default Storybook control definitions for rocketstyle pseudo-state props.\n * Provides boolean toggles for hover, active, pressed, and focus states,\n * as well as descriptions for their corresponding mouse/focus event handlers.\n */\nconst group = 'Rocketstyle (Vitus-Labs)'\n\nexport default {\n hover: {\n group,\n type: 'boolean',\n value: false,\n description:\n 'Can be manually triggered **hover** event on the element. Behaves as **:hover** state in _CSS_.',\n },\n active: {\n group,\n type: 'boolean',\n value: false,\n description:\n 'Can be manually triggered **active** event on the element. Can be used to define element as `active`, e.g. _links_.',\n },\n pressed: {\n group,\n type: 'boolean',\n value: false,\n description:\n 'Can be manually triggered **pressed** event on the element. Behaves as `:active` state in _CSS_.',\n },\n focus: {\n group,\n type: 'boolean',\n value: false,\n description:\n 'Can be manually triggered **focus** event on the element. Behaves as `:focus` state in _CSS_.',\n },\n onMouseEnter: {\n group,\n type: 'function',\n description:\n 'The _onMouseEnter_ function can take a `SyntheticMouseEvent`.',\n },\n onMouseLeave: {\n group,\n type: 'function',\n description:\n 'The _onMouseLeave_ function can take a `SyntheticMouseEvent.`',\n },\n onMouseDown: {\n group,\n type: 'function',\n description: 'The _onMouseDown_ function can take a `SyntheticMouseEvent`.',\n },\n onMouseUp: {\n group,\n type: 'function',\n description: 'The _onMouseUp_ function can take a `SyntheticMouseEvent`.',\n },\n onFocus: {\n group,\n type: 'function',\n description: 'The _onFocus_ function can take a `SyntheticFocusEvent`.',\n },\n onBlur: {\n group,\n type: 'function',\n description: 'The _onBlur_ function can take a `SyntheticFocusEvent`.',\n },\n} as const\n","/**\n * Default Storybook control definitions for Text-based components.\n * Provides controls for paragraph mode, HTML tag selection, children/label\n * content, and CSS extension.\n */\nimport { HTML_TAGS } from '@vitus-labs/core'\n\nconst group = 'Text (Vitus-Labs)'\n\nexport default {\n paragraph: {\n group,\n type: 'boolean',\n description:\n 'Changes a behavior of inline text to become **block** text. Also changes HTML **tag** to `p`',\n },\n tag: {\n group,\n type: 'select',\n options: HTML_TAGS,\n },\n children: {\n group,\n type: '',\n valueType: 'ReactNode',\n description:\n 'React children. Priorities when rendering are **children** → **label**, therefore _children_ has the highest priority.',\n },\n label: {\n group,\n type: 'text',\n valueType: 'ReactNode',\n description:\n 'A prop which can be used instead of _children_. Priorities when rendering are **children** → **label**, therefore _label_ has lower priority than _children_.',\n },\n extendCss: {\n group,\n type: 'text',\n description:\n 'An additional styling prop to enhance Text element CSS styles.',\n },\n} as const\n","/**\n * Utilities for creating, converting, and formatting Storybook controls.\n * Handles transformation from rocketstories control definitions to the\n * Storybook argTypes format, including dimension-based select controls\n * and component-specific default controls.\n */\nimport * as CONTROLS from '~/controls'\nimport type {\n ControlConfiguration,\n Controls,\n RocketType,\n StorybookControl,\n} from '~/types'\n\n/** Normalizes user-supplied control shorthand (string or object) into full ControlConfiguration objects. */\nexport const createControls = (props: Record<string, any>) =>\n Object.entries(props).reduce<Record<string, any>>((acc, [key, value]) => {\n if (typeof value === 'string') {\n return {\n ...acc,\n [key]: {\n type: value,\n },\n }\n }\n\n if (typeof value === 'object' && value !== null) {\n return { ...acc, [key]: value }\n }\n\n return acc\n }, {})\n\ntype ConvertDimensionsToControls = ({\n dimensions,\n multiKeys,\n}: {\n dimensions: Record<string, any>\n multiKeys: Record<string, true>\n}) => Controls\n\n/** Converts rocketstyle dimension metadata into select/multi-select Storybook controls. */\nexport const convertDimensionsToControls: ConvertDimensionsToControls = ({\n dimensions,\n multiKeys,\n}) =>\n Object.entries(dimensions).reduce((acc, [key, value]) => {\n const valueKeys = Object.keys(value)\n const isMultiKey = !!multiKeys[key]\n\n const control = {\n type: isMultiKey ? 'multi-select' : 'select',\n options: valueKeys,\n group: 'Dimensions [Rocketstyle (Vitus-Labs)]',\n }\n\n return { ...acc, [key]: control }\n }, {})\n\n// --------------------------------------------------------\n// values to controls\n// --------------------------------------------------------\ntype GetDefaultVitusLabsControls = (component: RocketType) => Controls\n\n/** Returns pre-defined controls based on the component's Vitus Labs type (Element, List, Text, Overlay). */\nexport const getDefaultVitusLabsControls: GetDefaultVitusLabsControls = (\n component,\n) => {\n const { IS_ROCKETSTYLE, VITUS_LABS__COMPONENT } = component\n\n const IS_ELEMENT = VITUS_LABS__COMPONENT === '@vitus-labs/elements/Element'\n const IS_LIST = VITUS_LABS__COMPONENT === '@vitus-labs/elements/List'\n const IS_TEXT = VITUS_LABS__COMPONENT === '@vitus-labs/elements/Text'\n const IS_OVERLAY = VITUS_LABS__COMPONENT === '@vitus-labs/elements/Overlay'\n\n const result = {\n ...(IS_ELEMENT || IS_LIST ? CONTROLS.ELEMENT_CONTROLS : {}),\n\n ...(IS_LIST ? CONTROLS.LIST_CONTROLS : {}),\n\n ...(IS_TEXT ? CONTROLS.TEXT_CONTROLS : {}),\n\n ...(IS_OVERLAY ? CONTROLS.OVERLAY_CONTROLS : {}),\n\n ...(IS_ROCKETSTYLE ? CONTROLS.ROCKETSTYLE_CONTROLS : {}),\n }\n\n return result as Controls\n}\n\n/** Transforms internal control definitions into the Storybook argTypes format with table metadata. */\ntype MakeStorybookControls = (\n obj: Record<string, ControlConfiguration>,\n props: Record<string, any>,\n) => Record<string, StorybookControl>\n\nexport const makeStorybookControls: MakeStorybookControls = (obj, props) =>\n Object.entries(obj).reduce<Record<string, StorybookControl>>(\n (acc, [key, control]) => {\n const defaultValue =\n typeof props[key] !== 'function' ? props[key] : undefined\n\n if (control.disable) {\n acc[key] = {\n table: {\n disable: control.disable,\n },\n }\n } else {\n acc[key] = {\n control: { type: control.type ?? 'text' },\n description: control.description,\n options: control.options /* || CONTROL_OPTIONS[control.type] */,\n table: {\n defaultValue: {\n summary: defaultValue || control.value,\n },\n disable: control.disable,\n category: control.group /* || CONTROL_TYPES_GROUPS[control.type] */,\n type: {\n summary: control.valueType,\n },\n },\n }\n }\n\n return acc\n },\n {},\n )\n\n// --------------------------------------------------------\n// disableControl\n// --------------------------------------------------------\ntype DisableControl = (\n name: string,\n) => Record<string, { table: { disable: true } }>\n\nconst disableControl: DisableControl = (name) => ({\n [name]: { table: { disable: true } },\n})\n\n/** Produces argType overrides that hide individual dimension value keys from the controls panel. */\ntype DisableDimensionControls = (\n dimensions: Record<string, boolean>,\n name?: string,\n) => any\n\nexport const disableDimensionControls: DisableDimensionControls = (\n dimensions,\n dimensionName,\n) => {\n const result = dimensionName ? disableControl(dimensionName) : {}\n const dimensionKeys = Object.values(dimensions)\n\n return dimensionKeys.reduce((acc, value) => {\n Object.keys(value).forEach((item) => {\n acc = { ...acc, ...disableControl(item) }\n })\n\n return acc\n }, result)\n}\n","/**\n * Higher-order component factory for regular (non-rocketstyle) components.\n * Converts user-defined controls into Storybook argTypes and attaches\n * args and argTypes to the returned story component.\n */\nimport type { StoryComponent, StoryConfiguration } from '~/types'\nimport { createControls, makeStorybookControls } from '~/utils/controls'\n\nexport type Story<P = {}> = (\n WrappedComponent: any,\n) => (params: StoryConfiguration) => StoryComponent<P>\n\nconst story: Story =\n (WrappedComponent) =>\n ({ component, attrs, controls }) => {\n // ------------------------------------------------------\n // CONTROLS GENERATION\n // ------------------------------------------------------\n const createdControls = createControls(controls)\n\n const finalControls = createdControls\n const storybookControls = makeStorybookControls(finalControls, attrs)\n\n const Enhanced = WrappedComponent(component)\n\n Enhanced.args = attrs\n Enhanced.argTypes = storybookControls\n\n return Enhanced\n }\n\nexport default story\n","/**\n * Renders a list story for a regular non-rocketstyle component.\n * Accepts list configuration (data, itemKey, etc.) and wraps the component\n * through StoryHoc, rendering it inside a Vitus Labs List element.\n */\n\nimport { List } from '@vitus-labs/elements'\nimport type { ComponentType } from 'react'\nimport StoryHoc from '~/internal/StoryHoc'\nimport type {\n ListStoryOptions,\n RocketStoryConfiguration,\n StoryComponent,\n} from '~/types'\n\nexport type RenderList<P = {}> = (\n render: ListStoryOptions,\n params: RocketStoryConfiguration,\n) => StoryComponent<P>\n\nexport default (list: ListStoryOptions) =>\n StoryHoc((component: ComponentType) => (props: Record<string, unknown>) => (\n <List\n rootElement={false}\n {...list}\n itemProps={props}\n component={component}\n />\n ))\n","/**\n * Renders the main (default) story for a regular non-rocketstyle component.\n * Wraps the component through StoryHoc to attach Storybook controls, then\n * renders it with createElement using the current args.\n */\nimport { type ComponentType, createElement } from 'react'\nimport StoryHoc from '~/internal/StoryHoc'\n\nimport type { RocketStoryConfiguration, StoryComponent } from '~/types'\n\nexport type RenderMain<P = {}> = (\n params: RocketStoryConfiguration,\n) => StoryComponent<P>\n\nexport default StoryHoc(\n (component: ComponentType) => (props: Record<string, unknown>) => (\n <>{createElement(component, props)}</>\n ),\n)\n","import type { FC } from 'react'\nimport StoryHoc from '~/internal/StoryHoc'\nimport type { RocketStoryConfiguration, StoryComponent } from '~/types'\n\nexport type RenderRender<P = {}> = (\n render: FC,\n params: RocketStoryConfiguration,\n) => StoryComponent<P>\n\nexport default (render: FC) => StoryHoc(() => render)\n","/**\n * Base rocketstyle element used internally by rocketstories for\n * layout wrappers and story containers. Applies a default Arial\n * font family via the theme and renders unistyle-based CSS.\n */\nimport { Element } from '@vitus-labs/elements'\nimport rocketstyle from '@vitus-labs/rocketstyle'\nimport { styles } from '@vitus-labs/unistyle'\n\nexport default rocketstyle()({\n component: Element,\n name: 'element',\n})\n .theme({\n fontFamily: 'Arial',\n })\n .styles(\n (css) => css<any>`\n ${({ $rocketstyle }) => {\n const baseTheme = styles({ theme: $rocketstyle, css, rootSize: 16 })\n\n return css`\n ${baseTheme};\n `\n }};\n `,\n )\n","/**\n * Heading component built on the base element. Renders as an h1 tag\n * and provides two size variants: level1 (20px) and level2 (16px).\n * Used for labeling dimension items and pseudo-state groups in stories.\n */\nimport element from './element'\n\nexport default element.attrs({ tag: 'h1', block: true }).sizes({\n level1: {\n fontSize: 20,\n },\n level2: {\n marginTop: 0,\n fontSize: 16,\n },\n})\n","/**\n * Empty placeholder component displayed when a requested dimension\n * has no values or the story cannot be rendered.\n */\nimport { config } from '@vitus-labs/core'\nimport type { FC } from 'react'\n\nconst Wrapper = config.styled.div`\n display: flex;\n font-size: 32px;\n`\n\nconst component: FC = () => <Wrapper>Nothing here</Wrapper>\n\ncomponent.displayName = '@vitus-labs/rocketstories/Empty'\n\nexport default component\n","import { get } from '@vitus-labs/core'\nimport type { Control, Obj, SimpleValue } from '~/types'\n\n// --------------------------------------------------------\n// parseProps\n// --------------------------------------------------------\ntype ObjValue = Control\n\ntype ParseProps = <\n T extends Record<string, SimpleValue | SimpleValue[] | ObjValue>,\n>(\n props: T,\n) => Record<keyof T, unknown>\n\nconst parseProps: ParseProps = (props) =>\n Object.entries(props).reduce((acc, [key, value]) => {\n if (value === null) return acc\n\n const valueType = typeof value\n\n if (['string', 'number', 'boolean', 'bigint'].includes(valueType)) {\n return { ...acc, [key]: value }\n }\n\n if (Array.isArray(value)) {\n return { ...acc, [key]: value }\n }\n\n if (valueType === 'object') {\n const type = get(value, 'type')\n const options = get(value, 'options')\n const defaultValue = get(value, 'value')\n\n // if has custom knobs configuration\n if (type && options && defaultValue) {\n return { ...acc, [key]: defaultValue || options }\n }\n\n return { ...acc, [key]: value }\n }\n\n return acc\n }, {} as any)\n\n// --------------------------------------------------------\n// stringifyArray\n// --------------------------------------------------------\ntype StringifyArray = (props: unknown[]) => string\n\nconst stringifyArray: StringifyArray = (props) => {\n let result = '['\n\n const arrayLength = props.length\n\n result += props.reduce((acc, value, i) => {\n if (Array.isArray(value)) {\n // TODO: parse arrays\n acc += `${stringifyArray(value)}`\n } else if (typeof value === 'object' && value !== null) {\n acc += `${stringifyObject(value as Record<string, any>)}`\n } else if (['number', 'string'].includes(typeof value)) {\n acc += `\"${value}\"`\n } else {\n acc += `${value}`\n }\n\n // if not last item, add comma and space\n if (arrayLength !== i + 1) {\n acc += `, `\n }\n\n return acc\n }, '')\n\n result += ']'\n\n return result\n}\n\n// --------------------------------------------------------\n// stringifyObject\n// --------------------------------------------------------\ntype StringifyObject = (props: Obj) => string\n\nconst stringifyObject: StringifyObject = (props) => {\n let result = '{ '\n\n const propsArray = Object.entries(props)\n const arrayLength = propsArray.length\n\n result += propsArray.reduce((acc, [key, value], i) => {\n if (Array.isArray(value)) {\n // TODO: parse arrays\n acc += `${key}: ${value}`\n } else if (typeof value === 'object' && value !== null) {\n acc += `${key}: ${stringifyObject(value)}`\n } else if (['string'].includes(typeof value)) {\n acc += `${key}: \"${value}\"`\n } else {\n acc += `${key}: ${value}`\n }\n\n if (arrayLength !== i + 1) {\n acc += `, `\n }\n\n return acc\n }, '')\n\n result += ' }'\n\n return result\n}\n\n// --------------------------------------------------------\n// stringifyObject\n// --------------------------------------------------------\ntype StringifyProps = (props: Obj) => string\n\nconst stringifyProps: StringifyProps = (props) => {\n const parsedProps = parseProps(props)\n const arrayProps = Object.entries(parsedProps)\n const arrayLength = arrayProps.length\n\n return arrayProps.reduce((acc, [key, value], i) => {\n if (typeof value === 'boolean') {\n if (value === true) acc += `${key}`\n else acc += `${key}=${value}`\n } else if (\n ['string', 'number'].includes(typeof value) ||\n value === null ||\n value === undefined\n ) {\n acc += `${key}=\"${value}\"`\n } else if (Array.isArray(value)) {\n acc += `${key}={${stringifyArray(value)}}`\n } else if (typeof value === 'object' && value !== null) {\n acc += `${key}={${stringifyObject(value as Record<string, any>)}}`\n }\n\n if (arrayLength !== i + 1) {\n acc += ' '\n }\n\n return acc\n }, '')\n}\n\nconst parseComponentName = (name: string) => {\n const helper = name.split('/')\n\n if (helper.length > 1) {\n return helper[helper.length - 1]\n }\n\n return name\n}\n\n/**\n * Generates a single self-closing JSX tag string for the given component\n * name and props, e.g. `<Button primary size=\"large\" />`.\n */\ntype CreateJSXCode = (name: string, props: Obj) => string\n\nexport const createJSXCode: CreateJSXCode = (name, props) =>\n `<${parseComponentName(name)} ${stringifyProps(props)} />`\n\n// --------------------------------------------------------\n// createJSXCodeArray\n// --------------------------------------------------------\ntype CreateJSXCodeArray = (\n name: string,\n props: Obj,\n dimensionName: string,\n dimensions: Obj,\n useBooleans: boolean,\n isMultiKey: boolean,\n) => string\n\nexport const createJSXCodeArray: CreateJSXCodeArray = (\n name,\n props,\n dimensionName,\n dimensions,\n useBooleans,\n isMultiKey,\n) => {\n if (!dimensions) return `// nothing here`\n\n let result = ''\n\n const finalProps = { ...props }\n delete finalProps[dimensionName]\n\n result += Object.keys(dimensions).reduce((acc, key) => {\n acc += createJSXCode(name, {\n [dimensionName]: isMultiKey ? [key] : key,\n ...finalProps,\n })\n acc += `\\n`\n return acc\n }, '')\n\n if (useBooleans) {\n result += `\\n\\n`\n result += `// Or alternatively use boolean ${dimensionName} props (${Object.keys(\n dimensions,\n ).toString()})`\n result += `\\n`\n\n result += Object.keys(dimensions).reduce((acc, key) => {\n acc += createJSXCode(name, { [key]: true, ...finalProps })\n acc += `\\n`\n return acc\n }, '')\n }\n\n return result\n}\n\nconst addBooleanCodeComment = (values: string[]) => {\n let result = `\\n\\n`\n result += `// Or alternatively use boolean props (e.g. ${values})`\n result += `\\n`\n\n return result\n}\n\n/**\n * Generates the JSX code snippet shown in the Storybook docs panel for the\n * main story. Includes the primary JSX tag and, when boolean dimension\n * shorthand is available, an alternative boolean-prop usage example.\n */\ntype GenerateMainJSXCode = (params: {\n name: string\n props: Record<string, string>\n dimensions: Record<string, string>\n booleanDimensions: any\n}) => any\n\nexport const generateMainJSXCode: GenerateMainJSXCode = ({\n name,\n props,\n dimensions,\n booleanDimensions,\n}) => {\n let result = createJSXCode(name, { ...dimensions, ...props })\n\n if (booleanDimensions) {\n const keys = Object.keys(booleanDimensions)\n result += addBooleanCodeComment(keys)\n result += createJSXCode(name, { ...booleanDimensions, ...props })\n }\n\n return result\n}\n","/**\n * Retrieves the current theme object from the global\n * `window.__VITUS_LABS_STORIES__` store, which is populated\n * by the Storybook preview configuration at startup.\n */\ndeclare global {\n interface Window {\n __VITUS_LABS_STORIES__: {\n decorators: {\n theme: Record<string, unknown>\n }\n }\n }\n}\n\ntype GetTheme = () => Record<string, unknown>\nconst getTheme: GetTheme = () => window.__VITUS_LABS_STORIES__.decorators.theme\n\nexport default getTheme\n","/**\n * React context for the dimension story renderer. Provides the wrapped\n * rocketstyle component reference to nested Item and PseudoList components\n * so they can render it without prop-drilling.\n */\nimport {\n type ComponentType,\n useContext as contextHook,\n createContext,\n type FC,\n type ReactNode,\n} from 'react'\n\ntype Context = {\n component: ComponentType\n}\n\nexport const context = createContext<Context>({} as Context)\n\nexport const useContext = () => contextHook(context)\n\nconst ContextProvider = context.Provider\n\nconst Provider: FC<Context & { children: ReactNode }> = ({\n children,\n ...props\n}) => <ContextProvider value={props}>{children}</ContextProvider>\n\nexport default Provider\n","/**\n * Renders a single dimension value item within a dimension story.\n * Retrieves the component from context and renders it with the given\n * props, optionally prefixed by a level2 Heading showing the item title.\n */\nimport { createElement, type FC } from 'react'\nimport { Heading } from '~/components/base'\nimport { useContext } from '../context'\n\ntype Props = {\n title?: string\n} & { [key: string]: any }\n\nconst component: FC<Props> = ({ title, ...props }) => {\n const { component } = useContext()\n\n return (\n <div>\n {title && <Heading level2 label={title} />}\n {createElement(component, props)}\n </div>\n )\n}\n\nexport default component\n","/**\n * Renders a list of pseudo-state variations (base, hover, pressed, active)\n * for a single dimension value. Each pseudo state is rendered as an Item\n * with the corresponding pseudo prop set to true.\n */\nimport type { FC } from 'react'\nimport Item from './Item'\n\nconst pseudo = ['base', 'hover', 'pressed', 'active'] as const\n\ntype Props = {\n itemProps: Record<string, any>\n}\n\nconst component: FC<Props> = ({ itemProps }) => (\n <>\n {pseudo.map((item) => {\n const pseudoProps = { [item]: true }\n\n return <Item key={item} title={item} {...itemProps} {...pseudoProps} />\n })}\n </>\n)\n\nexport default component\n","/**\n * Renders a dimension story for a rocketstyle component. Iterates over all\n * values of the specified dimension and renders each as an Item (or a\n * PseudoList when pseudo-state visualization is enabled). Generates\n * corresponding JSX code snippets and Storybook controls.\n */\nimport { isEmpty, pick } from '@vitus-labs/core'\nimport { Element } from '@vitus-labs/elements'\nimport { Fragment } from 'react'\nimport { Heading } from '~/components/base'\nimport NotFound from '~/components/NotFound'\nimport type {\n RocketDimensions,\n RocketStoryConfiguration,\n StoryComponent,\n} from '~/types'\nimport { createJSXCodeArray } from '~/utils/code'\nimport {\n convertDimensionsToControls,\n createControls,\n disableDimensionControls,\n getDefaultVitusLabsControls,\n makeStorybookControls,\n} from '~/utils/controls'\nimport getTheme from '~/utils/theme'\nimport Item from './components/Item'\nimport PseudoList from './components/PseudoList'\nimport Provider from './context'\n\nexport type RenderDimension<P = {}> = (\n dimension: RocketDimensions,\n params: RocketStoryConfiguration & {\n ignore: any\n },\n) => StoryComponent<P>\n\nconst renderDimension: RenderDimension = (\n dimension,\n { name, component, attrs = {}, controls, storyOptions = {}, ignore = [] },\n) => {\n // ------------------------------------------------------\n // ROCKETSTYLE COMPONENT INFO\n // ------------------------------------------------------\n const theme = getTheme()\n const statics = component.getStaticDimensions(theme)\n const defaultAttrs = component.getDefaultAttrs(attrs, theme, 'light')\n const { dimensions, useBooleans, multiKeys } = statics\n\n const finalAttrs = { ...defaultAttrs, ...attrs }\n\n // ------------------------------------------------------\n // CURRENT ROCKETSTYLE DIMENSION INFO\n // ------------------------------------------------------\n const currentDimension = dimensions[dimension]\n const isMultiKey = !!multiKeys[dimension]\n\n // ------------------------------------------------------\n // RENDER EMPTY PAGE WHEN DIMENSION IS NOT AVAILABLE\n // ------------------------------------------------------\n const DONT_RENDER = isEmpty(currentDimension)\n if (DONT_RENDER) return NotFound\n\n // ------------------------------------------------------\n // CONTROLS GENERATION\n // ------------------------------------------------------\n const createdControls = createControls(controls)\n const dimensionControls = convertDimensionsToControls(statics)\n const vitusLabsControls = getDefaultVitusLabsControls(component)\n\n const finalControls = {\n ...vitusLabsControls,\n ...createdControls,\n ...dimensionControls,\n }\n\n const storybookControls = makeStorybookControls(finalControls, defaultAttrs)\n\n // ------------------------------------------------------\n // CREATE DEFAULT STORY DESCRIPTION\n // ------------------------------------------------------\n const hasPseudo = storyOptions.pseudo === true\n\n let story = `This story renders all _options_ of the **${dimension}** dimension. `\n if (hasPseudo) {\n story += 'Including `pseudo` states.'\n }\n\n // ------------------------------------------------------\n // STORY COMPONENT\n // ------------------------------------------------------\n const revertedDirection =\n storyOptions.direction === 'rows' ? 'inline' : 'rows'\n const hasStoryOptions = !isEmpty(storyOptions)\n const WrapElement = hasStoryOptions ? Element : Fragment\n const wrapperProps = hasStoryOptions\n ? ({\n block: true,\n contentDirection: hasPseudo\n ? revertedDirection\n : storyOptions.direction,\n contentAlignX: storyOptions.alignX,\n contentAlignY: storyOptions.alignY,\n style: { gap: storyOptions.gap },\n } as const)\n : {}\n\n const innerGap = storyOptions.gap ? storyOptions.gap / 2 : 0\n\n const Enhanced: StoryComponent = (props) => (\n <WrapElement {...wrapperProps}>\n {Object.keys(currentDimension).map((item) => {\n const shouldBeIgnored = ignore.includes(item)\n const key = `${dimension}-${item}`\n\n const storyProps = {\n 'data-story': key,\n contentDirection: revertedDirection,\n contentAlignX: storyOptions.alignX,\n contentAlignY: storyOptions.alignY,\n style: { gap: innerGap },\n } as const\n\n // do not render ignored dimension keys\n if (shouldBeIgnored) return null\n\n if (storyOptions.pseudo === true) {\n return (\n <WrapElement key={key} contentDirection=\"rows\" contentAlignY=\"top\">\n <Heading\n level1\n label={item.charAt(0).toUpperCase() + item.slice(1)}\n />\n <WrapElement\n {...storyProps}\n contentDirection={storyOptions.direction}\n contentAlignY=\"top\"\n >\n <Provider component={component}>\n <PseudoList\n itemProps={{\n ...props,\n [dimension]: isMultiKey ? [item] : item,\n }}\n />\n </Provider>\n </WrapElement>\n </WrapElement>\n )\n }\n\n return (\n <WrapElement key={key} {...storyProps}>\n <Provider component={component}>\n <Item\n {...{\n ...props,\n [dimension]: isMultiKey ? [item] : item,\n }}\n />\n </Provider>\n </WrapElement>\n )\n })}\n </WrapElement>\n )\n\n Enhanced.args = finalAttrs\n Enhanced.argTypes = {\n ...storybookControls,\n ...disableDimensionControls(dimensions, dimension),\n }\n\n Enhanced.parameters = {\n docs: {\n description: {\n story,\n },\n source: {\n code: createJSXCodeArray(\n name,\n pick(finalAttrs, Object.keys(attrs)),\n dimension,\n currentDimension,\n useBooleans,\n isMultiKey,\n ),\n },\n },\n }\n\n return Enhanced\n}\n\nexport default renderDimension\n","/**\n * Extracts default boolean shorthand props from rocketstyle dimensions.\n * For each single-key dimension, picks the first value key and maps it\n * to `true`, enabling the boolean prop alternative in code snippets.\n * Returns null when useBooleans is disabled.\n */\ntype ExtractDefaultBooleanProps = (params: {\n dimensions: Record<string, any>\n multiKeys: Record<string, true>\n useBooleans?: boolean\n}) => Record<string, any> | null\n\nexport const extractDefaultBooleanProps: ExtractDefaultBooleanProps = ({\n dimensions,\n multiKeys,\n useBooleans,\n}) => {\n if (!useBooleans) return null\n\n return Object.entries(dimensions).reduce((acc, [key, value]) => {\n if (!multiKeys[key]) {\n const propName = Object.keys(value)[0] as string\n\n return { ...acc, [propName]: true }\n }\n\n return acc\n }, {})\n}\n","/**\n * Higher-order component factory for rocketstyle components.\n * Extracts dimension metadata and default attributes from the component's\n * static configuration, auto-generates Storybook controls for dimensions\n * and known Vitus Labs props, and attaches args/argTypes/parameters to the story.\n */\nimport { pick } from '@vitus-labs/core'\nimport type { RocketStoryConfiguration, StoryComponent } from '~/types'\nimport { generateMainJSXCode } from '~/utils/code'\nimport {\n convertDimensionsToControls,\n createControls,\n disableDimensionControls,\n getDefaultVitusLabsControls,\n makeStorybookControls,\n} from '~/utils/controls'\nimport { extractDefaultBooleanProps } from '~/utils/dimensions'\nimport getTheme from '~/utils/theme'\n\nexport type RocketStory<P = {}> = (\n WrappedComponent: any,\n) => (params: RocketStoryConfiguration) => StoryComponent<P>\n\nconst rocketStory: RocketStory =\n (WrappedComponent) =>\n ({ name, component, attrs, controls }) => {\n // ------------------------------------------------------\n // ROCKETSTYLE COMPONENT INFO\n // ------------------------------------------------------\n const theme = getTheme()\n const statics = component.getStaticDimensions(theme)\n const defaultAttrs = component.getDefaultAttrs(attrs, theme, 'light')\n const { dimensions, useBooleans, multiKeys } = statics\n\n const finalAttrs = { ...defaultAttrs, ...attrs }\n\n // ------------------------------------------------------\n // CONTROLS GENERATION\n // ------------------------------------------------------\n const createdControls = createControls(controls)\n const dimensionControls = convertDimensionsToControls(statics)\n const vitusLabsControls = getDefaultVitusLabsControls(component)\n\n const finalControls = {\n ...dimensionControls,\n ...vitusLabsControls,\n ...createdControls,\n }\n\n const storybookControls = makeStorybookControls(finalControls, defaultAttrs)\n\n // ------------------------------------------------------\n // CREATE DEFAULT STORY DESCRIPTION\n // ------------------------------------------------------\n const story = `This story is a showcase of a _${name}_ component`\n\n // ------------------------------------------------------\n // PROPS TO BE PASSED TO CODE GENERATION\n // ------------------------------------------------------\n // TODO\n\n // ------------------------------------------------------\n // STORY COMPONENT\n // ------------------------------------------------------\n const Enhanced = WrappedComponent(component)\n\n Enhanced.args = finalAttrs\n Enhanced.argTypes = {\n ...storybookControls,\n ...disableDimensionControls(dimensions),\n }\n\n Enhanced.parameters = {\n docs: {\n description: {\n story,\n },\n source: {\n code: generateMainJSXCode({\n name,\n dimensions: {},\n props: pick(finalAttrs, Object.keys(attrs)),\n booleanDimensions: extractDefaultBooleanProps({\n dimensions,\n multiKeys,\n useBooleans,\n }),\n }),\n },\n },\n }\n\n return Enhanced\n }\n\nexport default rocketStory\n","/**\n * Renders a list story for a rocketstyle component.\n * Accepts list configuration and wraps the component through RocketStoryHoc,\n * rendering it inside a Vitus Labs List element with auto-generated controls.\n */\n\nimport { List } from '@vitus-labs/elements'\nimport type { ComponentType } from 'react'\nimport RocketStoryHoc from '~/internal/RocketStoryHoc'\nimport type {\n ListStoryOptions,\n RocketStoryConfiguration,\n StoryComponent,\n} from '~/types'\n\nexport type RenderList<P = {}> = (\n render: ListStoryOptions,\n params: RocketStoryConfiguration,\n) => StoryComponent<P>\n\nexport default (list: ListStoryOptions) =>\n RocketStoryHoc(\n (component: ComponentType) => (props: Record<string, unknown>) => (\n <List\n rootElement={false}\n itemProps={props}\n {...list}\n component={component}\n />\n ),\n )\n","/**\n * Renders the main (default) story for a rocketstyle component.\n * Wraps the component through RocketStoryHoc to auto-generate dimension\n * controls and Vitus Labs-specific argTypes, then renders it with createElement.\n */\nimport { type ComponentType, createElement } from 'react'\nimport RocketStoryHoc from '~/internal/RocketStoryHoc'\n\nimport type { RocketStoryConfiguration, StoryComponent } from '~/types'\n\nexport type RenderMain<P = {}> = (\n params: RocketStoryConfiguration,\n) => StoryComponent<P>\n\nexport default RocketStoryHoc(\n (component: ComponentType) => (props: Record<string, unknown>) => (\n <>{createElement(component, props)}</>\n ),\n)\n","import type { FC } from 'react'\nimport RocketStoryHoc from '~/internal/RocketStoryHoc'\nimport type { RocketStoryConfiguration, StoryComponent } from '~/types'\n\nexport type RenderRender<P = {}> = (\n render: FC,\n params: RocketStoryConfiguration,\n) => StoryComponent<P>\n\nexport default (render: FC) => RocketStoryHoc(() => render)\n","import { get } from '@vitus-labs/core'\nimport { isRocketComponent } from '@vitus-labs/rocketstyle'\nimport * as simplestory from '~/stories/base'\nimport * as rocketstory from '~/stories/rocketstories'\nimport type {\n Configuration,\n Control,\n ExtractProps,\n ListStoryOptions,\n RenderStoryOptions,\n RocketType,\n TObj,\n} from '~/types'\n\n/**\n * Clones the current configuration, merges in new options,\n * and returns a fresh IRocketStories instance for immutable chaining.\n */\nconst cloneAndEhnance = (\n defaultOptions: Configuration,\n options: Partial<Configuration>,\n) => {\n const result = {\n ...defaultOptions,\n name: defaultOptions.name || options.name,\n prefix: options.prefix || defaultOptions.prefix,\n component: options.component || defaultOptions.component,\n attrs: { ...defaultOptions.attrs, ...options.attrs },\n storyOptions: { ...defaultOptions.storyOptions, ...options.storyOptions },\n controls: { ...defaultOptions.controls, ...options.controls },\n decorators: [\n ...(defaultOptions.decorators || []),\n ...(options.decorators || []),\n ],\n }\n\n const finalName = (result.name ||\n result.component.displayName ||\n get(result.component, 'name')) as string\n\n const finalStoryName = result.prefix\n ? `${result.prefix}/${finalName}`\n : finalName\n\n return createRocketStories({ ...result, name: finalStoryName })\n}\n\n/**\n * Chainable builder interface returned by the rocketstories factory.\n * Provides methods to generate Storybook stories (main, dimension, list, render)\n * and chainable configuration methods (attrs, controls, storyOptions, config, etc.).\n *\n * @typeParam OA - The component's own prop types\n * @typeParam RA - The rocketstyle dimension attributes (unknown for non-rocketstyle components)\n * @typeParam ISRS - Whether the wrapped component is a rocketstyle component\n */\nexport interface IRocketStories<\n OA extends TObj = {},\n RA extends TObj | unknown = unknown,\n ISRS extends boolean = false,\n> {\n CONFIG: Configuration\n\n // MAIN story\n // --------------------------------------------------------\n main: () => ISRS extends true\n ? ReturnType<rocketstory.RenderMain<OA>>\n : ReturnType<simplestory.RenderMain<OA>>\n\n // DIMENSION(S) story\n // --------------------------------------------------------\n dimension: <P extends keyof RA>(\n dimension: ISRS extends true ? P : never,\n options?: Partial<{ ignore: RA[P][] }>,\n ) => ReturnType<rocketstory.RenderDimension<OA>> | null\n\n // RENDER story\n // --------------------------------------------------------\n render: (\n params: RenderStoryOptions<OA>,\n ) => ISRS extends true\n ? ReturnType<rocketstory.RenderRender<OA>>\n : ReturnType<simplestory.RenderRender<OA>>\n\n // RENDER story\n // --------------------------------------------------------\n list: (\n params: ListStoryOptions,\n ) => ISRS extends true\n ? ReturnType<rocketstory.RenderList<OA>>\n : ReturnType<simplestory.RenderList<OA>>\n\n // INIT chaining method\n // --------------------------------------------------------\n init: () => {\n component: Configuration['component']\n title: Configuration['name']\n decorators: Configuration['decorators']\n }\n\n // STORY OPTIONS chaining method\n // --------------------------------------------------------\n storyOptions: (\n options: Configuration['storyOptions'],\n ) => IRocketStories<OA, RA, ISRS>\n\n controls: (\n options: Partial<{ [I in keyof OA]: Control }>,\n ) => IRocketStories<OA, RA, ISRS>\n\n // CONFIG chaining method\n // --------------------------------------------------------\n config: <P extends Partial<Omit<Configuration, 'attrs'>>>(\n params: P,\n ) => IRocketStories<OA, RA, ISRS>\n\n // ATTRS chaining method\n // --------------------------------------------------------\n attrs: <P extends Partial<OA>>(params: P) => IRocketStories<OA, RA, ISRS>\n\n // COMPONENT chaining method\n // --------------------------------------------------------\n replaceComponent: <P extends Configuration['component']>(\n param: P,\n ) => P extends RocketType\n ? IRocketStories<ExtractProps<P>, P['$$rocketstyle'], true>\n : IRocketStories<ExtractProps<P>, unknown, false>\n\n // COMPONENT chaining method\n // --------------------------------------------------------\n decorators: <P extends Configuration['decorators']>(\n param: P,\n ) => IRocketStories<OA, RA, ISRS>\n}\n\n/**\n * Core story generation pipeline. Takes a full Configuration object and returns\n * an IRocketStories builder. Delegates to rocketstory or simplestory renderers\n * depending on whether the component is a rocketstyle component.\n */\ntype CreateRocketStories = (options: Configuration) => IRocketStories\n// @ts-expect-error\nconst createRocketStories: CreateRocketStories = (options) => {\n const isRocket = isRocketComponent(options.component)\n\n return {\n CONFIG: options,\n // output methods\n main: () =>\n isRocket\n ? rocketstory.renderMain({\n ...options,\n component: options.component as RocketType,\n })\n : simplestory.renderMain(options),\n dimension: (dimension, params = {}) => {\n if (!isRocket) return null\n\n const { ignore = [] } = params\n\n return rocketstory.renderDimension(dimension, {\n ...options,\n component: options.component as RocketType,\n ignore,\n })\n },\n\n render: (renderer) =>\n isRocket\n ? rocketstory.renderRender(renderer)({\n ...options,\n component: options.component as RocketType,\n })\n : simplestory.renderRender(renderer)({\n ...options,\n component: options.component as RocketType,\n }),\n\n list: (params) =>\n isRocket\n ? rocketstory.renderList(params)({\n ...options,\n component: options.component as RocketType,\n })\n : simplestory.renderList(params)({\n ...options,\n component: options.component as RocketType,\n }),\n\n init: {\n component: options.component,\n title: options.name,\n decorators: options.decorators,\n },\n\n // chaining methods\n storyOptions: (storyOptions) => cloneAndEhnance(options, { storyOptions }),\n controls: (controls) => cloneAndEhnance(options, { controls }),\n\n config: ({ component, storyOptions, prefix, name, decorators }) =>\n cloneAndEhnance(options, {\n component,\n storyOptions,\n prefix,\n name,\n decorators,\n }),\n\n attrs: (attrs) => cloneAndEhnance(options, { attrs }),\n\n replaceComponent: (component) => cloneAndEhnance(options, { component }),\n\n decorators: (decorators) => cloneAndEhnance(options, { decorators }),\n }\n}\n\nexport default createRocketStories\n","import type { IRocketStories } from '~/rocketstories'\nimport createRocketStories from '~/rocketstories'\nimport type { Configuration, ExtractProps, RocketType } from '~/types'\n\n/**\n * Curried factory that accepts shared configuration options first,\n * then a component, producing a fully configured IRocketStories builder.\n * Useful for pre-configuring decorators or storyOptions across many stories.\n */\nexport type Init = <\n P extends Partial<Omit<Configuration, 'component' | 'attrs'>>,\n>(\n params: P,\n) => <T extends Configuration['component']>(\n component: T,\n) => T extends RocketType\n ? IRocketStories<ExtractProps<T>, T['$$rocketstyle'], true>\n : IRocketStories<ExtractProps<T>, unknown, false>\n\n/** @see {@link Init} */\nconst init: Init =\n ({ decorators = [], storyOptions = {}, ...rest }) =>\n (component) =>\n rocketstories(component, { decorators, storyOptions, ...rest })\n\n/**\n * One-shot factory that takes a component and optional configuration,\n * returning an IRocketStories builder with chainable methods for\n * generating Storybook stories, controls, and dimension showcases.\n */\nexport type Rocketstories = <C extends Configuration['component']>(\n component: C,\n options?: Partial<Omit<Configuration, 'component' | 'attrs'>>,\n) => C extends RocketType\n ? IRocketStories<ExtractProps<C>, C['$$rocketstyle'], true>\n : IRocketStories<ExtractProps<C>, unknown, false>\n\n/** @see {@link Rocketstories} */\n//@ts-expect-error\nconst rocketstories: Rocketstories = (component, options = {}) => {\n const { decorators = [], storyOptions = {} } = options\n\n const result: Configuration = {\n component,\n name: component.displayName || component.name,\n attrs: {},\n storyOptions: {\n gap: 16,\n direction: 'rows',\n alignY: 'top',\n alignX: 'left',\n ...storyOptions,\n },\n decorators,\n controls: {},\n }\n\n return createRocketStories(result)\n}\n\nexport { init, rocketstories }\n","import type { Init, Rocketstories } from '~/init'\nimport { init, rocketstories } from '~/init'\nimport type { IRocketStories } from '~/rocketstories'\nimport type {\n Configuration,\n Control,\n Controls,\n ControlTypes,\n ElementType,\n ExtractDimensions,\n ExtractProps,\n PartialControls,\n RocketStoryConfiguration,\n RocketType,\n StorybookControl,\n StoryComponent,\n StoryConfiguration,\n} from '~/types'\n\nexport type {\n IRocketStories,\n Init,\n Rocketstories,\n ExtractDimensions,\n ExtractProps,\n ElementType,\n StoryComponent,\n StorybookControl,\n RocketType,\n Configuration,\n RocketStoryConfiguration,\n StoryConfiguration,\n Control,\n ControlTypes,\n Controls,\n PartialControls,\n}\n\nexport { rocketstories, init }\nexport default init\n"],"mappings":";;;;;;;;;;;;;AAOA,MAAMA,UAAQ;AAEd,MAAM,gBAAgB;AACtB,MAAM,aAAa;AACnB,MAAM,aAAa;AACnB,MAAM,UAAU;AAEhB,MAAM,YAAY;CAChB;CACA,MAAM;CACN,SAAS,CAAC,SAAS,GAAG,cAAc,MAAM,MAAM,CAAC;CACjD,OAAO;CACP,WAAW,GAAG,cAAc,oBAAoB,cAAc,YAAY;CAC3E;AAED,MAAM,UAAU;CACd;CACA,MAAM;CACN,SAAS,WAAW,MAAM,MAAM;CAChC,OAAO;CACP,WAAW,GAAG,WAAW,oBAAoB,WAAW,YAAY;CACrE;AAED,MAAM,UAAU;CACd;CACA,MAAM;CACN,SAAS,WAAW,MAAM,MAAM;CAChC,OAAO;CACP,WAAW,GAAG,WAAW,oBAAoB,WAAW,YAAY;CACrE;AAED,MAAM,MAAM;CACV;CACA,MAAM;CACN,WAAW,GAAG,QAAQ,mBAAmB,QAAQ,YAAY,QAAQ;CACtE;AAED,wBAAe;CACb,KAAK;EACH;EACA,MAAM;EACN,SAAS;EACT,WAAW;EACX,aAAa;EACd;CACD,UAAU;EACR;EACA,MAAM;EACN,WAAW;EACX,aACE;EACH;CACD,SAAS;EACP;EACA,MAAM;EACN,WAAW;EACX,aACE;EACH;CACD,OAAO;EACL;EACA,MAAM;EACN,WAAW;EACX,aACE;EACH;CACD,OAAO;EACL;EACA,MAAM;EACN,WAAW;EACX,aACE;EACH;CACD,WAAW;EACT,GAAG;EACH,OAAO;EACP,aACE;EACH;CACD,QAAQ;EACN,GAAG;EACH,aACE;EACH;CACD,QAAQ;EACN,GAAG;EACH,aACE;EACH;CACD,kBAAkB;EAChB,GAAG;EACH,aACE;EACH;CACD,eAAe;EACb,GAAG;EACH,aACE;EACH;CACD,eAAe;EACb,GAAG;EACH,aACE;EACH;CACD,wBAAwB;EACtB,GAAG;EACH,aACE;EACH;CACD,qBAAqB;EACnB,GAAG;EACH,aACE;EACH;CACD,qBAAqB;EACnB,GAAG;EACH,aACE;EACH;CACD,uBAAuB;EACrB,GAAG;EACH,aACE;EACH;CACD,oBAAoB;EAClB,GAAG;EACH,aACE;EACH;CACD,oBAAoB;EAClB,GAAG;EACH,aACE;EACH;CACD,WAAW;EACT,MAAM;EACN;EACA,WAAW;EACX,aACE;EACH;CACD,KAAK;EACH,MAAM;EACN;EACA,WAAW;EACX,aACE;EACH;CAQD,eAAe;EACb;EACA,MAAM;EACN,WAAW;EACX,aAAa;EACd;CACD,cAAc;EACZ;EACA,MAAM;EACN,WAAW;EACX,aAAa;EACd;CACD,KAAK;EACH,GAAG;EACH,aACE;EACH;CACD,YAAY;EACV,GAAG;EACH,aACE;EACH;CACD,kBAAkB;EAChB,GAAG;EACH,aACE;EACH;CACD,iBAAiB;EACf,GAAG;EACH,aACE;EACH;CACD,KAAK;EACH;EACA,aAAa;EACb,WAAW;EACZ;CACD,UAAU;EACR;EACA,aAAa;EACb,WAAW;EACZ;CACD,yBAAyB;EACvB;EACA,MAAM;EACN,SAAS;EACT,WAAW;EACZ;CACF;;;;;;;;;AC7MD,MAAMC,UAAQ;AAEd,MAAM,gBAAgB;AAEtB,mBAAe;CACb,aAAa;EACX;EACA,MAAM;EACN,WAAW;EACX,aACE;EACH;CACD,MAAM;EACJ;EACA,MAAM;EACN,WAAW;EACX,aACE;EACH;CACD,WAAW;EACT;EACA,MAAM;EACN,WAAW;EACX,aACE;EACH;CACD,WAAW;EACT;EACA,WAAW;EACX,aACE;EACH;CACD,WAAW;EACT;EACA,WAAW;EACX,aACE;EACH;CACD,SAAS;EACP;EACA,WAAW;EACX,aACE;EACH;CACD,WAAW;EACT;EACA,MAAM;EACN,WAAW;EACX,aACE;EACH;CACD,eAAe;EACb;EACA,MAAM;EACN,WAAW;EACX,aACE;EACH;CACD,OAAO,EACL,SAAS,MACV;CACD,SAAS,EACP,SAAS,MACV;CACF;;;;ACrED,MAAMC,UAAQ;AAEd,sBAAe;CACb,SAAS;EACP,MAAM;EACN,OAAO;EACP,aACE;EACF;EACD;CACD,gBAAgB;EACd,MAAM;EACN,aACE;EACF;EACD;CACD,gBAAgB;EACd,MAAM;EACN,aACE;EACF;EACD;CACD,QAAQ;EACN,MAAM;EACN,OAAO;EACP,aAAa;EACb;EACD;CACD,QAAQ;EACN,MAAM;EACN,SAAS,CAAC,SAAS,QAAQ;EAC3B,OAAO;EACP,aAAa;EACb;EACD;CACD,SAAS;EACP,MAAM;EACN,SAAS;GAAC;GAAS;GAAgB;GAAS;GAAS;EACrD,OAAO;EACP,aAAa;EACb;EACD;CACD,MAAM;EACJ,MAAM;EACN,SAAS;GAAC;GAAY;GAAW;GAAW;GAAQ;EACpD,OAAO;EACP,aAAa;EACb;EACD;CACD,OAAO;EACL,MAAM;EACN,SAAS;GAAC;GAAO;GAAQ;GAAU;GAAQ;EAC3C,OAAO;EACP,aAAa;EACb;EACD;CACD,QAAQ;EACN,MAAM;EACN,SAAS;GAAC;GAAQ;GAAU;GAAQ;EACpC,OAAO;EACP,aAAa;EACb;EACD;CACD,QAAQ;EACN,MAAM;EACN,SAAS;GAAC;GAAO;GAAU;GAAS;EACpC,OAAO;EACP,aAAa;EACb;EACD;CACD,UAAU;EACR,MAAM;EACN,SAAS;GAAC;GAAS;GAAY;GAAY;GAAS;EACpD,OAAO;EACP,aAAa;EACb;EACD;CACD,SAAS;EACP,MAAM;EACN,OAAO;EACP,aAAa;EACb;EACD;CACD,SAAS;EACP,MAAM;EACN,OAAO;EACP,aAAa;EACb;EACD;CACD,eAAe;EACb,MAAM;EACN,OAAO;EACP,aAAa;EACb;EACD;CACD,UAAU,EACR,aAAa,iDACd;CACF;;;;;;;;;AC7FD,MAAMC,UAAQ;AAEd,0BAAe;CACb,OAAO;EACL;EACA,MAAM;EACN,OAAO;EACP,aACE;EACH;CACD,QAAQ;EACN;EACA,MAAM;EACN,OAAO;EACP,aACE;EACH;CACD,SAAS;EACP;EACA,MAAM;EACN,OAAO;EACP,aACE;EACH;CACD,OAAO;EACL;EACA,MAAM;EACN,OAAO;EACP,aACE;EACH;CACD,cAAc;EACZ;EACA,MAAM;EACN,aACE;EACH;CACD,cAAc;EACZ;EACA,MAAM;EACN,aACE;EACH;CACD,aAAa;EACX;EACA,MAAM;EACN,aAAa;EACd;CACD,WAAW;EACT;EACA,MAAM;EACN,aAAa;EACd;CACD,SAAS;EACP;EACA,MAAM;EACN,aAAa;EACd;CACD,QAAQ;EACN;EACA,MAAM;EACN,aAAa;EACd;CACF;;;;;;;;;AC7DD,MAAM,QAAQ;AAEd,mBAAe;CACb,WAAW;EACT;EACA,MAAM;EACN,aACE;EACH;CACD,KAAK;EACH;EACA,MAAM;EACN,SAAS;EACV;CACD,UAAU;EACR;EACA,MAAM;EACN,WAAW;EACX,aACE;EACH;CACD,OAAO;EACL;EACA,MAAM;EACN,WAAW;EACX,aACE;EACH;CACD,WAAW;EACT;EACA,MAAM;EACN,aACE;EACH;CACF;;;;;;;;;;;AC1BD,MAAa,kBAAkB,UAC7B,OAAO,QAAQ,MAAM,CAAC,QAA6B,KAAK,CAAC,KAAK,WAAW;AACvE,KAAI,OAAO,UAAU,SACnB,QAAO;EAC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pB,CAAC;EAER,OAAO,WACL,WACIC,mBAAuB,OAAO,CAAC;GAC7B,GAAG;GACH,WAAW,QAAQ;GACpB,CAAC,GACFC,qBAAuB,OAAO,CAAC;GAC7B,GAAG;GACH,WAAW,QAAQ;GACpB,CAAC;EAER,MAAM;GACJ,WAAW,QAAQ;GACnB,OAAO,QAAQ;GACf,YAAY,QAAQ;GACrB;EAGD,eAAe,iBAAiB,gBAAgB,SAAS,EAAE,cAAc,CAAC;EAC1E,WAAW,aAAa,gBAAgB,SAAS,EAAE,UAAU,CAAC;EAE9D,SAAS,EAAE,WAAW,cAAc,QAAQ,MAAM,iBAChD,gBAAgB,SAAS;GACvB;GACA;GACA;GACA;GACA;GACD,CAAC;EAEJ,QAAQ,UAAU,gBAAgB,SAAS,EAAE,OAAO,CAAC;EAErD,mBAAmB,cAAc,gBAAgB,SAAS,EAAE,WAAW,CAAC;EAExE,aAAa,eAAe,gBAAgB,SAAS,EAAE,YAAY,CAAC;EACrE;;;;;;ACjMH,MAAM,QACH,EAAE,aAAa,EAAE,EAAE,eAAe,EAAE,EAAE,GAAG,YACzC,cACC,cAAc,WAAW;CAAE;CAAY;CAAc,GAAG;CAAM,CAAC;;AAgBnE,MAAM,iBAAgC,WAAW,UAAU,EAAE,KAAK;CAChE,MAAM,EAAE,aAAa,EAAE,EAAE,eAAe,EAAE,KAAK;AAiB/C,QAAO,oBAfuB;EAC5B;EACA,MAAM,UAAU,eAAe,UAAU;EACzC,OAAO,EAAE;EACT,cAAc;GACZ,KAAK;GACL,WAAW;GACX,QAAQ;GACR,QAAQ;GACR,GAAG;GACJ;EACD;EACA,UAAU,EAAE;EACb,CAEiC;;;;;AClBpC,kBAAe"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vitus-labs/rocketstories",
3
- "version": "1.3.1",
3
+ "version": "1.3.2-alpha.1+cde49e2",
4
4
  "license": "MIT",
5
5
  "author": "Vit Bokisch <vit@bokisch.cz>",
6
6
  "maintainers": [
@@ -63,15 +63,15 @@
63
63
  "react": ">= 19"
64
64
  },
65
65
  "dependencies": {
66
- "@vitus-labs/elements": "1.3.1"
66
+ "@vitus-labs/elements": "1.3.2-alpha.1+cde49e2"
67
67
  },
68
68
  "devDependencies": {
69
- "@vitus-labs/core": "1.3.1",
70
- "@vitus-labs/rocketstyle": "1.3.1",
69
+ "@vitus-labs/core": "1.3.2-alpha.1+cde49e2",
70
+ "@vitus-labs/rocketstyle": "1.3.2-alpha.1+cde49e2",
71
71
  "@vitus-labs/tools-rolldown": "^1.6.0",
72
72
  "@vitus-labs/tools-storybook": "^1.6.0",
73
73
  "@vitus-labs/tools-typescript": "^1.6.0",
74
- "@vitus-labs/unistyle": "1.3.1"
74
+ "@vitus-labs/unistyle": "1.3.2-alpha.1+cde49e2"
75
75
  },
76
- "gitHead": "bb22d6fa565082f85feab8275cb01ec51e4fc531"
76
+ "gitHead": "cde49e22c4d35f2d9c944c9a8f3cc7f84fda6943"
77
77
  }