Bläddra i källkod

分享海报调整样式

lifanagju_citu 2 månader sedan
förälder
incheckning
ef87bc6cd5
2 ändrade filer med 7 tillägg och 9 borttagningar
  1. 1 3
      components.d.ts
  2. 6 6
      src/views/recruit/components/jobFairEntShare/index.vue

+ 1 - 3
components.d.ts

@@ -30,6 +30,7 @@ declare module 'vue' {
     CtTextField: typeof import('./src/components/CtVuetify/CtTextField/index.vue')['default']
     DatePicker: typeof import('./src/components/DatePicker/index.vue')['default']
     Echarts: typeof import('./src/components/Echarts/index.vue')['default']
+    ElCascader: typeof import('element-plus/es')['ElCascader']
     ElConfigProvider: typeof import('element-plus/es')['ElConfigProvider']
     Empty: typeof import('./src/components/Empty/index.vue')['default']
     File: typeof import('./src/components/Upload/file.vue')['default']
@@ -73,7 +74,4 @@ declare module 'vue' {
     VerifySlide: typeof import('./src/components/Verifition/Verify/VerifySlide.vue')['default']
     WangEditor: typeof import('./src/components/FormUI/wangEditor/index.vue')['default']
   }
-  export interface ComponentCustomProperties {
-    vLoading: typeof import('element-plus/es')['ElLoadingDirective']
-  }
 }

+ 6 - 6
src/views/recruit/components/jobFairEntShare/index.vue

@@ -67,8 +67,8 @@ const drawCanvas = () => {
       thirdImg.onload = () => {
         // 企业头像
         ctx.save()
-        const secondImgWidth = 80
-        const secondImgHeight = 80
+        const secondImgWidth = 120
+        const secondImgHeight = 120
         const x = (canvas.width - secondImgWidth) / 2
         const y = canvas.height - secondImgHeight - 460
         
@@ -81,7 +81,7 @@ const drawCanvas = () => {
         // 企业名称
         const maxTextWidth = 400
         const text = props.enterpriseName
-        const fontStyle = 'bold 18px Arial'
+        const fontStyle = 'bold 24px Arial'
         ctx.font = fontStyle
         let truncatedText = text
         while (ctx.measureText(truncatedText + '...').width > maxTextWidth && truncatedText.length > 0) {
@@ -97,8 +97,8 @@ const drawCanvas = () => {
         const tagPaddingLeftRight = 20
         const tagPaddingTopBottom = 10
         const tagRadius = 8
-        const tagSpacing = 30
-        let tagY = textY + tagSpacing
+        const tagSpacing = 22
+        let tagY = textY + tagSpacing + 10
         props.positionList.forEach((tag) => {
           let truncatedTag = tag
           while (ctx.measureText(truncatedTag + '...').width > maxTextWidth - 2 * tagPaddingLeftRight && truncatedTag.length > 0) {
@@ -123,7 +123,7 @@ const drawCanvas = () => {
           ctx.closePath()
           ctx.fill()
 
-          ctx.font = '16px Arial'
+          ctx.font = '18px Arial'
           ctx.fillStyle = '#fff'
           ctx.fillText(truncatedTag, tagX + tagPaddingLeftRight, tagY + tagPaddingTopBottom + 10)