import"./p-cd1b0e39.js";import{R as n}from"./p-6eb29778.js";import{T as e}from"./p-681f800a.js";import{a as t,l as r}from"./p-214632d0.js";import{a as s}from"./p-234c1f97.js";function o(n){return n.map((n=>({fieldId:n.id})))}function i(n,e){return n.find((n=>n.viewName===e))}function a(t,r,o,i){return[...f(t,r,o),...m(i,r),new n("user","User","firstName","imageUrl","users",[new s("imageUrl",""),new e("firstName","First Name")])]}function c(n,e,t,r){return[...f(n,e,t),...m(r,e)]}function u(n,e,t,r,s,i){let a;return a=s?o(c(n,e,t,r)).map((n=>Object.assign(Object.assign({},n),{lines:1,maxItems:3}))):o(c(n,e,t,r)),i&&(a=a.slice(0,i)),a}function f(n,e,t){const s="mentor"===t?e.profileFieldVisibilities.mentor:e.profileFieldVisibilities.mentee;return r(n).filter((n=>s[n.id]))}function m(n,e){return("none"!==e.metadataVisibility[n]&&("mentor"===n?e.metadatas.mentee:e.metadatas.mentor)||[]).map((n=>t(n)))}function p(n,e,t){const r=("mentor"===n?e.metadatas.mentee:e.metadatas.mentor).map((n=>n.id));return t.filter((({fieldId:n})=>r.includes(n)))}function l(n){const{subscriptionConfig:e}=n;return{isMentorSelectionOn:"showAvailableMentors"===e.mentorVisibilityStatus,canMentorEndSubscription:e.mentorsCanEndSubscription,pairLimitForMentees:n.subscriptionConfig.menteeSubscriptionLimit,selectionLimitForMentees:n.subscriptionConfig.menteeSelectionLimit}}export{m as a,l as b,o as c,a as d,u as e,p as f,i as g,f as h}