Commit Graph
3038 Commits
Author SHA1 Message Date
Zef Hemel b126320c5a Better readOnly checking, making sure that tag pages are never saved,
for instance
2025-10-07 14:33:54 +02:00
Zef Hemel 869f4c6dd3 Remove duplicate appearance of items on the tag page 2025-10-07 13:21:24 +02:00
Zef Hemel f9527c8238 Lua: allow passing in a number to tonumber 2025-10-07 09:07:12 +02:00
Zef Hemel 4f44426346 Fixes #1595
Accidentally was using `+` instead of `..` operator.
2025-10-07 09:02:55 +02:00
Oleksandr KuvshynovandGitHub 1b56357aa4 silverbullet: fix ToC rendering when item itself is a link. (#1597)
When item itself is a link, it seems to be rendered as
`[[[[header_name]]]]`

Just stripping `[[ ]]` from the title before creating anchor link.
2025-10-07 08:11:06 +02:00
Nico S.andGitHub c7d9bd29f8 Update space.md: addded "space.pageExists()" (#1594) 2025-10-06 18:22:04 +02:00
Zef Hemel ad94c95c18 Lint 2025-10-06 17:22:49 +02:00
Zef Hemel dde3433b87 Some tag page improvements:
* More efficient
* Now also exposes data objects

New markdown.objectToTable syscall to turn a list of objects into a
markdown table.
2025-10-06 17:22:10 +02:00
Zef Hemel c3a6d7aaaf Add data to itags for data objects to be able to distinguish them. 2025-10-06 16:50:12 +02:00
Zef Hemel 51e1eaf817 /.proxy enhancements
Now cleanly separates request and response headers for the request and
response of the http request from the ones that SB needs/serves itself.
2025-10-06 14:38:00 +02:00
Zef Hemel fff65f9094 Fixes #1593
Lua widget output can now be selected
2025-10-06 10:35:05 +02:00
Zef Hemel 5be6297271 2.1.7 2025-10-04 15:41:12 +02:00
Zef Hemel abf7f2782d Fixes #1589
Symlinks are supported again
2025-10-04 15:30:30 +02:00
Matouš Jan FialkaandGitHub e91bec71c0 Fix Lua arithmetic model (#1587)
This patch fixes the Lua arithmetic model at parser level only. Runtime
level fixtures are left for future work.

MOTIVATION

Space Lua treats all numbers as IEEE-754 doubles (JS semantics), so it
preserves negative zero. Lua uses integers and floats. The literal "-0"
in Lua is parsed as unary minus applied to the integer literal "0",
which yields the integer "0" (no sign). This difference flips the sign
of the divisor in "1/-0" and "-1/-0". Although it could be fixed without
touching the parser by changing only unary minus evaluation, this commit
goes a little further and provides integer vs float differenciating at
the parser level as well uses it to fix the unary minus evaluation.

Extensive tests are added to test this exact change works and the Space
Lua arithmetic model is aligned with Lua. Note that things like `-(expr)`
in general may still produce results inconsistent with Lua. This cannot
be fixed at parser level and must be fixed at runtime level which will
need far more complex change to the Space Lua interpreter code. Therefor
these cases we omitted from the tests.

Signed-off-by: Matouš Jan Fialka <mjf@mjf.cz>
2025-10-03 16:31:00 +02:00
Zef Hemel d919a2e97c Fix caching of index page for offline on auth setups 2025-10-03 10:43:28 +02:00
Zef Hemel b530d99dd6 No longer accept < and > in page names to avoid potential exploints 2025-10-03 09:00:38 +02:00
Matouš Jan FialkaandGitHub 9967cf1fd1 Space Lua: Remove unary plus (#1585)
* Improve documentation on string to number conversion (plus minor fixes of typos)
* Update Lua grammar to disallow unary plus

Signed-off-by: Matouš Jan Fialka <mjf@mjf.cz>
2025-10-03 08:28:36 +02:00
David HayesandGitHub 731a0cf334 Handle incoming signals and add more logging around server start. (#1584) 2025-10-02 19:25:15 +02:00
Zef Hemel 5222252a23 Fixes #1580
Added $SB_URL_PREFIX to health check endpoint URL docker uses
2025-10-02 09:52:35 +02:00
Zef Hemel df7eff1e3d make fmt 2025-10-01 17:14:54 +02:00
Zef Hemel b333d4ac36 Remove redundant disk_space_primitives 2025-10-01 17:14:46 +02:00
Zef Hemel b0b6087659 Removed unsupported transclusion syntax from docs 2025-10-01 16:57:56 +02:00
Matouš Jan FialkaandGitHub c9c6a212a5 Improve documentation on string to number conversion (plus minor fixes of typos) (#1579)
Signed-off-by: Matouš Jan Fialka <mjf@mjf.cz>
2025-10-01 15:56:26 +02:00
Amanda StjernaandGitHub 7b7e905790 LIQ: add mention of rendering links (#1578) 2025-10-01 13:19:11 +02:00
Zef Hemel fbdde5aae6 Use full page path in full-text search results 2025-10-01 12:55:28 +02:00
Zef Hemel 5b7e4c6027 Switch default generated CONFIG page use of the config.set API. 2025-10-01 11:31:40 +02:00
Matouš Jan FialkaandGitHub 80f31da16b Fix arithmetic coercion - refactored and enhanced (#1576)
The Lua 5.4 compatible `tonumber` implementation completely reworked

- custom char-by-char parser (no regexes)
- proper Lua space handling
- support for heximal integers and floats
- support for scientific float notation
- extended tests
- updated website docs

Signed-off-by: Matouš Jan Fialka <mjf@mjf.cz>
2025-10-01 11:30:58 +02:00
Zef Hemel 26d9d5bdf0 Restructure standard library and improve documentation
Refactor Library/Std into subfolders for APIs, Infrastructure, Editor,
Widgets, etc. Add more documentation and descriptions. Update references
throughout website and docs.
2025-10-01 11:22:31 +02:00
Zef Hemel bcb5fa5655 Properly fix #1577 2025-10-01 08:38:57 +02:00
Zef Hemel 99834a8b5b Fixes #1577
There was a recursive parent looking loop happening
2025-10-01 08:36:16 +02:00
Zef Hemel 6ca64f1e3f Bring back the page:saved event 2025-10-01 08:36:16 +02:00
Noah StanleyandGitHub 81989042b6 Show an error alert on Clipboard API write exceptions (#1575)
* Show alert on Clipboard API write exceptions

* Change Clipboard API error to flashNotification
2025-09-30 13:24:21 +02:00
Zef Hemel 15d30120f2 Bump tags.* lua script priority 2025-09-30 11:24:16 +02:00
Zef Hemel 9521c7605a 2.1.6 2025-09-30 11:08:37 +02:00
Zef Hemel d7cc6532e6 Filter hidden files and folders, as well as files without extensions
from FetchFileList

Add tests for hidden file and extension filtering in FetchFileList
2025-09-30 10:47:42 +02:00
Zef Hemel 1333c6d7a4 Slight reorganization of std library 2025-09-29 16:57:08 +02:00
Zef Hemel d63c7e49a7 Disable js.import tests for now 2025-09-29 15:56:41 +02:00
Zef Hemel 041823bca4 Changelog 2025-09-29 15:50:06 +02:00
Zef Hemel 7973a3a3c3 Enable GZIP HTTP compression for sensible content types 2025-09-29 15:49:09 +02:00
Zef Hemel 7c663ce1df Fixes #1572 2025-09-29 15:39:56 +02:00
Zef Hemel c123d87886 Added logging when indexing a broken link as aspiring page 2025-09-29 15:35:13 +02:00
Zef Hemel a2a784ddfe Fixes #1561
Last openen page information is now kept in the datastore and therefore
persistent even across tabs. This seems to also have fixed ther andom
behavior when deleting a page -> you always go back to your last opened
page (before the one you deleted).
2025-09-29 15:30:38 +02:00
Zef Hemel ea08c85202 Fixes #928
Command runs are now persisted to datastore
2025-09-29 15:20:14 +02:00
Zef Hemel dd1990cc8f More dead code elimination 2025-09-29 11:32:12 +02:00
Zef Hemel 2f6f0a5897 Dead code 2025-09-29 11:21:35 +02:00
Zef Hemel d6190b7c05 Moving more files around 2025-09-29 11:17:55 +02:00
Zef Hemel bb602dd9e8 Moved some more code around
Mostly just shuffling files to different folders, but also: renamed
PagePicker to AnythingPicker
2025-09-29 11:03:06 +02:00
Zef Hemel b4cec7ae81 Stop triggering file:deleted event on getFileMeta checks
Not sure why that happened...
2025-09-29 10:29:41 +02:00
Zef Hemel 64288ab1d1 Fixes #1568 2025-09-28 17:24:25 +02:00
Zef Hemel 2b32ab65ea 2.1.5 2025-09-27 06:43:12 +02:00