File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed
Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -1431,9 +1431,14 @@ export class TilingLayout extends Layout {
14311431 const policies = this . config . resizePolicies ;
14321432 if ( ! policies ) return ;
14331433
1434- for ( let m of containerSpec . submorphs ) {
1435- let match , fixedTotalExtent ;
1436- if ( m . isPolicy ) m = m . spec ;
1434+ for ( let i = 0 ; i < containerSpec . submorphs . length ; i ++ ) {
1435+ let match ; let fixedTotalExtent ; let m = containerSpec . submorphs [ i ] ;
1436+ if ( m . isPolicy ) {
1437+ m = containerSpec . submorphs [ i ] = m . copy ( ) ;
1438+ m = m . spec ;
1439+ } else {
1440+ m = containerSpec . submorphs [ i ] = { ...m } ;
1441+ }
14371442 if ( match = policies . find ( ( [ name , policy ] ) => name === m . name ) ) {
14381443 const [ _ , policy ] = match ;
14391444 if ( policy . width === 'fill' ) {
You can’t perform that action at this time.
0 commit comments