OWL ITS + 탐지시스템(인터넷 진흥원)
이민희
2021-11-25 fd037f73c6f07129698188a69fb2b0d2c6a520d2
1
2
3
4
5
6
7
8
9
10
11
/**
 * Get the opposite placement of the given one
 * @method
 * @memberof Popper.Utils
 * @argument {String} placement
 * @returns {String} flipped placement
 */
export default function getOppositePlacement(placement) {
  const hash = { left: 'right', right: 'left', bottom: 'top', top: 'bottom' };
  return placement.replace(/left|right|bottom|top/g, matched => hash[matched]);
}