1
0
Fork 0
mirror of https://github.com/anyproto/anytype-ts.git synced 2025-06-07 21:47:02 +09:00

JS-7034: fix

This commit is contained in:
Andrew Simachev 2025-05-19 10:30:10 +02:00
parent 7a59bb69f4
commit 165dc920dc
No known key found for this signature in database
GPG key ID: 1DFE44B21443F0EF
2 changed files with 16 additions and 11 deletions

View file

@ -238,9 +238,7 @@ const Create = observer(class Create extends React.Component<I.PageComponent, St
return;
};
U.Object.getById(collection, {}, object => {
console.log('Collection', collection, object);
});
U.Object.getById(collection, {}, object => this.setState({ collection: object }));
};
initName () {

View file

@ -260,11 +260,19 @@ const ChatMessage = observer(class ChatMessage extends React.Component<I.ChatMes
const { account } = S.Auth;
const isSelf = creator == account.id;
const readonly = this.props.readonly || !isSelf;
const node = $(this.node);
const et = node.find('.bubbleOuter .text');
const er = node.find('.reply .text');
renderMentions(rootId, this.node, marks, () => text, { subId });
renderObjects(rootId, this.node, marks, () => text, { readonly }, { subId });
renderLinks(rootId, this.node, marks, () => text, { readonly }, { subId });
renderEmoji(this.node);
renderMentions(rootId, et, marks, () => text, { subId });
renderObjects(rootId, et, marks, () => text, { readonly }, { subId });
renderLinks(rootId, et, marks, () => text, { readonly }, { subId });
renderEmoji(et);
renderMentions(rootId, er, marks, () => text, { subId, iconSize: 16 });
renderObjects(rootId, er, marks, () => text, { readonly }, { subId, iconSize: 16 });
renderLinks(rootId, er, marks, () => text, { readonly }, { subId, iconSize: 16 });
renderEmoji(er, { iconSize: 16 });
this.checkLinesLimit();
};
@ -414,11 +422,10 @@ const ChatMessage = observer(class ChatMessage extends React.Component<I.ChatMes
};
highlight () {
$(this.node).addClass('highlight');
const node = $(this.node);
window.setTimeout(() => {
$(this.node).removeClass('highlight');
}, J.Constant.delay.highlight);
node.addClass('highlight');
window.setTimeout(() => node.removeClass('highlight'), J.Constant.delay.highlight);
};
});