@tap-payments/os-micro-frontend-shared 0.1.96-test.2 → 0.1.96-test.21

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 (136) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +12 -12
  3. package/build/components/ActionMenu/style.d.ts +1 -1
  4. package/build/components/AmountStatusChip/AmountStatusChip.d.ts +9 -0
  5. package/build/components/AmountStatusChip/AmountStatusChip.js +19 -0
  6. package/build/components/AmountStatusChip/index.d.ts +3 -0
  7. package/build/components/AmountStatusChip/index.js +2 -0
  8. package/build/components/AmountStatusChip/style.d.ts +3 -0
  9. package/build/components/AmountStatusChip/style.js +13 -0
  10. package/build/components/AppServices/AppServices.d.ts +10 -5
  11. package/build/components/AppServices/AppServices.js +16 -18
  12. package/build/components/AppServices/ServiceItem.d.ts +2 -4
  13. package/build/components/AppServices/ServiceItem.js +2 -4
  14. package/build/components/AppServicesBar/AppServicesBar.d.ts +22 -0
  15. package/build/components/AppServicesBar/AppServicesBar.js +18 -0
  16. package/build/components/AppServicesBar/index.d.ts +3 -0
  17. package/build/components/AppServicesBar/index.js +3 -0
  18. package/build/components/AppServicesBar/style.d.ts +4 -0
  19. package/build/components/AppServicesBar/style.js +6 -0
  20. package/build/components/AppWindowWrapper/headers/AccountHeader/components/AccountHeaderTitle/AccountHeaderTitle.d.ts +1 -1
  21. package/build/components/AppWindowWrapper/headers/AccountHeader/components/AccountHeaderTitle/AccountHeaderTitle.js +1 -1
  22. package/build/components/AppWindowWrapper/headers/AppWindowHeader/AppWindowHeaderBase.d.ts +1 -1
  23. package/build/components/AppWindowWrapper/headers/AppWindowHeader/AppWindowHeaderBase.js +2 -2
  24. package/build/components/AuthenticationTypeChip/AuthenticationTypeChip.d.ts +9 -0
  25. package/build/components/AuthenticationTypeChip/AuthenticationTypeChip.js +21 -0
  26. package/build/components/AuthenticationTypeChip/constants.d.ts +16 -0
  27. package/build/components/AuthenticationTypeChip/constants.js +13 -0
  28. package/build/components/AuthenticationTypeChip/index.d.ts +3 -0
  29. package/build/components/AuthenticationTypeChip/index.js +2 -0
  30. package/build/components/ColorPicker/ColorPicker.d.ts +4 -1
  31. package/build/components/ColorPicker/ColorPicker.js +10 -43
  32. package/build/components/ColorPicker/ColorPickerPanel.d.ts +7 -0
  33. package/build/components/ColorPicker/ColorPickerPanel.js +41 -0
  34. package/build/components/ColorPicker/ColorSchemeSelect.d.ts +7 -0
  35. package/build/components/ColorPicker/ColorSchemeSelect.js +35 -0
  36. package/build/components/ColorPicker/HexaFields.d.ts +7 -0
  37. package/build/components/ColorPicker/HexaFields.js +79 -0
  38. package/build/components/ColorPicker/RGBAFields.d.ts +7 -0
  39. package/build/components/ColorPicker/RGBAFields.js +25 -0
  40. package/build/components/ColorPicker/style.d.ts +20 -9
  41. package/build/components/ColorPicker/style.js +49 -2
  42. package/build/components/JSONViewer/components/JSONTitleBar/JSONTitleBar.d.ts +1 -1
  43. package/build/components/JSONViewer/components/JSONTitleBar/JSONTitleBar.js +1 -1
  44. package/build/components/ListLayout/ListLayout.d.ts +10 -0
  45. package/build/components/ListLayout/ListLayout.js +20 -0
  46. package/build/components/ListLayout/index.d.ts +2 -0
  47. package/build/components/ListLayout/index.js +2 -0
  48. package/build/components/ListLayout/styles.d.ts +4 -0
  49. package/build/components/ListLayout/styles.js +9 -0
  50. package/build/components/RightLeftExpandingCenterChip/style.js +0 -2
  51. package/build/components/SearchButton/styles.d.ts +1 -1
  52. package/build/components/StatusChip/StatusChip.d.ts +1 -1
  53. package/build/components/StatusChip/StatusChip.js +13 -10
  54. package/build/components/StatusChip/style.d.ts +4 -0
  55. package/build/components/StatusChip/style.js +13 -5
  56. package/build/components/StatusChip/type.d.ts +4 -0
  57. package/build/components/StatusChipWithCopy/StatusChipWithCopy.d.ts +2 -1
  58. package/build/components/StatusChipWithCopy/StatusChipWithCopy.js +2 -2
  59. package/build/components/StatusIcons/AuthorizationAutoIcons/style.js +1 -1
  60. package/build/components/TableCells/CustomCells/ActionCell/constant.d.ts +1 -0
  61. package/build/components/TableCells/CustomCells/ActionCell/constant.js +2 -1
  62. package/build/components/TableCells/CustomCells/ActionCell/hooks/useActionCell.d.ts +1 -1
  63. package/build/components/TableCells/CustomCells/ActionCell/style.d.ts +1 -1
  64. package/build/components/TableCells/CustomCells/ApplicationStatusCell/ApplicationStatusCell.js +4 -4
  65. package/build/components/TableCells/CustomCells/BalanceCell/style.js +1 -1
  66. package/build/components/TableCells/CustomCells/ProductsCell/style.js +1 -1
  67. package/build/components/TableCells/CustomCells/RefundChargeCell/style.js +1 -1
  68. package/build/components/TableCells/CustomCells/RefundStatusCell/style.js +1 -1
  69. package/build/components/TableCells/CustomCells/style.js +1 -1
  70. package/build/components/TableCells/SheetViewCells/PaymentAgreementCell/PaymentAgreementCell.d.ts +13 -0
  71. package/build/components/TableCells/SheetViewCells/PaymentAgreementCell/PaymentAgreementCell.js +26 -0
  72. package/build/components/TableCells/SheetViewCells/PaymentAgreementCell/index.d.ts +1 -0
  73. package/build/components/TableCells/SheetViewCells/PaymentAgreementCell/index.js +1 -0
  74. package/build/components/TableCells/SheetViewCells/index.d.ts +1 -0
  75. package/build/components/TableCells/SheetViewCells/index.js +1 -0
  76. package/build/components/TableCells/index.d.ts +1 -0
  77. package/build/components/TableCells/index.js +1 -0
  78. package/build/components/ToggleView/ToggleView.d.ts +16 -0
  79. package/build/components/ToggleView/ToggleView.js +32 -0
  80. package/build/components/ToggleView/ToggleWrapper.d.ts +4 -0
  81. package/build/components/ToggleView/ToggleWrapper.js +8 -0
  82. package/build/components/ToggleView/index.d.ts +3 -0
  83. package/build/components/ToggleView/index.js +3 -0
  84. package/build/components/ToggleView/style.d.ts +14 -0
  85. package/build/components/ToggleView/style.js +31 -0
  86. package/build/components/ToggleView/types.d.ts +6 -0
  87. package/build/components/ToggleView/types.js +6 -0
  88. package/build/components/Toolbar/style.d.ts +5 -2
  89. package/build/components/Toolbar/style.js +6 -1
  90. package/build/components/VirtualTables/SheetViewVirtualTable/SheetViewVirtualTable.d.ts +1 -1
  91. package/build/components/VirtualTables/SheetViewVirtualTable/SheetViewVirtualTable.js +2 -2
  92. package/build/components/VirtualTables/SheetViewVirtualTable/components/LoadingMainTable.js +2 -0
  93. package/build/components/VirtualTables/SheetViewVirtualTable/components/MainTable.js +5 -1
  94. package/build/components/VirtualTables/SheetViewVirtualTable/components/PinnedColumn.js +5 -1
  95. package/build/components/VirtualTables/SheetViewVirtualTable/components/SheetViewTableLoading.d.ts +1 -4
  96. package/build/components/VirtualTables/SheetViewVirtualTable/components/SheetViewTableLoading.js +39 -7
  97. package/build/components/VirtualTables/VirtualTable/VirtualTable.d.ts +1 -1
  98. package/build/components/VirtualTables/VirtualTable/VirtualTable.js +2 -2
  99. package/build/components/VirtualTables/VirtualTableWithCard/VirtualTableWithCard.d.ts +1 -1
  100. package/build/components/VirtualTables/VirtualTableWithCard/VirtualTableWithCard.js +2 -2
  101. package/build/components/VirtualTables/components/TableRow.js +2 -1
  102. package/build/components/Window/Window.d.ts +2 -1
  103. package/build/components/Window/Window.js +2 -2
  104. package/build/components/Window/style.d.ts +1 -0
  105. package/build/components/Window/style.js +1 -1
  106. package/build/components/index.d.ts +8 -0
  107. package/build/components/index.js +8 -0
  108. package/build/constants/apps.d.ts +41 -0
  109. package/build/constants/apps.js +19 -2
  110. package/build/constants/chips/index.d.ts +1 -0
  111. package/build/constants/chips/index.js +1 -0
  112. package/build/{components/StatusChip/constants.d.ts → constants/chips/statusChips.d.ts} +1 -1
  113. package/build/{components/StatusChip/constants.js → constants/chips/statusChips.js} +1 -1
  114. package/build/constants/index.d.ts +1 -0
  115. package/build/constants/index.js +1 -0
  116. package/build/constants/table/cell/authenticationsTableCellWidth.d.ts +1 -1
  117. package/build/constants/table/cell/authenticationsTableCellWidth.js +1 -1
  118. package/build/constants/table/cell/authorizationTableCellWidth.d.ts +4 -4
  119. package/build/constants/table/cell/authorizationTableCellWidth.js +4 -4
  120. package/build/constants/table/cell/chargeTableCellWidth.d.ts +3 -3
  121. package/build/constants/table/cell/chargeTableCellWidth.js +3 -3
  122. package/build/constants/table/cell/destinationsTableCellWidth.d.ts +3 -3
  123. package/build/constants/table/cell/destinationsTableCellWidth.js +3 -3
  124. package/build/constants/table/cell/merchantsTableCellWidth.d.ts +1 -1
  125. package/build/constants/table/cell/merchantsTableCellWidth.js +1 -1
  126. package/build/constants/table/cell/refundTableCellWidth.d.ts +3 -3
  127. package/build/constants/table/cell/refundTableCellWidth.js +3 -3
  128. package/build/types/apps.d.ts +50 -1
  129. package/build/types/table.d.ts +1 -1
  130. package/build/utils/color.d.ts +11 -0
  131. package/build/utils/color.js +27 -0
  132. package/build/utils/object.d.ts +1 -0
  133. package/build/utils/object.js +4 -3
  134. package/build/utils/table.d.ts +3 -6
  135. package/build/utils/table.js +6 -32
  136. package/package.json +29 -2
@@ -73,38 +73,12 @@ export const isHeightNotFullyFilledByRows = (totalRows) => {
73
73
  const allowedRows = maxRowsThatFit();
74
74
  return totalRows < allowedRows + 1;
75
75
  };
76
- export const calculateSheetViewHeight = (totalRows, rowHeight = TABLE_CONTENT_ROW_HEIGHT) => {
77
- const headerHeight = 56;
78
- const padding = 16;
79
- const calculatedHeight = headerHeight + totalRows * rowHeight + padding;
80
- const minHeight = 200;
81
- const maxHeight = window.innerHeight * 0.8;
82
- return Math.max(minHeight, Math.min(calculatedHeight, maxHeight));
83
- };
84
- export const calculateSheetViewMaxRows = (availableHeight, rowHeight = TABLE_CONTENT_ROW_HEIGHT) => {
85
- const headerHeight = 56;
86
- const padding = 16;
87
- const availableContentHeight = availableHeight - headerHeight - padding;
88
- return Math.floor(availableContentHeight / rowHeight);
89
- };
90
- export const isSheetViewScrollable = (totalRows, containerHeight, rowHeight = TABLE_CONTENT_ROW_HEIGHT) => {
91
- const headerHeight = 56;
92
- const padding = 16;
93
- const contentHeight = headerHeight + totalRows * rowHeight + padding;
94
- return contentHeight > containerHeight;
95
- };
96
- export const getSheetViewRowHeight = () => {
97
- const baseRowHeight = TABLE_CONTENT_ROW_HEIGHT;
98
- return baseRowHeight * 0.8;
76
+ export const isTableDefaultMode = (tableMode) => {
77
+ return tableMode === 'default';
99
78
  };
100
- export const calculateSheetViewOptimalHeight = (totalRows, tableType, maxHeightPercentage = 0.8) => {
101
- const rowHeight = getSheetViewRowHeight();
102
- const headerHeight = 56;
103
- const padding = 16;
104
- const calculatedHeight = headerHeight + totalRows * rowHeight + padding;
105
- const maxHeight = window.innerHeight * maxHeightPercentage;
106
- return Math.min(calculatedHeight, maxHeight);
79
+ export const isTableSheetMode = (tableMode) => {
80
+ return tableMode === 'sheet';
107
81
  };
108
- export const isTableDefaultMode = (tableMode = 'default') => {
109
- return tableMode === 'default';
82
+ export const isTableTextMode = (tableMode) => {
83
+ return tableMode === 'text';
110
84
  };
package/package.json CHANGED
@@ -1,13 +1,14 @@
1
1
  {
2
2
  "name": "@tap-payments/os-micro-frontend-shared",
3
3
  "description": "Shared components and utilities for Tap Payments micro frontends",
4
- "version": "0.1.96-test.2",
5
- "testVersion": 2,
4
+ "version": "0.1.96-test.21",
5
+ "testVersion": 21,
6
6
  "type": "module",
7
7
  "main": "build/index.js",
8
8
  "module": "build/index.js",
9
9
  "types": "build/index.d.ts",
10
10
  "exports": {
11
+ "./package.json": "./package.json",
11
12
  ".": {
12
13
  "types": "./build/index.d.ts",
13
14
  "import": "./build/index.js",
@@ -127,6 +128,32 @@
127
128
  "vite": "6.0.5",
128
129
  "vite-tsconfig-paths": "^4.2.0"
129
130
  },
131
+ "peerDependencies": {
132
+ "react": "^18",
133
+ "react-dom": "^18",
134
+ "@mui/material": "^5",
135
+ "@emotion/react": "^11",
136
+ "@emotion/styled": "^11",
137
+ "framer-motion": "^10",
138
+ "react-hook-form": "^7",
139
+ "@hookform/resolvers": "^3",
140
+ "react-router-dom": "^7",
141
+ "i18next": "^22",
142
+ "react-i18next": "^12",
143
+ "react-multi-date-picker": "^4",
144
+ "dayjs": "^1",
145
+ "react-dropzone": "^14",
146
+ "react-hot-toast": "^2",
147
+ "recharts": "^2",
148
+ "react-window": "^1.8",
149
+ "react-window-infinite-loader": "^1",
150
+ "react-virtualized-auto-sizer": "^1",
151
+ "re-resizable": "^6",
152
+ "react-draggable": "^4",
153
+ "react-currency-input-field": "^3",
154
+ "react18-input-otp": "^1",
155
+ "@uiw/react-json-view": "^2.0.0-alpha"
156
+ },
130
157
  "lint-staged": {
131
158
  "src/**/*.{ts,tsx,json,js,jsx}": [
132
159
  "yarn run prettier:fix",