ActionSheet+Items.swift 770 B

1234567891011121314151617181920212223242526272829303132333435
  1. //
  2. // ActionSheet+Items.swift
  3. // SheeeeeeeeetExample
  4. //
  5. // Created by Jonas Ullström on 2018-03-16.
  6. // Copyright © 2018 Jonas Ullström. All rights reserved.
  7. //
  8. /*
  9. These extensions provides action sheets with functions that
  10. are shared by all example action sheets.
  11. */
  12. import Sheeeeeeeeet
  13. extension ActionSheet {
  14. static var cancelButton: ActionSheetCancelButton {
  15. return ActionSheetCancelButton(title: "Cancel")
  16. }
  17. static var okButton: ActionSheetOkButton {
  18. return ActionSheetOkButton(title: "OK")
  19. }
  20. static var standardTitle: String {
  21. return "What do you want to eat?"
  22. }
  23. static func titleItem(title: String) -> ActionSheetTitle {
  24. return ActionSheetTitle(title: title)
  25. }
  26. }