Rename the word "Collapse" in the Calcite design

262
3
06-05-2023 07:46 AM
GIS_test
New Contributor II

Hello everyone,

In the project below, how can I rename the word "Collapse"?

Project: https://codepen.io/pen?editors=1000

 

Collapse.PNG

Thank you for your help.

0 Kudos
3 Replies
KenBuja
MVP Esteemed Contributor

You'll have to provide a new link to your project

0 Kudos
GIS_test
New Contributor II
0 Kudos
UndralBatsukh
Esri Regular Contributor

Hi there, 

You will likely to get more responses if you post your question on calcite community: https://community.esri.com/t5/calcite-design-system/ct-p/calcite-design-system

 

Calcite developer page lets you interact with the different aspects of the component on their page. Then you can get the updated the code from the page and use it in your app. For action bar you can use this page: https://developers.arcgis.com/calcite-design-system/components/action-bar/

You can change the word under translations. For example for the collapse you can change the following way: 

<script>
    document.querySelector("calcite-action-bar").messageOverrides = {
        collapse: "Override message"
    };
</script>

 

This works with the latest version. I see that the codepen you provided is using beta version of the calcite. You may want to update your version so that the approach above works. If not you can ask the follow up question on the calcite community. 

0 Kudos