forkit-connect 0.1.14 → 0.1.16
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 +239 -143
- package/package.json +1 -1
package/dist/launcher.js
CHANGED
|
@@ -1807,11 +1807,12 @@ function renderLauncherHtml(launcherToken) {
|
|
|
1807
1807
|
|
|
1808
1808
|
.quick-review-chip:focus-visible,
|
|
1809
1809
|
.quick-review-primary:focus-visible,
|
|
1810
|
-
.quick-review-
|
|
1810
|
+
.quick-review-secondary:focus-visible,
|
|
1811
|
+
.quick-review-danger:focus-visible,
|
|
1812
|
+
.quick-review-tertiary:focus-visible,
|
|
1811
1813
|
.review-mode-button:focus-visible,
|
|
1812
1814
|
.quick-review-field select:focus-visible,
|
|
1813
|
-
.discovery-review-field select:focus-visible
|
|
1814
|
-
.quick-review-options-menu button:focus-visible {
|
|
1815
|
+
.discovery-review-field select:focus-visible {
|
|
1815
1816
|
outline: 2px solid rgba(157, 238, 245, 0.72);
|
|
1816
1817
|
outline-offset: 2px;
|
|
1817
1818
|
}
|
|
@@ -1888,13 +1889,13 @@ function renderLauncherHtml(launcherToken) {
|
|
|
1888
1889
|
color: #f7efe4;
|
|
1889
1890
|
}
|
|
1890
1891
|
|
|
1891
|
-
.
|
|
1892
|
+
.review-summary-grid {
|
|
1892
1893
|
display: grid;
|
|
1893
1894
|
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
1894
1895
|
gap: 10px;
|
|
1895
1896
|
}
|
|
1896
1897
|
|
|
1897
|
-
.
|
|
1898
|
+
.review-summary-pill {
|
|
1898
1899
|
display: grid;
|
|
1899
1900
|
gap: 4px;
|
|
1900
1901
|
padding: 11px 12px;
|
|
@@ -1903,7 +1904,7 @@ function renderLauncherHtml(launcherToken) {
|
|
|
1903
1904
|
background: rgba(255,255,255,0.045);
|
|
1904
1905
|
}
|
|
1905
1906
|
|
|
1906
|
-
.
|
|
1907
|
+
.review-summary-label {
|
|
1907
1908
|
font-size: 0.68rem;
|
|
1908
1909
|
text-transform: uppercase;
|
|
1909
1910
|
letter-spacing: 0.12em;
|
|
@@ -1911,13 +1912,50 @@ function renderLauncherHtml(launcherToken) {
|
|
|
1911
1912
|
color: rgba(241, 235, 223, 0.55);
|
|
1912
1913
|
}
|
|
1913
1914
|
|
|
1914
|
-
.
|
|
1915
|
+
.review-summary-value {
|
|
1915
1916
|
font-size: 0.86rem;
|
|
1916
1917
|
line-height: 1.35;
|
|
1917
1918
|
color: #fff7ea;
|
|
1918
1919
|
font-weight: 600;
|
|
1919
1920
|
}
|
|
1920
1921
|
|
|
1922
|
+
.review-recommendation-card {
|
|
1923
|
+
display: grid;
|
|
1924
|
+
gap: 6px;
|
|
1925
|
+
padding: 14px 15px;
|
|
1926
|
+
border-radius: 18px;
|
|
1927
|
+
border: 1px solid rgba(157, 238, 245, 0.14);
|
|
1928
|
+
background:
|
|
1929
|
+
linear-gradient(180deg, rgba(39, 51, 69, 0.52), rgba(22, 18, 47, 0.72)),
|
|
1930
|
+
radial-gradient(circle at top right, rgba(244, 147, 85, 0.12), transparent 52%);
|
|
1931
|
+
box-shadow: inset 0 1px 0 rgba(255,255,255,0.06);
|
|
1932
|
+
}
|
|
1933
|
+
|
|
1934
|
+
.review-recommendation-kicker {
|
|
1935
|
+
margin: 0;
|
|
1936
|
+
font-size: 0.68rem;
|
|
1937
|
+
text-transform: uppercase;
|
|
1938
|
+
letter-spacing: 0.13em;
|
|
1939
|
+
font-weight: 700;
|
|
1940
|
+
color: rgba(157, 238, 245, 0.82);
|
|
1941
|
+
}
|
|
1942
|
+
|
|
1943
|
+
.review-recommendation-title {
|
|
1944
|
+
margin: 0;
|
|
1945
|
+
font-family: "Sora", sans-serif;
|
|
1946
|
+
font-size: 1rem;
|
|
1947
|
+
line-height: 1.2;
|
|
1948
|
+
color: #fff8ef;
|
|
1949
|
+
font-weight: 700;
|
|
1950
|
+
}
|
|
1951
|
+
|
|
1952
|
+
.review-recommendation-detail {
|
|
1953
|
+
margin: 0;
|
|
1954
|
+
font-size: 0.86rem;
|
|
1955
|
+
line-height: 1.5;
|
|
1956
|
+
color: rgba(241, 235, 223, 0.74);
|
|
1957
|
+
}
|
|
1958
|
+
|
|
1921
1959
|
.quick-review-topline {
|
|
1922
1960
|
display: flex;
|
|
1923
1961
|
align-items: flex-start;
|
|
@@ -2090,9 +2128,8 @@ function renderLauncherHtml(launcherToken) {
|
|
|
2090
2128
|
|
|
2091
2129
|
.quick-review-actions {
|
|
2092
2130
|
display: grid;
|
|
2093
|
-
grid-template-columns: minmax(0, 1fr) auto;
|
|
2094
2131
|
gap: 10px;
|
|
2095
|
-
align-items:
|
|
2132
|
+
align-items: stretch;
|
|
2096
2133
|
}
|
|
2097
2134
|
|
|
2098
2135
|
.review-resolution-actions {
|
|
@@ -2101,6 +2138,35 @@ function renderLauncherHtml(launcherToken) {
|
|
|
2101
2138
|
gap: 10px;
|
|
2102
2139
|
}
|
|
2103
2140
|
|
|
2141
|
+
.review-resolution-shell {
|
|
2142
|
+
display: grid;
|
|
2143
|
+
gap: 10px;
|
|
2144
|
+
padding: 12px 13px;
|
|
2145
|
+
border-radius: 16px;
|
|
2146
|
+
border: 1px solid rgba(244, 147, 85, 0.16);
|
|
2147
|
+
background: rgba(255,255,255,0.038);
|
|
2148
|
+
}
|
|
2149
|
+
|
|
2150
|
+
.review-resolution-shell[hidden] {
|
|
2151
|
+
display: none;
|
|
2152
|
+
}
|
|
2153
|
+
|
|
2154
|
+
.review-resolution-kicker {
|
|
2155
|
+
margin: 0;
|
|
2156
|
+
font-size: 0.68rem;
|
|
2157
|
+
text-transform: uppercase;
|
|
2158
|
+
letter-spacing: 0.12em;
|
|
2159
|
+
font-weight: 700;
|
|
2160
|
+
color: rgba(255, 211, 178, 0.82);
|
|
2161
|
+
}
|
|
2162
|
+
|
|
2163
|
+
.review-resolution-copy {
|
|
2164
|
+
margin: 0;
|
|
2165
|
+
font-size: 0.84rem;
|
|
2166
|
+
line-height: 1.45;
|
|
2167
|
+
color: rgba(241, 235, 223, 0.72);
|
|
2168
|
+
}
|
|
2169
|
+
|
|
2104
2170
|
.review-resolution-actions[hidden] {
|
|
2105
2171
|
display: none;
|
|
2106
2172
|
}
|
|
@@ -2137,94 +2203,66 @@ function renderLauncherHtml(launcherToken) {
|
|
|
2137
2203
|
}
|
|
2138
2204
|
|
|
2139
2205
|
.quick-review-primary:disabled,
|
|
2140
|
-
.quick-review-
|
|
2206
|
+
.quick-review-secondary:disabled,
|
|
2207
|
+
.quick-review-danger:disabled,
|
|
2208
|
+
.quick-review-tertiary:disabled {
|
|
2141
2209
|
opacity: 0.45;
|
|
2142
2210
|
cursor: not-allowed;
|
|
2143
2211
|
}
|
|
2144
2212
|
|
|
2145
|
-
.quick-review-
|
|
2146
|
-
position: relative;
|
|
2147
|
-
}
|
|
2148
|
-
|
|
2149
|
-
.quick-review-options-button {
|
|
2150
|
-
min-height: 52px;
|
|
2151
|
-
padding: 0 16px;
|
|
2152
|
-
border-radius: 16px;
|
|
2153
|
-
border: 1px solid rgba(241, 235, 223, 0.14);
|
|
2154
|
-
background: rgba(255,255,255,0.05);
|
|
2155
|
-
color: #fff7ea;
|
|
2156
|
-
font-size: 0.92rem;
|
|
2157
|
-
font-weight: 600;
|
|
2158
|
-
cursor: pointer;
|
|
2159
|
-
min-width: 122px;
|
|
2160
|
-
transition: background 160ms ease, border-color 160ms ease;
|
|
2161
|
-
}
|
|
2162
|
-
|
|
2163
|
-
.quick-review-options-button:hover {
|
|
2164
|
-
background: rgba(255,255,255,0.08);
|
|
2165
|
-
border-color: rgba(157, 238, 245, 0.22);
|
|
2166
|
-
}
|
|
2167
|
-
|
|
2168
|
-
.quick-review-options-menu {
|
|
2169
|
-
position: absolute;
|
|
2170
|
-
top: calc(100% + 8px);
|
|
2171
|
-
right: 0;
|
|
2172
|
-
min-width: 214px;
|
|
2213
|
+
.quick-review-secondary-actions {
|
|
2173
2214
|
display: grid;
|
|
2174
|
-
|
|
2175
|
-
|
|
2176
|
-
border-radius: 18px;
|
|
2177
|
-
border: 1px solid rgba(241, 235, 223, 0.12);
|
|
2178
|
-
background: rgba(19, 20, 31, 0.98);
|
|
2179
|
-
box-shadow: 0 22px 44px rgba(7, 10, 24, 0.38);
|
|
2215
|
+
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
2216
|
+
gap: 10px;
|
|
2180
2217
|
}
|
|
2181
2218
|
|
|
2182
|
-
.quick-review-
|
|
2219
|
+
.quick-review-secondary,
|
|
2220
|
+
.quick-review-danger,
|
|
2221
|
+
.quick-review-tertiary {
|
|
2183
2222
|
min-height: 46px;
|
|
2184
|
-
border-radius:
|
|
2185
|
-
border: 1px solid transparent;
|
|
2186
|
-
background: rgba(255,255,255,0.04);
|
|
2187
|
-
color: #f7efe4;
|
|
2188
|
-
text-align: left;
|
|
2189
|
-
padding: 10px 12px;
|
|
2223
|
+
border-radius: 14px;
|
|
2190
2224
|
font-size: 0.9rem;
|
|
2191
2225
|
font-weight: 600;
|
|
2192
2226
|
cursor: pointer;
|
|
2227
|
+
transition: background 160ms ease, border-color 160ms ease, color 160ms ease;
|
|
2193
2228
|
}
|
|
2194
2229
|
|
|
2195
|
-
.quick-review-
|
|
2196
|
-
|
|
2197
|
-
|
|
2198
|
-
|
|
2199
|
-
|
|
2200
|
-
display: grid;
|
|
2201
|
-
gap: 2px;
|
|
2230
|
+
.quick-review-secondary {
|
|
2231
|
+
border: 1px solid rgba(241, 235, 223, 0.14);
|
|
2232
|
+
background: rgba(255,255,255,0.05);
|
|
2233
|
+
color: #fff7ea;
|
|
2234
|
+
padding: 0 14px;
|
|
2202
2235
|
}
|
|
2203
2236
|
|
|
2204
|
-
.quick-review-
|
|
2205
|
-
|
|
2206
|
-
|
|
2207
|
-
color: #fff7ea;
|
|
2208
|
-
font-weight: 600;
|
|
2237
|
+
.quick-review-secondary:hover {
|
|
2238
|
+
background: rgba(255,255,255,0.08);
|
|
2239
|
+
border-color: rgba(157, 238, 245, 0.22);
|
|
2209
2240
|
}
|
|
2210
2241
|
|
|
2211
|
-
.quick-review-
|
|
2212
|
-
|
|
2213
|
-
|
|
2214
|
-
color:
|
|
2242
|
+
.quick-review-danger {
|
|
2243
|
+
border: 1px solid rgba(255, 125, 149, 0.22);
|
|
2244
|
+
background: rgba(109, 29, 46, 0.24);
|
|
2245
|
+
color: #ffd4da;
|
|
2246
|
+
padding: 0 14px;
|
|
2215
2247
|
}
|
|
2216
2248
|
|
|
2217
|
-
.quick-review-
|
|
2218
|
-
background: rgba(
|
|
2219
|
-
border-color: rgba(
|
|
2249
|
+
.quick-review-danger:hover {
|
|
2250
|
+
background: rgba(124, 33, 52, 0.34);
|
|
2251
|
+
border-color: rgba(255, 160, 180, 0.32);
|
|
2220
2252
|
}
|
|
2221
2253
|
|
|
2222
|
-
.quick-review-
|
|
2223
|
-
|
|
2254
|
+
.quick-review-tertiary {
|
|
2255
|
+
min-height: 0;
|
|
2256
|
+
border: none;
|
|
2257
|
+
background: transparent;
|
|
2258
|
+
color: rgba(157, 238, 245, 0.92);
|
|
2259
|
+
justify-self: start;
|
|
2260
|
+
padding: 0;
|
|
2224
2261
|
}
|
|
2225
2262
|
|
|
2226
|
-
.quick-review-
|
|
2227
|
-
color: #
|
|
2263
|
+
.quick-review-tertiary:hover {
|
|
2264
|
+
color: #bdf6fb;
|
|
2265
|
+
text-decoration: underline;
|
|
2228
2266
|
}
|
|
2229
2267
|
|
|
2230
2268
|
.status-chip {
|
|
@@ -6516,16 +6554,21 @@ function renderLauncherHtml(launcherToken) {
|
|
|
6516
6554
|
</div>
|
|
6517
6555
|
<p class="quick-review-meta" id="quick-review-meta">Open Connect to approve or defer this item.</p>
|
|
6518
6556
|
<p class="quick-review-detail" id="quick-review-detail">Nothing is registered automatically.</p>
|
|
6519
|
-
<div class="
|
|
6520
|
-
<div class="
|
|
6521
|
-
<span class="
|
|
6522
|
-
<span class="
|
|
6557
|
+
<div class="review-summary-grid">
|
|
6558
|
+
<div class="review-summary-pill">
|
|
6559
|
+
<span class="review-summary-label">Action</span>
|
|
6560
|
+
<span class="review-summary-value" id="quick-review-action-summary">Register on this account now</span>
|
|
6523
6561
|
</div>
|
|
6524
|
-
<div class="
|
|
6525
|
-
<span class="
|
|
6526
|
-
<span class="
|
|
6562
|
+
<div class="review-summary-pill">
|
|
6563
|
+
<span class="review-summary-label">Scope</span>
|
|
6564
|
+
<span class="review-summary-value" id="quick-review-scope-summary">Account scope</span>
|
|
6527
6565
|
</div>
|
|
6528
6566
|
</div>
|
|
6567
|
+
<div class="review-recommendation-card">
|
|
6568
|
+
<p class="review-recommendation-kicker">Recommended next step</p>
|
|
6569
|
+
<h4 class="review-recommendation-title" id="quick-review-recommendation-title">Register solo</h4>
|
|
6570
|
+
<p class="review-recommendation-detail" id="quick-review-recommendation-detail">Register this item on your account now.</p>
|
|
6571
|
+
</div>
|
|
6529
6572
|
<div class="quick-review-status" id="quick-review-status">Waiting for review.</div>
|
|
6530
6573
|
<div class="quick-review-scope" id="quick-review-scope" hidden>
|
|
6531
6574
|
<div class="review-mode-group" id="quick-review-mode">
|
|
@@ -6548,33 +6591,19 @@ function renderLauncherHtml(launcherToken) {
|
|
|
6548
6591
|
</div>
|
|
6549
6592
|
<div class="quick-review-actions">
|
|
6550
6593
|
<button class="quick-review-primary" id="quick-review-primary" type="button" disabled>Approve and register</button>
|
|
6551
|
-
<div class="quick-review-
|
|
6552
|
-
<button class="quick-review-
|
|
6553
|
-
<
|
|
6554
|
-
<button id="quick-review-open-discovery" type="button">
|
|
6555
|
-
<span class="quick-review-menu-copy">
|
|
6556
|
-
<span class="quick-review-menu-label">Open full review</span>
|
|
6557
|
-
<span class="quick-review-menu-meta">See the full local discovery context.</span>
|
|
6558
|
-
</span>
|
|
6559
|
-
</button>
|
|
6560
|
-
<button id="quick-review-defer" type="button">
|
|
6561
|
-
<span class="quick-review-menu-copy">
|
|
6562
|
-
<span class="quick-review-menu-label">Not now (24h)</span>
|
|
6563
|
-
<span class="quick-review-menu-meta">Hide this prompt until tomorrow.</span>
|
|
6564
|
-
</span>
|
|
6565
|
-
</button>
|
|
6566
|
-
<button id="quick-review-ignore" class="danger" type="button">
|
|
6567
|
-
<span class="quick-review-menu-copy">
|
|
6568
|
-
<span class="quick-review-menu-label">Deny on this device</span>
|
|
6569
|
-
<span class="quick-review-menu-meta">Keep it out of this device review queue.</span>
|
|
6570
|
-
</span>
|
|
6571
|
-
</button>
|
|
6572
|
-
</div>
|
|
6594
|
+
<div class="quick-review-secondary-actions">
|
|
6595
|
+
<button class="quick-review-secondary" id="quick-review-defer" type="button" disabled>Not now</button>
|
|
6596
|
+
<button class="quick-review-danger" id="quick-review-ignore" type="button" disabled>Deny on this device</button>
|
|
6573
6597
|
</div>
|
|
6598
|
+
<button class="quick-review-tertiary" id="quick-review-open-discovery" type="button" disabled>Open full review</button>
|
|
6574
6599
|
</div>
|
|
6575
|
-
<div class="review-resolution-
|
|
6576
|
-
<
|
|
6577
|
-
<
|
|
6600
|
+
<div class="review-resolution-shell" id="quick-review-resolution-shell" hidden>
|
|
6601
|
+
<p class="review-resolution-kicker">Recovery path</p>
|
|
6602
|
+
<p class="review-resolution-copy" id="quick-review-resolution-copy">Choose the safest next step when registration cannot finish here.</p>
|
|
6603
|
+
<div class="review-resolution-actions" id="quick-review-resolution" hidden>
|
|
6604
|
+
<button class="review-resolution-button" id="quick-review-resolution-primary" type="button" hidden></button>
|
|
6605
|
+
<button class="review-resolution-button" id="quick-review-resolution-secondary" type="button" hidden></button>
|
|
6606
|
+
</div>
|
|
6578
6607
|
</div>
|
|
6579
6608
|
</section>
|
|
6580
6609
|
</div>
|
|
@@ -6937,6 +6966,21 @@ function renderLauncherHtml(launcherToken) {
|
|
|
6937
6966
|
<h4 class="discovery-review-title" id="discovery-review-title">Select a discovery item</h4>
|
|
6938
6967
|
<p class="discovery-review-meta" id="discovery-review-meta">Choose a model, agent, or runtime to review it here.</p>
|
|
6939
6968
|
<p class="discovery-review-detail" id="discovery-review-detail">Registering creates or updates a Forkit Passport. Nothing is published automatically.</p>
|
|
6969
|
+
<div class="review-summary-grid">
|
|
6970
|
+
<div class="review-summary-pill">
|
|
6971
|
+
<span class="review-summary-label">Action</span>
|
|
6972
|
+
<span class="review-summary-value" id="discovery-review-action-summary">Select an item</span>
|
|
6973
|
+
</div>
|
|
6974
|
+
<div class="review-summary-pill">
|
|
6975
|
+
<span class="review-summary-label">Scope</span>
|
|
6976
|
+
<span class="review-summary-value" id="discovery-review-scope-summary">Review</span>
|
|
6977
|
+
</div>
|
|
6978
|
+
</div>
|
|
6979
|
+
<div class="review-recommendation-card">
|
|
6980
|
+
<p class="review-recommendation-kicker">Recommended next step</p>
|
|
6981
|
+
<h4 class="review-recommendation-title" id="discovery-review-recommendation-title">Select an item</h4>
|
|
6982
|
+
<p class="review-recommendation-detail" id="discovery-review-recommendation-detail">Connect will show the best next step after you choose a model, agent, or runtime.</p>
|
|
6983
|
+
</div>
|
|
6940
6984
|
<div class="discovery-review-status" id="discovery-review-status">Select an item to continue.</div>
|
|
6941
6985
|
<div class="discovery-review-scope" id="discovery-review-scope" hidden>
|
|
6942
6986
|
<div class="review-mode-group" id="discovery-review-mode">
|
|
@@ -6959,12 +7003,16 @@ function renderLauncherHtml(launcherToken) {
|
|
|
6959
7003
|
</div>
|
|
6960
7004
|
<div class="discovery-review-actions">
|
|
6961
7005
|
<button class="primary" id="discovery-review-primary" type="button" disabled>Review</button>
|
|
6962
|
-
<button class="secondary" id="discovery-review-defer" type="button" disabled>
|
|
7006
|
+
<button class="secondary" id="discovery-review-defer" type="button" disabled>Not now</button>
|
|
6963
7007
|
<button class="danger" id="discovery-review-ignore" type="button" disabled>Deny on this device</button>
|
|
6964
7008
|
</div>
|
|
6965
|
-
<div class="review-resolution-
|
|
6966
|
-
<
|
|
6967
|
-
<
|
|
7009
|
+
<div class="review-resolution-shell" id="discovery-review-resolution-shell" hidden>
|
|
7010
|
+
<p class="review-resolution-kicker">Recovery path</p>
|
|
7011
|
+
<p class="review-resolution-copy" id="discovery-review-resolution-copy">Choose the safest next step when registration cannot finish here.</p>
|
|
7012
|
+
<div class="review-resolution-actions" id="discovery-review-resolution" hidden>
|
|
7013
|
+
<button class="review-resolution-button" id="discovery-review-resolution-primary" type="button" hidden></button>
|
|
7014
|
+
<button class="review-resolution-button" id="discovery-review-resolution-secondary" type="button" hidden></button>
|
|
7015
|
+
</div>
|
|
6968
7016
|
</div>
|
|
6969
7017
|
</section>
|
|
6970
7018
|
|
|
@@ -7679,7 +7727,7 @@ function renderLauncherHtml(launcherToken) {
|
|
|
7679
7727
|
}
|
|
7680
7728
|
|
|
7681
7729
|
function resetReviewResolutionActions(prefix) {
|
|
7682
|
-
setReviewResolutionActions(prefix, []);
|
|
7730
|
+
setReviewResolutionActions(prefix, [], '');
|
|
7683
7731
|
}
|
|
7684
7732
|
|
|
7685
7733
|
function derivePassportResolutionQuery(item) {
|
|
@@ -7742,6 +7790,15 @@ function renderLauncherHtml(launcherToken) {
|
|
|
7742
7790
|
: 'Register this item on your account now';
|
|
7743
7791
|
}
|
|
7744
7792
|
|
|
7793
|
+
function updateReviewRecommendation(prefix, item, scopeMode) {
|
|
7794
|
+
const title = document.getElementById(prefix + '-recommendation-title');
|
|
7795
|
+
const detail = document.getElementById(prefix + '-recommendation-detail');
|
|
7796
|
+
if (!title || !detail) return;
|
|
7797
|
+
const effectiveScopeMode = scopeMode === 'workspace' ? 'workspace' : 'solo';
|
|
7798
|
+
title.textContent = getReviewPrimaryLabel(item, effectiveScopeMode);
|
|
7799
|
+
detail.textContent = getReviewActionSummary(item, effectiveScopeMode) + '.';
|
|
7800
|
+
}
|
|
7801
|
+
|
|
7745
7802
|
function getReviewDetailText(item) {
|
|
7746
7803
|
if (!item) return 'Review local metadata, then decide what happens next.';
|
|
7747
7804
|
if (item.kind === 'runtime') {
|
|
@@ -7797,16 +7854,32 @@ function renderLauncherHtml(launcherToken) {
|
|
|
7797
7854
|
: result && (result.code === 'WORKSPACE_PROJECT_BINDING_REQUIRED' || result.code === 'DRAFT_CREATION_NOT_ALLOWED_BY_BINDING')
|
|
7798
7855
|
? 'Scope required · choose workspace and project'
|
|
7799
7856
|
: null,
|
|
7857
|
+
resolutionCopy: nextActions.length
|
|
7858
|
+
? nextActions[0]
|
|
7859
|
+
: result && result.code === 'GOVERNED_PASSPORT_CAPACITY_REACHED'
|
|
7860
|
+
? 'Reuse an existing passport before creating another governed record.'
|
|
7861
|
+
: result && result.code === 'DRAFT_LIMIT_REACHED'
|
|
7862
|
+
? 'Use an existing passport or clear an older draft before continuing.'
|
|
7863
|
+
: result && result.code === 'SIMILAR_PASSPORT_EXISTS'
|
|
7864
|
+
? 'Open the matching passport instead of creating another record.'
|
|
7865
|
+
: result && (result.code === 'WORKSPACE_PROJECT_BINDING_REQUIRED' || result.code === 'DRAFT_CREATION_NOT_ALLOWED_BY_BINDING')
|
|
7866
|
+
? 'Set workspace and project scope before governed registration continues.'
|
|
7867
|
+
: null,
|
|
7800
7868
|
resolutionActions,
|
|
7801
7869
|
};
|
|
7802
7870
|
}
|
|
7803
7871
|
|
|
7804
|
-
function setReviewResolutionActions(prefix, actions) {
|
|
7872
|
+
function setReviewResolutionActions(prefix, actions, copy) {
|
|
7873
|
+
const shell = document.getElementById(prefix + '-resolution-shell');
|
|
7805
7874
|
const wrapper = document.getElementById(prefix + '-resolution');
|
|
7875
|
+
const detail = document.getElementById(prefix + '-resolution-copy');
|
|
7806
7876
|
const primary = document.getElementById(prefix + '-resolution-primary');
|
|
7807
7877
|
const secondary = document.getElementById(prefix + '-resolution-secondary');
|
|
7808
7878
|
if (!wrapper || !primary || !secondary) return;
|
|
7809
7879
|
const normalized = Array.isArray(actions) ? actions.slice(0, 2) : [];
|
|
7880
|
+
if (detail) {
|
|
7881
|
+
detail.textContent = copy || 'Choose the safest next step when registration cannot finish here.';
|
|
7882
|
+
}
|
|
7810
7883
|
[primary, secondary].forEach((button, index) => {
|
|
7811
7884
|
const action = normalized[index];
|
|
7812
7885
|
if (!action) {
|
|
@@ -7820,6 +7893,9 @@ function renderLauncherHtml(launcherToken) {
|
|
|
7820
7893
|
button.textContent = String(action.label || '').trim();
|
|
7821
7894
|
});
|
|
7822
7895
|
wrapper.hidden = normalized.length === 0;
|
|
7896
|
+
if (shell) {
|
|
7897
|
+
shell.hidden = normalized.length === 0;
|
|
7898
|
+
}
|
|
7823
7899
|
}
|
|
7824
7900
|
|
|
7825
7901
|
async function handleReviewResolutionAction(prefix, action) {
|
|
@@ -7885,14 +7961,6 @@ function renderLauncherHtml(launcherToken) {
|
|
|
7885
7961
|
}
|
|
7886
7962
|
}
|
|
7887
7963
|
|
|
7888
|
-
function setQuickReviewOptionsOpen(open) {
|
|
7889
|
-
const button = document.getElementById('quick-review-options');
|
|
7890
|
-
const menu = document.getElementById('quick-review-options-menu');
|
|
7891
|
-
if (!button || !menu) return;
|
|
7892
|
-
menu.hidden = !open;
|
|
7893
|
-
button.setAttribute('aria-expanded', open ? 'true' : 'false');
|
|
7894
|
-
}
|
|
7895
|
-
|
|
7896
7964
|
function setQuickReviewPanelOpen(open) {
|
|
7897
7965
|
const toggle = document.getElementById('quick-review-toggle');
|
|
7898
7966
|
const panel = document.getElementById('quick-review-panel');
|
|
@@ -7908,9 +7976,6 @@ function renderLauncherHtml(launcherToken) {
|
|
|
7908
7976
|
}
|
|
7909
7977
|
: {});
|
|
7910
7978
|
}
|
|
7911
|
-
if (!open) {
|
|
7912
|
-
setQuickReviewOptionsOpen(false);
|
|
7913
|
-
}
|
|
7914
7979
|
}
|
|
7915
7980
|
|
|
7916
7981
|
function updateQuickReviewScopeSummary(scopeMode) {
|
|
@@ -7952,6 +8017,7 @@ function renderLauncherHtml(launcherToken) {
|
|
|
7952
8017
|
}
|
|
7953
8018
|
if (item) {
|
|
7954
8019
|
setText('quick-review-action-summary', getReviewActionSummary(item, reviewScopeMode));
|
|
8020
|
+
updateReviewRecommendation('quick-review', item, reviewScopeMode);
|
|
7955
8021
|
}
|
|
7956
8022
|
updateQuickReviewScopeSummary(reviewScopeMode);
|
|
7957
8023
|
return reviewScopeMode;
|
|
@@ -8008,7 +8074,6 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8008
8074
|
const workspaceSelect = document.getElementById('quick-review-workspace');
|
|
8009
8075
|
const projectSelect = document.getElementById('quick-review-project');
|
|
8010
8076
|
const primaryButton = document.getElementById('quick-review-primary');
|
|
8011
|
-
const optionsButton = document.getElementById('quick-review-options');
|
|
8012
8077
|
const openDiscoveryButton = document.getElementById('quick-review-open-discovery');
|
|
8013
8078
|
const deferButton = document.getElementById('quick-review-defer');
|
|
8014
8079
|
const ignoreButton = document.getElementById('quick-review-ignore');
|
|
@@ -8025,7 +8090,12 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8025
8090
|
anchor.hidden = false;
|
|
8026
8091
|
setText('quick-review-count', String(total));
|
|
8027
8092
|
setText('quick-review-chip-title', item.name);
|
|
8028
|
-
setText(
|
|
8093
|
+
setText(
|
|
8094
|
+
'quick-review-chip-meta',
|
|
8095
|
+
total > 1
|
|
8096
|
+
? (getReviewPrimaryLabel(item, 'solo') + ' · ' + String(total) + ' items need review')
|
|
8097
|
+
: getReviewActionSummary(item, 'solo'),
|
|
8098
|
+
);
|
|
8029
8099
|
setText('quick-review-kicker', item.typeLabel || item.kind);
|
|
8030
8100
|
setText('quick-review-title', item.name);
|
|
8031
8101
|
setText('quick-review-badge', item.kind === 'runtime' ? 'Runtime' : item.kind === 'agent' ? 'Agent' : 'Model');
|
|
@@ -8039,21 +8109,21 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8039
8109
|
'quick-review-action-summary',
|
|
8040
8110
|
getReviewActionSummary(item, 'solo'),
|
|
8041
8111
|
);
|
|
8112
|
+
updateReviewRecommendation('quick-review', item, 'solo');
|
|
8042
8113
|
if (primaryButton) {
|
|
8043
8114
|
primaryButton.textContent = primaryLabel;
|
|
8044
8115
|
primaryButton.disabled = item.inboxGroup === 'ignored';
|
|
8045
8116
|
}
|
|
8046
|
-
if (optionsButton) {
|
|
8047
|
-
optionsButton.disabled = false;
|
|
8048
|
-
}
|
|
8049
8117
|
if (openDiscoveryButton) {
|
|
8050
|
-
openDiscoveryButton.
|
|
8118
|
+
openDiscoveryButton.disabled = false;
|
|
8051
8119
|
}
|
|
8052
8120
|
if (deferButton) {
|
|
8053
8121
|
deferButton.hidden = !canReviewDefer(item);
|
|
8122
|
+
deferButton.disabled = !canReviewDefer(item);
|
|
8054
8123
|
}
|
|
8055
8124
|
if (ignoreButton) {
|
|
8056
8125
|
ignoreButton.hidden = !canReviewIgnore(item);
|
|
8126
|
+
ignoreButton.disabled = !canReviewIgnore(item);
|
|
8057
8127
|
}
|
|
8058
8128
|
|
|
8059
8129
|
const showScopeChoice = canChooseReviewScope(item);
|
|
@@ -8062,6 +8132,7 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8062
8132
|
setReviewRegistrationMode('quick-review', 'solo');
|
|
8063
8133
|
quickReviewScopeCacheKey = null;
|
|
8064
8134
|
setText('quick-review-scope-summary', getPassiveReviewScopeSummary(item));
|
|
8135
|
+
updateReviewRecommendation('quick-review', item, 'solo');
|
|
8065
8136
|
return;
|
|
8066
8137
|
}
|
|
8067
8138
|
|
|
@@ -8161,7 +8232,7 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8161
8232
|
if (feedback.actionSummary) {
|
|
8162
8233
|
setText('quick-review-action-summary', feedback.actionSummary);
|
|
8163
8234
|
}
|
|
8164
|
-
setReviewResolutionActions('quick-review', feedback.resolutionActions || []);
|
|
8235
|
+
setReviewResolutionActions('quick-review', feedback.resolutionActions || [], feedback.resolutionCopy || feedback.actionSummary || feedback.message);
|
|
8165
8236
|
return;
|
|
8166
8237
|
}
|
|
8167
8238
|
resetReviewResolutionActions('quick-review');
|
|
@@ -8184,7 +8255,6 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8184
8255
|
setActivityMessage(result.message || 'Review deferred.', result.ok ? 'ok' : 'warn');
|
|
8185
8256
|
await refreshAll();
|
|
8186
8257
|
resetReviewResolutionActions('quick-review');
|
|
8187
|
-
setQuickReviewOptionsOpen(false);
|
|
8188
8258
|
}
|
|
8189
8259
|
|
|
8190
8260
|
async function submitQuickReviewIgnore() {
|
|
@@ -8201,7 +8271,6 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8201
8271
|
setActivityMessage(result.message || 'Item denied on this device.', result.ok ? 'ok' : 'warn');
|
|
8202
8272
|
await refreshAll();
|
|
8203
8273
|
resetReviewResolutionActions('quick-review');
|
|
8204
|
-
setQuickReviewOptionsOpen(false);
|
|
8205
8274
|
}
|
|
8206
8275
|
|
|
8207
8276
|
function setDiscoveryReviewButtons(config) {
|
|
@@ -8220,6 +8289,28 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8220
8289
|
}
|
|
8221
8290
|
}
|
|
8222
8291
|
|
|
8292
|
+
function updateDiscoveryReviewScopeSummary(scopeMode) {
|
|
8293
|
+
const workspaceSelect = document.getElementById('discovery-review-workspace');
|
|
8294
|
+
const projectSelect = document.getElementById('discovery-review-project');
|
|
8295
|
+
const workspaceId = workspaceSelect ? String(workspaceSelect.value || '').trim() : '';
|
|
8296
|
+
const projectId = projectSelect ? String(projectSelect.value || '').trim() : '';
|
|
8297
|
+
const workspaceLabel = readSelectedOptionLabel(workspaceSelect);
|
|
8298
|
+
const projectLabel = readSelectedOptionLabel(projectSelect);
|
|
8299
|
+
if (scopeMode !== 'workspace') {
|
|
8300
|
+
setText('discovery-review-scope-summary', 'Account scope');
|
|
8301
|
+
return;
|
|
8302
|
+
}
|
|
8303
|
+
if (!workspaceId) {
|
|
8304
|
+
setText('discovery-review-scope-summary', 'Choose governed workspace');
|
|
8305
|
+
return;
|
|
8306
|
+
}
|
|
8307
|
+
if (!projectId) {
|
|
8308
|
+
setText('discovery-review-scope-summary', workspaceLabel ? (workspaceLabel + ' · choose project') : 'Choose project');
|
|
8309
|
+
return;
|
|
8310
|
+
}
|
|
8311
|
+
setText('discovery-review-scope-summary', [workspaceLabel, projectLabel].filter(Boolean).join(' · ') || 'Governed project');
|
|
8312
|
+
}
|
|
8313
|
+
|
|
8223
8314
|
function syncDiscoveryReviewRegistrationMode(item, mode) {
|
|
8224
8315
|
const reviewScopeMode = setReviewRegistrationMode('discovery-review', mode);
|
|
8225
8316
|
const workspaceSelect = document.getElementById('discovery-review-workspace');
|
|
@@ -8237,7 +8328,10 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8237
8328
|
deferEnabled: canReviewDefer(item),
|
|
8238
8329
|
ignoreEnabled: canReviewIgnore(item),
|
|
8239
8330
|
});
|
|
8331
|
+
setText('discovery-review-action-summary', getReviewActionSummary(item, reviewScopeMode));
|
|
8332
|
+
updateReviewRecommendation('discovery-review', item, reviewScopeMode);
|
|
8240
8333
|
}
|
|
8334
|
+
updateDiscoveryReviewScopeSummary(reviewScopeMode);
|
|
8241
8335
|
return reviewScopeMode;
|
|
8242
8336
|
}
|
|
8243
8337
|
|
|
@@ -8253,6 +8347,7 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8253
8347
|
setScopeOptions(projectSelect, [{ id: '', label: 'Solo registration / no project' }], '');
|
|
8254
8348
|
if (primaryButton) primaryButton.disabled = false;
|
|
8255
8349
|
}
|
|
8350
|
+
updateDiscoveryReviewScopeSummary(scopeMode);
|
|
8256
8351
|
return;
|
|
8257
8352
|
}
|
|
8258
8353
|
setScopeOptions(projectSelect, [{ id: '', label: 'Loading projects...' }], '');
|
|
@@ -8272,12 +8367,14 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8272
8367
|
if (primaryButton) {
|
|
8273
8368
|
primaryButton.disabled = !projects.length;
|
|
8274
8369
|
}
|
|
8370
|
+
updateDiscoveryReviewScopeSummary(scopeMode);
|
|
8275
8371
|
} catch {
|
|
8276
8372
|
setScopeOptions(projectSelect, [{ id: '', label: 'Project list unavailable' }], '');
|
|
8277
8373
|
setDiscoveryReviewStatus('Project list is unavailable right now.', 'warn');
|
|
8278
8374
|
if (primaryButton) {
|
|
8279
8375
|
primaryButton.disabled = true;
|
|
8280
8376
|
}
|
|
8377
|
+
updateDiscoveryReviewScopeSummary(scopeMode);
|
|
8281
8378
|
}
|
|
8282
8379
|
}
|
|
8283
8380
|
|
|
@@ -8292,6 +8389,10 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8292
8389
|
setText('discovery-review-title', 'Select a discovery item');
|
|
8293
8390
|
setText('discovery-review-meta', 'Choose a model, agent, or runtime to review it here.');
|
|
8294
8391
|
setText('discovery-review-detail', 'Registering creates or updates a Forkit Passport. Nothing is published automatically.');
|
|
8392
|
+
setText('discovery-review-action-summary', 'Select an item');
|
|
8393
|
+
setText('discovery-review-scope-summary', 'Review');
|
|
8394
|
+
setText('discovery-review-recommendation-title', 'Select an item');
|
|
8395
|
+
setText('discovery-review-recommendation-detail', 'Connect will show the best next step after you choose a model, agent, or runtime.');
|
|
8295
8396
|
if (scopeWrap) scopeWrap.hidden = true;
|
|
8296
8397
|
setReviewRegistrationMode('discovery-review', 'solo');
|
|
8297
8398
|
setDiscoveryReviewStatus('Select an item to continue.', '');
|
|
@@ -8307,6 +8408,8 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8307
8408
|
setText('discovery-review-title', item.name);
|
|
8308
8409
|
setText('discovery-review-meta', item.subtitle + ' · ' + item.source);
|
|
8309
8410
|
setText('discovery-review-detail', getReviewDetailText(item));
|
|
8411
|
+
setText('discovery-review-action-summary', getReviewActionSummary(item, 'solo'));
|
|
8412
|
+
updateReviewRecommendation('discovery-review', item, 'solo');
|
|
8310
8413
|
setDiscoveryReviewStatus(item.statusLabel + (item.statusMeta ? ' · ' + item.statusMeta : ''), item.statusTone === 'muted' ? '' : item.statusTone);
|
|
8311
8414
|
resetReviewResolutionActions('discovery-review');
|
|
8312
8415
|
setDiscoveryReviewButtons({
|
|
@@ -8320,6 +8423,8 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8320
8423
|
if (scopeWrap) scopeWrap.hidden = true;
|
|
8321
8424
|
setReviewRegistrationMode('discovery-review', 'solo');
|
|
8322
8425
|
reviewScopeCacheKey = null;
|
|
8426
|
+
setText('discovery-review-scope-summary', getPassiveReviewScopeSummary(item));
|
|
8427
|
+
updateReviewRecommendation('discovery-review', item, 'solo');
|
|
8323
8428
|
return;
|
|
8324
8429
|
}
|
|
8325
8430
|
|
|
@@ -8413,7 +8518,7 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8413
8518
|
const feedback = formatLauncherActionFeedback(result, 'Registration failed.');
|
|
8414
8519
|
setDiscoveryReviewStatus(feedback.message, 'warn');
|
|
8415
8520
|
setActivityMessage(feedback.activity, 'warn');
|
|
8416
|
-
setReviewResolutionActions('discovery-review', feedback.resolutionActions || []);
|
|
8521
|
+
setReviewResolutionActions('discovery-review', feedback.resolutionActions || [], feedback.resolutionCopy || feedback.actionSummary || feedback.message);
|
|
8417
8522
|
return;
|
|
8418
8523
|
}
|
|
8419
8524
|
resetReviewResolutionActions('discovery-review');
|
|
@@ -8424,7 +8529,7 @@ function renderLauncherHtml(launcherToken) {
|
|
|
8424
8529
|
async function submitDiscoveryReviewDefer() {
|
|
8425
8530
|
const item = getSelectedDiscoveryItem();
|
|
8426
8531
|
if (!item || !canReviewDefer(item)) {
|
|
8427
|
-
setDiscoveryReviewStatus('
|
|
8532
|
+
setDiscoveryReviewStatus('Not now is not available for this item.', 'warn');
|
|
8428
8533
|
return;
|
|
8429
8534
|
}
|
|
8430
8535
|
const result = await postAction('/api/discovery/review/defer', 'Deferring this review...', {
|
|
@@ -10303,18 +10408,9 @@ function renderLauncherHtml(launcherToken) {
|
|
|
10303
10408
|
void handleReviewResolutionAction('quick-review', String(quickReviewResolutionSecondary.dataset.action || '').trim());
|
|
10304
10409
|
});
|
|
10305
10410
|
}
|
|
10306
|
-
const quickReviewOptionsButton = document.getElementById('quick-review-options');
|
|
10307
|
-
if (quickReviewOptionsButton) {
|
|
10308
|
-
quickReviewOptionsButton.addEventListener('click', (event) => {
|
|
10309
|
-
event.stopPropagation();
|
|
10310
|
-
const menu = document.getElementById('quick-review-options-menu');
|
|
10311
|
-
setQuickReviewOptionsOpen(Boolean(menu && menu.hidden));
|
|
10312
|
-
});
|
|
10313
|
-
}
|
|
10314
10411
|
const quickReviewOpenDiscovery = document.getElementById('quick-review-open-discovery');
|
|
10315
10412
|
if (quickReviewOpenDiscovery) {
|
|
10316
10413
|
quickReviewOpenDiscovery.addEventListener('click', () => {
|
|
10317
|
-
setQuickReviewOptionsOpen(false);
|
|
10318
10414
|
setQuickReviewPanelOpen(false);
|
|
10319
10415
|
setView('discovery');
|
|
10320
10416
|
renderDiscoveryRows();
|