Code Monkey home page Code Monkey logo

swift-flexibleheightbar's People

Contributors

vicentesuarez avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

swift-flexibleheightbar's Issues

Cannot hide custombar with a few data

It's ok with lost of data but cannot hide custombar with a few data
Example: a tableView cans display 4 visible cells is maximum, your data are more than 4, it's ok but less than is not

bad lib

bad lib. Image does not return to original frame when using "fast" scrolling to bottom

Bar doesn't scroll to final position

topBar.behaviorDefiner = SquareCashBarBehaviorDefiner()

    scrollView.delegate = topBar.behaviorDefiner

even that I'm running this code the bar doesn't scroll to the final position.

I thought adding the following code could help:

topBar.behaviorDefiner?.addSnappingPositionProgress(1.0, _forProgressRangeStart: 0.5, end: 1.0)
topBar.behaviorDefiner?.addSnappingPositionProgress(0.0, _forProgressRangeStart: 0.0, end: 0.5)

But this code throws an exception (Idk how this is called in Swift, I'm Java developer mainly and learning Swift now) in the file FlexibleHeightBarBehaviourDefiner.swift in line 60, which runs the code

assert(noRangeConflict, self.snappingPositionAssertionMessage)

By printing the value of noRangeConflict I found out, that the value of noRangeConflict = false.

A fix or help about the usage of FlexibleHeightBar would be much appreciated.

Slow AutoLayout

When using AutoLayout, changing size by changing the constant property in auto layout constraints is slower than setting the view properties and FlexibleHeightBarSubviewLayoutAttributes properties directly. It becomes noticeable in some instances when the bar resizes quickly.

Currently, I don't have a fix for since inherently, auto layout performance is slow. A possible fix might include caching the calculations auto layout makes and applying those to the frame programmatically, but that might defeat the purpose of auto layout. Further, the view layout attributes cannot be set when using auto layout.

Therefore, I recommend using auto layout with the Flexible Height Bar in cases where the resize speed is not noticeable, like it was implemented in the FacebookFlexibleHeightBar in the FHBAutoLayoutDemo project. I do not recommend using auto layout where it might be noticeable, such as in the SquareCashFlexibleHeightBar in the FHBAutoLayoutDemo project.

All suggestions are welcome.

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.