Issue #1116💬 AnsweredOpened May 15, 2018by perfect-coders0 reactions

Property gradient is not working

快速解答by artf

Plugin gjs-style-gradient not found Are you sure you've imported it correctly?

Read full answer below ↓

Question

Hi @artf. I have used the GrapesJS Style Gradient plugin and do the same as it is suggested. But it is not making the gradient in the settings. I am giving like that

代码片段TEXT
{
      name: 'Gradient',
      property: 'background-image',
      type: 'gradient',
      defaults: 'none'
    }


Also When I added the "artf/grapesjs-style-gradient" plugin through grapes method like this
plugins: [ 'gjs-style-gradient'], 
pluginsOpts: {
                'gjs-style-gradient': {
                      colorPicker: 'default',
                      grapickOpts: {
                                      min: 1,
                                      max: 99,
                                  }    
                },                

It is showing the error :- Plugin gjs-style-gradient not found

Answers (3)

artfMay 18, 2018

Plugin gjs-style-gradient not found

Are you sure you've imported it correctly?

perfect-codersMay 18, 2018

This is how the gradient property is coming.

screenshot from 2018-05-18 19 22 10

And this is how I am doing /* Page Settings */ { name : 'Page Settings', open : true, buildProps : ['background-color','background','background-repeat','background-size','background-position', 'background-attachment'], properties : [ { name: 'Gradient', property: 'background-image', type: 'gradient', defaults: 'none' }, { property : 'background-color', name: 'Background Color', }, { property : 'background', name: 'Background Image', }, { property : 'background-size', name: 'Sizing', }, { property : 'background-position', name: 'Alignment', }, { property : 'background-repeat', name: 'Repeat', }, { property : 'background-attachment', name: 'Attachment', }, ] },

please see this fiddle https://jsfiddle.net/3h7bthy3/#&togetherjs=GH3IytSyog

artfMay 23, 2018

Your fiddle doesn't work (you didn't setup it correctly), btw this is the demo, it uses the latest version and it works as expected

Related Questions and Answers

Continue research with similar issue discussions.

Paid Plugins That Match This Issue

Curated by issue keywords and label relevance to help you ship faster.

View all plugins

Loading paid plugin recommendations...

Free option

Check the open-source GrapesJS plugins on GitHub or run a quick search in our free catalog.

Browse free plugins →
Premium option

Premium plugins ship with support, regular updates, and production-ready features — save days of integration work.

Browse premium plugins →

Related tutorials

In-depth guides on the same topic.

All tutorials →

Browse Plugin Categories

Jump directly to plugin category pages on the marketplace.