"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
    return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
const jsx_runtime_1 = require("react/jsx-runtime");
const profile_1 = __importDefault(require("lib/hooks/profile"));
const util_1 = require("lib/share/util");
function Name({ account_id, style }) {
    const profile = (0, profile_1.default)({ account_id });
    if (profile == null) {
        return (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, {});
    }
    const { first_name, last_name } = profile;
    return (0, jsx_runtime_1.jsx)("span", { style: style, children: (0, util_1.trunc)(`${first_name} ${last_name}`, 50) });
}
exports.default = Name;
//# sourceMappingURL=name.js.map