Преглед на файлове

feat:
1.开发最新 tabbar UI
2.将 vc的数据,移动到 vm中
3.会员开发 周和年

100Years преди 2 месеца
родител
ревизия
1ae2c68b16
променени са 76 файла, в които са добавени 423 реда и са изтрити 648 реда
  1. 12 0
      TSLiveWallpaper.xcodeproj/project.pbxproj
  2. BIN
      TSLiveWallpaper/Assets.xcassets/AIList/nav_title_ailist.imageset/nav_title_ailist@2x.png
  3. BIN
      TSLiveWallpaper/Assets.xcassets/AIList/nav_title_ailist.imageset/nav_title_ailist@3x.png
  4. BIN
      TSLiveWallpaper/Assets.xcassets/Common/normal_submit_bg.imageset/normal_submit_bg@2x.png
  5. BIN
      TSLiveWallpaper/Assets.xcassets/Common/normal_submit_bg.imageset/normal_submit_bg@3x.png
  6. BIN
      TSLiveWallpaper/Assets.xcassets/Common/view_main_bg.imageset/view_main_bg@2x.png
  7. BIN
      TSLiveWallpaper/Assets.xcassets/Common/view_main_bg.imageset/view_main_bg@3x.png
  8. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_ailist.imageset/tabbar_select_ailist@2x.png
  9. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_ailist.imageset/tabbar_select_ailist@3x.png
  10. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_edit.imageset/tabbar_select_edit@2x.png
  11. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_edit.imageset/tabbar_select_edit@3x.png
  12. 2 2
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_history.imageset/Contents.json
  13. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_history.imageset/tabbar_select_history@2x.png
  14. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_history.imageset/tabbar_select_history@3x.png
  15. 0 22
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_home.imageset/Contents.json
  16. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_home.imageset/tabbar_select_home@2x.png
  17. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_home.imageset/tabbar_select_home@3x.png
  18. 0 22
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_mark.imageset/Contents.json
  19. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_mark.imageset/tabbar_select_mark@2x.png
  20. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_mark.imageset/tabbar_select_mark@3x.png
  21. 0 22
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_mine.imageset/Contents.json
  22. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_mine.imageset/tabbar_select_mine@2x.png
  23. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_mine.imageset/tabbar_select_mine@3x.png
  24. 0 23
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_music.imageset/Contents.json
  25. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_music.imageset/tabbar_select_music@1x.png
  26. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_music.imageset/tabbar_select_music@2x.png
  27. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_music.imageset/tabbar_select_music@3x.png
  28. 0 26
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_playlist.imageset/Contents.json
  29. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_playlist.imageset/tabbar_select_playlist@1x.png
  30. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_playlist.imageset/tabbar_select_playlist@2x.png
  31. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_playlist.imageset/tabbar_select_playlist@3x.png
  32. 0 22
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_random.imageset/Contents.json
  33. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_random.imageset/tabbar_select_random@2x.png
  34. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_random.imageset/tabbar_select_random@3x.png
  35. 2 2
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_setting.imageset/Contents.json
  36. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_setting.imageset/tabbar_select_setting@2x.png
  37. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_setting.imageset/tabbar_select_setting@3x.png
  38. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_allist.imageset/tabbar_unSelect_allist@2x.png
  39. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_allist.imageset/tabbar_unSelect_allist@3x.png
  40. 0 22
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_edit.imageset/Contents.json
  41. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_edit.imageset/tabbar_unSelect_edit@2x.png
  42. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_edit.imageset/tabbar_unSelect_edit@3x.png
  43. 2 2
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_history.imageset/Contents.json
  44. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_history.imageset/tabbar_unSelect_history@2x.png
  45. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_history.imageset/tabbar_unSelect_history@3x.png
  46. 0 22
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_home.imageset/Contents.json
  47. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_home.imageset/tabbar_unSelect_home@2x.png
  48. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_home.imageset/tabbar_unSelect_home@3x.png
  49. 0 22
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_mine.imageset/Contents.json
  50. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_mine.imageset/tabbar_unSelect_mine@2x.png
  51. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_mine.imageset/tabbar_unSelect_mine@3x.png
  52. 0 23
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_music.imageset/Contents.json
  53. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_music.imageset/tabbar_unSelect_music@1x.png
  54. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_music.imageset/tabbar_unSelect_music@2x.png
  55. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_music.imageset/tabbar_unSelect_music@3x.png
  56. 0 22
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_random.imageset/Contents.json
  57. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_random.imageset/tabbar_unSelect_random@2x.png
  58. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_random.imageset/tabbar_unSelect_random@3x.png
  59. 2 2
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_setting.imageset/Contents.json
  60. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_setting.imageset/tabbar_unSelect_setting@2x.png
  61. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_setting.imageset/tabbar_unSelect_setting@3x.png
  62. 0 26
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unselect_playlist.imageset/Contents.json
  63. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unselect_playlist.imageset/tabbar_unselect_playlist@1x.png
  64. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unselect_playlist.imageset/tabbar_unselect_playlist@2x.png
  65. BIN
      TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unselect_playlist.imageset/tabbar_unselect_playlist@3x.png
  66. 12 8
      TSLiveWallpaper/Business/TSAIListVC/TSAIListHistoryVC/TSAIListHistoryVC.swift
  67. 20 196
      TSLiveWallpaper/Business/TSAIListVC/TSAIListVC/TSAIListVC.swift
  68. 182 0
      TSLiveWallpaper/Business/TSAIListVC/TSAIListVC/TSAIListVM.swift
  69. 5 137
      TSLiveWallpaper/Business/TSMineVC/TSMineVC.swift
  70. 151 0
      TSLiveWallpaper/Business/TSMineVC/TSMineVM.swift
  71. 4 4
      TSLiveWallpaper/Business/TSPurchaseMembershipVC/TSPurchaseVC.swift
  72. 24 19
      TSLiveWallpaper/Business/TSTabBarController/TSTabBarController.swift
  73. 1 0
      TSLiveWallpaper/Common/Ex/UIFont+Ex.swift
  74. 3 2
      TSLiveWallpaper/Common/Purchase/TSPurchaseBusiness.swift
  75. 1 0
      TSLiveWallpaper/Info.plist
  76. BIN
      TSLiveWallpaper/Resource/Font/Pacifico-Regular.ttf

+ 12 - 0
TSLiveWallpaper.xcodeproj/project.pbxproj

@@ -121,6 +121,9 @@
 		A8EE92CE2DFFF2860077DFFD /* TSGenerateBaseOperation.swift in Sources */ = {isa = PBXBuildFile; fileRef = A8EE92C72DFFF2860077DFFD /* TSGenerateBaseOperation.swift */; };
 		A8EE92CF2DFFF2860077DFFD /* TSGenerateBasePhotoOperation.swift in Sources */ = {isa = PBXBuildFile; fileRef = A8EE92C82DFFF2860077DFFD /* TSGenerateBasePhotoOperation.swift */; };
 		A8EE92D02DFFF2860077DFFD /* TSBaseOperationQueue.swift in Sources */ = {isa = PBXBuildFile; fileRef = A8EE92CA2DFFF2860077DFFD /* TSBaseOperationQueue.swift */; };
+		A8EE92D22DFFFE2F0077DFFD /* TSMineVM.swift in Sources */ = {isa = PBXBuildFile; fileRef = A8EE92D12DFFFE250077DFFD /* TSMineVM.swift */; };
+		A8EE92D42DFFFFAD0077DFFD /* TSAIListVM.swift in Sources */ = {isa = PBXBuildFile; fileRef = A8EE92D32DFFFFAA0077DFFD /* TSAIListVM.swift */; };
+		A8EE92D62E0005F70077DFFD /* Pacifico-Regular.ttf in Resources */ = {isa = PBXBuildFile; fileRef = A8EE92D52E0005F70077DFFD /* Pacifico-Regular.ttf */; };
 		A8F76C422D350A9600AA6E93 /* TSPurchaseManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = A8F76C3E2D350A9600AA6E93 /* TSPurchaseManager.swift */; };
 		A8F76C4D2D3747B400AA6E93 /* TSPurchaseVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = A8F76C4C2D3747AB00AA6E93 /* TSPurchaseVC.swift */; };
 		A8F778AE2D1AC12400BF55D5 /* TSRandomWallpaperBrowseView.swift in Sources */ = {isa = PBXBuildFile; fileRef = A8F778AD2D1AC12100BF55D5 /* TSRandomWallpaperBrowseView.swift */; };
@@ -265,6 +268,9 @@
 		A8EE92C82DFFF2860077DFFD /* TSGenerateBasePhotoOperation.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TSGenerateBasePhotoOperation.swift; sourceTree = "<group>"; };
 		A8EE92CA2DFFF2860077DFFD /* TSBaseOperationQueue.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TSBaseOperationQueue.swift; sourceTree = "<group>"; };
 		A8EE92CB2DFFF2860077DFFD /* TSBaseOperation.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TSBaseOperation.swift; sourceTree = "<group>"; };
+		A8EE92D12DFFFE250077DFFD /* TSMineVM.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TSMineVM.swift; sourceTree = "<group>"; };
+		A8EE92D32DFFFFAA0077DFFD /* TSAIListVM.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TSAIListVM.swift; sourceTree = "<group>"; };
+		A8EE92D52E0005F70077DFFD /* Pacifico-Regular.ttf */ = {isa = PBXFileReference; lastKnownFileType = file; path = "Pacifico-Regular.ttf"; sourceTree = "<group>"; };
 		A8F76C3E2D350A9600AA6E93 /* TSPurchaseManager.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TSPurchaseManager.swift; sourceTree = "<group>"; };
 		A8F76C4C2D3747AB00AA6E93 /* TSPurchaseVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TSPurchaseVC.swift; sourceTree = "<group>"; };
 		A8F778AD2D1AC12100BF55D5 /* TSRandomWallpaperBrowseView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TSRandomWallpaperBrowseView.swift; sourceTree = "<group>"; };
@@ -466,6 +472,7 @@
 				A8FD8F362DFBD650008CAACF /* View */,
 				A839461C2D1D61A900ABFF0D /* VC */,
 				A81CA4982D1652C200A3AAC8 /* TSMineVC.swift */,
+				A8EE92D12DFFFE250077DFFD /* TSMineVM.swift */,
 				A81CA4A92D16943200A3AAC8 /* TSMineCell.swift */,
 			);
 			path = TSMineVC;
@@ -518,6 +525,7 @@
 				A8FD8F302DFBCB85008CAACF /* ZillaSlab-BoldItalic.ttf */,
 				A8FD8F312DFBCB85008CAACF /* ZillaSlab-Medium.ttf */,
 				A8FD8F322DFBCB85008CAACF /* ZillaSlab-Regular.ttf */,
+				A8EE92D52E0005F70077DFFD /* Pacifico-Regular.ttf */,
 				A86857C52DF92BE70089D222 /* ZillaSlab-Bold.ttf */,
 			);
 			path = Font;
@@ -721,6 +729,7 @@
 		A868579F2DF91EA10089D222 /* TSAIListVC */ = {
 			isa = PBXGroup;
 			children = (
+				A8EE92D32DFFFFAA0077DFFD /* TSAIListVM.swift */,
 				A86857A02DF91EB80089D222 /* TSAIListVC.swift */,
 				A86857A22DF91F680089D222 /* TSAILIstCell.swift */,
 			);
@@ -1029,6 +1038,7 @@
 				A8E56BF92D1520EC003C54AF /* Assets.xcassets in Resources */,
 				A81F5B522D19685900740085 /* response.json in Resources */,
 				A8E56BFB2D1520EC003C54AF /* LaunchScreen.storyboard in Resources */,
+				A8EE92D62E0005F70077DFFD /* Pacifico-Regular.ttf in Resources */,
 			);
 			runOnlyForDeploymentPostprocessing = 0;
 		};
@@ -1143,6 +1153,7 @@
 				A86857892DF81B660089D222 /* TSNetworkManager+Loading.swift in Sources */,
 				A86857A32DF91F690089D222 /* TSAILIstCell.swift in Sources */,
 				A868577C2DF819BB0089D222 /* TSDBManager.swift in Sources */,
+				A8EE92D22DFFFE2F0077DFFD /* TSMineVM.swift in Sources */,
 				A86857BE2DF926220089D222 /* TSAIListHistoryCell.swift in Sources */,
 				A86857DD2DF99C200089D222 /* TSImageIPanComparisonView.swift in Sources */,
 				A86857D32DF978740089D222 /* TSProgressState.swift in Sources */,
@@ -1161,6 +1172,7 @@
 				A84C239D2D1E3A4300B61B55 /* GPVideoConfigMaker.swift in Sources */,
 				A839463C2D1D6E3600ABFF0D /* TSRandomWallpaperCopyrightVC.swift in Sources */,
 				A81CA4952D1652B500A3AAC8 /* TSEditLiveVC.swift in Sources */,
+				A8EE92D42DFFFFAD0077DFFD /* TSAIListVM.swift in Sources */,
 				A86857D12DF977980089D222 /* TSAIListPhotoGeneratorVM.swift in Sources */,
 				A8E590392DFFAE4400C2533F /* TSBootVC.swift in Sources */,
 				A86857982DF846FE0089D222 /* TSDynamicBlurView.swift in Sources */,

BIN
TSLiveWallpaper/Assets.xcassets/AIList/nav_title_ailist.imageset/nav_title_ailist@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/AIList/nav_title_ailist.imageset/nav_title_ailist@3x.png


BIN
TSLiveWallpaper/Assets.xcassets/Common/normal_submit_bg.imageset/normal_submit_bg@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Common/normal_submit_bg.imageset/normal_submit_bg@3x.png


BIN
TSLiveWallpaper/Assets.xcassets/Common/view_main_bg.imageset/view_main_bg@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Common/view_main_bg.imageset/view_main_bg@3x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_ailist.imageset/tabbar_select_ailist@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_ailist.imageset/tabbar_select_ailist@3x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_edit.imageset/tabbar_select_edit@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_edit.imageset/tabbar_select_edit@3x.png


+ 2 - 2
TSLiveWallpaper/Assets.xcassets/AIList/nav_title_ailist.imageset/Contents.json → TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_history.imageset/Contents.json

@@ -5,12 +5,12 @@
       "scale" : "1x"
     },
     {
-      "filename" : "nav_title_ailist@2x.png",
+      "filename" : "tabbar_select_history@2x.png",
       "idiom" : "universal",
       "scale" : "2x"
     },
     {
-      "filename" : "nav_title_ailist@3x.png",
+      "filename" : "tabbar_select_history@3x.png",
       "idiom" : "universal",
       "scale" : "3x"
     }

BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_history.imageset/tabbar_select_history@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_history.imageset/tabbar_select_history@3x.png


+ 0 - 22
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_home.imageset/Contents.json

@@ -1,22 +0,0 @@
-{
-  "images" : [
-    {
-      "idiom" : "universal",
-      "scale" : "1x"
-    },
-    {
-      "filename" : "tabbar_select_home@2x.png",
-      "idiom" : "universal",
-      "scale" : "2x"
-    },
-    {
-      "filename" : "tabbar_select_home@3x.png",
-      "idiom" : "universal",
-      "scale" : "3x"
-    }
-  ],
-  "info" : {
-    "author" : "xcode",
-    "version" : 1
-  }
-}

BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_home.imageset/tabbar_select_home@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_home.imageset/tabbar_select_home@3x.png


+ 0 - 22
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_mark.imageset/Contents.json

@@ -1,22 +0,0 @@
-{
-  "images" : [
-    {
-      "idiom" : "universal",
-      "scale" : "1x"
-    },
-    {
-      "filename" : "tabbar_select_mark@2x.png",
-      "idiom" : "universal",
-      "scale" : "2x"
-    },
-    {
-      "filename" : "tabbar_select_mark@3x.png",
-      "idiom" : "universal",
-      "scale" : "3x"
-    }
-  ],
-  "info" : {
-    "author" : "xcode",
-    "version" : 1
-  }
-}

BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_mark.imageset/tabbar_select_mark@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_mark.imageset/tabbar_select_mark@3x.png


+ 0 - 22
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_mine.imageset/Contents.json

@@ -1,22 +0,0 @@
-{
-  "images" : [
-    {
-      "idiom" : "universal",
-      "scale" : "1x"
-    },
-    {
-      "filename" : "tabbar_select_mine@2x.png",
-      "idiom" : "universal",
-      "scale" : "2x"
-    },
-    {
-      "filename" : "tabbar_select_mine@3x.png",
-      "idiom" : "universal",
-      "scale" : "3x"
-    }
-  ],
-  "info" : {
-    "author" : "xcode",
-    "version" : 1
-  }
-}

BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_mine.imageset/tabbar_select_mine@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_mine.imageset/tabbar_select_mine@3x.png


+ 0 - 23
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_music.imageset/Contents.json

@@ -1,23 +0,0 @@
-{
-  "images" : [
-    {
-      "filename" : "tabbar_select_music@1x.png",
-      "idiom" : "universal",
-      "scale" : "1x"
-    },
-    {
-      "filename" : "tabbar_select_music@2x.png",
-      "idiom" : "universal",
-      "scale" : "2x"
-    },
-    {
-      "filename" : "tabbar_select_music@3x.png",
-      "idiom" : "universal",
-      "scale" : "3x"
-    }
-  ],
-  "info" : {
-    "author" : "xcode",
-    "version" : 1
-  }
-}

BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_music.imageset/tabbar_select_music@1x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_music.imageset/tabbar_select_music@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_music.imageset/tabbar_select_music@3x.png


+ 0 - 26
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_playlist.imageset/Contents.json

@@ -1,26 +0,0 @@
-{
-  "images" : [
-    {
-      "filename" : "tabbar_select_playlist@1x.png",
-      "idiom" : "universal",
-      "scale" : "1x"
-    },
-    {
-      "filename" : "tabbar_select_playlist@2x.png",
-      "idiom" : "universal",
-      "scale" : "2x"
-    },
-    {
-      "filename" : "tabbar_select_playlist@3x.png",
-      "idiom" : "universal",
-      "scale" : "3x"
-    }
-  ],
-  "info" : {
-    "author" : "xcode",
-    "version" : 1
-  },
-  "properties" : {
-    "template-rendering-intent" : "original"
-  }
-}

BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_playlist.imageset/tabbar_select_playlist@1x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_playlist.imageset/tabbar_select_playlist@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_playlist.imageset/tabbar_select_playlist@3x.png


+ 0 - 22
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_random.imageset/Contents.json

@@ -1,22 +0,0 @@
-{
-  "images" : [
-    {
-      "idiom" : "universal",
-      "scale" : "1x"
-    },
-    {
-      "filename" : "tabbar_select_random@2x.png",
-      "idiom" : "universal",
-      "scale" : "2x"
-    },
-    {
-      "filename" : "tabbar_select_random@3x.png",
-      "idiom" : "universal",
-      "scale" : "3x"
-    }
-  ],
-  "info" : {
-    "author" : "xcode",
-    "version" : 1
-  }
-}

BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_random.imageset/tabbar_select_random@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_random.imageset/tabbar_select_random@3x.png


+ 2 - 2
TSLiveWallpaper/Assets.xcassets/Common/view_main_bg.imageset/Contents.json → TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_setting.imageset/Contents.json

@@ -5,12 +5,12 @@
       "scale" : "1x"
     },
     {
-      "filename" : "view_main_bg@2x.png",
+      "filename" : "tabbar_select_setting@2x.png",
       "idiom" : "universal",
       "scale" : "2x"
     },
     {
-      "filename" : "view_main_bg@3x.png",
+      "filename" : "tabbar_select_setting@3x.png",
       "idiom" : "universal",
       "scale" : "3x"
     }

BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_setting.imageset/tabbar_select_setting@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_setting.imageset/tabbar_select_setting@3x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_allist.imageset/tabbar_unSelect_allist@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_allist.imageset/tabbar_unSelect_allist@3x.png


+ 0 - 22
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_edit.imageset/Contents.json

@@ -1,22 +0,0 @@
-{
-  "images" : [
-    {
-      "idiom" : "universal",
-      "scale" : "1x"
-    },
-    {
-      "filename" : "tabbar_unSelect_edit@2x.png",
-      "idiom" : "universal",
-      "scale" : "2x"
-    },
-    {
-      "filename" : "tabbar_unSelect_edit@3x.png",
-      "idiom" : "universal",
-      "scale" : "3x"
-    }
-  ],
-  "info" : {
-    "author" : "xcode",
-    "version" : 1
-  }
-}

BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_edit.imageset/tabbar_unSelect_edit@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_edit.imageset/tabbar_unSelect_edit@3x.png


+ 2 - 2
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_select_edit.imageset/Contents.json → TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_history.imageset/Contents.json

@@ -5,12 +5,12 @@
       "scale" : "1x"
     },
     {
-      "filename" : "tabbar_select_edit@2x.png",
+      "filename" : "tabbar_unSelect_history@2x.png",
       "idiom" : "universal",
       "scale" : "2x"
     },
     {
-      "filename" : "tabbar_select_edit@3x.png",
+      "filename" : "tabbar_unSelect_history@3x.png",
       "idiom" : "universal",
       "scale" : "3x"
     }

BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_history.imageset/tabbar_unSelect_history@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_history.imageset/tabbar_unSelect_history@3x.png


+ 0 - 22
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_home.imageset/Contents.json

@@ -1,22 +0,0 @@
-{
-  "images" : [
-    {
-      "idiom" : "universal",
-      "scale" : "1x"
-    },
-    {
-      "filename" : "tabbar_unSelect_home@2x.png",
-      "idiom" : "universal",
-      "scale" : "2x"
-    },
-    {
-      "filename" : "tabbar_unSelect_home@3x.png",
-      "idiom" : "universal",
-      "scale" : "3x"
-    }
-  ],
-  "info" : {
-    "author" : "xcode",
-    "version" : 1
-  }
-}

BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_home.imageset/tabbar_unSelect_home@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_home.imageset/tabbar_unSelect_home@3x.png


+ 0 - 22
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_mine.imageset/Contents.json

@@ -1,22 +0,0 @@
-{
-  "images" : [
-    {
-      "idiom" : "universal",
-      "scale" : "1x"
-    },
-    {
-      "filename" : "tabbar_unSelect_mine@2x.png",
-      "idiom" : "universal",
-      "scale" : "2x"
-    },
-    {
-      "filename" : "tabbar_unSelect_mine@3x.png",
-      "idiom" : "universal",
-      "scale" : "3x"
-    }
-  ],
-  "info" : {
-    "author" : "xcode",
-    "version" : 1
-  }
-}

BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_mine.imageset/tabbar_unSelect_mine@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_mine.imageset/tabbar_unSelect_mine@3x.png


+ 0 - 23
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_music.imageset/Contents.json

@@ -1,23 +0,0 @@
-{
-  "images" : [
-    {
-      "filename" : "tabbar_unSelect_music@1x.png",
-      "idiom" : "universal",
-      "scale" : "1x"
-    },
-    {
-      "filename" : "tabbar_unSelect_music@2x.png",
-      "idiom" : "universal",
-      "scale" : "2x"
-    },
-    {
-      "filename" : "tabbar_unSelect_music@3x.png",
-      "idiom" : "universal",
-      "scale" : "3x"
-    }
-  ],
-  "info" : {
-    "author" : "xcode",
-    "version" : 1
-  }
-}

BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_music.imageset/tabbar_unSelect_music@1x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_music.imageset/tabbar_unSelect_music@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_music.imageset/tabbar_unSelect_music@3x.png


+ 0 - 22
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_random.imageset/Contents.json

@@ -1,22 +0,0 @@
-{
-  "images" : [
-    {
-      "idiom" : "universal",
-      "scale" : "1x"
-    },
-    {
-      "filename" : "tabbar_unSelect_random@2x.png",
-      "idiom" : "universal",
-      "scale" : "2x"
-    },
-    {
-      "filename" : "tabbar_unSelect_random@3x.png",
-      "idiom" : "universal",
-      "scale" : "3x"
-    }
-  ],
-  "info" : {
-    "author" : "xcode",
-    "version" : 1
-  }
-}

BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_random.imageset/tabbar_unSelect_random@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_random.imageset/tabbar_unSelect_random@3x.png


+ 2 - 2
TSLiveWallpaper/Assets.xcassets/Common/normal_submit_bg.imageset/Contents.json → TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_setting.imageset/Contents.json

@@ -5,12 +5,12 @@
       "scale" : "1x"
     },
     {
-      "filename" : "normal_submit_bg@2x.png",
+      "filename" : "tabbar_unSelect_setting@2x.png",
       "idiom" : "universal",
       "scale" : "2x"
     },
     {
-      "filename" : "normal_submit_bg@3x.png",
+      "filename" : "tabbar_unSelect_setting@3x.png",
       "idiom" : "universal",
       "scale" : "3x"
     }

BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_setting.imageset/tabbar_unSelect_setting@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unSelect_setting.imageset/tabbar_unSelect_setting@3x.png


+ 0 - 26
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unselect_playlist.imageset/Contents.json

@@ -1,26 +0,0 @@
-{
-  "images" : [
-    {
-      "filename" : "tabbar_unselect_playlist@1x.png",
-      "idiom" : "universal",
-      "scale" : "1x"
-    },
-    {
-      "filename" : "tabbar_unselect_playlist@2x.png",
-      "idiom" : "universal",
-      "scale" : "2x"
-    },
-    {
-      "filename" : "tabbar_unselect_playlist@3x.png",
-      "idiom" : "universal",
-      "scale" : "3x"
-    }
-  ],
-  "info" : {
-    "author" : "xcode",
-    "version" : 1
-  },
-  "properties" : {
-    "template-rendering-intent" : "original"
-  }
-}

BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unselect_playlist.imageset/tabbar_unselect_playlist@1x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unselect_playlist.imageset/tabbar_unselect_playlist@2x.png


BIN
TSLiveWallpaper/Assets.xcassets/Tabbar/tabbar_unselect_playlist.imageset/tabbar_unselect_playlist@3x.png


+ 12 - 8
TSLiveWallpaper/Business/TSAIListVC/TSAIListHistoryVC/TSAIListHistoryVC.swift

@@ -12,16 +12,20 @@ class TSAIListHistoryVC: TSBaseVC {
     var listModelArray:List<TSDBActionInfoModel> = List<TSDBActionInfoModel>()
     
     lazy var navBarView: TSBaseNavContentBarView = {
-       let navBarView = TSBaseNavContentBarView()
-       
-       let titleImageView = UIImageView.createImageView(imageName: "nav_title_ailist",contentMode: .scaleToFill)
-       navBarView.barView.addSubview(titleImageView)
-       titleImageView.snp.makeConstraints { make in
-           make.center.equalToSuperview()
-       }
+        let navBarView = TSBaseNavContentBarView()
 
+        let label = UILabel.createLabel(text: "History",font: .font(name: .Pacifico, size: 24))
+        navBarView.barView.addSubview(label)
+        label.snp.makeConstraints { make in
+           make.center.equalToSuperview()
+        }
+        
+        kMainAsync {
+            label.applyGradient(colors: ["#F1D3AB".uiColor,"#E4A858".uiColor])
+        }
+        
        return navBarView
-   }()
+    }()
     
     //###################################### 集合视图 ######################################
     let collectionViewBtootm:CGFloat = 80

+ 20 - 196
TSLiveWallpaper/Business/TSAIListVC/TSAIListVC/TSAIListVC.swift

@@ -8,125 +8,32 @@
 
 class TSAIListVC: TSBaseVC {
     
-    lazy var dataArray: [TSBasicSectionModel] = {
-        var dataArray = [TSBasicSectionModel]()
-        let sectionModel = TSBasicSectionModel()
-        dataArray.append(sectionModel)
-        
-
-        
-        //照片高清修复
-        sectionModel.addSubItemModel(
-            createItemModel(
-                leftImageName:"aiList_Enhance",
-                leftTitle: "Enhance".localized,
-                leftSubTitle: "Remove blur, sharpen, add details".localized,
-                rightViewStyle: 0,
-                tapBlock: { [weak self] model, _, _ in
-                   guard let self = self else { return }
-                    enterSelectPhotos(style: .enhance) { image in
-                    let baseVc = TSAIUploadPhotoVC(titleString: model.leftTitle ?? "",upLoadImage: image, generatorStyle: .enhance)
-                        kPushVC(target: self, modelVC: baseVc)
-                    }
-        }))
-        
-        //黑白照片变颜色
-        sectionModel.addSubItemModel(
-            createItemModel(
-                leftImageName:"aiList_Colorize",
-                leftTitle: "Colorize".localized,
-                leftSubTitle: "Add colors to black-and-white photos".localized,
-                rightViewStyle: 0,
-                tapBlock: { [weak self] model, _, _ in
-                   guard let self = self else { return }
-                    enterSelectPhotos(style: .colorize) { image in
-                    let baseVc = TSAIUploadPhotoVC(titleString: model.leftTitle ?? "",upLoadImage: image, generatorStyle: .colorize)
-                        kPushVC(target: self, modelVC: baseVc)
-                    }
-        }))
-        
-        //老照片修复
-        sectionModel.addSubItemModel(
-            createItemModel(
-                leftImageName:"aiList_Descratch",
-                leftTitle: "Descratch".localized,
-                leftSubTitle: "Remove scratches and dirt".localized,
-                rightViewStyle: 0,
-                tapBlock: { [weak self] model, _, _ in
-                   guard let self = self else { return }
-                    enterSelectPhotos(style: .descratch) { image in
-                        let baseVc = TSAIUploadPhotoVC(titleString: model.leftTitle ?? "",upLoadImage: image, generatorStyle: .descratch)
-                        kPushVC(target: self, modelVC: baseVc)
-                    }
-        }))
-        
-        //修复和上色老照片
-        sectionModel.addSubItemModel(
-            createItemModel(
-                leftImageName:"aiList_Recreate",
-                leftTitle: "Recreate".localized,
-                leftSubTitle: "Bring new life to old photos".localized,
-                rightViewStyle: 0,
-                tapBlock: { [weak self] model, _, _ in
-                   guard let self = self else { return }
-                    enterSelectPhotos(style: .recreate) { image in
-                    let baseVc = TSAIUploadPhotoVC(titleString: model.leftTitle ?? "",upLoadImage: image, generatorStyle: .recreate)
-                        kPushVC(target: self, modelVC: baseVc)
-                    }
-        }))
-        
-        //调整光线
-        sectionModel.addSubItemModel(
-            createItemModel(
-                leftImageName:"aiList_Enlighten",
-                leftTitle: "Enlighten".localized,
-                leftSubTitle: "Easily fix lighting issues on photos".localized,
-                rightViewStyle: 0,
-                tapBlock: { [weak self] model, _, _ in
-                   guard let self = self else { return }
-                    enterSelectPhotos(style: .enlighten) { image in
-                    let baseVc = TSAIUploadPhotoVC(titleString: model.leftTitle ?? "",upLoadImage: image, generatorStyle: .enlighten)
-                        kPushVC(target: self, modelVC: baseVc)
-                    }
-        }))
-        
-
-
-        return dataArray
-
+    lazy var viewModel: TSAIListVM = {
+        let viewModel = TSAIListVM(target: self)
+        return viewModel
     }()
     
-    var hintBaseVC:TSAIListHintBaseVC = TSAIListHintBaseVC(config: .descratchConfig)
-    //###################################### 导航栏 view ######################################
+    lazy var dataArray: [TSBasicSectionModel] = {
+        return viewModel.dataArray
+    }()
 
-    lazy var recordBtn: UIButton = {
-       let recordBtn = UIButton.createButton(image: UIImage(named: "record")) { [weak self]  in
-           guard let self = self else { return }
-           kPushVC(target: self, modelVC: TSAIListHistoryVC())
-       }
-       return recordBtn
-   }()
-    
+    //###################################### 导航栏 view ######################################
 
     lazy var navBarView: TSBaseNavContentBarView = {
-       let navBarView = TSBaseNavContentBarView()
-       
-       let titleImageView = UIImageView.createImageView(imageName: "nav_title_ailist",contentMode: .scaleToFill)
-       navBarView.barView.addSubview(titleImageView)
-       titleImageView.snp.makeConstraints { make in
-           make.centerY.equalToSuperview()
-           make.left.equalTo(16)
-       }
-       
-       navBarView.barView.addSubview(recordBtn)
-        recordBtn.snp.makeConstraints { make in
-           make.centerY.equalToSuperview()
-           make.trailing.equalTo(-16)
-           make.width.height.equalTo(36)
-       }
-       
+        let navBarView = TSBaseNavContentBarView()
+
+        let label = UILabel.createLabel(text: "Home",font: .font(name: .Pacifico, size: 24))
+        navBarView.barView.addSubview(label)
+        label.snp.makeConstraints { make in
+           make.center.equalToSuperview()
+        }
+        
+        kMainAsync {
+            label.applyGradient(colors: ["#F1D3AB".uiColor,"#E4A858".uiColor])
+        }
+
        return navBarView
-   }()
+    }()
     
     //###################################### 导航栏 ######################################
     lazy var layout: UICollectionViewFlowLayout = {
@@ -155,11 +62,6 @@ class TSAIListVC: TSBaseVC {
         return collectionView
     }()
 
-    lazy var photoPickerManager: TSPhotoPickerManager = {
-        let photoPickerManager = TSPhotoPickerManager(viewController: self)
-        return photoPickerManager
-    }()
-    
     override func createView() {
         
         navBarContentView.addSubview(navBarView)
@@ -186,30 +88,6 @@ class TSAIListVC: TSBaseVC {
     }
 }
 
-
-extension TSAIListVC {
-
-//    @objc func updateVipView() {
-//        kMainAsync {
-//            self.vipBtn.isHidden = PurchaseManager.default.isVip
-//        }
-//    }
-
-    func createItemModel(leftImageName: String,
-                         leftTitle: String,
-                         leftSubTitle: String,
-                        rightViewStyle: Int,
-                        tapBlock: @escaping ((TSBasicItemModel, Int, Any?) -> Void)) -> TSBasicItemModel {
-        let model = TSBasicItemModel()
-        model.leftImageName = leftImageName
-        model.leftTitle = leftTitle
-        model.leftSubTitle = leftSubTitle
-        model.rightViewStyle = rightViewStyle
-        model.tapBlock = tapBlock
-        return model
-    }
-}
-
 extension TSAIListVC: UICollectionViewDataSource ,UICollectionViewDelegate {
     
     public func numberOfSections(in collectionView: UICollectionView) -> Int {
@@ -241,57 +119,3 @@ extension TSAIListVC: UICollectionViewDataSource ,UICollectionViewDelegate {
         }
     }
 }
-
-extension TSAIListVC{
-    
-    func enterSelectPhotos(style:TSGeneratorImageStyle,complete: @escaping (UIImage)->Void){
-        if style.userDefaultsKey.isEmpty{
-            self.pickSinglePhoto(maxBitSize:style.imageMaxBitSize,complete:complete)
-        }else{
-            TSAIListHintBaseVC.userDefaultsKey = style.userDefaultsKey
-            if TSAIListHintBaseVC.isShowUploadImageHint{
-                TSAIListHintBaseVC.isShowUploadImageHint = false
-                self.presentModalHintVC(config:style.config,complete:complete)
-            }else {
-                self.pickSinglePhoto(maxBitSize:style.imageMaxBitSize,complete:complete)
-            }
-        }
-    }
-    
-    
-    func presentModalHintVC(config:TSAIListHintBaseVC.Config,complete:@escaping (UIImage)->Void){
-        hintBaseVC = TSAIListHintBaseVC(config: config) { [weak self] image in
-            guard let self = self else { return }
-            if let image = image {
-                complete(image)
-            }else{
-                dePrint("图片异常")
-            }
-            kDelayMainShort {
-                self.hintBaseVC.dismissPageVC()
-            }
-        }
- 
-        kPresentModalVC(target: self, modelVC: hintBaseVC,transitionStyle: .crossDissolve)
-    }
-    
-    func pickSinglePhoto(maxBitSize:Int,complete: @escaping (UIImage)->Void)  {
-//        photoPickerManager.pickSinglePhoto(maxBitSize: maxBitSize) { [weak self] image, errorString in
-        photoPickerManager.pickCustomSinglePhoto() { [weak self] image, errorString in
-            guard let self = self else { return }
-            if let errorString = errorString {
-                TSToastShared.showToast(text: errorString)
-            }else if let image = image {
-                complete(image)
-            }else{
-                dePrint("图片异常")
-            }
-            kDelayMainShort {
-                self.photoPickerManager.dismissPageVC()
-            }
-            
-        }
-    }
-}
-
-

+ 182 - 0
TSLiveWallpaper/Business/TSAIListVC/TSAIListVC/TSAIListVM.swift

@@ -0,0 +1,182 @@
+//
+//  TSAIListVM.swift
+//  TSLiveWallpaper
+//
+//  Created by 100Years on 2025/6/16.
+//
+
+class TSAIListVM {
+    
+    init(target: UIViewController) {
+        self.target = target
+    }
+    
+    var target:UIViewController
+    var hintBaseVC:TSAIListHintBaseVC = TSAIListHintBaseVC(config: .descratchConfig)
+    
+    lazy var photoPickerManager: TSPhotoPickerManager = {
+        let photoPickerManager = TSPhotoPickerManager(viewController: self.target)
+        return photoPickerManager
+    }()
+
+    lazy var dataArray: [TSBasicSectionModel] = {
+        var dataArray = [TSBasicSectionModel]()
+        let sectionModel = TSBasicSectionModel()
+        dataArray.append(sectionModel)
+        
+
+        
+        //照片高清修复
+        sectionModel.addSubItemModel(
+            createItemModel(
+                leftImageName:"aiList_Enhance",
+                leftTitle: "Enhance".localized,
+                leftSubTitle: "Remove blur, sharpen, add details".localized,
+                rightViewStyle: 0,
+                tapBlock: { [weak self] model, _, _ in
+                   guard let self = self else { return }
+                    enterSelectPhotos(style: .enhance) { image in
+                    let baseVc = TSAIUploadPhotoVC(titleString: model.leftTitle ?? "",upLoadImage: image, generatorStyle: .enhance)
+                        kPushVC(target: self.target, modelVC: baseVc)
+                    }
+        }))
+        
+        //黑白照片变颜色
+        sectionModel.addSubItemModel(
+            createItemModel(
+                leftImageName:"aiList_Colorize",
+                leftTitle: "Colorize".localized,
+                leftSubTitle: "Add colors to black-and-white photos".localized,
+                rightViewStyle: 0,
+                tapBlock: { [weak self] model, _, _ in
+                   guard let self = self else { return }
+                    enterSelectPhotos(style: .colorize) { image in
+                    let baseVc = TSAIUploadPhotoVC(titleString: model.leftTitle ?? "",upLoadImage: image, generatorStyle: .colorize)
+                        kPushVC(target: self.target, modelVC: baseVc)
+                    }
+        }))
+        
+        //老照片修复
+        sectionModel.addSubItemModel(
+            createItemModel(
+                leftImageName:"aiList_Descratch",
+                leftTitle: "Descratch".localized,
+                leftSubTitle: "Remove scratches and dirt".localized,
+                rightViewStyle: 0,
+                tapBlock: { [weak self] model, _, _ in
+                   guard let self = self else { return }
+                    enterSelectPhotos(style: .descratch) { image in
+                        let baseVc = TSAIUploadPhotoVC(titleString: model.leftTitle ?? "",upLoadImage: image, generatorStyle: .descratch)
+                        kPushVC(target: self.target, modelVC: baseVc)
+                    }
+        }))
+        
+        //修复和上色老照片
+        sectionModel.addSubItemModel(
+            createItemModel(
+                leftImageName:"aiList_Recreate",
+                leftTitle: "Recreate".localized,
+                leftSubTitle: "Bring new life to old photos".localized,
+                rightViewStyle: 0,
+                tapBlock: { [weak self] model, _, _ in
+                   guard let self = self else { return }
+                    enterSelectPhotos(style: .recreate) { image in
+                    let baseVc = TSAIUploadPhotoVC(titleString: model.leftTitle ?? "",upLoadImage: image, generatorStyle: .recreate)
+                        kPushVC(target: self.target, modelVC: baseVc)
+                    }
+        }))
+        
+        //调整光线
+        sectionModel.addSubItemModel(
+            createItemModel(
+                leftImageName:"aiList_Enlighten",
+                leftTitle: "Enlighten".localized,
+                leftSubTitle: "Easily fix lighting issues on photos".localized,
+                rightViewStyle: 0,
+                tapBlock: { [weak self] model, _, _ in
+                   guard let self = self else { return }
+                    enterSelectPhotos(style: .enlighten) { image in
+                    let baseVc = TSAIUploadPhotoVC(titleString: model.leftTitle ?? "",upLoadImage: image, generatorStyle: .enlighten)
+                        kPushVC(target: self.target, modelVC: baseVc)
+                    }
+        }))
+        
+
+
+        return dataArray
+
+    }()
+    
+    
+}
+
+extension TSAIListVM {
+
+    func createItemModel(leftImageName: String,
+                         leftTitle: String,
+                         leftSubTitle: String,
+                        rightViewStyle: Int,
+                        tapBlock: @escaping ((TSBasicItemModel, Int, Any?) -> Void)) -> TSBasicItemModel {
+        let model = TSBasicItemModel()
+        model.leftImageName = leftImageName
+        model.leftTitle = leftTitle
+        model.leftSubTitle = leftSubTitle
+        model.rightViewStyle = rightViewStyle
+        model.tapBlock = tapBlock
+        return model
+    }
+}
+
+extension TSAIListVM{
+    
+    func enterSelectPhotos(style:TSGeneratorImageStyle,complete: @escaping (UIImage)->Void){
+        if style.userDefaultsKey.isEmpty{
+            self.pickSinglePhoto(maxBitSize:style.imageMaxBitSize,complete:complete)
+        }else{
+            TSAIListHintBaseVC.userDefaultsKey = style.userDefaultsKey
+            if TSAIListHintBaseVC.isShowUploadImageHint{
+                TSAIListHintBaseVC.isShowUploadImageHint = false
+                self.presentModalHintVC(config:style.config,complete:complete)
+            }else {
+                self.pickSinglePhoto(maxBitSize:style.imageMaxBitSize,complete:complete)
+            }
+        }
+    }
+    
+    
+    func presentModalHintVC(config:TSAIListHintBaseVC.Config,complete:@escaping (UIImage)->Void){
+        hintBaseVC = TSAIListHintBaseVC(config: config) { [weak self] image in
+            guard let self = self else { return }
+            if let image = image {
+                complete(image)
+            }else{
+                dePrint("图片异常")
+            }
+            kDelayMainShort {
+                self.hintBaseVC.dismissPageVC()
+            }
+        }
+ 
+        kPresentModalVC(target: self.target, modelVC: hintBaseVC,transitionStyle: .crossDissolve)
+    }
+    
+    func pickSinglePhoto(maxBitSize:Int,complete: @escaping (UIImage)->Void)  {
+//        photoPickerManager.pickSinglePhoto(maxBitSize: maxBitSize) { [weak self] image, errorString in
+        photoPickerManager.pickCustomSinglePhoto() { [weak self] image, errorString in
+            guard let self = self else { return }
+            if let errorString = errorString {
+                TSToastShared.showToast(text: errorString)
+            }else if let image = image {
+                complete(image)
+            }else{
+                dePrint("图片异常")
+            }
+            kDelayMainShort {
+                self.photoPickerManager.dismissPageVC()
+            }
+            
+        }
+    }
+}
+
+

+ 5 - 137
TSLiveWallpaper/Business/TSMineVC/TSMineVC.swift

@@ -7,6 +7,10 @@
 let appid = "6447607955"
 class TSMineVC: TSBaseVC {
     
+    lazy var viewModel: TSMineVM = {
+        let viewModel = TSMineVM(target: self)
+        return viewModel
+    }()
     lazy var headerView: TSMineTopView = {
         let headerView = TSMineTopView()
         headerView.frame = CGRect(x: 0, y: 0, width: k_ScreenWidth - 32, height: 134)
@@ -22,123 +26,11 @@ class TSMineVC: TSBaseVC {
     lazy var simpleTableView: TSSimpleTableView = {
         let simpleTableView = TSSimpleTableView()
         simpleTableView.reuseClass = ["TSMineCell"]
-        simpleTableView.dataArray = dataArray
+        simpleTableView.dataArray = viewModel.dataArray
         simpleTableView.tableView.tableHeaderView = headerView
         return simpleTableView
     }()
 
-    lazy var dataArray: [TSBasicSectionModel] = {
-        var dataArray = [TSBasicSectionModel]()
-        let sectionModel = TSBasicSectionModel()
-        dataArray.append(sectionModel)
-
-//        sectionModel.addSubItemModel(
-//            createItemModel(
-//                leftImage: .mineCellShare,
-//                leftTitle: "Update".localized,
-//                rightViewStyle: 0,
-//                rightString: "",
-//                rightIsHave: true,
-//                height: 80,
-//                rectCorner: .allCorners,
-//                tapBlock: { [weak self] _, _, _ in
-//                    let httpAppStoreLink = "https://apps.apple.com/app/id\(appid)"
-//                    guard let appStoreURL = URL(string: httpAppStoreLink) else { return }
-//
-//                    if UIApplication.shared.canOpenURL(appStoreURL) {
-//                        UIApplication.shared.open(appStoreURL, options: [:], completionHandler: nil)
-//                    }
-//                }))
-
-        sectionModel.addSubItemModel(
-            createItemModel(
-                leftImage: .mineCellShare,
-                leftTitle: "Share us".localized,
-                tapBlock: { [weak self] _, _, _ in
-                    guard let self = self else { return }
-
-                    let httpAppStoreLink = "https://apps.apple.com/app/id\(appid)"
-                    let text = ""
-                    let url = URL(string: httpAppStoreLink)!
-                    let image = UIImage(named: "App-Icon")!
-                    let vc = UIActivityViewController(activityItems: [image, text, url], applicationActivities: nil)
-                    vc.completionWithItemsHandler = { activity, _, _, _ in
-                        if let type = activity, type == .copyToPasteboard {
-                            UIPasteboard.general.string = httpAppStoreLink
-                        }
-                    }
-
-                    if UIDevice.isPad {
-                        if let popover = vc.popoverPresentationController {
-                            popover.sourceView = self.view // 设置锚点视图
-                            popover.sourceRect = CGRect(x: self.view.bounds.midX, y: self.view.bounds.midY, width: 0, height: 0) // 设置弹窗位置为屏幕中心
-                            popover.permittedArrowDirections = [] // 禁止箭头指向
-                        }
-                    }
-
-                    self.present(vc, animated: true)
-
-                }))
-        
-        
-        sectionModel.addSubItemModel(
-            createItemModel(
-                leftImage: .mineCellRateUs,
-                leftTitle: "Rate us".localized,
-                tapBlock: { [weak self] _, _, _ in
-
-                    guard let self = self else { return }
-                    let appStoreLink = "itms-apps://itunes.apple.com/app/id\(appid)"
-                    if let url = URL(string: appStoreLink + "?action=write-review"),
-                       UIApplication.shared.canOpenURL(url) {
-                        UIApplication.shared.open(url)
-                    }
-                }))
-        
-        sectionModel.addSubItemModel(
-            createItemModel(
-                leftImage: .mineCellUseragree,
-                leftTitle: "User Agreement".localized,
-                tapBlock: { [weak self] _, _, _ in
-                    guard let self = self else { return }
-                    let vc = TSBusinessWebVC(urlType: .terms)
-                    vc.hidesBottomBarWhenPushed = true
-                    navigationController?.pushViewController(vc, animated: true)
-                }))
-        
-        sectionModel.addSubItemModel(
-            createItemModel(
-                leftImage: .mineCellPrivacy,
-                leftTitle: "Privacy Policy".localized,
-                tapBlock: { [weak self] _, _, _ in
-                    guard let self = self else { return }
-                    let vc = TSBusinessWebVC(urlType: .privacy)
-                    vc.hidesBottomBarWhenPushed = true
-                    navigationController?.pushViewController(vc, animated: true)
-                }))
-
-
-
-        sectionModel.addSubItemModel(
-            createItemModel(
-                leftImage: .mineCellAbout,
-                leftTitle: "About us".localized,
-                rightString: appVersion(),
-                rightIsHave: false,
-                tapBlock: { [weak self] _, _, _ in
-                    guard let self = self else { return }
-                    #if DEBUG
-                        let vc = TSPurchaseVC()
-                        vc.hidesBottomBarWhenPushed = true
-                        kPresentModalVC(target: self, modelVC: vc)
-                    #endif
-
-                }))
-
-        return dataArray
-
-    }()
-
     override func createView() {
         setNavBarViewHidden(true)
         contentView.addSubview(simpleTableView.tableView)
@@ -163,27 +55,3 @@ class TSMineVC: TSBaseVC {
         }
     }
 }
-
-
-extension TSMineVC {
-    func createItemModel(
-        leftImage:UIImage,
-        leftTitle: String,
-        rightViewStyle: Int = 0,
-        rightString: String = "",
-        rightIsHave: Bool = true,
-        height: CGFloat = 64,
-        tapBlock: @escaping ((TSBasicItemModel, Int, Any?) -> Void))
-    -> TSBasicItemModel
-    {
-        let model = TSBasicItemModel()
-        model.leftImage = leftImage
-        model.leftTitle = leftTitle
-        model.rightViewStyle = rightViewStyle
-        model.rightString = rightString
-        model.rightIsHave = rightIsHave
-        model.height = height
-        model.tapBlock = tapBlock
-        return model
-    }
-}

+ 151 - 0
TSLiveWallpaper/Business/TSMineVC/TSMineVM.swift

@@ -0,0 +1,151 @@
+//
+//  Untitled.swift
+//  TSLiveWallpaper
+//
+//  Created by 100Years on 2025/6/16.
+//
+
+class TSMineVM {
+    
+    var target:UIViewController
+    init(target: UIViewController) {
+        self.target = target
+    }
+    
+    
+    lazy var dataArray: [TSBasicSectionModel] = {
+        var dataArray = [TSBasicSectionModel]()
+        let sectionModel = TSBasicSectionModel()
+        dataArray.append(sectionModel)
+
+//        sectionModel.addSubItemModel(
+//            createItemModel(
+//                leftImage: .mineCellShare,
+//                leftTitle: "Update".localized,
+//                rightViewStyle: 0,
+//                rightString: "",
+//                rightIsHave: true,
+//                height: 80,
+//                rectCorner: .allCorners,
+//                tapBlock: { [weak self] _, _, _ in
+//                    let httpAppStoreLink = "https://apps.apple.com/app/id\(appid)"
+//                    guard let appStoreURL = URL(string: httpAppStoreLink) else { return }
+//
+//                    if UIApplication.shared.canOpenURL(appStoreURL) {
+//                        UIApplication.shared.open(appStoreURL, options: [:], completionHandler: nil)
+//                    }
+//                }))
+
+        sectionModel.addSubItemModel(
+            createItemModel(
+                leftImage: .mineCellShare,
+                leftTitle: "Share us".localized,
+                tapBlock: { [weak self] _, _, _ in
+                    guard let self = self else { return }
+
+                    let httpAppStoreLink = "https://apps.apple.com/app/id\(appid)"
+                    let text = ""
+                    let url = URL(string: httpAppStoreLink)!
+                    let image = UIImage(named: "App-Icon")!
+                    let vc = UIActivityViewController(activityItems: [image, text, url], applicationActivities: nil)
+                    vc.completionWithItemsHandler = { activity, _, _, _ in
+                        if let type = activity, type == .copyToPasteboard {
+                            UIPasteboard.general.string = httpAppStoreLink
+                        }
+                    }
+
+                    if UIDevice.isPad {
+                        if let popover = vc.popoverPresentationController {
+                            popover.sourceView = self.target.view // 设置锚点视图
+                            popover.sourceRect = CGRect(x: self.target.view.bounds.midX, y: self.target.view.bounds.midY, width: 0, height: 0) // 设置弹窗位置为屏幕中心
+                            popover.permittedArrowDirections = [] // 禁止箭头指向
+                        }
+                    }
+
+                    self.target.present(vc, animated: true)
+
+                }))
+        
+        
+        sectionModel.addSubItemModel(
+            createItemModel(
+                leftImage: .mineCellRateUs,
+                leftTitle: "Rate us".localized,
+                tapBlock: { [weak self] _, _, _ in
+
+                    guard let self = self else { return }
+                    let appStoreLink = "itms-apps://itunes.apple.com/app/id\(appid)"
+                    if let url = URL(string: appStoreLink + "?action=write-review"),
+                       UIApplication.shared.canOpenURL(url) {
+                        UIApplication.shared.open(url)
+                    }
+                }))
+        
+        sectionModel.addSubItemModel(
+            createItemModel(
+                leftImage: .mineCellUseragree,
+                leftTitle: "User Agreement".localized,
+                tapBlock: { [weak self] _, _, _ in
+                    guard let self = self else { return }
+                    let vc = TSBusinessWebVC(urlType: .terms)
+                    vc.hidesBottomBarWhenPushed = true
+                    self.target.navigationController?.pushViewController(vc, animated: true)
+                }))
+        
+        sectionModel.addSubItemModel(
+            createItemModel(
+                leftImage: .mineCellPrivacy,
+                leftTitle: "Privacy Policy".localized,
+                tapBlock: { [weak self] _, _, _ in
+                    guard let self = self else { return }
+                    let vc = TSBusinessWebVC(urlType: .privacy)
+                    vc.hidesBottomBarWhenPushed = true
+                    self.target.navigationController?.pushViewController(vc, animated: true)
+                }))
+
+
+
+        sectionModel.addSubItemModel(
+            createItemModel(
+                leftImage: .mineCellAbout,
+                leftTitle: "About us".localized,
+                rightString: appVersion(),
+                rightIsHave: false,
+                tapBlock: { [weak self] _, _, _ in
+                    guard let self = self else { return }
+                    #if DEBUG
+                        let vc = TSPurchaseVC()
+                        vc.hidesBottomBarWhenPushed = true
+                    kPresentModalVC(target: self.target, modelVC: vc)
+                    #endif
+
+                }))
+
+        return dataArray
+
+    }()
+}
+
+
+extension TSMineVM {
+    func createItemModel(
+        leftImage:UIImage,
+        leftTitle: String,
+        rightViewStyle: Int = 0,
+        rightString: String = "",
+        rightIsHave: Bool = true,
+        height: CGFloat = 64,
+        tapBlock: @escaping ((TSBasicItemModel, Int, Any?) -> Void))
+    -> TSBasicItemModel
+    {
+        let model = TSBasicItemModel()
+        model.leftImage = leftImage
+        model.leftTitle = leftTitle
+        model.rightViewStyle = rightViewStyle
+        model.rightString = rightString
+        model.rightIsHave = rightIsHave
+        model.height = height
+        model.tapBlock = tapBlock
+        return model
+    }
+}

+ 4 - 4
TSLiveWallpaper/Business/TSPurchaseMembershipVC/TSPurchaseVC.swift

@@ -286,8 +286,8 @@ struct PurchaseView :View {
                             .offset(x:-30,y:-14)
                     }
                     
-                PurchaseItemView(title: "MONTH".localized, type: .month, selectedType: $viewModel.selectedType).onTapGesture {
-                        viewModel.selectedType = .month
+                PurchaseItemView(title: "WEEKLY".localized, type: .week, selectedType: $viewModel.selectedType).onTapGesture {
+                    viewModel.selectedType = .week
                         viewModel.buyPublisher.send(true)
                     }
                     
@@ -406,8 +406,8 @@ struct PurchaseItemView: View {
         switch type {
         case .year:
             return "Per Year".localized
-        case .month:
-            return "Per Month".localized
+        case .week:
+            return "Per Week".localized
         default:
             return ""
         }

+ 24 - 19
TSLiveWallpaper/Business/TSTabBarController/TSTabBarController.swift

@@ -13,24 +13,26 @@ class TSTabBarController: UITabBarController {
     private var titleArray: [String] = []
     private var selectedImageArray: [String] = []
     private var unselectedImageArray: [String] = []
-    private let markWidth = k_ScreenWidth / 2
+    private var markWidth = k_ScreenWidth / 2
     private lazy var markView: UIView = {
         let bgView = UIView()
-        let imageView = UIImageView.createImageView(imageName: "tabbar_select_mark")
-        bgView.addSubview(imageView)
-        imageView.snp.makeConstraints { make in
-            make.top.centerX.equalToSuperview()
-            make.width.equalTo(24)
-            make.height.equalTo(8)
+        let colorView = UIView()
+        colorView.backgroundColor = .themeColor
+        bgView.addSubview(colorView)
+        colorView.snp.makeConstraints { make in
+            make.center.equalToSuperview()
+            make.width.equalTo(15)
+            make.height.equalTo(2)
         }
         return bgView
     }()
 
     override func viewDidLoad() {
         super.viewDidLoad()
-//        delegate = self
-        createUI()
+        delegate = self
         setUpData()
+        createUI()
+      
     }
 
     @objc private func setUpData() {
@@ -41,13 +43,13 @@ class TSTabBarController: UITabBarController {
         
         selectedImageArray = [
             "tabbar_select_ailist",
-            "tabbar_select_ailist",
-            "tabbar_select_mine",
+            "tabbar_select_history",
+            "tabbar_select_setting",
         ]
         unselectedImageArray = [
             "tabbar_unSelect_allist",
-            "tabbar_unSelect_allist",
-            "tabbar_unSelect_mine",
+            "tabbar_unSelect_history",
+            "tabbar_unSelect_setting",
         ]
 
         var tabArray: [UINavigationController] = []
@@ -67,6 +69,7 @@ class TSTabBarController: UITabBarController {
         }
 
         viewControllers = tabArray
+        markWidth = k_ScreenWidth / CGFloat(tabArray.count)
     }
 
     private func createUI() {
@@ -85,10 +88,10 @@ class TSTabBarController: UITabBarController {
 
         tabBar.addSubview(markView)
         markView.snp.makeConstraints { make in
-            make.top.equalTo(0)
+            make.bottom.equalTo(-k_Height_safeAreaInsetsBottom())
             make.left.equalTo(0)
             make.width.equalTo(markWidth)
-            make.height.equalTo(8)
+            make.height.equalTo(2)
         }
     }
 
@@ -120,10 +123,12 @@ class TSTabBarController: UITabBarController {
 
 }
 
-//extension TSTabBarController: UITabBarControllerDelegate {
-//    func tabBarController(_ tabBarController: UITabBarController, didSelect viewController: UIViewController) {
-//    }
-//}
+extension TSTabBarController: UITabBarControllerDelegate {
+    func tabBarController(_ tabBarController: UITabBarController, didSelect viewController: UIViewController) {
+        updateMarkViewFrame()
+    }
+}
+
 
 // MARK: 进到首页后需要做的处理
 

+ 1 - 0
TSLiveWallpaper/Common/Ex/UIFont+Ex.swift

@@ -8,4 +8,5 @@
 public extension FontName {
     static let ZillaSlab   = "Zilla Slab"
     static let ZillaSlabBoldItalic  = "ZillaSlab-BoldItalic"
+    static let Pacifico  = "Pacifico"
 }

+ 3 - 2
TSLiveWallpaper/Common/Purchase/TSPurchaseBusiness.swift

@@ -119,9 +119,10 @@ extension TSPurchaseBusiness{
     func launchPrchase() {
         PurchaseManager.default.password = "155c8104e2b041c0abae43ace199124c"
         PurchaseManager.default.purchaseProducts = [
-            PurchaseProduct(productId: "1001", period:.month),
+            PurchaseProduct(productId: "1006", period:.week),
+//            PurchaseProduct(productId: "1001", period:.month),
             PurchaseProduct(productId: "1002", period:.year),
-            PurchaseProduct(productId: "003", period:.lifetime)
+//            PurchaseProduct(productId: "003", period:.lifetime)
         ]
         
         PurchaseManager.default.requestProducts()

+ 1 - 0
TSLiveWallpaper/Info.plist

@@ -17,6 +17,7 @@
 		<string>ZillaSlab-BoldItalic.ttf</string>
 		<string>ZillaSlab-Medium.ttf</string>
 		<string>ZillaSlab-Regular.ttf</string>
+		<string>Pacifico-Regular.ttf</string>
 	</array>
 	<key>UIBackgroundModes</key>
 	<array>

BIN
TSLiveWallpaper/Resource/Font/Pacifico-Regular.ttf