pollination-react-io 1.26.0 → 1.26.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.
@@ -41810,6 +41810,7 @@ var SelectAccount = function (_a) {
41810
41810
  var _b;
41811
41811
  var authUser = _a.authUser, client = _a.client, value = _a.value, onChange = _a.onChange;
41812
41812
  var comboBoxRef = useRef();
41813
+ var valueRef = useRef();
41813
41814
  var _c = useState(value), selAccount = _c[0], setSelAccount = _c[1];
41814
41815
  var _d = useState(function () { return authUser ? [authUser] : []; }), accounts = _d[0], setAccounts = _d[1];
41815
41816
  var _e = useState(false), loading = _e[0], setLoading = _e[1];
@@ -41824,7 +41825,7 @@ var SelectAccount = function (_a) {
41824
41825
  }), queryConfig = _g[0], setQueryConfig = _g[1];
41825
41826
  // resetting query
41826
41827
  useEffect(function () {
41827
- if (!authUser)
41828
+ if (authUser == null)
41828
41829
  return;
41829
41830
  // reset total loaded
41830
41831
  totalAccountsRef.current = {
@@ -41860,7 +41861,13 @@ var SelectAccount = function (_a) {
41860
41861
  fetchOrganizations(queryConfig);
41861
41862
  }, [fetchOrganizations, queryConfig]);
41862
41863
  useEffect(function () {
41864
+ if (lodash_isequal(valueRef.current, selAccount)) {
41865
+ return;
41866
+ }
41867
+ if (selAccount == null)
41868
+ return;
41863
41869
  comboBoxRef.current.selectItem(selAccount);
41870
+ valueRef.current = selAccount;
41864
41871
  // comboBoxRef.current.setInputValue( selAccount.name )
41865
41872
  onChange && onChange(selAccount);
41866
41873
  }, [onChange, selAccount]);
@@ -41966,6 +41973,8 @@ var SelectRecipe = function (_a) {
41966
41973
  if (lodash_isequal(valueRef.current, selRecipe)) {
41967
41974
  return;
41968
41975
  }
41976
+ if (selRecipe == null)
41977
+ return;
41969
41978
  if (selRecipe && selRecipe.metadata && selRecipe.metadata.name) {
41970
41979
  comboBoxRef.current.setInputValue(selRecipe.metadata.name);
41971
41980
  }
@@ -46340,6 +46349,8 @@ var SelectStudy = function (_a) {
46340
46349
  if (lodash_isequal(valueRef.current, selStudy)) {
46341
46350
  return;
46342
46351
  }
46352
+ if (selStudy == null)
46353
+ return;
46343
46354
  if (selStudy && selStudy.id) {
46344
46355
  if (selStudy.spec.name) {
46345
46356
  comboBoxRef.current.setInputValue(selStudy.spec.name);