2
votes

To start, I followed these directions exactly as it's stated: http://dev.day.com/docs/en/cq/5-6/developing/mobile/responsive.html

The problem is, despite all of that, my Devices dropdown on the sidekick in preview mode is empty.

The list works without issue in the Geometrixx Media without issue.

I made sure I set the cq:deviceGroups and the sling:OsgiConfig as required, and also included the simulator.js in the head tags.

Edit: I have found that if I set the resourceType on the root level page to geometrixx-media/components/page, which is their working demo, it works. I have completely removed all jsp and config items from that component page and it still continues to work anyways.

Does anyone know of something that is missing from the documents, and how to fix the issue?

Thanks.

1

1 Answers

1
votes

This is what I did to resolve this issue:

I am going to assume your application name is jason-riis

In CRXDE|Lite create a config folder in /apps/jason-riis/

Now create a node of:

TYPE=sling:OsgiConfig
NAME=com.day.cq.wcm.mobile.core.impl.MobileEmulatorProvider-<*alias>

*alias could be anything, I gave my application name. What it does is it will get you a unique PID when you look at it in configuration Manager

If you go to your configuration manager now, you should be able to see two MobileEmulatorProvider config settings.

Add a node property to node you just created:

NAME=mobile.resourceTypes
TYPE=String[] (you have to click multi at the end of the value textbox)
VALUE=jason-riis/components/<*page>

*page is all the components that has sling:resourceSuperType of foundation/components/page and it is a multi array so it should look like this

jason-riis/components/page, jason-riis/components/widepage, jason-riis/components/newspage

I assume you already have the cq:include for simulation in your header. This makes the devices button appear in preview mode.

Last thing is, go to your website root page's jcr:content [/content/jason-riis/jcr:content] and add node property

NAME=cq:deviceGroups
TYPE=String[]
*VALUE=/etc/mobile/groups/touch, /etc/mobile/groups/smart

*If you go to this etc path in CRXDE|Lite; you will see more relevant information in jcr:content node. This will help you in creating your own custom emulator list.

You should be able to see the dropdown now, with options of iPhone and iPad and all. I know AEM docs are frustrating, let me know if there is any confusion.