@kya-os/consent 0.1.48 → 0.1.49
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/bundle/inline.d.ts +1 -0
- package/dist/bundle/inline.d.ts.map +1 -1
- package/dist/bundle/inline.js +5 -4
- package/dist/bundle/inline.js.map +1 -1
- package/dist/bundle/shell.d.ts +4 -0
- package/dist/bundle/shell.d.ts.map +1 -1
- package/dist/bundle/shell.js +7 -3
- package/dist/bundle/shell.js.map +1 -1
- package/dist/cjs/bundle/inline.js +4 -4
- package/dist/cjs/bundle/inline.js.map +1 -1
- package/dist/cjs/bundle/shell.js +7 -3
- package/dist/cjs/bundle/shell.js.map +1 -1
- package/dist/cjs/components/consent-capabilities-screen.js +35 -16
- package/dist/cjs/components/consent-capabilities-screen.js.map +1 -1
- package/dist/cjs/components/consent-revocation-notice.js +14 -6
- package/dist/cjs/components/consent-revocation-notice.js.map +1 -1
- package/dist/cjs/components/mcp-consent.js +122 -16
- package/dist/cjs/components/mcp-consent.js.map +1 -1
- package/dist/cjs/copy/tokens.js +2 -0
- package/dist/cjs/copy/tokens.js.map +1 -1
- package/dist/cjs/mcp-app/inline.js +2 -2
- package/dist/cjs/mcp-app/inline.js.map +1 -1
- package/dist/cjs/schemas/api.schemas.js +1 -0
- package/dist/cjs/schemas/api.schemas.js.map +1 -1
- package/dist/components/consent-capabilities-screen.d.ts +1 -0
- package/dist/components/consent-capabilities-screen.d.ts.map +1 -1
- package/dist/components/consent-capabilities-screen.js +35 -16
- package/dist/components/consent-capabilities-screen.js.map +1 -1
- package/dist/components/consent-revocation-notice.d.ts +2 -1
- package/dist/components/consent-revocation-notice.d.ts.map +1 -1
- package/dist/components/consent-revocation-notice.js +14 -6
- package/dist/components/consent-revocation-notice.js.map +1 -1
- package/dist/components/mcp-consent.d.ts +8 -0
- package/dist/components/mcp-consent.d.ts.map +1 -1
- package/dist/components/mcp-consent.js +122 -16
- package/dist/components/mcp-consent.js.map +1 -1
- package/dist/consent.js +153 -33
- package/dist/consent.min.js +114 -53
- package/dist/copy/tokens.d.ts +2 -0
- package/dist/copy/tokens.d.ts.map +1 -1
- package/dist/copy/tokens.js +2 -0
- package/dist/copy/tokens.js.map +1 -1
- package/dist/mcp-app/index.d.ts +1 -0
- package/dist/mcp-app/index.js +1 -0
- package/dist/mcp-app/inline.d.ts +1 -0
- package/dist/mcp-app/inline.d.ts.map +1 -1
- package/dist/mcp-app/inline.js +3 -2
- package/dist/mcp-app/inline.js.map +1 -1
- package/dist/mcp-app/types.d.ts +1 -0
- package/dist/mcp-app/types.js +1 -0
- package/dist/schemas/api.schemas.d.ts +5 -0
- package/dist/schemas/api.schemas.d.ts.map +1 -1
- package/dist/schemas/api.schemas.js +1 -0
- package/dist/schemas/api.schemas.js.map +1 -1
- package/dist/types/api.types.d.ts +2 -0
- package/dist/types/api.types.d.ts.map +1 -1
- package/package.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inline.js","sourceRoot":"","sources":["../../../src/bundle/inline.ts"],"names":[],"mappings":";AAAA;;;;;;;;GAQG;;;AAEH;;;GAGG;AACU,QAAA,cAAc,GAAW,
|
|
1
|
+
{"version":3,"file":"inline.js","sourceRoot":"","sources":["../../../src/bundle/inline.ts"],"names":[],"mappings":";AAAA;;;;;;;;GAQG;;;AAEH;;;GAGG;AACU,QAAA,cAAc,GAAW,i1gRAAi1gR,CAAC;AAEx3gR;;GAEG;AACU,QAAA,mBAAmB,GAAW,MAAM,CAAC;AAElD;;GAEG;AACU,QAAA,mBAAmB,GAAW,kBAAkB,CAAC;AAE9D;;;;;;;;;;;GAWG;AACU,QAAA,mBAAmB,GAAW,8BAA8B,CAAC"}
|
package/dist/cjs/bundle/shell.js
CHANGED
|
@@ -46,10 +46,10 @@ const inline_js_1 = require("./inline.js");
|
|
|
46
46
|
* ```
|
|
47
47
|
*/
|
|
48
48
|
function generateConsentShell(options) {
|
|
49
|
-
const { config, tool, scopes, agentDid, sessionId, projectId, serverUrl, oauthIdentity, bundlePath = inline_js_1.CONSENT_BUNDLE_PATH, pageTitle = "Permission Request", nonce, authMode, agentName, provider, csrfToken, credentialProviderType, credentialProvider, userDid, // CRITICAL: Bypasses KV consistency issues
|
|
49
|
+
const { config, tool, scopes, agentDid, sessionId, anchorSid, projectId, serverUrl, oauthIdentity, bundlePath = inline_js_1.CONSENT_BUNDLE_PATH, pageTitle = "Permission Request", nonce, authMode, agentName, provider, csrfToken, credentialProviderType, credentialProvider, userDid, // CRITICAL: Bypasses KV consistency issues
|
|
50
50
|
credentialUserEmail, // User email from credential provider
|
|
51
51
|
credentialProviderUserId, // Provider's user ID (e.g., customer ID)
|
|
52
|
-
oauthUrl, // Pre-built OAuth authorization URL
|
|
52
|
+
nativeScopeSelection, oauthUrl, // Pre-built OAuth authorization URL
|
|
53
53
|
authorizationType, // Dynamic authorization type from tool protection
|
|
54
54
|
oauthProviderType, // OAuth provider type from prior OAuth auth step
|
|
55
55
|
oauthProviderName, // OAuth provider name (e.g., 'custom', 'github')
|
|
@@ -209,6 +209,7 @@ function generateConsentShell(options) {
|
|
|
209
209
|
scopes='${(0, escape_js_1.escapeAttr)(scopesJson)}'
|
|
210
210
|
agent-did="${(0, escape_js_1.escapeAttr)(agentDid)}"
|
|
211
211
|
session-id="${(0, escape_js_1.escapeAttr)(sessionId)}"
|
|
212
|
+
${anchorSid ? `anchor-sid="${(0, escape_js_1.escapeAttr)(anchorSid)}"` : ""}
|
|
212
213
|
project-id="${(0, escape_js_1.escapeAttr)(projectId)}"
|
|
213
214
|
server-url="${(0, escape_js_1.escapeAttr)(serverUrl)}"
|
|
214
215
|
${oauthJson ? `oauth-identity='${(0, escape_js_1.escapeAttr)(oauthJson)}'` : ""}
|
|
@@ -221,6 +222,7 @@ function generateConsentShell(options) {
|
|
|
221
222
|
${userDid ? `user-did="${(0, escape_js_1.escapeAttr)(userDid)}"` : ""}
|
|
222
223
|
${credentialUserEmail ? `credential-user-email="${(0, escape_js_1.escapeAttr)(credentialUserEmail)}"` : ""}
|
|
223
224
|
${credentialProviderUserId ? `credential-provider-user-id="${(0, escape_js_1.escapeAttr)(credentialProviderUserId)}"` : ""}
|
|
225
|
+
${nativeScopeSelection ? "native-scope-selection" : ""}
|
|
224
226
|
${oauthUrl ? `oauth-url="${(0, escape_js_1.escapeAttr)(oauthUrl)}"` : ""}
|
|
225
227
|
${authorizationType ? `authorization-type="${(0, escape_js_1.escapeAttr)(authorizationType)}"` : ""}
|
|
226
228
|
${oauthProviderType ? `oauth-provider-type="${(0, escape_js_1.escapeAttr)(oauthProviderType)}"` : ""}
|
|
@@ -261,6 +263,7 @@ function generateConsentShell(options) {
|
|
|
261
263
|
<input type="hidden" name="scopes" value="${(0, escape_js_1.escapeAttr)(scopesJson)}">
|
|
262
264
|
<input type="hidden" name="agent_did" value="${(0, escape_js_1.escapeAttr)(agentDid)}">
|
|
263
265
|
<input type="hidden" name="session_id" value="${(0, escape_js_1.escapeAttr)(sessionId)}">
|
|
266
|
+
${anchorSid ? `<input type="hidden" name="sid" value="${(0, escape_js_1.escapeAttr)(anchorSid)}">` : ""}
|
|
264
267
|
<input type="hidden" name="project_id" value="${(0, escape_js_1.escapeAttr)(projectId)}">
|
|
265
268
|
<input type="hidden" name="auth_mode" value="consent-only">
|
|
266
269
|
<input type="hidden" name="provider_type" value="none">
|
|
@@ -286,7 +289,7 @@ function generateConsentShell(options) {
|
|
|
286
289
|
* @param bundleSource - The bundled consent.js source code
|
|
287
290
|
*/
|
|
288
291
|
function generateInlineConsentShell(options, bundleSource) {
|
|
289
|
-
const { config, tool, scopes, agentDid, sessionId, projectId, serverUrl, oauthIdentity, pageTitle = "Permission Request", nonce, } = options;
|
|
292
|
+
const { config, tool, scopes, agentDid, sessionId, anchorSid, projectId, serverUrl, oauthIdentity, pageTitle = "Permission Request", nonce, } = options;
|
|
290
293
|
const configJson = JSON.stringify(config);
|
|
291
294
|
const scopesJson = JSON.stringify(scopes);
|
|
292
295
|
const oauthJson = oauthIdentity ? JSON.stringify(oauthIdentity) : null;
|
|
@@ -320,6 +323,7 @@ ${bundleSource}
|
|
|
320
323
|
scopes='${(0, escape_js_1.escapeAttr)(scopesJson)}'
|
|
321
324
|
agent-did="${(0, escape_js_1.escapeAttr)(agentDid)}"
|
|
322
325
|
session-id="${(0, escape_js_1.escapeAttr)(sessionId)}"
|
|
326
|
+
${anchorSid ? `anchor-sid="${(0, escape_js_1.escapeAttr)(anchorSid)}"` : ""}
|
|
323
327
|
project-id="${(0, escape_js_1.escapeAttr)(projectId)}"
|
|
324
328
|
server-url="${(0, escape_js_1.escapeAttr)(serverUrl)}"
|
|
325
329
|
${oauthJson ? `oauth-identity='${(0, escape_js_1.escapeAttr)(oauthJson)}'` : ""}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"shell.js","sourceRoot":"","sources":["../../../src/bundle/shell.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;
|
|
1
|
+
{"version":3,"file":"shell.js","sourceRoot":"","sources":["../../../src/bundle/shell.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;AA2JH,oDA4PC;AAgBD,gEA2DC;AAheD,qDAA+D;AAC/D,2CAAkD;AA8HlD;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,SAAgB,oBAAoB,CAAC,OAA4B;IAC/D,MAAM,EACJ,MAAM,EACN,IAAI,EACJ,MAAM,EACN,QAAQ,EACR,SAAS,EACT,SAAS,EACT,SAAS,EACT,SAAS,EACT,aAAa,EACb,UAAU,GAAG,+BAAmB,EAChC,SAAS,GAAG,oBAAoB,EAChC,KAAK,EACL,QAAQ,EACR,SAAS,EACT,QAAQ,EACR,SAAS,EACT,sBAAsB,EACtB,kBAAkB,EAClB,OAAO,EAAE,2CAA2C;IACpD,mBAAmB,EAAE,sCAAsC;IAC3D,wBAAwB,EAAE,yCAAyC;IACnE,oBAAoB,EACpB,QAAQ,EAAE,oCAAoC;IAC9C,i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C,MAAM,CAAC,CAAC;IAC1C,MAAM,UAAU,GAAG,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC;IAC1C,MAAM,SAAS,GAAG,aAAa,CAAC,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC;IACvE,MAAM,SAAS,GAAG,KAAK,CAAC,CAAC,CAAC,WAAW,IAAA,sBAAU,EAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC;IAE/D,OAAO;;;;;WAKE,IAAA,sBAAU,EAAC,SAAS,CAAC;yBACP,SAAS;EAChC,YAAY;;UAEJ,SAAS;;;;;;;;;;;;;;;cAeL,IAAA,sBAAU,EAAC,UAAU,CAAC;YACxB,IAAA,sBAAU,EAAC,IAAI,CAAC;cACd,IAAA,sBAAU,EAAC,UAAU,CAAC;iBACnB,IAAA,sBAAU,EAAC,QAAQ,CAAC;kBACnB,IAAA,sBAAU,EAAC,SAAS,CAAC;MACjC,SAAS,CAAC,CAAC,CAAC,eAAe,IAAA,sBAAU,EAAC,SAAS,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE;kBAC5C,IAAA,sBAAU,EAAC,SAAS,CAAC;kBACrB,IAAA,sBAAU,EAAC,SAAS,CAAC;MACjC,SAAS,CAAC,CAAC,CAAC,mBAAmB,IAAA,sBAAU,EAAC,SAAS,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE;;;QAG1D,CAAC;AACT,CAAC"}
|
|
@@ -45,6 +45,7 @@ let ConsentCapabilitiesScreen = class ConsentCapabilitiesScreen extends lit_1.Li
|
|
|
45
45
|
this.headlineVerb = "use";
|
|
46
46
|
this.revocationPath = "Account → Connected Agents";
|
|
47
47
|
this.inactivityDays = 90;
|
|
48
|
+
this.fixedExpiry = false;
|
|
48
49
|
this.theme = "light";
|
|
49
50
|
this.howItWorksUrl = "";
|
|
50
51
|
this.loading = false;
|
|
@@ -96,9 +97,12 @@ let ConsentCapabilitiesScreen = class ConsentCapabilitiesScreen extends lit_1.Li
|
|
|
96
97
|
if (this.loading || this.disabled || !(event instanceof CustomEvent))
|
|
97
98
|
return;
|
|
98
99
|
const detail = event.detail;
|
|
99
|
-
if (!detail ||
|
|
100
|
-
|
|
101
|
-
!("
|
|
100
|
+
if (!detail ||
|
|
101
|
+
typeof detail !== "object" ||
|
|
102
|
+
!("id" in detail) ||
|
|
103
|
+
typeof detail.id !== "string" ||
|
|
104
|
+
!("checked" in detail) ||
|
|
105
|
+
typeof detail.checked !== "boolean" ||
|
|
102
106
|
!this.capabilities.some((capability) => capability.id === detail.id))
|
|
103
107
|
return;
|
|
104
108
|
const next = new Set(this.selected);
|
|
@@ -160,8 +164,11 @@ let ConsentCapabilitiesScreen = class ConsentCapabilitiesScreen extends lit_1.Li
|
|
|
160
164
|
return `:host { ${(0, theme_js_1.themeToCssVariables)((0, theme_js_1.getConsentTheme)(this.theme))} }`;
|
|
161
165
|
}
|
|
162
166
|
get approvalDisabled() {
|
|
163
|
-
return this.disabled ||
|
|
164
|
-
|
|
167
|
+
return (this.disabled ||
|
|
168
|
+
this.allowDisabled ||
|
|
169
|
+
this.selected.size === 0 ||
|
|
170
|
+
(this.requireAll &&
|
|
171
|
+
this.capabilities.some((capability) => !this.selected.has(capability.id))));
|
|
165
172
|
}
|
|
166
173
|
compileCapabilityCedar(capability) {
|
|
167
174
|
const cedar = capability.cedar?.trim() || "";
|
|
@@ -198,7 +205,8 @@ let ConsentCapabilitiesScreen = class ConsentCapabilitiesScreen extends lit_1.Li
|
|
|
198
205
|
render() {
|
|
199
206
|
const tokens = tokens_js_1.CONSENT_COPY_TOKENS;
|
|
200
207
|
const agentName = this.agentMetadata?.name || "this agent";
|
|
201
|
-
const subhead = this.description ||
|
|
208
|
+
const subhead = this.description ||
|
|
209
|
+
(0, tokens_js_1.formatToken)(tokens.subhead.template, { Agent: agentName });
|
|
202
210
|
const sectionHeader = (0, tokens_js_1.formatToken)(tokens.section.capabilitiesHeader, {
|
|
203
211
|
Agent: agentName.toUpperCase(),
|
|
204
212
|
});
|
|
@@ -217,7 +225,9 @@ let ConsentCapabilitiesScreen = class ConsentCapabilitiesScreen extends lit_1.Li
|
|
|
217
225
|
logo-dev-token="${this.logoDevToken}"
|
|
218
226
|
></consent-connector-header>
|
|
219
227
|
<div class="card" part="card">
|
|
220
|
-
<span class="eyebrow" part="eyebrow"
|
|
228
|
+
<span class="eyebrow" part="eyebrow"
|
|
229
|
+
>${tokens.eyebrow.permissionRequest}</span
|
|
230
|
+
>
|
|
221
231
|
${this.renderHeadline()}
|
|
222
232
|
<p class="subhead" part="subhead">${subhead}</p>
|
|
223
233
|
<slot name="identity"></slot>
|
|
@@ -232,6 +242,7 @@ let ConsentCapabilitiesScreen = class ConsentCapabilitiesScreen extends lit_1.Li
|
|
|
232
242
|
connectedAt="${this.agentMetadata.connectedAt || ""}"
|
|
233
243
|
></consent-agent-header>`
|
|
234
244
|
: lit_1.nothing}
|
|
245
|
+
<slot name="agent-key"></slot>
|
|
235
246
|
<div part="permissions">
|
|
236
247
|
<div class="section-header">
|
|
237
248
|
<span>${sectionHeader}</span>
|
|
@@ -255,11 +266,14 @@ let ConsentCapabilitiesScreen = class ConsentCapabilitiesScreen extends lit_1.Li
|
|
|
255
266
|
</div>
|
|
256
267
|
<slot name="auth"></slot>
|
|
257
268
|
<slot name="details"></slot>
|
|
258
|
-
<slot name="notice"
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
269
|
+
<slot name="notice"
|
|
270
|
+
><consent-revocation-notice
|
|
271
|
+
revocationPath="${this.revocationPath}"
|
|
272
|
+
orgName="${this.orgName || "this site"}"
|
|
273
|
+
inactivityDays=${this.inactivityDays}
|
|
274
|
+
?fixed-expiry=${this.fixedExpiry}
|
|
275
|
+
></consent-revocation-notice
|
|
276
|
+
></slot>
|
|
263
277
|
<consent-action-bar
|
|
264
278
|
part="actions"
|
|
265
279
|
agentName="${agentName}"
|
|
@@ -272,10 +286,12 @@ let ConsentCapabilitiesScreen = class ConsentCapabilitiesScreen extends lit_1.Li
|
|
|
272
286
|
@consent-allow=${this.onAllow}
|
|
273
287
|
@consent-deny=${this.onDeny}
|
|
274
288
|
></consent-action-bar>
|
|
275
|
-
<slot name="footer"
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
289
|
+
<slot name="footer"
|
|
290
|
+
><consent-footer
|
|
291
|
+
theme="${this.theme}"
|
|
292
|
+
howItWorksUrl="${this.howItWorksUrl}"
|
|
293
|
+
></consent-footer
|
|
294
|
+
></slot>
|
|
279
295
|
</div>
|
|
280
296
|
`;
|
|
281
297
|
}
|
|
@@ -385,6 +401,9 @@ __decorate([
|
|
|
385
401
|
__decorate([
|
|
386
402
|
(0, decorators_js_1.property)({ type: Number })
|
|
387
403
|
], ConsentCapabilitiesScreen.prototype, "inactivityDays", void 0);
|
|
404
|
+
__decorate([
|
|
405
|
+
(0, decorators_js_1.property)({ type: Boolean, attribute: "fixed-expiry" })
|
|
406
|
+
], ConsentCapabilitiesScreen.prototype, "fixedExpiry", void 0);
|
|
388
407
|
__decorate([
|
|
389
408
|
(0, decorators_js_1.property)({ type: String })
|
|
390
409
|
], ConsentCapabilitiesScreen.prototype, "theme", void 0);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"consent-capabilities-screen.js","sourceRoot":"","sources":["../../../src/components/consent-capabilities-screen.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;GAgBG;;;;;;;;;AAEH,6BAAqD;AACrD,qDAAmE;AAEnE,iDAAqE;AACrE,iDAA0E;AAO1E,oDAA8D;AAC9D,yFAGkD;AAClD,kEAA6E;AAC7E,qCAAmC;AACnC,wCAAsC;AACtC,mCAAiC;AACjC,+BAA6B;AAC7B,0CAAwC;AACxC,yCAAuC;AAYhC,IAAM,yBAAyB,GAA/B,MAAM,yBAA0B,SAAQ,gBAAU;IAAlD;;QAGsB,iBAAY,GAA6B,EAAE,CAAC;QAG3C,YAAO,GAAG,EAAE,CAAC;QACb,iBAAY,GAAG,KAAK,CAAC;QACrB,mBAAc,GAAG,4BAA4B,CAAC;QAC9C,mBAAc,GAAG,EAAE,CAAC;
|
|
1
|
+
{"version":3,"file":"consent-capabilities-screen.js","sourceRoot":"","sources":["../../../src/components/consent-capabilities-screen.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;GAgBG;;;;;;;;;AAEH,6BAAqD;AACrD,qDAAmE;AAEnE,iDAAqE;AACrE,iDAA0E;AAO1E,oDAA8D;AAC9D,yFAGkD;AAClD,kEAA6E;AAC7E,qCAAmC;AACnC,wCAAsC;AACtC,mCAAiC;AACjC,+BAA6B;AAC7B,0CAAwC;AACxC,yCAAuC;AAYhC,IAAM,yBAAyB,GAA/B,MAAM,yBAA0B,SAAQ,gBAAU;IAAlD;;QAGsB,iBAAY,GAA6B,EAAE,CAAC;QAG3C,YAAO,GAAG,EAAE,CAAC;QACb,iBAAY,GAAG,KAAK,CAAC;QACrB,mBAAc,GAAG,4BAA4B,CAAC;QAC9C,mBAAc,GAAG,EAAE,CAAC;QACQ,gBAAW,GAAG,KAAK,CAAC;QAChD,UAAK,GAAiB,OAAO,CAAC;QACC,kBAAa,GAAG,EAAE,CAAC;QACjD,YAAO,GAAG,KAAK,CAAC;QAC7C,2DAA2D;QAC9B,aAAQ,GAAG,KAAK,CAAC;QAClB,gBAAW,GAAG,EAAE,CAAC;QACU,gBAAW,GAAG,EAAE,CAAC;QACjB,gBAAW,GAAG,EAAE,CAAC;QAExE;;;;WAIG;QAEH,gBAAW,GAAG,KAAK,CAAC;QAEpB;;;;WAIG;QACuD,kBAAa,GACrE,KAAK,CAAC;QAER;;;;WAIG;QACqD,iBAAY,GAAG,EAAE,CAAC;QAE1E;;;;WAIG;QACsD,iBAAY,GAAG,EAAE,CAAC;QAE3E;;;;WAIG;QACuD,kBAAa,GAAG,EAAE,CAAC;QAE7E,0EAA0E;QACnB,eAAU,GAAG,KAAK,CAAC;QAEzD,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AS,UAAU,CAAC,KAAa;IAC/B,OAAO,KAAK;SACT,OAAO,CAAC,IAAI,EAAE,OAAO,CAAC;SACtB,OAAO,CAAC,IAAI,EAAE,MAAM,CAAC;SACrB,OAAO,CAAC,IAAI,EAAE,MAAM,CAAC;SACrB,OAAO,CAAC,IAAI,EAAE,QAAQ,CAAC;SACvB,OAAO,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;AAC5B,CAAC"}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Consent Revocation Notice
|
|
4
4
|
*
|
|
5
5
|
* Clock-iconed footer block telling the user where they can revoke and that
|
|
6
|
-
* permissions
|
|
6
|
+
* permissions expire according to the applicable authorization policy.
|
|
7
7
|
*
|
|
8
8
|
* @module components/consent-revocation-notice
|
|
9
9
|
*/
|
|
@@ -24,13 +24,18 @@ let ConsentRevocationNotice = class ConsentRevocationNotice extends lit_1.LitEle
|
|
|
24
24
|
this.revocationPath = "Account → Connected Agents";
|
|
25
25
|
this.orgName = "this site";
|
|
26
26
|
this.inactivityDays = 90;
|
|
27
|
+
this.fixedExpiry = false;
|
|
27
28
|
}
|
|
28
29
|
render() {
|
|
29
30
|
const revoke = (0, tokens_js_1.formatToken)(tokens_js_1.CONSENT_COPY_TOKENS.footer.revocationTemplate, {
|
|
30
31
|
RevocationPath: this.revocationPath,
|
|
31
32
|
Org: this.orgName,
|
|
32
33
|
});
|
|
33
|
-
const
|
|
34
|
+
const expiry = this.fixedExpiry
|
|
35
|
+
? tokens_js_1.CONSENT_COPY_TOKENS.footer.fixedExpiryNotice
|
|
36
|
+
: (0, tokens_js_1.formatToken)(tokens_js_1.CONSENT_COPY_TOKENS.footer.inactivityTemplate, {
|
|
37
|
+
Days: this.inactivityDays,
|
|
38
|
+
});
|
|
34
39
|
return (0, lit_1.html) `
|
|
35
40
|
<svg
|
|
36
41
|
class="icon"
|
|
@@ -47,7 +52,7 @@ let ConsentRevocationNotice = class ConsentRevocationNotice extends lit_1.LitEle
|
|
|
47
52
|
</svg>
|
|
48
53
|
<div class="content">
|
|
49
54
|
<span>${revoke}</span>
|
|
50
|
-
<span>${
|
|
55
|
+
<span>${expiry}</span>
|
|
51
56
|
</div>
|
|
52
57
|
`;
|
|
53
58
|
}
|
|
@@ -60,7 +65,7 @@ ConsentRevocationNotice.styles = (0, lit_1.css) `
|
|
|
60
65
|
gap: 10px;
|
|
61
66
|
padding: 12px 14px;
|
|
62
67
|
border-radius: 12px;
|
|
63
|
-
background: var(--cs-surface-inset, #
|
|
68
|
+
background: var(--cs-surface-inset, #f1ece2);
|
|
64
69
|
color: var(--cs-text-secondary, #334155);
|
|
65
70
|
font-size: 12.5px;
|
|
66
71
|
line-height: 1.5;
|
|
@@ -71,7 +76,7 @@ ConsentRevocationNotice.styles = (0, lit_1.css) `
|
|
|
71
76
|
height: 16px;
|
|
72
77
|
flex-shrink: 0;
|
|
73
78
|
margin-top: 2px;
|
|
74
|
-
color: var(--cs-text-tertiary, #
|
|
79
|
+
color: var(--cs-text-tertiary, #64748b);
|
|
75
80
|
}
|
|
76
81
|
|
|
77
82
|
.content {
|
|
@@ -82,7 +87,7 @@ ConsentRevocationNotice.styles = (0, lit_1.css) `
|
|
|
82
87
|
|
|
83
88
|
em {
|
|
84
89
|
font-style: normal;
|
|
85
|
-
color: var(--cs-text-primary, #
|
|
90
|
+
color: var(--cs-text-primary, #0f172a);
|
|
86
91
|
font-weight: 500;
|
|
87
92
|
}
|
|
88
93
|
`;
|
|
@@ -95,6 +100,9 @@ __decorate([
|
|
|
95
100
|
__decorate([
|
|
96
101
|
(0, decorators_js_1.property)({ type: Number })
|
|
97
102
|
], ConsentRevocationNotice.prototype, "inactivityDays", void 0);
|
|
103
|
+
__decorate([
|
|
104
|
+
(0, decorators_js_1.property)({ type: Boolean, attribute: "fixed-expiry" })
|
|
105
|
+
], ConsentRevocationNotice.prototype, "fixedExpiry", void 0);
|
|
98
106
|
exports.ConsentRevocationNotice = ConsentRevocationNotice = __decorate([
|
|
99
107
|
(0, decorators_js_1.customElement)("consent-revocation-notice")
|
|
100
108
|
], ConsentRevocationNotice);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"consent-revocation-notice.js","sourceRoot":"","sources":["../../../src/components/consent-revocation-notice.ts"],"names":[],"mappings":";AAAA;;;;;;;GAOG;;;;;;;;;AAEH,6BAA4C;AAC5C,qDAA4D;AAE5D,iDAAqE;AAG9D,IAAM,uBAAuB,GAA7B,MAAM,uBAAwB,SAAQ,gBAAU;IAAhD;;QACuB,mBAAc,GAAG,4BAA4B,CAAC;QAC9C,YAAO,GAAG,WAAW,CAAC;QACtB,mBAAc,GAAG,EAAE,CAAC;
|
|
1
|
+
{"version":3,"file":"consent-revocation-notice.js","sourceRoot":"","sources":["../../../src/components/consent-revocation-notice.ts"],"names":[],"mappings":";AAAA;;;;;;;GAOG;;;;;;;;;AAEH,6BAA4C;AAC5C,qDAA4D;AAE5D,iDAAqE;AAG9D,IAAM,uBAAuB,GAA7B,MAAM,uBAAwB,SAAQ,gBAAU;IAAhD;;QACuB,mBAAc,GAAG,4BAA4B,CAAC;QAC9C,YAAO,GAAG,WAAW,CAAC;QACtB,mBAAc,GAAG,EAAE,CAAC;QACQ,gBAAW,GAAG,KAAK,CAAC;IAmE9E,CAAC;IA/BU,MAAM;QACb,MAAM,MAAM,GAAG,IAAA,uBAAW,EAAC,+BAAmB,CAAC,MAAM,CAAC,kBAAkB,EAAE;YACxE,cAAc,EAAE,IAAI,CAAC,cAAc;YACnC,GAAG,EAAE,IAAI,CAAC,OAAO;SAClB,CAAC,CAAC;QACH,MAAM,MAAM,GAAG,IAAI,CAAC,WAAW;YAC7B,CAAC,CAAC,+BAAmB,CAAC,MAAM,CAAC,iBAAiB;YAC9C,CAAC,CAAC,IAAA,uBAAW,EAAC,+BAAmB,CAAC,MAAM,CAAC,kBAAkB,EAAE;gBACzD,IAAI,EAAE,IAAI,CAAC,cAAc;aAC1B,CAAC,CAAC;QAEP,OAAO,IAAA,UAAI,EAAA;;;;;;;;;;;;;;;gBAeC,MAAM;gBACN,MAAM;;KAEjB,CAAC;IACJ,CAAC;;AAtEU,0DAAuB;AAMlB,8BAAM,GAAG,IAAA,SAAG,EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgC3B,AAhCqB,CAgCpB;AArC0B;IAA3B,IAAA,wBAAQ,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;+DAA+C;AAC9C;IAA3B,IAAA,wBAAQ,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;wDAAuB;AACtB;IAA3B,IAAA,wBAAQ,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;+DAAqB;AACQ;IAAvD,IAAA,wBAAQ,EAAC,EAAE,IAAI,EAAE,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,CAAC;4DAAqB;kCAJjE,uBAAuB;IADnC,IAAA,6BAAa,EAAC,2BAA2B,CAAC;GAC9B,uBAAuB,CAuEnC"}
|
|
@@ -86,6 +86,8 @@ let McpConsent = class McpConsent extends lit_1.LitElement {
|
|
|
86
86
|
* Session ID
|
|
87
87
|
*/
|
|
88
88
|
this.sessionId = "";
|
|
89
|
+
/** Explicit HTTP anchor routing, separate from legacy session ID syntax. */
|
|
90
|
+
this.anchorSid = "";
|
|
89
91
|
/**
|
|
90
92
|
* Project ID
|
|
91
93
|
*/
|
|
@@ -145,6 +147,9 @@ let McpConsent = class McpConsent extends lit_1.LitElement {
|
|
|
145
147
|
* Example: https://github.com/login/oauth/authorize?client_id=...
|
|
146
148
|
*/
|
|
147
149
|
this.oauthUrl = "";
|
|
150
|
+
/** Native HTTP resolves assertion scopes from its immutable anchor, so the
|
|
151
|
+
* submitted grant may safely narrow to the human's selected permissions. */
|
|
152
|
+
this.nativeScopeSelection = false;
|
|
148
153
|
// === HUMANIZED CONSENT (capability-based) ===
|
|
149
154
|
/**
|
|
150
155
|
* Operator-authored capability groups. When present and non-empty, the new
|
|
@@ -388,15 +393,11 @@ let McpConsent = class McpConsent extends lit_1.LitElement {
|
|
|
388
393
|
// The server creates the DelegationCredential (VC) when this request succeeds
|
|
389
394
|
const formData = new FormData();
|
|
390
395
|
formData.append("tool", this.tool);
|
|
391
|
-
//
|
|
392
|
-
//
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
// Scope narrowing on this path isn't supported: legacy scopes are
|
|
397
|
-
// display-only, and the capability screen requires every permission.
|
|
398
|
-
// Assertion-less consent-only grants use the user's selected subset.
|
|
399
|
-
formData.append("scopes", JSON.stringify(this.identityAssertion ? this.scopes : this.selectedScopes));
|
|
396
|
+
// Legacy assertion gates hash the posted scope set. Native HTTP verifies
|
|
397
|
+
// against its immutable anchor separately, then grants only this selection.
|
|
398
|
+
formData.append("scopes", JSON.stringify(this.identityAssertion && !this.nativeScopeSelection
|
|
399
|
+
? this.scopes
|
|
400
|
+
: this.selectedScopes));
|
|
400
401
|
formData.append("agent_did", this.agentDid);
|
|
401
402
|
// The credential flow redirects to a second (consent-only) screen, and
|
|
402
403
|
// the agent name only ever arrives as a URL param — it is never stored on
|
|
@@ -406,6 +407,8 @@ let McpConsent = class McpConsent extends lit_1.LitElement {
|
|
|
406
407
|
formData.append("agent_name", this.agentName);
|
|
407
408
|
}
|
|
408
409
|
formData.append("session_id", this.sessionId);
|
|
410
|
+
if (this.anchorSid)
|
|
411
|
+
formData.append("sid", this.anchorSid);
|
|
409
412
|
formData.append("project_id", this.projectId);
|
|
410
413
|
formData.append("auth_mode", this.currentMode);
|
|
411
414
|
// Set provider_type based on auth mode to ensure correct server-side routing
|
|
@@ -487,6 +490,15 @@ let McpConsent = class McpConsent extends lit_1.LitElement {
|
|
|
487
490
|
return; // Don't show success yet - the redirect page will handle it
|
|
488
491
|
}
|
|
489
492
|
// No redirect - VC/delegation created successfully, show success screen
|
|
493
|
+
if (this.nativeScopeSelection) {
|
|
494
|
+
const expiresAt = result.expires_at;
|
|
495
|
+
this.issuedExpiresAt =
|
|
496
|
+
Number.isSafeInteger(expiresAt) &&
|
|
497
|
+
expiresAt > 0 &&
|
|
498
|
+
Number.isFinite(new Date(expiresAt * 1000).getTime())
|
|
499
|
+
? expiresAt
|
|
500
|
+
: undefined;
|
|
501
|
+
}
|
|
490
502
|
this.step = "success";
|
|
491
503
|
this.dispatchEvent(new CustomEvent("mcp-consent:approve", {
|
|
492
504
|
detail: { success: true, delegationId: result.delegation_id },
|
|
@@ -553,6 +565,20 @@ let McpConsent = class McpConsent extends lit_1.LitElement {
|
|
|
553
565
|
}));
|
|
554
566
|
}
|
|
555
567
|
// === RENDER METHODS ===
|
|
568
|
+
renderNativeAgentKey() {
|
|
569
|
+
// The native bridge derives agentDid from the proved holder pin. Legacy
|
|
570
|
+
// agent metadata does not establish possession of a key, so do not make
|
|
571
|
+
// this disclosure on shells without the native opt-in.
|
|
572
|
+
if (!this.nativeScopeSelection || !this.agentDid)
|
|
573
|
+
return lit_1.nothing;
|
|
574
|
+
return (0, lit_1.html) `
|
|
575
|
+
<section class="agent-key" aria-label="Agent key">
|
|
576
|
+
<p><strong>Agent key</strong></p>
|
|
577
|
+
<p>This permission is bound to this key.</p>
|
|
578
|
+
<code>${this.agentDid}</code>
|
|
579
|
+
</section>
|
|
580
|
+
`;
|
|
581
|
+
}
|
|
556
582
|
renderAgentInfo() {
|
|
557
583
|
const agentDisplay = this.agentName || "this agent";
|
|
558
584
|
return (0, lit_1.html) `
|
|
@@ -579,6 +605,7 @@ let McpConsent = class McpConsent extends lit_1.LitElement {
|
|
|
579
605
|
</p>
|
|
580
606
|
</div>
|
|
581
607
|
</div>
|
|
608
|
+
${this.renderNativeAgentKey()}
|
|
582
609
|
`;
|
|
583
610
|
}
|
|
584
611
|
handlePermissionsChange(e) {
|
|
@@ -595,7 +622,8 @@ let McpConsent = class McpConsent extends lit_1.LitElement {
|
|
|
595
622
|
// would let the user "uncheck" a scope that gets granted anyway, so this
|
|
596
623
|
// renders display-only rows instead until the deferred subset-binding
|
|
597
624
|
// follow-up lands. See `shouldRenderScopesInteractive`.
|
|
598
|
-
const interactive =
|
|
625
|
+
const interactive = this.nativeScopeSelection ||
|
|
626
|
+
(0, credential_capabilities_js_1.shouldRenderScopesInteractive)(this.identityAssertion);
|
|
599
627
|
return (0, lit_1.html) `
|
|
600
628
|
<p class="permissions-header">
|
|
601
629
|
${this.resolved?.ui.permissionsHeader ??
|
|
@@ -612,6 +640,10 @@ let McpConsent = class McpConsent extends lit_1.LitElement {
|
|
|
612
640
|
`;
|
|
613
641
|
}
|
|
614
642
|
renderExpiration() {
|
|
643
|
+
// Native expiry is determined by the issued VC, not this UI configuration.
|
|
644
|
+
// It is only available after approval; do not advertise a guessed duration.
|
|
645
|
+
if (this.nativeScopeSelection)
|
|
646
|
+
return lit_1.nothing;
|
|
615
647
|
const days = this.resolved?.expirationDays ?? 7;
|
|
616
648
|
return (0, lit_1.html) `
|
|
617
649
|
<p class="expiration">
|
|
@@ -915,6 +947,31 @@ let McpConsent = class McpConsent extends lit_1.LitElement {
|
|
|
915
947
|
year: "numeric",
|
|
916
948
|
});
|
|
917
949
|
}
|
|
950
|
+
renderSuccessExpiry() {
|
|
951
|
+
if (!this.nativeScopeSelection)
|
|
952
|
+
return (0, lit_1.html) `<div class="credential-expiry">
|
|
953
|
+
Expires ${this.formatExpiryDate()}
|
|
954
|
+
</div>`;
|
|
955
|
+
if (this.issuedExpiresAt === undefined)
|
|
956
|
+
return (0, lit_1.html) `<div class="credential-expiry">
|
|
957
|
+
Expiration time unavailable.
|
|
958
|
+
</div>`;
|
|
959
|
+
const expiry = new Date(this.issuedExpiresAt * 1000);
|
|
960
|
+
return (0, lit_1.html) `<div class="credential-expiry">
|
|
961
|
+
Expires
|
|
962
|
+
<time datetime=${expiry.toISOString()}
|
|
963
|
+
>${expiry.toLocaleString("en-US", {
|
|
964
|
+
month: "short",
|
|
965
|
+
day: "numeric",
|
|
966
|
+
year: "numeric",
|
|
967
|
+
hour: "numeric",
|
|
968
|
+
minute: "2-digit",
|
|
969
|
+
second: "2-digit",
|
|
970
|
+
timeZoneName: "short",
|
|
971
|
+
})}</time
|
|
972
|
+
>
|
|
973
|
+
</div>`;
|
|
974
|
+
}
|
|
918
975
|
/**
|
|
919
976
|
* Get the display name for the agent.
|
|
920
977
|
* Returns agent name if available, otherwise falls back to agent DID.
|
|
@@ -925,7 +982,6 @@ let McpConsent = class McpConsent extends lit_1.LitElement {
|
|
|
925
982
|
renderSuccess() {
|
|
926
983
|
const success = this.resolved?.success;
|
|
927
984
|
const agentDisplay = this.getAgentDisplayName();
|
|
928
|
-
const expiryDate = this.formatExpiryDate();
|
|
929
985
|
// Use selectedScopes if available (user may have deselected some), otherwise fall back to scopes
|
|
930
986
|
const displayScopes = this.selectedScopes.length > 0 ? this.selectedScopes : this.scopes;
|
|
931
987
|
return (0, lit_1.html) `
|
|
@@ -973,8 +1029,7 @@ let McpConsent = class McpConsent extends lit_1.LitElement {
|
|
|
973
1029
|
</div>
|
|
974
1030
|
`
|
|
975
1031
|
: lit_1.nothing}
|
|
976
|
-
|
|
977
|
-
<div class="credential-expiry">Expires ${expiryDate}</div>
|
|
1032
|
+
${this.renderSuccessExpiry()}
|
|
978
1033
|
|
|
979
1034
|
<!-- Verified Badge -->
|
|
980
1035
|
<div class="verified-badge">
|
|
@@ -1099,17 +1154,28 @@ let McpConsent = class McpConsent extends lit_1.LitElement {
|
|
|
1099
1154
|
headlineVerb="${this.headlineVerb}"
|
|
1100
1155
|
revocationPath="${this.revocationPath}"
|
|
1101
1156
|
inactivityDays=${this.inactivityDays}
|
|
1157
|
+
?fixed-expiry=${this.nativeScopeSelection}
|
|
1102
1158
|
theme="${this.consentTheme}"
|
|
1103
1159
|
how-it-works-url="${this.howItWorksUrl}"
|
|
1104
1160
|
?loading=${this.loading}
|
|
1105
1161
|
?all-selected=${allSelected}
|
|
1106
1162
|
?require-all=${allSelected}
|
|
1107
|
-
?allow-disabled=${!projection.ok ||
|
|
1163
|
+
?allow-disabled=${!projection.ok ||
|
|
1164
|
+
(credentials && !(0, credential_capabilities_js_1.areCredentialsComplete)(this.formData))}
|
|
1108
1165
|
@capabilities-allow=${this.onCapabilitiesAllow}
|
|
1109
1166
|
@capabilities-deny=${this.handleDeny}
|
|
1110
1167
|
>
|
|
1168
|
+
${this.nativeScopeSelection && this.agentDid
|
|
1169
|
+
? (0, lit_1.html) `<div slot="agent-key">${this.renderNativeAgentKey()}</div>`
|
|
1170
|
+
: lit_1.nothing}
|
|
1111
1171
|
${allSelected
|
|
1112
|
-
? (0, lit_1.html) `<div slot="auth"
|
|
1172
|
+
? (0, lit_1.html) `<div slot="auth">
|
|
1173
|
+
<p>
|
|
1174
|
+
This request grants every listed permission. Select all
|
|
1175
|
+
permissions or deny the request.
|
|
1176
|
+
</p>
|
|
1177
|
+
${credentials ? this.renderCredentialFields() : lit_1.nothing}
|
|
1178
|
+
</div>`
|
|
1113
1179
|
: lit_1.nothing}
|
|
1114
1180
|
</consent-capabilities-screen>
|
|
1115
1181
|
`;
|
|
@@ -1117,7 +1183,8 @@ let McpConsent = class McpConsent extends lit_1.LitElement {
|
|
|
1117
1183
|
get requiresAllCapabilities() {
|
|
1118
1184
|
// Credentials use a fixed session scope key; signed identity assertions
|
|
1119
1185
|
// bind the complete requested set. Neither path can narrow implicitly.
|
|
1120
|
-
return (0, credential_capabilities_js_1.shouldSelectAllCapabilities)(this.currentMode) ||
|
|
1186
|
+
return ((0, credential_capabilities_js_1.shouldSelectAllCapabilities)(this.currentMode) ||
|
|
1187
|
+
(!this.nativeScopeSelection && Boolean(this.identityAssertion)));
|
|
1121
1188
|
}
|
|
1122
1189
|
};
|
|
1123
1190
|
exports.McpConsent = McpConsent;
|
|
@@ -1176,6 +1243,36 @@ McpConsent.styles = (0, lit_1.css) `
|
|
|
1176
1243
|
color: #111827;
|
|
1177
1244
|
}
|
|
1178
1245
|
|
|
1246
|
+
.agent-key {
|
|
1247
|
+
min-width: 0;
|
|
1248
|
+
padding: 1rem;
|
|
1249
|
+
margin-bottom: 1rem;
|
|
1250
|
+
border: 1px solid var(--cs-surface-border, #e5e7eb);
|
|
1251
|
+
border-radius: 0.5rem;
|
|
1252
|
+
color: var(--cs-text-primary, #111827);
|
|
1253
|
+
font-size: 0.875rem;
|
|
1254
|
+
line-height: 1.5;
|
|
1255
|
+
}
|
|
1256
|
+
|
|
1257
|
+
.agent-key p {
|
|
1258
|
+
margin: 0 0 0.5rem;
|
|
1259
|
+
}
|
|
1260
|
+
|
|
1261
|
+
.agent-key code {
|
|
1262
|
+
display: block;
|
|
1263
|
+
white-space: normal;
|
|
1264
|
+
overflow-wrap: anywhere;
|
|
1265
|
+
font-size: 0.75rem;
|
|
1266
|
+
}
|
|
1267
|
+
|
|
1268
|
+
[slot="agent-key"] {
|
|
1269
|
+
min-width: 0;
|
|
1270
|
+
}
|
|
1271
|
+
|
|
1272
|
+
[slot="agent-key"] .agent-key {
|
|
1273
|
+
margin-bottom: 0;
|
|
1274
|
+
}
|
|
1275
|
+
|
|
1179
1276
|
/* Permissions section */
|
|
1180
1277
|
.permissions-header {
|
|
1181
1278
|
font-size: 0.875rem;
|
|
@@ -1531,6 +1628,9 @@ __decorate([
|
|
|
1531
1628
|
__decorate([
|
|
1532
1629
|
(0, decorators_js_1.property)({ type: String, attribute: "session-id" })
|
|
1533
1630
|
], McpConsent.prototype, "sessionId", void 0);
|
|
1631
|
+
__decorate([
|
|
1632
|
+
(0, decorators_js_1.property)({ type: String, attribute: "anchor-sid" })
|
|
1633
|
+
], McpConsent.prototype, "anchorSid", void 0);
|
|
1534
1634
|
__decorate([
|
|
1535
1635
|
(0, decorators_js_1.property)({ type: String, attribute: "project-id" })
|
|
1536
1636
|
], McpConsent.prototype, "projectId", void 0);
|
|
@@ -1567,6 +1667,9 @@ __decorate([
|
|
|
1567
1667
|
__decorate([
|
|
1568
1668
|
(0, decorators_js_1.property)({ type: String, attribute: "oauth-url" })
|
|
1569
1669
|
], McpConsent.prototype, "oauthUrl", void 0);
|
|
1670
|
+
__decorate([
|
|
1671
|
+
(0, decorators_js_1.property)({ type: Boolean, attribute: "native-scope-selection" })
|
|
1672
|
+
], McpConsent.prototype, "nativeScopeSelection", void 0);
|
|
1570
1673
|
__decorate([
|
|
1571
1674
|
(0, decorators_js_1.property)({
|
|
1572
1675
|
type: Array,
|
|
@@ -1684,6 +1787,9 @@ __decorate([
|
|
|
1684
1787
|
__decorate([
|
|
1685
1788
|
(0, decorators_js_1.state)()
|
|
1686
1789
|
], McpConsent.prototype, "step", void 0);
|
|
1790
|
+
__decorate([
|
|
1791
|
+
(0, decorators_js_1.state)()
|
|
1792
|
+
], McpConsent.prototype, "issuedExpiresAt", void 0);
|
|
1687
1793
|
__decorate([
|
|
1688
1794
|
(0, decorators_js_1.state)()
|
|
1689
1795
|
], McpConsent.prototype, "termsAccepted", void 0);
|