Browse Source

Merge pull request #29 in ~GUY/fineui from ~WINDY/fineui:master to master

* commit 'dd1d894b237cc043a3de239f36572271ef107ae3':
  segment
es6
windy 7 years ago
parent
commit
7d55b1eec2
  1. 17
      bi/base.css
  2. 13
      bi/case.js
  3. 6
      bi/core.js
  4. 17
      docs/base.css
  5. 13
      docs/case.js
  6. 6
      docs/core.js
  7. 13
      src/case/segment/segment.js
  8. 2
      src/core/proto/date.js
  9. 17
      src/css/base/segment/segment.css
  10. 20
      src/less/base/segment/segment.less

17
bi/base.css

@ -678,8 +678,13 @@ li.CodeMirror-hint-active {
overflow: hidden;
overflow-x: hidden;
overflow-y: hidden;
background: #ffffff;
border-right: 1px solid #d4dadd;
border-top: 1px solid #d4dadd;
border-bottom: 1px solid #d4dadd;
}
.bi-segment > .first-element {
border-left: 1px solid #d4dadd;
-webkit-border-radius: 6px 0px 0px 6px;
-moz-border-radius: 6px 0px 0px 6px;
border-radius: 6px 0px 0px 6px;
@ -689,6 +694,18 @@ li.CodeMirror-hint-active {
-moz-border-radius: 0px 6px 6px 0px;
border-radius: 0px 6px 6px 0px;
}
.bi-theme-dark .bi-segment > .center-element {
overflow: hidden;
overflow-x: hidden;
overflow-y: hidden;
background: #242640;
border-right: 1px solid #525466;
border-top: 1px solid #525466;
border-bottom: 1px solid #525466;
}
.bi-theme-dark .bi-segment > .first-element {
border-left: 1px solid #242640;
}
/****添加计算宽度的--运算符直接需要space****/
/****** common color(常用颜色,可用于普遍场景) *****/
/**** custom color(自定义颜色,用于特定场景) ****/

13
bi/case.js

@ -8804,15 +8804,10 @@ BI.Segment = BI.inherit(BI.Widget, {
this.buttonGroup = BI.createWidget({
element: this,
type: "bi.button_group",
items: BI.map(o.items, function (i, item) {
return BI.extend({
type: "bi.segment_button",
height: o.height - 2,
whiteSpace: o.whiteSpace
}, item, {
cls: (i === 0 ? "bi-border-left " : "")
+ (item.cls || "") + " bi-border-top bi-border-right bi-border-bottom"
});
items: BI.createItems(o.items, {
type: "bi.segment_button",
height: o.height - 2,
whiteSpace: o.whiteSpace
}),
layout: [
{

6
bi/core.js

@ -6169,19 +6169,19 @@ Date._DN = [BI.i18nText("BI-Basic_Sunday"),
BI.i18nText("BI-Basic_Sunday")];
// short day names
Date._SDN = [BI.i18nText("BI-Day_Ri"),
Date._SDN = [BI.i18nText("BI-Date_Day"),
BI.i18nText("BI-Basic_One"),
BI.i18nText("BI-Basic_Two"),
BI.i18nText("BI-Basic_Three"),
BI.i18nText("BI-Basic_Four"),
BI.i18nText("BI-Basic_Five"),
BI.i18nText("BI-Basic_Six"),
BI.i18nText("BI-Day_Ri")];
BI.i18nText("BI-Date_Day")];
// Monday first, etc.
Date._FD = 1;
// full month names
// full month namesdat
Date._MN = [
BI.i18nText("BI-Basic_January"),
BI.i18nText("BI-Basic_February"),

17
docs/base.css

@ -678,8 +678,13 @@ li.CodeMirror-hint-active {
overflow: hidden;
overflow-x: hidden;
overflow-y: hidden;
background: #ffffff;
border-right: 1px solid #d4dadd;
border-top: 1px solid #d4dadd;
border-bottom: 1px solid #d4dadd;
}
.bi-segment > .first-element {
border-left: 1px solid #d4dadd;
-webkit-border-radius: 6px 0px 0px 6px;
-moz-border-radius: 6px 0px 0px 6px;
border-radius: 6px 0px 0px 6px;
@ -689,6 +694,18 @@ li.CodeMirror-hint-active {
-moz-border-radius: 0px 6px 6px 0px;
border-radius: 0px 6px 6px 0px;
}
.bi-theme-dark .bi-segment > .center-element {
overflow: hidden;
overflow-x: hidden;
overflow-y: hidden;
background: #242640;
border-right: 1px solid #525466;
border-top: 1px solid #525466;
border-bottom: 1px solid #525466;
}
.bi-theme-dark .bi-segment > .first-element {
border-left: 1px solid #242640;
}
/****添加计算宽度的--运算符直接需要space****/
/****** common color(常用颜色,可用于普遍场景) *****/
/**** custom color(自定义颜色,用于特定场景) ****/

13
docs/case.js

@ -8804,15 +8804,10 @@ BI.Segment = BI.inherit(BI.Widget, {
this.buttonGroup = BI.createWidget({
element: this,
type: "bi.button_group",
items: BI.map(o.items, function (i, item) {
return BI.extend({
type: "bi.segment_button",
height: o.height - 2,
whiteSpace: o.whiteSpace
}, item, {
cls: (i === 0 ? "bi-border-left " : "")
+ (item.cls || "") + " bi-border-top bi-border-right bi-border-bottom"
});
items: BI.createItems(o.items, {
type: "bi.segment_button",
height: o.height - 2,
whiteSpace: o.whiteSpace
}),
layout: [
{

6
docs/core.js

@ -23645,19 +23645,19 @@ Date._DN = [BI.i18nText("BI-Basic_Sunday"),
BI.i18nText("BI-Basic_Sunday")];
// short day names
Date._SDN = [BI.i18nText("BI-Day_Ri"),
Date._SDN = [BI.i18nText("BI-Date_Day"),
BI.i18nText("BI-Basic_One"),
BI.i18nText("BI-Basic_Two"),
BI.i18nText("BI-Basic_Three"),
BI.i18nText("BI-Basic_Four"),
BI.i18nText("BI-Basic_Five"),
BI.i18nText("BI-Basic_Six"),
BI.i18nText("BI-Day_Ri")];
BI.i18nText("BI-Date_Day")];
// Monday first, etc.
Date._FD = 1;
// full month names
// full month namesdat
Date._MN = [
BI.i18nText("BI-Basic_January"),
BI.i18nText("BI-Basic_February"),

13
src/case/segment/segment.js

@ -19,15 +19,10 @@ BI.Segment = BI.inherit(BI.Widget, {
this.buttonGroup = BI.createWidget({
element: this,
type: "bi.button_group",
items: BI.map(o.items, function (i, item) {
return BI.extend({
type: "bi.segment_button",
height: o.height - 2,
whiteSpace: o.whiteSpace
}, item, {
cls: (i === 0 ? "bi-border-left " : "")
+ (item.cls || "") + " bi-border-top bi-border-right bi-border-bottom"
});
items: BI.createItems(o.items, {
type: "bi.segment_button",
height: o.height - 2,
whiteSpace: o.whiteSpace
}),
layout: [
{

2
src/core/proto/date.js

@ -21,7 +21,7 @@ Date._SDN = [BI.i18nText("BI-Date_Day"),
// Monday first, etc.
Date._FD = 1;
// full month names
// full month namesdat
Date._MN = [
BI.i18nText("BI-Basic_January"),
BI.i18nText("BI-Basic_February"),

17
src/css/base/segment/segment.css

@ -5,8 +5,13 @@
overflow: hidden;
overflow-x: hidden;
overflow-y: hidden;
background: #ffffff;
border-right: 1px solid #d4dadd;
border-top: 1px solid #d4dadd;
border-bottom: 1px solid #d4dadd;
}
.bi-segment > .first-element {
border-left: 1px solid #d4dadd;
-webkit-border-radius: 6px 0px 0px 6px;
-moz-border-radius: 6px 0px 0px 6px;
border-radius: 6px 0px 0px 6px;
@ -16,3 +21,15 @@
-moz-border-radius: 0px 6px 6px 0px;
border-radius: 0px 6px 6px 0px;
}
.bi-theme-dark .bi-segment > .center-element {
overflow: hidden;
overflow-x: hidden;
overflow-y: hidden;
background: #242640;
border-right: 1px solid #525466;
border-top: 1px solid #525466;
border-bottom: 1px solid #525466;
}
.bi-theme-dark .bi-segment > .first-element {
border-left: 1px solid #242640;
}

20
src/less/base/segment/segment.less

@ -3,11 +3,31 @@
.bi-segment{
& > .center-element{
.overflow-hidden();
background: @color-bi-background-default;
border-right: 1px solid @color-bi-border-line;
border-top: 1px solid @color-bi-border-line;
border-bottom: 1px solid @color-bi-border-line;
}
& > .first-element{
border-left: 1px solid @color-bi-border-line;
.border-corner-radius(6px,0px,0px,6px)
}
& > .last-element{
.border-corner-radius(0px,6px,6px,0px)
}
}
.bi-theme-dark {
.bi-segment {
& > .center-element{
.overflow-hidden();
background: @color-bi-background-default-theme-dark;
border-right: 1px solid @color-bi-border-line-theme-dark;
border-top: 1px solid @color-bi-border-line-theme-dark;
border-bottom: 1px solid @color-bi-border-line-theme-dark;
}
& > .first-element{
border-left: 1px solid @color-bi-background-default-theme-dark;
}
}
}
Loading…
Cancel
Save