"use strict";
var __create = Object.create;
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __getProtoOf = Object.getPrototypeOf;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __export = (target, all) => {
  for (var name in all)
    __defProp(target, name, { get: all[name], enumerable: true });
};
var __copyProps = (to, from, except, desc) => {
  if (from && typeof from === "object" || typeof from === "function") {
    for (let key of __getOwnPropNames(from))
      if (!__hasOwnProp.call(to, key) && key !== except)
        __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
  }
  return to;
};
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
  // If the importer is in node compatibility mode or this is not an ESM
  // file that has been converted to a CommonJS file using a Babel-
  // compatible transform (i.e. "__esModule" has not been set), then set
  // "default" to the CommonJS "module.exports" for node compatibility.
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
  mod
));
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
var SuggestedFriends_exports = {};
__export(SuggestedFriends_exports, {
  SuggestedFriendsComponent: () => SuggestedFriendsComponent,
  SuggestedFriends_suggestedFriendsFragment: () => SuggestedFriends_suggestedFriendsFragment
});
module.exports = __toCommonJS(SuggestedFriends_exports);
var React = __toESM(require("react"), 1);
var import_react_relay = require("react-relay");
const SuggestedFriends_suggestedFriendsFragment = import_react_relay.graphql`
  fragment SuggestedFriends_suggestedFriendsFragment on Viewer {
    suggestedFriends {
      id
      name {
        firstName
        lastName
      }
    }
  }
`;
const SuggestedFriendsComponent = (props) => {
  const { suggestedFriends } = (0, import_react_relay.useFragment)(
    SuggestedFriends_suggestedFriendsFragment,
    props.viewer
  );
  if (!suggestedFriends || suggestedFriends.length === 0) {
    return /* @__PURE__ */ React.createElement("div", null, "No suggested friends available.");
  }
  return /* @__PURE__ */ React.createElement("div", { style: { padding: 16 } }, /* @__PURE__ */ React.createElement("h2", null, "Suggested Friends"), suggestedFriends.length === 0 ? /* @__PURE__ */ React.createElement("p", null, "No suggested friends at the moment.") : /* @__PURE__ */ React.createElement("ul", { style: { listStyle: "none", padding: 0 } }, suggestedFriends.map((friend) => {
    var _a, _b;
    return /* @__PURE__ */ React.createElement(
      "li",
      {
        key: friend.id,
        style: {
          padding: 8,
          margin: "8px 0",
          border: "1px solid #ddd",
          borderRadius: 4,
          backgroundColor: "#f9f9f9"
        }
      },
      /* @__PURE__ */ React.createElement("strong", null, (_a = friend.name) == null ? void 0 : _a.firstName, " ", (_b = friend.name) == null ? void 0 : _b.lastName)
    );
  })));
};
