From 80e89a24b690afa78492f73b6e6fd5607150b703 Mon Sep 17 00:00:00 2001 From: Dessalines Date: Wed, 11 Sep 2019 17:20:57 -0700 Subject: [PATCH] Fixing tribute positioning issue, moving recent comments to top. --- ui/package.json | 2 +- ui/src/components/comment-form.tsx | 10 +- ui/src/components/post.tsx | 4 +- ui/src/css/main.css | 2 +- ui/src/css/tribute.css | 4 + ui/yarn.lock | 660 +++-------------------------- 6 files changed, 77 insertions(+), 605 deletions(-) diff --git a/ui/package.json b/ui/package.json index 338893dd5..5a2239a79 100644 --- a/ui/package.json +++ b/ui/package.json @@ -36,7 +36,7 @@ "moment": "^2.24.0", "rxjs": "^6.4.0", "terser": "^3.17.0", - "tributejs": "^3.7.2", + "tributejs": "^3.7.3", "twemoji": "^12.1.2", "ws": "^7.0.0" }, diff --git a/ui/src/components/comment-form.tsx b/ui/src/components/comment-form.tsx index 5b60aced5..5baec7258 100644 --- a/ui/src/components/comment-form.tsx +++ b/ui/src/components/comment-form.tsx @@ -6,7 +6,7 @@ import { WebSocketService, UserService } from '../services'; import * as autosize from 'autosize'; import { i18n } from '../i18next'; import { T } from 'inferno-i18next'; -import Tribute from 'tributejs/src/Tribute.js'; +import * as Tribute from 'tributejs'; import * as emojiShortName from 'emoji-short-name'; interface CommentFormProps { @@ -60,7 +60,7 @@ export class CommentForm extends Component { values: Object.entries(emojiShortName).map(e => {return {'key': e[1], 'val': e[0]}}), allowSpaces: false, autocompleteMode: true, - menuItemLimit: 10, + menuItemLimit: mentionDropdownFetchLimit, }, // Users { @@ -73,7 +73,7 @@ export class CommentForm extends Component { }, allowSpaces: false, autocompleteMode: true, - menuItemLimit: 10, + menuItemLimit: mentionDropdownFetchLimit, }, // Communities @@ -87,7 +87,7 @@ export class CommentForm extends Component { }, allowSpaces: false, autocompleteMode: true, - menuItemLimit: 10, + menuItemLimit: mentionDropdownFetchLimit, } ] }); @@ -123,7 +123,7 @@ export class CommentForm extends Component {
-
+