OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub
Ruby agile-developmentangularbcfboardsbug-trackerganttgantt-chartifcissue-trackerjira-alternativekanbanopenprojectproduct-managementproject-managementproject-planningroadmaprubyscrumtimelineworkflows
Align arrow with multi-line header in news widget on mobile and desktop && fix some code alignments
Henriette Darge212c3afab627
diff --git a/app/assets/stylesheets/content/_news.sass b/app/assets/stylesheets/content/_news.sassindex 258eccb7925..12ad1c6a064 100644--- a/app/assets/stylesheets/content/_news.sass+++ b/app/assets/stylesheets/content/_news.sass@@ -33,14 +33,23 @@@include text-shortenermargin-bottom: 5px+.summary+ font-style: italic+.news-author- font-size: 0.8rem- color: $gray-dark- display: block+ font-size: 0.8rem+ color: $gray-dark+ display: block+ padding: 5px 0 5px 40px+ line-height: 1.25.news-author-avatar- margin-right: 5px- float: left+ margin-right: 5px+ float: left+.news-project+ line-height: 1-+@media screen and (max-width: 679px)+ .news-author+ padding-left: 0diff --git a/app/assets/stylesheets/content/_widget_box.sass b/app/assets/stylesheets/content/_widget_box.sassindex e5690671a5f..8698caa4d24 100644--- a/app/assets/stylesheets/content/_widget_box.sass+++ b/app/assets/stylesheets/content/_widget_box.sass@@ -153,6 +153,7 @@ $widget-box--enumeration-width: 20px.-widget-box--arrow-multiline&:before+ line-height: 2float: left&:after@@ -172,3 +173,7 @@ $widget-box--enumeration-width: 20px&.-flex.widget-boxflex-basis: 100%++ .widget-box--arrow-links+ .-widget-box--arrow-multiline:before+ padding-top: 0diff --git a/app/views/homescreen/blocks/_news.html.erb b/app/views/homescreen/blocks/_news.html.erbindex 39837b8f369..d91d2f25b04 100644--- a/app/views/homescreen/blocks/_news.html.erb+++ b/app/views/homescreen/blocks/_news.html.erb@@ -4,14 +4,16 @@<% @news.each do |news| %><li class="-widget-box--arrow-multiline"><div>- <%= avatar(news.author, {class: 'avatar news-author-avatar'}) %>- <%= link_to_project(news.project) + ': ' %>- <%= link_to h(news.title), news_path(news) %>+ <%= avatar(news.author, {class: 'avatar news-author-avatar hidden-for-mobile'}) %>+ <div class="news-project">+ <%= link_to_project(news.project) + ': ' %>+ <%= link_to h(news.title), news_path(news) %>+ </div><div class="news-author"><span><%= authoring_at Date.strptime(news.created_at.to_s), news.author %></span></div><div>- <p class="widget-box--additional-info"><%= news.summary %></p>+ <p class="widget-box--additional-info"><%= news.summary %></p></div></div></li>diff --git a/frontend/src/app/modules/grids/widgets/news/news.component.html b/frontend/src/app/modules/grids/widgets/news/news.component.htmlindex e9096664c91..4ade14ccd06 100644--- a/frontend/src/app/modules/grids/widgets/news/news.component.html+++ b/frontend/src/app/modules/grids/widgets/news/news.component.html@@ -1,4 +1,5 @@-<widget-header [name]="widgetName" [editable]="isEditable">+<widget-header [name]="widgetName"+ [editable]="isEditable"><widget-menu [resource]="resource"></widget-menu>@@ -6,34 +7,32 @@</widget-header><div class="grid--widget-content"><no-results *ngIf="noEntries"- [title]="text.noResults">+ [title]="text.noResults"></no-results><ul class="widget-box--arrow-links"><li class="-widget-box--arrow-multiline"*ngFor="let news of entries">- <div>- <user-avatar- *ngIf="news.author"- [user]="news.author"- data-class-list="avatar news-author-avatar">+ <div class="news-project">+ <user-avatar *ngIf="news.author"+ [user]="news.author"+ data-class-list="avatar news-author-avatar hidden-for-mobile"></user-avatar><div>- <a- [href]="newsProjectPath(news)"- [textContent]="newsProjectName(news)">- </a>:- <a [href]="newsPath(news)"- [textContent]="news.title">- </a>+ <a [href]="newsProjectPath(news)"+ [textContent]="newsProjectName(news)">+ </a>:+ <a [href]="newsPath(news)"+ [textContent]="news.title">+ </a></div><div *ngIf="news.author"- class="news-author">- <span [innerHTML]="text.addedBy(news)"> </span>+ class="news-author">+ <span [innerHTML]="text.addedBy(news)"></span></div><div><p *ngIf="news.summary"- [textContent]="news.summary"- class="widget-box--additional-info"></p>+ [textContent]="news.summary"+ class="widget-box--additional-info"></p></div></div></li>