Skip to content

Instantly share code, notes, and snippets.

Avatar
🏡

Johannes Siipola joppuyo

🏡
View GitHub Profile
View wordpress-5.5-gutenberg-remove-drop-cap.js
function removeDropCap(settings, name) {
if (name !== 'core/paragraph') {
return settings;
}
let newSettings = Object.assign({}, settings);
if (newSettings.supports &&
newSettings.supports.__experimentalFeatures &&
newSettings.supports.__experimentalFeatures.typography &&
newSettings.supports.__experimentalFeatures.typography.dropCap) {
newSettings.supports.__experimentalFeatures.typography.dropCap = false