# HG changeset patch # User Mads Kiilerich # Date 1438770581 -7200 # Node ID 24d01c64c5f3269c543322a5e91136b72beda2a4 # Parent 5f0f341c5a4429b76cbff54e48b865ac8eaa7d89 comments: when linking to specific comments, make the browser show a bit of the context of the comment Make the link targets have an invisible pre: that goes 100px above the target. diff -r 5f0f341c5a44 -r 24d01c64c5f3 kallithea/public/css/style.css --- a/kallithea/public/css/style.css Wed Aug 05 12:29:41 2015 +0200 +++ b/kallithea/public/css/style.css Wed Aug 05 12:29:41 2015 +0200 @@ -4128,7 +4128,7 @@ max-width: 978px; } -.comments .comment { +.comments .comment .comment-wrapp { border: 1px solid #ddd; margin-top: 10px; border-radius: 4px; @@ -4328,20 +4328,19 @@ margin: 0; padding: 0 20px 0px; } -.inline-comments .comment { + +.inline-comments .comment .comment-wrapp { max-width: 978px; border: 1px solid #ddd; border-radius: 4px; margin: 3px 3px 5px 5px; background-color: #FAFAFA; } + .inline-comments .add-comment { padding: 2px 4px 8px 5px; } -.inline-comments .comment-wrapp { - padding: 1px; -} .inline-comments .comment .meta { background: #f8f8f8; padding: 4px; @@ -4839,6 +4838,15 @@ transform: scale(1.2, 1.2); } +/* show some context of link targets - but only works when the link target + can be extended with any visual difference */ +:target:before { + display: block; + height: 100px; + margin: -100px 0 0; + content: ""; +} + div.comment:target>.comment-wrapp { border: solid 2px #ee0 !important; }