Skip to content
This repository has been archived by the owner on Mar 27, 2023. It is now read-only.

Commit

Permalink
Removed unused code
Browse files Browse the repository at this point in the history
  • Loading branch information
subbiahsn committed Jul 30, 2019
1 parent a6373c8 commit 3e1e195
Showing 1 changed file with 1 addition and 11 deletions.
12 changes: 1 addition & 11 deletions app/javascript/modules/transition/index.ts
@@ -1,6 +1,6 @@
import * as $ from 'jquery';

function makeTransition(transition) {
export const transitionFromTo = (transition: string) => {
const [tfrom, tto] = transition.split(':');
const $from = document.querySelector(`[data-transition-id="${tfrom}"]`);
const $to = document.querySelector(`[data-transition-id="${tto}"]`);
Expand All @@ -15,15 +15,5 @@ function makeTransition(transition) {
block: 'center',
inline: 'nearest',
});
$($from).fadeOut();
}
}

export const transitionFromTo = (transitionString: string) => {
if (transitionString.includes('__')) {
const transitions = transitionString.split('__');
transitions.map(transition => makeTransition(transition));
} else {
makeTransition(transitionString);
}
};

0 comments on commit 3e1e195

Please sign in to comment.