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

feat: React component interface #627

Open
5 tasks done
Neurrone opened this issue Jan 4, 2025 · 2 comments
Open
5 tasks done

feat: React component interface #627

Neurrone opened this issue Jan 4, 2025 · 2 comments
Assignees
Labels
enhancement New feature or request

Comments

@Neurrone
Copy link

Neurrone commented Jan 4, 2025

Feature Request

Description

For ease of use, it would be great if this was available as a React component.

The current use of a global variable is problematic in component-based applications.

Motivation

Grafana is mostly useless for screen reader users right now. Hence, I was prototyping the creation of a panel plugin that uses Maidr.

I quickly ran into issues because of the current requirement to use a script tag.

Proposed Solution

Provide a React component interface.

Additional Context

This would enable the library to be used more easily, encouraging adoption.

Checklist

  • I have searched for similar feature requests and confirmed that this is a new request.
  • I have provided a clear and concise description of the feature.
  • I have explained the motivation behind this feature request.
  • I have outlined a proposed solution or ideas for implementing this feature.
  • I have provided any additional context or screenshots if applicable.
@Neurrone Neurrone added the enhancement New feature or request label Jan 4, 2025
@jooyoungseo
Copy link
Member

@Neurrone Thanks for your feedback. We are currently working on a TypeScript migration of this project and will be addressing this issue as part of that. FYI, we have a Python binder that supports dashboard support (e.g., Streamlit, Shiny, etc.) Please feel free to check out Py maidr for more info.

@Neurrone
Copy link
Author

Neurrone commented Jan 5, 2025

Good to hear that this is planned.

About the Python bindings, do you have control over the generated HTML such that the current restriction of a single global isn't an issue? I'm curious how that issue was worked around.

The readme mentions that it needs a selector. I also notice that when using the galary, pressing the arrow keys does highlight the relevant portion of the chart. How is that implemented, and would I also need the selector to point to an SVG to use it with Maidr?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

5 participants