Skip to content

fix(action-sheet): forward open-type callbacks - #6093

Merged
rex-zsd merged 1 commit into
youzan:devfrom
rex-zsd:codex/fix-action-sheet-open-type
Oct 10, 2026
Merged

rex-zsd merged 1 commit into
youzan:devfrom
rex-zsd:codex/fix-action-sheet-open-type

Conversation

@rex-zsd

@rex-zsd rex-zsd commented Oct 10, 2026

Copy link
Copy Markdown
Collaborator

ActionSheet actions using agreePrivacyAuthorization or getRealtimePhoneNumber did not forward native button results to their documented component events. Bind the existing handlers and support actions[].buttonId as the native button ID, allowing custom privacy authorization flows to resolve the correct button.

Document the new action option and synchronize the affected dist and lib templates.

Validation:

  • Existing ActionSheet, Button and Dialog tests: 4 suites, 5 tests and 3 snapshots passed.
  • In-memory miniprogram-simulate verification passed for per-action button IDs, both callbacks and the combined getRealtimePhoneNumber|agreePrivacyAuthorization open type.
  • Generated templates match the source; git diff --check passed.

@rex-zsd
rex-zsd requested a balanced review from Copilot October 10, 2026 05:34
@rex-zsd
rex-zsd merged commit 635866b into youzan:dev Oct 10, 2026
4 checks passed

Copilot AI 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.

🟢 Approval recommended

The callback forwarding and button-ID support are consistent across all templates with no unresolved issues.

0 open findings

What changed in this PR

Forwards ActionSheet native button callbacks and supports per-action button IDs.

Changes:

  • Binds real-time phone and privacy authorization callbacks.
  • Adds and documents actions[].buttonId.
  • Synchronizes source, lib, and dist templates.
File Description
packages/​action-sheet/​README.md Documents buttonId.
packages/​action-sheet/​index.wxml Adds IDs and callback bindings.
lib/​action-sheet/​index.wxml Synchronizes library template.
dist/​action-sheet/​index.wxml Synchronizes distribution template.

🧠 Review effort: Balanced


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants