4011 Commits
Author SHA1 Message Date
hazre 1e000baa15 fix: polish settings permalinks and routing 2026-03-27 15:21:06 +01:00
Rye 6e238ef948 first implementation of MSC4440 Bios (will have to be changed later) 2026-03-27 15:13:17 +01:00
hazre 95335de49a feat: route settings and add permalinks 2026-03-27 13:03:29 +01:00
hazre 9a15cafc02 fix: trust arborium availability for unsupported labels 2026-03-27 12:37:56 +01:00
hazre 240ced593e fix: add arborium language compatibility mapping 2026-03-27 12:31:55 +01:00
hazre 3c397acbd6 test: relax text viewer renderer assertion 2026-03-27 12:31:55 +01:00
hazre 575c4f96fb refactor: replace prism text highlighting with arborium 2026-03-27 12:31:55 +01:00
hazre 428505cc21 fix: preserve structured code blocks in parser 2026-03-27 12:31:55 +01:00
hazre bfdda68483 fix: handle whitespace in code block language lookup 2026-03-27 12:31:55 +01:00
hazre f804f07a3c feat: render message code blocks with arborium 2026-03-27 12:31:55 +01:00
hazre e74f167268 fix: prevent stale arborium highlight flash 2026-03-27 12:31:55 +01:00
hazre 4e07ec15dc feat: add shared arborium code renderer 2026-03-27 12:31:55 +01:00
hazre c3cf613a2c fix: restore prism body theme classes 2026-03-27 12:31:55 +01:00
hazre dda1be44be fix: use arborium dist theme urls 2026-03-27 12:31:54 +01:00
hazre 9148978326 feat: add arborium theme bridge 2026-03-27 12:31:54 +01:00
hazre 20c941e951 test: preserve code language metadata during sanitization 2026-03-27 12:31:54 +01:00
hazre bce5b50a24 fix: treat escaped arborium output as plain 2026-03-27 12:31:54 +01:00
hazre 0e0290f557 fix: align arborium runtime api with spec 2026-03-27 12:31:54 +01:00
hazre 286b85c434 fix: align arborium runtime api with spec 2026-03-27 12:31:54 +01:00
hazre c78beb8cb5 feat: add arborium runtime wrapper 2026-03-27 12:31:54 +01:00
7w1 86a3ccb88f fix: fetch room/sender avatar and display name for push notifications (#551)
### Description

When the pusher is configured with `event_id_only` format, the service
worker fetches event details itself rather than receiving them in the
push payload. Previously only the sender display name and room name were
retrieved — `room_avatar_url` was always `undefined`, so every
notification showed the default app logo regardless of whether the room
or sender had an avatar set. Display names could also be stale in the
encrypted path when the app resumed from a cold state.

**Changes in `src/sw.ts`:**

- `fetchMemberDisplayName` → `fetchMemberInfo`: the same single HTTP
request to `m.room.member` state now also extracts `avatar_url`, giving
both display name and sender avatar for free
- `fetchRoomAvatar`: new helper that fetches the `m.room.avatar` state
event URL
- `mxcToNotificationUrl`: converts `mxc://` to a legacy unauthenticated
thumbnail URL (`/_matrix/media/v3/thumbnail/…`) so the OS can load the
notification icon without an auth header
- `handleMinimalPushPayload`: room avatar is now fetched in the initial
parallel batch alongside the event and room name; icon is resolved as
room avatar → member avatar (DM fallback) → default logo;
`room_avatar_url` passed to all `handlePushNotificationPushData` call
sites
- Encrypted relay path now uses the server-fetched `senderDisplay`
(authoritative) rather than the SDK cache value from the relay, which
can be absent or stale when the app hasn't fully synced after a cold
resume

Fixes #

#### Type of change

- [x] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing
functionality to not work as expected)
- [ ] This change requires a documentation update

### Checklist:

- [x] My code follows the style guidelines of this project
- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings

### AI disclosure:

- [ ] Partially AI assisted (clarify which code was AI assisted and
briefly explain what it does).
- [x] Fully AI generated (explain what all the generated code does in
moderate detail).

`fetchMemberInfo` extends the existing member state fetch to also return
`avatar_url`. `fetchRoomAvatar` GETs `m.room.avatar` state.
`mxcToNotificationUrl` builds a legacy `/_matrix/media/v3/thumbnail/`
URL (no auth required, OS-loadable) from an `mxc://` URI.
`handleMinimalPushPayload` adds `fetchRoomAvatar` to its parallel fetch
batch, resolves the notification icon with room > member > default
priority, and passes it through as `room_avatar_url` to every
`handlePushNotificationPushData` invocation. The encrypted relay path is
updated to prefer the server-fetched display name over the relay's
potentially-stale SDK cache value.
2026-03-27 03:46:59 +00:00
7w1 8e30086bf4 add ability to show user info in member and state event messages (#536)
### Description

Add ability to open the user hero by clicking on the usernames shown in
member and state events (e.g. user joins room, room name changed). I
expected this behavior based on previous usage of discord, it wasn't
doing anything previously so I think this is a useful addition.

#### Type of change

- [ ] Bug fix (non-breaking change which fixes an issue)
- [X] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing
functionality to not work as expected)
- [ ] This change requires a documentation update

### Checklist:

- [ ] My code follows the style guidelines of this project
- [X] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [X] My changes generate no new warnings

### AI disclosure:

- [ ] Partially AI assisted (clarify which code was AI assisted and
briefly explain what it does).
- [ ] Fully AI generated (explain what all the generated code does in
moderate detail).
2026-03-27 03:34:03 +00:00
Rye 0c7911cbf8 fix: remove unused files and added fallback for regex escaping 2026-03-27 02:32:41 +01:00
Rye 7dfafc31c8 Merge branch 'feat/compat/pluralkit' of https://github.com/dozro/Sable2 into feat/compat/pluralkit 2026-03-27 01:44:18 +01:00
Rye bc8e9646ce docs(PMP-Command): adjusted the description of /usepmp and also added a changeset 2026-03-27 01:43:33 +01:00
Rose 523fcbbc9f Merge branch 'dev' into feat/compat/pluralkit 2026-03-27 01:39:39 +01:00
Rye 155ac64c65 fix(PMP-Command): fix the syntax handling of pmp related command 2026-03-27 01:38:05 +01:00
hazre 8d1c6e1d06 fix: redirect desktop settings root 2026-03-26 23:52:07 +01:00
hazre 633bd25904 fix: prevent nested settings openers 2026-03-26 23:45:36 +01:00
hazre e76c278dad refactor: open settings via route navigation 2026-03-26 23:45:36 +01:00
hazre 8a8791e12f fix: avoid shallow settings history churn 2026-03-26 23:45:36 +01:00
hazre fbde318180 fix: preserve shallow settings background state 2026-03-26 23:45:36 +01:00
hazre bb47bd037a feat: render settings as a shallow desktop modal 2026-03-26 23:45:35 +01:00
hazre 3f03a1a1dd fix: harden settings route navigation 2026-03-26 23:45:35 +01:00
hazre 7aad1ac68d fix: align settings mobile back behavior 2026-03-26 23:45:35 +01:00
hazre f786860947 feat: make settings route-driven 2026-03-26 23:45:35 +01:00
hazre 0ec294405c refactor: share settings section layout and focus handling 2026-03-26 23:45:35 +01:00
hazre 144ff90522 refactor: remove settings route type inversion 2026-03-26 23:45:35 +01:00
hazre a6376d77e7 feat: add settings route helpers 2026-03-26 23:45:34 +01:00
Evie Gauthier a704a3500f Merge branch 'dev' into fix/bug-fixes 2026-03-26 17:25:14 -04:00
Evie Gauthier 32663bd51c Merge branch 'dev' into fix/push-notification-metadata 2026-03-26 17:24:08 -04:00
7w1 95cdfa1b23 feat: room abbreviations with hover tooltips and space inheritance (#514)
<!-- Please read
https://github.com/SableClient/Sable/blob/dev/CONTRIBUTING.md before
submitting your pull request -->

### Description

Adds a room abbreviations feature: moderators can define term/definition
pairs in room settings. Defined terms are highlighted with a dotted
underline in messages and show a tooltip on hover (tap-to-pin on
mobile). Abbreviations defined in a parent space are inherited by child
rooms and nested spaces, with overrides allowed at each level. The
settings UI shows a flat list of inherited and locally-defined entries.

Fixes #

#### Type of change

- [ ] Bug fix (non-breaking change which fixes an issue)
- [x] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing
functionality to not work as expected)
- [ ] This change requires a documentation update

### Checklist:

- [x] My code follows the style guidelines of this project
- [x] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings

### AI disclosure:

- [ ] Partially AI assisted (clarify which code was AI assisted and
briefly explain what it does).
- [X] Fully AI generated (explain what all the generated code does in
moderate detail).

<!-- Write any explanation required here, but do not generate the
explanation using AI!! You must prove you understand what the code in
this PR does. -->

The code adds changes that allow for setting and viewing room
abbreviations, with an on-hover tooltip (or press on mobile -
semi-persistent). It stores these in the room state under a new key, and
recursively fetches abbreviations from the space level. This also adds
regex so that abbreviations correctly work at word boundaries. Also adds
the needed hooks to `room.ts` and `slidingSync.ts`
2026-03-26 21:18:00 +00:00
7w1 99d2b4bf87 fix confusing ui for client side embed settings (#535)
### Description

this is a tiny fix to a potentially confusing "problem" that i thought
of when going to sleep last night, previously if you enabled client side
embeds in both unencrypted and encrypted rooms, and then turned off the
main client side embeds toggle, the encrypted rooms setting would remain
on, even though it would be hidden in the setting ui

feel free to just close if this is stupid

#### Type of change

- [X] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing
functionality to not work as expected)
- [ ] This change requires a documentation update

### Checklist:

- [ ] My code follows the style guidelines of this project
- [X] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [X] My changes generate no new warnings

### AI disclosure:

- [ ] Partially AI assisted (clarify which code was AI assisted and
briefly explain what it does).
- [ ] Fully AI generated (explain what all the generated code does in
moderate detail).
2026-03-26 21:17:16 +00:00
7w1 64082c4cec Add better parsing for youtube embed links (#534)
### Description

Replace the previous hacky regex method with a slightly better link
parser. Add support for timestamps, playlists and youtube music links,
tracking info is still stripped and embeds use the timestamp. Previously
none of these features were supported, this might also be slightly more
robust.

#### Type of change

- [ ] Bug fix (non-breaking change which fixes an issue)
- [X] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing
functionality to not work as expected)
- [ ] This change requires a documentation update

### Checklist:

- [ ] My code follows the style guidelines of this project
- [X] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [X] My changes generate no new warnings

### AI disclosure:

- [ ] Partially AI assisted (clarify which code was AI assisted and
briefly explain what it does).
- [ ] Fully AI generated (explain what all the generated code does in
moderate detail).
2026-03-26 21:16:50 +00:00
Evie Gauthier cc2c51a95b fix: replace for...of with Array.from().forEach() to satisfy no-restricted-syntax 2026-03-26 16:50:52 -04:00
Evie Gauthier 5ddb05e1b4 fix: address review comments on room abbreviations PR 2026-03-26 16:40:33 -04:00
Rye 2a4fd48af9 feat(PMP-PK): added more options (removing shorthand,...) and documentation 2026-03-26 19:47:59 +01:00
7w1 746f777d3d Remove null value from message forwarding metadata (#540)
### Description

not setting `sender` to `null` anymore but just not setting it.

Fixes #539 (hopefully)

#### Type of change

- [x] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing
functionality to not work as expected)
- [ ] This change requires a documentation update

### Checklist:

- [x] My code follows the style guidelines of this project
- [x] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings

### AI disclosure:

- [ ] Partially AI assisted (clarify which code was AI assisted and
briefly explain what it does).
- [ ] Fully AI generated (explain what all the generated code does in
moderate detail).

no AI was used for this PR
2026-03-26 10:13:26 -05:00
Evie Gauthier ac3814d6cb chore: add changeset for push notification metadata fix 2026-03-26 10:58:57 -04:00
Evie Gauthier 59fcd841a1 fix: fetch room/sender avatar and display name for push notifications
When the pusher uses event_id_only format the SW fetches event details
itself. Previously only the display name and room name were retrieved;
the notification icon was always the default app logo.

- fetchMemberDisplayName → fetchMemberInfo: also captures avatar_url
  from the m.room.member state response, so a single HTTP request gives
  us both the display name and the sender avatar
- fetchRoomAvatar: fetches m.room.avatar state; used for group rooms
- mxcToNotificationUrl: converts mxc:// to a legacy unauthenticated
  thumbnail URL so the OS can load the icon without an auth header
- handleMinimalPushPayload: fetch room avatar in the initial parallel
  request batch; resolve notification icon as room avatar > member
  avatar (DM fallback); pass room_avatar_url to all
  handlePushNotificationPushData call sites
- encrypted path: prefer the server-fetched senderDisplay (authoritative)
  over the relay's SDK cache value, which may be stale or absent when
  the app hasn't fully synced after a cold resume
2026-03-26 10:30:48 -04:00