hisd3-ui-kit 3.0.0 → 4.0.0
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.
- package/README.md +118 -78
- package/dist/index.cjs.js +485 -93
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.ts +211 -22
- package/dist/index.js +485 -93
- package/dist/index.js.map +1 -1
- package/package.json +7 -8
package/dist/index.cjs.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs.js","sources":["../node_modules/.pnpm/style-inject@0.3.0/node_modules/style-inject/dist/style-inject.es.js","../src/theme/antd.ts","../src/components/Sidebar/index.styled.tsx","../src/components/Sidebar/menu.ts","../src/components/Sidebar/UserMenu.tsx","../src/components/Sidebar/index.tsx","../src/enum/theme.ts"],"sourcesContent":["function styleInject(css, ref) {\n if ( ref === void 0 ) ref = {};\n var insertAt = ref.insertAt;\n\n if (!css || typeof document === 'undefined') { return; }\n\n var head = document.head || document.getElementsByTagName('head')[0];\n var style = document.createElement('style');\n style.type = 'text/css';\n\n if (insertAt === 'top') {\n if (head.firstChild) {\n head.insertBefore(style, head.firstChild);\n } else {\n head.appendChild(style);\n }\n } else {\n head.appendChild(style);\n }\n\n if (style.styleSheet) {\n style.styleSheet.cssText = css;\n } else {\n style.appendChild(document.createTextNode(css));\n }\n}\n\nexport default styleInject;\n","import type { ThemeConfig } from \"antd\";\n\n/**\n * HISD3 brand tokens for Ant Design v6.\n *\n * These reproduce the look of the former ProLayout `token.sider` settings\n * (teal selected/hover state) and are exported so every HISD3 app can pass\n * them to its own `<ConfigProvider theme={hisd3AntdTheme}>`.\n */\nexport const HISD3_COLORS = {\n primary: \"#00796b\",\n primaryLight: \"#e0f7f7\",\n headerSelectedBg: \"rgba(0,0,0,0.04)\",\n} as const;\n\nexport const hisd3AntdTheme: ThemeConfig = {\n token: {\n colorPrimary: HISD3_COLORS.primary,\n },\n components: {\n Menu: {\n itemSelectedBg: HISD3_COLORS.primaryLight,\n itemSelectedColor: HISD3_COLORS.primary,\n itemHoverBg: HISD3_COLORS.primaryLight,\n itemHoverColor: HISD3_COLORS.primary,\n subMenuItemSelectedColor: HISD3_COLORS.primary,\n itemActiveBg: HISD3_COLORS.primaryLight,\n horizontalItemSelectedBg: HISD3_COLORS.headerSelectedBg,\n horizontalItemSelectedColor: HISD3_COLORS.primary,\n },\n Layout: {\n siderBg: \"#ffffff\",\n headerBg: \"#ffffff\",\n triggerBg: \"#ffffff\",\n triggerColor: \"rgba(0,0,0,0.65)\",\n },\n },\n};\n","import styled from \"styled-components\";\nimport { Avatar, Layout, List } from \"antd\";\n\nconst { Header, Content } = Layout;\n\nexport const SIDER_WIDTH = 220;\nexport const SIDER_COLLAPSED_WIDTH = 64;\nexport const HEADER_HEIGHT = 56;\n\nexport const StyledRoot = styled(Layout)`\n min-height: 100vh;\n\n /*\n * The Sider is rendered as a plain antd <Sider> (not styled(Sider)) because\n * styled-components would swallow its \\`theme\\` prop; style it from here.\n */\n > .ant-layout-sider.hisd3-sider {\n position: sticky;\n top: 0;\n height: 100vh;\n overflow: hidden;\n border-right: 1px solid\n ${({ theme }) => theme?.palette?.borderColor || \"rgba(5, 5, 5, 0.06)\"};\n\n .ant-layout-sider-children {\n display: flex;\n flex-direction: column;\n height: 100%;\n }\n }\n`;\n\nexport const StyledSiderMenuWrap = styled.div`\n flex: 1 1 auto;\n overflow-y: auto;\n overflow-x: hidden;\n\n .ant-menu-inline,\n .ant-menu-vertical {\n border-inline-end: none !important;\n }\n`;\n\nexport const StyledBrand = styled.a<{ $collapsed?: boolean }>`\n display: flex;\n align-items: center;\n gap: 10px;\n height: ${HEADER_HEIGHT}px;\n padding: 0 ${({ $collapsed }) => ($collapsed ? 12 : 16)}px;\n justify-content: ${({ $collapsed }) => ($collapsed ? \"center\" : \"flex-start\")};\n color: inherit;\n text-decoration: none;\n overflow: hidden;\n white-space: nowrap;\n flex: 0 0 auto;\n\n img {\n height: 32px;\n width: 32px;\n object-fit: contain;\n flex: 0 0 auto;\n }\n\n h1 {\n margin: 0;\n font-size: 16px;\n font-weight: 600;\n color: ${({ theme }) => theme?.palette?.text || \"rgba(0, 0, 0, 0.88)\"};\n overflow: hidden;\n text-overflow: ellipsis;\n }\n`;\n\nexport const StyledHeader = styled(Header)`\n display: flex;\n align-items: center;\n gap: 16px;\n height: ${HEADER_HEIGHT}px;\n line-height: ${HEADER_HEIGHT}px;\n padding: 0 16px;\n position: sticky;\n top: 0;\n z-index: 100;\n border-bottom: 1px solid\n ${({ theme }) => theme?.palette?.borderColor || \"rgba(5, 5, 5, 0.06)\"};\n\n .ant-menu-horizontal {\n flex: 1 1 auto;\n min-width: 0;\n border-bottom: none;\n line-height: ${HEADER_HEIGHT - 2}px;\n }\n`;\n\nexport const StyledSiderHeader = styled(Header)`\n display: flex;\n align-items: center;\n height: ${HEADER_HEIGHT}px;\n line-height: ${HEADER_HEIGHT}px;\n padding: 0 16px;\n position: sticky;\n top: 0;\n z-index: 99;\n border-bottom: 1px solid\n ${({ theme }) => theme?.palette?.borderColor || \"rgba(5, 5, 5, 0.06)\"};\n`;\n\nexport const StyledCollapseTrigger = styled.button`\n border: none;\n background: transparent;\n cursor: pointer;\n font-size: 16px;\n padding: 8px;\n border-radius: ${({ theme }) => theme?.sizes?.borderRadius?.base || \"6px\"};\n color: inherit;\n display: inline-flex;\n align-items: center;\n\n &:hover {\n background: rgba(0, 0, 0, 0.04);\n }\n`;\n\nexport const StyledContent = styled(Content)`\n padding: 24px;\n min-height: calc(100vh - ${HEADER_HEIGHT}px);\n`;\n\nexport const StyledDropdownList = styled(List)`\n & .ant-list-item {\n padding: 5px 12px;\n cursor: pointer;\n }\n`;\n\nexport const StyledCrUserInfo = styled.div<{\n $collapsed?: boolean;\n $inHeader?: boolean;\n}>`\n background-color: transparent;\n padding: ${({ $inHeader }) => ($inHeader ? \"0 4px\" : \"7px 12px\")};\n min-height: ${({ $inHeader }) => ($inHeader ? \"auto\" : \"56px\")};\n line-height: 1.3;\n display: flex;\n flex-direction: column;\n justify-content: center;\n transition: all 0.2s ease;\n flex: 0 0 auto;\n min-width: ${({ $inHeader, $collapsed }) =>\n $inHeader ? \"200px\" : $collapsed ? \"0\" : \"auto\"};\n border-top: ${({ $inHeader, theme }) =>\n $inHeader\n ? \"none\"\n : `1px solid ${theme?.palette?.borderColor || \"rgba(5, 5, 5, 0.06)\"}`};\n\n @media screen and (min-width: ${({ theme }) =>\n theme?.breakpoints?.md || 768}px) {\n ${({ $inHeader }) =>\n $inHeader\n ? \"\"\n : \"padding-top: 10px; padding-bottom: 10px; min-height: 71px;\"}\n }\n\n & .ant-dropdown-link {\n color: inherit;\n\n & .anticon {\n font-size: ${({ theme }) => theme?.font?.size?.sm || \"14px\"};\n }\n }\n`;\n\nexport const StyledCrUserInfoInner = styled.a`\n display: flex;\n align-items: center;\n cursor: pointer;\n color: inherit;\n`;\n\nexport const StyledCrUserInfoAvatar = styled(Avatar)`\n font-size: 24px;\n background-color: ${({ theme }) => theme?.palette?.orange?.[6] || \"#FFA500\"};\n width: 40px;\n height: 40px;\n display: flex;\n align-items: center;\n justify-content: center;\n flex: 0 0 auto;\n`;\n\nexport const StyledCrUserInfoContent = styled.span`\n width: calc(100% - 62px);\n margin-left: 16px;\n transition: all 0.2s ease;\n min-width: 0;\n\n [dir=\"rtl\"] & {\n margin-left: 0;\n margin-right: 16px;\n }\n`;\n\nexport const StyledUsernameInfo = styled.span`\n display: flex;\n align-items: center;\n justify-content: space-between;\n`;\n\nexport const StyledUsername = styled.h3`\n margin-bottom: 0;\n font-size: ${({ theme }) => theme?.font?.size?.sm || \"14px\"};\n font-weight: ${({ theme }) => theme?.font?.weight?.lg || \"bold\"};\n color: ${({ theme }) => theme?.palette?.text || \"#000000e0\"};\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n`;\n\nexport const StyledUserArrow = styled.span`\n margin-left: 12px;\n width: 24px;\n display: flex;\n align-items: center;\n justify-content: center;\n\n [dir=\"rtl\"] & {\n margin-left: 0;\n margin-right: 12px;\n }\n\n & svg {\n display: block;\n }\n`;\n\nexport const StyledCrUserDesignation = styled.span`\n display: block;\n margin-top: -2px;\n color: ${({ theme }) => theme?.palette?.text || \"#000000e0\"};\n font-size: ${({ theme }) => theme?.font?.size?.sm || \"14px\"};\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n`;\n","import type { MenuProps } from \"antd\";\nimport { createElement, type ReactNode } from \"react\";\n\nexport type AntdMenuItem = Required<MenuProps>[\"items\"][number];\n\n/**\n * Menu item shape accepted by HISD3Sidebar.\n *\n * This intentionally mirrors the `MenuDataItem` shape that the previous\n * ProLayout-based sidebar consumed (`path`, `name`, `icon`, `children`,\n * `hideInMenu`), so existing apps keep passing the same `menuItems`.\n */\nexport interface HISD3MenuItem {\n key?: string;\n path?: string;\n name?: ReactNode;\n icon?: ReactNode;\n children?: HISD3MenuItem[];\n hideInMenu?: boolean;\n disabled?: boolean;\n /** When true the item is rendered as a group title (like ProLayout's `flatMenu`). */\n group?: boolean;\n [key: string]: unknown;\n}\n\nexport const itemKey = (item: HISD3MenuItem, index: number): string =>\n item.key ?? item.path ?? `menu-${index}`;\n\n/** Convert HISD3MenuItem[] to antd `Menu` items, rendering leaf items as anchors. */\nexport const toAntdMenuItems = (\n items: HISD3MenuItem[] | undefined,\n renderLink: (item: HISD3MenuItem, label: ReactNode) => ReactNode,\n): AntdMenuItem[] =>\n (items ?? [])\n .filter((item) => item && !item.hideInMenu)\n .map((item, index): AntdMenuItem => {\n const key = itemKey(item, index);\n const hasChildren = Array.isArray(item.children) && item.children.length > 0;\n\n if (hasChildren) {\n return {\n key,\n icon: item.icon,\n label: item.name,\n disabled: item.disabled,\n type: item.group ? \"group\" : undefined,\n children: toAntdMenuItems(item.children, renderLink),\n } as AntdMenuItem;\n }\n\n return {\n key,\n icon: item.icon,\n disabled: item.disabled,\n label: renderLink(item, item.name),\n } as AntdMenuItem;\n });\n\n/**\n * Find the key of the item whose `path` best matches `pathname`\n * (longest prefix wins) together with the keys of all its ancestors,\n * so the correct submenu can be opened.\n */\nexport const findSelection = (\n items: HISD3MenuItem[] | undefined,\n pathname: string,\n): { selectedKey?: string; openKeys: string[] } => {\n let best: { key: string; parents: string[]; length: number } | undefined;\n\n const walk = (list: HISD3MenuItem[] | undefined, parents: string[]) => {\n (list ?? []).forEach((item, index) => {\n const key = itemKey(item, index);\n if (item.path && pathname.startsWith(item.path)) {\n const exact = pathname === item.path;\n const length = item.path.length + (exact ? 1 : 0);\n if (!best || length > best.length) {\n best = { key, parents, length };\n }\n }\n if (item.children?.length) {\n walk(item.children, [...parents, key]);\n }\n });\n };\n\n walk(items, []);\n return { selectedKey: best?.key, openKeys: best?.parents ?? [] };\n};\n\n/** Default anchor renderer used when no `renderMenuLink` is supplied. */\nexport const defaultRenderLink = (item: HISD3MenuItem, label: ReactNode) =>\n createElement(\"a\", { href: item.path || \"/\" }, label);\n","import {\n DownOutlined,\n ExclamationCircleOutlined,\n LogoutOutlined,\n SettingOutlined,\n} from \"@ant-design/icons\";\nimport { App, Dropdown, type MenuProps } from \"antd\";\nimport React from \"react\";\n\nimport type { IUserEmployee } from \"../../types/account\";\nimport {\n StyledCrUserDesignation,\n StyledCrUserInfo,\n StyledCrUserInfoAvatar,\n StyledCrUserInfoContent,\n StyledCrUserInfoInner,\n StyledUserArrow,\n StyledUsername,\n StyledUsernameInfo,\n} from \"./index.styled\";\n\nexport interface UserMenuProps {\n account: IUserEmployee;\n avatarSrc?: string;\n settingsUrl?: string;\n onLogout: () => Promise<void> | void;\n collapsed?: boolean;\n /** \"topRight\" for the sider footer, \"bottomRight\" for the top header. */\n placement?: \"topRight\" | \"bottomRight\";\n extraItems?: MenuProps[\"items\"];\n}\n\n/**\n * Account dropdown (Settings / Logout) shown in the sider footer or header.\n * Uses `App.useApp()` so the confirm modal picks up the surrounding\n * ConfigProvider theme — the static `Modal.confirm` cannot in antd v6.\n */\nexport const UserMenu: React.FC<UserMenuProps> = ({\n account,\n avatarSrc,\n settingsUrl,\n onLogout,\n collapsed = false,\n placement = \"topRight\",\n extraItems = [],\n}) => {\n const { modal } = App.useApp();\n\n const confirmLogout = () => {\n modal.confirm({\n title: \"Are you sure you want to logout?\",\n content: \"Please click OK to continue\",\n icon: <ExclamationCircleOutlined />,\n onOk: onLogout,\n });\n };\n\n const items: MenuProps[\"items\"] = [\n ...(extraItems ?? []),\n {\n key: \"settings\",\n icon: <SettingOutlined />,\n label: \"Settings\",\n onClick: () => {\n window.location.href = settingsUrl ?? \"/settings\";\n },\n },\n {\n key: \"logout\",\n icon: <LogoutOutlined />,\n label: \"Logout\",\n onClick: confirmLogout,\n },\n ];\n\n const initials = (account.fullName || \"?\")\n .split(\" \")\n .filter(Boolean)\n .slice(0, 2)\n .map((s) => s[0]?.toUpperCase())\n .join(\"\");\n\n return (\n <StyledCrUserInfo\n className=\"cr-user-info-light\"\n $collapsed={collapsed}\n $inHeader={placement === \"bottomRight\"}\n >\n <Dropdown trigger={[\"click\"]} placement={placement} menu={{ items }}>\n <StyledCrUserInfoInner\n className=\"ant-dropdown-link\"\n onClick={(e) => e.preventDefault()}\n >\n <StyledCrUserInfoAvatar src={avatarSrc} size=\"small\">\n {!avatarSrc && initials}\n </StyledCrUserInfoAvatar>\n {!collapsed && (\n <StyledCrUserInfoContent>\n <StyledUsernameInfo>\n <StyledUsername title={account.fullName}>\n {account.fullName}\n </StyledUsername>\n <StyledUserArrow>\n <DownOutlined />\n </StyledUserArrow>\n </StyledUsernameInfo>\n {account.positionType && (\n <StyledCrUserDesignation title={account.positionType}>\n {account.positionType}\n </StyledCrUserDesignation>\n )}\n </StyledCrUserInfoContent>\n )}\n </StyledCrUserInfoInner>\n </Dropdown>\n </StyledCrUserInfo>\n );\n};\n\nexport default UserMenu;\n","import { MenuFoldOutlined, MenuUnfoldOutlined } from \"@ant-design/icons\";\nimport {\n App as AntdApp,\n ConfigProvider,\n Layout,\n Menu,\n Spin,\n type MenuProps,\n type ThemeConfig,\n} from \"antd\";\nimport React, { useEffect, useMemo, useState, type ReactNode } from \"react\";\nimport { ThemeProvider } from \"styled-components\";\n\nimport { hisd3AntdTheme } from \"../../theme/antd\";\nimport type { IUserEmployee } from \"../../types/account\";\nimport type { StyledTheme } from \"../../types/theme\";\nimport {\n SIDER_COLLAPSED_WIDTH,\n SIDER_WIDTH,\n StyledBrand,\n StyledCollapseTrigger,\n StyledContent,\n StyledHeader,\n StyledRoot,\n StyledSiderHeader,\n StyledSiderMenuWrap,\n} from \"./index.styled\";\nimport {\n defaultRenderLink,\n findSelection,\n toAntdMenuItems,\n type HISD3MenuItem,\n} from \"./menu\";\nimport { UserMenu } from \"./UserMenu\";\n\nconst { Sider } = Layout;\n\nexport interface HISD3SidebarProps {\n account: IUserEmployee;\n logoUrl: string;\n appName: string;\n /** Same shape as before (ProLayout `MenuDataItem`): `{ path, name, icon, children }`. */\n menuItems: HISD3MenuItem[];\n onLogout: () => Promise<void> | void;\n /** Current location pathname, used to highlight the active menu item. */\n pathname: string;\n styledTheme: StyledTheme;\n collapsed?: boolean;\n /** Called when the user toggles the sider (controlled usage). */\n onCollapse?: (collapsed: boolean) => void;\n loading?: boolean;\n hideSidebar?: boolean;\n /** Render the navigation as a top header bar instead of a left sider. */\n layoutTop?: boolean;\n avatarSrc?: string;\n settingsUrl?: string;\n /**\n * Ant Design theme applied via a nested `ConfigProvider`.\n * Defaults to `hisd3AntdTheme`; pass `null` to inherit the parent theme untouched.\n */\n antdTheme?: ThemeConfig | null;\n /**\n * Custom link renderer, e.g. to use react-router's `<Link>`:\n * `(item, label) => <Link to={item.path!}>{label}</Link>`\n */\n renderMenuLink?: (item: HISD3MenuItem, label: ReactNode) => ReactNode;\n /** Extra content rendered in the header, right side (top layout) or sider header (side layout). */\n headerExtra?: ReactNode;\n /** Extra items prepended to the account dropdown. */\n userMenuItems?: MenuProps[\"items\"];\n /** Hide the collapse trigger button. */\n hideCollapseTrigger?: boolean;\n /** Width in px of the expanded sider. Default 220. */\n siderWidth?: number;\n /** Disable the built-in content padding wrapper and render children directly. */\n bareContent?: boolean;\n children: React.ReactNode;\n}\n\nexport const HISD3Sidebar: React.FC<HISD3SidebarProps> = ({\n children,\n account,\n logoUrl,\n appName,\n menuItems,\n onLogout,\n pathname,\n avatarSrc,\n styledTheme,\n settingsUrl,\n antdTheme = hisd3AntdTheme,\n renderMenuLink = defaultRenderLink,\n headerExtra,\n userMenuItems,\n onCollapse,\n collapsed = false,\n loading = false,\n hideSidebar = false,\n layoutTop = false,\n hideCollapseTrigger = false,\n siderWidth = SIDER_WIDTH,\n bareContent = false,\n}) => {\n const [isCollapsed, setIsCollapsed] = useState(collapsed);\n\n useEffect(() => {\n setIsCollapsed(collapsed);\n }, [collapsed]);\n\n const items = useMemo(\n () => toAntdMenuItems(menuItems, renderMenuLink),\n [menuItems, renderMenuLink],\n );\n\n const selection = useMemo(\n () => findSelection(menuItems, pathname),\n [menuItems, pathname],\n );\n\n // Start with the active route's submenu open so there is no flash on first paint.\n const [openKeys, setOpenKeys] = useState<string[]>(() => selection.openKeys);\n\n // Open the submenu that contains the active route whenever the route changes.\n useEffect(() => {\n setOpenKeys((prev) =>\n Array.from(new Set([...prev, ...selection.openKeys])),\n );\n }, [selection.openKeys.join(\"|\")]);\n\n const toggleCollapse = (next: boolean) => {\n setIsCollapsed(next);\n onCollapse?.(next);\n };\n\n const selectedKeys = selection.selectedKey ? [selection.selectedKey] : [];\n\n const brand = (\n <StyledBrand href=\"/\" $collapsed={!layoutTop && isCollapsed}>\n {logoUrl && <img src={logoUrl} alt={appName} />}\n {(layoutTop || !isCollapsed) && <h1>{appName}</h1>}\n </StyledBrand>\n );\n\n const content = bareContent ? (\n children\n ) : (\n <StyledContent>{children}</StyledContent>\n );\n\n const renderBody = () => {\n if (hideSidebar) {\n return <>{children}</>;\n }\n\n if (layoutTop) {\n return (\n <StyledRoot>\n <StyledHeader>\n {brand}\n <Menu\n mode=\"horizontal\"\n items={items}\n selectedKeys={selectedKeys}\n />\n {headerExtra}\n <UserMenu\n account={account}\n avatarSrc={avatarSrc}\n settingsUrl={settingsUrl}\n onLogout={onLogout}\n placement=\"bottomRight\"\n extraItems={userMenuItems}\n />\n </StyledHeader>\n {content}\n </StyledRoot>\n );\n }\n\n return (\n <StyledRoot hasSider>\n <Sider\n className=\"hisd3-sider\"\n width={siderWidth}\n collapsedWidth={SIDER_COLLAPSED_WIDTH}\n collapsible\n collapsed={isCollapsed}\n trigger={null}\n theme=\"light\"\n breakpoint=\"lg\"\n onBreakpoint={(broken) => {\n if (broken) toggleCollapse(true);\n }}\n >\n {brand}\n <StyledSiderMenuWrap>\n <Menu\n mode=\"inline\"\n theme=\"light\"\n inlineCollapsed={isCollapsed}\n items={items}\n selectedKeys={selectedKeys}\n openKeys={isCollapsed ? undefined : openKeys}\n onOpenChange={(keys) => setOpenKeys(keys as string[])}\n />\n </StyledSiderMenuWrap>\n <UserMenu\n account={account}\n avatarSrc={avatarSrc}\n settingsUrl={settingsUrl}\n onLogout={onLogout}\n collapsed={isCollapsed}\n placement=\"topRight\"\n extraItems={userMenuItems}\n />\n </Sider>\n\n <Layout>\n <StyledSiderHeader>\n {!hideCollapseTrigger && (\n <StyledCollapseTrigger\n type=\"button\"\n aria-label={isCollapsed ? \"Expand menu\" : \"Collapse menu\"}\n onClick={() => toggleCollapse(!isCollapsed)}\n >\n {isCollapsed ? <MenuUnfoldOutlined /> : <MenuFoldOutlined />}\n </StyledCollapseTrigger>\n )}\n <span style={{ flex: 1 }} />\n {headerExtra}\n </StyledSiderHeader>\n {content}\n </Layout>\n </StyledRoot>\n );\n };\n\n if (typeof document === \"undefined\") {\n return null;\n }\n\n const body = (\n <AntdApp component={false}>\n <Spin spinning={loading} size=\"large\">\n {renderBody()}\n </Spin>\n </AntdApp>\n );\n\n return (\n <ThemeProvider theme={styledTheme}>\n {antdTheme ? (\n <ConfigProvider theme={antdTheme}>{body}</ConfigProvider>\n ) : (\n body\n )}\n </ThemeProvider>\n );\n};\n\nexport default HISD3Sidebar;\n","export enum ThemeStyle {\n MODERN = \"modern\",\n STANDARD = \"standard\",\n}\nexport enum ThemeStyleRadius {\n MODERN = \"30px\",\n STANDARD = \"16px\",\n}\nexport enum ThemeMode {\n LIGHT = \"light\",\n SEMI_DARK = \"semi-dark\",\n DARK = \"dark\",\n}\nexport enum LayoutType {\n FULL_WIDTH = \"full-width\",\n BOXED = \"boxed\",\n FRAMED = \"framed\",\n}\n\nexport enum MenuStyle {\n DEFAULT = \"default\",\n STANDARD = \"standard\",\n ROUNDED = \"rounded\",\n ROUNDED_REVERSE = \"rounded-reverse\",\n CURVED_MENU = \"curved-menu\",\n}\n\nexport enum NavStyle {\n DEFAULT = \"default\",\n MINI = \"mini\",\n MINI_SIDEBAR_TOGGLE = \"mini-sidebar-toggle\",\n STANDARD = \"standard\",\n HEADER_USER = \"user-header\",\n HEADER_USER_MINI = \"user-mini-header\",\n DRAWER = \"drawer\",\n BIT_BUCKET = \"bit-bucket\",\n H_DEFAULT = \"h-default\",\n HOR_HEADER_FIXED = \"hor-header-fixed\",\n HOR_DARK_LAYOUT = \"hor-dark-layout\",\n}\nexport enum FooterType {\n FIXED = \"fixed\",\n FLUID = \"fluid\",\n}\nexport enum LayoutDirection {\n RTL = \"rtl\",\n LTR = \"ltr\",\n}\nexport enum HeaderType {\n DARK = \"dark\",\n LIGHT = \"light\",\n}\nexport enum RouteTransition {\n NONE = \"none\",\n FADE = \"fade\",\n SLIDE_LEFT = \"slideLeft\",\n SLIDE_RIGHT = \"slideRight\",\n SLIDE_UP = \"slideUp\",\n SLIDE_DOWN = \"slideDown\",\n}\nexport enum Fonts {\n LIGHT = \"300\",\n REGULAR = \"400\",\n MEDIUM = \"500\",\n BOLD = \"600\",\n}\n\nexport enum AuthType {\n FIREBASE = \"firebase\",\n AWS_COGNITO = \"aws_cognito\",\n AUTH0 = \"auth0\",\n JWT_AUTH = \"jwt_auth\",\n}\n\nexport enum AppAnimates {\n SLIDEUPIN = \"transition.slideUpIn\",\n SLIDEUPOUT = \"transition.slideUpOut\",\n SLIDEDOWNIN = \"transition.slideDownIn\",\n SLIDEDOWNOUT = \"transition.slideDownOut\",\n SLIDELEFTIN = \"transition.slideLeftIn\",\n SLIDELEFTOUT = \"transition.slideLeftOut\",\n SLIDERIGHTIN = \"transition.slideRightIn\",\n SLIDERIGHTOUT = \"transition.slideRightOut\",\n FADEIN = \"transition.fadeIn\",\n FADEOUT = \"transition.fadeOut\",\n}\n\nexport const AppAnimateGroups = {\n SLIDEUPIN: {\n hidden: {\n y: 0,\n },\n visible: {\n opacity: 1,\n y: 0,\n transition: {\n ease: \"easeIn\",\n delay: 0,\n when: \"beforeChildren\",\n duration: 0.2,\n staggerChildren: 0.05,\n },\n },\n },\n SLIDEUPOUT: {\n hidden: {\n y: 0,\n },\n visible: {\n opacity: 0,\n y: \"100vh\",\n transition: {\n ease: \"easeOut\",\n delay: 0,\n when: \"beforeChildren\",\n duration: 0.4,\n staggerChildren: 0.15,\n },\n },\n },\n SLIDEDOWNIN: {\n hidden: {\n opacity: 0,\n y: \"-100vh\",\n },\n visible: {\n opacity: 1,\n y: 0,\n transition: {\n ease: \"easeIn\",\n delay: 0,\n when: \"beforeChildren\",\n duration: 0.4,\n staggerChildren: 0.15,\n },\n },\n },\n SLIDEDOWNOUT: {\n hidden: {\n y: 0,\n },\n visible: {\n opacity: 0,\n y: \"-100vh\",\n transition: {\n ease: \"easeOut\",\n delay: 0,\n when: \"beforeChildren\",\n duration: 0.4,\n staggerChildren: 0.15,\n },\n },\n },\n SLIDELEFTIN: {\n hidden: {\n x: \"100vw\",\n },\n visible: {\n opacity: 1,\n x: 0,\n transition: {\n ease: \"easeIn\",\n delay: 0,\n when: \"beforeChildren\",\n duration: 0.4,\n staggerChildren: 0.15,\n },\n },\n },\n SLIDELEFTOUT: {\n hidden: {\n x: 0,\n },\n visible: {\n opacity: 0,\n x: \"100vw\",\n transition: {\n ease: \"easeOut\",\n delay: 0,\n when: \"beforeChildren\",\n duration: 0.4,\n staggerChildren: 0.15,\n },\n },\n },\n SLIDERIGHTIN: {\n hidden: {\n x: \"-100vw\",\n },\n visible: {\n opacity: 1,\n x: 0,\n transition: {\n ease: \"easeIn\",\n delay: 0,\n when: \"beforeChildren\",\n duration: 0.4,\n staggerChildren: 0.15,\n },\n },\n },\n SLIDERIGHTOUT: {\n hidden: {\n x: 0,\n },\n visible: {\n opacity: 0,\n x: \"-100vw\",\n transition: {\n ease: \"easeOut\",\n delay: 0,\n when: \"beforeChildren\",\n duration: 0.4,\n staggerChildren: 0.15,\n },\n },\n },\n FADEIN: {\n hidden: {\n opacity: 0,\n scale: 1,\n },\n visible: {\n opacity: 1,\n scale: 1,\n transition: {\n ease: \"easeIn\",\n when: \"beforeChildren\",\n staggerChildren: 0.15,\n },\n },\n },\n FADEOUT: {\n hidden: {\n opacity: 1,\n scale: 1,\n },\n visible: {\n opacity: 0,\n scale: 1,\n transition: {\n ease: \"easeOut\",\n when: \"beforeChildren\",\n staggerChildren: 0.15,\n },\n },\n },\n NOANIMATION: {\n hidden: {\n opacity: 1,\n },\n visible: {\n opacity: 1,\n },\n },\n};\n\nexport const AppMotionAnimate = {\n SLIDEUPIN: {\n variants: {\n hidden: {\n y: 100,\n opacity: 0,\n },\n visible: {\n opacity: 1,\n y: 0,\n },\n },\n transition: {\n ease: \"easeIn\",\n when: \"beforeChildren\",\n },\n },\n SLIDEUPOUT: {\n variants: {\n hidden: {\n y: 0,\n opacity: 1,\n },\n visible: {\n opacity: 0,\n y: \"-100vh\",\n },\n },\n transition: {\n ease: \"easeOut\",\n when: \"beforeChildren\",\n },\n },\n SLIDEDOWNIN: {\n variants: {\n hidden: {\n y: -100,\n opacity: 0,\n },\n visible: {\n opacity: 1,\n y: 0,\n },\n },\n transition: {\n ease: \"easeIn\",\n when: \"beforeChildren\",\n },\n },\n SLIDEDOWNOUT: {\n variants: {\n hidden: {\n y: 0,\n opacity: 1,\n },\n visible: {\n opacity: 0,\n y: \"100vh\",\n },\n },\n transition: {\n ease: \"easeOut\",\n when: \"beforeChildren\",\n },\n },\n SLIDELEFTIN: {\n variants: {\n hidden: {\n x: 100,\n opacity: 0,\n },\n visible: {\n opacity: 1,\n x: 0,\n },\n },\n transition: {\n ease: \"easeIn\",\n when: \"beforeChildren\",\n },\n },\n SLIDELEFTOUT: {\n variants: {\n hidden: {\n x: 0,\n opacity: 1,\n },\n visible: {\n opacity: 0,\n x: \"-100vw\",\n },\n },\n transition: {\n ease: \"easeOut\",\n when: \"beforeChildren\",\n },\n },\n SLIDERIGHTIN: {\n variants: {\n hidden: {\n x: -100,\n opacity: 0,\n },\n visible: {\n opacity: 1,\n x: 0,\n },\n },\n transition: {\n ease: \"easeIn\",\n when: \"beforeChildren\",\n },\n },\n SLIDERIGHTOUT: {\n variants: {\n hidden: {\n x: 0,\n opacity: 1,\n },\n visible: {\n opacity: 0,\n x: \"-100vw\",\n },\n },\n transition: {\n ease: \"easeOut\",\n when: \"beforeChildren\",\n },\n },\n FADEIN: {\n variants: {\n hidden: {\n opacity: 0,\n },\n visible: {\n opacity: 1,\n },\n },\n transition: {\n duration: 0.1,\n ease: \"easeIn\",\n when: \"beforeChildren\",\n },\n },\n FADEOUT: {\n variants: {\n hidden: {\n opacity: 1,\n },\n visible: {\n opacity: 0,\n },\n },\n transition: {\n duration: 0.1,\n ease: \"easeOut\",\n when: \"beforeChildren\",\n },\n },\n};\n\nexport enum MessageType {\n MEDIA = 1,\n TEXT = 2,\n}\n\nexport enum RoutePermittedRole {\n Admin = \"admin\",\n User = \"user\",\n}\n"],"names":["css","ref","insertAt","document","head","getElementsByTagName","style","createElement","type","firstChild","insertBefore","appendChild","styleSheet","cssText","createTextNode","HISD3_COLORS","primary","primaryLight","headerSelectedBg","hisd3AntdTheme","token","colorPrimary","components","Menu","itemSelectedBg","itemSelectedColor","itemHoverBg","itemHoverColor","subMenuItemSelectedColor","itemActiveBg","horizontalItemSelectedBg","horizontalItemSelectedColor","Layout","siderBg","headerBg","triggerBg","triggerColor","Header","Content","HEADER_HEIGHT","StyledRoot","styled","theme","palette","borderColor","StyledSiderMenuWrap","div","StyledBrand","a","$collapsed","text","StyledHeader","StyledSiderHeader","StyledCollapseTrigger","button","sizes","borderRadius","base","StyledContent","List","StyledCrUserInfo","$inHeader","breakpoints","md","font","size","sm","StyledCrUserInfoInner","StyledCrUserInfoAvatar","Avatar","orange","StyledCrUserInfoContent","span","StyledUsernameInfo","StyledUsername","h3","weight","lg","StyledUserArrow","StyledCrUserDesignation","itemKey","item","index","key","path","toAntdMenuItems","items","renderLink","filter","hideInMenu","map","Array","isArray","children","length","icon","label","name","disabled","group","undefined","defaultRenderLink","href","UserMenu","account","avatarSrc","settingsUrl","onLogout","collapsed","placement","extraItems","modal","App","useApp","_jsx","SettingOutlined","onClick","window","location","LogoutOutlined","confirm","title","content","ExclamationCircleOutlined","onOk","initials","fullName","split","Boolean","slice","s","toUpperCase","join","jsx","className","Dropdown","trigger","menu","_jsxs","e","preventDefault","src","jsxs","DownOutlined","positionType","Sider","ThemeStyle","ThemeStyleRadius","ThemeMode","LayoutType","MenuStyle","NavStyle","FooterType","LayoutDirection","HeaderType","RouteTransition","Fonts","AuthType","AppAnimates","MessageType","RoutePermittedRole","SLIDEUPIN","hidden","y","visible","opacity","transition","ease","delay","when","duration","staggerChildren","SLIDEUPOUT","SLIDEDOWNIN","SLIDEDOWNOUT","SLIDELEFTIN","x","SLIDELEFTOUT","SLIDERIGHTIN","SLIDERIGHTOUT","FADEIN","scale","FADEOUT","NOANIMATION","variants","logoUrl","appName","menuItems","pathname","styledTheme","antdTheme","renderMenuLink","headerExtra","userMenuItems","onCollapse","loading","hideSidebar","layoutTop","hideCollapseTrigger","siderWidth","bareContent","isCollapsed","setIsCollapsed","useState","useEffect","useMemo","selection","best","walk","list","parents","forEach","startsWith","exact","selectedKey","openKeys","findSelection","setOpenKeys","prev","from","Set","toggleCollapse","next","selectedKeys","brand","alt","body","AntdApp","component","Spin","spinning","_Fragment","Fragment","mode","hasSider","width","collapsedWidth","collapsible","breakpoint","onBreakpoint","broken","inlineCollapsed","onOpenChange","keys","MenuUnfoldOutlined","MenuFoldOutlined","flex","ThemeProvider","ConfigProvider"],"mappings":"oJAAA,SAAqBA,EAAKC,QACX,IAARA,IAAiBA,EAAM,CAAE,GAC9B,IAAIC,EAAWD,EAAIC,SAEnB,GAAgC,oBAAbC,SAAnB,CAEA,IAAIC,EAAOD,SAASC,MAAQD,SAASE,qBAAqB,QAAQ,GAC9DC,EAAQH,SAASI,cAAc,SACnCD,EAAME,KAAO,WAEI,QAAbN,GACEE,EAAKK,WACPL,EAAKM,aAAaJ,EAAOF,EAAKK,YAKhCL,EAAKO,YAAYL,GAGfA,EAAMM,WACRN,EAAMM,WAAWC,QAAUb,EAE3BM,EAAMK,YAAYR,SAASW,eAAed,GAnBU,CAqBxD,mzFChBa,MAAAe,EAAe,CAC1BC,QAAS,UACTC,aAAc,UACdC,iBAAkB,oBAGPC,EAA8B,CACzCC,MAAO,CACLC,aAAcN,EAAaC,SAE7BM,WAAY,CACVC,KAAM,CACJC,eAAgBT,EAAaE,aAC7BQ,kBAAmBV,EAAaC,QAChCU,YAAaX,EAAaE,aAC1BU,eAAgBZ,EAAaC,QAC7BY,yBAA0Bb,EAAaC,QACvCa,aAAcd,EAAaE,aAC3Ba,yBAA0Bf,EAAaG,iBACvCa,4BAA6BhB,EAAaC,SAE5CgB,OAAQ,CACNC,QAAS,UACTC,SAAU,UACVC,UAAW,UACXC,aAAc,uBC/BdC,OAAEA,EAAMC,QAAEA,GAAYN,EAAMA,OAIrBO,EAAgB,GAEhBC,EAAaC,EAAOT,EAAAA,OAAO;;;;;;;;;;;;;QAahC,EAAGU,WAAYA,GAAOC,SAASC,aAAe;;;;;;;;EAUzCC,EAAsBJ,EAAOK,GAAG;;;;;;;;;EAWhCC,EAAcN,EAAOO,CAA2B;;;;YAIjDT;eACG,EAAGU,gBAAkBA,EAAa,GAAK;qBACjC,EAAGA,gBAAkBA,EAAa,SAAW;;;;;;;;;;;;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,YAAaA,EACbC,SAAUA,EACVC,UAAW6F,EACX5F,UAAU,WACVC,WAAYmF,OAIhBvD,OAAC1G,EAAAA,OAAM,CAAA6D,SAAA,CACL6C,EAAAA,KAACtF,EAAiB,CAAAyC,SAAA,EACdyG,GACApF,EAAAmB,IAAChF,EAAqB,CACpB7C,KAAK,SACO,aAAAiM,EAAc,cAAgB,gBAC1CrF,QAAS,IAAMyG,GAAgBpB,GAE9B5G,SAAA4G,EAAcvF,EAACmB,IAAA+G,yBAAwBlI,EAAAA,IAACmI,EAAgBA,iBAAG,MAGhEnI,cAAM5G,MAAO,CAAEgP,KAAM,KACpBtD,KAEFtE,YAkBT,OACER,EAAAA,IAACqI,EAAAA,cAAa,CAAC7M,MAAOmJ,EAAWhG,SAC9BiG,EACC5E,EAACmB,IAAAmH,EAAcA,eAAC,CAAA9M,MAAOoJ,EAAYjG,SAAAqI,IAAsB,GAI7C","x_google_ignoreList":[0]}
|
|
1
|
+
{"version":3,"file":"index.cjs.js","sources":["../node_modules/.pnpm/style-inject@0.3.0/node_modules/style-inject/dist/style-inject.es.js","../src/theme/antd.ts","../src/components/Provider/index.tsx","../src/theme/layout.ts","../src/components/Sidebar/index.styled.tsx","../src/components/Sidebar/menu.ts","../src/components/Sidebar/UserMenu.tsx","../src/components/Sidebar/index.tsx","../src/components/PageHeader/index.tsx","../src/components/Table/index.tsx","../src/components/Tabs/index.tsx","../src/components/Tag/index.tsx","../src/components/Button/index.tsx","../src/components/Input/index.tsx","../src/enum/theme.ts"],"sourcesContent":["function styleInject(css, ref) {\n if ( ref === void 0 ) ref = {};\n var insertAt = ref.insertAt;\n\n if (!css || typeof document === 'undefined') { return; }\n\n var head = document.head || document.getElementsByTagName('head')[0];\n var style = document.createElement('style');\n style.type = 'text/css';\n\n if (insertAt === 'top') {\n if (head.firstChild) {\n head.insertBefore(style, head.firstChild);\n } else {\n head.appendChild(style);\n }\n } else {\n head.appendChild(style);\n }\n\n if (style.styleSheet) {\n style.styleSheet.cssText = css;\n } else {\n style.appendChild(document.createTextNode(css));\n }\n}\n\nexport default styleInject;\n","import type { ThemeConfig } from \"antd\";\n\n/** Named primary-color presets. Any hex string is also accepted. */\nexport const HISD3_PRESETS = {\n red: \"#E5401C\",\n orange: \"#F26B1D\",\n teal: \"#00796B\",\n blue: \"#1D5FD1\",\n green: \"#2E7D32\",\n purple: \"#6A3FD6\",\n} as const;\n\nexport type HISD3Preset = keyof typeof HISD3_PRESETS;\n\n/** Neutral palette shared by every preset (the \"Backoffice\" look). */\nexport const HISD3_NEUTRALS = {\n bgLayout: \"#F3F2F0\",\n bgContainer: \"#F3F2F0\",\n bgElevated: \"#FFFFFF\",\n bgFilled: \"#E6E4E1\",\n text: \"#171717\",\n textSecondary: \"#4A4A4A\",\n textTertiary: \"#6E6E6E\",\n border: \"#1F1F1F\",\n borderSecondary: \"#CFCDC9\",\n white: \"#FFFFFF\",\n} as const;\n\nexport const HISD3_FONT_FAMILY =\n \"'Archivo', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif\";\n/** Archivo is used for both body (400) and headings (800). */\nexport const HISD3_FONT_WEIGHT_HEADING = 800;\nexport const HISD3_FONT_WEIGHT_BODY = 400;\n\nexport interface HISD3ThemeOptions {\n /** Preset name or any hex color. Default \"red\". */\n primary?: HISD3Preset | string;\n /** Corner radius in px. The Backoffice look is square (0). */\n radius?: number;\n /** Border width in px used by buttons, inputs, dividers. Default 2. */\n lineWidth?: number;\n /** Override / extend the generated antd theme. */\n overrides?: ThemeConfig;\n}\n\nexport const resolvePrimary = (primary: HISD3Preset | string = \"red\"): string =>\n (HISD3_PRESETS as Record<string, string>)[primary] ?? primary;\n\n/** Mix a hex color with white: amount 0 → color, 1 → white. */\nexport const tint = (hex: string, amount: number): string => {\n const h = hex.replace(\"#\", \"\");\n const full = h.length === 3 ? h.split(\"\").map((c) => c + c).join(\"\") : h;\n const n = parseInt(full, 16);\n const r = (n >> 16) & 255;\n const g = (n >> 8) & 255;\n const b = n & 255;\n const mix = (c: number) => Math.round(c + (255 - c) * amount);\n return `#${[mix(r), mix(g), mix(b)]\n .map((c) => c.toString(16).padStart(2, \"0\"))\n .join(\"\")}`;\n};\n\n/**\n * Build the HISD3 Ant Design v6 theme.\n *\n * ```ts\n * <ConfigProvider theme={createHisd3Theme({ primary: \"teal\" })}>\n * ```\n */\nexport const createHisd3Theme = ({\n primary,\n radius = 0,\n lineWidth = 2,\n overrides,\n}: HISD3ThemeOptions = {}): ThemeConfig => {\n const p = resolvePrimary(primary);\n const n = HISD3_NEUTRALS;\n\n const base: ThemeConfig = {\n cssVar: { key: \"hisd3\" },\n token: {\n colorPrimary: p,\n colorInfo: p,\n colorLink: p,\n colorPrimaryBg: tint(p, 0.92),\n colorPrimaryBgHover: tint(p, 0.86),\n colorPrimaryBorder: tint(p, 0.6),\n fontFamily: HISD3_FONT_FAMILY,\n fontSize: 14,\n fontWeightStrong: 700,\n borderRadius: radius,\n borderRadiusLG: radius,\n borderRadiusSM: radius,\n borderRadiusXS: radius,\n lineWidth,\n colorBgLayout: n.bgLayout,\n colorBgContainer: n.bgContainer,\n colorBgElevated: n.bgElevated,\n colorText: n.text,\n colorTextSecondary: n.textSecondary,\n colorTextTertiary: n.textTertiary,\n colorTextHeading: n.text,\n colorBorder: n.border,\n colorBorderSecondary: n.borderSecondary,\n colorSplit: n.borderSecondary,\n controlHeight: 40,\n controlHeightLG: 52,\n controlHeightSM: 32,\n boxShadow: \"none\",\n boxShadowSecondary: \"0 8px 24px rgba(0,0,0,0.12)\",\n },\n components: {\n Layout: {\n siderBg: n.bgLayout,\n headerBg: n.bgLayout,\n bodyBg: n.bgLayout,\n headerPadding: \"0 48px\",\n },\n Menu: {\n itemBg: \"transparent\",\n subMenuItemBg: \"transparent\",\n itemColor: n.text,\n itemHoverColor: n.text,\n itemHoverBg: \"rgba(0,0,0,0.04)\",\n itemSelectedBg: tint(p, 0.9),\n itemSelectedColor: p,\n itemActiveBg: tint(p, 0.86),\n subMenuItemSelectedColor: p,\n groupTitleColor: n.textTertiary,\n groupTitleFontSize: 12,\n itemBorderRadius: 0,\n itemMarginInline: 0,\n itemMarginBlock: 0,\n itemHeight: 46,\n itemPaddingInline: 24,\n iconSize: 18,\n collapsedIconSize: 18,\n activeBarBorderWidth: 0,\n activeBarWidth: 0,\n },\n Button: {\n fontWeight: 600,\n primaryShadow: \"none\",\n defaultShadow: \"none\",\n dangerShadow: \"none\",\n defaultBorderColor: n.border,\n defaultColor: n.text,\n defaultBg: n.bgLayout,\n defaultHoverBg: n.white,\n defaultHoverBorderColor: n.border,\n defaultHoverColor: n.text,\n defaultActiveBorderColor: n.border,\n paddingInline: 20,\n contentFontSizeLG: 16,\n },\n Input: {\n activeShadow: \"none\",\n colorBorder: n.borderSecondary,\n hoverBorderColor: n.border,\n activeBorderColor: n.border,\n paddingInline: 16,\n },\n Select: { optionSelectedBg: tint(p, 0.9), colorBorder: n.borderSecondary },\n Table: {\n headerBg: \"transparent\",\n headerColor: n.textTertiary,\n headerSplitColor: \"transparent\",\n headerBorderRadius: 0,\n borderColor: n.borderSecondary,\n rowHoverBg: \"rgba(0,0,0,0.03)\",\n cellPaddingBlock: 20,\n cellPaddingInline: 16,\n cellFontSize: 16,\n footerBg: \"transparent\",\n },\n Tabs: {\n inkBarColor: p,\n itemColor: n.text,\n itemSelectedColor: p,\n itemHoverColor: p,\n titleFontSize: 18,\n horizontalItemGutter: 48,\n horizontalMargin: \"0\",\n lineWidthBold: 4,\n },\n Tag: { borderRadiusSM: 0, defaultBg: \"transparent\" },\n Pagination: {\n itemBg: n.bgLayout,\n itemActiveBg: p,\n itemSize: 48,\n itemInputBg: n.bgLayout,\n },\n Dropdown: { paddingBlock: 10 },\n Breadcrumb: {\n itemColor: n.textTertiary,\n lastItemColor: n.text,\n linkColor: n.textTertiary,\n linkHoverColor: p,\n separatorColor: n.textTertiary,\n },\n Card: { headerFontSize: 20 },\n },\n };\n\n if (!overrides) return base;\n return {\n ...base,\n ...overrides,\n token: { ...base.token, ...overrides.token },\n components: { ...base.components, ...overrides.components },\n };\n};\n\n/** Default HISD3 theme — the red \"Backoffice\" look. */\nexport const hisd3AntdTheme: ThemeConfig = createHisd3Theme();\n\n/** @deprecated use HISD3_PRESETS / createHisd3Theme */\nexport const HISD3_COLORS = {\n primary: HISD3_PRESETS.red,\n primaryLight: tint(HISD3_PRESETS.red, 0.9),\n headerSelectedBg: \"rgba(0,0,0,0.04)\",\n} as const;\n","import { App as AntdApp, ConfigProvider, type ThemeConfig } from \"antd\";\nimport React, { createContext, useContext, useMemo } from \"react\";\nimport { ThemeProvider } from \"styled-components\";\n\nimport {\n createHisd3Theme,\n type HISD3Preset,\n type HISD3ThemeOptions,\n} from \"../../theme/antd\";\nimport type { StyledTheme } from \"../../types/theme\";\n\nconst HISD3ProviderContext = createContext(false);\n\n/** True when rendered somewhere below an `HISD3Provider`. */\nexport const useInsideHISD3Provider = () => useContext(HISD3ProviderContext);\n\nexport interface HISD3ProviderProps extends HISD3ThemeOptions {\n /** Shorthand: preset name or hex. Same as `options.primary`. */\n primary?: HISD3Preset | string;\n /** Legacy styled-components theme object used by older HISD3 screens. */\n styledTheme?: StyledTheme;\n /** Fully custom antd theme — skips `createHisd3Theme` entirely. */\n theme?: ThemeConfig;\n children: React.ReactNode;\n}\n\n/**\n * Root provider for HISD3 apps. Put it once at the top of the tree:\n *\n * ```tsx\n * <HISD3Provider primary=\"teal\">\n * <App />\n * </HISD3Provider>\n * ```\n *\n * It wires the antd `ConfigProvider` (with CSS variables enabled so every\n * kit component follows the chosen primary), antd `App` (for themed\n * `modal.confirm` / `message`), and the styled-components `ThemeProvider`.\n */\nexport const HISD3Provider: React.FC<HISD3ProviderProps> = ({\n primary,\n radius,\n lineWidth,\n overrides,\n theme,\n styledTheme = {},\n children,\n}) => {\n const antdTheme = useMemo(\n () => theme ?? createHisd3Theme({ primary, radius, lineWidth, overrides }),\n [theme, primary, radius, lineWidth, overrides],\n );\n\n return (\n <HISD3ProviderContext.Provider value={true}>\n <ConfigProvider theme={antdTheme}>\n <ThemeProvider theme={styledTheme}>\n <AntdApp component={false}>{children}</AntdApp>\n </ThemeProvider>\n </ConfigProvider>\n </HISD3ProviderContext.Provider>\n );\n};\n\nexport default HISD3Provider;\n","/** Shared layout metrics so the sidebar brand block and page top bar line up. */\nexport const HISD3_LAYOUT = {\n siderWidth: 280,\n siderCollapsedWidth: 72,\n topBarHeight: 88,\n pageGutter: 40,\n} as const;\n","import styled from \"styled-components\";\nimport { Layout } from \"antd\";\n\nimport { HISD3_LAYOUT } from \"../../theme/layout\";\n\nconst { Header, Content } = Layout;\n\nexport const SIDER_WIDTH = HISD3_LAYOUT.siderWidth;\nexport const SIDER_COLLAPSED_WIDTH = HISD3_LAYOUT.siderCollapsedWidth;\nexport const HEADER_HEIGHT = HISD3_LAYOUT.topBarHeight;\n\nexport const StyledRoot = styled(Layout)`\n min-height: 100vh;\n background: var(--ant-color-bg-layout);\n\n /*\n * The Sider is rendered as a plain antd <Sider> (not styled(Sider)) because\n * styled-components would swallow its \\`theme\\` prop; style it from here.\n */\n > .ant-layout-sider.hisd3-sider {\n position: sticky;\n top: 0;\n height: 100vh;\n overflow: hidden;\n background: var(--ant-color-bg-layout);\n border-right: 2px solid var(--ant-color-border);\n\n .ant-layout-sider-children {\n display: flex;\n flex-direction: column;\n height: 100%;\n }\n }\n`;\n\nexport const StyledSiderMenuWrap = styled.div`\n flex: 1 1 auto;\n overflow-y: auto;\n overflow-x: hidden;\n padding-top: 8px;\n\n .ant-menu-inline,\n .ant-menu-vertical {\n border-inline-end: none !important;\n background: transparent;\n }\n\n /* Section titles: \"RECEIVABLES AND COLLECTIONS\" */\n .ant-menu-item-group-title {\n padding: 22px 24px 8px;\n font-size: 12px;\n font-weight: 600;\n letter-spacing: 0.14em;\n text-transform: uppercase;\n color: var(--ant-color-text-tertiary);\n }\n\n .ant-menu-item-group + .ant-menu-item-group > .ant-menu-item-group-title,\n .ant-menu-item-group + .ant-menu-item-group::before {\n border-top: 2px solid var(--ant-color-border-secondary);\n margin-top: 12px;\n padding-top: 26px;\n }\n .ant-menu-item-group + .ant-menu-item-group::before {\n content: none;\n }\n\n .ant-menu-item,\n .ant-menu-submenu-title {\n font-size: 17px;\n font-weight: 500;\n position: relative;\n width: 100%;\n }\n\n .ant-menu-item .ant-menu-item-icon,\n .ant-menu-submenu-title .ant-menu-item-icon {\n font-size: 18px;\n }\n\n /* open parent (\"Billing\") in primary */\n .ant-menu-submenu-open > .ant-menu-submenu-title,\n .ant-menu-submenu-selected > .ant-menu-submenu-title {\n color: var(--ant-color-primary);\n font-weight: 700;\n }\n\n /* child items are indented by antd; keep them slightly smaller */\n .ant-menu-sub.ant-menu-inline > .ant-menu-item {\n font-size: 16px;\n }\n\n /* active item: tint + 4px accent bar */\n .ant-menu-item-selected {\n font-weight: 700;\n\n &::before {\n content: \"\";\n position: absolute;\n left: 0;\n top: 0;\n bottom: 0;\n width: 5px;\n background: var(--ant-color-primary);\n }\n }\n\n &.hisd3-collapsed .ant-menu-item-group-title {\n display: none;\n }\n`;\n\nexport const StyledBrand = styled.a<{ $collapsed?: boolean }>`\n display: flex;\n align-items: center;\n gap: 16px;\n height: ${HEADER_HEIGHT}px;\n padding: 0 ${({ $collapsed }) => ($collapsed ? 14 : 24)}px;\n justify-content: ${({ $collapsed }) => ($collapsed ? \"center\" : \"flex-start\")};\n color: inherit;\n text-decoration: none;\n overflow: hidden;\n white-space: nowrap;\n flex: 0 0 auto;\n border-bottom: 2px solid var(--ant-color-border);\n\n .hisd3-brand-mark {\n width: 40px;\n height: 40px;\n flex: 0 0 auto;\n background: var(--ant-color-primary);\n display: flex;\n align-items: center;\n justify-content: center;\n }\n\n img {\n height: 40px;\n width: 40px;\n object-fit: contain;\n flex: 0 0 auto;\n }\n\n h1 {\n margin: 0;\n font-family: var(--font-heading);\n font-size: 22px;\n font-weight: var(--font-weight-heading, 800);\n letter-spacing: 0.04em;\n text-transform: uppercase;\n color: var(--ant-color-text);\n overflow: hidden;\n text-overflow: ellipsis;\n }\n`;\n\nexport const StyledHeader = styled(Header)`\n display: flex;\n align-items: center;\n gap: 24px;\n height: ${HEADER_HEIGHT}px;\n line-height: ${HEADER_HEIGHT}px;\n padding: 0 ${HISD3_LAYOUT.pageGutter}px;\n position: sticky;\n top: 0;\n z-index: 100;\n background: var(--ant-color-bg-layout);\n border-bottom: 2px solid var(--ant-color-border);\n\n .ant-menu-horizontal {\n flex: 1 1 auto;\n min-width: 0;\n border-bottom: none;\n background: transparent;\n line-height: ${HEADER_HEIGHT - 2}px;\n font-size: 16px;\n font-weight: 500;\n }\n`;\n\nexport const StyledSiderHeader = styled(Header)`\n display: flex;\n align-items: center;\n gap: 16px;\n height: ${HEADER_HEIGHT}px;\n line-height: ${HEADER_HEIGHT}px;\n padding: 0 ${HISD3_LAYOUT.pageGutter}px;\n position: sticky;\n top: 0;\n z-index: 99;\n background: var(--ant-color-bg-layout);\n border-bottom: 2px solid var(--ant-color-border);\n`;\n\nexport const StyledCollapseTrigger = styled.button`\n border: 2px solid var(--ant-color-border);\n background: transparent;\n cursor: pointer;\n font-size: 16px;\n width: 40px;\n height: 40px;\n color: inherit;\n display: inline-flex;\n align-items: center;\n justify-content: center;\n flex: 0 0 auto;\n\n &:hover {\n background: rgba(0, 0, 0, 0.05);\n }\n`;\n\nexport const StyledContent = styled(Content)`\n padding: 32px ${HISD3_LAYOUT.pageGutter}px 48px;\n min-height: calc(100vh - ${HEADER_HEIGHT}px);\n`;\n\n/* ---------- account card (sider footer / header) ---------- */\n\nexport const StyledCrUserInfo = styled.div<{\n $collapsed?: boolean;\n $inHeader?: boolean;\n}>`\n flex: 0 0 auto;\n display: flex;\n flex-direction: column;\n justify-content: center;\n line-height: 1.25;\n transition: all 0.2s ease;\n padding: ${({ $inHeader, $collapsed }) =>\n $inHeader ? \"0 4px\" : $collapsed ? \"16px 0\" : \"20px 24px\"};\n min-width: ${({ $inHeader }) => ($inHeader ? \"220px\" : \"0\")};\n border-top: ${({ $inHeader }) =>\n $inHeader ? \"none\" : \"2px solid var(--ant-color-border)\"};\n\n & .ant-dropdown-link {\n color: inherit;\n }\n`;\n\nexport const StyledCrUserInfoInner = styled.a`\n display: flex;\n align-items: center;\n justify-content: center;\n cursor: pointer;\n color: inherit;\n gap: 16px;\n`;\n\nexport const StyledCrUserInfoAvatar = styled.span<{ $src?: string }>`\n width: 48px;\n height: 48px;\n flex: 0 0 auto;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 16px;\n font-weight: 700;\n color: var(--ant-color-text);\n background: ${({ $src }) =>\n $src ? `center / cover no-repeat url(\"${$src}\")` : \"#D9D6D2\"};\n`;\n\nexport const StyledCrUserInfoContent = styled.span`\n flex: 1 1 auto;\n min-width: 0;\n`;\n\nexport const StyledUsernameInfo = styled.span`\n display: flex;\n align-items: flex-start;\n justify-content: space-between;\n gap: 8px;\n`;\n\nexport const StyledUsername = styled.h3`\n margin: 0;\n font-family: var(--font-body);\n font-size: 17px;\n font-weight: 700;\n letter-spacing: 0;\n color: var(--ant-color-text);\n overflow: hidden;\n text-overflow: ellipsis;\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n`;\n\nexport const StyledUserArrow = styled.span`\n width: 20px;\n height: 22px;\n display: flex;\n align-items: center;\n justify-content: center;\n flex: 0 0 auto;\n color: var(--ant-color-text);\n\n & svg {\n display: block;\n }\n`;\n\nexport const StyledCrUserDesignation = styled.span`\n display: block;\n margin-top: 4px;\n font-size: 12px;\n font-weight: 500;\n letter-spacing: 0.12em;\n text-transform: uppercase;\n color: var(--ant-color-text-tertiary);\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n`;\n","import type { MenuProps } from \"antd\";\nimport { createElement, type ReactNode } from \"react\";\n\nexport type AntdMenuItem = Required<MenuProps>[\"items\"][number];\n\n/**\n * Menu item shape accepted by HISD3Sidebar.\n *\n * This intentionally mirrors the `MenuDataItem` shape that the previous\n * ProLayout-based sidebar consumed (`path`, `name`, `icon`, `children`,\n * `hideInMenu`), so existing apps keep passing the same `menuItems`.\n */\nexport interface HISD3MenuItem {\n key?: string;\n path?: string;\n name?: ReactNode;\n icon?: ReactNode;\n children?: HISD3MenuItem[];\n hideInMenu?: boolean;\n disabled?: boolean;\n /** When true the item is rendered as a group title (like ProLayout's `flatMenu`). */\n group?: boolean;\n [key: string]: unknown;\n}\n\nexport const itemKey = (item: HISD3MenuItem, index: number): string =>\n item.key ?? item.path ?? `menu-${index}`;\n\n/** Convert HISD3MenuItem[] to antd `Menu` items, rendering leaf items as anchors. */\nexport const toAntdMenuItems = (\n items: HISD3MenuItem[] | undefined,\n renderLink: (item: HISD3MenuItem, label: ReactNode) => ReactNode,\n): AntdMenuItem[] =>\n (items ?? [])\n .filter((item) => item && !item.hideInMenu)\n .map((item, index): AntdMenuItem => {\n const key = itemKey(item, index);\n const hasChildren = Array.isArray(item.children) && item.children.length > 0;\n\n if (hasChildren) {\n return {\n key,\n icon: item.icon,\n label: item.name,\n disabled: item.disabled,\n type: item.group ? \"group\" : undefined,\n children: toAntdMenuItems(item.children, renderLink),\n } as AntdMenuItem;\n }\n\n return {\n key,\n icon: item.icon,\n disabled: item.disabled,\n label: renderLink(item, item.name),\n } as AntdMenuItem;\n });\n\n/**\n * Find the key of the item whose `path` best matches `pathname`\n * (longest prefix wins) together with the keys of all its ancestors,\n * so the correct submenu can be opened.\n */\nexport const findSelection = (\n items: HISD3MenuItem[] | undefined,\n pathname: string,\n): { selectedKey?: string; openKeys: string[] } => {\n let best: { key: string; parents: string[]; length: number } | undefined;\n\n const walk = (list: HISD3MenuItem[] | undefined, parents: string[]) => {\n (list ?? []).forEach((item, index) => {\n const key = itemKey(item, index);\n if (item.path && pathname.startsWith(item.path)) {\n const exact = pathname === item.path;\n const length = item.path.length + (exact ? 1 : 0);\n if (!best || length > best.length) {\n best = { key, parents, length };\n }\n }\n if (item.children?.length) {\n walk(item.children, [...parents, key]);\n }\n });\n };\n\n walk(items, []);\n return { selectedKey: best?.key, openKeys: best?.parents ?? [] };\n};\n\n/** Default anchor renderer used when no `renderMenuLink` is supplied. */\nexport const defaultRenderLink = (item: HISD3MenuItem, label: ReactNode) =>\n createElement(\"a\", { href: item.path || \"/\" }, label);\n","import {\n DownOutlined,\n ExclamationCircleOutlined,\n LogoutOutlined,\n SettingOutlined,\n} from \"@ant-design/icons\";\nimport { App, Dropdown, type MenuProps } from \"antd\";\nimport React from \"react\";\n\nimport type { IUserEmployee } from \"../../types/account\";\nimport {\n StyledCrUserDesignation,\n StyledCrUserInfo,\n StyledCrUserInfoAvatar,\n StyledCrUserInfoContent,\n StyledCrUserInfoInner,\n StyledUserArrow,\n StyledUsername,\n StyledUsernameInfo,\n} from \"./index.styled\";\n\nexport interface UserMenuProps {\n account: IUserEmployee;\n avatarSrc?: string;\n settingsUrl?: string;\n onLogout: () => Promise<void> | void;\n collapsed?: boolean;\n /** \"topRight\" for the sider footer, \"bottomRight\" for the top header. */\n placement?: \"topRight\" | \"bottomRight\";\n extraItems?: MenuProps[\"items\"];\n}\n\n/**\n * Account dropdown (Settings / Logout) shown in the sider footer or header.\n * Uses `App.useApp()` so the confirm modal picks up the surrounding\n * ConfigProvider theme — the static `Modal.confirm` cannot in antd v6.\n */\nexport const UserMenu: React.FC<UserMenuProps> = ({\n account,\n avatarSrc,\n settingsUrl,\n onLogout,\n collapsed = false,\n placement = \"topRight\",\n extraItems = [],\n}) => {\n const { modal } = App.useApp();\n\n const confirmLogout = () => {\n modal.confirm({\n title: \"Are you sure you want to logout?\",\n content: \"Please click OK to continue\",\n icon: <ExclamationCircleOutlined />,\n onOk: onLogout,\n });\n };\n\n const items: MenuProps[\"items\"] = [\n ...(extraItems ?? []),\n {\n key: \"settings\",\n icon: <SettingOutlined />,\n label: \"Settings\",\n onClick: () => {\n window.location.href = settingsUrl ?? \"/settings\";\n },\n },\n {\n key: \"logout\",\n icon: <LogoutOutlined />,\n label: \"Logout\",\n onClick: confirmLogout,\n },\n ];\n\n const initials =\n (account.fullName || \"\")\n .replace(/\\(.*?\\)/g, \" \")\n .split(/[\\s,]+/)\n .map((w) => w.replace(/[^\\p{L}\\p{N}]/gu, \"\"))\n .filter(Boolean)\n .slice(0, 2)\n .map((w) => w[0].toUpperCase())\n .join(\"\") || \"?\";\n\n return (\n <StyledCrUserInfo\n className=\"cr-user-info-light\"\n $collapsed={collapsed}\n $inHeader={placement === \"bottomRight\"}\n >\n <Dropdown trigger={[\"click\"]} placement={placement} menu={{ items }}>\n <StyledCrUserInfoInner\n className=\"ant-dropdown-link\"\n onClick={(e) => e.preventDefault()}\n >\n <StyledCrUserInfoAvatar $src={avatarSrc} aria-hidden>\n {!avatarSrc && initials}\n </StyledCrUserInfoAvatar>\n {!collapsed && (\n <StyledCrUserInfoContent>\n <StyledUsernameInfo>\n <StyledUsername title={account.fullName}>\n {account.fullName}\n </StyledUsername>\n <StyledUserArrow>\n <DownOutlined />\n </StyledUserArrow>\n </StyledUsernameInfo>\n {account.positionType && (\n <StyledCrUserDesignation title={account.positionType}>\n {account.positionType}\n </StyledCrUserDesignation>\n )}\n </StyledCrUserInfoContent>\n )}\n </StyledCrUserInfoInner>\n </Dropdown>\n </StyledCrUserInfo>\n );\n};\n\nexport default UserMenu;\n","import { MenuFoldOutlined, MenuUnfoldOutlined } from \"@ant-design/icons\";\nimport {\n App as AntdApp,\n ConfigProvider,\n Layout,\n Menu,\n Spin,\n type MenuProps,\n type ThemeConfig,\n} from \"antd\";\nimport React, { useEffect, useMemo, useState, type ReactNode } from \"react\";\nimport { ThemeProvider } from \"styled-components\";\n\nimport { hisd3AntdTheme } from \"../../theme/antd\";\nimport { useInsideHISD3Provider } from \"../Provider\";\nimport type { IUserEmployee } from \"../../types/account\";\nimport type { StyledTheme } from \"../../types/theme\";\nimport {\n SIDER_COLLAPSED_WIDTH,\n SIDER_WIDTH,\n StyledBrand,\n StyledCollapseTrigger,\n StyledContent,\n StyledHeader,\n StyledRoot,\n StyledSiderHeader,\n StyledSiderMenuWrap,\n} from \"./index.styled\";\nimport {\n defaultRenderLink,\n findSelection,\n toAntdMenuItems,\n type HISD3MenuItem,\n} from \"./menu\";\nimport { UserMenu } from \"./UserMenu\";\n\nconst { Sider } = Layout;\n\nexport interface HISD3SidebarProps {\n account: IUserEmployee;\n /** Logo image URL. When omitted a square block in the primary color is shown. */\n logoUrl?: string;\n appName: string;\n /** Same shape as before (ProLayout `MenuDataItem`): `{ path, name, icon, children }`. */\n menuItems: HISD3MenuItem[];\n onLogout: () => Promise<void> | void;\n /** Current location pathname, used to highlight the active menu item. */\n pathname: string;\n /** styled-components theme; optional when inside HISD3Provider. */\n styledTheme?: StyledTheme;\n collapsed?: boolean;\n /** Called when the user toggles the sider (controlled usage). */\n onCollapse?: (collapsed: boolean) => void;\n loading?: boolean;\n hideSidebar?: boolean;\n /** Render the navigation as a top header bar instead of a left sider. */\n layoutTop?: boolean;\n avatarSrc?: string;\n settingsUrl?: string;\n /**\n * Ant Design theme applied via a nested `ConfigProvider`.\n * Defaults to `hisd3AntdTheme` (red) when used standalone. Inside an\n * `HISD3Provider` nothing is applied so the provider's primary is inherited.\n * Pass `null` to force inheritance, or a ThemeConfig to override.\n */\n antdTheme?: ThemeConfig | null;\n /**\n * Custom link renderer, e.g. to use react-router's `<Link>`:\n * `(item, label) => <Link to={item.path!}>{label}</Link>`\n */\n renderMenuLink?: (item: HISD3MenuItem, label: ReactNode) => ReactNode;\n /** Extra content rendered in the header, right side (top layout) or sider header (side layout). */\n headerExtra?: ReactNode;\n /** Extra items prepended to the account dropdown. */\n userMenuItems?: MenuProps[\"items\"];\n /** Hide the collapse trigger button. */\n hideCollapseTrigger?: boolean;\n /** Width in px of the expanded sider. Default 220. */\n siderWidth?: number;\n /** Disable the built-in content padding wrapper and render children directly. */\n bareContent?: boolean;\n /**\n * Hide the sider layout's own top bar (collapse trigger + headerExtra).\n * Use together with `HISD3PageHeader`, which renders its own top bar.\n */\n hideHeaderBar?: boolean;\n /** Where the brand block links to. Default \"/\". */\n brandHref?: string;\n children: React.ReactNode;\n}\n\nexport const HISD3Sidebar: React.FC<HISD3SidebarProps> = ({\n children,\n account,\n logoUrl,\n appName,\n menuItems,\n onLogout,\n pathname,\n avatarSrc,\n styledTheme,\n settingsUrl,\n antdTheme,\n renderMenuLink = defaultRenderLink,\n headerExtra,\n userMenuItems,\n onCollapse,\n collapsed = false,\n loading = false,\n hideSidebar = false,\n layoutTop = false,\n hideCollapseTrigger = false,\n siderWidth = SIDER_WIDTH,\n bareContent = false,\n hideHeaderBar = false,\n brandHref = \"/\",\n}) => {\n const insideProvider = useInsideHISD3Provider();\n const resolvedTheme =\n antdTheme === undefined ? (insideProvider ? null : hisd3AntdTheme) : antdTheme;\n const [isCollapsed, setIsCollapsed] = useState(collapsed);\n\n useEffect(() => {\n setIsCollapsed(collapsed);\n }, [collapsed]);\n\n const items = useMemo(\n () => toAntdMenuItems(menuItems, renderMenuLink),\n [menuItems, renderMenuLink],\n );\n\n const selection = useMemo(\n () => findSelection(menuItems, pathname),\n [menuItems, pathname],\n );\n\n // Start with the active route's submenu open so there is no flash on first paint.\n const [openKeys, setOpenKeys] = useState<string[]>(() => selection.openKeys);\n\n // Open the submenu that contains the active route whenever the route changes.\n useEffect(() => {\n setOpenKeys((prev) =>\n Array.from(new Set([...prev, ...selection.openKeys])),\n );\n }, [selection.openKeys.join(\"|\")]);\n\n const toggleCollapse = (next: boolean) => {\n setIsCollapsed(next);\n onCollapse?.(next);\n };\n\n const selectedKeys = selection.selectedKey ? [selection.selectedKey] : [];\n\n const brand = (\n <StyledBrand href={brandHref} $collapsed={!layoutTop && isCollapsed}>\n {logoUrl ? (\n <img src={logoUrl} alt={appName} />\n ) : (\n <span className=\"hisd3-brand-mark\" aria-hidden />\n )}\n {(layoutTop || !isCollapsed) && <h1>{appName}</h1>}\n </StyledBrand>\n );\n\n const content = bareContent ? (\n children\n ) : (\n <StyledContent>{children}</StyledContent>\n );\n\n const renderBody = () => {\n if (hideSidebar) {\n return <>{children}</>;\n }\n\n if (layoutTop) {\n return (\n <StyledRoot>\n <StyledHeader>\n {brand}\n <Menu\n mode=\"horizontal\"\n items={items}\n selectedKeys={selectedKeys}\n />\n {headerExtra}\n <UserMenu\n account={account}\n avatarSrc={avatarSrc}\n settingsUrl={settingsUrl}\n onLogout={onLogout}\n placement=\"bottomRight\"\n extraItems={userMenuItems}\n />\n </StyledHeader>\n {content}\n </StyledRoot>\n );\n }\n\n return (\n <StyledRoot hasSider>\n <Sider\n className=\"hisd3-sider\"\n width={siderWidth}\n collapsedWidth={SIDER_COLLAPSED_WIDTH}\n collapsible\n collapsed={isCollapsed}\n trigger={null}\n theme=\"light\"\n breakpoint=\"lg\"\n onBreakpoint={(broken) => {\n if (broken) toggleCollapse(true);\n }}\n >\n {brand}\n <StyledSiderMenuWrap className={isCollapsed ? \"hisd3-collapsed\" : undefined}>\n <Menu\n mode=\"inline\"\n theme=\"light\"\n inlineCollapsed={isCollapsed}\n items={items}\n selectedKeys={selectedKeys}\n openKeys={isCollapsed ? undefined : openKeys}\n onOpenChange={(keys) => setOpenKeys(keys as string[])}\n />\n </StyledSiderMenuWrap>\n <UserMenu\n account={account}\n avatarSrc={avatarSrc}\n settingsUrl={settingsUrl}\n onLogout={onLogout}\n collapsed={isCollapsed}\n placement=\"topRight\"\n extraItems={userMenuItems}\n />\n </Sider>\n\n <Layout style={{ background: \"transparent\" }}>\n {!hideHeaderBar && (\n <StyledSiderHeader>\n {!hideCollapseTrigger && (\n <StyledCollapseTrigger\n type=\"button\"\n aria-label={isCollapsed ? \"Expand menu\" : \"Collapse menu\"}\n onClick={() => toggleCollapse(!isCollapsed)}\n >\n {isCollapsed ? <MenuUnfoldOutlined /> : <MenuFoldOutlined />}\n </StyledCollapseTrigger>\n )}\n <span style={{ flex: 1 }} />\n {headerExtra}\n </StyledSiderHeader>\n )}\n {content}\n </Layout>\n </StyledRoot>\n );\n };\n\n if (typeof document === \"undefined\") {\n return null;\n }\n\n const body = (\n <AntdApp component={false}>\n <Spin spinning={loading} size=\"large\">\n {renderBody()}\n </Spin>\n </AntdApp>\n );\n\n if (insideProvider && !styledTheme) {\n return resolvedTheme ? (\n <ConfigProvider theme={resolvedTheme}>{body}</ConfigProvider>\n ) : (\n body\n );\n }\n\n return (\n <ThemeProvider theme={styledTheme ?? {}}>\n {resolvedTheme ? (\n <ConfigProvider theme={resolvedTheme}>{body}</ConfigProvider>\n ) : (\n body\n )}\n </ThemeProvider>\n );\n};\n\nexport default HISD3Sidebar;\n","import { Breadcrumb } from \"antd\";\nimport React from \"react\";\nimport styled from \"styled-components\";\n\nimport { HISD3_LAYOUT } from \"../../theme/layout\";\n\nexport interface HISD3BreadcrumbItem {\n title: React.ReactNode;\n href?: string;\n onClick?: () => void;\n}\n\nexport interface HISD3PageHeaderProps {\n title: React.ReactNode;\n subtitle?: React.ReactNode;\n breadcrumb?: HISD3BreadcrumbItem[];\n /** Action buttons rendered on the right of the top bar. */\n extra?: React.ReactNode;\n /** Content rendered to the left of the breadcrumb (e.g. the sidebar collapse trigger). */\n leading?: React.ReactNode;\n /** Hide the top bar entirely and render only the title block. */\n hideTopBar?: boolean;\n className?: string;\n}\n\nexport const PAGE_GUTTER = HISD3_LAYOUT.pageGutter;\n\nconst TopBar = styled.div`\n display: flex;\n align-items: center;\n gap: 24px;\n height: ${HISD3_LAYOUT.topBarHeight}px; /* same as the sidebar brand block */\n padding: 0 ${PAGE_GUTTER}px;\n border-bottom: 2px solid var(--ant-color-border);\n background: var(--ant-color-bg-layout);\n position: sticky;\n top: 0;\n z-index: 20;\n\n .ant-breadcrumb {\n font-size: 16px;\n flex: 1 1 auto;\n min-width: 0;\n }\n\n .ant-breadcrumb ol {\n flex-wrap: nowrap;\n }\n`;\n\nconst Actions = styled.div`\n display: flex;\n align-items: center;\n gap: 16px;\n flex: 0 0 auto;\n`;\n\nconst TitleBlock = styled.div`\n display: flex;\n align-items: baseline;\n gap: 24px;\n flex-wrap: wrap;\n padding: 36px ${PAGE_GUTTER}px 28px;\n border-bottom: 2px solid var(--ant-color-border-secondary);\n\n h1 {\n margin: 0;\n font-family: var(--font-heading);\n font-size: 56px;\n line-height: 1.05;\n font-weight: var(--font-weight-heading, 800);\n letter-spacing: -0.02em;\n color: var(--ant-color-text);\n }\n\n p {\n margin: 0;\n font-size: 20px;\n color: var(--ant-color-text-secondary);\n }\n`;\n\n/** Padded body area that lines up with the header gutters. */\nexport const HISD3PageBody = styled.div`\n padding: 32px ${PAGE_GUTTER}px 48px;\n`;\n\n/**\n * Sticky top bar (breadcrumb + actions) followed by a big page title block.\n * Designed to sit directly inside `HISD3Sidebar` with `bareContent` and\n * `hideHeaderBar`.\n */\nexport const HISD3PageHeader: React.FC<HISD3PageHeaderProps> = ({\n title,\n subtitle,\n breadcrumb,\n extra,\n leading,\n hideTopBar = false,\n className,\n}) => (\n <header className={className}>\n {!hideTopBar && (\n <TopBar>\n {leading}\n {breadcrumb && breadcrumb.length > 0 && (\n <Breadcrumb\n items={breadcrumb.map((b) => ({\n title: b.href ? <a href={b.href}>{b.title}</a> : b.title,\n onClick: b.onClick,\n }))}\n />\n )}\n {!breadcrumb?.length && <span style={{ flex: 1 }} />}\n {extra && <Actions>{extra}</Actions>}\n </TopBar>\n )}\n <TitleBlock>\n <h1>{title}</h1>\n {subtitle && <p>{subtitle}</p>}\n </TitleBlock>\n </header>\n);\n\nexport default HISD3PageHeader;\n","import { LeftOutlined, RightOutlined } from \"@ant-design/icons\";\nimport { Pagination, Table, type TableProps } from \"antd\";\nimport type { AnyObject } from \"antd/es/_util/type\";\nimport React from \"react\";\nimport styled from \"styled-components\";\n\nexport interface HISD3TablePagination {\n current: number;\n pageSize: number;\n total: number;\n onChange: (page: number, pageSize: number) => void;\n /** Page-size toggle buttons on the right. Default [10, 20, 50]. */\n pageSizeOptions?: number[];\n /** Custom total text. Default \"Total 7,223 items\". */\n renderTotal?: (total: number, range: [number, number]) => React.ReactNode;\n /** Hide the page-size buttons. */\n hidePageSize?: boolean;\n}\n\nexport interface HISD3TableProps<T extends AnyObject>\n extends Omit<TableProps<T>, \"pagination\" | \"footer\"> {\n /** HISD3 pagination bar (total · pages · page-size). Omit for no pagination. */\n pagination?: HISD3TablePagination | false;\n /** Optional summary strip rendered between the rows and the pagination bar. */\n footer?: React.ReactNode;\n}\n\nconst Wrap = styled.div`\n .ant-table-wrapper .ant-table {\n background: transparent;\n }\n\n .ant-table-wrapper .ant-table-thead > tr > th {\n font-size: 13px;\n font-weight: 700;\n letter-spacing: 0.1em;\n text-transform: uppercase;\n color: var(--ant-color-text-tertiary);\n padding-block: 14px;\n border-bottom: 2px solid var(--ant-color-border);\n background: transparent;\n }\n\n .ant-table-wrapper .ant-table-tbody > tr > td {\n border-bottom: 2px solid var(--ant-color-border-secondary);\n font-size: 16px;\n }\n\n .ant-table-wrapper .ant-table-tbody > tr:last-child > td {\n border-bottom: 2px solid var(--ant-color-border);\n }\n\n .ant-table-wrapper .ant-table-thead > tr > th:first-child,\n .ant-table-wrapper .ant-table-tbody > tr > td:first-child {\n padding-left: 0;\n }\n\n .ant-table-wrapper .ant-table-thead > tr > th:last-child,\n .ant-table-wrapper .ant-table-tbody > tr > td:last-child {\n padding-right: 0;\n }\n\n .ant-table-wrapper .ant-table-cell-row-hover {\n background: rgba(0, 0, 0, 0.025) !important;\n }\n\n /* Highlighted / linked cell text, e.g. bill numbers */\n .hisd3-cell-primary {\n color: var(--ant-color-primary);\n font-weight: 700;\n }\n .hisd3-cell-link {\n color: var(--ant-color-primary);\n }\n .hisd3-cell-muted {\n color: var(--ant-color-text-tertiary);\n }\n`;\n\nconst FooterStrip = styled.div`\n padding: 22px 0 14px;\n font-size: 13px;\n font-weight: 600;\n letter-spacing: 0.1em;\n text-transform: uppercase;\n color: var(--ant-color-text-tertiary);\n`;\n\nconst PagerBar = styled.div`\n display: flex;\n align-items: center;\n gap: 24px;\n padding: 20px 0 8px;\n\n .hisd3-total {\n flex: 1 1 auto;\n font-size: 16px;\n color: var(--ant-color-text-secondary);\n }\n\n .ant-pagination {\n display: inline-flex;\n border: 2px solid var(--ant-color-border);\n\n .ant-pagination-item,\n .ant-pagination-prev,\n .ant-pagination-next,\n .ant-pagination-jump-prev,\n .ant-pagination-jump-next {\n margin: 0;\n min-width: 56px;\n height: 56px;\n line-height: 56px;\n border: 0;\n border-right: 2px solid var(--ant-color-border);\n border-radius: 0;\n font-weight: 700;\n font-size: 16px;\n background: transparent;\n\n &:last-child {\n border-right: 0;\n }\n\n a {\n color: var(--ant-color-text);\n }\n }\n\n .ant-pagination-item-active {\n background: var(--ant-color-primary);\n a {\n color: #fff;\n }\n }\n\n .ant-pagination-prev .ant-pagination-item-link,\n .ant-pagination-next .ant-pagination-item-link {\n color: var(--ant-color-text);\n font-size: 14px;\n }\n\n .ant-pagination-jump-prev .ant-pagination-item-container .ant-pagination-item-ellipsis,\n .ant-pagination-jump-next .ant-pagination-item-container .ant-pagination-item-ellipsis {\n color: var(--ant-color-text);\n font-weight: 700;\n }\n }\n`;\n\nconst SizeGroup = styled.div`\n display: inline-flex;\n border: 2px solid var(--ant-color-border);\n\n button {\n height: 56px;\n padding: 0 22px;\n border: 0;\n border-right: 2px solid var(--ant-color-border);\n background: transparent;\n font: inherit;\n font-size: 16px;\n color: var(--ant-color-text);\n cursor: pointer;\n\n &:last-child {\n border-right: 0;\n }\n\n &[aria-pressed=\"true\"] {\n background: var(--ant-color-primary);\n color: #fff;\n }\n }\n`;\n\nconst defaultTotal = (total: number) =>\n `Total ${total.toLocaleString()} items`;\n\nexport function HISD3Table<T extends AnyObject>({\n pagination,\n footer,\n ...tableProps\n}: HISD3TableProps<T>) {\n const p = pagination || undefined;\n const sizes = p?.pageSizeOptions ?? [10, 20, 50];\n\n return (\n <Wrap>\n <Table<T> {...tableProps} pagination={false} />\n\n {footer && <FooterStrip>{footer}</FooterStrip>}\n\n {p && (\n <PagerBar>\n <span className=\"hisd3-total\">\n {(p.renderTotal ?? defaultTotal)(p.total, [\n (p.current - 1) * p.pageSize + 1,\n Math.min(p.current * p.pageSize, p.total),\n ])}\n </span>\n <Pagination\n current={p.current}\n pageSize={p.pageSize}\n total={p.total}\n showSizeChanger={false}\n onChange={(page, size) => p.onChange(page, size)}\n itemRender={(_, type, el) => {\n if (type === \"prev\") return <span className=\"ant-pagination-item-link\"><LeftOutlined /></span>;\n if (type === \"next\") return <span className=\"ant-pagination-item-link\"><RightOutlined /></span>;\n return el;\n }}\n />\n {!p.hidePageSize && (\n <SizeGroup role=\"group\" aria-label=\"Rows per page\">\n {sizes.map((s) => (\n <button\n key={s}\n type=\"button\"\n aria-pressed={s === p.pageSize}\n onClick={() => p.onChange(1, s)}\n >\n {s} / page\n </button>\n ))}\n </SizeGroup>\n )}\n </PagerBar>\n )}\n </Wrap>\n );\n}\n\nexport default HISD3Table;\n","import { Tabs, type TabsProps } from \"antd\";\nimport React from \"react\";\nimport styled from \"styled-components\";\n\nexport interface HISD3TabItem {\n key: string;\n label: React.ReactNode;\n /** Optional count badge rendered after the label (e.g. \"All Patients 10\"). */\n count?: number | string;\n disabled?: boolean;\n children?: React.ReactNode;\n}\n\nexport interface HISD3TabsProps extends Omit<TabsProps, \"items\"> {\n items: HISD3TabItem[];\n}\n\nconst StyledTabs = styled(Tabs)`\n &.ant-tabs .ant-tabs-nav {\n margin: 0;\n\n &::before {\n border-bottom: 2px solid var(--ant-color-border-secondary);\n }\n }\n\n &.ant-tabs .ant-tabs-tab {\n padding: 14px 0 18px;\n font-weight: 600;\n font-size: 18px;\n\n + .ant-tabs-tab {\n margin-left: 48px;\n }\n }\n\n &.ant-tabs .ant-tabs-ink-bar {\n height: 4px;\n }\n\n .hisd3-tab-count {\n margin-left: 10px;\n font-size: 14px;\n font-weight: 500;\n color: var(--ant-color-text-tertiary);\n }\n\n .ant-tabs-tab-active .hisd3-tab-count {\n color: var(--ant-color-primary);\n }\n`;\n\n/** Underlined filter tabs with optional counts. */\nexport const HISD3Tabs: React.FC<HISD3TabsProps> = ({ items, ...rest }) => (\n <StyledTabs\n {...rest}\n items={items.map(({ count, label, ...item }) => ({\n ...item,\n label: (\n <>\n {label}\n {count !== undefined && <span className=\"hisd3-tab-count\">{count}</span>}\n </>\n ),\n }))}\n />\n);\n\nexport default HISD3Tabs;\n","import React from \"react\";\nimport styled from \"styled-components\";\n\nexport type HISD3TagVariant = \"neutral\" | \"soft\" | \"outline\" | \"solid\";\nexport type HISD3TagTone = \"default\" | \"primary\" | \"success\" | \"warning\" | \"danger\";\n\nexport interface HISD3TagProps extends React.HTMLAttributes<HTMLSpanElement> {\n /**\n * neutral → light grey fill, dark text (ACTIVE, IN PATIENT)\n * soft → primary tint fill, primary text (ER PATIENT)\n * outline → 2px primary border, primary text (OUT PATIENT)\n * solid → primary fill, white text\n */\n variant?: HISD3TagVariant;\n tone?: HISD3TagTone;\n children: React.ReactNode;\n}\n\nconst toneVar: Record<HISD3TagTone, string> = {\n default: \"var(--ant-color-text)\",\n primary: \"var(--ant-color-primary)\",\n success: \"var(--ant-color-success)\",\n warning: \"var(--ant-color-warning)\",\n danger: \"var(--ant-color-error)\",\n};\n\nconst toneBgVar: Record<HISD3TagTone, string> = {\n default: \"rgba(0,0,0,0.05)\",\n primary: \"var(--ant-color-primary-bg)\",\n success: \"var(--ant-color-success-bg)\",\n warning: \"var(--ant-color-warning-bg)\",\n danger: \"var(--ant-color-error-bg)\",\n};\n\nconst StyledTag = styled.span<{ $variant: HISD3TagVariant; $tone: HISD3TagTone }>`\n display: inline-flex;\n align-items: center;\n gap: 6px;\n height: 32px;\n padding: 0 14px;\n font-size: 12px;\n font-weight: 500;\n letter-spacing: 0.06em;\n text-transform: uppercase;\n white-space: nowrap;\n line-height: 1;\n border: 2px solid transparent;\n border-radius: 0;\n\n ${({ $variant, $tone }) => {\n const color = toneVar[$tone];\n const bg = toneBgVar[$tone];\n switch ($variant) {\n case \"soft\":\n return `color: ${color}; background: ${bg};`;\n case \"outline\":\n return `color: ${color}; border-color: ${color}; background: transparent;`;\n case \"solid\":\n return `color: #fff; background: ${$tone === \"default\" ? \"var(--ant-color-text)\" : color};`;\n default:\n return `color: var(--ant-color-text); background: rgba(0,0,0,0.05);`;\n }\n }}\n`;\n\nexport const HISD3Tag: React.FC<HISD3TagProps> = ({\n variant = \"neutral\",\n tone = variant === \"neutral\" ? \"default\" : \"primary\",\n children,\n ...rest\n}) => (\n <StyledTag $variant={variant} $tone={tone} {...rest}>\n {children}\n </StyledTag>\n);\n\nexport default HISD3Tag;\n","import { Button, type ButtonProps } from \"antd\";\nimport React from \"react\";\nimport styled from \"styled-components\";\n\nexport type HISD3ButtonVariant = \"primary\" | \"secondary\" | \"ghost\" | \"danger\";\n\nexport interface HISD3ButtonProps extends Omit<ButtonProps, \"variant\" | \"color\" | \"type\"> {\n /**\n * primary → filled with the theme primary (e.g. \"New folio\")\n * secondary → outlined, dark 2px border (e.g. \"Refresh\", \"Export\")\n * ghost → text only\n * danger → filled red\n */\n variant?: HISD3ButtonVariant;\n}\n\nconst StyledButton = styled(Button)`\n &.ant-btn {\n text-transform: none;\n letter-spacing: 0;\n display: inline-flex;\n align-items: center;\n gap: 8px;\n height: var(--hisd3-btn-height, 52px);\n padding-inline: 20px;\n font-size: 16px;\n font-weight: 600;\n box-shadow: none;\n }\n\n &.ant-btn-sm {\n --hisd3-btn-height: 36px;\n font-size: 14px;\n padding-inline: 14px;\n }\n\n &.ant-btn-lg {\n --hisd3-btn-height: 56px;\n }\n\n &.ant-btn-default {\n border-width: 2px;\n }\n\n .anticon {\n font-size: 1.05em;\n }\n`;\n\nconst map: Record<HISD3ButtonVariant, Pick<ButtonProps, \"type\" | \"danger\">> = {\n primary: { type: \"primary\" },\n secondary: { type: \"default\" },\n ghost: { type: \"text\" },\n danger: { type: \"primary\", danger: true },\n};\n\nexport const HISD3Button: React.FC<HISD3ButtonProps> = ({\n variant = \"secondary\",\n ...rest\n}) => <StyledButton {...map[variant]} {...rest} />;\n\nexport default HISD3Button;\n","import { SearchOutlined } from \"@ant-design/icons\";\nimport { Input, type InputProps } from \"antd\";\nimport React from \"react\";\nimport styled from \"styled-components\";\n\nexport type HISD3InputProps = InputProps;\n\nconst StyledInput = styled(Input)`\n &.ant-input,\n &.ant-input-affix-wrapper {\n border-width: 2px;\n font-size: 16px;\n }\n\n &.ant-input-affix-wrapper .ant-input-prefix {\n margin-inline-end: 14px;\n color: var(--ant-color-text-tertiary);\n font-size: 18px;\n }\n`;\n\n/** Plain text input with the HISD3 2px border. */\nexport const HISD3Input: React.FC<HISD3InputProps> = (props) => (\n <StyledInput {...props} />\n);\n\nconst StyledSearch = styled(StyledInput)`\n &.ant-input-affix-wrapper {\n background: var(--hisd3-bg-filled, #e6e4e1);\n border-color: var(--ant-color-border-secondary);\n height: 72px;\n padding-inline: 24px;\n\n &:hover,\n &:focus-within {\n border-color: var(--ant-color-border);\n background: var(--hisd3-bg-filled, #e6e4e1);\n }\n\n .ant-input {\n background: transparent;\n font-size: 20px;\n }\n\n .ant-input-prefix {\n font-size: 22px;\n }\n }\n\n &.hisd3-search-compact.ant-input-affix-wrapper {\n height: 48px;\n padding-inline: 16px;\n\n .ant-input {\n font-size: 16px;\n }\n .ant-input-prefix {\n font-size: 18px;\n }\n }\n`;\n\nexport interface HISD3SearchInputProps extends InputProps {\n /** 48px tall instead of the 72px hero search. */\n compact?: boolean;\n}\n\n/** Grey filled search field with leading icon (the page-level search bar). */\nexport const HISD3SearchInput: React.FC<HISD3SearchInputProps> = ({\n compact = false,\n className,\n ...props\n}) => (\n <StyledSearch\n allowClear\n prefix={<SearchOutlined />}\n className={[compact ? \"hisd3-search-compact\" : \"\", className ?? \"\"].join(\" \").trim()}\n {...props}\n />\n);\n\nexport default HISD3Input;\n","export enum ThemeStyle {\n MODERN = \"modern\",\n STANDARD = \"standard\",\n}\nexport enum ThemeStyleRadius {\n MODERN = \"30px\",\n STANDARD = \"16px\",\n}\nexport enum ThemeMode {\n LIGHT = \"light\",\n SEMI_DARK = \"semi-dark\",\n DARK = \"dark\",\n}\nexport enum LayoutType {\n FULL_WIDTH = \"full-width\",\n BOXED = \"boxed\",\n FRAMED = \"framed\",\n}\n\nexport enum MenuStyle {\n DEFAULT = \"default\",\n STANDARD = \"standard\",\n ROUNDED = \"rounded\",\n ROUNDED_REVERSE = \"rounded-reverse\",\n CURVED_MENU = \"curved-menu\",\n}\n\nexport enum NavStyle {\n DEFAULT = \"default\",\n MINI = \"mini\",\n MINI_SIDEBAR_TOGGLE = \"mini-sidebar-toggle\",\n STANDARD = \"standard\",\n HEADER_USER = \"user-header\",\n HEADER_USER_MINI = \"user-mini-header\",\n DRAWER = \"drawer\",\n BIT_BUCKET = \"bit-bucket\",\n H_DEFAULT = \"h-default\",\n HOR_HEADER_FIXED = \"hor-header-fixed\",\n HOR_DARK_LAYOUT = \"hor-dark-layout\",\n}\nexport enum FooterType {\n FIXED = \"fixed\",\n FLUID = \"fluid\",\n}\nexport enum LayoutDirection {\n RTL = \"rtl\",\n LTR = \"ltr\",\n}\nexport enum HeaderType {\n DARK = \"dark\",\n LIGHT = \"light\",\n}\nexport enum RouteTransition {\n NONE = \"none\",\n FADE = \"fade\",\n SLIDE_LEFT = \"slideLeft\",\n SLIDE_RIGHT = \"slideRight\",\n SLIDE_UP = \"slideUp\",\n SLIDE_DOWN = \"slideDown\",\n}\nexport enum Fonts {\n LIGHT = \"300\",\n REGULAR = \"400\",\n MEDIUM = \"500\",\n BOLD = \"600\",\n}\n\nexport enum AuthType {\n FIREBASE = \"firebase\",\n AWS_COGNITO = \"aws_cognito\",\n AUTH0 = \"auth0\",\n JWT_AUTH = \"jwt_auth\",\n}\n\nexport enum AppAnimates {\n SLIDEUPIN = \"transition.slideUpIn\",\n SLIDEUPOUT = \"transition.slideUpOut\",\n SLIDEDOWNIN = \"transition.slideDownIn\",\n SLIDEDOWNOUT = \"transition.slideDownOut\",\n SLIDELEFTIN = \"transition.slideLeftIn\",\n SLIDELEFTOUT = \"transition.slideLeftOut\",\n SLIDERIGHTIN = \"transition.slideRightIn\",\n SLIDERIGHTOUT = \"transition.slideRightOut\",\n FADEIN = \"transition.fadeIn\",\n FADEOUT = \"transition.fadeOut\",\n}\n\nexport const AppAnimateGroups = {\n SLIDEUPIN: {\n hidden: {\n y: 0,\n },\n visible: {\n opacity: 1,\n y: 0,\n transition: {\n ease: \"easeIn\",\n delay: 0,\n when: \"beforeChildren\",\n duration: 0.2,\n staggerChildren: 0.05,\n },\n },\n },\n SLIDEUPOUT: {\n hidden: {\n y: 0,\n },\n visible: {\n opacity: 0,\n y: \"100vh\",\n transition: {\n ease: \"easeOut\",\n delay: 0,\n when: \"beforeChildren\",\n duration: 0.4,\n staggerChildren: 0.15,\n },\n },\n },\n SLIDEDOWNIN: {\n hidden: {\n opacity: 0,\n y: \"-100vh\",\n },\n visible: {\n opacity: 1,\n y: 0,\n transition: {\n ease: \"easeIn\",\n delay: 0,\n when: \"beforeChildren\",\n duration: 0.4,\n staggerChildren: 0.15,\n },\n },\n },\n SLIDEDOWNOUT: {\n hidden: {\n y: 0,\n },\n visible: {\n opacity: 0,\n y: \"-100vh\",\n transition: {\n ease: \"easeOut\",\n delay: 0,\n when: \"beforeChildren\",\n duration: 0.4,\n staggerChildren: 0.15,\n },\n },\n },\n SLIDELEFTIN: {\n hidden: {\n x: \"100vw\",\n },\n visible: {\n opacity: 1,\n x: 0,\n transition: {\n ease: \"easeIn\",\n delay: 0,\n when: \"beforeChildren\",\n duration: 0.4,\n staggerChildren: 0.15,\n },\n },\n },\n SLIDELEFTOUT: {\n hidden: {\n x: 0,\n },\n visible: {\n opacity: 0,\n x: \"100vw\",\n transition: {\n ease: \"easeOut\",\n delay: 0,\n when: \"beforeChildren\",\n duration: 0.4,\n staggerChildren: 0.15,\n },\n },\n },\n SLIDERIGHTIN: {\n hidden: {\n x: \"-100vw\",\n },\n visible: {\n opacity: 1,\n x: 0,\n transition: {\n ease: \"easeIn\",\n delay: 0,\n when: \"beforeChildren\",\n duration: 0.4,\n staggerChildren: 0.15,\n },\n },\n },\n SLIDERIGHTOUT: {\n hidden: {\n x: 0,\n },\n visible: {\n opacity: 0,\n x: \"-100vw\",\n transition: {\n ease: \"easeOut\",\n delay: 0,\n when: \"beforeChildren\",\n duration: 0.4,\n staggerChildren: 0.15,\n },\n },\n },\n FADEIN: {\n hidden: {\n opacity: 0,\n scale: 1,\n },\n visible: {\n opacity: 1,\n scale: 1,\n transition: {\n ease: \"easeIn\",\n when: \"beforeChildren\",\n staggerChildren: 0.15,\n },\n },\n },\n FADEOUT: {\n hidden: {\n opacity: 1,\n scale: 1,\n },\n visible: {\n opacity: 0,\n scale: 1,\n transition: {\n ease: \"easeOut\",\n when: \"beforeChildren\",\n staggerChildren: 0.15,\n },\n },\n },\n NOANIMATION: {\n hidden: {\n opacity: 1,\n },\n visible: {\n opacity: 1,\n },\n },\n};\n\nexport const AppMotionAnimate = {\n SLIDEUPIN: {\n variants: {\n hidden: {\n y: 100,\n opacity: 0,\n },\n visible: {\n opacity: 1,\n y: 0,\n },\n },\n transition: {\n ease: \"easeIn\",\n when: \"beforeChildren\",\n },\n },\n SLIDEUPOUT: {\n variants: {\n hidden: {\n y: 0,\n opacity: 1,\n },\n visible: {\n opacity: 0,\n y: \"-100vh\",\n },\n },\n transition: {\n ease: \"easeOut\",\n when: \"beforeChildren\",\n },\n },\n SLIDEDOWNIN: {\n variants: {\n hidden: {\n y: -100,\n opacity: 0,\n },\n visible: {\n opacity: 1,\n y: 0,\n },\n },\n transition: {\n ease: \"easeIn\",\n when: \"beforeChildren\",\n },\n },\n SLIDEDOWNOUT: {\n variants: {\n hidden: {\n y: 0,\n opacity: 1,\n },\n visible: {\n opacity: 0,\n y: \"100vh\",\n },\n },\n transition: {\n ease: \"easeOut\",\n when: \"beforeChildren\",\n },\n },\n SLIDELEFTIN: {\n variants: {\n hidden: {\n x: 100,\n opacity: 0,\n },\n visible: {\n opacity: 1,\n x: 0,\n },\n },\n transition: {\n ease: \"easeIn\",\n when: \"beforeChildren\",\n },\n },\n SLIDELEFTOUT: {\n variants: {\n hidden: {\n x: 0,\n opacity: 1,\n },\n visible: {\n opacity: 0,\n x: \"-100vw\",\n },\n },\n transition: {\n ease: \"easeOut\",\n when: \"beforeChildren\",\n },\n },\n SLIDERIGHTIN: {\n variants: {\n hidden: {\n x: -100,\n opacity: 0,\n },\n visible: {\n opacity: 1,\n x: 0,\n },\n },\n transition: {\n ease: \"easeIn\",\n when: \"beforeChildren\",\n },\n },\n SLIDERIGHTOUT: {\n variants: {\n hidden: {\n x: 0,\n opacity: 1,\n },\n visible: {\n opacity: 0,\n x: \"-100vw\",\n },\n },\n transition: {\n ease: \"easeOut\",\n when: \"beforeChildren\",\n },\n },\n FADEIN: {\n variants: {\n hidden: {\n opacity: 0,\n },\n visible: {\n opacity: 1,\n },\n },\n transition: {\n duration: 0.1,\n ease: \"easeIn\",\n when: \"beforeChildren\",\n },\n },\n FADEOUT: {\n variants: {\n hidden: {\n opacity: 1,\n },\n visible: {\n opacity: 0,\n },\n },\n transition: {\n duration: 0.1,\n ease: \"easeOut\",\n when: \"beforeChildren\",\n },\n },\n};\n\nexport enum MessageType {\n MEDIA = 1,\n TEXT = 2,\n}\n\nexport enum RoutePermittedRole {\n Admin = \"admin\",\n User = \"user\",\n}\n"],"names":["styleInject","css","ref","insertAt","document","head","getElementsByTagName","style","createElement","type","firstChild","insertBefore","appendChild","styleSheet","cssText","createTextNode","HISD3_PRESETS","red","orange","teal","blue","green","purple","HISD3_NEUTRALS","bgLayout","bgContainer","bgElevated","bgFilled","text","textSecondary","textTertiary","border","borderSecondary","white","HISD3_FONT_FAMILY","resolvePrimary","primary","tint","hex","amount","h","replace","full","length","split","map","c","join","n","parseInt","g","b","mix","Math","round","toString","padStart","createHisd3Theme","radius","lineWidth","overrides","p","base","cssVar","key","token","colorPrimary","colorInfo","colorLink","colorPrimaryBg","colorPrimaryBgHover","colorPrimaryBorder","fontFamily","fontSize","fontWeightStrong","borderRadius","borderRadiusLG","borderRadiusSM","borderRadiusXS","colorBgLayout","colorBgContainer","colorBgElevated","colorText","colorTextSecondary","colorTextTertiary","colorTextHeading","colorBorder","colorBorderSecondary","colorSplit","controlHeight","controlHeightLG","controlHeightSM","boxShadow","boxShadowSecondary","components","Layout","siderBg","headerBg","bodyBg","headerPadding","Menu","itemBg","subMenuItemBg","itemColor","itemHoverColor","itemHoverBg","itemSelectedBg","itemSelectedColor","itemActiveBg","subMenuItemSelectedColor","groupTitleColor","groupTitleFontSize","itemBorderRadius","itemMarginInline","itemMarginBlock","itemHeight","itemPaddingInline","iconSize","collapsedIconSize","activeBarBorderWidth","activeBarWidth","Button","fontWeight","primaryShadow","defaultShadow","dangerShadow","defaultBorderColor","defaultColor","defaultBg","defaultHoverBg","defaultHoverBorderColor","defaultHoverColor","defaultActiveBorderColor","paddingInline","contentFontSizeLG","Input","activeShadow","hoverBorderColor","activeBorderColor","Select","optionSelectedBg","Table","headerColor","headerSplitColor","headerBorderRadius","borderColor","rowHoverBg","cellPaddingBlock","cellPaddingInline","cellFontSize","footerBg","Tabs","inkBarColor","titleFontSize","horizontalItemGutter","horizontalMargin","lineWidthBold","Tag","Pagination","itemSize","itemInputBg","Dropdown","paddingBlock","Breadcrumb","lastItemColor","linkColor","linkHoverColor","separatorColor","Card","headerFontSize","hisd3AntdTheme","HISD3_COLORS","primaryLight","headerSelectedBg","HISD3ProviderContext","createContext","useInsideHISD3Provider","useContext","HISD3_LAYOUT","siderWidth","siderCollapsedWidth","topBarHeight","pageGutter","Header","Content","SIDER_WIDTH","SIDER_COLLAPSED_WIDTH","HEADER_HEIGHT","StyledRoot","styled","StyledSiderMenuWrap","div","StyledBrand","a","$collapsed","StyledHeader","StyledSiderHeader","StyledCollapseTrigger","button","StyledContent","StyledCrUserInfo","$inHeader","StyledCrUserInfoInner","StyledCrUserInfoAvatar","span","$src","StyledCrUserInfoContent","StyledUsernameInfo","StyledUsername","h3","StyledUserArrow","StyledCrUserDesignation","itemKey","item","index","path","toAntdMenuItems","items","renderLink","filter","hideInMenu","Array","isArray","children","icon","label","name","disabled","group","undefined","defaultRenderLink","href","UserMenu","account","avatarSrc","settingsUrl","onLogout","collapsed","placement","extraItems","modal","App","useApp","_jsx","SettingOutlined","onClick","window","location","LogoutOutlined","confirm","title","content","ExclamationCircleOutlined","onOk","initials","fullName","w","Boolean","slice","toUpperCase","jsx","className","trigger","menu","_jsxs","e","preventDefault","jsxs","DownOutlined","positionType","Sider","PAGE_GUTTER","TopBar","Actions","TitleBlock","HISD3PageBody","Wrap","FooterStrip","PagerBar","SizeGroup","defaultTotal","total","toLocaleString","StyledTabs","toneVar","default","success","warning","danger","toneBgVar","StyledTag","$variant","$tone","color","bg","StyledButton","secondary","ghost","StyledInput","StyledSearch","ThemeStyle","ThemeStyleRadius","ThemeMode","LayoutType","MenuStyle","NavStyle","FooterType","LayoutDirection","HeaderType","RouteTransition","Fonts","AuthType","AppAnimates","MessageType","RoutePermittedRole","SLIDEUPIN","hidden","y","visible","opacity","transition","ease","delay","when","duration","staggerChildren","SLIDEUPOUT","SLIDEDOWNIN","SLIDEDOWNOUT","SLIDELEFTIN","x","SLIDELEFTOUT","SLIDERIGHTIN","SLIDERIGHTOUT","FADEIN","scale","FADEOUT","NOANIMATION","variants","variant","rest","props","subtitle","breadcrumb","extra","leading","hideTopBar","flex","theme","styledTheme","antdTheme","useMemo","Provider","value","ConfigProvider","ThemeProvider","AntdApp","component","compact","allowClear","prefix","SearchOutlined","trim","logoUrl","appName","menuItems","pathname","renderMenuLink","headerExtra","userMenuItems","onCollapse","loading","hideSidebar","layoutTop","hideCollapseTrigger","bareContent","hideHeaderBar","brandHref","insideProvider","resolvedTheme","isCollapsed","setIsCollapsed","useState","useEffect","selection","best","walk","list","parents","forEach","startsWith","exact","selectedKey","openKeys","findSelection","setOpenKeys","prev","from","Set","toggleCollapse","next","selectedKeys","brand","src","alt","body","Spin","spinning","size","_Fragment","Fragment","mode","hasSider","width","collapsedWidth","collapsible","breakpoint","onBreakpoint","broken","inlineCollapsed","onOpenChange","keys","background","MenuUnfoldOutlined","MenuFoldOutlined","pagination","footer","tableProps","sizes","pageSizeOptions","renderTotal","current","pageSize","min","showSizeChanger","onChange","page","itemRender","_","el","LeftOutlined","RightOutlined","hidePageSize","role","s","count","tone"],"mappings":"mJAAA,SAASA,EAAYC,EAAKC,QACX,IAARA,IAAiBA,EAAM,CAAE,GAC9B,IAAIC,EAAWD,EAAIC,SAEnB,GAAKF,GAA2B,oBAAbG,SAAnB,CAEA,IAAIC,EAAOD,SAASC,MAAQD,SAASE,qBAAqB,QAAQ,GAC9DC,EAAQH,SAASI,cAAc,SACnCD,EAAME,KAAO,WAEI,QAAbN,GACEE,EAAKK,WACPL,EAAKM,aAAaJ,EAAOF,EAAKK,YAKhCL,EAAKO,YAAYL,GAGfA,EAAMM,WACRN,EAAMM,WAAWC,QAAUb,EAE3BM,EAAMK,YAAYR,SAASW,eAAed,GAnBU,CAqBxD,m3GCtBa,MAAAe,EAAgB,CAC3BC,IAAK,UACLC,OAAQ,UACRC,KAAM,UACNC,KAAM,UACNC,MAAO,UACPC,OAAQ,WAMGC,EAAiB,CAC5BC,SAAU,UACVC,YAAa,UACbC,WAAY,UACZC,SAAU,UACVC,KAAM,UACNC,cAAe,UACfC,aAAc,UACdC,OAAQ,UACRC,gBAAiB,UACjBC,MAAO,WAGIC,EACX,wGAgBWC,EAAiB,CAACC,EAAgC,QAC5DpB,EAAyCoB,IAAYA,EAG3CC,EAAO,CAACC,EAAaC,KAChC,MAAMC,EAAIF,EAAIG,QAAQ,IAAK,IACrBC,EAAoB,IAAbF,EAAEG,OAAeH,EAAEI,MAAM,IAAIC,KAAKC,GAAMA,EAAIA,IAAGC,KAAK,IAAMP,EACjEQ,EAAIC,SAASP,EAAM,IAEnBQ,EAAKF,GAAK,EAAK,IACfG,EAAQ,IAAJH,EACJI,EAAON,GAAcO,KAAKC,MAAMR,GAAK,IAAMA,GAAKP,GACtD,MAAO,IAAI,CAACa,EAJDJ,GAAK,GAAM,KAIFI,EAAIF,GAAIE,EAAID,IAC7BN,KAAKC,GAAMA,EAAES,SAAS,IAAIC,SAA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F,KAGT1X,EAAE6X,cACFvM,EAACiB,IAAAmB,EAAU,CAAAoK,KAAK,QAAO,aAAY,gBAAe5N,SAC/C6M,EAAM/X,KAAK+Y,GACVpL,EAAAA,KAEE,SAAA,CAAA/P,KAAK,SAAQ,eACCmb,IAAM/X,EAAEmX,SACtB3L,QAAS,IAAMxL,EAAEsX,SAAS,EAAGS,GAE5B7N,SAAA,CAAA6N,EALI,YAAAA,YAcvB,oBClLmD,EAAGnO,WAAU2H,KAC9DjG,EAAAA,IAACwC,EACK,IAAAyD,EACJ3H,MAAOA,EAAM5K,KAAI,EAAGgZ,QAAO5N,WAAUZ,MAAY,IAC5CA,EACHY,MACEuC,EAAAG,KAAA8I,WAAA,CAAA1L,SAAA,CACGE,OACUI,IAAVwN,GAAuB1M,EAAAiB,IAAA,OAAA,CAAMC,UAAU,2BAAmBwL,8BCIpB,EAC/C1G,UAAU,UACV2G,QAAmB,YAAZ3G,EAAwB,UAAY,WAC3CpH,cACGqH,KAEHjG,EAAAA,IAAC+C,GAAoB,CAAAC,SAAAgD,QAAgB2G,KAAU1G,EAC5CrH,SAAAA,sFVxCiC,sCADG","x_google_ignoreList":[0]}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,13 +1,66 @@
|
|
|
1
|
-
import { ThemeConfig, MenuProps } from 'antd';
|
|
1
|
+
import { ThemeConfig, MenuProps, TableProps, TabsProps, ButtonProps, InputProps } from 'antd';
|
|
2
2
|
import React, { ReactNode } from 'react';
|
|
3
|
+
import * as styled_components_dist_types from 'styled-components/dist/types';
|
|
4
|
+
import * as styled_components from 'styled-components';
|
|
5
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
6
|
+
import { AnyObject } from 'antd/es/_util/type';
|
|
3
7
|
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
/** Named primary-color presets. Any hex string is also accepted. */
|
|
9
|
+
declare const HISD3_PRESETS: {
|
|
10
|
+
readonly red: "#E5401C";
|
|
11
|
+
readonly orange: "#F26B1D";
|
|
12
|
+
readonly teal: "#00796B";
|
|
13
|
+
readonly blue: "#1D5FD1";
|
|
14
|
+
readonly green: "#2E7D32";
|
|
15
|
+
readonly purple: "#6A3FD6";
|
|
16
|
+
};
|
|
17
|
+
type HISD3Preset = keyof typeof HISD3_PRESETS;
|
|
18
|
+
/** Neutral palette shared by every preset (the "Backoffice" look). */
|
|
19
|
+
declare const HISD3_NEUTRALS: {
|
|
20
|
+
readonly bgLayout: "#F3F2F0";
|
|
21
|
+
readonly bgContainer: "#F3F2F0";
|
|
22
|
+
readonly bgElevated: "#FFFFFF";
|
|
23
|
+
readonly bgFilled: "#E6E4E1";
|
|
24
|
+
readonly text: "#171717";
|
|
25
|
+
readonly textSecondary: "#4A4A4A";
|
|
26
|
+
readonly textTertiary: "#6E6E6E";
|
|
27
|
+
readonly border: "#1F1F1F";
|
|
28
|
+
readonly borderSecondary: "#CFCDC9";
|
|
29
|
+
readonly white: "#FFFFFF";
|
|
30
|
+
};
|
|
31
|
+
declare const HISD3_FONT_FAMILY = "'Archivo', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif";
|
|
32
|
+
/** Archivo is used for both body (400) and headings (800). */
|
|
33
|
+
declare const HISD3_FONT_WEIGHT_HEADING = 800;
|
|
34
|
+
declare const HISD3_FONT_WEIGHT_BODY = 400;
|
|
35
|
+
interface HISD3ThemeOptions {
|
|
36
|
+
/** Preset name or any hex color. Default "red". */
|
|
37
|
+
primary?: HISD3Preset | string;
|
|
38
|
+
/** Corner radius in px. The Backoffice look is square (0). */
|
|
39
|
+
radius?: number;
|
|
40
|
+
/** Border width in px used by buttons, inputs, dividers. Default 2. */
|
|
41
|
+
lineWidth?: number;
|
|
42
|
+
/** Override / extend the generated antd theme. */
|
|
43
|
+
overrides?: ThemeConfig;
|
|
10
44
|
}
|
|
45
|
+
declare const resolvePrimary: (primary?: HISD3Preset | string) => string;
|
|
46
|
+
/** Mix a hex color with white: amount 0 → color, 1 → white. */
|
|
47
|
+
declare const tint: (hex: string, amount: number) => string;
|
|
48
|
+
/**
|
|
49
|
+
* Build the HISD3 Ant Design v6 theme.
|
|
50
|
+
*
|
|
51
|
+
* ```ts
|
|
52
|
+
* <ConfigProvider theme={createHisd3Theme({ primary: "teal" })}>
|
|
53
|
+
* ```
|
|
54
|
+
*/
|
|
55
|
+
declare const createHisd3Theme: ({ primary, radius, lineWidth, overrides, }?: HISD3ThemeOptions) => ThemeConfig;
|
|
56
|
+
/** Default HISD3 theme — the red "Backoffice" look. */
|
|
57
|
+
declare const hisd3AntdTheme: ThemeConfig;
|
|
58
|
+
/** @deprecated use HISD3_PRESETS / createHisd3Theme */
|
|
59
|
+
declare const HISD3_COLORS: {
|
|
60
|
+
readonly primary: "#E5401C";
|
|
61
|
+
readonly primaryLight: string;
|
|
62
|
+
readonly headerSelectedBg: "rgba(0,0,0,0.04)";
|
|
63
|
+
};
|
|
11
64
|
|
|
12
65
|
declare enum ThemeStyle {
|
|
13
66
|
MODERN = "modern",
|
|
@@ -550,6 +603,40 @@ interface StyledTheme {
|
|
|
550
603
|
sizes?: Sizes;
|
|
551
604
|
}
|
|
552
605
|
|
|
606
|
+
/** True when rendered somewhere below an `HISD3Provider`. */
|
|
607
|
+
declare const useInsideHISD3Provider: () => boolean;
|
|
608
|
+
interface HISD3ProviderProps extends HISD3ThemeOptions {
|
|
609
|
+
/** Shorthand: preset name or hex. Same as `options.primary`. */
|
|
610
|
+
primary?: HISD3Preset | string;
|
|
611
|
+
/** Legacy styled-components theme object used by older HISD3 screens. */
|
|
612
|
+
styledTheme?: StyledTheme;
|
|
613
|
+
/** Fully custom antd theme — skips `createHisd3Theme` entirely. */
|
|
614
|
+
theme?: ThemeConfig;
|
|
615
|
+
children: React.ReactNode;
|
|
616
|
+
}
|
|
617
|
+
/**
|
|
618
|
+
* Root provider for HISD3 apps. Put it once at the top of the tree:
|
|
619
|
+
*
|
|
620
|
+
* ```tsx
|
|
621
|
+
* <HISD3Provider primary="teal">
|
|
622
|
+
* <App />
|
|
623
|
+
* </HISD3Provider>
|
|
624
|
+
* ```
|
|
625
|
+
*
|
|
626
|
+
* It wires the antd `ConfigProvider` (with CSS variables enabled so every
|
|
627
|
+
* kit component follows the chosen primary), antd `App` (for themed
|
|
628
|
+
* `modal.confirm` / `message`), and the styled-components `ThemeProvider`.
|
|
629
|
+
*/
|
|
630
|
+
declare const HISD3Provider: React.FC<HISD3ProviderProps>;
|
|
631
|
+
|
|
632
|
+
interface IUserEmployee {
|
|
633
|
+
id: string;
|
|
634
|
+
fullName: string;
|
|
635
|
+
gender: "MALE" | "FEMALE";
|
|
636
|
+
positionType?: string;
|
|
637
|
+
[key: string]: any;
|
|
638
|
+
}
|
|
639
|
+
|
|
553
640
|
/**
|
|
554
641
|
* Menu item shape accepted by HISD3Sidebar.
|
|
555
642
|
*
|
|
@@ -572,14 +659,16 @@ interface HISD3MenuItem {
|
|
|
572
659
|
|
|
573
660
|
interface HISD3SidebarProps {
|
|
574
661
|
account: IUserEmployee;
|
|
575
|
-
|
|
662
|
+
/** Logo image URL. When omitted a square block in the primary color is shown. */
|
|
663
|
+
logoUrl?: string;
|
|
576
664
|
appName: string;
|
|
577
665
|
/** Same shape as before (ProLayout `MenuDataItem`): `{ path, name, icon, children }`. */
|
|
578
666
|
menuItems: HISD3MenuItem[];
|
|
579
667
|
onLogout: () => Promise<void> | void;
|
|
580
668
|
/** Current location pathname, used to highlight the active menu item. */
|
|
581
669
|
pathname: string;
|
|
582
|
-
|
|
670
|
+
/** styled-components theme; optional when inside HISD3Provider. */
|
|
671
|
+
styledTheme?: StyledTheme;
|
|
583
672
|
collapsed?: boolean;
|
|
584
673
|
/** Called when the user toggles the sider (controlled usage). */
|
|
585
674
|
onCollapse?: (collapsed: boolean) => void;
|
|
@@ -591,7 +680,9 @@ interface HISD3SidebarProps {
|
|
|
591
680
|
settingsUrl?: string;
|
|
592
681
|
/**
|
|
593
682
|
* Ant Design theme applied via a nested `ConfigProvider`.
|
|
594
|
-
* Defaults to `hisd3AntdTheme
|
|
683
|
+
* Defaults to `hisd3AntdTheme` (red) when used standalone. Inside an
|
|
684
|
+
* `HISD3Provider` nothing is applied so the provider's primary is inherited.
|
|
685
|
+
* Pass `null` to force inheritance, or a ThemeConfig to override.
|
|
595
686
|
*/
|
|
596
687
|
antdTheme?: ThemeConfig | null;
|
|
597
688
|
/**
|
|
@@ -609,6 +700,13 @@ interface HISD3SidebarProps {
|
|
|
609
700
|
siderWidth?: number;
|
|
610
701
|
/** Disable the built-in content padding wrapper and render children directly. */
|
|
611
702
|
bareContent?: boolean;
|
|
703
|
+
/**
|
|
704
|
+
* Hide the sider layout's own top bar (collapse trigger + headerExtra).
|
|
705
|
+
* Use together with `HISD3PageHeader`, which renders its own top bar.
|
|
706
|
+
*/
|
|
707
|
+
hideHeaderBar?: boolean;
|
|
708
|
+
/** Where the brand block links to. Default "/". */
|
|
709
|
+
brandHref?: string;
|
|
612
710
|
children: React.ReactNode;
|
|
613
711
|
}
|
|
614
712
|
declare const HISD3Sidebar: React.FC<HISD3SidebarProps>;
|
|
@@ -630,19 +728,110 @@ interface UserMenuProps {
|
|
|
630
728
|
*/
|
|
631
729
|
declare const UserMenu: React.FC<UserMenuProps>;
|
|
632
730
|
|
|
731
|
+
interface HISD3BreadcrumbItem {
|
|
732
|
+
title: React.ReactNode;
|
|
733
|
+
href?: string;
|
|
734
|
+
onClick?: () => void;
|
|
735
|
+
}
|
|
736
|
+
interface HISD3PageHeaderProps {
|
|
737
|
+
title: React.ReactNode;
|
|
738
|
+
subtitle?: React.ReactNode;
|
|
739
|
+
breadcrumb?: HISD3BreadcrumbItem[];
|
|
740
|
+
/** Action buttons rendered on the right of the top bar. */
|
|
741
|
+
extra?: React.ReactNode;
|
|
742
|
+
/** Content rendered to the left of the breadcrumb (e.g. the sidebar collapse trigger). */
|
|
743
|
+
leading?: React.ReactNode;
|
|
744
|
+
/** Hide the top bar entirely and render only the title block. */
|
|
745
|
+
hideTopBar?: boolean;
|
|
746
|
+
className?: string;
|
|
747
|
+
}
|
|
748
|
+
/** Padded body area that lines up with the header gutters. */
|
|
749
|
+
declare const HISD3PageBody: styled_components_dist_types.IStyledComponentBase<"web", styled_components.FastOmit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
633
750
|
/**
|
|
634
|
-
*
|
|
635
|
-
*
|
|
636
|
-
*
|
|
637
|
-
* (teal selected/hover state) and are exported so every HISD3 app can pass
|
|
638
|
-
* them to its own `<ConfigProvider theme={hisd3AntdTheme}>`.
|
|
751
|
+
* Sticky top bar (breadcrumb + actions) followed by a big page title block.
|
|
752
|
+
* Designed to sit directly inside `HISD3Sidebar` with `bareContent` and
|
|
753
|
+
* `hideHeaderBar`.
|
|
639
754
|
*/
|
|
640
|
-
declare const
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
755
|
+
declare const HISD3PageHeader: React.FC<HISD3PageHeaderProps>;
|
|
756
|
+
|
|
757
|
+
interface HISD3TablePagination {
|
|
758
|
+
current: number;
|
|
759
|
+
pageSize: number;
|
|
760
|
+
total: number;
|
|
761
|
+
onChange: (page: number, pageSize: number) => void;
|
|
762
|
+
/** Page-size toggle buttons on the right. Default [10, 20, 50]. */
|
|
763
|
+
pageSizeOptions?: number[];
|
|
764
|
+
/** Custom total text. Default "Total 7,223 items". */
|
|
765
|
+
renderTotal?: (total: number, range: [number, number]) => React.ReactNode;
|
|
766
|
+
/** Hide the page-size buttons. */
|
|
767
|
+
hidePageSize?: boolean;
|
|
768
|
+
}
|
|
769
|
+
interface HISD3TableProps<T extends AnyObject> extends Omit<TableProps<T>, "pagination" | "footer"> {
|
|
770
|
+
/** HISD3 pagination bar (total · pages · page-size). Omit for no pagination. */
|
|
771
|
+
pagination?: HISD3TablePagination | false;
|
|
772
|
+
/** Optional summary strip rendered between the rows and the pagination bar. */
|
|
773
|
+
footer?: React.ReactNode;
|
|
774
|
+
}
|
|
775
|
+
declare function HISD3Table<T extends AnyObject>({ pagination, footer, ...tableProps }: HISD3TableProps<T>): react_jsx_runtime.JSX.Element;
|
|
776
|
+
|
|
777
|
+
interface HISD3TabItem {
|
|
778
|
+
key: string;
|
|
779
|
+
label: React.ReactNode;
|
|
780
|
+
/** Optional count badge rendered after the label (e.g. "All Patients 10"). */
|
|
781
|
+
count?: number | string;
|
|
782
|
+
disabled?: boolean;
|
|
783
|
+
children?: React.ReactNode;
|
|
784
|
+
}
|
|
785
|
+
interface HISD3TabsProps extends Omit<TabsProps, "items"> {
|
|
786
|
+
items: HISD3TabItem[];
|
|
787
|
+
}
|
|
788
|
+
/** Underlined filter tabs with optional counts. */
|
|
789
|
+
declare const HISD3Tabs: React.FC<HISD3TabsProps>;
|
|
790
|
+
|
|
791
|
+
type HISD3TagVariant = "neutral" | "soft" | "outline" | "solid";
|
|
792
|
+
type HISD3TagTone = "default" | "primary" | "success" | "warning" | "danger";
|
|
793
|
+
interface HISD3TagProps extends React.HTMLAttributes<HTMLSpanElement> {
|
|
794
|
+
/**
|
|
795
|
+
* neutral → light grey fill, dark text (ACTIVE, IN PATIENT)
|
|
796
|
+
* soft → primary tint fill, primary text (ER PATIENT)
|
|
797
|
+
* outline → 2px primary border, primary text (OUT PATIENT)
|
|
798
|
+
* solid → primary fill, white text
|
|
799
|
+
*/
|
|
800
|
+
variant?: HISD3TagVariant;
|
|
801
|
+
tone?: HISD3TagTone;
|
|
802
|
+
children: React.ReactNode;
|
|
803
|
+
}
|
|
804
|
+
declare const HISD3Tag: React.FC<HISD3TagProps>;
|
|
805
|
+
|
|
806
|
+
type HISD3ButtonVariant = "primary" | "secondary" | "ghost" | "danger";
|
|
807
|
+
interface HISD3ButtonProps extends Omit<ButtonProps, "variant" | "color" | "type"> {
|
|
808
|
+
/**
|
|
809
|
+
* primary → filled with the theme primary (e.g. "New folio")
|
|
810
|
+
* secondary → outlined, dark 2px border (e.g. "Refresh", "Export")
|
|
811
|
+
* ghost → text only
|
|
812
|
+
* danger → filled red
|
|
813
|
+
*/
|
|
814
|
+
variant?: HISD3ButtonVariant;
|
|
815
|
+
}
|
|
816
|
+
declare const HISD3Button: React.FC<HISD3ButtonProps>;
|
|
817
|
+
|
|
818
|
+
type HISD3InputProps = InputProps;
|
|
819
|
+
/** Plain text input with the HISD3 2px border. */
|
|
820
|
+
declare const HISD3Input: React.FC<HISD3InputProps>;
|
|
821
|
+
interface HISD3SearchInputProps extends InputProps {
|
|
822
|
+
/** 48px tall instead of the 72px hero search. */
|
|
823
|
+
compact?: boolean;
|
|
824
|
+
}
|
|
825
|
+
/** Grey filled search field with leading icon (the page-level search bar). */
|
|
826
|
+
declare const HISD3SearchInput: React.FC<HISD3SearchInputProps>;
|
|
827
|
+
|
|
828
|
+
/** Shared layout metrics so the sidebar brand block and page top bar line up. */
|
|
829
|
+
declare const HISD3_LAYOUT: {
|
|
830
|
+
readonly siderWidth: 280;
|
|
831
|
+
readonly siderCollapsedWidth: 72;
|
|
832
|
+
readonly topBarHeight: 88;
|
|
833
|
+
readonly pageGutter: 40;
|
|
644
834
|
};
|
|
645
|
-
declare const hisd3AntdTheme: ThemeConfig;
|
|
646
835
|
|
|
647
|
-
export { AppAnimateGroups, AppAnimates, AppMotionAnimate, AuthType, Fonts, FooterType, HISD3Sidebar, HISD3_COLORS, HeaderType, LayoutDirection, LayoutType, MenuStyle, MessageType, NavStyle, RoutePermittedRole, RouteTransition, ThemeMode, ThemeStyle, ThemeStyleRadius, UserMenu, hisd3AntdTheme };
|
|
648
|
-
export type { HISD3MenuItem, HISD3SidebarProps, IUserEmployee, StyledTheme, UserMenuProps };
|
|
836
|
+
export { AppAnimateGroups, AppAnimates, AppMotionAnimate, AuthType, Fonts, FooterType, HISD3Button, HISD3Input, HISD3PageBody, HISD3PageHeader, HISD3Provider, HISD3SearchInput, HISD3Sidebar, HISD3Table, HISD3Tabs, HISD3Tag, HISD3_COLORS, HISD3_FONT_FAMILY, HISD3_FONT_WEIGHT_BODY, HISD3_FONT_WEIGHT_HEADING, HISD3_LAYOUT, HISD3_NEUTRALS, HISD3_PRESETS, HeaderType, LayoutDirection, LayoutType, MenuStyle, MessageType, NavStyle, RoutePermittedRole, RouteTransition, ThemeMode, ThemeStyle, ThemeStyleRadius, UserMenu, createHisd3Theme, hisd3AntdTheme, resolvePrimary, tint, useInsideHISD3Provider };
|
|
837
|
+
export type { HISD3BreadcrumbItem, HISD3ButtonProps, HISD3ButtonVariant, HISD3InputProps, HISD3MenuItem, HISD3PageHeaderProps, HISD3Preset, HISD3ProviderProps, HISD3SearchInputProps, HISD3SidebarProps, HISD3TabItem, HISD3TablePagination, HISD3TableProps, HISD3TabsProps, HISD3TagProps, HISD3TagTone, HISD3TagVariant, HISD3ThemeOptions, IUserEmployee, StyledTheme, UserMenuProps };
|