-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
Expose translationMetadata so we can retrieve the language files #20769
Comments
Frontend repo is not the right place for asking about changes to a websocket API, core implements those. That said I believe that is only for core translations. Translations in the frontend repo (like ui.common.close), I don't see how core could serve those since they are not present in the core repo, but I'm not super knowledgeable on that. |
@karwosts I didn't just ask about the websocket api, i also asked for the |
I still don't think this is the right place for this request, but I'll let it go for now. |
I'll re-phrase the question to suit the frontend |
frontend/get_translations
Checklist
Describe the issue you are experiencing
Currently, the front-end retrieves a lanaguage file to populate fields in the UI - from this url
/static/translations/en-c907c791db816c05eb6bad244e22784a.json
obviously the hash in this url is dynamic and currently there's no way to fetch these for an addon so we don't have to copy these translations again down into the addon directly which i see time and time again with custom integrations.I poked around in the frontend code and noticed there's a
translationMetadata
object which is used to retrieve the hash and this is populated at build time, it would be great to expose this somehow so that custom addons / external addons have the ability to utilize the work already gone into generating these locales.Describe the behavior you expected
It would be great if we could expose the
translationMetadata
object to the client so we can manually fetch the language file ourselvesSteps to reproduce the issue
No real steps to reproduce this issue, it's simply unavailable and bundled within the app.js code
What version of Home Assistant Core has the issue?
2024.5.0
What was the last working version of Home Assistant Core?
No response
In which browser are you experiencing the issue with?
Unrelated
Which operating system are you using to run this browser?
Unrelated
State of relevant entities
Problem-relevant frontend configuration
NA
Javascript errors shown in your browser console/inspector
Additional information
I think simply allowing this websocket call to allow "ui" as a category would be very beneficial!
The text was updated successfully, but these errors were encountered: