浏览代码

1.全新的会员入口
2.修复其他 bug

100Years 2 周之前
父节点
当前提交
869044f571

+ 4 - 0
AIEmoji.xcodeproj/project.pbxproj

@@ -101,6 +101,7 @@
 		A81BECA82DD1F075005D06A2 /* TSGeneratoringAnimationView.swift in Sources */ = {isa = PBXBuildFile; fileRef = A81BECA72DD1F071005D06A2 /* TSGeneratoringAnimationView.swift */; };
 		A81BECAC2DD31F4E005D06A2 /* TSImageComparisonView.swift in Sources */ = {isa = PBXBuildFile; fileRef = A81BECAB2DD31F4E005D06A2 /* TSImageComparisonView.swift */; };
 		A81BECAE2DD31FF0005D06A2 /* TYCycleImageComparisonView.swift in Sources */ = {isa = PBXBuildFile; fileRef = A81BECAD2DD31FEE005D06A2 /* TYCycleImageComparisonView.swift */; };
+		A81BECB12DD4AE9A005D06A2 /* Poppins-BoldItalic.otf in Resources */ = {isa = PBXBuildFile; fileRef = A81BECB02DD4AE9A005D06A2 /* Poppins-BoldItalic.otf */; };
 		A82D60792DB7703D00596190 /* TSAIExpandImageVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = A82D60782DB7703C00596190 /* TSAIExpandImageVC.swift */; };
 		A82D607B2DB7724700596190 /* TSAIExpandStyleView.swift in Sources */ = {isa = PBXBuildFile; fileRef = A82D607A2DB7724600596190 /* TSAIExpandStyleView.swift */; };
 		A82D607D2DB7748800596190 /* ai_expand_image_style.json in Resources */ = {isa = PBXBuildFile; fileRef = A82D607C2DB7748200596190 /* ai_expand_image_style.json */; };
@@ -368,6 +369,7 @@
 		A81BECA72DD1F071005D06A2 /* TSGeneratoringAnimationView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TSGeneratoringAnimationView.swift; sourceTree = "<group>"; };
 		A81BECAB2DD31F4E005D06A2 /* TSImageComparisonView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TSImageComparisonView.swift; sourceTree = "<group>"; };
 		A81BECAD2DD31FEE005D06A2 /* TYCycleImageComparisonView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TYCycleImageComparisonView.swift; sourceTree = "<group>"; };
+		A81BECB02DD4AE9A005D06A2 /* Poppins-BoldItalic.otf */ = {isa = PBXFileReference; lastKnownFileType = file; path = "Poppins-BoldItalic.otf"; sourceTree = "<group>"; };
 		A82D60782DB7703C00596190 /* TSAIExpandImageVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TSAIExpandImageVC.swift; sourceTree = "<group>"; };
 		A82D607A2DB7724600596190 /* TSAIExpandStyleView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TSAIExpandStyleView.swift; sourceTree = "<group>"; };
 		A82D607C2DB7748200596190 /* ai_expand_image_style.json */ = {isa = PBXFileReference; lastKnownFileType = text.json; path = ai_expand_image_style.json; sourceTree = "<group>"; };
@@ -2011,6 +2013,7 @@
 			children = (
 				A83404D62D9D34ED00C140E4 /* Kelsi-fill.otf */,
 				A83404D72D9D34ED00C140E4 /* Kelsi-Regular.otf */,
+				A81BECB02DD4AE9A005D06A2 /* Poppins-BoldItalic.otf */,
 				A83404CB2D9BEED800C140E4 /* Poppins-BlackItalic.ttf */,
 				A83404DA2D9D382200C140E4 /* AccentURW-Reg.ttf */,
 				A8FDB17F2DCC8C5600E9919B /* catPaw_left.gif */,
@@ -2165,6 +2168,7 @@
 				A8EEADD62D3E6CD80032C5A0 /* Fish🐠.json in Resources */,
 				A8EEADE22D3E76110032C5A0 /* Dog🐕.json in Resources */,
 				A83405032DA35CB700C140E4 /* InfoPlist.strings in Resources */,
+				A81BECB12DD4AE9A005D06A2 /* Poppins-BoldItalic.otf in Resources */,
 				A8EEADD82D3E74D20032C5A0 /* Pink🩷.json in Resources */,
 				A80E723F2D3F4D3700C64288 /* Universe🌍.json in Resources */,
 				A8EEADDE2D3E75610032C5A0 /* Fruit🍊.json in Resources */,

+ 0 - 0
AIEmoji/Assets.xcassets/Common/launch_all.imageset/Contents.json → AIEmoji/Assets.xcassets/Common/launch_allLanch.imageset/Contents.json


+ 0 - 0
AIEmoji/Assets.xcassets/Common/launch_all.imageset/launch_all@2x.png → AIEmoji/Assets.xcassets/Common/launch_allLanch.imageset/launch_all@2x.png


+ 0 - 0
AIEmoji/Assets.xcassets/Common/launch_all.imageset/launch_all@3x.png → AIEmoji/Assets.xcassets/Common/launch_allLanch.imageset/launch_all@3x.png


+ 7 - 7
AIEmoji/Base.lproj/LaunchScreen.storyboard

@@ -16,17 +16,17 @@
                         <rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
                         <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
                         <subviews>
-                            <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="launch_all" highlighted="YES" translatesAutoresizingMaskIntoConstraints="NO" id="FfL-7D-71P">
-                                <rect key="frame" x="-1" y="-1" width="393" height="854"/>
+                            <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="launch_allLanch" highlighted="YES" translatesAutoresizingMaskIntoConstraints="NO" id="FfL-7D-71P">
+                                <rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
                             </imageView>
                         </subviews>
                         <viewLayoutGuide key="safeArea" id="6Tk-OE-BBY"/>
                         <color key="backgroundColor" red="0.027450980392156862" green="0.031372549019607843" blue="0.047058823529411764" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                         <constraints>
-                            <constraint firstItem="FfL-7D-71P" firstAttribute="leading" secondItem="6Tk-OE-BBY" secondAttribute="leading" constant="-1" id="8Gj-dY-fqQ"/>
-                            <constraint firstAttribute="bottom" secondItem="FfL-7D-71P" secondAttribute="bottom" constant="-1" id="8ZS-ob-UGd"/>
-                            <constraint firstItem="FfL-7D-71P" firstAttribute="top" secondItem="Ze5-6b-2t3" secondAttribute="top" constant="-1" id="Mrk-rv-06S"/>
-                            <constraint firstItem="FfL-7D-71P" firstAttribute="trailing" secondItem="6Tk-OE-BBY" secondAttribute="trailing" constant="-1" id="bxL-Ck-xdu"/>
+                            <constraint firstItem="FfL-7D-71P" firstAttribute="leading" secondItem="6Tk-OE-BBY" secondAttribute="leading" id="8Gj-dY-fqQ"/>
+                            <constraint firstAttribute="bottom" secondItem="FfL-7D-71P" secondAttribute="bottom" id="8ZS-ob-UGd"/>
+                            <constraint firstItem="FfL-7D-71P" firstAttribute="top" secondItem="Ze5-6b-2t3" secondAttribute="top" id="Mrk-rv-06S"/>
+                            <constraint firstItem="FfL-7D-71P" firstAttribute="trailing" secondItem="6Tk-OE-BBY" secondAttribute="trailing" id="bxL-Ck-xdu"/>
                         </constraints>
                     </view>
                 </viewController>
@@ -36,6 +36,6 @@
         </scene>
     </scenes>
     <resources>
-        <image name="launch_all" width="375" height="812"/>
+        <image name="launch_allLanch" width="375" height="812"/>
     </resources>
 </document>

+ 3 - 3
AIEmoji/Business/TSAILIstVC/TSAIUploadPhotoBaseVC/TSAIUploadPhotoBaseVC.swift

@@ -290,13 +290,13 @@ class TSAIUploadPhotoBaseVC: TSBaseVC {
         segmentedView.addTarget(self,action: #selector(segmentedControlValueChanged(_:)),for: .valueChanged)
         return segmentedView
     }()
-    var additionalPrompt = "female"
+    var additionalPrompt = ",female"
     @objc func segmentedControlValueChanged(_ sender: BetterSegmentedControl) {
         switch sender.index {
         case 0:
-            additionalPrompt = "female"//女
+            additionalPrompt = ",female"//女
         case 1:
-            additionalPrompt = "male"//男
+            additionalPrompt = ",male"//男
         default:
             additionalPrompt = ""
         }

+ 42 - 84
AIEmoji/Business/TSSetingVC/SetingVC/View/SettingPurchaseTopView.swift

@@ -9,104 +9,62 @@ struct SettingPurchaseTopView: View {
     var eventPublisher: ListEventPublisher
     @Binding var vipType: PremiumPeriod
     var body: some View {
-        let contentW = 343*kDesignScale
-        let contentH = 118*kDesignScale
-        let vipType = PremiumPeriod.week
+        let topW = k_ScreenWidth-32
+        let topH = 134.0    //kGetScaleHeight(originalSize: CGSize(width: 343, height: 130), width: topW)
+        let updateText = vipType == .week ? "Upgrade Yearly Pro".localized : "Update to PRO".localized
         ZStack {
-            Color.clear
-            Image(.settingVipBj).resizable()//.frame(width: contentW, height: contentH)
-            
-            if vipType == .none {
-                HStack {
-                    Spacer().frame(width:20)
-                    
-                    VStack(alignment: .leading,spacing: 12) {
-                        customText(text: "\(kAppName) ",fontName: .KelsiFill,color:UIColor.white.color).frame(height: 50*kDesignScale)
-                        HStack {
-                            Text("Limited Time Discount".localized)
-                                .font(.font(size: 14))
-                                .frame(height: 14)
-                                .foregroundColor(UIColor.white.withAlphaComponent(0.6).color)
-                            
-                            Spacer()
-                        }
-                    }
-                    
-                    Spacer()
-                    
-                    Text("Upgrade".localized)
+            Image(.settingVipBj).resizable().cornerRadius(16.0)
+            if vipType == .year {
+                VStack(alignment: .center) {
+                    customGradientText(text: "\(kAppName) pro", font: .font(name: .PoppinsBoldItalic,size: 36))
+                    Spacer().frame(height: 16)
+                    Text("Due Date:".localized + " \(PurchaseManager.default.expiredDateString)")
+                        .foregroundColor(.white.opacity(0.6))
                         .font(.font(size: 14,weight: .medium))
-                        .padding(EdgeInsets(top: 0, leading: 12, bottom: 0, trailing: 12))
-                        .frame(height: 26) // 设置高度
-                        .foregroundColor("#010101".uiColor.color)
-                        .background(UIColor.themeColor.color)
-                        .cornerRadius(13.0) // 圆角
-//                        .onTapGesture {
-//                            eventPublisher.enterPurchasePublisher.send(true)
-//                        }
-
-                        Spacer().frame(width: 15)
-                }//.padding(.all,7)
-            }else if vipType == .week {
-                ZStack(){//}(alignment: .topTrailing) { // 对齐到右上角
+                        .frame(height: 14)
+                }//.border(Color.blue, width: 1)
+            }else{
+                VStack(){
                     HStack {
-                        Spacer().frame(width:33)
-                        
-                        VStack(alignment: .leading,spacing: 19) {
-                            customGradientText(text: "Upgrade Yearly Pro".localized, font: .font(name: .PoppinsBlackItalic,size: 22)).frame(height: 26)
+                        VStack(alignment: .leading,spacing: 8) {
+                            customGradientText(text: updateText, font: .font(name: .PoppinsBoldItalic,size: 22),colors: [.white]).frame(height: 26)
                             HStack {
-                                Text("Due Date:".localized + " \(PurchaseManager.default.expiredDateString)")
-                                    .foregroundColor(.white.opacity(0.6))
-                                    .font(.font(size: 14,weight: .regular))
+                                Text("Limited Time Discount".localized)
+                                    .font(.font(size: 14))
                                     .frame(height: 14)
+                                    .foregroundColor(UIColor.white.withAlphaComponent(0.6).color)
                                 Spacer()
                             }
                         }
+                        
                         Spacer()
+                 
+                        Text("Save-Vip".localized + " 80%")
+                            .foregroundColor(Color.white)
+                            .font(.font(size: 12,weight: .semibold))
+                            .frame(width: 82, height: 28, alignment: .center)
+                            .foregroundColor("#010101".uiColor.color)
+                            .background(Color.hex("#E83E3E"))
+                            .cornerRadius(4.0)
+                            .rotationEffect(.degrees(15)) // 向右旋转45度
                     }
-                    .border(Color.red, width: 1)
-                    //.padding(.all,20)
                     
-
-                  
+                    Spacer().frame(width: 12)
                     
-                }
-            }else if vipType == .year {
-                VStack {
-                    Spacer().frame(height: 20)
-                    customGradientText(text: "\(kAppName) ",font: .font(name: .KelsiFill,size: 48)).frame(height: 50*kDesignScale)
-                    Spacer()
-
-                    Text("Due Date:".localized + " \(PurchaseManager.default.expiredDateString)")
-                        .foregroundColor(.white.opacity(0.6))
+                    Text("Upgrade".localized)
                         .font(.font(size: 14,weight: .medium))
-                        .frame(height: 14)
+                        .frame(width: topW-32, height: 38, alignment: .center)
+                        .foregroundColor("#010101".uiColor.color)
+                        .background(UIColor.themeColor.color)
+                        .cornerRadius(8.0) // 圆角
+                        .onTapGesture {
+                            eventPublisher.enterPurchasePublisher.send(true)
+                        }
 
-                    Spacer().frame(height: 22)
-                }//.padding(.all,7)
+                }.padding(.all,16.0)
             }
 
-            
-            ZStack(alignment: .topTrailing){
-                
-                Color.clear
-                ZStack(alignment: .center){
-                    Image(.settingVipCornerMark)
-                    .resizable()
-                    .frame(width: 106, height: 103)
-                    Text("Save-Vip".localized + " 80%")
-                        .foregroundColor(Color.hex("#111111"))
-                        .font(.font(size: 12))
-                        .offset(x: 0, y: -22)
-                        .rotationEffect(.degrees(45)) // 向右旋转45度
-                }
-                //.offset(x: -3, y: -7)
-                .border(Color.yellow, width: 1)
-    
-            }
-            
-        }//.padding(.all,7)
-            .border(Color.blue, width: 1)
+        }.frame(width: topW, height: topH)
     }
     
     // 定义一个返回 View 的方法
@@ -125,11 +83,11 @@ struct SettingPurchaseTopView: View {
 //            .minimumScaleFactor(0.5) // 最小缩放比例(0.5表示最小可缩放到初始大小的50%)
     }
     
-    func customGradientText(text:String,font:Font) -> some View {
+    func customGradientText(text:String,font:Font,colors:[Color] = [.hex("#FA794F"),.hex("#F8C32A"),.hex("#FEFBF4")]) -> some View {
         return Text(text)
             .font(font)
             .gradientForeground(
-                colors: [.hex("#FA794F"),.hex("#F8C32A"),.hex("#FEFBF4")],
+                colors: colors,
                 startPoint: UnitPoint.leading,
                 endPoint: UnitPoint.trailing
             )

+ 3 - 9
AIEmoji/Business/TSSetingVC/SetingVC/View/TSSettingListView.swift

@@ -14,10 +14,8 @@ struct TSSettingListView: View {
         CocoaScrollView {
             VStack(spacing: 0) {
                 Spacer().frame(height: 16)
-                
+        
                 SettingPurchaseTopView(eventPublisher: publisher, vipType: $viewModel.vipType)
-                    .frame(height: 118*kDesignScale)
-                    .padding(.all,9)
                     .onTapGesture {
                         publisher.enterPurchasePublisher.send(true)
                     }
@@ -28,19 +26,15 @@ struct TSSettingListView: View {
                     .onTapGesture {
                         publisher.settingPublisher.send(type)
                     }
-                }.padding(.horizontal,16)
+                }
                 
                 Spacer()
 
-            }
-         
+            }.padding(.horizontal)
             Spacer().frame(height: 20)
         }
         .alwaysBounceVertical(true)
         .scrollIndicatorStyle(HiddenScrollViewIndicatorStyle())
-        
-    
-        
     }
 }
 

+ 1 - 0
AIEmoji/Business/VIewTool/TSGeneratorloadingView/TSGeneratorloadingView.swift

@@ -151,6 +151,7 @@ class TSGeneratorView: TSBaseView {
     
     @objc func clickErrorBtn() {
         clickErrorBlock?(self.style)
+        errorView.submitBtn.preventMultipleTaps()
     }
     
 }

+ 1 - 0
AIEmoji/Common/Ex/UIFont+TSEx.swift

@@ -8,6 +8,7 @@
 public extension FontName {
     static let AccentURW   = "AccentURWReg"
     static let PoppinsBlackItalic   = "Poppins-BlackItalic"
+    static let PoppinsBoldItalic   = "Poppins-BoldItalic"
     
     static let KelsiFill   = "Kelsi 1"
     static let KelsiRegular   = "Kelsi"

+ 1 - 0
AIEmoji/Info.plist

@@ -22,6 +22,7 @@
 	</dict>
 	<key>UIAppFonts</key>
 	<array>
+		<string>Poppins-BoldItalic.otf</string>
 		<string>Poppins-BlackItalic.ttf</string>
 		<string>AccentURW-Reg.ttf</string>
 		<string>Kelsi-fill.otf</string>

二进制
AIEmoji/Res/Poppins-BoldItalic.otf