| | |
| | | <template> |
| | | <!-- |
| | | 作者:lyzflash |
| | | 时间:2023-08-10 |
| | | 描述:diy组件-模拟显示-选项卡组 |
| | | --> |
| | | <div @click.stop="$parent.$parent.onEditer(index)"> |
| | | <div class="drag optional" :class="{selected:index === selectedIndex}"> |
| | | <div class="diy-tab-box" :style="{background:item.style.background}"> |
| | | <ul class="list tab-list" :class="item.style.show_type==2?'tab-nowrap':'tab-flex d-b-c'"> |
| | | <li class="item" :key="index" v-for="(navBar,index) in item.data" :style="index==0?'background:'+item.style.background_active:''"> |
| | | <div class="item-text" :class="item.style.show_type==1?'text-ellipsis':''" :style="index==0?'color:'+item.style.text_active:'color:'+navBar.color">{{navBar.text}}</div> |
| | | </li> |
| | | </ul> |
| | | </div> |
| | | <div class="btn-edit-del"> |
| | | <div class="btn-del" @click.stop="$parent.$parent.onDeleleItem(index)">删除</div> |
| | | </div> |
| | | <!-- |
| | | 作者:lyzflash |
| | | 时间:2023-08-10 |
| | | 描述:diy组件-模拟显示-选项卡组 |
| | | --> |
| | | <div @click.stop="$parent.$parent.onEditer(index)"> |
| | | <div class="drag optional" :class="{selected:index === selectedIndex}"> |
| | | <div class="diy-tab-box" :style="{background:item.style.background}"> |
| | | <ul class="list tab-list" :class="item.style.show_type==2?'tab-nowrap':'tab-flex d-b-c'"> |
| | | <li class="item" :key="index" v-for="(navBar,index) in item.data" :style="index==0?'background:'+item.style.background_active:''"> |
| | | <div class="item-text" :class="item.style.show_type==1?'text-ellipsis':''" :style="index==0?'color:'+item.style.text_active:'color:'+navBar.color">{{navBar.text}}</div> |
| | | </li> |
| | | </ul> |
| | | </div> |
| | | <div class="btn-edit-del"> |
| | | <div class="btn-del" @click.stop="$parent.$parent.onDeleleItem(index)">删除</div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | export default { |
| | | data() { |
| | | return { |
| | | export default { |
| | | data() { |
| | | return { |
| | | |
| | | }; |
| | | }, |
| | | props: ['item', 'index', 'selectedIndex'], |
| | | methods: { |
| | | }; |
| | | }, |
| | | props: ['item', 'index', 'selectedIndex'], |
| | | methods: { |
| | | |
| | | } |
| | | }; |
| | | } |
| | | }; |
| | | </script> |
| | | |
| | | <style> |