Git Product home page Git Product logo

swift-badge's Issues

error line

translatesAutoresizingMaskIntoConstraints = false

Various compile errors with example

swift-badge-master/swift-badge/SwiftBadge.swift:15:12: Initializer does not override a designated initializer from its superclass

swift-badge-master/swift-badge/SwiftBadge.swift:16:5: Must call a designated initializer of the superclass 'UILabel'

swift-badge-master/swift-badge/ViewController.swift:50:12: 'NSString' is not implicitly convertible to 'String'; did you mean to use 'as' to explicitly convert?

I' m using latest Xcode and swift.

Swift 5 support

Xcode 10.2 Beta now comes with Swift 5. Any plans on updating swift-badge to support it? Thanks!

What version is in Swift 2.3?

I am having trouble finding what Version supports swift 2.3?

I have gone as fat back as 2.011. Could you include this in the docs for future reference?

Thanks!

Render Issue on Storyboad

I have added Bade on story and then, it start complaining some random error.

Failed to render and update auto layout status for [My View Controller Name].swift "
Required code signature missing for BadeSwift.framework missing. 
  • Library setup method: file, Carthage, CocoaPods or Swift Package Manager.
  • Version of the library : 5.0.1
  • Xcode version. Example: 9.3
  • OS version. Example: iOS 11

.Hidden

The .hidden property on the badge seems to hide only the red background. The white text still remains visible. I have tried setting it to "" but it remains the previous value. Any ideas? Thanks

if listingsToLoad[indexPath.row].unReadMessages.value != nil {
    cell.cellBadge.hidden = false
    cell.cellBadge.text = String(listingsToLoad[indexPath.row].unReadMessages.value!)
} else {
    cell.cellBadge.hidden = true
    cell.cellBadge.text = ""
}

Subclassing when using CocoaPods

Hi!

I wanted to subclass BadgeSwift to add some custom default styling. But when i tried i got..

Cannot inherit from non-open class 'BadgeSwift' outside of it´s defining module.

I´m using CocoaPods. I guess this is just because of the missing open declaration.
Could we add this? Or is the class intentionally non-open?

ld: warning: linking against a dylib which is not safe for use in application extensions

As explained here, there are some APIs unavailable for extensions. Seems like BadgeSwift is using them, because I am getting the error:

ld: warning: linking against a dylib which is not safe for use in application extensions

Any idea which is the part of the code that is using this kind of APIs? Looking at the functionality of this framework, it should be possible to use it in extensions.

different shape and arrow

it's possible to add and arrow like disclosure indicator to the badge? And it's possible have different shape?

Why not add it to cocospod?

This is very useful for me. And I think it's much more flexible than other badges you have listed.Why not add it to cocospod?

I can't import BadgeSwift

when in try to use swift-badge I can't import BadgeSwift
I installed pod but I can't import it

  • Xcode version : 9.0.1.

Swift 4.2

Hi,

I'm using the last version of the library from cocoapods (BadgeSwift (5.0.1)) and it doesn't build on Swift4.2.
Is there any plan to update it?
It's just one line of code actually:
let rectWithoutInsets = UIEdgeInsetsInsetRect(rect, insets)
to
let rectWithoutInsets = rect.inset(by: insets)

Thanks,

Gradient

Is there a way to specify a gradient for the badge color?

The small red part

Please consider submitting the following information (if relevant):

  • Library setup method: CocoaPods.
  • Version of the library. Example: 5.0.1.
  • Xcode version. Example: 9.4.1.
  • OS version. Example: iOS 11.4.

The small red part that appears to be cut off on the top right always pops up. What should I do in order to remove it?

img_2880

Thank you!

[Bug] Top left stroke edge error

The corner radius support will be added in #10, but if the radius is 0, and the label has border, the top left border has an error

screen shot 2016-11-09 at 10 49 37 am

Without border:
screen shot 2016-11-09 at 10 50 56 am

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.