ywana-core8 0.0.543 → 0.0.546

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.
@@ -2153,14 +2153,17 @@ var TreeItem = function TreeItem(_ref3) {
2153
2153
  icon = _ref3$icon === void 0 ? 'description' : _ref3$icon,
2154
2154
  label = _ref3.label,
2155
2155
  actions = _ref3.actions,
2156
- onSelect = _ref3.onSelect;
2156
+ onSelect = _ref3.onSelect,
2157
+ _ref3$selected = _ref3.selected,
2158
+ selected = _ref3$selected === void 0 ? false : _ref3$selected;
2157
2159
 
2158
2160
  function select() {
2159
2161
  if (onSelect) onSelect(id);
2160
2162
  }
2161
2163
 
2164
+ var style = selected ? "selected" : "";
2162
2165
  return /*#__PURE__*/React.createElement("div", {
2163
- className: "tree-item final",
2166
+ className: "tree-item final " + style,
2164
2167
  onClick: select
2165
2168
  }, /*#__PURE__*/React.createElement(Icon, {
2166
2169
  icon: icon,
@@ -5427,12 +5430,14 @@ var CollectionTree = function CollectionTree(props) {
5427
5430
  label: title,
5428
5431
  open: true
5429
5432
  }, node.nodes ? renderNodes(node.nodes) : node.items.map(function (item) {
5433
+ var selected = pageContext.selected && item.id === pageContext.selected.id;
5430
5434
  return /*#__PURE__*/React.createElement(TreeItem, {
5431
5435
  icon: icon,
5432
5436
  key: item.id,
5433
5437
  id: item.id,
5434
5438
  label: item.name,
5435
- onSelect: select
5439
+ onSelect: select,
5440
+ selected: selected
5436
5441
  }, "item");
5437
5442
  }));
5438
5443
  });
@@ -6011,7 +6016,8 @@ var TablePage = function TablePage(props) {
6011
6016
  url = props.url,
6012
6017
  field = props.field,
6013
6018
  host = props.host,
6014
- params = props.params,
6019
+ _props$params = props.params,
6020
+ params = _props$params === void 0 ? "" : _props$params,
6015
6021
  _props$autosave = props.autosave,
6016
6022
  autosave = _props$autosave === void 0 ? true : _props$autosave,
6017
6023
  _props$delay = props.delay,
@@ -6883,6 +6889,10 @@ var TableContext$1 = function TableContext(url, field, host, urlQuery, params) {
6883
6889
 
6884
6890
 
6885
6891
  var TableAPI$1 = function TableAPI(url, host, params) {
6892
+ if (params === void 0) {
6893
+ params = "";
6894
+ }
6895
+
6886
6896
  var http = HTTPClient(host || window.API || process.env.REACT_APP_API, Session);
6887
6897
  return {
6888
6898
  all: function all(filters) {