Skip to content

Latest commit

 

History

5 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 

Repository files navigation

TagLayout

Taglayout is SwiftUI library allows you to display your tag list.
Minimum iOS version: 15

Simulator Screenshot - iPhone 15 - 2024-07-28 at 16 11 35

Usage

import SwiftUI
import TagLayout


struct ContentView: View {

    let fruits = [
        "Apple", "Banana", "Cherry", "Date", "Elderberry", "Fig", "Grape", "Honeydew", "Indian Fig", "Jackfruit",
        "Kiwi", "Lemon", "Mango", "Nectarine", "Orange", "Papaya", "Quince", "Raspberry", "Strawberry", "Tangerine",
        "Ugli Fruit", "Vanilla", "Watermelon", "Xigua", "Yellow Passion Fruit", "Zucchini", "Blueberry", "Cantaloupe",
        "Dragonfruit", "Pineapple"
    ]

    var body: some View {
        TagLayout(tags: fruits) { tag in
            Text(tag)
                .font(.title3)
                .cornerRadius(3)
                .padding(4)
                .overlay(RoundedRectangle(cornerRadius: 3).stroke(Color.blue, lineWidth: 1.0))
                .padding(8)
        }.padding(.all, 8)
    }
}

Installation

TagLayout is available via Swift Package Manager.

Using Xcode 15, go to File -> Swift Packages -> Add Package Dependency and enter https://github.com/yotsu12/TagLayoutView

About

No description, website, or topics provided.

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages