forked from antonafana/node-brightness
-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Feature Request: Multi-platform Operating System Support
Description
Currently, node-brightness appears to have limited operating system support. It would be great to extend the library to support multiple operating systems including Windows, macOS, and various Linux distributions.
Current Status
The library seems to be primarily focused on Linux systems. Cross-platform compatibility would greatly increase its usability for Node.js applications that need to run on different operating systems.
Proposed Enhancement
Add support for:
- Windows: Utilize WMI (Windows Management Instrumentation) or Windows API calls to control screen brightness
- macOS: Use Core Graphics framework or AppleScript for brightness control
- Linux: Maintain current functionality while ensuring compatibility across different distributions
Implementation Suggestions
- Implement OS detection to determine the current platform
- Create platform-specific modules for brightness control
- Provide a unified API that abstracts the underlying OS differences
- Add comprehensive error handling for unsupported platforms
- Include platform-specific installation instructions and dependencies
Benefits
- Broader adoption of the library across different development environments
- Simplified cross-platform development for applications requiring brightness control
- More robust error handling and user feedback
Additional Considerations
- Consider adding TypeScript definitions for better developer experience
- Include platform-specific examples in the documentation
- Add automated testing across different operating systems in CI/CD pipeline
Would be happy to contribute to this enhancement if there's interest from the maintainers!
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels