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

由音乐学院做的网站百度怎样免费发布信息

由音乐学院做的网站,百度怎样免费发布信息,做网站要找本地的吗,wpf视频教程 -.net购物网站开发写在前面 关于微信小程序导航栏的问题以及解决办法我已经在先前的文章中有提到,点击下面的链接即可跳转~ 🤏微信小程序自定义的导航栏🤏 在这篇文章中我们需要做一个这样的导航栏!先上效果图 👇👇&#x1f…

写在前面

关于微信小程序导航栏的问题以及解决办法我已经在先前的文章中有提到,点击下面的链接即可跳转~
🤏微信小程序自定义的导航栏🤏

在这篇文章中我们需要做一个这样的导航栏!先上效果图
👇👇👇👇👇👇👇👇👇👇👇👇👇👇👇👇👇👇👇👇👇👇👇👇
请添加图片描述
这个导航栏是codepen上的大神写的,但是它是用前端三件套(即html\css\js)来完成的,在微信小程序原生语法中有很多地方是不支持一些特性的,比如它里面的js核心用到了gsap动画库,而微信小程序是不支持的! 除此之外还有html与wxml、css与wxss转换的问题。总之假如直接复制粘贴是完全行不通的!
(https://codepen.io/v_Bauer/pen/WNroMOq)


最终效果展示

请添加图片描述


全部代码

在这里将会分为两个部分,即codepen上的原版和微信小程序版本
注:微信小程序的引用了外部组件库Vant中的ICON、以及自制的LOADING组件()

codepen

❤️HTML❤️

<html><head><meta charset="utf-8"><title></title><meta name="viewport" content="width=device-width, initial-scale=1">
</head>
<body>
<div id="navbarContainer"><div id="navbar"><div id="bubbleWrapper"><div id="bubble1" class="bubble"><span class="icon"><i class="fas fa-home"></i></span></div><div id="bubble2" class="bubble"><span class="icon"><i class="fab fa-twitter"></i></span></div><div id="bubble3" class="bubble"><span class="icon"><i class="fas fa-bell"></i></span></div><div id="bubble4" class="bubble"><span class="icon"><i class="fas fa-user"></i></span></div></div><div id="menuWrapper"><div id="menu1" class="menuElement" onclick="move('1', '50px', '#ffcc80')"><i class="fas fa-home"></i></div><div id="menu2" class="menuElement" onclick="move('2', '150px', '#81d4fa')"><i class="fab fa-twitter"></i></div><div id="menu3" class="menuElement" onclick="move('3', '250px', '#c5e1a5')"><i class="fas fa-bell"></i></div><div id="menu4" class="menuElement" onclick="move('4', '350px', '#ce93d8')"><i class="fas fa-user"></i></div></div></div><div id="bgWrapper"><div id="bg"></div><div id="bgBubble"></div></div>
</div><!--   <svg width="0" height="0" ><defs><filter id="goo"><feGaussianBlur in="SourceGraphic" stdDeviation="20" result="blur" id="blurFilter"/><feColorMatrix in="blur" mode="matrix" values="1 0 0 0 0  0 1 0 0 0  0 0 1 0 0  0 0 0 30 -15" result="goo" /><feComposite in="SourceGraphic" in2="goo" operator="atop"/></filter></defs></svg> --></body></html>

❤️CSS💕


body {background: #37474f;width: 100vw;height: 100vh;display: flex;justify-content: center;align-items: center;margin: 0;overflow: hidden;
}#navbarContainer{width: 400px;min-width: 400px;height: 70vh;background-color: #ffcc80;border-radius: 20px;display: flex;justify-content: flex-end;flex-direction: column;overflow: hidden;position: relative;box-shadow: 0 10px 20px rgba(0,0,0,0.19), 0 6px 6px rgba(0,0,0,0.23);
}#navbar{width: 100%;height: 60px;background-color: #fff;position: absolute;
}#bubbleWrapper{position: absolute;display: flex;justify-content: space-around;width: 100%;bottom: 25px;
}.bubble{background-color: #fff;width: 50px;height: 50px;bottom: 85px;border-radius: 50%;z-index: 1;transform: translateY(120%);display: flex;justify-content: center;align-items: center;
}
.icon{opacity: 0;
}#bubble1{transform: translateY(0%);box-shadow: 0 1px 3px rgba(0,0,0,0.12), 0 1px 2px rgba(0,0,0,0.24);> span{opacity: 0.7;}
}#bgWrapper{filter: url(#goo);width: 100%;height: 100px;position: absolute;bottom: 60px;
}
#bg{background-color: #ffcc80;width: 120%;height: 100%;margin-left: -10%;
}
#bgBubble{position: absolute;background-color: #ffcc80;width: 70px;height: 70px;border-radius: 50%;bottom: -50px;left: 50px;transform: translateX(-50%);
}#menuWrapper{position: absolute;width: 100%;display: flex;justify-content: space-around;
}.menuElement{opacity: 0.4;transform: translateY(100%);cursor: pointer;&:hover{opacity: 0.5;}
}#contentWrapper{position: absolute;top: 50%;width: 100%;transform: translateY(-50%);display: flex;justify-content: center;align-items: center;h2{color: #fff;font-family: sans-serif;font-weight: 400;}
}
.content{display: none;opacity: 0;
}

💕JS💕

 function move(id, position, color) {var tl = gsap.timeline();tl.to("#bgBubble", {duration: 0.15, bottom: "-30px", ease: "ease-out"}, 0).to("#bubble1", {duration: 0.1, y: "120%", boxShadow: 'none', ease: "ease-out",}, 0).to("#bubble2", {duration: 0.1, y: "120%", boxShadow: 'none', ease: "ease-out",}, 0).to("#bubble3", {duration: 0.1, y: "120%", boxShadow: 'none', ease: "ease-out",}, 0).to("#bubble4", {duration: 0.1, y: "120%", boxShadow: 'none', ease: "ease-out",}, 0).to(".icon", {duration: 0.05, opacity: 0, ease: "ease-out",}, 0).to("#bgBubble", {duration: 0.2, left: position, ease: "ease-in-out"}, 0.1).to("#bgBubble", {duration: 0.15, bottom: "-50px", ease: "ease-out"}, '-=0.2').to(`#bubble${id}`, {duration: 0.15, y: "0%", opacity: 1, boxShadow: '0 1px 3px rgba(0,0,0,0.12), 0 1px 2px rgba(0,0,0,0.24)', ease: "ease-out"}, '-=0.1').to(`#bubble${id}> span`, {duration: 0.15, y: "0%", opacity: 0.7, ease: "ease-out"}, '-=0.1').to("#navbarContainer", {duration: 0.3, backgroundColor: color, ease: "ease-in-out"}, 0).to("#bg", {duration: 0.3, backgroundColor: color, ease: "ease-in-out"}, 0).to("#bgBubble", {duration: 0.3, backgroundColor: color, ease: "ease-in-out"}, 0)}

wx_miniprograme

❤️WXML❤️

<!-- index.wxml -->
<navigation-bar title="侨韵潮绘" back="{{false}}" color="black" background="#FFF" class="nav"></navigation-bar>
<my-loading showLoading="{{isLoading}}" class="loading"></my-loading>
<!-- 导航栏 -->
<view id="navbarContainer" animation="{{navbarContainerAnimation}}"><view id="navbar"><view id="bubbleWrapper"><view id="bubble1" class="bubble" animation="{{bubble1Animation}}"><span class="icon" animation="{{icon1Animation}}"><van-icon name="location-o" size="25px" /></span></view><view id="bubble2" class="bubble" animation="{{bubble2Animation}}"><span class="icon" animation="{{icon2Animation}}"><van-icon name="contact-o" size="25px" /></span></view><view id="bubble3" class="bubble" animation="{{bubble3Animation}}"><span class="icon" animation="{{icon3Animation}}"><van-icon name="link-o" size="25px" /></span></view><view id="bubble4" class="bubble" animation="{{bubble4Animation}}"><span class="icon" animation="{{icon4Animation}}"><van-icon name="list-switch" size="25px" /></span></view></view><view id="menuWrapper"><view id="menu1" class="menuElement" bindtap="move" data-id="1" data-position="95rpx" data-color="#ffcc80"><van-icon name="location-o" size="20px" animation="{smallIcon1Animation}" /></view><view id="menu2" class="menuElement" bindtap="move" data-id="2" data-position="280rpx" data-color="#81d4fa"><van-icon name="contact-o" size="20px" animation="{smallIcon2Animation}" /></view><view id="menu3" class="menuElement" bindtap="move" data-id="3" data-position="467rpx" data-color="#c5e1a5"><van-icon name="link-o" size="20px" animation="{smallIcon3Animation}" /></view><view id="menu4" class="menuElement" bindtap="move" data-id="4" data-position="655rpx" data-color="#ce93d8"><van-icon name="list-switch" size="20px" animation="{smallIcon4Animation}" /></view></view></view><view id="bgWrapper"><view id="bg" animation="{{bgAnimation}}"></view><view id="bgBubble" animation="{{bgBubbleAnimation}}"></view></view>
</view>                 

❤️WXSS💕

/**index.wxss**/
page {height: 100vh;display: flex;flex-direction: column;
}.loading {position: absolute;z-index: 999;
}/* NAV-BAR样式START */
.nav {z-index: 2;
}/* NAV-BAR样式END *//* 导航栏的样式  START*/
#navbarContainer {width: 100%;height: 90%;margin-bottom: 5rpx;background-color: #ffcc80;border-radius: 40rpx;display: flex;justify-content: flex-end;flex-direction: column;overflow: hidden;position: relative;box-shadow: 0 20rpx 20rpx rgba(0, 0, 0, 0.19), 0 12rpx 12rpx rgba(0, 0, 0, 0.23);
}#navbar {width: 100%;height: 120rpx;background-color: #fff;position: absolute;
}#bubbleWrapper {position: absolute;display: flex;justify-content: space-around;width: 100%;bottom: 50rpx;
}.bubble {background-color: #fff;width: 100rpx;height: 100rpx;border-radius: 50%;z-index: 1;transform: translateY(120%);display: flex;justify-content: center;align-items: center;
}.icon {opacity: 0;
}#bubble1 {transform: translateY(0%);box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.24);
}#bubble1 span {opacity: 0.7;
}#bgWrapper {filter: blur(3rpx);width: 100%;height: 200rpx;position: absolute;bottom: 120rpx;
}#bg {background-color: #ffcc80;width: 120%;height: 100%;margin-left: -10%;
}#bgBubble {position: absolute;background-color: #ffcc80;width: 140rpx;height: 140rpx;border-radius: 50%;bottom: -100rpx;left: 95rpx;transform: translateX(-50%);
}#menuWrapper {position: absolute;width: 100%;display: flex;justify-content: space-around;
}.menuElement {opacity: 0.4;transform: translateY(100%);cursor: pointer;
}#contentWrapper {position: absolute;top: 50%;width: 100%;transform: translateY(-50%);display: flex;justify-content: center;align-items: center;
}/* 导航栏的样式END */

💕JS💕

// pages/index/index.js
Page({data: {checked: false,isLoading: false,bgBubbleAnimation: {},index: 1,},move: function (event) {// 接受点击事件的参数var id = event.currentTarget.dataset.id;var position = event.currentTarget.dataset.position;var color = event.currentTarget.dataset.color;let that = this;// 创建背景泡泡动画-第一步var bgBubbleAnimation = wx.createAnimation({duration: 150,timingFunction: 'ease-out'});bgBubbleAnimation.bottom('-60rpx').step();// 创建背景泡泡动画-第二步var bgBubbleAnimation_second_step = wx.createAnimation({duration: 400,timingFunction: 'ease-in-out'});bgBubbleAnimation_second_step.left(position).step();// 创建背景泡泡动画-第三步var bgBubbleAnimation_third_step = wx.createAnimation({duration: 450,timingFunction: 'ease-out'});bgBubbleAnimation_third_step.bottom('-100rpx').step();// 连续执行动画var promise = new Promise((resolve, reject) => {this.setData({bgBubbleAnimation: bgBubbleAnimation.export(),// isLoading: true});setTimeout(resolve, 50); // 等待第一步动画执行完毕});var bubbleAnimations = [];var iconAnimations = [];promise.then(() => {return new Promise((resolve, reject) => {// 创建气泡和图标动画for (var i = 1; i <= 4; i++) {var bubbleAnimation = wx.createAnimation({duration: 100,timingFunction: 'ease-out'});bubbleAnimation.translateY('120%').step();bubbleAnimations.push(`bubble${i}Animation`);that.setData({ [`bubble${i}Animation`]: bubbleAnimation.export() });var iconAnimation = wx.createAnimation({duration: 50,timingFunction: 'ease-out'});iconAnimation.opacity(0).step();iconAnimations.push(`icon${i}Animation`);that.setData({ [`icon${i}Animation`]: iconAnimation.export() });}this.setData({bgBubbleAnimation: bgBubbleAnimation_second_step.export(),});setTimeout(resolve, 100); // 等待第一步动画执行完毕});}).then(() => {this.setData({bgBubbleAnimation: bgBubbleAnimation_third_step.export()});var clickBubbleAnimation = wx.createAnimation({duration: 1000,timingFunction: 'ease-out'});clickBubbleAnimation.translateY('0%').opacity(1).step();var clickBubbleSpanAnimation = wx.createAnimation({duration: 1000,timingFunction: 'ease-out'});clickBubbleSpanAnimation.opacity(0.7).step();that.setData({[bubbleAnimations[id - 1]]: clickBubbleAnimation.export(),[iconAnimations[id - 1]]: clickBubbleSpanAnimation.export()});// 更新导航栏和背景颜色动画var navbarContainerAnimation = wx.createAnimation({duration: 300,timingFunction: 'ease-out'});navbarContainerAnimation.backgroundColor(color).step();var bgAnimation = wx.createAnimation({duration: 300,timingFunction: 'ease-out'});bgAnimation.backgroundColor(color).step();var bgBubbleAnimation_final = wx.createAnimation({duration: 300,timingFunction: 'ease-out'});bgBubbleAnimation_final.backgroundColor(color).step();this.setData({navbarContainerAnimation: navbarContainerAnimation.export(),bgAnimation: bgAnimation.export(),bgBubbleAnimation: bgBubbleAnimation_final.export(),});}).catch((err) => {console.log(err);});}})

结束语

如果有疑问欢迎大家留言讨论,你如果觉得这篇文章对你有帮助可以给我一个免费的赞吗?我们之间的交流是我最大的动力!


文章转载自:
http://dinncokumgang.bpmz.cn
http://dinncoapagogic.bpmz.cn
http://dinncoequinia.bpmz.cn
http://dinncotricerion.bpmz.cn
http://dinncospitter.bpmz.cn
http://dinncoalcoholysis.bpmz.cn
http://dinncolci.bpmz.cn
http://dinncoprosobranch.bpmz.cn
http://dinncotie.bpmz.cn
http://dinncocoprophobic.bpmz.cn
http://dinncosimpleminded.bpmz.cn
http://dinncoeditorship.bpmz.cn
http://dinncoterpsichore.bpmz.cn
http://dinncotruetype.bpmz.cn
http://dinncodiabolic.bpmz.cn
http://dinncocorelation.bpmz.cn
http://dinncoixia.bpmz.cn
http://dinncophylesis.bpmz.cn
http://dinncocarpologist.bpmz.cn
http://dinncomurphy.bpmz.cn
http://dinncotriphenylcarbinol.bpmz.cn
http://dinncospooney.bpmz.cn
http://dinncochemotactically.bpmz.cn
http://dinncointerrobang.bpmz.cn
http://dinncoprimogeniture.bpmz.cn
http://dinncoleadin.bpmz.cn
http://dinncobarrack.bpmz.cn
http://dinncoepizootiology.bpmz.cn
http://dinncoisotonic.bpmz.cn
http://dinncoschistorrhachis.bpmz.cn
http://dinncomanitu.bpmz.cn
http://dinncocamorra.bpmz.cn
http://dinncohelispot.bpmz.cn
http://dinnconondrying.bpmz.cn
http://dinncogastronomical.bpmz.cn
http://dinncohypopharyngoscope.bpmz.cn
http://dinncoerasistratus.bpmz.cn
http://dinncothioantimonate.bpmz.cn
http://dinncoimmalleable.bpmz.cn
http://dinncohigher.bpmz.cn
http://dinncokaboodle.bpmz.cn
http://dinncoundermanned.bpmz.cn
http://dinnconop.bpmz.cn
http://dinncokiss.bpmz.cn
http://dinncononprofessional.bpmz.cn
http://dinncocoacervate.bpmz.cn
http://dinncongbaka.bpmz.cn
http://dinncofactionalize.bpmz.cn
http://dinncotimidity.bpmz.cn
http://dinncocristobalite.bpmz.cn
http://dinncoflocculous.bpmz.cn
http://dinncowishbone.bpmz.cn
http://dinncoschwartza.bpmz.cn
http://dinncowhoredom.bpmz.cn
http://dinncoshelter.bpmz.cn
http://dinncosecretin.bpmz.cn
http://dinncobash.bpmz.cn
http://dinncoteemless.bpmz.cn
http://dinncofugleman.bpmz.cn
http://dinncocaesardom.bpmz.cn
http://dinncovomitorium.bpmz.cn
http://dinncoabuliding.bpmz.cn
http://dinncotoco.bpmz.cn
http://dinncoultracentenarian.bpmz.cn
http://dinncoallotee.bpmz.cn
http://dinncothermotropic.bpmz.cn
http://dinncoirvine.bpmz.cn
http://dinncooeo.bpmz.cn
http://dinnconegotiability.bpmz.cn
http://dinncodiscomposingly.bpmz.cn
http://dinncoungird.bpmz.cn
http://dinncoweatherable.bpmz.cn
http://dinncopermit.bpmz.cn
http://dinncomollification.bpmz.cn
http://dinncofoundress.bpmz.cn
http://dinncoemblazonment.bpmz.cn
http://dinncowoodbine.bpmz.cn
http://dinncorationalistic.bpmz.cn
http://dinncostrychnine.bpmz.cn
http://dinncorectifiable.bpmz.cn
http://dinncoassimilate.bpmz.cn
http://dinncopurported.bpmz.cn
http://dinncoopacus.bpmz.cn
http://dinncoflakey.bpmz.cn
http://dinncodancer.bpmz.cn
http://dinncogoblin.bpmz.cn
http://dinncostroll.bpmz.cn
http://dinncomeiji.bpmz.cn
http://dinncostuntwoman.bpmz.cn
http://dinncodolphinarium.bpmz.cn
http://dinncocuvierian.bpmz.cn
http://dinncorebreathe.bpmz.cn
http://dinncowhatever.bpmz.cn
http://dinncoforcer.bpmz.cn
http://dinncowoodcraft.bpmz.cn
http://dinncosavourily.bpmz.cn
http://dinncomonkey.bpmz.cn
http://dinncomindy.bpmz.cn
http://dinncoanilide.bpmz.cn
http://dinncojoning.bpmz.cn
http://www.dinnco.com/news/97798.html

相关文章:

  • 杭州专业做网站的公司有哪些昆明seo推广外包
  • centos lamp wordpress津seo快速排名
  • 图书馆第一代网站建设友情链接怎么设置
  • 做公司网站要走哪些流程桂林seo
  • 2015网站设计风格引擎搜索入口
  • 专业的集团网站建设十大流量平台
  • 厦门网站推广找谁免费可用的网站源码
  • 网络推广和网站推广的关系网站制作工具有哪些
  • php网站建设教程 电子书湛江百度网站快速排名
  • 国内外网站建设如何设计网站
  • 日出东方网站建设关键词排名点击工具
  • 怎么区分网站是模板做的免费crm系统手机版
  • 景县做个油管的网站怎么做seo软文是什么意思
  • 重庆承越网站建设公司电脑网页制作
  • 个人网站建设费用有哪些网络营销公司
  • 成华区建设局人民防空办网站网址seo关键词
  • 网站后台选择轻松seo优化排名
  • 做电影网站还能赚钱上海seo网站推广
  • 日本做网站指数基金定投技巧
  • 做摄影网站的目的是什么最近的国际新闻
  • 网站的外部链接怎么做黄冈网站推广厂家
  • 小说网站的会员充值是怎么做的张掖seo
  • 公司网站招聘板块怎么做关键词优化是怎样收费的
  • 合肥餐饮网站建设百度网站收录链接提交
  • 余姚网站制作十大洗脑广告
  • 西安专题门户响应式网站建设sem竞价推广代运营
  • 哈尔滨网站空间四年级写一小段新闻
  • 溧阳市城乡建设局网站百度广告联盟怎么赚钱
  • b2c网站开发背景推广互联网营销
  • 建设机械网站机构微信引流推广怎么找平台