* fix: properly strip HTML tags and resolve entities in feed article summaries
Fixes#146
The parseTextFromHtml function was using document.textContent directly on
the parsed HTML document, which could leave raw HTML tags and unresolved
entities in feed article summaries.
Changes:
- Extract text from body element to avoid document wrapper artifacts
- Collapse multiple whitespace/newlines into single spaces for cleaner output
- Add early return for empty/whitespace-only input
- Use optional chaining for safer null handling
* fix: preserve single line breaks, only collapse 2+ consecutive whitespace
Address review feedback: the previous \s+ regex was too aggressive and
broke text-only summaries with legitimate line breaks.
Now:
- Collapse runs of 2+ non-newline whitespace into a single space
- Collapse 3+ consecutive newlines into double newline (paragraph break)
- Single line breaks are preserved
---------
Co-authored-by: User <user@example.com>
This implements a huge change, where Fresh is removed as a framework and serving files, allowing more control over importing, bundling, and serving files and components.
The biggest challenge was to continue making sure that there weren't too many places to look into for import versions, and `PasswordlessPasskeyLogin.tsx` became a prototype in migrating a component to fully SSR, no need for frontend parsing (via Babel) or bundling (via a custom-script, downloading frontend dependencies from esm.sh). Still, there are too many components to migrate like that, and it's all working, so I likely won't even attempt it unless there's some bug, new feature, or security vulnerability to address that warrants a rewrite of those.
This also updates all dependencies (except `@libs/xml` because that still causes some breaking in DAV endpoints), including Deno!
All other advantages can be seen in the related issues, and the breaking change this (v4.0.0) introduces is related simply to `config.email.tlsMode` (which had a deprecation warning throughout v3), and because, while I tested many things exhaustively, it's not impossible something broke that I didn't see.
Closes#141Closes#132
* Add systemd-compatible service manager notification after bewCloud has successfully started
* Use `systemd-notify` util instead of native integration while Deno APIs aren’t there yet
* Implement different approach for systemd-notification reporting
I went with a slightly different option, given I was struggling to lose a lot of flexibility in the original listening log (because it's started with some server state parameters) or allow so much unnecessary/duplicate complexity from Fresh in `fresh.config.ts` because I'll probably eventually ditch it (given #99).
Some relevant references in the original `fresh` code:
- ab14d1044c/docs/1.x/concepts/server-configuration.md (L207-L208)
- d9764e2005/src/server/config.ts (L95)
- d9764e2005/src/server/mod.ts (L115-L118)
- d9764e2005/src/server/boot.ts (L52-L57)
* Remove unnecessary comments
---------
Co-authored-by: Bruno Bernardino <me@brunobernardino.com>
* Declare `deno task execute-with-permissions` task specifying all the permissions actually needed and alias all other tasks through that
Also add `migrate-db` task to the Deno configuration and use that in the
`Makefile`, so that the Makefile is fully optional, and swap the meanings of
the `start` and `preview` tasks, so that `start` is for production while
`preview` is for development.
* Keep task names consistent (no breaking changes)
* Reorder tasks
* Remove empty lines
* Use correct task in Dockerfile
* Bring back start (no breaking changes)
* Update readme with preview command
* Update necessary permissions for running locally and in docker
---------
Co-authored-by: Bruno Bernardino <me@brunobernardino.com>
* Expose new `tlsMode` and `tlsVerify` options for connecting to the mail submission agent
* Make `tlsVerify` default to opportunistic StartTLS on ports other than 465 to prevent breaking change
---------
Co-authored-by: Bruno Bernardino <me@brunobernardino.com>
* Use OS default Sans-Serif font instead of Google Nunito Sans Font
* Link calendar event locations to OSM instead of Google Maps
Better would be to use https://www.mediawiki.org/wiki/GeoHack – which is used
by WikiPedia to show an interactive selector for the mapping service to use –,
but it requires geo coordinates. Some systems also support generic geo:-URIs,
but they require coodinates and outside Android support is pretty spotty
(Apple wants you to use Apple Maps links instead, desktop platforms generally
require installed third-party apps …). Android does support an extension (`?q=`)
(https://developer.android.com/guide/components/intents-common#Maps) to search
by address via geo:-links though.
Remove file share when deleting a file/directory (#121)
Keep a consistent logged-out-view of file shares (#123)
Simplify README, add FAQ with more info, including `.env`-based config (#90)
Closes#121Closes#123Closes#90
This allows not enabling Dashboard and Files. It also sorts the apps in the menu according to the order in the `config.core.enabledApps` array.
Since this will require a major version upgrade (`v3.0.0`), I also took the opportunity to upgrade PostgreSQL. You can [follow this guide on how to upgrade PostgreSQL on Docker containers](https://news.onbrn.com/step-by-step-guide-upgrading-postgresql-docker-containers/).
Finally, this has some minor security improvements (confirming API endpoints won't work if their app is disabled in the config).
Closes#114Closes#108
* Add directory download as zip feature
Implements the ability for users to download directories as zip files if enabled in config. Adds a new API route for directory zipping, updates UI components to show a download button for directories, and introduces related config and type changes. Also includes a new download icon.
* Windows path bugfix
* Include empty directories in zip archive
* Address feedback
- `isDirectoryDownloadsAllowed` -> `areDirectoryDownloadsAllowed`
- send `parentPath` & `name` to API instead of resolving `fullPath` on client
- call `ensureUserPathIsValidAndSecurelyAccessible` before zipping
- set config `allowDirectoryDownloads` default to `false`
- add `zip` to Dockerfile and replace in-house zip algorithm
- replace `download.svg` with heroicon's `arrow-down-tray`
- `replace` with glob -> `replaceAll` with string
* Cleanup apt-get command
* Remove unused zip archive and directory functions
This takes part of the work being done in #96 that was reverted but still useful.
Note Tailwind and Fresh weren't upgraded because there's no security vulnerability in either, and I have found the new versions to be worse in performance. Thos will likely stay at those fixed versions going forward.