mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 21:33:26 +00:00
Add scaledFrame/scaledPadding APIs (#2079)
* Add scaled frame and padding modifiers * Refactor AppLockScreen * Refactor FormattingToolbar * Refactor RoomAttachmentPicker * Refactor ComposerToolbar * Refactor VoiceMessageRecordingButton * More refactors * Refine ScaledPaddingModifier * Cleanup * Fix preview tests * Fix preview test * Use CompoundIcon for custom image * Add .scaledFrame(size:) overload * Set fallback style to .body
This commit is contained in:
@@ -21,8 +21,6 @@ struct InviteUsersScreenSelectedItem: View {
|
||||
let imageProvider: ImageProviderProtocol?
|
||||
let dismissAction: () -> Void
|
||||
|
||||
@ScaledMetric private var buttonSize: CGFloat = 20
|
||||
|
||||
var body: some View {
|
||||
VStack(spacing: 0) {
|
||||
avatar
|
||||
@@ -46,7 +44,7 @@ struct InviteUsersScreenSelectedItem: View {
|
||||
Button(action: dismissAction) {
|
||||
Image(systemName: "xmark.circle.fill")
|
||||
.resizable()
|
||||
.frame(width: buttonSize, height: buttonSize)
|
||||
.scaledFrame(size: 20)
|
||||
.symbolRenderingMode(.palette)
|
||||
.foregroundStyle(Color.compound.iconOnSolidPrimary, Color.compound.iconPrimary)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user