-
Notifications
You must be signed in to change notification settings - Fork 10.8k
Consistently display shortcodes with square brackets in WooCommerce system status report #59687
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
Consistently display shortcodes with square brackets in WooCommerce system status report #59687
Conversation
📝 WalkthroughWalkthroughThe change updates the display logic for shortcodes in the WooCommerce admin status report. It ensures that all shortcodes are shown with square brackets, regardless of how they are stored, by programmatically adding brackets if they are missing before displaying them. Additionally, the PR template guidance was clarified to prohibit removal of checkbox items. Changes
Sequence Diagram(s)sequenceDiagram
participant Admin as Admin User
participant WooAdmin as WooCommerce Admin Page
Admin->>WooAdmin: View status report
WooAdmin->>WooAdmin: Retrieve page shortcodes
WooAdmin->>WooAdmin: Check if shortcode has brackets
alt Brackets missing
WooAdmin->>WooAdmin: Add square brackets to shortcode
end
WooAdmin->>Admin: Display shortcode with square brackets
📜 Recent review detailsConfiguration used: .coderabbit.yml 📒 Files selected for processing (1)
✅ Files skipped from review due to trivial changes (1)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (24)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. 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
Documentation and Community
|
Test using WordPress PlaygroundThe changes in this pull request can be previewed and tested using a WordPress Playground instance. Test this pull request with WordPress Playground. Note that this URL is valid for 30 days from when this comment was last updated. You can update it by closing/reopening the PR or pushing a new commit. |
Testing GuidelinesHi @albarin , Apart from reviewing the code changes, please make sure to review the testing instructions (Guide) and verify that relevant tests (E2E, Unit, Integration, etc.) have been added or updated as needed. Reminder: PR reviewers are required to document testing performed. This includes:
|
- **Remove Irrelevant Sections:** You may erase template sections that are not applicable to your PR, except for those required by automation. | ||
- **Remove Irrelevant Sections:** You may erase template sections that are not applicable to your PR, except for those required by automation. Do not remove any checkbox items. |
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.
I've included a minor tweak to the PR description rules for cursor to improve generation.
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.
Submission Review Guidelines:
Changes proposed in this Pull Request:
This PR addresses the inconsistency in shortcode display within the WooCommerce Status "WooCommerce pages" box. Previously, the My Account page showed shortcodes with square brackets (e.g.,
[woocommerce_my_account]
) while Cart and Checkout pages showed them without brackets (e.g.,woocommerce_cart
,woocommerce_checkout
).The fix ensures all shortcodes are displayed consistently with square brackets for better clarity and consistency across the status report.
Closes #59673.
Screenshots or screen recordings:
Checkout: "Contains the woocommerce_checkout shortcode"
My Account: "Contains the [woocommerce_my_account] shortcode"
Checkout: "Contains the [woocommerce_checkout] shortcode"
My Account: "Contains the [woocommerce_my_account] shortcode"
How to test the changes in this Pull Request:
Changelog entry
Changelog Entry Details
Significance
Type
Message
Fix inconsistent shortcode display in WooCommerce Status pages section. This improvement ensures consistent formatting of shortcode display in the WooCommerce Status "WooCommerce pages" box, making all shortcodes appear with square brackets for better clarity and consistency.
Changelog Entry Comment
Comment