gdx-ui 1.12.5 → 1.12.7

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.
@@ -105,8 +105,7 @@ var BoxToolbar = exports.BoxToolbar = function BoxToolbar(_ref4) {
105
105
  borderBottom = _ref4$borderBottom === void 0 ? false : _ref4$borderBottom;
106
106
  var _useContext3 = (0, _react.useContext)(BoxContext),
107
107
  settings = _useContext3.settings;
108
- var open = settings.open,
109
- isLoading = settings.isLoading;
108
+ var open = settings.open;
110
109
  return /*#__PURE__*/_react["default"].createElement("div", {
111
110
  className: "box-toolbar \n ".concat(spacing ? 'content' : '', "\n ").concat(open ? '' : 'hidden', "\n ").concat(borderTop ? 'border-top' : '', "\n ").concat(borderBottom ? 'border-bottom' : '', "\n ")
112
111
  }, children);
@@ -7,7 +7,7 @@ exports.IconButton = void 0;
7
7
  var _react = _interopRequireDefault(require("react"));
8
8
  var _propTypes = _interopRequireDefault(require("prop-types"));
9
9
  var _reactFontawesome = require("@fortawesome/react-fontawesome");
10
- var _excluded = ["icon", "className", "bg", "size", "color"];
10
+ var _excluded = ["icon", "type", "className", "bg", "size", "color"];
11
11
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
12
12
  function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
13
13
  function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
@@ -19,6 +19,8 @@ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) r
19
19
  */
20
20
  var IconButton = exports.IconButton = function IconButton(_ref) {
21
21
  var icon = _ref.icon,
22
+ _ref$type = _ref.type,
23
+ type = _ref$type === void 0 ? 'button' : _ref$type,
22
24
  _ref$className = _ref.className,
23
25
  className = _ref$className === void 0 ? '' : _ref$className,
24
26
  _ref$bg = _ref.bg,
@@ -29,6 +31,7 @@ var IconButton = exports.IconButton = function IconButton(_ref) {
29
31
  color = _ref$color === void 0 ? 'default' : _ref$color,
30
32
  props = _objectWithoutProperties(_ref, _excluded);
31
33
  return /*#__PURE__*/_react["default"].createElement("button", _extends({
34
+ type: type,
32
35
  className: "btn-circle btn-circle-bg-".concat(bg, " btn-circle-size-").concat(size, " ").concat(className)
33
36
  }, props), /*#__PURE__*/_react["default"].createElement(_reactFontawesome.FontAwesomeIcon, {
34
37
  className: "".concat(color ? "".concat(color, "-color") : ''),
@@ -37,6 +40,8 @@ var IconButton = exports.IconButton = function IconButton(_ref) {
37
40
  };
38
41
  IconButton.propTypes = {
39
42
  icon: _propTypes["default"].any,
43
+ type: _propTypes["default"].string,
44
+ className: _propTypes["default"].string,
40
45
  bg: _propTypes["default"].oneOf(['clear', 'solid']),
41
46
  color: _propTypes["default"].oneOf(['default', 'invert', 'primary', 'alert', 'success']),
42
47
  size: _propTypes["default"].oneOf(['default', 'small', 'large'])
@@ -130,7 +130,7 @@ var Pagination = exports.Pagination = function Pagination(_ref) {
130
130
  icon: _freeSolidSvgIcons.faAngleRight
131
131
  })))), /*#__PURE__*/_react["default"].createElement("div", {
132
132
  className: "pagination-note gray center"
133
- }, "Mostrando ", recordsDisplayed, " de ", totalRecords, " registros. ", pages, " p\xE1ginas."));
133
+ }, "Mostrando ", recordsDisplayed < totalRecords ? recordsDisplayed : totalRecords, " de ", totalRecords, " registros. P\xE1g. ", page, " de ", pages, " ", pages > 1 ? 'páginas' : 'página', "."));
134
134
  };
135
135
  Pagination.propTypes = {
136
136
  page: _propTypes["default"].number,
@@ -9,7 +9,13 @@ var _propTypes = _interopRequireDefault(require("prop-types"));
9
9
  var _reactFontawesome = require("@fortawesome/react-fontawesome");
10
10
  var _freeSolidSvgIcons = require("@fortawesome/free-solid-svg-icons");
11
11
  var _utils = require("../../utils/utils");
12
+ var _excluded = ["children", "className", "bordered", "expanded", "striped", "hover"],
13
+ _excluded2 = ["children", "id", "color", "className"],
14
+ _excluded3 = ["children", "id", "className", "align"];
12
15
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
16
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
17
+ function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
18
+ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
13
19
  var Table = exports.Table = function Table(_ref) {
14
20
  var children = _ref.children,
15
21
  className = _ref.className,
@@ -20,10 +26,11 @@ var Table = exports.Table = function Table(_ref) {
20
26
  _ref$striped = _ref.striped,
21
27
  striped = _ref$striped === void 0 ? false : _ref$striped,
22
28
  _ref$hover = _ref.hover,
23
- hover = _ref$hover === void 0 ? false : _ref$hover;
24
- return /*#__PURE__*/_react["default"].createElement("table", {
25
- className: "table ".concat(expanded ? "expanded" : '', " \n ").concat(hover ? "table-hover" : '', "\n ").concat(bordered ? "bordered" : '', "\n ").concat(striped ? "table-striped" : '', "\n ").concat(className ? className : '')
26
- }, children);
29
+ hover = _ref$hover === void 0 ? false : _ref$hover,
30
+ props = _objectWithoutProperties(_ref, _excluded);
31
+ return /*#__PURE__*/_react["default"].createElement("table", _extends({
32
+ className: "table ".concat(expanded ? 'expanded' : '', " \n ").concat(hover ? 'table-hover' : '', "\n ").concat(bordered ? 'bordered' : '', "\n ").concat(striped ? 'table-striped' : '', "\n ").concat(className ? className : '')
33
+ }, props), children);
27
34
  };
28
35
  /**
29
36
  *
@@ -69,22 +76,25 @@ var TableBody = exports.TableBody = function TableBody(_ref5) {
69
76
  var TableRow = exports.TableRow = function TableRow(_ref6) {
70
77
  var children = _ref6.children,
71
78
  id = _ref6.id,
72
- color = _ref6.color;
73
- return /*#__PURE__*/_react["default"].createElement("tr", {
79
+ color = _ref6.color,
80
+ className = _ref6.className,
81
+ props = _objectWithoutProperties(_ref6, _excluded2);
82
+ return /*#__PURE__*/_react["default"].createElement("tr", _extends({
74
83
  key: id ? id : (0, _utils.generateId)(),
75
- className: "".concat(color && "highlight-".concat(color))
76
- }, children);
84
+ className: "".concat(color && "highlight-".concat(color), " ").concat(className ? className : '')
85
+ }, props), children);
77
86
  };
78
87
  var TableData = exports.TableData = function TableData(_ref7) {
79
88
  var children = _ref7.children,
80
89
  id = _ref7.id,
81
90
  className = _ref7.className,
82
91
  _ref7$align = _ref7.align,
83
- align = _ref7$align === void 0 ? 'left' : _ref7$align;
84
- return /*#__PURE__*/_react["default"].createElement("td", {
92
+ align = _ref7$align === void 0 ? 'left' : _ref7$align,
93
+ props = _objectWithoutProperties(_ref7, _excluded3);
94
+ return /*#__PURE__*/_react["default"].createElement("td", _extends({
85
95
  key: id ? id : (0, _utils.generateId)(),
86
96
  className: "".concat(align, " ").concat(className ? className : '')
87
- }, children);
97
+ }, props), children);
88
98
  };
89
99
  var TableRowSkeleton = exports.TableRowSkeleton = function TableRowSkeleton(_ref8) {
90
100
  var id = _ref8.id,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gdx-ui",
3
- "version": "1.12.5",
3
+ "version": "1.12.7",
4
4
  "description": "UI gdx",
5
5
  "main": "index.js",
6
6
  "module": "index.js",