dash-core-components 1.15.0 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +8 -44
- package/dash_core_components/async-datepicker.js +1 -1
- package/dash_core_components/async-datepicker.js.map +1 -1
- package/dash_core_components/async-dropdown.js +2 -2
- package/dash_core_components/async-dropdown.js.map +1 -1
- package/dash_core_components/async-graph.js +1 -1
- package/dash_core_components/async-graph.js.map +1 -1
- package/dash_core_components/async-highlight.js +1 -1
- package/dash_core_components/async-highlight.js.map +1 -1
- package/dash_core_components/async-markdown.js +2 -2
- package/dash_core_components/async-markdown.js.map +1 -1
- package/dash_core_components/async-plotlyjs.js +2 -2
- package/dash_core_components/async-slider.js +1 -2
- package/dash_core_components/async-slider.js.map +1 -1
- package/dash_core_components/async-upload.js +1 -1
- package/dash_core_components/async-upload.js.map +1 -1
- package/dash_core_components/dash_core_components-shared.js +2 -2
- package/dash_core_components/dash_core_components-shared.js.map +1 -1
- package/dash_core_components/dash_core_components.js +3 -0
- package/dash_core_components/dash_core_components.js.map +1 -0
- package/dash_core_components/plotly.min.js +30 -26
- package/lib/components/Checklist.react.js +77 -35
- package/lib/components/Clipboard.react.js +354 -0
- package/lib/components/ConfirmDialog.react.js +16 -12
- package/lib/components/ConfirmDialogProvider.react.js +19 -15
- package/lib/components/DatePickerRange.react.js +111 -97
- package/lib/components/DatePickerSingle.react.js +95 -81
- package/lib/components/Download.react.js +138 -0
- package/lib/components/Dropdown.react.js +69 -47
- package/lib/components/Graph.react.js +36 -24
- package/lib/components/Input.react.js +98 -92
- package/lib/components/Interval.react.js +18 -12
- package/lib/components/Link.react.js +36 -30
- package/lib/components/Loading.react.js +21 -15
- package/lib/components/Location.react.js +15 -13
- package/lib/components/LogoutButton.react.js +18 -14
- package/lib/components/Markdown.react.js +23 -17
- package/lib/components/RadioItems.react.js +77 -35
- package/lib/components/RangeSlider.react.js +61 -55
- package/lib/components/Slider.react.js +52 -46
- package/lib/components/Store.react.js +16 -16
- package/lib/components/Tab.react.js +6 -2
- package/lib/components/Tabs.react.js +32 -23
- package/lib/components/Textarea.react.js +19 -13
- package/lib/components/Tooltip.react.js +152 -0
- package/lib/components/Upload.react.js +25 -19
- package/lib/components/css/Dropdown.css +1 -1
- package/lib/fragments/DatePickerRange.react.js +63 -51
- package/lib/fragments/DatePickerSingle.react.js +28 -17
- package/lib/fragments/Dropdown.react.js +33 -22
- package/lib/fragments/Graph.privateprops.js +1 -1
- package/lib/fragments/Graph.react.js +44 -28
- package/lib/fragments/Loading/spinners/CircleSpinner.js +16 -16
- package/lib/fragments/Loading/spinners/CubeSpinner.js +11 -11
- package/lib/fragments/Loading/spinners/DefaultSpinner.js +9 -9
- package/lib/fragments/Loading/spinners/DotSpinner.js +7 -7
- package/lib/fragments/Loading/spinners/GraphSpinner.js +18 -18
- package/lib/fragments/Markdown.react.js +35 -32
- package/lib/fragments/RangeSlider.react.js +57 -22
- package/lib/fragments/Slider.react.js +40 -21
- package/lib/fragments/Upload.react.js +19 -13
- package/lib/index.js +77 -53
- package/lib/third-party/highlight.js +12 -0
- package/lib/utils/LazyLoader/datePickerRange.js +9 -3
- package/lib/utils/LazyLoader/datePickerSingle.js +9 -3
- package/lib/utils/LazyLoader/dropdown.js +9 -3
- package/lib/utils/LazyLoader/graph.js +9 -3
- package/lib/utils/LazyLoader/hljs.js +9 -3
- package/lib/utils/LazyLoader/markdown.js +9 -3
- package/lib/utils/LazyLoader/plotly.js +9 -3
- package/lib/utils/LazyLoader/rangeSlider.js +9 -3
- package/lib/utils/LazyLoader/slider.js +9 -3
- package/lib/utils/LazyLoader/upload.js +9 -3
- package/lib/utils/computeSliderMarkers.js +230 -0
- package/lib/utils/convertToMoment.js +4 -0
- package/lib/utils/optionTypes.js +52 -0
- package/package.json +68 -75
- package/CHANGELOG.md +0 -1034
- package/dash_core_components/dash_core_components.min.js +0 -2
- package/dash_core_components/dash_core_components.min.js.map +0 -1
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
+
|
|
3
5
|
Object.defineProperty(exports, "__esModule", {
|
|
4
6
|
value: true
|
|
5
7
|
});
|
|
@@ -15,25 +17,27 @@ var _ConfirmDialog = _interopRequireDefault(require("./ConfirmDialog.react"));
|
|
|
15
17
|
|
|
16
18
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
17
19
|
|
|
18
|
-
function _typeof(obj) { if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
|
|
19
|
-
|
|
20
20
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
21
21
|
|
|
22
22
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
23
23
|
|
|
24
24
|
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
25
25
|
|
|
26
|
-
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
26
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
27
27
|
|
|
28
|
-
function
|
|
28
|
+
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } Object.defineProperty(subClass, "prototype", { value: Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }), writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
29
29
|
|
|
30
|
-
function
|
|
30
|
+
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
31
31
|
|
|
32
|
-
function
|
|
32
|
+
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
33
33
|
|
|
34
|
-
function
|
|
34
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
|
35
35
|
|
|
36
|
-
function
|
|
36
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
37
|
+
|
|
38
|
+
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
39
|
+
|
|
40
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
37
41
|
|
|
38
42
|
/**
|
|
39
43
|
* A wrapper component that will display a confirmation dialog
|
|
@@ -47,15 +51,15 @@ function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || func
|
|
|
47
51
|
* id='confirm')
|
|
48
52
|
* ```
|
|
49
53
|
*/
|
|
50
|
-
var ConfirmDialogProvider =
|
|
51
|
-
/*#__PURE__*/
|
|
52
|
-
function (_React$Component) {
|
|
54
|
+
var ConfirmDialogProvider = /*#__PURE__*/function (_React$Component) {
|
|
53
55
|
_inherits(ConfirmDialogProvider, _React$Component);
|
|
54
56
|
|
|
57
|
+
var _super = _createSuper(ConfirmDialogProvider);
|
|
58
|
+
|
|
55
59
|
function ConfirmDialogProvider() {
|
|
56
60
|
_classCallCheck(this, ConfirmDialogProvider);
|
|
57
61
|
|
|
58
|
-
return
|
|
62
|
+
return _super.apply(this, arguments);
|
|
59
63
|
}
|
|
60
64
|
|
|
61
65
|
_createClass(ConfirmDialogProvider, [{
|
|
@@ -77,13 +81,13 @@ function (_React$Component) {
|
|
|
77
81
|
});
|
|
78
82
|
};
|
|
79
83
|
|
|
80
|
-
return _react.default.cloneElement(child, props);
|
|
84
|
+
return /*#__PURE__*/_react.default.cloneElement(child, props);
|
|
81
85
|
};
|
|
82
86
|
|
|
83
|
-
return _react.default.createElement("div", {
|
|
87
|
+
return /*#__PURE__*/_react.default.createElement("div", {
|
|
84
88
|
id: id,
|
|
85
89
|
"data-dash-is-loading": loading_state && loading_state.is_loading || undefined
|
|
86
|
-
}, Array.isArray(children) ? children.map(wrapClick) : wrapClick(children), _react.default.createElement(_ConfirmDialog.default, _extends({}, this.props, {
|
|
90
|
+
}, Array.isArray(children) ? children.map(wrapClick) : wrapClick(children), /*#__PURE__*/_react.default.createElement(_ConfirmDialog.default, _extends({}, this.props, {
|
|
87
91
|
displayed: displayed
|
|
88
92
|
})));
|
|
89
93
|
}
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
+
|
|
3
5
|
Object.defineProperty(exports, "__esModule", {
|
|
4
6
|
value: true
|
|
5
7
|
});
|
|
6
|
-
exports.
|
|
8
|
+
exports.propTypes = exports.defaultProps = exports.default = void 0;
|
|
7
9
|
|
|
8
10
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
9
11
|
|
|
@@ -13,29 +15,33 @@ var _datePickerRange = _interopRequireDefault(require("../utils/LazyLoader/dateP
|
|
|
13
15
|
|
|
14
16
|
var _DatePickerPersistence = _interopRequireDefault(require("../utils/DatePickerPersistence"));
|
|
15
17
|
|
|
16
|
-
function
|
|
18
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
17
19
|
|
|
18
|
-
function
|
|
20
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
19
21
|
|
|
20
|
-
function
|
|
22
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
21
23
|
|
|
22
24
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
23
25
|
|
|
24
26
|
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
25
27
|
|
|
26
|
-
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
28
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
27
29
|
|
|
28
|
-
function
|
|
30
|
+
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } Object.defineProperty(subClass, "prototype", { value: Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }), writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
29
31
|
|
|
30
|
-
function
|
|
32
|
+
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
31
33
|
|
|
32
|
-
function
|
|
34
|
+
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
33
35
|
|
|
34
|
-
function
|
|
36
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
|
35
37
|
|
|
36
|
-
function
|
|
38
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
39
|
+
|
|
40
|
+
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
41
|
+
|
|
42
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
37
43
|
|
|
38
|
-
var RealDatePickerRange = (0, _react.lazy)(_datePickerRange.default);
|
|
44
|
+
var RealDatePickerRange = /*#__PURE__*/(0, _react.lazy)(_datePickerRange.default);
|
|
39
45
|
/**
|
|
40
46
|
* DatePickerRange is a tailor made component designed for selecting
|
|
41
47
|
* timespan across multiple days off of a calendar.
|
|
@@ -48,23 +54,23 @@ var RealDatePickerRange = (0, _react.lazy)(_datePickerRange.default);
|
|
|
48
54
|
* which can be found here: https://github.com/airbnb/react-dates
|
|
49
55
|
*/
|
|
50
56
|
|
|
51
|
-
var DatePickerRange =
|
|
52
|
-
/*#__PURE__*/
|
|
53
|
-
function (_Component) {
|
|
57
|
+
var DatePickerRange = /*#__PURE__*/function (_Component) {
|
|
54
58
|
_inherits(DatePickerRange, _Component);
|
|
55
59
|
|
|
60
|
+
var _super = _createSuper(DatePickerRange);
|
|
61
|
+
|
|
56
62
|
function DatePickerRange() {
|
|
57
63
|
_classCallCheck(this, DatePickerRange);
|
|
58
64
|
|
|
59
|
-
return
|
|
65
|
+
return _super.apply(this, arguments);
|
|
60
66
|
}
|
|
61
67
|
|
|
62
68
|
_createClass(DatePickerRange, [{
|
|
63
69
|
key: "render",
|
|
64
70
|
value: function render() {
|
|
65
|
-
return _react.default.createElement(_react.Suspense, {
|
|
71
|
+
return /*#__PURE__*/_react.default.createElement(_react.Suspense, {
|
|
66
72
|
fallback: null
|
|
67
|
-
}, _react.default.createElement(RealDatePickerRange, this.props));
|
|
73
|
+
}, /*#__PURE__*/_react.default.createElement(RealDatePickerRange, this.props));
|
|
68
74
|
}
|
|
69
75
|
}]);
|
|
70
76
|
|
|
@@ -73,13 +79,6 @@ function (_Component) {
|
|
|
73
79
|
|
|
74
80
|
exports.default = DatePickerRange;
|
|
75
81
|
DatePickerRange.propTypes = {
|
|
76
|
-
/**
|
|
77
|
-
* The ID of this component, used to identify dash components
|
|
78
|
-
* in callbacks. The ID needs to be unique across all of the
|
|
79
|
-
* components in an app.
|
|
80
|
-
*/
|
|
81
|
-
id: _propTypes.default.string,
|
|
82
|
-
|
|
83
82
|
/**
|
|
84
83
|
* Specifies the starting date for the component.
|
|
85
84
|
* Accepts datetime.datetime objects or strings
|
|
@@ -87,18 +86,6 @@ DatePickerRange.propTypes = {
|
|
|
87
86
|
*/
|
|
88
87
|
start_date: _propTypes.default.string,
|
|
89
88
|
|
|
90
|
-
/**
|
|
91
|
-
* The HTML element ID of the start date input field.
|
|
92
|
-
* Not used by Dash, only by CSS.
|
|
93
|
-
*/
|
|
94
|
-
start_date_id: _propTypes.default.string,
|
|
95
|
-
|
|
96
|
-
/**
|
|
97
|
-
* The HTML element ID of the end date input field.
|
|
98
|
-
* Not used by Dash, only by CSS.
|
|
99
|
-
*/
|
|
100
|
-
end_date_id: _propTypes.default.string,
|
|
101
|
-
|
|
102
89
|
/**
|
|
103
90
|
* Specifies the ending date for the component.
|
|
104
91
|
* Accepts datetime.datetime objects or strings
|
|
@@ -121,12 +108,27 @@ DatePickerRange.propTypes = {
|
|
|
121
108
|
max_date_allowed: _propTypes.default.string,
|
|
122
109
|
|
|
123
110
|
/**
|
|
124
|
-
* Specifies
|
|
125
|
-
*
|
|
111
|
+
* Specifies additional days between min_date_allowed and max_date_allowed
|
|
112
|
+
* that should be disabled. Accepted datetime.datetime objects or strings
|
|
126
113
|
* in the format 'YYYY-MM-DD'
|
|
127
|
-
*
|
|
128
114
|
*/
|
|
129
|
-
|
|
115
|
+
disabled_days: _propTypes.default.arrayOf(_propTypes.default.string),
|
|
116
|
+
|
|
117
|
+
/**
|
|
118
|
+
* Specifies a minimum number of nights that must be selected between
|
|
119
|
+
* the startDate and the endDate
|
|
120
|
+
*/
|
|
121
|
+
minimum_nights: _propTypes.default.number,
|
|
122
|
+
|
|
123
|
+
/**
|
|
124
|
+
* Determines when the component should update
|
|
125
|
+
* its value. If `bothdates`, then the DatePicker
|
|
126
|
+
* will only trigger its value when the user has
|
|
127
|
+
* finished picking both dates. If `singledate`, then
|
|
128
|
+
* the DatePicker will update its value
|
|
129
|
+
* as one date is picked.
|
|
130
|
+
*/
|
|
131
|
+
updatemode: _propTypes.default.oneOf(['singledate', 'bothdates']),
|
|
130
132
|
|
|
131
133
|
/**
|
|
132
134
|
* Text that will be displayed in the first input
|
|
@@ -141,22 +143,19 @@ DatePickerRange.propTypes = {
|
|
|
141
143
|
end_date_placeholder_text: _propTypes.default.string,
|
|
142
144
|
|
|
143
145
|
/**
|
|
144
|
-
*
|
|
145
|
-
*
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
/**
|
|
150
|
-
* Orientation of calendar, either vertical or horizontal.
|
|
151
|
-
* Valid options are 'vertical' or 'horizontal'.
|
|
146
|
+
* Specifies the month that is initially presented when the user
|
|
147
|
+
* opens the calendar. Accepts datetime.datetime objects or strings
|
|
148
|
+
* in the format 'YYYY-MM-DD'
|
|
149
|
+
*
|
|
152
150
|
*/
|
|
153
|
-
|
|
151
|
+
initial_visible_month: _propTypes.default.string,
|
|
154
152
|
|
|
155
153
|
/**
|
|
156
|
-
*
|
|
157
|
-
*
|
|
154
|
+
* Whether or not the dropdown is "clearable", that is, whether or
|
|
155
|
+
* not a small "x" appears on the right of the dropdown that removes
|
|
156
|
+
* the selected value.
|
|
158
157
|
*/
|
|
159
|
-
|
|
158
|
+
clearable: _propTypes.default.bool,
|
|
160
159
|
|
|
161
160
|
/**
|
|
162
161
|
* If True, the calendar will automatically open when cleared
|
|
@@ -164,22 +163,23 @@ DatePickerRange.propTypes = {
|
|
|
164
163
|
reopen_calendar_on_clear: _propTypes.default.bool,
|
|
165
164
|
|
|
166
165
|
/**
|
|
167
|
-
*
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
*
|
|
173
|
-
* not supported on vertical calendar
|
|
166
|
+
* Specifies the format that the selected dates will be displayed
|
|
167
|
+
* valid formats are variations of "MM YY DD". For example:
|
|
168
|
+
* "MM YY DD" renders as '05 10 97' for May 10th 1997
|
|
169
|
+
* "MMMM, YY" renders as 'May, 1997' for May 10th 1997
|
|
170
|
+
* "M, D, YYYY" renders as '07, 10, 1997' for September 10th 1997
|
|
171
|
+
* "MMMM" renders as 'May' for May 10 1997
|
|
174
172
|
*/
|
|
175
|
-
|
|
173
|
+
display_format: _propTypes.default.string,
|
|
176
174
|
|
|
177
175
|
/**
|
|
178
|
-
*
|
|
179
|
-
*
|
|
180
|
-
*
|
|
176
|
+
* Specifies the format that the month will be displayed in the calendar,
|
|
177
|
+
* valid formats are variations of "MM YY". For example:
|
|
178
|
+
* "MM YY" renders as '05 97' for May 1997
|
|
179
|
+
* "MMMM, YYYY" renders as 'May, 1997' for May 1997
|
|
180
|
+
* "MMM, YY" renders as 'Sep, 97' for September 1997
|
|
181
181
|
*/
|
|
182
|
-
|
|
182
|
+
month_format: _propTypes.default.string,
|
|
183
183
|
|
|
184
184
|
/**
|
|
185
185
|
* Specifies what day is the first day of the week, values must be
|
|
@@ -188,10 +188,10 @@ DatePickerRange.propTypes = {
|
|
|
188
188
|
first_day_of_week: _propTypes.default.oneOf([0, 1, 2, 3, 4, 5, 6]),
|
|
189
189
|
|
|
190
190
|
/**
|
|
191
|
-
*
|
|
192
|
-
* the
|
|
191
|
+
* If True the calendar will display days that rollover into
|
|
192
|
+
* the next month
|
|
193
193
|
*/
|
|
194
|
-
|
|
194
|
+
show_outside_days: _propTypes.default.bool,
|
|
195
195
|
|
|
196
196
|
/**
|
|
197
197
|
* If True the calendar will not close when the user has selected a value
|
|
@@ -200,29 +200,40 @@ DatePickerRange.propTypes = {
|
|
|
200
200
|
stay_open_on_select: _propTypes.default.bool,
|
|
201
201
|
|
|
202
202
|
/**
|
|
203
|
-
*
|
|
204
|
-
*
|
|
203
|
+
* Orientation of calendar, either vertical or horizontal.
|
|
204
|
+
* Valid options are 'vertical' or 'horizontal'.
|
|
205
205
|
*/
|
|
206
|
-
|
|
206
|
+
calendar_orientation: _propTypes.default.oneOf(['vertical', 'horizontal']),
|
|
207
207
|
|
|
208
208
|
/**
|
|
209
|
-
*
|
|
210
|
-
* valid formats are variations of "MM YY". For example:
|
|
211
|
-
* "MM YY" renders as '05 97' for May 1997
|
|
212
|
-
* "MMMM, YYYY" renders as 'May, 1997' for May 1997
|
|
213
|
-
* "MMM, YY" renders as 'Sep, 97' for September 1997
|
|
209
|
+
* Number of calendar months that are shown when calendar is opened
|
|
214
210
|
*/
|
|
215
|
-
|
|
211
|
+
number_of_months_shown: _propTypes.default.number,
|
|
216
212
|
|
|
217
213
|
/**
|
|
218
|
-
*
|
|
219
|
-
*
|
|
220
|
-
* "MM YY DD" renders as '05 10 97' for May 10th 1997
|
|
221
|
-
* "MMMM, YY" renders as 'May, 1997' for May 10th 1997
|
|
222
|
-
* "M, D, YYYY" renders as '07, 10, 1997' for September 10th 1997
|
|
223
|
-
* "MMMM" renders as 'May' for May 10 1997
|
|
214
|
+
* If True, calendar will open in a screen overlay portal,
|
|
215
|
+
* not supported on vertical calendar
|
|
224
216
|
*/
|
|
225
|
-
|
|
217
|
+
with_portal: _propTypes.default.bool,
|
|
218
|
+
|
|
219
|
+
/**
|
|
220
|
+
* If True, calendar will open in a full screen overlay portal, will
|
|
221
|
+
* take precedent over 'withPortal' if both are set to true,
|
|
222
|
+
* not supported on vertical calendar
|
|
223
|
+
*/
|
|
224
|
+
with_full_screen_portal: _propTypes.default.bool,
|
|
225
|
+
|
|
226
|
+
/**
|
|
227
|
+
* Size of rendered calendar days, higher number
|
|
228
|
+
* means bigger day size and larger calendar overall
|
|
229
|
+
*/
|
|
230
|
+
day_size: _propTypes.default.number,
|
|
231
|
+
|
|
232
|
+
/**
|
|
233
|
+
* Determines whether the calendar and days operate
|
|
234
|
+
* from left to right or from right to left
|
|
235
|
+
*/
|
|
236
|
+
is_RTL: _propTypes.default.bool,
|
|
226
237
|
|
|
227
238
|
/**
|
|
228
239
|
* If True, no dates can be selected.
|
|
@@ -230,16 +241,16 @@ DatePickerRange.propTypes = {
|
|
|
230
241
|
disabled: _propTypes.default.bool,
|
|
231
242
|
|
|
232
243
|
/**
|
|
233
|
-
*
|
|
234
|
-
*
|
|
235
|
-
* the selected value.
|
|
244
|
+
* The HTML element ID of the start date input field.
|
|
245
|
+
* Not used by Dash, only by CSS.
|
|
236
246
|
*/
|
|
237
|
-
|
|
247
|
+
start_date_id: _propTypes.default.string,
|
|
238
248
|
|
|
239
249
|
/**
|
|
240
|
-
*
|
|
250
|
+
* The HTML element ID of the end date input field.
|
|
251
|
+
* Not used by Dash, only by CSS.
|
|
241
252
|
*/
|
|
242
|
-
|
|
253
|
+
end_date_id: _propTypes.default.string,
|
|
243
254
|
|
|
244
255
|
/**
|
|
245
256
|
* CSS styles appended to wrapper div
|
|
@@ -252,14 +263,16 @@ DatePickerRange.propTypes = {
|
|
|
252
263
|
className: _propTypes.default.string,
|
|
253
264
|
|
|
254
265
|
/**
|
|
255
|
-
*
|
|
256
|
-
*
|
|
257
|
-
*
|
|
258
|
-
* finished picking both dates. If `singledate`, then
|
|
259
|
-
* the DatePicker will update its value
|
|
260
|
-
* as one date is picked.
|
|
266
|
+
* The ID of this component, used to identify dash components
|
|
267
|
+
* in callbacks. The ID needs to be unique across all of the
|
|
268
|
+
* components in an app.
|
|
261
269
|
*/
|
|
262
|
-
|
|
270
|
+
id: _propTypes.default.string,
|
|
271
|
+
|
|
272
|
+
/**
|
|
273
|
+
* Dash-assigned callback that gets fired when the value changes.
|
|
274
|
+
*/
|
|
275
|
+
setProps: _propTypes.default.func,
|
|
263
276
|
|
|
264
277
|
/**
|
|
265
278
|
* Object that holds the loading state object coming from dash-renderer
|
|
@@ -323,7 +336,8 @@ DatePickerRange.defaultProps = {
|
|
|
323
336
|
disabled: false,
|
|
324
337
|
updatemode: 'singledate',
|
|
325
338
|
persisted_props: ['start_date', 'end_date'],
|
|
326
|
-
persistence_type: 'local'
|
|
339
|
+
persistence_type: 'local',
|
|
340
|
+
disabled_days: []
|
|
327
341
|
};
|
|
328
342
|
var propTypes = DatePickerRange.propTypes;
|
|
329
343
|
exports.propTypes = propTypes;
|