Latest 1.0.3
Homepage https://github.com/Fxxxxxx/FXStarRatingTool
License MIT
Platforms ios 8.0
Frameworks UIKit
Authors

FXStarRatingTool – iOS超方便的评星工具

  • 前言

    评星,在移动开发中经常会用到,例如淘宝的评价,外卖的订单评价等等,用最多5颗星星给出相应的评价。在安卓中,有相应的RatingBar控件,而iOS就没有这么方便来,需要我们自定义,所以我写了这个名为FXStarRatingTool的框架,方便大家用及其简单的代码完成集成开发。

    GitHub地址: https://github.com/Fxxxxxx/FXStarRatingTool
    使用swift4.0
    iOS8.0及以上
    点击、拖动都有效

  • 效果展示:

    效果图.gif

  • 集成方法:

    1. Cocoapods集成
      pod  'FXStarRatingTool'
    2. 下载工程,把根目录的FXStarRatingTool文件夹整个拉入工程

image.png

  • 使用

    let ratingView = FXStarRatingTool()
    ratingView.isAllowHalf = true
    ratingView.themeColor = UIColor.red
    ratingView.callBack = { (count) -> () in
    //do something u want
    }
    ratingView.show()
  • isAllowHalf 是否允许半星
  • themeColor App主体的颜色,这里就是评价按钮的字体颜色
  • callBack 返回星数的闭包
    这几个属性都是选填的,不设置也会有默认值,创建好直接show()就可以显示了,是不是超级方便😛

欢迎使用和交流, [email protected]

Latest podspec

{
    "name": "FXStarRatingTool",
    "version": "1.0.3",
    "summary": "u8d85u7ea7u7b80u5355u6613u7528u7684u661fu661fu8bc4u5206u5de5u5177.",
    "description": ""u8d85u7ea7u7b80u5355u6613u7528u7684u661fu661fu8bc4u5206u5de5u5177uff0cu8bbeu7f6eu597du5c5eu6027uff0cu4e00u884cu4ee3u7801u663eu793auff0cblocku56deu8c03u7ed3u679cuff0cu8d85u5febu901fu96c6u6210u3002"",
    "homepage": "https://github.com/Fxxxxxx/FXStarRatingTool",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "Fxxx": "[email protected]"
    },
    "platforms": {
        "ios": "8.0"
    },
    "pod_target_xcconfig": {
        "SWIFT_VERSION": "4.0"
    },
    "source": {
        "git": "https://github.com/Fxxxxxx/FXStarRatingTool.git",
        "tag": "1.0.3"
    },
    "source_files": [
        "FXStarRatingTool",
        "FXStarRatingTool/*.swift"
    ],
    "resources": "FXStarRatingTool/star.bundle",
    "frameworks": "UIKit"
}

Pin It on Pinterest

Share This