Skip to content

Hardware→Outpost: in-app notification instead of the after-recording popup#767

Open
dhamariT wants to merge 3 commits into
mainfrom
feat/hardware-outpost-notification
Open

Hardware→Outpost: in-app notification instead of the after-recording popup#767
dhamariT wants to merge 3 commits into
mainfrom
feat/hardware-outpost-notification

Conversation

@dhamariT

@dhamariT dhamariT commented Jul 2, 2026

Copy link
Copy Markdown
Collaborator

Per review feedback: recording a timelapse on a hardware project shouldn't throw a modal — send an in-app notification instead (lands in the notifications list, like the achievement/shop-order rows).

What changed

  • New notification type Notifications::HardwareMovedToOutpost — inbox-only (low priority, no Slack/email), aggregatable so a builder who records repeatedly keeps a single unread notice instead of a pile. Registered in Notifications::Registry and given an alert-triangle icon; inbox partial reads "Hardware projects have moved to Hack Club Outpost" with the subtitle "Building hardware? It all happens over on Hack Club Outpost now." and links to outpost.hackclub.com.
  • Fires from LookoutSessionsController#create for hardware projects (flag hardware_to_outpost), after the session is created — recording is unaffected.
  • Removed the on-recorder popup (Show the hardware→Outpost notice after a timelapse, not before #765): the record.html.erb render + the capture controller's showHardwareOutpostNotice trigger/method.

Unchanged

Project creation (starting a new hardware project, or picking a hardware mission in the setup wizard) still shows the Outpost popup up front — this only moves the timelapse nudge from a modal to a notification. The popup partial + modal controller are still used there.

Gating

Fires only when the user has hardware_to_outpost (the feature flag) and week_2_release (the notification system's own rollout gate — every notification type inherits this).

Testing

  • ruby -c / node --check / ERB parse all clean; net +17 lines.
  • Manual (both flags on, hardware project): start a timelapse → it records normally → a "Hardware projects have moved to Hack Club Outpost" notification appears in the inbox; no modal.

Note

Low Risk
Changes are feature-flagged, non-blocking on the recording path, and the backfill defaults to dry-run; no auth or payment logic touched.

Overview
Hardware → Outpost messaging for Lookout timelapses moves from a blocking modal on the recorder to an in-app notification that appears when a hardware project starts a Lookout session (after the session is created, recording unchanged).

Adds Notifications::HardwareMovedToOutpost: low-priority, inbox-only, aggregatable, with an inbox partial linking to Outpost and preview copy. Notification rows can show a brand image chip (Outpost favicon) via new TYPE_ICON_IMAGES styling in the item component.

Removes the hardware Outpost modal from record.html.erb and showHardwareOutpostNotice in the capture controller. Project creation / setup wizards still use the existing Outpost popup.

Adds a one-time backfill job (dry-run by default) to notify all users with hardware project memberships, reusing the same notify path and aggregation rules.

Gated by hardware_to_outpost on the Lookout create path and the notification system’s usual rollout gates on notify.

Reviewed by Cursor Bugbot for commit 3a8c5e8. Bugbot is set up for automated code reviews on this repo. Configure here.

…popup

Per review, recording a timelapse on a hardware project shouldn't throw a
modal — it should drop a notification in the inbox instead.

- New Notifications::HardwareMovedToOutpost type (inbox-only/low priority,
  aggregatable so repeat recordings keep one unread notice), registered +
  given an alert-triangle icon, with an inbox partial linking to Outpost.
- Fire it from LookoutSessionsController#create for hardware projects (flag
  hardware_to_outpost), after the session is created so recording is
  unaffected.
- Remove the on-recorder popup: the record.html.erb render + the capture
  controller's showHardwareOutpostNotice trigger/method.

Project *creation* (new hardware project / hardware mission) still shows the
Outpost popup up front — that's unchanged. Notification links to
outpost.hackclub.com. Gated by hardware_to_outpost (+ the notification
system's own week_2_release rollout flag).

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using default effort and found 2 potential issues.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 7d92c89. Configure here.


def preview_text
"Building hardware? It all happens over on Hack Club Outpost now."
end

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing aggregate group key

Medium Severity

HardwareMovedToOutpost sets aggregatable but leaves the default build_group_key (nil). Other aggregatable notification types define a non-nil key so the partial unique index can dedupe unread rows; with a nil group_key, concurrent notify calls can each insert a separate unread notification instead of one aggregated notice.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 7d92c89. Configure here.

# inbox notification rather than the old on-recorder popup, without blocking
# the recording.
if @project.hardware? && Flipper.enabled?(:hardware_to_outpost, current_user)
Notifications::HardwareMovedToOutpost.notify(recipient: current_user, record: @project)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Timelapse nudge lost without inbox

Medium Severity

The recorder Outpost modal was removed for users with only hardware_to_outpost, while the replacement notification is skipped unless week_2_release is enabled for the recipient inside Notification.notify. Those users no longer get any timelapse Outpost nudge.

Additional Locations (1)
Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 7d92c89. Configure here.

dhamariT added 2 commits July 2, 2026 15:11
…icon

Two follow-ups on the notification:

1) Notify everyone who already has a hardware project, not only those who
   record a timelapse. New OneTime::BackfillHardwareOutpostNotificationsJob
   sweeps every member of a hardware project (dry-run by default; the notif is
   aggregatable + self-gates on week_2_release, so no dupes/spam). New hardware
   projects can't be created on Stardance anymore, so this audience is fixed.

2) Prettier icon: instead of the generic alert-triangle line icon, show a
   colour chip cropped from the Outpost flame logo (borrowed from the sidebar
   widget). item_component gains optional image icons (TYPE_ICON_IMAGES); the
   notifications SCSS crops the wide wordmark to its flame side as a rounded,
   full-colour badge.
The cropped wordmark chip looked off. Swap it for the actual Outpost flame
favicon (square, transparent) and drop the crop hack — render it whole with
object-fit: contain so nothing clips.
@dhamariT dhamariT added this pull request to the merge queue Jul 2, 2026
@github-merge-queue github-merge-queue Bot removed this pull request from the merge queue due to invalid changes in the merge commit Jul 2, 2026
@dhamariT dhamariT added this pull request to the merge queue Jul 2, 2026
@github-merge-queue github-merge-queue Bot removed this pull request from the merge queue due to invalid changes in the merge commit Jul 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant