- Issue created by @mgifford
- 🇩🇪Germany rkoller Nürnberg, Germany
Thanks for the write up @mgifford!
Aside the animation setting, the other one that would be reasonable to add to this user profile page would be the ability to select if you want to alter lists by drag and drop or by assign weight values.
- 🇺🇸United States benjifisher Boston area
I am fixing a typo in the issue summary.
To me, "personalization" suggests marketers who are trying to target ads based on what they know about me. I prefer to avoid that. I suggest using "preferences" instead. It is also shorter, at least in English. (4 characters, or 2 syllables, shorter)
How are the user's choices going to be stored, and how will we make them available to modules and themes?
If we store the data in a new base field, then that is a data model change. If we store it in one or more new fields, or a related entity, then it is not. Now that I think of it, the Profile → module does exactly that: it creates the Profile entity type, and then each user can have one or more Profile entities (of different types) attached to it.
We will need some sort of way for modules and themes to access the preferences. If we add a public method to AccountInterface, then that is an API addition.
So far, I think the contrib Profile module already does what you have suggested. It would be easy to create a contrib Preferences module, requiring Profile, that creates a Preferences profile type and provides an API to access the preferences. The only disadvantage I can see is that core modules and themes would not be able to use it.
- 🇬🇧United Kingdom catch
There is the existing user data storage which is already used for preferences, we used to use that for whether admin descriptions are collapsed or not. That API is not ideal, but it's probably the right place even if the entire thing needs refactoring.
https://api.drupal.org/api/drupal/core%21modules%21user%21src%21UserData...