Skip to content

Commit

Permalink
Merge pull request #51 from arjunkomath/main
Browse files Browse the repository at this point in the history
UI fixes
  • Loading branch information
arjunkomath authored Dec 28, 2023
2 parents f7de934 + a1a8ae5 commit 097d3af
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 11 deletions.
13 changes: 8 additions & 5 deletions netdata/Modules/ServerList/Components/ServerListRow.swift
Original file line number Diff line number Diff line change
Expand Up @@ -35,18 +35,21 @@ struct ServerListRow: View {

Spacer()

if !server.basicAuthBase64.isEmpty {
Image(systemName: "lock.shield")
.foregroundColor(.accentColor)
}

RedactedView(loading: fetchingAlarm) {
Circle()
.fill(self.getAlarmStatusColor())
.frame(width: 12, height: 12, alignment: .leading)
}

if !server.basicAuthBase64.isEmpty {
Image(systemName: "lock.shield")
.foregroundColor(.accentColor)
}

#if targetEnvironment(macCatalyst)
#else
Image(systemName: "chevron.right")
#endif
}

Text(server.description)
Expand Down
4 changes: 2 additions & 2 deletions netdata/Modules/Shared/Charts/AbsoluteUsageData.swift
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,11 @@ struct AbsoluteUsageData: View {
} else if usage != nil {
if convertSecondsToHours ?? false {
Text(String(format: "%.f", ((usage!/60)/60)))
.font(.system(size: 16, weight: .heavy, design: .rounded))
.font(.system(size: 16, weight: .regular, design: .rounded))
.padding(0)
} else {
Text(String(format: "%.2f", usage!))
.font(.system(size: 16, weight: .heavy, design: .rounded))
.font(.system(size: 16, weight: .regular, design: .rounded))
.padding(0)
}
}
Expand Down
5 changes: 2 additions & 3 deletions netdata/Modules/Shared/Charts/Meter.swift
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,13 @@ struct Meter : View {

var body: some View {
Gauge(
value: max(progress, 0),
value: max(progress, 1),
in: 0...1
) {
Text("%")
} currentValueLabel: {
Text(String(format: "%.0f", min(self.progress, 1.0)*100.0))
.font(.caption)
.bold()
.font(.system(size: 18, weight: .regular, design: .rounded))
}
.gaugeStyle(.accessoryCircular)
.tint(getColor())
Expand Down
2 changes: 1 addition & 1 deletion netdata/Modules/Shared/Charts/PercentageUsageData.swift
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ struct PercentageUsageData: View {
.frame(alignment: .leading)

Text("\(Int(self.usage))%")
.font(.system(size: 16, weight: .heavy, design: .rounded))
.font(.system(size: 16, weight: .regular, design: .rounded))
.padding(0)
}
.frame(height: 50)
Expand Down

0 comments on commit 097d3af

Please sign in to comment.