Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
I am trying to implement localization within a propriatary custom visual. However I was able to reproduce the issue within a starter custom visual which you can find in this github:
Basically I am following the instructions for implementing localization from the main wiki page:
Add the locale in Power BI for Power BI visuals - Power BI | Microsoft Learn
However, the localization manager does not seem to be pulling the displayNameKey; nor the descriptionKey; ids assigned to the dataRoles in the capabilities.json nor the settings.ts file, correctly. Instead I get this:
I have done the following steps:
I'm unsure what I am doing wrong. I tried looking at other microsoft repositories and they appear to be doing the same thing I was doing:
microsoft/powerbi-visuals-heatmap: powerbi-visuals-heatmap (github.com)
Any help would be most appreciative.
Solved! Go to Solution.
Hi @timseltman - are you looking at the developer visual or the packaged visual? Historically, this has only worked when you package the visual and test that.
It looked like they recently made a change in powerbi-visuals-tools 4.0.7 to try and support this, but quickly rolled it back due to vulnerabilities, so may appear again in the near future.
Regards,.
Daniel
Proud to be a Super User!
My course: Introduction to Developing Power BI Visuals
On how to ask a technical question, if you really want an answer (courtesy of SQLBI)
Hi @timseltman - are you looking at the developer visual or the packaged visual? Historically, this has only worked when you package the visual and test that.
It looked like they recently made a change in powerbi-visuals-tools 4.0.7 to try and support this, but quickly rolled it back due to vulnerabilities, so may appear again in the near future.
Regards,.
Daniel
Proud to be a Super User!
My course: Introduction to Developing Power BI Visuals
On how to ask a technical question, if you really want an answer (courtesy of SQLBI)
After testing this morning, you are correct. It appears that in order to test if the localization is working, I have to package the visual and test it as if it is the final product. It does not appear that the description key is working though (nothing happens when I hover over the labels; even though I have set up description keys for each), so I may have to default that to English for the time being. But otherwise this just adds to the testing of the program. Either way this answers my question. Hopefully in the future, description keys work properly and we are able to test localization in developer view.
Edit: after further testing, the hovering appears to be weird when using English. In Spanish, the hover works just fine, but not so in English. Nothing appears when I hover over the labels. Not sure if it is a bug or what.
I am working with the developer visual and have not tested as a package. I am working with powerbi-visuals-tools version 4.0.8; along with upgrading all modules to their latest version (including powerbi-visuals-api to 5.2.0). I will attempt to test this tomorrow and I'll let you know the result.
Check out the September 2024 Power BI update to learn about new features.
Learn from experts, get hands-on experience, and win awesome prizes.
User | Count |
---|---|
27 | |
11 | |
8 | |
6 | |
6 |