Skip to content

Commit 9ece08a

Browse files
committed
Merge branch 'master' into fs2
2 parents 01770b6 + 2b81c52 commit 9ece08a

File tree

7 files changed

+47
-37
lines changed

7 files changed

+47
-37
lines changed

src/packages/frontend/chat/chatroom.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,9 @@ export function ChatRoom({
143143
}
144144

145145
function renderFilterRecent() {
146+
if (messages == null || messages.size <= 5) {
147+
return null;
148+
}
146149
return (
147150
<Tooltip title="Only show recent threads.">
148151
<Select
@@ -224,7 +227,7 @@ export function ChatRoom({
224227
}
225228

226229
function render_button_row() {
227-
if (messages == null) {
230+
if (messages == null || messages.size <= 5) {
228231
return null;
229232
}
230233
return (
@@ -235,9 +238,6 @@ export function ChatRoom({
235238
style={{
236239
margin: 0,
237240
width: "100%",
238-
...(messages.size >= 2
239-
? undefined
240-
: { visibility: "hidden", height: 0 }),
241241
}}
242242
/>
243243
{renderFilterRecent()}

src/packages/frontend/chat/side-chat.tsx

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -238,14 +238,8 @@ function AddChatCollab({ addCollab, project_id }) {
238238
}
239239
return (
240240
<div>
241-
You can{" "}
242-
{redux.getProjectsStore().hasLanguageModelEnabled(project_id) && (
243-
<>chat with AI or notify a collaborator by typing @, </>
244-
)}
245-
<A href="https://github.com/sagemathinc/cocalc/discussions">
246-
join a discussion on GitHub
247-
</A>
248-
, and add more collaborators to this project below.
241+
@mention AI or collaborators, add more collaborators below, or{" "}
242+
<A href="https://discord.gg/EugdaJZ8">join the CoCalc Discord.</A>
249243
<AddCollaborators project_id={project_id} autoFocus where="side-chat" />
250244
<div style={{ color: COLORS.GRAY_M }}>
251245
(Collaborators have access to all files in this project.)

src/packages/frontend/collaborators/project-invite-tokens.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -300,7 +300,7 @@ export const ProjectInviteTokens: React.FC<Props> = React.memo(
300300
}
301301

302302
return (
303-
<Card style={{ width: "100%", overflowX: "auto" }}>
303+
<Card style={{ minWidth: "800px", width: "100%", overflow: "auto" }}>
304304
{heading}
305305
<br />
306306
<br />

src/packages/frontend/editors/markdown-input/multimode.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -351,8 +351,8 @@ export default function MultiMarkdownInput({
351351
color: COLORS.GRAY_M,
352352
...(mode == "editor" || hideHelp
353353
? {
354-
position: "absolute",
355-
right: 0,
354+
float: "right",
355+
position: "relative",
356356
zIndex: 1,
357357
}
358358
: { float: "right" }),

src/packages/next/components/landing/social-media-icon-list.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ enum SocialMediaType {
1111
LINKEDIN = "linkedin",
1212
TWITTER = "twitter",
1313
YOUTUBE = "youtube",
14+
DISCORD = "discord",
1415
}
1516

1617
const ICON_MAP: Record<SocialMediaType, IconName> = {
@@ -20,6 +21,7 @@ const ICON_MAP: Record<SocialMediaType, IconName> = {
2021
[SocialMediaType.LINKEDIN]: "linkedin-filled",
2122
[SocialMediaType.TWITTER]: "twitter",
2223
[SocialMediaType.YOUTUBE]: "youtube-filled",
24+
[SocialMediaType.DISCORD]: "discord",
2325
};
2426

2527
export interface SocialMediaIconListProps {

src/packages/next/pages/support/community.tsx

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import { MAX_WIDTH } from "lib/config";
1111
import { Customize } from "lib/customize";
1212
import withCustomize from "lib/with-customize";
1313
import MailingList from "public/info/cocalc-mailing-list.png";
14+
import Discord from "public/info/discord.png";
1415
import { COLORS } from "@cocalc/util/theme";
1516
import Facebook from "public/info/facebook.png";
1617
import GitHubDiscussions from "public/info/github-discussions.png";
@@ -22,6 +23,24 @@ import Twitter from "public/info/twitter.png";
2223
const imageWidth = "300px";
2324

2425
const dataSource = [
26+
{
27+
link: "https://discord.gg/nEHs2GK",
28+
title: (
29+
<>
30+
<b>Chat</b> about CoCalc on Discord
31+
</>
32+
),
33+
logo: "comment",
34+
image: Discord,
35+
imageWidth,
36+
description: (
37+
<>
38+
Visit the{" "}
39+
<A href="https://discord.gg/EugdaJZ8">CoCalc Discord server</A> to chat
40+
with other CoCalc users, ask questions, and give us quick feedback.
41+
</>
42+
),
43+
},
2544
{
2645
link: "https://github.com/sagemathinc/cocalc",
2746
logo: "github",

src/packages/next/pages/support/index.tsx

Lines changed: 17 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -73,39 +73,19 @@ const dataSource = [
7373
</>
7474
),
7575
},
76-
{
77-
link: "/support/chatgpt",
78-
title: "ChatGPT Suppport",
79-
logo: "robot",
80-
hide: (customize) => !customize.openaiEnabled || !customize.onCoCalcCom,
81-
description: (
82-
<>
83-
Our <A href="/support/chatgpt">integrated ChatGPT support</A> is free
84-
and often very helpful since it knows so much about the open source
85-
software in CoCalc.
86-
<ChatGPTHelp
87-
style={{ marginTop: "15px" }}
88-
size="large"
89-
tag="support-index"
90-
/>
91-
</>
92-
),
93-
},
9476
{
9577
link: "/support/community",
9678
title: "CoCalc Community Support",
9779
logo: "users",
9880
description: (
9981
<>
100-
<A href="https://github.com/sagemathinc/cocalc/discussions">
101-
Join a discussion
102-
</A>{" "}
103-
or{" "}
82+
<A href="https://discord.gg/EugdaJZ8">Join our Discord server</A> or{" "}
10483
<A href="https://groups.google.com/forum/?fromgroups#!forum/cocalc">
10584
post to the mailing list.{" "}
10685
</A>
10786
<SocialMediaIconList
10887
links={{
88+
discord: "https://discord.gg/EugdaJZ8",
10989
facebook: "https://www.facebook.com/CoCalcOnline",
11090
github: "https://github.com/sagemathinc/cocalc",
11191
linkedin: "https://www.linkedin.com/company/sagemath-inc./",
@@ -117,6 +97,21 @@ const dataSource = [
11797
</>
11898
),
11999
},
100+
{
101+
link: "/support/chatgpt",
102+
title: "ChatGPT",
103+
logo: "robot",
104+
hide: (customize) => !customize.openaiEnabled || !customize.onCoCalcCom,
105+
description: (
106+
<>
107+
<ChatGPTHelp
108+
style={{ marginTop: "15px" }}
109+
size="large"
110+
tag="support-index"
111+
/>
112+
</>
113+
),
114+
},
120115
{
121116
landingPages: true,
122117
link: ({ supportVideoCall }: CustomizeType) => supportVideoCall,

0 commit comments

Comments
 (0)