diff --git a/.gitignore b/.gitignore index 3fc25bd96d211a85c32f437688d7dfbd017f68df..82a9adb9ad9014dea8599f58038107468e4d85da 100644 --- a/.gitignore +++ b/.gitignore @@ -42,7 +42,7 @@ public/500.html app/assets/images/branding-*.png app/assets/images/branding/logos-*.png app/assets/images/icons-*.png -app/assets/images/social_media_logos-*.png +app/assets/images/social-media-logos-*.png # Documentation .yardoc/ diff --git a/Changelog.md b/Changelog.md index a189ee2e482901f18e45e29b1aca74a8c8a40daf..4a7c05ebdf610372771e1b592750e0c17295006f 100644 --- a/Changelog.md +++ b/Changelog.md @@ -94,6 +94,7 @@ Contributions are very welcome, the hard work is done! * Optimized the pod up checks [#6727](https://github.com/diaspora/diaspora/pull/6727) * Prune and do not create aspect visibilities for public posts [#6732](https://github.com/diaspora/diaspora/pull/6732) * Optimized mobile login and registration forms [#6764](https://github.com/diaspora/diaspora/pull/6764) +* Redesign stream pages [#6535](https://github.com/diaspora/diaspora/pull/6535) ## Bug fixes * Destroy Participation when removing interactions with a post [#5852](https://github.com/diaspora/diaspora/pull/5852) diff --git a/app/assets/images/social_media_logos/Readme.txt b/app/assets/images/social-media-logos/Readme.txt similarity index 100% rename from app/assets/images/social_media_logos/Readme.txt rename to app/assets/images/social-media-logos/Readme.txt diff --git a/app/assets/images/social_media_logos/facebook-16x16.png b/app/assets/images/social-media-logos/facebook-16x16.png similarity index 100% rename from app/assets/images/social_media_logos/facebook-16x16.png rename to app/assets/images/social-media-logos/facebook-16x16.png diff --git a/app/assets/images/social_media_logos/facebook-24x24.png b/app/assets/images/social-media-logos/facebook-24x24.png similarity index 100% rename from app/assets/images/social_media_logos/facebook-24x24.png rename to app/assets/images/social-media-logos/facebook-24x24.png diff --git a/app/assets/images/social_media_logos/facebook-32x32.png b/app/assets/images/social-media-logos/facebook-32x32.png similarity index 100% rename from app/assets/images/social_media_logos/facebook-32x32.png rename to app/assets/images/social-media-logos/facebook-32x32.png diff --git a/app/assets/images/social_media_logos/tumblr-16x16.png b/app/assets/images/social-media-logos/tumblr-16x16.png similarity index 100% rename from app/assets/images/social_media_logos/tumblr-16x16.png rename to app/assets/images/social-media-logos/tumblr-16x16.png diff --git a/app/assets/images/social_media_logos/tumblr-24x24.png b/app/assets/images/social-media-logos/tumblr-24x24.png similarity index 100% rename from app/assets/images/social_media_logos/tumblr-24x24.png rename to app/assets/images/social-media-logos/tumblr-24x24.png diff --git a/app/assets/images/social_media_logos/tumblr-32x32.png b/app/assets/images/social-media-logos/tumblr-32x32.png similarity index 100% rename from app/assets/images/social_media_logos/tumblr-32x32.png rename to app/assets/images/social-media-logos/tumblr-32x32.png diff --git a/app/assets/images/social_media_logos/twitter-16x16.png b/app/assets/images/social-media-logos/twitter-16x16.png similarity index 100% rename from app/assets/images/social_media_logos/twitter-16x16.png rename to app/assets/images/social-media-logos/twitter-16x16.png diff --git a/app/assets/images/social_media_logos/twitter-24x24.png b/app/assets/images/social-media-logos/twitter-24x24.png similarity index 100% rename from app/assets/images/social_media_logos/twitter-24x24.png rename to app/assets/images/social-media-logos/twitter-24x24.png diff --git a/app/assets/images/social_media_logos/twitter-32x32.png b/app/assets/images/social-media-logos/twitter-32x32.png similarity index 100% rename from app/assets/images/social_media_logos/twitter-32x32.png rename to app/assets/images/social-media-logos/twitter-32x32.png diff --git a/app/assets/images/social_media_logos/wordpress-16x16.png b/app/assets/images/social-media-logos/wordpress-16x16.png similarity index 100% rename from app/assets/images/social_media_logos/wordpress-16x16.png rename to app/assets/images/social-media-logos/wordpress-16x16.png diff --git a/app/assets/images/social_media_logos/wordpress-24x24.png b/app/assets/images/social-media-logos/wordpress-24x24.png similarity index 100% rename from app/assets/images/social_media_logos/wordpress-24x24.png rename to app/assets/images/social-media-logos/wordpress-24x24.png diff --git a/app/assets/images/social_media_logos/wordpress-32x32.png b/app/assets/images/social-media-logos/wordpress-32x32.png similarity index 100% rename from app/assets/images/social_media_logos/wordpress-32x32.png rename to app/assets/images/social-media-logos/wordpress-32x32.png diff --git a/app/assets/javascripts/app/app.js b/app/assets/javascripts/app/app.js index cd6ebbd684b90f3671a0ddd9c89376c2a13cf7cf..f1762da847e9c853e72e5261e9196d1a27d43a02 100644 --- a/app/assets/javascripts/app/app.js +++ b/app/assets/javascripts/app/app.js @@ -104,9 +104,9 @@ var app = { evt.preventDefault(); var link = $(this); if(link.data("stream-title") && link.data("stream-title").length) { - $(".stream_title").text(link.data("stream-title")); + $(".stream-title").text(link.data("stream-title")); } else { - $(".stream_title").text(link.text()); + $(".stream-title").text(link.text()); } $("html, body").animate({scrollTop: 0}); diff --git a/app/assets/javascripts/app/views/aspects_list_view.js b/app/assets/javascripts/app/views/aspects_list_view.js index 321132857bee585c6cb01614411549957b459e1c..0138c20c1238df9d5ed6c6c021dbc8da2a6a9bba 100644 --- a/app/assets/javascripts/app/views/aspects_list_view.js +++ b/app/assets/javascripts/app/views/aspects_list_view.js @@ -59,7 +59,7 @@ app.views.AspectsList = app.views.Base.extend({ }, updateStreamTitle: function() { - $('.stream_title').text(this.collection.toSentence()); + $(".stream-title").text(this.collection.toSentence()); }, updateAspectList: function() { diff --git a/app/assets/javascripts/app/views/publisher/getting_started_view.js b/app/assets/javascripts/app/views/publisher/getting_started_view.js index 25b1dacfda5a995ff40e99698e41b355111f62f9..02a025e0ae379e1de08b2b333b1e05433f29d98d 100644 --- a/app/assets/javascripts/app/views/publisher/getting_started_view.js +++ b/app/assets/javascripts/app/views/publisher/getting_started_view.js @@ -20,15 +20,13 @@ app.views.PublisherGettingStarted = Backbone.View.extend({ show: function() { this._addPopover(this.firstMessage, { trigger: "manual", - offset: 30, id: "first_message_explain", - placement: "right", + placement: "left", html: true, container: "body" }, 600); this._addPopover(this.visibility, { trigger: "manual", - offset: 10, id: "message_visibility_explain", placement: "bottom", html: true, @@ -36,7 +34,6 @@ app.views.PublisherGettingStarted = Backbone.View.extend({ }, 1000); this._addPopover(this.stream, { trigger: "manual", - offset: -5, id: "stream_explain", placement: "left", html: true, @@ -77,4 +74,3 @@ app.views.PublisherGettingStarted = Backbone.View.extend({ } }); // @license-end - diff --git a/app/assets/javascripts/app/views/publisher_view.js b/app/assets/javascripts/app/views/publisher_view.js index 5446a972f87baf0e0d36bd4105ae376dbf1ef5ed..609c29c4c3381ad190e22125487621b41b2014b1 100644 --- a/app/assets/javascripts/app/views/publisher_view.js +++ b/app/assets/javascripts/app/views/publisher_view.js @@ -121,7 +121,7 @@ app.views.Publisher = Backbone.View.extend({ this.viewGettingStarted = new app.views.PublisherGettingStarted({ firstMessageEl: this.inputEl, visibilityEl: this.$(".public_toggle .aspect_dropdown > .dropdown-toggle"), - streamEl: $("#gs-shim") + streamEl: $("#main_stream") }); this.viewUploader = new app.views.PublisherUploader({ diff --git a/app/assets/javascripts/app/views/sidebar.js b/app/assets/javascripts/app/views/sidebar.js index 446137bb050a541bf5ae413c49067c7fa3be42fb..f5ce24b80fdd5f7087039a0baafd8355719d4874 100644 --- a/app/assets/javascripts/app/views/sidebar.js +++ b/app/assets/javascripts/app/views/sidebar.js @@ -1,15 +1,19 @@ // @license magnet:?xt=urn:btih:0b31508aeb0634b347b8270c7bee4d411b5d4109&dn=agpl-3.0.txt AGPL-v3-or-Later app.views.Sidebar = app.views.Base.extend({ - el: ".rightbar", + el: ".info-bar", events: { - "click input#invite_code": "selectInputText" + "click input#invite_code": "selectInputText", + "click .section .title": "toggleSection" }, selectInputText: function(event) { event.target.select(); + }, + + toggleSection: function(e) { + $(e.target).closest(".section").toggleClass("collapsed"); } }); // @license-end - diff --git a/app/assets/stylesheets/_application.scss b/app/assets/stylesheets/_application.scss index f7542f95053229e2e858ea495ec42d06759e3346..ad90623bff88e58de8eacf2cc90085b964870b2d 100644 --- a/app/assets/stylesheets/_application.scss +++ b/app/assets/stylesheets/_application.scss @@ -87,9 +87,6 @@ @import 'oembed'; @import 'post-content'; -/* right bar */ -@import 'navbar_right'; - /* contacts */ @import 'contacts'; @import 'navbar_left'; diff --git a/app/assets/stylesheets/base.scss b/app/assets/stylesheets/base.scss index 1142980436b1cb0473dc104d044c200a85974afa..1e7f268d10a6388c1539bc5434b81bc3436bc471 100644 --- a/app/assets/stylesheets/base.scss +++ b/app/assets/stylesheets/base.scss @@ -5,11 +5,6 @@ body { .container-fluid { max-width: $screen-lg-min; } -.page-streams, -.page-tags.action-show { - > .container-fluid { max-width: 100%; } -} - // These names are generated by a rails controller // scss-lint:disable SelectorFormat .page-contacts, @@ -22,10 +17,11 @@ body { .page-profiles.action-edit, .page-services.action-index, .page-streams, +.page-tags, .page-user_applications, .page-users.action-edit, .page-users.action-privacy_settings { - background-color: $sidebars-background; + background-color: $main-background; } // scss-lint:enable SelectorFormat diff --git a/app/assets/stylesheets/color-variables.scss b/app/assets/stylesheets/color-variables.scss index a4c9f7e41e663c78d6e9b56a1cd854a36b6570f3..d3862a09d7c0bfa11f7ab45b5231d8360db322a1 100644 --- a/app/assets/stylesheets/color-variables.scss +++ b/app/assets/stylesheets/color-variables.scss @@ -26,8 +26,8 @@ $light-green: lighten($green, 20%); $red: #a80000; $blue: #3f8fba; -$sidebars-background: #f0f0f0 !default; -$sidebars-sub-background: darken($sidebars-background, 12%) !default; +$main-background: #f0f0f0 !default; +$sidebars-background: $background-white !default; $left-navbar-drawer-background: darken($sidebars-background, 6%); $card-shadow: 0 1px 2px 0 rgba(0, 0, 0, .16), 0 2px 10px 0 rgba(0, 0, 0, .12) !default; diff --git a/app/assets/stylesheets/color_themes/original_white/_style.scss b/app/assets/stylesheets/color_themes/original_white/_style.scss index 5997151c80acfbdb47456f75da9b33b986b1f025..7f702bcafe32942c1a4a688926dd87310aa3b0fd 100644 --- a/app/assets/stylesheets/color_themes/original_white/_style.scss +++ b/app/assets/stylesheets/color_themes/original_white/_style.scss @@ -7,8 +7,8 @@ $main-color-dark: darken($main-color, 15%); // Variables $header-background-color: $main-color-dark; +$main-background: $background; $sidebars-background: $background; -$sidebars-sub-background: $background; $card-shadow: none; @import 'color_themes/color_theme_override_origwhite'; diff --git a/app/assets/stylesheets/getting-started.scss b/app/assets/stylesheets/getting-started.scss index 16cc1bff7df6af3da6378bd669f37e7e5b7a1c0b..32b41644976da8b1171f096e79bba421459d86cd 100644 --- a/app/assets/stylesheets/getting-started.scss +++ b/app/assets/stylesheets/getting-started.scss @@ -45,10 +45,8 @@ #welcome-to-diaspora { background: orange; box-shadow: inset 0 -2px 10px rgba(0,0,0,0.35); - margin-bottom: 20px; - margin-top: -40px; padding-bottom: 30px; - padding-top: 60px; + padding-top: 20px; h1,h3 { color: $white; diff --git a/app/assets/stylesheets/mobile/mobile.scss b/app/assets/stylesheets/mobile/mobile.scss index 6b59d01b29458ce89cedacfbc34d52e5779921ea..8b01ce88ca854d3f8e94a0faeedf3af1faa1a348 100644 --- a/app/assets/stylesheets/mobile/mobile.scss +++ b/app/assets/stylesheets/mobile/mobile.scss @@ -29,7 +29,7 @@ code { } body { - background-color: $sidebars-background; + background-color: $main-background; padding: 0; } diff --git a/app/assets/stylesheets/navbar_left.scss b/app/assets/stylesheets/navbar_left.scss index 35896974ed5deaa32346a4726c27a5e3734ac9fd..df6df71ee1e0556b46195f9a586afeb28d9945d7 100644 --- a/app/assets/stylesheets/navbar_left.scss +++ b/app/assets/stylesheets/navbar_left.scss @@ -1,23 +1,8 @@ -/* Fixed backgrounds are a common practice to avoid height issues */ -.left-navbar-fixed-sub-background { - background: $sidebars-sub-background; - position: fixed; - height: 100%; -} - -.left-navbar-fixed-background { - background: $sidebars-background; - border-right: 1px solid $light-grey; - position: fixed; - height: 100%; -} - .left-navbar { - background: $sidebars-background; - border-right: 1px solid $light-grey; + padding: 0; + padding-bottom: 10px; + a { - color: $link-grey; - font-weight: bold; text-decoration: none; outline: 0; } @@ -26,32 +11,35 @@ margin: 0; padding: 0; list-style: none; - &#stream_selection { - margin: 0px -15px; /* -15px overrides Bootstrap's default gutter width */ - } } .hoverable { - border-bottom: 1px solid $border-grey; color: $link-grey; display: block; - font-weight: normal; padding: 10px 20px; + font-weight: bold; + + a { + color: $link-grey; + } &:hover, &:hover a, &:hover [class^="entypo"] { background-color: $blue; + border-color: $blue; color: $white; } } - .all_aspects a.hoverable.selected, - .followed-tags-sidebar a.hoverable.selected, - li.selected > a.hoverable { + .all-aspects .hoverable.selected, + .followed-tags-sidebar .hoverable.selected, + .selected > .hoverable { color: $white; background: $gray; + border-color: $gray; } - #aspects_list, #tags_list { + .all-aspects ul, + .followed-tags-sidebar ul { background: $left-navbar-drawer-background; li { padding: 0; } .entypo-check { visibility: hidden; } @@ -71,30 +59,6 @@ .hoverable:hover > .action { visibility: visible; } } - #home_user_badge { - min-height: 90px; - padding: 20px; - margin: 0 -15px; - - .avatar { - float: left; - height: 50px; - width: 50px; - } - - h4 { - margin: 0 0 0 60px; - overflow: hidden; - text-overflow: ellipsis; - line-height: 25px; - - a { - color: $black; - font-weight: normal; - } - } - } - #tags_list { #new_tag_following { padding: 10px 20px 10px 30px; @@ -136,3 +100,93 @@ /* ---- end override app/stylesheets/vendor/autoSuggest.css ---- */ } } + +.info-bar { + margin-top: 20px; + padding: 10px 20px 0; + + .info-links { + border-top: 1px solid $border-grey; + margin-top: 10px; + padding: 5px; + } + + .section { + margin-top: 10px; + + &:last-child { + margin-bottom: 10px; + } + + &:not(.collapsed) .entypo-triangle-right, + &.collapsed .entypo-triangle-down, + &.collapsed .content { + display: none; + } + + &.collapsed .title h5 { + font-weight: normal; + } + } + + .title { + cursor: pointer; + padding-bottom: 5px; + + h5 { + color: $text-dark-grey; + font-size: $font-size-base; + font-weight: bold; + margin: 0; + } + } + + .content { + color: $text-grey; + font-size: $font-size-small; + line-height: 18px; + padding: 10px 0; + + p, + ul { + margin: 0; + } + + ul { + list-style: none; + margin-bottom: 5px; + padding-left: 0; + } + + .btn-link { + font-size: $font-size-small; + padding-left: 0; + } + + > [name="invite_code"] { + box-sizing: border-box; + font-size: $font-size-small; + height: 30px; + width: 100%; + } + } + + .right-service-icons { + padding: 10px { + bottom: 0; + } + text-align: center; + + .social-media-logos-facebook-24x24, + .social-media-logos-twitter-24x24, + .social-media-logos-tumblr-24x24, + .social-media-logos-wordpress-24x24 { + height: 24px; + width: 24px; + } + + a { + display: inline-block; + } + } +} diff --git a/app/assets/stylesheets/navbar_right.scss b/app/assets/stylesheets/navbar_right.scss deleted file mode 100644 index 134123d30809b96801e00659c2f0cc77b4714838..0000000000000000000000000000000000000000 --- a/app/assets/stylesheets/navbar_right.scss +++ /dev/null @@ -1,90 +0,0 @@ -.right-sidebar-fixed-background { - height: 100%; - border-left: 1px solid $light-grey; - background: $sidebars-background; - position: fixed; - right: 0; -} -.right-sidebar-fixed-sub-background { - height: 100%; - background: $sidebars-sub-background; - position: fixed; - right: 0; -} - -.right-sidebar-padder { - max-width: 400px; -} -.rightbar { - padding-top: 20px; - border-left: 1px solid $light-grey; - background: $sidebars-background; - - .section { - margin-bottom: 20px; - - > .title { - border-bottom: 1px solid $border-grey; - padding-bottom: 5px; - - &.no_icon { padding-left: 8px; } - - h5 { - color: $text-dark-grey; - font-weight: normal; - font-size: $font-size-base; - margin: 0; - } - } - - .content { - color: $text-grey; - font-size: $font-size-small; - line-height: 18px; - padding: 10px 0; - - p, ul { margin: 0; } - - ul { - margin-bottom: 5px; - padding-left: 0; - li { list-style: none; } - } - - .btn-link { - font-size: $font-size-small; - padding-left: 0; - } - - & > #invite_code { - box-sizing: border-box; - font-size: $font-size-small; - height: 30px; - width: 100%; - } - - & > #right_service_icons { - text-align: center; - padding: 10px { - bottom: 0; - }; - .social_media_logos-facebook-24x24, - .social_media_logos-twitter-24x24, - .social_media_logos-tumblr-24x24, - .social_media_logos-wordpress-24x24 { - height: 24px; - width: 24px; - } - a { - display: inline-block; - } - } - } - } -} - -@media screen and (min-width: 1200px) { - .right-sidebar-fixed-background { - margin-right: 8.33333%; /* Only for LARGE screens, same as lg-offset-1 class, BS3 does not provide right side offsetting */ - } -} diff --git a/app/assets/stylesheets/publisher.scss b/app/assets/stylesheets/publisher.scss index 93a7637fd5203700f2ef9c0781075d994701be7e..df04cf34929fd3d251a60889eb5c11783d2d1e8a 100644 --- a/app/assets/stylesheets/publisher.scss +++ b/app/assets/stylesheets/publisher.scss @@ -1,7 +1,8 @@ -#publisher { +.publisher { z-index: 1; color: $text-grey; margin: 0; + margin-bottom: 20px; &.closed { #button_container, @@ -35,6 +36,7 @@ .options_and_submit { padding: 10px 0; + #publisher-service-icons { text-decoration: none; @@ -46,7 +48,7 @@ .service_icon { padding: 6px 5px; } .btn.btn-link.question_mark:hover .entypo-cog { color: $black; } .dim { opacity: 0.3; } - .social_media_logos-wordpress-16x16 { + .social-media-logos-wordpress-16x16 { display: inline-block; height: 16px; width: 16px; diff --git a/app/assets/stylesheets/sidebar.scss b/app/assets/stylesheets/sidebar.scss index 9242840e60c5fd36e3094cce4fc555203958084c..1df833b427409f54eb9e42c586fc69f53395f6c7 100644 --- a/app/assets/stylesheets/sidebar.scss +++ b/app/assets/stylesheets/sidebar.scss @@ -2,9 +2,8 @@ .framed-content { background-color: $white; border: 1px solid $light-grey; + border-top: 0; box-shadow: $card-shadow; - margin-top: -10px; - padding-top: 10px; .header, .sidebar-header { diff --git a/app/assets/stylesheets/single-post-view.scss b/app/assets/stylesheets/single-post-view.scss index 03767b997e1f63c2d84042640927f434e1bec677..e0cb2894e21c94c620bc770219ebec2cbd33b43a 100644 --- a/app/assets/stylesheets/single-post-view.scss +++ b/app/assets/stylesheets/single-post-view.scss @@ -4,9 +4,8 @@ #single-post-content { .head { - padding-bottom: 10px; - padding-top: 5px; border-bottom: 1px solid $border-grey; + padding: 10px 0; #post-info { .author{ color: $grey; } .info { @@ -108,6 +107,11 @@ } #single-post-interactions { + + > .framed-content { + padding-top: 10px; + } + .no-comments { text-align: center; } a { diff --git a/app/assets/stylesheets/sprites.scss b/app/assets/stylesheets/sprites.scss index bef149df977bf2ff24956880d88b2344e36264ac..981e20cc36dd9c5210d695c6d6d8bc586f8f4561 100644 --- a/app/assets/stylesheets/sprites.scss +++ b/app/assets/stylesheets/sprites.scss @@ -1,5 +1,5 @@ /* ===== sprites ===== */ @import 'branding/logos/*.png'; -@import 'social_media_logos/*.png'; +@import 'social-media-logos/*.png'; @include all-logos-sprites; -@include all-social_media_logos-sprites; +@include all-social-media-logos-sprites; diff --git a/app/assets/stylesheets/stream.scss b/app/assets/stylesheets/stream.scss index 355ff8e9af0a135b67f0fd9e434e3e3fc4aa2a51..622e4272b0e5219763fa2ec0bcd2ea1e2e068da0 100644 --- a/app/assets/stylesheets/stream.scss +++ b/app/assets/stylesheets/stream.scss @@ -1,6 +1,25 @@ .stream_container { - #publisher { - margin-bottom: 15px; + .stream-title { + margin: 12px 0; + } +} + +.main-stream-publisher { + padding: 0; + + .avatar { + height: 50px; + width: 50px; + } + + .publisher { + margin-left: 65px; + } +} + +@media(max-width: $screen-xs-max) { + + .main-stream-publisher .publisher { + margin-left: 0; } - .well#ignore-info { text-align: center; } } diff --git a/app/assets/stylesheets/tag.scss b/app/assets/stylesheets/tag.scss index 037cc1c70db3e6377ae6b03c09a578d87daa64fa..c18102ae83b7cad784f8af08c9e8040bde02c905 100644 --- a/app/assets/stylesheets/tag.scss +++ b/app/assets/stylesheets/tag.scss @@ -23,11 +23,13 @@ h1.tag { } } .page-tags { - background-color: $sidebars-background; - .left-navbar-fixed-background { border-right: 0; } #tags_show { - .col-md-3 { - h4 { margin: 25px 0 15px; } + .sidebar { + h3 { + font-size: 13px; + line-height: 1.1; + } + .side_stream #people_stream { .name { display: block; } .name, .diaspora_handle { @@ -37,7 +39,7 @@ h1.tag { } } } - .col-md-7 { + .col-md-9 { .tag-following-action { max-width: 100%; input[type="submit"] { diff --git a/app/helpers/publisher_helper.rb b/app/helpers/publisher_helper.rb index 4afe09c4abc981274b022a857d27aa2f02a82b68..3935bc52cd8cbf6609853bc4165c692100b3fc74 100644 --- a/app/helpers/publisher_helper.rb +++ b/app/helpers/publisher_helper.rb @@ -19,7 +19,7 @@ module PublisherHelper maxchar: "#{service.class::MAX_CHARACTERS}", data: {toggle: "tooltip", placement: "bottom"} do if service.provider == "wordpress" - content_tag(:span, "", class: "social_media_logos-wordpress-16x16") + content_tag(:span, "", class: "social-media-logos-wordpress-16x16") else content_tag(:i, "", class: "entypo-social-#{ service.provider } small") end diff --git a/app/views/api/openid_connect/user_applications/index.html.haml b/app/views/api/openid_connect/user_applications/index.html.haml index 667abc2185c742d711dc0d51d3fa8648c7114136..b90082995ab17fb6cb461835b5620b91d02240e8 100644 --- a/app/views/api/openid_connect/user_applications/index.html.haml +++ b/app/views/api/openid_connect/user_applications/index.html.haml @@ -7,7 +7,7 @@ .sidebar = render "shared/settings_nav" .col-md-9 - .framed-content + .framed-content.clearfix %h3= t(".title") .row .col-md-12 diff --git a/app/views/aspects/_aspect_stream.haml b/app/views/aspects/_aspect_stream.haml index 69999e7013d08245501d6e880a2c1ac9af470fa1..7aa104d130ea55166df585eec30b4957d2a1e9a6 100644 --- a/app/views/aspects/_aspect_stream.haml +++ b/app/views/aspects/_aspect_stream.haml @@ -3,14 +3,19 @@ -# the COPYRIGHT file. - if user_signed_in? && @person != current_user.person - %h3#aspect_stream_header.stream_title + %h3.stream-title = stream.title -= render 'publisher/publisher', publisher_aspects_for(stream) +.container-fluid.main-stream-publisher + .pull-left.hidden-xs + = owner_image_link + = render "publisher/publisher", publisher_aspects_for(stream) -#gs-shim{:title => popover_with_close_html("3. #{t('.stay_updated')}"), 'data-content' => t('.stay_updated_explanation')} - -#main_stream.stream +- if current_user.getting_started? + .stream#main_stream{:title => popover_with_close_html("3. #{t('.stay_updated')}"), + "data-content" => t(".stay_updated_explanation")} +- else + .stream#main_stream #paginate %span.loader.hidden diff --git a/app/views/conversations/index.haml b/app/views/conversations/index.haml index 47c1e76d69a774b1d3d980a6a32b84630a4fc815..31297c79e5182d1951b94449f2c7f2267779183f 100644 --- a/app/views/conversations/index.haml +++ b/app/views/conversations/index.haml @@ -34,7 +34,7 @@ - else .stream_container.hidden #conversation_show - .framed-content#conversation_new + .framed-content.clearfix#conversation_new .new-conversation %h3.text-center = t("conversations.index.new_conversation") diff --git a/app/views/profiles/edit.haml b/app/views/profiles/edit.haml index 8eee45d2a32eddeec55edc89aa1b018ce49b7ba0..043cbfe88e0bc99a0e125451d5767df956706d41 100644 --- a/app/views/profiles/edit.haml +++ b/app/views/profiles/edit.haml @@ -8,7 +8,7 @@ .sidebar = render "shared/settings_nav" .col-md-9 - .framed-content + .framed-content.clearfix - content_for :submit_block do = link_to t("cancel"), local_or_remote_person_path(current_user.person), class: "btn btn-default" = submit_tag t(".update_profile"), class: "btn btn-primary pull-right", id: "update_profile" diff --git a/app/views/publisher/_publisher.html.haml b/app/views/publisher/_publisher.html.haml index 70d386ce59251fed8372835a4fa6d43fca0df2b6..3ecec1f403274c724abbf50633348f01c38393eb 100644 --- a/app/views/publisher/_publisher.html.haml +++ b/app/views/publisher/_publisher.html.haml @@ -4,7 +4,7 @@ if( app.publisher ) app.publisher.triggerGettingStarted(); }); -.row#publisher{class: ((aspect == :profile || publisher_open) ? "mention_popup" : "closed")} +.row.publisher#publisher{class: ((aspect == :profile || publisher_open) ? "mention_popup" : "closed")} .content_creation = form_for(StatusMessage.new) do |status| = status.error_messages diff --git a/app/views/publisher/_publisher.mobile.haml b/app/views/publisher/_publisher.mobile.haml index 8040a152d82e61cd80f4514fb98d5bd122aba205..4399b7c13b69484d74d308a9cdc3e0367f804da0 100644 --- a/app/views/publisher/_publisher.mobile.haml +++ b/app/views/publisher/_publisher.mobile.haml @@ -11,7 +11,9 @@ %span#publisher-service-icons - if current_user.services - for service in current_user.services - = image_tag "social_media_logos/#{service.provider}-32x32.png", title: service.provider.titleize, class: "service_icon dim", id:"#{service.provider}", maxchar: "#{service.class::MAX_CHARACTERS}" + = image_tag "social-media-logos/#{service.provider}-32x32.png", + title: service.provider.titleize, class: "service_icon dim", + id: "#{service.provider}", maxchar: "#{service.class::MAX_CHARACTERS}" %select{id: "aspect_ids_", class: "form-control", name: "aspect_ids[]"} %option{value: 'public'} diff --git a/app/views/services/index.html.haml b/app/views/services/index.html.haml index 3828b102fd9325ff4562f939e9746fc21d4c5c8c..432dafdb32d2e650c0d8806bfc33aa79c63a3711 100644 --- a/app/views/services/index.html.haml +++ b/app/views/services/index.html.haml @@ -11,7 +11,7 @@ .sidebar = render "shared/settings_nav" .col-md-9 - .framed-content + .framed-content.clearfix %h3= t(".title") .row .col-md-12 diff --git a/app/views/shared/_right_sections.html.haml b/app/views/shared/_right_sections.html.haml deleted file mode 100644 index e8fd5b013d8fd28f84129b2da158882b83e23048..0000000000000000000000000000000000000000 --- a/app/views/shared/_right_sections.html.haml +++ /dev/null @@ -1,94 +0,0 @@ --# Copyright (c) 2010-2011, Diaspora Inc. This file is --# licensed under the Affero General Public License version 3 or later. See --# the COPYRIGHT file. - -.right-sidebar-padder - - - if AppConfig.settings.invitations.open? - .section - .title - %h5.title-header - = t('shared.invitations.invite_your_friends') - .content - = render "shared/invitations" - - .section - .title - %h5.title-header - = t('aspects.index.new_here.title') - .content - != t('aspects.index.new_here.follow', link: link_to("#"+t('shared.publisher.new_user_prefill.newhere'), tag_path(name: t('shared.publisher.new_user_prefill.newhere')))) - %br - = link_to(t('aspects.index.new_here.learn_more'), "http://wiki.diasporafoundation.org/Welcoming_Committee") - - .section - .title - %h5.title-header - = t('aspects.index.help.need_help') - .content - %p - = t('aspects.index.help.here_to_help') - %p - = t('aspects.index.help.do_you') - %ul - %li - != t('aspects.index.help.have_a_question', :link => link_to("#"+t('aspects.index.help.tag_question'), tag_path(:name => t('aspects.index.help.tag_question')))) - %li - != t('aspects.index.help.find_a_bug', :link => link_to("#"+t('aspects.index.help.tag_bug'), tag_path(:name => t('aspects.index.help.tag_bug')))) - %li - != t('aspects.index.help.feature_suggestion', :link => link_to("#"+t('aspects.index.help.tag_feature'), tag_path(:name => t('aspects.index.help.tag_feature')))) - %p - != t('aspects.index.help.tutorials_and_wiki', - :faq => link_to(t('_help'), help_path), - :tutorial => link_to(t('aspects.index.help.tutorial_link_text'), "https://diasporafoundation.org/tutorials", :target => '_blank'), - :wiki => link_to('Wiki','http://wiki.diasporafoundation.org', :target => '_blank'), :target => '_blank') - - - unless AppConfig.configured_services.blank? || all_services_connected? - .section - .title - %h5.title-header - = t('aspects.index.services.heading') - .content - %div - = t('aspects.index.services.content') - - #right_service_icons - - AppConfig.configured_services.each do |service| - - if AppConfig.show_service?(service, current_user) - - unless current_user.services.any?{|x| x.provider == service} - = link_to(content_tag(:div, nil, :class => "social_media_logos-#{service.to_s.downcase}-24x24", :title => service.to_s.titleize), "/auth/#{service}") - - .section - .title - %h5.title-header - = t('bookmarklet.heading') - .content - != t('bookmarklet.explanation', :link => link_to(t('bookmarklet.post_something'), bookmarklet_code)) - - - if AppConfig.settings.paypal_donations.enable? || AppConfig.bitcoin_donation_address - .section - .title - %h5.title-header - = t('aspects.index.donate') - .content - %p - = t('aspects.index.keep_pod_running', :pod => AppConfig.pod_uri.host) - = render 'shared/donatepod' - - - if AppConfig.admins.podmin_email.present? - .section - .title - %h5.title-header - = t('aspects.index.help.any_problem') - .content - %p - = t('aspects.index.help.contact_podmin') - %p - = link_to t("aspects.index.help.mail_podmin"), "mailto:#{AppConfig.admins.podmin_email}" - - .section - .title - .content - %ul - = render "shared/links" - diff --git a/app/views/shared/_settings_nav.haml b/app/views/shared/_settings_nav.haml index 7c4b74460da156db22a51912a959bd7409f64719..53794791ebdf5778d6363ec4660a1d645196aa34 100644 --- a/app/views/shared/_settings_nav.haml +++ b/app/views/shared/_settings_nav.haml @@ -1,6 +1,7 @@ #section_header - %h3.sidebar-header - = t("settings") + .sidebar-header.clearfix + %h3 + = t("settings") .list-group#settings_nav = link_to t("profile"), edit_profile_path, class: current_page?(edit_profile_path) ? "list-group-item active" : "list-group-item" diff --git a/app/views/streams/main_stream.html.haml b/app/views/streams/main_stream.html.haml index cb3bb5d5fd6d6949cfa6e3b6f5aa96710b534419..25c4155c53699688baed021c1bfc9b18271f422f 100644 --- a/app/views/streams/main_stream.html.haml +++ b/app/views/streams/main_stream.html.haml @@ -9,49 +9,154 @@ - if current_user.getting_started? #welcome-to-diaspora - .container + .container-fluid .row - .col-md-8.offset1 + .col-md-9 %h1 = t('aspects.index.welcome_to_diaspora', name: current_user.first_name) %h3 = t('aspects.index.introduce_yourself') - .col-md-2 + .col-md-3 .pull-right = link_to '×'.html_safe, getting_started_completed_path, id: "gs-skip-x", class: "close" -%div.container-fluid +.container-fluid .row - .left-navbar-fixed-sub-background.col-lg-1.visible-lg - .left-navbar-fixed-background.col-lg-offset-1.col-lg-2.col-md-3.hidden-sm.hidden-xs - .left-navbar.col-lg-offset-1.col-lg-2.col-md-3 - #home_user_badge - = owner_image_link - %h4 - = link_to current_user.first_name, local_or_remote_person_path(current_user.person) - - %ul#stream_selection - %li{data: {stream: "stream"}} - = link_to t("streams.multi.title"), stream_path, rel: "backbone", class: "hoverable" - %li{data: {stream: "activity"}} - = link_to t("streams.activity.title"), activity_stream_path, rel: "backbone", class: "hoverable" - %li{data: {stream: "mentions"}} - = link_to t("streams.mentions.title"), mentioned_stream_path, rel: "backbone", class: "hoverable" - %li.all_aspects - = render "aspects/aspect_listings", stream: @stream - %li.followed-tags-sidebar - = render "tags/followed_tags_listings" - %li{data: {stream: "public"}} - = link_to t("streams.public.title"), public_stream_path, rel: "backbone", class: "hoverable" - - .col-md-6 - #aspect_stream_container.stream_container - = render 'aspects/aspect_stream', stream: @stream - - .right-sidebar-fixed-sub-background.col-lg-3.visible-lg - .right-sidebar-fixed-background.col-md-3.col-lg-2.hidden-sm.hidden-xs - .col-md-3.col-lg-2.hidden-xs.hidden-sm.rightbar - = render 'shared/right_sections' + .col-md-3 + .sidebar.left-navbar + %ul#stream_selection + %li{data: {stream: "stream"}} + = link_to t("streams.multi.title"), stream_path, rel: "backbone", class: "hoverable" + %li{data: {stream: "activity"}} + = link_to t("streams.activity.title"), activity_stream_path, rel: "backbone", class: "hoverable" + %li{data: {stream: "mentions"}} + = link_to t("streams.mentions.title"), mentioned_stream_path, rel: "backbone", class: "hoverable" + %li.all-aspects + = render "aspects/aspect_listings", stream: @stream + %li.followed-tags-sidebar + = render "tags/followed_tags_listings" + %li{data: {stream: "public"}} + = link_to t("streams.public.title"), public_stream_path, rel: "backbone", class: "hoverable" + + .sidebar.info-bar.hidden-xs + - if AppConfig.settings.invitations.open? + .section.collapsed + .title + %h5.title-header + .entypo-triangle-right + .entypo-triangle-down + = t("shared.invitations.invite_your_friends") + .content + = render "shared/invitations" + + .section.collapsed + .title + %h5.title-header + .entypo-triangle-right + .entypo-triangle-down + = t("aspects.index.new_here.title") + .content + != t("aspects.index.new_here.follow", + link: link_to("#" + t("shared.publisher.new_user_prefill.newhere"), + tag_path(name: t("shared.publisher.new_user_prefill.newhere")))) + %br + = link_to(t("aspects.index.new_here.learn_more"), + "http://wiki.diasporafoundation.org/Welcoming_Committee") + + .section.collapsed + .title + %h5.title-header + .entypo-triangle-right + .entypo-triangle-down + = t("aspects.index.help.need_help") + .content + %p + = t("aspects.index.help.here_to_help") + %p + = t("aspects.index.help.do_you") + %ul + %li + != t("aspects.index.help.have_a_question", + link: link_to("#" + t("aspects.index.help.tag_question"), + tag_path(name: t("aspects.index.help.tag_question")))) + %li + != t("aspects.index.help.find_a_bug", + link: link_to("#" + t("aspects.index.help.tag_bug"), + tag_path(name: t("aspects.index.help.tag_bug")))) + %li + != t("aspects.index.help.feature_suggestion", + link: link_to("#" + t("aspects.index.help.tag_feature"), + tag_path(name: t("aspects.index.help.tag_feature")))) + %p + != t("aspects.index.help.tutorials_and_wiki", + faq: link_to(t("_help"), help_path), + tutorial: link_to(t("aspects.index.help.tutorial_link_text"), + "https://diasporafoundation.org/tutorials", target: "_blank"), + wiki: link_to("Wiki", "http://wiki.diasporafoundation.org", + target: "_blank"), + target: "_blank") + + - unless AppConfig.configured_services.blank? || all_services_connected? + .section.collapsed + .title + %h5.title-header + .entypo-triangle-right + .entypo-triangle-down + = t("aspects.index.services.heading") + .content + %div + = t("aspects.index.services.content") + + .right-service-icons + - AppConfig.configured_services.each do |service| + - if AppConfig.show_service?(service, current_user) + - unless current_user.services.any? {|x| x.provider == service } + = link_to(content_tag(:div, nil, + class: "social-media-logos-#{service.to_s.downcase}-24x24", + title: service.to_s.titleize), "/auth/#{service}") + + .section.collapsed + .title + %h5.title-header + .entypo-triangle-right + .entypo-triangle-down + = t("bookmarklet.heading") + .content + != t("bookmarklet.explanation", link: link_to(t("bookmarklet.post_something"), bookmarklet_code)) + + - if AppConfig.settings.paypal_donations.enable? || AppConfig.bitcoin_donation_address + .section.collapsed + .title + %h5.title-header + .entypo-triangle-right + .entypo-triangle-down + = t("aspects.index.donate") + .content + %p + = t("aspects.index.keep_pod_running", pod: AppConfig.pod_uri.host) + = render "shared/donatepod" + + - if AppConfig.admins.podmin_email.present? + .section.collapsed + .title + %h5.title-header + .entypo-triangle-right + .entypo-triangle-down + = t("aspects.index.help.any_problem") + .content + %p + = t("aspects.index.help.contact_podmin") + %p + = link_to t("aspects.index.help.mail_podmin"), "mailto:#{AppConfig.admins.podmin_email}" + + .info-links + .content + %ul + = render "shared/links" + + .col-md-9 + .stream_container#aspect_stream_container + = render "aspects/aspect_stream", stream: @stream %a.back-to-top#back-to-top{title: "#{t('layouts.application.back_to_top')}", href: "#"} ⇧ diff --git a/app/views/tags/show.haml b/app/views/tags/show.haml index f40a6f8898926b677c9928f34cfe2fe775380386..ebb468b28a3a404713b12709dd798711de770f3e 100644 --- a/app/views/tags/show.haml +++ b/app/views/tags/show.haml @@ -10,16 +10,16 @@ .container-fluid#tags_show .row - .col-lg-1.visible-lg.left-navbar-fixed-sub-background - .col-lg-offset-1.col-lg-3.col-md-4.hidden-sm.hidden-xs.left-navbar-fixed-background - .col-lg-offset-1.col-lg-3.col-md-4 - %h4 - = t('.tagged_people', count: @stream.tagged_people_count, tag: @stream.display_tag_name) + .col-md-3.hidden-xs + .sidebar + .sidebar-header.clearfix + %h3 + = t(".tagged_people", count: @stream.tagged_people_count, tag: @stream.display_tag_name) - .side_stream.stream - = render partial: 'people/index', locals: {people: @stream.tagged_people} + .side_stream.stream + = render partial: "people/index", locals: {people: @stream.tagged_people} - .col-lg-7.col-md-8 + .col-md-9 .stream_container #author_info %h2 @@ -34,7 +34,5 @@ %span.loader.hidden .spinner - .col-lg-1.visible-lg.right-sidebar-fixed-sub-background - %a.back-to-top#back-to-top{title: "#{t('layouts.application.back_to_top')}", href: "#"} ⇧ diff --git a/features/desktop/donations.feature b/features/desktop/donations.feature index 9bf0b28180c639a3e1c7cb8b425ce0b31ba60709..0985ff132cfc2d08712e47447323ed526a6210fe 100644 --- a/features/desktop/donations.feature +++ b/features/desktop/donations.feature @@ -13,4 +13,6 @@ Feature: donations Scenario: Bitcoin donations Given I have configured a Bitcoin address And I go to the home page + Then I should see "Donate" within ".info-bar" + And I click on "Donate" navbar title Then I should see the Bitcoin address diff --git a/features/desktop/invitations.feature b/features/desktop/invitations.feature index 74ce102fc2b009f10242be3dd78f7f7629f83769..76ce989028e8712f093558803c69dfd1d77288eb 100644 --- a/features/desktop/invitations.feature +++ b/features/desktop/invitations.feature @@ -37,11 +37,13 @@ Feature: Invitations And I close the publisher And I log out And I sign in as "alice@alice.alice" + And I click on "Invite your friends" navbar title And I click on selector "#invitations-button" Then I should see one less invite Scenario: sends an invitation When I sign in as "alice@alice.alice" + And I click on "Invite your friends" navbar title And I click on selector "#invitations-button" And I fill in the following: | email_inviter_emails | alex@example.com | diff --git a/features/desktop/keyboard_navigation.feature b/features/desktop/keyboard_navigation.feature index aed65c3f65d6d35006bd794c68ce42b521cb8d86..a5061a3e328f4cd7ac4c8ea5fe54ae63f589d02e 100644 --- a/features/desktop/keyboard_navigation.feature +++ b/features/desktop/keyboard_navigation.feature @@ -25,7 +25,7 @@ Feature: Keyboard navigation Scenario: navigate downwards after changing the stream When I go to the activity stream page And I click on selector "[data-stream='stream'] a" - Then I should see "Stream" within ".stream_title" + Then I should see "Stream" within ".stream-title" When I press the "J" key somewhere Then post 1 should be highlighted diff --git a/features/step_definitions/aspects_steps.rb b/features/step_definitions/aspects_steps.rb index 0cfeb8242d68ac86233e33e795bd9c996d274056..b51284dccba590cd0c721af9753bfb9e612992f1 100644 --- a/features/step_definitions/aspects_steps.rb +++ b/features/step_definitions/aspects_steps.rb @@ -34,7 +34,7 @@ end World(AspectCukeHelpers) When /^I click on "([^"]*)" aspect edit icon$/ do |aspect_name| - within(".all_aspects") do + within(".all-aspects") do li = find('li', text: aspect_name) li.hover li.find('.modify_aspect').click diff --git a/features/step_definitions/stream_steps.rb b/features/step_definitions/stream_steps.rb index 830d9de8276be6d84a38bd577371b00ee1d0118c..22c285439c334bca0e5f7d91857b6141222e5192 100644 --- a/features/step_definitions/stream_steps.rb +++ b/features/step_definitions/stream_steps.rb @@ -21,3 +21,9 @@ end Then /^I should have (\d+) nsfw posts$/ do |num_posts| page.should have_css(".nsfw-shield", count: num_posts.to_i) end + +When /^(?:|I )click on "([^"]*)" navbar title$/ do |title| + with_scope(".info-bar") do + find("h5", text: title).click + end +end