Last active
January 31, 2018 13:18
-
-
Save MrChriZ/78bb807277b50460cc8eda1161417983 to your computer and use it in GitHub Desktop.
New Twiddle
This file contains hidden or 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'; | |
import { MDCToolbar } from '@material/toolbar'; | |
import toolbarComponent from 'ember-material-components/components/mdc-toolbar'; | |
export default toolbarComponent.extend({ | |
init() { | |
this._super(...arguments); | |
}, | |
didInsertElement() { | |
this._super(...arguments); | |
toolbar.fixedAdjustElement = Ember.$('.mdc-toolbar-fixed-adjust')[0]; | |
var interval = 100; | |
this.startWatchingTime(interval); | |
}, | |
startWatchingTime(interval) { | |
let toolbar = MDCToolbar.attachTo(Ember.get(this, 'element')); | |
toolbar.fixedAdjustElement = Ember.$('.mdc-toolbar-fixed-adjust')[0]; | |
Ember.run.later(() => this.startWatchingTime(interval), interval); | |
} | |
}); |
This file contains hidden or 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 hidden or 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.Service.extend({ | |
}); |
This file contains hidden or 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.13.0", | |
"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.16.2", | |
"ember-template-compiler": "2.16.2", | |
"ember-testing": "2.16.2" | |
}, | |
"addons": { | |
"ember-data": "2.16.3", | |
"ember-cli-sass": "7.1.4", | |
"ember-material-components": "0.0.4" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment