{"version":3,"file":"getEnabledMethods.mjs","sources":["../../../../../../../../web/src/ui/b2b/getEnabledMethods.ts"],"sourcesContent":["export const getEnabledMethods = <TMethod>({\n  allMethods,\n  orgSupportedMethods,\n  uiIncludedMethods,\n}: {\n  allMethods: readonly TMethod[];\n  orgSupportedMethods: readonly TMethod[];\n  uiIncludedMethods: readonly TMethod[] | undefined;\n}) => {\n  // If the org only supported a restricted set of methods, use that\n  if (orgSupportedMethods?.length) {\n    return new Set(orgSupportedMethods);\n  }\n\n  // Use the configured list of included methods, or all methods by default\n  const methodsArr = uiIncludedMethods?.length ? uiIncludedMethods : allMethods;\n  return new Set(methodsArr);\n};\n"],"names":["getEnabledMethods","allMethods","orgSupportedMethods","uiIncludedMethods","length","Set","methodsArr"],"mappings":"AAAO,MAAMA,oBAAoB,CAAU,EACzCC,UAAU,EACVC,mBAAmB,EACnBC,iBAAiB,EAKlB,GAAA;;AAEC,IAAA,IAAID,qBAAqBE,MAAAA,EAAQ;AAC/B,QAAA,OAAO,IAAIC,GAAAA,CAAIH,mBAAAA,CAAAA;AACjB,IAAA;;IAGA,MAAMI,UAAAA,GAAaH,iBAAAA,EAAmBC,MAAAA,GAASD,iBAAAA,GAAoBF,UAAAA;AACnE,IAAA,OAAO,IAAII,GAAAA,CAAIC,UAAAA,CAAAA;AACjB;;;;"}