We'd like to be able to have widgets maintain UI state (eg. collapsible panels open/closed) and preferences for individual users. An example from Outlook, users can choose to have their Reading Pane displayed Right, Bottom, or Off. How might we go about doing something like this in Mendix? My first thought is to associate a UserPreference entity and associate these with the context entities (page parameters) and then use this for conditional visibility (still requires nesting Data Views to get access to the entity/attributes for this). This gets us some functionality, but what about using this for more specific state/attributes of a widget?
Your idea is definitely an option. Also you could think about different pages per user depending on the preferences and then linked to a UserPreference entity.