Adding TinyMCE plugin with toolbar icon using a module package in Episerver CMS 12 - content-management-system

I have a custom TinyMCE plugin that add a toolbar icon to the tinymce tool bar. Plugin is configured in a file called editor_plugin.js which is placed inside my custom EpiServer module. I need this to register in tinyMCE.
I added following code in the startup.cs file:
services.Configure<TinyMceConfiguration>(config =>
{
config.Default()
.AddEpiserverSupport()
.AddExternalPlugin("qbankmodule", "/QbankModule/TinyPlugin/editor_plugin.js")
.AppendToolbar("qbankmodule");
});
but I am getting following error in TinyMCE toolbar area:
Failed to load plugin url: http://localhost:8000/EPiServer/EPiServer.Cms.TinyMce/3.1.0/ClientResources/tinymce/QbankModule/TinyPlugin/editor_plugin.js
I Have following questions:
How can I point this to the editor_plugin.js file in the QbankModule I have it as QbankModule/TinyMCE/editor_plugin.js but now it is loading from EPiServer.Cms.TinyMce module.
Instead of registering this in the startup.cs since our product it this QbankModule, we need this to be registered using Customized TinyMce Initialization module using IConfigurableModule. Any one have experience in this area how to implement that?

Related

how to use custom layout with ionic3 barcode-scanner plugin

I am using ionic3, I need to create a screen to scan QRCode/Barcode with this layout: show model example, Is there a possibility of HTML injection in this plugin?
Documentation:
https://ionicframework.com/docs/native/barcode-scanner
https://github.com/phonegap/phonegap-plugin-barcodescanner
Useful links:
https://github.com/cordova-plugin-camera-preview/cordova-plugin-camera-preview
Get picture in Custom View Camera Preview Ionic 3
It's difficult to build a custom layout using barcode-scanner but,
You can make a custom layout for QRcode scanner using the following plugin:
https://ionicframework.com/docs/native/qr-scanner

Customization of login screen is not working in Keycloak application?

provide configuration for customization of login page.
https://www.keycloak.org/docs/latest/server_development/index.html#_themes
Tried the above tutorial but its not working.
Do i need any permission for customization?
I wanted to change the logo, so I tried following the official tutorial, but it did not change. After all, I found that we should add few html lines containing the css class (resources/*.css) to display the logo instead of the default text. Steps below:
Select you Realm
Go to Realms Settings
Tab General
Fill the HTML Display Name field (by default it is blank) with the content having class kc-logo-text (login.css related) or your custom class (you can see the Master realm did it) in order to make the logo appeared.
Save
Tab Themes
Select your custom theme
Save
// For example:
HTML Display Name: <div class="kc-logo-text"><span>Keycloak</span></div>
Solution derived after I read https://lists.jboss.org/pipermail/keycloak-user/2019-September/019320.html

Load specific style sheet for each frontend plugin - TYPO3 Extbase

Using TYPO3 version 8
I have a custom extension that contains three frontend plugins.
For each of the three plugins I have a separate stylesheet for each of them.
Currently, all three style sheets are loaded even if one of the plugins isn't loaded on that page.
My setup.ts:
page.includeCSS.tx_myextension_frontendpluginONE = EXT:myextension/Resources/Public/Css/frontendpluginONE.css
page.includeCSS.tx_myextension_frontendpluginTWO = EXT:myextension/Resources/Public/Css/frontendpluginTWO.css
page.includeCSS.tx_myextension_frontendpluginTHREE = EXT:myextension/Resources/Public/Css/frontendpluginTHREE.css
Question:
Using only Typoscript, can I load a stylesheet for each plugin and not have it load if the plugin is not displayed on the page? I assumed it would sit somewhere in my extension configuration:
plugin.tx_myextension_frontendpluginONE.settings {
Call it in here perhaps?
}
Thanks again.

How to override Ionic2 sass variable just in one page?

I tried to override sass variable in variables.css like this
but it's not what I want.
It seems to change the styles of all tabs.
You just need to do as shown below on the page component which you need to apply.
my.scss
.ios,
.md,
.wp {
page-my {
.margin-top-15 {
margin-top: 15px;//this is just an example
}
}
}
Currently, it is not possible to override a sass variable in one single page, it simply does not work.
This is the response to a similar issue reported in ionic forums:
https://github.com/ionic-team/ionic/issues/7469
One useful solution is to ionic serve your project, open the inspector on your browser, inspect the desired element and see its ionic generated classes to overwrite them manually in the .scss file.
Currently you cannot change sass variables in one page. That's just not how sass works. Sass is meant to be used as a global setting.
There is a work around to change let's say for example the background of a loading container.
You can do this for most.
If you open developer tools and select inspect element on the loading wrapper it gives the class .loading-wrapper as shown in image link below.
css class for loading shown in inspect element
In your app.css
.loadingCss {
.loading-wrapper {
color: #f4f4f4;
background: #2979ff;
}
}
in your component ts add the class to your loading create instance
//initialize a loading overlay
let working = this.loadingCtrl.create({
content: 'Working...',
spinner: 'dots',
cssClass: 'loadingCss'
});
Now you can create multiple instances of loading and have separate classes for loading and add them to your instance and the css will take effect.
Final result is shown in the below image link.
Loading overlays with custom css on two pages
I hope this helps

not able to register two plugins of touch-ui rte dialog

I am using the steps given in the URL to make a color-picker rte plugin
http://experience-aem.blogspot.in/2015/01/aem-6-sp1-touchui-richtext-editor-color-picker-plugin.html
and at the same time I am making another custom rte plugin to do some text modulation.
But only one of them is working using rte.coralui2 as categories.
and both icons are coming at the same location.
If I disable one js then another is working.
I have registered the plugin with different name and I have also used different variables.
I am not able to make the rte plugin button at different location.
Please suggest the possible solution.
it's possible you are overlaying rather than extending the rte.coralui2 category. I suspect your custom clientLibs are competing with each other and only one is available.
It seems like you are using the same steps provided in the blogpost for creating both the plugins and while doing that, you are using the below code twice with different icons :
if(items.indexOf(ExperienceAEM.TCP_UI_SETTING) == -1){
items.splice(3, 0, ExperienceAEM.TCP_UI_SETTING);
}
So, maybe, the icons are being added at the same place and only one of them is shown.
You should create ExperienceAEM.CuiToolbarBuilder Class only once and add both icons inside that class