From 521b6f15ec87cd48391cd8923dc2f725b25a616d Mon Sep 17 00:00:00 2001 From: bernborgess Date: Thu, 2 Apr 2026 01:04:17 -0300 Subject: [PATCH 1/4] fix: Chats.css must be uppercase (in linux) --- src/css/chat/{chats.css => Chats.css} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename src/css/chat/{chats.css => Chats.css} (100%) diff --git a/src/css/chat/chats.css b/src/css/chat/Chats.css similarity index 100% rename from src/css/chat/chats.css rename to src/css/chat/Chats.css From 01de4b239ea60132c19228b7ebbb8d0f819ed7d2 Mon Sep 17 00:00:00 2001 From: duckietm Date: Fri, 3 Apr 2026 08:02:19 +0200 Subject: [PATCH 2/4] =?UTF-8?q?=F0=9F=86=99=20Fix=20Scrollbar=20old=20view?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/catalog/CatalogClassicView.tsx | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/components/catalog/CatalogClassicView.tsx b/src/components/catalog/CatalogClassicView.tsx index a5fabd4..e4203af 100644 --- a/src/components/catalog/CatalogClassicView.tsx +++ b/src/components/catalog/CatalogClassicView.tsx @@ -83,7 +83,6 @@ const CatalogClassicViewInner: FC<{}> = () => { isVisible && setIsVisible(false) } /> - { /* Admin banner */ } { adminMode &&
⚙ Admin Mode @@ -128,14 +127,12 @@ const CatalogClassicViewInner: FC<{}> = () => ); }) } - { /* Admin toggle button in tabs bar */ } { isMod && setAdminMode(!adminMode) }> } - { /* Admin: add new root category */ } { adminMode && rootNode &&
} { !navigationHidden && - + { activeNodes && (activeNodes.length > 0) && } } From 19b7d7d9d90e23634e8183b2572ae5126459354d Mon Sep 17 00:00:00 2001 From: duckietm Date: Fri, 3 Apr 2026 10:48:34 +0200 Subject: [PATCH 3/4] =?UTF-8?q?=F0=9F=86=99=20=20more=20optimization=20mem?= =?UTF-8?q?.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/room/widgets/ChatBubbleUtilities.ts | 24 ++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) diff --git a/src/api/room/widgets/ChatBubbleUtilities.ts b/src/api/room/widgets/ChatBubbleUtilities.ts index 2f6d54c..bbfbc5b 100644 --- a/src/api/room/widgets/ChatBubbleUtilities.ts +++ b/src/api/room/widgets/ChatBubbleUtilities.ts @@ -2,6 +2,8 @@ import { AvatarFigurePartType, AvatarScaleType, AvatarSetType, GetAvatarRenderMa export class ChatBubbleUtilities { + private static MAX_CACHE_SIZE: number = 200; + public static AVATAR_COLOR_CACHE: Map = new Map(); public static AVATAR_IMAGE_CACHE: Map = new Map(); public static PET_IMAGE_CACHE: Map = new Map(); @@ -9,6 +11,19 @@ export class ChatBubbleUtilities private static placeHolderImageUrl: string = ''; + private static pruneCache(cache: Map, maxSize: number = ChatBubbleUtilities.MAX_CACHE_SIZE): void + { + if(cache.size <= maxSize) return; + + const deleteCount = cache.size - maxSize; + const iterator = cache.keys(); + + for(let i = 0; i < deleteCount; i++) + { + cache.delete(iterator.next().value as string); + } + } + public static async setFigureImage(figure: string): Promise { const avatarImage = GetAvatarRenderManager().createAvatarImage(figure, AvatarScaleType.LARGE, null, { @@ -34,6 +49,9 @@ export class ChatBubbleUtilities this.AVATAR_COLOR_CACHE.set(figure, ((color && color.rgb) || 16777215)); this.AVATAR_IMAGE_CACHE.set(figure, imageUrl); + this.pruneCache(this.AVATAR_COLOR_CACHE); + this.pruneCache(this.AVATAR_IMAGE_CACHE); + avatarImage.dispose(); return imageUrl; @@ -100,7 +118,11 @@ export class ChatBubbleUtilities if(!resolvedImage) resolvedImage = await getImageUrl(imageResult); - if(resolvedImage) this.PET_IMAGE_CACHE.set(cacheKey, resolvedImage); + if(resolvedImage) + { + this.PET_IMAGE_CACHE.set(cacheKey, resolvedImage); + this.pruneCache(this.PET_IMAGE_CACHE); + } return resolvedImage; })(); From 9df5663103bc43c699f8ff4696502fa38f873a92 Mon Sep 17 00:00:00 2001 From: duckietm Date: Fri, 3 Apr 2026 11:43:04 +0200 Subject: [PATCH 4/4] =?UTF-8?q?=F0=9F=86=99=20Sync?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/catalog/CatalogClassicView.tsx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/components/catalog/CatalogClassicView.tsx b/src/components/catalog/CatalogClassicView.tsx index e4203af..e86b384 100644 --- a/src/components/catalog/CatalogClassicView.tsx +++ b/src/components/catalog/CatalogClassicView.tsx @@ -83,6 +83,7 @@ const CatalogClassicViewInner: FC<{}> = () => { isVisible && setIsVisible(false) } /> + { /* Admin banner */ } { adminMode &&
⚙ Admin Mode @@ -127,12 +128,14 @@ const CatalogClassicViewInner: FC<{}> = () => ); }) } + { /* Admin toggle button in tabs bar */ } { isMod && setAdminMode(!adminMode) }> } + { /* Admin: add new root category */ } { adminMode && rootNode &&
} { !navigationHidden && - + { activeNodes && (activeNodes.length > 0) && } }