diff --git a/assets/css/scss/components/post/post.scss b/assets/css/scss/components/post/post.scss
index 09c9b3a..f818e45 100644
--- a/assets/css/scss/components/post/post.scss
+++ b/assets/css/scss/components/post/post.scss
@@ -317,6 +317,9 @@
line-height: 150% !important;
font-size: $MmediumS;
font-style: $light;
+ .highlight{
+ color: $green;
+ }
}
.actions {
diff --git a/templates/comment/only-comment.html.twig b/templates/comment/only-comment.html.twig
index 6913451..112f309 100644
--- a/templates/comment/only-comment.html.twig
+++ b/templates/comment/only-comment.html.twig
@@ -118,7 +118,7 @@
data-action="{{ path('comment.delete',{'comment': comment.id} ) }}"
class="deleteForm">
- Suprimer
diff --git a/templates/notification/index.html.twig b/templates/notification/index.html.twig
index 0ffec24..0e94824 100644
--- a/templates/notification/index.html.twig
+++ b/templates/notification/index.html.twig
@@ -132,7 +132,14 @@
{% endif %}
-
+ {% if notif.byUser.image == "false" %}
+
+ {% else %}
+
+
+
+ {% endif %}
+
{% else %}
{% if notif.byPost is not null %}
diff --git a/templates/posts/only-post.html.twig b/templates/posts/only-post.html.twig
index f8c8186..d94439e 100644
--- a/templates/posts/only-post.html.twig
+++ b/templates/posts/only-post.html.twig
@@ -132,7 +132,7 @@
data-action="{{ path('post.delete',{'post': post.id} ) }}"
class="deleteForm">
- Suprimer
diff --git a/templates/search/index.html.twig b/templates/search/index.html.twig
index 95565d8..f3dc32a 100644
--- a/templates/search/index.html.twig
+++ b/templates/search/index.html.twig
@@ -93,30 +93,28 @@
//we need to check if the value is the same
if (value == $(that).val()) {
var result = JSON.parse(msg);
- // console.log(result.list.posts);
+ // console.log(result.list.posts);
$.each(result, function (key, arr) {
- if (arr.users.length >0 ) {
+ if (arr.users.length > 0) {
usersSelector.find($('.single-compte').remove());
usersSelector.html(arr.users);
- }else{
+ } else {
usersSelector.text('Aucun résultat');
}
if (arr.posts.length > 0) {
postsSelector.find($('.post-container').remove());
-
- arr.posts.map((x,i)=>{
- console.log( )
- var textBrut = $($(x)[0]).find('.text')[0];
- textBrut.replace(value, ''+value+'');
- var postEntier = $((x)[0]);
- postsSelector.append(x.replace(new RegExp('('+value+')','ig'), '$1'))
+ postsSelector.html('');
+ arr.posts.map((x, i) => {
+ changed = $(x).find('.text')[0].innerText.replace(value, '' + value + '')
+ console.log(changed)
+ return postsSelector.append(x.replace($(x).find('.text')[0].innerText, changed))
})
- // postsSelector.html(arr.posts);
+ //
console.log(value)
- }else{
+ } else {
postsSelector.text('Aucun résultat');
}
@@ -124,7 +122,7 @@
});
}
},
- error:function(msg){
+ error: function (msg) {
}