Deploy dev to stage — webhook user_metadata fix, textarea, initStripe #135

Merged
will.anderson merged 3 commits from dev into stage 2026-05-12 17:50:12 +00:00
Owner

Merges dev into stage to deploy PR #134 fixes:

  • supabase_admin_update_user: always stamp plan/name/stripe_customer_id after payment
  • waitlist_upsert: on_conflict=email,plan (true upsert)
  • initStripe load order fix
  • subscription webhook email extraction fix
  • chat textarea auto-resize UX
Merges dev into stage to deploy PR #134 fixes: - supabase_admin_update_user: always stamp plan/name/stripe_customer_id after payment - waitlist_upsert: on_conflict=email,plan (true upsert) - initStripe load order fix - subscription webhook email extraction fix - chat textarea auto-resize UX
will.anderson added 3 commits 2026-05-12 17:50:00 +00:00
Fix initStripe load order, subscription webhook email extraction, chat textarea UX
Dev — Build & local smoke test / build-smoke (pull_request) Successful in 1m18s
c72127032e
- checkout.el: swap stripe_el_script before auth_script so initStripe is
  defined when Supabase auth fires onAuthStateChange on page load
- main.el: fix Stripe webhook email extraction for checkout.session.completed
  (subscription) events — customer_details is nested at data.object level,
  not at root; previous code only worked for payment_intent.succeeded
- page_close.c: replace <input type="text"> with <textarea rows="1"> in
  the chat widget input row so long questions are visible as you type
- page_css.c: update #neuron-demo-text CSS for textarea (resize:none,
  overflow:hidden, min/max-height, align-items:flex-end on row)
- chat-widget.el: add auto-resize event listener (grows up to ~4 lines),
  reset height to auto on send
Fix webhook failing to update plan for pre-existing Supabase users
Dev — Build & local smoke test / build-smoke (pull_request) Successful in 1m17s
99ed8b85f7
supabase_admin_invite re-sends a magic link for users who already have
an account (e.g. signed up via attestation before paying) but does not
touch their user_metadata — leaving plan as "free" after purchase.

Fix: add supabase_admin_update_user (PUT /auth/v1/admin/users/{id})
and call it after every invite so user_metadata is always stamped with
the correct plan, name, and stripe_customer_id. Idempotent for new and
returning users.

Also fix waitlist_upsert to use on_conflict=email,plan so the upsert
works for users who already have a waitlist row from attestation,
rather than silently failing on duplicate key.
Merge PR #134: Fix initStripe load order, webhook user_metadata, chat textarea
will.anderson merged commit b5285ccb74 into stage 2026-05-12 17:50:12 +00:00
Sign in to join this conversation.
No Reviewers
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: neuron-technologies/neuron-web#135