This commit is contained in:
2025-12-04 13:37:11 +08:00
parent f770f8055e
commit b216ddaa61
11 changed files with 377 additions and 10 deletions

View File

@@ -10,6 +10,7 @@
#import "UICollectionViewLeftAlignedLayout.h"
#import "KBMyKeyboardCell.h"
#import "KBAlert.h"
#import "KBMyVM.h"
///
static NSString * const kKBMyKeyboardCellId = @"kKBMyKeyboardCellId";
@@ -29,6 +30,7 @@ static NSString * const kKBMyKeyboardCellId = @"kKBMyKeyboardCellId";
//
@property (nonatomic, strong) NSMutableArray<NSMutableArray<NSDictionary *> *> *dataSourceArray; // {emoji,title}
@property (nonatomic, strong) KBMyVM *viewModel; // VM
@end
@@ -40,6 +42,7 @@ static NSString * const kKBMyKeyboardCellId = @"kKBMyKeyboardCellId";
- (void)viewDidLoad {
[super viewDidLoad];
self.viewModel = [[KBMyVM alloc] init];
self.view.backgroundColor = [UIColor colorWithHex:0xF6F8F9];
self.kb_navView.backgroundColor = [UIColor clearColor];
self.kb_titleLabel.text = @"My KeyBoard";
@@ -71,7 +74,11 @@ static NSString * const kKBMyKeyboardCellId = @"kKBMyKeyboardCellId";
}];
//
[self buildDefaultData];
// [self buildDefaultData];
__weak typeof(self) weakSelf = self;
[self.viewModel fetchCharacterListByUserWithCompletion:^(NSArray<KBCharacter *> * _Nonnull characterArray, NSError * _Nullable error) {
}];
}
- (void)viewWillAppear:(BOOL)animated {