提交 9ff6f925 编写于 作者: C Catouse

* fix dropdown menu width for colorpicker.

上级 e1726dcd
......@@ -69,6 +69,8 @@ ZUI 官方网站为 https://www.openzui.com/ ,并提供了[英文文档(https:
* 加载指示器:
* 优化了与按钮一起使用时的样式;
* 优化了覆盖层的样式,减少了透明度;
* 颜色选择器:
* 修复了下拉菜单宽度问题;
* 文件上传:
* 优化了对远程服务器返回的 JSON 内容容错性,如果返回的 JSON 对象中没有指定 `status``result` 属性仍然视为上传成功;
* 修复了对 IE 浏览器的兼容;
......
......@@ -70,6 +70,8 @@ ZUI official website is https://www.openzui.com/ and English version is availabl
* Load indicator
* Optimized the style used with icons.
* Optimized the style of the overlay and reduced the opacity.
* Color picker
* Fixed dropdown menu width.
* Uploader
* Optimized the fault tolerance of JSON content called back by a remote server. It is deemed as uploaded, if no specified `status` or `result` in JSON.
* Fixed the IE browser compatibility.
......
......@@ -120,12 +120,12 @@
};
ColorPicker.prototype.updateColors = function(colors) {
var $picker = this.$picker,
$menu = this.$menu.children('li:not(.heading)').remove(),
var $menu = this.$menu,
options = this.options,
colors = colors || this.colors,
that = this;
colors = colors || this.colors,
that = this;
var bestLineCount = 0;
$menu.children('li:not(.heading)').remove();
$.each(colors, function(idx, color) {
that.addColor(color);
bestLineCount++;
......@@ -139,11 +139,11 @@
};
ColorPicker.prototype.setValue = function(color, notSetInput) {
var that = this;
var that = this;
var options = that.options;
var $btn = that.$btn;
var $btn = that.$btn;
var hex = '';
that.$menu.find('.cp-tile.active').removeClass('active');
var hex = '';
var updateBtn = options.updateBtn;
if (updateBtn === 'auto') {
var $btnBar = $btn.find('.color-bar');
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册