Bug fix and Improvements (#5113)

Signed-off-by: chBehzad <behzad.chaudury@gmail.com>
This commit is contained in:
ChBehzad 2024-04-08 11:38:58 +05:00 committed by GitHub
parent a3a77eb6b1
commit 8b9fc860a0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 6 additions and 4 deletions

View File

@ -191,7 +191,7 @@
{#if showSend} {#if showSend}
<Button <Button
{loading} {loading}
disabled={(isEmpty && !haveAttachment) || loading} disabled={(isEmpty && !haveAttachment) || (!isEmpty && !content.replace(/<[^>]*>/g, '').trim()) || loading}
icon={iconSend ?? Send} icon={iconSend ?? Send}
iconProps={{ size: buttonSize }} iconProps={{ size: buttonSize }}
kind={kindSend} kind={kindSend}

View File

@ -1824,7 +1824,9 @@
flex-wrap: nowrap; flex-wrap: nowrap;
min-width: 0; min-width: 0;
.ap-icon { .ap-icon {
display: flex;
align-items: center;
color: var(--theme-dark-color); color: var(--theme-dark-color);
height: 100%; height: 100%;
aspect-ratio: 1; aspect-ratio: 1;

View File

@ -48,7 +48,7 @@
loading++ loading++
try { try {
const uuid = await uploadFile(file) const uuid = await uploadFile(file)
client.addCollection(attachment.class.Photo, space, objectId, _class, 'photos', { client.addCollection(attachment.class.Photo, space, objectId, _class, 'attachments', {
name: file.name, name: file.name,
file: uuid, file: uuid,
type: file.type, type: file.type,

View File

@ -9,7 +9,7 @@
async function addCard (event: CustomEvent) { async function addCard (event: CustomEvent) {
const title = event.detail const title = event.detail
if (!title) { if (!title || title.trim().length === 0) {
return return
} }
await onAdd(title, true) await onAdd(title, true)