BottomSheetDialog With RecyclerView

问题遇到的现象和发生背景

BottomSheetDialog中使用RecyclerView

问题相关代码,请勿粘贴截图

img

运行结果及报错内容

img

我的解答思路和尝试过的方法

吧layoutManager换layoutparam可以解决崩溃,但是适配器的onBindViewHolder不执行,似乎和onCreateViewholder的parent参数有关

我想要达到的结果

rv使用layoutmanager无报错

这不是很明显的错误嘛 String: java.Lang. ClassCastException: android.widget.FrameLayoutSLayoutParams cannot be cast to androidx.appcompat.widget.LinearLayoutCompat$LayoutParams 类型转换错误

bottomsheetdialog加载的布局文件

img