gitlab-org--gitlab-foss/app/helpers
Dmitriy Zaporozhets 4666515538 Merge branch 'flatten-dirs' into 'master'
Flatten the directory hierarchy while there is only one directory descendant

In some languages, especially java, the directory structure reflects the package structure.This means that using the file tree browser to reach the directories that matter you have to click a lot of directories containing only another subdirectory.

This merge request tries to enhance this by showing and providing the link to the first directory that doesn't contain only one directory.

See also [this feature request](http://feedback.gitlab.com/forums/176466-general/suggestions/6236769-jump-forward-to-the-first-folder-that-has-more-tha)

This is very similar to what [GitHub does](https://github.com/blog/1877-folder-jumping), but I don't think graying out the empty directories is really necessary.

Screenshots: [Before](https://gitlab.com/uploads/marmis85/gitlab-ce/b683a0000f/before.png) - [After](https://gitlab.com/uploads/marmis85/gitlab-ce/a23725a1c1/after.png)

I'm actually very new at ruby, rails, haml, and almost everything involved in Gitlab's development...
From what I could understand, when we render each directory item in the list we only have the data structure representing the item but not his descendants.
To iterate through the hierarchy I call Gitlab::Git:Tree.where() but I'm not sure if this is the most efficient way.

I also considered making every directory a clickable link, but I tried that and in the end it wasn't very useful and reduced the click target for the most useful directory.

See merge request !275
2015-01-11 04:42:28 +00:00
..
appearances_helper.rb Improve login page behaviour 2014-07-13 20:56:29 +03:00
application_helper.rb Improve application settings and write tests 2015-01-08 09:53:35 -08:00
application_settings_helper.rb Finally fix stuff related to dynamic config 2015-01-08 14:26:43 -08:00
blob_helper.rb revert using the extension of the blob to determine the syntax highlighting language 2014-11-18 12:55:22 +01:00
branches_helper.rb Dont show new file link on protected branch for developers 2014-06-02 16:18:16 +03:00
broadcast_messages_helper.rb Customization and previewing of broadcast messages 2013-12-18 17:43:45 -05:00
commits_helper.rb Clean the string with commit author and email. 2014-11-14 11:08:58 +01:00
compare_helper.rb Fix bug with showing create merge request button while merge request are disabled in project settings 2013-12-04 11:02:36 +03:00
dashboard_helper.rb Restyle and refactor dashboard projects page filtering 2015-01-06 13:09:56 -08:00
diff_helper.rb Set of UI changes mostly for issue and merge request 2014-12-25 14:32:49 +02:00
emails_helper.rb Set action on issue/mr creation mail. 2014-11-12 11:59:57 +01:00
events_helper.rb Restyle group page and event filter 2014-12-16 18:15:48 +02:00
git_helper.rb Hide gpg signature on tags page from tag message 2014-11-18 18:00:38 +02:00
gitlab_markdown_helper.rb Render cross reference in issue title 2014-12-03 11:15:00 +02:00
graph_helper.rb Remove the dependancy of grit from class Network::Graph 2013-08-20 12:05:23 +09:00
groups_helper.rb Restyle and refactor milestones filter 2015-01-06 12:32:04 -08:00
icons_helper.rb Upgrade to Font Awesome v4.2 2014-10-03 12:19:24 +02:00
issues_helper.rb DRY and refactor atom code 2014-12-04 22:14:20 +02:00
labels_helper.rb Consistency: Capitalize hex values of sugested colors 2014-08-15 11:02:05 +02:00
merge_requests_helper.rb Merge pull request #7379 from cirosantilli/remove-title 2014-10-06 11:55:43 +03:00
milestones_helper.rb Restyle and refactor milestones filter 2015-01-06 12:32:04 -08:00
namespaces_helper.rb Improve fork to namespaces feature 2014-11-14 16:06:39 +02:00
notes_helper.rb Render MR diff full size of screen 2014-12-22 20:36:15 +02:00
notifications_helper.rb Upgrade to Font Awesome v4.2 2014-10-03 12:19:24 +02:00
oauth_helper.rb added helper 2014-12-04 13:03:55 +02:00
profile_helper.rb Finally fix stuff related to dynamic config 2015-01-08 14:26:43 -08:00
projects_helper.rb Refactor issues and merge requests lists 2014-12-23 18:49:39 +02:00
search_helper.rb Sort projects in search autocomplete by amount of stars. Most popular go first 2014-09-25 19:41:49 +03:00
selects_helper.rb Helper for ajax group selectbox 2014-12-30 11:46:47 +02:00
snippets_helper.rb Restyle snippets 2013-06-05 22:25:27 +03:00
sorting_helper.rb Set proper filter words 2014-12-04 12:12:51 +02:00
submodule_helper.rb Refactor some search scopes to prevent wierd behaviour and PG::Error issues 2014-06-05 20:37:35 +03:00
tab_helper.rb Fix nav_link support for several path options 2014-12-25 20:51:07 +02:00
tags_helper.rb Add parenthesis to function def with arguments. 2014-10-03 09:18:46 +02:00
tree_helper.rb Flatten the directory hierarchy while there is only one directory descendant 2014-12-31 03:15:04 +01:00
visibility_level_helper.rb Snippets: public/internal/private 2014-10-09 17:09:53 +03:00