AGENTS.md
========

Build/Lint/Test Commands:
------------------------
- **Build**: `npm run dist`
- **Lint**: `npm run lint`
- **Test**: `npm test`
- **Single Test**: `npm run test:pw:run -- --grep="Test Name"`
- **Validate**: `npm run validate`
- **Watch**: `npm run watch`

Code Style Guidelines:
----------------------
- **Imports**: Use relative paths with `@` alias for core files
- **Formatting**: Prettier via Babel config
- **Types**: Use JSDoc for type annotations
- **Naming**: PascalCase for components, kebab-case for CSS classes
- **Error Handling**: Use try/catch with GF specific error codes
- **React**: Functional components with hooks
- **CSS**: PostCSS with CSS modules

CSS Architecture:
- BEM naming: `.block__element--modifier`
- Logical properties: Use `block-size`/`inline-size`
- Design tokens: Use `@gravityforms/design-tokens`
- PostCSS nesting for child selectors

React Best Practices:
- Avoid unnecessary effects (use useMemo for calculations)
- Use `@gravityforms/react-utils` for state management
- JSDoc required for ALL functions/components


Library Imports:
- Use `@gravityforms/libraries` for React, classnames, zustand
- Use `@gravityforms/utils` for debounce, deepMerge, etc.
