A fully open source & end-to-end encrypted note taking alternative to Evernote.
TypeScript asp-net-coredotnet-coreelectronfosshacktoberfestnote-managmentnote-takingnote-taking-appnotebooknotesnotes-appopen-sourceopensourceprivacyproductivityreactreact-nativereactjsself-hosted
web: show tags in readonly mode
Abdullah Atta4627a58a5274
diff --git a/apps/web/src/components/editor/header.tsx b/apps/web/src/components/editor/header.tsxindex 0ec0bd1a6..71cb4bc04 100644--- a/apps/web/src/components/editor/header.tsx+++ b/apps/web/src/components/editor/header.tsx@@ -39,7 +39,7 @@ function Header(props: HeaderProps) {return (<>- {!readonly && id && (+ {id && (<Flexsx={{ lineHeight: 2.5, alignItems: "center", flexWrap: "wrap" }}data-test-id="tags"@@ -55,19 +55,21 @@ function Header(props: HeaderProps) {styles={{ container: { mr: 1 }, text: { fontSize: "body" } }}/>))}- <Autosuggest- sessionId={id}- filter={(query) =>- db.lookup?.tags(filterableTags, query).slice(0, 10) || []- }- onAdd={(value) => setTag(value)}- onSelect={(item) => setTag(item.title)}- onRemove={() => {- if (tags.length <= 0) return;- setTag(tags[tags.length - 1]);- }}- defaultItems={filterableTags?.slice(0, 10) || []}- />+ {!readonly && (+ <Autosuggest+ sessionId={id}+ filter={(query) =>+ db.lookup?.tags(filterableTags, query).slice(0, 10) || []+ }+ onAdd={(value) => setTag(value)}+ onSelect={(item) => setTag(item.title)}+ onRemove={() => {+ if (tags.length <= 0) return;+ setTag(tags[tags.length - 1]);+ }}+ defaultItems={filterableTags?.slice(0, 10) || []}+ />+ )}</Flex>)}</>