RTE Styleselect value changes and not syncing when...
# help-with-umbraco
h
It appears as though the value for the 'style select' toolbar option has changed in the TinyMCE json configuration from 'styleselect' to 'styles'. This doesn't appear to be mapping when using usync to import these files. We're using the latest version of Umbraco 13 (13.0.2 at time of writing) and uSync (13.0.1). Saving down the property serialised the usync file back down to the new value (which is how I identified the change) but it's not clear this is required - might be a required change to usync possible to convert this value when importing (or at least display an error if it's present) https://cdn.discordapp.com/attachments/1199687789453787176/1199688505475989608/image.png?ex=65c373fc&is=65b0fefc&hm=5cc2091a9f4ac966ddacafb2220eb8ed15b8e66c54648ed88bd75480704daee6& https://cdn.discordapp.com/attachments/1199687789453787176/1199688505719279697/image.png?ex=65c373fc&is=65b0fefc&hm=519207b1b0e84f8df4b19f7d3bd577ab278b1321df7a7f129a3b853f6c08a01c&
@Kevin Jump apologies for the ping on this one. I did have a good look both in the repo and this discord to see if this had been mentioned elsewhere but I couldn't see anything Pre and post umbraco upgrade screenshots of usync files attached. Let me know if you'd like me to raise as a github issue or even a PR if I can find time - it's not urgent as manually updating the value in the usync config has solved it for us but it will revert to the old value on export I'm also not sure/not aware of any other properties that might have changed
k
Hi, I will take a look, but uSync doesn't (Usually) look into the config of datatypes - we are just serialzing the config object in and outso we don't actually know if this property is there or not. 🤔 We could look at adding a IConfigurationSerializer for RTE where we could load it up and take a look at fixing it... If you wanted to do this before we get around to it 😉 you can see the ones that exist now here https://github.com/KevinJump/uSync/tree/v13/main/uSync.Community.DataTypeSerializers/CoreTypes it would be very similar to one of these but with the RTE Configuration.
Humm.. i get this - but just to confirm on v10 its "styleselect" and on v13 its "styles" - but in your screenshot it says "stylesheet" ? not sure where thats from ?
h
Sorry, you're absolutely right it should be styleselect - confession time, I manually typed it in (wrong) for the purpose of the screenshot 😅
I can take a look if I get time a bit later 👍
In that case I wonder if it's Umbraco that needs the fix then, I guess the problem being that the value has obviously changed but (rightly) the existing usync config files haven't. Would we be expecting Umbraco to handle the mapping of old to new value?
https://github.com/umbraco/Umbraco-CMS/blob/contrib/src/Umbraco.Web.UI.Client/src/views/propertyeditors/rte/rte.prevalues.controller.js#L184-L189 Interestingly (from my limited knowledge) this seems to imply that either alias would be fine/supported but in practice does not seem to be the case
k
yeah - it could be seen as a migration thing (and maybe there is a migration somewhere in umbraco to map these values as part of an upgrade ? ) but that would still mean moving from v10 -> v13 with uSync will loose this value, so i think we will need a mapper, and we will get around to doing it at some point 😄 (i've checkd and its the only one of the toolbar values to change). -
h
Awesome, thanks Kevin. I'll see what I can do also
Cheers for taking a look
k
w
@Kevin Jump does your PRs generate CI/nightly build at all?
k
No, but i can push one out...
(don't do
--preview
as you will get the v13.1 beta - which doesn't have this fix in it!)
w
OK thanks appreciate it - will look tomorrow and tripple check it fixes it (but looking at the PR, don't see why it wouldn't)
h
Wow super fast - I hadn't even cloned it yet 😅 thank you Kevin
39 Views