MWColorPicker 0.9.1

MWColorPicker 0.9.1

LiY 维护。



  • 作者:
  • mw202

MWColorPicker

CI Status Version License Platform

说明

Swift 颜色选择器

screenshot1.png

使用

使用 dataSource 设置选中状态。如果返回 nil,则不会显示选中状态

func colorPickerViewShowSelectBox(_ view: MWColorPickerView) -> MWColorPickerSelectBoxStyle?

使用 delegate 获取选中项。color 返回十六进制颜色值的字符串形式,例如 000FFF

func colorPickerView(_ view: MWColorPickerView, didSelectAt index: Int, color: String)

或者使用 Block

func bindBlock(selected index: Int, block: Block? = nil)

示例

要运行示例项目,请克隆仓库,然后首先从 Example 目录运行 pod install

需求

安装

MWColorPicker 可通过 CocoaPods 使用。要安装

它,只需将以下行添加到您的 Podfile 中

pod 'MWColorPicker'

作者

mw202, [email protected]

许可证

MWColorPicker 可在 MIT 许可证下使用。查看 LICENSE 文件以获取更多信息。