@algorithm-shift/design-system 1.2.993 → 1.2.995

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.
package/dist/index.mjs CHANGED
@@ -764,7 +764,7 @@ function Icon(props) {
764
764
  ...rest
765
765
  } = props;
766
766
  const [dynamicIcon, setDynamicIcon] = useState5(icon || null);
767
- async function loadFAIcon(iconName, prefix2 = "fas") {
767
+ async function loadFAIcon(iconName, prefix2) {
768
768
  const pkgMap = {
769
769
  fas: SolidIcons,
770
770
  far: RegularIcons,
@@ -774,7 +774,7 @@ function Icon(props) {
774
774
  return basePackage[iconName] ?? null;
775
775
  }
776
776
  useEffect3(() => {
777
- if (icon && iconSet === "fontawesome") {
777
+ if (icon && iconSet === "fontawesome" && prefix) {
778
778
  loadFAIcon(icon, prefix).then((ico) => setDynamicIcon(ico));
779
779
  }
780
780
  }, [iconSet, icon, prefix]);
@@ -2029,7 +2029,8 @@ function LazySelectDropdown({
2029
2029
  errorMessage,
2030
2030
  axiosInstance,
2031
2031
  enableAddNewOption = false,
2032
- enforceStrictQueryParams = false
2032
+ enforceStrictQueryParams = false,
2033
+ ...props
2033
2034
  }) {
2034
2035
  const [isOpen, setIsOpen] = useState8(false);
2035
2036
  const [searchTerm, setSearchTerm] = useState8("");
@@ -2155,7 +2156,10 @@ function LazySelectDropdown({
2155
2156
  top: dropdownRef.current ? dropdownRef.current.getBoundingClientRect().bottom + window.scrollY : 0,
2156
2157
  left: dropdownRef.current ? dropdownRef.current.getBoundingClientRect().left + window.scrollX : 0
2157
2158
  },
2158
- children: loading && lazyOptions.length === 0 ? /* @__PURE__ */ jsxs19("div", { className: "px-3 py-4 text-center text-gray-500 flex items-center justify-center gap-2 text-sm", children: [
2159
+ children: props.loading && !loading ? /* @__PURE__ */ jsxs19("div", { className: "px-3 py-4 text-center text-gray-500 flex items-center justify-center gap-2 text-sm", children: [
2160
+ /* @__PURE__ */ jsx36("div", { className: "animate-spin w-4 h-4 border-2 border-gray-300 border-t-blue-500 rounded-full" }),
2161
+ "Loading..."
2162
+ ] }) : /* @__PURE__ */ jsx36(Fragment11, { children: loading && lazyOptions.length === 0 ? /* @__PURE__ */ jsxs19("div", { className: "px-3 py-4 text-center text-gray-500 flex items-center justify-center gap-2 text-sm", children: [
2159
2163
  /* @__PURE__ */ jsx36("div", { className: "animate-spin w-4 h-4 border-2 border-gray-300 border-t-blue-500 rounded-full" }),
2160
2164
  "Loading..."
2161
2165
  ] }) : lazyOptions.length > 0 ? /* @__PURE__ */ jsxs19(Fragment11, { children: [
@@ -2193,7 +2197,7 @@ function LazySelectDropdown({
2193
2197
  children: `Add "${searchTerm}"`
2194
2198
  }
2195
2199
  )
2196
- ] })
2200
+ ] }) })
2197
2201
  }
2198
2202
  ) })
2199
2203
  ] });
@@ -4258,8 +4262,8 @@ var Table2 = ({
4258
4262
  onFilterChange: (filters) => onFilterChange?.({ columnKey: filters.columnKey, columnTerm: filters.columnTerm }),
4259
4263
  onGlobalSearch: (term) => onGlobalSearch?.({ searchTerm: term }),
4260
4264
  globalSearch,
4261
- onCellClick: (cell) => {
4262
- onCellClick?.({ id: cell.id, column: cell });
4265
+ onCellClick: (cell, columnId) => {
4266
+ onCellClick?.({ id: cell.id, column: cell, columnId });
4263
4267
  },
4264
4268
  onDeleteRow: (cell) => {
4265
4269
  onDeleteRow?.(cell.id);