|
@@ -56,8 +56,25 @@
|
|
|
v-loading="item.isUpdating" :element-loading-text="$t('Slides.updating_chart_loading')"
|
|
|
@click="changeCurrentItem(item)">
|
|
|
<!-- 标题 -->
|
|
|
- <div class="title-wrap">
|
|
|
- <input type="text" :placeholder="$t('Slides.click_to_input_title')" v-model="item.title"/>
|
|
|
+ <!-- <div class="title-wrap" style="background-color: #999999;">
|
|
|
+ <input type="text" placeholder="单击输入标题" v-model="item.title"/>
|
|
|
+ </div> -->
|
|
|
+ <!-- 自定义标题 -->
|
|
|
+ <div @click.stop="handleEditTitle"
|
|
|
+ :class="[
|
|
|
+ 'ppt-editor-title',
|
|
|
+ 'custom-title-wrap',
|
|
|
+ currentItem.id===item.id&&isEditTitle?'editor-model':''
|
|
|
+ ]"
|
|
|
+ :style="item.titleDetail?{
|
|
|
+ left:item.titleDetail.left+'%',
|
|
|
+ top:item.titleDetail.top+'%',
|
|
|
+ width:item.titleDetail.width+'%',
|
|
|
+ height:item.titleDetail.height+'%',
|
|
|
+ }:{
|
|
|
+ left:'10%',top:'5.5%',width:'68%',height:'7%'
|
|
|
+ }">
|
|
|
+ <div class="title" v-html="item.title"></div>
|
|
|
</div>
|
|
|
<!-- 内容 -->
|
|
|
<component :is="getComponentName(item.modelId)"
|
|
@@ -68,6 +85,7 @@
|
|
|
:isCopy="true"
|
|
|
:isAdd="true"
|
|
|
:isEditLayer="isEditLayer"
|
|
|
+ :isEditTitle="isEditTitle"
|
|
|
:choosedId="currentItem.id"
|
|
|
:activeLayerEl="activeLayerEl"
|
|
|
:amendatoryPositionInfo="item.positionInfo"
|
|
@@ -121,7 +139,7 @@
|
|
|
</div>
|
|
|
<div class="richtext-tool"></div>
|
|
|
<!-- 防止el-tabs未渲染时触发scrollToActiveTab 报错,v-if改为v-show-->
|
|
|
- <div class="addppt-right-box" v-show="!isEditLayer">
|
|
|
+ <div class="addppt-right-box" v-show="!isEditLayer&&!isEditTitle">
|
|
|
<el-tabs v-model="tabsactive">
|
|
|
<el-tab-pane :label="tab.label" :name="tab.val" v-for="tab in panelTabs" :key="tab.val"></el-tab-pane>
|
|
|
</el-tabs>
|
|
@@ -187,7 +205,7 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
<!-- 图层编辑 -->
|
|
|
- <div class="layer-edit-box" v-show="isEditLayer">
|
|
|
+ <div class="layer-edit-box" v-if="isEditLayer">
|
|
|
<el-collapse v-model="activeNames" class="tool-list">
|
|
|
<el-collapse-item :title="$t('Slides.layer_element')" name="el">
|
|
|
<div class="el-wrap">
|
|
@@ -226,6 +244,17 @@
|
|
|
</el-collapse-item>
|
|
|
</el-collapse>
|
|
|
</div>
|
|
|
+ <!-- 标题编辑 -->
|
|
|
+ <div class="title-edit-box" v-if="isEditTitle">
|
|
|
+ <p>{{$t('Slides.page_title_style_setting')}}</p>
|
|
|
+ <TitleEditorTool
|
|
|
+ ref="titleEditor"
|
|
|
+ :currentItem="currentItem"
|
|
|
+ @changeSizeAll="changeSizeAll"
|
|
|
+ @changePositionAll="changePositionAll"
|
|
|
+ @styleChange="handleTitelStyleChange"
|
|
|
+ @textChange="handleTextChange"/>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
@@ -310,6 +339,7 @@ import InsertCharts from './components/editor/InsertCharts.vue';
|
|
|
import ContextMenu from './components/ContextMenu.vue';
|
|
|
import InsertSemantics from './components/editor/InsertSemantics.vue';
|
|
|
import ChooseCoverNew from './components/editor/ChooseCoverNew.vue';
|
|
|
+import TitleEditorTool from './components/editor/TitleEditorTool';
|
|
|
export default {
|
|
|
mixins:[pptmixin,//ppt页面共同逻辑
|
|
|
mixins,//图表加载逻辑
|
|
@@ -319,7 +349,7 @@ export default {
|
|
|
components: {
|
|
|
IndexItem, ChooseCover, AddFormat, ShapePreview,
|
|
|
LayerEditTool, DeletePageDialog, ChangeFormatDialog, InsertPageDialog, addMyClassifyDia, InsertCharts, ContextMenu, InsertSemantics,
|
|
|
- ChooseCoverNew
|
|
|
+ ChooseCoverNew,TitleEditorTool
|
|
|
},
|
|
|
data() {
|
|
|
return {
|
|
@@ -742,6 +772,8 @@ export default {
|
|
|
if(this.currentItem&&this.currentItem.id!==id){
|
|
|
this.isEditLayer = false
|
|
|
this.activeLayerEl = {}
|
|
|
+
|
|
|
+ this.isEditTitle = false
|
|
|
}
|
|
|
this.pageList.map((item,index)=>{
|
|
|
if(item.id===id){
|
|
@@ -1323,23 +1355,6 @@ export default {
|
|
|
<style lang="scss">
|
|
|
@import './css/common.scss';
|
|
|
@import './css/format.scss';
|
|
|
-.page-wrap{
|
|
|
- .ppt-editor-wrap{
|
|
|
- .ppt-tool{
|
|
|
- .layer-edit-box{
|
|
|
- .tool-list{
|
|
|
- .el-collapse-item__header{
|
|
|
- margin-bottom: 0;
|
|
|
- }
|
|
|
- .el-collapse-item__wrap{
|
|
|
- overflow: visible;
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
</style>
|
|
|
<style scoped lang="scss">
|
|
|
$titleColor:#333333;
|
|
@@ -1493,17 +1508,19 @@ $titleColor:#333333;
|
|
|
min-width:320px;
|
|
|
width: 320px;
|
|
|
height:100%;
|
|
|
- .tool-btn{
|
|
|
- margin-bottom: 12px;
|
|
|
+ overflow-y: hidden;
|
|
|
+ .richtext-tool{
|
|
|
+ margin:10px 0;
|
|
|
}
|
|
|
.addppt-right-box{
|
|
|
flex: 1;
|
|
|
- height: calc(100% - 182px);
|
|
|
+ /* height: calc(100% - 182px); */
|
|
|
padding: 0 10px;
|
|
|
- margin-top: 12px;
|
|
|
box-sizing: border-box;
|
|
|
- border:1px solid #B2B9C3;
|
|
|
+ border: 2px solid #EBEBEB;
|
|
|
+ border-radius: 4px;
|
|
|
min-width: 320px;
|
|
|
+ overflow-y: auto;
|
|
|
#tabs {
|
|
|
padding: 0px 40px;
|
|
|
box-sizing: border-box;
|
|
@@ -1579,20 +1596,20 @@ $titleColor:#333333;
|
|
|
}
|
|
|
|
|
|
}
|
|
|
- .layer-edit-box{
|
|
|
+ .layer-edit-box,.title-edit-box{
|
|
|
flex: 1;
|
|
|
- height: calc(100% - 182px);
|
|
|
+ /* height: calc(100% - 182px); */
|
|
|
padding: 0 20px;
|
|
|
- margin-top: 12px;
|
|
|
box-sizing: border-box;
|
|
|
border: 2px solid #EBEBEB;
|
|
|
border-radius: 4px;
|
|
|
min-width: 320px;
|
|
|
- overflow-y: scroll;
|
|
|
+ overflow-y: auto;
|
|
|
.tool-list{
|
|
|
.el-wrap{
|
|
|
display: flex;
|
|
|
- justify-content: space-between;
|
|
|
+ /* justify-content: space-between; */
|
|
|
+ gap: 0 15px;
|
|
|
flex-wrap: wrap;
|
|
|
.el-item{
|
|
|
border: 1px solid #DCDFE6;
|
|
@@ -1614,24 +1631,14 @@ $titleColor:#333333;
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
+ .title-edit-box{
|
|
|
+ p{
|
|
|
+ font-size: 16px;
|
|
|
+ font-weight: bold;
|
|
|
+ margin-top:16px;
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
</style>
|
|
|
-<style lang="scss">
|
|
|
-.page-wrap {
|
|
|
- .el-tabs__nav-wrap::after {
|
|
|
- height: 0;
|
|
|
- }
|
|
|
- .el-tabs__item { font-size: 16px; }
|
|
|
- .layer-edit-box{
|
|
|
- .tool-list{
|
|
|
- .el-collapse-item:first-child{
|
|
|
- .el-collapse-item__content{
|
|
|
- padding-bottom: 5px;
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
-}
|
|
|
-</style>
|