ctrl+shift+p filters: :st2 :st3 :win :osx :linux
Browse

Goto-CSS-Declaration

by Razumenko Maksim ST2/ST3

Goto CSS declaration in an open *.css file

Details

Installs

  • Total 28K
  • Win 17K
  • OS X 9K
  • Linux 2K
May 28 May 27 May 26 May 25 May 24 May 23 May 22 May 21 May 20 May 19 May 18 May 17 May 16 May 15 May 14 May 13 May 12 May 11 May 10 May 9 May 8 May 7 May 6 May 5 May 4 May 3 May 2 May 1 Apr 30 Apr 29 Apr 28 Apr 27 Apr 26 Apr 25 Apr 24 Apr 23 Apr 22 Apr 21 Apr 20 Apr 19 Apr 18 Apr 17 Apr 16 Apr 15 Apr 14 Apr 13
Windows 13 29 25 14 15 12 19 18 24 32 27 14 17 29 25 33 28 38 14 25 24 28 11 22 25 14 20 22 24 25 40 19 9 13 30 26 24 28 30 13 17 30 25 25 30 32
OS X 5 14 17 12 4 7 13 22 11 8 18 6 10 13 6 6 12 16 4 21 21 10 11 6 10 10 9 18 9 6 17 12 9 11 12 11 14 16 17 11 9 8 13 8 13 17
Linux 0 3 1 1 0 1 2 1 0 3 0 1 0 5 2 1 1 1 1 2 3 1 1 3 1 4 2 1 2 2 1 1 2 5 3 1 5 3 0 0 1 2 1 0 1 4

Readme

Source
raw.​githubusercontent.​com

Goto-CSS-Declaration

v0.3 - 99% refactoring

v0.2.1 - Fix empty view.file_name


Goto CSS declaration in an open *.css (.less, .sass, .other) file from other file (*.html, *.js, *.other_extantion)

Forum Thread http://www.sublimetext.com/forum/viewtopic.php?f=5&t=4397

Goto-CSS-Declaration

Example

html:

<div id="box" class="box"></div>
                      ^
                      |-cursor

js:

$(".box").click(...);
     ^
     |-cursor

Pressing the key super+right or super+left go to the first CSS declaration of box (.class or #id => .box or #box), in this example the id #box

#box .box-shadow {
    background: url(../img/box.jpg);
    }
#box-shadow .box-shadow-1 {
    box-shadow: 0 0 5px #ff0;
    }
    .box__inner {
        box-shadow: 0 0 5px #f00;
        }

and if then press (in CSS file) super+right goes to the next CSS declaration of box, in this example the class .box-shadow, and next => #box-shadow, and next => .box-shadow-1, and next => .box__inner

also you can press (in CSS file) super+left and goes to the previous CSS declaration of box.

goto_css_declaration.sublime-settings

{
    "css_files": [".css", ".sass", ".less"]
}

Default (Linux).sublime-keymap

super + right
super + left

Default (Windows).sublime-keymap

super + .
super + ,

Copyright

Copyright © 2011 Razumenko Maksim razumenko.maksim@gmail.com

MIT License, see http://opensource.org/licenses/MIT