diff options
Diffstat (limited to 'app/assets')
21 files changed, 112 insertions, 92 deletions
diff --git a/app/assets/images/msapplication-tile.png b/app/assets/images/msapplication-tile.png Binary files differnew file mode 100644 index 00000000000..f8c5c8b28b4 --- /dev/null +++ b/app/assets/images/msapplication-tile.png diff --git a/app/assets/images/touch-icon-ipad-retina.png b/app/assets/images/touch-icon-ipad-retina.png Binary files differnew file mode 100644 index 00000000000..feb32b48ec9 --- /dev/null +++ b/app/assets/images/touch-icon-ipad-retina.png diff --git a/app/assets/images/touch-icon-ipad.png b/app/assets/images/touch-icon-ipad.png Binary files differnew file mode 100644 index 00000000000..a6ddc543509 --- /dev/null +++ b/app/assets/images/touch-icon-ipad.png diff --git a/app/assets/images/touch-icon-iphone-retina.png b/app/assets/images/touch-icon-iphone-retina.png Binary files differnew file mode 100644 index 00000000000..8bf7ccb7534 --- /dev/null +++ b/app/assets/images/touch-icon-iphone-retina.png diff --git a/app/assets/images/touch-icon-iphone.png b/app/assets/images/touch-icon-iphone.png Binary files differnew file mode 100644 index 00000000000..87da550f8be --- /dev/null +++ b/app/assets/images/touch-icon-iphone.png diff --git a/app/assets/javascripts/application.js.coffee b/app/assets/javascripts/application.js.coffee index bb120424ccf..8b041c490d8 100644 --- a/app/assets/javascripts/application.js.coffee +++ b/app/assets/javascripts/application.js.coffee @@ -40,6 +40,7 @@ #= require shortcuts_issuable #= require shortcuts_network #= require cal-heatmap +#= require jquery.nicescroll.min #= require_tree . window.slugify = (text) -> @@ -104,6 +105,8 @@ if location.hash window.addEventListener "hashchange", shiftWindow $ -> + $(".nicescroll").niceScroll(cursoropacitymax: '0.4', cursorcolor: '#FFF', cursorborder: "1px solid #FFF") + # Click a .js-select-on-focus field, select the contents $(".js-select-on-focus").on "focusin", -> # Prevent a mouseup event from deselecting the input diff --git a/app/assets/javascripts/dispatcher.js.coffee b/app/assets/javascripts/dispatcher.js.coffee index a8ec0abc264..81e73799271 100644 --- a/app/assets/javascripts/dispatcher.js.coffee +++ b/app/assets/javascripts/dispatcher.js.coffee @@ -62,8 +62,9 @@ class Dispatcher shortcut_handler = new ShortcutsNavigation() when 'projects:commits:show' shortcut_handler = new ShortcutsNavigation() + when 'projects:activity' + shortcut_handler = new ShortcutsNavigation() when 'projects:show' - new Activities() shortcut_handler = new ShortcutsNavigation() when 'groups:show' new Activities() @@ -127,7 +128,10 @@ class Dispatcher shortcut_handler = new ShortcutsNavigation() new ZenMode() new DropzoneInput($('.wiki-form')) - when 'snippets', 'labels', 'graphs' + when 'snippets' + shortcut_handler = new ShortcutsNavigation() + new ZenMode() if path[2] == 'show' + when 'labels', 'graphs' shortcut_handler = new ShortcutsNavigation() when 'project_members', 'deploy_keys', 'hooks', 'services', 'protected_branches' shortcut_handler = new ShortcutsNavigation() diff --git a/app/assets/javascripts/dropzone_input.js.coffee b/app/assets/javascripts/dropzone_input.js.coffee index a7476146010..a4f511301c1 100644 --- a/app/assets/javascripts/dropzone_input.js.coffee +++ b/app/assets/javascripts/dropzone_input.js.coffee @@ -25,10 +25,10 @@ class @DropzoneInput form_dropzone = $(form).find('.div-dropzone') form_dropzone.parent().addClass "div-dropzone-wrapper" form_dropzone.append divHover - $(".div-dropzone-hover").append iconPaperclip + form_dropzone.find(".div-dropzone-hover").append iconPaperclip form_dropzone.append divSpinner - $(".div-dropzone-spinner").append iconSpinner - $(".div-dropzone-spinner").css + form_dropzone.find(".div-dropzone-spinner").append iconSpinner + form_dropzone.find(".div-dropzone-spinner").css "opacity": 0 "display": "none" diff --git a/app/assets/javascripts/line_highlighter.js.coffee b/app/assets/javascripts/line_highlighter.js.coffee index a8b3c1fa33e..e604e6025c2 100644 --- a/app/assets/javascripts/line_highlighter.js.coffee +++ b/app/assets/javascripts/line_highlighter.js.coffee @@ -70,7 +70,7 @@ class @LineHighlighter @clearHighlight() - lineNumber = $(event.target).data('line-number') + lineNumber = $(event.target).closest('a').data('line-number') current = @hashToRange(@_hash) unless current[0] && event.shiftKey diff --git a/app/assets/javascripts/merge_request.js.coffee b/app/assets/javascripts/merge_request.js.coffee index 7462975bd3d..b21cb7904b5 100644 --- a/app/assets/javascripts/merge_request.js.coffee +++ b/app/assets/javascripts/merge_request.js.coffee @@ -15,9 +15,7 @@ class @MergeRequest this.$('.show-all-commits').on 'click', => this.showAllCommits() - # `MergeRequests#new` has no tab-persisting or lazy-loading behavior - unless @opts.action == 'new' - new MergeRequestTabs(@opts) + @initTabs() # Prevent duplicate event bindings @disableTaskList() @@ -29,6 +27,14 @@ class @MergeRequest $: (selector) -> this.$el.find(selector) + initTabs: -> + if @opts.action != 'new' + # `MergeRequests#new` has no tab-persisting or lazy-loading behavior + new MergeRequestTabs(@opts) + else + # Show the first tab (Commits) + $('.merge-request-tabs a[data-toggle="tab"]:first').tab('show') + showAllCommits: -> this.$('.first-commits').remove() this.$('.all-commits').removeClass 'hide' diff --git a/app/assets/javascripts/notes.js.coffee b/app/assets/javascripts/notes.js.coffee index 1c05a2b9fe8..bcff7bcc49e 100644 --- a/app/assets/javascripts/notes.js.coffee +++ b/app/assets/javascripts/notes.js.coffee @@ -298,7 +298,7 @@ class @Notes note.find(".note-header").hide() base_form = note.find(".note-edit-form") form = base_form.clone().insertAfter(base_form) - form.addClass('current-note-edit-form') + form.addClass('current-note-edit-form gfm-form') form.find('.div-dropzone').remove() # Show the attachment delete link diff --git a/app/assets/javascripts/pager.js.coffee b/app/assets/javascripts/pager.js.coffee index fe83dc0410e..d639303aed3 100644 --- a/app/assets/javascripts/pager.js.coffee +++ b/app/assets/javascripts/pager.js.coffee @@ -12,7 +12,7 @@ @loading.show() $.ajax type: "GET" - url: location.href + url: $(".content_list").data('href') || location.href data: "limit=" + @limit + "&offset=" + @offset complete: => @loading.hide() diff --git a/app/assets/javascripts/project_show.js.coffee b/app/assets/javascripts/project_show.js.coffee index 6828ae471e5..1fdf28f2528 100644 --- a/app/assets/javascripts/project_show.js.coffee +++ b/app/assets/javascripts/project_show.js.coffee @@ -1,15 +1,3 @@ class @ProjectShow constructor: -> - $('.project-home-panel .star').on 'ajax:success', (e, data, status, xhr) -> - $(@).toggleClass('on').find('.count').html(data.star_count) - .on 'ajax:error', (e, xhr, status, error) -> - new Flash('Star toggle failed. Try again later.', 'alert') - - $("a[data-toggle='tab']").on "shown.bs.tab", (e) -> - $.cookie "default_view", $(e.target).attr("href"), { expires: 30, path: '/' } - - defaultView = $.cookie("default_view") - if defaultView - $("a[href=" + defaultView + "]").tab "show" - else - $("a[data-toggle='tab']:first").tab "show" + # I kept class for future diff --git a/app/assets/javascripts/shortcuts_navigation.coffee b/app/assets/javascripts/shortcuts_navigation.coffee index 31895fbf2bc..5b6f9e7e3f2 100644 --- a/app/assets/javascripts/shortcuts_navigation.coffee +++ b/app/assets/javascripts/shortcuts_navigation.coffee @@ -4,6 +4,7 @@ class @ShortcutsNavigation extends Shortcuts constructor: -> super() Mousetrap.bind('g p', -> ShortcutsNavigation.findAndFollowLink('.shortcuts-project')) + Mousetrap.bind('g e', -> ShortcutsNavigation.findAndFollowLink('.shortcuts-project-activity')) Mousetrap.bind('g f', -> ShortcutsNavigation.findAndFollowLink('.shortcuts-tree')) Mousetrap.bind('g c', -> ShortcutsNavigation.findAndFollowLink('.shortcuts-commits')) Mousetrap.bind('g n', -> ShortcutsNavigation.findAndFollowLink('.shortcuts-network')) diff --git a/app/assets/stylesheets/base/mixins.scss b/app/assets/stylesheets/base/mixins.scss index 08cbe911672..d64e79170b9 100644 --- a/app/assets/stylesheets/base/mixins.scss +++ b/app/assets/stylesheets/base/mixins.scss @@ -109,7 +109,7 @@ font-size: 1.2em; } - blockquote p { + blockquote { color: #888; font-size: 15px; line-height: 1.5; diff --git a/app/assets/stylesheets/generic/mobile.scss b/app/assets/stylesheets/generic/mobile.scss index a49775daf8b..24c828e0d97 100644 --- a/app/assets/stylesheets/generic/mobile.scss +++ b/app/assets/stylesheets/generic/mobile.scss @@ -44,20 +44,18 @@ .project-home-panel { padding-left: 0 !important; - .project-home-row { - .project-home-desc { - margin-right: 0 !important; - float: none !important; - } - - .project-repo-buttons { - position: static; - margin-top: 15px; - width: 100%; - float: none; - text-align: left; - } + .project-avatar { + display: block; } + + .project-repo-buttons, + .git-clone-holder { + display: none; + } + } + + .project-stats { + display: none; } .container .title { diff --git a/app/assets/stylesheets/generic/sidebar.scss b/app/assets/stylesheets/generic/sidebar.scss index 00e0534b81e..b96664d30db 100644 --- a/app/assets/stylesheets/generic/sidebar.scss +++ b/app/assets/stylesheets/generic/sidebar.scss @@ -2,6 +2,9 @@ .sidebar-wrapper { position: fixed; top: 0; + bottom: 0; + overflow-y: auto; + overflow-x: hidden; left: 0; height: 100%; transition-duration: .3s; @@ -21,8 +24,9 @@ } .nav-sidebar { + margin-top: 29 + $header-height; + margin-bottom: 50px; transition-duration: .3s; - margin: 0; list-style: none; overflow: hidden; @@ -39,12 +43,12 @@ } a { + padding: 8px 15px; + font-size: 13px; + line-height: 18px; color: $gray; display: block; text-decoration: none; - padding: 8px 15px; - font-size: 14px; - line-height: 20px; padding-left: 16px; &:hover { @@ -88,14 +92,17 @@ width: $sidebar_width; .nav-sidebar { - margin-top: 29px; - position: fixed; - top: $header-height; width: $sidebar_width; } .nav-sidebar li a{ width: 230px; + + &.back-link { + i { + visibility: hidden; + } + } } } } @@ -108,15 +115,9 @@ width: $sidebar_collapsed_width; .nav-sidebar { - margin-top: 29px; - position: fixed; - top: $header-height; width: $sidebar_collapsed_width; li a { - font-size: 14px; - padding: 8px 15px; - text-align: left; padding-left: 16px; } } @@ -175,7 +176,7 @@ } .sidebar-user { - position: absolute; + position: fixed; bottom: 0; width: $sidebar_width; padding: 10px; diff --git a/app/assets/stylesheets/generic/typography.scss b/app/assets/stylesheets/generic/typography.scss index 66767cb13cb..2db4213159a 100644 --- a/app/assets/stylesheets/generic/typography.scss +++ b/app/assets/stylesheets/generic/typography.scss @@ -17,6 +17,14 @@ pre { background: #333; color: $background-color; } + + &.plain-readme { + background: none; + border: none; + padding: 0; + margin: 0; + font-size: 14px; + } } .monospace { diff --git a/app/assets/stylesheets/pages/notes.scss b/app/assets/stylesheets/pages/notes.scss index 42b8ecabb38..4da65b28743 100644 --- a/app/assets/stylesheets/pages/notes.scss +++ b/app/assets/stylesheets/pages/notes.scss @@ -72,13 +72,28 @@ ul.notes { .note { display: block; position:relative; + .note-body { overflow: auto; + .note-text { overflow: auto; word-wrap: break-word; @include md-typography; + // Reset ul style types since we're nested inside a ul already + & > ul { + list-style-type: disc; + + ul { + list-style-type: circle; + + ul { + list-style-type: square; + } + } + } + // Reduce left padding of first task list ul element ul.task-list:first-child { padding-left: 10px; @@ -94,6 +109,7 @@ ul.notes { } } } + .note-header { padding-bottom: 3px; } diff --git a/app/assets/stylesheets/pages/projects.scss b/app/assets/stylesheets/pages/projects.scss index e19b2eafa43..5f415f2d78f 100644 --- a/app/assets/stylesheets/pages/projects.scss +++ b/app/assets/stylesheets/pages/projects.scss @@ -15,48 +15,31 @@ } .project-home-panel { - margin-top: 10px; - margin-bottom: 15px; - position: relative; - padding-left: 65px; - min-height: 50px; + text-align: center; + margin-bottom: 20px; .project-identicon-holder { - position: absolute; - left: 0; - top: -14px; + margin-bottom: 15px; - .avatar { - width: 50px; - height: 50px; + .avatar, .identicon { + margin: 0 auto; + float: none; } .identicon { - font-size: 26px; - line-height: 50px; + @include border-radius(50%); } } - .project-home-row { - @extend .clearfix; - margin-bottom: 15px; - - &.project-home-row-top { - margin-bottom: 15px; + .lead { + p { + display: inline; } + } - .project-home-desc { - color: $gray; - float: left; - font-size: 16px; - line-height: 1.3; - margin-right: 250px; - - // Render Markdown-generated HTML inline for this block - p { - display: inline; - } - } + .git-clone-holder { + max-width: 600px; + margin: 0 auto; } .visibility-level-label { @@ -67,22 +50,22 @@ } .project-repo-buttons { - margin-top: -3px; - position: absolute; - right: 0; - width: 265px; - text-align: right; + margin-top: 25px; + margin-bottom: 25px; .btn { + @extend .btn-info; + + margin-left: 10px; font-weight: bold; font-size: 14px; line-height: 16px; + padding: 8px 12px; .count { - padding-left: 10px; - border-left: 1px solid #ccc; + padding-left: 7px; display: inline-block; - margin-left: 10px; + margin-left: 7px; } } } @@ -307,3 +290,15 @@ table.table.protected-branches-list tr.no-border { float: left; margin-right: 10px; } + +.project-stats { + text-align: center; + + ul.nav-pills { display:inline-block; } + li { display:inline; } + a { float:left; } +} + +pre.light-well { + border-color: #f1f1f1; +} diff --git a/app/assets/stylesheets/themes/gitlab-theme.scss b/app/assets/stylesheets/themes/gitlab-theme.scss index dc47b108100..3589cb88d03 100644 --- a/app/assets/stylesheets/themes/gitlab-theme.scss +++ b/app/assets/stylesheets/themes/gitlab-theme.scss @@ -35,9 +35,9 @@ .sidebar-wrapper { background: $color-darker; - border-right: 1px solid $color-darker; .sidebar-user { + background: $color-darker; color: $color-light; &:hover { |
