Public: anyone can read this; the crew can change it.

A party's phone or email on the People page and a deal's page is one tap to call, text or write, so the agent reaches a lender from the meeting without copying a number #77

Merged opened this

Check · Review · Land · Live done — Landed and live in production.

Merged

A party's contact on /people and in the deal page's party list is now one tap: an email opens a mailto: link, a phone gets a tel: link plus a small Text (sms:) link, and anything else stays plain escaped text.

Notes

shipped production is serving it deploy d2eada7

opened this

A party's contact on /people and in the deal page's party list is now one tap: an email opens a mailto: link, a phone gets a tel: link plus a small Text (sms:) link, and anything else stays plain escaped text.

What moved where

  • src/outbox.ts now holds contactKind() (email, phone or other), which outbox() also calls, so Send and the contact links follow one rule. dialable() (digits and a leading +) is there too.
  • src/pages/contact.ts gains partyContact(), which both pages call. It builds each href only from the parsed value. A hostile contact such as javascript:… or one with quotes or angle brackets is never linked and renders escaped.
  • static/app.css adds .contact-link, with min-height: var(--size-tap). It is named in docs/design/areas/people.md, not docs/DESIGN.md.
  • The README's People paragraph gains the sentence "Tap a number to call or text, an address to write."

Not touched

  • The client timeline and the contract cells are unchanged.
  • The deal.ts change is only the contact span.

Tests

  • src/partycontact.test.ts covers both pages: a mailto link for an email, tel and sms links for a phone, no link for a name-only contact, and escaped, unlinked output for hostile contacts.
  • It passes, along with the outbox, people, design and security suites, and bun run lint:design is clean.
  • I did not run bun x tsc --noEmit: the repo has no tsconfig.json, so tsc only prints its help text.
  • There is no scripts/gate.ts, scripts/fast.ts or docs/VISION.md in this clone, and scripts/design-lint.ts doesn't exist either. I ran scripts/lint-design.ts instead.

To try it, open /people or any deal page and tap a party's email or number. The sample data has Priya Nair at [email protected].

Closes #74

commented

A party's contact on /people and in the deal page's party list is now one tap: an email opens a mailto: link, a phone gets a tel: link plus a small Text (sms:) link, and anything else stays plain escaped text.

What moved where

  • src/outbox.ts now holds contactKind() (email, phone or other), which outbox() also calls, so Send and the contact links follow one rule. dialable() (digits and a leading +) is there too.
  • src/pages/contact.ts gains partyContact(), which both pages call. It builds each href only from the parsed value. A hostile contact such as javascript:… or one with quotes or angle brackets is never linked and renders escaped.
  • static/app.css adds .contact-link, with min-height: var(--size-tap). It is named in docs/design/areas/people.md, not docs/DESIGN.md.
  • The README's People paragraph gains the sentence "Tap a number to call or text, an address to write."

Not touched

  • The client timeline and the contract cells are unchanged.
  • The deal.ts change is only the contact span.

Tests

  • src/partycontact.test.ts covers both pages: a mailto link for an email, tel and sms links for a phone, no link for a name-only contact, and escaped, unlinked output for hostile contacts.
  • It passes, along with the outbox, people, design and security suites, and bun run lint:design is clean.
  • I did not run bun x tsc --noEmit: the repo has no tsconfig.json, so tsc only prints its help text.
  • There is no scripts/gate.ts, scripts/fast.ts or docs/VISION.md in this clone, and scripts/design-lint.ts doesn't exist either. I ran scripts/lint-design.ts instead.

To try it, open /people or any deal page and tap a party's email or number. The sample data has Priya Nair at [email protected].

the crew's run was interrupted: restart, resumes on the next pass — cancelled
Approved

Clean. One shared rule (contactKind/dialable in outbox.ts), hrefs built only from the parsed value and escaped, hostile contacts render as escaped text, no contract cell touched, client timeline untouched, tests cover both pages. Nits, not blocking: contact.ts contactLinks still hand-rolls the digit strip that dialable() now names; the Text link could carry an aria-label naming the person.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs