forkit-connect 0.1.18 → 0.1.20
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/launcher.js +130 -62
- package/package.json +1 -1
package/dist/launcher.js
CHANGED
|
@@ -695,14 +695,14 @@ function buildDiscovery(service) {
|
|
|
695
695
|
}
|
|
696
696
|
else if (draftPending) {
|
|
697
697
|
statusLabel = 'Registration in progress';
|
|
698
|
-
statusMeta = '
|
|
698
|
+
statusMeta = 'Continue the existing private review before starting anything new.';
|
|
699
699
|
statusTone = 'warn';
|
|
700
700
|
actionLabel = 'Continue';
|
|
701
701
|
actionTone = 'accent';
|
|
702
702
|
}
|
|
703
703
|
else if (registrationState === 'private_draft_required') {
|
|
704
704
|
statusLabel = 'Finish privately first';
|
|
705
|
-
statusMeta = registrationGuidance ?? '
|
|
705
|
+
statusMeta = registrationGuidance ?? 'Complete one private review step before publishing.';
|
|
706
706
|
statusTone = 'warn';
|
|
707
707
|
actionLabel = 'Continue';
|
|
708
708
|
actionTone = 'accent';
|
|
@@ -1366,6 +1366,9 @@ function renderLauncherHtml(launcherToken) {
|
|
|
1366
1366
|
--launcher-accent-text: rgba(157, 238, 245, 0.92);
|
|
1367
1367
|
--launcher-warning-text: rgba(255, 211, 178, 0.9);
|
|
1368
1368
|
--launcher-shadow-strong: 0 28px 56px rgba(7, 10, 24, 0.42);
|
|
1369
|
+
--launcher-inbox-row-columns: 28px minmax(220px, 2.35fr) minmax(92px, 0.72fr) minmax(116px, 0.84fr) minmax(0, 1.08fr) 154px;
|
|
1370
|
+
--launcher-inbox-row-columns-compact: 28px minmax(0, 1.85fr) minmax(84px, 0.68fr) minmax(108px, 0.82fr) minmax(0, 0.98fr) 146px;
|
|
1371
|
+
--launcher-inbox-action-width: 154px;
|
|
1369
1372
|
--traffic-intensity: 32;
|
|
1370
1373
|
--traffic-speed: 12s;
|
|
1371
1374
|
}
|
|
@@ -1906,7 +1909,7 @@ function renderLauncherHtml(launcherToken) {
|
|
|
1906
1909
|
|
|
1907
1910
|
.quick-review-card {
|
|
1908
1911
|
display: grid;
|
|
1909
|
-
gap:
|
|
1912
|
+
gap: 10px;
|
|
1910
1913
|
padding: 18px;
|
|
1911
1914
|
border-radius: 26px;
|
|
1912
1915
|
border: 1px solid var(--launcher-border-strong);
|
|
@@ -1925,6 +1928,10 @@ function renderLauncherHtml(launcherToken) {
|
|
|
1925
1928
|
gap: 10px;
|
|
1926
1929
|
}
|
|
1927
1930
|
|
|
1931
|
+
.quick-review-summary-grid {
|
|
1932
|
+
display: none;
|
|
1933
|
+
}
|
|
1934
|
+
|
|
1928
1935
|
.review-summary-pill {
|
|
1929
1936
|
display: grid;
|
|
1930
1937
|
gap: 3px;
|
|
@@ -2031,17 +2038,18 @@ function renderLauncherHtml(launcherToken) {
|
|
|
2031
2038
|
|
|
2032
2039
|
.quick-review-meta {
|
|
2033
2040
|
margin: 0;
|
|
2034
|
-
font-size: 0.
|
|
2035
|
-
line-height: 1.
|
|
2036
|
-
color: var(--launcher-text-
|
|
2041
|
+
font-size: 0.84rem;
|
|
2042
|
+
line-height: 1.4;
|
|
2043
|
+
color: var(--launcher-text-primary);
|
|
2037
2044
|
letter-spacing: 0.01em;
|
|
2045
|
+
font-weight: 500;
|
|
2038
2046
|
}
|
|
2039
2047
|
|
|
2040
2048
|
.quick-review-detail {
|
|
2041
2049
|
margin: 0;
|
|
2042
|
-
font-size: 0.
|
|
2043
|
-
line-height: 1.
|
|
2044
|
-
color: var(--launcher-text-
|
|
2050
|
+
font-size: 0.8rem;
|
|
2051
|
+
line-height: 1.4;
|
|
2052
|
+
color: var(--launcher-text-muted);
|
|
2045
2053
|
}
|
|
2046
2054
|
|
|
2047
2055
|
.quick-review-detail[hidden] {
|
|
@@ -2050,12 +2058,13 @@ function renderLauncherHtml(launcherToken) {
|
|
|
2050
2058
|
|
|
2051
2059
|
.quick-review-status {
|
|
2052
2060
|
border-radius: 16px;
|
|
2053
|
-
padding:
|
|
2061
|
+
padding: 9px 12px;
|
|
2054
2062
|
border: 1px solid rgba(202, 188, 255, 0.12);
|
|
2055
2063
|
background: var(--launcher-surface-muted);
|
|
2056
|
-
color: var(--launcher-text-
|
|
2057
|
-
font-size: 0.
|
|
2058
|
-
line-height: 1.
|
|
2064
|
+
color: var(--launcher-text-primary);
|
|
2065
|
+
font-size: 0.8rem;
|
|
2066
|
+
line-height: 1.4;
|
|
2067
|
+
font-weight: 600;
|
|
2059
2068
|
}
|
|
2060
2069
|
|
|
2061
2070
|
.quick-review-status.ok {
|
|
@@ -4416,7 +4425,7 @@ function renderLauncherHtml(launcherToken) {
|
|
|
4416
4425
|
.discovery-rows-head {
|
|
4417
4426
|
margin-top: 14px;
|
|
4418
4427
|
display: grid;
|
|
4419
|
-
grid-template-columns:
|
|
4428
|
+
grid-template-columns: var(--launcher-inbox-row-columns);
|
|
4420
4429
|
gap: 16px;
|
|
4421
4430
|
padding: 0 14px;
|
|
4422
4431
|
font-size: 0.86rem;
|
|
@@ -4439,7 +4448,7 @@ function renderLauncherHtml(launcherToken) {
|
|
|
4439
4448
|
|
|
4440
4449
|
.discovery-item-row {
|
|
4441
4450
|
display: grid;
|
|
4442
|
-
grid-template-columns:
|
|
4451
|
+
grid-template-columns: var(--launcher-inbox-row-columns);
|
|
4443
4452
|
gap: 16px;
|
|
4444
4453
|
align-items: center;
|
|
4445
4454
|
min-width: 0;
|
|
@@ -4601,6 +4610,8 @@ function renderLauncherHtml(launcherToken) {
|
|
|
4601
4610
|
margin-top: 4px;
|
|
4602
4611
|
font-size: 0.84rem;
|
|
4603
4612
|
color: rgba(241, 235, 223, 0.62);
|
|
4613
|
+
line-height: 1.4;
|
|
4614
|
+
overflow-wrap: anywhere;
|
|
4604
4615
|
}
|
|
4605
4616
|
|
|
4606
4617
|
.discovery-type-pill {
|
|
@@ -4663,6 +4674,13 @@ function renderLauncherHtml(launcherToken) {
|
|
|
4663
4674
|
white-space: nowrap;
|
|
4664
4675
|
}
|
|
4665
4676
|
|
|
4677
|
+
.discovery-status-copy small {
|
|
4678
|
+
display: -webkit-box;
|
|
4679
|
+
-webkit-line-clamp: 2;
|
|
4680
|
+
-webkit-box-orient: vertical;
|
|
4681
|
+
overflow: hidden;
|
|
4682
|
+
}
|
|
4683
|
+
|
|
4666
4684
|
.discovery-status-dot.ok { background: #3fd08f; box-shadow: 0 0 0 5px rgba(63, 208, 143, 0.12); }
|
|
4667
4685
|
.discovery-status-dot.warn { background: #f59b52; box-shadow: 0 0 0 5px rgba(245, 155, 82, 0.12); }
|
|
4668
4686
|
.discovery-status-dot.error { background: #4fa9ff; box-shadow: 0 0 0 5px rgba(79, 169, 255, 0.12); }
|
|
@@ -4673,6 +4691,9 @@ function renderLauncherHtml(launcherToken) {
|
|
|
4673
4691
|
align-items: center;
|
|
4674
4692
|
justify-content: flex-end;
|
|
4675
4693
|
gap: 10px;
|
|
4694
|
+
width: var(--launcher-inbox-action-width);
|
|
4695
|
+
justify-self: end;
|
|
4696
|
+
flex: 0 0 auto;
|
|
4676
4697
|
}
|
|
4677
4698
|
|
|
4678
4699
|
.discovery-action-btn,
|
|
@@ -6357,7 +6378,8 @@ function renderLauncherHtml(launcherToken) {
|
|
|
6357
6378
|
.discovery-filter-wrap,
|
|
6358
6379
|
.discovery-search-wrap { flex: 1 1 0; }
|
|
6359
6380
|
.discovery-rows-head,
|
|
6360
|
-
.discovery-item-row { grid-template-columns:
|
|
6381
|
+
.discovery-item-row { grid-template-columns: var(--launcher-inbox-row-columns-compact); }
|
|
6382
|
+
.discovery-action-group { width: 146px; }
|
|
6361
6383
|
.passport-overview-grid { grid-template-columns: 1fr; }
|
|
6362
6384
|
.passport-stats { grid-template-columns: 1fr 1fr; }
|
|
6363
6385
|
.runtime-layout { grid-template-columns: 1fr; }
|
|
@@ -6643,16 +6665,6 @@ function renderLauncherHtml(launcherToken) {
|
|
|
6643
6665
|
</div>
|
|
6644
6666
|
<p class="quick-review-meta" id="quick-review-meta">Model · Local</p>
|
|
6645
6667
|
<p class="quick-review-detail" id="quick-review-detail" hidden>Nothing is registered automatically.</p>
|
|
6646
|
-
<div class="review-summary-grid">
|
|
6647
|
-
<div class="review-summary-pill">
|
|
6648
|
-
<span class="review-summary-label">Action</span>
|
|
6649
|
-
<span class="review-summary-value" id="quick-review-action-summary">Register on this account now</span>
|
|
6650
|
-
</div>
|
|
6651
|
-
<div class="review-summary-pill">
|
|
6652
|
-
<span class="review-summary-label">Scope</span>
|
|
6653
|
-
<span class="review-summary-value" id="quick-review-scope-summary">Account scope</span>
|
|
6654
|
-
</div>
|
|
6655
|
-
</div>
|
|
6656
6668
|
<div class="review-recommendation-card">
|
|
6657
6669
|
<p class="review-recommendation-kicker">Recommended next step</p>
|
|
6658
6670
|
<h4 class="review-recommendation-title" id="quick-review-recommendation-title">Register solo</h4>
|
|
@@ -7073,16 +7085,6 @@ function renderLauncherHtml(launcherToken) {
|
|
|
7073
7085
|
<h4 class="discovery-review-title" id="discovery-review-title">Select a discovery item</h4>
|
|
7074
7086
|
<p class="discovery-review-meta" id="discovery-review-meta">Choose a model, agent, or runtime to review it here.</p>
|
|
7075
7087
|
<p class="discovery-review-detail" id="discovery-review-detail">Registering creates or updates a Forkit Passport. Nothing is published automatically.</p>
|
|
7076
|
-
<div class="review-summary-grid">
|
|
7077
|
-
<div class="review-summary-pill">
|
|
7078
|
-
<span class="review-summary-label">Action</span>
|
|
7079
|
-
<span class="review-summary-value" id="discovery-review-action-summary">Select an item</span>
|
|
7080
|
-
</div>
|
|
7081
|
-
<div class="review-summary-pill">
|
|
7082
|
-
<span class="review-summary-label">Scope</span>
|
|
7083
|
-
<span class="review-summary-value" id="discovery-review-scope-summary">Review</span>
|
|
7084
|
-
</div>
|
|
7085
|
-
</div>
|
|
7086
7088
|
<div class="review-recommendation-card">
|
|
7087
7089
|
<p class="review-recommendation-kicker">Recommended next step</p>
|
|
7088
7090
|
<h4 class="review-recommendation-title" id="discovery-review-recommendation-title">Select an item</h4>
|
|
@@ -7939,10 +7941,10 @@ function renderLauncherHtml(launcherToken) {
|
|
|
7939
7941
|
: 'Open runtime review to confirm health and connected models.';
|
|
7940
7942
|
}
|
|
7941
7943
|
if (item.statusLabel === 'Registration in progress') {
|
|
7942
|
-
return '
|
|
7944
|
+
return '';
|
|
7943
7945
|
}
|
|
7944
7946
|
if (item.statusLabel === 'Finish privately first') {
|
|
7945
|
-
return '
|
|
7947
|
+
return '';
|
|
7946
7948
|
}
|
|
7947
7949
|
if (item.matchedPassportGaid && !item.passportGaid) {
|
|
7948
7950
|
return 'A matching passport already exists. Reuse it first.';
|
|
@@ -7956,14 +7958,62 @@ function renderLauncherHtml(launcherToken) {
|
|
|
7956
7958
|
return '';
|
|
7957
7959
|
}
|
|
7958
7960
|
|
|
7961
|
+
function getDiscoveryReviewDetailText(item) {
|
|
7962
|
+
if (!item) return 'Registering creates or updates a Forkit Passport. Nothing is published automatically.';
|
|
7963
|
+
if (item.kind === 'runtime') {
|
|
7964
|
+
return item.statusTone === 'error'
|
|
7965
|
+
? 'Open runtime review to fix health before linked registrations continue.'
|
|
7966
|
+
: '';
|
|
7967
|
+
}
|
|
7968
|
+
if (item.statusLabel === 'Registration in progress') {
|
|
7969
|
+
return '';
|
|
7970
|
+
}
|
|
7971
|
+
if (item.statusLabel === 'Finish privately first') {
|
|
7972
|
+
return '';
|
|
7973
|
+
}
|
|
7974
|
+
if (item.matchedPassportGaid && !item.passportGaid) {
|
|
7975
|
+
return '';
|
|
7976
|
+
}
|
|
7977
|
+
if (item.passportGaid) {
|
|
7978
|
+
return '';
|
|
7979
|
+
}
|
|
7980
|
+
if (item.actionLabel === 'Retry') {
|
|
7981
|
+
return 'Review the latest local metadata before retrying registration.';
|
|
7982
|
+
}
|
|
7983
|
+
return '';
|
|
7984
|
+
}
|
|
7985
|
+
|
|
7959
7986
|
function getQuickReviewStatusText(item) {
|
|
7960
7987
|
if (!item) return 'Waiting for review.';
|
|
7961
7988
|
const meta = typeof item.statusMeta === 'string' ? item.statusMeta.trim() : '';
|
|
7962
|
-
if (
|
|
7963
|
-
|
|
7964
|
-
|
|
7989
|
+
if (item.kind === 'runtime') {
|
|
7990
|
+
return meta || item.statusLabel;
|
|
7991
|
+
}
|
|
7992
|
+
if (item.statusLabel === 'Registration in progress') {
|
|
7993
|
+
return 'Continue the existing private review.';
|
|
7994
|
+
}
|
|
7995
|
+
if (item.statusLabel === 'Finish privately first') {
|
|
7996
|
+
return 'Private review is required before publishing.';
|
|
7997
|
+
}
|
|
7998
|
+
if (item.matchedPassportGaid && !item.passportGaid) {
|
|
7999
|
+
return 'A matching passport is ready to reuse.';
|
|
8000
|
+
}
|
|
8001
|
+
if (item.passportGaid) {
|
|
8002
|
+
return 'Passport already linked on Forkit.dev.';
|
|
8003
|
+
}
|
|
8004
|
+
if (item.actionLabel === 'Retry') {
|
|
8005
|
+
return 'Retry registration after the required fix is complete.';
|
|
7965
8006
|
}
|
|
7966
|
-
return item.statusLabel;
|
|
8007
|
+
return meta || item.statusLabel;
|
|
8008
|
+
}
|
|
8009
|
+
|
|
8010
|
+
function getQuickReviewChipMeta(item, total) {
|
|
8011
|
+
if (!item) return 'Everything looks clear';
|
|
8012
|
+
const precise = getQuickReviewStatusText(item);
|
|
8013
|
+
if (total > 1) {
|
|
8014
|
+
return precise + ' · ' + String(total) + ' items in inbox';
|
|
8015
|
+
}
|
|
8016
|
+
return precise;
|
|
7967
8017
|
}
|
|
7968
8018
|
|
|
7969
8019
|
function formatLauncherActionFeedback(result, fallbackMessage) {
|
|
@@ -8234,9 +8284,7 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8234
8284
|
setText('quick-review-chip-title', item.name);
|
|
8235
8285
|
setText(
|
|
8236
8286
|
'quick-review-chip-meta',
|
|
8237
|
-
total
|
|
8238
|
-
? (getReviewPrimaryLabel(item, 'solo') + ' · ' + String(total) + ' items need review')
|
|
8239
|
-
: getReviewActionSummary(item, 'solo'),
|
|
8287
|
+
getQuickReviewChipMeta(item, total),
|
|
8240
8288
|
);
|
|
8241
8289
|
setText('quick-review-kicker', item.typeLabel || item.kind);
|
|
8242
8290
|
setText('quick-review-title', item.name);
|
|
@@ -8443,14 +8491,11 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8443
8491
|
return;
|
|
8444
8492
|
}
|
|
8445
8493
|
if (!workspaceId) {
|
|
8446
|
-
setText('discovery-review-scope-summary', 'Choose governed workspace');
|
|
8447
8494
|
return;
|
|
8448
8495
|
}
|
|
8449
8496
|
if (!projectId) {
|
|
8450
|
-
setText('discovery-review-scope-summary', workspaceLabel ? (workspaceLabel + ' · choose project') : 'Choose project');
|
|
8451
8497
|
return;
|
|
8452
8498
|
}
|
|
8453
|
-
setText('discovery-review-scope-summary', [workspaceLabel, projectLabel].filter(Boolean).join(' · ') || 'Governed project');
|
|
8454
8499
|
}
|
|
8455
8500
|
|
|
8456
8501
|
function syncDiscoveryReviewRegistrationMode(item, mode) {
|
|
@@ -8470,7 +8515,6 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8470
8515
|
deferEnabled: canReviewDefer(item),
|
|
8471
8516
|
ignoreEnabled: canReviewIgnore(item),
|
|
8472
8517
|
});
|
|
8473
|
-
setText('discovery-review-action-summary', getReviewActionSummary(item, reviewScopeMode));
|
|
8474
8518
|
updateReviewRecommendation('discovery-review', item, reviewScopeMode);
|
|
8475
8519
|
}
|
|
8476
8520
|
updateDiscoveryReviewScopeSummary(reviewScopeMode);
|
|
@@ -8531,8 +8575,6 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8531
8575
|
setText('discovery-review-title', 'Select a discovery item');
|
|
8532
8576
|
setText('discovery-review-meta', 'Choose a model, agent, or runtime to review it here.');
|
|
8533
8577
|
setText('discovery-review-detail', 'Registering creates or updates a Forkit Passport. Nothing is published automatically.');
|
|
8534
|
-
setText('discovery-review-action-summary', 'Select an item');
|
|
8535
|
-
setText('discovery-review-scope-summary', 'Review');
|
|
8536
8578
|
setText('discovery-review-recommendation-title', 'Select an item');
|
|
8537
8579
|
setText('discovery-review-recommendation-detail', 'Connect will show the best next step after you choose a model, agent, or runtime.');
|
|
8538
8580
|
if (scopeWrap) scopeWrap.hidden = true;
|
|
@@ -8549,10 +8591,9 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8549
8591
|
setText('discovery-review-kicker', typeLabel);
|
|
8550
8592
|
setText('discovery-review-title', item.name);
|
|
8551
8593
|
setText('discovery-review-meta', item.subtitle + ' · ' + item.source);
|
|
8552
|
-
|
|
8553
|
-
setText('discovery-review-action-summary', getReviewActionSummary(item, 'solo'));
|
|
8594
|
+
setOptionalDetail('discovery-review-detail', getDiscoveryReviewDetailText(item));
|
|
8554
8595
|
updateReviewRecommendation('discovery-review', item, 'solo');
|
|
8555
|
-
setDiscoveryReviewStatus(
|
|
8596
|
+
setDiscoveryReviewStatus(getQuickReviewStatusText(item), item.statusTone === 'muted' ? '' : item.statusTone);
|
|
8556
8597
|
resetReviewResolutionActions('discovery-review');
|
|
8557
8598
|
setDiscoveryReviewButtons({
|
|
8558
8599
|
primaryLabel: getReviewPrimaryLabel(item, 'solo'),
|
|
@@ -8565,7 +8606,6 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8565
8606
|
if (scopeWrap) scopeWrap.hidden = true;
|
|
8566
8607
|
setReviewRegistrationMode('discovery-review', 'solo');
|
|
8567
8608
|
reviewScopeCacheKey = null;
|
|
8568
|
-
setText('discovery-review-scope-summary', getPassiveReviewScopeSummary(item));
|
|
8569
8609
|
updateReviewRecommendation('discovery-review', item, 'solo');
|
|
8570
8610
|
return;
|
|
8571
8611
|
}
|
|
@@ -8707,16 +8747,44 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8707
8747
|
const normalizedUrl = String(avatarUrl || '').trim();
|
|
8708
8748
|
if (initialsEl) initialsEl.textContent = initials || 'FC';
|
|
8709
8749
|
if (!root || !image) return;
|
|
8710
|
-
|
|
8711
|
-
|
|
8712
|
-
|
|
8713
|
-
if (initialsEl) initialsEl.hidden = true;
|
|
8714
|
-
root.classList.add('has-image');
|
|
8715
|
-
} else {
|
|
8716
|
-
image.removeAttribute('src');
|
|
8750
|
+
image.alt = initials ? (initials + ' profile photo') : 'Forkit Connect profile photo';
|
|
8751
|
+
|
|
8752
|
+
const showInitials = () => {
|
|
8717
8753
|
image.hidden = true;
|
|
8754
|
+
image.removeAttribute('src');
|
|
8755
|
+
image.removeAttribute('data-avatar-url');
|
|
8718
8756
|
if (initialsEl) initialsEl.hidden = false;
|
|
8719
8757
|
root.classList.remove('has-image');
|
|
8758
|
+
};
|
|
8759
|
+
|
|
8760
|
+
const showPhoto = () => {
|
|
8761
|
+
image.hidden = false;
|
|
8762
|
+
if (initialsEl) initialsEl.hidden = true;
|
|
8763
|
+
root.classList.add('has-image');
|
|
8764
|
+
};
|
|
8765
|
+
|
|
8766
|
+
if (!normalizedUrl) {
|
|
8767
|
+
image.onload = null;
|
|
8768
|
+
image.onerror = null;
|
|
8769
|
+
showInitials();
|
|
8770
|
+
return;
|
|
8771
|
+
}
|
|
8772
|
+
|
|
8773
|
+
image.onload = () => {
|
|
8774
|
+
if (image.getAttribute('data-avatar-url') !== normalizedUrl) return;
|
|
8775
|
+
showPhoto();
|
|
8776
|
+
};
|
|
8777
|
+
image.onerror = () => {
|
|
8778
|
+
if (image.getAttribute('data-avatar-url') !== normalizedUrl) return;
|
|
8779
|
+
showInitials();
|
|
8780
|
+
};
|
|
8781
|
+
image.setAttribute('data-avatar-url', normalizedUrl);
|
|
8782
|
+
image.hidden = true;
|
|
8783
|
+
if (initialsEl) initialsEl.hidden = false;
|
|
8784
|
+
root.classList.remove('has-image');
|
|
8785
|
+
image.setAttribute('src', normalizedUrl);
|
|
8786
|
+
if (image.complete && image.naturalWidth > 0) {
|
|
8787
|
+
showPhoto();
|
|
8720
8788
|
}
|
|
8721
8789
|
}
|
|
8722
8790
|
|