@pisell/materials 6.12.81 → 6.12.82
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/lowcode/assets-daily.json +11 -11
- package/build/lowcode/assets-dev.json +2 -2
- package/build/lowcode/assets-prod.json +11 -11
- package/build/lowcode/meta.js +1 -1
- package/build/lowcode/render/default/view.js +1 -1
- package/build/lowcode/view.js +1 -1
- package/es/components/walletCard/Guest/index.js +2 -1
- package/es/components/walletCard/index.js +11 -4
- package/lib/components/walletCard/Guest/index.js +2 -1
- package/lib/components/walletCard/index.js +11 -4
- package/package.json +2 -2
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import useEngineContext from "../../../hooks/useEngineContext.js";
|
|
2
2
|
import Button from "../../button/index.js";
|
|
3
3
|
import React from "react";
|
|
4
|
+
import { image } from "@pisell/utils";
|
|
4
5
|
import "./index.less";
|
|
5
6
|
//#region src/components/walletCard/Guest/index.tsx
|
|
6
7
|
const Guest = (props) => {
|
|
@@ -44,7 +45,7 @@ const Guest = (props) => {
|
|
|
44
45
|
style: { backgroundColor: setting === null || setting === void 0 ? void 0 : setting.backgroundColor }
|
|
45
46
|
}, (utils === null || utils === void 0 || (_utils$translation = utils.translation) === null || _utils$translation === void 0 ? void 0 : _utils$translation.call(utils, setting === null || setting === void 0 ? void 0 : setting.backgroundImage)) ? /* @__PURE__ */ React.createElement("img", {
|
|
46
47
|
className: "pisell-wallet-guest-bg",
|
|
47
|
-
src: (utils === null || utils === void 0 || (_utils$translation2 = utils.translation) === null || _utils$translation2 === void 0 ? void 0 : _utils$translation2.call(utils, setting.backgroundImage)) || "",
|
|
48
|
+
src: image.ali((utils === null || utils === void 0 || (_utils$translation2 = utils.translation) === null || _utils$translation2 === void 0 ? void 0 : _utils$translation2.call(utils, setting.backgroundImage)) || "", 175),
|
|
48
49
|
alt: (utils === null || utils === void 0 || (_utils$translation3 = utils.translation) === null || _utils$translation3 === void 0 ? void 0 : _utils$translation3.call(utils, setting === null || setting === void 0 ? void 0 : setting.backgroundImageAlt)) || "",
|
|
49
50
|
title: (utils === null || utils === void 0 || (_utils$translation4 = utils.translation) === null || _utils$translation4 === void 0 ? void 0 : _utils$translation4.call(utils, setting === null || setting === void 0 ? void 0 : setting.backgroundImageAlt)) || ""
|
|
50
51
|
}) : null, /* @__PURE__ */ React.createElement("div", { className: `pisell-wallet-guest-content ${setting.align === "center" ? "pisell-wallet-guest-center" : ""}` }, /* @__PURE__ */ React.createElement("div", null, /* @__PURE__ */ React.createElement("div", {
|
|
@@ -7,6 +7,7 @@ import Amount from "../pisellText/components/Amount/index.js";
|
|
|
7
7
|
import Guest from "./Guest/index.js";
|
|
8
8
|
import Guide from "./Guide/index.js";
|
|
9
9
|
import React, { useMemo, useState } from "react";
|
|
10
|
+
import { image } from "@pisell/utils";
|
|
10
11
|
import { Button, Card, QRCode } from "antd";
|
|
11
12
|
import classNames from "classnames";
|
|
12
13
|
import Barcode from "react-barcode";
|
|
@@ -133,7 +134,7 @@ const CardHeader = ({ showIcon = true, showWalletName = true, showShopName = tru
|
|
|
133
134
|
const processedShowCode = toBooleanValue(showCode);
|
|
134
135
|
const processedShowViewPin = toBooleanValue(showViewPin);
|
|
135
136
|
return /* @__PURE__ */ React.createElement("div", { className: "pisell-wallet-card-header" }, /* @__PURE__ */ React.createElement("div", { className: "pisell-wallet-card-header-left" }, /* @__PURE__ */ React.createElement("div", { className: "pisell-wallet-card-header-level" }, processedShowIcon && iconImg ? /* @__PURE__ */ React.createElement("div", { className: "pisell-wallet-card-header-icon" }, /* @__PURE__ */ React.createElement("img", {
|
|
136
|
-
src: iconImg,
|
|
137
|
+
src: image.ali(iconImg, 40),
|
|
137
138
|
alt: "wallet icon",
|
|
138
139
|
style: {
|
|
139
140
|
width: "20px",
|
|
@@ -244,11 +245,17 @@ const WalletCard = (props) => {
|
|
|
244
245
|
const { isModalOpen, handleCodeClick, closeModal } = useCodeModal(cardNo, onCodeClick, codeType);
|
|
245
246
|
console.log("showViewPin", props);
|
|
246
247
|
const backgroundStyle = useMemo(() => {
|
|
247
|
-
if (props.customBackgroundImage) return { backgroundImage: `url(${props.customBackgroundImage})` };
|
|
248
|
+
if (props.customBackgroundImage) return { backgroundImage: `url(${image.ali(props.customBackgroundImage, 175)})` };
|
|
248
249
|
else {
|
|
249
|
-
var _props$walletGuideCon;
|
|
250
|
+
var _props$walletGuideCon, _constants;
|
|
250
251
|
if ((props === null || props === void 0 || (_props$walletGuideCon = props.walletGuideConfig) === null || _props$walletGuideCon === void 0 ? void 0 : _props$walletGuideCon.backgroundColor) && isGuide || (props === null || props === void 0 ? void 0 : props.backgroundColor) && !isLogin) return { backgroundImage: "none" };
|
|
251
|
-
|
|
252
|
+
let staticUrl = (_constants = constants) === null || _constants === void 0 ? void 0 : _constants.staticURL;
|
|
253
|
+
if (!staticUrl) {
|
|
254
|
+
var _constants2;
|
|
255
|
+
staticUrl = ((_constants2 = constants) === null || _constants2 === void 0 || (_constants2 = _constants2.config) === null || _constants2 === void 0 ? void 0 : _constants2.awsStatic) || "https://static.pisellcdn.com";
|
|
256
|
+
}
|
|
257
|
+
const backgroundImage = `${staticUrl}/${mode === "dark" ? "dark_wallet.png" : "light_wallet.png"}`;
|
|
258
|
+
return { backgroundImage: `url(${image.ali(backgroundImage, 175)})` };
|
|
252
259
|
}
|
|
253
260
|
}, [
|
|
254
261
|
props.customBackgroundImage,
|
|
@@ -3,6 +3,7 @@ const require_useEngineContext = require("../../../hooks/useEngineContext.js");
|
|
|
3
3
|
const require_index = require("../../button/index.js");
|
|
4
4
|
let react = require("react");
|
|
5
5
|
react = require_runtime.__toESM(react);
|
|
6
|
+
let _pisell_utils = require("@pisell/utils");
|
|
6
7
|
require("./index.less");
|
|
7
8
|
//#region src/components/walletCard/Guest/index.tsx
|
|
8
9
|
const Guest = (props) => {
|
|
@@ -46,7 +47,7 @@ const Guest = (props) => {
|
|
|
46
47
|
style: { backgroundColor: setting === null || setting === void 0 ? void 0 : setting.backgroundColor }
|
|
47
48
|
}, (utils === null || utils === void 0 || (_utils$translation = utils.translation) === null || _utils$translation === void 0 ? void 0 : _utils$translation.call(utils, setting === null || setting === void 0 ? void 0 : setting.backgroundImage)) ? /* @__PURE__ */ react.default.createElement("img", {
|
|
48
49
|
className: "pisell-wallet-guest-bg",
|
|
49
|
-
src: (utils === null || utils === void 0 || (_utils$translation2 = utils.translation) === null || _utils$translation2 === void 0 ? void 0 : _utils$translation2.call(utils, setting.backgroundImage)) || "",
|
|
50
|
+
src: _pisell_utils.image.ali((utils === null || utils === void 0 || (_utils$translation2 = utils.translation) === null || _utils$translation2 === void 0 ? void 0 : _utils$translation2.call(utils, setting.backgroundImage)) || "", 175),
|
|
50
51
|
alt: (utils === null || utils === void 0 || (_utils$translation3 = utils.translation) === null || _utils$translation3 === void 0 ? void 0 : _utils$translation3.call(utils, setting === null || setting === void 0 ? void 0 : setting.backgroundImageAlt)) || "",
|
|
51
52
|
title: (utils === null || utils === void 0 || (_utils$translation4 = utils.translation) === null || _utils$translation4 === void 0 ? void 0 : _utils$translation4.call(utils, setting === null || setting === void 0 ? void 0 : setting.backgroundImageAlt)) || ""
|
|
52
53
|
}) : null, /* @__PURE__ */ react.default.createElement("div", { className: `pisell-wallet-guest-content ${setting.align === "center" ? "pisell-wallet-guest-center" : ""}` }, /* @__PURE__ */ react.default.createElement("div", null, /* @__PURE__ */ react.default.createElement("div", {
|
|
@@ -9,6 +9,7 @@ const require_index$4 = require("./Guest/index.js");
|
|
|
9
9
|
const require_index$5 = require("./Guide/index.js");
|
|
10
10
|
let react = require("react");
|
|
11
11
|
react = require_runtime.__toESM(react);
|
|
12
|
+
let _pisell_utils = require("@pisell/utils");
|
|
12
13
|
let antd = require("antd");
|
|
13
14
|
let classnames = require("classnames");
|
|
14
15
|
classnames = require_runtime.__toESM(classnames);
|
|
@@ -138,7 +139,7 @@ const CardHeader = ({ showIcon = true, showWalletName = true, showShopName = tru
|
|
|
138
139
|
const processedShowCode = toBooleanValue(showCode);
|
|
139
140
|
const processedShowViewPin = toBooleanValue(showViewPin);
|
|
140
141
|
return /* @__PURE__ */ react.default.createElement("div", { className: "pisell-wallet-card-header" }, /* @__PURE__ */ react.default.createElement("div", { className: "pisell-wallet-card-header-left" }, /* @__PURE__ */ react.default.createElement("div", { className: "pisell-wallet-card-header-level" }, processedShowIcon && iconImg ? /* @__PURE__ */ react.default.createElement("div", { className: "pisell-wallet-card-header-icon" }, /* @__PURE__ */ react.default.createElement("img", {
|
|
141
|
-
src: iconImg,
|
|
142
|
+
src: _pisell_utils.image.ali(iconImg, 40),
|
|
142
143
|
alt: "wallet icon",
|
|
143
144
|
style: {
|
|
144
145
|
width: "20px",
|
|
@@ -249,11 +250,17 @@ const WalletCard = (props) => {
|
|
|
249
250
|
const { isModalOpen, handleCodeClick, closeModal } = useCodeModal(cardNo, onCodeClick, codeType);
|
|
250
251
|
console.log("showViewPin", props);
|
|
251
252
|
const backgroundStyle = (0, react.useMemo)(() => {
|
|
252
|
-
if (props.customBackgroundImage) return { backgroundImage: `url(${props.customBackgroundImage})` };
|
|
253
|
+
if (props.customBackgroundImage) return { backgroundImage: `url(${_pisell_utils.image.ali(props.customBackgroundImage, 175)})` };
|
|
253
254
|
else {
|
|
254
|
-
var _props$walletGuideCon;
|
|
255
|
+
var _props$walletGuideCon, _constants;
|
|
255
256
|
if ((props === null || props === void 0 || (_props$walletGuideCon = props.walletGuideConfig) === null || _props$walletGuideCon === void 0 ? void 0 : _props$walletGuideCon.backgroundColor) && isGuide || (props === null || props === void 0 ? void 0 : props.backgroundColor) && !isLogin) return { backgroundImage: "none" };
|
|
256
|
-
|
|
257
|
+
let staticUrl = (_constants = constants) === null || _constants === void 0 ? void 0 : _constants.staticURL;
|
|
258
|
+
if (!staticUrl) {
|
|
259
|
+
var _constants2;
|
|
260
|
+
staticUrl = ((_constants2 = constants) === null || _constants2 === void 0 || (_constants2 = _constants2.config) === null || _constants2 === void 0 ? void 0 : _constants2.awsStatic) || "https://static.pisellcdn.com";
|
|
261
|
+
}
|
|
262
|
+
const backgroundImage = `${staticUrl}/${mode === "dark" ? "dark_wallet.png" : "light_wallet.png"}`;
|
|
263
|
+
return { backgroundImage: `url(${_pisell_utils.image.ali(backgroundImage, 175)})` };
|
|
257
264
|
}
|
|
258
265
|
}, [
|
|
259
266
|
props.customBackgroundImage,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pisell/materials",
|
|
3
|
-
"version": "6.12.
|
|
3
|
+
"version": "6.12.82",
|
|
4
4
|
"main": "./lib/index.js",
|
|
5
5
|
"module": "./es/index.js",
|
|
6
6
|
"types": "./lib/index.d.ts",
|
|
@@ -95,8 +95,8 @@
|
|
|
95
95
|
"swiper": "^8.4.7",
|
|
96
96
|
"antd-mobile": "^5.38.1",
|
|
97
97
|
"vod-js-sdk-v6": "^1.4.11",
|
|
98
|
-
"@pisell/date-picker": "3.0.12",
|
|
99
98
|
"@pisell/icon": "0.0.11",
|
|
99
|
+
"@pisell/date-picker": "3.0.12",
|
|
100
100
|
"@pisell/utils": "3.0.7"
|
|
101
101
|
},
|
|
102
102
|
"peerDependencies": {
|