mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
Rename attributes and vars for clarity
This commit is contained in:
parent
fb7d902038
commit
3f073c2341
3 changed files with 10 additions and 10 deletions
|
@ -63,8 +63,8 @@ block content
|
|||
resize-on="layout:chat:resize",
|
||||
minimum-restore-size-west="130"
|
||||
custom-toggler-pane="'west'"
|
||||
custom-toggler-tooltip-open="'Click to open the file tree'"
|
||||
custom-toggler-tooltip-close="'Click to close the file tree'"
|
||||
custom-toggler-msg-when-open="'Click to close the file tree'"
|
||||
custom-toggler-msg-when-closed="'Click to open the file tree'"
|
||||
)
|
||||
.ui-layout-west
|
||||
include ./editor/file-tree
|
||||
|
|
|
@ -9,8 +9,8 @@ div.full-size(
|
|||
minimum-restore-size-east="300"
|
||||
allow-overflow-on="'center'"
|
||||
custom-toggler-pane="'east'"
|
||||
custom-toggler-tooltip-open="'Click to open the PDF'"
|
||||
custom-toggler-tooltip-close="'Click to close the PDF'"
|
||||
custom-toggler-msg-when-open="'Click to close the PDF'"
|
||||
custom-toggler-msg-when-closed="'Click to open the PDF'"
|
||||
)
|
||||
.ui-layout-center(
|
||||
ng-controller="ReviewPanelController",
|
||||
|
|
|
@ -9,9 +9,9 @@ define [
|
|||
name = attrs.layout
|
||||
|
||||
customTogglerPane = scope.$eval(attrs.customTogglerPane)
|
||||
customTogglerTooltipOpen = scope.$eval(attrs.customTogglerTooltipOpen)
|
||||
customTogglerTooltipClose = scope.$eval(attrs.customTogglerTooltipClose)
|
||||
hasCustomToggler = customTogglerPane? and customTogglerTooltipOpen? and customTogglerTooltipClose?
|
||||
customTogglerMsgWhenOpen = scope.$eval(attrs.customTogglerMsgWhenOpen)
|
||||
customTogglerMsgWhenClosed = scope.$eval(attrs.customTogglerMsgWhenClosed)
|
||||
hasCustomToggler = customTogglerPane? and customTogglerMsgWhenOpen? and customTogglerMsgWhenClosed?
|
||||
|
||||
if attrs.spacingOpen?
|
||||
spacingOpen = parseInt(attrs.spacingOpen, 10)
|
||||
|
@ -124,8 +124,8 @@ define [
|
|||
customTogglerScope.isOpen = false
|
||||
|
||||
console.log customTogglerScope.isOpen
|
||||
customTogglerScope.tooltipMsgOpen = customTogglerTooltipOpen
|
||||
customTogglerScope.tooltipMsgClose = customTogglerTooltipClose
|
||||
customTogglerScope.tooltipMsgWhenOpen = customTogglerMsgWhenOpen
|
||||
customTogglerScope.tooltipMsgWhenClosed = customTogglerMsgWhenClosed
|
||||
|
||||
customTogglerScope.tooltipPlacement = if customTogglerPane == "east" then "left" else "right"
|
||||
customTogglerScope.handleClick = () ->
|
||||
|
@ -135,7 +135,7 @@ define [
|
|||
<a href
|
||||
class=\"custom-toggler #{ 'custom-toggler-' + customTogglerPane }\"
|
||||
ng-class=\"isOpen ? 'custom-toggler-open' : 'custom-toggler-closed'\"
|
||||
tooltip=\"{{ isOpen ? tooltipMsgClose : tooltipMsgOpen }}\"
|
||||
tooltip=\"{{ isOpen ? tooltipMsgWhenOpen : tooltipMsgWhenClosed }}\"
|
||||
tooltip-placement=\"{{ tooltipPlacement }}\"
|
||||
ng-click=\"handleClick()\">
|
||||
")(customTogglerScope)
|
||||
|
|
Loading…
Reference in a new issue