merge devel
This commit is contained in:
+1
-1
@@ -993,7 +993,7 @@
|
||||
},
|
||||
"search_placeholder": {
|
||||
"translation": "Liste: email:lisa@beispiel.de, tel:17025550003...",
|
||||
"defaultMessage": "List like email:alice@example.com, tel:17025550003...",
|
||||
"defaultMessage": "List like alice@example.com, +17025550003...",
|
||||
"description": "Placeholder in contacts search field",
|
||||
"missing": false,
|
||||
"obsolete": false
|
||||
|
||||
+1
-1
@@ -1000,7 +1000,7 @@
|
||||
},
|
||||
"search_placeholder": {
|
||||
"translation": "List like email:alice@example.com, tel:17025550003...",
|
||||
"defaultMessage": "List like email:alice@example.com, tel:17025550003...",
|
||||
"defaultMessage": "List like alice@example.com, +17025550003...",
|
||||
"description": "Placeholder in contacts search field",
|
||||
"missing": false,
|
||||
"obsolete": false
|
||||
|
||||
+1
-1
@@ -993,7 +993,7 @@
|
||||
},
|
||||
"search_placeholder": {
|
||||
"translation": "Ej. email:alice@example.com, tel:17025550003...",
|
||||
"defaultMessage": "List like email:alice@example.com, tel:17025550003...",
|
||||
"defaultMessage": "List like alice@example.com, +17025550003...",
|
||||
"description": "Placeholder in contacts search field",
|
||||
"missing": false,
|
||||
"obsolete": false
|
||||
|
||||
@@ -805,7 +805,7 @@
|
||||
"description": "Text shown in contacts view when query returned no results."
|
||||
},
|
||||
"search_placeholder": {
|
||||
"defaultMessage": "List like email:alice@example.com, tel:17025550003...",
|
||||
"defaultMessage": "List like alice@example.com, +17025550003...",
|
||||
"description": "Placeholder in contacts search field"
|
||||
},
|
||||
"sidepanel_title_acc_notifications": {
|
||||
|
||||
+1
-1
@@ -1000,7 +1000,7 @@
|
||||
},
|
||||
"search_placeholder": {
|
||||
"translation": "Liste comme email:alice@exemple.com, tel:17025550003...",
|
||||
"defaultMessage": "List like email:alice@example.com, tel:17025550003...",
|
||||
"defaultMessage": "List like alice@example.com, +17025550003...",
|
||||
"description": "Placeholder in contacts search field",
|
||||
"missing": false,
|
||||
"obsolete": false
|
||||
|
||||
+1
-1
@@ -993,7 +993,7 @@
|
||||
},
|
||||
"search_placeholder": {
|
||||
"translation": "email:alice@example.com,tel:17025550003...와같은목록",
|
||||
"defaultMessage": "List like email:alice@example.com, tel:17025550003...",
|
||||
"defaultMessage": "List like alice@example.com, +17025550003...",
|
||||
"description": "Placeholder in contacts search field",
|
||||
"missing": false,
|
||||
"obsolete": false
|
||||
|
||||
+1
-1
@@ -993,7 +993,7 @@
|
||||
},
|
||||
"search_placeholder": {
|
||||
"translation": "Caută după e-mail sau număr telefon...",
|
||||
"defaultMessage": "List like email:alice@example.com, tel:17025550003...",
|
||||
"defaultMessage": "List like alice@example.com, +17025550003...",
|
||||
"description": "Placeholder in contacts search field",
|
||||
"missing": false,
|
||||
"obsolete": false
|
||||
|
||||
+1
-1
@@ -993,7 +993,7 @@
|
||||
},
|
||||
"search_placeholder": {
|
||||
"translation": "Список, напр. email:alice@example.com, tel:+17025550003...",
|
||||
"defaultMessage": "List like email:alice@example.com, tel:17025550003...",
|
||||
"defaultMessage": "List like alice@example.com, +17025550003...",
|
||||
"description": "Placeholder in contacts search field",
|
||||
"missing": false,
|
||||
"obsolete": false
|
||||
|
||||
+1
-1
@@ -993,7 +993,7 @@
|
||||
},
|
||||
"search_placeholder": {
|
||||
"translation": "例如 email:alice@example.com, tel:17025550003... 的清單",
|
||||
"defaultMessage": "List like email:alice@example.com, tel:17025550003...",
|
||||
"defaultMessage": "List like alice@example.com, +17025550003...",
|
||||
"description": "Placeholder in contacts search field",
|
||||
"missing": false,
|
||||
"obsolete": false
|
||||
|
||||
+1
-1
@@ -993,7 +993,7 @@
|
||||
},
|
||||
"search_placeholder": {
|
||||
"translation": "列表如 email:alice@example.com, tel:+17025550003...",
|
||||
"defaultMessage": "List like email:alice@example.com, tel:17025550003...",
|
||||
"defaultMessage": "List like alice@example.com, +17025550003...",
|
||||
"description": "Placeholder in contacts search field",
|
||||
"missing": false,
|
||||
"obsolete": false
|
||||
|
||||
+19
-11
@@ -109,6 +109,7 @@ class MessagesView extends React.Component {
|
||||
|
||||
this.state = MessagesView.getDerivedStateFromProps(props, {});
|
||||
|
||||
this.componentSetup = this.componentSetup.bind(this);
|
||||
this.leave = this.leave.bind(this);
|
||||
this.sendMessage = this.sendMessage.bind(this);
|
||||
this.retrySend = this.retrySend.bind(this);
|
||||
@@ -188,6 +189,8 @@ class MessagesView extends React.Component {
|
||||
|
||||
// Drag and drop events
|
||||
this.mountDnDEvents(this.dndRef);
|
||||
|
||||
this.componentSetup({}, {});
|
||||
}
|
||||
|
||||
componentWillUnmount() {
|
||||
@@ -208,9 +211,9 @@ class MessagesView extends React.Component {
|
||||
}
|
||||
}
|
||||
|
||||
// Scroll last message into view on component update e.g. on message received
|
||||
// or vertical shrinking.
|
||||
componentDidUpdate(prevProps, prevState) {
|
||||
// Scroll last message into view on component update e.g. on message received
|
||||
// or vertical shrinking.
|
||||
if (this.messagesScroller &&
|
||||
(prevState.topic != this.state.topic || prevState.maxSeqId != this.state.maxSeqId ||
|
||||
prevState.minSeqId != this.state.minSeqId)) {
|
||||
@@ -221,6 +224,18 @@ class MessagesView extends React.Component {
|
||||
}
|
||||
}
|
||||
|
||||
if (!this.props.applicationVisible) {
|
||||
// If application is not visible, flush all unsent 'read' notifications.
|
||||
this.clearNotificationQueue();
|
||||
} else {
|
||||
// Otherwise assume there are unread messages.
|
||||
this.postReadNotification(0);
|
||||
}
|
||||
|
||||
this.componentSetup(prevProps, prevState);
|
||||
}
|
||||
|
||||
componentSetup(prevProps, prevState) {
|
||||
const topic = this.props.tinode ? this.props.tinode.getTopic(this.state.topic) : undefined;
|
||||
if (this.state.topic != prevState.topic) {
|
||||
if (prevState.topic && !Tinode.isNewGroupTopicName(prevState.topic)) {
|
||||
@@ -241,18 +256,11 @@ class MessagesView extends React.Component {
|
||||
}
|
||||
}
|
||||
|
||||
if (!this.props.applicationVisible) {
|
||||
// If application is not visible, flush all unsent 'read' notifications.
|
||||
this.clearNotificationQueue();
|
||||
} else {
|
||||
// Otherwise assume there are unread messages.
|
||||
this.postReadNotification(0);
|
||||
}
|
||||
|
||||
if (topic) {
|
||||
if ((this.state.topic != prevState.topic) || !prevProps.ready) {
|
||||
// Don't immediately subscribe to a new p2p topic, wait for the first message.
|
||||
if (topic._new && topic.isP2PType()) {
|
||||
const newTopic = (this.props.newTopicParams && this.props.newTopicParams._topicName == this.props.topic);
|
||||
if (topic.isP2PType() && newTopic) {
|
||||
topic.getMeta(topic.startMetaQuery().withDesc().build());
|
||||
} else {
|
||||
this.subscribe(topic);
|
||||
|
||||
@@ -25,7 +25,7 @@ const messages = defineMessages({
|
||||
},
|
||||
search_placeholder: {
|
||||
id: "search_placeholder",
|
||||
defaultMessage: "List like email:alice@example.com, tel:17025550003...",
|
||||
defaultMessage: "List like alice@example.com, +17025550003...",
|
||||
description: "Placeholder in contacts search field"
|
||||
},
|
||||
});
|
||||
@@ -61,10 +61,10 @@ class NewTopicView extends React.Component {
|
||||
this.setState({searchQuery: Tinode.isNullValue(query) ? null : query});
|
||||
}
|
||||
|
||||
handleSearchResultSelected(name) {
|
||||
handleSearchResultSelected(topicName) {
|
||||
if (this.state.tabSelected == 'find') {
|
||||
HashNavigation.navigateTo(HashNavigation.removeUrlParam(window.location.hash, 'tab'));
|
||||
this.props.onCreateTopic(name);
|
||||
this.props.onCreateTopic(topicName);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1334,7 +1334,7 @@ class TinodeWeb extends React.Component {
|
||||
|
||||
const params = {};
|
||||
if (Tinode.isP2PTopicName(topicName)) {
|
||||
// Because we are initialing the subscription, set 'want' to all permissions.
|
||||
// Because we are initiating the subscription, set 'want' to all permissions.
|
||||
params.sub = {mode: DEFAULT_P2P_ACCESS_MODE};
|
||||
// Give the other user all permissions too.
|
||||
params.desc = {defacs: {auth: DEFAULT_P2P_ACCESS_MODE}};
|
||||
|
||||
Reference in New Issue
Block a user