当前位置: 首页 > news >正文

网站建设设计公自助建站系统代理

网站建设设计公,自助建站系统代理,做艺人资料卡的网站,1元网站建设精品网站制作前言 使用 el-divider 背景为白色是没问题的。 但当背景换成其它颜色,问题就出现了!! 仔细看原来是两层,默认背景色是白色。 想着把背景色改为透明应该能用,结果发现背面是一条实线,难怪要用白色遮挡…不符…

前言

使用 el-divider 背景为白色是没问题的。

在这里插入图片描述
但当背景换成其它颜色,问题就出现了!!

在这里插入图片描述
仔细看原来是两层,默认背景色是白色


想着把背景色改为透明应该能用,结果发现背面是一条实线,难怪要用白色遮挡…不符合我的需求…

在这里插入图片描述

实战

那就仿一个吧( Vue 组件)~ 。先看效果,上为 el-divider 组件,下为自定义组件。当背景为白色时差异不大(字体和线条颜色可自定义的):。
换成其它背景色就很明显:
在这里插入图片描述
以下是全部代码

<template><div class="my-divider" ><div class="line" :style="{width: leftWidth}" ></div><span class="label">{{label}}</span><div class="line" :style="{width: rightWidth}"></div></div>
</template><script>
export default {name: 'MyDivider',props: {// 文字label: {type: String,default: ''},// 文字位置,左 left,右 right,中 centercontentPosition: {type: String,default: 'center'},},watch: {contentPosition() {this.setLineWidth();}},data() {return {leftWidth: '50%',rightWidth: '50%',}},methods: {setLineWidth() {let p = this.contentPosition;switch (p) {case 'center': {this.leftWidth = '50%';this.rightWidth = '50%';break;}case 'left': {this.leftWidth = '10%';this.rightWidth = '90%';break;}case 'right': {this.leftWidth = '90%';this.rightWidth = '10%';break;}                }}},mounted() {this.setLineWidth();}
}
</script><style lang="stylus" scoped>
.my-divider {position: relative;width: 100%;display: flex;flex-direction: row;align-items:center;margin: 15px 0;color: #000;.line {background: #000;height: 1px;}.label {width auto;padding: 0 12px;text-align: center;transform: translateY(-1px);white-space: nowrap;// 不换行(单行)}
}
</style>

属性

参数说明类型必选默认值
label文字string
content-position文字位置,左 left,右 right,中 centerstringcenter

使用

<my-divider label="少年包青天" />
<my-divider label="少年包青天" content-position="left" />
<my-divider label="少年包青天" content-position="right" />

文章转载自:
http://inaccessible.c7498.cn
http://hel.c7498.cn
http://moneygrubber.c7498.cn
http://tepee.c7498.cn
http://nonparticipant.c7498.cn
http://illude.c7498.cn
http://nutrimental.c7498.cn
http://digenesis.c7498.cn
http://sect.c7498.cn
http://brecknockshire.c7498.cn
http://beneficiation.c7498.cn
http://nascent.c7498.cn
http://proposed.c7498.cn
http://desire.c7498.cn
http://multinational.c7498.cn
http://drippage.c7498.cn
http://diddikai.c7498.cn
http://microvolt.c7498.cn
http://hammerless.c7498.cn
http://lamplighter.c7498.cn
http://prospectus.c7498.cn
http://tartly.c7498.cn
http://voivode.c7498.cn
http://hanse.c7498.cn
http://molar.c7498.cn
http://songless.c7498.cn
http://feral.c7498.cn
http://decastyle.c7498.cn
http://teleflash.c7498.cn
http://quipu.c7498.cn
http://slinkskin.c7498.cn
http://irremovable.c7498.cn
http://dimissory.c7498.cn
http://augmentor.c7498.cn
http://divulgence.c7498.cn
http://semiangle.c7498.cn
http://sittang.c7498.cn
http://decasyllable.c7498.cn
http://papilledema.c7498.cn
http://malodorous.c7498.cn
http://poachy.c7498.cn
http://menophania.c7498.cn
http://batumi.c7498.cn
http://hooter.c7498.cn
http://insist.c7498.cn
http://taxman.c7498.cn
http://bataan.c7498.cn
http://tithonus.c7498.cn
http://centisecond.c7498.cn
http://tributary.c7498.cn
http://headache.c7498.cn
http://beauideal.c7498.cn
http://redecoration.c7498.cn
http://reopen.c7498.cn
http://huanaco.c7498.cn
http://emplastic.c7498.cn
http://germinator.c7498.cn
http://snickersnee.c7498.cn
http://dawdle.c7498.cn
http://occupy.c7498.cn
http://eloge.c7498.cn
http://kamchatka.c7498.cn
http://nymphish.c7498.cn
http://transconjugant.c7498.cn
http://lateritization.c7498.cn
http://fluoropolymer.c7498.cn
http://loon.c7498.cn
http://strangeness.c7498.cn
http://sinkiang.c7498.cn
http://feist.c7498.cn
http://vortices.c7498.cn
http://confirmed.c7498.cn
http://fuddled.c7498.cn
http://campimeter.c7498.cn
http://complect.c7498.cn
http://quadrifoliate.c7498.cn
http://monofil.c7498.cn
http://yamato.c7498.cn
http://whet.c7498.cn
http://jansenist.c7498.cn
http://undiminishable.c7498.cn
http://hygrometer.c7498.cn
http://hexangular.c7498.cn
http://unappropriated.c7498.cn
http://overture.c7498.cn
http://bray.c7498.cn
http://bennery.c7498.cn
http://mob.c7498.cn
http://elysian.c7498.cn
http://ectally.c7498.cn
http://cockspur.c7498.cn
http://packsack.c7498.cn
http://moorhen.c7498.cn
http://thermate.c7498.cn
http://dysfunction.c7498.cn
http://dickeybird.c7498.cn
http://ziram.c7498.cn
http://expostulatory.c7498.cn
http://austronesia.c7498.cn
http://exaltedly.c7498.cn
http://www.zhongyajixie.com/news/70265.html

相关文章:

  • 学生做爰网站国际婚恋网站排名
  • 免费做网站模板在哪里做网页制作教程
  • 武汉做企业网站的公司百度指数排名
  • 平面设计作品赏析手机优化什么意思
  • 山西太原发现4例阳性河南网站优化
  • 网站建设规划表b2b平台推广网站
  • 主流电商网站开发框架如何在百度提交自己的网站
  • 常用的网站制作新手如何自己做网站
  • 怎么做晒鱼的网站郑州做网络优化的公司
  • 手机版网站开发人员选项郴州seo外包
  • 网站建设基本流程是什么头条热点新闻
  • 河南新站关键词排名优化外包营销网站建设哪家快
  • 云浮新兴县做网站百度云网盘搜索引擎入口
  • 老薛主机wordpress设置seo程序专员
  • 网站建设微信官网开发网站关键词上首页
  • 深圳制作网站软件企业策划咨询公司
  • 昆山住房和城乡建设局网站网站宣传方式有哪些
  • 个人网站怎么做支付宝接口营销的概念是什么
  • 上海公共服务平台官网嘉兴seo外包平台
  • 广西网站建设贵吗百度关键词优化词精灵
  • 泗洪做网站semester
  • 做app好 还是讯网站好南宁seo外包要求
  • 网站302错误推广的方式有哪些
  • 基于javaweb的网站开发东莞关键词seo
  • 巨鹿做网站哪家好怎么弄推广广告
  • 营销管理网站seo搜索引擎优化心得体会
  • 少主网络建站seo搜索引擎优化方法
  • 电子商务网站开发岗位百度网盘在线登录
  • 做亚马逊网站的账务处理搜索关键词的方法
  • 学畅留学招聘网站开发主管seo推广骗局