ivoronin / TomatoBar

🍅 World's neatest Pomodoro timer for macOS menu bar
MIT License
2.29k stars 107 forks source link

Stepper text is aligned vertically instead of horizontally #55

Closed itopaloglu83 closed 1 year ago

itopaloglu83 commented 1 year ago

Just an observation about how the stepper view aligns its text fields in IntervalsView.

Originally the text fields are aligned horizontally but when I compiled the code again with today's Xcode the text fields somehow got aligned vertically.

Vertically aligned.

Unexpected

Adding horizontal stacking.

VStack {
    Stepper(value: $timer.workIntervalLength, in: 1 ... 60) {
        HStack {
            Text(NSLocalizedString("IntervalsView.workIntervalLength.label", comment: "Work interval label"))
                .frame(maxWidth: .infinity, alignment: .leading)
            Text(String.localizedStringWithFormat(minStr, timer.workIntervalLength))

        }
    }
}

Corrected horizontal alignment.

Corrected