-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[5.0] [new feature] TinyMce sample image plugin #36968
Conversation
This is a toolbar icon for the tinymce editor that will let you quickly generate a placeholder image in your content. To test 1. Apply pr 2. rebuild the js with `npm run build:js` 3. Go to the tinymce plugin and drag the new icon to your toolbar 4. Go to any article and try it you
Why do you need that? I don't think this needs to come in core. Write a plugin and load it through the plugin feature if you need it. |
It speeds up development and makes life easier to build a site. Feedback was very positive when I showed the concept on FB. We have to start treating tinymce as a first class citizen. Instead we push people to use an editor that is old and outdate but has the extras people need. |
Don't agree here. The core should act as an example and doesn't need to compete out 3rd party extensions. Bloating the core with such useless features which will not bring any benefit to the users is a wrong direction. Instead of, you should tell the users how extensible the core editor is and make an example of this use case either in the official docs or in a magazine post. |
I couldnt disagree more |
I think the idea is good, can be useful for authors, it allow to format the article and replace images to final ones later. |
I don't think it should be in core if it's possible to do it with a Plugin. A 3rd Party Plugin could also use 3rd Party image services. |
I know, but that something that Writers would like to see in core. |
@HLeithner you are missing the point. Core must be usable and useful. It doesnt matter how fast the code is or how modern the code is. What matters is that users can use it. Why should they have to install a plugin for something that is 40 lines of code. You can make the argument about making it a 3rd party extension with every new feature added to core in J4. Workflows -> almost unusable in its current form without extra code. Schedule -> completely unusable without extra code. Media Manager - the least said abut the better. |
Forgot to add. I actually did some (rudimentary) user research before even starting this. When was the last time anyone did that |
TinyMCE has a feature where you can load TinyMCE plugins by adding it to the options. We do not talk here about a Joomla plugin. |
You can make this argument about everything. Its a stupid argument. We must make joomla usable. |
Show me how a joomla user can install that plugin. There is no functionality for that. |
@laoneo please do not forget that Joe Average does not have a skills to code it (and this plugin exists nowhere) 😉 |
@laoneo I am well aware of that option. Still doesn't answer the fact that there is no way on joomla to install that plugin. There has been more lines of comment than there has been code |
Again, publish your sample lines and tell the world how extensible it is.
Uploading it via FTP or the template editor is enough. There is really nothing to install here. Again, this is a great showcase how to use the plugin feature of TinyMCE. |
Copy paste is enough for the few people who are using it. |
I wonder how you would have reacted if I had told you to just write a blog post about custom fields. No need for that to be in the core. Just copy paste code, use ftp etc. |
It's ok, no need to shift away. I shared my opinion. Do whatever you guys want. It really doesn't matter if this feature is in or not at the end of the day. |
I have tested this item ✅ successfully on fa08447 This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/36968. |
closed due to lack of interest from release lead |
This pull request has been automatically rebased to 5.0-dev. |
I have tested this item 🔴 unsuccessfully on fa08447 "An error has occurred. This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/36968. |
|
a trace log would be helpful |
@HLeithner I really dont know why, but after I tested #36975 with the same result, I went back to here, installed again and the error is gone now... Inserting sample images works as expected. |
I have tested this item ✅ successfully on e2ada52 This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/36968. |
The error comes back when I remove the other new plugin (sample text) from the tinymce toolbar. After I tested it and left it there, the sample image worked. |
Nope, this can happen when $application not injected in to plugin while bootPlugin,
It nothing with events.
|
@fancyFranci did you tested iit for joomla 5 or 4? because title say 4,but the target is 5 :) |
I have tested this item 🔴 unsuccessfully on e2ada52 using J5.0-dev This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/36968. |
a trace log would be helpful |
The PR was created for Joomla 4.2 using tinymce 5. @HLeithner changed this to be for 5.0 but as that uses tinymce 6 and a reworked plugin tbh I wouldnt expect this to work at all. |
ok, so this fails j5. |
same as the other pr, why not using the template system for this? |
because the template system is not easily portable and is template dependent |
didn't we had a standard set/location in joomla too? or was this located only in Cassiopiea? Anyway tinymce deprecated the "simple" template system for there paid advanced template system. So we forked it and maybe @Fedik or @dgrammatiko or @laoneo has a nice idea for a better template system for such cases. |
Following code is looking for templates joomla-cms/plugins/editors/tinymce/src/Extension/TinyMCE.php Lines 65 to 67 in ad7796a
Not sure what exactly, I think @dgrammatiko know better. |
it maybe a good idea to have some default templates under |
That ajax fn just replaced the code that resolved the templates on startup (now it's per use case)
It's very easy to add one more lookup path in the code you linked above #36968 (comment) |
do it without me. wasted enough time on making a good editor for joomla already without an 18 month delay to everything |
This is a toolbar icon for the tinymce editor that will let you quickly generate a placeholder image in your content.
To test
npm run build:js
Plugin
Demo