Merge branch 'matilde/chat-feedback' (#2027)

* matilde/chat-feedback:
  chat: Fix chat join link - %ask-history error
  chat: join channel on enter
  chat: wrap long links, join button uses pointer

Signed-off-by: Jared Tobin <jared@tlon.io>
This commit is contained in:
Jared Tobin 2019-12-06 12:10:55 +08:00
commit 4251b13d0e
No known key found for this signature in database
GPG Key ID: 0E4647D58F8A69E4
6 changed files with 16 additions and 7 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -95,6 +95,10 @@ h2 {
cursor: default;
}
.word-break-all {
word-break: break-all;
}
/* responsive */
@media all and (max-width: 34.375em) {

View File

@ -30,7 +30,7 @@ export class JoinScreen extends Component {
});
return;
}
this.props.api.chatView.join(ship, station);
this.props.api.chatView.join(ship, station, true);
this.props.history.push('/~chat');
}
}
@ -80,9 +80,9 @@ export class JoinScreen extends Component {
render() {
const { props } = this;
let joinClasses = "db f9 green2 ba pa2 b--green2";
let joinClasses = "db f9 green2 ba pa2 b--green2 pointer";
if ((!this.state.station) || (this.state.station === "/")) {
joinClasses = 'db f9 gray2 ba pa2 b--gray3';
joinClasses = 'db f9 gray2 ba pa2 b--gray3 pointer';
}
let errElem = (<span />);
@ -110,6 +110,11 @@ export class JoinScreen extends Component {
placeholder="~zod/chatroom"
spellCheck="false"
rows={1}
onKeyPress={e => {
if (e.key === "Enter") {
this.onClickJoin();
}
}}
style={{
resize: 'none',
}}

View File

@ -47,7 +47,7 @@ export class Message extends Component {
);
}
return (
<a className="f7 lh-copy v-top bb b--black"
<a className="f7 lh-copy v-top bb b--black word-break-all"
href={letter.url}
target="_blank"
rel="noopener noreferrer">