Code Monkey home page Code Monkey logo

wrnavigationbar's Introduction

image


iOS 技术交流

我创建了一个 微信 iOS 技术交流群,欢迎小伙伴们加入一起交流学习~

可以加我微信我拉你进去(备注iOS),我的微信号 wr1204607318

Requirements

  • iOS 7.0+
  • Xcode 8+

Demo

拉钩App首页 新浪微博个人中心 qq空间 知乎日报
QQ我的资料页 蚂蚁森林 连续多个界面导航栏透明 移动导航栏

Installation

CocoaPods pod 'WRNavigationBar','~>1.4.0’ 如果未发现 1.4.0 请更新一下pod

手动拖入 将 WRNavigationBar 文件夹拽入项目中,导入头文件:#import "WRNavigationBar.h"

Use

✨✨ 一定要看 Demo 中的 AppDelegate 文件 ✨✨


// 设置是 全局使用WRNavigationBar,还是局部使用WRNavigationBar,目前默认是全局使用 (局部使用待开发)
[WRNavigationBar wr_widely];
// WRNavigationBar 不会对 blackList 中的控制器有影响
[WRNavigationBar wr_setBlacklist:@[@"SpecialController",
				 @"TZPhotoPickerController",
				 @"TZGifPhotoPreviewController",
				 @"TZAlbumPickerController",
				 @"TZPhotoPreviewController",
				 @"TZVideoPlayerController"]];

// 一行代码搞定导航栏颜色
[self wr_setNavBarBarTintColor:[UIColor whiteColor]];
// 一行代码搞定导航栏透明度
[self wr_setNavBarBackgroundAlpha:alpha];
// 一行代码搞定导航栏两边按钮颜色
[self wr_setNavBarTintColor:[UIColor whiteColor]];
// 一行代码搞定导航栏上标题颜色
[self wr_setNavBarTitleColor:[UIColor whiteColor]];
// 一行代码搞定状态栏是 default 还是 lightContent
[self wr_setStatusBarStyle:UIStatusBarStyleLightContent];
// 一行代码搞定导航栏底部分割线是否隐藏
[self wr_setNavBarShadowImageHidden:YES];

// 设置导航栏默认的背景颜色
[WRNavigationBar wr_setDefaultNavBarBarTintColor:MainNavBarColor];
// 设置导航栏所有按钮的默认颜色
[WRNavigationBar wr_setDefaultNavBarTintColor:[UIColor whiteColor]];
// 设置导航栏标题默认颜色
[WRNavigationBar wr_setDefaultNavBarTitleColor:[UIColor whiteColor]];
// 统一设置状态栏样式
[WRNavigationBar wr_setDefaultStatusBarStyle:UIStatusBarStyleLightContent];
// 如果需要设置导航栏底部分割线隐藏,可以在这里统一设置
[WRNavigationBar wr_setDefaultNavBarShadowImageHidden:YES];

License

WRNavigationBar is available under the MIT license. See the LICENSE file for more info.

wrnavigationbar's People

Contributors

wangrui460 avatar hefeiking avatar felixyin66 avatar jiguangkj avatar cx478815108 avatar

Stargazers

 avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.