pixuireactcomponents 1.5.37 → 1.5.39
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/index.d.ts +1 -1
- package/index.js +2 -1
- package/package.json +1 -1
- package/src/components/tools/assetCache.js +5 -4
package/index.d.ts
CHANGED
|
@@ -14,10 +14,10 @@ export { FrameAnimation } from "./src/components/react/app/frameAnimation/FrameA
|
|
|
14
14
|
export { AsyncTaskProcessor } from "./src/components/tools/AsyncTaskProcessor";
|
|
15
15
|
export { assetCache } from "./src/components/tools/assetCache";
|
|
16
16
|
export { ScrollBar } from "./src/components/react/app/scrollBar/ScrollBar";
|
|
17
|
-
export { tools } from "./src/components/tools/tools";
|
|
18
17
|
export { PreloadImg } from "./src/components/react/app/preloadImg/PreloadImg";
|
|
19
18
|
export { LoadChecker } from "./src/components/tools/LoadChecker";
|
|
20
19
|
export { AntiRepeat } from "./src/components/tools/antiRepeat";
|
|
21
20
|
export { DragList } from "./src/components/react/app/dragList/dragList";
|
|
22
21
|
export { QRCode } from "./src/components/react/app/qrcode/QRCode";
|
|
22
|
+
export { VirtualList } from "./src/components/react/app/virtualList/VirtualList";
|
|
23
23
|
export { Slider, SliderProps } from "./src/components/react/app/slider/Slider";
|
package/index.js
CHANGED
|
@@ -19,9 +19,10 @@ export { FrameAnimation } from './src/components/react/app/frameAnimation/FrameA
|
|
|
19
19
|
export { AsyncTaskProcessor } from './src/components/tools/AsyncTaskProcessor';
|
|
20
20
|
export { assetCache } from './src/components/tools/assetCache';
|
|
21
21
|
export { ScrollBar } from './src/components/react/app/scrollBar/ScrollBar';
|
|
22
|
-
export { tools } from './src/components/tools/tools';
|
|
22
|
+
// export { tools } from './src/components/tools/tools';
|
|
23
23
|
export { PreloadImg } from './src/components/react/app/preloadImg/PreloadImg';
|
|
24
24
|
export { LoadChecker } from './src/components/tools/LoadChecker';
|
|
25
25
|
export { AntiRepeat } from './src/components/tools/antiRepeat';
|
|
26
26
|
export { DragList } from './src/components/react/app/dragList/dragList';
|
|
27
27
|
export { QRCode } from './src/components/react/app/qrcode/QRCode';
|
|
28
|
+
export { VirtualList } from './src/components/react/app/virtualList/VirtualList';
|
package/package.json
CHANGED
|
@@ -34,7 +34,6 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
34
34
|
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
35
35
|
}
|
|
36
36
|
};
|
|
37
|
-
import path from 'path';
|
|
38
37
|
import { sha1 } from './Sha1';
|
|
39
38
|
import { LibMgr } from '../../../lib/loadlib/lib_mgr';
|
|
40
39
|
var assetPrefix = 'cacheAsset';
|
|
@@ -210,12 +209,14 @@ export var assetCache;
|
|
|
210
209
|
console.warn('getLocalPath failed', url);
|
|
211
210
|
return '';
|
|
212
211
|
}
|
|
213
|
-
var filePath =
|
|
212
|
+
var filePath = "".concat(cachePath, "/assetcache");
|
|
214
213
|
//检查assetcache文件夹
|
|
215
214
|
if (!OPLib.dirExists(filePath)) {
|
|
216
215
|
OPLib.makeDir(filePath);
|
|
217
216
|
}
|
|
218
|
-
var
|
|
219
|
-
|
|
217
|
+
var cleanUrl = url.split('?')[0].split('#')[0];
|
|
218
|
+
var ext = cleanUrl.includes('.') ? cleanUrl.slice(cleanUrl.lastIndexOf('.')) : '';
|
|
219
|
+
var fileName = sha1(assetPrefix + url).substring(0, 20) + ext;
|
|
220
|
+
return "".concat(filePath, "/").concat(fileName);
|
|
220
221
|
};
|
|
221
222
|
})(assetCache || (assetCache = {}));
|