-
Notifications
You must be signed in to change notification settings - Fork 36
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
'Show controls' button should be ticked by default #38
Comments
I haven't tested this, but I'm guessing plugin.js line 25 should grab a value from the CKEditor's configuration? ckeditor-html5-video/html5video/plugin.js Line 25 in 15fc6b1
|
Yeah, the pattern used in a plugin like autosave would work well. Just have a new config like html5video that can can change the defaults here. |
jonespm
added a commit
to jonespm/ckeditor-html5-video
that referenced
this issue
Mar 6, 2021
…t and configurable
jonespm
added a commit
to jonespm/ckeditor-html5-video
that referenced
this issue
Mar 6, 2021
…t and configurable
if (editor.config) {
var getConfig = function(key, defaultVal = false) {
if (editor.config[`html5video_${key}`] != undefined) {
return editor.config[`html5video_${key}`];
} else if (editor.config.html5video && editor.config.html5video[key] != undefined) {
return editor.config.html5video[key];
} else {
return defaultVal;
}
}
this.setData('controls', getConfig('controls'));
this.setData('autoplay', getConfig('autoplay', 'no'));
this.setData('responsive', getConfig('responsive'));
} use example global config config.extraPlugins = 'html5video';
config.html5video = {
// controls: true,
// autoplay: 'yes', // [yes, no]
// responsive: true,
}; single config CKEDITOR.replace('dom id', {
filebrowserImageUploadUrl: '/foo',
filebrowserHtml5videoUploadUrl: '/bar',
extraPlugins: 'html5video',
html5video_controls: true,
html5video_responsive: true,
html5video_autoplay: 'yes',
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
By default 'Show controls' seems to be off, which seems to be an unhelpful default.
It does not seem to be possible to change this programmatically using the CKEditor JS API either :(
The text was updated successfully, but these errors were encountered: