web-component-gallery 2.0.5 → 2.0.7
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/lib/amap-draw/index.jsx
CHANGED
|
@@ -89,7 +89,7 @@ const AmapDraw = {
|
|
|
89
89
|
this.amap = this.amapStore.initMap(this.drawEl)
|
|
90
90
|
this.amapSatellite = new this.amapStore.AMap.TileLayer.Satellite()
|
|
91
91
|
this.amap.add(this.amapSatellite)
|
|
92
|
-
this.amapSatellite.hide()
|
|
92
|
+
// this.amapSatellite.hide()
|
|
93
93
|
this.buttonProps = [].concat(this.drawButtonProps)
|
|
94
94
|
this.echoDrawLayers(this.drawType)
|
|
95
95
|
/** 如果有限制区域,则描绘在地图上 */
|
|
@@ -329,8 +329,7 @@ const AmapDraw = {
|
|
|
329
329
|
key={i}
|
|
330
330
|
class={i === amapType && 'LayersActive'}
|
|
331
331
|
onClick={() => onLayersSwitch(i)}
|
|
332
|
-
>
|
|
333
|
-
{i === amapType}
|
|
332
|
+
>
|
|
334
333
|
{layer}
|
|
335
334
|
</span>
|
|
336
335
|
))}
|
package/lib/form-comp/ARadio.vue
CHANGED
package/package.json
CHANGED
package/utils/Axios.js
CHANGED
|
@@ -15,7 +15,7 @@ class RequestManager {
|
|
|
15
15
|
|
|
16
16
|
remove(key) {
|
|
17
17
|
this.pendingMap.delete(key)
|
|
18
|
-
}
|
|
18
|
+
}
|
|
19
19
|
|
|
20
20
|
cancel(key) {
|
|
21
21
|
const controller = this.pendingMap.get(key)
|
|
@@ -37,6 +37,8 @@ const createService = (options = {}) => {
|
|
|
37
37
|
const tokenKey = options.tokenKey ?? 'token'
|
|
38
38
|
const token = storage[storageMode].get(tokenKey)
|
|
39
39
|
token && (config.headers[tokenKey] = token)
|
|
40
|
+
|
|
41
|
+
if (checkWhiteList(config)) return config
|
|
40
42
|
|
|
41
43
|
const key = generateRequestKey(config)
|
|
42
44
|
const controller = new AbortController()
|
|
@@ -79,6 +81,11 @@ const createService = (options = {}) => {
|
|
|
79
81
|
})
|
|
80
82
|
}
|
|
81
83
|
|
|
84
|
+
// 白名单校验
|
|
85
|
+
function checkWhiteList(config) {
|
|
86
|
+
return config.headers?.['X-No-Cancel'] === 'true'
|
|
87
|
+
}
|
|
88
|
+
|
|
82
89
|
function generateRequestKey(config) {
|
|
83
90
|
return `${config.url}-${config.method}-${JSON.stringify(config.params)}`
|
|
84
91
|
}
|