Hi, On Sun, Jan 28, 2018 at 5:45 PM, Istvan Devai <ist...@istvandevai.com> wrote:
> hi, > > When using resource references for linking to a CSS file, there is a > possibility to have multiple versions that can be selected via the style / > variation setting. > > What I'd like to achieve is, that the style / variation is picked based on > the page where the resource reference is used. > > This I can achieve currently by placing a wicket:link element in the > header: > > <head> > <wicket:link> > <link rel="stylesheet" type="text//css/" href="theme./css/"> > </wicket:link> > </head> > > This is all fine, however if I don't use the above "autolink" feature, > instead I'd like to add the reference as a HeaderItem in code, picking up > of the style / variation no more works. Looking into the source code, the > only path where style / variation info is read in this case if from > getSession().getStyle(), which is not OK for me, because I'd like to have > it set based on the page and not based on a global setting. > > Is there some way to make the HeaderItem aware of the page and pass the > style/variation info to the resource reference? > I think this is not supported at the moment. > > Thanks, > Istvan > >