@local-civics/mgmt-ui 0.1.194 → 0.1.195

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.js CHANGED
@@ -3567,8 +3567,10 @@ var __spreadValues$1 = (a, b) => {
3567
3567
  var __spreadProps$1 = (a, b) => __defProps$1(a, __getOwnPropDescs$1(b));
3568
3568
  function Table$2(props) {
3569
3569
  const preparedItems = React__namespace.useMemo(() => {
3570
+ var _a, _b;
3570
3571
  console.group("Pathway Table Data Check");
3571
- console.log("Raw items from props:", props.items);
3572
+ console.log("Raw items from props:", props);
3573
+ console.log("Raw items from prop.itemss:", props.items);
3572
3574
  console.log("Categories available:", props.categories);
3573
3575
  const mapped = props.items.map((item) => {
3574
3576
  const flatItem = __spreadProps$1(__spreadValues$1({}, item), {
@@ -3582,17 +3584,13 @@ function Table$2(props) {
3582
3584
  return flatItem;
3583
3585
  });
3584
3586
  console.log("Transformed items (Flat):", mapped);
3585
- if (mapped.length > 0 && props.categories.length > 0) {
3586
- const firstStudent = mapped[0];
3587
- const firstCatId = props.categories[0].categoryId;
3588
- console.log(
3589
- `Matching Check: Does student have key [${firstCatId}]?`,
3590
- firstStudent.hasOwnProperty(firstCatId) ? "YES \u2705" : "NO \u274C",
3591
- "Value:",
3592
- firstStudent[firstCatId]
3593
- );
3594
- }
3595
- console.groupEnd();
3587
+ const firstCatId = (_b = (_a = props.categories) == null ? void 0 : _a[0]) == null ? void 0 : _b.categoryId;
3588
+ if (mapped.length > 0 && firstCatId) {
3589
+ console.log(`Matching Check for ID [${firstCatId}]:`, mapped[0][firstCatId] !== void 0 ? "\u2705 FOUND" : "\u274C MISSING");
3590
+ console.groupEnd();
3591
+ } else if (props.categories) {
3592
+ console.groupEnd();
3593
+ }
3596
3594
  return mapped;
3597
3595
  }, [props.items, props.categories]);
3598
3596
  const { items: sortedItems, requestSort, sortConfig } = useSortableData(preparedItems);