tabler-react-2 0.1.106 → 0.1.108

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.
@@ -7,7 +7,7 @@ exports.DropdownInput = void 0;
7
7
  var _react = _interopRequireWildcard(require("react"));
8
8
  var _propTypes = _interopRequireDefault(require("prop-types"));
9
9
  var _index = require("../index");
10
- var _excluded = ["prompt", "values", "items", "value", "onChange", "aprops", "showSearch", "loading", "disabled", "disabledText", "label", "showLabel", "color", "outline", "maxHeight"];
10
+ var _excluded = ["prompt", "values", "items", "value", "onChange", "aprops", "showSearch", "loading", "disabled", "disabledText", "label", "showLabel", "color", "outline", "maxHeight", "required"];
11
11
  function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
12
12
  function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
13
13
  function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { "default": e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n["default"] = e, t && t.set(e, n), n; }
@@ -42,6 +42,7 @@ var DropdownInput = exports.DropdownInput = function DropdownInput(_ref) {
42
42
  outline = _ref.outline,
43
43
  _ref$maxHeight = _ref.maxHeight,
44
44
  maxHeight = _ref$maxHeight === void 0 ? "300px" : _ref$maxHeight,
45
+ required = _ref.required,
45
46
  props = _objectWithoutProperties(_ref, _excluded);
46
47
  // Allow aliasing: pass either `values` or `items`
47
48
  var values = ivalues || items || [];
@@ -159,7 +160,7 @@ var DropdownInput = exports.DropdownInput = function DropdownInput(_ref) {
159
160
 
160
161
  // If a label is provided, wrap the dropdown with the label inside a container.
161
162
  return label && showLabel ? /*#__PURE__*/_react["default"].createElement(_index.Util.Col, null, /*#__PURE__*/_react["default"].createElement("label", {
162
- className: "form-label"
163
+ className: "form-label ".concat(required ? "required" : "")
163
164
  }, label), dropdownContent) : dropdownContent;
164
165
  };
165
166
  DropdownInput.propTypes = {
@@ -2,6 +2,10 @@
2
2
  title: Changelog
3
3
  ---
4
4
 
5
+ ## 0.1.108
6
+
7
+ - Added `required` prop to the `DropdownInput` component.
8
+
5
9
  ## 0.1.97
6
10
 
7
11
  - Added `helpText`, `helpTextPlacement`, `helpPrompt`, `required`, `hint`, and `labelDescription` props to the `Input` component.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tabler-react-2",
3
- "version": "0.1.106",
3
+ "version": "0.1.108",
4
4
  "description": "A react implementation of Tabler ui",
5
5
  "main": "dist/index.js",
6
6
  "scripts": {