Created
March 29, 2017 18:19
-
-
Save twokul/107a59f2311f696a96e27f1707d85b6f to your computer and use it in GitHub Desktop.
Salary facet
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 Ember from 'ember'; | |
const MAX = 1157; | |
export default Ember.Component.extend({ | |
tagName: 'rect', | |
attributeBindings: ['computedHeight:height'], | |
computedHeight: Ember.computed('facet.count', function() { | |
let facetCount = this.get('facet.count'); | |
debugger; | |
return 100 - facetCount/MAX; | |
}) | |
}); |
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 Ember from 'ember'; | |
export default Ember.Component.extend({ | |
tagName: 'svg' | |
}); |
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 Ember from 'ember'; | |
export default Ember.Controller.extend({ | |
appName: 'Ember Twiddle' | |
}); |
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 Ember from 'ember'; | |
export default Ember.Route.extend({ | |
model() { | |
return { | |
facetContainers: [{ | |
"count": 1157, | |
"displayValue": "$40,000+", | |
"value": "1" | |
}, { | |
"count": 1139, | |
"displayValue": "$60,000+", | |
"value": "2" | |
}, { | |
"count": 1026, | |
"displayValue": "$80,000+", | |
"value": "3" | |
}, { | |
"count": 787, | |
"displayValue": "$100,000+", | |
"value": "4" | |
}, { | |
"count": 515, | |
"displayValue": "$120,000+", | |
"value": "5" | |
}, { | |
"count": 198, | |
"displayValue": "$140,000+", | |
"value": "6" | |
}, { | |
"count": 58, | |
"displayValue": "$160,000+", | |
"value": "7" | |
}, { | |
"count": 19, | |
"displayValue": "$180,000+", | |
"value": "8" | |
}, { | |
"count": 1, | |
"displayValue": "$200,000+", | |
"value": "9" | |
}] | |
}; | |
} | |
}); |
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
{ | |
"version": "0.12.1", | |
"EmberENV": { | |
"FEATURES": {} | |
}, | |
"options": { | |
"use_pods": false, | |
"enable-testing": false | |
}, | |
"dependencies": { | |
"jquery": "https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.3/jquery.js", | |
"ember": "2.12.0", | |
"ember-template-compiler": "2.12.0", | |
"ember-testing": "2.12.0" | |
}, | |
"addons": { | |
"ember-data": "2.12.1" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment