Skip to content
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

Feature-gate accessibility in bevy_ui #16312

Open
Niashi24 opened this issue Nov 9, 2024 · 1 comment
Open

Feature-gate accessibility in bevy_ui #16312

Niashi24 opened this issue Nov 9, 2024 · 1 comment
Labels
A-UI Graphical user interfaces, styles, layouts, and widgets C-Feature A new feature, making something new possible D-Straightforward Simple bug fixes and API improvements, docs, test and examples S-Ready-For-Implementation This issue is ready for an implementation PR. Go for it!

Comments

@Niashi24
Copy link
Contributor

Niashi24 commented Nov 9, 2024

What problem does this solve or what need does it fill?

Due to bevy_ui's dependency on accesskit (and bevy_a11y) which depends on std, bevy_ui cannot currently support no_std. However, UI is foundational to many games, and other features of bevy_ui that would not depend on std (especially layouting) would be great to have in no_std. While accessibility features may be valuable to have in no_std, we are currently blocked on the ecosystem. In the meantime, these features should be feature-gated out of bevy_ui to allow for future no_std support.

What solution would you like?

Add an accessibility feature and gate integration with accesskit and bevy_a11y behind it. This should be enabled by default.

What alternative(s) have you considered?

Break out the base UI Node and layouting systems into a separate crate (bevy_layout?) that could then be made no_std on its own. This could be confusing for people but also might be worth it if bevy_ui gets too big in the future.

Additional context

no_std support for bevy_ui is also currently blocked on no_std support for bevy_ecs and bevy_app (#15460), and a dependency with bevy_render (#16313). These can be done in parallel however.

@Niashi24 Niashi24 added C-Feature A new feature, making something new possible S-Needs-Triage This issue needs to be labelled labels Nov 9, 2024
@BenjaminBrienen BenjaminBrienen added A-Accessibility A problem that prevents users with disabilities from using Bevy A-UI Graphical user interfaces, styles, layouts, and widgets S-Ready-For-Implementation This issue is ready for an implementation PR. Go for it! D-Straightforward Simple bug fixes and API improvements, docs, test and examples and removed S-Needs-Triage This issue needs to be labelled A-Accessibility A problem that prevents users with disabilities from using Bevy labels Nov 9, 2024
@DataTriny
Copy link
Contributor

FYI the core of AccessKit, that is the accesskit crate, is no-std compatible now. Since the other adapter crates are meant to be compiled only on the relevant platforms, bevy_ui can keep AccessKit support and still be no-std compatible without a feature.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-UI Graphical user interfaces, styles, layouts, and widgets C-Feature A new feature, making something new possible D-Straightforward Simple bug fixes and API improvements, docs, test and examples S-Ready-For-Implementation This issue is ready for an implementation PR. Go for it!
Projects
None yet
Development

No branches or pull requests

3 participants