diff --git a/components/uni-navbar-lite/uni-navbar-lite.uvue b/components/uni-navbar-lite/uni-navbar-lite.uvue index 679b1f3a204fb42165f53ae32b5f1c385cb41cdb..797e33649a7922f935d27009412f8d06256c1a9f 100644 --- a/components/uni-navbar-lite/uni-navbar-lite.uvue +++ b/components/uni-navbar-lite/uni-navbar-lite.uvue @@ -4,7 +4,7 @@ {{unicode}} - + {{title}} @@ -23,11 +23,7 @@ type: String, default: '' }, - open: { - type: Boolean, - default: false - }, - disabled: { + isLeft: { type: Boolean, default: false } @@ -54,11 +50,19 @@ fail(err) { console.log(err); }, - }) - + }) const sys = uni.getSystemInfoSync() const statusBarHeight = sys.statusBarHeight this.statusBarHeight = statusBarHeight + }, + mounted() { + // TODO 暂时加定时器,否则不生效 + setTimeout(() => { + uni.setNavigationBarColor({ + frontColor: '#000000', + backgroundColor: '#ffffff' + }) + }, 100) }, methods: { back() { @@ -103,8 +107,12 @@ bottom: 0; left: 45px; right: 45px; - display: flex; + display: flex; + flex-direction: row; justify-content: center; align-items: center; + } + .is-left { + justify-content: flex-start; } diff --git a/pages/template/navbar-lite/navbar-lite.uvue b/pages/template/navbar-lite/navbar-lite.uvue index 44e388a7b4c7f9899b561d2cf0ed987a3368ffc2..b7ac93e10f8a0b1444b6e807f50ec4a89744c3bc 100644 --- a/pages/template/navbar-lite/navbar-lite.uvue +++ b/pages/template/navbar-lite/navbar-lite.uvue @@ -1,9 +1,12 @@