pb-sxp-ui 1.0.62 → 1.0.64

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.
@@ -1,5 +1,4 @@
1
1
  import React, { memo, useCallback, useEffect, useMemo, useRef, useState } from 'react';
2
- import Hls from 'hls.js';
3
2
  import { useIconLink } from '../SxpPageRender/useIconLink';
4
3
  import FormatImage from '../SxpPageRender/FormatImage';
5
4
  import { useSxpDataSource } from '../../../core/hooks';
@@ -139,8 +138,8 @@ const VideoWidget = ({ rec, index, height, data, muted, activeIndex, videoPostCo
139
138
  if (!videoRef.current.src) {
140
139
  const videoSrc = rec.video.url;
141
140
  if (videoSrc.includes('.m3u8')) {
142
- if (Hls.isSupported()) {
143
- const hls = new Hls();
141
+ if (typeof window !== 'undefined' && (window === null || window === void 0 ? void 0 : window.Hls.isSupported())) {
142
+ const hls = new window.Hls();
144
143
  hls.loadSource(videoSrc);
145
144
  hls.attachMedia(videoRef.current);
146
145
  }
@@ -1,4 +1,4 @@
1
- import React, { forwardRef, memo, useEffect, useImperativeHandle, useState } from 'react';
1
+ import React, { forwardRef, memo, useEffect, useImperativeHandle, useRef, useState } from 'react';
2
2
  const FormatImage = forwardRef((props, ref) => {
3
3
  const { src, onLoad, style, className, loading } = props;
4
4
  const [imgSrc, setImgSrc] = useState();
@@ -7,10 +7,28 @@ const FormatImage = forwardRef((props, ref) => {
7
7
  setImgSrc(v);
8
8
  }
9
9
  }));
10
+ const imgRef = useRef(null);
10
11
  useEffect(() => {
11
- setImgSrc(src);
12
+ let observer = null;
13
+ const { current } = imgRef;
14
+ if (current) {
15
+ observer = new IntersectionObserver((entries) => {
16
+ entries.forEach((entry) => {
17
+ if (entry.isIntersecting) {
18
+ setImgSrc(src);
19
+ observer.unobserve(current);
20
+ }
21
+ });
22
+ }, { threshold: 0.1 });
23
+ observer.observe(current);
24
+ }
25
+ return () => {
26
+ if (observer && current) {
27
+ observer.unobserve(current);
28
+ }
29
+ };
12
30
  }, [src]);
13
- return (React.createElement(React.Fragment, null, (imgSrc === null || imgSrc === void 0 ? void 0 : imgSrc.includes('.avif')) ? (React.createElement("picture", null,
31
+ return (React.createElement("div", { ref: imgRef }, (imgSrc === null || imgSrc === void 0 ? void 0 : imgSrc.includes('.avif')) ? (React.createElement("picture", null,
14
32
  React.createElement("source", { type: 'image/avif', srcSet: imgSrc }),
15
33
  React.createElement("source", { type: 'image/webp', srcSet: `${imgSrc}?imageMogr2/format/webp` }),
16
34
  React.createElement("source", { type: 'image/jpeg', srcSet: `${imgSrc}?imageMogr2/format/jpg` }),
@@ -181,6 +181,7 @@ const VideoWidget = ({ rec, index, height, data, muted, activeIndex, videoPostCo
181
181
  const videoSrc = rec.video.url;
182
182
  if (!videoSrc)
183
183
  return;
184
+ videoRef === null || videoRef === void 0 ? void 0 : videoRef.src(videoSrc);
184
185
  setIsPauseVideo(false);
185
186
  const videoPlayerWrapperNode = document.querySelector(`#${videoId}`);
186
187
  const dom = document.querySelector('#player-container-id');
@@ -188,7 +189,6 @@ const VideoWidget = ({ rec, index, height, data, muted, activeIndex, videoPostCo
188
189
  if (!dom && !dom2)
189
190
  return;
190
191
  videoPlayerWrapperNode === null || videoPlayerWrapperNode === void 0 ? void 0 : videoPlayerWrapperNode.appendChild(dom || dom2);
191
- videoRef === null || videoRef === void 0 ? void 0 : videoRef.src(videoSrc);
192
192
  videoRef === null || videoRef === void 0 ? void 0 : videoRef.on('loadedmetadata', handleLoadedmetadata);
193
193
  videoRef === null || videoRef === void 0 ? void 0 : videoRef.on('loadeddata', handLoadeddata);
194
194
  videoRef === null || videoRef === void 0 ? void 0 : videoRef.on('playing', handlePlaying);
@@ -155,12 +155,16 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
155
155
  return res === null || res === void 0 ? void 0 : res.success;
156
156
  }), [bffFetch]);
157
157
  const bffGetTagList = useCallback(() => __awaiter(void 0, void 0, void 0, function* () {
158
- var _h, _j;
158
+ var _h, _j, _k, _l, _m;
159
159
  if (!utmVal)
160
160
  return;
161
161
  try {
162
- const result = yield (bffFetch === null || bffFetch === void 0 ? void 0 : bffFetch('/tag/list', { method: 'GET', query: { channel: utmVal } }));
163
- setTagList((_j = (_h = result === null || result === void 0 ? void 0 : result.data) === null || _h === void 0 ? void 0 : _h.tags) !== null && _j !== void 0 ? _j : []);
162
+ const val = (_k = (_j = (_h = utmVal === null || utmVal === void 0 ? void 0 : utmVal.split('&')) === null || _h === void 0 ? void 0 : _h.filter((val) => {
163
+ const key = val.split('=')[0];
164
+ return UTM_KEYS.includes(key);
165
+ })) === null || _j === void 0 ? void 0 : _j.join('&')) !== null && _k !== void 0 ? _k : '';
166
+ const result = yield (bffFetch === null || bffFetch === void 0 ? void 0 : bffFetch('/tag/list', { method: 'GET', query: { channel: decodeURIComponent(val) } }));
167
+ setTagList((_m = (_l = result === null || result === void 0 ? void 0 : result.data) === null || _l === void 0 ? void 0 : _l.tags) !== null && _m !== void 0 ? _m : []);
164
168
  }
165
169
  catch (e) {
166
170
  console.log('e', e);
@@ -66,10 +66,10 @@ const CommodityDetail = (_a) => {
66
66
  React.createElement("div", { className: 'pb-commondity-content-title', style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.title, hidden: !!product && !(product === null || product === void 0 ? void 0 : product.title) }, (_b = product === null || product === void 0 ? void 0 : product.title) !== null && _b !== void 0 ? _b : 'Pendant in Yellow Gold with Diamonds, Medium'),
67
67
  React.createElement("div", { className: 'pb-commondity-content-price', style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.price, hidden: !!product && !(product === null || product === void 0 ? void 0 : product.price) }, priceText),
68
68
  React.createElement("div", { hidden: !!product && (!(product === null || product === void 0 ? void 0 : product.info) || (product === null || product === void 0 ? void 0 : product.info) === '') },
69
- React.createElement(ExpandableText, { foldText: tipText === null || tipText === void 0 ? void 0 : tipText.foldText, unfoldText: tipText === null || tipText === void 0 ? void 0 : tipText.unfoldText, onClick: () => setShowModal(true), isPost: isPost, text: (_c = product === null || product === void 0 ? void 0 : product.info) !== null && _c !== void 0 ? _c : `The design inspiration of Tiffany Lock series comes from the power of connection and inclusiveness, and the
70
- bold and avant-garde visual design interprets the emotional bond connecting my heart. The Tiffany Lock
71
- collection is unisex and is inspired by the padlock pattern found in the Tiffany Antique Collection. This
72
- necklace features a stylish and eye-catching oval clasp chain decorated with a lock pattern. Crafted from
69
+ React.createElement(ExpandableText, { foldText: tipText === null || tipText === void 0 ? void 0 : tipText.foldText, unfoldText: tipText === null || tipText === void 0 ? void 0 : tipText.unfoldText, onClick: () => setShowModal(true), isPost: isPost, text: (_c = product === null || product === void 0 ? void 0 : product.info) !== null && _c !== void 0 ? _c : `The design inspiration of Tiffany Lock series comes from the power of connection and inclusiveness, and the
70
+ bold and avant-garde visual design interprets the emotional bond connecting my heart. The Tiffany Lock
71
+ collection is unisex and is inspired by the padlock pattern found in the Tiffany Antique Collection. This
72
+ necklace features a stylish and eye-catching oval clasp chain decorated with a lock pattern. Crafted from
73
73
  18-karat gold, this necklace is embellished with hand-set diamonds.`, maxStr: 79, className: 'pb-commondity-content-info', style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.info }))));
74
74
  };
75
75
  const renderBtn = () => {
@@ -91,7 +91,7 @@ const CommodityDetailDiroNew = (_a) => {
91
91
  const productInfoText = ({ isPost }) => {
92
92
  return (React.createElement("div", { hidden: !!product && (!(product === null || product === void 0 ? void 0 : product.info) || (product === null || product === void 0 ? void 0 : product.info) === '') },
93
93
  React.createElement(ExpandableText, { isPost: isPost, onClick: () => setShowModal(true), className: 'pb-commondityDiroNew-info', style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.info, foldText: tipText === null || tipText === void 0 ? void 0 : tipText.foldText, unfoldText: tipText === null || tipText === void 0 ? void 0 : tipText.unfoldText, text: (product === null || product === void 0 ? void 0 : product.info) ||
94
- `Unveiled at the Spring-Summer 2023 fashion show, the Dior Toujours bag is distinguished by a casual and practical design. Crafted in black calfskin with Macrocannage topstitching, it showcases a spacious interior compartment with a matching pouch to organize essentials. Its leather strap closure keeps items secure while the D of the CD Lock closure twists to adjust the sides and enhance the bag's silhouette. The leather handles can be adjusted using the small notches in order to be able to carry the large bag by hand or wear it over the shoulder. CD Lock and strap closures D.I.O.R. charms Removable interior pouch Adjustable leather handles Dust bag included
94
+ `Unveiled at the Spring-Summer 2023 fashion show, the Dior Toujours bag is distinguished by a casual and practical design. Crafted in black calfskin with Macrocannage topstitching, it showcases a spacious interior compartment with a matching pouch to organize essentials. Its leather strap closure keeps items secure while the D of the CD Lock closure twists to adjust the sides and enhance the bag's silhouette. The leather handles can be adjusted using the small notches in order to be able to carry the large bag by hand or wear it over the shoulder. CD Lock and strap closures D.I.O.R. charms Removable interior pouch Adjustable leather handles Dust bag included
95
95
  Made in Italy` })));
96
96
  };
97
97
  return (React.createElement("div", { className: 'pb-commondityDiroNew' },
@@ -2,7 +2,6 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
4
  const react_1 = tslib_1.__importStar(require("react"));
5
- const hls_js_1 = tslib_1.__importDefault(require("hls.js"));
6
5
  const useIconLink_1 = require("../SxpPageRender/useIconLink");
7
6
  const FormatImage_1 = tslib_1.__importDefault(require("../SxpPageRender/FormatImage"));
8
7
  const hooks_1 = require("../../../core/hooks");
@@ -142,8 +141,8 @@ const VideoWidget = ({ rec, index, height, data, muted, activeIndex, videoPostCo
142
141
  if (!videoRef.current.src) {
143
142
  const videoSrc = rec.video.url;
144
143
  if (videoSrc.includes('.m3u8')) {
145
- if (hls_js_1.default.isSupported()) {
146
- const hls = new hls_js_1.default();
144
+ if (typeof window !== 'undefined' && (window === null || window === void 0 ? void 0 : window.Hls.isSupported())) {
145
+ const hls = new window.Hls();
147
146
  hls.loadSource(videoSrc);
148
147
  hls.attachMedia(videoRef.current);
149
148
  }
@@ -10,10 +10,28 @@ const FormatImage = (0, react_1.forwardRef)((props, ref) => {
10
10
  setImgSrc(v);
11
11
  }
12
12
  }));
13
+ const imgRef = (0, react_1.useRef)(null);
13
14
  (0, react_1.useEffect)(() => {
14
- setImgSrc(src);
15
+ let observer = null;
16
+ const { current } = imgRef;
17
+ if (current) {
18
+ observer = new IntersectionObserver((entries) => {
19
+ entries.forEach((entry) => {
20
+ if (entry.isIntersecting) {
21
+ setImgSrc(src);
22
+ observer.unobserve(current);
23
+ }
24
+ });
25
+ }, { threshold: 0.1 });
26
+ observer.observe(current);
27
+ }
28
+ return () => {
29
+ if (observer && current) {
30
+ observer.unobserve(current);
31
+ }
32
+ };
15
33
  }, [src]);
16
- return (react_1.default.createElement(react_1.default.Fragment, null, (imgSrc === null || imgSrc === void 0 ? void 0 : imgSrc.includes('.avif')) ? (react_1.default.createElement("picture", null,
34
+ return (react_1.default.createElement("div", { ref: imgRef }, (imgSrc === null || imgSrc === void 0 ? void 0 : imgSrc.includes('.avif')) ? (react_1.default.createElement("picture", null,
17
35
  react_1.default.createElement("source", { type: 'image/avif', srcSet: imgSrc }),
18
36
  react_1.default.createElement("source", { type: 'image/webp', srcSet: `${imgSrc}?imageMogr2/format/webp` }),
19
37
  react_1.default.createElement("source", { type: 'image/jpeg', srcSet: `${imgSrc}?imageMogr2/format/jpg` }),
@@ -184,6 +184,7 @@ const VideoWidget = ({ rec, index, height, data, muted, activeIndex, videoPostCo
184
184
  const videoSrc = rec.video.url;
185
185
  if (!videoSrc)
186
186
  return;
187
+ videoRef === null || videoRef === void 0 ? void 0 : videoRef.src(videoSrc);
187
188
  setIsPauseVideo(false);
188
189
  const videoPlayerWrapperNode = document.querySelector(`#${videoId}`);
189
190
  const dom = document.querySelector('#player-container-id');
@@ -191,7 +192,6 @@ const VideoWidget = ({ rec, index, height, data, muted, activeIndex, videoPostCo
191
192
  if (!dom && !dom2)
192
193
  return;
193
194
  videoPlayerWrapperNode === null || videoPlayerWrapperNode === void 0 ? void 0 : videoPlayerWrapperNode.appendChild(dom || dom2);
194
- videoRef === null || videoRef === void 0 ? void 0 : videoRef.src(videoSrc);
195
195
  videoRef === null || videoRef === void 0 ? void 0 : videoRef.on('loadedmetadata', handleLoadedmetadata);
196
196
  videoRef === null || videoRef === void 0 ? void 0 : videoRef.on('loadeddata', handLoadeddata);
197
197
  videoRef === null || videoRef === void 0 ? void 0 : videoRef.on('playing', handlePlaying);
@@ -158,12 +158,16 @@ const SxpDataSourceProvider = ({ render, dataSources, utmVal, enableReportEvent
158
158
  return res === null || res === void 0 ? void 0 : res.success;
159
159
  }), [bffFetch]);
160
160
  const bffGetTagList = (0, react_1.useCallback)(() => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
161
- var _h, _j;
161
+ var _h, _j, _k, _l, _m;
162
162
  if (!utmVal)
163
163
  return;
164
164
  try {
165
- const result = yield (bffFetch === null || bffFetch === void 0 ? void 0 : bffFetch('/tag/list', { method: 'GET', query: { channel: utmVal } }));
166
- setTagList((_j = (_h = result === null || result === void 0 ? void 0 : result.data) === null || _h === void 0 ? void 0 : _h.tags) !== null && _j !== void 0 ? _j : []);
165
+ const val = (_k = (_j = (_h = utmVal === null || utmVal === void 0 ? void 0 : utmVal.split('&')) === null || _h === void 0 ? void 0 : _h.filter((val) => {
166
+ const key = val.split('=')[0];
167
+ return UTM_KEYS.includes(key);
168
+ })) === null || _j === void 0 ? void 0 : _j.join('&')) !== null && _k !== void 0 ? _k : '';
169
+ const result = yield (bffFetch === null || bffFetch === void 0 ? void 0 : bffFetch('/tag/list', { method: 'GET', query: { channel: decodeURIComponent(val) } }));
170
+ setTagList((_m = (_l = result === null || result === void 0 ? void 0 : result.data) === null || _l === void 0 ? void 0 : _l.tags) !== null && _m !== void 0 ? _m : []);
167
171
  }
168
172
  catch (e) {
169
173
  console.log('e', e);
@@ -68,10 +68,10 @@ const CommodityDetail = (_a) => {
68
68
  react_1.default.createElement("div", { className: 'pb-commondity-content-title', style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.title, hidden: !!product && !(product === null || product === void 0 ? void 0 : product.title) }, (_b = product === null || product === void 0 ? void 0 : product.title) !== null && _b !== void 0 ? _b : 'Pendant in Yellow Gold with Diamonds, Medium'),
69
69
  react_1.default.createElement("div", { className: 'pb-commondity-content-price', style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.price, hidden: !!product && !(product === null || product === void 0 ? void 0 : product.price) }, priceText),
70
70
  react_1.default.createElement("div", { hidden: !!product && (!(product === null || product === void 0 ? void 0 : product.info) || (product === null || product === void 0 ? void 0 : product.info) === '') },
71
- react_1.default.createElement(ExpandableText_1.default, { foldText: tipText === null || tipText === void 0 ? void 0 : tipText.foldText, unfoldText: tipText === null || tipText === void 0 ? void 0 : tipText.unfoldText, onClick: () => setShowModal(true), isPost: isPost, text: (_c = product === null || product === void 0 ? void 0 : product.info) !== null && _c !== void 0 ? _c : `The design inspiration of Tiffany Lock series comes from the power of connection and inclusiveness, and the
72
- bold and avant-garde visual design interprets the emotional bond connecting my heart. The Tiffany Lock
73
- collection is unisex and is inspired by the padlock pattern found in the Tiffany Antique Collection. This
74
- necklace features a stylish and eye-catching oval clasp chain decorated with a lock pattern. Crafted from
71
+ react_1.default.createElement(ExpandableText_1.default, { foldText: tipText === null || tipText === void 0 ? void 0 : tipText.foldText, unfoldText: tipText === null || tipText === void 0 ? void 0 : tipText.unfoldText, onClick: () => setShowModal(true), isPost: isPost, text: (_c = product === null || product === void 0 ? void 0 : product.info) !== null && _c !== void 0 ? _c : `The design inspiration of Tiffany Lock series comes from the power of connection and inclusiveness, and the
72
+ bold and avant-garde visual design interprets the emotional bond connecting my heart. The Tiffany Lock
73
+ collection is unisex and is inspired by the padlock pattern found in the Tiffany Antique Collection. This
74
+ necklace features a stylish and eye-catching oval clasp chain decorated with a lock pattern. Crafted from
75
75
  18-karat gold, this necklace is embellished with hand-set diamonds.`, maxStr: 79, className: 'pb-commondity-content-info', style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.info }))));
76
76
  };
77
77
  const renderBtn = () => {
@@ -93,7 +93,7 @@ const CommodityDetailDiroNew = (_a) => {
93
93
  const productInfoText = ({ isPost }) => {
94
94
  return (react_1.default.createElement("div", { hidden: !!product && (!(product === null || product === void 0 ? void 0 : product.info) || (product === null || product === void 0 ? void 0 : product.info) === '') },
95
95
  react_1.default.createElement(ExpandableText_1.default, { isPost: isPost, onClick: () => setShowModal(true), className: 'pb-commondityDiroNew-info', style: commodityStyles === null || commodityStyles === void 0 ? void 0 : commodityStyles.info, foldText: tipText === null || tipText === void 0 ? void 0 : tipText.foldText, unfoldText: tipText === null || tipText === void 0 ? void 0 : tipText.unfoldText, text: (product === null || product === void 0 ? void 0 : product.info) ||
96
- `Unveiled at the Spring-Summer 2023 fashion show, the Dior Toujours bag is distinguished by a casual and practical design. Crafted in black calfskin with Macrocannage topstitching, it showcases a spacious interior compartment with a matching pouch to organize essentials. Its leather strap closure keeps items secure while the D of the CD Lock closure twists to adjust the sides and enhance the bag's silhouette. The leather handles can be adjusted using the small notches in order to be able to carry the large bag by hand or wear it over the shoulder. CD Lock and strap closures D.I.O.R. charms Removable interior pouch Adjustable leather handles Dust bag included
96
+ `Unveiled at the Spring-Summer 2023 fashion show, the Dior Toujours bag is distinguished by a casual and practical design. Crafted in black calfskin with Macrocannage topstitching, it showcases a spacious interior compartment with a matching pouch to organize essentials. Its leather strap closure keeps items secure while the D of the CD Lock closure twists to adjust the sides and enhance the bag's silhouette. The leather handles can be adjusted using the small notches in order to be able to carry the large bag by hand or wear it over the shoulder. CD Lock and strap closures D.I.O.R. charms Removable interior pouch Adjustable leather handles Dust bag included
97
97
  Made in Italy` })));
98
98
  };
99
99
  return (react_1.default.createElement("div", { className: 'pb-commondityDiroNew' },
package/package.json CHANGED
@@ -1,115 +1,114 @@
1
- {
2
- "name": "pb-sxp-ui",
3
- "version": "1.0.62",
4
- "description": "React enterprise-class UI components",
5
- "main": "dist/index.cjs",
6
- "module": "dist/index.js",
7
- "unpkg": "dist/pb-ui.min.js",
8
- "typings": "es/index.d.ts",
9
- "type": "module",
10
- "scripts": {
11
- "prebuild": "rimraf lib && rimraf es && rimraf dist",
12
- "build": "tsc --build tsconfig.es.json && tsc --build tsconfig.cjs.json",
13
- "postbuild": "tsc-alias -p tsconfig.es.json && tsc-alias -p tsconfig.cjs.json",
14
- "package": "npm run build && cross-env NODE_ENV=production rollup -c --configPlugin typescript",
15
- "start": "npm run build && cross-env NODE_ENV=development rollup -w -c",
16
- "lint": "eslint .",
17
- "lint:fix": "eslint --fix .",
18
- "dev": "rollup -w -c",
19
- "dev:package": "npm run build && rollup -w -c",
20
- "pub": "zx ./scripts/publish.mjs"
21
- },
22
- "files": [
23
- "dist",
24
- "lib",
25
- "es",
26
- "package.json",
27
- "README.md"
28
- ],
29
- "keywords": [
30
- "antd",
31
- "react",
32
- "react-component",
33
- "ui",
34
- "component",
35
- "components"
36
- ],
37
- "author": "frontend@chatlabs.cn",
38
- "license": "MIT",
39
- "dependencies": {
40
- "@ant-design/pro-components": "^2.6.35",
41
- "@emotion/css": "^11.11.2",
42
- "antd": "^5.15.3",
43
- "eslint": "^8.48.0",
44
- "eventemitter3": "^5.0.1",
45
- "hls.js": "^1.5.8",
46
- "less": "^4.2.0",
47
- "lodash": "^4.17.21",
48
- "pako": "^2.1.0",
49
- "qs": "^6.11.2",
50
- "swiper": "^11.0.3",
51
- "uuid": "^9.0.1"
52
- },
53
- "devDependencies": {
54
- "@babel/core": "^7.22.11",
55
- "@babel/plugin-transform-runtime": "^7.22.10",
56
- "@babel/preset-env": "^7.22.10",
57
- "@rollup/plugin-alias": "^5.0.0",
58
- "@rollup/plugin-babel": "^6.0.3",
59
- "@rollup/plugin-commonjs": "^25.0.4",
60
- "@rollup/plugin-eslint": "^9.0.4",
61
- "@rollup/plugin-image": "^3.0.2",
62
- "@rollup/plugin-json": "^6.0.0",
63
- "@rollup/plugin-node-resolve": "^15.2.0",
64
- "@rollup/plugin-typescript": "^11.1.2",
65
- "@rollup/plugin-url": "^8.0.1",
66
- "@svgr/rollup": "^8.1.0",
67
- "@types/crypto-js": "^4.1.3",
68
- "@types/lodash": "^4.14.198",
69
- "@types/node": "^20.5.3",
70
- "@types/pako": "^2.0.3",
71
- "@types/qs": "^6.9.8",
72
- "@types/react": "^18.2.21",
73
- "@types/react-dom": "^18.2.14",
74
- "@types/uuid": "^9.0.7",
75
- "@typescript-eslint/eslint-plugin": "^6.6.0",
76
- "@typescript-eslint/parser": "^6.6.0",
77
- "autoprefixer": "^10.4.15",
78
- "cross-env": "^7.0.3",
79
- "cssnano": "^6.0.1",
80
- "esbuild": "^0.19.2",
81
- "eslint-config-standard": "^17.1.0",
82
- "eslint-config-standard-react": "^13.0.0",
83
- "eslint-plugin-import": "^2.28.1",
84
- "eslint-plugin-n": "^16.0.2",
85
- "eslint-plugin-promise": "^6.1.1",
86
- "eslint-plugin-react": "^7.33.2",
87
- "eslint-plugin-react-hooks": "^4.6.0",
88
- "eslint-plugin-unused-imports": "^3.0.0",
89
- "postcss": "^8.4.28",
90
- "querystring": "^0.2.1",
91
- "react": "^18.2.0",
92
- "react-dom": "^18.2.0",
93
- "rimraf": "^5.0.1",
94
- "rollup": "^3.28.1",
95
- "rollup-plugin-esbuild": "^5.0.0",
96
- "rollup-plugin-postcss": "^4.0.2",
97
- "rollup-plugin-terser": "^7.0.2",
98
- "tsc-alias": "^1.8.7",
99
- "tslib": "^2.6.2",
100
- "typescript": "^5.1.6",
101
- "zx": "^7.2.3"
102
- },
103
- "peerDependencies": {
104
- "react": ">=16.9.0",
105
- "react-dom": ">=16.9.0"
106
- },
107
- "browserslist": [
108
- "defaults",
109
- "not ie < 8",
110
- "last 2 versions",
111
- "> 1%",
112
- "iOS 7",
113
- "last 3 iOS versions"
114
- ]
115
- }
1
+ {
2
+ "name": "pb-sxp-ui",
3
+ "version": "1.0.64",
4
+ "description": "React enterprise-class UI components",
5
+ "main": "dist/index.cjs",
6
+ "module": "dist/index.js",
7
+ "unpkg": "dist/pb-ui.min.js",
8
+ "typings": "es/index.d.ts",
9
+ "type": "module",
10
+ "scripts": {
11
+ "prebuild": "rimraf lib && rimraf es && rimraf dist",
12
+ "build": "tsc --build tsconfig.es.json && tsc --build tsconfig.cjs.json",
13
+ "postbuild": "tsc-alias -p tsconfig.es.json && tsc-alias -p tsconfig.cjs.json",
14
+ "package": "npm run build && cross-env NODE_ENV=production rollup -c --configPlugin typescript",
15
+ "start": "npm run build && cross-env NODE_ENV=development rollup -w -c",
16
+ "lint": "eslint .",
17
+ "lint:fix": "eslint --fix .",
18
+ "dev": "rollup -w -c",
19
+ "dev:package": "npm run build && rollup -w -c",
20
+ "pub": "zx ./scripts/publish.mjs"
21
+ },
22
+ "files": [
23
+ "dist",
24
+ "lib",
25
+ "es",
26
+ "package.json",
27
+ "README.md"
28
+ ],
29
+ "keywords": [
30
+ "antd",
31
+ "react",
32
+ "react-component",
33
+ "ui",
34
+ "component",
35
+ "components"
36
+ ],
37
+ "author": "frontend@chatlabs.cn",
38
+ "license": "MIT",
39
+ "dependencies": {
40
+ "@ant-design/pro-components": "^2.6.35",
41
+ "@emotion/css": "^11.11.2",
42
+ "antd": "^5.15.3",
43
+ "eslint": "^8.48.0",
44
+ "eventemitter3": "^5.0.1",
45
+ "less": "^4.2.0",
46
+ "lodash": "^4.17.21",
47
+ "pako": "^2.1.0",
48
+ "qs": "^6.11.2",
49
+ "swiper": "^11.0.3",
50
+ "uuid": "^9.0.1"
51
+ },
52
+ "devDependencies": {
53
+ "@babel/core": "^7.22.11",
54
+ "@babel/plugin-transform-runtime": "^7.22.10",
55
+ "@babel/preset-env": "^7.22.10",
56
+ "@rollup/plugin-alias": "^5.0.0",
57
+ "@rollup/plugin-babel": "^6.0.3",
58
+ "@rollup/plugin-commonjs": "^25.0.4",
59
+ "@rollup/plugin-eslint": "^9.0.4",
60
+ "@rollup/plugin-image": "^3.0.2",
61
+ "@rollup/plugin-json": "^6.0.0",
62
+ "@rollup/plugin-node-resolve": "^15.2.0",
63
+ "@rollup/plugin-typescript": "^11.1.2",
64
+ "@rollup/plugin-url": "^8.0.1",
65
+ "@svgr/rollup": "^8.1.0",
66
+ "@types/crypto-js": "^4.1.3",
67
+ "@types/lodash": "^4.14.198",
68
+ "@types/node": "^20.5.3",
69
+ "@types/pako": "^2.0.3",
70
+ "@types/qs": "^6.9.8",
71
+ "@types/react": "^18.2.21",
72
+ "@types/react-dom": "^18.2.14",
73
+ "@types/uuid": "^9.0.7",
74
+ "@typescript-eslint/eslint-plugin": "^6.6.0",
75
+ "@typescript-eslint/parser": "^6.6.0",
76
+ "autoprefixer": "^10.4.15",
77
+ "cross-env": "^7.0.3",
78
+ "cssnano": "^6.0.1",
79
+ "esbuild": "^0.19.2",
80
+ "eslint-config-standard": "^17.1.0",
81
+ "eslint-config-standard-react": "^13.0.0",
82
+ "eslint-plugin-import": "^2.28.1",
83
+ "eslint-plugin-n": "^16.0.2",
84
+ "eslint-plugin-promise": "^6.1.1",
85
+ "eslint-plugin-react": "^7.33.2",
86
+ "eslint-plugin-react-hooks": "^4.6.0",
87
+ "eslint-plugin-unused-imports": "^3.0.0",
88
+ "postcss": "^8.4.28",
89
+ "querystring": "^0.2.1",
90
+ "react": "^18.2.0",
91
+ "react-dom": "^18.2.0",
92
+ "rimraf": "^5.0.1",
93
+ "rollup": "^3.28.1",
94
+ "rollup-plugin-esbuild": "^5.0.0",
95
+ "rollup-plugin-postcss": "^4.0.2",
96
+ "rollup-plugin-terser": "^7.0.2",
97
+ "tsc-alias": "^1.8.7",
98
+ "tslib": "^2.6.2",
99
+ "typescript": "^5.1.6",
100
+ "zx": "^7.2.3"
101
+ },
102
+ "peerDependencies": {
103
+ "react": ">=16.9.0",
104
+ "react-dom": ">=16.9.0"
105
+ },
106
+ "browserslist": [
107
+ "defaults",
108
+ "not ie < 8",
109
+ "last 2 versions",
110
+ "> 1%",
111
+ "iOS 7",
112
+ "last 3 iOS versions"
113
+ ]
114
+ }