@swan-io/shared-business 13.4.9 → 13.4.10
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@swan-io/shared-business",
|
|
3
|
-
"version": "13.4.
|
|
3
|
+
"version": "13.4.10",
|
|
4
4
|
"engines": {
|
|
5
5
|
"node": ">22.12.0"
|
|
6
6
|
},
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
],
|
|
26
26
|
"license": "MIT",
|
|
27
27
|
"peerDependencies": {
|
|
28
|
-
"@swan-io/lake": "13.4.
|
|
28
|
+
"@swan-io/lake": "13.4.10"
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
31
|
"@formatjs/intl": "^3.1.6",
|
|
@@ -50,6 +50,6 @@
|
|
|
50
50
|
"@types/react-dom": "^19.1.7",
|
|
51
51
|
"@types/react-native": "^0.72.8",
|
|
52
52
|
"type-fest": "^4.41.0",
|
|
53
|
-
"@swan-io/lake": "13.4.
|
|
53
|
+
"@swan-io/lake": "13.4.10"
|
|
54
54
|
}
|
|
55
55
|
}
|
|
@@ -14,38 +14,38 @@ const styles = StyleSheet.create({
|
|
|
14
14
|
padding: 10,
|
|
15
15
|
},
|
|
16
16
|
firstSectionTitle: {
|
|
17
|
-
...getTextStyle("sans",
|
|
17
|
+
...getTextStyle("sans", 12),
|
|
18
18
|
color: colors.swan[500],
|
|
19
|
-
fontWeight: "
|
|
19
|
+
fontWeight: "400",
|
|
20
20
|
textTransform: "uppercase",
|
|
21
21
|
paddingBottom: spacings[4],
|
|
22
22
|
marginTop: "30%",
|
|
23
23
|
},
|
|
24
24
|
sectionTitle: {
|
|
25
|
-
...getTextStyle("sans",
|
|
25
|
+
...getTextStyle("sans", 12),
|
|
26
26
|
color: colors.swan[500],
|
|
27
|
-
fontWeight: "
|
|
27
|
+
fontWeight: "400",
|
|
28
28
|
textTransform: "uppercase",
|
|
29
29
|
paddingBottom: spacings[4],
|
|
30
30
|
},
|
|
31
31
|
dateTitle: {
|
|
32
|
-
...getTextStyle("sans",
|
|
32
|
+
...getTextStyle("sans", 12),
|
|
33
33
|
color: colors.swan[500],
|
|
34
34
|
paddingBottom: spacings[4],
|
|
35
35
|
},
|
|
36
36
|
totalAmount: {
|
|
37
|
-
...getTextStyle("sans",
|
|
38
|
-
fontWeight: "
|
|
37
|
+
...getTextStyle("sans", 16),
|
|
38
|
+
fontWeight: "400",
|
|
39
39
|
textAlign: "right",
|
|
40
40
|
},
|
|
41
41
|
pageTitle: {
|
|
42
|
-
...getTextStyle("sans",
|
|
43
|
-
fontWeight: "
|
|
42
|
+
...getTextStyle("sans", 16),
|
|
43
|
+
fontWeight: "400",
|
|
44
44
|
color: "#26232F",
|
|
45
45
|
},
|
|
46
46
|
titleColumn: {
|
|
47
|
-
...getTextStyle("sans",
|
|
48
|
-
fontWeight: "
|
|
47
|
+
...getTextStyle("sans", 10),
|
|
48
|
+
fontWeight: "400",
|
|
49
49
|
paddingVertical: spacings[4],
|
|
50
50
|
minWidth: spacings[96],
|
|
51
51
|
},
|
|
@@ -55,24 +55,24 @@ const styles = StyleSheet.create({
|
|
|
55
55
|
},
|
|
56
56
|
textColumn: {
|
|
57
57
|
paddingVertical: spacings[4],
|
|
58
|
-
...getTextStyle("sans",
|
|
58
|
+
...getTextStyle("sans", 8),
|
|
59
59
|
},
|
|
60
60
|
text: {
|
|
61
|
-
...getTextStyle("sans",
|
|
61
|
+
...getTextStyle("sans", 10),
|
|
62
62
|
},
|
|
63
63
|
pageSubTitle: {
|
|
64
|
-
...getTextStyle("sans",
|
|
64
|
+
...getTextStyle("sans", 10),
|
|
65
65
|
color: "#454348",
|
|
66
66
|
paddingBottom: spacings[12],
|
|
67
67
|
},
|
|
68
68
|
row: {
|
|
69
69
|
textAlign: "right",
|
|
70
70
|
paddingVertical: spacings[4],
|
|
71
|
-
fontWeight: "
|
|
71
|
+
fontWeight: "400",
|
|
72
72
|
width: "15%",
|
|
73
73
|
},
|
|
74
74
|
closingBalanceRow: {
|
|
75
|
-
...getTextStyle("sans",
|
|
75
|
+
...getTextStyle("sans", 10),
|
|
76
76
|
backgroundColor: colors.gray[50],
|
|
77
77
|
width: "50%",
|
|
78
78
|
},
|
|
@@ -3,8 +3,8 @@ import { SwanLogo } from "@swan-io/lake/src/components/SwanLogo";
|
|
|
3
3
|
import { colors } from "@swan-io/lake/src/constants/design";
|
|
4
4
|
import { isNotNullishOrEmpty } from "@swan-io/lake/src/utils/nullish";
|
|
5
5
|
import { useTranslation } from "../utils/i18n";
|
|
6
|
-
const LOGO_MAX_HEIGHT =
|
|
7
|
-
const LOGO_MAX_WIDTH =
|
|
6
|
+
const LOGO_MAX_HEIGHT = 50;
|
|
7
|
+
const LOGO_MAX_WIDTH = 300;
|
|
8
8
|
// Used to generate inline styles without css variables for PDF generation
|
|
9
9
|
const styles = {
|
|
10
10
|
container: {
|
|
@@ -27,8 +27,7 @@ const styles = {
|
|
|
27
27
|
},
|
|
28
28
|
partnershipText: {
|
|
29
29
|
fontSize: "12px",
|
|
30
|
-
lineHeight: "24px"
|
|
31
|
-
marginBottom: "4px",
|
|
30
|
+
lineHeight: "24px"
|
|
32
31
|
},
|
|
33
32
|
logo: {
|
|
34
33
|
display: "flex",
|
|
@@ -45,7 +44,7 @@ const styles = {
|
|
|
45
44
|
top: 0.5,
|
|
46
45
|
},
|
|
47
46
|
pageNumber: {
|
|
48
|
-
fontSize: "
|
|
47
|
+
fontSize: "12px",
|
|
49
48
|
color: "#26232F",
|
|
50
49
|
fontWeight: "600",
|
|
51
50
|
textTransform: "uppercase",
|
|
@@ -59,5 +58,5 @@ const logoStyle = {
|
|
|
59
58
|
};
|
|
60
59
|
export const AccountStatementHeader = ({ partnerLogoUrl, language, }) => {
|
|
61
60
|
const t = useTranslation(language);
|
|
62
|
-
return (_jsxs("div", { style: styles.container, children: [_jsxs("div", { style: styles.logo, children: [isNotNullishOrEmpty(partnerLogoUrl) ? (_jsx("img", { src: partnerLogoUrl, style: logoStyle })) : (_jsx(SwanLogo, { style: styles.defaultLogo })), _jsxs("div", { style: styles.partnership, children: [_jsx("div", { style: styles.partnershipText, children: t("accountStatement.partnership") }), _jsx(SwanLogo, { color: colors.gray[900], style: styles.swanLogo })] })] }), _jsxs("div", { style: styles.pageNumber, children: [t("accountStatement.page"), " ", _jsx("span", { className: "pageNumber" }), "
|
|
61
|
+
return (_jsxs("div", { style: styles.container, children: [_jsxs("div", { style: styles.logo, children: [isNotNullishOrEmpty(partnerLogoUrl) ? (_jsx("img", { src: partnerLogoUrl, style: logoStyle })) : (_jsx(SwanLogo, { style: styles.defaultLogo })), _jsxs("div", { style: styles.partnership, children: [_jsx("div", { style: styles.partnershipText, children: t("accountStatement.partnership") }), _jsx(SwanLogo, { color: colors.gray[900], style: styles.swanLogo })] })] }), _jsxs("div", { style: styles.pageNumber, children: [t("accountStatement.page"), " ", _jsx("span", { className: "pageNumber" }), "/", " ", _jsx("span", { className: "totalPages" })] })] }));
|
|
63
62
|
};
|