aboutsummaryrefslogtreecommitdiffhomepage
path: root/examples/value-and-defaultValue.js
diff options
context:
space:
mode:
authorafc163 <afc163@gmail.com>2017-04-14 17:22:58 +0800
committerafc163 <afc163@gmail.com>2017-04-14 17:22:58 +0800
commit5b1086548164afd65cf4a5cbb7ec1f92cd5e2b9e (patch)
treed5c8b096944cd0648b04983cdf0630ade3a94151 /examples/value-and-defaultValue.js
parentbc74c14f3cb8ea2d2b242563dbe9963b6491ade4 (diff)
downloadtime-picker-5b1086548164afd65cf4a5cbb7ec1f92cd5e2b9e.tar.gz
time-picker-5b1086548164afd65cf4a5cbb7ec1f92cd5e2b9e.tar.zst
time-picker-5b1086548164afd65cf4a5cbb7ec1f92cd5e2b9e.zip
Updates
Diffstat (limited to 'examples/value-and-defaultValue.js')
-rw-r--r--examples/value-and-defaultValue.js76
1 files changed, 49 insertions, 27 deletions
diff --git a/examples/value-and-defaultValue.js b/examples/value-and-defaultValue.js
index c18a47f..48c85cf 100644
--- a/examples/value-and-defaultValue.js
+++ b/examples/value-and-defaultValue.js
@@ -1,55 +1,75 @@
1webpackJsonp([6],{ 1webpackJsonp([6],{
2 2
3/***/ 0: 3/***/ 0:
4/***/ function(module, exports, __webpack_require__) { 4/***/ (function(module, exports, __webpack_require__) {
5 5
6 module.exports = __webpack_require__(271); 6 module.exports = __webpack_require__(322);
7 7
8 8
9/***/ }, 9/***/ }),
10 10
11/***/ 271: 11/***/ 322:
12/***/ function(module, exports, __webpack_require__) { 12/***/ (function(module, exports, __webpack_require__) {
13 13
14 'use strict'; 14 'use strict';
15 15
16 var _classCallCheck2 = __webpack_require__(188);
17
18 var _classCallCheck3 = _interopRequireDefault(_classCallCheck2);
19
20 var _possibleConstructorReturn2 = __webpack_require__(189);
21
22 var _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2);
23
24 var _inherits2 = __webpack_require__(258);
25
26 var _inherits3 = _interopRequireDefault(_inherits2);
27
16 __webpack_require__(2); 28 __webpack_require__(2);
17 29
18 var _react = __webpack_require__(3); 30 var _react = __webpack_require__(3);
19 31
20 var _react2 = _interopRequireDefault(_react); 32 var _react2 = _interopRequireDefault(_react);
21 33
22 var _reactDom = __webpack_require__(34); 34 var _reactDom = __webpack_require__(38);
23 35
24 var _reactDom2 = _interopRequireDefault(_reactDom); 36 var _reactDom2 = _interopRequireDefault(_reactDom);
25 37
26 var _moment = __webpack_require__(180); 38 var _moment = __webpack_require__(184);
27 39
28 var _moment2 = _interopRequireDefault(_moment); 40 var _moment2 = _interopRequireDefault(_moment);
29 41
30 var _rcTimePicker = __webpack_require__(181); 42 var _rcTimePicker = __webpack_require__(185);
31 43
32 var _rcTimePicker2 = _interopRequireDefault(_rcTimePicker); 44 var _rcTimePicker2 = _interopRequireDefault(_rcTimePicker);
33 45
34 function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } 46 function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
35 47
36 var App = _react2.default.createClass({ 48 var App = function (_React$Component) {
37 displayName: 'App', 49 (0, _inherits3.default)(App, _React$Component);
38 getInitialState: function getInitialState() { 50
39 return { 51 function App() {
52 var _temp, _this, _ret;
53
54 (0, _classCallCheck3.default)(this, App);
55
56 for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
57 args[_key] = arguments[_key];
58 }
59
60 return _ret = (_temp = (_this = (0, _possibleConstructorReturn3.default)(this, _React$Component.call.apply(_React$Component, [this].concat(args))), _this), _this.state = {
40 value: (0, _moment2.default)() 61 value: (0, _moment2.default)()
41 }; 62 }, _this.handleValueChange = function (value) {
42 }, 63 console.log(value && value.format('HH:mm:ss'));
43 handleValueChange: function handleValueChange(value) { 64 _this.setState({ value: value });
44 console.log(value && value.format('HH:mm:ss')); 65 }, _this.clear = function () {
45 this.setState({ value: value }); 66 _this.setState({
46 }, 67 value: undefined
47 clear: function clear() { 68 });
48 this.setState({ 69 }, _temp), (0, _possibleConstructorReturn3.default)(_this, _ret);
49 value: undefined 70 }
50 }); 71
51 }, 72 App.prototype.render = function render() {
52 render: function render() {
53 return _react2.default.createElement( 73 return _react2.default.createElement(
54 'div', 74 'div',
55 null, 75 null,
@@ -67,12 +87,14 @@ webpackJsonp([6],{
67 'clear' 87 'clear'
68 ) 88 )
69 ); 89 );
70 } 90 };
71 }); /* eslint no-console:0 */ 91
92 return App;
93 }(_react2.default.Component); /* eslint no-console:0 */
72 94
73 _reactDom2.default.render(_react2.default.createElement(App, null), document.getElementById('__react-content')); 95 _reactDom2.default.render(_react2.default.createElement(App, null), document.getElementById('__react-content'));
74 96
75/***/ } 97/***/ })
76 98
77}); 99});
78//# sourceMappingURL=value-and-defaultValue.js.map \ No newline at end of file 100//# sourceMappingURL=value-and-defaultValue.js.map \ No newline at end of file