1
0
Fork 0
forked from jriou/coller

feat: Add text editor

Use Monaco Editor to create notes. Support syntax highlighting. Store the
language with the note in the database to later support syntax highlighting in
a note web view.

Signed-off-by: Julien Riou <julien@riou.xyz>
This commit is contained in:
Julien Riou 2025-08-27 22:42:12 +02:00
commit c54f32495b
Signed by: jriou
GPG key ID: 9A099EDA51316854
9 changed files with 170 additions and 24 deletions

View file

@ -8,6 +8,7 @@ import (
"os"
"path/filepath"
"regexp"
"strings"
)
func ReadConfig(file string, config interface{}) error {
@ -109,3 +110,10 @@ func ReturnError(logger *slog.Logger, message string, err error) int {
}
return RC_ERROR
}
func ToLowerStringSlice(src []string) (dst []string) {
for _, s := range src {
dst = append(dst, strings.ToLower(s))
}
return
}