This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import SwiftUI | |
struct LazyVGridDemo: View { | |
private var symbols = ["keyboard", "hifispeaker.fill", "printer.fill", "tv.fill", "desktopcomputer", "headphones", "tv.music.note", "mic", "plus.bubble", "video"] | |
private var colors: [Color] = [.yellow, .purple, .green] | |
private var gridItemLayout1 = [GridItem(.flexible()), GridItem(.flexible()), GridItem(.flexible())] | |
private var sixColumnGrid: [GridItem] = Array(repeating: .init(.flexible()), count: 6) | |
private var gridItemLayout2 = [GridItem(.adaptive(minimum: 50))] | |
private var gridItemLayout3 = [GridItem(.fixed(100)), GridItem(.fixed(150))] | |
private var gridItemLayout4 = [GridItem(.fixed(150)), GridItem(.adaptive(minimum: 50))] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import SwiftUI | |
struct LazyVGridDemo: View { | |
private var symbols = ["keyboard", "hifispeaker.fill", "printer.fill", "tv.fill", "desktopcomputer", "headphones", "tv.music.note", "mic", "plus.bubble", "video"] | |
private var colors: [Color] = [.yellow, .purple, .green] | |
private var gridItemLayout1 = [GridItem(.flexible()), GridItem(.flexible()), GridItem(.flexible())] | |
private var sixColumnGrid: [GridItem] = Array(repeating: .init(.flexible()), count: 6) | |
private var gridItemLayout2 = [GridItem(.adaptive(minimum: 50))] | |
private var gridItemLayout3 = [GridItem(.fixed(100)), GridItem(.fixed(150))] | |
private var gridItemLayout4 = [GridItem(.fixed(150)), GridItem(.adaptive(minimum: 50))] |