Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
有没有办法用 Wicket 刷新标题组件,css 样式?
对于用户的操作,应用程序必须更改页面头部的 css 语句。目前我正在使用带有 wicket:head 部分和 CssContentHeaderItem 的 WebMarkupContainer,但这似乎并没有完成。
为什么要更改 css 语句?我假设您正在更改某些 css 类以确保所有带有“标签”类的东西现在都是绿色而不是红色(或者每个“标签”现在都是绿色而不是红色)。
为什么不简单地向组件添加一个不同的 css-class 并将两个类都保留在生成的 css 中?
也就是说,我相信向 ajaxrequest ( AjaxRequest#add) 添加组件也会调用该renderHead组件的方法。
AjaxRequest#add
renderHead