Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR applies PHPCS (PHP CodeSniffer) auto-fixes to JavaScript files and PHP tooling to enforce consistent code formatting across the module. The changes standardize brace placement, add required visibility modifiers, and ensure proper code style compliance.
Key changes:
- JavaScript functions now use opening braces on new lines consistent with the module's coding standard
- PHP constants in test class now have required public visibility modifiers
- Added proper guard clauses with braces for improved readability
Reviewed Changes
Copilot reviewed 10 out of 12 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
| tools/validate_ics.php | Updated function brace placement to match coding standards |
| tests/Controller/CalendarSubscriptionTest.php | Added required public visibility modifiers to class constants |
| client/src/js/components/*.js | Standardized JavaScript function brace placement and added braces to single-line conditionals |
| client/src/js/calendar.js | Applied consistent brace formatting to class methods |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
There was a problem hiding this comment.
The CSS class name contains spaces around the hyphens which will create invalid class names. Should be swipe-indicator swipe-${direction}.
| indicator.className = `swipe - indicator swipe - ${direction}`; | |
| indicator.className = `swipe-indicator swipe-${direction}`; |
There was a problem hiding this comment.
The URL construction is incorrect - there's a space before the question mark. Should be ${baseUrl}events?${params.toString()}.
| return `${baseUrl}events ? ${params.toString()}`; | |
| return `${baseUrl}events?${params.toString()}`; |
There was a problem hiding this comment.
The HTML template has spaces around operators that will result in invalid HTML attributes. The spaces around <, =, and - should be removed.
There was a problem hiding this comment.
The HTML template has spaces around the < operator and = signs that will result in invalid HTML. Should be <div class=\"alert alert-warning\">.
Summary
Testing