@tarojs/extend 4.0.0-canary.8 → 4.0.0
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/LICENSE +17 -3
- package/package.json +4 -9
- package/src/jquery/zepto.js +6 -2
package/LICENSE
CHANGED
|
@@ -154,7 +154,21 @@ See `/LICENSE` for details of the license.
|
|
|
154
154
|
|
|
155
155
|
==================
|
|
156
156
|
|
|
157
|
-
MIT (
|
|
158
|
-
The following files embed [
|
|
159
|
-
`/packages/taro-components
|
|
157
|
+
MIT (weui):
|
|
158
|
+
The following files embed [weui](https://github.com/Tencent/weui) MIT:
|
|
159
|
+
`/packages/taro-components/src/components/*.scss`
|
|
160
|
+
See `/LICENSE.txt` for details of the license.
|
|
161
|
+
|
|
162
|
+
==================
|
|
163
|
+
|
|
164
|
+
Apache-2.0 (intersection-observer):
|
|
165
|
+
The following files embed [intersection-observer](https://github.com/GoogleChromeLabs/intersection-observer) Apache-2.0:
|
|
166
|
+
`/packages/taro-api/src/polyfill/intersection-observer.ts`
|
|
167
|
+
See `/LICENSE.txt` for details of the license.
|
|
168
|
+
|
|
169
|
+
==================
|
|
170
|
+
|
|
171
|
+
MIT (babel-plugin-jsx-dom-expressions):
|
|
172
|
+
The following files embed [babel-plugin-jsx-dom-expressions](https://github.com/ryansolid/dom-expressions/blob/main/packages/babel-plugin-jsx-dom-expressions) MIT:
|
|
173
|
+
`/packages/babel-plugin-transform-solid-jsx/src/*`
|
|
160
174
|
See `/LICENSE` for details of the license.
|
package/package.json
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tarojs/extend",
|
|
3
|
-
"version": "4.0.0
|
|
3
|
+
"version": "4.0.0",
|
|
4
4
|
"description": "Taro extend functionality",
|
|
5
|
-
"author": "
|
|
6
|
-
"homepage": "https://github.com/nervjs/taro/tree/master/packages/taro-extend#readme",
|
|
5
|
+
"author": "O2Team",
|
|
7
6
|
"license": "MIT",
|
|
8
7
|
"main": "src/index.js",
|
|
9
8
|
"files": [
|
|
@@ -16,12 +15,8 @@
|
|
|
16
15
|
"bugs": {
|
|
17
16
|
"url": "https://github.com/NervJS/taro/issues"
|
|
18
17
|
},
|
|
19
|
-
"
|
|
20
|
-
"
|
|
21
|
-
"jest-cli": "^29.3.1",
|
|
22
|
-
"jest-environment-node": "^29.5.0",
|
|
23
|
-
"ts-jest": "^29.0.5",
|
|
24
|
-
"typescript": "^4.7.4"
|
|
18
|
+
"engines": {
|
|
19
|
+
"node": ">= 18"
|
|
25
20
|
},
|
|
26
21
|
"scripts": {
|
|
27
22
|
"test": "TARO_ENV=weapp jest --coverage false",
|
package/src/jquery/zepto.js
CHANGED
|
@@ -815,9 +815,13 @@ export const Zepto = (function () {
|
|
|
815
815
|
if (isBrowser) {
|
|
816
816
|
return Promise.resolve(hasScrollTop ? this[0].scrollTop : this[0].pageYOffset)
|
|
817
817
|
}
|
|
818
|
-
return hasScrollTop ? Promise.resolve(this[0].scrollTop) : new Promise((resolve) => {
|
|
818
|
+
return hasScrollTop ? Promise.resolve(this[0].scrollTop) : new Promise((resolve, reject) => {
|
|
819
819
|
Taro.createSelectorQuery().select('#' + this[0].uid).scrollOffset(function (res) {
|
|
820
|
-
|
|
820
|
+
if (res) {
|
|
821
|
+
resolve(res.scrollTop)
|
|
822
|
+
} else {
|
|
823
|
+
reject(new Error(`get scrollTop error: #${this[0].uid} query fail`))
|
|
824
|
+
}
|
|
821
825
|
}).exec()
|
|
822
826
|
})
|
|
823
827
|
}
|