@oscarrf2/goo-ds 0.1.0 → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +74 -0
- package/dist/assets/index.css +1 -0
- package/dist/components/Button/Button.d.ts +20 -0
- package/dist/components/Button/Button.d.ts.map +1 -0
- package/dist/components/Button/Button.js +60 -0
- package/dist/components/Button/Button.js.map +1 -0
- package/dist/components/Button/Button.types.d.ts +46 -0
- package/dist/components/Button/Button.types.d.ts.map +1 -0
- package/{src/components/Button/index.ts → dist/components/Button/index.d.ts} +4 -3
- package/dist/components/Button/index.d.ts.map +1 -0
- package/dist/components/Cell/Cell.d.ts +19 -0
- package/dist/components/Cell/Cell.d.ts.map +1 -0
- package/dist/components/Cell/Cell.js +28 -0
- package/dist/components/Cell/Cell.js.map +1 -0
- package/dist/components/Cell/Cell.types.d.ts +34 -0
- package/dist/components/Cell/Cell.types.d.ts.map +1 -0
- package/{src/components/Cell/index.ts → dist/components/Cell/index.d.ts} +4 -3
- package/dist/components/Cell/index.d.ts.map +1 -0
- package/dist/components/Codeblock/Codeblock.d.ts +25 -0
- package/dist/components/Codeblock/Codeblock.d.ts.map +1 -0
- package/dist/components/Codeblock/Codeblock.js +51 -0
- package/dist/components/Codeblock/Codeblock.js.map +1 -0
- package/dist/components/Codeblock/Codeblock.types.d.ts +36 -0
- package/dist/components/Codeblock/Codeblock.types.d.ts.map +1 -0
- package/{src/components/Codeblock/index.ts → dist/components/Codeblock/index.d.ts} +4 -3
- package/dist/components/Codeblock/index.d.ts.map +1 -0
- package/dist/components/CoreText/CoreText.d.ts +17 -0
- package/dist/components/CoreText/CoreText.d.ts.map +1 -0
- package/dist/components/CoreText/CoreText.js +26 -0
- package/dist/components/CoreText/CoreText.js.map +1 -0
- package/dist/components/CoreText/CoreText.types.d.ts +26 -0
- package/dist/components/CoreText/CoreText.types.d.ts.map +1 -0
- package/{src/components/CoreText/index.ts → dist/components/CoreText/index.d.ts} +3 -2
- package/dist/components/CoreText/index.d.ts.map +1 -0
- package/dist/components/Divider/Divider.d.ts +17 -0
- package/dist/components/Divider/Divider.d.ts.map +1 -0
- package/dist/components/Divider/Divider.js +25 -0
- package/dist/components/Divider/Divider.js.map +1 -0
- package/dist/components/Divider/Divider.types.d.ts +17 -0
- package/dist/components/Divider/Divider.types.d.ts.map +1 -0
- package/{src/components/Divider/index.ts → dist/components/Divider/index.d.ts} +4 -3
- package/dist/components/Divider/index.d.ts.map +1 -0
- package/dist/components/InputImage/InputImage.d.ts +26 -0
- package/dist/components/InputImage/InputImage.d.ts.map +1 -0
- package/dist/components/InputImage/InputImage.js +284 -0
- package/dist/components/InputImage/InputImage.js.map +1 -0
- package/dist/components/InputImage/InputImage.types.d.ts +65 -0
- package/dist/components/InputImage/InputImage.types.d.ts.map +1 -0
- package/{src/components/InputImage/index.ts → dist/components/InputImage/index.d.ts} +3 -2
- package/dist/components/InputImage/index.d.ts.map +1 -0
- package/{src/components/Sidebar/Sidebar.tsx → dist/components/Sidebar/Sidebar.d.ts} +22 -42
- package/dist/components/Sidebar/Sidebar.d.ts.map +1 -0
- package/dist/components/Sidebar/Sidebar.js +27 -0
- package/dist/components/Sidebar/Sidebar.js.map +1 -0
- package/dist/components/Sidebar/Sidebar.types.d.ts +21 -0
- package/dist/components/Sidebar/Sidebar.types.d.ts.map +1 -0
- package/{src/components/Sidebar/index.ts → dist/components/Sidebar/index.d.ts} +4 -3
- package/dist/components/Sidebar/index.d.ts.map +1 -0
- package/dist/components/SidebarItem/SidebarItem.d.ts +19 -0
- package/dist/components/SidebarItem/SidebarItem.d.ts.map +1 -0
- package/dist/components/SidebarItem/SidebarItem.js +37 -0
- package/dist/components/SidebarItem/SidebarItem.js.map +1 -0
- package/dist/components/SidebarItem/SidebarItem.types.d.ts +33 -0
- package/dist/components/SidebarItem/SidebarItem.types.d.ts.map +1 -0
- package/{src/components/SidebarItem/index.ts → dist/components/SidebarItem/index.d.ts} +4 -3
- package/dist/components/SidebarItem/index.d.ts.map +1 -0
- package/dist/components/Skeleton/Skeleton.d.ts +18 -0
- package/dist/components/Skeleton/Skeleton.d.ts.map +1 -0
- package/dist/components/Skeleton/Skeleton.js +30 -0
- package/dist/components/Skeleton/Skeleton.js.map +1 -0
- package/dist/components/Skeleton/Skeleton.types.d.ts +31 -0
- package/dist/components/Skeleton/Skeleton.types.d.ts.map +1 -0
- package/{src/components/Skeleton/index.ts → dist/components/Skeleton/index.d.ts} +5 -5
- package/dist/components/Skeleton/index.d.ts.map +1 -0
- package/{src/components/Spacer/Spacer.tsx → dist/components/Spacer/Spacer.d.ts} +17 -31
- package/dist/components/Spacer/Spacer.d.ts.map +1 -0
- package/dist/components/Spacer/Spacer.js +21 -0
- package/dist/components/Spacer/Spacer.js.map +1 -0
- package/dist/components/Spacer/Spacer.types.d.ts +21 -0
- package/dist/components/Spacer/Spacer.types.d.ts.map +1 -0
- package/{src/components/Spacer/index.ts → dist/components/Spacer/index.d.ts} +4 -3
- package/dist/components/Spacer/index.d.ts.map +1 -0
- package/dist/components/TabItem/TabItem.d.ts +19 -0
- package/dist/components/TabItem/TabItem.d.ts.map +1 -0
- package/dist/components/TabItem/TabItem.js +33 -0
- package/dist/components/TabItem/TabItem.js.map +1 -0
- package/dist/components/TabItem/TabItem.types.d.ts +30 -0
- package/dist/components/TabItem/TabItem.types.d.ts.map +1 -0
- package/{src/components/TabItem/index.ts → dist/components/TabItem/index.d.ts} +4 -3
- package/dist/components/TabItem/index.d.ts.map +1 -0
- package/{src/components/Table/Table.tsx → dist/components/Table/Table.d.ts} +26 -39
- package/dist/components/Table/Table.d.ts.map +1 -0
- package/dist/components/Table/Table.js +18 -0
- package/dist/components/Table/Table.js.map +1 -0
- package/dist/components/Table/Table.types.d.ts +16 -0
- package/dist/components/Table/Table.types.d.ts.map +1 -0
- package/{src/components/Table/index.ts → dist/components/Table/index.d.ts} +4 -3
- package/dist/components/Table/index.d.ts.map +1 -0
- package/dist/components/TableRow/TableRow.d.ts +24 -0
- package/dist/components/TableRow/TableRow.d.ts.map +1 -0
- package/dist/components/TableRow/TableRow.js +35 -0
- package/dist/components/TableRow/TableRow.js.map +1 -0
- package/dist/components/TableRow/TableRow.types.d.ts +35 -0
- package/dist/components/TableRow/TableRow.types.d.ts.map +1 -0
- package/{src/components/TableRow/index.ts → dist/components/TableRow/index.d.ts} +4 -3
- package/dist/components/TableRow/index.d.ts.map +1 -0
- package/{src/components/Tabs/Tabs.tsx → dist/components/Tabs/Tabs.d.ts} +21 -37
- package/dist/components/Tabs/Tabs.d.ts.map +1 -0
- package/dist/components/Tabs/Tabs.js +23 -0
- package/dist/components/Tabs/Tabs.js.map +1 -0
- package/{src/components/Tabs/Tabs.types.ts → dist/components/Tabs/Tabs.types.d.ts} +16 -18
- package/dist/components/Tabs/Tabs.types.d.ts.map +1 -0
- package/{src/components/Tabs/index.ts → dist/components/Tabs/index.d.ts} +4 -3
- package/dist/components/Tabs/index.d.ts.map +1 -0
- package/{src/components/index.ts → dist/components/index.d.ts} +15 -15
- package/dist/components/index.d.ts.map +1 -0
- package/dist/compositions/index.d.ts +2 -0
- package/dist/compositions/index.d.ts.map +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +32 -0
- package/dist/index.js.map +1 -0
- package/dist/vite.svg +1 -0
- package/package.json +16 -16
- package/src/components/Button/Button.tsx +0 -82
- package/src/components/Button/Button.types.ts +0 -62
- package/src/components/Cell/Cell.tsx +0 -42
- package/src/components/Cell/Cell.types.ts +0 -42
- package/src/components/Codeblock/Codeblock.tsx +0 -88
- package/src/components/Codeblock/Codeblock.types.ts +0 -42
- package/src/components/CoreText/CoreText.tsx +0 -43
- package/src/components/CoreText/CoreText.types.ts +0 -56
- package/src/components/Divider/Divider.tsx +0 -35
- package/src/components/Divider/Divider.types.ts +0 -19
- package/src/components/InputImage/InputImage.tsx +0 -314
- package/src/components/InputImage/InputImage.types.ts +0 -86
- package/src/components/Sidebar/Sidebar.types.ts +0 -24
- package/src/components/SidebarItem/SidebarItem.tsx +0 -55
- package/src/components/SidebarItem/SidebarItem.types.ts +0 -39
- package/src/components/Skeleton/Skeleton.tsx +0 -41
- package/src/components/Skeleton/Skeleton.types.ts +0 -65
- package/src/components/Spacer/Spacer.types.ts +0 -58
- package/src/components/TabItem/TabItem.tsx +0 -45
- package/src/components/TabItem/TabItem.types.ts +0 -35
- package/src/components/Table/Table.types.ts +0 -18
- package/src/components/TableRow/TableRow.tsx +0 -53
- package/src/components/TableRow/TableRow.types.ts +0 -41
- package/src/compositions/index.ts +0 -3
- package/src/index.ts +0 -4
- /package/{src → dist}/components/Button/Button.css +0 -0
- /package/{src → dist}/components/Cell/Cell.css +0 -0
- /package/{src → dist}/components/Codeblock/Codeblock.css +0 -0
- /package/{src → dist}/components/Divider/Divider.css +0 -0
- /package/{src → dist}/components/InputImage/InputImage.css +0 -0
- /package/{src → dist}/components/Sidebar/Sidebar.css +0 -0
- /package/{src → dist}/components/SidebarItem/SidebarItem.css +0 -0
- /package/{src → dist}/components/Skeleton/Skeleton.css +0 -0
- /package/{src → dist}/components/TabItem/TabItem.css +0 -0
- /package/{src → dist}/components/Table/Table.css +0 -0
- /package/{src → dist}/components/TableRow/TableRow.css +0 -0
- /package/{src → dist}/components/Tabs/Tabs.css +0 -0
- /package/{src → dist}/index.css +0 -0
- /package/{src → dist}/styles/component-tokens.css +0 -0
- /package/{src → dist}/styles/component-tokens.current.css +0 -0
- /package/{src → dist}/styles/fonts.css +0 -0
- /package/{src → dist}/styles/global-tokens.css +0 -0
- /package/{src → dist}/styles/index.css +0 -0
- /package/{src → dist}/styles/number-tokens.css +0 -0
- /package/{src → dist}/styles/semantic-tokens.css +0 -0
- /package/{src → dist}/styles/style-tokens.css +0 -0
- /package/{src → dist}/styles/typography-tokens.css +0 -0
- /package/{src → dist}/styles.css +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Sidebar/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,YAAY,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { SidebarItemProps } from "./SidebarItem.types";
|
|
2
|
+
import "./SidebarItem.css";
|
|
3
|
+
/**
|
|
4
|
+
* SidebarItem - Sidebar navigation item component for the goo-ds design system
|
|
5
|
+
*
|
|
6
|
+
* Provides consistent sidebar navigation item with interactive states.
|
|
7
|
+
* Supports icons and active state indication.
|
|
8
|
+
* Token-first per Constitution (no hardcoded values).
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* ```tsx
|
|
12
|
+
* <SidebarItem>Dashboard</SidebarItem>
|
|
13
|
+
* <SidebarItem active icon={<HomeIcon />}>Home</SidebarItem>
|
|
14
|
+
* <SidebarItem onClick={() => navigate('/settings')}>Settings</SidebarItem>
|
|
15
|
+
* ```
|
|
16
|
+
*/
|
|
17
|
+
export declare function SidebarItem({ active, icon, children, className, onClick, href, ...props }: SidebarItemProps): import("react/jsx-runtime").JSX.Element;
|
|
18
|
+
export default SidebarItem;
|
|
19
|
+
//# sourceMappingURL=SidebarItem.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SidebarItem.d.ts","sourceRoot":"","sources":["../../../src/components/SidebarItem/SidebarItem.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAC5D,OAAO,mBAAmB,CAAC;AAE3B;;;;;;;;;;;;;GAaG;AACH,wBAAgB,WAAW,CAAC,EAC1B,MAAc,EACd,IAAI,EACJ,QAAQ,EACR,SAAc,EACd,OAAO,EACP,IAAI,EACJ,GAAG,KAAK,EACT,EAAE,gBAAgB,2CA2BlB;AAED,eAAe,WAAW,CAAC"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { jsxs as l, jsx as d } from "react/jsx-runtime";
|
|
2
|
+
/* empty css */
|
|
3
|
+
function v({
|
|
4
|
+
active: i = !1,
|
|
5
|
+
icon: s,
|
|
6
|
+
children: r,
|
|
7
|
+
className: n = "",
|
|
8
|
+
onClick: e,
|
|
9
|
+
href: t,
|
|
10
|
+
...o
|
|
11
|
+
}) {
|
|
12
|
+
const a = !!(e || t), m = (c) => {
|
|
13
|
+
e && e(c), t && !e && (window.location.href = t);
|
|
14
|
+
};
|
|
15
|
+
return /* @__PURE__ */ l(
|
|
16
|
+
"div",
|
|
17
|
+
{
|
|
18
|
+
className: `gds-sidebar-item ${i ? "gds-sidebar-item-active" : ""} ${a ? "gds-sidebar-item-interactive" : ""} ${n}`.trim(),
|
|
19
|
+
onClick: a ? m : void 0,
|
|
20
|
+
role: a ? "button" : void 0,
|
|
21
|
+
tabIndex: a ? 0 : void 0,
|
|
22
|
+
"aria-current": i ? "page" : void 0,
|
|
23
|
+
"data-component": "SidebarItem",
|
|
24
|
+
"data-active": i,
|
|
25
|
+
...o,
|
|
26
|
+
children: [
|
|
27
|
+
s && /* @__PURE__ */ d("span", { className: "gds-sidebar-item-icon", children: s }),
|
|
28
|
+
/* @__PURE__ */ d("span", { className: "gds-sidebar-item-text", children: r })
|
|
29
|
+
]
|
|
30
|
+
}
|
|
31
|
+
);
|
|
32
|
+
}
|
|
33
|
+
export {
|
|
34
|
+
v as SidebarItem,
|
|
35
|
+
v as default
|
|
36
|
+
};
|
|
37
|
+
//# sourceMappingURL=SidebarItem.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SidebarItem.js","sources":["../../../src/components/SidebarItem/SidebarItem.tsx"],"sourcesContent":["import type { SidebarItemProps } from \"./SidebarItem.types\";\r\nimport \"./SidebarItem.css\";\r\n\r\n/**\r\n * SidebarItem - Sidebar navigation item component for the goo-ds design system\r\n *\r\n * Provides consistent sidebar navigation item with interactive states.\r\n * Supports icons and active state indication.\r\n * Token-first per Constitution (no hardcoded values).\r\n *\r\n * @example\r\n * ```tsx\r\n * <SidebarItem>Dashboard</SidebarItem>\r\n * <SidebarItem active icon={<HomeIcon />}>Home</SidebarItem>\r\n * <SidebarItem onClick={() => navigate('/settings')}>Settings</SidebarItem>\r\n * ```\r\n */\r\nexport function SidebarItem({\r\n active = false,\r\n icon,\r\n children,\r\n className = \"\",\r\n onClick,\r\n href,\r\n ...props\r\n}: SidebarItemProps) {\r\n const isInteractive = Boolean(onClick || href);\r\n\r\n const handleClick = (event: React.MouseEvent<HTMLDivElement>) => {\r\n if (onClick) {\r\n onClick(event);\r\n }\r\n if (href && !onClick) {\r\n window.location.href = href;\r\n }\r\n };\r\n\r\n return (\r\n <div\r\n className={`gds-sidebar-item ${active ? \"gds-sidebar-item-active\" : \"\"} ${isInteractive ? \"gds-sidebar-item-interactive\" : \"\"} ${className}`.trim()}\r\n onClick={isInteractive ? handleClick : undefined}\r\n role={isInteractive ? \"button\" : undefined}\r\n tabIndex={isInteractive ? 0 : undefined}\r\n aria-current={active ? \"page\" : undefined}\r\n data-component=\"SidebarItem\"\r\n data-active={active}\r\n {...props}\r\n >\r\n {icon && <span className=\"gds-sidebar-item-icon\">{icon}</span>}\r\n <span className=\"gds-sidebar-item-text\">{children}</span>\r\n </div>\r\n );\r\n}\r\n\r\nexport default SidebarItem;\r\n"],"names":["SidebarItem","active","icon","children","className","onClick","href","props","isInteractive","handleClick","event","jsxs","jsx"],"mappings":";;AAiBO,SAASA,EAAY;AAAA,EAC1B,QAAAC,IAAS;AAAA,EACT,MAAAC;AAAA,EACA,UAAAC;AAAA,EACA,WAAAC,IAAY;AAAA,EACZ,SAAAC;AAAA,EACA,MAAAC;AAAA,EACA,GAAGC;AACL,GAAqB;AACnB,QAAMC,IAAgB,GAAQH,KAAWC,IAEnCG,IAAc,CAACC,MAA4C;AAC/D,IAAIL,KACFA,EAAQK,CAAK,GAEXJ,KAAQ,CAACD,MACX,OAAO,SAAS,OAAOC;AAAA,EAE3B;AAEA,SACE,gBAAAK;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAW,oBAAoBV,IAAS,4BAA4B,EAAE,IAAIO,IAAgB,iCAAiC,EAAE,IAAIJ,CAAS,GAAG,KAAA;AAAA,MAC7I,SAASI,IAAgBC,IAAc;AAAA,MACvC,MAAMD,IAAgB,WAAW;AAAA,MACjC,UAAUA,IAAgB,IAAI;AAAA,MAC9B,gBAAcP,IAAS,SAAS;AAAA,MAChC,kBAAe;AAAA,MACf,eAAaA;AAAA,MACZ,GAAGM;AAAA,MAEH,UAAA;AAAA,QAAAL,KAAQ,gBAAAU,EAAC,QAAA,EAAK,WAAU,yBAAyB,UAAAV,GAAK;AAAA,QACvD,gBAAAU,EAAC,QAAA,EAAK,WAAU,yBAAyB,UAAAT,EAAA,CAAS;AAAA,MAAA;AAAA,IAAA;AAAA,EAAA;AAGxD;"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import type { ReactNode } from "react";
|
|
2
|
+
/**
|
|
3
|
+
* SidebarItem component props
|
|
4
|
+
* Provides sidebar navigation items using design system tokens
|
|
5
|
+
*/
|
|
6
|
+
export interface SidebarItemProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
7
|
+
/**
|
|
8
|
+
* Whether the item is currently active/selected
|
|
9
|
+
* @default false
|
|
10
|
+
*/
|
|
11
|
+
active?: boolean;
|
|
12
|
+
/**
|
|
13
|
+
* Icon to display before the text
|
|
14
|
+
*/
|
|
15
|
+
icon?: ReactNode;
|
|
16
|
+
/**
|
|
17
|
+
* Item content (text or other elements)
|
|
18
|
+
*/
|
|
19
|
+
children?: ReactNode;
|
|
20
|
+
/**
|
|
21
|
+
* Additional CSS class names
|
|
22
|
+
*/
|
|
23
|
+
className?: string;
|
|
24
|
+
/**
|
|
25
|
+
* Click handler for navigation
|
|
26
|
+
*/
|
|
27
|
+
onClick?: (event: React.MouseEvent<HTMLDivElement>) => void;
|
|
28
|
+
/**
|
|
29
|
+
* href for link behavior (optional)
|
|
30
|
+
*/
|
|
31
|
+
href?: string;
|
|
32
|
+
}
|
|
33
|
+
//# sourceMappingURL=SidebarItem.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SidebarItem.types.d.ts","sourceRoot":"","sources":["../../../src/components/SidebarItem/SidebarItem.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC;;;GAGG;AAEH,MAAM,WAAW,gBAAiB,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IAC5E;;;OAGG;IACH,MAAM,CAAC,EAAE,OAAO,CAAC;IAEjB;;OAEG;IACH,IAAI,CAAC,EAAE,SAAS,CAAC;IAEjB;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAC;IAErB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,KAAK,CAAC,UAAU,CAAC,cAAc,CAAC,KAAK,IAAI,CAAC;IAE5D;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;CACf"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
-
export { SidebarItem } from "./SidebarItem";
|
|
2
|
-
export type { SidebarItemProps } from "./SidebarItem.types";
|
|
3
|
-
export { default } from "./SidebarItem";
|
|
1
|
+
export { SidebarItem } from "./SidebarItem";
|
|
2
|
+
export type { SidebarItemProps } from "./SidebarItem.types";
|
|
3
|
+
export { default } from "./SidebarItem";
|
|
4
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/SidebarItem/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,YAAY,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAC5D,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { SkeletonProps } from "./Skeleton.types";
|
|
2
|
+
/**
|
|
3
|
+
* Skeleton - Loading state placeholder component for the goo-ds design system
|
|
4
|
+
*
|
|
5
|
+
* Provides consistent loading state placeholders using design system tokens.
|
|
6
|
+
* Includes a pulse animation to indicate loading state.
|
|
7
|
+
* Token-first per Constitution (no hardcoded values).
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* ```tsx
|
|
11
|
+
* <Skeleton size="16" />
|
|
12
|
+
* <Skeleton size="48" width="200px" />
|
|
13
|
+
* <Skeleton size="64" animate={false} />
|
|
14
|
+
* ```
|
|
15
|
+
*/
|
|
16
|
+
export declare function Skeleton({ size, className, width, animate, ...props }: SkeletonProps): import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
export default Skeleton;
|
|
18
|
+
//# sourceMappingURL=Skeleton.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Skeleton.d.ts","sourceRoot":"","sources":["../../../src/components/Skeleton/Skeleton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAEtD;;;;;;;;;;;;;GAaG;AACH,wBAAgB,QAAQ,CAAC,EACvB,IAAW,EACX,SAAc,EACd,KAAc,EACd,OAAc,EACd,GAAG,KAAK,EACT,EAAE,aAAa,2CAgBf;AAED,eAAe,QAAQ,CAAC"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { jsx as d } from "react/jsx-runtime";
|
|
2
|
+
function l({
|
|
3
|
+
size: e = "16",
|
|
4
|
+
className: a = "",
|
|
5
|
+
width: r = "100%",
|
|
6
|
+
animate: o = !0,
|
|
7
|
+
...t
|
|
8
|
+
}) {
|
|
9
|
+
return /* @__PURE__ */ d(
|
|
10
|
+
"div",
|
|
11
|
+
{
|
|
12
|
+
className: `${o ? "skeleton-pulse" : ""} ${a}`.trim(),
|
|
13
|
+
style: {
|
|
14
|
+
height: `var(--size-${e})`,
|
|
15
|
+
width: r,
|
|
16
|
+
backgroundColor: "var(--skeleton-background-default)",
|
|
17
|
+
borderRadius: "var(--radius-50)",
|
|
18
|
+
overflow: "clip"
|
|
19
|
+
},
|
|
20
|
+
"aria-hidden": t["aria-hidden"] !== !1,
|
|
21
|
+
"data-component": "Skeleton",
|
|
22
|
+
"data-size": e
|
|
23
|
+
}
|
|
24
|
+
);
|
|
25
|
+
}
|
|
26
|
+
export {
|
|
27
|
+
l as Skeleton,
|
|
28
|
+
l as default
|
|
29
|
+
};
|
|
30
|
+
//# sourceMappingURL=Skeleton.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Skeleton.js","sources":["../../../src/components/Skeleton/Skeleton.tsx"],"sourcesContent":["import type { SkeletonProps } from \"./Skeleton.types\";\r\n\r\n/**\r\n * Skeleton - Loading state placeholder component for the goo-ds design system\r\n *\r\n * Provides consistent loading state placeholders using design system tokens.\r\n * Includes a pulse animation to indicate loading state.\r\n * Token-first per Constitution (no hardcoded values).\r\n *\r\n * @example\r\n * ```tsx\r\n * <Skeleton size=\"16\" />\r\n * <Skeleton size=\"48\" width=\"200px\" />\r\n * <Skeleton size=\"64\" animate={false} />\r\n * ```\r\n */\r\nexport function Skeleton({\r\n size = \"16\",\r\n className = \"\",\r\n width = \"100%\",\r\n animate = true,\r\n ...props\r\n}: SkeletonProps) {\r\n return (\r\n <div\r\n className={`${animate ? \"skeleton-pulse\" : \"\"} ${className}`.trim()}\r\n style={{\r\n height: `var(--size-${size})`,\r\n width: width,\r\n backgroundColor: \"var(--skeleton-background-default)\",\r\n borderRadius: \"var(--radius-50)\",\r\n overflow: \"clip\",\r\n }}\r\n aria-hidden={props[\"aria-hidden\"] !== false}\r\n data-component=\"Skeleton\"\r\n data-size={size}\r\n />\r\n );\r\n}\r\n\r\nexport default Skeleton;\r\n"],"names":["Skeleton","size","className","width","animate","props","jsx"],"mappings":";AAgBO,SAASA,EAAS;AAAA,EACvB,MAAAC,IAAO;AAAA,EACP,WAAAC,IAAY;AAAA,EACZ,OAAAC,IAAQ;AAAA,EACR,SAAAC,IAAU;AAAA,EACV,GAAGC;AACL,GAAkB;AAChB,SACE,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAW,GAAGF,IAAU,mBAAmB,EAAE,IAAIF,CAAS,GAAG,KAAA;AAAA,MAC7D,OAAO;AAAA,QACL,QAAQ,cAAcD,CAAI;AAAA,QAC1B,OAAAE;AAAA,QACA,iBAAiB;AAAA,QACjB,cAAc;AAAA,QACd,UAAU;AAAA,MAAA;AAAA,MAEZ,eAAaE,EAAM,aAAa,MAAM;AAAA,MACtC,kBAAe;AAAA,MACf,aAAWJ;AAAA,IAAA;AAAA,EAAA;AAGjB;"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Skeleton component props
|
|
3
|
+
* Provides loading state placeholders using design system tokens
|
|
4
|
+
*/
|
|
5
|
+
export type SkeletonSize = "1" | "2" | "4" | "6" | "8" | "12" | "16" | "20" | "24" | "28" | "32" | "36" | "40" | "44" | "48" | "56" | "64" | "80" | "96" | "112" | "128" | "144" | "160" | "176" | "192" | "208" | "224" | "240" | "256";
|
|
6
|
+
export interface SkeletonProps {
|
|
7
|
+
/**
|
|
8
|
+
* The height of the skeleton, corresponding to number tokens (--size-X)
|
|
9
|
+
* @default "16"
|
|
10
|
+
*/
|
|
11
|
+
size?: SkeletonSize;
|
|
12
|
+
/**
|
|
13
|
+
* Additional CSS class names
|
|
14
|
+
*/
|
|
15
|
+
className?: string;
|
|
16
|
+
/**
|
|
17
|
+
* Width of the skeleton (CSS value or percentage)
|
|
18
|
+
* @default "100%"
|
|
19
|
+
*/
|
|
20
|
+
width?: string;
|
|
21
|
+
/**
|
|
22
|
+
* Whether to animate the skeleton with a pulse effect
|
|
23
|
+
* @default true
|
|
24
|
+
*/
|
|
25
|
+
animate?: boolean;
|
|
26
|
+
/**
|
|
27
|
+
* ARIA label for accessibility (optional, for screen readers)
|
|
28
|
+
*/
|
|
29
|
+
"aria-hidden"?: boolean;
|
|
30
|
+
}
|
|
31
|
+
//# sourceMappingURL=Skeleton.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Skeleton.types.d.ts","sourceRoot":"","sources":["../../../src/components/Skeleton/Skeleton.types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,MAAM,MAAM,YAAY,GACpB,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,CAAC;AAEV,MAAM,WAAW,aAAa;IAC5B;;;OAGG;IACH,IAAI,CAAC,EAAE,YAAY,CAAC;IAEpB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;OAGG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB;;OAEG;IACH,aAAa,CAAC,EAAE,OAAO,CAAC;CACzB"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import "./Skeleton.css";
|
|
2
|
-
|
|
3
|
-
export {
|
|
4
|
-
export
|
|
5
|
-
|
|
1
|
+
import "./Skeleton.css";
|
|
2
|
+
export { Skeleton } from "./Skeleton";
|
|
3
|
+
export type { SkeletonProps, SkeletonSize } from "./Skeleton.types";
|
|
4
|
+
export { default } from "./Skeleton";
|
|
5
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Skeleton/index.ts"],"names":[],"mappings":"AAAA,OAAO,gBAAgB,CAAC;AAExB,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,YAAY,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AACpE,OAAO,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC"}
|
|
@@ -1,31 +1,17 @@
|
|
|
1
|
-
import type { SpacerProps } from "./Spacer.types";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
* <Spacer size="
|
|
12
|
-
* <Spacer size="
|
|
13
|
-
*
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
export
|
|
17
|
-
|
|
18
|
-
<div
|
|
19
|
-
className={className}
|
|
20
|
-
style={{
|
|
21
|
-
height: `var(--size-${size})`,
|
|
22
|
-
width: "100%",
|
|
23
|
-
}}
|
|
24
|
-
aria-hidden={props["aria-hidden"] !== false}
|
|
25
|
-
data-component="Spacer"
|
|
26
|
-
data-size={size}
|
|
27
|
-
/>
|
|
28
|
-
);
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
export default Spacer;
|
|
1
|
+
import type { SpacerProps } from "./Spacer.types";
|
|
2
|
+
/**
|
|
3
|
+
* Spacer - Layout spacing component for the goo-ds design system
|
|
4
|
+
*
|
|
5
|
+
* Provides consistent vertical spacing using number tokens from Figma.
|
|
6
|
+
* Token-first per Constitution (no hardcoded values).
|
|
7
|
+
*
|
|
8
|
+
* @example
|
|
9
|
+
* ```tsx
|
|
10
|
+
* <Spacer size="16" />
|
|
11
|
+
* <Spacer size="32" />
|
|
12
|
+
* <Spacer size="64" />
|
|
13
|
+
* ```
|
|
14
|
+
*/
|
|
15
|
+
export declare function Spacer({ size, className, ...props }: SpacerProps): import("react/jsx-runtime").JSX.Element;
|
|
16
|
+
export default Spacer;
|
|
17
|
+
//# sourceMappingURL=Spacer.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Spacer.d.ts","sourceRoot":"","sources":["../../../src/components/Spacer/Spacer.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAElD;;;;;;;;;;;;GAYG;AACH,wBAAgB,MAAM,CAAC,EAAE,IAAW,EAAE,SAAc,EAAE,GAAG,KAAK,EAAE,EAAE,WAAW,2CAa5E;AAED,eAAe,MAAM,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { jsx as i } from "react/jsx-runtime";
|
|
2
|
+
function d({ size: a = "16", className: e = "", ...t }) {
|
|
3
|
+
return /* @__PURE__ */ i(
|
|
4
|
+
"div",
|
|
5
|
+
{
|
|
6
|
+
className: e,
|
|
7
|
+
style: {
|
|
8
|
+
height: `var(--size-${a})`,
|
|
9
|
+
width: "100%"
|
|
10
|
+
},
|
|
11
|
+
"aria-hidden": t["aria-hidden"] !== !1,
|
|
12
|
+
"data-component": "Spacer",
|
|
13
|
+
"data-size": a
|
|
14
|
+
}
|
|
15
|
+
);
|
|
16
|
+
}
|
|
17
|
+
export {
|
|
18
|
+
d as Spacer,
|
|
19
|
+
d as default
|
|
20
|
+
};
|
|
21
|
+
//# sourceMappingURL=Spacer.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Spacer.js","sources":["../../../src/components/Spacer/Spacer.tsx"],"sourcesContent":["import type { SpacerProps } from \"./Spacer.types\";\r\n\r\n/**\r\n * Spacer - Layout spacing component for the goo-ds design system\r\n *\r\n * Provides consistent vertical spacing using number tokens from Figma.\r\n * Token-first per Constitution (no hardcoded values).\r\n *\r\n * @example\r\n * ```tsx\r\n * <Spacer size=\"16\" />\r\n * <Spacer size=\"32\" />\r\n * <Spacer size=\"64\" />\r\n * ```\r\n */\r\nexport function Spacer({ size = \"16\", className = \"\", ...props }: SpacerProps) {\r\n return (\r\n <div\r\n className={className}\r\n style={{\r\n height: `var(--size-${size})`,\r\n width: \"100%\",\r\n }}\r\n aria-hidden={props[\"aria-hidden\"] !== false}\r\n data-component=\"Spacer\"\r\n data-size={size}\r\n />\r\n );\r\n}\r\n\r\nexport default Spacer;\r\n"],"names":["Spacer","size","className","props","jsx"],"mappings":";AAeO,SAASA,EAAO,EAAE,MAAAC,IAAO,MAAM,WAAAC,IAAY,IAAI,GAAGC,KAAsB;AAC7E,SACE,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAAF;AAAA,MACA,OAAO;AAAA,QACL,QAAQ,cAAcD,CAAI;AAAA,QAC1B,OAAO;AAAA,MAAA;AAAA,MAET,eAAaE,EAAM,aAAa,MAAM;AAAA,MACtC,kBAAe;AAAA,MACf,aAAWF;AAAA,IAAA;AAAA,EAAA;AAGjB;"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Spacer component props
|
|
3
|
+
* Provides vertical spacing using design system number tokens
|
|
4
|
+
*/
|
|
5
|
+
export type SpacerSize = "1" | "2" | "4" | "6" | "8" | "12" | "16" | "20" | "24" | "28" | "32" | "36" | "40" | "44" | "48" | "56" | "64" | "80" | "96" | "112" | "128" | "144" | "160" | "176" | "192" | "208" | "224" | "240" | "256" | "288" | "320" | "384" | "448" | "512";
|
|
6
|
+
export interface SpacerProps {
|
|
7
|
+
/**
|
|
8
|
+
* The size of the spacer, corresponding to number tokens (--size-X)
|
|
9
|
+
* @default "16"
|
|
10
|
+
*/
|
|
11
|
+
size?: SpacerSize;
|
|
12
|
+
/**
|
|
13
|
+
* Additional CSS class names
|
|
14
|
+
*/
|
|
15
|
+
className?: string;
|
|
16
|
+
/**
|
|
17
|
+
* ARIA label for accessibility (optional, for screen readers)
|
|
18
|
+
*/
|
|
19
|
+
"aria-hidden"?: boolean;
|
|
20
|
+
}
|
|
21
|
+
//# sourceMappingURL=Spacer.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Spacer.types.d.ts","sourceRoot":"","sources":["../../../src/components/Spacer/Spacer.types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,MAAM,MAAM,UAAU,GAClB,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,CAAC;AAEV,MAAM,WAAW,WAAW;IAC1B;;;OAGG;IACH,IAAI,CAAC,EAAE,UAAU,CAAC;IAElB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,aAAa,CAAC,EAAE,OAAO,CAAC;CACzB"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
-
export { Spacer } from "./Spacer";
|
|
2
|
-
export type { SpacerProps, SpacerSize } from "./Spacer.types";
|
|
3
|
-
export { default } from "./Spacer";
|
|
1
|
+
export { Spacer } from "./Spacer";
|
|
2
|
+
export type { SpacerProps, SpacerSize } from "./Spacer.types";
|
|
3
|
+
export { default } from "./Spacer";
|
|
4
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Spacer/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,YAAY,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAC9D,OAAO,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { TabItemProps } from "./TabItem.types";
|
|
2
|
+
import "./TabItem.css";
|
|
3
|
+
/**
|
|
4
|
+
* TabItem - Tab navigation item component for the goo-ds design system
|
|
5
|
+
*
|
|
6
|
+
* Provides consistent tab item with selected/unselected states.
|
|
7
|
+
* Designed to be used within a Tabs container.
|
|
8
|
+
* Token-first per Constitution (no hardcoded values).
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* ```tsx
|
|
12
|
+
* <TabItem selected>Overview</TabItem>
|
|
13
|
+
* <TabItem onClick={() => handleTabChange('details')}>Details</TabItem>
|
|
14
|
+
* <TabItem>Settings</TabItem>
|
|
15
|
+
* ```
|
|
16
|
+
*/
|
|
17
|
+
export declare function TabItem({ selected, children, className, onClick, disabled, ...props }: TabItemProps): import("react/jsx-runtime").JSX.Element;
|
|
18
|
+
export default TabItem;
|
|
19
|
+
//# sourceMappingURL=TabItem.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TabItem.d.ts","sourceRoot":"","sources":["../../../src/components/TabItem/TabItem.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,eAAe,CAAC;AAEvB;;;;;;;;;;;;;GAaG;AACH,wBAAgB,OAAO,CAAC,EACtB,QAAgB,EAChB,QAAQ,EACR,SAAc,EACd,OAAO,EACP,QAAgB,EAChB,GAAG,KAAK,EACT,EAAE,YAAY,2CAkBd;AAED,eAAe,OAAO,CAAC"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
+
/* empty css */
|
|
3
|
+
function r({
|
|
4
|
+
selected: t = !1,
|
|
5
|
+
children: s,
|
|
6
|
+
className: m = "",
|
|
7
|
+
onClick: i,
|
|
8
|
+
disabled: a = !1,
|
|
9
|
+
...b
|
|
10
|
+
}) {
|
|
11
|
+
return /* @__PURE__ */ e(
|
|
12
|
+
"button",
|
|
13
|
+
{
|
|
14
|
+
type: "button",
|
|
15
|
+
className: `gds-tab-item ${t ? "gds-tab-item-selected" : "gds-tab-item-unselected"} ${a ? "gds-tab-item-disabled" : ""} ${m}`.trim(),
|
|
16
|
+
onClick: i,
|
|
17
|
+
disabled: a,
|
|
18
|
+
role: "tab",
|
|
19
|
+
"aria-selected": t,
|
|
20
|
+
"aria-disabled": a,
|
|
21
|
+
tabIndex: t ? 0 : -1,
|
|
22
|
+
"data-component": "TabItem",
|
|
23
|
+
"data-selected": t,
|
|
24
|
+
...b,
|
|
25
|
+
children: /* @__PURE__ */ e("span", { className: "gds-tab-item-text", children: s })
|
|
26
|
+
}
|
|
27
|
+
);
|
|
28
|
+
}
|
|
29
|
+
export {
|
|
30
|
+
r as TabItem,
|
|
31
|
+
r as default
|
|
32
|
+
};
|
|
33
|
+
//# sourceMappingURL=TabItem.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TabItem.js","sources":["../../../src/components/TabItem/TabItem.tsx"],"sourcesContent":["import type { TabItemProps } from \"./TabItem.types\";\r\nimport \"./TabItem.css\";\r\n\r\n/**\r\n * TabItem - Tab navigation item component for the goo-ds design system\r\n *\r\n * Provides consistent tab item with selected/unselected states.\r\n * Designed to be used within a Tabs container.\r\n * Token-first per Constitution (no hardcoded values).\r\n *\r\n * @example\r\n * ```tsx\r\n * <TabItem selected>Overview</TabItem>\r\n * <TabItem onClick={() => handleTabChange('details')}>Details</TabItem>\r\n * <TabItem>Settings</TabItem>\r\n * ```\r\n */\r\nexport function TabItem({\r\n selected = false,\r\n children,\r\n className = \"\",\r\n onClick,\r\n disabled = false,\r\n ...props\r\n}: TabItemProps) {\r\n return (\r\n <button\r\n type=\"button\"\r\n className={`gds-tab-item ${selected ? \"gds-tab-item-selected\" : \"gds-tab-item-unselected\"} ${disabled ? \"gds-tab-item-disabled\" : \"\"} ${className}`.trim()}\r\n onClick={onClick}\r\n disabled={disabled}\r\n role=\"tab\"\r\n aria-selected={selected}\r\n aria-disabled={disabled}\r\n tabIndex={selected ? 0 : -1}\r\n data-component=\"TabItem\"\r\n data-selected={selected}\r\n {...props}\r\n >\r\n <span className=\"gds-tab-item-text\">{children}</span>\r\n </button>\r\n );\r\n}\r\n\r\nexport default TabItem;\r\n"],"names":["TabItem","selected","children","className","onClick","disabled","props","jsx"],"mappings":";;AAiBO,SAASA,EAAQ;AAAA,EACtB,UAAAC,IAAW;AAAA,EACX,UAAAC;AAAA,EACA,WAAAC,IAAY;AAAA,EACZ,SAAAC;AAAA,EACA,UAAAC,IAAW;AAAA,EACX,GAAGC;AACL,GAAiB;AACf,SACE,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,MAAK;AAAA,MACL,WAAW,gBAAgBN,IAAW,0BAA0B,yBAAyB,IAAII,IAAW,0BAA0B,EAAE,IAAIF,CAAS,GAAG,KAAA;AAAA,MACpJ,SAAAC;AAAA,MACA,UAAAC;AAAA,MACA,MAAK;AAAA,MACL,iBAAeJ;AAAA,MACf,iBAAeI;AAAA,MACf,UAAUJ,IAAW,IAAI;AAAA,MACzB,kBAAe;AAAA,MACf,iBAAeA;AAAA,MACd,GAAGK;AAAA,MAEJ,UAAA,gBAAAC,EAAC,QAAA,EAAK,WAAU,qBAAqB,UAAAL,EAAA,CAAS;AAAA,IAAA;AAAA,EAAA;AAGpD;"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import type { ReactNode } from "react";
|
|
2
|
+
/**
|
|
3
|
+
* TabItem component props
|
|
4
|
+
* Provides tab navigation item using design system tokens
|
|
5
|
+
*/
|
|
6
|
+
export interface TabItemProps extends React.HTMLAttributes<HTMLButtonElement> {
|
|
7
|
+
/**
|
|
8
|
+
* Whether this tab is currently selected/active
|
|
9
|
+
* @default false
|
|
10
|
+
*/
|
|
11
|
+
selected?: boolean;
|
|
12
|
+
/**
|
|
13
|
+
* Tab content (text or other elements)
|
|
14
|
+
*/
|
|
15
|
+
children?: ReactNode;
|
|
16
|
+
/**
|
|
17
|
+
* Additional CSS class names
|
|
18
|
+
*/
|
|
19
|
+
className?: string;
|
|
20
|
+
/**
|
|
21
|
+
* Click handler for tab selection
|
|
22
|
+
*/
|
|
23
|
+
onClick?: (event: React.MouseEvent<HTMLButtonElement>) => void;
|
|
24
|
+
/**
|
|
25
|
+
* Whether the tab is disabled
|
|
26
|
+
* @default false
|
|
27
|
+
*/
|
|
28
|
+
disabled?: boolean;
|
|
29
|
+
}
|
|
30
|
+
//# sourceMappingURL=TabItem.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TabItem.types.d.ts","sourceRoot":"","sources":["../../../src/components/TabItem/TabItem.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC;;;GAGG;AAEH,MAAM,WAAW,YAAa,SAAQ,KAAK,CAAC,cAAc,CAAC,iBAAiB,CAAC;IAC3E;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IAEnB;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAC;IAErB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,KAAK,CAAC,UAAU,CAAC,iBAAiB,CAAC,KAAK,IAAI,CAAC;IAE/D;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
-
export { TabItem } from "./TabItem";
|
|
2
|
-
export type { TabItemProps } from "./TabItem.types";
|
|
3
|
-
export { default } from "./TabItem";
|
|
1
|
+
export { TabItem } from "./TabItem";
|
|
2
|
+
export type { TabItemProps } from "./TabItem.types";
|
|
3
|
+
export { default } from "./TabItem";
|
|
4
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/TabItem/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,YAAY,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC"}
|
|
@@ -1,39 +1,26 @@
|
|
|
1
|
-
import type { TableProps } from "./Table.types";
|
|
2
|
-
import "./Table.css";
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
* <Cell type="header">
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
*
|
|
19
|
-
* <Cell>
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
export
|
|
26
|
-
|
|
27
|
-
<table
|
|
28
|
-
className={`gds-table ${className}`.trim()}
|
|
29
|
-
data-component="Table"
|
|
30
|
-
{...props}
|
|
31
|
-
>
|
|
32
|
-
<tbody>
|
|
33
|
-
{children}
|
|
34
|
-
</tbody>
|
|
35
|
-
</table>
|
|
36
|
-
);
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
export default Table;
|
|
1
|
+
import type { TableProps } from "./Table.types";
|
|
2
|
+
import "./Table.css";
|
|
3
|
+
/**
|
|
4
|
+
* Table - Table container component for the goo-ds design system
|
|
5
|
+
*
|
|
6
|
+
* Provides consistent table layout with background, border, and rounded corners.
|
|
7
|
+
* Designed to contain TableRow components with Cell children.
|
|
8
|
+
* Token-first per Constitution (no hardcoded values).
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* ```tsx
|
|
12
|
+
* <Table>
|
|
13
|
+
* <TableRow>
|
|
14
|
+
* <Cell type="header">Name</Cell>
|
|
15
|
+
* <Cell type="header">Email</Cell>
|
|
16
|
+
* </TableRow>
|
|
17
|
+
* <TableRow>
|
|
18
|
+
* <Cell>John Doe</Cell>
|
|
19
|
+
* <Cell>john@example.com</Cell>
|
|
20
|
+
* </TableRow>
|
|
21
|
+
* </Table>
|
|
22
|
+
* ```
|
|
23
|
+
*/
|
|
24
|
+
export declare function Table({ children, className, ...props }: TableProps): import("react/jsx-runtime").JSX.Element;
|
|
25
|
+
export default Table;
|
|
26
|
+
//# sourceMappingURL=Table.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Table.d.ts","sourceRoot":"","sources":["../../../src/components/Table/Table.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAChD,OAAO,aAAa,CAAC;AAErB;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAgB,KAAK,CAAC,EAAE,QAAQ,EAAE,SAAc,EAAE,GAAG,KAAK,EAAE,EAAE,UAAU,2CAYvE;AAED,eAAe,KAAK,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
+
/* empty css */
|
|
3
|
+
function m({ children: a, className: e = "", ...o }) {
|
|
4
|
+
return /* @__PURE__ */ t(
|
|
5
|
+
"table",
|
|
6
|
+
{
|
|
7
|
+
className: `gds-table ${e}`.trim(),
|
|
8
|
+
"data-component": "Table",
|
|
9
|
+
...o,
|
|
10
|
+
children: /* @__PURE__ */ t("tbody", { children: a })
|
|
11
|
+
}
|
|
12
|
+
);
|
|
13
|
+
}
|
|
14
|
+
export {
|
|
15
|
+
m as Table,
|
|
16
|
+
m as default
|
|
17
|
+
};
|
|
18
|
+
//# sourceMappingURL=Table.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Table.js","sources":["../../../src/components/Table/Table.tsx"],"sourcesContent":["import type { TableProps } from \"./Table.types\";\r\nimport \"./Table.css\";\r\n\r\n/**\r\n * Table - Table container component for the goo-ds design system\r\n *\r\n * Provides consistent table layout with background, border, and rounded corners.\r\n * Designed to contain TableRow components with Cell children.\r\n * Token-first per Constitution (no hardcoded values).\r\n *\r\n * @example\r\n * ```tsx\r\n * <Table>\r\n * <TableRow>\r\n * <Cell type=\"header\">Name</Cell>\r\n * <Cell type=\"header\">Email</Cell>\r\n * </TableRow>\r\n * <TableRow>\r\n * <Cell>John Doe</Cell>\r\n * <Cell>john@example.com</Cell>\r\n * </TableRow>\r\n * </Table>\r\n * ```\r\n */\r\nexport function Table({ children, className = \"\", ...props }: TableProps) {\r\n return (\r\n <table\r\n className={`gds-table ${className}`.trim()}\r\n data-component=\"Table\"\r\n {...props}\r\n >\r\n <tbody>\r\n {children}\r\n </tbody>\r\n </table>\r\n );\r\n}\r\n\r\nexport default Table;\r\n"],"names":["Table","children","className","props","jsx"],"mappings":";;AAwBO,SAASA,EAAM,EAAE,UAAAC,GAAU,WAAAC,IAAY,IAAI,GAAGC,KAAqB;AACxE,SACE,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAW,aAAaF,CAAS,GAAG,KAAA;AAAA,MACpC,kBAAe;AAAA,MACd,GAAGC;AAAA,MAEJ,UAAA,gBAAAC,EAAC,WACE,UAAAH,EAAA,CACH;AAAA,IAAA;AAAA,EAAA;AAGN;"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { ReactNode } from "react";
|
|
2
|
+
/**
|
|
3
|
+
* Table component props
|
|
4
|
+
* Provides table container using design system tokens
|
|
5
|
+
*/
|
|
6
|
+
export interface TableProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
7
|
+
/**
|
|
8
|
+
* Table content (typically TableRow components)
|
|
9
|
+
*/
|
|
10
|
+
children?: ReactNode;
|
|
11
|
+
/**
|
|
12
|
+
* Additional CSS class names
|
|
13
|
+
*/
|
|
14
|
+
className?: string;
|
|
15
|
+
}
|
|
16
|
+
//# sourceMappingURL=Table.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Table.types.d.ts","sourceRoot":"","sources":["../../../src/components/Table/Table.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC;;;GAGG;AAEH,MAAM,WAAW,UAAW,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IACtE;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAC;IAErB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
-
export { Table } from "./Table";
|
|
2
|
-
export type { TableProps } from "./Table.types";
|
|
3
|
-
export { default } from "./Table";
|
|
1
|
+
export { Table } from "./Table";
|
|
2
|
+
export type { TableProps } from "./Table.types";
|
|
3
|
+
export { default } from "./Table";
|
|
4
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Table/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,YAAY,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAChD,OAAO,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import type { TableRowProps } from "./TableRow.types";
|
|
2
|
+
import "./TableRow.css";
|
|
3
|
+
/**
|
|
4
|
+
* TableRow - Table row component for the goo-ds design system
|
|
5
|
+
*
|
|
6
|
+
* Provides consistent table row layout with interactive states and dividers.
|
|
7
|
+
* Designed to contain Cell components.
|
|
8
|
+
* Token-first per Constitution (no hardcoded values).
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* ```tsx
|
|
12
|
+
* <TableRow>
|
|
13
|
+
* <Cell>Name</Cell>
|
|
14
|
+
* <Cell>Email</Cell>
|
|
15
|
+
* </TableRow>
|
|
16
|
+
* <TableRow selected>
|
|
17
|
+
* <Cell>John</Cell>
|
|
18
|
+
* <Cell>john@example.com</Cell>
|
|
19
|
+
* </TableRow>
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
22
|
+
export declare function TableRow({ divider, selected, disabled, children, className, onClick, ...props }: TableRowProps): import("react/jsx-runtime").JSX.Element;
|
|
23
|
+
export default TableRow;
|
|
24
|
+
//# sourceMappingURL=TableRow.d.ts.map
|