project/src/main/webapp/shared.js
/**
 * Makes the masonry grid for events-feed ordered roughly from left to right
 * instead of top to bottom
 */
Makes the masonry grid for events-feed ordered roughly from left to right
instead of top to bottom
Makes the masonry grid for events - feed ordered roughly from left to right instead of top to bottom
function transposeEventLevels(eventLevels) {
  const numberOfColumns = 4;
  let transposed = [[], [], [], []];
  for (let i = 0; i < eventLevels.length; i++) {
    transposed[i % numberOfColumns].push(eventLevels[i]);
  }
  return transposed;
}
function transposeEventLevels ( eventLevels ) { const numberOfColumns = 4 ; let transposed = [ [ ] , [ ] , [ ] , [ ] ] ; for ( let i = 0 ; i < eventLevels . length ; i ++ ) { transposed [ i % numberOfColumns ] . push ( eventLevels [ i ] ) ; } return transposed ; }
Makes the masonry grid for events-feed ordered roughly from left to right
 instead of top to bottom
Makes the masonry grid for events - feed ordered roughly from left to right instead of top to bottom