Browse Source

Merge pull request #427 in FUI/fineui from ~WINDY/fui:master to master

* commit '943fbac5aa4f65b8376cded9fa7a938bf0a89116':
  update
  update
  update
  BI-22461
es6
guy 7 years ago
parent
commit
f3c65859a9
  1. 1
      demo/js/case/demo.color_chooser_popup.js
  2. 44
      dist/_fineui.min.js
  3. 6
      dist/base.css
  4. 6
      dist/bundle.css
  5. 53
      dist/bundle.js
  6. 2
      dist/bundle.min.css
  7. 32
      dist/bundle.min.js
  8. 53
      dist/case.js
  9. 1
      dist/demo.js
  10. 6
      dist/fineui.css
  11. 53
      dist/fineui.js
  12. 2
      dist/fineui.min.css
  13. 44
      dist/fineui.min.js
  14. 44
      src/case/colorchooser/colorchooser.popup.js
  15. 2
      src/case/editor/editor.state.simple.js
  16. 7
      src/case/richeditor/richeditor.js
  17. 6
      src/css/base/colorchooser/colorchooser.css
  18. 8
      src/less/base/colorchooser/colorchooser.popup.less

1
demo/js/case/demo.color_chooser_popup.js

@ -9,6 +9,7 @@ Demo.Func = BI.inherit(BI.Widget, {
items: [{ items: [{
el: { el: {
type: "bi.color_chooser_popup", type: "bi.color_chooser_popup",
disabled: true,
cls: "bi-card" cls: "bi-card"
}, },
left: 100, left: 100,

44
dist/_fineui.min.js vendored

File diff suppressed because one or more lines are too long

6
dist/base.css vendored

@ -1,3 +1,9 @@
.bi-color-chooser-popup .disable-mask {
opacity: 0.5;
filter: alpha(opacity=50);
background-color: #ffffff;
}
.bi-color-chooser-trigger { .bi-color-chooser-trigger {
-webkit-border-radius: 2px; -webkit-border-radius: 2px;
-moz-border-radius: 2px; -moz-border-radius: 2px;

6
dist/bundle.css vendored

@ -2044,6 +2044,12 @@ textarea {
.bi-theme-dark .bi-input { .bi-theme-dark .bi-input {
color: #ffffff; color: #ffffff;
} }
.bi-color-chooser-popup .disable-mask {
opacity: 0.5;
filter: alpha(opacity=50);
background-color: #ffffff;
}
.bi-color-chooser-trigger { .bi-color-chooser-trigger {
-webkit-border-radius: 2px; -webkit-border-radius: 2px;
-moz-border-radius: 2px; -moz-border-radius: 2px;

53
dist/bundle.js vendored

@ -76188,16 +76188,13 @@ BI.shortcut("bi.color_chooser", BI.ColorChooser);/**
*/ */
BI.ColorChooserPopup = BI.inherit(BI.Widget, { BI.ColorChooserPopup = BI.inherit(BI.Widget, {
_defaultConfig: function () { props: {
return BI.extend(BI.ColorChooserPopup.superclass._defaultConfig.apply(this, arguments), {
baseCls: "bi-color-chooser-popup", baseCls: "bi-color-chooser-popup",
width: 200, width: 200,
height: 145 height: 145
});
}, },
_init: function () { render: function () {
BI.ColorChooserPopup.superclass._init.apply(this, arguments);
var self = this, o = this.options; var self = this, o = this.options;
this.colorEditor = BI.createWidget(o.editor, { this.colorEditor = BI.createWidget(o.editor, {
type: "bi.color_picker_editor", type: "bi.color_picker_editor",
@ -76304,9 +76301,11 @@ BI.ColorChooserPopup = BI.inherit(BI.Widget, {
} }
}); });
BI.createWidget({ return {
type: "bi.absolute",
items: [{
el: {
type: "bi.vtape", type: "bi.vtape",
element: this,
items: [{ items: [{
el: { el: {
type: "bi.absolute", type: "bi.absolute",
@ -76345,12 +76344,41 @@ BI.ColorChooserPopup = BI.inherit(BI.Widget, {
el: this.more, el: this.more,
height: 20 height: 20
}] }]
}); },
left: 0,
right: 0,
top: 0,
bottom: 0
}, {
el: {
type: "bi.layout",
cls: "disable-mask",
invisible: !o.disabled,
ref: function () {
self.mask = this;
}
},
left: 0,
right: 0,
top: 0,
bottom: 0
}]
};
},
mounted: function () {
var self = this;
var o = this.options;
if (BI.isNotNull(o.value)) { if (BI.isNotNull(o.value)) {
this.setValue(o.value); this.setValue(o.value);
} }
}, },
_setEnable: function (enable) {
BI.ColorChooserPopup.superclass._setEnable.apply(this, arguments);
this.mask.setVisible(!enable);
},
setStoreColors: function (colors) { setStoreColors: function (colors) {
if (BI.isArray(colors)) { if (BI.isArray(colors)) {
var items = BI.map(colors, function (i, color) { var items = BI.map(colors, function (i, color) {
@ -80709,7 +80737,7 @@ BI.SimpleStateEditor = BI.inherit(BI.Widget, {
}); });
this.text = BI.createWidget({ this.text = BI.createWidget({
type: "bi.text_button", type: "bi.text_button",
cls: "state-editor-infinite-text bi-disabled", cls: "state-editor-infinite-text",
textAlign: "left", textAlign: "left",
height: o.height, height: o.height,
text: BI.i18nText("BI-Basic_Unrestricted"), text: BI.i18nText("BI-Basic_Unrestricted"),
@ -84089,7 +84117,7 @@ BI.shortcut("bi.rich_editor_size_chooser", BI.RichEditorSizeChooser);/**
BI.RichEditor = BI.inherit(BI.Widget, { BI.RichEditor = BI.inherit(BI.Widget, {
props: { props: {
baseCls: "bi-rich-editor", baseCls: "bi-rich-editor bi-textarea",
toolbar: {}, toolbar: {},
readOnly: false readOnly: false
}, },
@ -84160,6 +84188,11 @@ BI.RichEditor = BI.inherit(BI.Widget, {
} }
}, },
_setEnable: function (enable) {
BI.RichEditor.superclass._setEnable.apply(this, arguments);
this.mask.setVisible(!enable);
},
focus: function () { focus: function () {
this.editor.focus(); this.editor.focus();
}, },

2
dist/bundle.min.css vendored

File diff suppressed because one or more lines are too long

32
dist/bundle.min.js vendored

File diff suppressed because one or more lines are too long

53
dist/case.js vendored

@ -3709,16 +3709,13 @@ BI.shortcut("bi.color_chooser", BI.ColorChooser);/**
*/ */
BI.ColorChooserPopup = BI.inherit(BI.Widget, { BI.ColorChooserPopup = BI.inherit(BI.Widget, {
_defaultConfig: function () { props: {
return BI.extend(BI.ColorChooserPopup.superclass._defaultConfig.apply(this, arguments), {
baseCls: "bi-color-chooser-popup", baseCls: "bi-color-chooser-popup",
width: 200, width: 200,
height: 145 height: 145
});
}, },
_init: function () { render: function () {
BI.ColorChooserPopup.superclass._init.apply(this, arguments);
var self = this, o = this.options; var self = this, o = this.options;
this.colorEditor = BI.createWidget(o.editor, { this.colorEditor = BI.createWidget(o.editor, {
type: "bi.color_picker_editor", type: "bi.color_picker_editor",
@ -3825,9 +3822,11 @@ BI.ColorChooserPopup = BI.inherit(BI.Widget, {
} }
}); });
BI.createWidget({ return {
type: "bi.absolute",
items: [{
el: {
type: "bi.vtape", type: "bi.vtape",
element: this,
items: [{ items: [{
el: { el: {
type: "bi.absolute", type: "bi.absolute",
@ -3866,12 +3865,41 @@ BI.ColorChooserPopup = BI.inherit(BI.Widget, {
el: this.more, el: this.more,
height: 20 height: 20
}] }]
}); },
left: 0,
right: 0,
top: 0,
bottom: 0
}, {
el: {
type: "bi.layout",
cls: "disable-mask",
invisible: !o.disabled,
ref: function () {
self.mask = this;
}
},
left: 0,
right: 0,
top: 0,
bottom: 0
}]
};
},
mounted: function () {
var self = this;
var o = this.options;
if (BI.isNotNull(o.value)) { if (BI.isNotNull(o.value)) {
this.setValue(o.value); this.setValue(o.value);
} }
}, },
_setEnable: function (enable) {
BI.ColorChooserPopup.superclass._setEnable.apply(this, arguments);
this.mask.setVisible(!enable);
},
setStoreColors: function (colors) { setStoreColors: function (colors) {
if (BI.isArray(colors)) { if (BI.isArray(colors)) {
var items = BI.map(colors, function (i, color) { var items = BI.map(colors, function (i, color) {
@ -8230,7 +8258,7 @@ BI.SimpleStateEditor = BI.inherit(BI.Widget, {
}); });
this.text = BI.createWidget({ this.text = BI.createWidget({
type: "bi.text_button", type: "bi.text_button",
cls: "state-editor-infinite-text bi-disabled", cls: "state-editor-infinite-text",
textAlign: "left", textAlign: "left",
height: o.height, height: o.height,
text: BI.i18nText("BI-Basic_Unrestricted"), text: BI.i18nText("BI-Basic_Unrestricted"),
@ -11610,7 +11638,7 @@ BI.shortcut("bi.rich_editor_size_chooser", BI.RichEditorSizeChooser);/**
BI.RichEditor = BI.inherit(BI.Widget, { BI.RichEditor = BI.inherit(BI.Widget, {
props: { props: {
baseCls: "bi-rich-editor", baseCls: "bi-rich-editor bi-textarea",
toolbar: {}, toolbar: {},
readOnly: false readOnly: false
}, },
@ -11681,6 +11709,11 @@ BI.RichEditor = BI.inherit(BI.Widget, {
} }
}, },
_setEnable: function (enable) {
BI.RichEditor.superclass._setEnable.apply(this, arguments);
this.mask.setVisible(!enable);
},
focus: function () { focus: function () {
this.editor.focus(); this.editor.focus();
}, },

1
dist/demo.js vendored

@ -2406,6 +2406,7 @@ BI.shortcut("demo.clipboard", Demo.Func);Demo.Func = BI.inherit(BI.Widget, {
items: [{ items: [{
el: { el: {
type: "bi.color_chooser_popup", type: "bi.color_chooser_popup",
disabled: true,
cls: "bi-card" cls: "bi-card"
}, },
left: 100, left: 100,

6
dist/fineui.css vendored

@ -2044,6 +2044,12 @@ textarea {
.bi-theme-dark .bi-input { .bi-theme-dark .bi-input {
color: #ffffff; color: #ffffff;
} }
.bi-color-chooser-popup .disable-mask {
opacity: 0.5;
filter: alpha(opacity=50);
background-color: #ffffff;
}
.bi-color-chooser-trigger { .bi-color-chooser-trigger {
-webkit-border-radius: 2px; -webkit-border-radius: 2px;
-moz-border-radius: 2px; -moz-border-radius: 2px;

53
dist/fineui.js vendored

@ -76431,16 +76431,13 @@ BI.shortcut("bi.color_chooser", BI.ColorChooser);/**
*/ */
BI.ColorChooserPopup = BI.inherit(BI.Widget, { BI.ColorChooserPopup = BI.inherit(BI.Widget, {
_defaultConfig: function () { props: {
return BI.extend(BI.ColorChooserPopup.superclass._defaultConfig.apply(this, arguments), {
baseCls: "bi-color-chooser-popup", baseCls: "bi-color-chooser-popup",
width: 200, width: 200,
height: 145 height: 145
});
}, },
_init: function () { render: function () {
BI.ColorChooserPopup.superclass._init.apply(this, arguments);
var self = this, o = this.options; var self = this, o = this.options;
this.colorEditor = BI.createWidget(o.editor, { this.colorEditor = BI.createWidget(o.editor, {
type: "bi.color_picker_editor", type: "bi.color_picker_editor",
@ -76547,9 +76544,11 @@ BI.ColorChooserPopup = BI.inherit(BI.Widget, {
} }
}); });
BI.createWidget({ return {
type: "bi.absolute",
items: [{
el: {
type: "bi.vtape", type: "bi.vtape",
element: this,
items: [{ items: [{
el: { el: {
type: "bi.absolute", type: "bi.absolute",
@ -76588,12 +76587,41 @@ BI.ColorChooserPopup = BI.inherit(BI.Widget, {
el: this.more, el: this.more,
height: 20 height: 20
}] }]
}); },
left: 0,
right: 0,
top: 0,
bottom: 0
}, {
el: {
type: "bi.layout",
cls: "disable-mask",
invisible: !o.disabled,
ref: function () {
self.mask = this;
}
},
left: 0,
right: 0,
top: 0,
bottom: 0
}]
};
},
mounted: function () {
var self = this;
var o = this.options;
if (BI.isNotNull(o.value)) { if (BI.isNotNull(o.value)) {
this.setValue(o.value); this.setValue(o.value);
} }
}, },
_setEnable: function (enable) {
BI.ColorChooserPopup.superclass._setEnable.apply(this, arguments);
this.mask.setVisible(!enable);
},
setStoreColors: function (colors) { setStoreColors: function (colors) {
if (BI.isArray(colors)) { if (BI.isArray(colors)) {
var items = BI.map(colors, function (i, color) { var items = BI.map(colors, function (i, color) {
@ -80952,7 +80980,7 @@ BI.SimpleStateEditor = BI.inherit(BI.Widget, {
}); });
this.text = BI.createWidget({ this.text = BI.createWidget({
type: "bi.text_button", type: "bi.text_button",
cls: "state-editor-infinite-text bi-disabled", cls: "state-editor-infinite-text",
textAlign: "left", textAlign: "left",
height: o.height, height: o.height,
text: BI.i18nText("BI-Basic_Unrestricted"), text: BI.i18nText("BI-Basic_Unrestricted"),
@ -84332,7 +84360,7 @@ BI.shortcut("bi.rich_editor_size_chooser", BI.RichEditorSizeChooser);/**
BI.RichEditor = BI.inherit(BI.Widget, { BI.RichEditor = BI.inherit(BI.Widget, {
props: { props: {
baseCls: "bi-rich-editor", baseCls: "bi-rich-editor bi-textarea",
toolbar: {}, toolbar: {},
readOnly: false readOnly: false
}, },
@ -84403,6 +84431,11 @@ BI.RichEditor = BI.inherit(BI.Widget, {
} }
}, },
_setEnable: function (enable) {
BI.RichEditor.superclass._setEnable.apply(this, arguments);
this.mask.setVisible(!enable);
},
focus: function () { focus: function () {
this.editor.focus(); this.editor.focus();
}, },

2
dist/fineui.min.css vendored

File diff suppressed because one or more lines are too long

44
dist/fineui.min.js vendored

File diff suppressed because one or more lines are too long

44
src/case/colorchooser/colorchooser.popup.js

@ -7,16 +7,13 @@
*/ */
BI.ColorChooserPopup = BI.inherit(BI.Widget, { BI.ColorChooserPopup = BI.inherit(BI.Widget, {
_defaultConfig: function () { props: {
return BI.extend(BI.ColorChooserPopup.superclass._defaultConfig.apply(this, arguments), {
baseCls: "bi-color-chooser-popup", baseCls: "bi-color-chooser-popup",
width: 200, width: 200,
height: 145 height: 145
});
}, },
_init: function () { render: function () {
BI.ColorChooserPopup.superclass._init.apply(this, arguments);
var self = this, o = this.options; var self = this, o = this.options;
this.colorEditor = BI.createWidget(o.editor, { this.colorEditor = BI.createWidget(o.editor, {
type: "bi.color_picker_editor", type: "bi.color_picker_editor",
@ -123,9 +120,11 @@ BI.ColorChooserPopup = BI.inherit(BI.Widget, {
} }
}); });
BI.createWidget({ return {
type: "bi.absolute",
items: [{
el: {
type: "bi.vtape", type: "bi.vtape",
element: this,
items: [{ items: [{
el: { el: {
type: "bi.absolute", type: "bi.absolute",
@ -164,12 +163,41 @@ BI.ColorChooserPopup = BI.inherit(BI.Widget, {
el: this.more, el: this.more,
height: 20 height: 20
}] }]
}); },
left: 0,
right: 0,
top: 0,
bottom: 0
}, {
el: {
type: "bi.layout",
cls: "disable-mask",
invisible: !o.disabled,
ref: function () {
self.mask = this;
}
},
left: 0,
right: 0,
top: 0,
bottom: 0
}]
};
},
mounted: function () {
var self = this;
var o = this.options;
if (BI.isNotNull(o.value)) { if (BI.isNotNull(o.value)) {
this.setValue(o.value); this.setValue(o.value);
} }
}, },
_setEnable: function (enable) {
BI.ColorChooserPopup.superclass._setEnable.apply(this, arguments);
this.mask.setVisible(!enable);
},
setStoreColors: function (colors) { setStoreColors: function (colors) {
if (BI.isArray(colors)) { if (BI.isArray(colors)) {
var items = BI.map(colors, function (i, color) { var items = BI.map(colors, function (i, color) {

2
src/case/editor/editor.state.simple.js

@ -46,7 +46,7 @@ BI.SimpleStateEditor = BI.inherit(BI.Widget, {
}); });
this.text = BI.createWidget({ this.text = BI.createWidget({
type: "bi.text_button", type: "bi.text_button",
cls: "state-editor-infinite-text bi-disabled", cls: "state-editor-infinite-text",
textAlign: "left", textAlign: "left",
height: o.height, height: o.height,
text: BI.i18nText("BI-Basic_Unrestricted"), text: BI.i18nText("BI-Basic_Unrestricted"),

7
src/case/richeditor/richeditor.js

@ -8,7 +8,7 @@
BI.RichEditor = BI.inherit(BI.Widget, { BI.RichEditor = BI.inherit(BI.Widget, {
props: { props: {
baseCls: "bi-rich-editor", baseCls: "bi-rich-editor bi-textarea",
toolbar: {}, toolbar: {},
readOnly: false readOnly: false
}, },
@ -79,6 +79,11 @@ BI.RichEditor = BI.inherit(BI.Widget, {
} }
}, },
_setEnable: function (enable) {
BI.RichEditor.superclass._setEnable.apply(this, arguments);
this.mask.setVisible(!enable);
},
focus: function () { focus: function () {
this.editor.focus(); this.editor.focus();
}, },

6
src/css/base/colorchooser/colorchooser.css

@ -1,3 +1,9 @@
.bi-color-chooser-popup .disable-mask {
opacity: 0.5;
filter: alpha(opacity=50);
background-color: #ffffff;
}
.bi-color-chooser-trigger { .bi-color-chooser-trigger {
-webkit-border-radius: 2px; -webkit-border-radius: 2px;
-moz-border-radius: 2px; -moz-border-radius: 2px;

8
src/less/base/colorchooser/colorchooser.popup.less

@ -0,0 +1,8 @@
@import "../../index";
.bi-color-chooser-popup {
& .disable-mask {
.opacity(0.5);
background-color: @color-bi-background-default;
}
}
Loading…
Cancel
Save