Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pedroortizordep/09bdd4439a5efbba6c9d234940aae7c6 to your computer and use it in GitHub Desktop.
Save pedroortizordep/09bdd4439a5efbba6c9d234940aae7c6 to your computer and use it in GitHub Desktop.
func getLocalizableSampleTemplate(for complication: CLKComplication, withHandler handler: @escaping (CLKComplicationTemplate?) -> Void) {
let template = CLKComplicationTemplateModularLargeStandardBody()
let beerGlass = UIImage(named: "beer_glass")
template.headerImageProvider =
CLKImageProvider(onePieceImage: beerGlass!)
template.headerTextProvider = CLKSimpleTextProvider(text: "Beer Festival")
template.body1TextProvider = CLKSimpleTextProvider(text: "Beer Tasting Schedule")
handler(template)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment