Skip to content

iPile/wrkoutUI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

wrkoutUI

wrkoutUI is a design system library of the wrkout application written in Swift (utilising Apple's SwiftUI framework).

Its purpose is to generalise the UI throughout the application and make it easier to implement new views by simply reusing the components already described in this package.

Components

Typography

Available fonts:

  • wrkoutButton
  • wrkoutExtraSmall
  • wrkoutSmall
  • wrkoutMedium
  • wrkoutLarge
  • wrkoutTitle

Usage:

Text("wrkoutButton")
    .font(.wrkoutButton)

typography

Colorgraphy

Available colors:

  • wrkoutGray
  • wrkoutDarkGray
  • wrkoutOcean
  • wrkoutBlue
  • wrkoutDarkBlue
  • wrkoutGreen
  • wrkoutOrange
  • wrkoutDarkOrange

Usage:

Circle()
    .fill(Color.wrkoutOrange)

colorgraphy

Animations

Spring Effect

Usage:

AnyView()
  .onTapGesture {
    withAnimation(.springEffect) {
      self.scaleFonts.toggle()
    }
  }

Molecules

Molecules are design components that persist of two or more atoms.

WrkoutTextField

Parameters:

  • placeHolderText (String)
  • textInputBinding (Binding<String)
  • errorText (String)
  • isSecure (Bool = false)

Components:

  • TextField (SecureField if isSecure = true) with WrkoutInputTextField modifier
  • Text view to display error text

Both wrapped in to a VStack with leading alignment.

Usage:

WrkoutTextField(placeHolderText: "This is a wrkout text field",
                textInputBinding: $textBinding,
                errorText: "And its error text")

wrkoutTextField

Styles

Button Styles

FilledButtonsStyle

Parameters:

  • backgroundColor (Color)
  • textColor (Color)
  • disabled (Bool)

Usage:

Button(action: {}) {
    Text("FilledButtonStyle")
}
.buttonStyle(FilledButtonStyle(backgroundColor: .wrkoutOrange,
                               textColor: .white,                                    
                               disabled: false))

filledButton

Backgrounds

WrkoutBackground

Parameters:

  • cornerRadius (CGFloat = 24)
  • opacity (Double = 1)

Usage:

AnyView()
  .background(WrkoutBackground())

wrkoutBackground

About

SwiftUI based iOS App Design System

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages