Commit c94ae31c authored by Fatih Acet's avatar Fatih Acet

Merge branch '25155-fix-edited-text-in-comments' into 'master'

break comment "edited at" block out of the note-text element to prevent issues w…

## What does this MR do?

Moves "edited" text below a note into its own element apart from rendered markdown to prevent issues when it is preceded by an inline text node.

## Are there points in the code the reviewer needs to double check?

to reproduce the bug, add text immediately following an image in a note's markdown like so:

```markdown
![foo](/uploads/c6f86574e5c3b5b73e91eeccbcb06fe6/foo.png) test text here
```

then edit and save the note.


## Why was this MR needed?

## Screenshots (if relevant)

Before:  
![Screen_Shot_2016-12-12_at_1.01.59_PM_copy](/uploads/c6f86574e5c3b5b73e91eeccbcb06fe6/Screen_Shot_2016-12-12_at_1.01.59_PM_copy.png)

After:  
![Screen_Shot_2016-12-12_at_1.00.47_PM_copy](/uploads/7a6d86d1c415114b05b4c7b662f97e93/Screen_Shot_2016-12-12_at_1.00.47_PM_copy.png)

## Does this MR meet the acceptance criteria?

- [ ] ~~[Changelog entry](https://docs.gitlab.com/ce/development/changelog.html) added~~
- [ ] ~~[Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md)~~
- [ ] ~~API support added~~
- Tests
  - [ ] ~~Added for this feature/bug~~
  - [ ] All builds are passing
- [x] Conform by the [merge request performance guides](http://docs.gitlab.com/ce/development/merge_request_performance_guidelines.html)
- [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides)
- [x] Branch has no merge conflicts with `master` (if it does - rebase it please)
- [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits)

## What are the relevant issue numbers?

Closes #25155

See merge request !8048
parents 4db62fef e8d1c7a5
...@@ -65,7 +65,7 @@ ...@@ -65,7 +65,7 @@
.note-text.md .note-text.md
= preserve do = preserve do
= note.redacted_note_html = note.redacted_note_html
= edited_time_ago_with_tooltip(note, placement: 'bottom', html_class: 'note_edited_ago', include_author: true) = edited_time_ago_with_tooltip(note, placement: 'bottom', html_class: 'note_edited_ago', include_author: true)
- if note_editable - if note_editable
= render 'projects/notes/edit_form', note: note = render 'projects/notes/edit_form', note: note
.note-awards .note-awards
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment