mirror of
https://github.com/atom/atom.git
synced 2026-01-23 05:48:10 -05:00
basic expand/collapse working
This commit is contained in:
@@ -22,6 +22,16 @@ class PreviewList extends ScrollView
|
||||
@setSelectedOperationIndex(parseInt($(e.target).closest('li').data('index')))
|
||||
@executeSelectedOperation()
|
||||
|
||||
@on 'click', 'li.path', @onPathSelected
|
||||
|
||||
onPathSelected: (event) =>
|
||||
e = $(event.target)
|
||||
e = e.parent() if e.parent().hasClass 'path'
|
||||
return unless e.hasClass 'path'
|
||||
e.children('ul.matches').toggle 100, (e) ->
|
||||
$(this).closest('li.path').toggleClass 'is-collapsed'
|
||||
|
||||
|
||||
destroy: ->
|
||||
@destroyOperations() if @operations
|
||||
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
|
||||
.command-panel .preview-list .path {
|
||||
color: #999;
|
||||
border-top: 1px solid rgba(255, 255, 255, 0.05);
|
||||
border-top: 1px solid rgba(255, 255, 255, 0.02);
|
||||
}
|
||||
|
||||
.command-panel .preview-list .path:first-child {
|
||||
|
||||
Reference in New Issue
Block a user