34 lines
714 B
Swift
34 lines
714 B
Swift
//
|
|
// ButtonModel.swift
|
|
// VDS
|
|
//
|
|
// Created by Jarrod Courtney on 9/16/22.
|
|
//
|
|
|
|
import Foundation
|
|
import UIKit
|
|
|
|
public enum ButtonSize: String, Codable, CaseIterable {
|
|
case large
|
|
case small
|
|
}
|
|
|
|
public protocol ButtonModel: Modelable, Useable {
|
|
var text: String? { get set }
|
|
var width: CGFloat? { get set }
|
|
var size: ButtonSize { get set }
|
|
var use: Use { get set }
|
|
}
|
|
|
|
public struct DefaultButtonModel: ButtonModel {
|
|
|
|
public var id = UUID()
|
|
public var text: String?
|
|
public var surface: Surface = .light
|
|
public var use: Use = .primary
|
|
public var disabled: Bool = false
|
|
public var width: CGFloat?
|
|
public var size: ButtonSize = .large
|
|
public init(){}
|
|
}
|