A table view for common use, have fun.
- Add
pod 'MCCommonTableView', '~> 0.0.1'
to your Podfile. - Run
pod install
orpod update
. - Import <MCCommonTableView.h>.
- Add
github "chucklab/MCCommonTableView"
to your Cartfile. - Run
carthage update --platform ios
and add the framework to your project. - Import <MCCommonTableView/MCCommonTableView.h>.
// Example
MCCommonTableView *tableView = [MCCommonTableView tableViewWithFrame:self.view.bounds];
[self.view addSubview:tableView];
tableView.dataMap = @{
@"Day One" : @{
@"1. Normal" : ^(){ NSLog(@"Normal, tapped."); },
@"2. Multi lines" : ^(){ NSLog(@"Multi, tapped."); },
@"3. Long single line" : ^(){ NSLog(@"Long, tapped."); },
@"4. Very long text" : ^(){ NSLog(@"Very, tapped."); },
@"5. No message" : ^(){ NSLog(@"No, tapped."); }
},
@"Day two" : @{
@"1. Normal" : ^(){ NSLog(@"Normal, tapped."); },
@"2. Multi lines" : ^(){ NSLog(@"Multi, tapped."); },
@"3. Long single line" : ^(){ NSLog(@"Long, tapped."); },
@"4. Very long text" : ^(){ NSLog(@"Very, tapped."); },
@"5. No message" : ^(){ NSLog(@"No, tapped."); }
}
};
This library requires a deployment target of iOS 6.0 or greater.
MCCommonTableView is provided under the MIT license. See LICENSE file for details.