refactored push pull menu directive