@xjur-ui/react 1.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.
Files changed (70) hide show
  1. package/.turbo/turbo-build.log +57 -0
  2. package/dist/components/resources/icons.d.ts +4 -0
  3. package/dist/components/resources/icons.js +133 -0
  4. package/dist/components/resources/logo/horizontal.d.ts +12 -0
  5. package/dist/components/resources/logo/horizontal.js +107 -0
  6. package/dist/components/resources/logo/icon.d.ts +12 -0
  7. package/dist/components/resources/logo/icon.js +79 -0
  8. package/dist/components/resources/logo/index.d.ts +4 -0
  9. package/dist/components/resources/logo/index.js +291 -0
  10. package/dist/components/resources/logo/vertical.d.ts +12 -0
  11. package/dist/components/resources/logo/vertical.js +107 -0
  12. package/dist/components/ui/accordion.d.ts +5 -0
  13. package/dist/components/ui/accordion.js +8 -0
  14. package/dist/components/ui/button.d.ts +16 -0
  15. package/dist/components/ui/button.js +95 -0
  16. package/dist/components/ui/icon.d.ts +12 -0
  17. package/dist/components/ui/icon.js +158 -0
  18. package/dist/components/ui/index.d.ts +17 -0
  19. package/dist/components/ui/index.js +788 -0
  20. package/dist/components/ui/input/content.d.ts +9 -0
  21. package/dist/components/ui/input/content.js +183 -0
  22. package/dist/components/ui/input/index.d.ts +12 -0
  23. package/dist/components/ui/input/index.js +335 -0
  24. package/dist/components/ui/input/label.d.ts +12 -0
  25. package/dist/components/ui/input/label.js +165 -0
  26. package/dist/components/ui/input/message.d.ts +10 -0
  27. package/dist/components/ui/input/message.js +128 -0
  28. package/dist/components/ui/input/root.d.ts +18 -0
  29. package/dist/components/ui/input/root.js +163 -0
  30. package/dist/components/ui/input/slot.d.ts +10 -0
  31. package/dist/components/ui/input/slot.js +20 -0
  32. package/dist/components/ui/input/text.d.ts +10 -0
  33. package/dist/components/ui/input/text.js +195 -0
  34. package/dist/components/ui/logo.d.ts +10 -0
  35. package/dist/components/ui/logo.js +324 -0
  36. package/dist/components/ui/otp-input.d.ts +13 -0
  37. package/dist/components/ui/otp-input.js +47 -0
  38. package/dist/components/ui/typography.d.ts +17 -0
  39. package/dist/components/ui/typography.js +78 -0
  40. package/dist/index.css +770 -0
  41. package/dist/index.d.ts +17 -0
  42. package/dist/index.js +788 -0
  43. package/eslint.config.js +3 -0
  44. package/package.json +41 -0
  45. package/postcss.config.js +5 -0
  46. package/prettier.config.js +7 -0
  47. package/src/components/resources/icons.ts +131 -0
  48. package/src/components/resources/logo/horizontal.tsx +70 -0
  49. package/src/components/resources/logo/icon.tsx +54 -0
  50. package/src/components/resources/logo/index.ts +3 -0
  51. package/src/components/resources/logo/vertical.tsx +70 -0
  52. package/src/components/ui/accordion.tsx +3 -0
  53. package/src/components/ui/button.tsx +105 -0
  54. package/src/components/ui/icon.tsx +29 -0
  55. package/src/components/ui/index.ts +13 -0
  56. package/src/components/ui/input/content.tsx +59 -0
  57. package/src/components/ui/input/index.ts +6 -0
  58. package/src/components/ui/input/label.tsx +41 -0
  59. package/src/components/ui/input/message.tsx +37 -0
  60. package/src/components/ui/input/root.tsx +57 -0
  61. package/src/components/ui/input/slot.tsx +21 -0
  62. package/src/components/ui/input/text.tsx +69 -0
  63. package/src/components/ui/logo.tsx +39 -0
  64. package/src/components/ui/otp-input.tsx +45 -0
  65. package/src/components/ui/typography.tsx +85 -0
  66. package/src/index.css +2 -0
  67. package/src/index.ts +2 -0
  68. package/src/types.d.ts +4 -0
  69. package/tsconfig.json +4 -0
  70. package/tsup.config.ts +12 -0
@@ -0,0 +1,78 @@
1
+ // src/components/ui/typography.tsx
2
+ import { Slot } from "@radix-ui/react-slot";
3
+ import { cva } from "@xjur-ui/util";
4
+ import { memo } from "react";
5
+ import { jsx } from "react/jsx-runtime";
6
+ var typographyVariants = cva("", {
7
+ variants: {
8
+ variant: {
9
+ body: "",
10
+ label: "",
11
+ title: "",
12
+ headline: ""
13
+ },
14
+ size: {
15
+ "sm-2x": "",
16
+ "sm-1x": "",
17
+ sm: "",
18
+ md: "",
19
+ lg: ""
20
+ },
21
+ weight: {
22
+ thin: "font-thin",
23
+ extraLight: "font-extralight",
24
+ light: "font-light",
25
+ normal: "font-normal",
26
+ medium: "font-medium",
27
+ semibold: "font-semibold",
28
+ bold: "font-bold",
29
+ extraBold: "font-extrabold",
30
+ black: "font-black"
31
+ }
32
+ },
33
+ compoundVariants: [
34
+ { variant: "body", size: "sm-1x", class: "text-size-body-sm-1x" },
35
+ { variant: "body", size: "sm", class: "text-size-body-sm" },
36
+ { variant: "body", size: "md", class: "text-size-body-md" },
37
+ { variant: "body", size: "lg", class: "text-size-body-lg" },
38
+ { variant: "label", size: "sm-2x", class: "text-size-label-sm-2x" },
39
+ { variant: "label", size: "sm-1x", class: "text-size-label-sm-1x" },
40
+ { variant: "label", size: "sm", class: "text-size-label-sm" },
41
+ { variant: "label", size: "md", class: "text-size-label-md" },
42
+ { variant: "label", size: "lg", class: "text-size-label-lg" },
43
+ { variant: "title", size: "sm", class: "text-size-title-sm" },
44
+ { variant: "title", size: "md", class: "text-size-title-md" },
45
+ { variant: "title", size: "lg", class: "text-size-title-lg" },
46
+ { variant: "headline", size: "sm", class: "text-size-headline-sm" },
47
+ { variant: "headline", size: "md", class: "text-size-headline-md" },
48
+ { variant: "headline", size: "lg", class: "text-size-headline-lg" }
49
+ ],
50
+ defaultVariants: {
51
+ variant: "body",
52
+ size: "md",
53
+ weight: "normal"
54
+ }
55
+ });
56
+ var Typography = memo(
57
+ ({
58
+ variant,
59
+ size,
60
+ weight,
61
+ asChild,
62
+ className,
63
+ ...props
64
+ }) => {
65
+ const Component = asChild ? Slot : "span";
66
+ return /* @__PURE__ */ jsx(
67
+ Component,
68
+ {
69
+ className: typographyVariants({ variant, size, weight, className }),
70
+ ...props
71
+ }
72
+ );
73
+ }
74
+ );
75
+ Typography.displayName = "Typography";
76
+ export {
77
+ Typography
78
+ };