Browse Source

Fix color picker style

pull/561/head
Artur Arseniev 9 years ago
parent
commit
0728f84e45
  1. 2
      dist/css/grapes.min.css
  2. 4
      dist/grapes.min.js
  3. 2
      package-lock.json
  4. 2
      package.json
  5. 3
      src/domain_abstract/ui/InputColor.js
  6. 1
      src/style_manager/view/LayerView.js
  7. 2
      src/style_manager/view/PropertyStackView.js
  8. 1
      src/styles/scss/main.scss

2
dist/css/grapes.min.css

File diff suppressed because one or more lines are too long

4
dist/grapes.min.js

File diff suppressed because one or more lines are too long

2
package-lock.json

@ -1,6 +1,6 @@
{ {
"name": "grapesjs", "name": "grapesjs",
"version": "0.12.40", "version": "0.12.41",
"lockfileVersion": 1, "lockfileVersion": 1,
"requires": true, "requires": true,
"dependencies": { "dependencies": {

2
package.json

@ -1,7 +1,7 @@
{ {
"name": "grapesjs", "name": "grapesjs",
"description": "Free and Open Source Web Builder Framework", "description": "Free and Open Source Web Builder Framework",
"version": "0.12.40", "version": "0.12.41",
"author": "Artur Arseniev", "author": "Artur Arseniev",
"license": "BSD-3-Clause", "license": "BSD-3-Clause",
"homepage": "http://grapesjs.com", "homepage": "http://grapesjs.com",

3
src/domain_abstract/ui/InputColor.js

@ -53,6 +53,7 @@ module.exports = Input.extend({
getColorEl() { getColorEl() {
if (!this.colorEl) { if (!this.colorEl) {
const self = this; const self = this;
const ppfx = this.ppfx;
var model = this.model; var model = this.model;
var colorEl = $(`<div class="${this.ppfx}field-color-picker"></div>`); var colorEl = $(`<div class="${this.ppfx}field-color-picker"></div>`);
@ -66,8 +67,8 @@ module.exports = Input.extend({
let changed = 0; let changed = 0;
let previousСolor; let previousСolor;
this.$el.find(`[data-colorp-c]`).append(colorEl); this.$el.find(`[data-colorp-c]`).append(colorEl);
colorEl.spectrum({ colorEl.spectrum({
containerClassName: `${ppfx}one-bg ${ppfx}two-color`,
appendTo: elToAppend || 'body', appendTo: elToAppend || 'body',
maxSelectionSize: 8, maxSelectionSize: 8,
showPalette: true, showPalette: true,

1
src/style_manager/view/LayerView.js

@ -156,6 +156,7 @@ module.exports = Backbone.View.extend({
const properties = new PropertiesView({ const properties = new PropertiesView({
collection: model.get('properties'), collection: model.get('properties'),
config: this.config, config: this.config,
target: propsConfig.target,
customValue: propsConfig.customValue, customValue: propsConfig.customValue,
propTarget: propsConfig.propTarget, propTarget: propsConfig.propTarget,
onChange: propsConfig.onChange, onChange: propsConfig.onChange,

2
src/style_manager/view/PropertyStackView.js

@ -135,6 +135,7 @@ module.exports = PropertyCompositeView.extend({
const fieldEl = this.el.querySelector('[data-layers-wrapper]'); const fieldEl = this.el.querySelector('[data-layers-wrapper]');
const PropertiesView = require('./PropertiesView'); const PropertiesView = require('./PropertiesView');
const propsConfig = { const propsConfig = {
target: this.target,
propTarget: this.propTarget, propTarget: this.propTarget,
// Things to do when a single sub-property is changed // Things to do when a single sub-property is changed
@ -160,6 +161,7 @@ module.exports = PropertyCompositeView.extend({
// Will use it to propogate changes // Will use it to propogate changes
new PropertiesView({ new PropertiesView({
target: this.target,
collection: this.model.get('properties'), collection: this.model.get('properties'),
stackModel: model, stackModel: model,
config: this.config, config: this.config,

1
src/styles/scss/main.scss

@ -760,7 +760,6 @@ $prefix: $app-prefix;
.sp-hue{ left: 90%; } .sp-hue{ left: 90%; }
.sp-color{right: 15%;} .sp-color{right: 15%;}
.sp-container { .sp-container {
@extend .#{$app-prefix}bg-main;
border: 1px solid $mainDkColor; border: 1px solid $mainDkColor;
box-shadow: 0 0 7px $mainDkColor; box-shadow: 0 0 7px $mainDkColor;
border-radius: 3px; border-radius: 3px;

Loading…
Cancel
Save