@xyo-network/react-appbar 7.5.7 → 7.5.11

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.
Files changed (36) hide show
  1. package/dist/browser/components/MobileSystemControls/SystemControlsRoot.d.ts +2 -1
  2. package/dist/browser/components/MobileSystemControls/SystemControlsRoot.d.ts.map +1 -1
  3. package/dist/browser/index.mjs +217 -197
  4. package/dist/browser/index.mjs.map +1 -1
  5. package/package.json +100 -35
  6. package/src/components/AppBar/Application.stories.tsx +0 -85
  7. package/src/components/AppBar/Application.tsx +0 -27
  8. package/src/components/AppBar/index.ts +0 -1
  9. package/src/components/CollapsibleDrawer/CollapseDrawer.stories.tsx +0 -55
  10. package/src/components/CollapsibleDrawer/CollapseToggle.tsx +0 -35
  11. package/src/components/CollapsibleDrawer/CollapsibleDrawer.tsx +0 -41
  12. package/src/components/CollapsibleDrawer/index.ts +0 -2
  13. package/src/components/CollapsibleDrawer/storyExampleMenuData.tsx +0 -87
  14. package/src/components/MobileSystemControls/SystemControls.stories.tsx +0 -37
  15. package/src/components/MobileSystemControls/SystemControls.tsx +0 -15
  16. package/src/components/MobileSystemControls/SystemControlsRoot.tsx +0 -58
  17. package/src/components/MobileSystemControls/SystemControlsType.ts +0 -10
  18. package/src/components/MobileSystemControls/SystemControlsUnstyled.tsx +0 -42
  19. package/src/components/MobileSystemControls/controls/SystemControl.tsx +0 -46
  20. package/src/components/MobileSystemControls/controls/SystemControlText.tsx +0 -20
  21. package/src/components/MobileSystemControls/controls/index.ts +0 -2
  22. package/src/components/MobileSystemControls/index.ts +0 -3
  23. package/src/components/SearchBar/SearchBar.tsx +0 -55
  24. package/src/components/SearchBar/index.ts +0 -1
  25. package/src/components/Toolbar/Context/ContextToolbar.stories.tsx +0 -28
  26. package/src/components/Toolbar/Context/ContextToolbar.tsx +0 -21
  27. package/src/components/Toolbar/Context/Logo.tsx +0 -7
  28. package/src/components/Toolbar/Context/LogoLinkEx.tsx +0 -45
  29. package/src/components/Toolbar/Context/index.ts +0 -1
  30. package/src/components/Toolbar/System/SystemToolbar.stories.tsx +0 -59
  31. package/src/components/Toolbar/System/SystemToolbar.tsx +0 -43
  32. package/src/components/Toolbar/System/index.ts +0 -1
  33. package/src/components/Toolbar/index.ts +0 -2
  34. package/src/components/index.ts +0 -5
  35. package/src/global.d.ts +0 -1
  36. package/src/index.ts +0 -1
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/components/AppBar/Application.tsx","../../src/components/Toolbar/Context/ContextToolbar.tsx","../../src/components/Toolbar/Context/LogoLinkEx.tsx","../../src/components/Toolbar/Context/Logo.tsx","../../src/components/Toolbar/System/SystemToolbar.tsx","../../src/components/CollapsibleDrawer/CollapseToggle.tsx","../../src/components/CollapsibleDrawer/CollapsibleDrawer.tsx","../../src/components/MobileSystemControls/SystemControls.tsx","../../src/components/MobileSystemControls/SystemControlsRoot.tsx","../../src/components/MobileSystemControls/SystemControlsType.ts","../../src/components/MobileSystemControls/SystemControlsUnstyled.tsx","../../src/components/MobileSystemControls/controls/SystemControl.tsx","../../src/components/SearchBar/SearchBar.tsx"],"sourcesContent":["import type { ToolbarProps } from '@mui/material'\nimport type { ApplicationAppBarProps } from '@xylabs/react-appbar'\nimport { ApplicationAppBar } from '@xylabs/react-appbar'\nimport type { ReactElement } from 'react'\nimport React from 'react'\n\nimport { XyoContextToolbar, XyoSystemToolbar } from '../Toolbar/index.ts'\n\nexport interface XyoApplicationAppBarProps extends ApplicationAppBarProps {\n contextToolbar?: ReactElement<ToolbarProps>\n responsive?: boolean\n systemToolbar?: ReactElement<ToolbarProps>\n}\n\nexport const XyoApplicationAppBar: React.FC<XyoApplicationAppBarProps> = ({\n systemToolbar, contextToolbar, responsive = true, ...props\n}) => {\n return (\n <ApplicationAppBar\n systemToolbar={systemToolbar ?? <XyoSystemToolbar />}\n contextToolbar={contextToolbar ?? <XyoContextToolbar />}\n position=\"sticky\"\n responsive={responsive}\n {...props}\n />\n )\n}\n","import { Toolbar } from '@mui/material'\nimport type { ContextToolbarProps } from '@xylabs/react-appbar'\nimport type { ReactNode } from 'react'\nimport React from 'react'\n\nimport { LogoLinkEx } from './LogoLinkEx.tsx'\n\nexport interface XyoContextToolbarProps extends ContextToolbarProps {\n logo?: ReactNode\n}\n\nexport const XyoContextToolbar: React.FC<XyoContextToolbarProps> = ({\n children, logo, logoTo = '/', version = false, ...props\n}) => {\n return (\n <Toolbar {...props}>\n <LogoLinkEx logo={logo} version={version} to={logoTo} />\n {children}\n </Toolbar>\n )\n}\n","import { Typography, useTheme } from '@mui/material'\nimport { FlexRow } from '@xylabs/react-flexbox'\nimport type { LinkExProps } from '@xylabs/react-link'\nimport { LinkEx } from '@xylabs/react-link'\nimport { assertEx } from '@xylabs/sdk-js'\nimport React from 'react'\n\nimport { Logo } from './Logo.tsx'\n\nexport type LogoLinkExProps = LinkExProps & {\n logo?: React.ReactNode\n version?: boolean | string\n}\n\nexport const LogoLinkEx: React.FC<LogoLinkExProps> = ({\n logo, to = '/', href, version = false, ...props\n}) => {\n const theme = useTheme()\n assertEx(href === undefined, () => 'href is not supported')\n return (\n <LinkEx to={to} sx={{ 'opacity': 0.8, '&:hover': { opacity: 1 } }} {...props}>\n <FlexRow paddingX=\"4px\">\n {logo ?? <Logo height=\"40\" width=\"43\" />}\n {version === undefined\n ? null\n : (\n <Typography\n position=\"absolute\"\n borderRadius={1}\n right={6}\n color={theme.vars.palette.primary.main}\n bottom={0}\n bgcolor={theme.vars.palette.primary.contrastText}\n paddingX=\"2px\"\n lineHeight={1}\n variant=\"caption\"\n border={`1px ${theme.vars.palette.primary.main} solid`}\n >\n {typeof version === 'string' ? version : '2.1'}\n </Typography>\n )}\n </FlexRow>\n </LinkEx>\n )\n}\n","import React from 'react'\n\nexport const Logo: React.FC<React.DetailedHTMLProps<React.ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>> = (props) => {\n const logoUrl\n = 'https://cdn.xy.company/img/brand/XYO/XYO_icon_white.svg'\n return <img src={logoUrl} {...props} />\n}\n","import { Paper } from '@mui/material'\nimport {\n type SiteMenuProps, SystemToolbar, type SystemToolbarProps,\n} from '@xylabs/react-appbar'\nimport { FlexRow } from '@xylabs/react-flexbox'\nimport type { NetworkSelectExProps } from '@xyo-network/react-network'\nimport { NetworkSelectEx } from '@xyo-network/react-network'\nimport type { ReactNode } from 'react'\nimport React from 'react'\n\nexport interface XyoSystemToolbarProps extends SystemToolbarProps {\n darkModeButton?: boolean\n developerMode?: boolean\n hideNetworkSelect?: boolean\n menuItems?: ReactNode\n networkSelectProps?: NetworkSelectExProps\n onMenuToggle?: SiteMenuProps['onMenuToggle']\n precedingChildren?: ReactNode\n}\n\nexport const XyoSystemToolbar: React.FC<XyoSystemToolbarProps> = ({\n children,\n hideNetworkSelect,\n networkSelectProps,\n precedingChildren,\n ...props\n}) => {\n return (\n <SystemToolbar {...props}>\n {precedingChildren}\n {hideNetworkSelect\n ? null\n : (\n <FlexRow marginX={0.5}>\n <Paper variant=\"elevation\">\n <NetworkSelectEx fullWidth {...networkSelectProps} />\n </Paper>\n </FlexRow>\n )}\n {children}\n </SystemToolbar>\n )\n}\n","import { Icon, useTheme } from '@mui/material'\nimport type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport { FlexRow } from '@xylabs/react-flexbox'\nimport { useCollapsible } from '@xylabs/react-shared'\nimport React, { useState } from 'react'\nimport { VscArrowSmallLeft, VscArrowSmallRight } from 'react-icons/vsc'\n\nexport const CollapseToggleFlex: React.FC<FlexBoxProps> = (props) => {\n const {\n collapse, setCollapse, setCollapseEnd,\n } = useCollapsible()\n const [hover, setHover] = useState(false)\n const theme = useTheme()\n\n const handleCollapseToggle = () => {\n setCollapse?.(!collapse)\n setCollapseEnd?.(previous => (previous ? false : previous))\n }\n\n return (\n <FlexRow mt={2} py={2} justifyContent={collapse ? 'start' : 'center'} {...props}>\n <Icon\n onClick={handleCollapseToggle}\n onMouseEnter={() => setHover(true)}\n onMouseLeave={() => setHover(false)}\n fontSize=\"large\"\n sx={{ color: hover ? theme.vars.palette.secondary.main : 'inherit', cursor: 'pointer' }}\n >\n {collapse\n ? <VscArrowSmallRight />\n : <VscArrowSmallLeft />}\n </Icon>\n </FlexRow>\n )\n}\n","import type { CollapseProps } from '@mui/material'\nimport {\n Collapse, styled, useTheme,\n} from '@mui/material'\nimport { useCollapsible } from '@xylabs/react-shared'\nimport type { PropsWithChildren } from 'react'\nimport React from 'react'\n\nexport const CollapsibleDrawer: React.FC<PropsWithChildren<CollapseProps>> = ({\n children, sx, ...props\n}) => {\n const { collapse, setCollapseEnd } = useCollapsible()\n const theme = useTheme()\n\n const collapsedSize = props.collapsedSize ?? theme.spacing(5)\n\n return (\n <CollapsibleFlexInner\n in={!collapse}\n orientation=\"horizontal\"\n collapsedSize={collapsedSize}\n onExited={() => setCollapseEnd?.(true)}\n sx={{\n alignItems: 'start',\n display: 'flex',\n height: '100%',\n ...sx,\n }}\n {...props}\n >\n {children}\n </CollapsibleFlexInner>\n )\n}\n\nconst CollapsibleFlexInner = styled(Collapse)(() => ({\n '& .MuiCollapse-wrapperInner': {\n display: 'flex',\n flexDirection: 'column',\n },\n}))\n","import { FlexCol } from '@xylabs/react-flexbox'\nimport React from 'react'\n\nimport { SystemControlsRoot } from './SystemControlsRoot.tsx'\nimport type { SystemControlsUnstyledProps } from './SystemControlsUnstyled.tsx'\n\nconst SystemControls: React.FC<SystemControlsUnstyledProps> = (props) => {\n return (\n <FlexCol>\n <SystemControlsRoot {...props} />\n </FlexCol>\n )\n}\n\nexport { SystemControls }\n","import { styled } from '@mui/material'\n\nimport { SystemControlsType } from './SystemControlsType.ts'\nimport type { SystemControlsUnstyledProps } from './SystemControlsUnstyled.tsx'\nimport { SystemControlsUnstyled } from './SystemControlsUnstyled.tsx'\n\nconst SystemControlsRoot = styled(SystemControlsUnstyled, { name: 'SystemControls', slot: 'Root' })<SystemControlsUnstyledProps>(({ theme }) => ({\n // shared defaults\n ['&']: {\n '.toggle': { backgroundColor: theme.vars.palette.primary.main },\n 'alignItems': 'start',\n 'zIndex': 1,\n },\n // WindowShade System Controls styles\n [`&.system-controls-type-${SystemControlsType.WindowShade}`]: {\n '.control': {\n borderRadius: '0 0 5px 5px',\n flexDirection: 'row',\n flexGrow: 1,\n justifyContent: 'space-around',\n padding: `${theme.spacing(2)} ${theme.spacing(2.5)}`,\n },\n '.controls': {\n alignItems: 'stretch',\n flexDirection: 'column',\n flexGrow: 1,\n },\n '.toggle': {\n borderRadius: '0 0 5px 5px',\n padding: `${theme.spacing(0.5)} ${theme.spacing(1)}`,\n },\n 'flexDirection': 'row',\n 'position': 'absolute',\n 'top': 0,\n 'width': '100%',\n },\n // Left System Control styles\n [`&.system-controls-type-${SystemControlsType.Left}`]: {\n '.control': {\n alignItems: 'start',\n flexDirection: 'column',\n padding: `${theme.spacing(2)} ${theme.spacing(2.5)}`,\n },\n '.control-wrap': { marginBottom: `${theme.spacing(2)}` },\n '.toggle': {\n borderRadius: '0 5px 5px 0',\n padding: `${theme.spacing(1)} ${theme.spacing(0.5)}`,\n writingMode: 'vertical-rl',\n },\n 'flexDirection': 'column',\n 'left': 0,\n 'position': 'fixed',\n 'top': '30vh',\n 'width': 'auto',\n },\n}))\n\nexport { SystemControlsRoot }\n","import type { EnumValue } from '@xylabs/sdk-js'\nimport { Enum } from '@xylabs/sdk-js'\n\nexport const SystemControlsType = Enum({\n Left: 'Left',\n Right: 'Right',\n WindowShade: 'WindowShade',\n})\n\nexport type SystemControlsType = EnumValue<typeof SystemControlsType>\n","import type { Theme } from '@mui/material'\nimport { Paper, useMediaQuery } from '@mui/material'\nimport type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport { FlexCol, FlexRow } from '@xylabs/react-flexbox'\nimport { NetworkSelectEx } from '@xyo-network/react-network'\nimport React from 'react'\n\nimport { SystemControl } from './controls/index.ts'\nimport { SystemControlsType } from './SystemControlsType.ts'\n\ninterface SystemControlsUnstyledProps extends FlexBoxProps {\n systemControlsType?: SystemControlsType\n visible?: boolean\n}\n\nconst SystemControlsUnstyled: React.FC<SystemControlsUnstyledProps> = ({\n visible,\n systemControlsType = SystemControlsType.WindowShade,\n ...props\n}) => {\n const isSmall = useMediaQuery<Theme>(theme => theme.breakpoints.down('sm'))\n\n return visible || isSmall\n ? (\n <FlexCol {...props} className={`${props.className} system-controls-type-${systemControlsType}`}>\n <SystemControl\n systemControlsType={systemControlsType}\n controlElement={(\n <FlexRow className=\"control-wrap\">\n <Paper variant=\"elevation\" elevation={0}>\n <NetworkSelectEx responsive={false} className=\"network-ex\" />\n </Paper>\n </FlexRow>\n )}\n />\n </FlexCol>\n )\n : <FlexCol />\n}\n\nexport type { SystemControlsUnstyledProps }\nexport { SystemControlsUnstyled }\n","import type { CollapseProps } from '@mui/material'\nimport { Collapse } from '@mui/material'\nimport type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport { FlexCol, FlexRow } from '@xylabs/react-flexbox'\nimport type { PropsWithChildren } from 'react'\nimport React, { useState } from 'react'\n\nimport { SystemControlsType } from '../SystemControlsType.ts'\n\ninterface SystemControlProps extends FlexBoxProps {\n controlElement: React.ReactNode\n systemControlsType?: SystemControlsType\n}\n\nconst SystemControl: React.FC<PropsWithChildren<SystemControlProps>> = ({\n children,\n controlElement,\n systemControlsType = SystemControlsType.WindowShade,\n ...props\n}) => {\n const [toggleControls, setToggleControls] = useState(false)\n\n let orientation: CollapseProps['orientation'] = 'vertical'\n\n switch (systemControlsType) {\n case SystemControlsType.Left: {\n orientation = 'horizontal'\n break\n }\n }\n\n return (\n <FlexRow className=\"controls\" {...props}>\n <Collapse in={toggleControls} orientation={orientation} timeout={500}>\n <FlexRow bgcolor=\"primary.main\" className=\"control\">\n {controlElement}\n </FlexRow>\n </Collapse>\n <FlexCol style={{ cursor: 'pointer' }} onClick={() => setToggleControls(!toggleControls)}>\n {children}\n </FlexCol>\n </FlexRow>\n )\n}\n\nexport { SystemControl }\n","import { Search as SearchIcon } from '@mui/icons-material'\nimport { Paper, TextField } from '@mui/material'\nimport { ButtonEx } from '@xylabs/react-button'\nimport type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport { FlexRow } from '@xylabs/react-flexbox'\nimport React, { useState } from 'react'\n\nexport interface SearchBarProps extends FlexBoxProps {\n onSearch?: (term?: string) => void\n}\n\nexport const SearchBar: React.FC<SearchBarProps> = ({\n defaultValue, onSearch, ...props\n}) => {\n const [term, setTerm] = useState<string>()\n\n return (\n <FlexRow alignItems=\"stretch\" {...props}>\n <Paper\n variant=\"elevation\"\n elevation={0}\n style={{\n display: 'flex', overflow: 'hidden', width: '100%',\n }}\n >\n <TextField\n variant=\"outlined\"\n size=\"small\"\n defaultValue={defaultValue}\n fullWidth\n onChange={event => setTerm(event.target.value)}\n onKeyDown={(event) => {\n if (event.key === 'Enter') onSearch?.(term)\n }}\n slotProps={{\n input: {\n color: 'secondary',\n style: {\n borderBottomRightRadius: 0, borderTopRightRadius: 0, borderWidth: 0,\n },\n },\n }}\n />\n <ButtonEx\n variant=\"contained\"\n style={{ borderRadius: 0, borderTopLeftRadius: 0 }}\n color=\"secondary\"\n onClick={() => onSearch?.(term)}\n >\n <SearchIcon />\n </ButtonEx>\n </Paper>\n </FlexRow>\n )\n}\n"],"mappings":";;;;AAEA,SAASA,yBAAyB;AAElC,OAAOC,YAAW;;;ACJlB,SAASC,eAAe;AAGxB,OAAOC,YAAW;;;ACHlB,SAASC,YAAYC,gBAAgB;AACrC,SAASC,eAAe;AAExB,SAASC,cAAc;AACvB,SAASC,gBAAgB;AACzB,OAAOC,YAAW;;;ACLlB,OAAOC,WAAW;AAEX,IAAMC,OAAuG,wBAACC,UAAAA;AACnH,QAAMC,UACF;AACJ,SAAO,sBAAA,cAACC,OAAAA;IAAIC,KAAKF;IAAU,GAAGD;;AAChC,GAJoH;;;ADY7G,IAAMI,aAAwC,wBAAC,EACpDC,MAAMC,KAAK,KAAKC,MAAMC,UAAU,OAAO,GAAGC,MAAAA,MAC3C;AACC,QAAMC,QAAQC,SAAAA;AACdC,WAASL,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AAM,CAACC,MAAMC,OAAAA,IAAWC,UAAAA;AAExB,SACE,gBAAAC,QAAA,cAACC,UAAAA;IAAQC,YAAW;IAAW,GAAGN;KAChC,gBAAAI,QAAA,cAACG,QAAAA;IACCC,SAAQ;IACRC,WAAW;IACXC,OAAO;MACLC,SAAS;MAAQC,UAAU;MAAUC,OAAO;IAC9C;KAEA,gBAAAT,QAAA,cAACU,WAAAA;IACCN,SAAQ;IACRO,MAAK;IACLjB;IACAkB,WAAAA;IACAC,UAAUC,wBAAAA,UAAShB,QAAQgB,MAAMC,OAAOC,KAAK,GAAnCF;IACVG,WAAW,wBAACH,UAAAA;AACV,UAAIA,MAAMI,QAAQ,QAASvB,YAAWE,IAAAA;IACxC,GAFW;IAGXsB,WAAW;MACTC,OAAO;QACLC,OAAO;QACPf,OAAO;UACLgB,yBAAyB;UAAGC,sBAAsB;UAAGC,aAAa;QACpE;MACF;IACF;MAEF,gBAAAxB,QAAA,cAACyB,UAAAA;IACCrB,SAAQ;IACRE,OAAO;MAAEoB,cAAc;MAAGC,qBAAqB;IAAE;IACjDN,OAAM;IACNO,SAAS,6BAAMjC,WAAWE,IAAAA,GAAjB;KAET,gBAAAG,QAAA,cAAC6B,YAAAA,IAAAA,CAAAA,CAAAA,CAAAA;AAKX,GA3CmD;","names":["ApplicationAppBar","React","Toolbar","React","Typography","useTheme","FlexRow","LinkEx","assertEx","React","React","Logo","props","logoUrl","img","src","LogoLinkEx","logo","to","href","version","props","theme","useTheme","assertEx","undefined","React","LinkEx","sx","opacity","FlexRow","paddingX","Logo","height","width","Typography","position","borderRadius","right","color","vars","palette","primary","main","bottom","bgcolor","contrastText","lineHeight","variant","border","XyoContextToolbar","children","logo","logoTo","version","props","React","Toolbar","LogoLinkEx","to","Paper","SystemToolbar","FlexRow","NetworkSelectEx","React","XyoSystemToolbar","children","hideNetworkSelect","networkSelectProps","precedingChildren","props","React","SystemToolbar","FlexRow","marginX","Paper","variant","NetworkSelectEx","fullWidth","XyoApplicationAppBar","systemToolbar","contextToolbar","responsive","props","React","ApplicationAppBar","XyoSystemToolbar","XyoContextToolbar","position","Icon","useTheme","FlexRow","useCollapsible","React","useState","VscArrowSmallLeft","VscArrowSmallRight","CollapseToggleFlex","props","collapse","setCollapse","setCollapseEnd","useCollapsible","hover","setHover","useState","theme","useTheme","handleCollapseToggle","previous","React","FlexRow","mt","py","justifyContent","Icon","onClick","onMouseEnter","onMouseLeave","fontSize","sx","color","vars","palette","secondary","main","cursor","VscArrowSmallRight","VscArrowSmallLeft","Collapse","styled","useTheme","useCollapsible","React","CollapsibleDrawer","children","sx","props","collapse","setCollapseEnd","useCollapsible","theme","useTheme","collapsedSize","spacing","React","CollapsibleFlexInner","in","orientation","onExited","alignItems","display","height","styled","Collapse","flexDirection","FlexCol","React","styled","Enum","SystemControlsType","Left","Right","WindowShade","Paper","useMediaQuery","FlexCol","FlexRow","NetworkSelectEx","React","Collapse","FlexCol","FlexRow","React","useState","SystemControl","children","controlElement","systemControlsType","SystemControlsType","WindowShade","props","toggleControls","setToggleControls","useState","orientation","Left","React","FlexRow","className","Collapse","in","timeout","bgcolor","FlexCol","style","cursor","onClick","SystemControlsUnstyled","visible","systemControlsType","SystemControlsType","WindowShade","props","isSmall","useMediaQuery","theme","breakpoints","down","React","FlexCol","className","SystemControl","controlElement","FlexRow","Paper","variant","elevation","NetworkSelectEx","responsive","SystemControlsRoot","styled","SystemControlsUnstyled","name","slot","theme","backgroundColor","vars","palette","primary","main","SystemControlsType","WindowShade","borderRadius","flexDirection","flexGrow","justifyContent","padding","spacing","alignItems","Left","marginBottom","writingMode","SystemControls","props","React","FlexCol","SystemControlsRoot","Search","SearchIcon","Paper","TextField","ButtonEx","FlexRow","React","useState","SearchBar","defaultValue","onSearch","props","term","setTerm","useState","React","FlexRow","alignItems","Paper","variant","elevation","style","display","overflow","width","TextField","size","fullWidth","onChange","event","target","value","onKeyDown","key","slotProps","input","color","borderBottomRightRadius","borderTopRightRadius","borderWidth","ButtonEx","borderRadius","borderTopLeftRadius","onClick","SearchIcon"]}
1
+ {"version":3,"sources":["../../src/components/AppBar/Application.tsx","../../src/components/Toolbar/Context/ContextToolbar.tsx","../../src/components/Toolbar/Context/LogoLinkEx.tsx","../../src/components/Toolbar/Context/Logo.tsx","../../src/components/Toolbar/System/SystemToolbar.tsx","../../src/components/CollapsibleDrawer/CollapseToggle.tsx","../../src/components/CollapsibleDrawer/CollapsibleDrawer.tsx","../../src/components/MobileSystemControls/SystemControls.tsx","../../src/components/MobileSystemControls/SystemControlsRoot.tsx","../../src/components/MobileSystemControls/SystemControlsType.ts","../../src/components/MobileSystemControls/SystemControlsUnstyled.tsx","../../src/components/MobileSystemControls/controls/SystemControl.tsx","../../src/components/SearchBar/SearchBar.tsx"],"sourcesContent":["import type { ToolbarProps } from '@mui/material'\nimport type { ApplicationAppBarProps } from '@xylabs/react-appbar'\nimport { ApplicationAppBar } from '@xylabs/react-appbar'\nimport type { ReactElement } from 'react'\nimport React from 'react'\n\nimport { XyoContextToolbar, XyoSystemToolbar } from '../Toolbar/index.ts'\n\nexport interface XyoApplicationAppBarProps extends ApplicationAppBarProps {\n contextToolbar?: ReactElement<ToolbarProps>\n responsive?: boolean\n systemToolbar?: ReactElement<ToolbarProps>\n}\n\nexport const XyoApplicationAppBar: React.FC<XyoApplicationAppBarProps> = ({\n systemToolbar, contextToolbar, responsive = true, ...props\n}) => {\n return (\n <ApplicationAppBar\n systemToolbar={systemToolbar ?? <XyoSystemToolbar />}\n contextToolbar={contextToolbar ?? <XyoContextToolbar />}\n position=\"sticky\"\n responsive={responsive}\n {...props}\n />\n )\n}\n","import { Toolbar } from '@mui/material'\nimport type { ContextToolbarProps } from '@xylabs/react-appbar'\nimport type { ReactNode } from 'react'\nimport React from 'react'\n\nimport { LogoLinkEx } from './LogoLinkEx.tsx'\n\nexport interface XyoContextToolbarProps extends ContextToolbarProps {\n logo?: ReactNode\n}\n\nexport const XyoContextToolbar: React.FC<XyoContextToolbarProps> = ({\n children, logo, logoTo = '/', version = false, ...props\n}) => {\n return (\n <Toolbar {...props}>\n <LogoLinkEx logo={logo} version={version} to={logoTo} />\n {children}\n </Toolbar>\n )\n}\n","import { Typography, useTheme } from '@mui/material'\nimport { FlexRow } from '@xylabs/react-flexbox'\nimport type { LinkExProps } from '@xylabs/react-link'\nimport { LinkEx } from '@xylabs/react-link'\nimport { assertEx } from '@xylabs/sdk-js'\nimport React from 'react'\n\nimport { Logo } from './Logo.tsx'\n\nexport type LogoLinkExProps = LinkExProps & {\n logo?: React.ReactNode\n version?: boolean | string\n}\n\nexport const LogoLinkEx: React.FC<LogoLinkExProps> = ({\n logo, to = '/', href, version = false, ...props\n}) => {\n const theme = useTheme()\n assertEx(href === undefined, () => 'href is not supported')\n return (\n <LinkEx to={to} sx={{ 'opacity': 0.8, '&:hover': { opacity: 1 } }} {...props}>\n <FlexRow paddingX=\"4px\">\n {logo ?? <Logo height=\"40\" width=\"43\" />}\n {version === undefined\n ? null\n : (\n <Typography\n position=\"absolute\"\n borderRadius={1}\n right={6}\n color={theme.vars.palette.primary.main}\n bottom={0}\n bgcolor={theme.vars.palette.primary.contrastText}\n paddingX=\"2px\"\n lineHeight={1}\n variant=\"caption\"\n border={`1px ${theme.vars.palette.primary.main} solid`}\n >\n {typeof version === 'string' ? version : '2.1'}\n </Typography>\n )}\n </FlexRow>\n </LinkEx>\n )\n}\n","import React from 'react'\n\nexport const Logo: React.FC<React.DetailedHTMLProps<React.ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>> = (props) => {\n const logoUrl\n = 'https://cdn.xy.company/img/brand/XYO/XYO_icon_white.svg'\n return <img src={logoUrl} {...props} />\n}\n","import { Paper } from '@mui/material'\nimport {\n type SiteMenuProps, SystemToolbar, type SystemToolbarProps,\n} from '@xylabs/react-appbar'\nimport { FlexRow } from '@xylabs/react-flexbox'\nimport type { NetworkSelectExProps } from '@xyo-network/react-network'\nimport { NetworkSelectEx } from '@xyo-network/react-network'\nimport type { ReactNode } from 'react'\nimport React from 'react'\n\nexport interface XyoSystemToolbarProps extends SystemToolbarProps {\n darkModeButton?: boolean\n developerMode?: boolean\n hideNetworkSelect?: boolean\n menuItems?: ReactNode\n networkSelectProps?: NetworkSelectExProps\n onMenuToggle?: SiteMenuProps['onMenuToggle']\n precedingChildren?: ReactNode\n}\n\nexport const XyoSystemToolbar: React.FC<XyoSystemToolbarProps> = ({\n children,\n hideNetworkSelect,\n networkSelectProps,\n precedingChildren,\n ...props\n}) => {\n return (\n <SystemToolbar {...props}>\n {precedingChildren}\n {hideNetworkSelect\n ? null\n : (\n <FlexRow marginX={0.5}>\n <Paper variant=\"elevation\">\n <NetworkSelectEx fullWidth {...networkSelectProps} />\n </Paper>\n </FlexRow>\n )}\n {children}\n </SystemToolbar>\n )\n}\n","import { Icon, useTheme } from '@mui/material'\nimport type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport { FlexRow } from '@xylabs/react-flexbox'\nimport { useCollapsible } from '@xylabs/react-shared'\nimport React, { useState } from 'react'\nimport { VscArrowSmallLeft, VscArrowSmallRight } from 'react-icons/vsc'\n\nexport const CollapseToggleFlex: React.FC<FlexBoxProps> = (props) => {\n const {\n collapse, setCollapse, setCollapseEnd,\n } = useCollapsible()\n const [hover, setHover] = useState(false)\n const theme = useTheme()\n\n const handleCollapseToggle = () => {\n setCollapse?.(!collapse)\n setCollapseEnd?.(previous => (previous ? false : previous))\n }\n\n return (\n <FlexRow mt={2} py={2} justifyContent={collapse ? 'start' : 'center'} {...props}>\n <Icon\n onClick={handleCollapseToggle}\n onMouseEnter={() => setHover(true)}\n onMouseLeave={() => setHover(false)}\n fontSize=\"large\"\n sx={{ color: hover ? theme.vars.palette.secondary.main : 'inherit', cursor: 'pointer' }}\n >\n {collapse\n ? <VscArrowSmallRight />\n : <VscArrowSmallLeft />}\n </Icon>\n </FlexRow>\n )\n}\n","import type { CollapseProps } from '@mui/material'\nimport {\n Collapse, styled, useTheme,\n} from '@mui/material'\nimport { useCollapsible } from '@xylabs/react-shared'\nimport type { PropsWithChildren } from 'react'\nimport React from 'react'\n\nexport const CollapsibleDrawer: React.FC<PropsWithChildren<CollapseProps>> = ({\n children, sx, ...props\n}) => {\n const { collapse, setCollapseEnd } = useCollapsible()\n const theme = useTheme()\n\n const collapsedSize = props.collapsedSize ?? theme.spacing(5)\n\n return (\n <CollapsibleFlexInner\n in={!collapse}\n orientation=\"horizontal\"\n collapsedSize={collapsedSize}\n onExited={() => setCollapseEnd?.(true)}\n sx={{\n alignItems: 'start',\n display: 'flex',\n height: '100%',\n ...sx,\n }}\n {...props}\n >\n {children}\n </CollapsibleFlexInner>\n )\n}\n\nconst CollapsibleFlexInner = styled(Collapse)(() => ({\n '& .MuiCollapse-wrapperInner': {\n display: 'flex',\n flexDirection: 'column',\n },\n}))\n","import { FlexCol } from '@xylabs/react-flexbox'\nimport React from 'react'\n\nimport { SystemControlsRoot } from './SystemControlsRoot.tsx'\nimport type { SystemControlsUnstyledProps } from './SystemControlsUnstyled.tsx'\n\nconst SystemControls: React.FC<SystemControlsUnstyledProps> = (props) => {\n return (\n <FlexCol>\n <SystemControlsRoot {...props} />\n </FlexCol>\n )\n}\n\nexport { SystemControls }\n","import { styled } from '@mui/material'\nimport type React from 'react'\n\nimport { SystemControlsType } from './SystemControlsType.ts'\nimport type { SystemControlsUnstyledProps } from './SystemControlsUnstyled.tsx'\nimport { SystemControlsUnstyled } from './SystemControlsUnstyled.tsx'\n\nconst SystemControlsRoot: React.FC<SystemControlsUnstyledProps> = styled(SystemControlsUnstyled, { name: 'SystemControls', slot: 'Root' })<SystemControlsUnstyledProps>(({ theme }) => ({\n // shared defaults\n ['&']: {\n '.toggle': { backgroundColor: theme.vars.palette.primary.main },\n 'alignItems': 'start',\n 'zIndex': 1,\n },\n // WindowShade System Controls styles\n [`&.system-controls-type-${SystemControlsType.WindowShade}`]: {\n '.control': {\n borderRadius: '0 0 5px 5px',\n flexDirection: 'row',\n flexGrow: 1,\n justifyContent: 'space-around',\n padding: `${theme.spacing(2)} ${theme.spacing(2.5)}`,\n },\n '.controls': {\n alignItems: 'stretch',\n flexDirection: 'column',\n flexGrow: 1,\n },\n '.toggle': {\n borderRadius: '0 0 5px 5px',\n padding: `${theme.spacing(0.5)} ${theme.spacing(1)}`,\n },\n 'flexDirection': 'row',\n 'position': 'absolute',\n 'top': 0,\n 'width': '100%',\n },\n // Left System Control styles\n [`&.system-controls-type-${SystemControlsType.Left}`]: {\n '.control': {\n alignItems: 'start',\n flexDirection: 'column',\n padding: `${theme.spacing(2)} ${theme.spacing(2.5)}`,\n },\n '.control-wrap': { marginBottom: `${theme.spacing(2)}` },\n '.toggle': {\n borderRadius: '0 5px 5px 0',\n padding: `${theme.spacing(1)} ${theme.spacing(0.5)}`,\n writingMode: 'vertical-rl',\n },\n 'flexDirection': 'column',\n 'left': 0,\n 'position': 'fixed',\n 'top': '30vh',\n 'width': 'auto',\n },\n}))\n\nexport { SystemControlsRoot }\n","import type { EnumValue } from '@xylabs/sdk-js'\nimport { Enum } from '@xylabs/sdk-js'\n\nexport const SystemControlsType = Enum({\n Left: 'Left',\n Right: 'Right',\n WindowShade: 'WindowShade',\n})\n\nexport type SystemControlsType = EnumValue<typeof SystemControlsType>\n","import type { Theme } from '@mui/material'\nimport { Paper, useMediaQuery } from '@mui/material'\nimport type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport { FlexCol, FlexRow } from '@xylabs/react-flexbox'\nimport { NetworkSelectEx } from '@xyo-network/react-network'\nimport React from 'react'\n\nimport { SystemControl } from './controls/index.ts'\nimport { SystemControlsType } from './SystemControlsType.ts'\n\ninterface SystemControlsUnstyledProps extends FlexBoxProps {\n systemControlsType?: SystemControlsType\n visible?: boolean\n}\n\nconst SystemControlsUnstyled: React.FC<SystemControlsUnstyledProps> = ({\n visible,\n systemControlsType = SystemControlsType.WindowShade,\n ...props\n}) => {\n const isSmall = useMediaQuery<Theme>(theme => theme.breakpoints.down('sm'))\n\n return visible || isSmall\n ? (\n <FlexCol {...props} className={`${props.className} system-controls-type-${systemControlsType}`}>\n <SystemControl\n systemControlsType={systemControlsType}\n controlElement={(\n <FlexRow className=\"control-wrap\">\n <Paper variant=\"elevation\" elevation={0}>\n <NetworkSelectEx responsive={false} className=\"network-ex\" />\n </Paper>\n </FlexRow>\n )}\n />\n </FlexCol>\n )\n : <FlexCol />\n}\n\nexport type { SystemControlsUnstyledProps }\nexport { SystemControlsUnstyled }\n","import type { CollapseProps } from '@mui/material'\nimport { Collapse } from '@mui/material'\nimport type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport { FlexCol, FlexRow } from '@xylabs/react-flexbox'\nimport type { PropsWithChildren } from 'react'\nimport React, { useState } from 'react'\n\nimport { SystemControlsType } from '../SystemControlsType.ts'\n\ninterface SystemControlProps extends FlexBoxProps {\n controlElement: React.ReactNode\n systemControlsType?: SystemControlsType\n}\n\nconst SystemControl: React.FC<PropsWithChildren<SystemControlProps>> = ({\n children,\n controlElement,\n systemControlsType = SystemControlsType.WindowShade,\n ...props\n}) => {\n const [toggleControls, setToggleControls] = useState(false)\n\n let orientation: CollapseProps['orientation'] = 'vertical'\n\n switch (systemControlsType) {\n case SystemControlsType.Left: {\n orientation = 'horizontal'\n break\n }\n }\n\n return (\n <FlexRow className=\"controls\" {...props}>\n <Collapse in={toggleControls} orientation={orientation} timeout={500}>\n <FlexRow bgcolor=\"primary.main\" className=\"control\">\n {controlElement}\n </FlexRow>\n </Collapse>\n <FlexCol style={{ cursor: 'pointer' }} onClick={() => setToggleControls(!toggleControls)}>\n {children}\n </FlexCol>\n </FlexRow>\n )\n}\n\nexport { SystemControl }\n","import { Search as SearchIcon } from '@mui/icons-material'\nimport { Paper, TextField } from '@mui/material'\nimport { ButtonEx } from '@xylabs/react-button'\nimport type { FlexBoxProps } from '@xylabs/react-flexbox'\nimport { FlexRow } from '@xylabs/react-flexbox'\nimport React, { useState } from 'react'\n\nexport interface SearchBarProps extends FlexBoxProps {\n onSearch?: (term?: string) => void\n}\n\nexport const SearchBar: React.FC<SearchBarProps> = ({\n defaultValue, onSearch, ...props\n}) => {\n const [term, setTerm] = useState<string>()\n\n return (\n <FlexRow alignItems=\"stretch\" {...props}>\n <Paper\n variant=\"elevation\"\n elevation={0}\n style={{\n display: 'flex', overflow: 'hidden', width: '100%',\n }}\n >\n <TextField\n variant=\"outlined\"\n size=\"small\"\n defaultValue={defaultValue}\n fullWidth\n onChange={event => setTerm(event.target.value)}\n onKeyDown={(event) => {\n if (event.key === 'Enter') onSearch?.(term)\n }}\n slotProps={{\n input: {\n color: 'secondary',\n style: {\n borderBottomRightRadius: 0, borderTopRightRadius: 0, borderWidth: 0,\n },\n },\n }}\n />\n <ButtonEx\n variant=\"contained\"\n style={{ borderRadius: 0, borderTopLeftRadius: 0 }}\n color=\"secondary\"\n onClick={() => onSearch?.(term)}\n >\n <SearchIcon />\n </ButtonEx>\n </Paper>\n </FlexRow>\n )\n}\n"],"mappings":";AAEA,SAAS,yBAAyB;;;ACFlC,SAAS,eAAe;;;ACAxB,SAAS,YAAY,gBAAgB;AACrC,SAAS,eAAe;AAExB,SAAS,cAAc;AACvB,SAAS,gBAAgB;;;ACChB;AAHF,IAAM,OAAuG,CAAC,UAAU;AAC7H,QAAM,UACF;AACJ,SAAO,oBAAC,SAAI,KAAK,SAAU,GAAG,OAAO;AACvC;;;ADeM,SACW,OAAAA,MADX;AAPC,IAAM,aAAwC,CAAC;AAAA,EACpD;AAAA,EAAM,KAAK;AAAA,EAAK;AAAA,EAAM,UAAU;AAAA,EAAO,GAAG;AAC5C,MAAM;AACJ,QAAM,QAAQ,SAAS;AACvB,WAAS,SAAS,QAAW,MAAM,uBAAuB;AAC1D,SACE,gBAAAA,KAAC,UAAO,IAAQ,IAAI,EAAE,WAAW,KAAK,WAAW,EAAE,SAAS,EAAE,EAAE,GAAI,GAAG,OACrE,+BAAC,WAAQ,UAAS,OACf;AAAA,YAAQ,gBAAAA,KAAC,QAAK,QAAO,MAAK,OAAM,MAAK;AAAA,IACrC,YAAY,SACT,OAEE,gBAA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AgB;AAEzB,SAAS,WAAAC,gBAAe;AACxB,SAAgB,YAAAC,iBAAgB;AAa1B,SAOE,OAAAC,OAPF,QAAAC,aAAA;AAPC,IAAM,YAAsC,CAAC;AAAA,EAClD;AAAA,EAAc;AAAA,EAAU,GAAG;AAC7B,MAAM;AACJ,QAAM,CAAC,MAAM,OAAO,IAAIF,UAAiB;AAEzC,SACE,gBAAAC,MAACF,UAAA,EAAQ,YAAW,WAAW,GAAG,OAChC,0BAAAG;AAAA,IAACJ;AAAA,IAAA;AAAA,MACC,SAAQ;AAAA,MACR,WAAW;AAAA,MACX,OAAO;AAAA,QACL,SAAS;AAAA,QAAQ,UAAU;AAAA,QAAU,OAAO;AAAA,MAC9C;AAAA,MAEA;AAAA,wBAAAG;AAAA,UAAC;AAAA;AAAA,YACC,SAAQ;AAAA,YACR,MAAK;AAAA,YACL;AAAA,YACA,WAAS;AAAA,YACT,UAAU,WAAS,QAAQ,MAAM,OAAO,KAAK;AAAA,YAC7C,WAAW,CAAC,UAAU;AACpB,kBAAI,MAAM,QAAQ,QAAS,YAAW,IAAI;AAAA,YAC5C;AAAA,YACA,WAAW;AAAA,cACT,OAAO;AAAA,gBACL,OAAO;AAAA,gBACP,OAAO;AAAA,kBACL,yBAAyB;AAAA,kBAAG,sBAAsB;AAAA,kBAAG,aAAa;AAAA,gBACpE;AAAA,cACF;AAAA,YACF;AAAA;AAAA,QACF;AAAA,QACA,gBAAAA;AAAA,UAAC;AAAA;AAAA,YACC,SAAQ;AAAA,YACR,OAAO,EAAE,cAAc,GAAG,qBAAqB,EAAE;AAAA,YACjD,OAAM;AAAA,YACN,SAAS,MAAM,WAAW,IAAI;AAAA,YAE9B,0BAAAA,MAAC,cAAW;AAAA;AAAA,QACd;AAAA;AAAA;AAAA,EACF,GACF;AAEJ;","names":["jsx","jsx","jsxs","FlexRow","jsx","jsxs","jsx","useTheme","FlexRow","jsx","useTheme","useCollapsible","jsx","FlexCol","styled","Paper","FlexCol","FlexRow","NetworkSelectEx","Collapse","FlexRow","useState","jsx","jsxs","useState","FlexRow","Collapse","jsx","FlexCol","FlexRow","Paper","NetworkSelectEx","styled","jsx","FlexCol","Paper","FlexRow","useState","jsx","jsxs"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xyo-network/react-appbar",
3
- "version": "7.5.7",
3
+ "version": "7.5.11",
4
4
  "description": "Common React library for all XYO projects that use React",
5
5
  "keywords": [
6
6
  "xyo",
@@ -36,52 +36,117 @@
36
36
  },
37
37
  "./package.json": "./package.json"
38
38
  },
39
- "module": "dist/browser/index.mjs",
40
- "types": "dist/browser/index.d.ts",
41
39
  "files": [
42
40
  "dist",
43
- "src"
41
+ "README.md"
44
42
  ],
45
43
  "dependencies": {
46
- "@xylabs/react-appbar": "~7.1.17",
47
- "@xylabs/react-button": "~7.1.17",
48
- "@xylabs/react-flexbox": "~7.1.17",
49
- "@xylabs/react-link": "~7.1.17",
50
- "@xylabs/react-shared": "~7.1.17",
51
- "@xylabs/sdk-js": "~5.0.90",
52
- "@xyo-network/react-network": "7.5.7",
53
- "react-icons": "~5.6.0"
44
+ "@xyo-network/react-network": "~7.5.11"
54
45
  },
55
46
  "devDependencies": {
56
- "@mui/icons-material": "~7.3.9",
57
- "@mui/material": "~7.3.9",
58
- "@storybook/react-vite": "~10.3.3",
47
+ "@bitauth/libauth": "~3.0.0",
48
+ "@mui/icons-material": "^7.3.10",
49
+ "@mui/material": "^7.3.10",
50
+ "@opentelemetry/api": "^1.9.1",
51
+ "@opentelemetry/sdk-trace-base": "^2.7.0",
52
+ "@scure/base": "~2.2.0",
53
+ "@scure/bip39": "~2.2.0",
54
+ "@storybook/react-vite": "~10.3.5",
55
+ "@types/node": "~25.6.0",
59
56
  "@types/react": "^19.2.14",
60
- "@xylabs/ts-scripts-common": "~7.5.6",
61
- "@xylabs/ts-scripts-yarn3": "~7.5.6",
62
- "@xylabs/tsconfig": "~7.5.6",
63
- "@xylabs/tsconfig-dom": "~7.5.6",
64
- "@xylabs/tsconfig-react": "~7.5.6",
65
- "@xyo-network/react-storybook": "7.5.7",
66
- "@xyo-network/react-wallet": "7.5.7",
67
- "react": "^19.2.4",
68
- "react-dom": "^19.2.4",
69
- "react-router-dom": "^7.13.2",
70
- "storybook": "~10.3.3",
57
+ "@xylabs/react-appbar": "~7.1.20",
58
+ "@xylabs/react-async-effect": "~7.1.20",
59
+ "@xylabs/react-button": "~7.1.20",
60
+ "@xylabs/react-crypto": "~7.1.20",
61
+ "@xylabs/react-dialogs": "~7.1.20",
62
+ "@xylabs/react-flexbox": "~7.1.20",
63
+ "@xylabs/react-hooks": "~7.1.20",
64
+ "@xylabs/react-identicon": "~7.1.20",
65
+ "@xylabs/react-link": "~7.1.20",
66
+ "@xylabs/react-number-status": "~7.1.20",
67
+ "@xylabs/react-promise": "~7.1.20",
68
+ "@xylabs/react-quick-tip-button": "~7.1.20",
69
+ "@xylabs/react-select": "~7.1.20",
70
+ "@xylabs/react-shared": "~7.1.20",
71
+ "@xylabs/react-theme": "~7.1.20",
72
+ "@xylabs/sdk-js": "^5.0.100",
73
+ "@xylabs/threads": "~5.0.100",
74
+ "@xylabs/toolchain": "~7.11.9",
75
+ "@xylabs/tsconfig": "^7.11.9",
76
+ "@xylabs/tsconfig-dom": "^7.11.9",
77
+ "@xylabs/tsconfig-react": "~7.11.9",
78
+ "@xylabs/zod": "~5.0.100",
79
+ "@xyo-network/account-model": "^5.5.1",
80
+ "@xyo-network/boundwitness-model": "^5.5.1",
81
+ "@xyo-network/boundwitness-validator": "^5.5.1",
82
+ "@xyo-network/network": "~5.5.1",
83
+ "@xyo-network/payload-builder": "^5.5.1",
84
+ "@xyo-network/payload-model": "^5.5.1",
85
+ "@xyo-network/wallet": "~5.5.1",
86
+ "@xyo-network/wallet-model": "^5.5.1",
87
+ "async-mutex": "^0.5.0",
88
+ "axios": "^1.15.2",
89
+ "bn.js": "^5.2.3",
90
+ "bowser": "^2.14.1",
91
+ "buffer": "^6.0.3",
92
+ "chalk": "^5.6.2",
93
+ "debug": "~4.4.3",
94
+ "esbuild": "~0.28.0",
95
+ "eslint": "^10.2.1",
96
+ "ethers": "^6.16.0",
97
+ "fast-deep-equal": "~3.1.3",
98
+ "hash-wasm": "~4.12.0",
99
+ "js-cookie": "~3.0.5",
100
+ "observable-fns": "~0.6.1",
101
+ "pako": "^2.1.0",
102
+ "react": "^19.2.5",
103
+ "react-dom": "^19.2.5",
104
+ "react-icons": "~5.6.0",
105
+ "react-is": "^19.2.5",
106
+ "react-router-dom": "^7.14.2",
107
+ "spark-md5": "~3.0.2",
108
+ "storybook": "^10.3.5",
71
109
  "typescript": "^5.9.3",
72
- "vite": "~8.0.3",
73
- "zod": "^4.3.6"
110
+ "vite": "^8.0.10",
111
+ "wasm-feature-detect": "~1.8.0",
112
+ "zod": "^4.3.6",
113
+ "@xyo-network/react-storybook": "~7.5.11",
114
+ "@xyo-network/react-wallet": "~7.5.11"
74
115
  },
75
116
  "peerDependencies": {
76
- "@mui/icons-material": ">=6 <8",
77
- "@mui/material": ">=6 <8",
78
- "react": "^19",
79
- "react-dom": "^19",
80
- "react-router-dom": "^7",
81
- "zod": "^4"
117
+ "@mui/icons-material": "^7.3.10",
118
+ "@mui/material": "^7.3.10",
119
+ "@opentelemetry/sdk-trace-base": "^2.7.0",
120
+ "@xylabs/react-appbar": "~7.1.20",
121
+ "@xylabs/react-async-effect": "~7.1.20",
122
+ "@xylabs/react-button": "~7.1.20",
123
+ "@xylabs/react-flexbox": "~7.1.20",
124
+ "@xylabs/react-link": "~7.1.20",
125
+ "@xylabs/react-select": "~7.1.20",
126
+ "@xylabs/react-shared": "~7.1.20",
127
+ "@xylabs/sdk-js": "^5.0.100",
128
+ "@xylabs/zod": "~5.0.100",
129
+ "@xyo-network/network": "~5.5.1",
130
+ "@xyo-network/payload-builder": "^5.5.1",
131
+ "async-mutex": "^0.5.0",
132
+ "bn.js": "^5.2.3",
133
+ "bowser": "^2.14.1",
134
+ "buffer": "^6.0.3",
135
+ "chalk": "^5.6.2",
136
+ "ethers": "^6.16.0",
137
+ "fast-deep-equal": "~3.1.3",
138
+ "js-cookie": "~3.0.5",
139
+ "pako": "^2.1.0",
140
+ "react": "^19.2.5",
141
+ "react-dom": "^19.2.5",
142
+ "react-icons": "~5.6.0",
143
+ "react-is": "^19.2.5",
144
+ "react-router-dom": "^7.14.2",
145
+ "spark-md5": "~3.0.2",
146
+ "zod": "^4.3.6"
82
147
  },
83
148
  "publishConfig": {
84
149
  "access": "public"
85
150
  },
86
151
  "docs": "dist/docs.json"
87
- }
152
+ }
@@ -1,85 +0,0 @@
1
- import { List, Paper } from '@mui/material'
2
- import type { Meta, StoryFn } from '@storybook/react-vite'
3
- import { MenuListItemContainer } from '@xylabs/react-appbar'
4
- import { FlexGrowCol } from '@xylabs/react-flexbox'
5
- import { NetworkMemoryProvider } from '@xyo-network/react-network'
6
- import { DefaultSeedPhrase } from '@xyo-network/react-storybook'
7
- import {
8
- useWallet, WalletAccountSelect, WalletProvider,
9
- } from '@xyo-network/react-wallet'
10
- import React from 'react'
11
- import { BrowserRouter } from 'react-router-dom'
12
-
13
- import { SearchBar } from '../SearchBar/index.ts'
14
- import { XyoSystemToolbar } from '../Toolbar/index.ts'
15
- import { XyoApplicationAppBar } from './Application.tsx'
16
-
17
- const StorybookEntry = {
18
- argTypes: {},
19
- component: XyoApplicationAppBar,
20
- parameters: { docs: { page: null } },
21
- title: 'appbar/AppBar/Application',
22
- } as Meta<typeof XyoApplicationAppBar>
23
-
24
- const Template: StoryFn<typeof XyoApplicationAppBar> = (args) => {
25
- const [wallet] = useWallet({ mnemonic: DefaultSeedPhrase })
26
- return (
27
- <WalletProvider rootWallet={wallet}>
28
- <BrowserRouter>
29
- <NetworkMemoryProvider>
30
- <XyoApplicationAppBar
31
- systemToolbar={(
32
- <XyoSystemToolbar
33
- menuItems={(
34
- <List>
35
- <MenuListItemContainer primary="Hello" />
36
- </List>
37
- )}
38
- />
39
- )}
40
- {...args}
41
- >
42
- </XyoApplicationAppBar>
43
- </NetworkMemoryProvider>
44
- </BrowserRouter>
45
- </WalletProvider>
46
- )
47
- }
48
-
49
- const Default = Template.bind({})
50
- Default.args = {}
51
-
52
- const WithSearchBar = Template.bind({})
53
- WithSearchBar.args = {
54
- children: <SearchBar flexGrow={1} onSearch={term => alert(term)} />,
55
- color: 'primary',
56
- systemToolbar: (
57
- <XyoSystemToolbar
58
- darkModeButton
59
- menuItems={(
60
- <List>
61
- <MenuListItemContainer primary="Hello" />
62
- </List>
63
- )}
64
- />
65
- ),
66
- }
67
-
68
- const WithWalletSelectBar = Template.bind({})
69
- WithWalletSelectBar.args = {
70
- children: (
71
- <FlexGrowCol alignItems="stretch">
72
- <Paper variant="elevation">
73
- <WalletAccountSelect icons size="small" fullWidth />
74
- </Paper>
75
- </FlexGrowCol>
76
- ),
77
- color: 'primary',
78
- systemToolbar: <XyoSystemToolbar darkModeButton />,
79
- }
80
-
81
- export {
82
- Default, WithSearchBar, WithWalletSelectBar,
83
- }
84
-
85
- export default StorybookEntry
@@ -1,27 +0,0 @@
1
- import type { ToolbarProps } from '@mui/material'
2
- import type { ApplicationAppBarProps } from '@xylabs/react-appbar'
3
- import { ApplicationAppBar } from '@xylabs/react-appbar'
4
- import type { ReactElement } from 'react'
5
- import React from 'react'
6
-
7
- import { XyoContextToolbar, XyoSystemToolbar } from '../Toolbar/index.ts'
8
-
9
- export interface XyoApplicationAppBarProps extends ApplicationAppBarProps {
10
- contextToolbar?: ReactElement<ToolbarProps>
11
- responsive?: boolean
12
- systemToolbar?: ReactElement<ToolbarProps>
13
- }
14
-
15
- export const XyoApplicationAppBar: React.FC<XyoApplicationAppBarProps> = ({
16
- systemToolbar, contextToolbar, responsive = true, ...props
17
- }) => {
18
- return (
19
- <ApplicationAppBar
20
- systemToolbar={systemToolbar ?? <XyoSystemToolbar />}
21
- contextToolbar={contextToolbar ?? <XyoContextToolbar />}
22
- position="sticky"
23
- responsive={responsive}
24
- {...props}
25
- />
26
- )
27
- }
@@ -1 +0,0 @@
1
- export * from './Application.tsx'
@@ -1,55 +0,0 @@
1
- import { Divider, useTheme } from '@mui/material'
2
- import type {
3
- Decorator, Meta, StoryFn,
4
- } from '@storybook/react-vite'
5
- import { MenuSection } from '@xylabs/react-appbar'
6
- import {
7
- FlexCol, FlexGrowCol, FlexRow,
8
- } from '@xylabs/react-flexbox'
9
- import { CollapsibleProvider, useCollapsible } from '@xylabs/react-shared'
10
- import React from 'react'
11
-
12
- import { CollapseToggleFlex } from './CollapseToggle.tsx'
13
- import { CollapsibleDrawer } from './CollapsibleDrawer.tsx'
14
- import { menuDataBottom, menuDataTop } from './storyExampleMenuData.tsx'
15
-
16
- const CollapseProviderDecorator: Decorator = (Story, args) => {
17
- return (
18
- <CollapsibleProvider>
19
- <Story {...args} />
20
- </CollapsibleProvider>
21
- )
22
- }
23
-
24
- const StorybookEntry = {
25
- argTypes: {},
26
- component: CollapsibleDrawer,
27
- decorators: [CollapseProviderDecorator],
28
- parameters: { docs: { page: null } },
29
- title: 'appbar/CollapseDrawer',
30
- } as Meta<typeof CollapsibleDrawer>
31
-
32
- const Template: StoryFn<typeof CollapsibleDrawer> = (args) => {
33
- const { collapse, setCollapseEnd } = useCollapsible()
34
- const theme = useTheme()
35
- return (
36
- <FlexRow justifyContent="start">
37
- <FlexCol alignItems="start">
38
- <CollapsibleDrawer in={!collapse} orientation="horizontal" collapsedSize={theme.spacing(5)} onExited={() => setCollapseEnd?.(true)} {...args}>
39
- <MenuSection title="Explore & Create" listItems={menuDataTop} showTitle={!collapse} />
40
- <MenuSection title="Settings & Analytics" listItems={menuDataBottom} showTitle={!collapse} />
41
- <FlexGrowCol height="100%" />
42
- <CollapseToggleFlex />
43
- </CollapsibleDrawer>
44
- </FlexCol>
45
- <Divider flexItem orientation="vertical" />
46
- </FlexRow>
47
- )
48
- }
49
-
50
- const Default = Template.bind({})
51
- Default.args = { collapsedSize: '40px' }
52
-
53
- export { Default }
54
-
55
- export default StorybookEntry
@@ -1,35 +0,0 @@
1
- import { Icon, useTheme } from '@mui/material'
2
- import type { FlexBoxProps } from '@xylabs/react-flexbox'
3
- import { FlexRow } from '@xylabs/react-flexbox'
4
- import { useCollapsible } from '@xylabs/react-shared'
5
- import React, { useState } from 'react'
6
- import { VscArrowSmallLeft, VscArrowSmallRight } from 'react-icons/vsc'
7
-
8
- export const CollapseToggleFlex: React.FC<FlexBoxProps> = (props) => {
9
- const {
10
- collapse, setCollapse, setCollapseEnd,
11
- } = useCollapsible()
12
- const [hover, setHover] = useState(false)
13
- const theme = useTheme()
14
-
15
- const handleCollapseToggle = () => {
16
- setCollapse?.(!collapse)
17
- setCollapseEnd?.(previous => (previous ? false : previous))
18
- }
19
-
20
- return (
21
- <FlexRow mt={2} py={2} justifyContent={collapse ? 'start' : 'center'} {...props}>
22
- <Icon
23
- onClick={handleCollapseToggle}
24
- onMouseEnter={() => setHover(true)}
25
- onMouseLeave={() => setHover(false)}
26
- fontSize="large"
27
- sx={{ color: hover ? theme.vars.palette.secondary.main : 'inherit', cursor: 'pointer' }}
28
- >
29
- {collapse
30
- ? <VscArrowSmallRight />
31
- : <VscArrowSmallLeft />}
32
- </Icon>
33
- </FlexRow>
34
- )
35
- }
@@ -1,41 +0,0 @@
1
- import type { CollapseProps } from '@mui/material'
2
- import {
3
- Collapse, styled, useTheme,
4
- } from '@mui/material'
5
- import { useCollapsible } from '@xylabs/react-shared'
6
- import type { PropsWithChildren } from 'react'
7
- import React from 'react'
8
-
9
- export const CollapsibleDrawer: React.FC<PropsWithChildren<CollapseProps>> = ({
10
- children, sx, ...props
11
- }) => {
12
- const { collapse, setCollapseEnd } = useCollapsible()
13
- const theme = useTheme()
14
-
15
- const collapsedSize = props.collapsedSize ?? theme.spacing(5)
16
-
17
- return (
18
- <CollapsibleFlexInner
19
- in={!collapse}
20
- orientation="horizontal"
21
- collapsedSize={collapsedSize}
22
- onExited={() => setCollapseEnd?.(true)}
23
- sx={{
24
- alignItems: 'start',
25
- display: 'flex',
26
- height: '100%',
27
- ...sx,
28
- }}
29
- {...props}
30
- >
31
- {children}
32
- </CollapsibleFlexInner>
33
- )
34
- }
35
-
36
- const CollapsibleFlexInner = styled(Collapse)(() => ({
37
- '& .MuiCollapse-wrapperInner': {
38
- display: 'flex',
39
- flexDirection: 'column',
40
- },
41
- }))
@@ -1,2 +0,0 @@
1
- export * from './CollapseToggle.tsx'
2
- export * from './CollapsibleDrawer.tsx'
@@ -1,87 +0,0 @@
1
- import type { MenuListItemProps } from '@xylabs/react-appbar'
2
- import React from 'react'
3
- import {
4
- VscAccount,
5
- VscAdd,
6
- VscDashboard,
7
- VscGlobe,
8
- VscGraph,
9
- VscGraphLine,
10
- VscJson,
11
- VscServer,
12
- VscSettingsGear,
13
- VscSymbolMethod,
14
- VscSymbolNamespace,
15
- VscTable,
16
- } from 'react-icons/vsc'
17
-
18
- export const menuDataTop: MenuListItemProps[] = [
19
- {
20
- icon: <VscGlobe fontSize="body1" />,
21
- primary: 'Explore',
22
- to: '',
23
- tooltip: 'View global archivist data on a world map.',
24
- },
25
- {
26
- icon: <VscSymbolMethod fontSize="body1" />,
27
- primary: 'Blocks',
28
- to: '',
29
- tooltip: 'The most recent blocks seen in the in temp archive on your current network.',
30
- },
31
- {
32
- icon: <VscSymbolNamespace fontSize="body1" />,
33
- primary: 'Payloads',
34
- to: '',
35
- tooltip: 'The most recent blocks seen in the in temp archive on your current network.',
36
- },
37
- {
38
- icon: <VscGraph fontSize="body1" />,
39
- primary: 'Queries',
40
- to: '',
41
- tooltip: 'The most recent blocks seen in the in temp archive on your current network.',
42
- },
43
- {
44
- icon: <VscServer fontSize="body1" />,
45
- primary: 'Archives',
46
- subNavListItems: [
47
- {
48
- icon: <VscDashboard fontSize="body2" />, primary: 'Dashboard', to: '', tooltip: 'View data for all archives on this network.',
49
- },
50
- {
51
- icon: <VscAdd fontSize="body2" />, primary: 'Create Archive', to: '', tooltip: 'Create a new archive on this network.',
52
- },
53
- {
54
- icon: <VscTable fontSize="body2" />, primary: 'Archive Table', to: '', tooltip: 'View all archives on this network as a table.',
55
- },
56
- ],
57
- to: '',
58
- tooltip: 'The most recent blocks seen in the in temp archive on your current network.',
59
- },
60
- ]
61
-
62
- export const menuDataBottom: MenuListItemProps[] = [
63
- {
64
- icon: <VscGraphLine fontSize="body1" />,
65
- primary: 'Statistics',
66
- to: '',
67
- tooltip: 'The most recent blocks seen in the in temp archive on your current network.',
68
- },
69
- {
70
- icon: <VscJson fontSize="body1" />,
71
- primary: 'Schema',
72
- to: '',
73
- tooltip: 'The most recent blocks seen in the in temp archive on your current network.',
74
- },
75
- {
76
- icon: <VscAccount fontSize="body1" />,
77
- primary: 'Account',
78
- to: '',
79
- tooltip: 'The most recent blocks seen in the in temp archive on your current network.',
80
- },
81
- {
82
- icon: <VscSettingsGear fontSize="body1" />,
83
- primary: 'Settings',
84
- to: '',
85
- tooltip: 'The most recent blocks seen in the in temp archive on your current network.',
86
- },
87
- ]