overleaf/services/web/public/coffee/ide/review-panel/directives/reviewPanelToggle.coffee

14 lines
341 B
CoffeeScript
Raw Normal View History

2016-11-23 09:34:21 -05:00
define [
"base"
], (App) ->
App.directive "reviewPanelToggle", () ->
restrict: "E"
scope:
innerModel: '=ngModel'
template: """
<div class="rp-toggle">
<input id="rp-toggle-{{$id}}" type="checkbox" class="rp-toggle-hidden-input" ng-model="innerModel" />
<label for="rp-toggle-{{$id}}" class="rp-toggle-btn"></label>
</div>
"""