|
|
@ -147,6 +147,9 @@ struct SaveKeyView: View { |
|
|
|
|
|
|
|
var body: some View { |
|
|
|
HStack { |
|
|
|
Spacer() |
|
|
|
VStack { |
|
|
|
spacerBlock(width: 0, height: 0) |
|
|
|
Button(action: copy_text) { |
|
|
|
Label("", systemImage: is_copied ? "checkmark.circle.fill" : "doc.on.doc") |
|
|
|
.foregroundColor(is_copied ? .green : .white) |
|
|
@ -162,6 +165,7 @@ struct SaveKeyView: View { |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
Text(text) |
|
|
|
.padding(5) |
|
|
@ -174,7 +178,14 @@ struct SaveKeyView: View { |
|
|
|
.onTapGesture { |
|
|
|
copy_text() |
|
|
|
} |
|
|
|
|
|
|
|
spacerBlock(width: 0, height: 0) /// set a 'width' > 0 here to vary key Text's aspect ratio |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
@ViewBuilder private func spacerBlock(width: CGFloat, height: CGFloat) -> some View { |
|
|
|
Color.orange.opacity(1) |
|
|
|
.frame(width: width, height: height) |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|