@codezee/sixtify-brahma 0.2.6 → 0.2.7

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 (279) hide show
  1. package/package.json +7 -2
  2. package/.github/workflows/deploy-storybook.yml +0 -40
  3. package/.husky/commit-msg +0 -4
  4. package/.husky/pre-commit +0 -4
  5. package/.husky/pre-push +0 -4
  6. package/.lintstagedrc +0 -5
  7. package/.prettierignore +0 -11
  8. package/.prettierrc +0 -22
  9. package/.vscode/extensions.json +0 -22
  10. package/.vscode/settings.json +0 -17
  11. package/apps/docs/.eslintrc.cjs +0 -4
  12. package/apps/docs/.eslintrc.js +0 -9
  13. package/apps/docs/.storybook/main.ts +0 -23
  14. package/apps/docs/.storybook/preview.tsx +0 -27
  15. package/apps/docs/next-env.d.ts +0 -5
  16. package/apps/docs/next.config.mjs +0 -4
  17. package/apps/docs/package.json +0 -38
  18. package/apps/docs/public/globals.css +0 -25
  19. package/apps/docs/stories/AgGrid/AgGrid.stories.tsx +0 -69
  20. package/apps/docs/stories/AppBar/AppBar.stories.tsx +0 -39
  21. package/apps/docs/stories/Breadcrumbs/Breadcrumbs.stories.tsx +0 -37
  22. package/apps/docs/stories/Button/ButtonGroup.stories.tsx +0 -99
  23. package/apps/docs/stories/Button/button.stories.tsx +0 -99
  24. package/apps/docs/stories/Card/AttendanceCard.stories.tsx +0 -37
  25. package/apps/docs/stories/Card/Card.stories.tsx +0 -39
  26. package/apps/docs/stories/Charts/PieChart.stories.tsx +0 -264
  27. package/apps/docs/stories/Chips/Chip.stories.tsx +0 -141
  28. package/apps/docs/stories/Chips/ChipWithBorder.stories.tsx +0 -18
  29. package/apps/docs/stories/Chips/FilterPill.stories.tsx +0 -24
  30. package/apps/docs/stories/Color/Color.stories.tsx +0 -14
  31. package/apps/docs/stories/Dialog/ButtomDialog.stories.tsx +0 -47
  32. package/apps/docs/stories/Dialog/DeleteDialog.stories.tsx +0 -31
  33. package/apps/docs/stories/Dialog/Dialog.stories.tsx +0 -47
  34. package/apps/docs/stories/Drawer/Drawer.stories.tsx +0 -94
  35. package/apps/docs/stories/FilterList/FilterList.stories.tsx +0 -88
  36. package/apps/docs/stories/FilterList/FilterListV2.stories.tsx +0 -92
  37. package/apps/docs/stories/FormFields/AutoComplete.stories.tsx +0 -87
  38. package/apps/docs/stories/FormFields/CheckBox.stories.tsx +0 -61
  39. package/apps/docs/stories/FormFields/DatePicker.stories.tsx +0 -98
  40. package/apps/docs/stories/FormFields/DateRangePicker.stories.tsx +0 -37
  41. package/apps/docs/stories/FormFields/FileUpload.stories.tsx +0 -83
  42. package/apps/docs/stories/FormFields/ImageUpload.stories.tsx +0 -69
  43. package/apps/docs/stories/FormFields/ListItemButton.stories.tsx +0 -59
  44. package/apps/docs/stories/FormFields/RadioGroupField.stories.tsx +0 -170
  45. package/apps/docs/stories/FormFields/SearchField.stories.tsx +0 -72
  46. package/apps/docs/stories/FormFields/TextField.stories.tsx +0 -111
  47. package/apps/docs/stories/FormFields/TimeField.stories.tsx +0 -82
  48. package/apps/docs/stories/FormFields/TimePicker.stories.tsx +0 -82
  49. package/apps/docs/stories/Indicator/Indicator.stories.tsx +0 -33
  50. package/apps/docs/stories/Indicator/SeverityIndicator.stories.tsx +0 -27
  51. package/apps/docs/stories/Layouts/FormRow.stories.tsx +0 -45
  52. package/apps/docs/stories/PadBox/PadBox.stories.tsx +0 -49
  53. package/apps/docs/stories/Stepper/Stepper.stories.tsx +0 -75
  54. package/apps/docs/stories/Stepper/StepperV2.stories.tsx +0 -44
  55. package/apps/docs/stories/Timeline/AttendanceStatus.stories.tsx +0 -29
  56. package/apps/docs/stories/Timeline/Timeline.stories.tsx +0 -38
  57. package/apps/docs/stories/Tooltip/Tooltip.stories.tsx +0 -30
  58. package/apps/docs/stories/UserProfileMenu/UserProfileMenu.stories.tsx +0 -112
  59. package/apps/docs/tsconfig.json +0 -19
  60. package/commitlint.config.cjs +0 -6
  61. package/index.ts +0 -1
  62. package/packages/eslint-config/README.md +0 -3
  63. package/packages/eslint-config/library.js +0 -88
  64. package/packages/eslint-config/next.js +0 -85
  65. package/packages/eslint-config/package.json +0 -19
  66. package/packages/eslint-config/react-internal.js +0 -89
  67. package/packages/shared-components/.eslintrc.js +0 -10
  68. package/packages/shared-components/package.json +0 -22
  69. package/packages/shared-components/src/Actions/AddAction.tsx +0 -13
  70. package/packages/shared-components/src/Actions/CalendarAction.tsx +0 -13
  71. package/packages/shared-components/src/Actions/ConfigureAction.tsx +0 -13
  72. package/packages/shared-components/src/Actions/DeleteAction.tsx +0 -13
  73. package/packages/shared-components/src/Actions/DownloadAction.tsx +0 -13
  74. package/packages/shared-components/src/Actions/EditAction.tsx +0 -13
  75. package/packages/shared-components/src/Actions/HistoryAction.tsx +0 -13
  76. package/packages/shared-components/src/Actions/index.ts +0 -7
  77. package/packages/shared-components/src/AgGrid/ActionCell/ActionCell.tsx +0 -57
  78. package/packages/shared-components/src/AgGrid/ActionCell/Popover.tsx +0 -32
  79. package/packages/shared-components/src/AgGrid/AgGrid.tsx +0 -93
  80. package/packages/shared-components/src/AgGrid/LoadingCell.tsx +0 -5
  81. package/packages/shared-components/src/AgGrid/index.ts +0 -3
  82. package/packages/shared-components/src/AppBar/AppBar.styled.tsx +0 -25
  83. package/packages/shared-components/src/AppBar/AppBar.tsx +0 -20
  84. package/packages/shared-components/src/AppBar/index.ts +0 -1
  85. package/packages/shared-components/src/Breadcrumbs/Breadcrumbs.tsx +0 -76
  86. package/packages/shared-components/src/Breadcrumbs/index.ts +0 -1
  87. package/packages/shared-components/src/Button/ActionButton.tsx +0 -38
  88. package/packages/shared-components/src/Button/Button.tsx +0 -19
  89. package/packages/shared-components/src/Button/ButtonGroup.tsx +0 -37
  90. package/packages/shared-components/src/Button/index.ts +0 -3
  91. package/packages/shared-components/src/Card/AttendanceCard.tsx +0 -51
  92. package/packages/shared-components/src/Card/Card.tsx +0 -34
  93. package/packages/shared-components/src/Card/CardItem/CardItem.tsx +0 -33
  94. package/packages/shared-components/src/Card/CardItem/CardItemValue.tsx +0 -98
  95. package/packages/shared-components/src/Card/CardItem/index.ts +0 -2
  96. package/packages/shared-components/src/Card/ProfileCard/ProfileCard.tsx +0 -40
  97. package/packages/shared-components/src/Card/ProfileCard/ProfileCardItem/ProfileCardBody.tsx +0 -53
  98. package/packages/shared-components/src/Card/ProfileCard/ProfileCardItem/ProfileCardHeader.tsx +0 -96
  99. package/packages/shared-components/src/Card/index.ts +0 -6
  100. package/packages/shared-components/src/Charts/PieChart.tsx +0 -81
  101. package/packages/shared-components/src/Charts/Skeleton.tsx +0 -36
  102. package/packages/shared-components/src/Charts/index.ts +0 -1
  103. package/packages/shared-components/src/Chips/Chip.tsx +0 -26
  104. package/packages/shared-components/src/Chips/ChipWithBorder.tsx +0 -39
  105. package/packages/shared-components/src/Chips/FilterPill.tsx +0 -47
  106. package/packages/shared-components/src/Chips/index.ts +0 -3
  107. package/packages/shared-components/src/Dialog/BottomDialog.styled.tsx +0 -28
  108. package/packages/shared-components/src/Dialog/BottomDialog.tsx +0 -37
  109. package/packages/shared-components/src/Dialog/DeleteDialog.tsx +0 -48
  110. package/packages/shared-components/src/Dialog/Dialog.tsx +0 -61
  111. package/packages/shared-components/src/Dialog/index.ts +0 -3
  112. package/packages/shared-components/src/Drawer/Bullet.tsx +0 -12
  113. package/packages/shared-components/src/Drawer/CloseDrawer/CloseDrawerMenuItem.tsx +0 -57
  114. package/packages/shared-components/src/Drawer/CloseDrawer/CloseDrawerMenuItemList.tsx +0 -109
  115. package/packages/shared-components/src/Drawer/CloseDrawer/CloseDrawerSubMenuItemList.tsx +0 -124
  116. package/packages/shared-components/src/Drawer/CloseDrawer/MenuItem.tsx +0 -0
  117. package/packages/shared-components/src/Drawer/CloseDrawer/Popover.tsx +0 -45
  118. package/packages/shared-components/src/Drawer/CloseDrawer/Popper.tsx +0 -43
  119. package/packages/shared-components/src/Drawer/Drawer.styled.tsx +0 -51
  120. package/packages/shared-components/src/Drawer/Drawer.tsx +0 -55
  121. package/packages/shared-components/src/Drawer/MenuItem.tsx +0 -75
  122. package/packages/shared-components/src/Drawer/OpenDrawer/OpenDrawerCollapse.tsx +0 -13
  123. package/packages/shared-components/src/Drawer/OpenDrawer/OpenDrawerMenuItem.tsx +0 -46
  124. package/packages/shared-components/src/Drawer/OpenDrawer/OpenDrawerMenuItemList.tsx +0 -197
  125. package/packages/shared-components/src/Drawer/index.ts +0 -1
  126. package/packages/shared-components/src/FilterList/FilterList.tsx +0 -172
  127. package/packages/shared-components/src/FilterList/FilterListV2.tsx +0 -515
  128. package/packages/shared-components/src/FilterList/FilterPopup.tsx +0 -148
  129. package/packages/shared-components/src/FilterList/FilterPopupWrapper.tsx +0 -113
  130. package/packages/shared-components/src/FilterList/FilterTypeWrapper.tsx +0 -58
  131. package/packages/shared-components/src/FilterList/getFormData.ts +0 -29
  132. package/packages/shared-components/src/FilterList/index.ts +0 -5
  133. package/packages/shared-components/src/FormFields/Autocomplete/Autocomplete.tsx +0 -510
  134. package/packages/shared-components/src/FormFields/Autocomplete/Skeleton.tsx +0 -26
  135. package/packages/shared-components/src/FormFields/Autocomplete/index.ts +0 -1
  136. package/packages/shared-components/src/FormFields/CheckBox/CheckBox.styled.tsx +0 -67
  137. package/packages/shared-components/src/FormFields/CheckBox/CheckBox.tsx +0 -44
  138. package/packages/shared-components/src/FormFields/CheckBox/Skeleton.tsx +0 -12
  139. package/packages/shared-components/src/FormFields/CheckBox/index.ts +0 -1
  140. package/packages/shared-components/src/FormFields/DatePicker/DatePicker.tsx +0 -217
  141. package/packages/shared-components/src/FormFields/DatePicker/Skeleton.tsx +0 -28
  142. package/packages/shared-components/src/FormFields/DatePicker/index.ts +0 -1
  143. package/packages/shared-components/src/FormFields/DateRangePicker/DateRangePicker.tsx +0 -96
  144. package/packages/shared-components/src/FormFields/DateRangePicker/Skeleton.tsx +0 -38
  145. package/packages/shared-components/src/FormFields/DateRangePicker/index.ts +0 -1
  146. package/packages/shared-components/src/FormFields/DateTimePicker/DateTimePicker.tsx +0 -250
  147. package/packages/shared-components/src/FormFields/DateTimePicker/Skeleton.tsx +0 -24
  148. package/packages/shared-components/src/FormFields/DateTimePicker/index.ts +0 -1
  149. package/packages/shared-components/src/FormFields/FileUpload/FileNames.tsx +0 -32
  150. package/packages/shared-components/src/FormFields/FileUpload/FileUpload.styled.tsx +0 -22
  151. package/packages/shared-components/src/FormFields/FileUpload/FileUpload.tsx +0 -157
  152. package/packages/shared-components/src/FormFields/FileUpload/Skeleton.tsx +0 -21
  153. package/packages/shared-components/src/FormFields/FileUpload/UploadedFileName.tsx +0 -27
  154. package/packages/shared-components/src/FormFields/FileUpload/index.ts +0 -2
  155. package/packages/shared-components/src/FormFields/ImageUpload/ImageUpload.styled.tsx +0 -16
  156. package/packages/shared-components/src/FormFields/ImageUpload/ImageUpload.tsx +0 -181
  157. package/packages/shared-components/src/FormFields/ImageUpload/ImageUploadView.tsx +0 -65
  158. package/packages/shared-components/src/FormFields/ImageUpload/PhotoCaptureDialog.tsx +0 -74
  159. package/packages/shared-components/src/FormFields/ImageUpload/Skeleton.tsx +0 -31
  160. package/packages/shared-components/src/FormFields/ImageUpload/index.ts +0 -2
  161. package/packages/shared-components/src/FormFields/ListItemButton/ListItemButton.styled.tsx +0 -22
  162. package/packages/shared-components/src/FormFields/ListItemButton/ListItemButton.tsx +0 -52
  163. package/packages/shared-components/src/FormFields/ListItemButton/index.ts +0 -1
  164. package/packages/shared-components/src/FormFields/PasswordField/PasswordField.tsx +0 -50
  165. package/packages/shared-components/src/FormFields/PasswordField/index.ts +0 -1
  166. package/packages/shared-components/src/FormFields/RadioGroupField/RadioGroupField.tsx +0 -105
  167. package/packages/shared-components/src/FormFields/RadioGroupField/Skeleton.tsx +0 -26
  168. package/packages/shared-components/src/FormFields/RadioGroupField/index.ts +0 -1
  169. package/packages/shared-components/src/FormFields/SearchField/SearchField.tsx +0 -21
  170. package/packages/shared-components/src/FormFields/SearchField/index.ts +0 -1
  171. package/packages/shared-components/src/FormFields/Switch/Skeleton.tsx +0 -12
  172. package/packages/shared-components/src/FormFields/Switch/Switch.tsx +0 -33
  173. package/packages/shared-components/src/FormFields/Switch/index.ts +0 -1
  174. package/packages/shared-components/src/FormFields/TextField/Skeleton.tsx +0 -31
  175. package/packages/shared-components/src/FormFields/TextField/TextField.tsx +0 -92
  176. package/packages/shared-components/src/FormFields/TextField/index.ts +0 -1
  177. package/packages/shared-components/src/FormFields/TimeField/Skeleton.tsx +0 -24
  178. package/packages/shared-components/src/FormFields/TimeField/TimeField.tsx +0 -120
  179. package/packages/shared-components/src/FormFields/TimeField/index.ts +0 -1
  180. package/packages/shared-components/src/FormFields/TimePicker/Skeleton.tsx +0 -24
  181. package/packages/shared-components/src/FormFields/TimePicker/TimePicker.tsx +0 -168
  182. package/packages/shared-components/src/FormFields/TimePicker/index.ts +0 -1
  183. package/packages/shared-components/src/FormFields/index.ts +0 -13
  184. package/packages/shared-components/src/Indicator/Indicator.tsx +0 -18
  185. package/packages/shared-components/src/Indicator/SeverityIndicator.tsx +0 -34
  186. package/packages/shared-components/src/Indicator/index.ts +0 -2
  187. package/packages/shared-components/src/Layouts/FormContainer.tsx +0 -6
  188. package/packages/shared-components/src/Layouts/FormGridLayout.tsx +0 -27
  189. package/packages/shared-components/src/Layouts/FormRow/FormRow.styled.tsx +0 -39
  190. package/packages/shared-components/src/Layouts/FormRow/FormRow.tsx +0 -20
  191. package/packages/shared-components/src/Layouts/FormRow/index.ts +0 -1
  192. package/packages/shared-components/src/Layouts/FormSection.tsx +0 -22
  193. package/packages/shared-components/src/Layouts/index.ts +0 -4
  194. package/packages/shared-components/src/Loader/FacebookCircularProgress.tsx +0 -41
  195. package/packages/shared-components/src/Loader/index.ts +0 -1
  196. package/packages/shared-components/src/PadBox/PadBox.tsx +0 -21
  197. package/packages/shared-components/src/PadBox/index.ts +0 -1
  198. package/packages/shared-components/src/Pagination/Pagination.tsx +0 -42
  199. package/packages/shared-components/src/Pagination/index.ts +0 -1
  200. package/packages/shared-components/src/Stepper/Stepper.tsx +0 -54
  201. package/packages/shared-components/src/Stepper/StepperV2.tsx +0 -115
  202. package/packages/shared-components/src/Stepper/StepperV3.tsx +0 -72
  203. package/packages/shared-components/src/Stepper/index.ts +0 -3
  204. package/packages/shared-components/src/Svgs/AppLogo/AppLogoMedium.tsx +0 -65
  205. package/packages/shared-components/src/Svgs/AppLogo/AppLogoSmall.tsx +0 -48
  206. package/packages/shared-components/src/Svgs/ArrowUp.tsx +0 -11
  207. package/packages/shared-components/src/Svgs/Company/CompanyBanner.tsx +0 -480
  208. package/packages/shared-components/src/Svgs/Company/index.ts +0 -1
  209. package/packages/shared-components/src/Svgs/Drawer/SettingIcon.tsx +0 -31
  210. package/packages/shared-components/src/Svgs/Drawer/SvgBankConfig.tsx +0 -36
  211. package/packages/shared-components/src/Svgs/Drawer/SvgConfiguration.tsx +0 -16
  212. package/packages/shared-components/src/Svgs/Drawer/SvgPayroll.tsx +0 -32
  213. package/packages/shared-components/src/Svgs/Drawer/SvgsEmployees.tsx +0 -25
  214. package/packages/shared-components/src/Svgs/Drawer/SvgsOrganization.tsx +0 -36
  215. package/packages/shared-components/src/Svgs/Drawer/SvgsTransaction.tsx +0 -81
  216. package/packages/shared-components/src/Svgs/Drawer/index.ts +0 -7
  217. package/packages/shared-components/src/Svgs/FormAction.tsx +0 -118
  218. package/packages/shared-components/src/Svgs/ImportExcelSuccessIcon.tsx +0 -54
  219. package/packages/shared-components/src/Svgs/LogoIcon.tsx +0 -74
  220. package/packages/shared-components/src/Svgs/SvgAdd.tsx +0 -28
  221. package/packages/shared-components/src/Svgs/SvgCalendar.tsx +0 -89
  222. package/packages/shared-components/src/Svgs/SvgConfigure.tsx +0 -51
  223. package/packages/shared-components/src/Svgs/SvgDelete.tsx +0 -55
  224. package/packages/shared-components/src/Svgs/SvgDownload.tsx +0 -20
  225. package/packages/shared-components/src/Svgs/SvgEmail.tsx +0 -24
  226. package/packages/shared-components/src/Svgs/SvgFilterList.tsx +0 -19
  227. package/packages/shared-components/src/Svgs/SvgNoLogo.tsx +0 -66
  228. package/packages/shared-components/src/Svgs/SvgNoSign.tsx +0 -28
  229. package/packages/shared-components/src/Svgs/SvgPhone.tsx +0 -16
  230. package/packages/shared-components/src/Svgs/SvgsDrop.tsx +0 -44
  231. package/packages/shared-components/src/Svgs/SvgsEdit.tsx +0 -42
  232. package/packages/shared-components/src/Svgs/SvgsHistory.tsx +0 -40
  233. package/packages/shared-components/src/Svgs/SvgsHome.tsx +0 -18
  234. package/packages/shared-components/src/Svgs/SvgsIndicator.tsx +0 -24
  235. package/packages/shared-components/src/Svgs/index.ts +0 -14
  236. package/packages/shared-components/src/Tab/Skeleton.tsx +0 -15
  237. package/packages/shared-components/src/Tab/Tabs.tsx +0 -64
  238. package/packages/shared-components/src/Tab/index.ts +0 -1
  239. package/packages/shared-components/src/Timeline/AttendanceStatus.tsx +0 -56
  240. package/packages/shared-components/src/Timeline/Timeline.tsx +0 -171
  241. package/packages/shared-components/src/Timeline/TimelineTrackSegments.tsx +0 -130
  242. package/packages/shared-components/src/Timeline/index.ts +0 -2
  243. package/packages/shared-components/src/Toast/Toast.tsx +0 -59
  244. package/packages/shared-components/src/Toast/ToastBody.tsx +0 -26
  245. package/packages/shared-components/src/Toast/ToastFooterLink.tsx +0 -19
  246. package/packages/shared-components/src/Toast/Toaster.styled.tsx +0 -76
  247. package/packages/shared-components/src/Toast/Toaster.tsx +0 -21
  248. package/packages/shared-components/src/Toast/index.ts +0 -3
  249. package/packages/shared-components/src/Toast/toasts.tsx +0 -28
  250. package/packages/shared-components/src/Toast/types.ts +0 -13
  251. package/packages/shared-components/src/Tooltip/Tooltip.tsx +0 -36
  252. package/packages/shared-components/src/Tooltip/index.ts +0 -1
  253. package/packages/shared-components/src/UserProfileMenu/UserProfileMenu.styled.tsx +0 -33
  254. package/packages/shared-components/src/UserProfileMenu/UserProfileMenu.tsx +0 -168
  255. package/packages/shared-components/src/UserProfileMenu/index.ts +0 -1
  256. package/packages/shared-components/src/index.ts +0 -25
  257. package/packages/shared-components/src/utils/colorVariant.ts +0 -162
  258. package/packages/shared-components/src/utils/date.ts +0 -25
  259. package/packages/shared-components/src/utils/file.ts +0 -20
  260. package/packages/shared-components/src/utils/fileSizeValidate.ts +0 -5
  261. package/packages/shared-components/src/utils/index.ts +0 -9
  262. package/packages/shared-components/src/utils/theme/colorPalette.ts +0 -112
  263. package/packages/shared-components/src/utils/theme/colorPaletteUI.tsx +0 -44
  264. package/packages/shared-components/src/utils/theme/paletteDark.ts +0 -10
  265. package/packages/shared-components/src/utils/theme/paletteLight.ts +0 -31
  266. package/packages/shared-components/src/utils/theme/theme.ts +0 -297
  267. package/packages/shared-components/src/utils/theme/types.ts +0 -18
  268. package/packages/shared-components/src/utils/theme/typography.ts +0 -52
  269. package/packages/shared-components/src/utils/urlToNestedObject.ts +0 -9
  270. package/packages/shared-components/tsconfig.json +0 -8
  271. package/packages/shared-components/tsconfig.lint.json +0 -8
  272. package/packages/shared-components/turbo/generators/config.ts +0 -33
  273. package/packages/shared-components/turbo/generators/templates/component.hbs +0 -8
  274. package/packages/typescript-config/base.json +0 -20
  275. package/packages/typescript-config/nextjs.json +0 -13
  276. package/packages/typescript-config/package.json +0 -9
  277. package/packages/typescript-config/react-library.json +0 -8
  278. package/pnpm-workspace.yaml +0 -3
  279. package/turbo.json +0 -44
@@ -1,89 +0,0 @@
1
- const { resolve } = require("node:path");
2
-
3
- const project = resolve(process.cwd(), "tsconfig.json");
4
-
5
- /*
6
- * This is a custom ESLint configuration for use with
7
- * internal (bundled by their consumer) libraries
8
- * that utilize React.
9
- */
10
-
11
- /** @type {import("eslint").Linter.Config} */
12
- module.exports = {
13
- extends: [
14
- "eslint:recommended",
15
- "plugin:react/recommended",
16
- "prettier",
17
- "turbo",
18
- "plugin:@typescript-eslint/recommended",
19
- "plugin:sonarjs/recommended-legacy",
20
- "plugin:import/recommended",
21
- ],
22
- plugins: ["sonarjs", "import"],
23
- globals: {
24
- React: true,
25
- JSX: true,
26
- },
27
- env: {
28
- browser: true,
29
- },
30
- settings: {
31
- react: {
32
- version: "detect",
33
- },
34
- "import/resolver": {
35
- typescript: {
36
- project,
37
- },
38
- },
39
- },
40
- ignorePatterns: [".*.js", "node_modules/", "dist/"],
41
- overrides: [{ files: ["*.js?(x)", "*.ts?(x)"] }],
42
- rules: {
43
- "@typescript-eslint/consistent-type-definitions": ["error", "type"],
44
- "import/no-duplicates": ["error"],
45
- "react/jsx-curly-brace-presence": [
46
- "error",
47
- { props: "never", children: "never" },
48
- ],
49
- "object-shorthand": ["error", "always"],
50
- curly: "error",
51
- quotes: ["error", "double"],
52
- "import/no-default-export": "error",
53
- "no-template-curly-in-string": "error",
54
- "sonarjs/todo-tag": "off",
55
- "no-use-before-define": "error",
56
- "@typescript-eslint/consistent-type-imports": "error",
57
- "no-console": "error",
58
- "no-empty-function": "error",
59
- "no-lone-blocks": "error",
60
- "no-lonely-if": "error",
61
- "no-else-return": "error",
62
- "padding-line-between-statements": [
63
- "error",
64
- { blankLine: "always", prev: ["case", "default"], next: "*" },
65
- { blankLine: "always", prev: "directive", next: "*" },
66
- { blankLine: "any", prev: "directive", next: "directive" },
67
- {
68
- blankLine: "always",
69
- prev: ["var", "let", "const"],
70
- next: "*",
71
- },
72
- {
73
- blankLine: "always",
74
- prev: "*",
75
- next: ["var", "let", "const"],
76
- },
77
- {
78
- blankLine: "always",
79
- prev: "*",
80
- next: "return",
81
- },
82
- {
83
- blankLine: "always",
84
- prev: "*",
85
- next: "if",
86
- },
87
- ],
88
- },
89
- };
@@ -1,10 +0,0 @@
1
- /** @type {import("eslint").Linter.Config} */
2
- module.exports = {
3
- root: true,
4
- extends: ["@repo/eslint-config/react-internal.js"],
5
- parser: "@typescript-eslint/parser",
6
- parserOptions: {
7
- project: "./tsconfig.lint.json",
8
- tsconfigRootDir: __dirname,
9
- },
10
- };
@@ -1,22 +0,0 @@
1
- {
2
- "devDependencies": {
3
- "@repo/eslint-config": "workspace:*",
4
- "@repo/typescript-config": "workspace:*",
5
- "@turbo/gen": "^1.12.4",
6
- "@types/eslint": "^8.56.5",
7
- "@types/node": "^20.11.24",
8
- "@types/react": "^18.2.61",
9
- "@types/react-dom": "^18.2.19",
10
- "eslint": "^8.57.0",
11
- "react": "^18.2.0",
12
- "typescript": "^5.3.3"
13
- },
14
- "main": "src/index.ts",
15
- "name": "@repo/shared-components",
16
- "private": true,
17
- "scripts": {
18
- "generate:component": "turbo gen react-component",
19
- "lint": "eslint . --max-warnings 0"
20
- },
21
- "version": "0.0.0"
22
- }
@@ -1,13 +0,0 @@
1
- import type { IconButtonProps } from "@mui/material";
2
- import { IconButton } from "@mui/material";
3
- import { SvgAdd } from "../Svgs";
4
-
5
- export type AddActionProps = IconButtonProps;
6
-
7
- export const AddAction = (props: AddActionProps) => {
8
- return (
9
- <IconButton {...props}>
10
- <SvgAdd />
11
- </IconButton>
12
- );
13
- };
@@ -1,13 +0,0 @@
1
- import type { IconButtonProps } from "@mui/material";
2
- import { IconButton } from "@mui/material";
3
- import { SvgCalendar } from "../Svgs";
4
-
5
- export type CalendarActionProps = IconButtonProps;
6
-
7
- export const CalendarAction = (props: CalendarActionProps) => {
8
- return (
9
- <IconButton sx={{ color: "#4C5D70" }} {...props}>
10
- <SvgCalendar />
11
- </IconButton>
12
- );
13
- };
@@ -1,13 +0,0 @@
1
- import type { IconButtonProps } from "@mui/material";
2
- import { IconButton } from "@mui/material";
3
- import { SvgConfigure } from "../Svgs";
4
-
5
- export type ConfigureActionProps = IconButtonProps;
6
-
7
- export const ConfigureAction = (props: ConfigureActionProps) => {
8
- return (
9
- <IconButton {...props}>
10
- <SvgConfigure />
11
- </IconButton>
12
- );
13
- };
@@ -1,13 +0,0 @@
1
- import type { IconButtonProps } from "@mui/material";
2
- import { IconButton } from "@mui/material";
3
- import { SvgDelete } from "../Svgs/SvgDelete";
4
-
5
- export type DeleteActionProps = IconButtonProps;
6
-
7
- export const DeleteAction = (props: DeleteActionProps) => {
8
- return (
9
- <IconButton {...props}>
10
- <SvgDelete />
11
- </IconButton>
12
- );
13
- };
@@ -1,13 +0,0 @@
1
- import type { IconButtonProps } from "@mui/material";
2
- import { IconButton } from "@mui/material";
3
- import { SvgDownload } from "../Svgs";
4
-
5
- export type DownloadActionProps = IconButtonProps;
6
-
7
- export const DownloadAction = (props: DownloadActionProps) => {
8
- return (
9
- <IconButton {...props}>
10
- <SvgDownload />
11
- </IconButton>
12
- );
13
- };
@@ -1,13 +0,0 @@
1
- import type { IconButtonProps } from "@mui/material";
2
- import { IconButton } from "@mui/material";
3
- import { SvgsEdit } from "../Svgs/SvgsEdit";
4
-
5
- export type EditActionProps = IconButtonProps;
6
-
7
- export const EditAction = (props: EditActionProps) => {
8
- return (
9
- <IconButton {...props}>
10
- <SvgsEdit />
11
- </IconButton>
12
- );
13
- };
@@ -1,13 +0,0 @@
1
- import type { IconButtonProps } from "@mui/material";
2
- import { IconButton } from "@mui/material";
3
- import { SvgsHistory } from "../Svgs/SvgsHistory";
4
-
5
- export type HistoryActionProps = IconButtonProps;
6
-
7
- export const HistoryAction = (props: HistoryActionProps) => {
8
- return (
9
- <IconButton {...props}>
10
- <SvgsHistory />
11
- </IconButton>
12
- );
13
- };
@@ -1,7 +0,0 @@
1
- export * from "./AddAction";
2
- export * from "./CalendarAction";
3
- export * from "./ConfigureAction";
4
- export * from "./DeleteAction";
5
- export * from "./DownloadAction";
6
- export * from "./EditAction";
7
- export * from "./HistoryAction";
@@ -1,57 +0,0 @@
1
- import MoreVertIcon from "@mui/icons-material/MoreVert";
2
- import { Box, IconButton, ListItemButton, Stack } from "@mui/material";
3
- import { type MouseEvent, useState } from "react";
4
- import { PadBox } from "../../PadBox";
5
- import { Popover } from "./Popover";
6
-
7
- type AgGridActionColumn = {
8
- title: string;
9
- onClick: () => void;
10
- };
11
-
12
- type ActionColumnProps = {
13
- items: AgGridActionColumn[];
14
- disabled?: boolean;
15
- };
16
- export const ActionCell = ({ items, disabled }: ActionColumnProps) => {
17
- const [anchorEl, setAnchorEl] = useState<HTMLDivElement | null>(null);
18
-
19
- const HandleClose = () => {
20
- setAnchorEl(null);
21
- };
22
-
23
- const HandleClick = (event: MouseEvent<HTMLDivElement>) => {
24
- setAnchorEl(event.currentTarget);
25
- };
26
-
27
- return (
28
- <Box sx={{ width: "100%" }}>
29
- <IconButton
30
- component="div"
31
- sx={{ cursor: "pointer", alignItems: "center", width: "100%" }}
32
- onClick={HandleClick}
33
- disabled={disabled}
34
- >
35
- <MoreVertIcon />
36
- </IconButton>
37
- {!!anchorEl && (
38
- <Popover open={true} anchorEl={anchorEl} onClose={HandleClose}>
39
- <PadBox padding={{ padding: "2px" }}>
40
- {items.map((item) => {
41
- return (
42
- <Stack key={item.title}>
43
- <ListItemButton
44
- sx={{ width: "100%", textAlign: "center" }}
45
- onClick={() => item?.onClick()}
46
- >
47
- {item.title}
48
- </ListItemButton>
49
- </Stack>
50
- );
51
- })}
52
- </PadBox>
53
- </Popover>
54
- )}
55
- </Box>
56
- );
57
- };
@@ -1,32 +0,0 @@
1
- import type { PopoverProps } from "@mui/material";
2
- import { Popover as MuiPopover } from "@mui/material";
3
-
4
- export const Popover = ({
5
- open,
6
- anchorEl,
7
- children,
8
- onClose,
9
- }: PopoverProps) => {
10
- return (
11
- <MuiPopover
12
- open={open}
13
- anchorEl={anchorEl}
14
- onClose={onClose}
15
- anchorOrigin={{
16
- vertical: "bottom",
17
- horizontal: "center",
18
- }}
19
- transformOrigin={{
20
- vertical: "top",
21
- horizontal: "right",
22
- }}
23
- sx={{
24
- "& .MuiPaper-root": {
25
- width: "auto",
26
- },
27
- }}
28
- >
29
- {children}
30
- </MuiPopover>
31
- );
32
- };
@@ -1,93 +0,0 @@
1
- import { Box, Typography, useTheme } from "@mui/material";
2
- import type { AgGridReactProps } from "ag-grid-react";
3
- import { AgGridReact } from "ag-grid-react";
4
- import type { Ref } from "react";
5
- import { forwardRef } from "react";
6
-
7
- export const defaultPageSize = 50;
8
-
9
- export const pageSizeOptions = [20, 50, 100, 200];
10
-
11
- //TODO: jaydip, fix unknown type
12
- export type AgGridProps<T = unknown> = AgGridReactProps<T> & {
13
- height?: string;
14
- ref?: Ref<AgGridReact<T>>;
15
- totalRecords?: number;
16
- overlayNoRowsTemplate?: string;
17
- };
18
-
19
- type AgGridType = React.ForwardRefExoticComponent<AgGridProps> &
20
- (<GenericType>(props: AgGridProps<GenericType>) => JSX.Element);
21
-
22
- export const AgGrid = forwardRef(
23
- <T,>(props: AgGridProps<T>, ref: Ref<AgGridReact<T>>) => {
24
- const {
25
- cacheBlockSize = defaultPageSize,
26
- defaultColDef = {
27
- flex: 1,
28
- floatingFilter: false,
29
- filterParams: {
30
- buttons: ["apply", "reset"],
31
- closeOnApply: true,
32
- contains: false,
33
- },
34
- },
35
- height = "597px",
36
- rowHeight = 50,
37
- rowModelType = "infinite",
38
- rowBuffer = 5,
39
- totalRecords,
40
- // eslint-disable-next-line quotes
41
- overlayNoRowsTemplate = '<span class="ag-overlay-no-rows-center">No Data Found</span>',
42
- infiniteInitialRowCount = defaultPageSize,
43
- pagination = false,
44
- ...rest
45
- } = props;
46
-
47
- const {
48
- palette: {
49
- app: { color },
50
- },
51
- } = useTheme();
52
-
53
- if (totalRecords === 0) {
54
- return (
55
- <Box
56
- sx={{
57
- borderRadius: "4px",
58
- margin: "20px",
59
- display: "flex",
60
- justifyContent: "center",
61
- alignItems: "center",
62
- height: "300px",
63
- textAlign: "center",
64
- backgroundColor: color.butterflyBlue[700],
65
- }}
66
- >
67
- <Typography variant="h6">No result found</Typography>
68
- </Box>
69
- );
70
- }
71
-
72
- return (
73
- <div className="ag-theme-quartz " style={{ width: "100%", height }}>
74
- <AgGridReact<T>
75
- ref={ref}
76
- cacheBlockSize={cacheBlockSize}
77
- defaultColDef={defaultColDef}
78
- rowHeight={rowHeight}
79
- rowModelType={rowModelType}
80
- rowBuffer={rowBuffer}
81
- infiniteInitialRowCount={infiniteInitialRowCount}
82
- overlayNoRowsTemplate={overlayNoRowsTemplate}
83
- pagination={pagination}
84
- {...(pagination ? { paginationPageSize: defaultPageSize } : {})}
85
- paginationPageSizeSelector={pagination ? pageSizeOptions : false}
86
- {...rest}
87
- />
88
- </div>
89
- );
90
- }
91
- ) as AgGridType;
92
-
93
- AgGrid.displayName = "AgGrid";
@@ -1,5 +0,0 @@
1
- import { Skeleton } from "@mui/material";
2
-
3
- export const LoadingCell = () => {
4
- return <Skeleton animation="pulse" width="100%" />;
5
- };
@@ -1,3 +0,0 @@
1
- export * from "./AgGrid";
2
- export * from "./LoadingCell";
3
- export * from "./ActionCell/ActionCell";
@@ -1,25 +0,0 @@
1
- import { styled } from "@mui/material";
2
- import type { AppBarProps as MuiAppBarProps } from "@mui/material/AppBar";
3
- import MuiAppBar from "@mui/material/AppBar";
4
-
5
- export const StyledAppBar = styled(MuiAppBar, {
6
- shouldForwardProp: (prop) => prop !== "open",
7
- })<MuiAppBarProps & { open?: boolean }>(({ theme, open }) => ({
8
- background: theme.palette.app.color.iron[600],
9
- boxShadow: "unset",
10
- zIndex: theme.zIndex.drawer + 1,
11
- transition: theme.transitions.create(["width", "margin"], {
12
- easing: theme.transitions.easing.sharp,
13
- duration: theme.transitions.duration.leavingScreen,
14
- }),
15
- marginLeft: "80px",
16
- width: "calc(100% - 80px)",
17
- ...(open && {
18
- marginLeft: "300px",
19
- width: "calc(100% - 300px)",
20
- transition: theme.transitions.create(["width", "margin"], {
21
- easing: theme.transitions.easing.sharp,
22
- duration: theme.transitions.duration.enteringScreen,
23
- }),
24
- }),
25
- }));
@@ -1,20 +0,0 @@
1
- "use client";
2
-
3
- import { Toolbar } from "@mui/material";
4
- import type { PropsWithChildren } from "react";
5
- import { StyledAppBar } from "./AppBar.styled";
6
-
7
- export type AppBarProps = {
8
- drawerOpen: boolean;
9
- };
10
-
11
- export const AppBar = ({
12
- drawerOpen,
13
- children,
14
- }: PropsWithChildren<AppBarProps>) => {
15
- return (
16
- <StyledAppBar position="fixed" open={drawerOpen}>
17
- <Toolbar>{children}</Toolbar>
18
- </StyledAppBar>
19
- );
20
- };
@@ -1 +0,0 @@
1
- export { AppBar } from "./AppBar";
@@ -1,76 +0,0 @@
1
- import {
2
- Box,
3
- IconButton,
4
- Link,
5
- Breadcrumbs as MuiBreadcrumbs,
6
- Typography,
7
- useTheme,
8
- } from "@mui/material";
9
- import type { ReactNode } from "react";
10
- import { v4 as uuidv4 } from "uuid";
11
-
12
- type BreadcrumbItem = {
13
- icon?: ReactNode;
14
- text?: string;
15
- onClick?: () => void;
16
- };
17
-
18
- type BreadcrumbProps = {
19
- items: BreadcrumbItem[];
20
- };
21
-
22
- export const Breadcrumbs = ({ items }: BreadcrumbProps) => {
23
- const theme = useTheme();
24
-
25
- const { butterflyBlue } = theme.palette.app.color;
26
-
27
- return (
28
- <MuiBreadcrumbs>
29
- {items.map((item) => {
30
- const { icon, text, onClick } = item;
31
-
32
- if (onClick) {
33
- return (
34
- <Link
35
- key={uuidv4()}
36
- underline="hover"
37
- sx={{ display: "flex", alignItems: "center" }}
38
- onClick={(e) => {
39
- e.preventDefault();
40
-
41
- onClick();
42
- }}
43
- href="#"
44
- >
45
- {icon && (
46
- <IconButton
47
- sx={{
48
- color: butterflyBlue[900],
49
- }}
50
- >
51
- {icon}
52
- </IconButton>
53
- )}
54
- {text && <Typography>{text}</Typography>}
55
- </Link>
56
- );
57
- }
58
-
59
- return (
60
- <Box key={uuidv4()}>
61
- {icon && (
62
- <IconButton
63
- sx={{
64
- color: butterflyBlue[900],
65
- }}
66
- >
67
- {icon}
68
- </IconButton>
69
- )}
70
- {text && <Typography>{text}</Typography>}
71
- </Box>
72
- );
73
- })}
74
- </MuiBreadcrumbs>
75
- );
76
- };
@@ -1 +0,0 @@
1
- export * from "./Breadcrumbs";
@@ -1,38 +0,0 @@
1
- import ExpandMoreRoundedIcon from "@mui/icons-material/ExpandMoreRounded";
2
- import type { ButtonProps as MuiButtonProps } from "@mui/material";
3
- import {
4
- Button,
5
- CircularProgress,
6
- Divider,
7
- Stack,
8
- useTheme,
9
- } from "@mui/material";
10
- export type ActionButtonProps = MuiButtonProps & {
11
- loading?: boolean;
12
- };
13
-
14
- export const ActionButton = ({
15
- loading = false,
16
- children,
17
- ...rest
18
- }: ActionButtonProps) => {
19
- const theme = useTheme();
20
-
21
- const { lightBlue } = theme.palette.app.color;
22
-
23
- return (
24
- <Button {...rest}>
25
- <Stack gap="10px" flexDirection="row" alignItems="center">
26
- {loading ? <CircularProgress size={28} /> : children}
27
- <Divider
28
- orientation="vertical"
29
- sx={{
30
- borderColor: lightBlue[100],
31
- height: "22px",
32
- }}
33
- />
34
- <ExpandMoreRoundedIcon fontSize="small" />
35
- </Stack>
36
- </Button>
37
- );
38
- };
@@ -1,19 +0,0 @@
1
- import type { ButtonProps as MuiButtonProps } from "@mui/material";
2
- import { CircularProgress, Button as MuiButton } from "@mui/material";
3
-
4
- export type ButtonProps = MuiButtonProps & {
5
- loading?: boolean;
6
- };
7
-
8
- export const Button = ({
9
- loading = false,
10
- children,
11
- disabled = false,
12
- ...rest
13
- }: ButtonProps) => {
14
- return (
15
- <MuiButton disabled={loading || disabled} {...rest}>
16
- {loading ? <CircularProgress size={28} /> : children}
17
- </MuiButton>
18
- );
19
- };
@@ -1,37 +0,0 @@
1
- import { ButtonGroup as MuiButtonGroup } from "@mui/material";
2
- import { isFunction } from "lodash";
3
- import type { ReactNode } from "react";
4
- import { Button } from "./Button";
5
-
6
- type ButtonObject = {
7
- icon: ReactNode;
8
- value: string;
9
- label: string;
10
- selected: boolean;
11
- onClick: (value: string) => void;
12
- };
13
-
14
- type ButtonGroupProps = {
15
- renderButtons: ButtonObject[];
16
- };
17
-
18
- export const ButtonGroup = ({ renderButtons }: ButtonGroupProps) => {
19
- return (
20
- <MuiButtonGroup sx={{ boxShadow: "none" }} aria-label="Basic button group">
21
- {renderButtons?.map(({ icon, value, label, selected, onClick }) => (
22
- <Button
23
- variant={!selected ? "outlined" : "contained"}
24
- key={value}
25
- onClick={() => {
26
- if (isFunction(onClick)) {
27
- onClick(value);
28
- }
29
- }}
30
- startIcon={icon}
31
- >
32
- {label}
33
- </Button>
34
- ))}
35
- </MuiButtonGroup>
36
- );
37
- };
@@ -1,3 +0,0 @@
1
- export * from "./ActionButton";
2
- export * from "./Button";
3
- export * from "./ButtonGroup";