Giter Club home page Giter Club logo

donggelaile / hdcollectionview Goto Github PK

View Code? Open in Web Editor NEW
421.0 421.0 79.0 1.71 MB

An efficient and flexible listView (data driven). Based on Flexbox, it supports floating, waterfall, decorative view, horizontal sliding, segmented layout, and various alignments. Support diff refresh, animation update UI / 数据驱动(data driven)的高效灵活列表。基于Flexbox,支持 悬浮、瀑布流、装饰view、横向滑动、分段布局、各种对齐方式。支持链式语法初始化。支持diff刷新,渐进式加载,动画更新UI

License: MIT License

Objective-C 98.78% Ruby 0.62% C 0.60%

hdcollectionview's People

Contributors

donggelaile avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

hdcollectionview's Issues

依赖的Yoga报错

Xcode 14.3运行项目,依赖的Yoga报错,建议升级下Yoga的版本

tableCell 嵌套瀑布流时,在赋值的过程中出现了问题,必须多次调用后才会显示内容

var cellData:Any?{
didSet{

        guard let cellData = cellData as? ZZZ_HomeNoisePresetList else { return  }
        titlab.text = cellData.preset_cate_name
        //该段layout
        let layout = HDWaterFlowLayout()
        layout.secInset      = UIEdgeInsets(top: 0, left: 20, bottom: 0, right: 0)
        layout.verticalGap   = 16;
        layout.horizontalGap = 16;
        layout.headerSize    = .zero;
        layout.footerSize    = .zero;
        layout.columnRatioArr =  [NSNumber(integerLiteral: 1),NSNumber(integerLiteral: 1)]
        layout.decorationMargin = UIEdgeInsets(top: 0, left: 0, bottom: 0, right: 0)
        let hdCellModels = cellData.noise_data.map { list in
            let model = HDCellModel()
            model.orgData = list
            model.cellClassStr = "ZZZ_HomeDoubleCollectionCell"
            model.cellSize = CGSize(width: WIDTH * 0.62, height: 82)
            return model
        }
        //该段的所有数据封装
        let secModel = HDSectionModel();
        secModel.sectionDataArr        = NSMutableArray(array: hdCellModels)
        secModel.layout                = layout
        listV.hd_setAllDataArr([secModel])
    }
}

crash

Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'UICollectionView received layout attributes for a cell with an index path that does not exist: <NSIndexPath: 0xe2d90c1049400e15> {length = 2, path = 2 - 0}'

如何巧妙的通过PMFieldModel或者HDCellModel实现滑动手势

PMFieldModel *model1 = [PMFieldModel new];
model1.fieldName = self.source == 1 ? @"添加收款计划" : @"添加付款计划";
HDCellModel *cellModel1 = HDMakeCellModelChain
.hd_orgData(model1)
.hd_cellSize(CGSizeMake(kScreenWidth, 48))
.hd_cellClassStr(@"PMAddDefaultTableViewCell")
.hd_reuseIdentifier(@"addPlan")
.hd_generateObj;
[cellModelArr addObject:cellModel1];

代码如下,我想实现添加滑动手势增加删除按钮

侵入性太强

这个库功能还是挺强大的,但是假如在原有项目中接入的话,对原有的项目代码侵入性太强。建议作者可以考虑一些侵入性较小的方案

调用 hd_deleteSectionWithKey: 时Crash

发现一个问题。http没有返回,去其他页面做其他操作。当页面的http 返回时,在SuccessBlock 中 调用 hd_deleteSectionWithKey:方法会crash。Crash 原因是:attempt to delete section 0, but there are only 0 sections before the update。
但是在调用delete 前我判断了 hd_sectionModelExist:这个方法,为什么还是会Crash呢?

yoga 版本无法升级到最新

大佬你好,项目中有用了yogakit最新版本,但pod 无法更新到最新的yoga 版本

CocoaPods could not find compatible versions for pod "Yoga":
In Podfile:
HDCollectionView was resolved to 0.6.8, which depends on
Yoga (~> 1.9.0)

YogaKit (= 1.18.1) was resolved to 1.18.1, which depends on
  Yoga (~> 1.14)

请问下这种情况要怎么解决,谢谢

SectionHeader的数据如果刷新呢?

[ws.collectionView hd_changeSectionModelWithKey:@"header1" animated:YES changingIn:^(id _Nonnull secModel) {
secModel.headerObj = @"新值";
}];

  • (void)updateSecVUI:(__kindof id)model
    {
    /// 此方法不会被调用, 我是在这里修改数据的
    }

请问是我使用方式错了还是不能这样更新SectionHeader的数据呢?

__NSArrayM isNeedAutoCountCellHW 报错.

*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[__NSArrayM isNeedAutoCountCellHW]: unrecognized selector sent to instance 0x60000083a8e0'

我无论是copydemovc4的代码, 还是直接把demoVC4相关的东西拷贝过来, 都会报这个错

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.