diff --git a/Planet/SharedAssets.xcassets/arb-logo.imageset/Contents.json b/Planet/SharedAssets.xcassets/arb-logo.imageset/Contents.json new file mode 100644 index 00000000..3e9b3eca --- /dev/null +++ b/Planet/SharedAssets.xcassets/arb-logo.imageset/Contents.json @@ -0,0 +1,12 @@ +{ + "images" : [ + { + "filename" : "arbitrum-logo.png", + "idiom" : "universal" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Planet/SharedAssets.xcassets/arb-logo.imageset/arbitrum-logo.png b/Planet/SharedAssets.xcassets/arb-logo.imageset/arbitrum-logo.png new file mode 100644 index 00000000..a7ee4623 Binary files /dev/null and b/Planet/SharedAssets.xcassets/arb-logo.imageset/arbitrum-logo.png differ diff --git a/Planet/SharedAssets.xcassets/base-logo.imageset/Contents.json b/Planet/SharedAssets.xcassets/base-logo.imageset/Contents.json new file mode 100644 index 00000000..7d9e6f45 --- /dev/null +++ b/Planet/SharedAssets.xcassets/base-logo.imageset/Contents.json @@ -0,0 +1,12 @@ +{ + "images" : [ + { + "filename" : "base-logo.png", + "idiom" : "universal" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Planet/SharedAssets.xcassets/base-logo.imageset/base-logo.png b/Planet/SharedAssets.xcassets/base-logo.imageset/base-logo.png new file mode 100644 index 00000000..f90fe306 Binary files /dev/null and b/Planet/SharedAssets.xcassets/base-logo.imageset/base-logo.png differ diff --git a/Planet/versioning.xcconfig b/Planet/versioning.xcconfig index 45dca1bc..3b68b0df 100644 --- a/Planet/versioning.xcconfig +++ b/Planet/versioning.xcconfig @@ -1 +1 @@ -CURRENT_PROJECT_VERSION = 2053 +CURRENT_PROJECT_VERSION = 2058 diff --git a/PlanetLite/Croptop/MintSettings.swift b/PlanetLite/Croptop/MintSettings.swift index 538d3469..e3215c19 100644 --- a/PlanetLite/Croptop/MintSettings.swift +++ b/PlanetLite/Croptop/MintSettings.swift @@ -25,10 +25,15 @@ struct MintSettings: View { "collectionCategory", "curatorAddress", "separator1", + "label:If you want to use a different RPC endpoint, please enter it below.", "ethereumMainnetRPC", "ethereumSepoliaRPC", "optimismMainnetRPC", "optimismSepoliaRPC", + "arbitrumMainnetRPC", + "arbitrumSepoliaRPC", + "baseMainnetRPC", + "baseSepoliaRPC", // "separator2", // "highlightColor", ] @@ -55,27 +60,22 @@ struct MintSettings: View { .padding(.top, 6) .padding(.bottom, 6) } + else if key.hasPrefix("label:") { + HStack { + Text(key.replacingOccurrences(of: "label:", with: "")) + .font(.body) + .foregroundColor(.secondary) + .fixedSize(horizontal: false, vertical: true) + Spacer() + } + .padding(.bottom, 6) + } else { HStack { HStack { // You can get more logo images from: // https://cryptologos.cc/ethereum - if key == "ethereumMainnetRPC" - || key == "ethereumSepoliaRPC" - { - Image("eth-logo") - .interpolation(.high) - .resizable() - .frame(width: LOGO_SIZE, height: LOGO_SIZE) - } - if key == "optimismMainnetRPC" - || key == "optimismSepoliaRPC" - { - Image("op-logo") - .interpolation(.high) - .resizable() - .frame(width: LOGO_SIZE, height: LOGO_SIZE) - } + cryptoLogo(key) Text("\(settings[key]?.name ?? key)") Spacer() } @@ -161,4 +161,40 @@ struct MintSettings: View { } ) } + + @ViewBuilder + private func cryptoLogo(_ key: String) -> some View { + if key == "ethereumMainnetRPC" + || key == "ethereumSepoliaRPC" + { + Image("eth-logo") + .interpolation(.high) + .resizable() + .frame(width: LOGO_SIZE, height: LOGO_SIZE) + } + if key == "optimismMainnetRPC" + || key == "optimismSepoliaRPC" + { + Image("op-logo") + .interpolation(.high) + .resizable() + .frame(width: LOGO_SIZE, height: LOGO_SIZE) + } + if key == "arbitrumMainnetRPC" + || key == "arbitrumSepoliaRPC" + { + Image("arb-logo") + .interpolation(.high) + .resizable() + .frame(width: LOGO_SIZE, height: LOGO_SIZE) + } + if key == "baseMainnetRPC" + || key == "baseSepoliaRPC" + { + Image("base-logo") + .interpolation(.high) + .resizable() + .frame(width: LOGO_SIZE, height: LOGO_SIZE) + } + } }