Skip to content
프로젝트

ChenYilong/CollectionViewClassifyMenu

GitHub에서 보기

ChenYilong/CollectionViewClassifyMenu has 1,530 GitHub stars and 358 forks. GitHot measured 0 stars in 24 hours, -1 in 7 days, and -1 in 15 days. Last checked 2026-11-21 09:42 UTC. Last push 2026-11-19.

이 수치를 측정하는 방법

측정된 스타 증가

in 24h
0
in 7 days
-1
in 15 days
-1
in 1 month
기록 수집 중

서로 겹치는 기간의 순증가량이며 일별 합계가 아닙니다. 측정값이 없으면 비워 둡니다. 스타는 관심도를 나타내며 품질을 보장하지 않습니다.

소개

CollectionView做的两级菜单,可以折叠第二级菜单

개발 도구

README.md

Original

CollectionViewClassifyMenu

功能展示

Example screenshot

单选可折叠菜单的特性展示

Example screenshot

Check out my weibo for more info.

然并卵? 请看以下应用场景:

场景一:《手机淘宝App》

筛选条件,如果数目过多,可以折叠,:比如《手机淘宝App》中商品的评价筛选

enter image description here

场景二:《脉脉App》

分类菜单:比如《脉脉App》中的搜索分类筛选

enter image description here

Demo中具有两种样式

第一种是CollectionView做的两级菜单,可以折叠第二级菜单

第二种是侧边栏菜单,具有多选功能,并可将数据持久化,在下次打开app后,保留用户的筛选条件.默认保存.

数据持久化使用NSCoding,若要关闭该项功能,可在AppDelegate里清除固化数据,

清除方法已经在工程中写出:

- (void)initFilterSetting:(BOOL)restore
{
    if (!restore) {
        CYLFilterParamsTool *filterParamsTool = [[CYLFilterParamsTool alloc] init];
        [NSKeyedArchiver archiveRootObject:filterParamsTool toFile:filterParamsTool.filename];
    }
}

用法如下

YES为保存,NO为不保存.

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
    //...
    //设NO表示,每次启动程序,清除用户上次的筛选条件,不写该行,默认保存.
    [self initFilterSetting:NO];
    return YES;
}

Check out my twitter for more info.

관련 프로젝트 살펴보기

불러오는 중…