@tap-payments/os-micro-frontend-shared 0.1.286 → 0.1.287-test.1
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/build/components/Amount/TotalAmount/TotalAmount.js +4 -2
- package/build/components/AmountInput/AmountInput.d.ts +1 -1
- package/build/components/AmountInput/AmountInput.js +3 -2
- package/build/components/Chip/style.d.ts +0 -1
- package/build/components/CountBadge/style.d.ts +0 -1
- package/build/components/Dialog/style.d.ts +0 -1
- package/build/components/Discount/TotalDiscount/TotalDiscount.js +2 -1
- package/build/components/DisplayAmount/DisplayAmount.d.ts +2 -3
- package/build/components/DisplayAmount/DisplayAmount.js +2 -3
- package/build/components/FlippingCard/style.d.ts +0 -1
- package/build/components/ImageWrapper/ImageWrapper.d.ts +0 -1
- package/build/components/JSONViewer/style.d.ts +0 -1
- package/build/components/LeftPeekRightExpandingChip/style.d.ts +0 -1
- package/build/components/RightLeftExpandingCenterChip/style.d.ts +0 -1
- package/build/components/SearchButton/styles.d.ts +0 -1
- package/build/components/StatusIcons/AuthIcons/style.d.ts +0 -1
- package/build/components/StatusIcons/AuthorizationAutoIcons/style.d.ts +0 -1
- package/build/components/StatusIcons/ChargeStatusIcon/style.d.ts +0 -1
- package/build/components/StatusIcons/SourceIcons/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/ActionCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/ApplicationStatusCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/AuthenticationCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/AuthenticationStatusCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/AuthenticationTypeCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/BalanceCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/ChannelsCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/CheckoutStatusCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/DestinationStatusCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/DueDateCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/IDButton/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/IntentsStatusCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/InvoiceStatusCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/PayoutStatusCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/ProductsCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/ReferenceCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/RefundChargeCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/RefundStatusCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/SalesChannelCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/SegmentsCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/SourceCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/StatusCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/TokenStatusCell/style.d.ts +0 -1
- package/build/components/TableCells/CustomCells/style.d.ts +0 -1
- package/build/components/TableReports/components/DownloadButton/style.d.ts +0 -1
- package/build/components/TableReports/style.d.ts +0 -1
- package/build/components/VAT/TotalVAT/TotalVAT.js +4 -2
- package/build/components/VirtualTables/components/style.d.ts +0 -1
- package/build/constants/table/cell/merchantsTableCellWidth.d.ts +4 -4
- package/build/constants/table/cell/merchantsTableCellWidth.js +4 -4
- package/package.json +3 -3
|
@@ -9,6 +9,7 @@ import { InputStyled, TotalAmountWrapper, Error } from './style';
|
|
|
9
9
|
import { Loading } from './Loading';
|
|
10
10
|
const isSafari = isSafariBrowser();
|
|
11
11
|
function TotalAmount({ totalGrossAmount, items, selectedCurrency, isAmountIsMissing, isDisabled, isLoading, onResetAllItems, onAddFirstItem, }) {
|
|
12
|
+
var _a;
|
|
12
13
|
const [editMode, setEditMode] = useState(false);
|
|
13
14
|
const [amount, setAmount] = useState();
|
|
14
15
|
const { isConfirmed } = useConfirmDialog();
|
|
@@ -43,6 +44,7 @@ function TotalAmount({ totalGrossAmount, items, selectedCurrency, isAmountIsMiss
|
|
|
43
44
|
onAddFirstItem(Number(numberToString(Number(e.target.value), selectedCurrency === null || selectedCurrency === void 0 ? void 0 : selectedCurrency.decimals)));
|
|
44
45
|
};
|
|
45
46
|
const isEditable = totalGrossAmount === 0 || (items.length === 1 && totalGrossAmount === items[0].total);
|
|
47
|
+
const currencyCode = ((_a = selectedCurrency === null || selectedCurrency === void 0 ? void 0 : selectedCurrency.code) === null || _a === void 0 ? void 0 : _a.english) || '';
|
|
46
48
|
if (isLoading) {
|
|
47
49
|
return _jsx(Loading, {});
|
|
48
50
|
}
|
|
@@ -50,9 +52,9 @@ function TotalAmount({ totalGrossAmount, items, selectedCurrency, isAmountIsMiss
|
|
|
50
52
|
if (isSafari && isNaN(Number(evt.key)) && evt.key !== 'Backspace' && evt.key !== '.') {
|
|
51
53
|
evt.preventDefault();
|
|
52
54
|
}
|
|
53
|
-
}, autoFocus: true })) : (_jsx(DisplayAmount, { sx: { fontSize: '36px', textAlign: 'center' }, amount: totalGrossAmount || 0,
|
|
55
|
+
}, autoFocus: true })) : (_jsx(DisplayAmount, { sx: { fontSize: '36px', textAlign: 'center' }, amount: totalGrossAmount || 0, currencyCode: currencyCode, onClick: () => {
|
|
54
56
|
setEditMode(true);
|
|
55
|
-
} })) })) : (_jsxs(TotalAmountWrapper, { children: [_jsx(DisplayAmount, { sx: { fontSize: '36px', textAlign: 'center' },
|
|
57
|
+
} })) })) : (_jsxs(TotalAmountWrapper, { children: [_jsx(DisplayAmount, { sx: { fontSize: '36px', textAlign: 'center' }, currencyCode: currencyCode, amount: totalGrossAmount || 0, onClick: () => {
|
|
56
58
|
if (isEditable)
|
|
57
59
|
setEditMode(true);
|
|
58
60
|
} }), totalGrossAmount > 0 && _jsx(Box, { component: "img", src: removeAllItem, alt: "r", onClick: removeAllItems })] })), isAmountIsMissing && (_jsxs(Error, { children: [_jsx(Box, { component: "img", src: unknownIcon }), _jsx(Box, { children: t('enterAmount') })] }))] })));
|
|
@@ -9,6 +9,6 @@ interface AmountInputI extends BoxProps {
|
|
|
9
9
|
placeholder?: string;
|
|
10
10
|
selectedCurrency: Currency;
|
|
11
11
|
}
|
|
12
|
-
declare function AmountInput({ amount, setAmount,
|
|
12
|
+
declare function AmountInput({ amount, setAmount, maxAmount, isError, selectedCurrency, ...props }: AmountInputI): import("react/jsx-runtime").JSX.Element;
|
|
13
13
|
declare const _default: import("react").MemoExoticComponent<typeof AmountInput>;
|
|
14
14
|
export default _default;
|
|
@@ -16,7 +16,8 @@ import { DisplayAmount } from '../index.js';
|
|
|
16
16
|
import { Wrapper, InputStyled } from './style';
|
|
17
17
|
const isSafari = isSafariBrowser();
|
|
18
18
|
function AmountInput(_a) {
|
|
19
|
-
var
|
|
19
|
+
var _b;
|
|
20
|
+
var { amount, setAmount, maxAmount, isError, selectedCurrency } = _a, props = __rest(_a, ["amount", "setAmount", "maxAmount", "isError", "selectedCurrency"]);
|
|
20
21
|
const [editMode, setEditMode] = useState(false);
|
|
21
22
|
const [value, setValue] = useState(amount || '');
|
|
22
23
|
const currencyPlaceholder = useMemo(() => getAmountPlaceholder(selectedCurrency === null || selectedCurrency === void 0 ? void 0 : selectedCurrency.decimals), [selectedCurrency]);
|
|
@@ -36,7 +37,7 @@ function AmountInput(_a) {
|
|
|
36
37
|
evt.preventDefault();
|
|
37
38
|
}
|
|
38
39
|
};
|
|
39
|
-
return (_jsx(Wrapper, Object.assign({ sx: props.sx }, { children: editMode ? (_jsx(InputStyled, { placeholder: currencyPlaceholder, value: value, onChange: onChange, onBlur: onBlur, onKeyDown: onKeyDown, isError: isError, inputProps: { step: '0.01' }, hideArrows: true, autoFocus: true })) : (_jsx(DisplayAmount, { selectedCurrency: selectedCurrency, amount: amount, onClick: () => {
|
|
40
|
+
return (_jsx(Wrapper, Object.assign({ sx: props.sx }, { children: editMode ? (_jsx(InputStyled, { placeholder: currencyPlaceholder, value: value, onChange: onChange, onBlur: onBlur, onKeyDown: onKeyDown, isError: isError, inputProps: { step: '0.01' }, hideArrows: true, autoFocus: true })) : (_jsx(DisplayAmount, { currencyCode: (_b = selectedCurrency === null || selectedCurrency === void 0 ? void 0 : selectedCurrency.code) === null || _b === void 0 ? void 0 : _b.english, amount: amount, onClick: () => {
|
|
40
41
|
setEditMode(true);
|
|
41
42
|
} })) })));
|
|
42
43
|
}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
/// <reference types="react" />
|
|
3
2
|
import { GetSourceAnimationFunction } from './type';
|
|
4
3
|
export declare const ChipStyled: import("@emotion/styled").StyledComponent<import("react").RefAttributes<unknown> & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme> & {
|
|
5
4
|
variant?: import("./type").ChipVariant | undefined;
|
|
@@ -20,9 +20,10 @@ function TotalDiscount({ selectedCurrency, totalGrossAmount, totalDiscount, onCh
|
|
|
20
20
|
onChangeTotalDiscount(Object.assign(Object.assign({}, newDiscount), { value: getDiscountValue(totalGrossAmount, newDiscount) }));
|
|
21
21
|
};
|
|
22
22
|
const getLabel = () => {
|
|
23
|
+
var _a;
|
|
23
24
|
if (totalDiscount.value === 0)
|
|
24
25
|
return t('noDiscount');
|
|
25
|
-
return (_jsxs(Box, Object.assign({ sx: { display: 'flex', gap: '2px' } }, { children: [_jsx("span", { children: "-" }), _jsx(DisplayAmount, { amount: totalDiscount.value, selectedCurrency: selectedCurrency })] })));
|
|
26
|
+
return (_jsxs(Box, Object.assign({ sx: { display: 'flex', gap: '2px' } }, { children: [_jsx("span", { children: "-" }), _jsx(DisplayAmount, { amount: totalDiscount.value, currencyCode: (_a = selectedCurrency === null || selectedCurrency === void 0 ? void 0 : selectedCurrency.code) === null || _a === void 0 ? void 0 : _a.english })] })));
|
|
26
27
|
};
|
|
27
28
|
return (_jsxs(LabelWrapper, Object.assign({ isOpen: isOpen, isDisabled: isDisabled, onClick: toggleDropdown, ref: discountButtonRef, sx: Object.assign({}, (isDisabled && { pointerEvents: 'none', opacity: 0.7 })) }, { children: [_jsx("img", { src: discountIcon, alt: "p" }), _jsx(Label, Object.assign({ isDisabled: isDisabled }, { children: getLabel() })), _jsx(Box, { component: "img", src: isOpen ? activeActionIcon : actionsIcon, alt: "a" }), isOpen && _jsx(CustomBackdrop, { onClick: toggleDropdown }), _jsx(Popper, Object.assign({ open: Boolean(isOpen), anchorEl: discountButtonRef.current, placement: "bottom-start" }, { children: _jsx(DiscountDropdown, { sx: { position: 'absolute', top: 8, left: 0, display: isOpen ? 'block' : 'none' }, selectedCurrency: selectedCurrency, discount: totalDiscount, setDiscount: handleDiscount, setIsOpen: setIsOpen, maxDiscount: Number(totalGrossAmount) }) }))] })));
|
|
28
29
|
}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { BoxProps } from '@mui/material/Box';
|
|
3
|
-
import { Currency } from '../../types/index.js';
|
|
4
3
|
interface DisplayAmountI extends BoxProps {
|
|
5
4
|
amount: number;
|
|
6
|
-
|
|
5
|
+
currencyCode: string;
|
|
7
6
|
}
|
|
8
|
-
declare function DisplayAmount({ amount,
|
|
7
|
+
declare function DisplayAmount({ amount, currencyCode, ...props }: DisplayAmountI): import("react/jsx-runtime").JSX.Element;
|
|
9
8
|
declare const _default: import("react").MemoExoticComponent<typeof DisplayAmount>;
|
|
10
9
|
export default _default;
|
|
@@ -14,9 +14,8 @@ import { memo } from 'react';
|
|
|
14
14
|
import { formatAmountWithCurrency } from '../../utils/index.js';
|
|
15
15
|
import { DecimalSpan, CurrencySpan } from './style';
|
|
16
16
|
function DisplayAmount(_a) {
|
|
17
|
-
var
|
|
18
|
-
|
|
19
|
-
const { integerAmount, decimalAmount } = formatAmountWithCurrency(amount, (_b = selectedCurrency === null || selectedCurrency === void 0 ? void 0 : selectedCurrency.code) === null || _b === void 0 ? void 0 : _b.english);
|
|
17
|
+
var { amount, currencyCode } = _a, props = __rest(_a, ["amount", "currencyCode"]);
|
|
18
|
+
const { integerAmount, decimalAmount } = formatAmountWithCurrency(amount, currencyCode);
|
|
20
19
|
return (_jsxs(CurrencySpan, Object.assign({}, props, { children: [_jsx("span", { children: integerAmount }), _jsx("span", { children: "." }), _jsx(DecimalSpan, { children: decimalAmount })] })));
|
|
21
20
|
}
|
|
22
21
|
export default memo(DisplayAmount);
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
/// <reference types="react" />
|
|
3
2
|
export declare const StyledSourceCell: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
4
3
|
export declare const StyledSourceImage: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>, {}>;
|
|
5
4
|
export declare const PaymentSourcesContainer: import("@emotion/styled").StyledComponent<{
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
/// <reference types="react" />
|
|
3
2
|
export declare const StyledSourceCell: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
4
3
|
export declare const StyledSourceImage: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>, {}>;
|
|
5
4
|
export declare const PaymentSourcesContainer: import("@emotion/styled").StyledComponent<{
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
/// <reference types="react" />
|
|
3
2
|
import { TableMode } from '../../../../types/index.js';
|
|
4
3
|
export declare const ActionCellContainer: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme> & {
|
|
5
4
|
tableMode?: TableMode | undefined;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
/// <reference types="react" />
|
|
3
2
|
export declare const StyledAppsCell: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
4
3
|
export declare const AppsStatusContainer: import("@emotion/styled").StyledComponent<{
|
|
5
4
|
hidden?: boolean | undefined;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
/// <reference types="react" />
|
|
3
2
|
export declare const AuthIcon: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>, {}>;
|
|
4
3
|
export declare const AuthCellContainer: import("@emotion/styled").StyledComponent<{
|
|
5
4
|
hidden?: boolean | undefined;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
/// <reference types="react" />
|
|
3
2
|
export declare const StyledSourceCell: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
4
3
|
export declare const StyledSourceImage: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>, {}>;
|
|
5
4
|
export declare const PaymentSourcesContainer: import("@emotion/styled").StyledComponent<{
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
/// <reference types="react" />
|
|
3
2
|
export declare const StyledSourceCell: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
4
3
|
export declare const StyledSourceImage: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>, {}>;
|
|
5
4
|
export declare const ReferenceSourcesContainer: import("@emotion/styled").StyledComponent<{
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
/// <reference types="react" />
|
|
3
2
|
export declare const StyledSourceCell: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
4
3
|
export declare const StyledSourceImage: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>, {}>;
|
|
5
4
|
export declare const SalesChannelsContainer: import("@emotion/styled").StyledComponent<{
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
/// <reference types="react" />
|
|
3
2
|
export declare const StyledSourceCell: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
4
3
|
export declare const ReferenceSourcesContainer: import("@emotion/styled").StyledComponent<{
|
|
5
4
|
hidden?: boolean | undefined;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
/// <reference types="react" />
|
|
3
2
|
export declare const StyledSourceCell: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
4
3
|
export declare const StyledSourceImage: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>, {}>;
|
|
5
4
|
export declare const PaymentSourcesContainer: import("@emotion/styled").StyledComponent<{
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
/// <reference types="react" />
|
|
3
2
|
export declare const GeographyBox: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme> & {
|
|
4
3
|
variant?: "Global" | "Regional" | "Local" | undefined;
|
|
5
4
|
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
@@ -9,6 +9,7 @@ import { Label, LabelWrapper } from './style';
|
|
|
9
9
|
import { getVatValue } from '../utils';
|
|
10
10
|
import VATDropdown from '../VATDropdown';
|
|
11
11
|
function TotalVAT({ totalGrossAmount, totalVat, selectedCurrency, onChangeTotalVat, isDisabled }) {
|
|
12
|
+
var _a;
|
|
12
13
|
const [isOpen, setIsOpen] = useState(false);
|
|
13
14
|
const vatButtonRef = useRef();
|
|
14
15
|
const { t } = useTranslation();
|
|
@@ -19,12 +20,13 @@ function TotalVAT({ totalGrossAmount, totalVat, selectedCurrency, onChangeTotalV
|
|
|
19
20
|
const modifyTotalVAT = (newVat) => {
|
|
20
21
|
onChangeTotalVat(Object.assign(Object.assign({}, newVat), { value: getVatValue(totalGrossAmount, newVat) }));
|
|
21
22
|
};
|
|
23
|
+
const currencyCode = ((_a = selectedCurrency === null || selectedCurrency === void 0 ? void 0 : selectedCurrency.code) === null || _a === void 0 ? void 0 : _a.english) || '';
|
|
22
24
|
const getLabel = () => {
|
|
23
25
|
if (totalVat.percentage === 0)
|
|
24
26
|
return t('noVat');
|
|
25
27
|
if (!totalVat.isInclusive)
|
|
26
|
-
return _jsx(DisplayAmount, {
|
|
27
|
-
return (_jsxs(Box, Object.assign({ sx: { display: 'flex', gap: '4px' } }, { children: [_jsxs("span", { children: [t('inclusive'), " "] }), _jsx(DisplayAmount, { amount: totalVat.value,
|
|
28
|
+
return _jsx(DisplayAmount, { currencyCode: currencyCode, amount: totalVat.value });
|
|
29
|
+
return (_jsxs(Box, Object.assign({ sx: { display: 'flex', gap: '4px' } }, { children: [_jsxs("span", { children: [t('inclusive'), " "] }), _jsx(DisplayAmount, { amount: totalVat.value, currencyCode: currencyCode })] })));
|
|
28
30
|
};
|
|
29
31
|
return (_jsxs(LabelWrapper, Object.assign({ isDisabled: isDisabled, isOpen: isOpen, onClick: toggleDropdown, ref: vatButtonRef, sx: Object.assign({}, (isDisabled && { pointerEvents: 'none', opacity: 0.7 })) }, { children: [_jsx("img", { src: taxIcon, alt: "p" }), _jsx(Label, Object.assign({ isDisabled: isDisabled }, { children: getLabel() })), _jsx(Box, { component: "img", src: isOpen ? activeActionIcon : actionsIcon, alt: "a" }), isOpen && _jsx(CustomBackdrop, { onClick: toggleDropdown }), _jsx(Popper, Object.assign({ open: Boolean(isOpen), anchorEl: vatButtonRef.current, placement: "bottom-start" }, { children: _jsx(VATDropdown, { setIsOpen: setIsOpen, vat: totalVat, setVat: modifyTotalVAT, sx: { position: 'absolute', top: 8, left: 0, display: isOpen ? 'block' : 'none' } }) }))] })));
|
|
30
32
|
}
|
|
@@ -110,17 +110,17 @@ export declare const merchantsTableCellWidth: {
|
|
|
110
110
|
readonly sheet: "180px";
|
|
111
111
|
};
|
|
112
112
|
readonly psp: {
|
|
113
|
-
readonly default: "
|
|
113
|
+
readonly default: "77px";
|
|
114
114
|
readonly text: "180px";
|
|
115
115
|
readonly sheet: "180px";
|
|
116
116
|
};
|
|
117
117
|
readonly status: {
|
|
118
|
-
readonly default: "
|
|
118
|
+
readonly default: "86px";
|
|
119
119
|
readonly text: "100px";
|
|
120
120
|
readonly sheet: "172px";
|
|
121
121
|
};
|
|
122
122
|
readonly partners: {
|
|
123
|
-
readonly default: "
|
|
123
|
+
readonly default: "97px";
|
|
124
124
|
readonly text: "100px";
|
|
125
125
|
readonly sheet: "100px";
|
|
126
126
|
};
|
|
@@ -140,7 +140,7 @@ export declare const merchantsTableCellWidth: {
|
|
|
140
140
|
readonly sheet: "180px";
|
|
141
141
|
};
|
|
142
142
|
readonly channels: {
|
|
143
|
-
readonly default: "
|
|
143
|
+
readonly default: "102px";
|
|
144
144
|
readonly text: "120px";
|
|
145
145
|
readonly sheet: "440px";
|
|
146
146
|
};
|
|
@@ -110,17 +110,17 @@ export const merchantsTableCellWidth = {
|
|
|
110
110
|
sheet: '180px',
|
|
111
111
|
},
|
|
112
112
|
psp: {
|
|
113
|
-
default: '
|
|
113
|
+
default: '77px',
|
|
114
114
|
text: '180px',
|
|
115
115
|
sheet: '180px',
|
|
116
116
|
},
|
|
117
117
|
status: {
|
|
118
|
-
default: '
|
|
118
|
+
default: '86px',
|
|
119
119
|
text: '100px',
|
|
120
120
|
sheet: '172px',
|
|
121
121
|
},
|
|
122
122
|
partners: {
|
|
123
|
-
default: '
|
|
123
|
+
default: '97px',
|
|
124
124
|
text: '100px',
|
|
125
125
|
sheet: '100px',
|
|
126
126
|
},
|
|
@@ -140,7 +140,7 @@ export const merchantsTableCellWidth = {
|
|
|
140
140
|
sheet: '180px',
|
|
141
141
|
},
|
|
142
142
|
channels: {
|
|
143
|
-
default: '
|
|
143
|
+
default: '102px',
|
|
144
144
|
text: '120px',
|
|
145
145
|
sheet: '440px',
|
|
146
146
|
},
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
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.
|
|
5
|
-
"testVersion":
|
|
4
|
+
"version": "0.1.287-test.1",
|
|
5
|
+
"testVersion": 1,
|
|
6
6
|
"type": "module",
|
|
7
7
|
"main": "build/index.js",
|
|
8
8
|
"module": "build/index.js",
|
|
@@ -164,4 +164,4 @@
|
|
|
164
164
|
"publishConfig": {
|
|
165
165
|
"registry": "https://registry.npmjs.org/"
|
|
166
166
|
}
|
|
167
|
-
}
|
|
167
|
+
}
|