Created
September 20, 2018 21:00
-
-
Save davidjgonzalez/6163dd08c3486c624a49726f4f8a873d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Bem from '../../../../util/Bem'; | |
export default class Sort { | |
constructor() { | |
this.bem = new Bem('cmp-search-sort'); | |
this.component = $(this.bem.selector()); | |
this.sortByElement = this.component.element(this.bem.scope('selection', 'sort-by').selector()); | |
this.sortDirectionElement = this.component.element(this.bem.scope('selection', 'sort-direction').selector()); | |
} | |
get sortByLabel() { | |
return this.sortByElement.element(this.bem.element('selection-text')); | |
} | |
get sortByOptions() { | |
return this.sortByElement.elements(this.bem.element('selection-item')) | |
} | |
get sortDirectionLabel() { | |
return this.sortDirectionElement.element(this.bem.element('selection-text')); | |
} | |
get sortDirectionOptions() { | |
return this.sortDirectionElement.elements(this.bem.element('selection-item')); | |
} | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment