<template>
<view>
<uni-nav-bar :fixed="true" :border="false" :statusBar="true" left-icon="closeempty" right-icon="plusempty" title="发动态" @clickLeft="leftAction()" @clickRight="rightAction()"></uni-nav-bar>
<view style="width: 750rpx;background-color: #FFFFFF;margin: 32rpx;">
<textarea v-model="publish.text" :show-confirm-bar="false" placeholder="记录下此刻发布心情" />
</view>
</view>
</template>
<script>
export default {
data() {
return {
publish:{
text:''
},
}
},
methods: {
leftAction:function(){
uni.navigateBack()
},
rightAction:function(){
}
}
}
</script>
<style>
</style>
- 发布:2021-05-02 18:06
- 更新:2021-06-18 12:08
- 阅读:692
产品分类: uniapp/App
PC开发环境操作系统: Mac
PC开发环境操作系统版本号: 10.15.6
HBuilderX类型: 正式
HBuilderX版本号: 3.1.14
手机系统: iOS
手机系统版本号: IOS 14
手机厂商: 苹果
手机机型: iphonex
页面类型: nvue
打包方式: 云端
项目创建方式: HBuilderX
示例代码:
操作步骤:
<template>
<view>
<uni-nav-bar :fixed="true" :border="false" :statusBar="true" left-icon="closeempty" right-icon="plusempty" title="发动态" @clickLeft="leftAction()" @clickRight="rightAction()"></uni-nav-bar>
<view style="width: 750rpx;background-color: #FFFFFF;margin: 32rpx;">
<textarea v-model="publish.text" :show-confirm-bar="false" placeholder="记录下此刻发布心情" />
</view>
</view>
</template>
<script>
export default {
data() {
return {
publish:{
text:''
},
}
},
methods: {
leftAction:function(){
uni.navigateBack()
},
rightAction:function(){
}
}
}
</script>
<style>
</style>
<template>
<view>
<uni-nav-bar :fixed="true" :border="false" :statusBar="true" left-icon="closeempty" right-icon="plusempty" title="发动态" @clickLeft="leftAction()" @clickRight="rightAction()"></uni-nav-bar>
<view style="width: 750rpx;background-color: #FFFFFF;margin: 32rpx;">
<textarea v-model="publish.text" :show-confirm-bar="false" placeholder="记录下此刻发布心情" />
</view>
</view>
</template>
<script>
export default {
data() {
return {
publish:{
text:''
},
}
},
methods: {
leftAction:function(){
uni.navigateBack()
},
rightAction:function(){
}
}
}
</script>
<style>
</style>
预期结果:
<template>
<view>
<uni-nav-bar :fixed="true" :border="false" :statusBar="true" left-icon="closeempty" right-icon="plusempty" title="发动态" @clickLeft="leftAction()" @clickRight="rightAction()"></uni-nav-bar>
<view style="width: 750rpx;background-color: #FFFFFF;margin: 32rpx;">
<textarea v-model="publish.text" :show-confirm-bar="false" placeholder="记录下此刻发布心情" />
</view>
</view>
</template>
<script>
export default {
data() {
return {
publish:{
text:''
},
}
},
methods: {
leftAction:function(){
uni.navigateBack()
},
rightAction:function(){
}
}
}
</script>
<style>
</style>
<template>
<view>
<uni-nav-bar :fixed="true" :border="false" :statusBar="true" left-icon="closeempty" right-icon="plusempty" title="发动态" @clickLeft="leftAction()" @clickRight="rightAction()"></uni-nav-bar>
<view style="width: 750rpx;background-color: #FFFFFF;margin: 32rpx;">
<textarea v-model="publish.text" :show-confirm-bar="false" placeholder="记录下此刻发布心情" />
</view>
</view>
</template>
<script>
export default {
data() {
return {
publish:{
text:''
},
}
},
methods: {
leftAction:function(){
uni.navigateBack()
},
rightAction:function(){
}
}
}
</script>
<style>
</style>
实际结果:
<template>
<view>
<uni-nav-bar :fixed="true" :border="false" :statusBar="true" left-icon="closeempty" right-icon="plusempty" title="发动态" @clickLeft="leftAction()" @clickRight="rightAction()"></uni-nav-bar>
<view style="width: 750rpx;background-color: #FFFFFF;margin: 32rpx;">
<textarea v-model="publish.text" :show-confirm-bar="false" placeholder="记录下此刻发布心情" />
</view>
</view>
</template>
<script>
export default {
data() {
return {
publish:{
text:''
},
}
},
methods: {
leftAction:function(){
uni.navigateBack()
},
rightAction:function(){
}
}
}
</script>
<style>
</style>
<template>
<view>
<uni-nav-bar :fixed="true" :border="false" :statusBar="true" left-icon="closeempty" right-icon="plusempty" title="发动态" @clickLeft="leftAction()" @clickRight="rightAction()"></uni-nav-bar>
<view style="width: 750rpx;background-color: #FFFFFF;margin: 32rpx;">
<textarea v-model="publish.text" :show-confirm-bar="false" placeholder="记录下此刻发布心情" />
</view>
</view>
</template>
<script>
export default {
data() {
return {
publish:{
text:''
},
}
},
methods: {
leftAction:function(){
uni.navigateBack()
},
rightAction:function(){
}
}
}
</script>
<style>
</style>
收到,即将排查
-
7***@qq.com (作者)
还有 安卓 nvue navbar 自定义按钮图标消失。vue 向nvue 通信失败uni.$on uni.$emit 接收不到传输的参数
2021-05-08 16:48
7***@qq.com (作者)
我还以为官方来了呢
2021-05-02 18:49
DCloud_UNI_GSQ
回复 7***@qq.com: 来了
2021-05-08 16:42