DroppyWashButtonStyle

Droppy's wash for a Button, disc or pill by its label (DroppyKit 1.23.0): a symbol on Pomodoro's disc, words on its pill, at the mount's control size.

@MainActor struct DroppyWashButtonStyle

Droppy sets it as the style of each Button that sets none inside a ShelfWidgetCompositionProviding widget, so a plain Button there is already right. A widget on the classic makeWidgetView(_:context:) is never restyled: set the style yourself there (droppykit lint warns about a Button with no style in a widget file). A button in a popover or a sheet the widget opens keeps the native look. Set it yourself only for an accent:

Button("Start", systemImage: "play.fill") { start() }
    .buttonStyle(DroppyWashButtonStyle(tone: .accent(.orange)))

The size comes from droppyWashControlSize: 34 alone, 28 in a row or in the header beside the camera, 24 in a narrow row or a list row.

Available from DroppyKit 1.23.0.

Initializers

init(tone:size:)

@MainActor init(tone: DroppyWashTone = .neutral, size: CGFloat? = nil)

Creates the style.

  • Parameters:
  • tone: neutral, or the accent for the one action the widget is for.
  • size: The disc or pill height; nil takes the mount's.

Methods

makeBody(configuration:)

@MainActor func makeBody(configuration: Configuration) -> some View