簡體   English   中英

Angular-slickgrid 不顯示自定義標題菜單項文本(只有標題菜單項圖標可見)

[英]Angular-slickgrid is not showing custom headermenu item text(Only headermenu item icon is visible)

我在角度應用程序中使用 angular-slickgrid。我想向 headermenu 添加更多菜單項。 下面是我正在使用的代碼:

 column.header = {
    menu: {
      items: [
        // add Custom Header Menu Item Commands at the bottom of the already existing internal custom items
        // you cannot override an internal command but you can hide them and create your own
        // also note that the internal custom commands are in the positionOrder range of 50-60,
        // if you want yours at the bottom then start with 61, below 50 will make your command(s) on top
        {
          iconCssClass: 'fa fa-question-circle',
          disabled: (column.id === 'effort-driven'), // you can disable a command with certain logic
          titleKey: 'GROUP', // use "title" as plain string OR "titleKey" when using a translation key
          command: 'group',
          positionOrder: 61
        }
      ]
    }
  };

在運行應用程序時,只有圖標是可見的,上面的標題菜單項沒有文本。附上屏幕截圖: 在此處輸入圖像描述

答案很可能在評論中

titleKey: 'GROUP', // use "title" as plain string OR "titleKey" when using a translation key

titleKey是當你使用翻譯時,你很可能沒有那個翻譯。 您應該只使用帶有常規文本的title ,這樣應該可以

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM