pollination-react-io 1.8.0 → 1.8.1

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.
@@ -22,7 +22,7 @@ export declare class APIClient {
22
22
  constructor(props: ConfigurationParameters);
23
23
  private init;
24
24
  /** Overwrite current configuration and re-create all api clients. */
25
- configure(basePath?: string, token?: string): void;
25
+ configure(config: Partial<ConfigurationParameters>): void;
26
26
  }
27
27
  export declare const useAPIClient: (config?: ConfigurationParameters) => {
28
28
  client: React.MutableRefObject<APIClient>;
@@ -21564,8 +21564,8 @@ var APIClient = /** @class */ (function () {
21564
21564
  this.applications = new dist.ApplicationsApi(this.config);
21565
21565
  };
21566
21566
  /** Overwrite current configuration and re-create all api clients. */
21567
- APIClient.prototype.configure = function (basePath, token) {
21568
- this.config = new dist.Configuration({ basePath: basePath, accessToken: token });
21567
+ APIClient.prototype.configure = function (config) {
21568
+ this.config = new dist.Configuration(config);
21569
21569
  this.init();
21570
21570
  };
21571
21571
  return APIClient;
@@ -21578,6 +21578,7 @@ var useAPIClient = function (config) {
21578
21578
  useEffect(function () {
21579
21579
  if (!config)
21580
21580
  return;
21581
+ client.current.configure(__assign$3({ basePath: basePath }, config));
21581
21582
  setLoading(true);
21582
21583
  client.current.user.getMe()
21583
21584
  .then(function (_a) {
@@ -31858,7 +31859,7 @@ var ComboBox = React__default.forwardRef(function ComboBox(_a, ref) {
31858
31859
  return;
31859
31860
  debouncedOnScrollReachEnd && debouncedOnScrollReachEnd();
31860
31861
  } },
31861
- React__default.createElement("ul", __assign$3({}, getMenuProps(), { style: __assign$3(__assign$3({}, menuStyle), { display: 'flex', width: '100%', boxSizing: 'border-box', zIndex: 100, padding: 0, flexDirection: 'column' }) }), inputItems.map(function (item, i, arr) { return (React__default.createElement("li", __assign$3({ className: "poll-combobox-item", style: highlightedIndex === i ? { backgroundColor: '#bde4ff' } : {}, key: "".concat(item.name, "-").concat(i) }, getItemProps({
31862
+ React__default.createElement("ul", __assign$3({}, getMenuProps(), { style: __assign$3(__assign$3({}, menuStyle), { display: 'flex', width: '100%', boxSizing: 'border-box', zIndex: 100, padding: 0, flexDirection: 'column', margin: 0 }) }), inputItems.map(function (item, i, arr) { return (React__default.createElement("li", __assign$3({ className: "poll-combobox-item", style: highlightedIndex === i ? { backgroundColor: '#bde4ff' } : {}, key: "".concat(item.name, "-").concat(i) }, getItemProps({
31862
31863
  item: item,
31863
31864
  index: i,
31864
31865
  // isSelected: selectedItem && selectedItem.id === item.id,