Commit Graph

2228 Commits

Author SHA1 Message Date
dependabot[bot]
8feaddaedb build(deps): bump svgo from 3.3.2 to 3.3.3
Bumps [svgo](https://github.com/svg/svgo) from 3.3.2 to 3.3.3.
- [Release notes](https://github.com/svg/svgo/releases)
- [Commits](https://github.com/svg/svgo/compare/v3.3.2...v3.3.3)

---
updated-dependencies:
- dependency-name: svgo
  dependency-version: 3.3.3
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-03-05 00:45:18 +00:00
Harvey Tindall
d7fdf29c7c jf_activity: fix infinite load
computeScrollInfo wasn't being called before the first detectScroll
call, because there is no search functionality (somehow, i think). Fixed
by calling it if _scroll.rowHeight is 0.
2026-03-01 16:24:09 +00:00
Harvey Tindall
60bf89bc02 email: complain about invalid from address 2026-03-01 15:10:23 +00:00
Harvey Tindall
637cca0625 userpage: fix confirmation required message display
other content wasn't being hid when the message popped up, should now.
For #455.
2026-01-05 16:51:59 +00:00
Harvey Tindall
455bde491f tooltip: rework as pseudo-component, fix overflow
uses the <tool-tip> tag now, and the setupTooltips() function in ui.ts
must be called at any point in the pages load. added "below-center"
position, showing below and centered horizontally. breakpoint tailwind
lingo also now works (e.g. "below-center sm:right"). If a left or
right-aligned tooltip clips off the screen, it will be shifted the
appropriate amount left/right to avoid that automatically.
2026-01-05 16:49:13 +00:00
Harvey Tindall
ee96bb9f1b tabs: add clearURL method, loading tabs clears previous qps
Navigatable has clearURL, which for Search clears "search" qp, and
invites clears "invite" qp. Tab interfaces optionally include
"contentObject: AsTab", and show/hide funcs are passed the contentObject
of the previously loaded tab if one is available, so that they can call
it's clearURL method. This means searches you typed for the accounts tab
won't pop up when switching to activity.
2026-01-05 10:39:20 +00:00
Harvey Tindall
721b209e1f list: add load queue
_loadLock set true when a load is happening, if another _load is called
when this is happening, the method call is appended to _loadQueue. When
a running _load finishes, it shift()s the _loadQueue and calls the
method from it if there is one.
2026-01-05 09:51:22 +00:00
Harvey Tindall
c10f1e3b36 list/search/accounts: fully(?) page-based search
searches are triggered by setting the search QP, and ran by a listener
set on PageManager. same with details. Works surprisingly well, but i'm
sure theres bugs.
2025-12-25 13:04:03 +00:00
Harvey Tindall
3308739619 admin: tab system improvement, search: ?search qp
tab content classes (e.g. settingsList, activityList)
can implement "AsTab", "Navigatable" and or "PageEventBindable",
the first giving them a tab name, a subpath and a reloader function,
the second an "isURL" and "navigate" function for loading resources,
the last giving them bind/unbindPageEvent methods. These are looped
through in ts/admin.ts still crudely, maybe tabs.ts could accept "AsTab"
implementers directly.

"Search" class now has a ?search query param which just encodes the
search box content, set when you perform a server search (hit enter or
press the button). ?user queries from the accounts or activity tab will
be converted to this form on loading.
2025-12-24 12:56:02 +00:00
Harvey Tindall
748acc13c0 accounts: show table row when clicking into details, more usage of
RadioBasedTabs

when clicking a username in the accounts tab, the details comes up with
a copy of the row you clicked, so you can view logs and edit the user.
Also decided not to use a RadioBasedTab here, instead providing a link
to the activity tab with a search for the user (added the ability to do
that, ?user=username). FIXME: handle deleting the user or just generally
editing them.
2025-12-23 20:37:29 +00:00
Harvey Tindall
c3bac6c51c ui: select by index, id over name, buttonHTML on RadioBasedTabSelector
pass a string (new "id" field) or number to RadioBasedTabSelector.selected = x.
setting an "id" for a tab is optional, if not set it's value defaults to the "name" value.
Also added optional buttonHTML to put inside the button insetad of the
given name.
2025-12-23 15:12:44 +00:00
Harvey Tindall
3e39657642 ui: add RadioBasedTabs
does the "tabs" seen on the invite tab (invite expiry/user expiry), and
will be used in all other similar cases.
2025-12-21 19:55:49 +00:00
Harvey Tindall
41334e9051 api-users: add individual user summary route
GET /users/:id, skips the usercache.
2025-12-21 19:19:46 +00:00
Harvey Tindall
e2c34e574d jf_activity: ui changes
just committing so I can pull on another device.
2025-12-21 19:07:03 +00:00
Harvey Tindall
b6459b665d jf_activity: paginated list in ui
added POST route for pagination to activity route, a count route, and
modified Search and PaginatedList a bit to support lists without search
fields (essentially just running an empty search). Visible by clicking
on a user's name in the accounts tab.
2025-12-20 18:27:39 +00:00
Harvey Tindall
d72a5c91cf jf_activity_test: reduce time to run
values were reasonable when testing with a size limit of 20 or
something, now it's ~6000.
2025-12-20 11:58:56 +00:00
Harvey Tindall
cacd992aad jf_activity: remove debug line
also bump mediabrowser again to do the same.
2025-12-20 11:49:55 +00:00
Harvey Tindall
23ad016476 mediabrowser: bump to v0.3.34
forgot to switch back from my local copy in the previous commit.
2025-12-20 11:41:35 +00:00
Harvey Tindall
cc571409b9 Merge branch 'jf-log'
accidentally did a fix on the wrong branch, so i'm merging it
prematurely.
2025-12-20 11:23:18 +00:00
Harvey Tindall
d7bad69d40 jf-actvitity: functioning route, ombi fixes
forgot to switch branches before doing a fix for #455, so it's in here
too. OmbiUserByJfID/getOmbiUser takes an optional email *string, to
optionally pass an override email address to search with, used when
changing it.
2025-12-20 11:21:13 +00:00
Harvey Tindall
63bb678a72 Merge branch 'main' of github.com:hrfee/jfa-go 2025-12-19 13:12:27 +00:00
Harvey Tindall
2a41c5a393 admin: scroll current tab in nav to center
for #456, ensures you can see and press both the next and previous tabs
    even if you can't scroll for some reason.
2025-12-19 13:11:37 +00:00
Harvey Tindall
9b80492b4f userpage: fix display of email confirmation required message
recent adjustments to modals and CSS in general meant a "content" class
was removed that was being querySelector'ed. For #455.
2025-12-16 18:37:54 +00:00
Harvey Tindall
315d74eb2d userpage: fix redirect on contact method change
root userpage paths ("") would mess up the redirect, wrapper function
returns "/" if thats the case. For #455.
2025-12-16 18:32:37 +00:00
Harvey Tindall
c21df253a1 jf-activity: initial changes
functionality mostly there but needs a UI.
2025-12-16 18:15:39 +00:00
Harvey Tindall
e4e9369d54 theme: set theme-color for ios devices
colours the search bar, sometimes.
2025-12-11 14:47:22 +00:00
Harvey Tindall
26d05911fd ui: fix hidden overflow on mobile devices
mostly the accounts table was causing an overflow on mobile browsers,
specifically anything on ios and samsung browser. For #450.
2025-12-10 20:37:29 +00:00
Harvey Tindall
85a6d66228 html: fix headers
go's html/template was thinking header.html and other template snippets
were full documents, so inserting their own <html> and other tags,
breaking the head up. Renaming to txt seems to fix things.
2025-12-10 20:31:45 +00:00
Harvey Tindall
1c755306f9 tray: fix broken dependency. 2025-12-10 17:43:00 +00:00
Harvey Tindall
2e97142d9e accounts: reduce initial load time even further
took the referralCache idea further and did it for all db queries. Now
take ~40ms for ~5000 users on arm64 through QEMU, and ~60ms on a
rockpro64.
2025-12-10 17:39:54 +00:00
Harvey Tindall
a08a0fd3e6 accounts: reduce initial load time further
When generating the cache and calling userSummary per user, previously
the DB was queried for an invite with the ReferrerJellyfinID set to the
user's ID. This was fast enough on my test system (~5000 users in
~1.5s), while testing cross-compilation, I found it ran extremely slow
on an arm64 build (running through QEMU admittedly), doing ~5000 in
~18s. Instead, a map of IDs to invites/referrals is generated once and
queried instead. Initial load now takes ~80ms on my system, and 0.95s
through QEMU, and 0.68s on a rockpro64 SBC.
2025-12-10 16:44:21 +00:00
Harvey Tindall
420a22970d goreleaser: unset GOOS/GOARCH for precompile step
these should be run natively.
2025-12-10 15:05:30 +00:00
Harvey Tindall
d4109c8cf5 matrix: use goolm over libolm, ci: user smaller docker image base
removes one dependency. jfa-go-build-docker has been updated to reflect
this, and in general with a newer debian version and properly included
goreleaser, and a build for amd64. Dockerfiles now use a
"distroless"-style container as their base. Was gonna use
chainguard/glibc-dynamic, but it running as a different user meant it
wouldn't read/write from your /data mount without manual intervention.
2025-12-10 13:25:21 +00:00
Harvey Tindall
945d579f57 config: un-advanced date format, fix dependencies
changed dependency on "method" (from when it was in the email section)
to "enabled". For #453.
2025-12-10 09:51:12 +00:00
Harvey Tindall
6e1f07563d ci: use caches for container build too 2025-12-09 17:53:26 +00:00
Harvey Tindall
ce6f8b41dc ci: use npm cache too 2025-12-09 17:43:04 +00:00
Harvey Tindall
aa75305da4 scripts/version.sh: downgrade version
use go 1.24 and remove usage of wg.Go().
2025-12-09 17:42:45 +00:00
Harvey Tindall
03cf533c9d ci: use podman volumes for go mod/build cache 2025-12-09 17:38:12 +00:00
Harvey Tindall
ccf0584db8 build: use tsgo for type checking
I don't use and fancy typescript features, and apparently this version
is very usable at this point. Removes the typescript dependency, which
should have been in dev-deps anyway.
2025-12-09 17:31:23 +00:00
Harvey Tindall
833fd26091 scripts/variants: add parallel flag
doesn't result in much gain on my machine or my CI server so it's not
the default. On local machine (5800x), went from ~5ms to ~4ms, on my CI
(hetzner ampere altra with 8 vCPUs) went from ~15ms to ~10ms.
2025-12-09 15:44:47 +00:00
Harvey Tindall
fd72c838c3 userpage: don't trigger submit on "reset password" press
Fiex #452.
2025-12-09 15:25:54 +00:00
Harvey Tindall
63c770db73 css: fix lists with RTL
changes text-align:left to start, and margin-left: to
margin-inline-start:. Submitted a PR to a17t to change these values as
well. For #450.
2025-12-09 15:06:49 +00:00
Harvey Tindall
6237620390 scripts/variants: add verbose -v flag
disable output by default, enable with -v
2025-12-09 14:38:48 +00:00
Harvey Tindall
4a9bac1027 scripts: replace dark-variant.sh with go scripts/variants
uses regex mostly, resulting in a significantly faster execution (old:
~2s, new: ~31ms). Only matches classList.add/remove and class="..."
(won't touch string literal variables or colours), but these weren't
really used anyway. Supports multi-line classList.add/remove, which was
the reason I wrote this anyway (formatting the codebase introduced some
of these).
2025-12-09 14:28:05 +00:00
Harvey Tindall
817107622a ts: format finally
formatted with biome, a config file is provided.
2025-12-08 20:38:30 +00:00
Harvey Tindall
ca7c553147 telegram: add "always use default lang", /lang default
For #451. Setting in integrations > chat bots > telegram makes jfa-go
ignore the telegram users clients lanugage setting and always use
whatever is set as the default language in jfa-go. Also added /lang
default, to un-set a preferred language. the start message also now
shows up on typing /help or !help too.
2025-12-08 18:16:27 +00:00
Harvey Tindall
d00507fd20 accounts: fix matrix input
was too small to see what you were typing.
2025-12-08 17:50:50 +00:00
Harvey Tindall
2bbf97be19 accounts/activity: fix clear search button on RTL
use margin-inline-start instead of margin-left. For #450.
2025-12-08 17:46:11 +00:00
Harvey Tindall
4f135220bc lang: display ckb (kurdish) as RTL 2025-12-08 15:36:03 +00:00
Harvey Tindall
a2500add5a lang: add lang tag to name of Farsi and Kurdish 2025-12-08 15:35:12 +00:00