linkedunion-design-kit 1.7.3 → 1.7.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (126) hide show
  1. package/dist/src/components/Button/Button.js +4 -4
  2. package/dist/src/components/Card/MultipleNews/MultiNews.stories.d.ts +7 -7
  3. package/dist/src/components/Card/MultipleNews/MultiNews.stories.js +6 -6
  4. package/dist/src/components/Card/PhotoGallery.css +11 -0
  5. package/dist/src/components/Card/{SinglePost.d.ts → SinglePost/SinglePost.d.ts} +1 -1
  6. package/dist/src/components/Card/SinglePost/SinglePost.js +10 -0
  7. package/dist/src/components/Card/{SinglePost.stories.js → SinglePost/SinglePost.stories.js} +1 -1
  8. package/dist/src/components/Card/card.js +1 -1
  9. package/dist/src/components/ImageUploader/imageUploader.js +1 -1
  10. package/dist/src/components/Label/Label.js +5 -5
  11. package/dist/src/components/Typography/Heading/heading.js +6 -6
  12. package/dist/src/components/ui/accordion.js +1 -1
  13. package/dist/src/components/ui/caption.js +1 -1
  14. package/dist/src/components/ui/switch.js +4 -4
  15. package/dist/src/components/ui/tabs.js +2 -2
  16. package/dist/src/utils/iconList.js +1 -1
  17. package/dist/styles/global.css +46 -30
  18. package/package.json +1 -1
  19. package/dist/app/layout.jsx +0 -13
  20. package/dist/app/page.jsx +0 -5
  21. package/dist/src/components/Accordion/Accordion.stories.jsx +0 -25
  22. package/dist/src/components/Avatar/Avatar.jsx +0 -17
  23. package/dist/src/components/Avatar/Avatar.stories.jsx +0 -31
  24. package/dist/src/components/Avatar/Avatar.test.jsx +0 -51
  25. package/dist/src/components/Button/Button.jsx +0 -93
  26. package/dist/src/components/Button/Button.stories.jsx +0 -248
  27. package/dist/src/components/Button/Button.test.jsx +0 -73
  28. package/dist/src/components/Button/IconButton.jsx +0 -70
  29. package/dist/src/components/Button/IconButton.stories.jsx +0 -53
  30. package/dist/src/components/Button/IconButton.test.jsx +0 -27
  31. package/dist/src/components/Card/ContactProfile.d.ts +0 -2
  32. package/dist/src/components/Card/ContactProfile.js +0 -35
  33. package/dist/src/components/Card/ContactProfile.jsx +0 -57
  34. package/dist/src/components/Card/ContactProfile.stories.d.ts +0 -9
  35. package/dist/src/components/Card/ContactProfile.stories.js +0 -52
  36. package/dist/src/components/Card/ContactProfile.stories.jsx +0 -52
  37. package/dist/src/components/Card/MultiNews.d.ts +0 -2
  38. package/dist/src/components/Card/MultiNews.js +0 -43
  39. package/dist/src/components/Card/MultiNews.jsx +0 -59
  40. package/dist/src/components/Card/MultiNews.stories.d.ts +0 -9
  41. package/dist/src/components/Card/MultiNews.stories.js +0 -52
  42. package/dist/src/components/Card/MultiNews.stories.jsx +0 -52
  43. package/dist/src/components/Card/PostByCategory/PostByCategory.jsx +0 -60
  44. package/dist/src/components/Card/PostByCategory/PostByCategory.stories.jsx +0 -54
  45. package/dist/src/components/Card/PostByCategory.d.ts +0 -2
  46. package/dist/src/components/Card/PostByCategory.js +0 -38
  47. package/dist/src/components/Card/PostByCategory.stories.d.ts +0 -9
  48. package/dist/src/components/Card/PostByCategory.stories.js +0 -54
  49. package/dist/src/components/Card/SinglePost.js +0 -10
  50. package/dist/src/components/Card/SinglePost.jsx +0 -27
  51. package/dist/src/components/Card/SinglePost.stories.jsx +0 -46
  52. package/dist/src/components/Card/card.jsx +0 -31
  53. package/dist/src/components/Checkbox/checkbox.stories.jsx +0 -91
  54. package/dist/src/components/ColorPicker/ColorPicker.jsx +0 -65
  55. package/dist/src/components/ColorPicker/ColorPicker.stories.jsx +0 -14
  56. package/dist/src/components/Colors/color.jsx +0 -5
  57. package/dist/src/components/Colors/color.stories.jsx +0 -20
  58. package/dist/src/components/Colors/color.test.jsx +0 -23
  59. package/dist/src/components/EditorTooltip/EditorTooltip.d.ts +0 -5
  60. package/dist/src/components/EditorTooltip/EditorTooltip.js +0 -8
  61. package/dist/src/components/EditorTooltip/EditorTooltip.stories.d.ts +0 -6
  62. package/dist/src/components/EditorTooltip/EditorTooltip.stories.js +0 -24
  63. package/dist/src/components/Icons/IconList.test.jsx +0 -57
  64. package/dist/src/components/Icons/IconView.jsx +0 -25
  65. package/dist/src/components/Icons/IconView.stories.jsx +0 -8
  66. package/dist/src/components/Icons/LUIcon.jsx +0 -37
  67. package/dist/src/components/Icons/LUIcon.stories.jsx +0 -63
  68. package/dist/src/components/Icons/SingleIcon.test.jsx +0 -56
  69. package/dist/src/components/ImageUploader/ImageUploader.stories.jsx +0 -18
  70. package/dist/src/components/ImageUploader/imageUploader.jsx +0 -81
  71. package/dist/src/components/Images/LuImage.jsx +0 -19
  72. package/dist/src/components/Images/LuImage.stories.jsx +0 -154
  73. package/dist/src/components/Images/LuImage.test.jsx +0 -44
  74. package/dist/src/components/Input/Input.stories.jsx +0 -34
  75. package/dist/src/components/Label/Label.jsx +0 -32
  76. package/dist/src/components/Label/Label.stories.jsx +0 -30
  77. package/dist/src/components/Label/type.d.ts +0 -9
  78. package/dist/src/components/Label/type.js +0 -1
  79. package/dist/src/components/MediaCard/Card.jsx +0 -36
  80. package/dist/src/components/MediaCard/Card.stories.jsx +0 -56
  81. package/dist/src/components/MediaCard/Card.test.jsx +0 -27
  82. package/dist/src/components/MediaCard/ContactProfile/ContactProfile.jsx +0 -22
  83. package/dist/src/components/MediaCard/ContactProfile/ContactProfile.test.jsx +0 -60
  84. package/dist/src/components/MediaCard/ContactProfile/ContactProfileTheme1.jsx +0 -27
  85. package/dist/src/components/MediaCard/ContactProfile/ContactProfileTheme1.test.jsx +0 -87
  86. package/dist/src/components/MediaCard/ContactProfile/ContactProfileTheme2.jsx +0 -23
  87. package/dist/src/components/MediaCard/ContactProfile/ContactProfileTheme2.test.jsx +0 -87
  88. package/dist/src/components/MediaCard/PostByCategory/PostByCategory.jsx +0 -24
  89. package/dist/src/components/MediaCard/PostByCategory/PostByCategory.test.jsx +0 -61
  90. package/dist/src/components/MediaCard/PostByCategory/PostByCategoryTheme1.jsx +0 -25
  91. package/dist/src/components/MediaCard/PostByCategory/PostByCategoryTheme1.test.jsx +0 -87
  92. package/dist/src/components/MediaCard/PostByCategory/PostByCategoryTheme2.jsx +0 -23
  93. package/dist/src/components/MediaCard/PostByCategory/PostByCategoryTheme2.test.jsx +0 -87
  94. package/dist/src/components/MediaCard/VerticalCard/VerticalCard.jsx +0 -30
  95. package/dist/src/components/MediaCard/VerticalCard/VerticalCard.stories.jsx +0 -65
  96. package/dist/src/components/RadioButton/RadioButton.stories.jsx +0 -40
  97. package/dist/src/components/RadioButton/radio-button.jsx +0 -30
  98. package/dist/src/components/Switch/Switch.stories.jsx +0 -66
  99. package/dist/src/components/Tabs/Tabs.stories.jsx +0 -29
  100. package/dist/src/components/Title/Title.jsx +0 -8
  101. package/dist/src/components/Title/Title.stories.jsx +0 -37
  102. package/dist/src/components/Title/Title.test.jsx +0 -24
  103. package/dist/src/components/ToolTip/Tooltip.jsx +0 -18
  104. package/dist/src/components/ToolTip/Tooltip.stories.jsx +0 -25
  105. package/dist/src/components/Typography/Body/Body.stories.jsx +0 -34
  106. package/dist/src/components/Typography/Body/body.jsx +0 -52
  107. package/dist/src/components/Typography/Caption/Caption.stories.jsx +0 -24
  108. package/dist/src/components/Typography/Display/Display.stories.jsx +0 -24
  109. package/dist/src/components/Typography/Display/display.jsx +0 -39
  110. package/dist/src/components/Typography/Heading/Heading.stories.jsx +0 -24
  111. package/dist/src/components/Typography/Heading/heading.jsx +0 -60
  112. package/dist/src/components/ui/accordion.jsx +0 -39
  113. package/dist/src/components/ui/body.d.ts +0 -0
  114. package/dist/src/components/ui/body.js +0 -1
  115. package/dist/src/components/ui/caption.jsx +0 -25
  116. package/dist/src/components/ui/checkbox.jsx +0 -24
  117. package/dist/src/components/ui/input.jsx +0 -18
  118. package/dist/src/components/ui/label.d.ts +0 -12
  119. package/dist/src/components/ui/label.js +0 -41
  120. package/dist/src/components/ui/radio-button.d.ts +0 -3
  121. package/dist/src/components/ui/radio-button.js +0 -42
  122. package/dist/src/components/ui/switch.jsx +0 -61
  123. package/dist/src/components/ui/tabs.jsx +0 -32
  124. package/dist/src/components/ui/tooltip.jsx +0 -38
  125. package/dist/src/components/ui/typography.jsx +0 -56
  126. /package/dist/src/components/Card/{SinglePost.stories.d.ts → SinglePost/SinglePost.stories.d.ts} +0 -0
@@ -1,40 +0,0 @@
1
- import { RadioButton } from "./radio-button";
2
- import { Label } from "../Label/Label";
3
- var meta = {
4
- title: "Components/RadioButton",
5
- component: RadioButton,
6
- tags: ["autodocs"],
7
- args: {
8
- id: "radio-example",
9
- name: "example",
10
- value: "option1",
11
- },
12
- };
13
- export default meta;
14
- //Basic Radio (no label)
15
- export var Default = {
16
- args: {
17
- checked: true,
18
- },
19
- };
20
- //With Label wrapping the radio
21
- export var WithLabel = {
22
- render: function (args) { return (<Label htmlFor="radio-with-label">
23
- <RadioButton {...args} id="radio-with-label"/>
24
- Upload a Video
25
- </Label>); },
26
- };
27
- //Disabled
28
- export var Disabled = {
29
- render: function (args) { return (<Label htmlFor="radio-disabled">
30
- <RadioButton {...args} id="radio-disabled" disabled/>
31
- Disabled Option
32
- </Label>); },
33
- };
34
- //Checked by default
35
- export var Checked = {
36
- render: function (args) { return (<Label htmlFor="radio-checked">
37
- <RadioButton {...args} id="radio-checked" checked/>
38
- Pre-selected
39
- </Label>); },
40
- };
@@ -1,30 +0,0 @@
1
- var __rest = (this && this.__rest) || function (s, e) {
2
- var t = {};
3
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
4
- t[p] = s[p];
5
- if (s != null && typeof Object.getOwnPropertySymbols === "function")
6
- for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
7
- if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
8
- t[p[i]] = s[p[i]];
9
- }
10
- return t;
11
- };
12
- // components/ui/radio-button.tsx
13
- import * as React from "react";
14
- import { cn } from "../../lib/utils";
15
- var RadioButton = React.forwardRef(function (_a, ref) {
16
- var className = _a.className, props = __rest(_a, ["className"]);
17
- return (<input ref={ref} type="radio" className={cn(
18
- // Size and shape
19
- "size-4 shrink-0 rounded-full border",
20
- // Unchecked state
21
- "border-gray-400",
22
- // Checked state
23
- "checked:border-blue-600 checked:bg-blue-600",
24
- // Smooth transition
25
- "transition-all duration-150 ease-in-out",
26
- // Disabled state
27
- "disabled:cursor-not-allowed disabled:opacity-50", className)} {...props}/>);
28
- });
29
- RadioButton.displayName = "RadioButton";
30
- export { RadioButton };
@@ -1,66 +0,0 @@
1
- import { size, Switch, variant } from "../ui/switch";
2
- export default {
3
- title: "Components/Switch",
4
- component: Switch,
5
- tags: ["autodocs"],
6
- };
7
- var Template = function (args) { return <Switch {...args}></Switch>; };
8
- export var _Switch = Template.bind({});
9
- _Switch.args = {
10
- size: "md",
11
- variant: "default",
12
- defaultChecked: false,
13
- onCheckedChange: function (checked) {
14
- return console.log("Switch is ".concat(checked ? "on" : "off"));
15
- },
16
- };
17
- _Switch.argTypes = {
18
- variant: {
19
- control: { type: "select" },
20
- options: Object.keys(variant),
21
- description: "Switch variant",
22
- table: {
23
- defaultValue: { summary: "default" },
24
- type: { summary: "string" },
25
- },
26
- },
27
- size: {
28
- control: { type: "select" },
29
- options: Object.keys(size),
30
- description: "Switch size",
31
- table: {
32
- defaultValue: { summary: "md" },
33
- type: { summary: "string" },
34
- },
35
- },
36
- defaultChecked: {
37
- control: { type: "boolean" },
38
- description: "Initial checked state for uncontrolled switch",
39
- table: {
40
- defaultValue: { summary: "false" },
41
- type: { summary: "boolean" },
42
- },
43
- },
44
- checked: {
45
- control: { type: "boolean" },
46
- description: "Controlled checked state (e.g., checked={field.value} for form libraries)",
47
- table: {
48
- type: { summary: "boolean" },
49
- },
50
- },
51
- onCheckedChange: {
52
- action: "checked changed",
53
- description: "Callback function when switch state changes",
54
- table: {
55
- type: { summary: "(checked: boolean) => void" },
56
- },
57
- },
58
- disabled: {
59
- control: { type: "boolean" },
60
- description: "Disables the switch",
61
- table: {
62
- defaultValue: { summary: "false" },
63
- type: { summary: "boolean" },
64
- },
65
- },
66
- };
@@ -1,29 +0,0 @@
1
- import React from "react";
2
- import { Tabs, TabsContent, TabsList, TabsTrigger } from "../ui/tabs";
3
- export default {
4
- title: "Components/Tabs",
5
- component: Tabs,
6
- tags: ["autodocs"],
7
- };
8
- var Template = function (args) {
9
- return <>{args.children}</>;
10
- };
11
- export var _Tabs = Template.bind({});
12
- _Tabs.args = {
13
- children: (<Tabs defaultValue="account">
14
- <TabsList>
15
- <TabsTrigger value="account">Account</TabsTrigger>
16
- <TabsTrigger value="password">Password</TabsTrigger>
17
- </TabsList>
18
- <TabsContent value="account">Account Settings</TabsContent>
19
- <TabsContent value="password">Change Password</TabsContent>
20
- </Tabs>),
21
- };
22
- _Tabs.argTypes = {
23
- children: {
24
- description: "Pass `TabList` components as children. Each item includes an `TabsTrigger` (the clickable label) and `TabsContent`. You can customize both with any valid React nodes \n\nFor more details and usage examples, refer to the [ShadCN Tabs documentation](https://ui.shadcn.com/docs/components/tabs).",
25
- table: {
26
- type: { summary: "React.ReactNode" },
27
- },
28
- },
29
- };
@@ -1,8 +0,0 @@
1
- import React from "react";
2
- import { Dummy_Title } from "../../utils/constants";
3
- import TitleStyles from "./Title.module.css";
4
- var Title = function (_a) {
5
- var _b = _a.className, className = _b === void 0 ? "" : _b, _c = _a.children, children = _c === void 0 ? Dummy_Title : _c;
6
- return (<h2 className={"".concat(TitleStyles["main-title"], " ").concat(className)}>{children}</h2>);
7
- };
8
- export default Title;
@@ -1,37 +0,0 @@
1
- import { Dummy_Title } from "../../utils/constants";
2
- import Title from "./Title";
3
- export default {
4
- title: "Components/Title",
5
- component: Title,
6
- parameters: {
7
- docs: {
8
- description: {
9
- component: "A configurable body text component with design system-approved styling variants",
10
- },
11
- },
12
- },
13
- argTypes: {
14
- className: {
15
- description: "Additional CSS classes",
16
- control: "text",
17
- table: {
18
- type: { summary: "string" },
19
- defaultValue: { summary: "" },
20
- },
21
- },
22
- children: {
23
- description: "Text to be displayed",
24
- control: "text",
25
- table: {
26
- type: { summary: "string" },
27
- defaultValue: { summary: "Title" },
28
- },
29
- },
30
- },
31
- };
32
- var Template = function (args) { return <Title {...args}/>; };
33
- export var _Title = Template.bind({});
34
- _Title.args = {
35
- children: Dummy_Title,
36
- className: "",
37
- };
@@ -1,24 +0,0 @@
1
- import { render, screen } from "@testing-library/react";
2
- import { Dummy_Title } from "../../utils/constants";
3
- import Title from "./Title";
4
- describe("Title Component", function () {
5
- it("renders with default props", function () {
6
- render(<Title />);
7
- expect(screen.getByText(Dummy_Title)).toBeInTheDocument();
8
- });
9
- it("renders with custom children", function () {
10
- var customText = "Custom Title";
11
- render(<Title>{customText}</Title>);
12
- expect(screen.getByText(customText)).toBeInTheDocument();
13
- });
14
- it("applies custom className", function () {
15
- var customClass = "custom-class";
16
- render(<Title className={customClass}/>);
17
- var titleElement = screen.getByText(Dummy_Title);
18
- expect(titleElement).toHaveClass("main-title custom-class");
19
- });
20
- it("renders without crashing", function () {
21
- var container = render(<Title />).container;
22
- expect(container).toBeDefined();
23
- });
24
- });
@@ -1,18 +0,0 @@
1
- import { Tooltip as ShadTooltip, TooltipContent, TooltipProvider, TooltipTrigger, } from "../ui/tooltip";
2
- import { Body } from "../Typography/Body/body";
3
- var Tooltip = function (_a) {
4
- var title = _a.title, className = _a.className, children = _a.children;
5
- return (<TooltipProvider>
6
- <ShadTooltip>
7
- <TooltipTrigger asChild className={className}>
8
- {children}
9
- </TooltipTrigger>
10
- <TooltipContent>
11
- <Body variant="body-md" className="text-center">
12
- {title}
13
- </Body>
14
- </TooltipContent>
15
- </ShadTooltip>
16
- </TooltipProvider>);
17
- };
18
- export default Tooltip;
@@ -1,25 +0,0 @@
1
- import Tooltip from "./Tooltip";
2
- import { IconButton } from "../Button/IconButton";
3
- export default {
4
- title: "Components/Tooltip",
5
- component: Tooltip,
6
- tags: ["autodocs"],
7
- };
8
- var Template = function (args) { return (<Tooltip {...args}></Tooltip>); };
9
- export var _ToolTip = Template.bind({});
10
- _ToolTip.args = {
11
- children: <IconButton icon="volume-high" shape="rounded-full"/>,
12
- title: "Tooltip",
13
- };
14
- _ToolTip.argTypes = {
15
- children: {
16
- description: "React component to be wrapped",
17
- control: false,
18
- table: {
19
- type: { summary: "string" },
20
- defaultValue: {
21
- summary: '<IconButton icon={<LUIcon icon="volume-high" size="sm"/>} shape="rounded-full"/>',
22
- },
23
- },
24
- },
25
- };
@@ -1,34 +0,0 @@
1
- import { Dummy_Para } from "../../../utils/constants";
2
- import { Body, variant } from "../../../components/Typography/Body/body";
3
- export default {
4
- title: "Components/Typography/Body",
5
- component: Body,
6
- tags: ["autodocs"],
7
- };
8
- var Template = function (args) { return <Body {...args}></Body>; };
9
- export var _Body = Template.bind({});
10
- _Body.args = {
11
- children: Dummy_Para,
12
- variant: "body-base",
13
- as: "p",
14
- };
15
- _Body.argTypes = {
16
- variant: {
17
- control: { type: "select" },
18
- options: Object.keys(variant),
19
- description: "Body Variant",
20
- table: {
21
- defaultValue: { summary: "body-base" },
22
- type: { summary: "string" },
23
- },
24
- },
25
- as: {
26
- control: { type: "select" },
27
- options: ["p", "span"],
28
- description: "HTML tag to render",
29
- table: {
30
- defaultValue: { summary: "p" },
31
- type: { summary: '"p" | "span"' },
32
- },
33
- },
34
- };
@@ -1,52 +0,0 @@
1
- var __rest = (this && this.__rest) || function (s, e) {
2
- var t = {};
3
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
4
- t[p] = s[p];
5
- if (s != null && typeof Object.getOwnPropertySymbols === "function")
6
- for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
7
- if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
8
- t[p[i]] = s[p[i]];
9
- }
10
- return t;
11
- };
12
- import * as React from "react";
13
- import { cva } from "class-variance-authority";
14
- import { cn } from "../../../lib/utils";
15
- export var variant = {
16
- "body-xl": "text-xl font-normal",
17
- "body-xl-500": "text-xl font-medium",
18
- "body-xl-600": "text-xl font-semibold",
19
- "body-xl-700": "text-xl font-bold",
20
- "body-lg": "text-lg font-normal",
21
- "body-lg-500": "text-lg font-medium",
22
- "body-lg-600": "text-lg font-semibold",
23
- "body-lg-700": "text-lg font-bold",
24
- "body-md": "text-base font-normal",
25
- "body-md-500": "text-base font-medium",
26
- "body-md-600": "text-base font-semibold",
27
- "body-md-700": "text-base font-bold",
28
- "body-sm": "text-sm font-normal",
29
- "body-sm-500": "text-sm font-medium",
30
- "body-sm-600": "text-sm font-semibold",
31
- "body-sm-700": "text-sm font-bold",
32
- "body-xs": "text-xs font-normal",
33
- "body-xs-500": "text-xs font-medium",
34
- "body-xs-600": "text-xs font-semibold",
35
- "body-xs-700": "text-xs font-bold",
36
- };
37
- var bodyVariants = cva("!leading-normal m-0", {
38
- variants: {
39
- variant: variant,
40
- },
41
- defaultVariants: {
42
- variant: "body-md",
43
- },
44
- });
45
- function Body(_a) {
46
- var as = _a.as, className = _a.className, variant = _a.variant, children = _a.children, props = __rest(_a, ["as", "className", "variant", "children"]);
47
- var Tag = as || "p";
48
- return (<Tag className={cn(bodyVariants({ variant: variant }), className)} {...props}>
49
- {children}
50
- </Tag>);
51
- }
52
- export { Body, bodyVariants };
@@ -1,24 +0,0 @@
1
- import { Dummy_Para } from "../../../utils/constants";
2
- import { Caption, variantClasses } from "../../../components/ui/caption";
3
- export default {
4
- title: "Components/Typography/Caption",
5
- component: Caption,
6
- tags: ["autodocs"],
7
- };
8
- var Template = function (args) { return <Caption {...args}></Caption>; };
9
- export var _Caption = Template.bind({});
10
- _Caption.args = {
11
- children: Dummy_Para,
12
- variant: "md",
13
- };
14
- _Caption.argTypes = {
15
- variant: {
16
- control: { type: "select" },
17
- options: Object.keys(variantClasses),
18
- description: "Caption Variant",
19
- table: {
20
- defaultValue: { summary: "md" },
21
- type: { summary: "string" },
22
- },
23
- },
24
- };
@@ -1,24 +0,0 @@
1
- import { Dummy_Para } from "../../../utils/constants";
2
- import { Display, variant } from "../../../components/Typography/Display/display";
3
- export default {
4
- title: "Components/Typography/Display",
5
- component: Display,
6
- tags: ["autodocs"],
7
- };
8
- var Template = function (args) { return <Display {...args}></Display>; };
9
- export var _Display = Template.bind({});
10
- _Display.args = {
11
- children: Dummy_Para,
12
- variant: "display-md",
13
- };
14
- _Display.argTypes = {
15
- variant: {
16
- control: { type: "select" },
17
- options: Object.keys(variant),
18
- description: "Display Variant",
19
- table: {
20
- defaultValue: { summary: "display-md" },
21
- type: { summary: "string" },
22
- },
23
- },
24
- };
@@ -1,39 +0,0 @@
1
- var __rest = (this && this.__rest) || function (s, e) {
2
- var t = {};
3
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
4
- t[p] = s[p];
5
- if (s != null && typeof Object.getOwnPropertySymbols === "function")
6
- for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
7
- if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
8
- t[p[i]] = s[p[i]];
9
- }
10
- return t;
11
- };
12
- import * as React from "react";
13
- import { cva } from "class-variance-authority";
14
- import { cn } from "../../../lib/utils";
15
- export var variant = {
16
- "display-lg": "text-7xl font-bold",
17
- "display-md": "text-6xl font-bold",
18
- "display-sm": "text-5xl font-bold",
19
- };
20
- var displayVariants = cva("!leading-normal", // Default base class
21
- {
22
- variants: {
23
- variant: variant,
24
- },
25
- defaultVariants: {
26
- variant: "display-md",
27
- },
28
- });
29
- function Display(_a) {
30
- var className = _a.className, variant = _a.variant, children = _a.children, props = __rest(_a, ["className", "variant", "children"]);
31
- var Tag = "div";
32
- if (variant === null || variant === void 0 ? void 0 : variant.startsWith("display")) {
33
- Tag = "div";
34
- }
35
- return (<Tag className={cn(displayVariants({ variant: variant, className: className }))} {...props}>
36
- {children}
37
- </Tag>);
38
- }
39
- export { Display, displayVariants };
@@ -1,24 +0,0 @@
1
- import { Dummy_Para } from "../../../utils/constants";
2
- import { Heading, variant } from "./heading";
3
- export default {
4
- title: "Components/Typography/Heading",
5
- component: Heading,
6
- tags: ["autodocs"],
7
- };
8
- var Template = function (args) { return <Heading {...args}></Heading>; };
9
- export var _Heading = Template.bind({});
10
- _Heading.args = {
11
- children: Dummy_Para,
12
- variant: "h2",
13
- };
14
- _Heading.argTypes = {
15
- variant: {
16
- control: { type: "select" },
17
- options: Object.keys(variant),
18
- description: "Heading Variant",
19
- table: {
20
- defaultValue: { summary: "h2" },
21
- type: { summary: "string" },
22
- },
23
- },
24
- };
@@ -1,60 +0,0 @@
1
- var __rest = (this && this.__rest) || function (s, e) {
2
- var t = {};
3
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
4
- t[p] = s[p];
5
- if (s != null && typeof Object.getOwnPropertySymbols === "function")
6
- for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
7
- if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
8
- t[p[i]] = s[p[i]];
9
- }
10
- return t;
11
- };
12
- import * as React from "react";
13
- import { cva } from "class-variance-authority";
14
- import { cn } from "../../../lib/utils";
15
- export var variant = {
16
- h1: "text-5xl font-normal",
17
- "h1-500": "!text-5xl !font-medium",
18
- "h1-600": "!text-5xl !font-semibold",
19
- "h1-700": "!text-5xl !font-bold",
20
- h2: "text-4xl font-normal",
21
- "h2-500": "!text-4xl !font-medium",
22
- "h2-600": "!text-4xl !font-semibold",
23
- "h2-700": "!text-4xl !font-bold",
24
- h3: "text-3xl font-normal",
25
- "h3-500": "!text-3xl !font-medium",
26
- "h3-600": "!text-3xl !font-semibold",
27
- "h3-700": "!text-3xl !font-bold",
28
- h4: "text-2xl font-normal",
29
- "h4-500": "!text-2xl !font-medium",
30
- "h4-600": "!text-2xl !font-semibold",
31
- "h4-700": "!text-2xl !font-bold",
32
- h5: "text-xl font-normal",
33
- "h5-500": "!text-xl !font-medium",
34
- "h5-600": "!text-xl !font-semibold",
35
- "h5-700": "!text-xl !font-bold",
36
- h6: "!text-lg !font-normal",
37
- "h6-500": "!text-lg !font-medium",
38
- "h6-600": "!text-lg !font-semibold",
39
- "h6-700": "!text-lg !font-bold",
40
- };
41
- var headingVariants = cva("!leading-normal", // Default base class
42
- {
43
- variants: {
44
- variant: variant,
45
- },
46
- defaultVariants: {
47
- variant: "h2",
48
- },
49
- });
50
- function Heading(_a) {
51
- var className = _a.className, variant = _a.variant, children = _a.children, props = __rest(_a, ["className", "variant", "children"]);
52
- var Tag = "span";
53
- if (variant === null || variant === void 0 ? void 0 : variant.startsWith("h")) {
54
- Tag = variant.split("-")[0];
55
- }
56
- return (<Tag className={cn(headingVariants({ variant: variant, className: className }))} {...props}>
57
- {children}
58
- </Tag>);
59
- }
60
- export { Heading, headingVariants };
@@ -1,39 +0,0 @@
1
- var __rest = (this && this.__rest) || function (s, e) {
2
- var t = {};
3
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
4
- t[p] = s[p];
5
- if (s != null && typeof Object.getOwnPropertySymbols === "function")
6
- for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
7
- if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
8
- t[p[i]] = s[p[i]];
9
- }
10
- return t;
11
- };
12
- import * as React from "react";
13
- import * as AccordionPrimitive from "@radix-ui/react-accordion";
14
- import { cn } from "../../lib/utils";
15
- import LUIcon from "../Icons/LUIcon";
16
- function Accordion(_a) {
17
- var props = __rest(_a, []);
18
- return <AccordionPrimitive.Root data-slot="accordion" {...props}/>;
19
- }
20
- function AccordionItem(_a) {
21
- var className = _a.className, props = __rest(_a, ["className"]);
22
- return (<AccordionPrimitive.Item data-slot="accordion-item" className={cn("!border-b last:!border-b-0", className)} {...props}/>);
23
- }
24
- function AccordionTrigger(_a) {
25
- var className = _a.className, children = _a.children, props = __rest(_a, ["className", "children"]);
26
- return (<AccordionPrimitive.Header className="flex">
27
- <AccordionPrimitive.Trigger data-slot="accordion-trigger" className={cn("focus-visible:border-ring focus-visible:ring-ring/50 !flex !flex-1 !items-start !justify-between gap-4 !rounded-md !py-2 !text-left !text-sm !font-normal transition-all outline-none focus-visible:ring-[3px] disabled:pointer-events-none disabled:opacity-50 [&[data-state=open]>div]:rotate-180", className)} {...props}>
28
- {children}
29
- <LUIcon icon={"angle-down"} size="sm" variant="padded" color="light-blue" className="bg-blue-100 text-blue-600 pointer-events-none shrink-0 translate-y-0.5 transition-transform duration-200"/>
30
- </AccordionPrimitive.Trigger>
31
- </AccordionPrimitive.Header>);
32
- }
33
- function AccordionContent(_a) {
34
- var className = _a.className, children = _a.children, props = __rest(_a, ["className", "children"]);
35
- return (<AccordionPrimitive.Content data-slot="accordion-content" className="data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down overflow-hidden text-sm" {...props}>
36
- <div className={cn("!pt-0 !pb-4", className)}>{children}</div>
37
- </AccordionPrimitive.Content>);
38
- }
39
- export { Accordion, AccordionItem, AccordionTrigger, AccordionContent };
File without changes
@@ -1 +0,0 @@
1
- "use strict";
@@ -1,25 +0,0 @@
1
- var __rest = (this && this.__rest) || function (s, e) {
2
- var t = {};
3
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
4
- t[p] = s[p];
5
- if (s != null && typeof Object.getOwnPropertySymbols === "function")
6
- for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
7
- if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
8
- t[p[i]] = s[p[i]];
9
- }
10
- return t;
11
- };
12
- import * as React from "react";
13
- import { cn } from "../../lib/utils";
14
- export var variantClasses = {
15
- sm: "text-xs",
16
- md: "text-sm",
17
- lg: "text-base",
18
- };
19
- function Caption(_a) {
20
- var className = _a.className, children = _a.children, _b = _a.variant, variant = _b === void 0 ? "md" : _b, props = __rest(_a, ["className", "children", "variant"]);
21
- return (<p className={cn("font-normal leading-normal inline", variantClasses[variant], className)} {...props}>
22
- {children}
23
- </p>);
24
- }
25
- export { Caption };
@@ -1,24 +0,0 @@
1
- var __rest = (this && this.__rest) || function (s, e) {
2
- var t = {};
3
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
4
- t[p] = s[p];
5
- if (s != null && typeof Object.getOwnPropertySymbols === "function")
6
- for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
7
- if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
8
- t[p[i]] = s[p[i]];
9
- }
10
- return t;
11
- };
12
- import * as React from "react";
13
- import * as CheckboxPrimitive from "@radix-ui/react-checkbox";
14
- import { CheckIcon } from "lucide-react";
15
- import { cn } from "../../lib/utils";
16
- function Checkbox(_a) {
17
- var className = _a.className, props = __rest(_a, ["className"]);
18
- return (<CheckboxPrimitive.Root data-slot="checkbox" className={cn("peer border-input dark:bg-input/30 data-[state=checked]:bg-blue-600 data-[state=checked]:text-primary-foreground dark:data-[state=checked]:bg-primary data-[state=checked]:border-blue-600 focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive size-4.5 shrink-0 !rounded-[4px] border shadow-xs transition-shadow outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50", className)} {...props}>
19
- <CheckboxPrimitive.Indicator data-slot="checkbox-indicator" className="flex items-center justify-center text-current transition-none">
20
- <CheckIcon className="size-3.5"/>
21
- </CheckboxPrimitive.Indicator>
22
- </CheckboxPrimitive.Root>);
23
- }
24
- export { Checkbox };