From e53c9b4fa1fe80dcdfc2a7e9d5187e61416c3f09 Mon Sep 17 00:00:00 2001 From: Shusui MOYATANI Date: Wed, 29 May 2024 02:20:06 +0900 Subject: [PATCH] style: fix --- src/components/EmojiDisplay.tsx | 4 ++-- src/components/NotePostForm.tsx | 2 +- src/components/event/textNote/TextNoteContentDisplay.tsx | 2 +- src/components/utils/Copy.tsx | 2 +- src/hooks/useEmojiComplete.tsx | 2 +- src/nostr/parseTextNote.ts | 2 +- src/pages/Hello.tsx | 2 +- src/pages/NotFound.tsx | 2 +- 8 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/components/EmojiDisplay.tsx b/src/components/EmojiDisplay.tsx index e5e8e4f..257419a 100644 --- a/src/components/EmojiDisplay.tsx +++ b/src/components/EmojiDisplay.tsx @@ -13,7 +13,7 @@ const isPlus = (r: ReactionTypes) => r.type === 'LikeDislike' && r.content === ' const EmojiDisplay: Component = (props) => ( {props.reactionTypes.content}}> - + @@ -21,7 +21,7 @@ const EmojiDisplay: Component = (props) => ( {({ content }) => {content}} - {({ shortcode, url }) => {`:${shortcode}:`}} + {({ shortcode, url }) => {`:${shortcode}:`}} ); diff --git a/src/components/NotePostForm.tsx b/src/components/NotePostForm.tsx index edf47d9..beb1146 100644 --- a/src/components/NotePostForm.tsx +++ b/src/components/NotePostForm.tsx @@ -384,7 +384,7 @@ const NotePostForm: Component = (props) => { emojiTextAreaRef(el); }} name="text" - class="scrollbar max-h-[40vh] min-h-[4rem] overflow-y-auto rounded-md border border-border bg-bg ring-border placeholder:text-fg-secondary focus:border-border focus:ring-primary" + class="scrollbar max-h-[40vh] min-h-16 overflow-y-auto rounded-md border border-border bg-bg ring-border placeholder:text-fg-secondary focus:border-border focus:ring-primary" rows={4} placeholder={placeholder(mode())} onInput={handleInput} diff --git a/src/components/event/textNote/TextNoteContentDisplay.tsx b/src/components/event/textNote/TextNoteContentDisplay.tsx index ee5003b..9875f2d 100644 --- a/src/components/event/textNote/TextNoteContentDisplay.tsx +++ b/src/components/event/textNote/TextNoteContentDisplay.tsx @@ -131,7 +131,7 @@ const TextNoteContentDisplay = (props: TextNoteContentDisplayProps) => { // const { imageRef, canvas } = useImageAnimation({ initialPlaying: false }); return ( {item.content} = (props) => { -
+
Copied!
diff --git a/src/hooks/useEmojiComplete.tsx b/src/hooks/useEmojiComplete.tsx index b5090f1..3bae201 100644 --- a/src/hooks/useEmojiComplete.tsx +++ b/src/hooks/useEmojiComplete.tsx @@ -27,7 +27,7 @@ const useEmojiComplete = () => { template: (config: CustomEmojiConfig) => { const e = (
- {config.shortcode} + {config.shortcode}
{config.shortcode}
) as HTMLElement; diff --git a/src/nostr/parseTextNote.ts b/src/nostr/parseTextNote.ts index b9ee616..924ce14 100644 --- a/src/nostr/parseTextNote.ts +++ b/src/nostr/parseTextNote.ts @@ -101,7 +101,7 @@ const parseTextNote = (textNoteContent: string) => { ...textNoteContent.matchAll(mentionRegex), ...textNoteContent.matchAll(hashTagRegex), ...textNoteContent.matchAll(customEmojiRegex), - ].sort((a, b) => (a.index as number) - (b.index as number)); + ].sort((a, b) => a.index - b.index); let pos = 0; const result: ParsedTextNote = []; diff --git a/src/pages/Hello.tsx b/src/pages/Hello.tsx index 694bfa0..7d28615 100644 --- a/src/pages/Hello.tsx +++ b/src/pages/Hello.tsx @@ -51,7 +51,7 @@ const Hello: Component = () => { }); return ( -
+
logo

Rabbit

diff --git a/src/pages/NotFound.tsx b/src/pages/NotFound.tsx index 1bc7308..e11b2cc 100644 --- a/src/pages/NotFound.tsx +++ b/src/pages/NotFound.tsx @@ -6,7 +6,7 @@ const NotFound: Component = () => { const i18n = useTranslation(); return ( -
+

{i18n.t('notFound.title')}