redactor icon indicating copy to clipboard operation
redactor copied to clipboard

Redactor inside Craft CMS is not applying format classes

Open pbmills opened this issue 4 years ago • 3 comments

Description

Redactor inside Craft CMS is not applying format classes

{
	"buttons": ["formatting", "bold", "lists"],
	"formatting": ["p"],
	"formattingAdd": {
		"providers-feature-paragraph": {
			"title": "Feature Paragraph",
			"api": "module.block.format",
			"args": {
				"tag": "p",
				"class": "providers-feature-paragraph"
			}
		}
	},
	"plugins": ["fullscreen", "table", "counter"],
	"toolbarFixed": true,
	"source": true,
	"linkNewTab": true
}

Steps to reproduce

Additional info

  • Craft version: 3.7.18
  • PHP version: 7.4
  • Database driver & version:
  • Plugins & versions: 2.8.8

pbmills avatar Jan 24 '22 22:01 pbmills

I'm having issues with Redactor in Craft 3 as well. It will apply the format initially, but won't remove the format even with "type": "toggle" added to the "args".

johnnymueller avatar Jan 24 '22 23:01 johnnymueller

For me, it doesn't apply any class Screen Shot 2022-01-25 at 11 15 32 AM

A class should apply to P tag but it doesn't.

pbmills avatar Jan 24 '22 23:01 pbmills

Custom styles are a bit finicky in Redactor.

There will be a release next week that also updates the Redactor version - maybe that will help.

andris-sevcenko avatar Jan 28 '22 16:01 andris-sevcenko