我试图将可扩展的行添加到有角度的材质表中,因此找到了一个示例。我通过将角度版本升级到^ 7.0.0修改了示例,当从“折叠”过渡到“展开”时,动画突然停止工作。 Here is a stackblitz demonstrating the problem。如果单击某行以将其展开,则在短暂的延迟后,该行会立即展开。然后,如果再次单击该行使其折叠,动画将正常工作。如何修复动画,以便正确展开行动画?
答案 0 :(得分:2)
只需将动画保持在高度
Traceback (most recent call last):
File "C:\Users\adam\Scripting\xlxsComparer.py", line 160, in <module>
main()
File "C:\Users\adam\Scripting\xlxsComparer.py", line 156, in main
excel_diff(path_OLD, path_NEW, index_col)
File "C:\Users\adam\Scripting\xlxsComparer.py", line 130, in excel_diff
'format': removed_fmt})
File "C:\Program Files\Python36\lib\site-packages\xlsxwriter\worksheet.py", line 83, in cell_wrapper
int(args[0])
TypeError: only size-1 arrays can be converted to Python scalars
state('expanded', style({height: '*'})),
state('collapsed', style({height: '0px'})),
看起来很臭。
https://stackblitz.com/edit/angular-lb7n8q-ldwsld?file=app/table-expandable-rows-example.ts