@tap-payments/os-micro-frontend-shared 0.0.140 → 0.0.142
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.
- package/LICENSE +21 -21
- package/README.md +12 -12
- package/build/components/SearchButton/styles.d.ts +1 -1
- package/build/components/StatusChip/style.js +1 -1
- package/build/components/StatusIcons/AuthorizedIcon/AuthorizedIcon.js +1 -1
- package/build/components/StatusIcons/ChargeStatusIcon/ChargeStatusIcon.d.ts +3 -1
- package/build/components/StatusIcons/ChargeStatusIcon/ChargeStatusIcon.js +7 -2
- package/build/components/StatusIcons/PayoutIcon/PayoutIcon.d.ts +3 -1
- package/build/components/StatusIcons/PayoutIcon/PayoutIcon.js +7 -2
- package/build/components/TableCells/CustomCells/ActionCell/style.d.ts +1 -1
- package/build/components/TableCells/CustomCells/AmountCell/AmountCell.d.ts +1 -1
- package/build/components/TableCells/CustomCells/AmountCell/AmountCell.js +2 -2
- package/build/components/TableCells/CustomCells/AmountCell/style.d.ts +7 -2
- package/build/components/TableCells/CustomCells/AmountCell/style.js +4 -4
- package/build/components/TableCells/CustomCells/CustomerCell/CustomerCell.d.ts +1 -1
- package/build/components/TableCells/CustomCells/CustomerCell/CustomerCell.js +4 -1
- package/build/components/TableCells/CustomCells/CustomerCell/style.d.ts +4 -1
- package/build/components/TableCells/CustomCells/CustomerCell/style.js +3 -7
- package/build/components/TableCells/CustomCells/DateCell/DateCell.d.ts +1 -1
- package/build/components/TableCells/CustomCells/DateCell/DateCell.js +3 -2
- package/build/components/TableCells/CustomCells/OrderCell/OrderCell.d.ts +1 -1
- package/build/components/TableCells/CustomCells/OrderCell/OrderCell.js +4 -1
- package/build/components/TableCells/CustomCells/ReceiptCell/ReceiptCell.js +2 -2
- package/build/components/TableCells/CustomCells/ReferenceCell/ReferenceCell.js +21 -2
- package/build/components/TableCells/CustomCells/ReferenceCell/constant.d.ts +5 -0
- package/build/components/TableCells/CustomCells/ReferenceCell/constant.js +9 -0
- package/build/components/TableCells/CustomCells/ReferenceCell/style.d.ts +1 -0
- package/build/components/TableCells/CustomCells/ReferenceCell/style.js +3 -0
- package/build/components/TableCells/CustomCells/SalesChannelCell/style.js +1 -1
- package/build/components/TableCells/CustomCells/SheetViewIDButton/SheetViewIDButton.js +1 -1
- package/build/components/TableCells/CustomCells/SourceMergedCell/SourceMergedCell.js +2 -18
- package/build/components/TableCells/CustomCells/SourceMergedCell/style.d.ts +4 -1
- package/build/components/TableCells/CustomCells/SourceMergedCell/style.js +19 -0
- package/build/components/TableCells/CustomCells/StatusCell/constant.d.ts +29 -0
- package/build/components/TableCells/CustomCells/StatusCell/constant.js +29 -0
- package/build/components/TableCells/CustomCells/StatusCell/style.d.ts +1 -1
- package/build/components/TableCells/CustomCells/type.d.ts +4 -0
- package/build/components/VirtualTable/components/TableRowLoading.js +1 -0
- package/build/components/VirtualTable/style.d.ts +1 -1
- package/build/constants/table/cell/chargeTableCellWidth.d.ts +5 -5
- package/build/constants/table/cell/chargeTableCellWidth.js +5 -5
- package/package.json +132 -132
package/LICENSE
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2025 Tap Payments
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2025 Tap Payments
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
# os-micro-frontend-shared
|
|
2
|
-
|
|
3
|
-
## Publishing Workflow
|
|
4
|
-
|
|
5
|
-
1. Update version in package.json
|
|
6
|
-
2. Commit changes
|
|
7
|
-
3. Create and push a tag:
|
|
8
|
-
|
|
9
|
-
```bash
|
|
10
|
-
npm version patch # or minor, major
|
|
11
|
-
git push origin main --tags
|
|
12
|
-
```
|
|
1
|
+
# os-micro-frontend-shared
|
|
2
|
+
|
|
3
|
+
## Publishing Workflow
|
|
4
|
+
|
|
5
|
+
1. Update version in package.json
|
|
6
|
+
2. Commit changes
|
|
7
|
+
3. Create and push a tag:
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
npm version patch # or minor, major
|
|
11
|
+
git push origin main --tags
|
|
12
|
+
```
|
|
@@ -554,9 +554,9 @@ export declare const Icon: import("@emotion/styled").StyledComponent<{
|
|
|
554
554
|
onAnimationIterationCapture?: import("react").AnimationEventHandler<HTMLImageElement> | undefined;
|
|
555
555
|
onTransitionEnd?: import("react").TransitionEventHandler<HTMLImageElement> | undefined;
|
|
556
556
|
onTransitionEndCapture?: import("react").TransitionEventHandler<HTMLImageElement> | undefined;
|
|
557
|
+
referrerPolicy?: import("react").HTMLAttributeReferrerPolicy | undefined;
|
|
557
558
|
src?: string | undefined;
|
|
558
559
|
alt?: string | undefined;
|
|
559
|
-
referrerPolicy?: import("react").HTMLAttributeReferrerPolicy | undefined;
|
|
560
560
|
crossOrigin?: "" | "anonymous" | "use-credentials" | undefined;
|
|
561
561
|
useMap?: string | undefined;
|
|
562
562
|
loading?: "eager" | "lazy" | undefined;
|
|
@@ -18,7 +18,7 @@ export const ChipStyled = styled(Box)((_a) => {
|
|
|
18
18
|
alignItems: 'center',
|
|
19
19
|
justifyContent: 'center',
|
|
20
20
|
height: '18px',
|
|
21
|
-
padding: padding || `${theme.spacing(0.
|
|
21
|
+
padding: padding || `${theme.spacing(0.5)} ${theme.spacing(1.5)}`,
|
|
22
22
|
borderRadius: '30px',
|
|
23
23
|
border: `1px solid ${borderColor}`,
|
|
24
24
|
backgroundColor: bgColor,
|
|
@@ -9,7 +9,7 @@ import { TextLabel } from '../../TableCells/CustomCells/style';
|
|
|
9
9
|
export const AuthorizedIcon = ({ authorizedStatus, isTextShown, iconStyles, tableMode }) => {
|
|
10
10
|
const { t } = useTranslation();
|
|
11
11
|
const theme = useTheme();
|
|
12
|
-
return (_jsx(Tooltip, Object.assign({ title: t(camelCase(authorizedStatus)) }, { children: isTextShown ? (_jsx(TextLabel, Object.assign({ "data-testid": "StatusCell_AuthorizedStatusLabel", sx: Object.assign({ color: theme.palette.info.dark }, (tableMode === 'sheet' && {
|
|
12
|
+
return (_jsx(Tooltip, Object.assign({ title: tableMode === 'sheet' ? '' : t(camelCase(authorizedStatus)) }, { children: isTextShown ? (_jsx(TextLabel, Object.assign({ "data-testid": "StatusCell_AuthorizedStatusLabel", sx: Object.assign({ color: theme.palette.info.dark }, (tableMode === 'sheet' && {
|
|
13
13
|
height: '18px',
|
|
14
14
|
})) }, { children: t(camelCase(authorizedStatus)) }))) : (_jsx(Icon, { src: authorizedStatusIcons[authorizedStatus], alt: "authorized-icon", "data-testid": "StatusCell_AuthorizedStatusIcon", sx: iconStyles })) })));
|
|
15
15
|
};
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { CSSProperties } from 'react';
|
|
2
2
|
import { type ChargeStatus } from '../../TableCells';
|
|
3
|
-
|
|
3
|
+
import { TableMode } from '../../../types/index.js';
|
|
4
|
+
export declare function ChargeStatusIcon({ chargeStatus, gatewayTooltip, acquirerTooltip, chargeTooltip, errorCode, isTextShown, gatewayCode, acquirerCode, unCapturedStyles, iconStyles, iconWrapperStyles, gatewayIconWrapperStyles, gatewayContainerStyles, gateWayIconStyles, tableMode, showBadge, }: Readonly<{
|
|
4
5
|
chargeStatus?: ChargeStatus;
|
|
5
6
|
gatewayTooltip?: string;
|
|
6
7
|
showAuthorizedStatus?: boolean;
|
|
@@ -17,4 +18,5 @@ export declare function ChargeStatusIcon({ chargeStatus, gatewayTooltip, acquire
|
|
|
17
18
|
gatewayContainerStyles?: CSSProperties;
|
|
18
19
|
gateWayIconStyles?: CSSProperties;
|
|
19
20
|
showBadge?: boolean;
|
|
21
|
+
tableMode?: TableMode;
|
|
20
22
|
}>): import("react/jsx-runtime").JSX.Element;
|
|
@@ -5,17 +5,22 @@ import { useTranslation } from 'react-i18next';
|
|
|
5
5
|
import Tooltip from '../../Tooltip';
|
|
6
6
|
import { unCapturedStatuses } from '../../../constants/index.js';
|
|
7
7
|
import { AcquirerContainerAnimationVariants, ErrorCodeLabel, ErrorCodeLabelAnimationVariants, ErrorCodeVariants, ErrorCodeWrapper, GateWayIcon, GatewayIconWrapper, GatewayIconWrapperAnimationTransition, GatewaysContainer, GatewaysContainerAnimationVariants, StatusTextLabel, UnCapturedBadge, UnCapturedContainer, errorCodeLabelAnimation, TextViewWrapper, } from './style';
|
|
8
|
-
import { capturedStatusesStyles, unCapturedStatusesStyles, statusIcons } from '../../TableCells/CustomCells/StatusCell/constant';
|
|
8
|
+
import { capturedStatusesStyles, unCapturedStatusesStyles, statusIcons, sheetViewChipStyles, } from '../../TableCells/CustomCells/StatusCell/constant';
|
|
9
9
|
import { StatusIcon, StatusIconWrapper, TextLabel } from '../../TableCells/CustomCells/style';
|
|
10
|
-
|
|
10
|
+
import StatusChip from '../../StatusChip';
|
|
11
|
+
export function ChargeStatusIcon({ chargeStatus, gatewayTooltip, acquirerTooltip, chargeTooltip, errorCode, isTextShown, gatewayCode, acquirerCode, unCapturedStyles, iconStyles, iconWrapperStyles, gatewayIconWrapperStyles, gatewayContainerStyles, gateWayIconStyles, tableMode, showBadge = true, }) {
|
|
11
12
|
const unCapturedStatusStyle = chargeStatus ? unCapturedStatusesStyles[chargeStatus] : null;
|
|
12
13
|
const captureStatusStyle = chargeStatus ? capturedStatusesStyles[chargeStatus] : null;
|
|
14
|
+
const sheetViewStatusStyle = chargeStatus ? sheetViewChipStyles[chargeStatus] : null;
|
|
13
15
|
const theme = useTheme();
|
|
14
16
|
const { t } = useTranslation();
|
|
15
17
|
const chargeTooltipTitle = chargeTooltip && (_jsx(_Fragment, { children: _jsx("div", { children: chargeTooltip }) }));
|
|
16
18
|
const acquirerTooltipTitle = acquirerTooltip && (_jsxs(_Fragment, { children: [_jsx("div", { children: "Acquirer" }), _jsx("div", { children: acquirerTooltip })] }));
|
|
17
19
|
const gatewayTooltipTitle = gatewayTooltip && (_jsxs(_Fragment, { children: [_jsx("div", { children: "Gateway" }), _jsx("div", { children: gatewayTooltip })] }));
|
|
18
20
|
const chargeIcon = chargeStatus && statusIcons[chargeStatus] && (_jsx("div", Object.assign({ "data-testid": "ChargeStatusIcon_ChargeIcon", style: Object.assign({ display: 'flex', alignItems: 'center', justifyContent: 'center', width: '16px', height: '16px', borderRadius: unCapturedStatusStyle ? '50%' : '' }, iconWrapperStyles) }, { children: _jsx(StatusIcon, { src: statusIcons[chargeStatus], alt: "charge-icon", "data-testid": "ChargeStatusIcon_StatusIcon", style: Object.assign({ borderRadius: unCapturedStatusStyle ? '50%' : '', width: '16px', height: '16px' }, iconStyles) }) })));
|
|
21
|
+
if (tableMode === 'sheet') {
|
|
22
|
+
return _jsx(StatusChip, Object.assign({ sx: Object.assign({}, sheetViewStatusStyle) }, { children: t(camelCase(chargeStatus)) }));
|
|
23
|
+
}
|
|
19
24
|
if (isTextShown) {
|
|
20
25
|
return (_jsxs(TextViewWrapper, { children: [_jsx(Tooltip, Object.assign({ title: chargeTooltipTitle }, { children: _jsxs(StatusTextLabel, Object.assign({ "data-testid": "ChargeStatusIcon_isTextShown", "data-status": camelCase(chargeStatus), sx: {
|
|
21
26
|
background: (unCapturedStatusStyle === null || unCapturedStatusStyle === void 0 ? void 0 : unCapturedStatusStyle.background) || (captureStatusStyle === null || captureStatusStyle === void 0 ? void 0 : captureStatusStyle.background) || 'transparent',
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { PayoutStatusType } from '../../TableCells';
|
|
3
|
+
import { TableMode } from '../../../types/index.js';
|
|
3
4
|
type PayoutIconProps = {
|
|
4
5
|
iconStyles?: React.CSSProperties;
|
|
5
6
|
payoutStatus?: PayoutStatusType;
|
|
6
7
|
payoutTooltip?: React.ReactNode;
|
|
7
8
|
isTextShown?: boolean;
|
|
9
|
+
tableMode?: TableMode;
|
|
8
10
|
};
|
|
9
|
-
export declare const PayoutIcon: ({ payoutStatus, isTextShown, payoutTooltip, iconStyles }: PayoutIconProps) => import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export declare const PayoutIcon: ({ payoutStatus, tableMode, isTextShown, payoutTooltip, iconStyles }: PayoutIconProps) => import("react/jsx-runtime").JSX.Element;
|
|
10
12
|
export {};
|
|
@@ -4,9 +4,14 @@ import { useTranslation } from 'react-i18next';
|
|
|
4
4
|
import Tooltip from '../../Tooltip';
|
|
5
5
|
import { StatusIcon } from '../../TableCells/CustomCells/style';
|
|
6
6
|
import { StatusTextLabel } from '../../TableCells/CustomCells/InvoiceStatusCell/style';
|
|
7
|
-
import { payoutStatusIcons } from '../../TableCells/CustomCells/StatusCell/constant';
|
|
8
|
-
|
|
7
|
+
import { payoutStatusIcons, payoutStatusStyles } from '../../TableCells/CustomCells/StatusCell/constant';
|
|
8
|
+
import { StatusChip } from '../../index.js';
|
|
9
|
+
export const PayoutIcon = ({ payoutStatus = 'PENDING', tableMode, isTextShown, payoutTooltip, iconStyles }) => {
|
|
9
10
|
const { t } = useTranslation();
|
|
11
|
+
const payoutStatusStyle = payoutStatusStyles[payoutStatus];
|
|
12
|
+
if (tableMode === 'sheet') {
|
|
13
|
+
return _jsx(StatusChip, Object.assign({ sx: Object.assign({}, payoutStatusStyle) }, { children: t(camelCase(payoutStatus)) }));
|
|
14
|
+
}
|
|
10
15
|
const title = payoutTooltip ? payoutTooltip : t(camelCase(payoutStatus));
|
|
11
16
|
return (_jsx(Tooltip, Object.assign({ title: title }, { children: isTextShown ? (_jsx(StatusTextLabel, Object.assign({ "data-testid": "StatusCell_PayoutStatusLabel" }, { children: t(camelCase(payoutStatus)) }))) : (_jsx(StatusIcon, { src: payoutStatusIcons[payoutStatus], alt: "settled-icon", "data-testid": "StatusCell_PayoutStatusIcon", style: iconStyles })) })));
|
|
12
17
|
};
|
|
@@ -272,9 +272,9 @@ export declare const ActionIcon: import("@emotion/styled").StyledComponent<{
|
|
|
272
272
|
onAnimationIterationCapture?: import("react").AnimationEventHandler<HTMLImageElement> | undefined;
|
|
273
273
|
onTransitionEnd?: import("react").TransitionEventHandler<HTMLImageElement> | undefined;
|
|
274
274
|
onTransitionEndCapture?: import("react").TransitionEventHandler<HTMLImageElement> | undefined;
|
|
275
|
+
referrerPolicy?: import("react").HTMLAttributeReferrerPolicy | undefined;
|
|
275
276
|
src?: string | undefined;
|
|
276
277
|
alt?: string | undefined;
|
|
277
|
-
referrerPolicy?: import("react").HTMLAttributeReferrerPolicy | undefined;
|
|
278
278
|
crossOrigin?: "" | "anonymous" | "use-credentials" | undefined;
|
|
279
279
|
useMap?: string | undefined;
|
|
280
280
|
loading?: "eager" | "lazy" | undefined;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { AmountCellProps } from '../type';
|
|
2
|
-
declare function AmountCell({ conversionType, amount, currency, tooltipLabel, amountTooltipLabel, isTextShown, ...props }: AmountCellProps): import("react/jsx-runtime").JSX.Element;
|
|
2
|
+
declare function AmountCell({ conversionType, amount, currency, tooltipLabel, amountTooltipLabel, isTextShown, tableMode, ...props }: AmountCellProps): import("react/jsx-runtime").JSX.Element;
|
|
3
3
|
export default AmountCell;
|
|
@@ -18,10 +18,10 @@ import { formatAmountWithCurrency } from '../../../../utils/index.js';
|
|
|
18
18
|
import { AmountCellContainer, ConversionBadge, CurrencySpan, DecimalSpan, FlagContainer } from './style';
|
|
19
19
|
import { FlagIcon } from '../style';
|
|
20
20
|
function AmountCell(_a) {
|
|
21
|
-
var { conversionType, amount, currency, tooltipLabel, amountTooltipLabel, isTextShown } = _a, props = __rest(_a, ["conversionType", "amount", "currency", "tooltipLabel", "amountTooltipLabel", "isTextShown"]);
|
|
21
|
+
var { conversionType, amount, currency, tooltipLabel, amountTooltipLabel, isTextShown, tableMode } = _a, props = __rest(_a, ["conversionType", "amount", "currency", "tooltipLabel", "amountTooltipLabel", "isTextShown", "tableMode"]);
|
|
22
22
|
const icon = currency && _jsx(FlagIcon, { src: getCurrenciesIcon(currency), alt: "customer icon" });
|
|
23
23
|
const { fullAmount } = formatAmountWithCurrency(amount, currency);
|
|
24
24
|
const [integerAmount, decimalAmount] = fullAmount.toString().split('.');
|
|
25
|
-
return (_jsx(TableCell, Object.assign({}, props, { children: _jsxs(AmountCellContainer, { children: [_jsx(Tooltip, Object.assign({ title: tooltipLabel || '' }, { children: conversionType && _jsx(ConversionBadge, Object.assign({ className: "conversion-type" }, { children: conversionType })) })), _jsx(Tooltip, Object.assign({ title: _jsx(CurrencyIcon, { currency: currency }) }, { children: isTextShown ? _jsx("span", {}) : _jsx(FlagContainer, { children: icon }) })), _jsx(Tooltip, Object.assign({ title: amountTooltipLabel }, { children: _jsx(CurrencySpan, { children: integerAmount && decimalAmount && amount !== undefined ? (_jsxs(_Fragment, { children: [_jsx("span", { children: _jsx(CurrencyIcon, { currency: currency, fontSize: 10 }) }), ' ', integerAmount, ".", _jsx(DecimalSpan, { children: decimalAmount })] })) : (_jsx("span", { children: "-" })) }) }))] }) })));
|
|
25
|
+
return (_jsx(TableCell, Object.assign({}, props, { children: _jsxs(AmountCellContainer, { children: [_jsx(Tooltip, Object.assign({ title: tooltipLabel || '' }, { children: conversionType && (_jsx(ConversionBadge, Object.assign({ tableMode: tableMode, className: "conversion-type" }, { children: conversionType }))) })), _jsx(Tooltip, Object.assign({ title: _jsx(CurrencyIcon, { currency: currency }) }, { children: isTextShown ? _jsx("span", {}) : _jsx(FlagContainer, { children: icon }) })), _jsx(Tooltip, Object.assign({ title: amountTooltipLabel }, { children: _jsx(CurrencySpan, Object.assign({ tableMode: tableMode }, { children: integerAmount && decimalAmount && amount !== undefined ? (_jsxs(_Fragment, { children: [_jsx("span", { children: _jsx(CurrencyIcon, { currency: currency, fontSize: 10 }) }), ' ', integerAmount, ".", _jsx(DecimalSpan, { children: decimalAmount })] })) : (_jsx("span", { children: "-" })) })) }))] }) })));
|
|
26
26
|
}
|
|
27
27
|
export default AmountCell;
|
|
@@ -1,8 +1,13 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
+
import { TableMode } from '../../../../types/index.js';
|
|
2
3
|
export declare const AmountCellContainer: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
3
|
-
export declare const ConversionBadge: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme
|
|
4
|
+
export declare const ConversionBadge: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme> & {
|
|
5
|
+
tableMode?: TableMode | undefined;
|
|
6
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
4
7
|
export declare const FlagContainer: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
5
|
-
export declare const CurrencySpan: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme
|
|
8
|
+
export declare const CurrencySpan: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme> & {
|
|
9
|
+
tableMode?: TableMode | undefined;
|
|
10
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
6
11
|
export declare const DecimalSpan: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
7
12
|
export declare const ConversionTooltip: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
8
13
|
export declare const ConversionTooltipRow: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme> & {
|
|
@@ -5,12 +5,12 @@ export const AmountCellContainer = styled('span')(({ theme }) => ({
|
|
|
5
5
|
justifyContent: 'flex-end',
|
|
6
6
|
gap: theme.spacing(1),
|
|
7
7
|
}));
|
|
8
|
-
export const ConversionBadge = styled('span')(({ theme }) => ({
|
|
8
|
+
export const ConversionBadge = styled('span')(({ theme, tableMode }) => ({
|
|
9
9
|
backgroundColor: theme.palette.grey[100],
|
|
10
10
|
display: 'block',
|
|
11
11
|
borderRadius: '4px',
|
|
12
12
|
padding: '1.5px 3px',
|
|
13
|
-
fontSize: '10px',
|
|
13
|
+
fontSize: tableMode === 'sheet' ? '11px' : '10px',
|
|
14
14
|
lineHeight: '13px',
|
|
15
15
|
textTransform: 'uppercase',
|
|
16
16
|
fontWeight: theme.typography.fontWeightBold,
|
|
@@ -21,8 +21,8 @@ export const FlagContainer = styled('span')(() => ({
|
|
|
21
21
|
height: '12px',
|
|
22
22
|
flexShrink: 0,
|
|
23
23
|
}));
|
|
24
|
-
export const CurrencySpan = styled('span')(({ theme }) => ({
|
|
25
|
-
fontSize: theme.typography.body2.fontSize,
|
|
24
|
+
export const CurrencySpan = styled('span')(({ theme, tableMode }) => ({
|
|
25
|
+
fontSize: tableMode === 'sheet' ? '11px' : theme.typography.body2.fontSize,
|
|
26
26
|
lineHeight: '17px',
|
|
27
27
|
fontWeight: '700',
|
|
28
28
|
}));
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import type { CustomerCellProps } from '../type';
|
|
2
|
-
declare function CustomerCell({ customerInitiated, children, isTimezoneIconShown, hasCustomerIcon, customerIcon, customerName, hideCustomerInitiatedIcon, hideTimezoneIcon, phone, email, id, ...props }: Readonly<CustomerCellProps>): import("react/jsx-runtime").JSX.Element;
|
|
2
|
+
declare function CustomerCell({ customerInitiated, children, isTimezoneIconShown, hasCustomerIcon, customerIcon, customerName, hideCustomerInitiatedIcon, hideTimezoneIcon, phone, email, id, tableMode, ...props }: Readonly<CustomerCellProps>): import("react/jsx-runtime").JSX.Element;
|
|
3
3
|
export default CustomerCell;
|
|
@@ -20,7 +20,7 @@ import { TableCell } from '../../../TableCells';
|
|
|
20
20
|
import { AvatarStyled, StarBadgeWrapper } from '../style';
|
|
21
21
|
function CustomerCell(_a) {
|
|
22
22
|
var _b;
|
|
23
|
-
var { customerInitiated, children, isTimezoneIconShown, hasCustomerIcon, customerIcon, customerName, hideCustomerInitiatedIcon, hideTimezoneIcon, phone, email, id } = _a, props = __rest(_a, ["customerInitiated", "children", "isTimezoneIconShown", "hasCustomerIcon", "customerIcon", "customerName", "hideCustomerInitiatedIcon", "hideTimezoneIcon", "phone", "email", "id"]);
|
|
23
|
+
var { customerInitiated, children, isTimezoneIconShown, hasCustomerIcon, customerIcon, customerName, hideCustomerInitiatedIcon, hideTimezoneIcon, phone, email, id, tableMode } = _a, props = __rest(_a, ["customerInitiated", "children", "isTimezoneIconShown", "hasCustomerIcon", "customerIcon", "customerName", "hideCustomerInitiatedIcon", "hideTimezoneIcon", "phone", "email", "id", "tableMode"]);
|
|
24
24
|
const { t } = useTranslation();
|
|
25
25
|
const customerInitiatedTooltip = customerInitiated === false ? t('merchantInitiated') : '';
|
|
26
26
|
const isArabicCustomerName = isArabic(customerName);
|
|
@@ -38,6 +38,9 @@ function CustomerCell(_a) {
|
|
|
38
38
|
return null;
|
|
39
39
|
return (_jsx("div", Object.assign({ "data-testid": "CustomerCell_customerTooltip" }, { children: tooltipOptions.map(({ name, value }) => value && (_jsx("div", Object.assign({ "data-testid": `CustomerCell_customerTooltip_${name}` }, { children: name === 'Name' ? value : `${name}: ${value}` }), value))) })));
|
|
40
40
|
}, [tooltipOptions]);
|
|
41
|
+
if (tableMode === 'sheet') {
|
|
42
|
+
return (_jsx(StyledCustomerName, Object.assign({ tableMode: tableMode, "data-testid": "CustomerCell_StyledCustomerName", "data-is-arabic": isArabicCustomerName }, { children: children })));
|
|
43
|
+
}
|
|
41
44
|
return (_jsx(TableCell, Object.assign({}, props, { "data-testid": "CustomerCell_TableCell" }, { children: _jsxs(StyledCustomerCell, Object.assign({ "data-testid": "CustomerCell_StyledCustomerCell" }, { children: [customerShownIcon, _jsx(Tooltip, Object.assign({ title: customerTooltip }, { children: _jsx(StyledCustomerName, Object.assign({ "data-testid": "CustomerCell_StyledCustomerName", "data-is-arabic": isArabicCustomerName }, { children: children })) })), !hideTimezoneIcon && (_jsx(StyledCustomerIconContainer, Object.assign({ "data-testid": "CustomerCell_StyledCustomerIconContainer" }, { children: isTimezoneIconShown && _jsx(StyledCustomerIcon, { src: timezoneIcon, "data-testid": "CustomerCell_StyledCustomerIcon" }) }))), !hideCustomerInitiatedIcon && (_jsx(Tooltip, Object.assign({ title: customerInitiatedTooltip }, { children: _jsx(StarBadgeWrapper, Object.assign({ "data-testid": "CustomerCell_StarBadgeWrapper", className: "geography-box", isShown: !!customerInitiatedTooltip }, { children: customerInitiatedTooltip && (_jsx("img", { "data-testid": "CustomerCell_merchantInitiatedIcon", src: merchantInitiatedIcon, alt: "merchant", style: {
|
|
42
45
|
width: '16px',
|
|
43
46
|
height: '16px',
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
+
import { TableMode } from '../../../../types/index.js';
|
|
2
3
|
export declare const StyledCustomerCell: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
3
|
-
export declare const StyledCustomerName: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme
|
|
4
|
+
export declare const StyledCustomerName: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme> & {
|
|
5
|
+
tableMode?: TableMode | undefined;
|
|
6
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
4
7
|
export declare const StyledCustomerIconContainer: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
5
8
|
export declare const StyledCustomerIcon: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>, {}>;
|
|
@@ -5,13 +5,9 @@ export const StyledCustomerCell = styled('span')(({ theme }) => ({
|
|
|
5
5
|
justifyContent: 'flex-start',
|
|
6
6
|
gap: theme.spacing(1),
|
|
7
7
|
}));
|
|
8
|
-
export const StyledCustomerName = styled('span'
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
whiteSpace: 'nowrap',
|
|
12
|
-
maxWidth: '25ch',
|
|
13
|
-
flex: 1,
|
|
14
|
-
});
|
|
8
|
+
export const StyledCustomerName = styled('span', {
|
|
9
|
+
shouldForwardProp: (prop) => prop !== 'tableMode',
|
|
10
|
+
})(({ theme, tableMode }) => (Object.assign({ overflow: 'hidden', textOverflow: 'ellipsis', whiteSpace: 'nowrap', maxWidth: '25ch', flex: 1 }, (tableMode === 'sheet' && { fontSize: '11px', color: theme.palette.text.primary }))));
|
|
15
11
|
export const StyledCustomerIconContainer = styled('span')({
|
|
16
12
|
width: '11.6px',
|
|
17
13
|
height: '11.6px',
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { DateCellProps } from '../type';
|
|
2
|
-
declare function DateCell({ value, format: dateFormat, flagIcon, hasFlag, ...props }: DateCellProps): import("react/jsx-runtime").JSX.Element;
|
|
2
|
+
declare function DateCell({ value, format: dateFormat, flagIcon, hasFlag, tableMode, ...props }: DateCellProps): import("react/jsx-runtime").JSX.Element;
|
|
3
3
|
export default DateCell;
|
|
@@ -17,12 +17,13 @@ import CountryFlag from '../../../CountryFlag';
|
|
|
17
17
|
import { formatCellDate, getCountryName } from '../../../../utils/index.js';
|
|
18
18
|
import { DateCellContainer } from './style';
|
|
19
19
|
import { GeographyBox } from '../style';
|
|
20
|
+
import { Box } from '@mui/material';
|
|
20
21
|
function DateCell(_a) {
|
|
21
|
-
var { value, format: dateFormat, flagIcon, hasFlag } = _a, props = __rest(_a, ["value", "format", "flagIcon", "hasFlag"]);
|
|
22
|
+
var { value, format: dateFormat, flagIcon, hasFlag, tableMode } = _a, props = __rest(_a, ["value", "format", "flagIcon", "hasFlag", "tableMode"]);
|
|
22
23
|
const icon = flagIcon && (_jsx(Tooltip, Object.assign({ title: getCountryName(flagIcon || '') }, { children: _jsx(CountryFlag, { code: flagIcon }) })));
|
|
23
24
|
const renderedValue = useMemo(() => formatCellDate(value, dateFormat), [value]);
|
|
24
25
|
return (_jsx(TableCell, Object.assign({}, props, { children: _jsxs(DateCellContainer, { children: [hasFlag && (_jsx(GeographyBox, Object.assign({ sx: {
|
|
25
26
|
visibility: 'visible',
|
|
26
|
-
}, className: "geography-box" }, { children: icon }))), renderedValue] }) })));
|
|
27
|
+
}, className: "geography-box" }, { children: icon }))), _jsx(Box, Object.assign({ sx: Object.assign({}, (tableMode === 'sheet' && { fontSize: '11px' })) }, { children: renderedValue }))] }) })));
|
|
27
28
|
}
|
|
28
29
|
export default DateCell;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { OrderCellProps } from '../type';
|
|
2
|
-
declare function OrderCell({ value, label, items, ...props }: OrderCellProps): import("react/jsx-runtime").JSX.Element;
|
|
2
|
+
declare function OrderCell({ value, label, items, tableMode, ...props }: OrderCellProps): import("react/jsx-runtime").JSX.Element;
|
|
3
3
|
export default OrderCell;
|
|
@@ -14,7 +14,7 @@ import { TableCell } from '../../../TableCells';
|
|
|
14
14
|
import Tooltip from '../../../Tooltip';
|
|
15
15
|
import { MAX_TOOLTIP_ITEM_LENGTH } from './constant';
|
|
16
16
|
function OrderCell(_a) {
|
|
17
|
-
var { value, label, items } = _a, props = __rest(_a, ["value", "label", "items"]);
|
|
17
|
+
var { value, label, items, tableMode } = _a, props = __rest(_a, ["value", "label", "items", "tableMode"]);
|
|
18
18
|
const orderDiscriminator = Number.isInteger(value) && Number(value) > 1 && label.charAt(label.length - 1) !== 's' ? `${label}s` : label;
|
|
19
19
|
const orderLabel = `${value} ${orderDiscriminator}`;
|
|
20
20
|
const orderTooltip = (_jsx(_Fragment, { children: items === null || items === void 0 ? void 0 : items.map((item) => {
|
|
@@ -22,6 +22,9 @@ function OrderCell(_a) {
|
|
|
22
22
|
const truncatedItemContent = ((itemContent === null || itemContent === void 0 ? void 0 : itemContent.length) || 0) > MAX_TOOLTIP_ITEM_LENGTH ? `${itemContent === null || itemContent === void 0 ? void 0 : itemContent.slice(0, MAX_TOOLTIP_ITEM_LENGTH)}...` : itemContent;
|
|
23
23
|
return _jsx("div", { children: truncatedItemContent }, item.id);
|
|
24
24
|
}) }));
|
|
25
|
+
if (tableMode === 'sheet') {
|
|
26
|
+
return (_jsx(TableCell, Object.assign({ sx: { fontSize: '11px' } }, props, { children: orderLabel })));
|
|
27
|
+
}
|
|
25
28
|
return (_jsx(Tooltip, Object.assign({ title: (items || []).length > 1 ? orderTooltip : undefined }, { children: _jsx(TableCell, Object.assign({}, props, { children: _jsx("span", { children: orderLabel }) })) })));
|
|
26
29
|
}
|
|
27
30
|
export default OrderCell;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { TableCell } from '@mui/material';
|
|
3
3
|
import { TextTableCell } from '..';
|
|
4
|
-
import { TextLabel } from '../style';
|
|
4
|
+
import { StyledTextTableCell, TextLabel } from '../style';
|
|
5
5
|
import Tooltip from '../../../Tooltip';
|
|
6
6
|
import { receiptBillIcon } from '../../../../constants/index.js';
|
|
7
7
|
export const ReceiptCell = ({ receiptId, isTextShown, tableMode, }) => {
|
|
8
8
|
if (tableMode === 'sheet') {
|
|
9
|
-
return (_jsx(
|
|
9
|
+
return (_jsx(StyledTextTableCell, { children: _jsx("span", { children: receiptId }) }));
|
|
10
10
|
}
|
|
11
11
|
return isTextShown ? (_jsx(TextTableCell, { children: _jsx("span", { children: receiptId }) })) : (_jsx(TableCell, Object.assign({ component: "div" }, { children: _jsx(Tooltip, Object.assign({ title: `Receipt - ${receiptId}` }, { children: _jsx(TextLabel, Object.assign({ sx: {
|
|
12
12
|
padding: '3px 8px',
|
|
@@ -17,8 +17,9 @@ import Tooltip from '../../../Tooltip';
|
|
|
17
17
|
import { ImageWrapper } from '../../../index.js';
|
|
18
18
|
import { TableCell } from '../../../TableCells';
|
|
19
19
|
import StatusChip from '../../../StatusChip';
|
|
20
|
-
import { referenceIcons } from './constant';
|
|
20
|
+
import { referenceIcons, REFERENCE_ORDER, REFERENCE_WIDTH_MAP } from './constant';
|
|
21
21
|
import { ReferenceTextLabel, ReferenceTextWrapper, ReferenceSourcesContainer, StyledSourceCell, StyledSourceImage, referenceSourceAnimation, } from './style';
|
|
22
|
+
import { Box } from '@mui/material';
|
|
22
23
|
function ReferenceCell(_a) {
|
|
23
24
|
var { isTextShown, tableMode } = _a, props = __rest(_a, ["isTextShown", "tableMode"]);
|
|
24
25
|
const [isTooltipOpen, setIsTooltipOpen] = useState(false);
|
|
@@ -36,7 +37,25 @@ function ReferenceCell(_a) {
|
|
|
36
37
|
}), [props, references, isTextShown, theme]);
|
|
37
38
|
const referenceSourcesCount = (ReferenceSources === null || ReferenceSources === void 0 ? void 0 : ReferenceSources.length) || 0;
|
|
38
39
|
if (tableMode === 'sheet') {
|
|
39
|
-
return (_jsx(TableCell, Object.assign({}, props, { children: _jsx(StyledSourceCell, {
|
|
40
|
+
return (_jsx(TableCell, Object.assign({}, props, { children: _jsx(StyledSourceCell, Object.assign({ sx: { gap: '4px', display: 'flex', flexWrap: 'nowrap' } }, { children: REFERENCE_ORDER.map((referenceKey) => {
|
|
41
|
+
const referenceValue = props[referenceKey];
|
|
42
|
+
const hasValue = !!referenceValue;
|
|
43
|
+
const widthConfig = REFERENCE_WIDTH_MAP[referenceKey];
|
|
44
|
+
return (_jsx(Box, Object.assign({ sx: {
|
|
45
|
+
width: widthConfig.width,
|
|
46
|
+
minWidth: widthConfig.width,
|
|
47
|
+
maxWidth: widthConfig.width,
|
|
48
|
+
flexShrink: 0,
|
|
49
|
+
} }, { children: hasValue ? (_jsx(StatusChip, Object.assign({ sx: {
|
|
50
|
+
maxWidth: '100%',
|
|
51
|
+
overflow: 'hidden',
|
|
52
|
+
textOverflow: 'ellipsis',
|
|
53
|
+
whiteSpace: 'nowrap',
|
|
54
|
+
boxSizing: 'border-box',
|
|
55
|
+
display: 'inline-block',
|
|
56
|
+
padding: '0.75px 12px',
|
|
57
|
+
} }, { children: `${startCase(referenceKey)}: ${referenceValue}` }))) : null }), referenceKey));
|
|
58
|
+
}) })) })));
|
|
40
59
|
}
|
|
41
60
|
return (_jsx(TableCell, Object.assign({}, props, { children: _jsx(StyledSourceCell, { children: referenceSourcesCount > 0 ? (_jsx(ReferenceSourcesContainer, Object.assign({ layout: true, className: "reference-sources-container", whileHover: "animate", animate: isTooltipOpen ? 'animate' : 'start', sourcesCount: referenceSourcesCount, variants: { animate: { width: referenceSourcesCount * (6 + 32) } }, style: {
|
|
42
61
|
zIndex: 29,
|
|
@@ -4,3 +4,8 @@ export declare const referenceIcons: {
|
|
|
4
4
|
payment: string;
|
|
5
5
|
order: string;
|
|
6
6
|
};
|
|
7
|
+
export type ReferenceFields = 'order' | 'payment' | 'acquirer' | 'generic' | 'merchant' | 'customer';
|
|
8
|
+
export declare const REFERENCE_ORDER: ReferenceFields[];
|
|
9
|
+
export declare const REFERENCE_WIDTH_MAP: Record<ReferenceFields, {
|
|
10
|
+
width: string;
|
|
11
|
+
}>;
|
|
@@ -5,3 +5,12 @@ export const referenceIcons = {
|
|
|
5
5
|
payment: transactionIcon,
|
|
6
6
|
order: orderIcon,
|
|
7
7
|
};
|
|
8
|
+
export const REFERENCE_ORDER = ['order', 'payment', 'acquirer', 'generic', 'merchant', 'customer'];
|
|
9
|
+
export const REFERENCE_WIDTH_MAP = {
|
|
10
|
+
order: { width: '185px' },
|
|
11
|
+
payment: { width: '205px' },
|
|
12
|
+
acquirer: { width: '155px' },
|
|
13
|
+
generic: { width: '166px' },
|
|
14
|
+
merchant: { width: '140px' },
|
|
15
|
+
customer: { width: '140px' },
|
|
16
|
+
};
|
|
@@ -267,6 +267,7 @@ export declare const ReferenceSourcesContainer: import("@emotion/styled").Styled
|
|
|
267
267
|
}, {}, {}>;
|
|
268
268
|
export declare const ReferenceTextLabel: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
269
269
|
export declare const ReferenceTextWrapper: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
270
|
+
export declare const ReferenceEmptyPlaceholder: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
270
271
|
export declare const referenceSourceAnimation: (index: number, shadow: string, xDelta?: number) => {
|
|
271
272
|
start: {
|
|
272
273
|
x: number;
|
|
@@ -34,6 +34,9 @@ export const ReferenceTextWrapper = styled('div')(() => ({
|
|
|
34
34
|
justifyContent: 'center',
|
|
35
35
|
paddingInline: '4px',
|
|
36
36
|
}));
|
|
37
|
+
export const ReferenceEmptyPlaceholder = styled('div')(() => ({
|
|
38
|
+
height: '18px',
|
|
39
|
+
}));
|
|
37
40
|
export const referenceSourceAnimation = (index, shadow, xDelta) => ({
|
|
38
41
|
start: {
|
|
39
42
|
x: index * 6,
|
|
@@ -8,7 +8,7 @@ export const StyledSourceCell = styled('span')(({ theme }) => ({
|
|
|
8
8
|
}));
|
|
9
9
|
export const StyledSourceImage = styled('img')(() => ({
|
|
10
10
|
maxWidth: '36px',
|
|
11
|
-
maxHeight: '
|
|
11
|
+
maxHeight: '24px',
|
|
12
12
|
}));
|
|
13
13
|
export const SalesChannelsContainer = styled(motion.span)(({ theme, sourcesCount }) => ({
|
|
14
14
|
display: 'flex',
|
|
@@ -21,7 +21,7 @@ function SheetViewIDButton({ rowId }) {
|
|
|
21
21
|
};
|
|
22
22
|
}
|
|
23
23
|
};
|
|
24
|
-
return (_jsx(Tooltip, Object.assign({ title: t('copy') }, { children: _jsxs(Button, Object.assign({ onClick: handleCopyRowId }, { children: [_jsx(RowId, Object.assign({ style: { visibility: showCopy ? 'hidden' : 'visible' } }, { children: rowId })), showCopy && (_jsx(Box, Object.assign({ sx: {
|
|
24
|
+
return (_jsx(Tooltip, Object.assign({ title: t('copy') }, { children: _jsxs(Button, Object.assign({ sx: { minWidth: '213px' }, onClick: handleCopyRowId }, { children: [_jsx(RowId, Object.assign({ style: { visibility: showCopy ? 'hidden' : 'visible' } }, { children: rowId })), showCopy && (_jsx(Box, Object.assign({ sx: {
|
|
25
25
|
position: 'absolute',
|
|
26
26
|
top: 0,
|
|
27
27
|
left: 0,
|
|
@@ -12,7 +12,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
12
12
|
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
13
13
|
import { useRef, useEffect, useState, useMemo } from 'react';
|
|
14
14
|
import { TableCell } from '../../../TableCells';
|
|
15
|
-
import { StatusContainer, StatusWrapper, StatusIcon } from './style';
|
|
15
|
+
import { StatusContainer, StatusWrapper, StatusIcon, SheetModeContainer, SheetModeStatusWrapper, SheetModeIconContainer } from './style';
|
|
16
16
|
import { getIconXTranslation } from './utils';
|
|
17
17
|
import CollapsedViewIcon from './CollapsedViewIcon';
|
|
18
18
|
function SourceMergedCell(_a) {
|
|
@@ -46,23 +46,7 @@ function SourceMergedCell(_a) {
|
|
|
46
46
|
position: 'relative',
|
|
47
47
|
overflow: 'visible',
|
|
48
48
|
zIndex: 101,
|
|
49
|
-
} }, { children: _jsx(
|
|
50
|
-
display: 'flex',
|
|
51
|
-
alignItems: 'center',
|
|
52
|
-
gap: '4px',
|
|
53
|
-
height: '18px',
|
|
54
|
-
} }, { children: iconsList === null || iconsList === void 0 ? void 0 : iconsList.map((icon, index) => (_jsx("div", Object.assign({ "data-testid": `StatusWrapper-${icon.key}`, style: {
|
|
55
|
-
display: 'flex',
|
|
56
|
-
alignItems: 'center',
|
|
57
|
-
opacity: 1,
|
|
58
|
-
border: '1px solid #F2F2F2',
|
|
59
|
-
borderRadius: '24px',
|
|
60
|
-
padding: '0px 8px',
|
|
61
|
-
} }, { children: _jsx("div", Object.assign({ style: {
|
|
62
|
-
display: 'flex',
|
|
63
|
-
alignItems: 'center',
|
|
64
|
-
opacity: 1,
|
|
65
|
-
} }, { children: icon.icon })) }), `StatusWrapper-${icon.key}-${index}`))) })) })));
|
|
49
|
+
} }, { children: _jsx(SheetModeContainer, { children: iconsList === null || iconsList === void 0 ? void 0 : iconsList.map((icon, index) => (_jsx(SheetModeStatusWrapper, Object.assign({ "data-testid": `StatusWrapper-${icon.key}` }, { children: _jsx(SheetModeIconContainer, { children: icon.icon }) }), `StatusWrapper-${icon.key}-${index}`))) }) })));
|
|
66
50
|
}
|
|
67
51
|
return (_jsx(TableCell, Object.assign({}, props, { "data-testid": "StatusCell", sx: {
|
|
68
52
|
position: 'relative',
|
|
@@ -273,9 +273,9 @@ export declare const MultiRefundIcon: import("@emotion/styled").StyledComponent<
|
|
|
273
273
|
onAnimationIterationCapture?: import("react").AnimationEventHandler<HTMLImageElement> | undefined;
|
|
274
274
|
onTransitionEnd?: import("react").TransitionEventHandler<HTMLImageElement> | undefined;
|
|
275
275
|
onTransitionEndCapture?: import("react").TransitionEventHandler<HTMLImageElement> | undefined;
|
|
276
|
+
referrerPolicy?: import("react").HTMLAttributeReferrerPolicy | undefined;
|
|
276
277
|
src?: string | undefined;
|
|
277
278
|
alt?: string | undefined;
|
|
278
|
-
referrerPolicy?: import("react").HTMLAttributeReferrerPolicy | undefined;
|
|
279
279
|
crossOrigin?: "" | "anonymous" | "use-credentials" | undefined;
|
|
280
280
|
useMap?: string | undefined;
|
|
281
281
|
loading?: "eager" | "lazy" | undefined;
|
|
@@ -1617,3 +1617,6 @@ export declare const StatusContainer: import("@emotion/styled").StyledComponent<
|
|
|
1617
1617
|
} & import("framer-motion").MotionProps & import("react").RefAttributes<HTMLDivElement> & import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme> & {
|
|
1618
1618
|
isReversed?: boolean | undefined;
|
|
1619
1619
|
}, {}, {}>;
|
|
1620
|
+
export declare const SheetModeContainer: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
1621
|
+
export declare const SheetModeStatusWrapper: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
1622
|
+
export declare const SheetModeIconContainer: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
@@ -74,3 +74,22 @@ export const StatusContainer = styled(motion.div)(({ isReversed }) => ({
|
|
|
74
74
|
position: 'relative',
|
|
75
75
|
overflow: 'visible',
|
|
76
76
|
}));
|
|
77
|
+
export const SheetModeContainer = styled('div')(() => ({
|
|
78
|
+
display: 'flex',
|
|
79
|
+
alignItems: 'center',
|
|
80
|
+
gap: '4px',
|
|
81
|
+
height: '18px',
|
|
82
|
+
}));
|
|
83
|
+
export const SheetModeStatusWrapper = styled('div')(() => ({
|
|
84
|
+
display: 'flex',
|
|
85
|
+
alignItems: 'center',
|
|
86
|
+
opacity: 1,
|
|
87
|
+
border: '1px solid #F2F2F2',
|
|
88
|
+
borderRadius: '24px',
|
|
89
|
+
padding: '0px 8px',
|
|
90
|
+
}));
|
|
91
|
+
export const SheetModeIconContainer = styled('div')(() => ({
|
|
92
|
+
display: 'flex',
|
|
93
|
+
alignItems: 'center',
|
|
94
|
+
opacity: 1,
|
|
95
|
+
}));
|
|
@@ -13,6 +13,18 @@ export declare const statusIcons: {
|
|
|
13
13
|
UNKNOWN: string;
|
|
14
14
|
AUTHORIZED: string;
|
|
15
15
|
};
|
|
16
|
+
export declare const sheetViewChipStyles: {
|
|
17
|
+
ABANDONED: {
|
|
18
|
+
color: string;
|
|
19
|
+
background: string;
|
|
20
|
+
border: string;
|
|
21
|
+
};
|
|
22
|
+
CANCELLED: {
|
|
23
|
+
color: string;
|
|
24
|
+
background: string;
|
|
25
|
+
border: string;
|
|
26
|
+
};
|
|
27
|
+
};
|
|
16
28
|
export declare const unCapturedStatusesStyles: Record<(typeof unCapturedStatuses)[number], {
|
|
17
29
|
gatewayIcon: string;
|
|
18
30
|
acquirerIcon: string;
|
|
@@ -38,6 +50,23 @@ export declare const payoutStatusIcons: {
|
|
|
38
50
|
SETTLED: string;
|
|
39
51
|
PENDING: string;
|
|
40
52
|
};
|
|
53
|
+
export declare const payoutStatusStyles: {
|
|
54
|
+
PAID_OUT: {
|
|
55
|
+
color: string;
|
|
56
|
+
background: string;
|
|
57
|
+
border: string;
|
|
58
|
+
};
|
|
59
|
+
SETTLED: {
|
|
60
|
+
color: string;
|
|
61
|
+
background: string;
|
|
62
|
+
border: string;
|
|
63
|
+
};
|
|
64
|
+
PENDING: {
|
|
65
|
+
color: string;
|
|
66
|
+
background: string;
|
|
67
|
+
border: string;
|
|
68
|
+
};
|
|
69
|
+
};
|
|
41
70
|
export declare const authorizedStatusIcons: {
|
|
42
71
|
AUTHORIZED: string;
|
|
43
72
|
};
|
|
@@ -13,6 +13,18 @@ export const statusIcons = {
|
|
|
13
13
|
UNKNOWN: unknownIcon,
|
|
14
14
|
AUTHORIZED: authorizedIcon,
|
|
15
15
|
};
|
|
16
|
+
export const sheetViewChipStyles = {
|
|
17
|
+
ABANDONED: {
|
|
18
|
+
color: '#FFD600',
|
|
19
|
+
background: 'transparent',
|
|
20
|
+
border: '1px solid #FFD60080',
|
|
21
|
+
},
|
|
22
|
+
CANCELLED: {
|
|
23
|
+
color: '#EDC806',
|
|
24
|
+
background: '#FFD6001A',
|
|
25
|
+
border: 'none',
|
|
26
|
+
},
|
|
27
|
+
};
|
|
16
28
|
export const unCapturedStatusesStyles = {
|
|
17
29
|
UNKNOWN: {
|
|
18
30
|
gatewayIcon: gatewayOrangeIcon,
|
|
@@ -82,6 +94,23 @@ export const payoutStatusIcons = {
|
|
|
82
94
|
SETTLED: settledIcon,
|
|
83
95
|
PENDING: settlementInitiatedIcon,
|
|
84
96
|
};
|
|
97
|
+
export const payoutStatusStyles = {
|
|
98
|
+
PAID_OUT: {
|
|
99
|
+
color: '#2ACE00',
|
|
100
|
+
background: '#2ACE001A',
|
|
101
|
+
border: 'none',
|
|
102
|
+
},
|
|
103
|
+
SETTLED: {
|
|
104
|
+
color: '#2ACE00',
|
|
105
|
+
background: 'transparent',
|
|
106
|
+
border: '1px solid #2ACE0066',
|
|
107
|
+
},
|
|
108
|
+
PENDING: {
|
|
109
|
+
color: '#FF7A00',
|
|
110
|
+
background: '#FF7A000D',
|
|
111
|
+
border: 'none',
|
|
112
|
+
},
|
|
113
|
+
};
|
|
85
114
|
export const authorizedStatusIcons = {
|
|
86
115
|
AUTHORIZED: authorizedIcon,
|
|
87
116
|
};
|
|
@@ -262,9 +262,9 @@ export declare const MultiRefundIcon: import("@emotion/styled").StyledComponent<
|
|
|
262
262
|
onAnimationIterationCapture?: import("react").AnimationEventHandler<HTMLImageElement> | undefined;
|
|
263
263
|
onTransitionEnd?: import("react").TransitionEventHandler<HTMLImageElement> | undefined;
|
|
264
264
|
onTransitionEndCapture?: import("react").TransitionEventHandler<HTMLImageElement> | undefined;
|
|
265
|
+
referrerPolicy?: import("react").HTMLAttributeReferrerPolicy | undefined;
|
|
265
266
|
src?: string | undefined;
|
|
266
267
|
alt?: string | undefined;
|
|
267
|
-
referrerPolicy?: import("react").HTMLAttributeReferrerPolicy | undefined;
|
|
268
268
|
crossOrigin?: "" | "anonymous" | "use-credentials" | undefined;
|
|
269
269
|
useMap?: string | undefined;
|
|
270
270
|
loading?: "eager" | "lazy" | undefined;
|
|
@@ -10,6 +10,7 @@ export interface DateCellProps extends TableCellProps {
|
|
|
10
10
|
format?: object;
|
|
11
11
|
flagIcon?: string;
|
|
12
12
|
hasFlag?: boolean;
|
|
13
|
+
tableMode?: TableMode;
|
|
13
14
|
}
|
|
14
15
|
export interface OrderCellProps extends TableCellProps {
|
|
15
16
|
label: string;
|
|
@@ -19,6 +20,7 @@ export interface OrderCellProps extends TableCellProps {
|
|
|
19
20
|
description?: string;
|
|
20
21
|
name?: string;
|
|
21
22
|
}>;
|
|
23
|
+
tableMode?: TableMode;
|
|
22
24
|
}
|
|
23
25
|
export interface CustomerCellProps extends TableCellProps {
|
|
24
26
|
customerInitiated?: boolean;
|
|
@@ -32,6 +34,7 @@ export interface CustomerCellProps extends TableCellProps {
|
|
|
32
34
|
email?: string;
|
|
33
35
|
phone?: string;
|
|
34
36
|
id?: string;
|
|
37
|
+
tableMode?: TableMode;
|
|
35
38
|
}
|
|
36
39
|
export interface SourceCellProps extends TableCellProps {
|
|
37
40
|
geographyVariant?: 'G' | 'L' | 'R';
|
|
@@ -51,6 +54,7 @@ export interface AmountCellProps extends TableCellProps {
|
|
|
51
54
|
tooltipLabel?: React.ReactNode;
|
|
52
55
|
amountTooltipLabel?: React.ReactNode;
|
|
53
56
|
isTextShown?: boolean;
|
|
57
|
+
tableMode?: TableMode;
|
|
54
58
|
}
|
|
55
59
|
export interface DestinationCellProps extends TableCellProps {
|
|
56
60
|
destinationsCount?: number;
|
|
@@ -8,6 +8,7 @@ import { areEqual } from 'react-window';
|
|
|
8
8
|
const StyledSkeleton = styled(Skeleton)(({ theme }) => ({
|
|
9
9
|
backgroundColor: theme.palette.grey[100],
|
|
10
10
|
borderRadius: '64px',
|
|
11
|
+
minWidth: '20px',
|
|
11
12
|
}));
|
|
12
13
|
function TableRowLoading({ columns, style, index, animationType }) {
|
|
13
14
|
return (_jsx(MUITableRow, Object.assign({ sx: Object.assign(Object.assign({}, style), { display: 'flex', borderBottom: '1px solid #e3e8ee', '&:hover': {
|
|
@@ -306,9 +306,9 @@ export declare const ActionIcon: import("@emotion/styled").StyledComponent<{
|
|
|
306
306
|
onAnimationIterationCapture?: import("react").AnimationEventHandler<HTMLImageElement> | undefined;
|
|
307
307
|
onTransitionEnd?: import("react").TransitionEventHandler<HTMLImageElement> | undefined;
|
|
308
308
|
onTransitionEndCapture?: import("react").TransitionEventHandler<HTMLImageElement> | undefined;
|
|
309
|
+
referrerPolicy?: import("react").HTMLAttributeReferrerPolicy | undefined;
|
|
309
310
|
src?: string | undefined;
|
|
310
311
|
alt?: string | undefined;
|
|
311
|
-
referrerPolicy?: import("react").HTMLAttributeReferrerPolicy | undefined;
|
|
312
312
|
crossOrigin?: "" | "anonymous" | "use-credentials" | undefined;
|
|
313
313
|
useMap?: string | undefined;
|
|
314
314
|
loading?: "eager" | "lazy" | undefined;
|
|
@@ -22,12 +22,12 @@ export declare const chargeTableCellWidth: {
|
|
|
22
22
|
readonly date: {
|
|
23
23
|
readonly default: "170px";
|
|
24
24
|
readonly text: "170px";
|
|
25
|
-
readonly sheet: "
|
|
25
|
+
readonly sheet: "129px";
|
|
26
26
|
};
|
|
27
27
|
readonly reference: {
|
|
28
28
|
readonly default: "95px";
|
|
29
29
|
readonly text: "180px";
|
|
30
|
-
readonly sheet: "
|
|
30
|
+
readonly sheet: "985px";
|
|
31
31
|
};
|
|
32
32
|
readonly order: {
|
|
33
33
|
readonly default: "80px";
|
|
@@ -42,7 +42,7 @@ export declare const chargeTableCellWidth: {
|
|
|
42
42
|
readonly source: {
|
|
43
43
|
readonly default: "114px";
|
|
44
44
|
readonly text: "125px";
|
|
45
|
-
readonly sheet: "
|
|
45
|
+
readonly sheet: "450px";
|
|
46
46
|
};
|
|
47
47
|
readonly authenticate: {
|
|
48
48
|
readonly default: "55px";
|
|
@@ -72,7 +72,7 @@ export declare const chargeTableCellWidth: {
|
|
|
72
72
|
readonly status: {
|
|
73
73
|
readonly default: "70px";
|
|
74
74
|
readonly text: "300px";
|
|
75
|
-
readonly sheet: "
|
|
75
|
+
readonly sheet: "385px";
|
|
76
76
|
};
|
|
77
77
|
readonly merchant: {
|
|
78
78
|
readonly default: "100px";
|
|
@@ -107,7 +107,7 @@ export declare const chargeTableCellWidth: {
|
|
|
107
107
|
readonly metadata: {
|
|
108
108
|
readonly default: "180px";
|
|
109
109
|
readonly text: "180px";
|
|
110
|
-
readonly sheet: "
|
|
110
|
+
readonly sheet: "245px";
|
|
111
111
|
};
|
|
112
112
|
readonly settlement: {
|
|
113
113
|
readonly default: "200px";
|
|
@@ -22,12 +22,12 @@ export const chargeTableCellWidth = {
|
|
|
22
22
|
date: {
|
|
23
23
|
default: '170px',
|
|
24
24
|
text: '170px',
|
|
25
|
-
sheet: '
|
|
25
|
+
sheet: '129px',
|
|
26
26
|
},
|
|
27
27
|
reference: {
|
|
28
28
|
default: '95px',
|
|
29
29
|
text: '180px',
|
|
30
|
-
sheet: '
|
|
30
|
+
sheet: '985px',
|
|
31
31
|
},
|
|
32
32
|
order: {
|
|
33
33
|
default: '80px',
|
|
@@ -42,7 +42,7 @@ export const chargeTableCellWidth = {
|
|
|
42
42
|
source: {
|
|
43
43
|
default: '114px',
|
|
44
44
|
text: '125px',
|
|
45
|
-
sheet: '
|
|
45
|
+
sheet: '450px',
|
|
46
46
|
},
|
|
47
47
|
authenticate: {
|
|
48
48
|
default: '55px',
|
|
@@ -72,7 +72,7 @@ export const chargeTableCellWidth = {
|
|
|
72
72
|
status: {
|
|
73
73
|
default: '70px',
|
|
74
74
|
text: '300px',
|
|
75
|
-
sheet: '
|
|
75
|
+
sheet: '385px',
|
|
76
76
|
},
|
|
77
77
|
merchant: {
|
|
78
78
|
default: '100px',
|
|
@@ -107,7 +107,7 @@ export const chargeTableCellWidth = {
|
|
|
107
107
|
metadata: {
|
|
108
108
|
default: '180px',
|
|
109
109
|
text: '180px',
|
|
110
|
-
sheet: '
|
|
110
|
+
sheet: '245px',
|
|
111
111
|
},
|
|
112
112
|
settlement: {
|
|
113
113
|
default: '200px',
|
package/package.json
CHANGED
|
@@ -1,132 +1,132 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@tap-payments/os-micro-frontend-shared",
|
|
3
|
-
"description": "Shared components and utilities for Tap Payments micro frontends",
|
|
4
|
-
"version": "0.0.
|
|
5
|
-
"type": "module",
|
|
6
|
-
"main": "build/index.js",
|
|
7
|
-
"module": "build/index.js",
|
|
8
|
-
"types": "build/index.d.ts",
|
|
9
|
-
"exports": {
|
|
10
|
-
".": {
|
|
11
|
-
"types": "./build/index.d.ts",
|
|
12
|
-
"import": "./build/index.js",
|
|
13
|
-
"require": "./build/index.js"
|
|
14
|
-
},
|
|
15
|
-
"./constants": {
|
|
16
|
-
"types": "./build/constants/index.d.ts",
|
|
17
|
-
"import": "./build/constants/index.js",
|
|
18
|
-
"require": "./build/constants/index.js"
|
|
19
|
-
},
|
|
20
|
-
"./components": {
|
|
21
|
-
"types": "./build/components/index.d.ts",
|
|
22
|
-
"import": "./build/components/index.js",
|
|
23
|
-
"require": "./build/components/index.js"
|
|
24
|
-
},
|
|
25
|
-
"./components/*": {
|
|
26
|
-
"types": "./build/components/*/index.d.ts",
|
|
27
|
-
"import": "./build/components/*/index.js",
|
|
28
|
-
"require": "./build/components/*/index.js"
|
|
29
|
-
},
|
|
30
|
-
"./hooks": {
|
|
31
|
-
"types": "./build/hooks/index.d.ts",
|
|
32
|
-
"import": "./build/hooks/index.js",
|
|
33
|
-
"require": "./build/hooks/index.js"
|
|
34
|
-
},
|
|
35
|
-
"./utils": {
|
|
36
|
-
"types": "./build/utils/index.d.ts",
|
|
37
|
-
"import": "./build/utils/index.js",
|
|
38
|
-
"require": "./build/utils/index.js"
|
|
39
|
-
},
|
|
40
|
-
"./theme": {
|
|
41
|
-
"types": "./build/theme/index.d.ts",
|
|
42
|
-
"import": "./build/theme/index.js",
|
|
43
|
-
"require": "./build/theme/index.js"
|
|
44
|
-
},
|
|
45
|
-
"./types": {
|
|
46
|
-
"types": "./build/types/index.d.ts",
|
|
47
|
-
"import": "./build/types/index.js",
|
|
48
|
-
"require": "./build/types/index.js"
|
|
49
|
-
}
|
|
50
|
-
},
|
|
51
|
-
"license": "MIT",
|
|
52
|
-
"author": {
|
|
53
|
-
"name": "Ahmed Sharkawy",
|
|
54
|
-
"email": "a.elsharkawy@tap.company"
|
|
55
|
-
},
|
|
56
|
-
"files": [
|
|
57
|
-
"build",
|
|
58
|
-
"readme.md"
|
|
59
|
-
],
|
|
60
|
-
"scripts": {
|
|
61
|
-
"ts:build": "rm -rf build && tsc -p tsconfig.npm.json && tsc-alias -p tsconfig.npm.json",
|
|
62
|
-
"push": "npm version patch --no-git-tag-version && npm run ts:build && npm publish --access public",
|
|
63
|
-
"dev": "vite",
|
|
64
|
-
"build": "tsc -b && vite build ",
|
|
65
|
-
"prettier": "prettier --list-different \"src/**/*.{md,mdx,ts,js,tsx,jsx,json}\"",
|
|
66
|
-
"prettier:fix": "prettier --write \"src/**/*.{ts,tsx,js,jsx,json,md,css,json}\"",
|
|
67
|
-
"lint": "eslint . --color",
|
|
68
|
-
"lint:fix": "eslint src --fix --color",
|
|
69
|
-
"preview": "vite preview",
|
|
70
|
-
"prepare": "husky"
|
|
71
|
-
},
|
|
72
|
-
"dependencies": {
|
|
73
|
-
"@emotion/react": "^11.11.0",
|
|
74
|
-
"@emotion/styled": "^11.11.0",
|
|
75
|
-
"@hookform/resolvers": "^3.3.1",
|
|
76
|
-
"@mui/material": "^5.12.3",
|
|
77
|
-
"@uiw/react-json-view": "^2.0.0-alpha.16",
|
|
78
|
-
"axios": "^1.4.0",
|
|
79
|
-
"dayjs": "^1.11.8",
|
|
80
|
-
"framer-motion": "10.11.0",
|
|
81
|
-
"i18next": "^22.4.15",
|
|
82
|
-
"memoize-one": "^6.0.0",
|
|
83
|
-
"re-resizable": "^6.9.9",
|
|
84
|
-
"react": "^18.2.0",
|
|
85
|
-
"react-currency-input-field": "^3.6.11",
|
|
86
|
-
"react-dom": "^18.2.0",
|
|
87
|
-
"react-draggable": "^4.4.6",
|
|
88
|
-
"react-dropzone": "^14.2.3",
|
|
89
|
-
"react-hook-form": "^7.45.4",
|
|
90
|
-
"react-hot-toast": "^2.4.1",
|
|
91
|
-
"react-i18next": "^12.2.2",
|
|
92
|
-
"react-multi-date-picker": "^4.1.2",
|
|
93
|
-
"react-router-dom": "^6.14.2",
|
|
94
|
-
"react-virtualized-auto-sizer": "^1.0.20",
|
|
95
|
-
"react-window": "^1.8.9",
|
|
96
|
-
"react-window-infinite-loader": "^1.0.9",
|
|
97
|
-
"react18-input-otp": "^1.1.4",
|
|
98
|
-
"recharts": "^2.15.1"
|
|
99
|
-
},
|
|
100
|
-
"devDependencies": {
|
|
101
|
-
"@eslint/js": "^9.17.0",
|
|
102
|
-
"@testing-library/jest-dom": "^5.16.5",
|
|
103
|
-
"@types/lodash": "^4.17.15",
|
|
104
|
-
"@types/react": "^18.2.6",
|
|
105
|
-
"@types/react-dom": "^18.3.5",
|
|
106
|
-
"@types/react-virtualized-auto-sizer": "^1.0.8",
|
|
107
|
-
"@types/react-window": "^1.8.5",
|
|
108
|
-
"@types/react-window-infinite-loader": "^1.0.6",
|
|
109
|
-
"@vitejs/plugin-react": "^4.3.4",
|
|
110
|
-
"eslint": "^9.17.0",
|
|
111
|
-
"eslint-plugin-react-hooks": "^5.0.0",
|
|
112
|
-
"eslint-plugin-react-refresh": "^0.4.16",
|
|
113
|
-
"globals": "^15.14.0",
|
|
114
|
-
"husky": "^8.0.3",
|
|
115
|
-
"lint-staged": "^13.2.2",
|
|
116
|
-
"prettier": "^2.8.8",
|
|
117
|
-
"tsc-alias": "^1.8.16",
|
|
118
|
-
"typescript": "5.0.2",
|
|
119
|
-
"typescript-eslint": "^8.18.2",
|
|
120
|
-
"vite": "6.0.5",
|
|
121
|
-
"vite-tsconfig-paths": "^4.2.0"
|
|
122
|
-
},
|
|
123
|
-
"lint-staged": {
|
|
124
|
-
"src/**/*.{ts,tsx,json,js,jsx}": [
|
|
125
|
-
"yarn run prettier:fix",
|
|
126
|
-
"yarn run lint"
|
|
127
|
-
]
|
|
128
|
-
},
|
|
129
|
-
"publishConfig": {
|
|
130
|
-
"registry": "https://registry.npmjs.org/"
|
|
131
|
-
}
|
|
132
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "@tap-payments/os-micro-frontend-shared",
|
|
3
|
+
"description": "Shared components and utilities for Tap Payments micro frontends",
|
|
4
|
+
"version": "0.0.142",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "build/index.js",
|
|
7
|
+
"module": "build/index.js",
|
|
8
|
+
"types": "build/index.d.ts",
|
|
9
|
+
"exports": {
|
|
10
|
+
".": {
|
|
11
|
+
"types": "./build/index.d.ts",
|
|
12
|
+
"import": "./build/index.js",
|
|
13
|
+
"require": "./build/index.js"
|
|
14
|
+
},
|
|
15
|
+
"./constants": {
|
|
16
|
+
"types": "./build/constants/index.d.ts",
|
|
17
|
+
"import": "./build/constants/index.js",
|
|
18
|
+
"require": "./build/constants/index.js"
|
|
19
|
+
},
|
|
20
|
+
"./components": {
|
|
21
|
+
"types": "./build/components/index.d.ts",
|
|
22
|
+
"import": "./build/components/index.js",
|
|
23
|
+
"require": "./build/components/index.js"
|
|
24
|
+
},
|
|
25
|
+
"./components/*": {
|
|
26
|
+
"types": "./build/components/*/index.d.ts",
|
|
27
|
+
"import": "./build/components/*/index.js",
|
|
28
|
+
"require": "./build/components/*/index.js"
|
|
29
|
+
},
|
|
30
|
+
"./hooks": {
|
|
31
|
+
"types": "./build/hooks/index.d.ts",
|
|
32
|
+
"import": "./build/hooks/index.js",
|
|
33
|
+
"require": "./build/hooks/index.js"
|
|
34
|
+
},
|
|
35
|
+
"./utils": {
|
|
36
|
+
"types": "./build/utils/index.d.ts",
|
|
37
|
+
"import": "./build/utils/index.js",
|
|
38
|
+
"require": "./build/utils/index.js"
|
|
39
|
+
},
|
|
40
|
+
"./theme": {
|
|
41
|
+
"types": "./build/theme/index.d.ts",
|
|
42
|
+
"import": "./build/theme/index.js",
|
|
43
|
+
"require": "./build/theme/index.js"
|
|
44
|
+
},
|
|
45
|
+
"./types": {
|
|
46
|
+
"types": "./build/types/index.d.ts",
|
|
47
|
+
"import": "./build/types/index.js",
|
|
48
|
+
"require": "./build/types/index.js"
|
|
49
|
+
}
|
|
50
|
+
},
|
|
51
|
+
"license": "MIT",
|
|
52
|
+
"author": {
|
|
53
|
+
"name": "Ahmed Sharkawy",
|
|
54
|
+
"email": "a.elsharkawy@tap.company"
|
|
55
|
+
},
|
|
56
|
+
"files": [
|
|
57
|
+
"build",
|
|
58
|
+
"readme.md"
|
|
59
|
+
],
|
|
60
|
+
"scripts": {
|
|
61
|
+
"ts:build": "rm -rf build && tsc -p tsconfig.npm.json && tsc-alias -p tsconfig.npm.json",
|
|
62
|
+
"push": "npm version patch --no-git-tag-version && npm run ts:build && npm publish --access public",
|
|
63
|
+
"dev": "vite",
|
|
64
|
+
"build": "tsc -b && vite build ",
|
|
65
|
+
"prettier": "prettier --list-different \"src/**/*.{md,mdx,ts,js,tsx,jsx,json}\"",
|
|
66
|
+
"prettier:fix": "prettier --write \"src/**/*.{ts,tsx,js,jsx,json,md,css,json}\"",
|
|
67
|
+
"lint": "eslint . --color",
|
|
68
|
+
"lint:fix": "eslint src --fix --color",
|
|
69
|
+
"preview": "vite preview",
|
|
70
|
+
"prepare": "husky"
|
|
71
|
+
},
|
|
72
|
+
"dependencies": {
|
|
73
|
+
"@emotion/react": "^11.11.0",
|
|
74
|
+
"@emotion/styled": "^11.11.0",
|
|
75
|
+
"@hookform/resolvers": "^3.3.1",
|
|
76
|
+
"@mui/material": "^5.12.3",
|
|
77
|
+
"@uiw/react-json-view": "^2.0.0-alpha.16",
|
|
78
|
+
"axios": "^1.4.0",
|
|
79
|
+
"dayjs": "^1.11.8",
|
|
80
|
+
"framer-motion": "10.11.0",
|
|
81
|
+
"i18next": "^22.4.15",
|
|
82
|
+
"memoize-one": "^6.0.0",
|
|
83
|
+
"re-resizable": "^6.9.9",
|
|
84
|
+
"react": "^18.2.0",
|
|
85
|
+
"react-currency-input-field": "^3.6.11",
|
|
86
|
+
"react-dom": "^18.2.0",
|
|
87
|
+
"react-draggable": "^4.4.6",
|
|
88
|
+
"react-dropzone": "^14.2.3",
|
|
89
|
+
"react-hook-form": "^7.45.4",
|
|
90
|
+
"react-hot-toast": "^2.4.1",
|
|
91
|
+
"react-i18next": "^12.2.2",
|
|
92
|
+
"react-multi-date-picker": "^4.1.2",
|
|
93
|
+
"react-router-dom": "^6.14.2",
|
|
94
|
+
"react-virtualized-auto-sizer": "^1.0.20",
|
|
95
|
+
"react-window": "^1.8.9",
|
|
96
|
+
"react-window-infinite-loader": "^1.0.9",
|
|
97
|
+
"react18-input-otp": "^1.1.4",
|
|
98
|
+
"recharts": "^2.15.1"
|
|
99
|
+
},
|
|
100
|
+
"devDependencies": {
|
|
101
|
+
"@eslint/js": "^9.17.0",
|
|
102
|
+
"@testing-library/jest-dom": "^5.16.5",
|
|
103
|
+
"@types/lodash": "^4.17.15",
|
|
104
|
+
"@types/react": "^18.2.6",
|
|
105
|
+
"@types/react-dom": "^18.3.5",
|
|
106
|
+
"@types/react-virtualized-auto-sizer": "^1.0.8",
|
|
107
|
+
"@types/react-window": "^1.8.5",
|
|
108
|
+
"@types/react-window-infinite-loader": "^1.0.6",
|
|
109
|
+
"@vitejs/plugin-react": "^4.3.4",
|
|
110
|
+
"eslint": "^9.17.0",
|
|
111
|
+
"eslint-plugin-react-hooks": "^5.0.0",
|
|
112
|
+
"eslint-plugin-react-refresh": "^0.4.16",
|
|
113
|
+
"globals": "^15.14.0",
|
|
114
|
+
"husky": "^8.0.3",
|
|
115
|
+
"lint-staged": "^13.2.2",
|
|
116
|
+
"prettier": "^2.8.8",
|
|
117
|
+
"tsc-alias": "^1.8.16",
|
|
118
|
+
"typescript": "5.0.2",
|
|
119
|
+
"typescript-eslint": "^8.18.2",
|
|
120
|
+
"vite": "6.0.5",
|
|
121
|
+
"vite-tsconfig-paths": "^4.2.0"
|
|
122
|
+
},
|
|
123
|
+
"lint-staged": {
|
|
124
|
+
"src/**/*.{ts,tsx,json,js,jsx}": [
|
|
125
|
+
"yarn run prettier:fix",
|
|
126
|
+
"yarn run lint"
|
|
127
|
+
]
|
|
128
|
+
},
|
|
129
|
+
"publishConfig": {
|
|
130
|
+
"registry": "https://registry.npmjs.org/"
|
|
131
|
+
}
|
|
132
|
+
}
|