自定义webix标头

时间:2016-11-15 20:38:54

标签: javascript jquery webix

是否可以自定义webix UI标题,如图像1中的标题。我想提供一个图像,一个标题,一个带有注销按钮的欢迎用户行,以及一个导航到其他页面的菜单栏?请点击1,您将获得图像。

2 个答案:

答案 0 :(得分:0)

是的,您可以使用工具栏小部件实现这一目标:

{
  view:'toolbar', 

  css:'header', 
  elements: [
    { view: "label", label: "", width: 100, height: 38, css:'app-logo' },
    { view: "label", label: "My app" },
    {},
    {
      view: "button",
      type: "icon",
      id: 'app:toolbar:current_user_menu',
      icon: 'user',
      borderless: true,
      autowidth: true,
      label: 'Jean bombeur'
    }
   ]

}

然后自定义app-logo css类以获得徽标的背景图片。

请参阅演示代码段:http://webix.com/snippet/4f6131d3

答案 1 :(得分:0)

您可以通过提供自己的html格式化标题,例如:

{id:"col1", header:"<input type='button' value='Do something' class='dummy_button'>"}

通过添加样式(css),您可以根据自己的要求进行设计。

相关问题