Commit 8540ba2b by 杨明

fixed

1 parent 296ca5ff
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* @Author: yangming yangming@didihu.com.cn * @Author: yangming yangming@didihu.com.cn
* @Date: 2023-05-19 13:46:20 * @Date: 2023-05-19 13:46:20
* @LastEditors: yangming yangming@didihu.com.cn * @LastEditors: yangming yangming@didihu.com.cn
* @LastEditTime: 2023-05-30 15:56:43 * @LastEditTime: 2023-05-31 18:11:57
* @FilePath: \scrm-micro-home\src\mixins\gpt.js * @FilePath: \scrm-micro-home\src\mixins\gpt.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/ */
...@@ -50,16 +50,17 @@ export default { ...@@ -50,16 +50,17 @@ export default {
marketingTitle.split(' ').forEach((item, index) => { marketingTitle.split(' ').forEach((item, index) => {
textList.push({ textList.push({
x: title.titleStyle.x, x: title.titleStyle.x,
y: title.titleStyle.y + index * title.titleStyle.fontSize * 1.1, y: title.titleStyle.y + index * title.titleStyle.fontSize * 1.14,
fontSize: title.titleStyle.fontSize, fontSize: title.titleStyle.fontSize,
color: title.titleStyle.color, color: title.titleStyle.color,
text: item text: item,
bold: title.titleStyle.bold
}) })
}) })
new Array(marketingSubtitle).forEach((item, index) => { new Array(marketingSubtitle).forEach((item, index) => {
textList.push({ textList.push({
x: title.subTitleStyle.x, x: title.subTitleStyle.x,
y: title.subTitleStyle.y + title.titleStyle.fontSize * 1.1 * (textList.length - 1), y: title.subTitleStyle.y + title.titleStyle.fontSize * 1.14 * (textList.length - 1),
fontSize: title.subTitleStyle.fontSize, fontSize: title.subTitleStyle.fontSize,
color: title.subTitleStyle.color, color: title.subTitleStyle.color,
text: item text: item
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* @Author: yangming yangming@didihu.com.cn * @Author: yangming yangming@didihu.com.cn
* @Date: 2023-05-17 16:07:55 * @Date: 2023-05-17 16:07:55
* @LastEditors: yangming yangming@didihu.com.cn * @LastEditors: yangming yangming@didihu.com.cn
* @LastEditTime: 2023-05-30 16:50:44 * @LastEditTime: 2023-05-31 18:02:51
* @FilePath: \scrm-micro-home\src\utils\drawing.js * @FilePath: \scrm-micro-home\src\utils\drawing.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/ */
...@@ -43,11 +43,11 @@ class Drawing { ...@@ -43,11 +43,11 @@ class Drawing {
return this.pixelRatio * val return this.pixelRatio * val
} }
drawText(textParams) { drawText(textParams) {
let { fontSize, color, text, x, y } = textParams let { fontSize, color, text, x, y, bold } = textParams
fontSize = this.toRpx(fontSize) fontSize = this.toRpx(fontSize)
x = this.toRpx(x) x = this.toRpx(x)
y = this.toRpx(y) y = this.toRpx(y)
this.ctx.font = `${fontSize}px Calibri` this.ctx.font = `${bold ? 'bold ' : ''}${fontSize}px Calibri`
this.ctx.fillStyle = color this.ctx.fillStyle = color
this.ctx.textAlign = 'center' this.ctx.textAlign = 'center'
this.ctx.fillText(text, this.canvasId.width / 2, y + fontSize) this.ctx.fillText(text, this.canvasId.width / 2, y + fontSize)
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* @Author: 前端 qianduan01@didihu.com.cn * @Author: 前端 qianduan01@didihu.com.cn
* @Date: 2023-05-16 10:20:01 * @Date: 2023-05-16 10:20:01
* @LastEditors: yangming yangming@didihu.com.cn * @LastEditors: yangming yangming@didihu.com.cn
* @LastEditTime: 2023-05-31 15:46:53 * @LastEditTime: 2023-05-31 15:53:44
* @FilePath: \scrm-micro-home\src\views\home\components\Marketing\ChatGPT.vue * @FilePath: \scrm-micro-home\src\views\home\components\Marketing\ChatGPT.vue
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
--> -->
...@@ -104,9 +104,7 @@ export default { ...@@ -104,9 +104,7 @@ export default {
methods: { methods: {
...mapActions('marketing', ['setActivityInfo', 'setKeyWords']), ...mapActions('marketing', ['setActivityInfo', 'setKeyWords']),
selectText(html) { selectText(html) {
this.$nextTick(() => { this.contentHtml = html
this.contentHtml = html
})
this.phrasesShow = false this.phrasesShow = false
}, },
jumpUrl() { jumpUrl() {
...@@ -140,6 +138,7 @@ export default { ...@@ -140,6 +138,7 @@ export default {
}) })
} }
this.$refs.inputRef.textContent = '' this.$refs.inputRef.textContent = ''
this.contentHtml = ''
}, },
/**点击空白处隐藏下拉框 */ /**点击空白处隐藏下拉框 */
bodyCloseMenus(e) { bodyCloseMenus(e) {
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* @Author: 前端 qianduan01@didihu.com.cn * @Author: 前端 qianduan01@didihu.com.cn
* @Date: 2023-05-15 15:08:32 * @Date: 2023-05-15 15:08:32
* @LastEditors: yangming yangming@didihu.com.cn * @LastEditors: yangming yangming@didihu.com.cn
* @LastEditTime: 2023-05-30 15:22:39 * @LastEditTime: 2023-05-31 18:17:26
* @FilePath: \scrm-micro-home\src\views\home\components\Marketing\MarketingRight.vue * @FilePath: \scrm-micro-home\src\views\home\components\Marketing\MarketingRight.vue
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
--> -->
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
<div class="review-content"> <div class="review-content">
<div class="review-main"> <div class="review-main">
<template> <template>
<div class="main-title" :style="{ top: item.y + 'px', 'font-size': item.fontSize + 'px', color: item.color }" v-for="(item, index) in textList" :key="index">{{ item.text }}</div> <div class="main-title" :style="{'font-weight':item.bold?'bold':'', top: item.y + 'px', 'font-size': item.fontSize + 'px', color: item.color }" v-for="(item, index) in textList" :key="index">{{ item.text }}</div>
<div class="review-bg-img"> <div class="review-bg-img">
<img :src="detail.backgroundImage" v-if="detail.backgroundImage" /> <img :src="detail.backgroundImage" v-if="detail.backgroundImage" />
</div> </div>
...@@ -139,7 +139,8 @@ export default { ...@@ -139,7 +139,8 @@ export default {
y: (title.titleStyle.y + index * title.titleStyle.fontSize * 1.1) * 0.7, y: (title.titleStyle.y + index * title.titleStyle.fontSize * 1.1) * 0.7,
fontSize: title.titleStyle.fontSize * 0.7, fontSize: title.titleStyle.fontSize * 0.7,
color: title.titleStyle.color, color: title.titleStyle.color,
text: item text: item,
bold:title.titleStyle.bold
}) })
}) })
new Array(marketingSubtitle).forEach((item, index) => { new Array(marketingSubtitle).forEach((item, index) => {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!