Skip to content

Commit

Permalink
Rename SizeLength to SideLength
Browse files Browse the repository at this point in the history
  • Loading branch information
Kjuly committed Dec 11, 2023
1 parent c984e6e commit fb8ede0
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,14 @@ enum KYNearbyConnectionViewDimension {
// static let large: CGFloat = 10
}

public enum IconButtonSizeLength {
public enum IconButtonSideLength {
static let regular: CGFloat = 44
static let small: CGFloat = 32
}

public enum PeerCell {
public static let horizontalSpacing: CGFloat = 10
public static let peerStatusIndicatorSizeLength: CGFloat = 20
public static let secondaryContentLeadingPadding: CGFloat = peerStatusIndicatorSizeLength + horizontalSpacing
public static let peerStatusIndicatorSideLength: CGFloat = 20
public static let secondaryContentLeadingPadding: CGFloat = peerStatusIndicatorSideLength + horizontalSpacing
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ struct KYNearbyConnectionPeerCell: View {
private func _peerStatusAndNameLabel() -> some View {
Image(systemName: KYNearbyConnectionViewIconName.peerStatusIndicator)
.foregroundColor(_statusColor())
.frame(width: KYNearbyConnectionViewDimension.PeerCell.peerStatusIndicatorSizeLength)
.frame(width: KYNearbyConnectionViewDimension.PeerCell.peerStatusIndicatorSideLength)
Text(self.item.displayName)
.font(self.labelFont)
.foregroundColor(self.defaultContentColor)
Expand Down Expand Up @@ -192,8 +192,8 @@ struct KYNearbyConnectionPeerCell: View {
Image(systemName: KYNearbyConnectionViewIconName.terminateProcessing)
.foregroundColor(self.accentColor)
}
.frame(width: KYNearbyConnectionViewDimension.IconButtonSizeLength.small,
height: KYNearbyConnectionViewDimension.IconButtonSizeLength.regular,
.frame(width: KYNearbyConnectionViewDimension.IconButtonSideLength.small,
height: KYNearbyConnectionViewDimension.IconButtonSideLength.regular,
alignment: .trailing)
}

Expand Down

0 comments on commit fb8ede0

Please sign in to comment.