All files / actions LayoutActions.js

100% Statements 4/4
100% Branches 0/0
100% Functions 4/4
100% Lines 4/4
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22      1x               1x       1x       1x    
import { ADD_CARD, MOVE_CARD, REMOVE_CARD, RESTORE_LAYOUT } from '../actionTypes';
 
export function addCard(card, column, tab, index, size) {
  return { type: ADD_CARD, card, column, tab, index, size };
}
 
/*
  from: { column, index }
  to: { column, index }
*/
export function moveCard(tab, size, from, to) {
  return { type: MOVE_CARD, tab, size, from, to };
}
 
export function removeCard(card, column, tab, index, size) {
  return { type: REMOVE_CARD, card, column, tab, index, size };
}
 
export function restoreDefault() {
  return { type: RESTORE_LAYOUT };
}