TinyMCE Remove Advanced tab from Tables dialog - tinymce

I dont want to see the advanced tab on the tables dialog, and I dont want to remove it from the source in case its overwritten with updates.
Note: not Wordpress.
Any suggestions?

In TinyMCE v4, there are three plugin options: table_advtab, table_row_advtab and table_cell_advtab, that specify whether the Advanced Tab is enabled on the Table Properties, Row Properties and Cell Properties dialogs respectively.
So, if you want to hide the Advanced Tab for all table properties, you would set all of these options to false like this:
tinymce.init({
table_advtab: false,
table_row_advtab: false,
table_cell_advtab: false
});
Reference for these options can be found here:
https://www.tinymce.com/docs/plugins/table/#table_advtab

I have to tell you, that this is not possible. There are several settings concerning the table plugin, but not the one you are looking for.

Related

Can I change "OK" button style in Select Dialog to emphasized?

anyone know if sapui5 provide solution/function to change button style in select dialog? I've checked the SAPUI5 sdk but there is none for this solution.
If you are OK with using "private" properties then you can use _oOkButton property of SelectDialog or else you can use _getOkButton function which also is kind of "private" and returns ok button instance.
Just use the instance of the Select Dialog and get all buttons using the following methods. Select Dialog is a dialog only, you can use the methods of sap.m.Dialog
Let say you have the instance of the dialog as oSlectDialog then
oSlectDialog.getButtons() - will return all the Buttons in the footer. You can use loop them and give custom class accordingly.
var oBtns = oSlectDialog.getButtons()
for(var b in oBtns) {
var oBtn = oBtns[b];//You can check for button instance, if you want to add custom class differently.
oBtn.addStyleClass("YourCustomClass");
}
You can also use the sap.m.Dialog methods like oSlectDialog.getBeginButton(), oSlectDialog.getEndButton().
Since UI5 1.62.0, the primary action OK (later renamed to Select) is automatically emphasized if the theme is sap_fiori_3.
https://openui5.hana.ondemand.com/#/entity/sap.m.SelectDialog/sample/sap.m.sample.SelectDialog
If it's not urgent, I'd suggest to avoid relying on private methods/ properties, but update to the latest UI5 version and themes.
Update: and since 1.70 (commit:1f421b0), the button is automatically emphasized in other supported themes too, such as sap_belize, sap_belize_plus
Related Github issue: https://github.com/SAP/openui5/issues/2254

How to remove section from TinyMCE link plugin

In my app I using tinymce plugin for adding some files from local machine - link plugin. And it works great, but, there is one section - target, that I want to hide from users.
Because I'm just using '_blank' as default and type 'none' make some troubles.
In documentation I can't find option for hide this section. So I try to hide this by css. Unfortunately id and classes are dynamic, so it was bad idea with css 'display:none'.
It's possible to hide this section somehow?
You can remove the target list altogether by placing this in your TinyMCE configuration:
target_list: false
That is documented here: https://www.tinymce.com/docs/plugins/link/#target_list
To disable the option dialog set target_list to false

Remove navigation menu item for model without removing ability to manage in RailsAdmin and CanCan?

So I have a model (Image) that belongs to another model (Product), and I want to allow a user to manage both of these two types of models, but I don't want to list the model in the navigation menu in RailsAdmin.
Basically of these two I only want Product to be visible in the navigation menu, while allowing the user to still crud their images within the edit/add form of a Product.
Is this possible with CanCan? Or do I need to use CSS to hide these navigation items?
config.model Team do
visible false
end
According to this issue, and this issue your only valid approach would be the CSS approach
I had the same issue, and unfortunately I haven't found any proper solution. The only workaround was to hack Rails Admin using javascript.
So, to hide the model Image from the navigation menu I added this code in 'app/assets/javascripts/rails_admin/custom/ui.js':
$(document).on('rails_admin.dom_ready', function() {
$('ul.nav-pills li[data-model="image"]').hide();
});
I had same issue. fixed using this css
li[data-model="event_date"] {
display:none !important;
}
in your model:
rails_admin do
visible false
end
no need to edit your rails_admin.rb file.

Zend Framework: Hide navigation item in menu by show in breadcrumbs

i am using Zend_Navigation i want to show the nav item in the breadcrumbs but hide it in my menu, how can i do that?
There are many choices, e.g.
You may set visible parameter to false (eg. in xml config file), then use setRenderInvisible(true/false) on the navigation helper,
You may use separate containers,
You may modify the container on the fly (getContainer(), getItemBy()…)
When using an XML config file, use an integer instead of a boolean value:
<visible>0</visible>
An issue has already been logged for this problem here.

tinymce, view only

Evaluating Tinymce. I've looked at the docs/source/api, and have a question that I thought I'd pose to the stackoverflow group.
Has anyone implemented Tinymce, who can tell me it it's possible to setup Tinymce to restrict a user, allowing the user to only "view" a text file, and be able to add additional buttons to the save/cancel row of buttons..
I think it should be, and that I'm missing something subtle..
Thanks
-Tom
Sure, you set the read-only option. Configure your textarea like this in your javascript file:
tinyMCE.init({
...
theme : "advanced",
readonly : 1
});