KSCommons-Swift 0.1.2

KSCommons-Swift 0.1.2

MohamadYeganeh 维护。




Karo Studio Creative Agency

Karo Studio 是一家具有坚实的设计和开发专长的数字代理机构。我们构建移动和网页应用程序。访问我们的网站 karo.studio 或给我们留言 [点击这里发邮件]

CocoaPods License Version Swift 4.2 Instagram

示例

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

要求

  • iOS 9.3+
  • Xcode 10

安装

KSCommons-Swift 可通过 CocoaPods 获取。要安装它,只需将以下行添加到您的 Podfile 中

pod 'KSCommons-Swift'

UIView 扩展

这些选项将增强您的故事构建功能

  • UIButton imagePadding
  • 使用 tintOverlay 属性设置 UIButton 的图像着色颜色

  • UITextField 的 placeHolderColor

  • UIView 完整的 shadowbordercornerRadius 设置

  • UIView 为每个边框设置不同的圆角半径 view.roundCorners()

通用扩展

  • 字符串的 strikeThrough 属性,用于在文本上方画线并返回 NSAttributedString
  • 字符串的 toPersianNumber() 属性,用于将数字替换为波斯数值
  • 字符串的 widthheight 属性,根据字体返回文本的计算尺寸
  • 日期的 relativeTime 属性,返回从现在起的时间,例如 2 分钟前

作者

Mohamad Yeganeh

授权

KSSwiftCommons 适用于 MIT 许可证。有关更多信息,请参阅 LICENSE 文件。