unifyedx-storybook-new 0.1.62 → 0.1.63

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.
@@ -75960,14 +75960,14 @@ function DataTableRenderer({ item, data: initialData, updateHandler, validationE
75960
75960
  case "dropdown":
75961
75961
  return (props, rowIndex) => {
75962
75962
  const options = React__default.useMemo(() => {
75963
- if (field.optionsFrom) {
75963
+ if (field.optionsFrom && initialData) {
75964
75964
  const { config, valueField, labelField } = field.optionsFrom;
75965
- const configData = initialData[config];
75965
+ const configData = initialData[config] || [];
75966
75966
  if (Array.isArray(configData)) {
75967
75967
  console.log(`[DataTableRenderer] Generating options for ${field.key} from ${config}:`, configData);
75968
75968
  const mappedOptions = configData.map((item2) => ({
75969
- value: item2[valueField],
75970
- label: item2[labelField]
75969
+ value: item2[valueField] || "",
75970
+ label: item2[labelField] || ""
75971
75971
  }));
75972
75972
  console.log(`[DataTableRenderer] Generated options:`, mappedOptions);
75973
75973
  return mappedOptions;