jdf2e / nutui

京东风格的移动端 Vue 组件库,支持多端小程序(A Vue.js UI Toolkit for Mobile Web)
https://nutui.jd.com
MIT License
6.17k stars 835 forks source link

iconfont.css 客户端WAN网络断开无法下载字体文件 #3211

Open ddacxhs opened 1 month ago

ddacxhs commented 1 month ago

NutUI 包名

@nutui/nutui

NutUI 版本号

3.3.8

平台

h5

重现链接

https://github.com/jdf2e/nutui/blob/v3.3.8/src/packages/styles/font/iconfont.css

重现步骤

文件地址: src/packages/styles/font/iconfont.css

@font-face {
  font-family: "nutui-iconfont"; /* Project id 2166874 */
  src: url('https://storage.360buyimg.com/nutui/3x/static/iconfont.woff2?t=1668762221765') format('woff2'),
       url('https://storage.360buyimg.com/nutui/3x/static/iconfont.woff?t=1668762221765') format('woff'),
       url('https://storage.360buyimg.com/nutui/3x/static/iconfont.ttf?t=1668762221765') format('truetype');
}

断掉WAN网络,客户端无法下载其中的字体文件。

期望的结果是什么?

WAN网络断开后局域网内仍可使用字体。

实际的结果是什么?

https://storage.360buyimg.com/nutui/3x/static/iconfont.woff2?t=1668762221765 WAN网络断开后无法下载

环境信息

No response

其他补充信息

No response

ddacxhs commented 1 month ago

https://github.com/jdf2e/nutui/blob/v3.3.8/src/packages/__VUE/empty/index.vue 也存在公网地址引用

/**
 * 内置图片地址
 */
const defaultStatus: statusOptions = {
  empty: 'https://static-ftcms.jd.com/p/files/61a9e3183985005b3958672b.png',
  error: 'https://ftcms.jd.com/p/files/61a9e33ee7dcdbcc0ce62736.png',
  network: 'https://static-ftcms.jd.com/p/files/61a9e31de7dcdbcc0ce62734.png'
};