Commit Graph

9285 Commits

Author SHA1 Message Date
Rosa Gutierrez 26d5701217 Wait for service worker to be active before subscribing
The push subscription requires an active service worker. When
registering a new service worker, we now wait for it to become
active using navigator.serviceWorker.ready before attempting
to subscribe to push notifications.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-23 16:38:45 +01:00
Rosa Gutierrez c650cba179 Fix stuck state when permission granted but no subscription
When you had already granted notification permission but hadn't
completed the subscription flow (no service worker or no push
subscription), the UI showed neither the subscribe button nor the
enabled state, leaving you stuck with no way to subscribe, and wrong
instructions to fix it.

Instead, let's just show the button to allow you to subscribe.
2026-01-23 16:38:45 +01:00
Mike Dalessio 1aea6850f0 Extract Card::Commentable 2026-01-23 10:30:12 -05:00
Kevin McConnell 40946930d0 Merge pull request #2422 from basecamp/arm-build
Add arm64 architecture to Docker image
2026-01-23 14:38:13 +00:00
Kevin McConnell e27456b8f8 Include arm64 build in Docker workflow 2026-01-23 14:33:31 +00:00
Kevin McConnell 97be8b593f Merge pull request #2420 from basecamp/move-async-push-operation
Remove unnecessary `await` in push handler
2026-01-23 13:16:47 +00:00
Adrien Maston 764eb8987a Tweak orientation helper to prevent popups from going off screen 2026-01-23 14:06:17 +01:00
Kevin McConnell d7c9c4f3b0 Remove unnecessary await in push handler
We were `await`ing a synchronous method here, which will have the effect
of deferring its execution, and thus also the `event.waitUntil` call. We
want the latter to happen before control returns from the event.
Removing the unnecessary `await` solves this.

This seems unlikely to be a problem in practice, but all the same, it's
not right :)
2026-01-23 12:12:22 +00:00
Adrien Maston 65b2db0ec8 Add vertically compact layout for touch keyboard devices 2026-01-23 12:58:42 +01:00
Adrien Maston 97a1c29b0c Use bottom inset
... fixes content being stuck behind the tab bar in apps
2026-01-23 12:15:31 +01:00
Kevin McConnell 23fe40fa81 Correctly initialise WebPush connection (#2417)
The `ipaddr` arg here is being interpreted as a positional arg (since
the keyword arg doesn't exist), which results in an invalid connection
object. This was causing push notifications to silently fail.

We should initialise the property on the object instead.
2026-01-22 12:03:02 -08:00
Mike Dalessio 8ba6a97014 Merge pull request #2416 from basecamp/introduce-reactable
Make `Reaction` polymorphic with `reactable` association
2026-01-22 12:46:25 -05:00
Mike Dalessio ffab4cad6f Update models, views, and fixtures for polymorphic reactions
- Reaction: belongs_to :reactable (polymorphic) instead of :comment
- Comment: has_many :reactions with as: :reactable
- Views: use reaction.reactable instead of reaction.comment
- Fixtures: use polymorphic syntax for reactable association

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-22 12:29:54 -05:00
Mike Dalessio 1570c16f67 Make Reaction polymorphic
Add migration to replace comment_id with polymorphic reactable
association (reactable_type, reactable_id), enabling reactions on both
comments and cards.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-22 12:29:54 -05:00
Denis Švara 5384116f11 Rename the helper to user_pins and extract a pins_limit method. 2026-01-22 16:44:30 +01:00
Adrien Maston ff9e617f34 Merge branch 'main' into mobile/prepare-webviews-2
* main:
  Return to Board page when clearing filters
  Bump card perma z-index when dialog is open
  Only submit on blur if the input has a value
  Make the CLAUDE.md stub less obtrusive
  Only index up to 32KB of search content
  Use inline spacing variable
  Actually make it affect larger screens too
  Use CSS variable for panel size in delete dialogs
  Add viewport padding to dialogs on mobile
  Prevent page scrolling when modal dialog is open
2026-01-22 11:01:38 +01:00
Andy Smith 49f45b6645 Merge pull request #2410 from basecamp/handle-single-board-filters
Return to Board page when clearing filters
2026-01-21 15:32:43 -06:00
Andy Smith f9f638a9a7 Return to Board page when clearing filters 2026-01-21 15:05:47 -06:00
Andy Smith 5b94248169 Merge pull request #2409 from basecamp/improve-filter-settings-ux
Improve filter settings ux
2026-01-21 14:39:48 -06:00
Andy Smith 6c8d333bc9 Bump card perma z-index when dialog is open 2026-01-21 14:35:30 -06:00
Andy Smith eccef3b19c Only submit on blur if the input has a value 2026-01-21 14:33:19 -06:00
Andy Smith 9b1dd0bcd9 Merge pull request #2401 from nqst/modal-scroll-block
Prevent page scrolling when modal dialog is open
2026-01-21 14:02:20 -06:00
Jeremy Daer 783faf3c95 Make the CLAUDE.md stub less obtrusive
(Until Claude supports AGENTS.md natively, we need to keep the stub.)
2026-01-21 11:03:06 -08:00
Andy Smith 72123dc251 Merge pull request #2404 from nqst/dialog-viewport-spacing
Prevent modal dialogs from touching viewport edges
2026-01-21 11:23:01 -06:00
Kevin McConnell 74aca0867f Merge pull request #2406 from basecamp/search-content-limit
Only index up to 32KB of search content
2026-01-21 10:05:24 +00:00
Kevin McConnell 468fe5f16b Only index up to 32KB of search content
To prevent overflowing the columns in the search index tables (and also
just to avoid creating massive indexes), let's limit the searchable
content to the first 32KB.
2026-01-21 09:52:23 +00:00
Alexander Zaytsev 73cf1dede4 Use inline spacing variable 2026-01-20 20:51:01 +01:00
Adrien Maston 4519d75c24 Bump filters font-size on Android 2026-01-20 18:12:51 +01:00
Adrien Maston 7e84e44872 Support system font sizes on iOS 2026-01-20 17:46:05 +01:00
Adrien Maston 8c5ce3487e Remove keyboard shortcut from input's placeholder on mobile 2026-01-20 15:43:39 +01:00
Adrien Maston 3a685ca2b9 Hide filters by default on mobile 2026-01-20 13:39:00 +01:00
Adrien Maston 161925ab2b Merge branch 'main' into mobile/prepare-webviews-2
* main: (100 commits)
  Fix notification broadcast test for turbo-rails 2.0.21
  Update `turbo-rails` to get latest Turbo version
  Remove reference to removed controller
  Fix bad formatting on bridge page title attr
  Use private functions for bridge components
  Setup focus handling on touch target's connect callback
  Setup proper focus handling for mobile on the card perma's board picker
  Move dialog focus handling into the dialog controller
  Create popup initial alignment classes
  Fix class typo
  Hide the board selector button if card is closed
  Align board and tag picker dialogs without using math
  Add dialog manager to card perma
  Fix "M" hotkey using stale user from fragment cache
  Solve problem when Action Text raises on missing attachables
  Solve problem when Action Text raises on missing attachables
  Completing a step removes stalled status from UI
  Bump Bootsnap to v1.21.1
  Add Enable all/Disable all buttons to webhook event selection
  Use correct class selectors to target cards with  background images
  ...
2026-01-20 13:38:38 +01:00
Denis Švara 90a7b15db3 Move pins scope into a variable. Keep web limit to 20 and set JSON to 100. 2026-01-20 12:32:45 +01:00
Alexander Zaytsev bfea02ebd0 Actually make it affect larger screens too
And remove a magic number
2026-01-20 10:54:39 +01:00
Alexander Zaytsev aba88cdc3f Use CSS variable for panel size in delete dialogs 2026-01-20 10:40:29 +01:00
Alexander Zaytsev aea90f4b50 Add viewport padding to dialogs on mobile 2026-01-20 10:40:04 +01:00
Alexander Zaytsev 772b378668 Merge branch 'main' into modal-scroll-block 2026-01-19 22:19:51 +01:00
Jay Ohms 3fa850da3d Merge pull request #2307 from basecamp/mobile/bridge-components
Mobile: Bridge components
2026-01-19 15:59:16 -05:00
Jay Ohms cd6478d05b Merge branch 'main' into mobile/bridge-components
* main:
  Fix notification broadcast test for turbo-rails 2.0.21
  Update `turbo-rails` to get latest Turbo version
2026-01-19 15:23:17 -05:00
Alexander Zaytsev fa4e77f35e Prevent page scrolling when modal dialog is open 2026-01-19 20:46:49 +01:00
Rosa Gutierrez 80e0a03a40 Merge pull request #2399 from basecamp/update-turbo
Update `turbo-rails` to get latest Turbo version
2026-01-19 20:41:43 +01:00
Rosa Gutierrez 967f76de99 Fix notification broadcast test for turbo-rails 2.0.21
turbo-rails 2.0.21 changed `capture_turbo_stream_broadcasts` to only
return broadcasts produced within the block, matching its documented
behavior (see hotwired/turbo-rails#736).

Since `broadcast_unread` uses `broadcast_prepend_later_to` (async via
job), we need to wrap the call in `perform_enqueued_jobs` so the
broadcast actually happens within the assertion block.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-19 19:49:35 +01:00
Rosa Gutierrez 1083784a98 Update turbo-rails to get latest Turbo version
In preparation for offline mode.
2026-01-19 19:40:08 +01:00
Jay Ohms cc4e19bb20 Remove reference to removed controller 2026-01-19 12:47:11 -05:00
Jay Ohms a9b873f151 Merge branch 'main' into mobile/bridge-components
* main:
  Create popup initial alignment classes
  Fix class typo
  Hide the board selector button if card is closed
  Align board and tag picker dialogs without using math
  Add dialog manager to card perma
  Fix "M" hotkey using stale user from fragment cache
  Add Enable all/Disable all buttons to webhook event selection
  Remove whitespace
  Remove hover styles from disabled menu items

# Conflicts:
#	app/views/cards/_container.html.erb
2026-01-19 12:02:42 -05:00
Adrien Maston e9ebf8e9a5 Fix bad formatting on bridge page title attr 2026-01-19 17:42:05 +01:00
Jay Ohms b5985efdd1 Use private functions for bridge components 2026-01-19 10:05:48 -05:00
Adrien Maston e87dc10761 Setup focus handling on touch target's connect callback
... to support lazy loaded dialog content
2026-01-19 15:34:23 +01:00
Adrien Maston 511396144a Setup proper focus handling for mobile on the card perma's board picker 2026-01-19 15:33:12 +01:00
Adrien Maston 44732a345b Move dialog focus handling into the dialog controller
... instead of a separate dialog focus controller
2026-01-19 11:42:43 +01:00