@streamoid/settings 0.18.0 → 0.19.0

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.mjs CHANGED
@@ -9693,7 +9693,11 @@ function Spinner() {
9693
9693
  }
9694
9694
  );
9695
9695
  }
9696
- function LoadError({ message, onRetry }) {
9696
+ function LoadError({
9697
+ message,
9698
+ onRetry,
9699
+ retryLabel = "Try again"
9700
+ }) {
9697
9701
  return /* @__PURE__ */ jsxs22(
9698
9702
  "div",
9699
9703
  {
@@ -9708,7 +9712,7 @@ function LoadError({ message, onRetry }) {
9708
9712
  },
9709
9713
  children: [
9710
9714
  /* @__PURE__ */ jsx25("p", { style: { margin: 0, fontFamily: T15.font, fontSize: T15.fsSm, lineHeight: T15.lhSm, color: T15.primary }, children: message }),
9711
- /* @__PURE__ */ jsx25(ScButton10, { text: "Try again", variant: "outline", size: "sm", onClick: onRetry })
9715
+ /* @__PURE__ */ jsx25(ScButton10, { text: retryLabel, variant: "outline", size: "sm", onClick: onRetry })
9712
9716
  ]
9713
9717
  }
9714
9718
  );
@@ -14406,14 +14410,158 @@ function referralCodeOf(user) {
14406
14410
  function referralLink(code, origin) {
14407
14411
  return code && origin ? `${origin}?referral_code=${encodeURIComponent(code)}` : "";
14408
14412
  }
14413
+ var MONTHS = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"];
14414
+ function referralSignupDate(iso) {
14415
+ const date = iso ? new Date(iso) : null;
14416
+ if (!date || Number.isNaN(date.valueOf())) return "\u2013";
14417
+ return `${date.getDate()} ${MONTHS[date.getMonth()]} ${date.getFullYear()}`;
14418
+ }
14419
+ function sortReferredUsers(users) {
14420
+ const time = (u) => {
14421
+ const t = new Date(u.createdAt).valueOf();
14422
+ return Number.isNaN(t) ? -Infinity : t;
14423
+ };
14424
+ return [...users].sort((a, b) => time(b) - time(a));
14425
+ }
14426
+ function referralCountLabel(count) {
14427
+ return `${count} ${count === 1 ? "person" : "people"} signed up with your link`;
14428
+ }
14429
+ var MOCK_REFERRED_USERS = [
14430
+ { id: "r1", email: "chris@kepler.com", createdAt: "2025-11-09T10:30:00.000Z" },
14431
+ { id: "r2", email: "maya@northwind.studio", createdAt: "2026-11-24T06:15:00.000Z" },
14432
+ { id: "r3", email: "arjun@lumen.co", createdAt: "2026-03-02T12:00:00.000Z" }
14433
+ ];
14434
+
14435
+ // src/referral-history.tsx
14436
+ import { jsx as jsx32, jsxs as jsxs29 } from "react/jsx-runtime";
14437
+ var TITLE_ID = "settings-referral-history-title";
14438
+ var SKELETON_ROWS = 3;
14439
+ var REFERRAL_HISTORY_EMPTY = "No one has signed up with your link yet. Share it to get started.";
14440
+ var LOAD_FAILED = "Couldn't load your referral history.";
14441
+ function ReferralHistory({
14442
+ load
14443
+ }) {
14444
+ const { value, error, retry } = useLoad(
14445
+ "referred-users",
14446
+ (signal) => load(signal),
14447
+ LOAD_FAILED
14448
+ );
14449
+ return /* @__PURE__ */ jsx32(ReferralHistoryView, { users: value, error, onRetry: retry });
14450
+ }
14451
+ function ReferralHistoryView({ users, error, onRetry }) {
14452
+ let body;
14453
+ if (error) {
14454
+ body = /* @__PURE__ */ jsx32(LoadError, { message: error, onRetry, retryLabel: "Retry" });
14455
+ } else if (!users) {
14456
+ body = /* @__PURE__ */ jsx32(HistorySkeleton, {});
14457
+ } else if (users.length === 0) {
14458
+ body = /* @__PURE__ */ jsx32(Card2, { children: /* @__PURE__ */ jsx32("div", { style: { padding: T15.sp6xl }, children: /* @__PURE__ */ jsx32(Muted, { children: REFERRAL_HISTORY_EMPTY }) }) });
14459
+ } else {
14460
+ body = /* @__PURE__ */ jsx32(HistoryTable, { users: sortReferredUsers(users) });
14461
+ }
14462
+ return /* @__PURE__ */ jsxs29("section", { "aria-labelledby": TITLE_ID, className: "flex flex-col w-full", style: { gap: T15.spXl }, children: [
14463
+ /* @__PURE__ */ jsxs29("div", { className: "flex flex-col", style: { gap: T15.spXs }, children: [
14464
+ /* @__PURE__ */ jsx32(
14465
+ "h2",
14466
+ {
14467
+ id: TITLE_ID,
14468
+ style: {
14469
+ margin: 0,
14470
+ fontFamily: T15.font,
14471
+ fontSize: T15.fsSm,
14472
+ fontWeight: 400,
14473
+ lineHeight: T15.lhSm,
14474
+ color: "var(--alias-text---icons-tertiary)"
14475
+ },
14476
+ children: "Referral History"
14477
+ }
14478
+ ),
14479
+ !error && users && users.length > 0 && /* @__PURE__ */ jsx32(Muted, { children: referralCountLabel(users.length) })
14480
+ ] }),
14481
+ body
14482
+ ] });
14483
+ }
14484
+ function Card2({ children }) {
14485
+ return /* @__PURE__ */ jsx32(
14486
+ "div",
14487
+ {
14488
+ className: "w-full overflow-clip",
14489
+ style: {
14490
+ backgroundColor: T15.surfaceBase,
14491
+ border: `1px solid ${T15.borderSubtle}`,
14492
+ borderRadius: T15.r3xl
14493
+ },
14494
+ children
14495
+ }
14496
+ );
14497
+ }
14498
+ var CELL = { padding: `${T15.spXl} ${T15.sp6xl}`, textAlign: "left" };
14499
+ var HEAD_CELL = {
14500
+ ...CELL,
14501
+ fontFamily: T15.font,
14502
+ fontSize: T15.fsXs,
14503
+ lineHeight: T15.lhXs,
14504
+ fontWeight: 500,
14505
+ color: T15.muted
14506
+ };
14507
+ var BODY_CELL = {
14508
+ ...CELL,
14509
+ fontFamily: T15.font,
14510
+ fontSize: T15.fsSm,
14511
+ lineHeight: T15.lhSm,
14512
+ borderTop: `1px solid ${T15.borderDivider}`
14513
+ };
14514
+ function HistoryTable({ users }) {
14515
+ return /* @__PURE__ */ jsx32(Card2, { children: /* @__PURE__ */ jsxs29("table", { className: "w-full", style: { borderCollapse: "collapse" }, children: [
14516
+ /* @__PURE__ */ jsx32("thead", { children: /* @__PURE__ */ jsxs29("tr", { children: [
14517
+ /* @__PURE__ */ jsx32("th", { scope: "col", style: HEAD_CELL, children: "Email" }),
14518
+ /* @__PURE__ */ jsx32("th", { scope: "col", style: { ...HEAD_CELL, textAlign: "right" }, children: "Signed up" })
14519
+ ] }) }),
14520
+ /* @__PURE__ */ jsx32("tbody", { children: users.map((user) => /* @__PURE__ */ jsxs29("tr", { children: [
14521
+ /* @__PURE__ */ jsx32("td", { style: { ...BODY_CELL, color: T15.primary, wordBreak: "break-all" }, children: user.email }),
14522
+ /* @__PURE__ */ jsx32("td", { style: { ...BODY_CELL, color: T15.muted, textAlign: "right", whiteSpace: "nowrap" }, children: /* @__PURE__ */ jsx32("time", { dateTime: user.createdAt, children: referralSignupDate(user.createdAt) }) })
14523
+ ] }, user.id)) })
14524
+ ] }) });
14525
+ }
14526
+ function Bar({ width }) {
14527
+ return /* @__PURE__ */ jsx32(
14528
+ "div",
14529
+ {
14530
+ className: "animate-pulse",
14531
+ style: {
14532
+ width,
14533
+ height: 12,
14534
+ borderRadius: "var(--radius-full)",
14535
+ backgroundColor: "var(--alias-fill-neutral-neutral)"
14536
+ }
14537
+ }
14538
+ );
14539
+ }
14540
+ function HistorySkeleton() {
14541
+ return /* @__PURE__ */ jsx32("div", { role: "status", "aria-label": "Loading referral history", className: "w-full", children: /* @__PURE__ */ jsx32(Card2, { children: Array.from({ length: SKELETON_ROWS }, (_, i) => /* @__PURE__ */ jsxs29(
14542
+ "div",
14543
+ {
14544
+ className: "flex items-center justify-between",
14545
+ style: {
14546
+ padding: `${T15.spXl} ${T15.sp6xl}`,
14547
+ borderTop: i === 0 ? void 0 : `1px solid ${T15.borderDivider}`
14548
+ },
14549
+ children: [
14550
+ /* @__PURE__ */ jsx32(Bar, { width: 180 }),
14551
+ /* @__PURE__ */ jsx32(Bar, { width: 72 })
14552
+ ]
14553
+ },
14554
+ i
14555
+ )) }) });
14556
+ }
14409
14557
 
14410
14558
  // src/organization-integrations-content.tsx
14411
14559
  import { useState as useState24 } from "react";
14412
14560
  import { ScButton as ScButton17, ScToggleSwitch } from "@streamoid/ui";
14413
- import { Fragment as Fragment14, jsx as jsx32, jsxs as jsxs29 } from "react/jsx-runtime";
14561
+ import { Fragment as Fragment14, jsx as jsx33, jsxs as jsxs30 } from "react/jsx-runtime";
14414
14562
  var COLUMN = { app: "6.5rem", workspace: "9rem", date: "6.5rem", action: "4.75rem" };
14415
14563
  function HeaderRow() {
14416
- const cell = (label, width) => /* @__PURE__ */ jsx32(
14564
+ const cell = (label, width) => /* @__PURE__ */ jsx33(
14417
14565
  "span",
14418
14566
  {
14419
14567
  className: width ? "shrink-0" : "flex-1 min-w-0",
@@ -14431,7 +14579,7 @@ function HeaderRow() {
14431
14579
  children: label
14432
14580
  }
14433
14581
  );
14434
- return /* @__PURE__ */ jsxs29(
14582
+ return /* @__PURE__ */ jsxs30(
14435
14583
  "div",
14436
14584
  {
14437
14585
  className: "flex items-center",
@@ -14442,7 +14590,7 @@ function HeaderRow() {
14442
14590
  cell("Workspace", COLUMN.workspace),
14443
14591
  cell("Connected", COLUMN.date),
14444
14592
  cell("Last used", COLUMN.date),
14445
- /* @__PURE__ */ jsx32("span", { className: "shrink-0", style: { width: COLUMN.action } })
14593
+ /* @__PURE__ */ jsx33("span", { className: "shrink-0", style: { width: COLUMN.action } })
14446
14594
  ]
14447
14595
  }
14448
14596
  );
@@ -14451,7 +14599,7 @@ function ConnectionRow({ app, onRevoke }) {
14451
14599
  const name = app.user?.name?.trim();
14452
14600
  const email = app.user?.email ?? "";
14453
14601
  const active = app.status === "active";
14454
- const text2 = (value, width, color = T15.primary) => /* @__PURE__ */ jsx32(
14602
+ const text2 = (value, width, color = T15.primary) => /* @__PURE__ */ jsx33(
14455
14603
  "span",
14456
14604
  {
14457
14605
  className: "truncate shrink-0",
@@ -14460,7 +14608,7 @@ function ConnectionRow({ app, onRevoke }) {
14460
14608
  children: value
14461
14609
  }
14462
14610
  );
14463
- return /* @__PURE__ */ jsxs29(
14611
+ return /* @__PURE__ */ jsxs30(
14464
14612
  "div",
14465
14613
  {
14466
14614
  className: "flex items-center",
@@ -14471,10 +14619,10 @@ function ConnectionRow({ app, onRevoke }) {
14471
14619
  opacity: active ? 1 : 0.6
14472
14620
  },
14473
14621
  children: [
14474
- /* @__PURE__ */ jsxs29("div", { className: "flex items-center flex-1 min-w-0", style: { minWidth: 200, gap: T15.spMd }, children: [
14475
- /* @__PURE__ */ jsx32(ProfileAvatar, { name: name || email || "Member", size: 32 }),
14476
- /* @__PURE__ */ jsxs29("div", { className: "flex flex-col min-w-0", children: [
14477
- /* @__PURE__ */ jsx32(
14622
+ /* @__PURE__ */ jsxs30("div", { className: "flex items-center flex-1 min-w-0", style: { minWidth: 200, gap: T15.spMd }, children: [
14623
+ /* @__PURE__ */ jsx33(ProfileAvatar, { name: name || email || "Member", size: 32 }),
14624
+ /* @__PURE__ */ jsxs30("div", { className: "flex flex-col min-w-0", children: [
14625
+ /* @__PURE__ */ jsx33(
14478
14626
  "span",
14479
14627
  {
14480
14628
  className: "truncate",
@@ -14482,17 +14630,17 @@ function ConnectionRow({ app, onRevoke }) {
14482
14630
  children: name || email || "A member"
14483
14631
  }
14484
14632
  ),
14485
- name && email && /* @__PURE__ */ jsx32("span", { className: "truncate", style: { fontFamily: T15.font, fontSize: T15.fsSm, lineHeight: T15.lhSm, color: T15.muted }, children: email })
14633
+ name && email && /* @__PURE__ */ jsx33("span", { className: "truncate", style: { fontFamily: T15.font, fontSize: T15.fsSm, lineHeight: T15.lhSm, color: T15.muted }, children: email })
14486
14634
  ] })
14487
14635
  ] }),
14488
- /* @__PURE__ */ jsxs29("div", { className: "flex items-center shrink-0", style: { width: COLUMN.app, gap: T15.spMd }, children: [
14489
- /* @__PURE__ */ jsx32(AppMark, { name: app.clientName, size: 24 }),
14490
- /* @__PURE__ */ jsx32("span", { className: "truncate", style: { fontFamily: T15.font, fontSize: T15.fsSm, lineHeight: T15.lhSm, color: T15.primary }, children: app.clientName })
14636
+ /* @__PURE__ */ jsxs30("div", { className: "flex items-center shrink-0", style: { width: COLUMN.app, gap: T15.spMd }, children: [
14637
+ /* @__PURE__ */ jsx33(AppMark, { name: app.clientName, size: 24 }),
14638
+ /* @__PURE__ */ jsx33("span", { className: "truncate", style: { fontFamily: T15.font, fontSize: T15.fsSm, lineHeight: T15.lhSm, color: T15.primary }, children: app.clientName })
14491
14639
  ] }),
14492
14640
  text2(workspaceLabel(app), COLUMN.workspace),
14493
14641
  text2(formatDate2(app.createdAt), COLUMN.date),
14494
14642
  text2(active ? lastUsedLabel(app.lastUsedAt) : "Revoked", COLUMN.date, T15.muted),
14495
- /* @__PURE__ */ jsx32("div", { className: "flex justify-end shrink-0", style: { width: COLUMN.action }, children: active && /* @__PURE__ */ jsx32(
14643
+ /* @__PURE__ */ jsx33("div", { className: "flex justify-end shrink-0", style: { width: COLUMN.action }, children: active && /* @__PURE__ */ jsx33(
14496
14644
  ScButton17,
14497
14645
  {
14498
14646
  text: "Revoke",
@@ -14512,7 +14660,7 @@ function AccessCard({
14512
14660
  activeCount,
14513
14661
  onToggle
14514
14662
  }) {
14515
- return /* @__PURE__ */ jsxs29(
14663
+ return /* @__PURE__ */ jsxs30(
14516
14664
  "section",
14517
14665
  {
14518
14666
  "aria-label": "ChatGPT and Codex access",
@@ -14525,19 +14673,19 @@ function AccessCard({
14525
14673
  borderRadius: T15.r3xl
14526
14674
  },
14527
14675
  children: [
14528
- /* @__PURE__ */ jsx32(AppMark, { name: "ChatGPT and Codex" }),
14529
- /* @__PURE__ */ jsxs29("div", { className: "flex flex-col flex-1 min-w-0", style: { gap: T15.spXs }, children: [
14530
- /* @__PURE__ */ jsx32("span", { style: { fontFamily: T15.font, fontSize: T15.fsMd, fontWeight: 600, lineHeight: T15.lhMd, color: T15.primary }, children: "ChatGPT & Codex" }),
14531
- /* @__PURE__ */ jsx32(Muted, { children: "Let members use CXO from ChatGPT and Codex. Each member still chooses which workspace an app can reach, and the app gets only that member's permissions there." }),
14532
- enabled === false && activeCount > 0 && /* @__PURE__ */ jsxs29("span", { style: { fontFamily: T15.font, fontSize: T15.fsSm, lineHeight: T15.lhSm, color: T15.primary }, children: [
14676
+ /* @__PURE__ */ jsx33(AppMark, { name: "ChatGPT and Codex" }),
14677
+ /* @__PURE__ */ jsxs30("div", { className: "flex flex-col flex-1 min-w-0", style: { gap: T15.spXs }, children: [
14678
+ /* @__PURE__ */ jsx33("span", { style: { fontFamily: T15.font, fontSize: T15.fsMd, fontWeight: 600, lineHeight: T15.lhMd, color: T15.primary }, children: "ChatGPT & Codex" }),
14679
+ /* @__PURE__ */ jsx33(Muted, { children: "Let members use CXO from ChatGPT and Codex. Each member still chooses which workspace an app can reach, and the app gets only that member's permissions there." }),
14680
+ enabled === false && activeCount > 0 && /* @__PURE__ */ jsxs30("span", { style: { fontFamily: T15.font, fontSize: T15.fsSm, lineHeight: T15.lhSm, color: T15.primary }, children: [
14533
14681
  "Off: the ",
14534
14682
  countLabel(activeCount, "connection"),
14535
14683
  " below can't start new work until you turn this back on."
14536
14684
  ] })
14537
14685
  ] }),
14538
- /* @__PURE__ */ jsxs29("div", { className: "flex items-center shrink-0", style: { alignSelf: "center", gap: T15.spMd, minHeight: 26 }, children: [
14539
- /* @__PURE__ */ jsx32("span", { style: { fontFamily: T15.font, fontSize: T15.fsSm, lineHeight: T15.lhSm, color: T15.muted }, children: enabled === null ? "" : enabled ? "On" : "Off" }),
14540
- /* @__PURE__ */ jsx32("span", { style: { display: "inline-flex", width: 41, height: 25, alignItems: "center" }, children: /* @__PURE__ */ jsx32(
14686
+ /* @__PURE__ */ jsxs30("div", { className: "flex items-center shrink-0", style: { alignSelf: "center", gap: T15.spMd, minHeight: 26 }, children: [
14687
+ /* @__PURE__ */ jsx33("span", { style: { fontFamily: T15.font, fontSize: T15.fsSm, lineHeight: T15.lhSm, color: T15.muted }, children: enabled === null ? "" : enabled ? "On" : "Off" }),
14688
+ /* @__PURE__ */ jsx33("span", { style: { display: "inline-flex", width: 41, height: 25, alignItems: "center" }, children: /* @__PURE__ */ jsx33(
14541
14689
  ScToggleSwitch,
14542
14690
  {
14543
14691
  checked: !!enabled,
@@ -14583,7 +14731,7 @@ function OrganizationIntegrationsContent() {
14583
14731
  const [confirmOff, setConfirmOff] = useState24(false);
14584
14732
  const [revoking, setRevoking] = useState24(null);
14585
14733
  if (!canLoad) {
14586
- return /* @__PURE__ */ jsx32("div", { className: "flex flex-col flex-1 min-w-0", style: { gap: T15.sp3xl }, children: /* @__PURE__ */ jsx32(Muted, { children: !supported ? "Integrations aren't available here yet." : "Integrations are managed by organization admins." }) });
14734
+ return /* @__PURE__ */ jsx33("div", { className: "flex flex-col flex-1 min-w-0", style: { gap: T15.sp3xl }, children: /* @__PURE__ */ jsx33(Muted, { children: !supported ? "Integrations aren't available here yet." : "Integrations are managed by organization admins." }) });
14587
14735
  }
14588
14736
  const value = data.value;
14589
14737
  const rows = value ? sortConnections(value.rows) : [];
@@ -14621,8 +14769,8 @@ function OrganizationIntegrationsContent() {
14621
14769
  toast.error(errorMessage(cause, { method: "DELETE" }));
14622
14770
  }
14623
14771
  }
14624
- return /* @__PURE__ */ jsxs29("div", { className: "flex flex-col flex-1 min-w-0 min-h-0 h-full", style: { gap: T15.sp3xl }, children: [
14625
- /* @__PURE__ */ jsx32(
14772
+ return /* @__PURE__ */ jsxs30("div", { className: "flex flex-col flex-1 min-w-0 min-h-0 h-full", style: { gap: T15.sp3xl }, children: [
14773
+ /* @__PURE__ */ jsx33(
14626
14774
  ScopeHeader,
14627
14775
  {
14628
14776
  kind: "organization",
@@ -14632,10 +14780,10 @@ function OrganizationIntegrationsContent() {
14632
14780
  facts: [value && countLabel(activeRows.length, "active connection")]
14633
14781
  }
14634
14782
  ),
14635
- data.error && /* @__PURE__ */ jsx32(LoadError, { message: data.error, onRetry: data.retry }),
14636
- !value && !data.error && /* @__PURE__ */ jsx32(Spinner, {}),
14637
- value && /* @__PURE__ */ jsxs29(Fragment14, { children: [
14638
- /* @__PURE__ */ jsx32(
14783
+ data.error && /* @__PURE__ */ jsx33(LoadError, { message: data.error, onRetry: data.retry }),
14784
+ !value && !data.error && /* @__PURE__ */ jsx33(Spinner, {}),
14785
+ value && /* @__PURE__ */ jsxs30(Fragment14, { children: [
14786
+ /* @__PURE__ */ jsx33(
14639
14787
  AccessCard,
14640
14788
  {
14641
14789
  enabled: value.enabled,
@@ -14644,7 +14792,7 @@ function OrganizationIntegrationsContent() {
14644
14792
  onToggle: (next) => next ? void setAccess(true) : setConfirmOff(true)
14645
14793
  }
14646
14794
  ),
14647
- /* @__PURE__ */ jsx32(
14795
+ /* @__PURE__ */ jsx33(
14648
14796
  MemberListToolbar,
14649
14797
  {
14650
14798
  activeTab: "active",
@@ -14654,7 +14802,7 @@ function OrganizationIntegrationsContent() {
14654
14802
  activeCount: visible.length,
14655
14803
  searchQuery: search,
14656
14804
  onSearchChange: setSearch,
14657
- action: revokedCount > 0 ? /* @__PURE__ */ jsx32(
14805
+ action: revokedCount > 0 ? /* @__PURE__ */ jsx33(
14658
14806
  ScButton17,
14659
14807
  {
14660
14808
  text: showRevoked ? "Hide revoked" : `Show revoked (${revokedCount})`,
@@ -14665,30 +14813,30 @@ function OrganizationIntegrationsContent() {
14665
14813
  ) : void 0
14666
14814
  }
14667
14815
  ),
14668
- /* @__PURE__ */ jsx32(
14816
+ /* @__PURE__ */ jsx33(
14669
14817
  MemberListFrame,
14670
14818
  {
14671
- header: /* @__PURE__ */ jsx32(HeaderRow, {}),
14819
+ header: /* @__PURE__ */ jsx33(HeaderRow, {}),
14672
14820
  isEmpty: visible.length === 0,
14673
14821
  emptyText: q ? "No connections match your search" : value.enabled ? "No one has connected ChatGPT or Codex yet" : "Turn on ChatGPT & Codex to let members connect",
14674
14822
  grow: "fill",
14675
- children: visible.map((app) => /* @__PURE__ */ jsx32(ConnectionRow, { app, onRevoke: () => setRevoking(app) }, app.id))
14823
+ children: visible.map((app) => /* @__PURE__ */ jsx33(ConnectionRow, { app, onRevoke: () => setRevoking(app) }, app.id))
14676
14824
  }
14677
14825
  )
14678
14826
  ] }),
14679
- confirmOff && /* @__PURE__ */ jsx32(
14827
+ confirmOff && /* @__PURE__ */ jsx33(
14680
14828
  ConfirmActionModal,
14681
14829
  {
14682
14830
  title: "Turn off ChatGPT & Codex?",
14683
- body: /* @__PURE__ */ jsxs29(Fragment14, { children: [
14684
- /* @__PURE__ */ jsxs29("span", { children: [
14831
+ body: /* @__PURE__ */ jsxs30(Fragment14, { children: [
14832
+ /* @__PURE__ */ jsxs30("span", { children: [
14685
14833
  "Members of ",
14686
14834
  current?.name || "this organization",
14687
14835
  " won't be able to connect ChatGPT or Codex",
14688
14836
  activeRows.length > 0 ? `, and the ${countLabel(activeRows.length, "existing connection")} will stop working` : "",
14689
14837
  "."
14690
14838
  ] }),
14691
- /* @__PURE__ */ jsxs29("span", { style: { color: T15.muted, fontSize: T15.fsSm, lineHeight: T15.lhSm }, children: [
14839
+ /* @__PURE__ */ jsxs30("span", { style: { color: T15.muted, fontSize: T15.fsSm, lineHeight: T15.lhSm }, children: [
14692
14840
  REVOKE_TIMING,
14693
14841
  " Connections come back when you turn this on again."
14694
14842
  ] })
@@ -14699,20 +14847,20 @@ function OrganizationIntegrationsContent() {
14699
14847
  onConfirm: () => setAccess(false)
14700
14848
  }
14701
14849
  ),
14702
- revoking && /* @__PURE__ */ jsx32(
14850
+ revoking && /* @__PURE__ */ jsx33(
14703
14851
  ConfirmActionModal,
14704
14852
  {
14705
14853
  title: `Revoke ${revoking.clientName}?`,
14706
- body: /* @__PURE__ */ jsxs29(Fragment14, { children: [
14707
- /* @__PURE__ */ jsxs29("span", { children: [
14854
+ body: /* @__PURE__ */ jsxs30(Fragment14, { children: [
14855
+ /* @__PURE__ */ jsxs30("span", { children: [
14708
14856
  revoking.user?.name || revoking.user?.email || "This member",
14709
14857
  "'s ",
14710
14858
  revoking.clientName,
14711
14859
  " will no longer be able to use CXO in ",
14712
- /* @__PURE__ */ jsx32("span", { style: { fontWeight: 600 }, children: workspaceLabel(revoking) }),
14860
+ /* @__PURE__ */ jsx33("span", { style: { fontWeight: 600 }, children: workspaceLabel(revoking) }),
14713
14861
  "."
14714
14862
  ] }),
14715
- /* @__PURE__ */ jsxs29("span", { style: { color: T15.muted, fontSize: T15.fsSm, lineHeight: T15.lhSm }, children: [
14863
+ /* @__PURE__ */ jsxs30("span", { style: { color: T15.muted, fontSize: T15.fsSm, lineHeight: T15.lhSm }, children: [
14716
14864
  REVOKE_TIMING,
14717
14865
  " They can connect again unless you turn access off."
14718
14866
  ] })
@@ -14727,7 +14875,7 @@ function OrganizationIntegrationsContent() {
14727
14875
  }
14728
14876
 
14729
14877
  // src/settings-content.tsx
14730
- import { Fragment as Fragment16, jsx as jsx33, jsxs as jsxs30 } from "react/jsx-runtime";
14878
+ import { Fragment as Fragment16, jsx as jsx34, jsxs as jsxs31 } from "react/jsx-runtime";
14731
14879
  function deriveInitials(name) {
14732
14880
  return name.split(/\s+/).slice(0, 2).map((part) => part[0]?.toUpperCase() ?? "").join("") || "WS";
14733
14881
  }
@@ -14763,7 +14911,7 @@ function SettingsNavItem({
14763
14911
  onTabChange
14764
14912
  }) {
14765
14913
  const isActive = activeTab === tab;
14766
- return /* @__PURE__ */ jsx33(SettingsTooltip, { content: TAB_DESCRIPTIONS[tab], placement: "right", children: /* @__PURE__ */ jsx33("div", { children: /* @__PURE__ */ jsx33(
14914
+ return /* @__PURE__ */ jsx34(SettingsTooltip, { content: TAB_DESCRIPTIONS[tab], placement: "right", children: /* @__PURE__ */ jsx34("div", { children: /* @__PURE__ */ jsx34(
14767
14915
  ScSidebarMenu,
14768
14916
  {
14769
14917
  icon: icon(isActive ? PRIMARY_COLOR3 : MUTED_COLOR2),
@@ -14795,7 +14943,7 @@ function SettingsNav({
14795
14943
  showIntegrations = false,
14796
14944
  showReferral = false
14797
14945
  }) {
14798
- const item = (tab, icon) => /* @__PURE__ */ jsx33(
14946
+ const item = (tab, icon) => /* @__PURE__ */ jsx34(
14799
14947
  SettingsNavItem,
14800
14948
  {
14801
14949
  tab,
@@ -14805,7 +14953,7 @@ function SettingsNav({
14805
14953
  onTabChange
14806
14954
  }
14807
14955
  );
14808
- return /* @__PURE__ */ jsxs30(
14956
+ return /* @__PURE__ */ jsxs31(
14809
14957
  "div",
14810
14958
  {
14811
14959
  className: "flex flex-col items-start shrink-0 relative overflow-y-auto",
@@ -14828,43 +14976,43 @@ function SettingsNav({
14828
14976
  gap: "var(--spacing-5xl)"
14829
14977
  },
14830
14978
  children: [
14831
- /* @__PURE__ */ jsxs30("div", { className: "flex flex-col w-full", style: { gap: "var(--spacing-md)" }, children: [
14832
- /* @__PURE__ */ jsx33("div", { style: { padding: "4px 12px", fontSize: 11, fontWeight: 500, color: MUTED_COLOR2, textTransform: "uppercase", letterSpacing: "0.08em" }, children: "Account" }),
14833
- item("profile", (color) => /* @__PURE__ */ jsx33(SiconUser, { className: "w-5 h-5", color })),
14834
- item("workspaceList", (color) => /* @__PURE__ */ jsx33(SiconSwitch, { className: "w-5 h-5", color })),
14835
- showConnectedApps && item("connectedApps", (color) => /* @__PURE__ */ jsx33(SiconPlug_default, { className: "w-5 h-5", color })),
14836
- showReferral && item("referral", (color) => /* @__PURE__ */ jsx33(SiconReferral, { className: "w-5 h-5", color }))
14979
+ /* @__PURE__ */ jsxs31("div", { className: "flex flex-col w-full", style: { gap: "var(--spacing-md)" }, children: [
14980
+ /* @__PURE__ */ jsx34("div", { style: { padding: "4px 12px", fontSize: 11, fontWeight: 500, color: MUTED_COLOR2, textTransform: "uppercase", letterSpacing: "0.08em" }, children: "Account" }),
14981
+ item("profile", (color) => /* @__PURE__ */ jsx34(SiconUser, { className: "w-5 h-5", color })),
14982
+ item("workspaceList", (color) => /* @__PURE__ */ jsx34(SiconSwitch, { className: "w-5 h-5", color })),
14983
+ showConnectedApps && item("connectedApps", (color) => /* @__PURE__ */ jsx34(SiconPlug_default, { className: "w-5 h-5", color })),
14984
+ showReferral && item("referral", (color) => /* @__PURE__ */ jsx34(SiconReferral, { className: "w-5 h-5", color }))
14837
14985
  ] }),
14838
- /* @__PURE__ */ jsx33(ScHDivider, {}),
14839
- /* @__PURE__ */ jsxs30("div", { className: "flex flex-col w-full", style: { gap: "var(--spacing-md)" }, children: [
14840
- /* @__PURE__ */ jsx33("div", { title: workspaceName ?? void 0, style: { padding: "4px 12px", fontSize: 11, fontWeight: 500, color: MUTED_COLOR2, textTransform: "uppercase", letterSpacing: "0.08em" }, children: "Workspace" }),
14841
- item("workspace", (color) => /* @__PURE__ */ jsx33(SiconSettings2, { className: "w-5 h-5", color })),
14842
- item("workspaceMembers", (color) => /* @__PURE__ */ jsx33(SiconTeam, { className: "w-5 h-5", color })),
14843
- isWorkspaceAdmin && /* @__PURE__ */ jsxs30(Fragment16, { children: [
14844
- item("billing", (color) => /* @__PURE__ */ jsx33(SiconBilling, { className: "w-5 h-5", color })),
14845
- item("apikey", (color) => /* @__PURE__ */ jsx33(SiconKey_default, { className: "w-5 h-5", color }))
14986
+ /* @__PURE__ */ jsx34(ScHDivider, {}),
14987
+ /* @__PURE__ */ jsxs31("div", { className: "flex flex-col w-full", style: { gap: "var(--spacing-md)" }, children: [
14988
+ /* @__PURE__ */ jsx34("div", { title: workspaceName ?? void 0, style: { padding: "4px 12px", fontSize: 11, fontWeight: 500, color: MUTED_COLOR2, textTransform: "uppercase", letterSpacing: "0.08em" }, children: "Workspace" }),
14989
+ item("workspace", (color) => /* @__PURE__ */ jsx34(SiconSettings2, { className: "w-5 h-5", color })),
14990
+ item("workspaceMembers", (color) => /* @__PURE__ */ jsx34(SiconTeam, { className: "w-5 h-5", color })),
14991
+ isWorkspaceAdmin && /* @__PURE__ */ jsxs31(Fragment16, { children: [
14992
+ item("billing", (color) => /* @__PURE__ */ jsx34(SiconBilling, { className: "w-5 h-5", color })),
14993
+ item("apikey", (color) => /* @__PURE__ */ jsx34(SiconKey_default, { className: "w-5 h-5", color }))
14846
14994
  ] }),
14847
- !isWorkspaceAdmin && /* @__PURE__ */ jsx33("p", { style: { margin: "4px 12px", fontSize: 12, lineHeight: "18px", color: MUTED_COLOR2 }, children: "Contact your workspace admin for credit top-ups and billing history." })
14995
+ !isWorkspaceAdmin && /* @__PURE__ */ jsx34("p", { style: { margin: "4px 12px", fontSize: 12, lineHeight: "18px", color: MUTED_COLOR2 }, children: "Contact your workspace admin for credit top-ups and billing history." })
14848
14996
  ] }),
14849
- /* @__PURE__ */ jsx33(ScHDivider, {}),
14850
- /* @__PURE__ */ jsx33("div", { className: "flex flex-col w-full", style: { gap: "var(--spacing-md)" }, children: hasOrganization ? /* @__PURE__ */ jsxs30(Fragment16, { children: [
14851
- /* @__PURE__ */ jsx33("div", { style: { padding: "4px 12px", fontSize: 11, fontWeight: 500, color: MUTED_COLOR2, textTransform: "uppercase", letterSpacing: "0.08em" }, children: "Organization" }),
14852
- item("organizationList", (color) => /* @__PURE__ */ jsx33(SiconSwitch, { className: "w-5 h-5", color })),
14853
- item("organization", (color) => /* @__PURE__ */ jsx33(SiconTeam, { className: "w-5 h-5", color })),
14854
- item("organizationWorkspaces", (color) => /* @__PURE__ */ jsx33(SiconWorkspace2, { className: "w-5 h-5", color })),
14855
- showIntegrations && item("organizationIntegrations", (color) => /* @__PURE__ */ jsx33(SiconPlug_default, { className: "w-5 h-5", color }))
14856
- ] }) : /* @__PURE__ */ jsxs30(Fragment16, { children: [
14857
- /* @__PURE__ */ jsx33(
14997
+ /* @__PURE__ */ jsx34(ScHDivider, {}),
14998
+ /* @__PURE__ */ jsx34("div", { className: "flex flex-col w-full", style: { gap: "var(--spacing-md)" }, children: hasOrganization ? /* @__PURE__ */ jsxs31(Fragment16, { children: [
14999
+ /* @__PURE__ */ jsx34("div", { style: { padding: "4px 12px", fontSize: 11, fontWeight: 500, color: MUTED_COLOR2, textTransform: "uppercase", letterSpacing: "0.08em" }, children: "Organization" }),
15000
+ item("organizationList", (color) => /* @__PURE__ */ jsx34(SiconSwitch, { className: "w-5 h-5", color })),
15001
+ item("organization", (color) => /* @__PURE__ */ jsx34(SiconTeam, { className: "w-5 h-5", color })),
15002
+ item("organizationWorkspaces", (color) => /* @__PURE__ */ jsx34(SiconWorkspace2, { className: "w-5 h-5", color })),
15003
+ showIntegrations && item("organizationIntegrations", (color) => /* @__PURE__ */ jsx34(SiconPlug_default, { className: "w-5 h-5", color }))
15004
+ ] }) : /* @__PURE__ */ jsxs31(Fragment16, { children: [
15005
+ /* @__PURE__ */ jsx34(
14858
15006
  SettingsNavItem,
14859
15007
  {
14860
15008
  tab: "organization",
14861
15009
  label: "Organization",
14862
- icon: (color) => /* @__PURE__ */ jsx33(SiconGlobe3, { className: "w-5 h-5", color }),
15010
+ icon: (color) => /* @__PURE__ */ jsx34(SiconGlobe3, { className: "w-5 h-5", color }),
14863
15011
  activeTab,
14864
15012
  onTabChange
14865
15013
  }
14866
15014
  ),
14867
- item("organizationList", (color) => /* @__PURE__ */ jsx33(SiconSwitch, { className: "w-5 h-5", color }))
15015
+ item("organizationList", (color) => /* @__PURE__ */ jsx34(SiconSwitch, { className: "w-5 h-5", color }))
14868
15016
  ] }) })
14869
15017
  ]
14870
15018
  }
@@ -14873,7 +15021,7 @@ function SettingsNav({
14873
15021
  var SPECIALIZATION_ICON_SIZE = 24;
14874
15022
  function SpecializationIcon({ iconUrl }) {
14875
15023
  if (iconUrl) {
14876
- return /* @__PURE__ */ jsx33(
15024
+ return /* @__PURE__ */ jsx34(
14877
15025
  "img",
14878
15026
  {
14879
15027
  src: iconUrl,
@@ -14886,7 +15034,7 @@ function SpecializationIcon({ iconUrl }) {
14886
15034
  }
14887
15035
  );
14888
15036
  }
14889
- return /* @__PURE__ */ jsx33(
15037
+ return /* @__PURE__ */ jsx34(
14890
15038
  SiconBolt,
14891
15039
  {
14892
15040
  style: {
@@ -14959,15 +15107,15 @@ function SpecializationDropdown({
14959
15107
  };
14960
15108
  }, [open]);
14961
15109
  const selected = options.find((o) => o.id === value);
14962
- return /* @__PURE__ */ jsxs30(
15110
+ return /* @__PURE__ */ jsxs31(
14963
15111
  "div",
14964
15112
  {
14965
15113
  ref: containerRef,
14966
15114
  className: "w-full",
14967
15115
  style: { position: "relative" },
14968
15116
  children: [
14969
- /* @__PURE__ */ jsx33("style", { children: DROPDOWN_TRIGGER_STYLES }),
14970
- /* @__PURE__ */ jsx33(
15117
+ /* @__PURE__ */ jsx34("style", { children: DROPDOWN_TRIGGER_STYLES }),
15118
+ /* @__PURE__ */ jsx34(
14971
15119
  "div",
14972
15120
  {
14973
15121
  className: "spec-dropdown-trigger",
@@ -14975,7 +15123,7 @@ function SpecializationDropdown({
14975
15123
  onClick: () => !disabled && setOpen((v) => !v),
14976
15124
  "aria-haspopup": "listbox",
14977
15125
  "aria-expanded": open,
14978
- children: /* @__PURE__ */ jsx33(
15126
+ children: /* @__PURE__ */ jsx34(
14979
15127
  ScTextField,
14980
15128
  {
14981
15129
  label: "Specialization",
@@ -14983,8 +15131,8 @@ function SpecializationDropdown({
14983
15131
  value: selected?.label ?? "",
14984
15132
  placeholderFilled: "Select specialization",
14985
15133
  tfGroup: "icon-left-right",
14986
- tfLeftIcon: /* @__PURE__ */ jsx33(SpecializationIcon, { iconUrl: selected?.iconUrl }),
14987
- tfRightIcon: /* @__PURE__ */ jsx33(
15134
+ tfLeftIcon: /* @__PURE__ */ jsx34(SpecializationIcon, { iconUrl: selected?.iconUrl }),
15135
+ tfRightIcon: /* @__PURE__ */ jsx34(
14988
15136
  "span",
14989
15137
  {
14990
15138
  style: {
@@ -14994,7 +15142,7 @@ function SpecializationDropdown({
14994
15142
  transform: open ? "rotate(180deg)" : "none",
14995
15143
  transition: "transform 120ms ease-out"
14996
15144
  },
14997
- children: /* @__PURE__ */ jsx33(SiconDown2, {})
15145
+ children: /* @__PURE__ */ jsx34(SiconDown2, {})
14998
15146
  }
14999
15147
  ),
15000
15148
  className: "sc-text-field-full-width",
@@ -15005,7 +15153,7 @@ function SpecializationDropdown({
15005
15153
  )
15006
15154
  }
15007
15155
  ),
15008
- open && /* @__PURE__ */ jsx33(
15156
+ open && /* @__PURE__ */ jsx34(
15009
15157
  "div",
15010
15158
  {
15011
15159
  role: "listbox",
@@ -15027,11 +15175,11 @@ function SpecializationDropdown({
15027
15175
  },
15028
15176
  children: options.map((opt) => {
15029
15177
  const isActive = opt.id === value;
15030
- return /* @__PURE__ */ jsx33(
15178
+ return /* @__PURE__ */ jsx34(
15031
15179
  ScMenuOptions,
15032
15180
  {
15033
15181
  text: opt.label,
15034
- icon: /* @__PURE__ */ jsx33(SpecializationIcon, { iconUrl: opt.iconUrl }),
15182
+ icon: /* @__PURE__ */ jsx34(SpecializationIcon, { iconUrl: opt.iconUrl }),
15035
15183
  hover: isActive ? "true" : "false",
15036
15184
  variant: "default",
15037
15185
  role: "option",
@@ -15075,15 +15223,15 @@ function LanguageDropdown({
15075
15223
  document.removeEventListener("keydown", handleKeyDown);
15076
15224
  };
15077
15225
  }, [open]);
15078
- return /* @__PURE__ */ jsxs30(
15226
+ return /* @__PURE__ */ jsxs31(
15079
15227
  "div",
15080
15228
  {
15081
15229
  ref: containerRef,
15082
15230
  className: "w-full",
15083
15231
  style: { position: "relative" },
15084
15232
  children: [
15085
- /* @__PURE__ */ jsx33("style", { children: DROPDOWN_TRIGGER_STYLES }),
15086
- /* @__PURE__ */ jsx33(
15233
+ /* @__PURE__ */ jsx34("style", { children: DROPDOWN_TRIGGER_STYLES }),
15234
+ /* @__PURE__ */ jsx34(
15087
15235
  "div",
15088
15236
  {
15089
15237
  className: "spec-dropdown-trigger",
@@ -15091,7 +15239,7 @@ function LanguageDropdown({
15091
15239
  onClick: () => !disabled && setOpen((v) => !v),
15092
15240
  "aria-haspopup": "listbox",
15093
15241
  "aria-expanded": open,
15094
- children: /* @__PURE__ */ jsx33(
15242
+ children: /* @__PURE__ */ jsx34(
15095
15243
  ScTextField,
15096
15244
  {
15097
15245
  label: "Language",
@@ -15099,7 +15247,7 @@ function LanguageDropdown({
15099
15247
  value: userLanguageLabel(value),
15100
15248
  placeholderFilled: "Select language",
15101
15249
  tfGroup: "icon-right",
15102
- tfRightIcon: /* @__PURE__ */ jsx33(
15250
+ tfRightIcon: /* @__PURE__ */ jsx34(
15103
15251
  "span",
15104
15252
  {
15105
15253
  style: {
@@ -15109,7 +15257,7 @@ function LanguageDropdown({
15109
15257
  transform: open ? "rotate(180deg)" : "none",
15110
15258
  transition: "transform 120ms ease-out"
15111
15259
  },
15112
- children: /* @__PURE__ */ jsx33(SiconDown2, {})
15260
+ children: /* @__PURE__ */ jsx34(SiconDown2, {})
15113
15261
  }
15114
15262
  ),
15115
15263
  className: "sc-text-field-full-width",
@@ -15120,7 +15268,7 @@ function LanguageDropdown({
15120
15268
  )
15121
15269
  }
15122
15270
  ),
15123
- open && /* @__PURE__ */ jsx33(
15271
+ open && /* @__PURE__ */ jsx34(
15124
15272
  "div",
15125
15273
  {
15126
15274
  role: "listbox",
@@ -15146,11 +15294,11 @@ function LanguageDropdown({
15146
15294
  },
15147
15295
  children: USER_LANGUAGES.map((lang) => {
15148
15296
  const isActive = lang.code === value;
15149
- return /* @__PURE__ */ jsx33(
15297
+ return /* @__PURE__ */ jsx34(
15150
15298
  ScMenuOptions,
15151
15299
  {
15152
15300
  text: lang.label,
15153
- icon: /* @__PURE__ */ jsx33(Fragment16, {}),
15301
+ icon: /* @__PURE__ */ jsx34(Fragment16, {}),
15154
15302
  hover: isActive ? "true" : "false",
15155
15303
  variant: "default",
15156
15304
  role: "option",
@@ -15279,13 +15427,13 @@ function ProfileTab() {
15279
15427
  }
15280
15428
  auth.clearAuth();
15281
15429
  };
15282
- return /* @__PURE__ */ jsxs30(
15430
+ return /* @__PURE__ */ jsxs31(
15283
15431
  "div",
15284
15432
  {
15285
15433
  className: "flex flex-col items-start flex-1 min-w-0 min-h-0 overflow-y-auto",
15286
15434
  style: { gap: "var(--spacing-3xl)" },
15287
15435
  children: [
15288
- /* @__PURE__ */ jsxs30(
15436
+ /* @__PURE__ */ jsxs31(
15289
15437
  "div",
15290
15438
  {
15291
15439
  className: "sc-profile-card flex flex-col items-start w-full",
@@ -15298,13 +15446,13 @@ function ProfileTab() {
15298
15446
  gap: "var(--spacing-6xl)"
15299
15447
  },
15300
15448
  children: [
15301
- /* @__PURE__ */ jsxs30(
15449
+ /* @__PURE__ */ jsxs31(
15302
15450
  "div",
15303
15451
  {
15304
15452
  className: "flex items-center shrink-0 w-full",
15305
15453
  style: { gap: 24, flexWrap: "wrap" },
15306
15454
  children: [
15307
- profileImage ? /* @__PURE__ */ jsx33(
15455
+ profileImage ? /* @__PURE__ */ jsx34(
15308
15456
  "img",
15309
15457
  {
15310
15458
  src: profileImage,
@@ -15317,7 +15465,7 @@ function ProfileTab() {
15317
15465
  flexShrink: 0
15318
15466
  }
15319
15467
  }
15320
- ) : /* @__PURE__ */ jsx33(
15468
+ ) : /* @__PURE__ */ jsx34(
15321
15469
  "div",
15322
15470
  {
15323
15471
  "aria-label": "Profile",
@@ -15330,7 +15478,7 @@ function ProfileTab() {
15330
15478
  border: "1px solid var(--alias-border-subtle)",
15331
15479
  flexShrink: 0
15332
15480
  },
15333
- children: /* @__PURE__ */ jsx33(
15481
+ children: /* @__PURE__ */ jsx34(
15334
15482
  "span",
15335
15483
  {
15336
15484
  style: {
@@ -15345,7 +15493,7 @@ function ProfileTab() {
15345
15493
  )
15346
15494
  }
15347
15495
  ),
15348
- /* @__PURE__ */ jsx33(
15496
+ /* @__PURE__ */ jsx34(
15349
15497
  "input",
15350
15498
  {
15351
15499
  ref: fileInputRef,
@@ -15355,17 +15503,17 @@ function ProfileTab() {
15355
15503
  onChange: handleImageChange
15356
15504
  }
15357
15505
  ),
15358
- /* @__PURE__ */ jsxs30(
15506
+ /* @__PURE__ */ jsxs31(
15359
15507
  "div",
15360
15508
  {
15361
15509
  className: "flex items-center",
15362
15510
  style: { gap: 12, flexWrap: "wrap" },
15363
15511
  children: [
15364
- /* @__PURE__ */ jsx33(
15512
+ /* @__PURE__ */ jsx34(
15365
15513
  ScButton18,
15366
15514
  {
15367
15515
  text: "Upload photo",
15368
- icon: /* @__PURE__ */ jsx33(SiconUpload2, { className: "w-5 h-5", color: PRIMARY_COLOR3 }),
15516
+ icon: /* @__PURE__ */ jsx34(SiconUpload2, { className: "w-5 h-5", color: PRIMARY_COLOR3 }),
15369
15517
  styleVariant: "icon-left",
15370
15518
  variant: "outline",
15371
15519
  size: "md",
@@ -15373,11 +15521,11 @@ function ProfileTab() {
15373
15521
  onClick: handleUploadClick
15374
15522
  }
15375
15523
  ),
15376
- /* @__PURE__ */ jsx33(
15524
+ /* @__PURE__ */ jsx34(
15377
15525
  ScButton18,
15378
15526
  {
15379
15527
  text: "Remove photo",
15380
- icon: /* @__PURE__ */ jsx33(
15528
+ icon: /* @__PURE__ */ jsx34(
15381
15529
  SiconDelete,
15382
15530
  {
15383
15531
  className: "w-5 h-5",
@@ -15397,15 +15545,15 @@ function ProfileTab() {
15397
15545
  ]
15398
15546
  }
15399
15547
  ),
15400
- /* @__PURE__ */ jsx33(ScHDivider, {}),
15401
- /* @__PURE__ */ jsxs30(
15548
+ /* @__PURE__ */ jsx34(ScHDivider, {}),
15549
+ /* @__PURE__ */ jsxs31(
15402
15550
  "div",
15403
15551
  {
15404
15552
  className: "sc-profile-fields flex flex-col min-w-0 w-full",
15405
15553
  style: { gap: 24 },
15406
15554
  children: [
15407
- /* @__PURE__ */ jsxs30("div", { style: { display: "grid", width: "100%", gridTemplateColumns: "repeat(auto-fit, minmax(min(100%, 240px), 1fr))", gap: 24 }, children: [
15408
- /* @__PURE__ */ jsx33("div", { className: "flex-1 min-w-0", style: { overflow: "hidden" }, children: /* @__PURE__ */ jsx33(
15555
+ /* @__PURE__ */ jsxs31("div", { style: { display: "grid", width: "100%", gridTemplateColumns: "repeat(auto-fit, minmax(min(100%, 240px), 1fr))", gap: 24 }, children: [
15556
+ /* @__PURE__ */ jsx34("div", { className: "flex-1 min-w-0", style: { overflow: "hidden" }, children: /* @__PURE__ */ jsx34(
15409
15557
  ScTextField,
15410
15558
  {
15411
15559
  label: "Full Name",
@@ -15419,7 +15567,7 @@ function ProfileTab() {
15419
15567
  onChange: (e) => setFullName(e.target.value)
15420
15568
  }
15421
15569
  ) }),
15422
- /* @__PURE__ */ jsx33("div", { className: "flex-1 min-w-0", children: /* @__PURE__ */ jsx33(
15570
+ /* @__PURE__ */ jsx34("div", { className: "flex-1 min-w-0", children: /* @__PURE__ */ jsx34(
15423
15571
  SpecializationDropdown,
15424
15572
  {
15425
15573
  value: selectedSpec,
@@ -15428,8 +15576,8 @@ function ProfileTab() {
15428
15576
  }
15429
15577
  ) })
15430
15578
  ] }),
15431
- /* @__PURE__ */ jsxs30("div", { className: "flex items-start w-full", style: { gap: "var(--spacing-3xl)" }, children: [
15432
- /* @__PURE__ */ jsx33("div", { className: "flex-1 min-w-0", children: /* @__PURE__ */ jsx33(
15579
+ /* @__PURE__ */ jsxs31("div", { className: "flex items-start w-full", style: { gap: "var(--spacing-3xl)" }, children: [
15580
+ /* @__PURE__ */ jsx34("div", { className: "flex-1 min-w-0", children: /* @__PURE__ */ jsx34(
15433
15581
  LanguageDropdown,
15434
15582
  {
15435
15583
  value: selectedLanguage,
@@ -15437,9 +15585,9 @@ function ProfileTab() {
15437
15585
  disabled: disableAllActions
15438
15586
  }
15439
15587
  ) }),
15440
- /* @__PURE__ */ jsx33("div", { className: "flex-1 min-w-0" })
15588
+ /* @__PURE__ */ jsx34("div", { className: "flex-1 min-w-0" })
15441
15589
  ] }),
15442
- /* @__PURE__ */ jsx33("div", { className: "w-full", style: { overflow: "hidden" }, children: /* @__PURE__ */ jsx33(
15590
+ /* @__PURE__ */ jsx34("div", { className: "w-full", style: { overflow: "hidden" }, children: /* @__PURE__ */ jsx34(
15443
15591
  ScTextField,
15444
15592
  {
15445
15593
  label: "Email ID",
@@ -15448,7 +15596,7 @@ function ProfileTab() {
15448
15596
  value: user?.email ?? "",
15449
15597
  placeholderFilled: user?.email ?? "chris@kepler.com",
15450
15598
  tfGroup: "icon-right",
15451
- tfRightIcon: /* @__PURE__ */ jsx33(
15599
+ tfRightIcon: /* @__PURE__ */ jsx34(
15452
15600
  SiconLock,
15453
15601
  {
15454
15602
  className: "w-6 h-6",
@@ -15460,12 +15608,12 @@ function ProfileTab() {
15460
15608
  readOnly: true
15461
15609
  }
15462
15610
  ) }),
15463
- /* @__PURE__ */ jsx33(
15611
+ /* @__PURE__ */ jsx34(
15464
15612
  "div",
15465
15613
  {
15466
15614
  className: "flex items-center w-full",
15467
15615
  style: { justifyContent: "flex-end", paddingTop: "var(--spacing-md)" },
15468
- children: /* @__PURE__ */ jsx33(
15616
+ children: /* @__PURE__ */ jsx34(
15469
15617
  ScButton18,
15470
15618
  {
15471
15619
  text: saving ? "Saving..." : "Save changes",
@@ -15483,7 +15631,7 @@ function ProfileTab() {
15483
15631
  ]
15484
15632
  }
15485
15633
  ),
15486
- /* @__PURE__ */ jsxs30(
15634
+ /* @__PURE__ */ jsxs31(
15487
15635
  "div",
15488
15636
  {
15489
15637
  className: "flex items-center w-full",
@@ -15495,8 +15643,8 @@ function ProfileTab() {
15495
15643
  gap: "var(--spacing-3xl)"
15496
15644
  },
15497
15645
  children: [
15498
- /* @__PURE__ */ jsxs30("div", { className: "flex flex-col min-w-0 flex-1", style: { gap: "var(--spacing-xs)" }, children: [
15499
- /* @__PURE__ */ jsx33(
15646
+ /* @__PURE__ */ jsxs31("div", { className: "flex flex-col min-w-0 flex-1", style: { gap: "var(--spacing-xs)" }, children: [
15647
+ /* @__PURE__ */ jsx34(
15500
15648
  "span",
15501
15649
  {
15502
15650
  style: {
@@ -15509,7 +15657,7 @@ function ProfileTab() {
15509
15657
  children: "Session"
15510
15658
  }
15511
15659
  ),
15512
- /* @__PURE__ */ jsx33(
15660
+ /* @__PURE__ */ jsx34(
15513
15661
  "span",
15514
15662
  {
15515
15663
  className: "truncate",
@@ -15524,7 +15672,7 @@ function ProfileTab() {
15524
15672
  }
15525
15673
  )
15526
15674
  ] }),
15527
- /* @__PURE__ */ jsx33(
15675
+ /* @__PURE__ */ jsx34(
15528
15676
  ScButton18,
15529
15677
  {
15530
15678
  text: "Log out",
@@ -15658,13 +15806,13 @@ function WorkspaceListTab({
15658
15806
  });
15659
15807
  }, [fetchPlans, listLoading, visibleKey]);
15660
15808
  const planOf = (ws) => fetchPlans ? plans[ws._id] ?? "" : ws.plan ?? "";
15661
- return /* @__PURE__ */ jsxs30(
15809
+ return /* @__PURE__ */ jsxs31(
15662
15810
  "div",
15663
15811
  {
15664
15812
  className: "flex flex-col items-start flex-1 min-w-0",
15665
15813
  style: { gap: "var(--spacing-3xl)", height: "100%" },
15666
15814
  children: [
15667
- /* @__PURE__ */ jsx33(
15815
+ /* @__PURE__ */ jsx34(
15668
15816
  "p",
15669
15817
  {
15670
15818
  className: "shrink-0 w-full",
@@ -15677,7 +15825,7 @@ function WorkspaceListTab({
15677
15825
  children: "Switching changes which workspace the rest of Settings acts on."
15678
15826
  }
15679
15827
  ),
15680
- listLoading && /* @__PURE__ */ jsx33(
15828
+ listLoading && /* @__PURE__ */ jsx34(
15681
15829
  "p",
15682
15830
  {
15683
15831
  style: {
@@ -15688,13 +15836,13 @@ function WorkspaceListTab({
15688
15836
  children: "Loading workspaces\u2026"
15689
15837
  }
15690
15838
  ),
15691
- !listLoading && currentWorkspace && /* @__PURE__ */ jsxs30(
15839
+ !listLoading && currentWorkspace && /* @__PURE__ */ jsxs31(
15692
15840
  "div",
15693
15841
  {
15694
15842
  className: "flex flex-col items-start shrink-0 w-full",
15695
15843
  style: { gap: 16, padding: "var(--spacing-md) 0" },
15696
15844
  children: [
15697
- /* @__PURE__ */ jsxs30(
15845
+ /* @__PURE__ */ jsxs31(
15698
15846
  "p",
15699
15847
  {
15700
15848
  className: "w-full overflow-hidden text-ellipsis whitespace-nowrap",
@@ -15711,7 +15859,7 @@ function WorkspaceListTab({
15711
15859
  ]
15712
15860
  }
15713
15861
  ),
15714
- /* @__PURE__ */ jsx33(
15862
+ /* @__PURE__ */ jsx34(
15715
15863
  ScWorkspaceSwitchCard,
15716
15864
  {
15717
15865
  wsName: currentWorkspace.name,
@@ -15728,7 +15876,7 @@ function WorkspaceListTab({
15728
15876
  ]
15729
15877
  }
15730
15878
  ),
15731
- !listLoading && currentWorkspace && listTotal > 0 && /* @__PURE__ */ jsx33(
15879
+ !listLoading && currentWorkspace && listTotal > 0 && /* @__PURE__ */ jsx34(
15732
15880
  "div",
15733
15881
  {
15734
15882
  className: "shrink-0 w-full",
@@ -15738,19 +15886,19 @@ function WorkspaceListTab({
15738
15886
  }
15739
15887
  }
15740
15888
  ),
15741
- !listLoading && listTotal > 0 && /* @__PURE__ */ jsxs30(
15889
+ !listLoading && listTotal > 0 && /* @__PURE__ */ jsxs31(
15742
15890
  "div",
15743
15891
  {
15744
15892
  className: "flex flex-col items-start flex-1 min-h-0 w-full",
15745
15893
  style: { gap: 16, overflowY: "auto" },
15746
15894
  children: [
15747
- /* @__PURE__ */ jsx33(
15895
+ /* @__PURE__ */ jsx34(
15748
15896
  "div",
15749
15897
  {
15750
15898
  className: "flex flex-col items-start w-full",
15751
15899
  style: { gap: 16 },
15752
- children: pageRows.map(({ ws, group }, index) => /* @__PURE__ */ jsxs30(Fragment15, { children: [
15753
- (index === 0 || pageRows[index - 1].group.key !== group.key) && /* @__PURE__ */ jsx33(
15900
+ children: pageRows.map(({ ws, group }, index) => /* @__PURE__ */ jsxs31(Fragment15, { children: [
15901
+ (index === 0 || pageRows[index - 1].group.key !== group.key) && /* @__PURE__ */ jsx34(
15754
15902
  "p",
15755
15903
  {
15756
15904
  className: "w-full overflow-hidden text-ellipsis whitespace-nowrap shrink-0",
@@ -15765,7 +15913,7 @@ function WorkspaceListTab({
15765
15913
  children: group.label
15766
15914
  }
15767
15915
  ),
15768
- /* @__PURE__ */ jsx33(
15916
+ /* @__PURE__ */ jsx34(
15769
15917
  ScWorkspaceSwitchCard,
15770
15918
  {
15771
15919
  wsName: ws.name,
@@ -15783,13 +15931,13 @@ function WorkspaceListTab({
15783
15931
  ] }, ws._id))
15784
15932
  }
15785
15933
  ),
15786
- pageCount > 1 && /* @__PURE__ */ jsxs30(
15934
+ pageCount > 1 && /* @__PURE__ */ jsxs31(
15787
15935
  "div",
15788
15936
  {
15789
15937
  className: "flex items-center justify-between shrink-0 w-full",
15790
15938
  style: { gap: "var(--spacing-md)" },
15791
15939
  children: [
15792
- /* @__PURE__ */ jsxs30(
15940
+ /* @__PURE__ */ jsxs31(
15793
15941
  "span",
15794
15942
  {
15795
15943
  style: {
@@ -15808,8 +15956,8 @@ function WorkspaceListTab({
15808
15956
  ]
15809
15957
  }
15810
15958
  ),
15811
- /* @__PURE__ */ jsxs30("div", { className: "flex items-center", style: { gap: "var(--spacing-md)" }, children: [
15812
- /* @__PURE__ */ jsx33(
15959
+ /* @__PURE__ */ jsxs31("div", { className: "flex items-center", style: { gap: "var(--spacing-md)" }, children: [
15960
+ /* @__PURE__ */ jsx34(
15813
15961
  ScButton18,
15814
15962
  {
15815
15963
  text: "Previous",
@@ -15819,7 +15967,7 @@ function WorkspaceListTab({
15819
15967
  onClick: safePage === 0 ? void 0 : () => setPage(safePage - 1)
15820
15968
  }
15821
15969
  ),
15822
- /* @__PURE__ */ jsx33(
15970
+ /* @__PURE__ */ jsx34(
15823
15971
  ScButton18,
15824
15972
  {
15825
15973
  text: "Next",
@@ -15842,7 +15990,7 @@ function WorkspaceListTab({
15842
15990
  }
15843
15991
  var WorkspaceTab = WorkspaceListTab;
15844
15992
  function ReferralTab() {
15845
- const { auth, toast } = useSettingsAdapters();
15993
+ const { auth, toast, api } = useSettingsAdapters();
15846
15994
  const domain = typeof window !== "undefined" ? window.location.origin : "";
15847
15995
  const link = referralLink(referralCodeOf(auth.user), domain);
15848
15996
  const [copied, setCopied] = useState25(false);
@@ -15862,68 +16010,71 @@ function ReferralTab() {
15862
16010
  toast.error("Couldn't copy the referral link");
15863
16011
  }
15864
16012
  };
15865
- return /* @__PURE__ */ jsx33(
16013
+ return /* @__PURE__ */ jsxs31(
15866
16014
  "div",
15867
16015
  {
15868
16016
  className: "flex flex-col items-start flex-1 min-w-0",
15869
16017
  style: { gap: "var(--spacing-3xl)" },
15870
- children: /* @__PURE__ */ jsx33(
15871
- "div",
15872
- {
15873
- className: "w-full relative",
15874
- style: {
15875
- backgroundColor: "var(--alias-surface-base)",
15876
- borderRadius: "var(--radius-3xl)",
15877
- padding: "var(--spacing-6xl)"
15878
- },
15879
- children: /* @__PURE__ */ jsx33(
15880
- ScTextField,
15881
- {
15882
- label: "Your Referral Link",
15883
- labelGroup: "label",
15884
- state: "filled",
15885
- value: link,
15886
- placeholderFilled: "https://your-domain.com?referral_code=ABC123",
15887
- tfGroup: "none",
15888
- rightSlot: /* @__PURE__ */ jsxs30(
15889
- "button",
15890
- {
15891
- type: "button",
15892
- "aria-label": copied ? "Copied" : "Copy referral link",
15893
- title: copied ? "Copied" : "Copy referral link",
15894
- disabled: !link,
15895
- onClick: () => void copyLink(),
15896
- className: "flex items-center justify-center shrink-0 cursor-pointer border-none",
15897
- style: {
15898
- gap: "var(--spacing-xs)",
15899
- padding: "0 var(--spacing-md)",
15900
- height: 32,
15901
- borderRadius: "var(--radius-lg)",
15902
- background: "transparent",
15903
- color: "var(--alias-text---icons-primary)",
15904
- fontSize: "var(--font-size-font-size-sm)",
15905
- fontWeight: 500
15906
- },
15907
- onMouseEnter: (e) => {
15908
- e.currentTarget.style.background = "var(--alias-fill-neutral-neutralplus)";
15909
- },
15910
- onMouseLeave: (e) => {
15911
- e.currentTarget.style.background = "transparent";
15912
- },
15913
- children: [
15914
- copied ? /* @__PURE__ */ jsx33(SiconCheck2, { className: "w-4 h-4", color: "var(--alias-text---icons-primary)" }) : /* @__PURE__ */ jsx33(SiconCopy2, { className: "w-4 h-4", color: "var(--alias-text---icons-primary)" }),
15915
- copied ? "Copied" : "Copy"
15916
- ]
15917
- }
15918
- ),
15919
- desc: "Share this link. When someone opens it and creates a new Streamoid account, it's recorded as your referral.",
15920
- className: "sc-text-field-full-width w-full min-w-0",
15921
- readOnly: true,
15922
- onFocus: (e) => e.currentTarget.select()
15923
- }
15924
- )
15925
- }
15926
- )
16018
+ children: [
16019
+ /* @__PURE__ */ jsx34(
16020
+ "div",
16021
+ {
16022
+ className: "w-full relative",
16023
+ style: {
16024
+ backgroundColor: "var(--alias-surface-base)",
16025
+ borderRadius: "var(--radius-3xl)",
16026
+ padding: "var(--spacing-6xl)"
16027
+ },
16028
+ children: /* @__PURE__ */ jsx34(
16029
+ ScTextField,
16030
+ {
16031
+ label: "Your Referral Link",
16032
+ labelGroup: "label",
16033
+ state: "filled",
16034
+ value: link,
16035
+ placeholderFilled: "https://your-domain.com?referral_code=ABC123",
16036
+ tfGroup: "none",
16037
+ rightSlot: /* @__PURE__ */ jsxs31(
16038
+ "button",
16039
+ {
16040
+ type: "button",
16041
+ "aria-label": copied ? "Copied" : "Copy referral link",
16042
+ title: copied ? "Copied" : "Copy referral link",
16043
+ disabled: !link,
16044
+ onClick: () => void copyLink(),
16045
+ className: "flex items-center justify-center shrink-0 cursor-pointer border-none",
16046
+ style: {
16047
+ gap: "var(--spacing-xs)",
16048
+ padding: "0 var(--spacing-md)",
16049
+ height: 32,
16050
+ borderRadius: "var(--radius-lg)",
16051
+ background: "transparent",
16052
+ color: "var(--alias-text---icons-primary)",
16053
+ fontSize: "var(--font-size-font-size-sm)",
16054
+ fontWeight: 500
16055
+ },
16056
+ onMouseEnter: (e) => {
16057
+ e.currentTarget.style.background = "var(--alias-fill-neutral-neutralplus)";
16058
+ },
16059
+ onMouseLeave: (e) => {
16060
+ e.currentTarget.style.background = "transparent";
16061
+ },
16062
+ children: [
16063
+ copied ? /* @__PURE__ */ jsx34(SiconCheck2, { className: "w-4 h-4", color: "var(--alias-text---icons-primary)" }) : /* @__PURE__ */ jsx34(SiconCopy2, { className: "w-4 h-4", color: "var(--alias-text---icons-primary)" }),
16064
+ copied ? "Copied" : "Copy"
16065
+ ]
16066
+ }
16067
+ ),
16068
+ desc: "Share this link. When someone opens it and creates a new Streamoid account, it's recorded as your referral.",
16069
+ className: "sc-text-field-full-width w-full min-w-0",
16070
+ readOnly: true,
16071
+ onFocus: (e) => e.currentTarget.select()
16072
+ }
16073
+ )
16074
+ }
16075
+ ),
16076
+ api.getReferredUsers && /* @__PURE__ */ jsx34(ReferralHistory, { load: (signal) => api.getReferredUsers(signal) })
16077
+ ]
15927
16078
  }
15928
16079
  );
15929
16080
  }
@@ -15940,7 +16091,7 @@ function SettingsContent({
15940
16091
  inviteRequested,
15941
16092
  onInviteRequestHandled
15942
16093
  }) {
15943
- return /* @__PURE__ */ jsx33(SettingsAdaptersProvider, { adapters, children: /* @__PURE__ */ jsx33(
16094
+ return /* @__PURE__ */ jsx34(SettingsAdaptersProvider, { adapters, children: /* @__PURE__ */ jsx34(
15944
16095
  SettingsContentInner,
15945
16096
  {
15946
16097
  activeTab,
@@ -16393,7 +16544,7 @@ function SettingsContentInner({
16393
16544
  setConfirmLeaveOpen(true);
16394
16545
  return false;
16395
16546
  }
16396
- return /* @__PURE__ */ jsxs30(
16547
+ return /* @__PURE__ */ jsxs31(
16397
16548
  "div",
16398
16549
  {
16399
16550
  "data-streamoid-settings": "",
@@ -16404,8 +16555,8 @@ function SettingsContentInner({
16404
16555
  ...isOverview ? { display: "block", overflowY: "auto" } : {}
16405
16556
  },
16406
16557
  children: [
16407
- !isOverview && /* @__PURE__ */ jsx33(SettingsAppearance, {}),
16408
- /* @__PURE__ */ jsx33(
16558
+ !isOverview && /* @__PURE__ */ jsx34(SettingsAppearance, {}),
16559
+ /* @__PURE__ */ jsx34(
16409
16560
  "div",
16410
16561
  {
16411
16562
  className: "flex flex-col items-start relative h-full overflow-hidden",
@@ -16416,8 +16567,8 @@ function SettingsContentInner({
16416
16567
  width: "100%",
16417
16568
  ...isOverview ? { height: "auto", minHeight: "100%", overflow: "visible", marginInline: "auto" } : {}
16418
16569
  },
16419
- children: /* @__PURE__ */ jsxs30("div", { className: "flex flex-col w-full flex-1 min-h-0", style: { gap: 20, paddingTop: 16 }, children: [
16420
- !overviewDetail && onBack !== null && /* @__PURE__ */ jsx33("div", { className: "flex items-center shrink-0", style: { paddingLeft: 20 }, children: /* @__PURE__ */ jsxs30(
16570
+ children: /* @__PURE__ */ jsxs31("div", { className: "flex flex-col w-full flex-1 min-h-0", style: { gap: 20, paddingTop: 16 }, children: [
16571
+ !overviewDetail && onBack !== null && /* @__PURE__ */ jsx34("div", { className: "flex items-center shrink-0", style: { paddingLeft: 20 }, children: /* @__PURE__ */ jsxs31(
16421
16572
  "button",
16422
16573
  {
16423
16574
  type: "button",
@@ -16449,19 +16600,19 @@ function SettingsContentInner({
16449
16600
  else window.history.back();
16450
16601
  },
16451
16602
  children: [
16452
- /* @__PURE__ */ jsx33(SiconLeft3, { className: "w-4 h-4 shrink-0", color: "var(--alias-text---icons-muted)" }),
16603
+ /* @__PURE__ */ jsx34(SiconLeft3, { className: "w-4 h-4 shrink-0", color: "var(--alias-text---icons-muted)" }),
16453
16604
  "Back"
16454
16605
  ]
16455
16606
  }
16456
16607
  ) }),
16457
- overviewDetail && !isOverview && (isBillingSubView || onOverview) && /* @__PURE__ */ jsx33("div", { className: "flex items-center shrink-0", style: { paddingLeft: 20 }, children: /* @__PURE__ */ jsx33(
16608
+ overviewDetail && !isOverview && (isBillingSubView || onOverview) && /* @__PURE__ */ jsx34("div", { className: "flex items-center shrink-0", style: { paddingLeft: 20 }, children: /* @__PURE__ */ jsx34(
16458
16609
  ScButton18,
16459
16610
  {
16460
16611
  text: isBillingSubView ? "Back to billing" : "Back to account and workspace settings",
16461
16612
  variant: "tertiary",
16462
16613
  size: "sm",
16463
16614
  styleVariant: "icon-left",
16464
- icon: /* @__PURE__ */ jsx33(SiconArrowLeft, { size: 18, "aria-hidden": "true" }),
16615
+ icon: /* @__PURE__ */ jsx34(SiconArrowLeft, { size: 18, "aria-hidden": "true" }),
16465
16616
  onClick: () => {
16466
16617
  if (isBillingSubView) {
16467
16618
  setBillingShowPlans(false);
@@ -16473,7 +16624,7 @@ function SettingsContentInner({
16473
16624
  }
16474
16625
  }
16475
16626
  ) }),
16476
- /* @__PURE__ */ jsxs30(
16627
+ /* @__PURE__ */ jsxs31(
16477
16628
  "div",
16478
16629
  {
16479
16630
  className: "flex items-center shrink-0 w-full",
@@ -16484,9 +16635,9 @@ function SettingsContentInner({
16484
16635
  paddingRight: 20
16485
16636
  },
16486
16637
  children: [
16487
- /* @__PURE__ */ jsxs30("div", { className: "flex items-center flex-1 min-w-0", style: { gap: 8, paddingLeft: 20 }, children: [
16488
- /* @__PURE__ */ jsx33(SiconSettings2, { className: "w-6 h-6 shrink-0", color: "var(--alias-text---icons-primary)" }),
16489
- /* @__PURE__ */ jsx33(
16638
+ /* @__PURE__ */ jsxs31("div", { className: "flex items-center flex-1 min-w-0", style: { gap: 8, paddingLeft: 20 }, children: [
16639
+ /* @__PURE__ */ jsx34(SiconSettings2, { className: "w-6 h-6 shrink-0", color: "var(--alias-text---icons-primary)" }),
16640
+ /* @__PURE__ */ jsx34(
16490
16641
  "h1",
16491
16642
  {
16492
16643
  style: {
@@ -16500,10 +16651,10 @@ function SettingsContentInner({
16500
16651
  children: overviewDetail ? "Account and workspace settings" : "Settings"
16501
16652
  }
16502
16653
  ),
16503
- !isOverview && /* @__PURE__ */ jsxs30("nav", { "aria-label": "Breadcrumb", className: "flex items-center min-w-0", style: { gap: 8 }, children: [
16504
- scopeCrumb && /* @__PURE__ */ jsxs30(Fragment16, { children: [
16505
- /* @__PURE__ */ jsx33(SiconRight3, { className: "w-6 h-6 shrink-0", color: "var(--alias-text---icons-primary)" }),
16506
- /* @__PURE__ */ jsx33(
16654
+ !isOverview && /* @__PURE__ */ jsxs31("nav", { "aria-label": "Breadcrumb", className: "flex items-center min-w-0", style: { gap: 8 }, children: [
16655
+ scopeCrumb && /* @__PURE__ */ jsxs31(Fragment16, { children: [
16656
+ /* @__PURE__ */ jsx34(SiconRight3, { className: "w-6 h-6 shrink-0", color: "var(--alias-text---icons-primary)" }),
16657
+ /* @__PURE__ */ jsx34(
16507
16658
  "span",
16508
16659
  {
16509
16660
  className: "truncate",
@@ -16520,8 +16671,8 @@ function SettingsContentInner({
16520
16671
  }
16521
16672
  )
16522
16673
  ] }),
16523
- /* @__PURE__ */ jsx33(SiconRight3, { className: "w-6 h-6 shrink-0", color: "var(--alias-text---icons-primary)" }),
16524
- /* @__PURE__ */ jsx33(
16674
+ /* @__PURE__ */ jsx34(SiconRight3, { className: "w-6 h-6 shrink-0", color: "var(--alias-text---icons-primary)" }),
16675
+ /* @__PURE__ */ jsx34(
16525
16676
  "span",
16526
16677
  {
16527
16678
  style: {
@@ -16534,9 +16685,9 @@ function SettingsContentInner({
16534
16685
  children: leafLabel
16535
16686
  }
16536
16687
  ),
16537
- isBillingPlans && /* @__PURE__ */ jsxs30(Fragment16, { children: [
16538
- /* @__PURE__ */ jsx33(SiconRight3, { className: "w-6 h-6 shrink-0", color: "var(--alias-text---icons-primary)" }),
16539
- /* @__PURE__ */ jsx33(
16688
+ isBillingPlans && /* @__PURE__ */ jsxs31(Fragment16, { children: [
16689
+ /* @__PURE__ */ jsx34(SiconRight3, { className: "w-6 h-6 shrink-0", color: "var(--alias-text---icons-primary)" }),
16690
+ /* @__PURE__ */ jsx34(
16540
16691
  "span",
16541
16692
  {
16542
16693
  style: {
@@ -16550,9 +16701,9 @@ function SettingsContentInner({
16550
16701
  }
16551
16702
  )
16552
16703
  ] }),
16553
- isBillingPerUserLimits && /* @__PURE__ */ jsxs30(Fragment16, { children: [
16554
- /* @__PURE__ */ jsx33(SiconRight3, { className: "w-6 h-6 shrink-0", color: "var(--alias-text---icons-primary)" }),
16555
- /* @__PURE__ */ jsx33(
16704
+ isBillingPerUserLimits && /* @__PURE__ */ jsxs31(Fragment16, { children: [
16705
+ /* @__PURE__ */ jsx34(SiconRight3, { className: "w-6 h-6 shrink-0", color: "var(--alias-text---icons-primary)" }),
16706
+ /* @__PURE__ */ jsx34(
16556
16707
  "span",
16557
16708
  {
16558
16709
  style: {
@@ -16566,9 +16717,9 @@ function SettingsContentInner({
16566
16717
  }
16567
16718
  )
16568
16719
  ] }),
16569
- isBillingSharedCredits && /* @__PURE__ */ jsxs30(Fragment16, { children: [
16570
- /* @__PURE__ */ jsx33(SiconRight3, { className: "w-6 h-6 shrink-0", color: "var(--alias-text---icons-primary)" }),
16571
- /* @__PURE__ */ jsx33(
16720
+ isBillingSharedCredits && /* @__PURE__ */ jsxs31(Fragment16, { children: [
16721
+ /* @__PURE__ */ jsx34(SiconRight3, { className: "w-6 h-6 shrink-0", color: "var(--alias-text---icons-primary)" }),
16722
+ /* @__PURE__ */ jsx34(
16572
16723
  "span",
16573
16724
  {
16574
16725
  style: {
@@ -16584,20 +16735,20 @@ function SettingsContentInner({
16584
16735
  ] })
16585
16736
  ] })
16586
16737
  ] }),
16587
- !isOverview && activeTab === "workspaceList" && /* @__PURE__ */ jsx33(
16738
+ !isOverview && activeTab === "workspaceList" && /* @__PURE__ */ jsx34(
16588
16739
  SettingsTooltip,
16589
16740
  {
16590
16741
  content: "Start a new workspace with its own team, members and billing",
16591
16742
  placement: "bottom",
16592
16743
  inline: true,
16593
- children: /* @__PURE__ */ jsx33(
16744
+ children: /* @__PURE__ */ jsx34(
16594
16745
  ScButton18,
16595
16746
  {
16596
16747
  text: "Create Workspace",
16597
16748
  variant: "secondary",
16598
16749
  size: "md",
16599
16750
  styleVariant: "icon-left",
16600
- icon: /* @__PURE__ */ jsx33(
16751
+ icon: /* @__PURE__ */ jsx34(
16601
16752
  SiconWorkspace2,
16602
16753
  {
16603
16754
  className: "w-5 h-5",
@@ -16609,13 +16760,13 @@ function SettingsContentInner({
16609
16760
  )
16610
16761
  }
16611
16762
  ),
16612
- !isOverview && activeTab === "workspaceMembers" && /* @__PURE__ */ jsx33(
16763
+ !isOverview && activeTab === "workspaceMembers" && /* @__PURE__ */ jsx34(
16613
16764
  SettingsTooltip,
16614
16765
  {
16615
16766
  content: "Send someone an invite to join this workspace",
16616
16767
  placement: "bottom",
16617
16768
  inline: true,
16618
- children: /* @__PURE__ */ jsx33(
16769
+ children: /* @__PURE__ */ jsx34(
16619
16770
  ScButton18,
16620
16771
  {
16621
16772
  text: overviewDetail ? "Invite people" : "Invite user",
@@ -16623,7 +16774,7 @@ function SettingsContentInner({
16623
16774
  size: "md",
16624
16775
  styleVariant: "icon-left",
16625
16776
  state: canUseHeaderInvite ? "default" : "disabled",
16626
- icon: /* @__PURE__ */ jsx33(
16777
+ icon: /* @__PURE__ */ jsx34(
16627
16778
  SiconUserAdd3,
16628
16779
  {
16629
16780
  className: "w-5 h-5",
@@ -16637,14 +16788,14 @@ function SettingsContentInner({
16637
16788
  )
16638
16789
  }
16639
16790
  ),
16640
- !isOverview && activeTab === "apikey" && isWorkspaceAdmin && /* @__PURE__ */ jsxs30("div", { className: "flex items-center shrink-0", style: { gap: "var(--spacing-md)" }, children: [
16641
- /* @__PURE__ */ jsx33(
16791
+ !isOverview && activeTab === "apikey" && isWorkspaceAdmin && /* @__PURE__ */ jsxs31("div", { className: "flex items-center shrink-0", style: { gap: "var(--spacing-md)" }, children: [
16792
+ /* @__PURE__ */ jsx34(
16642
16793
  SettingsTooltip,
16643
16794
  {
16644
16795
  content: "Include keys you have already revoked in the list below",
16645
16796
  placement: "bottom",
16646
16797
  inline: true,
16647
- children: /* @__PURE__ */ jsx33(
16798
+ children: /* @__PURE__ */ jsx34(
16648
16799
  ScButton18,
16649
16800
  {
16650
16801
  text: tokenShowRevoked ? "Hide Revoked" : "Show Revoked",
@@ -16655,20 +16806,20 @@ function SettingsContentInner({
16655
16806
  )
16656
16807
  }
16657
16808
  ),
16658
- /* @__PURE__ */ jsx33(
16809
+ /* @__PURE__ */ jsx34(
16659
16810
  SettingsTooltip,
16660
16811
  {
16661
16812
  content: "Generate a key for calling the Streamoid APIs from your own code",
16662
16813
  placement: "bottom",
16663
16814
  inline: true,
16664
- children: /* @__PURE__ */ jsx33(
16815
+ children: /* @__PURE__ */ jsx34(
16665
16816
  ScButton18,
16666
16817
  {
16667
16818
  text: "New API Key",
16668
16819
  variant: "secondary",
16669
16820
  size: "md",
16670
16821
  styleVariant: "icon-left",
16671
- icon: /* @__PURE__ */ jsx33(
16822
+ icon: /* @__PURE__ */ jsx34(
16672
16823
  SiconPlus3,
16673
16824
  {
16674
16825
  className: "w-5 h-5",
@@ -16681,13 +16832,13 @@ function SettingsContentInner({
16681
16832
  }
16682
16833
  )
16683
16834
  ] }),
16684
- overviewDetail && onClose && /* @__PURE__ */ jsx33(SettingsTooltip, { content: "Close settings", placement: "bottom", inline: true, children: /* @__PURE__ */ jsx33(
16835
+ overviewDetail && onClose && /* @__PURE__ */ jsx34(SettingsTooltip, { content: "Close settings", placement: "bottom", inline: true, children: /* @__PURE__ */ jsx34(
16685
16836
  ScButton18,
16686
16837
  {
16687
16838
  styleVariant: "icon-only",
16688
16839
  variant: "outline",
16689
16840
  size: "md",
16690
- icon: /* @__PURE__ */ jsx33(SiconClose11, { className: "w-5 h-5", color: PRIMARY_COLOR3 }),
16841
+ icon: /* @__PURE__ */ jsx34(SiconClose11, { className: "w-5 h-5", color: PRIMARY_COLOR3 }),
16691
16842
  "aria-label": "Close settings",
16692
16843
  style: isOverview ? { width: "2rem", height: "2rem", padding: 0 } : void 0,
16693
16844
  onClick: onClose
@@ -16696,7 +16847,7 @@ function SettingsContentInner({
16696
16847
  ]
16697
16848
  }
16698
16849
  ),
16699
- isOverview ? /* @__PURE__ */ jsx33(
16850
+ isOverview ? /* @__PURE__ */ jsx34(
16700
16851
  AdministrationOverview,
16701
16852
  {
16702
16853
  workspaceName: workspaceScopeName,
@@ -16711,13 +16862,13 @@ function SettingsContentInner({
16711
16862
  onNavigate: setActiveTab,
16712
16863
  onInvitePeople
16713
16864
  }
16714
- ) : /* @__PURE__ */ jsxs30(
16865
+ ) : /* @__PURE__ */ jsxs31(
16715
16866
  "div",
16716
16867
  {
16717
16868
  className: "flex items-start flex-1 min-h-0 w-full overflow-hidden",
16718
16869
  style: { gap: 20 },
16719
16870
  children: [
16720
- !overviewDetail && !isBillingSubView && /* @__PURE__ */ jsx33(
16871
+ !overviewDetail && !isBillingSubView && /* @__PURE__ */ jsx34(
16721
16872
  SettingsNav,
16722
16873
  {
16723
16874
  isWorkspaceAdmin,
@@ -16731,8 +16882,8 @@ function SettingsContentInner({
16731
16882
  showReferral
16732
16883
  }
16733
16884
  ),
16734
- activeTab === "profile" && /* @__PURE__ */ jsx33(ProfileTab, {}),
16735
- activeTab === "workspace" && /* @__PURE__ */ jsx33("div", { className: "flex flex-col flex-1 min-w-0 min-h-0 h-full", children: /* @__PURE__ */ jsx33(
16885
+ activeTab === "profile" && /* @__PURE__ */ jsx34(ProfileTab, {}),
16886
+ activeTab === "workspace" && /* @__PURE__ */ jsx34("div", { className: "flex flex-col flex-1 min-w-0 min-h-0 h-full", children: /* @__PURE__ */ jsx34(
16736
16887
  WorkspaceGeneralTab,
16737
16888
  {
16738
16889
  workspace: currentWorkspaceData,
@@ -16754,7 +16905,7 @@ function SettingsContentInner({
16754
16905
  }
16755
16906
  }
16756
16907
  ) }),
16757
- activeTab === "workspaceMembers" && /* @__PURE__ */ jsx33("div", { className: "flex flex-col flex-1 min-w-0 min-h-0 h-full", children: /* @__PURE__ */ jsx33(
16908
+ activeTab === "workspaceMembers" && /* @__PURE__ */ jsx34("div", { className: "flex flex-col flex-1 min-w-0 min-h-0 h-full", children: /* @__PURE__ */ jsx34(
16758
16909
  TeamsContent,
16759
16910
  {
16760
16911
  embedded: true,
@@ -16769,7 +16920,7 @@ function SettingsContentInner({
16769
16920
  hiddenApps
16770
16921
  }
16771
16922
  ) }),
16772
- activeTab === "workspaceList" && /* @__PURE__ */ jsx33(
16923
+ activeTab === "workspaceList" && /* @__PURE__ */ jsx34(
16773
16924
  WorkspaceListTab,
16774
16925
  {
16775
16926
  workspaces: displayWorkspaces,
@@ -16794,11 +16945,11 @@ function SettingsContentInner({
16794
16945
  }
16795
16946
  }
16796
16947
  ),
16797
- activeTab === "referral" && showReferral && /* @__PURE__ */ jsx33(ReferralTab, {}),
16798
- activeTab === "connectedApps" && /* @__PURE__ */ jsx33(ConnectedAppsContent, {}),
16799
- activeTab === "organizationIntegrations" && /* @__PURE__ */ jsx33(OrganizationIntegrationsContent, {}),
16800
- activeTab === "organizationList" && /* @__PURE__ */ jsx33(OrganizationListContent, {}),
16801
- (activeTab === "organization" || activeTab === "organizationWorkspaces" || activeTab === "organizationDomains") && /* @__PURE__ */ jsx33("div", { className: "flex flex-col flex-1 min-w-0 min-h-0 h-full", children: organization.managementUrl ? /* @__PURE__ */ jsx33(
16948
+ activeTab === "referral" && showReferral && /* @__PURE__ */ jsx34(ReferralTab, {}),
16949
+ activeTab === "connectedApps" && /* @__PURE__ */ jsx34(ConnectedAppsContent, {}),
16950
+ activeTab === "organizationIntegrations" && /* @__PURE__ */ jsx34(OrganizationIntegrationsContent, {}),
16951
+ activeTab === "organizationList" && /* @__PURE__ */ jsx34(OrganizationListContent, {}),
16952
+ (activeTab === "organization" || activeTab === "organizationWorkspaces" || activeTab === "organizationDomains") && /* @__PURE__ */ jsx34("div", { className: "flex flex-col flex-1 min-w-0 min-h-0 h-full", children: organization.managementUrl ? /* @__PURE__ */ jsx34(
16802
16953
  ManagedOrganizationSummary,
16803
16954
  {
16804
16955
  name: workspaceOwner.organizationName,
@@ -16806,14 +16957,14 @@ function SettingsContentInner({
16806
16957
  status: workspaceOwner.organizationStatus,
16807
16958
  managementUrl: organization.managementUrl
16808
16959
  }
16809
- ) : /* @__PURE__ */ jsx33(
16960
+ ) : /* @__PURE__ */ jsx34(
16810
16961
  OrganizationContent,
16811
16962
  {
16812
16963
  embedded: true,
16813
16964
  view: activeTab === "organizationWorkspaces" || activeTab === "organizationDomains" ? "workspaces" : "people"
16814
16965
  }
16815
16966
  ) }),
16816
- activeTab === "billing" && isWorkspaceAdmin && /* @__PURE__ */ jsx33("div", { className: "flex flex-col flex-1 min-w-0 min-h-0 h-full", children: /* @__PURE__ */ jsx33(
16967
+ activeTab === "billing" && isWorkspaceAdmin && /* @__PURE__ */ jsx34("div", { className: "flex flex-col flex-1 min-w-0 min-h-0 h-full", children: /* @__PURE__ */ jsx34(
16817
16968
  BillingContent,
16818
16969
  {
16819
16970
  embedded: true,
@@ -16843,14 +16994,14 @@ function SettingsContentInner({
16843
16994
  }
16844
16995
  }
16845
16996
  ) }),
16846
- (activeTab === "billing" || activeTab === "apikey") && !isWorkspaceAdmin && /* @__PURE__ */ jsxs30("section", { role: "status", className: "flex flex-col flex-1 min-w-0", style: { padding: 28, gap: 12, background: "var(--alias-surface-base)", border: "1px solid var(--alias-border-default)", borderRadius: "var(--radius-3xl, 16px)" }, children: [
16847
- /* @__PURE__ */ jsx33(SiconLock, { size: 24, color: MUTED_COLOR2 }),
16848
- /* @__PURE__ */ jsx33("h2", { style: { margin: 0, fontSize: 18, fontWeight: 600, color: PRIMARY_COLOR3 }, children: "Contact your workspace admin" }),
16849
- /* @__PURE__ */ jsx33("p", { style: { margin: 0, fontSize: 14, lineHeight: "22px", color: MUTED_COLOR2, maxWidth: 480 }, children: activeTab === "billing" ? "Your workspace admin manages credit top-ups, plans and billing history. Get in touch with them to add credits or request billing details." : "API Keys are available to workspace Admins only. Get in touch with your workspace admin to manage API access." }),
16850
- /* @__PURE__ */ jsx33("button", { type: "button", onClick: () => setActiveTab("workspaceMembers"), style: { alignSelf: "flex-start", marginTop: 8, padding: "8px 12px", background: "transparent", color: PRIMARY_COLOR3, border: "1px solid var(--alias-border-default)", borderRadius: 8, cursor: "pointer" }, children: "View workspace members" })
16997
+ (activeTab === "billing" || activeTab === "apikey") && !isWorkspaceAdmin && /* @__PURE__ */ jsxs31("section", { role: "status", className: "flex flex-col flex-1 min-w-0", style: { padding: 28, gap: 12, background: "var(--alias-surface-base)", border: "1px solid var(--alias-border-default)", borderRadius: "var(--radius-3xl, 16px)" }, children: [
16998
+ /* @__PURE__ */ jsx34(SiconLock, { size: 24, color: MUTED_COLOR2 }),
16999
+ /* @__PURE__ */ jsx34("h2", { style: { margin: 0, fontSize: 18, fontWeight: 600, color: PRIMARY_COLOR3 }, children: "Contact your workspace admin" }),
17000
+ /* @__PURE__ */ jsx34("p", { style: { margin: 0, fontSize: 14, lineHeight: "22px", color: MUTED_COLOR2, maxWidth: 480 }, children: activeTab === "billing" ? "Your workspace admin manages credit top-ups, plans and billing history. Get in touch with them to add credits or request billing details." : "API Keys are available to workspace Admins only. Get in touch with your workspace admin to manage API access." }),
17001
+ /* @__PURE__ */ jsx34("button", { type: "button", onClick: () => setActiveTab("workspaceMembers"), style: { alignSelf: "flex-start", marginTop: 8, padding: "8px 12px", background: "transparent", color: PRIMARY_COLOR3, border: "1px solid var(--alias-border-default)", borderRadius: 8, cursor: "pointer" }, children: "View workspace members" })
16851
17002
  ] }),
16852
- activeTab === "apikey" && isWorkspaceAdmin && /* @__PURE__ */ jsxs30("div", { className: "flex flex-col flex-1 min-w-0 min-h-0 h-full", children: [
16853
- /* @__PURE__ */ jsxs30(
17003
+ activeTab === "apikey" && isWorkspaceAdmin && /* @__PURE__ */ jsxs31("div", { className: "flex flex-col flex-1 min-w-0 min-h-0 h-full", children: [
17004
+ /* @__PURE__ */ jsxs31(
16854
17005
  "a",
16855
17006
  {
16856
17007
  href: "https://docs.streamoid.com",
@@ -16860,19 +17011,19 @@ function SettingsContentInner({
16860
17011
  className: "flex items-center shrink-0",
16861
17012
  style: { gap: 14, padding: "16px 20px", marginBottom: 16, border: "1px solid var(--alias-border-default)", borderRadius: "var(--radius-3xl, 16px)", background: "var(--alias-surface-base)", color: PRIMARY_COLOR3, textDecoration: "none" },
16862
17013
  children: [
16863
- /* @__PURE__ */ jsx33(SiconBookOpen, { size: 24 }),
16864
- /* @__PURE__ */ jsxs30("span", { style: { display: "flex", flexDirection: "column", gap: 4, flex: 1 }, children: [
16865
- /* @__PURE__ */ jsx33("span", { style: { fontSize: 14, fontWeight: 600 }, children: "Build with the Streamoid API" }),
16866
- /* @__PURE__ */ jsx33("span", { style: { fontSize: 13, lineHeight: "20px", color: MUTED_COLOR2 }, children: "Explore authentication, API references and integration guides." })
17014
+ /* @__PURE__ */ jsx34(SiconBookOpen, { size: 24 }),
17015
+ /* @__PURE__ */ jsxs31("span", { style: { display: "flex", flexDirection: "column", gap: 4, flex: 1 }, children: [
17016
+ /* @__PURE__ */ jsx34("span", { style: { fontSize: 14, fontWeight: 600 }, children: "Build with the Streamoid API" }),
17017
+ /* @__PURE__ */ jsx34("span", { style: { fontSize: 13, lineHeight: "20px", color: MUTED_COLOR2 }, children: "Explore authentication, API references and integration guides." })
16867
17018
  ] }),
16868
- /* @__PURE__ */ jsxs30("span", { style: { display: "inline-flex", alignItems: "center", gap: 6, fontSize: 13, whiteSpace: "nowrap" }, children: [
17019
+ /* @__PURE__ */ jsxs31("span", { style: { display: "inline-flex", alignItems: "center", gap: 6, fontSize: 13, whiteSpace: "nowrap" }, children: [
16869
17020
  "View docs ",
16870
- /* @__PURE__ */ jsx33(SiconExternalLink2, { size: 16 })
17021
+ /* @__PURE__ */ jsx34(SiconExternalLink2, { size: 16 })
16871
17022
  ] })
16872
17023
  ]
16873
17024
  }
16874
17025
  ),
16875
- /* @__PURE__ */ jsx33(
17026
+ /* @__PURE__ */ jsx34(
16876
17027
  TokensContent,
16877
17028
  {
16878
17029
  embedded: true,
@@ -16889,7 +17040,7 @@ function SettingsContentInner({
16889
17040
  ] })
16890
17041
  }
16891
17042
  ),
16892
- /* @__PURE__ */ jsx33(
17043
+ /* @__PURE__ */ jsx34(
16893
17044
  WorkspaceModal,
16894
17045
  {
16895
17046
  open: wsModalOpen,
@@ -16908,7 +17059,7 @@ function SettingsContentInner({
16908
17059
  }
16909
17060
  }
16910
17061
  ),
16911
- /* @__PURE__ */ jsx33(
17062
+ /* @__PURE__ */ jsx34(
16912
17063
  ConfirmLeaveModal,
16913
17064
  {
16914
17065
  open: confirmLeaveOpen,
@@ -16941,7 +17092,7 @@ function SettingsContentInner({
16941
17092
  }
16942
17093
  }
16943
17094
  ),
16944
- /* @__PURE__ */ jsx33(
17095
+ /* @__PURE__ */ jsx34(
16945
17096
  ConfirmDeleteModal,
16946
17097
  {
16947
17098
  open: confirmDeleteOpen,
@@ -16974,7 +17125,7 @@ function SettingsContentInner({
16974
17125
  import { useState as useState26 } from "react";
16975
17126
  import { ScButton as ScButton19, ScCheckbox } from "@streamoid/ui";
16976
17127
  import { SiconChevronDown, SiconChevronRight } from "@streamoid/icons";
16977
- import { Fragment as Fragment17, jsx as jsx34, jsxs as jsxs31 } from "react/jsx-runtime";
17128
+ import { Fragment as Fragment17, jsx as jsx35, jsxs as jsxs32 } from "react/jsx-runtime";
16978
17129
  var T19 = {
16979
17130
  primary: "var(--alias-text---icons-primary)",
16980
17131
  muted: "var(--alias-text---icons-muted)",
@@ -17057,7 +17208,7 @@ function WorkspacePicker({
17057
17208
  );
17058
17209
  const workspaceRow = (workspace, first) => {
17059
17210
  const checked = selected.has(workspace._id);
17060
- return /* @__PURE__ */ jsxs31(
17211
+ return /* @__PURE__ */ jsxs32(
17061
17212
  "div",
17062
17213
  {
17063
17214
  role: "checkbox",
@@ -17078,8 +17229,8 @@ function WorkspacePicker({
17078
17229
  }
17079
17230
  },
17080
17231
  children: [
17081
- /* @__PURE__ */ jsx34(ScCheckbox, { checked }),
17082
- /* @__PURE__ */ jsx34(
17232
+ /* @__PURE__ */ jsx35(ScCheckbox, { checked }),
17233
+ /* @__PURE__ */ jsx35(
17083
17234
  ProfileAvatar,
17084
17235
  {
17085
17236
  name: workspace.name,
@@ -17088,8 +17239,8 @@ function WorkspacePicker({
17088
17239
  borderRadius: T19.rLg
17089
17240
  }
17090
17241
  ),
17091
- /* @__PURE__ */ jsxs31("div", { className: "flex flex-col min-w-0", children: [
17092
- /* @__PURE__ */ jsx34(
17242
+ /* @__PURE__ */ jsxs32("div", { className: "flex flex-col min-w-0", children: [
17243
+ /* @__PURE__ */ jsx35(
17093
17244
  "span",
17094
17245
  {
17095
17246
  className: "truncate",
@@ -17097,7 +17248,7 @@ function WorkspacePicker({
17097
17248
  children: workspace.name
17098
17249
  }
17099
17250
  ),
17100
- workspace.ownerName && /* @__PURE__ */ jsxs31(
17251
+ workspace.ownerName && /* @__PURE__ */ jsxs32(
17101
17252
  "span",
17102
17253
  {
17103
17254
  className: "truncate",
@@ -17118,8 +17269,8 @@ function WorkspacePicker({
17118
17269
  const isCollapsed = collapsed.has(section.organizationId);
17119
17270
  const picked = section.workspaces.filter((w) => selected.has(w._id)).length;
17120
17271
  const Chevron = isCollapsed ? SiconChevronRight : SiconChevronDown;
17121
- return /* @__PURE__ */ jsxs31("div", { className: "flex flex-col w-full", children: [
17122
- /* @__PURE__ */ jsxs31(
17272
+ return /* @__PURE__ */ jsxs32("div", { className: "flex flex-col w-full", children: [
17273
+ /* @__PURE__ */ jsxs32(
17123
17274
  "div",
17124
17275
  {
17125
17276
  role: "button",
@@ -17143,8 +17294,8 @@ function WorkspacePicker({
17143
17294
  }
17144
17295
  },
17145
17296
  children: [
17146
- /* @__PURE__ */ jsx34(Chevron, { className: "w-4 h-4", color: T19.muted }),
17147
- /* @__PURE__ */ jsx34(
17297
+ /* @__PURE__ */ jsx35(Chevron, { className: "w-4 h-4", color: T19.muted }),
17298
+ /* @__PURE__ */ jsx35(
17148
17299
  ProfileAvatar,
17149
17300
  {
17150
17301
  name: section.organizationName,
@@ -17153,7 +17304,7 @@ function WorkspacePicker({
17153
17304
  borderRadius: T19.rLg
17154
17305
  }
17155
17306
  ),
17156
- /* @__PURE__ */ jsx34(
17307
+ /* @__PURE__ */ jsx35(
17157
17308
  "span",
17158
17309
  {
17159
17310
  className: "truncate flex-1 min-w-0",
@@ -17161,11 +17312,11 @@ function WorkspacePicker({
17161
17312
  children: section.organizationName
17162
17313
  }
17163
17314
  ),
17164
- /* @__PURE__ */ jsx34("span", { style: { color: T19.muted, fontSize: T19.fsXs, lineHeight: T19.lhXs, flexShrink: 0 }, children: picked ? `${picked} of ${section.workspaces.length} selected` : `${section.workspaces.length} workspace${section.workspaces.length === 1 ? "" : "s"}` })
17315
+ /* @__PURE__ */ jsx35("span", { style: { color: T19.muted, fontSize: T19.fsXs, lineHeight: T19.lhXs, flexShrink: 0 }, children: picked ? `${picked} of ${section.workspaces.length} selected` : `${section.workspaces.length} workspace${section.workspaces.length === 1 ? "" : "s"}` })
17165
17316
  ]
17166
17317
  }
17167
17318
  ),
17168
- !isCollapsed && (section.workspaces.length ? section.workspaces.map((w) => workspaceRow(w, false)) : /* @__PURE__ */ jsx34(
17319
+ !isCollapsed && (section.workspaces.length ? section.workspaces.map((w) => workspaceRow(w, false)) : /* @__PURE__ */ jsx35(
17169
17320
  "div",
17170
17321
  {
17171
17322
  style: {
@@ -17180,14 +17331,14 @@ function WorkspacePicker({
17180
17331
  ))
17181
17332
  ] }, section.organizationId);
17182
17333
  };
17183
- return /* @__PURE__ */ jsxs31(
17334
+ return /* @__PURE__ */ jsxs32(
17184
17335
  "div",
17185
17336
  {
17186
17337
  className: "flex flex-col w-full",
17187
17338
  style: { maxWidth: 520, gap: T19.sp5xl, fontFamily: T19.font },
17188
17339
  children: [
17189
- /* @__PURE__ */ jsxs31("div", { className: "flex flex-col", style: { gap: T19.spMd }, children: [
17190
- /* @__PURE__ */ jsx34(
17340
+ /* @__PURE__ */ jsxs32("div", { className: "flex flex-col", style: { gap: T19.spMd }, children: [
17341
+ /* @__PURE__ */ jsx35(
17191
17342
  "p",
17192
17343
  {
17193
17344
  style: {
@@ -17200,9 +17351,9 @@ function WorkspacePicker({
17200
17351
  children: "Choose your workspaces"
17201
17352
  }
17202
17353
  ),
17203
- /* @__PURE__ */ jsx34("p", { style: { color: T19.muted, fontSize: T19.fsSm, lineHeight: T19.lhSm, margin: 0 }, children: hasWorkspaces || loading ? canCreate ? `Join one or more workspaces in ${orgLabel} as a member, or create your own.` : `Join one or more workspaces in ${orgLabel} as a member.` : canCreate ? `There are no workspaces to join in ${orgLabel} yet. Create one to get started.` : `There are no workspaces you can join in ${orgLabel} yet. Ask an admin${grouped ? "" : ` of ${orgLabel}`} to invite you to one.` })
17354
+ /* @__PURE__ */ jsx35("p", { style: { color: T19.muted, fontSize: T19.fsSm, lineHeight: T19.lhSm, margin: 0 }, children: hasWorkspaces || loading ? canCreate ? `Join one or more workspaces in ${orgLabel} as a member, or create your own.` : `Join one or more workspaces in ${orgLabel} as a member.` : canCreate ? `There are no workspaces to join in ${orgLabel} yet. Create one to get started.` : `There are no workspaces you can join in ${orgLabel} yet. Ask an admin${grouped ? "" : ` of ${orgLabel}`} to invite you to one.` })
17204
17355
  ] }),
17205
- (loading || hasWorkspaces) && /* @__PURE__ */ jsx34(
17356
+ (loading || hasWorkspaces) && /* @__PURE__ */ jsx35(
17206
17357
  "div",
17207
17358
  {
17208
17359
  className: "flex flex-col w-full overflow-y-auto",
@@ -17212,7 +17363,7 @@ function WorkspacePicker({
17212
17363
  border: `1px solid ${T19.borderSubtle}`,
17213
17364
  borderRadius: T19.r3xl
17214
17365
  },
17215
- children: loading ? /* @__PURE__ */ jsx34(
17366
+ children: loading ? /* @__PURE__ */ jsx35(
17216
17367
  "div",
17217
17368
  {
17218
17369
  className: "flex items-center justify-center",
@@ -17222,9 +17373,9 @@ function WorkspacePicker({
17222
17373
  ) : grouped ? sections.map(groupSection) : sections[0].workspaces.map((w, index) => workspaceRow(w, index === 0))
17223
17374
  }
17224
17375
  ),
17225
- showCreate ? /* @__PURE__ */ jsxs31("div", { className: "flex flex-col w-full", style: { gap: T19.spMd }, children: [
17226
- creatable.length > 1 && /* @__PURE__ */ jsxs31(Fragment17, { children: [
17227
- /* @__PURE__ */ jsx34(
17376
+ showCreate ? /* @__PURE__ */ jsxs32("div", { className: "flex flex-col w-full", style: { gap: T19.spMd }, children: [
17377
+ creatable.length > 1 && /* @__PURE__ */ jsxs32(Fragment17, { children: [
17378
+ /* @__PURE__ */ jsx35(
17228
17379
  "label",
17229
17380
  {
17230
17381
  htmlFor: "workspace-picker-organization",
@@ -17232,7 +17383,7 @@ function WorkspacePicker({
17232
17383
  children: "Organization"
17233
17384
  }
17234
17385
  ),
17235
- /* @__PURE__ */ jsx34(
17386
+ /* @__PURE__ */ jsx35(
17236
17387
  "select",
17237
17388
  {
17238
17389
  id: "workspace-picker-organization",
@@ -17249,11 +17400,11 @@ function WorkspacePicker({
17249
17400
  fontFamily: T19.font,
17250
17401
  fontSize: T19.fsSm
17251
17402
  },
17252
- children: creatable.map((s) => /* @__PURE__ */ jsx34("option", { value: s.organizationId, children: s.organizationName }, s.organizationId))
17403
+ children: creatable.map((s) => /* @__PURE__ */ jsx35("option", { value: s.organizationId, children: s.organizationName }, s.organizationId))
17253
17404
  }
17254
17405
  )
17255
17406
  ] }),
17256
- /* @__PURE__ */ jsx34(
17407
+ /* @__PURE__ */ jsx35(
17257
17408
  "label",
17258
17409
  {
17259
17410
  htmlFor: "workspace-picker-name",
@@ -17261,7 +17412,7 @@ function WorkspacePicker({
17261
17412
  children: "New workspace name"
17262
17413
  }
17263
17414
  ),
17264
- /* @__PURE__ */ jsx34(
17415
+ /* @__PURE__ */ jsx35(
17265
17416
  "input",
17266
17417
  {
17267
17418
  id: "workspace-picker-name",
@@ -17285,12 +17436,12 @@ function WorkspacePicker({
17285
17436
  }
17286
17437
  }
17287
17438
  ),
17288
- /* @__PURE__ */ jsx34("div", { role: "radiogroup", className: "flex w-full", style: { gap: T19.spMd }, children: [
17439
+ /* @__PURE__ */ jsx35("div", { role: "radiogroup", className: "flex w-full", style: { gap: T19.spMd }, children: [
17289
17440
  ["shared", "Shared", `Anyone in ${createLabel} can join`],
17290
17441
  ["private", "Private", "Invite only"]
17291
17442
  ].map(([value, label, hint]) => {
17292
17443
  const active = visibility === value;
17293
- return /* @__PURE__ */ jsxs31(
17444
+ return /* @__PURE__ */ jsxs32(
17294
17445
  "div",
17295
17446
  {
17296
17447
  role: "radio",
@@ -17311,7 +17462,7 @@ function WorkspacePicker({
17311
17462
  border: `1px solid ${active ? T19.primary : T19.borderSubtle}`
17312
17463
  },
17313
17464
  children: [
17314
- /* @__PURE__ */ jsx34(
17465
+ /* @__PURE__ */ jsx35(
17315
17466
  "span",
17316
17467
  {
17317
17468
  style: {
@@ -17323,14 +17474,14 @@ function WorkspacePicker({
17323
17474
  children: label
17324
17475
  }
17325
17476
  ),
17326
- /* @__PURE__ */ jsx34("span", { style: { color: T19.muted, fontSize: T19.fsXs, lineHeight: T19.lhXs }, children: hint })
17477
+ /* @__PURE__ */ jsx35("span", { style: { color: T19.muted, fontSize: T19.fsXs, lineHeight: T19.lhXs }, children: hint })
17327
17478
  ]
17328
17479
  },
17329
17480
  value
17330
17481
  );
17331
17482
  }) }),
17332
- /* @__PURE__ */ jsxs31("div", { className: "flex items-center justify-end w-full", style: { gap: T19.spMd }, children: [
17333
- hasWorkspaces && /* @__PURE__ */ jsx34(
17483
+ /* @__PURE__ */ jsxs32("div", { className: "flex items-center justify-end w-full", style: { gap: T19.spMd }, children: [
17484
+ hasWorkspaces && /* @__PURE__ */ jsx35(
17334
17485
  ScButton19,
17335
17486
  {
17336
17487
  text: "Back",
@@ -17339,7 +17490,7 @@ function WorkspacePicker({
17339
17490
  onClick: () => setCreating(false)
17340
17491
  }
17341
17492
  ),
17342
- /* @__PURE__ */ jsx34(
17493
+ /* @__PURE__ */ jsx35(
17343
17494
  ScButton19,
17344
17495
  {
17345
17496
  text: busy ? "Creating\u2026" : "Create workspace",
@@ -17350,8 +17501,8 @@ function WorkspacePicker({
17350
17501
  }
17351
17502
  )
17352
17503
  ] })
17353
- ] }) : !loading && !hasWorkspaces ? null : /* @__PURE__ */ jsxs31("div", { className: "flex flex-wrap items-center justify-between w-full", style: { gap: T19.spMd }, children: [
17354
- canCreate ? /* @__PURE__ */ jsx34(
17504
+ ] }) : !loading && !hasWorkspaces ? null : /* @__PURE__ */ jsxs32("div", { className: "flex flex-wrap items-center justify-between w-full", style: { gap: T19.spMd }, children: [
17505
+ canCreate ? /* @__PURE__ */ jsx35(
17355
17506
  ScButton19,
17356
17507
  {
17357
17508
  text: "Create a workspace",
@@ -17360,8 +17511,8 @@ function WorkspacePicker({
17360
17511
  state: loading || busy ? "disabled" : "default",
17361
17512
  onClick: loading || busy ? void 0 : () => setCreating(true)
17362
17513
  }
17363
- ) : /* @__PURE__ */ jsx34("span", {}),
17364
- /* @__PURE__ */ jsx34(
17514
+ ) : /* @__PURE__ */ jsx35("span", {}),
17515
+ /* @__PURE__ */ jsx35(
17365
17516
  ScButton19,
17366
17517
  {
17367
17518
  text: busy ? "Joining\u2026" : selected.size > 1 ? `Join ${selected.size} workspaces` : "Join workspace",
@@ -17380,7 +17531,7 @@ function WorkspacePicker({
17380
17531
  // src/organization-picker.tsx
17381
17532
  import { useEffect as useEffect21, useState as useState27 } from "react";
17382
17533
  import { ScButton as ScButton20, ScCheckbox as ScCheckbox2 } from "@streamoid/ui";
17383
- import { Fragment as Fragment18, jsx as jsx35, jsxs as jsxs32 } from "react/jsx-runtime";
17534
+ import { Fragment as Fragment18, jsx as jsx36, jsxs as jsxs33 } from "react/jsx-runtime";
17384
17535
  var T20 = {
17385
17536
  primary: "var(--alias-text---icons-primary)",
17386
17537
  muted: "var(--alias-text---icons-muted)",
@@ -17440,18 +17591,18 @@ function OrganizationPicker({
17440
17591
  const heading = choosing ? "Choose your organization" : "Create your organization";
17441
17592
  const subheading = choosing ? `${companyDomain ?? "Your company"} has more than one organization. Pick the ones to join as a member.` : publicDomain ? "Create an organization for your team. Or, if your team already uses Streamoid, ask them to invite you." : `Nobody from ${companyDomain ?? "your company"} has set up an organization you can join yet. Create one; you'll be its admin.`;
17442
17593
  const textStyle = { margin: 0, fontFamily: T20.font };
17443
- return /* @__PURE__ */ jsxs32(
17594
+ return /* @__PURE__ */ jsxs33(
17444
17595
  "div",
17445
17596
  {
17446
17597
  className: "flex flex-col w-full",
17447
17598
  style: { maxWidth: 520, gap: T20.sp5xl, fontFamily: T20.font },
17448
17599
  children: [
17449
- /* @__PURE__ */ jsxs32("div", { className: "flex flex-col", style: { gap: T20.spMd }, children: [
17450
- /* @__PURE__ */ jsx35("p", { style: { ...textStyle, color: T20.primary, fontSize: T20.fsXl, fontWeight: 600, lineHeight: T20.lhXl }, children: heading }),
17451
- /* @__PURE__ */ jsx35("p", { style: { ...textStyle, color: T20.muted, fontSize: T20.fsSm, lineHeight: T20.lhSm }, children: loading ? "Looking up your company\u2026" : subheading })
17600
+ /* @__PURE__ */ jsxs33("div", { className: "flex flex-col", style: { gap: T20.spMd }, children: [
17601
+ /* @__PURE__ */ jsx36("p", { style: { ...textStyle, color: T20.primary, fontSize: T20.fsXl, fontWeight: 600, lineHeight: T20.lhXl }, children: heading }),
17602
+ /* @__PURE__ */ jsx36("p", { style: { ...textStyle, color: T20.muted, fontSize: T20.fsSm, lineHeight: T20.lhSm }, children: loading ? "Looking up your company\u2026" : subheading })
17452
17603
  ] }),
17453
- !loading && choosing && /* @__PURE__ */ jsxs32(Fragment18, { children: [
17454
- /* @__PURE__ */ jsx35(
17604
+ !loading && choosing && /* @__PURE__ */ jsxs33(Fragment18, { children: [
17605
+ /* @__PURE__ */ jsx36(
17455
17606
  "div",
17456
17607
  {
17457
17608
  role: "group",
@@ -17464,7 +17615,7 @@ function OrganizationPicker({
17464
17615
  },
17465
17616
  children: organizations.map((org, index) => {
17466
17617
  const checked = selected.has(org._id);
17467
- return /* @__PURE__ */ jsxs32(
17618
+ return /* @__PURE__ */ jsxs33(
17468
17619
  "div",
17469
17620
  {
17470
17621
  role: "checkbox",
@@ -17485,11 +17636,11 @@ function OrganizationPicker({
17485
17636
  }
17486
17637
  },
17487
17638
  children: [
17488
- /* @__PURE__ */ jsx35(ScCheckbox2, { checked }),
17489
- /* @__PURE__ */ jsx35(ProfileAvatar, { name: org.name, profileImage: org.imageUrl, size: 32, borderRadius: T20.rLg }),
17490
- /* @__PURE__ */ jsxs32("div", { className: "flex flex-col min-w-0", children: [
17491
- /* @__PURE__ */ jsx35("span", { className: "truncate", style: { color: T20.primary, fontSize: T20.fsSm, fontWeight: 500, lineHeight: T20.lhSm }, children: org.name }),
17492
- org.domain && /* @__PURE__ */ jsx35("span", { className: "truncate", style: { color: T20.muted, fontSize: T20.fsXs, lineHeight: T20.lhXs }, children: org.domain })
17639
+ /* @__PURE__ */ jsx36(ScCheckbox2, { checked }),
17640
+ /* @__PURE__ */ jsx36(ProfileAvatar, { name: org.name, profileImage: org.imageUrl, size: 32, borderRadius: T20.rLg }),
17641
+ /* @__PURE__ */ jsxs33("div", { className: "flex flex-col min-w-0", children: [
17642
+ /* @__PURE__ */ jsx36("span", { className: "truncate", style: { color: T20.primary, fontSize: T20.fsSm, fontWeight: 500, lineHeight: T20.lhSm }, children: org.name }),
17643
+ org.domain && /* @__PURE__ */ jsx36("span", { className: "truncate", style: { color: T20.muted, fontSize: T20.fsXs, lineHeight: T20.lhXs }, children: org.domain })
17493
17644
  ] })
17494
17645
  ]
17495
17646
  },
@@ -17498,7 +17649,7 @@ function OrganizationPicker({
17498
17649
  })
17499
17650
  }
17500
17651
  ),
17501
- /* @__PURE__ */ jsx35("div", { className: "flex items-center justify-end w-full", children: /* @__PURE__ */ jsx35(
17652
+ /* @__PURE__ */ jsx36("div", { className: "flex items-center justify-end w-full", children: /* @__PURE__ */ jsx36(
17502
17653
  ScButton20,
17503
17654
  {
17504
17655
  text: busy ? "Joining\u2026" : selected.size > 1 ? `Join ${selected.size} organizations` : "Join organization",
@@ -17509,10 +17660,10 @@ function OrganizationPicker({
17509
17660
  }
17510
17661
  ) })
17511
17662
  ] }),
17512
- !loading && !choosing && /* @__PURE__ */ jsxs32("div", { className: "flex flex-col w-full", style: { gap: T20.sp3xl }, children: [
17513
- /* @__PURE__ */ jsxs32("div", { className: "flex flex-col w-full", style: { gap: T20.spMd }, children: [
17514
- /* @__PURE__ */ jsx35("label", { htmlFor: "organization-picker-name", style: { color: T20.tertiary, fontSize: T20.fsSm, lineHeight: T20.lhSm }, children: "Organization name" }),
17515
- /* @__PURE__ */ jsx35(
17663
+ !loading && !choosing && /* @__PURE__ */ jsxs33("div", { className: "flex flex-col w-full", style: { gap: T20.sp3xl }, children: [
17664
+ /* @__PURE__ */ jsxs33("div", { className: "flex flex-col w-full", style: { gap: T20.spMd }, children: [
17665
+ /* @__PURE__ */ jsx36("label", { htmlFor: "organization-picker-name", style: { color: T20.tertiary, fontSize: T20.fsSm, lineHeight: T20.lhSm }, children: "Organization name" }),
17666
+ /* @__PURE__ */ jsx36(
17516
17667
  "input",
17517
17668
  {
17518
17669
  id: "organization-picker-name",
@@ -17534,14 +17685,14 @@ function OrganizationPicker({
17534
17685
  }
17535
17686
  )
17536
17687
  ] }),
17537
- !publicDomain && /* @__PURE__ */ jsxs32("div", { className: "flex flex-col w-full", style: { gap: T20.spMd }, children: [
17538
- /* @__PURE__ */ jsx35("span", { style: { color: T20.tertiary, fontSize: T20.fsSm, lineHeight: T20.lhSm }, children: "Who can join" }),
17539
- /* @__PURE__ */ jsx35("div", { role: "radiogroup", className: "flex w-full", style: { gap: T20.spMd }, children: [
17688
+ !publicDomain && /* @__PURE__ */ jsxs33("div", { className: "flex flex-col w-full", style: { gap: T20.spMd }, children: [
17689
+ /* @__PURE__ */ jsx36("span", { style: { color: T20.tertiary, fontSize: T20.fsSm, lineHeight: T20.lhSm }, children: "Who can join" }),
17690
+ /* @__PURE__ */ jsx36("div", { role: "radiogroup", className: "flex w-full", style: { gap: T20.spMd }, children: [
17540
17691
  ["shared", "Shared"],
17541
17692
  ["private", "Private"]
17542
17693
  ].map(([value, label]) => {
17543
17694
  const active = type === value;
17544
- return /* @__PURE__ */ jsx35(
17695
+ return /* @__PURE__ */ jsx36(
17545
17696
  "div",
17546
17697
  {
17547
17698
  role: "radio",
@@ -17560,12 +17711,12 @@ function OrganizationPicker({
17560
17711
  borderRadius: T20.r3xl,
17561
17712
  border: `1px solid ${active ? T20.primary : T20.borderSubtle}`
17562
17713
  },
17563
- children: /* @__PURE__ */ jsx35("span", { style: { color: T20.primary, fontSize: T20.fsSm, lineHeight: T20.lhSm, fontWeight: active ? 600 : 400 }, children: label })
17714
+ children: /* @__PURE__ */ jsx36("span", { style: { color: T20.primary, fontSize: T20.fsSm, lineHeight: T20.lhSm, fontWeight: active ? 600 : 400 }, children: label })
17564
17715
  },
17565
17716
  value
17566
17717
  );
17567
17718
  }) }),
17568
- /* @__PURE__ */ jsx35(
17719
+ /* @__PURE__ */ jsx36(
17569
17720
  "span",
17570
17721
  {
17571
17722
  "data-testid": "organization-visibility-message",
@@ -17575,7 +17726,7 @@ function OrganizationPicker({
17575
17726
  }
17576
17727
  )
17577
17728
  ] }),
17578
- /* @__PURE__ */ jsx35("div", { className: "flex items-center justify-end w-full", children: /* @__PURE__ */ jsx35(
17729
+ /* @__PURE__ */ jsx36("div", { className: "flex items-center justify-end w-full", children: /* @__PURE__ */ jsx36(
17579
17730
  ScButton20,
17580
17731
  {
17581
17732
  text: busy ? "Creating\u2026" : "Create organization",
@@ -17683,18 +17834,18 @@ var app_settings_page_default = {
17683
17834
  };
17684
17835
 
17685
17836
  // src/app-settings-page.tsx
17686
- import { Fragment as Fragment19, jsx as jsx36, jsxs as jsxs33 } from "react/jsx-runtime";
17837
+ import { Fragment as Fragment19, jsx as jsx37, jsxs as jsxs34 } from "react/jsx-runtime";
17687
17838
  function AppSettingsHeader({ administrationHref, onOpenAdministration, onClose }) {
17688
- return /* @__PURE__ */ jsxs33("header", { className: app_settings_page_default.header, children: [
17689
- /* @__PURE__ */ jsx36("h1", { children: "App settings" }),
17690
- /* @__PURE__ */ jsxs33("div", { className: app_settings_page_default.actions, children: [
17691
- /* @__PURE__ */ jsx36("a", { href: administrationHref, onClick: (event) => {
17839
+ return /* @__PURE__ */ jsxs34("header", { className: app_settings_page_default.header, children: [
17840
+ /* @__PURE__ */ jsx37("h1", { children: "App settings" }),
17841
+ /* @__PURE__ */ jsxs34("div", { className: app_settings_page_default.actions, children: [
17842
+ /* @__PURE__ */ jsx37("a", { href: administrationHref, onClick: (event) => {
17692
17843
  if (onOpenAdministration && !event.metaKey && !event.ctrlKey && !event.shiftKey && !event.altKey && event.button === 0) {
17693
17844
  event.preventDefault();
17694
17845
  onOpenAdministration();
17695
17846
  }
17696
17847
  }, children: "Account and workspace settings" }),
17697
- onClose ? /* @__PURE__ */ jsx36("button", { type: "button", className: app_settings_page_default.close, "aria-label": "Close App settings", onClick: onClose, children: /* @__PURE__ */ jsx36(SiconX, { size: 20, "aria-hidden": "true" }) }) : null
17848
+ onClose ? /* @__PURE__ */ jsx37("button", { type: "button", className: app_settings_page_default.close, "aria-label": "Close App settings", onClick: onClose, children: /* @__PURE__ */ jsx37(SiconX, { size: 20, "aria-hidden": "true" }) }) : null
17698
17849
  ] })
17699
17850
  ] });
17700
17851
  }
@@ -17706,45 +17857,45 @@ function AppSettingsPage({
17706
17857
  emptyDescription = "Account, workspace and organization settings are available above.",
17707
17858
  children
17708
17859
  }) {
17709
- return /* @__PURE__ */ jsxs33("div", { className: app_settings_page_default.page, children: [
17710
- /* @__PURE__ */ jsx36(AppSettingsHeader, { administrationHref, onOpenAdministration, onClose }),
17711
- children ?? /* @__PURE__ */ jsxs33("section", { className: app_settings_page_default.empty, "aria-label": "App settings empty state", children: [
17712
- /* @__PURE__ */ jsx36("h2", { children: emptyTitle }),
17713
- /* @__PURE__ */ jsx36("p", { children: emptyDescription })
17860
+ return /* @__PURE__ */ jsxs34("div", { className: app_settings_page_default.page, children: [
17861
+ /* @__PURE__ */ jsx37(AppSettingsHeader, { administrationHref, onOpenAdministration, onClose }),
17862
+ children ?? /* @__PURE__ */ jsxs34("section", { className: app_settings_page_default.empty, "aria-label": "App settings empty state", children: [
17863
+ /* @__PURE__ */ jsx37("h2", { children: emptyTitle }),
17864
+ /* @__PURE__ */ jsx37("p", { children: emptyDescription })
17714
17865
  ] })
17715
17866
  ] });
17716
17867
  }
17717
17868
  function AppSettingsSection({ title, action, children }) {
17718
- return /* @__PURE__ */ jsxs33("section", { className: app_settings_page_default.section, "aria-label": title, children: [
17719
- /* @__PURE__ */ jsxs33("div", { className: app_settings_page_default.sectionHeader, children: [
17720
- /* @__PURE__ */ jsx36("h2", { children: title }),
17721
- action ? /* @__PURE__ */ jsx36("div", { className: app_settings_page_default.sectionAction, children: action }) : null
17869
+ return /* @__PURE__ */ jsxs34("section", { className: app_settings_page_default.section, "aria-label": title, children: [
17870
+ /* @__PURE__ */ jsxs34("div", { className: app_settings_page_default.sectionHeader, children: [
17871
+ /* @__PURE__ */ jsx37("h2", { children: title }),
17872
+ action ? /* @__PURE__ */ jsx37("div", { className: app_settings_page_default.sectionAction, children: action }) : null
17722
17873
  ] }),
17723
- /* @__PURE__ */ jsx36("div", { children })
17874
+ /* @__PURE__ */ jsx37("div", { children })
17724
17875
  ] });
17725
17876
  }
17726
17877
  function AppSettingsRow({ title, description, summary, href, onClick, disabled, disabledReason, ariaLabel, trailing }) {
17727
17878
  const reasonId = useId2();
17728
- const content = /* @__PURE__ */ jsxs33(Fragment19, { children: [
17729
- /* @__PURE__ */ jsxs33("span", { className: app_settings_page_default.rowCopy, children: [
17730
- /* @__PURE__ */ jsx36("span", { className: app_settings_page_default.rowTitle, children: title }),
17731
- description ? /* @__PURE__ */ jsx36("span", { className: app_settings_page_default.rowDescription, children: description }) : null
17879
+ const content = /* @__PURE__ */ jsxs34(Fragment19, { children: [
17880
+ /* @__PURE__ */ jsxs34("span", { className: app_settings_page_default.rowCopy, children: [
17881
+ /* @__PURE__ */ jsx37("span", { className: app_settings_page_default.rowTitle, children: title }),
17882
+ description ? /* @__PURE__ */ jsx37("span", { className: app_settings_page_default.rowDescription, children: description }) : null
17732
17883
  ] }),
17733
- summary || trailing || href || onClick ? /* @__PURE__ */ jsxs33("span", { className: app_settings_page_default.rowEnd, children: [
17884
+ summary || trailing || href || onClick ? /* @__PURE__ */ jsxs34("span", { className: app_settings_page_default.rowEnd, children: [
17734
17885
  summary,
17735
- trailing ?? (!disabled && (href || onClick) ? /* @__PURE__ */ jsx36(SiconArrowRight2, { size: 18, "aria-hidden": "true" }) : null)
17886
+ trailing ?? (!disabled && (href || onClick) ? /* @__PURE__ */ jsx37(SiconArrowRight2, { size: 18, "aria-hidden": "true" }) : null)
17736
17887
  ] }) : null,
17737
- disabledReason ? /* @__PURE__ */ jsx36("span", { className: app_settings_page_default.srOnly, id: reasonId, children: disabledReason }) : null
17888
+ disabledReason ? /* @__PURE__ */ jsx37("span", { className: app_settings_page_default.srOnly, id: reasonId, children: disabledReason }) : null
17738
17889
  ] });
17739
17890
  const props = { className: app_settings_page_default.row, "aria-label": ariaLabel, "aria-describedby": disabledReason ? reasonId : void 0 };
17740
- if (href && !disabled) return /* @__PURE__ */ jsx36("a", { ...props, href, onClick: (event) => {
17891
+ if (href && !disabled) return /* @__PURE__ */ jsx37("a", { ...props, href, onClick: (event) => {
17741
17892
  if (onClick && !event.metaKey && !event.ctrlKey && !event.shiftKey && !event.altKey && event.button === 0) {
17742
17893
  event.preventDefault();
17743
17894
  onClick();
17744
17895
  }
17745
17896
  }, children: content });
17746
- if (onClick || disabled) return /* @__PURE__ */ jsx36("button", { ...props, type: "button", disabled, onClick, children: content });
17747
- return /* @__PURE__ */ jsx36("div", { ...props, children: content });
17897
+ if (onClick || disabled) return /* @__PURE__ */ jsx37("button", { ...props, type: "button", disabled, onClick, children: content });
17898
+ return /* @__PURE__ */ jsx37("div", { ...props, children: content });
17748
17899
  }
17749
17900
  export {
17750
17901
  APP_KEYS,
@@ -17768,6 +17919,7 @@ export {
17768
17919
  ExportDateModal,
17769
17920
  INITIAL_USAGE_LOGS_STATE,
17770
17921
  InviteUpdateModal,
17922
+ MOCK_REFERRED_USERS,
17771
17923
  MemberCreditLimitModal,
17772
17924
  MemberListFrame,
17773
17925
  MemberListToolbar,
@@ -17783,6 +17935,7 @@ export {
17783
17935
  ProfileAvatar,
17784
17936
  ProfileTab,
17785
17937
  REMOVE_REASON_MAX_LENGTH,
17938
+ ReferralHistoryView,
17786
17939
  ReferralTab,
17787
17940
  RemovePoolMemberModal,
17788
17941
  SCOPE_LABELS,
@@ -17859,7 +18012,9 @@ export {
17859
18012
  productsForCountry,
17860
18013
  readSettingsCaller,
17861
18014
  referralCodeOf,
18015
+ referralCountLabel,
17862
18016
  referralLink,
18017
+ referralSignupDate,
17863
18018
  rememberSettingsCaller,
17864
18019
  resolveSettingsTabFromPath,
17865
18020
  roundCredits,
@@ -17867,6 +18022,7 @@ export {
17867
18022
  sharedPoolBannerText,
17868
18023
  sharedPoolEndsText,
17869
18024
  sliceUsageLogsPage,
18025
+ sortReferredUsers,
17870
18026
  sponsoredCreditsText,
17871
18027
  toCsv,
17872
18028
  toLocalDateInput,