@taiv/ui 1.2.0 → 1.3.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 (118) hide show
  1. package/dist/components/Data/Cards/ChartCard.d.ts +9 -0
  2. package/dist/components/Data/Cards/ChartCard.d.ts.map +1 -0
  3. package/dist/components/Data/Cards/ChartCard.js +9 -0
  4. package/dist/components/Data/Cards/PieChartCard.d.ts +10 -0
  5. package/dist/components/Data/Cards/PieChartCard.d.ts.map +1 -0
  6. package/dist/components/Data/Cards/PieChartCard.js +9 -0
  7. package/dist/components/Data/Cards/StatsCard.d.ts +17 -0
  8. package/dist/components/Data/Cards/StatsCard.d.ts.map +1 -0
  9. package/dist/components/Data/Cards/StatsCard.js +38 -0
  10. package/dist/components/Data/Chart.d.ts +5 -24
  11. package/dist/components/Data/Chart.d.ts.map +1 -1
  12. package/dist/components/Data/Chart.js +63 -80
  13. package/dist/components/Data/JustChart.d.ts +23 -0
  14. package/dist/components/Data/JustChart.d.ts.map +1 -0
  15. package/dist/components/Data/JustChart.js +70 -0
  16. package/dist/components/Data/JustPieChart.d.ts +20 -0
  17. package/dist/components/Data/JustPieChart.d.ts.map +1 -0
  18. package/dist/components/Data/JustPieChart.js +63 -0
  19. package/dist/components/Data/PieChart.d.ts +9 -12
  20. package/dist/components/Data/PieChart.d.ts.map +1 -1
  21. package/dist/components/Data/PieChart.js +35 -43
  22. package/dist/components/Data/StatsBadge.d.ts +10 -0
  23. package/dist/components/Data/StatsBadge.d.ts.map +1 -0
  24. package/dist/components/Data/StatsBadge.js +25 -0
  25. package/dist/components/Data/StatsCard.d.ts +2 -2
  26. package/dist/components/Data/StatsCard.d.ts.map +1 -1
  27. package/dist/components/Data/StatsCard.js +2 -2
  28. package/dist/components/Data/shared/chartFormats.d.ts +8 -0
  29. package/dist/components/Data/shared/chartFormats.d.ts.map +1 -0
  30. package/dist/components/Data/shared/chartFormats.js +29 -0
  31. package/dist/components/Data/shared/dataFormats.d.ts +7 -33
  32. package/dist/components/Data/shared/dataFormats.d.ts.map +1 -1
  33. package/dist/components/Data/shared/dataFormats.js +15 -20
  34. package/dist/components/Info/Badge.d.ts +10 -0
  35. package/dist/components/Info/Badge.d.ts.map +1 -1
  36. package/dist/components/Info/Badge.js +64 -1
  37. package/dist/components/Info/Tooltips/FormulaTooltip.d.ts +8 -0
  38. package/dist/components/Info/Tooltips/FormulaTooltip.d.ts.map +1 -0
  39. package/dist/components/Info/Tooltips/FormulaTooltip.js +11 -0
  40. package/dist/components/Info/Tooltips/InfoTooltip.d.ts +2 -1
  41. package/dist/components/Info/Tooltips/InfoTooltip.d.ts.map +1 -1
  42. package/dist/components/Info/Tooltips/InfoTooltip.js +2 -2
  43. package/dist/components/Info/Tooltips/Tooltip.d.ts +2 -1
  44. package/dist/components/Info/Tooltips/Tooltip.d.ts.map +1 -1
  45. package/dist/components/Info/Tooltips/Tooltip.js +2 -2
  46. package/dist/components/Inputs/Controls/Radio.d.ts +8 -0
  47. package/dist/components/Inputs/Controls/Radio.d.ts.map +1 -0
  48. package/dist/components/Inputs/Controls/Radio.js +43 -0
  49. package/dist/components/Inputs/Controls/RadioList.d.ts +16 -0
  50. package/dist/components/Inputs/Controls/RadioList.d.ts.map +1 -0
  51. package/dist/components/Inputs/Controls/RadioList.js +24 -0
  52. package/dist/components/Inputs/DatePickers/DatePicker.d.ts.map +1 -1
  53. package/dist/components/Inputs/DatePickers/DatePicker.js +39 -3
  54. package/dist/components/Inputs/Dates/DatePicker.d.ts +12 -0
  55. package/dist/components/Inputs/Dates/DatePicker.d.ts.map +1 -0
  56. package/dist/components/Inputs/Dates/DatePicker.js +71 -0
  57. package/dist/components/Inputs/Dropdowns/CascadingSelect.d.ts +17 -0
  58. package/dist/components/Inputs/Dropdowns/CascadingSelect.d.ts.map +1 -0
  59. package/dist/components/Inputs/Dropdowns/CascadingSelect.js +70 -0
  60. package/dist/components/Inputs/Dropdowns/FontSelect.d.ts +2 -5
  61. package/dist/components/Inputs/Dropdowns/FontSelect.d.ts.map +1 -1
  62. package/dist/components/Inputs/Dropdowns/FontSelect.js +1 -1
  63. package/dist/components/Inputs/Dropdowns/NestedSelect.d.ts +17 -0
  64. package/dist/components/Inputs/Dropdowns/NestedSelect.d.ts.map +1 -0
  65. package/dist/components/Inputs/Dropdowns/NestedSelect.js +70 -0
  66. package/dist/components/Inputs/Dropdowns/Select.d.ts.map +1 -1
  67. package/dist/components/Inputs/Dropdowns/Select.js +2 -2
  68. package/dist/components/Inputs/Dropdowns/shared/fontSelectList.d.ts +1 -4
  69. package/dist/components/Inputs/Dropdowns/shared/fontSelectList.d.ts.map +1 -1
  70. package/dist/components/Inputs/Dropdowns/shared/fontSelectList.js +1 -4
  71. package/dist/components/Layout/Divider.d.ts +2 -1
  72. package/dist/components/Layout/Divider.d.ts.map +1 -1
  73. package/dist/components/Layout/Divider.js +2 -2
  74. package/dist/components/Layout/SectionCard.d.ts.map +1 -1
  75. package/dist/components/Layout/SectionCard.js +3 -2
  76. package/dist/components/Misc/IconBadge.d.ts +2 -2
  77. package/dist/components/Misc/IconBadge.d.ts.map +1 -1
  78. package/dist/components/Misc/IconBadge.js +3 -4
  79. package/dist/components/Typography/Formula.d.ts +10 -0
  80. package/dist/components/Typography/Formula.d.ts.map +1 -0
  81. package/dist/components/Typography/Formula.js +141 -0
  82. package/dist/components/Typography/Fraction.d.ts +3 -4
  83. package/dist/components/Typography/Fraction.d.ts.map +1 -1
  84. package/dist/components/Typography/Fraction.js +6 -3
  85. package/dist/components/Typography/Text.d.ts +1 -1
  86. package/dist/components/Typography/Text.d.ts.map +1 -1
  87. package/dist/components/Typography/Text.js +7 -0
  88. package/dist/components/index.d.ts +11 -2
  89. package/dist/components/index.d.ts.map +1 -1
  90. package/dist/components/index.js +11 -2
  91. package/dist/constants/colors.d.ts +1 -1
  92. package/dist/constants/colors.d.ts.map +1 -1
  93. package/dist/constants/colors.js +3 -3
  94. package/dist/constants/data.d.ts +70 -0
  95. package/dist/constants/data.d.ts.map +1 -0
  96. package/dist/constants/data.js +15 -0
  97. package/dist/hooks/useDropdowns.d.ts +9 -0
  98. package/dist/hooks/useDropdowns.d.ts.map +1 -0
  99. package/dist/hooks/useDropdowns.js +12 -0
  100. package/dist/index.d.ts +2 -0
  101. package/dist/index.d.ts.map +1 -1
  102. package/dist/index.js +2 -0
  103. package/dist/types/index.d.ts +2 -0
  104. package/dist/types/index.d.ts.map +1 -0
  105. package/dist/types/index.js +1 -0
  106. package/dist/types/types.d.ts +20 -0
  107. package/dist/types/types.d.ts.map +1 -0
  108. package/dist/types/types.js +2 -0
  109. package/dist/utils/charts.d.ts +13 -0
  110. package/dist/utils/charts.d.ts.map +1 -0
  111. package/dist/utils/charts.js +48 -0
  112. package/dist/utils/index.d.ts +3 -0
  113. package/dist/utils/index.d.ts.map +1 -0
  114. package/dist/utils/index.js +2 -0
  115. package/dist/utils/select.d.ts +5 -0
  116. package/dist/utils/select.d.ts.map +1 -0
  117. package/dist/utils/select.js +12 -0
  118. package/package.json +4 -2
@@ -0,0 +1,24 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { Stack } from '../../Layout/Stack';
3
+ import { Radio } from './Radio';
4
+ import { neutral } from '../../../constants/colors';
5
+ import { Group } from '../../Layout/Group';
6
+ const RadioList = ({ data, value, onChange, disabled = false, width }) => {
7
+ const handleChange = (optionValue) => {
8
+ if (onChange) {
9
+ onChange(optionValue);
10
+ }
11
+ };
12
+ return (_jsx(Stack, { gap: "0", style: {
13
+ border: `1px solid ${neutral[100]}`,
14
+ borderRadius: '16px',
15
+ overflow: 'hidden',
16
+ padding: '0.2rem 0 0.2rem 0',
17
+ width,
18
+ }, children: data.map((option, index) => (_jsxs(Group, { position: "apart", style: {
19
+ padding: '1rem 1.2rem 0.8rem 1.2rem',
20
+ borderBottom: index < data.length - 1 ? `1px solid ${neutral[100]}` : 'none',
21
+ backgroundColor: 'white',
22
+ }, children: [_jsx(Radio, { value: option.value, label: option.label, checked: value === option.value, onChange: () => handleChange(option.value), disabled: disabled }), option.rightContent && option.rightContent] }, option.value))) }));
23
+ };
24
+ export { RadioList };
@@ -1 +1 @@
1
- {"version":3,"file":"DatePicker.d.ts","sourceRoot":"","sources":["../../../../src/components/Inputs/DatePickers/DatePicker.tsx"],"names":[],"mappings":"AACA,OAAO,EAA6C,oBAAoB,IAAI,2BAA2B,EAAE,MAAM,gBAAgB,CAAC;AAChI,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAG5C,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAE3D,MAAM,WAAW,eAAe,CAAC,CAAC,SAAS,SAAS,GAAG,UAAU,GAAG,OAAO,GAAG,SAAS,CAAE,SAAQ,IAAI,CAAC,2BAA2B,CAAC,CAAC,CAAC,EAAE,QAAQ,CAAC;IAC7I,IAAI,CAAC,EAAE,MAAM,OAAO,cAAc,CAAC;IACnC,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;IACnC,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED,eAAO,MAAM,UAAU,GAAI,CAAC,SAAS,SAAS,GAAG,UAAU,GAAG,OAAO,GAAG,SAAS,EAAE,qEAQhF,eAAe,CAAC,CAAC,CAAC,4CAyCpB,CAAC"}
1
+ {"version":3,"file":"DatePicker.d.ts","sourceRoot":"","sources":["../../../../src/components/Inputs/DatePickers/DatePicker.tsx"],"names":[],"mappings":"AACA,OAAO,EAA6C,oBAAoB,IAAI,2BAA2B,EAAE,MAAM,gBAAgB,CAAC;AAEhI,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAG5C,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAE3D,MAAM,WAAW,eAAe,CAAC,CAAC,SAAS,SAAS,GAAG,UAAU,GAAG,OAAO,GAAG,SAAS,CAAE,SAAQ,IAAI,CAAC,2BAA2B,CAAC,CAAC,CAAC,EAAE,QAAQ,CAAC;IAC7I,IAAI,CAAC,EAAE,MAAM,OAAO,cAAc,CAAC;IACnC,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;IACnC,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED,eAAO,MAAM,UAAU,GAAI,CAAC,SAAS,SAAS,GAAG,UAAU,GAAG,OAAO,GAAG,SAAS,EAAE,qEAQhF,eAAe,CAAC,CAAC,CAAC,4CA4EpB,CAAC"}
@@ -1,11 +1,12 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { DatePickerInput as MantineDatePickerInput } from '@mantine/dates';
3
+ import { createStyles } from '@mantine/core';
3
4
  import { neutral } from '../../../constants/colors';
4
5
  import { fontBase } from '../../../constants/font';
5
6
  import { componentSizes } from '../Dropdowns/shared/sizes';
6
7
  export const DatePicker = ({ size = 'md', width, fullWidth = false, placeholder = 'Pick Date', styles, showIcon = true, ...props }) => {
7
8
  const selectedSize = componentSizes[size];
8
- const style = {
9
+ const { classes } = createStyles(() => ({
9
10
  root: {
10
11
  width: fullWidth ? '100%' : width || `${selectedSize.minWidth}rem`,
11
12
  },
@@ -29,7 +30,42 @@ export const DatePicker = ({ size = 'md', width, fullWidth = false, placeholder
29
30
  fontSize: `calc(${selectedSize.fontSize} - 0.1rem)`,
30
31
  color: neutral[200],
31
32
  },
33
+ calendar: {
34
+ '& .mantine-UnstyledButton-root': {
35
+ borderRadius: '8px',
36
+ fontFamily: 'Poppins, sans-serif',
37
+ },
38
+ '& .mantine-Day-day': {
39
+ borderRadius: '50%',
40
+ },
41
+ '& .mantine-Day-day[data-selected="true"]': {
42
+ fontFamily: 'Poppins, sans-serif',
43
+ borderRadius: '50%',
44
+ },
45
+ '& .mantine-Day-day[data-in-range="true"]': {
46
+ fontFamily: 'Poppins, sans-serif',
47
+ borderRadius: '50%',
48
+ },
49
+ '& .mantine-Day-day[data-first-in-range="true"]': {
50
+ fontFamily: 'Poppins, sans-serif',
51
+ borderRadius: '50%',
52
+ },
53
+ '& .mantine-Day-day[data-last-in-range="true"]': {
54
+ fontFamily: 'Poppins, sans-serif',
55
+ borderRadius: '50%',
56
+ },
57
+ '& .mantine-WeekdaysRow-weekday': {
58
+ textAlign: 'center',
59
+ fontFamily: 'Poppins, sans-serif',
60
+ },
61
+ },
32
62
  ...styles,
33
- };
34
- return (_jsx(MantineDatePickerInput, { icon: showIcon ? _jsx("i", { className: "far fa-calendar", style: { fontSize: 14, marginLeft: '0.25rem' } }) : undefined, radius: "lg", size: "xl", styles: style, placeholder: placeholder, popoverProps: { radius: 'lg' }, ...props }));
63
+ }))();
64
+ return (_jsx(MantineDatePickerInput, { icon: showIcon ? _jsx("i", { className: "far fa-calendar", style: { fontSize: 14, marginLeft: '0.25rem' } }) : undefined, radius: "lg", size: "xl", classNames: {
65
+ root: classes.root,
66
+ input: classes.input,
67
+ placeholder: classes.placeholder,
68
+ label: classes.label,
69
+ calendar: classes.calendar,
70
+ }, placeholder: placeholder, popoverProps: { radius: 'lg' }, ...props }));
35
71
  };
@@ -0,0 +1,12 @@
1
+ import { DatePickerInputProps as MantineDatePickerInputProps } from '@mantine/dates';
2
+ import { CSSObject } from '@mantine/styles';
3
+ import { componentSizes } from '../Dropdowns/shared/sizes';
4
+ export interface DatePickerProps<T extends 'default' | 'multiple' | 'range' = 'default'> extends Omit<MantineDatePickerInputProps<T>, 'styles'> {
5
+ size?: keyof typeof componentSizes;
6
+ width?: string | number;
7
+ fullWidth?: boolean;
8
+ styles?: Record<string, CSSObject>;
9
+ showIcon?: boolean;
10
+ }
11
+ export declare const DatePicker: <T extends "default" | "multiple" | "range" = "default">({ size, width, fullWidth, placeholder, styles, showIcon, ...props }: DatePickerProps<T>) => import("react/jsx-runtime").JSX.Element;
12
+ //# sourceMappingURL=DatePicker.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DatePicker.d.ts","sourceRoot":"","sources":["../../../../src/components/Inputs/Dates/DatePicker.tsx"],"names":[],"mappings":"AACA,OAAO,EAA6C,oBAAoB,IAAI,2BAA2B,EAAE,MAAM,gBAAgB,CAAC;AAEhI,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAG5C,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAE3D,MAAM,WAAW,eAAe,CAAC,CAAC,SAAS,SAAS,GAAG,UAAU,GAAG,OAAO,GAAG,SAAS,CAAE,SAAQ,IAAI,CAAC,2BAA2B,CAAC,CAAC,CAAC,EAAE,QAAQ,CAAC;IAC7I,IAAI,CAAC,EAAE,MAAM,OAAO,cAAc,CAAC;IACnC,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;IACnC,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED,eAAO,MAAM,UAAU,GAAI,CAAC,SAAS,SAAS,GAAG,UAAU,GAAG,OAAO,GAAG,SAAS,EAAE,qEAQhF,eAAe,CAAC,CAAC,CAAC,4CA4EpB,CAAC"}
@@ -0,0 +1,71 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { DatePickerInput as MantineDatePickerInput } from '@mantine/dates';
3
+ import { createStyles } from '@mantine/core';
4
+ import { neutral } from '../../../constants/colors';
5
+ import { fontBase } from '../../../constants/font';
6
+ import { componentSizes } from '../Dropdowns/shared/sizes';
7
+ export const DatePicker = ({ size = 'md', width, fullWidth = false, placeholder = 'Pick Date', styles, showIcon = true, ...props }) => {
8
+ const selectedSize = componentSizes[size];
9
+ const { classes } = createStyles(() => ({
10
+ root: {
11
+ width: fullWidth ? '100%' : width || `${selectedSize.minWidth}rem`,
12
+ },
13
+ input: {
14
+ height: `${selectedSize.height}rem`,
15
+ paddingRight: selectedSize.inputPadding,
16
+ ...fontBase,
17
+ fontSize: selectedSize.fontSize,
18
+ color: neutral[300],
19
+ borderRadius: '8px',
20
+ border: `1px solid ${neutral[100]}`,
21
+ transition: 'all 200ms ease-in-out',
22
+ },
23
+ placeholder: {
24
+ ...fontBase,
25
+ fontSize: selectedSize.fontSize,
26
+ color: neutral[200],
27
+ },
28
+ label: {
29
+ ...fontBase,
30
+ fontSize: `calc(${selectedSize.fontSize} - 0.1rem)`,
31
+ color: neutral[200],
32
+ },
33
+ calendar: {
34
+ '& .mantine-UnstyledButton-root': {
35
+ borderRadius: '8px',
36
+ fontFamily: 'Poppins, sans-serif',
37
+ },
38
+ '& .mantine-Day-day': {
39
+ borderRadius: '50%',
40
+ },
41
+ '& .mantine-Day-day[data-selected="true"]': {
42
+ fontFamily: 'Poppins, sans-serif',
43
+ borderRadius: '50%',
44
+ },
45
+ '& .mantine-Day-day[data-in-range="true"]': {
46
+ fontFamily: 'Poppins, sans-serif',
47
+ borderRadius: '50%',
48
+ },
49
+ '& .mantine-Day-day[data-first-in-range="true"]': {
50
+ fontFamily: 'Poppins, sans-serif',
51
+ borderRadius: '50%',
52
+ },
53
+ '& .mantine-Day-day[data-last-in-range="true"]': {
54
+ fontFamily: 'Poppins, sans-serif',
55
+ borderRadius: '50%',
56
+ },
57
+ '& .mantine-WeekdaysRow-weekday': {
58
+ textAlign: 'center',
59
+ fontFamily: 'Poppins, sans-serif',
60
+ },
61
+ },
62
+ ...styles,
63
+ }))();
64
+ return (_jsx(MantineDatePickerInput, { icon: showIcon ? _jsx("i", { className: "far fa-calendar", style: { fontSize: 14, marginLeft: '0.25rem' } }) : undefined, radius: "lg", size: "xl", classNames: {
65
+ root: classes.root,
66
+ input: classes.input,
67
+ placeholder: classes.placeholder,
68
+ label: classes.label,
69
+ calendar: classes.calendar,
70
+ }, placeholder: placeholder, popoverProps: { radius: 'lg' }, ...props }));
71
+ };
@@ -0,0 +1,17 @@
1
+ import React from 'react';
2
+ import { SelectProps } from './Select';
3
+ import { SelectOption } from '../../../utils/select';
4
+ export type CascadingSelectItemProps = {
5
+ option: SelectOption;
6
+ icon?: React.ReactNode;
7
+ children?: CascadingSelectItemProps[];
8
+ };
9
+ export interface NestedSelectProps extends Omit<SelectProps, 'value' | 'data'> {
10
+ data?: CascadingSelectItemProps[];
11
+ value?: string | null;
12
+ width?: string | number;
13
+ fullWidth?: boolean;
14
+ }
15
+ declare const NestedSelect: ({ data, value, placeholder, size, width, fullWidth, styles, ...props }: NestedSelectProps) => import("react/jsx-runtime").JSX.Element;
16
+ export { NestedSelect as CascadingSelect };
17
+ //# sourceMappingURL=CascadingSelect.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CascadingSelect.d.ts","sourceRoot":"","sources":["../../../../src/components/Inputs/Dropdowns/CascadingSelect.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAK1B,OAAO,EAAU,WAAW,EAAE,MAAM,UAAU,CAAC;AAG/C,OAAO,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAErD,MAAM,MAAM,wBAAwB,GAAG;IACrC,MAAM,EAAE,YAAY,CAAC;IACrB,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,QAAQ,CAAC,EAAE,wBAAwB,EAAE,CAAC;CACvC,CAAC;AAEF,MAAM,WAAW,iBAAkB,SAAQ,IAAI,CAAC,WAAW,EAAE,OAAO,GAAG,MAAM,CAAC;IAC5E,IAAI,CAAC,EAAE,wBAAwB,EAAE,CAAC;IAClC,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED,QAAA,MAAM,YAAY,GAAI,wEAAiH,iBAAiB,4CA+EvJ,CAAC;AAEF,OAAO,EAAE,YAAY,IAAI,eAAe,EAAE,CAAC"}
@@ -0,0 +1,70 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { Box, Group } from '@mantine/core';
3
+ import { neutral } from '../../../constants/colors';
4
+ import { componentSizes } from './shared/sizes';
5
+ import { Select } from './Select';
6
+ import { Text } from '../../Typography/Text';
7
+ import { fontBase } from '../../../constants/font';
8
+ const NestedSelect = ({ data = [], value, placeholder = 'Select an option', size = 'md', width, fullWidth = false, styles, ...props }) => {
9
+ const selectedSize = componentSizes[size];
10
+ const computedWidth = fullWidth ? '100%' : width || `${selectedSize.minWidth}rem`;
11
+ // Flatten the hierarchy into a flat array with depth information
12
+ const flattenHierarchy = (items, depth = 0) => {
13
+ const result = [];
14
+ items.forEach((item) => {
15
+ result.push({ ...item.option, depth, icon: item.icon });
16
+ if (item.children && item.children.length > 0) {
17
+ result.push(...flattenHierarchy(item.children, depth + 1));
18
+ }
19
+ });
20
+ return result;
21
+ };
22
+ const flattenedData = flattenHierarchy(data);
23
+ const DropdownItem = ({ value, label, icon, depth, ...others }) => {
24
+ const indentLevel = depth * 0.8;
25
+ return (_jsx(Box, { sx: {
26
+ display: 'flex',
27
+ alignItems: 'center',
28
+ padding: selectedSize.dropdownPadding,
29
+ borderRadius: '8px',
30
+ transition: 'background-color 200ms ease-in-out',
31
+ cursor: 'pointer',
32
+ }, ...others, children: _jsxs(Group, { spacing: "0.5rem", sx: { marginLeft: `${indentLevel}rem` }, children: [icon && _jsx(Box, { sx: { display: 'flex', alignItems: 'center', color: neutral[200], fontSize: selectedSize.fontSize }, children: icon }), _jsx(Text, { style: { ...fontBase, color: neutral[200], fontSize: selectedSize.fontSize }, children: label })] }) }));
33
+ };
34
+ const style = {
35
+ input: {
36
+ color: neutral[300],
37
+ border: `1px solid ${neutral[100]}`,
38
+ borderRadius: '8px',
39
+ transition: 'all 200ms ease-in-out',
40
+ height: `${selectedSize.height}rem`,
41
+ ...fontBase,
42
+ fontSize: selectedSize.fontSize,
43
+ padding: selectedSize.inputPadding,
44
+ },
45
+ item: {
46
+ color: neutral[200],
47
+ borderRadius: '8px',
48
+ transition: 'background-color 200ms ease-in-out',
49
+ padding: 0,
50
+ fontSize: selectedSize.fontSize,
51
+ marginBottom: '0.2rem',
52
+ '&[data-selected]': {
53
+ backgroundColor: neutral[50],
54
+ color: neutral[200],
55
+ },
56
+ '&[data-hovered]': {
57
+ backgroundColor: neutral[50],
58
+ },
59
+ '&:not(:hover):not([data-selected])': {
60
+ backgroundColor: 'white',
61
+ },
62
+ '&[data-selected]:hover': {
63
+ backgroundColor: neutral[50],
64
+ },
65
+ ...styles,
66
+ },
67
+ };
68
+ return _jsx(Select, { placeholder: placeholder, width: computedWidth, value: value, size: size, styles: style, itemComponent: DropdownItem, data: flattenedData, ...props });
69
+ };
70
+ export { NestedSelect as CascadingSelect };
@@ -1,10 +1,7 @@
1
1
  import { SelectProps } from './Select';
2
- export type ItemProps = {
3
- value: string;
4
- label: string;
5
- };
2
+ import { SelectOption } from '../../../utils/select';
6
3
  export interface FontSelectProps extends Omit<SelectProps, 'value' | 'data'> {
7
- data?: ItemProps[];
4
+ data?: SelectOption[];
8
5
  value?: string | null;
9
6
  width?: string | number;
10
7
  fullWidth?: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"FontSelect.d.ts","sourceRoot":"","sources":["../../../../src/components/Inputs/Dropdowns/FontSelect.tsx"],"names":[],"mappings":"AAKA,OAAO,EAAU,WAAW,EAAE,MAAM,UAAU,CAAC;AAG/C,MAAM,MAAM,SAAS,GAAG;IACtB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,MAAM,WAAW,eAAgB,SAAQ,IAAI,CAAC,WAAW,EAAE,OAAO,GAAG,MAAM,CAAC;IAC1E,IAAI,CAAC,EAAE,SAAS,EAAE,CAAC;IACnB,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED,QAAA,MAAM,UAAU,GAAI,wEASjB,eAAe,4CA+DjB,CAAC;AAEF,OAAO,EAAE,UAAU,EAAE,CAAC"}
1
+ {"version":3,"file":"FontSelect.d.ts","sourceRoot":"","sources":["../../../../src/components/Inputs/Dropdowns/FontSelect.tsx"],"names":[],"mappings":"AAKA,OAAO,EAAU,WAAW,EAAE,MAAM,UAAU,CAAC;AAC/C,OAAO,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAGrD,MAAM,WAAW,eAAgB,SAAQ,IAAI,CAAC,WAAW,EAAE,OAAO,GAAG,MAAM,CAAC;IAC1E,IAAI,CAAC,EAAE,YAAY,EAAE,CAAC;IACtB,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED,QAAA,MAAM,UAAU,GAAI,wEAAyG,eAAe,4CAoD3I,CAAC;AAEF,OAAO,EAAE,UAAU,EAAE,CAAC"}
@@ -43,6 +43,6 @@ const FontSelect = ({ data, value, placeholder = 'Select a font', size = 'md', w
43
43
  ...styles,
44
44
  },
45
45
  };
46
- return (_jsx(Select, { placeholder: placeholder, width: computedWidth, value: value, size: size, styles: style, itemComponent: DropdownItem, data: data || Fonts.FONTS, ...props }));
46
+ return _jsx(Select, { placeholder: placeholder, width: computedWidth, value: value, size: size, styles: style, itemComponent: DropdownItem, data: data || Fonts.FONTS, ...props });
47
47
  };
48
48
  export { FontSelect };
@@ -0,0 +1,17 @@
1
+ import React from 'react';
2
+ import { SelectProps } from './Select';
3
+ export type NestedSelectItemProps = {
4
+ value: string;
5
+ label: string;
6
+ icon?: React.ReactNode;
7
+ children?: NestedSelectItemProps[];
8
+ };
9
+ export interface NestedSelectProps extends Omit<SelectProps, 'value' | 'data'> {
10
+ data?: NestedSelectItemProps[];
11
+ value?: string | null;
12
+ width?: string | number;
13
+ fullWidth?: boolean;
14
+ }
15
+ declare const NestedSelect: ({ data, value, placeholder, size, width, fullWidth, styles, ...props }: NestedSelectProps) => import("react/jsx-runtime").JSX.Element;
16
+ export { NestedSelect };
17
+ //# sourceMappingURL=NestedSelect.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NestedSelect.d.ts","sourceRoot":"","sources":["../../../../src/components/Inputs/Dropdowns/NestedSelect.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAK1B,OAAO,EAAU,WAAW,EAAE,MAAM,UAAU,CAAC;AAI/C,MAAM,MAAM,qBAAqB,GAAG;IAClC,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,QAAQ,CAAC,EAAE,qBAAqB,EAAE,CAAC;CACpC,CAAC;AAEF,MAAM,WAAW,iBAAkB,SAAQ,IAAI,CAAC,WAAW,EAAE,OAAO,GAAG,MAAM,CAAC;IAC5E,IAAI,CAAC,EAAE,qBAAqB,EAAE,CAAC;IAC/B,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED,QAAA,MAAM,YAAY,GAAI,wEAAiH,iBAAiB,4CA+EvJ,CAAC;AAEF,OAAO,EAAE,YAAY,EAAE,CAAC"}
@@ -0,0 +1,70 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { Box, Group } from '@mantine/core';
3
+ import { neutral } from '../../../constants/colors';
4
+ import { componentSizes } from './shared/sizes';
5
+ import { Select } from './Select';
6
+ import { Text } from '../../Typography/Text';
7
+ import { fontBase } from '../../..';
8
+ const NestedSelect = ({ data = [], value, placeholder = 'Select an option', size = 'md', width, fullWidth = false, styles, ...props }) => {
9
+ const selectedSize = componentSizes[size];
10
+ const computedWidth = fullWidth ? '100%' : width || `${selectedSize.minWidth}rem`;
11
+ // Flatten the hierarchy into a flat array with depth information
12
+ const flattenHierarchy = (items, depth = 0) => {
13
+ const result = [];
14
+ items.forEach((item) => {
15
+ result.push({ ...item, depth });
16
+ if (item.children && item.children.length > 0) {
17
+ result.push(...flattenHierarchy(item.children, depth + 1));
18
+ }
19
+ });
20
+ return result;
21
+ };
22
+ const flattenedData = flattenHierarchy(data);
23
+ const DropdownItem = ({ value, label, icon, depth, ...others }) => {
24
+ const indentLevel = depth * 0.8;
25
+ return (_jsx(Box, { sx: {
26
+ display: 'flex',
27
+ alignItems: 'center',
28
+ padding: selectedSize.dropdownPadding,
29
+ borderRadius: '8px',
30
+ transition: 'background-color 200ms ease-in-out',
31
+ cursor: 'pointer',
32
+ }, ...others, children: _jsxs(Group, { spacing: "0.5rem", sx: { marginLeft: `${indentLevel}rem` }, children: [icon && _jsx(Box, { sx: { display: 'flex', alignItems: 'center', color: neutral[200], fontSize: selectedSize.fontSize }, children: icon }), _jsx(Text, { style: { ...fontBase, color: neutral[200], fontSize: selectedSize.fontSize }, children: label })] }) }));
33
+ };
34
+ const style = {
35
+ input: {
36
+ color: neutral[300],
37
+ border: `1px solid ${neutral[100]}`,
38
+ borderRadius: '8px',
39
+ transition: 'all 200ms ease-in-out',
40
+ height: `${selectedSize.height}rem`,
41
+ ...fontBase,
42
+ fontSize: selectedSize.fontSize,
43
+ padding: selectedSize.inputPadding,
44
+ },
45
+ item: {
46
+ color: neutral[200],
47
+ borderRadius: '8px',
48
+ transition: 'background-color 200ms ease-in-out',
49
+ padding: 0,
50
+ fontSize: selectedSize.fontSize,
51
+ marginBottom: '0.2rem',
52
+ '&[data-selected]': {
53
+ backgroundColor: neutral[50],
54
+ color: neutral[200],
55
+ },
56
+ '&[data-hovered]': {
57
+ backgroundColor: neutral[50],
58
+ },
59
+ '&:not(:hover):not([data-selected])': {
60
+ backgroundColor: 'white',
61
+ },
62
+ '&[data-selected]:hover': {
63
+ backgroundColor: neutral[50],
64
+ },
65
+ ...styles,
66
+ },
67
+ };
68
+ return _jsx(Select, { placeholder: placeholder, width: computedWidth, value: value, size: size, styles: style, itemComponent: DropdownItem, data: flattenedData, ...props });
69
+ };
70
+ export { NestedSelect };
@@ -1 +1 @@
1
- {"version":3,"file":"Select.d.ts","sourceRoot":"","sources":["../../../../src/components/Inputs/Dropdowns/Select.tsx"],"names":[],"mappings":"AACA,OAAO,EAA2B,WAAW,IAAI,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAC3F,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAG5C,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAEhD,MAAM,WAAW,WAAY,SAAQ,kBAAkB;IACrD,IAAI,CAAC,EAAE,MAAM,OAAO,cAAc,CAAC;IACnC,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;CACpC;AAED,eAAO,MAAM,MAAM,GAAI,2DAOpB,WAAW,4CAmEb,CAAC"}
1
+ {"version":3,"file":"Select.d.ts","sourceRoot":"","sources":["../../../../src/components/Inputs/Dropdowns/Select.tsx"],"names":[],"mappings":"AACA,OAAO,EAA2B,WAAW,IAAI,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAC3F,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAG5C,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAEhD,MAAM,WAAW,WAAY,SAAQ,kBAAkB;IACrD,IAAI,CAAC,EAAE,MAAM,OAAO,cAAc,CAAC;IACnC,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;CACpC;AAED,eAAO,MAAM,MAAM,GAAI,2DAA+F,WAAW,4CA0DhI,CAAC"}
@@ -33,7 +33,7 @@ export const Select = ({ size = 'md', width, fullWidth = false, placeholder = 'S
33
33
  },
34
34
  item: {
35
35
  padding: selectedSize.dropdownPadding,
36
- marginBottom: '0.5rem',
36
+ marginBottom: '0.2rem',
37
37
  ...fontBase,
38
38
  fontSize: selectedSize.fontSize,
39
39
  color: neutral[200],
@@ -58,5 +58,5 @@ export const Select = ({ size = 'md', width, fullWidth = false, placeholder = 'S
58
58
  },
59
59
  ...styles,
60
60
  };
61
- return (_jsx(MantineSelect, { radius: "md", size: size, styles: style, placeholder: placeholder, maxDropdownHeight: selectedSize.dropdownHeight, ...props }));
61
+ return _jsx(MantineSelect, { radius: "md", size: size, styles: style, placeholder: placeholder, maxDropdownHeight: selectedSize.dropdownHeight, ...props });
62
62
  };
@@ -1,7 +1,4 @@
1
- interface SelectOption {
2
- value: string;
3
- label: string;
4
- }
1
+ import { SelectOption } from '../../../../utils/select';
5
2
  export declare const FONTS: SelectOption[];
6
3
  export declare const FONT_SIZES: SelectOption[];
7
4
  declare const _default: {
@@ -1 +1 @@
1
- {"version":3,"file":"fontSelectList.d.ts","sourceRoot":"","sources":["../../../../../src/components/Inputs/Dropdowns/shared/fontSelectList.ts"],"names":[],"mappings":"AAAA,UAAU,YAAY;IACrB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;CACd;AAED,eAAO,MAAM,KAAK,EAAE,YAAY,EAoC/B,CAAC;AAEF,eAAO,MAAM,UAAU,EAAE,YAAY,EA0BpC,CAAC;;;;;AAEF,wBAGE"}
1
+ {"version":3,"file":"fontSelectList.d.ts","sourceRoot":"","sources":["../../../../../src/components/Inputs/Dropdowns/shared/fontSelectList.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAExD,eAAO,MAAM,KAAK,EAAE,YAAY,EAoC/B,CAAC;AAEF,eAAO,MAAM,UAAU,EAAE,YAAY,EA0BpC,CAAC;;;;;AAEF,wBAAqC"}
@@ -62,7 +62,4 @@ export const FONT_SIZES = [
62
62
  { value: '64', label: '64' },
63
63
  { value: '72', label: '72' },
64
64
  ];
65
- export default {
66
- FONTS,
67
- FONT_SIZES,
68
- };
65
+ export default { FONTS, FONT_SIZES };
@@ -3,7 +3,8 @@ import { CSSObject } from '@mantine/styles';
3
3
  interface DividerProps extends MantineDividerProps {
4
4
  width?: string | number;
5
5
  styles?: Record<string, CSSObject>;
6
+ color?: string;
6
7
  }
7
- declare const Divider: ({ width, styles, ...props }: DividerProps) => import("react/jsx-runtime").JSX.Element;
8
+ declare const Divider: ({ width, styles, color, ...props }: DividerProps) => import("react/jsx-runtime").JSX.Element;
8
9
  export { Divider };
9
10
  //# sourceMappingURL=Divider.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Divider.d.ts","sourceRoot":"","sources":["../../../src/components/Layout/Divider.tsx"],"names":[],"mappings":"AACA,OAAO,EAA6B,YAAY,IAAI,mBAAmB,EAAE,MAAM,eAAe,CAAC;AAC/F,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAG5C,UAAU,YAAa,SAAQ,mBAAmB;IAChD,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;CACpC;AAED,QAAA,MAAM,OAAO,GAAI,6BAA6B,YAAY,4CAEzD,CAAC;AAEF,OAAO,EAAE,OAAO,EAAE,CAAC"}
1
+ {"version":3,"file":"Divider.d.ts","sourceRoot":"","sources":["../../../src/components/Layout/Divider.tsx"],"names":[],"mappings":"AACA,OAAO,EAA6B,YAAY,IAAI,mBAAmB,EAAE,MAAM,eAAe,CAAC;AAC/F,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAG5C,UAAU,YAAa,SAAQ,mBAAmB;IAChD,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;IACnC,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,QAAA,MAAM,OAAO,GAAI,oCAA2D,YAAY,4CAEvF,CAAC;AAEF,OAAO,EAAE,OAAO,EAAE,CAAC"}
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { Divider as MantineDivider } from '@mantine/core';
3
3
  import { neutral } from '../../constants/colors';
4
- const Divider = ({ width, styles, ...props }) => {
5
- return _jsx(MantineDivider, { color: neutral[50], w: width, styles: styles, ...props });
4
+ const Divider = ({ width = '100%', styles, color = neutral[50], ...props }) => {
5
+ return _jsx(MantineDivider, { color: color, w: width, styles: styles, ...props });
6
6
  };
7
7
  export { Divider };
@@ -1 +1 @@
1
- {"version":3,"file":"SectionCard.d.ts","sourceRoot":"","sources":["../../../src/components/Layout/SectionCard.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAuB,SAAS,IAAI,gBAAgB,EAAE,MAAM,eAAe,CAAC;AACnF,OAAO,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAC;AAKhD,MAAM,WAAW,gBAAiB,SAAQ,IAAI,CAAC,gBAAgB,EAAE,UAAU,CAAC;IAC1E,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,KAAK,CAAC,EAAE,MAAM,OAAO,MAAM,CAAC;CAC7B;AAED,eAAO,MAAM,WAAW,GAAI,gDAA4D,gBAAgB,4CAsBvG,CAAC"}
1
+ {"version":3,"file":"SectionCard.d.ts","sourceRoot":"","sources":["../../../src/components/Layout/SectionCard.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAuB,SAAS,IAAI,gBAAgB,EAAE,MAAM,eAAe,CAAC;AACnF,OAAO,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAC;AAIhD,MAAM,WAAW,gBAAiB,SAAQ,IAAI,CAAC,gBAAgB,EAAE,UAAU,CAAC;IAC1E,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,KAAK,CAAC,EAAE,MAAM,OAAO,MAAM,CAAC;CAC7B;AAED,eAAO,MAAM,WAAW,GAAI,gDAA4D,gBAAgB,4CAsBvG,CAAC"}
@@ -2,11 +2,12 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { Card as MantineCard } from '@mantine/core';
3
3
  import { Stack } from './Stack';
4
4
  import { Title } from '../Typography/Title';
5
+ import { Box } from './Box';
5
6
  export const SectionCard = ({ title, subtitle, children, color = 'primary', ...props }) => {
6
- return (_jsxs(MantineCard, { radius: "20px", shadow: "lg", withBorder: true, padding: 0, ...props, children: [_jsx("div", { style: {
7
+ return (_jsxs(MantineCard, { radius: "20px", shadow: "lg", withBorder: true, padding: 0, ...props, children: [_jsx(Box, { sx: {
7
8
  // background: `linear-gradient(to right, ${colors[color][300]}, ${colors[color][200]})`,
8
9
  backgroundColor: 'white',
9
10
  padding: '1.6rem 2rem 0 2rem',
10
11
  borderRadius: '20px 20px 0 0',
11
- }, children: _jsxs(Stack, { gap: "0.25rem", children: [_jsx(Title, { variant: "cardHeader", children: title }), subtitle && _jsx(Title, { variant: "cardSubheader", children: subtitle })] }) }), _jsx("div", { style: { padding: '2rem 3.2rem 3.2rem 3.2rem' }, children: children })] }));
12
+ }, children: _jsxs(Stack, { gap: "0.25rem", children: [_jsx(Title, { variant: "cardHeader", children: title }), subtitle && _jsx(Title, { variant: "cardSubheader", children: subtitle })] }) }), _jsx(Box, { sx: { padding: '2rem 3.2rem 3.2rem 3.2rem' }, children: children })] }));
12
13
  };
@@ -1,8 +1,8 @@
1
1
  import React from 'react';
2
- import { palettes } from '../../constants/colors';
2
+ import { primitives } from '../../constants/colors';
3
3
  export interface IconBadgeProps {
4
4
  icon: React.ReactNode;
5
- color: keyof typeof palettes;
5
+ color: keyof typeof primitives;
6
6
  }
7
7
  export declare const IconBadge: ({ icon, color }: IconBadgeProps) => import("react/jsx-runtime").JSX.Element;
8
8
  //# sourceMappingURL=IconBadge.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"IconBadge.d.ts","sourceRoot":"","sources":["../../../src/components/Misc/IconBadge.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAElD,MAAM,WAAW,cAAc;IAC7B,IAAI,EAAE,KAAK,CAAC,SAAS,CAAC;IACtB,KAAK,EAAE,MAAM,OAAO,QAAQ,CAAC;CAC9B;AAED,eAAO,MAAM,SAAS,GAAI,iBAAiB,cAAc,4CAkCxD,CAAC"}
1
+ {"version":3,"file":"IconBadge.d.ts","sourceRoot":"","sources":["../../../src/components/Misc/IconBadge.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AAEpD,MAAM,WAAW,cAAc;IAC7B,IAAI,EAAE,KAAK,CAAC,SAAS,CAAC;IACtB,KAAK,EAAE,MAAM,OAAO,UAAU,CAAC;CAChC;AAED,eAAO,MAAM,SAAS,GAAI,iBAAiB,cAAc,4CAgCxD,CAAC"}
@@ -1,12 +1,11 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import React from 'react';
3
- import { palettes } from '../../constants/colors';
3
+ import { primitives } from '../../constants/colors';
4
4
  export const IconBadge = ({ icon, color }) => {
5
5
  const getIconColors = () => {
6
- const colorPalette = palettes[color];
7
6
  return {
8
- background: colorPalette[50],
9
- icon: colorPalette[200],
7
+ background: primitives[color][50],
8
+ icon: primitives[color][200],
10
9
  };
11
10
  };
12
11
  const getIconSize = () => {
@@ -0,0 +1,10 @@
1
+ import { fontWeight, fontSize } from '../../constants/font';
2
+ interface FormulaProps {
3
+ expression: string;
4
+ weight?: keyof typeof fontWeight;
5
+ size?: keyof typeof fontSize;
6
+ color?: string;
7
+ }
8
+ declare const Formula: ({ expression, weight, size, color }: FormulaProps) => import("react/jsx-runtime").JSX.Element;
9
+ export { Formula };
10
+ //# sourceMappingURL=Formula.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Formula.d.ts","sourceRoot":"","sources":["../../../src/components/Typography/Formula.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAK5D,UAAU,YAAY;IACpB,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,CAAC,EAAE,MAAM,OAAO,UAAU,CAAC;IACjC,IAAI,CAAC,EAAE,MAAM,OAAO,QAAQ,CAAC;IAC7B,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AA0MD,QAAA,MAAM,OAAO,GAAI,qCAAqC,YAAY,4CAKjE,CAAC;AAEF,OAAO,EAAE,OAAO,EAAE,CAAC"}