Skip to content

Commit

Permalink
🎨
Browse files Browse the repository at this point in the history
  • Loading branch information
lijingcheng committed Dec 16, 2016
1 parent 9fbbe69 commit d6894e0
Show file tree
Hide file tree
Showing 47 changed files with 841 additions and 1,156 deletions.
136 changes: 89 additions & 47 deletions Example/JCTagListView.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0700"
LastUpgradeVersion = "0820"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
Expand Down
3 changes: 1 addition & 2 deletions Example/JCTagListView/JCAppDelegate.m
Expand Up @@ -10,8 +10,7 @@

@implementation JCAppDelegate

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
return YES;
}

Expand Down
3 changes: 1 addition & 2 deletions Example/JCTagListView/JCTableViewCell.m
Expand Up @@ -16,8 +16,7 @@ @interface JCTableViewCell ()

@implementation JCTableViewCell

- (void)setTags:(NSArray *)tags
{
- (void)setTags:(NSArray *)tags {
_tags = tags;

self.tagListView.tags = [NSMutableArray arrayWithArray:tags];
Expand Down
3 changes: 1 addition & 2 deletions Example/JCTagListView/JCTableViewController.m
Expand Up @@ -42,8 +42,7 @@ - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger
return self.allTags.count;
}

- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath
{
- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath {
return [self.cellHeights[indexPath.row] floatValue];
}

Expand Down
15 changes: 7 additions & 8 deletions Example/JCTagListView/JCViewController.m
Expand Up @@ -18,8 +18,7 @@ @interface JCViewController ()

@implementation JCViewController

- (void)viewDidLoad
{
- (void)viewDidLoad {
[super viewDidLoad];

self.tagListView.canSelectTags = YES;
Expand All @@ -40,17 +39,17 @@ - (void)viewDidLoad

#pragma mark - IBAction

- (IBAction)delete:(id)sender
{
- (IBAction)delete:(id)sender {
[self.tagListView.tags removeObjectsInArray:self.tagListView.selectedTags];
[self.tagListView.selectedTags removeAllObjects];

[self.tagListView.collectionView reloadData];
}

- (IBAction)openTableViewController:(id)sender {
JCTableViewController *tableVC = [self.storyboard instantiateViewControllerWithIdentifier:@"JCTableViewController"];

// tags in cell
// JCTableViewController *tableVC = [self.storyboard instantiateViewControllerWithIdentifier:@"JCTableViewController"];
//
// [self.navigationController pushViewController:tableVC animated:YES];
[self.navigationController pushViewController:tableVC animated:YES];
}

@end
37 changes: 24 additions & 13 deletions Example/JCTagListView/Main.storyboard
@@ -1,8 +1,11 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="10117" systemVersion="15F34" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" initialViewController="tXg-JF-3Hi">
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="11762" systemVersion="16B2555" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES" initialViewController="tXg-JF-3Hi">
<device id="retina4_7" orientation="portrait">
<adaptation id="fullscreen"/>
</device>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="10085"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="11757"/>
</dependencies>
<scenes>
<!--Navigation Controller-->
Expand Down Expand Up @@ -30,15 +33,15 @@
<viewControllerLayoutGuide type="bottom" id="Mvr-aV-6Um"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="TpU-gO-2f1">
<rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="UNz-gg-734" customClass="JCTagListView">
<rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</view>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstItem="Mvr-aV-6Um" firstAttribute="top" secondItem="UNz-gg-734" secondAttribute="bottom" id="KeM-3L-LHZ"/>
<constraint firstAttribute="trailing" secondItem="UNz-gg-734" secondAttribute="trailing" id="cic-xm-XXX"/>
Expand All @@ -47,6 +50,11 @@
</constraints>
</view>
<navigationItem key="navigationItem" title="JCTagListView" id="cMv-9O-1me">
<barButtonItem key="leftBarButtonItem" title="cell" id="D0C-wD-RMT">
<connections>
<action selector="openTableViewController:" destination="whP-gf-Uak" id="OQC-q1-Fjw"/>
</connections>
</barButtonItem>
<barButtonItem key="rightBarButtonItem" image="delete" id="GSW-Id-tuZ">
<connections>
<action selector="delete:" destination="whP-gf-Uak" id="izx-oK-L7N"/>
Expand All @@ -66,20 +74,22 @@
<objects>
<tableViewController storyboardIdentifier="JCTableViewController" id="U23-N7-vNa" customClass="JCTableViewController" sceneMemberID="viewController">
<tableView key="view" clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="prototypes" style="plain" separatorStyle="default" rowHeight="44" sectionHeaderHeight="28" sectionFooterHeight="28" id="LZ2-Cs-KP5">
<rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<color key="separatorColor" red="0.39607843139999999" green="0.61568627450000002" blue="0.054901960780000002" alpha="1" colorSpace="calibratedRGB"/>
<inset key="separatorInset" minX="0.0" minY="0.0" maxX="0.0" maxY="0.0"/>
<prototypes>
<tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" reuseIdentifier="cellId" id="hch-gG-zQZ" customClass="JCTableViewCell">
<rect key="frame" x="0.0" y="28" width="600" height="44"/>
<rect key="frame" x="0.0" y="28" width="375" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="hch-gG-zQZ" id="Ycz-5p-rBR">
<rect key="frame" x="0.0" y="0.0" width="600" height="43.5"/>
<rect key="frame" x="0.0" y="0.0" width="375" height="43.5"/>
<autoresizingMask key="autoresizingMask"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="Fwo-Ua-FJX" customClass="JCTagListView">
<rect key="frame" x="0.0" y="0.0" width="600" height="43"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<rect key="frame" x="0.0" y="0.0" width="375" height="43"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</view>
</subviews>
<constraints>
Expand All @@ -89,6 +99,7 @@
<constraint firstItem="Fwo-Ua-FJX" firstAttribute="top" secondItem="Ycz-5p-rBR" secondAttribute="top" id="k8M-ew-oGw"/>
</constraints>
</tableViewCellContentView>
<inset key="separatorInset" minX="0.0" minY="0.0" maxX="0.0" maxY="0.0"/>
<connections>
<outlet property="tagListView" destination="Fwo-Ua-FJX" id="2Ih-pM-2pJ"/>
</connections>
Expand Down
8 changes: 4 additions & 4 deletions Example/Podfile
@@ -1,11 +1,11 @@
source 'https://github.com/CocoaPods/Specs.git'

target 'JCTagListView_Example', :exclusive => true do
platform :ios, "8.0"

target 'JCTagListView_Example' do
pod "JCTagListView", :path => "../"
end

target 'JCTagListView_Tests', :exclusive => true do
target 'JCTagListView_Tests' do
pod "JCTagListView", :path => "../"


end
8 changes: 5 additions & 3 deletions Example/Podfile.lock
@@ -1,5 +1,5 @@
PODS:
- JCTagListView (0.0.1)
- JCTagListView (1.0.0)

DEPENDENCIES:
- JCTagListView (from `../`)
Expand All @@ -9,6 +9,8 @@ EXTERNAL SOURCES:
:path: ../

SPEC CHECKSUMS:
JCTagListView: 7010fc92bbb11ddde8464430148992ee9efaccca
JCTagListView: 3426fb0f79835cac498039dd146e21320251cd1e

COCOAPODS: 0.37.2
PODFILE CHECKSUM: 44df7712bb660b5cd8c1c71dd62d04978fdbf834

COCOAPODS: 1.2.0.beta.1
15 changes: 5 additions & 10 deletions Example/Pods/Local Podspecs/JCTagListView.podspec.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 5 additions & 3 deletions Example/Pods/Manifest.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit d6894e0

Please sign in to comment.