Skip to content

Commit cd2a94c

Browse files
Jack Coweycursoragent
andcommitted
Prepare release 0.1.12
Co-authored-by: Cursor <cursoragent@cursor.com>
1 parent e053305 commit cd2a94c

File tree

4 files changed

+26
-3
lines changed

4 files changed

+26
-3
lines changed

components/irc/message-area.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -376,7 +376,7 @@ export function MessageArea() {
376376
const messages = isServerConsole ? (server?.serverMessages || []) : (channel?.messages || [])
377377

378378
useEffect(() => {
379-
bottomRef.current?.scrollIntoView({ behavior: "smooth" })
379+
bottomRef.current?.scrollIntoView({ behavior: "auto" })
380380
}, [messages.length])
381381

382382
if (!server) {

lib/store.ts

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1073,6 +1073,11 @@ export const useIRCStore = create<IRCStore>((set, get) => ({
10731073
if (!isLiveBuild || nativeBridgeInitialized) return
10741074
nativeBridgeInitialized = true
10751075

1076+
// State for high-volume LIST output to avoid freezing the UI
1077+
let currentListCount = 0
1078+
let listTruncated = false
1079+
const MAX_LIST_ITEMS = 400
1080+
10761081
void listenNativeIrcEvents((event) => {
10771082
const state = get()
10781083
const server = state.servers.find((s) => s.id === event.server_id)
@@ -1227,6 +1232,8 @@ export const useIRCStore = create<IRCStore>((set, get) => ({
12271232
if (event.content) get().addServerMessage(event.server_id, event.content)
12281233
break
12291234
case 'list_start': {
1235+
currentListCount = 0
1236+
listTruncated = false
12301237
const active = get().activeView
12311238
const channelId = active.channelId
12321239
const serverId = active.serverId || event.server_id
@@ -1239,6 +1246,22 @@ export const useIRCStore = create<IRCStore>((set, get) => ({
12391246
break
12401247
}
12411248
case 'list_item': {
1249+
if (listTruncated) break
1250+
if (currentListCount >= MAX_LIST_ITEMS) {
1251+
listTruncated = true
1252+
const active = get().activeView
1253+
const channelId = active.channelId
1254+
const serverId = active.serverId || event.server_id
1255+
if (!serverId) break
1256+
const notice = `Channel list truncated after ${MAX_LIST_ITEMS} entries (too many results)`
1257+
if (channelId) {
1258+
get().addSystemMessage(serverId, channelId, notice)
1259+
} else {
1260+
get().addServerMessage(serverId, notice)
1261+
}
1262+
break
1263+
}
1264+
currentListCount++
12421265
const active = get().activeView
12431266
const channelId = active.channelId
12441267
const serverId = active.serverId || event.server_id

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "my-project",
3-
"version": "0.1.11",
3+
"version": "0.1.12",
44
"private": true,
55
"scripts": {
66
"dev": "next dev --turbo",

src-tauri/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "patchcord-desktop"
3-
version = "0.1.11"
3+
version = "0.1.12"
44
description = "Patchcord desktop app"
55
authors = ["Patchcord"]
66
license = ""

0 commit comments

Comments
 (0)