Skip to content

Commit 51e4983

Browse files
committed
Config file updates. Agent, docs and instructions file clean up. Test fixes and javascript fixes
1 parent 87cd8fc commit 51e4983

File tree

227 files changed

+26625
-4620
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

227 files changed

+26625
-4620
lines changed

.babelrc.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
"presets": [ "@wordpress/babel-preset-default" ]
2+
"presets": ["@wordpress/babel-preset-default"]
33
}

.coderabbit.yml

Lines changed: 105 additions & 105 deletions
Original file line numberDiff line numberDiff line change
@@ -1,111 +1,111 @@
11
$schema: https://coderabbit.ai/integrations/coderabbit-overrides.v2.json
2-
language: "en"
2+
language: 'en'
33
chat:
4-
auto_reply: true
4+
auto_reply: true
55
reviews:
6-
request_changes_workflow: true
7-
high_level_summary: true
8-
poem: false
9-
review_status: true
10-
collapse_walkthrough: true
6+
request_changes_workflow: true
7+
high_level_summary: true
8+
poem: false
9+
review_status: true
10+
collapse_walkthrough: true
1111
path_filters:
12-
- "!build/**"
13-
- "!node_modules/**"
14-
- "!assets/css/*.map"
15-
- "!logs/**"
12+
- '!build/**'
13+
- '!node_modules/**'
14+
- '!assets/css/*.map'
15+
- '!logs/**'
1616
auto_review:
17-
enabled: true
18-
drafts: false
19-
base_branches:
20-
- "main"
21-
- "develop"
22-
- "feature/*"
23-
- "fix/*"
24-
- "update/*"
17+
enabled: true
18+
drafts: false
19+
base_branches:
20+
- 'main'
21+
- 'develop'
22+
- 'feature/*'
23+
- 'fix/*'
24+
- 'update/*'
2525
path_instructions:
26-
- path: "**/theme.json"
27-
instructions: |
28-
Review theme.json configuration for WordPress block themes:
29-
- Ensure JSON syntax is valid and properly formatted
30-
- Verify color palettes use named tokens consistently (primary, secondary, accent)
31-
- Check typography settings include complete font definitions with fluid clamp() values
32-
- Validate spacing scales are consistent and use rem units
33-
- Confirm layout settings define appropriate contentSize and wideSize values
34-
- Ensure all settings follow WordPress block theme standards
35-
- Check accessibility compliance with sufficient color contrast ratios (4.5:1 minimum)
36-
- Verify compatibility with Full Site Editing (FSE) features
37-
- Validate custom properties don't conflict with core block functionality
38-
- path: "**/patterns/*.php"
39-
instructions: |
40-
Review WordPress block patterns for FSE compatibility:
41-
- Ensure proper pattern registration using register_block_pattern() function
42-
- Verify pattern naming follows lsx/[category]-[name] convention
43-
- Check that patterns use theme.json variables exclusively for styling
44-
- Validate proper heading hierarchy and accessibility compliance
45-
- Ensure placeholder content is realistic and appropriate
46-
- Check patterns maintain design integrity with different content lengths
47-
- Verify patterns are responsive and work across all viewport sizes
48-
- Confirm patterns avoid inline styles and use block variations appropriately
49-
- Validate proper block nesting and semantic HTML structure
50-
- Test that patterns follow WordPress coding standards for PHP
51-
- path: "**/parts/*.html"
52-
instructions: |
53-
Review WordPress template parts for block theme compatibility:
54-
- Ensure template parts follow WordPress HTML template structure
55-
- Verify proper use of WordPress block markup
56-
- Check semantic HTML elements and proper heading hierarchy
57-
- Validate accessibility features (ARIA roles, alt attributes)
58-
- Ensure template parts use theme.json variables for styling
59-
- Check compatibility with Full Site Editing interface
60-
- Verify proper block structure and nesting
61-
- Validate responsive design across different screen sizes
62-
- path: "**/templates/*.html"
63-
instructions: |
64-
Review WordPress block templates for FSE:
65-
- Ensure templates follow WordPress block template structure
66-
- Verify proper template hierarchy and naming conventions
67-
- Check integration with template parts and patterns
68-
- Validate proper query loop implementation for dynamic content
69-
- Ensure templates maintain design consistency
70-
- Check accessibility compliance throughout templates
71-
- Verify responsive behavior and layout integrity
72-
- path: "**/functions.php"
73-
instructions: |
74-
Review functions.php for WordPress block theme:
75-
- Ensure theme setup follows WordPress block theme standards
76-
- Verify proper theme support declarations for FSE features
77-
- Check secure coding practices (sanitization, validation, escaping)
78-
- Validate proper hook usage and WordPress coding standards
79-
- Ensure compatibility with latest WordPress version
80-
- Check for performance optimization in theme functions
81-
- Verify proper asset enqueueing and dependency management
82-
- Ensure functions don't conflict with block editor functionality
83-
- path: "**/*.{css,scss}"
84-
instructions: |
85-
Review CSS/SCSS for WordPress block theme:
86-
- Prefer theme.json configuration over custom CSS when possible
87-
- Ensure CSS enhances rather than replaces theme.json settings
88-
- Check for proper use of CSS custom properties from theme.json
89-
- Validate responsive design using consistent breakpoints
90-
- Ensure accessibility compliance in custom styles
91-
- Check for performance optimization (minimal CSS, efficient selectors)
92-
- Verify styles don't conflict with core WordPress block styles
93-
- Ensure proper CSS organization and maintainability
94-
- path: "**/e2e/*.{ts,js}"
95-
instructions: |
96-
Review Playwright end-to-end tests for WordPress block theme:
97-
- Ensure tests cover accessibility validation across all pages
98-
- Verify tests check responsive design at multiple breakpoints
99-
- Check tests validate Full Site Editing functionality
100-
- Ensure tests cover block pattern and template part functionality
101-
- Verify proper test structure, setup, and teardown
102-
- Ensure tests are reliable and not flaky
103-
- path: "**/src/js/*.js"
104-
instructions: |
105-
Review JavaScript for WordPress block theme:
106-
- Check for proper WordPress script enqueueing in functions.php
107-
- Validate accessibility enhancements don't conflict with core features
108-
- Ensure performance optimization and avoid unnecessary dependencies
109-
- Check compatibility with WordPress script loading patterns
110-
- Verify proper event handling and DOM manipulation
111-
- Ensure scripts work with both frontend and editor interfaces
26+
- path: '**/theme.json'
27+
instructions: |
28+
Review theme.json configuration for WordPress block themes:
29+
- Ensure JSON syntax is valid and properly formatted
30+
- Verify color palettes use named tokens consistently (primary, secondary, accent)
31+
- Check typography settings include complete font definitions with fluid clamp() values
32+
- Validate spacing scales are consistent and use rem units
33+
- Confirm layout settings define appropriate contentSize and wideSize values
34+
- Ensure all settings follow WordPress block theme standards
35+
- Check accessibility compliance with sufficient color contrast ratios (4.5:1 minimum)
36+
- Verify compatibility with Full Site Editing (FSE) features
37+
- Validate custom properties don't conflict with core block functionality
38+
- path: '**/patterns/*.php'
39+
instructions: |
40+
Review WordPress block patterns for FSE compatibility:
41+
- Ensure proper pattern registration using register_block_pattern() function
42+
- Verify pattern naming follows lsx/[category]-[name] convention
43+
- Check that patterns use theme.json variables exclusively for styling
44+
- Validate proper heading hierarchy and accessibility compliance
45+
- Ensure placeholder content is realistic and appropriate
46+
- Check patterns maintain design integrity with different content lengths
47+
- Verify patterns are responsive and work across all viewport sizes
48+
- Confirm patterns avoid inline styles and use block variations appropriately
49+
- Validate proper block nesting and semantic HTML structure
50+
- Test that patterns follow WordPress coding standards for PHP
51+
- path: '**/parts/*.html'
52+
instructions: |
53+
Review WordPress template parts for block theme compatibility:
54+
- Ensure template parts follow WordPress HTML template structure
55+
- Verify proper use of WordPress block markup
56+
- Check semantic HTML elements and proper heading hierarchy
57+
- Validate accessibility features (ARIA roles, alt attributes)
58+
- Ensure template parts use theme.json variables for styling
59+
- Check compatibility with Full Site Editing interface
60+
- Verify proper block structure and nesting
61+
- Validate responsive design across different screen sizes
62+
- path: '**/templates/*.html'
63+
instructions: |
64+
Review WordPress block templates for FSE:
65+
- Ensure templates follow WordPress block template structure
66+
- Verify proper template hierarchy and naming conventions
67+
- Check integration with template parts and patterns
68+
- Validate proper query loop implementation for dynamic content
69+
- Ensure templates maintain design consistency
70+
- Check accessibility compliance throughout templates
71+
- Verify responsive behavior and layout integrity
72+
- path: '**/functions.php'
73+
instructions: |
74+
Review functions.php for WordPress block theme:
75+
- Ensure theme setup follows WordPress block theme standards
76+
- Verify proper theme support declarations for FSE features
77+
- Check secure coding practices (sanitization, validation, escaping)
78+
- Validate proper hook usage and WordPress coding standards
79+
- Ensure compatibility with latest WordPress version
80+
- Check for performance optimization in theme functions
81+
- Verify proper asset enqueueing and dependency management
82+
- Ensure functions don't conflict with block editor functionality
83+
- path: '**/*.{css,scss}'
84+
instructions: |
85+
Review CSS/SCSS for WordPress block theme:
86+
- Prefer theme.json configuration over custom CSS when possible
87+
- Ensure CSS enhances rather than replaces theme.json settings
88+
- Check for proper use of CSS custom properties from theme.json
89+
- Validate responsive design using consistent breakpoints
90+
- Ensure accessibility compliance in custom styles
91+
- Check for performance optimization (minimal CSS, efficient selectors)
92+
- Verify styles don't conflict with core WordPress block styles
93+
- Ensure proper CSS organization and maintainability
94+
- path: '**/e2e/*.{ts,js}'
95+
instructions: |
96+
Review Playwright end-to-end tests for WordPress block theme:
97+
- Ensure tests cover accessibility validation across all pages
98+
- Verify tests check responsive design at multiple breakpoints
99+
- Check tests validate Full Site Editing functionality
100+
- Ensure tests cover block pattern and template part functionality
101+
- Verify proper test structure, setup, and teardown
102+
- Ensure tests are reliable and not flaky
103+
- path: '**/src/js/*.js'
104+
instructions: |
105+
Review JavaScript for WordPress block theme:
106+
- Check for proper WordPress script enqueueing in functions.php
107+
- Validate accessibility enhancements don't conflict with core features
108+
- Ensure performance optimization and avoid unnecessary dependencies
109+
- Check compatibility with WordPress script loading patterns
110+
- Verify proper event handling and DOM manipulation
111+
- Ensure scripts work with both frontend and editor interfaces

.devcontainer/devcontainer.json

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -34,15 +34,8 @@
3434
"[php]": {
3535
"editor.defaultFormatter": "bmewburn.vscode-intelephense-client"
3636
},
37-
"eslint.validate": [
38-
"javascript",
39-
"javascriptreact"
40-
],
41-
"stylelint.validate": [
42-
"css",
43-
"scss",
44-
"postcss"
45-
],
37+
"eslint.validate": ["javascript", "javascriptreact"],
38+
"stylelint.validate": ["css", "scss", "postcss"],
4639
"files.associations": {
4740
"*.php": "php",
4841
"*.html": "html"

.devcontainer/docker-compose.yml

Lines changed: 72 additions & 72 deletions
Original file line numberDiff line numberDiff line change
@@ -1,83 +1,83 @@
11
version: '3.8'
22

33
services:
4-
devcontainer:
5-
build:
6-
context: .
7-
dockerfile: Dockerfile
8-
volumes:
9-
- ..:/workspace:cached
10-
- wordpress-data:/var/www/html
11-
- node-modules:/workspace/node_modules
12-
command: sleep infinity
13-
networks:
14-
- wordpress-network
15-
depends_on:
16-
- db
4+
devcontainer:
5+
build:
6+
context: .
7+
dockerfile: Dockerfile
8+
volumes:
9+
- ..:/workspace:cached
10+
- wordpress-data:/var/www/html
11+
- node-modules:/workspace/node_modules
12+
command: sleep infinity
13+
networks:
14+
- wordpress-network
15+
depends_on:
16+
- db
1717

18-
wordpress:
19-
image: wordpress:latest
20-
ports:
21-
- "8080:80"
22-
environment:
23-
WORDPRESS_DB_HOST: db
24-
WORDPRESS_DB_USER: wordpress
25-
WORDPRESS_DB_PASSWORD: wordpress
26-
WORDPRESS_DB_NAME: wordpress
27-
WORDPRESS_DEBUG: "1"
28-
WORDPRESS_CONFIG_EXTRA: |
29-
define('WP_DEBUG_LOG', true);
30-
define('WP_DEBUG_DISPLAY', false);
31-
define('SCRIPT_DEBUG', true);
32-
define('SAVEQUERIES', true);
33-
volumes:
34-
- wordpress-data:/var/www/html
35-
- ..:/var/www/html/wp-content/themes/lswp-theme:cached
36-
networks:
37-
- wordpress-network
38-
depends_on:
39-
- db
18+
wordpress:
19+
image: wordpress:latest
20+
ports:
21+
- '8080:80'
22+
environment:
23+
WORDPRESS_DB_HOST: db
24+
WORDPRESS_DB_USER: wordpress
25+
WORDPRESS_DB_PASSWORD: wordpress
26+
WORDPRESS_DB_NAME: wordpress
27+
WORDPRESS_DEBUG: '1'
28+
WORDPRESS_CONFIG_EXTRA: |
29+
define('WP_DEBUG_LOG', true);
30+
define('WP_DEBUG_DISPLAY', false);
31+
define('SCRIPT_DEBUG', true);
32+
define('SAVEQUERIES', true);
33+
volumes:
34+
- wordpress-data:/var/www/html
35+
- ..:/var/www/html/wp-content/themes/lswp-theme:cached
36+
networks:
37+
- wordpress-network
38+
depends_on:
39+
- db
4040

41-
db:
42-
image: mariadb:10.6
43-
environment:
44-
MYSQL_ROOT_PASSWORD: root
45-
MYSQL_DATABASE: wordpress
46-
MYSQL_USER: wordpress
47-
MYSQL_PASSWORD: wordpress
48-
volumes:
49-
- db-data:/var/lib/mysql
50-
networks:
51-
- wordpress-network
52-
ports:
53-
- "3306:3306"
41+
db:
42+
image: mariadb:10.6
43+
environment:
44+
MYSQL_ROOT_PASSWORD: root
45+
MYSQL_DATABASE: wordpress
46+
MYSQL_USER: wordpress
47+
MYSQL_PASSWORD: wordpress
48+
volumes:
49+
- db-data:/var/lib/mysql
50+
networks:
51+
- wordpress-network
52+
ports:
53+
- '3306:3306'
5454

55-
phpmyadmin:
56-
image: phpmyadmin/phpmyadmin
57-
environment:
58-
PMA_HOST: db
59-
PMA_USER: root
60-
PMA_PASSWORD: root
61-
ports:
62-
- "8081:80"
63-
networks:
64-
- wordpress-network
65-
depends_on:
66-
- db
55+
phpmyadmin:
56+
image: phpmyadmin/phpmyadmin
57+
environment:
58+
PMA_HOST: db
59+
PMA_USER: root
60+
PMA_PASSWORD: root
61+
ports:
62+
- '8081:80'
63+
networks:
64+
- wordpress-network
65+
depends_on:
66+
- db
6767

68-
mailhog:
69-
image: mailhog/mailhog
70-
ports:
71-
- "8025:8025"
72-
- "1025:1025"
73-
networks:
74-
- wordpress-network
68+
mailhog:
69+
image: mailhog/mailhog
70+
ports:
71+
- '8025:8025'
72+
- '1025:1025'
73+
networks:
74+
- wordpress-network
7575

7676
volumes:
77-
wordpress-data:
78-
db-data:
79-
node-modules:
77+
wordpress-data:
78+
db-data:
79+
node-modules:
8080

8181
networks:
82-
wordpress-network:
83-
driver: bridge
82+
wordpress-network:
83+
driver: bridge

0 commit comments

Comments
 (0)