@zykjcommon/questions 0.0.28 → 0.0.30
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/dist/zykjcommon-questions.common.js +23 -24
- package/dist/zykjcommon-questions.css +1 -1
- package/dist/zykjcommon-questions.umd.js +23 -24
- package/dist/zykjcommon-questions.umd.min.js +2 -2
- package/package.json +1 -1
- package/src/assets/js/rem.js +2 -4
- package/src/assets/scss/questions/zykjcommon-questions.scss +1 -0
- package/src/components/questions/Question_Classify.vue +1 -1
- package/src/views/exam/FullScreen.vue +0 -1
package/package.json
CHANGED
package/src/assets/js/rem.js
CHANGED
|
@@ -32,17 +32,15 @@ export let setRem = function(){
|
|
|
32
32
|
//动态设置html的font-size ----end
|
|
33
33
|
}
|
|
34
34
|
|
|
35
|
-
export let setRemFixedHeight = function(designWidth=1440,repairH = 0,scale=1){
|
|
35
|
+
export let setRemFixedHeight = function(designWidth=1440,repairH = 0,scale=1,parent){
|
|
36
36
|
let baseNum = 100;
|
|
37
37
|
let winWidth = document.documentElement.clientWidth || document.body.clientWidth;
|
|
38
38
|
let winHeight = document.documentElement.clientHeight || document.body.clientHeight;
|
|
39
39
|
winHeight = winHeight - repairH
|
|
40
40
|
let html = document.getElementsByTagName('html')[0];
|
|
41
|
-
let frameBili = 4 / 3
|
|
41
|
+
let frameBili = 4.3 / 3
|
|
42
42
|
let b = frameBili / (winWidth / winHeight)
|
|
43
43
|
let realW = parseInt(winWidth * b)
|
|
44
|
-
let parent = document.querySelector('.zykjcommon-question')
|
|
45
44
|
parent.style.fontSize = (realW / designWidth) * baseNum * scale + 'px';
|
|
46
|
-
// html.style.fontSize = (realW / designWidth) * baseNum * scale + 'px';
|
|
47
45
|
console.log(html.style.fontSize);
|
|
48
46
|
}
|
|
@@ -203,7 +203,7 @@ export default {
|
|
|
203
203
|
},
|
|
204
204
|
setRootFontSize() {
|
|
205
205
|
// setRemFixedHeight(1000,140,1.08)
|
|
206
|
-
setRemFixedHeight(1000,this.screenRepairH,this.screenScale)
|
|
206
|
+
setRemFixedHeight(1000,this.screenRepairH,this.screenScale,this.$el)
|
|
207
207
|
},
|
|
208
208
|
unmountedDo(){
|
|
209
209
|
window.removeEventListener('resize',this.setRootFontSize)
|