2025-09-26 23:21:41 +03:00
import { ComponentChildren } from 'preact' ;
2025-09-26 23:06:57 +03:00
import Card from '../../components/Card' ;
import Section from '../../components/Section' ;
2025-09-26 23:28:58 +03:00
import DownloadButton from '../../components/DownloadButton' ;
2025-09-26 23:32:09 +03:00
import "./index.css" ;
2025-09-27 14:39:32 +03:00
import { useColorScheme , usePageTitle } from '../../hooks' ;
2025-09-27 15:38:01 +03:00
import Button , { Link } from '../../components/Button' ;
2025-09-27 14:15:08 +03:00
import gitHubIcon from "../../assets/boxicons/bx-github.svg?raw" ;
import dockerIcon from "../../assets/boxicons/bx-docker.svg?raw" ;
2025-09-27 18:40:00 +03:00
import noteStructureIcon from "../../assets/boxicons/bx-folder.svg?raw" ;
import attributesIcon from "../../assets/boxicons/bx-tag.svg?raw" ;
import hoistingIcon from "../../assets/boxicons/bx-chevrons-up.svg?raw" ;
import revisionsIcon from "../../assets/boxicons/bx-history.svg?raw" ;
import syncIcon from "../../assets/boxicons/bx-refresh-cw.svg?raw" ;
import protectedNotesIcon from "../../assets/boxicons/bx-shield.svg?raw" ;
import jumpToIcon from "../../assets/boxicons/bx-send-alt.svg?raw" ;
import searchIcon from "../../assets/boxicons/bx-search.svg?raw" ;
import webClipperIcon from "../../assets/boxicons/bx-paperclip.svg?raw" ;
import importExportIcon from "../../assets/boxicons/bx-swap-horizontal.svg?raw" ;
import shareIcon from "../../assets/boxicons/bx-globe.svg?raw" ;
2025-09-27 19:20:03 +03:00
import scriptingIcon from "../../assets/boxicons/bx-code.svg?raw" ;
import restApiIcon from "../../assets/boxicons/bx-extension.svg?raw" ;
2025-09-27 14:39:32 +03:00
import { getPlatform } from '../../download-helper' ;
2025-09-27 18:17:20 +03:00
import { useState } from 'preact/hooks' ;
2025-09-26 22:54:56 +03:00
export function Home() {
2025-09-27 13:55:04 +03:00
usePageTitle ( "" ) ;
2025-09-26 22:54:56 +03:00
return (
2025-09-26 23:16:06 +03:00
< >
2025-09-26 23:34:14 +03:00
< HeroSection / >
2025-09-27 19:39:39 +03:00
< OrganizationBenefitsSection / >
< ProductivityBenefitsSection / >
2025-09-26 23:34:14 +03:00
< NoteTypesSection / >
2025-09-27 19:39:39 +03:00
< ExtensibilityBenefitsSection / >
2025-09-26 23:34:14 +03:00
< CollectionsSection / >
< FaqSection / >
2025-09-27 17:56:23 +03:00
< FinalCta / >
2025-09-26 23:34:14 +03:00
< / >
) ;
}
function HeroSection() {
2025-09-27 14:39:32 +03:00
const platform = getPlatform ( ) ;
let screenshotUrl : string ;
const colorScheme = useColorScheme ( ) ;
switch ( platform ) {
case "macos" :
screenshotUrl = ` ./src/assets/screenshot_desktop_mac_ ${ colorScheme } .png ` ;
break ;
case "linux" :
break ;
case "windows" :
default :
2025-09-27 15:01:03 +03:00
screenshotUrl = ` ./src/assets/screenshot_desktop_win_ ${ colorScheme } .png ` ;
2025-09-27 14:39:32 +03:00
break ;
}
2025-09-26 23:34:14 +03:00
return (
< Section className = "hero-section" >
< div class = "title-section" >
< h1 > Organize your thoughts . Build your personal knowledge base . < / h1 >
< p > Trilium is an open - source solution for note - taking and organizing a personal knowledge base . Use it locally on your desktop , or sync it with your self - hosted server to keep your notes everywhere you go . < / p >
2025-09-27 00:08:35 +03:00
< div className = "download-wrapper" >
< DownloadButton big / >
2025-09-27 17:56:23 +03:00
< a class = "more-download-options desktop-only" href = "./get-started/" > More platforms & server setup < / a >
< Button href = "./get-started/" className = "mobile-only" text = "Get started" / >
2025-09-27 14:15:08 +03:00
< div className = "additional-options" >
< Button iconSvg = { gitHubIcon } outline text = "GitHub" href = "https://github.com/TriliumNext/Trilium/" openExternally / >
< Button iconSvg = { dockerIcon } outline text = "Docker Hub" href = "https://hub.docker.com/r/triliumnext/trilium" openExternally / >
< / div >
2025-09-27 00:08:35 +03:00
< / div >
2025-09-27 14:15:08 +03:00
2025-09-26 23:34:14 +03:00
< / div >
2025-09-26 23:24:28 +03:00
2025-09-27 14:39:32 +03:00
{ screenshotUrl && < img class = "screenshot" src = { screenshotUrl } / > }
2025-09-26 23:34:14 +03:00
< / Section >
)
}
2025-09-26 23:24:28 +03:00
2025-09-27 19:39:39 +03:00
function OrganizationBenefitsSection() {
2025-09-26 23:34:14 +03:00
return (
2025-09-27 18:27:15 +03:00
< >
< Section className = "benefits" title = "Organization" >
< div className = "benefits-container grid-3-cols" >
2025-09-27 19:08:39 +03:00
< Card iconSvg = { noteStructureIcon } title = "Note structure" moreInfoUrl = "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Basic%20Concepts%20and%20Features/Notes/index.html" > Notes can be arranged hierarchically . There ' s no need for folders , since each note can contain sub - notes . A single note can be added in multiple places in the hierarchy . < / Card >
2025-09-27 19:20:03 +03:00
< Card iconSvg = { attributesIcon } title = "Note labels and relationships" moreInfoUrl = "https://docs.triliumnotes.org/User Guide/User Guide/Advanced Usage/Attributes/index.html" > Use < em > relations < / em > between notes or add < em > labels < / em > for easy categorization . Use promoted attributes to enter structured information which can be used in tables , boards . < / Card >
2025-09-27 19:08:39 +03:00
< Card iconSvg = { hoistingIcon } title = "Workspaces and hoisting" moreInfoUrl = "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Basic%20Concepts%20and%20Features/Navigation/Note%20Hoisting.html" > Easily separate your personal and work notes by grouping them under a workspace , which focuses your note tree to only show a specific set of notes . < / Card >
2025-09-27 18:27:15 +03:00
< / div >
< / Section >
2025-09-27 19:39:39 +03:00
< / >
) ;
}
2025-09-27 18:27:15 +03:00
2025-09-27 19:39:39 +03:00
function ProductivityBenefitsSection() {
return (
< >
2025-09-27 18:27:15 +03:00
< Section className = "benefits accented" title = "Productivity and safety" >
< div className = "benefits-container grid-3-cols" >
2025-09-27 19:20:03 +03:00
< Card iconSvg = { revisionsIcon } title = "Note revisions" moreInfoUrl = "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Basic%20Concepts%20and%20Features/Notes/Note%20Revisions.html" > Notes are periodically saved in the background and revisions can be used for review or to undo accidental changes . Revisions can also be created on - demand . < / Card >
< Card iconSvg = { syncIcon } title = "Synchronization" moreInfoUrl = "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Installation%20%26%20Setup/Synchronization.html" > Use a self - hosted or cloud instance to easily synchronize your notes across multiple devices , and to access it from your mobile phone using a PWA . < / Card >
2025-09-27 19:08:39 +03:00
< Card iconSvg = { protectedNotesIcon } title = "Protected notes" moreInfoUrl = "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Basic%20Concepts%20and%20Features/Notes/Protected%20Notes.html" > Protect sensitive personal information by encrypting the notes and locking them behind a password - protected session . < / Card >
2025-09-27 19:20:03 +03:00
< Card iconSvg = { jumpToIcon } title = "Quick search and commands" moreInfoUrl = "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Basic%20Concepts%20and%20Features/Navigation/Jump%20to.html" > Jump quickly to notes or UI commands across the hierarchy by searching for their title , with fuzzy matching to account for typos or slight differences . < / Card >
2025-09-27 19:08:39 +03:00
< Card iconSvg = { searchIcon } title = "Powerful search" moreInfoUrl = "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Basic%20Concepts%20and%20Features/Navigation/Search.html" > Or search for text inside notes and narrow down the search by filtering by the parent note , or by depth . < / Card >
< Card iconSvg = { webClipperIcon } title = "Web clipper" moreInfoUrl = "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Installation%20%26%20Setup/Web%20Clipper.html" > Grab web pages ( or screenshots ) and place them directly into Trilium using the web clipper browser extension . < / Card >
2025-09-27 18:27:15 +03:00
< / div >
< / Section >
< / >
2025-09-26 23:34:14 +03:00
) ;
}
2025-09-26 23:16:06 +03:00
2025-09-26 23:34:14 +03:00
function NoteTypesSection() {
return (
2025-09-27 19:39:39 +03:00
< Section className = "note-types" title = "Multiple ways to represent your information" >
2025-09-27 18:59:51 +03:00
< ListWithScreenshot horizontal items = { [
2025-09-27 18:47:45 +03:00
{
title : "Text notes" ,
imageUrl : "./src/assets/type_text.png" ,
moreInfo : "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Note%20Types/Text/index.html" ,
description : "The notes are edited using a visual (WYSIWYG) editor, with support for tables, images, math expressions, code blocks with syntax highlighting. Quickly format the text using Markdown-like syntax or using slash commands."
} ,
{
title : "Code notes" ,
imageUrl : "./src/assets/type_code.png" ,
moreInfo : "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Note%20Types/Code.html" ,
description : "Large samples of source code or scripts use a dedicated editor, with syntax highlighting for many programming languages and with various color themes."
} ,
{
title : "File notes" ,
imageUrl : "./src/assets/type_file.png" ,
moreInfo : "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Note%20Types/File.html" ,
description : "Embed multimedia files such as PDFs, images, videos with an in-application preview."
} ,
{
title : "Canvas" ,
imageUrl : "./src/assets/type_canvas.png" ,
moreInfo : "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Note%20Types/Canvas.html" ,
description : "Arrange shapes, images and text across an infinite canvas, using the same technology behind excalidraw.com. Ideal for diagrams, sketches and visual planning."
} ,
{
title : "Mermaid diagrams" ,
imageUrl : "./src/assets/type_mermaid.png" ,
moreInfo : "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Note%20Types/Mermaid%20Diagrams/index.html" ,
2025-09-27 18:59:51 +03:00
description : "Create diagrams such as flowcharts, class & sequence diagrams, Gantt charts and many more, using the Mermaid syntax."
2025-09-27 18:47:45 +03:00
} ,
{
title : "Mindmap" ,
imageUrl : "./src/assets/type_mindmap.png" ,
moreInfo : "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Note%20Types/Mind%20Map.html" ,
description : "Organize your thoughts visually or do a brainstorming session."
}
] } / >
2025-09-27 15:38:01 +03:00
< p >
and others : { " " }
< Link href = "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Note%20Types/Note%20Map.html" openExternally > note map < / Link > , { " " }
< Link href = "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Note%20Types/Relation%20Map.html" openExternally > relation map < / Link > , { " " }
< Link href = "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Note%20Types/Saved%20Search.html" openExternally > saved searches < / Link > , { " " }
< Link href = "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Note%20Types/Render%20Note.html" openExternally > render note < / Link > , { " " }
< Link href = "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Note%20Types/Web%20View.html" openExternally > web views < / Link > .
< / p >
2025-09-26 23:34:14 +03:00
< / Section >
) ;
}
2025-09-26 23:18:38 +03:00
2025-09-27 19:39:39 +03:00
function ExtensibilityBenefitsSection() {
return (
< >
< Section className = "benefits accented" title = "Sharing & extensibility" >
< div className = "benefits-container grid-4-cols" >
< Card iconSvg = { importExportIcon } title = "Import/export" moreInfoUrl = "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Basic%20Concepts%20and%20Features/Import%20%26%20Export/Markdown/index.html" > Easily interact with other applications using Markdown , ENEX , OML formats . < / Card >
< Card iconSvg = { shareIcon } title = "Share notes on the web" moreInfoUrl = "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Advanced%20Usage/Sharing/Serving%20directly%20the%20content%20o.html" > If you have a server , it can be used to share a subset of your notes with other people . < / Card >
< Card iconSvg = { scriptingIcon } title = "Advanced scripting" moreInfoUrl = "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Scripting/Custom%20Widgets/index.html" > Build your own integrations within Trilium with custom widgets , or server - side logic . < / Card >
< Card iconSvg = { restApiIcon } title = "REST API" moreInfoUrl = "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Advanced%20Usage/ETAPI%20%28REST%20API%29/index.html" > Interact with Trilium programatically using its builtin REST API . < / Card >
< / div >
< / Section >
< / >
) ;
}
2025-09-26 23:34:14 +03:00
function CollectionsSection() {
return (
< Section className = "collections" title = "Collections" >
2025-09-27 18:17:20 +03:00
< ListWithScreenshot items = { [
{
title : "Calendar" ,
imageUrl : "./src/assets/collection_calendar.png" ,
moreInfo : "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Note%20Types/Collections/Calendar%20View.html" ,
description : "Organize your personal or professional events using a calendar, with support for all-day and multi-day events. See your events at a glance with the week, month and year views. Easy interaction to add or drag events."
} ,
{
title : "Table" ,
imageUrl : "./src/assets/collection_table.png" ,
moreInfo : "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Note%20Types/Collections/Table%20View.html" ,
description : "Display and edit information about notes in a tabular structure, with various column types such as text, number, check boxes, date & time, links and colors and support for relations. Optionally, display the notes within a tree hierarchy inside the table." } ,
{
title : "Board" ,
imageUrl : "./src/assets/collection_board.png" ,
moreInfo : "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Note%20Types/Collections/Board%20View.html" ,
description : "Organize your tasks or project status into a Kanban board with an easy way to create new items and columns and simply changing their status by dragging across the board."
} ,
{
title : "Geomap" ,
imageUrl : "./src/assets/collection_geomap.png" ,
moreInfo : "https://docs.triliumnotes.org/User%20Guide/User%20Guide/Note%20Types/Collections/Geo%20Map%20View.html" ,
description : "Plan your vacations or mark your points of interest directly on a geographical map using customizable markers. Display recorded GPX tracks to track itineraries."
}
] } / >
2025-09-26 23:34:14 +03:00
< / Section >
) ;
}
2025-09-26 23:21:41 +03:00
2025-09-27 18:59:51 +03:00
function ListWithScreenshot ( { items , horizontal , cardExtra } : {
2025-09-27 18:17:20 +03:00
items : { title : string , imageUrl : string , description : string , moreInfo : string } [ ] ;
2025-09-27 18:59:51 +03:00
horizontal? : boolean ;
cardExtra? : ComponentChildren ;
2025-09-27 18:17:20 +03:00
} ) {
const [ selectedItem , setSelectedItem ] = useState ( items [ 0 ] ) ;
return (
2025-09-27 18:59:51 +03:00
< div className = { ` list-with-screenshot ${ horizontal ? "horizontal" : "" } ` } >
2025-09-27 18:17:20 +03:00
< ul >
{ items . map ( item = > (
< li className = { ` ${ item === selectedItem ? "selected" : "" } ` } >
< Card
title = { item . title }
onMouseEnter = { ( ) = > setSelectedItem ( item ) }
onClick = { ( ) = > setSelectedItem ( item ) }
2025-09-27 19:02:13 +03:00
moreInfoUrl = { item . moreInfo }
2025-09-27 18:17:20 +03:00
>
{ item . description }
< / Card >
< / li >
) ) }
< / ul >
< div className = "details" >
2025-09-27 18:47:45 +03:00
{ selectedItem && (
< >
< img src = { selectedItem . imageUrl } / >
< / >
) }
2025-09-27 18:17:20 +03:00
< / div >
< / div >
)
}
2025-09-26 23:34:14 +03:00
function FaqSection() {
return (
< Section className = "faq" title = "Frequently Asked Questions" >
2025-09-27 19:29:40 +03:00
< div class = "grid-2-cols" >
< FaqItem question = "Is there a mobile application?" > Currently there is no official mobile application . However , if you have a server instance you can access it using a web browser and even install it as a PWA . For Android , there is an unofficial application called TriliumDroid that even works offline ( same as a desktop client ) . < / FaqItem >
< FaqItem question = "Where is the data stored?" > All your notes will be stored in an SQLite database in an application folder . The reasoning why Trilium uses a database instead of plain text files is both performance and some features would be much more difficult to implement such as clones ( same note in multiple places in the tree ) . To find the application folder , simply go to the About window . < / FaqItem >
< FaqItem question = "Do I need a server to use Trilium?" > No , the server allows access via a web browser and manages the synchronization if you have multiple devices . To get started , it ' s enough to download the desktop application and start using it . < / FaqItem >
< FaqItem question = "How well does the application scale with a large amount of notes?" > Depending on usage , the application should be able to handle at least 100.000 notes without an issue . Do note that the sync process can sometimes fail if uploading many large files ( & gt ; 1 GB per file ) since Trilium is meant more as a knowledge base application rather than a file store ( like NextCloud , for example ) . < / FaqItem >
< FaqItem question = "Can I share my database over a network drive?" > No , it ' s generally not a good idea to share a SQLite database over a network drive . Although sometimes it might work , there are chances that the database will get corrupted due to imperfect file locks over a network . < / FaqItem >
< FaqItem question = "How is my data protected?" > By default , notes are not encrypted and can be read directly from the database . Once a note is marked as encrypted , the note is encrypted using AES - 128 - CBC . < / FaqItem >
< / div >
2025-09-26 23:34:14 +03:00
< / Section >
) ;
2025-09-26 22:54:56 +03:00
}
2025-09-26 23:21:41 +03:00
function FaqItem ( { question , children } : { question : string ; children : ComponentChildren } ) {
return (
2025-09-27 19:29:40 +03:00
< Card title = { question } >
{ children }
< / Card >
2025-09-26 23:21:41 +03:00
)
}
2025-09-27 17:56:23 +03:00
function FinalCta() {
return (
< Section className = "final-cta accented" title = "Ready to get started with Trilium Notes?" >
< p > Build your personal knowledge base with powerful features and full privacy . < / p >
< div class = "buttons" >
< Button href = "./get-started/" text = "Get started" / >
< / div >
< / Section >
)
}