nl_tokens: ( an → string type → string ) - generate animation direction
pl_tokens: function ( an , type ) { var data = an var animate var result if ( / ^[a-z]+[A-Z][a-z]+$ / . test ( data ) ) { animate = data . match ( / ^([a-z]+)([A-Z][a-z]+)$ / ) if ( type === 'toggle' && isDefine ( animate_inverse ( animate [ 2 ] ) ) ) { result = animate [ 1 ] + animate_inverse ( animate [ 2 ] ) } } if ( / ^[a-z]+[A-Z][a-z]+[A-Z]$ / . test ( data ) ) { animate = <mask> . match ( / ^([a-z]+)([A-Z][a-z]+)([A-Z])$ / ) if ( type === 'toggle' && isDefine ( animate_inverse ( animate [ 2 ] ) ) ) { result = animate [ 1 ] + animate_inverse ( animate [ 2 ] ) + animate [ 3 ] } if ( type === 'toggle.inverse' && isDefine ( animate_inverse ( animate [ 2 ] ) ) ) { var direct = isDefine ( animate_inverse ( animate [ 3 ] ) ) ? animate_inverse ( animate [ 3 ] ) : animate [ 3 ] result = animate [ 1 ] + animate_inverse ( animate [ 2 ] ) + direct } } if ( / ^[a-z]+[A-Z][a-z]+[A-Z][a-z]+$ / . test ( data ) ) { animate = data . match ( / ^([a-z]+)([A-Z][a-z]+)([A-Z][a-z]+)$ / ) if ( type === 'toggle' && isDefine ( animate_inverse ( animate [ 2 ] ) ) ) { result = animate [ 1 ] + animate_inverse ( animate [ 2 ] ) + animate [ 3 ] } if ( type === 'toggle.inverse' && isDefine ( animate_inverse ( animate [ 2 ] ) ) ) { var direct = isDefine ( animate_inverse ( animate [ 3 ] ) ) ? animate_inverse ( animate [ 3 ] ) : animate [ 3 ] result = animate [ 1 ] + animate_inverse ( animate [ 2 ] ) + direct } } if ( / ^[a-z]+[A-Z][a-z]+[A-Z][a-z]+[A-Z][a-z]+$ / . test ( data ) ) { animate = data . match ( / ^([a-z]+)([A-Z][a-z]+)([A-Z][a-z]+)([A-Z][a-z]+)$ / ) if ( type === 'toggle' && isDefine ( animate_inverse ( animate [ 2 ] ) ) ) { result = animate [ 1 ] + animate_inverse ( animate [ 2 ] ) + animate [ 3 ] } if ( type === 'toggle.inverse' && isDefine ( animate_inverse ( animate [ 2 ] ) ) ) { var direct = isDefine ( animate_inverse ( animate [ 3 ] ) ) ? animate_inverse ( animate [ 3 ] ) : animate [ 3 ] + isDefine ( animate_inverse ( animate [ 4 ] ) ) ? animate_inverse ( animate [ 4 ] ) : animate [ 4 ] result = animate [ 1 ] + animate_inverse ( animate [ 2 ] ) + direct } } return result }