-
Couldn't load subscription status.
- Fork 5.5k
Modifying message content for approval workflow actions #15649
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎ 3 Skipped Deployments
|
WalkthroughThis pull request updates the approval workflow actions for both Gmail and Slack components. In the Gmail action, it introduces a new optional property Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant GmailModule as Gmail Action
participant EmailServer
User->>GmailModule: Request approval email
alt Custom body provided?
GmailModule->>GmailModule: Concatenate custom body with approval text (with <br> formatting)
else
GmailModule->>GmailModule: Use default approval text
end
GmailModule->>EmailServer: Send email
sequenceDiagram
participant User
participant SlackModule as Slack Action
participant SlackServer
User->>SlackModule: Request approval message
SlackModule->>SlackModule: Build message with updated description and button styles ("primary" & "danger")
SlackModule->>SlackServer: Send Slack message
Possibly related PRs
Suggested labels
Suggested reviewers
Poem
Warning There were issues while running some tools. Please review the errors and either fix the tool’s configuration or disable the tool if it’s a critical failure. 🔧 ESLint
components/gmail/actions/approve-workflow/approve-workflow.mjsOops! Something went wrong! :( ESLint: 8.57.1 Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'jsonc-eslint-parser' imported from /eslint.config.mjs 📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
⏰ Context from checks skipped due to timeout of 90000ms (3)
🔇 Additional comments (4)
✨ Finishing Touches
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (2)
components/gmail/actions/approve-workflow/approve-workflow.mjs(2 hunks)components/slack/actions/approve-workflow/approve-workflow.mjs(4 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (3)
- GitHub Check: pnpm publish
- GitHub Check: Publish TypeScript components
- GitHub Check: Verify TypeScript components
🔇 Additional comments (3)
components/gmail/actions/approve-workflow/approve-workflow.mjs (1)
30-37: Verify the compatibility betweenbodyTypeand HTML formatting.The
bodyTypeproperty defaults to "plaintext", but the email body uses HTML line breaks (<br />). This might cause the line breaks to be displayed as raw HTML in the email.Consider one of these solutions:
- Change the default
bodyTypeto "html":- default: "plaintext", + default: "html",
- Use
\ninstead of<br />for plaintext formatting.components/slack/actions/approve-workflow/approve-workflow.mjs (2)
66-66: LGTM! Enhanced button styling improves visual hierarchy.The addition of "primary" and "danger" styles for the Approve and Cancel buttons respectively improves the user experience by making the actions more visually distinct and following Slack's design patterns.
Also applies to: 75-75
7-7: LGTM! Improved text clarity and consistency.The description improvements enhance readability:
- Properly capitalized "Slack" in the component description
- Simplified the message property description
Also applies to: 39-39
WHY
Summary by CodeRabbit