This commit is contained in:
2022-07-20 11:11:08 +08:00
commit c0e7de76fd
141 changed files with 25350 additions and 0 deletions

12
src/config/rem.js Normal file
View File

@@ -0,0 +1,12 @@
(function (doc, win) {
var docEl = doc.documentElement
var resizeEvt = 'orientationchange' in window ? 'orientationchange' : 'resize'
var recalc = function () {
var clientWidth = docEl.clientWidth
if (!clientWidth) return
docEl.style.fontSize = 100 * (clientWidth / 750) + 'px'
}
if (!doc.addEventListener) return
win.addEventListener(resizeEvt, recalc, false)
doc.addEventListener('DOMContentLoaded', recalc, false)
})(document, window)