CosmicMind / Material

A UI/UX framework for creating beautiful applications.
http://cosmicmind.com
MIT License
11.98k stars 1.26k forks source link

Grid System dose not work #613

Closed yunhao closed 5 years ago

yunhao commented 8 years ago

Material 2.3.19 Xcode8

I tried to follow the tutorials in http://www.cosmicmind.com/material/grid

class ViewController: UIViewController {

    override func viewDidLoad() {
        super.viewDidLoad()

        let container = View()
        container.shapePreset = .square
        container.grid.interimSpacePreset = .interimSpace3

        view.layout(container).top(100).left(20).right(20)

        for _ in 0..<12 {
            let v = View()
            v.grid.columns = 1
            v.backgroundColor = Color.blue.base
            container.grid.views.append(v)
        }

    }

}

But only a blank page was showed on my screen. I saw this in Xcode8 by UI View Hierarchy: image

It seems that the layout is broken.

daniel-jonathan commented 8 years ago

Yes, there is an issue. I am pushing a fix within the hour. Thank you!

daniel-jonathan commented 8 years ago

Please update to Material 2.3.20, where you can find a fix for this issue. :) Thanks

You can find a sample project at Grid Sample.

samma89 commented 5 years ago

Hi,

It seems this issue is there in 3.1.6 release. I am running your sample grid from Samples repo.

Screen Shot 2019-08-27 at 7 25 21 AM

Any idea of why?

Thanks

daniel-jonathan commented 5 years ago

@samma89 We are updating the samples next week. We haven't had a chance to do so, because of a new product we are launching internally for testing this week, and announced next week. Sorry for any delays. We will look into this.

samma89 commented 5 years ago

@danieldahan Thank you!

daniel-jonathan commented 5 years ago

Hi there, sorry for any delays. We discovered that some earlier updates had caused a regression. You can find a fix in Material 3.1.7. Please test, and if there is still an issue, please reopen this issue or create a new issue. Thank you!