From 208ecf5081dc0f457c6856fc3aa218e23ce7358f Mon Sep 17 00:00:00 2001 From: Benjy Cui Date: Wed, 13 Apr 2016 09:25:29 +0800 Subject: [PATCH 1/4] docs: update docs for MonthPicker --- components/date-picker/index.md | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/components/date-picker/index.md b/components/date-picker/index.md index 9d9ad02a3f..ecbb9cb3ee 100644 --- a/components/date-picker/index.md +++ b/components/date-picker/index.md @@ -39,6 +39,21 @@ | onOk | 点击确定按钮的回调 | function(Date value) | 无 | | getCalendarContainer | 定义浮层的容器,默认为 body 上新建 div | function(trigger) | 无 | +### MonthPicker + +| 参数 | 说明 | 类型 | 默认值 | +|--------------|----------------|----------|--------------| +| value | 日期 | string or Date | 无 | +| defaultValue | 默认日期 | string or Date | 无 | +| format | 展示的日期格式,配置参考 [GregorianCalendarFormat](https://github.com/yiminghe/gregorian-calendar-format) | string | "yyyy-MM" | +| onChange | 时间发生变化的回调,发生在用户选择时间时 | function(Date value) | 无 | +| disabled | 禁用 | bool | false | +| style | 自定义输入框样式 | object | {} | +| popupStyle | 格外的弹出日历样式 | object | {} | +| size | 输入框大小,`large` 高度为 32px,`small` 为 22px,默认是 28px | string | 无 | +| locale | 国际化配置 | object | [默认配置](https://github.com/ant-design/ant-design/issues/424) | +| getCalendarContainer | 定义浮层的容器,默认为 body 上新建 div | function(trigger) | 无 | + ### RangePicker | 参数 | 说明 | 类型 | 默认值 | From 455d3654b8b1f88d348e66b6ea5c199427186109 Mon Sep 17 00:00:00 2001 From: afc163 Date: Wed, 13 Apr 2016 14:36:43 +0800 Subject: [PATCH 2/4] Fix dateInput format of DatePicker, close #1403 --- components/date-picker/RangePicker.jsx | 1 + components/date-picker/index.jsx | 1 + 2 files changed, 2 insertions(+) diff --git a/components/date-picker/RangePicker.jsx b/components/date-picker/RangePicker.jsx index a74eb2de2f..5faeebc3ce 100644 --- a/components/date-picker/RangePicker.jsx +++ b/components/date-picker/RangePicker.jsx @@ -129,6 +129,7 @@ export default React.createClass({ return ( Date: Wed, 13 Apr 2016 14:46:08 +0800 Subject: [PATCH 3/4] Fix menu selected style, close #1400 --- style/components/menu.less | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/style/components/menu.less b/style/components/menu.less index 20fa4b3b49..2c90bf3b51 100644 --- a/style/components/menu.less +++ b/style/components/menu.less @@ -69,6 +69,10 @@ color: @primary-color; // fix chrome render bug transform: translateZ(0); + > a, + > a:hover { + color: @primary-color; + } } &-inline, @@ -346,6 +350,10 @@ background-color: @primary-color; color: #fff; transform: translateZ(0); + > a, + > a:hover { + color: #fff; + } } &-dark &-item-active, From 861808469ac0fa0b027c1475b0c77a04c67774fd Mon Sep 17 00:00:00 2001 From: afc163 Date: Wed, 13 Apr 2016 15:00:47 +0800 Subject: [PATCH 4/4] fix code highlight --- components/queue-anim/demo/basic.md | 39 +++++------ components/queue-anim/demo/custom.md | 39 +++++------ components/queue-anim/demo/enter-leave.md | 39 +++++------ components/queue-anim/demo/page.md | 81 +++++++++++------------ 4 files changed, 100 insertions(+), 98 deletions(-) diff --git a/components/queue-anim/demo/basic.md b/components/queue-anim/demo/basic.md index 3c76886d90..2a71e61630 100644 --- a/components/queue-anim/demo/basic.md +++ b/components/queue-anim/demo/basic.md @@ -21,31 +21,32 @@ const Test = React.createClass({ }); }, render() { + const list = this.state.show ? [ +
+
    +
  • +
  • +
  • +
+
, +
+
+
+
    +
  • +
  • +
  • +
+
+
+ ] : null; return (

- {this.state.show ? [ -
-
    -
  • -
  • -
  • -
-
, -
-
-
-
    -
  • -
  • -
  • -
-
-
- ] : null} + {list}
); diff --git a/components/queue-anim/demo/custom.md b/components/queue-anim/demo/custom.md index 09ab895cfb..e8bf4fac2f 100644 --- a/components/queue-anim/demo/custom.md +++ b/components/queue-anim/demo/custom.md @@ -21,6 +21,25 @@ const Test = React.createClass({ }); }, render() { + const list = this.state.show ? [ +
+
    +
  • +
  • +
  • +
+
, +
+
+
+
    +
  • +
  • +
  • +
+
+
+ ] : null; return (

@@ -31,25 +50,7 @@ const Test = React.createClass({ { opacity: [1, 0], translateY: [0, 50] }, { opacity: [1, 0], translateY: [0, -50] } ]}> - {this.state.show ? [ -

-
    -
  • -
  • -
  • -
-
, -
-
-
-
    -
  • -
  • -
  • -
-
-
- ] : null} + {list}
); diff --git a/components/queue-anim/demo/enter-leave.md b/components/queue-anim/demo/enter-leave.md index 942c50f907..dfe890c75a 100644 --- a/components/queue-anim/demo/enter-leave.md +++ b/components/queue-anim/demo/enter-leave.md @@ -21,6 +21,25 @@ const Test = React.createClass({ }); }, render() { + const list = this.state.show ? [ +
+
    +
  • +
  • +
  • +
+
, +
+
+
+
    +
  • +
  • +
  • +
+
+
+ ] : null; return (

@@ -30,25 +49,7 @@ const Test = React.createClass({ key="demo" type={['right', 'left']} ease={['easeOutQuart', 'easeInOutQuart']}> - {this.state.show ? [ -

-
    -
  • -
  • -
  • -
-
, -
-
-
-
    -
  • -
  • -
  • -
-
-
- ] : null} + {list}
); diff --git a/components/queue-anim/demo/page.md b/components/queue-anim/demo/page.md index ac06146c50..548477b53f 100644 --- a/components/queue-anim/demo/page.md +++ b/components/queue-anim/demo/page.md @@ -21,54 +21,53 @@ const Test = React.createClass({ }); }, render() { - return ( -
-

- -

- - {this.state.show ? [ -
-
- - logo -
- + const page = this.state.show ? [ +
+
+ + logo +
+ +
  • +
  • +
  • +
  • +
  • +
    +
    , + +
    我是标题
    +
    + +
  • +
  • +
  • +
    +
    +
    我是标题
    +
    + +
    +
  • -
    , - -
    我是标题
    -
    - -
  • -
  • -
  • -
    -
    -
    我是标题
    -
    - -
    - -
  • -
  • -
  • -
  • -
  • -
    -
    -
    -
    , - -
    - ] : null} -
    +
    +
    , + +
    +
    + ] : null; + return ( +
    +

    + +

    + {page}
    ); }