@deepseek-ai/dsh-client-ui-settings-models 0.2.1-alpha.2 → 0.2.1-alpha.4

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/lib/client.js CHANGED
@@ -55,7 +55,7 @@ window.__ModuleLoader__.load({
55
55
  }
56
56
  //#endregion
57
57
  //#region \0dsh-css:/home/runner/work/deepseek-harness/deepseek-harness/packages/client/ui-settings-models/src/client/ModelsSection.module.css.mjs
58
- const css$3 = ".zGbnIq_section{max-width:720px;color:var(--dsw-alias-label-primary);flex-direction:column;gap:12px;display:flex}.zGbnIq_title{color:var(--dsw-alias-label-primary);margin:0;font-size:16px;font-weight:500;line-height:24px}.zGbnIq_intro{color:var(--dsw-alias-label-tertiary);margin:0;font-size:14px;line-height:22px}.zGbnIq_notice{color:var(--dsw-alias-state-warn-label);margin:0;font-size:12px;line-height:18px}.zGbnIq_savedNotice{color:var(--dsw-alias-state-success-primary);margin:0;font-size:12px;line-height:18px}.zGbnIq_rows{flex-direction:column;gap:8px;margin:12px 0 0;padding:0;list-style:none;display:flex}.zGbnIq_rowCard{border:.5px solid var(--dsw-alias-settings-card-stroke);background:var(--dsw-alias-settings-card-fill);border-radius:var(--dsw-radius-xl);flex-direction:column;gap:12px;padding:12px 14px;display:flex}.zGbnIq_rowHead{align-items:center;gap:10px;display:flex}.zGbnIq_rowIdentity{align-items:center;gap:6px;min-width:0;display:inline-flex}.zGbnIq_rowName{color:var(--dsw-alias-label-primary);font-size:14px;font-weight:500;line-height:22px}.zGbnIq_rowTag{border:.5px solid var(--dsw-alias-border-l3);border-radius:var(--dsw-radius-xs);color:var(--dsw-alias-label-secondary);flex:none;padding:1px 6px;font-size:11px;line-height:16px}.zGbnIq_credentialDot{box-sizing:border-box;corner-shape:round;border-radius:50%;flex:none;width:8px;height:8px;display:inline-block}.zGbnIq_credentialDotConfigured{background:var(--dsw-alias-state-success-primary)}.zGbnIq_credentialDotMissing{background:var(--dsw-alias-state-error-primary)}.zGbnIq_rowActions{align-items:center;gap:4px;margin-left:auto;display:inline-flex}.zGbnIq_primaryButton,.zGbnIq_secondaryButton,.zGbnIq_addButton{box-sizing:border-box;border-radius:var(--dsw-radius-md);height:36px;font:inherit;cursor:pointer;border:none;justify-content:center;align-items:center;gap:4px;padding:0 14px;font-size:14px;line-height:22px;display:inline-flex}.zGbnIq_primaryButton{background:var(--dsw-alias-button-primary-fill);color:var(--dsw-alias-label-primary-foreground)}.zGbnIq_primaryButton:hover:not(:disabled){background:var(--dsw-alias-button-primary-hover)}.zGbnIq_secondaryButton,.zGbnIq_addButton{border:.5px solid var(--dsw-alias-border-l3);color:var(--dsw-alias-label-primary);background:0 0}.zGbnIq_secondaryButton:hover:not(:disabled),.zGbnIq_addButton:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover)}.zGbnIq_secondaryButton:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover-solid)}.zGbnIq_dangerButton{box-sizing:border-box;border-radius:var(--dsw-radius-md);height:36px;color:var(--dsw-alias-state-error-primary);font:inherit;cursor:pointer;background:0 0;border:none;justify-content:center;align-items:center;padding:0 14px;font-size:14px;line-height:22px;display:inline-flex}.zGbnIq_dangerButton:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover-danger)}.zGbnIq_rowActions .zGbnIq_secondaryButton,.zGbnIq_rowActions .zGbnIq_dangerButton{border-radius:var(--dsw-radius-sm);height:28px;padding:0 10px;font-size:12px;line-height:18px}.zGbnIq_primaryButton:disabled,.zGbnIq_secondaryButton:disabled,.zGbnIq_dangerButton:disabled,.zGbnIq_addButton:disabled,.zGbnIq_linkButton:disabled,.zGbnIq_addModelButton:disabled{opacity:.4;cursor:default}.zGbnIq_primaryButton:focus-visible,.zGbnIq_secondaryButton:focus-visible,.zGbnIq_dangerButton:focus-visible,.zGbnIq_addButton:focus-visible,.zGbnIq_linkButton:focus-visible,.zGbnIq_addModelButton:focus-visible,.zGbnIq_iconButton:focus-visible,.zGbnIq_customizedSummary:focus-visible{box-shadow:0 0 0 2px var(--dsw-focus-ring-color,var(--dsw-alias-state-business-primary));outline:none}.zGbnIq_editor{border-radius:var(--dsw-radius-lg);background:var(--dsw-alias-bg-module-platform);flex-direction:column;gap:14px;padding:14px 16px;display:flex}.zGbnIq_editorHeader{align-items:baseline;gap:8px;display:flex}.zGbnIq_editorTitle{color:var(--dsw-alias-label-primary);font-size:14px;font-weight:500;line-height:22px}.zGbnIq_editorRoute{color:var(--dsw-alias-label-tertiary);font-size:12px;line-height:18px}.zGbnIq_field{flex-direction:column;gap:6px;display:flex}.zGbnIq_fieldLabel{color:var(--dsw-alias-label-secondary);align-items:center;gap:10px;font-size:12px;font-weight:500;line-height:18px;display:inline-flex}.zGbnIq_linkButton{box-sizing:border-box;border-radius:var(--dsw-radius-sm);height:28px;color:var(--dsw-alias-label-tertiary);font:inherit;cursor:pointer;background:0 0;border:none;align-items:center;padding:0 10px;font-size:12px;line-height:18px;display:inline-flex}.zGbnIq_linkButton:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-secondary)}.zGbnIq_advancedHint{color:var(--dsw-alias-label-tertiary);margin:0;font-size:12px;line-height:18px}.zGbnIq_editorActions{justify-content:flex-end;gap:8px;display:flex}.zGbnIq_addBlock{flex-direction:column;gap:12px;display:flex}.zGbnIq_addActions{display:flex}.zGbnIq_addButton{border:1px dashed var(--dsw-alias-border-l3);border-radius:var(--dsw-radius-lg);flex:1 1 0;gap:6px;min-width:180px;height:44px}.zGbnIq_addModes{flex-direction:column;align-items:flex-start;gap:8px;display:flex}.zGbnIq_addPanel{flex-direction:column;gap:14px;display:flex}.zGbnIq_addPanel[hidden]{display:none}.zGbnIq_addCard,.zGbnIq_setupCard{border-radius:var(--dsw-radius-lg);background:var(--dsw-alias-bg-module-platform);flex-direction:column;gap:14px;padding:14px 16px;list-style:none;display:flex}.zGbnIq_addCard .zGbnIq_editor,.zGbnIq_setupCard .zGbnIq_editor{background:0 0;padding:0}.zGbnIq_customized{border-top:.5px solid var(--dsw-alias-border-l2);padding-top:10px}.zGbnIq_customizedSummary{border-radius:var(--dsw-radius-sm);cursor:pointer;width:fit-content;color:var(--dsw-alias-label-secondary);align-items:center;gap:6px;margin-left:-4px;padding:2px 4px;font-size:12px;font-weight:500;line-height:18px;list-style:none;display:flex}.zGbnIq_customizedSummary::-webkit-details-marker{display:none}.zGbnIq_customizedSummary:before{content:\"\";border-bottom:1.5px solid;border-right:1.5px solid;width:5px;height:5px;transition:transform .12s;transform:rotate(-45deg)translate(-1px,-1px)}.zGbnIq_customized[open]>.zGbnIq_customizedSummary:before{transform:rotate(45deg)translate(-1px,-1px)}.zGbnIq_customizedSummary:hover{color:var(--dsw-alias-label-primary)}.zGbnIq_customizedBody{flex-direction:column;gap:12px;padding-top:12px;display:flex}.zGbnIq_modelCatalog{border-top:.5px solid var(--dsw-alias-border-l2);flex-direction:column;gap:10px;padding-top:12px;display:flex}.zGbnIq_modelCatalogHeading{flex-direction:column;gap:2px;display:flex}.zGbnIq_modelCatalogTitle{color:var(--dsw-alias-label-secondary);font-size:12px;font-weight:500;line-height:18px}.zGbnIq_modelCatalogMeta,.zGbnIq_modelEmpty{color:var(--dsw-alias-label-tertiary);margin:0;font-size:12px;line-height:18px}.zGbnIq_modelList{flex-direction:column;gap:8px;display:flex}.zGbnIq_modelListHead{justify-content:space-between;align-items:flex-start;gap:12px;display:flex}.zGbnIq_modelEntry{border:.5px solid var(--dsw-alias-border-l4);border-radius:var(--dsw-radius-lg);padding:6px}.zGbnIq_modelRow{grid-template-columns:minmax(0,1.4fr) minmax(0,1fr) auto auto;align-items:center;gap:6px;display:grid}.zGbnIq_iconButton{box-sizing:border-box;border-radius:var(--dsw-radius-sm);width:28px;height:28px;color:var(--dsw-alias-label-tertiary);cursor:pointer;background:0 0;border:none;justify-content:center;align-items:center;display:inline-flex}.zGbnIq_iconButton:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-primary)}.zGbnIq_iconButton:disabled{cursor:default;opacity:.4}.zGbnIq_iconButtonDanger:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover-danger);color:var(--dsw-alias-state-error-primary)}.zGbnIq_modelAdvanced{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;padding:8px 4px 2px;display:grid}.zGbnIq_modelField{flex-direction:column;gap:4px;min-width:0;display:flex}.zGbnIq_modelInputTypes{border:none;grid-column:1/-1;min-width:0;margin:0;padding:0}.zGbnIq_modelInputTypes legend{margin-bottom:4px;padding:0}.zGbnIq_modelInputChoices{flex-wrap:wrap;align-items:center;gap:16px;min-height:32px;display:flex}.zGbnIq_modelFieldLabel{color:var(--dsw-alias-label-tertiary);font-size:12px;line-height:18px}.zGbnIq_modelEmpty{border:1px dashed var(--dsw-alias-border-l3);border-radius:var(--dsw-radius-lg);text-align:center;padding:12px}.zGbnIq_addModelButton{box-sizing:border-box;border:.5px solid var(--dsw-alias-border-l3);border-radius:var(--dsw-radius-sm);height:28px;color:var(--dsw-alias-label-primary);font:inherit;cursor:pointer;background:0 0;align-self:flex-start;align-items:center;gap:4px;padding:0 10px;font-size:12px;line-height:18px;display:inline-flex}.zGbnIq_addModelButton:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover)}.zGbnIq_input{box-sizing:border-box;border:.5px solid var(--dsw-alias-border-l4);border-radius:var(--dsw-radius-md);width:100%;height:32px;font:inherit;background:var(--dsw-alias-bg-layer-1);color:var(--dsw-alias-label-primary);padding:0 10px;font-size:14px;line-height:22px}select.zGbnIq_input{cursor:pointer;max-width:240px}.zGbnIq_input:focus{border-color:var(--dsw-alias-state-business-primary);outline:none}.zGbnIq_input::placeholder{color:var(--dsw-alias-label-dimmed)}.zGbnIq_input:disabled{opacity:.6;cursor:default}.zGbnIq_selectInput{appearance:none;background-image:url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M3 4.5L6 7.5L9 4.5' stroke='%2381858C' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E\");background-position:right 12px center;background-repeat:no-repeat;background-size:12px 12px;padding-right:32px}.zGbnIq_error{color:var(--dsw-alias-state-error-primary);margin:0;font-size:12px;line-height:18px}.zGbnIq_deleteDialog{width:min(480px,100%)}.zGbnIq_deleteConfirm:not(:disabled){border-color:var(--dsw-alias-state-error-primary);color:var(--dsw-alias-state-error-primary)}.zGbnIq_deleteConfirm:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover-danger)}.zGbnIq_hiddenLabel{clip:rect(0 0 0 0);white-space:nowrap;width:1px;height:1px;position:absolute;overflow:hidden}@media (prefers-reduced-motion:reduce){.zGbnIq_customizedSummary:before,.zGbnIq_switchThumb{transition:none}}.zGbnIq_fetchDialog{--dsh-scrollbar-thumb:var(--dsw-alias-scrollbar-bg-l2);--dsh-scrollbar-thumb-hover:var(--dsw-alias-scrollbar-hover-l2);max-width:520px}.zGbnIq_candidateToolbar{align-items:center;gap:8px;margin-bottom:6px;display:flex}.zGbnIq_candidateSearch{flex:240px;min-width:0}.zGbnIq_candidateList{flex-direction:column;gap:2px;max-height:320px;margin:0;padding:0;list-style:none;display:flex;overflow-y:auto}.zGbnIq_candidate{border-radius:var(--dsw-radius-md)}.zGbnIq_candidateLabel{cursor:pointer;align-items:center;gap:8px;padding:6px 8px;display:flex}.zGbnIq_candidateId{min-width:0;font-family:var(--ds-font-family-code);text-overflow:ellipsis;white-space:nowrap;flex:auto;font-size:13px;overflow:hidden}.zGbnIq_candidateEmpty{color:var(--dsw-alias-label-secondary);text-align:center;margin:24px 0;font-size:13px;line-height:20px}";
58
+ const css$3 = ".zGbnIq_section{max-width:720px;color:var(--dsw-alias-label-primary);flex-direction:column;gap:12px;display:flex}.zGbnIq_title{color:var(--dsw-alias-label-primary);margin:0;font-size:16px;font-weight:500;line-height:24px}.zGbnIq_intro{color:var(--dsw-alias-label-tertiary);margin:0;font-size:14px;line-height:22px}.zGbnIq_notice{color:var(--dsw-alias-state-warn-label);margin:0;font-size:12px;line-height:18px}.zGbnIq_savedNotice{color:var(--dsw-alias-state-success-primary);margin:0;font-size:12px;line-height:18px}.zGbnIq_rows{flex-direction:column;gap:8px;margin:12px 0 0;padding:0;list-style:none;display:flex}.zGbnIq_rowCard{border:.5px solid var(--dsw-alias-settings-card-stroke);background:var(--dsw-alias-settings-card-fill);border-radius:var(--dsw-radius-xl);flex-direction:column;gap:12px;padding:12px 14px;display:flex}.zGbnIq_rowHead{align-items:center;gap:10px;display:flex}.zGbnIq_rowIdentity{align-items:center;gap:6px;min-width:0;display:inline-flex}.zGbnIq_rowName{color:var(--dsw-alias-label-primary);font-size:14px;font-weight:500;line-height:22px}.zGbnIq_rowTag{border:.5px solid var(--dsw-alias-border-l3);border-radius:var(--dsw-radius-xs);color:var(--dsw-alias-label-secondary);flex:none;padding:1px 6px;font-size:11px;line-height:16px}.zGbnIq_credentialDot{box-sizing:border-box;corner-shape:round;border-radius:50%;flex:none;width:8px;height:8px;display:inline-block}.zGbnIq_credentialDotConfigured{background:var(--dsw-alias-state-success-primary)}.zGbnIq_credentialDotMissing{background:var(--dsw-alias-state-error-primary)}.zGbnIq_accountStatus{color:var(--dsw-alias-state-success-primary);flex:none;align-items:center;gap:6px;font-size:13px;line-height:20px;display:inline-flex}.zGbnIq_rowActions{align-items:center;gap:4px;margin-left:auto;display:inline-flex}.zGbnIq_primaryButton,.zGbnIq_secondaryButton,.zGbnIq_addButton{box-sizing:border-box;border-radius:var(--dsw-radius-md);height:36px;font:inherit;cursor:pointer;border:none;justify-content:center;align-items:center;gap:4px;padding:0 14px;font-size:14px;line-height:22px;display:inline-flex}.zGbnIq_primaryButton{background:var(--dsw-alias-button-primary-fill);color:var(--dsw-alias-label-primary-foreground)}.zGbnIq_primaryButton:hover:not(:disabled){background:var(--dsw-alias-button-primary-hover)}.zGbnIq_secondaryButton,.zGbnIq_addButton{border:.5px solid var(--dsw-alias-border-l3);color:var(--dsw-alias-label-primary);background:0 0}.zGbnIq_secondaryButton:hover:not(:disabled),.zGbnIq_addButton:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover)}.zGbnIq_secondaryButton:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover-solid)}.zGbnIq_dangerButton{box-sizing:border-box;border-radius:var(--dsw-radius-md);height:36px;color:var(--dsw-alias-state-error-primary);font:inherit;cursor:pointer;background:0 0;border:none;justify-content:center;align-items:center;padding:0 14px;font-size:14px;line-height:22px;display:inline-flex}.zGbnIq_dangerButton:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover-danger)}.zGbnIq_rowActions .zGbnIq_secondaryButton,.zGbnIq_rowActions .zGbnIq_dangerButton{border-radius:var(--dsw-radius-sm);height:28px;padding:0 10px;font-size:12px;line-height:18px}.zGbnIq_primaryButton:disabled,.zGbnIq_secondaryButton:disabled,.zGbnIq_dangerButton:disabled,.zGbnIq_addButton:disabled,.zGbnIq_linkButton:disabled,.zGbnIq_addModelButton:disabled{opacity:.4;cursor:default}.zGbnIq_primaryButton:focus-visible,.zGbnIq_secondaryButton:focus-visible,.zGbnIq_dangerButton:focus-visible,.zGbnIq_addButton:focus-visible,.zGbnIq_linkButton:focus-visible,.zGbnIq_addModelButton:focus-visible,.zGbnIq_iconButton:focus-visible,.zGbnIq_customizedSummary:focus-visible{box-shadow:0 0 0 2px var(--dsw-focus-ring-color,var(--dsw-alias-state-business-primary));outline:none}.zGbnIq_editor{border-radius:var(--dsw-radius-lg);background:var(--dsw-alias-bg-module-platform);flex-direction:column;gap:14px;padding:14px 16px;display:flex}.zGbnIq_editorHeader{align-items:baseline;gap:8px;display:flex}.zGbnIq_editorTitle{color:var(--dsw-alias-label-primary);font-size:14px;font-weight:500;line-height:22px}.zGbnIq_editorRoute{color:var(--dsw-alias-label-tertiary);font-size:12px;line-height:18px}.zGbnIq_field{flex-direction:column;gap:6px;display:flex}.zGbnIq_fieldLabel{color:var(--dsw-alias-label-secondary);align-items:center;gap:10px;font-size:12px;font-weight:500;line-height:18px;display:inline-flex}.zGbnIq_helpButton{border:.5px solid var(--dsw-alias-border-l3);corner-shape:round;width:16px;height:16px;color:var(--dsw-alias-label-tertiary);font:inherit;text-align:center;cursor:help;background:0 0;border-radius:50%;padding:0;font-size:11px;line-height:15px}.zGbnIq_helpButton:hover,.zGbnIq_helpButton:focus-visible{color:var(--dsw-alias-label-primary);border-color:var(--dsw-alias-label-tertiary)}.zGbnIq_linkButton{box-sizing:border-box;border-radius:var(--dsw-radius-sm);height:28px;color:var(--dsw-alias-label-tertiary);font:inherit;cursor:pointer;background:0 0;border:none;align-items:center;padding:0 10px;font-size:12px;line-height:18px;display:inline-flex}.zGbnIq_linkButton:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-secondary)}.zGbnIq_advancedHint{color:var(--dsw-alias-label-tertiary);margin:0;font-size:12px;line-height:18px}.zGbnIq_editorActions{justify-content:flex-end;gap:8px;display:flex}.zGbnIq_addBlock{flex-direction:column;gap:12px;display:flex}.zGbnIq_addActions{display:flex}.zGbnIq_addButton{border:1px dashed var(--dsw-alias-border-l3);border-radius:var(--dsw-radius-lg);flex:1 1 0;gap:6px;min-width:180px;height:44px}.zGbnIq_addModes{flex-direction:column;align-items:flex-start;gap:8px;display:flex}.zGbnIq_addPanel{flex-direction:column;gap:14px;display:flex}.zGbnIq_addPanel[hidden]{display:none}.zGbnIq_addCard,.zGbnIq_setupCard{border-radius:var(--dsw-radius-lg);background:var(--dsw-alias-bg-module-platform);flex-direction:column;gap:14px;padding:14px 16px;list-style:none;display:flex}.zGbnIq_addCard .zGbnIq_editor,.zGbnIq_setupCard .zGbnIq_editor{background:0 0;padding:0}.zGbnIq_customized{border-top:.5px solid var(--dsw-alias-border-l2);padding-top:10px}.zGbnIq_customizedSummary{border-radius:var(--dsw-radius-sm);cursor:pointer;width:fit-content;color:var(--dsw-alias-label-secondary);align-items:center;gap:6px;margin-left:-4px;padding:2px 4px;font-size:12px;font-weight:500;line-height:18px;list-style:none;display:flex}.zGbnIq_customizedSummary::-webkit-details-marker{display:none}.zGbnIq_customizedSummary:before{content:\"\";border-bottom:1.5px solid;border-right:1.5px solid;width:5px;height:5px;transition:transform .12s;transform:rotate(-45deg)translate(-1px,-1px)}.zGbnIq_customized[open]>.zGbnIq_customizedSummary:before{transform:rotate(45deg)translate(-1px,-1px)}.zGbnIq_customizedSummary:hover{color:var(--dsw-alias-label-primary)}.zGbnIq_customizedBody{flex-direction:column;gap:12px;padding-top:12px;display:flex}.zGbnIq_modelCatalog{border-top:.5px solid var(--dsw-alias-border-l2);flex-direction:column;gap:10px;padding-top:12px;display:flex}.zGbnIq_modelCatalogHeading{flex-direction:column;gap:2px;display:flex}.zGbnIq_modelCatalogTitle{color:var(--dsw-alias-label-secondary);font-size:12px;font-weight:500;line-height:18px}.zGbnIq_modelCatalogMeta,.zGbnIq_modelEmpty{color:var(--dsw-alias-label-tertiary);margin:0;font-size:12px;line-height:18px}.zGbnIq_modelList{flex-direction:column;gap:8px;display:flex}.zGbnIq_modelListHead{justify-content:space-between;align-items:flex-start;gap:12px;display:flex}.zGbnIq_modelEntry{border:.5px solid var(--dsw-alias-border-l4);border-radius:var(--dsw-radius-lg);padding:6px}.zGbnIq_modelRow{grid-template-columns:minmax(0,1.4fr) minmax(0,1fr) auto auto;align-items:center;gap:6px;display:grid}.zGbnIq_iconButton{box-sizing:border-box;border-radius:var(--dsw-radius-sm);width:28px;height:28px;color:var(--dsw-alias-label-tertiary);cursor:pointer;background:0 0;border:none;justify-content:center;align-items:center;display:inline-flex}.zGbnIq_iconButton:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-primary)}.zGbnIq_iconButton:disabled{cursor:default;opacity:.4}.zGbnIq_iconButtonDanger:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover-danger);color:var(--dsw-alias-state-error-primary)}.zGbnIq_modelAdvanced{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;padding:8px 4px 2px;display:grid}.zGbnIq_modelField{flex-direction:column;gap:4px;min-width:0;display:flex}.zGbnIq_modelInputTypes{border:none;grid-column:1/-1;min-width:0;margin:0;padding:0}.zGbnIq_modelInputTypes legend{margin-bottom:4px;padding:0}.zGbnIq_modelInputChoices{flex-wrap:wrap;align-items:center;gap:16px;min-height:32px;display:flex}.zGbnIq_modelFieldLabel{color:var(--dsw-alias-label-tertiary);font-size:12px;line-height:18px}.zGbnIq_modelReasoning{flex-direction:column;grid-column:1/-1;gap:6px;min-width:0;display:flex}.zGbnIq_modelReasoningLabel{align-items:center;gap:6px;display:inline-flex}.zGbnIq_modelReasoningHead{justify-content:space-between;align-items:center;gap:8px;display:flex}.zGbnIq_modelReasoningRow{grid-template-columns:minmax(0,1fr) minmax(0,1fr) auto;align-items:center;gap:6px;display:grid}.zGbnIq_modelReasoningRow .zGbnIq_selectInput{max-width:none}.zGbnIq_modelReasoningValueInput{font-family:var(--ds-font-family-code);font-size:13px}.zGbnIq_modelEmpty{border:1px dashed var(--dsw-alias-border-l3);border-radius:var(--dsw-radius-lg);text-align:center;padding:12px}.zGbnIq_addModelButton{box-sizing:border-box;border:.5px solid var(--dsw-alias-border-l3);border-radius:var(--dsw-radius-sm);height:28px;color:var(--dsw-alias-label-primary);font:inherit;cursor:pointer;background:0 0;align-self:flex-start;align-items:center;gap:4px;padding:0 10px;font-size:12px;line-height:18px;display:inline-flex}.zGbnIq_addModelButton:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover)}.zGbnIq_input{box-sizing:border-box;border:.5px solid var(--dsw-alias-border-l4);border-radius:var(--dsw-radius-md);width:100%;height:32px;font:inherit;background:var(--dsw-alias-bg-layer-1);color:var(--dsw-alias-label-primary);padding:0 10px;font-size:14px;line-height:22px}select.zGbnIq_input{cursor:pointer;max-width:240px}.zGbnIq_input:focus{border-color:var(--dsw-alias-state-business-primary);outline:none}.zGbnIq_input::placeholder{color:var(--dsw-alias-label-dimmed)}.zGbnIq_input:disabled{opacity:.6;cursor:default}.zGbnIq_keyInput{position:relative}.zGbnIq_keyInputFilled{padding-right:40px}.zGbnIq_keyToggle{border-radius:var(--dsw-radius-md);width:32px;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:none;justify-content:center;align-items:center;padding:0;display:inline-flex;position:absolute;inset:1px 1px 1px auto}.zGbnIq_keyToggle:hover:not(:disabled){color:var(--dsw-alias-label-primary)}.zGbnIq_keyToggle:focus-visible{outline:var(--dsw-focus-ring-width) solid var(--dsw-focus-ring-color,var(--dsw-alias-state-business-primary));outline-offset:-2px}.zGbnIq_keyToggle:disabled{opacity:.6;cursor:default}.zGbnIq_selectInput{appearance:none;background-image:url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M3 4.5L6 7.5L9 4.5' stroke='%2381858C' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E\");background-position:right 12px center;background-repeat:no-repeat;background-size:12px 12px;padding-right:32px}.zGbnIq_error{color:var(--dsw-alias-state-error-primary);margin:0;font-size:12px;line-height:18px}.zGbnIq_deleteDialog{width:min(480px,100%)}.zGbnIq_deleteConfirm:not(:disabled){border-color:var(--dsw-alias-state-error-primary);color:var(--dsw-alias-state-error-primary)}.zGbnIq_deleteConfirm:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover-danger)}.zGbnIq_hiddenLabel{clip:rect(0 0 0 0);white-space:nowrap;width:1px;height:1px;position:absolute;overflow:hidden}@media (prefers-reduced-motion:reduce){.zGbnIq_customizedSummary:before,.zGbnIq_switchThumb{transition:none}}.zGbnIq_fetchDialog{--dsh-scrollbar-thumb:var(--dsw-alias-scrollbar-bg-l2);--dsh-scrollbar-thumb-hover:var(--dsw-alias-scrollbar-hover-l2);max-width:520px}.zGbnIq_candidateToolbar{align-items:center;gap:8px;margin-bottom:6px;display:flex}.zGbnIq_candidateSearch{flex:240px;min-width:0}.zGbnIq_candidateList{flex-direction:column;gap:2px;max-height:320px;margin:0;padding:0;list-style:none;display:flex;overflow-y:auto}.zGbnIq_candidate{border-radius:var(--dsw-radius-md)}.zGbnIq_candidateLabel{cursor:pointer;align-items:center;gap:8px;padding:6px 8px;display:flex}.zGbnIq_candidateId{min-width:0;font-family:var(--ds-font-family-code);text-overflow:ellipsis;white-space:nowrap;flex:auto;font-size:13px;overflow:hidden}.zGbnIq_candidateEmpty{color:var(--dsw-alias-label-secondary);text-align:center;margin:24px 0;font-size:13px;line-height:20px}";
59
59
  const tagId$3 = "@deepseek-ai/dsh-client-ui-settings-models/ModelsSection.module.css";
60
60
  if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId$3) + "]") === null) {
61
61
  const tag = document.createElement("style");
@@ -65,6 +65,7 @@ window.__ModuleLoader__.load({
65
65
  document.head.appendChild(tag);
66
66
  }
67
67
  var ModelsSection_module_css_default = {
68
+ "accountStatus": "zGbnIq_accountStatus",
68
69
  "addActions": "zGbnIq_addActions",
69
70
  "addBlock": "zGbnIq_addBlock",
70
71
  "addButton": "zGbnIq_addButton",
@@ -98,11 +99,15 @@ window.__ModuleLoader__.load({
98
99
  "fetchDialog": "zGbnIq_fetchDialog",
99
100
  "field": "zGbnIq_field",
100
101
  "fieldLabel": "zGbnIq_fieldLabel",
102
+ "helpButton": "zGbnIq_helpButton",
101
103
  "hiddenLabel": "zGbnIq_hiddenLabel",
102
104
  "iconButton": "zGbnIq_iconButton",
103
105
  "iconButtonDanger": "zGbnIq_iconButtonDanger",
104
106
  "input": "zGbnIq_input",
105
107
  "intro": "zGbnIq_intro",
108
+ "keyInput": "zGbnIq_keyInput",
109
+ "keyInputFilled": "zGbnIq_keyInputFilled",
110
+ "keyToggle": "zGbnIq_keyToggle",
106
111
  "linkButton": "zGbnIq_linkButton",
107
112
  "modelAdvanced": "zGbnIq_modelAdvanced",
108
113
  "modelCatalog": "zGbnIq_modelCatalog",
@@ -117,6 +122,11 @@ window.__ModuleLoader__.load({
117
122
  "modelInputTypes": "zGbnIq_modelInputTypes",
118
123
  "modelList": "zGbnIq_modelList",
119
124
  "modelListHead": "zGbnIq_modelListHead",
125
+ "modelReasoning": "zGbnIq_modelReasoning",
126
+ "modelReasoningHead": "zGbnIq_modelReasoningHead",
127
+ "modelReasoningLabel": "zGbnIq_modelReasoningLabel",
128
+ "modelReasoningRow": "zGbnIq_modelReasoningRow",
129
+ "modelReasoningValueInput": "zGbnIq_modelReasoningValueInput",
120
130
  "modelRow": "zGbnIq_modelRow",
121
131
  "notice": "zGbnIq_notice",
122
132
  "primaryButton": "zGbnIq_primaryButton",
@@ -136,6 +146,55 @@ window.__ModuleLoader__.load({
136
146
  "title": "zGbnIq_title"
137
147
  };
138
148
  //#endregion
149
+ //#region lib/types/client/ApiKeyInput.js
150
+ /** Write-only credential input with the same reveal behavior as masked conversation text. */
151
+ const EYE_CONTOUR = "M1.5 8C2.9 5.25 5.25 3.5 8 3.5C10.75 3.5 13.1 5.25 14.5 8C13.1 10.75 10.75 12.5 8 12.5C5.25 12.5 2.9 10.75 1.5 8Z";
152
+ const EYE_PATH = `${EYE_CONTOUR}M10 8C10 9.1 9.1 10 8 10C6.9 10 6 9.1 6 8C6 6.9 6.9 6 8 6C9.1 6 10 6.9 10 8Z`;
153
+ const EYE_OFF_PATH = `${EYE_CONTOUR}M2.5 2.5L13.5 13.5`;
154
+ /**
155
+ * Reveal only a nonempty draft; a different value starts masked, as in SecretText.
156
+ * @param props - current draft, input attributes, and translated control labels.
157
+ * @returns a password input with an optional reveal button.
158
+ */
159
+ function ApiKeyInput({ value, t, ...props }) {
160
+ const [revealedValue, setRevealedValue] = (0, react.useState)();
161
+ const revealed = value.length > 0 && revealedValue === value;
162
+ return (0, react_jsx_runtime.jsxs)("div", {
163
+ className: ModelsSection_module_css_default["keyInput"],
164
+ children: [(0, react_jsx_runtime.jsx)("input", {
165
+ ...props,
166
+ className: `${ModelsSection_module_css_default["input"]} ${value.length > 0 ? ModelsSection_module_css_default["keyInputFilled"] : ""}`,
167
+ type: revealed ? "text" : "password",
168
+ autoComplete: "new-password",
169
+ value,
170
+ onChange: (event) => {
171
+ setRevealedValue(void 0);
172
+ props.onChange?.(event);
173
+ }
174
+ }), value.length === 0 ? null : (0, react_jsx_runtime.jsx)("button", {
175
+ type: "button",
176
+ className: ModelsSection_module_css_default["keyToggle"],
177
+ "aria-label": t(revealed ? "keyHide" : "keyReveal"),
178
+ "aria-pressed": revealed,
179
+ disabled: props.disabled,
180
+ onClick: () => {
181
+ setRevealedValue(revealed ? void 0 : value);
182
+ },
183
+ children: (0, react_jsx_runtime.jsx)("svg", {
184
+ width: "16",
185
+ height: "16",
186
+ viewBox: "0 0 16 16",
187
+ fill: "none",
188
+ stroke: "currentColor",
189
+ strokeWidth: 1.3,
190
+ strokeLinecap: "round",
191
+ "aria-hidden": "true",
192
+ children: (0, react_jsx_runtime.jsx)("path", { d: revealed ? EYE_OFF_PATH : EYE_PATH })
193
+ })
194
+ })]
195
+ });
196
+ }
197
+ //#endregion
139
198
  //#region lib/types/client/EditorFooter.js
140
199
  /**
141
200
  * Render one provider card's action row.
@@ -200,6 +259,224 @@ window.__ModuleLoader__.load({
200
259
  });
201
260
  }
202
261
  //#endregion
262
+ //#region lib/types/client/ModelReasoningEfforts.js
263
+ /** Reasoning-level declarations for a model on a hand-declared pi-ai route. */
264
+ /** Levels a model offers when the switch is turned on, where the schema lists them: Off plus the common OpenAI-compatible trio. */
265
+ const INITIAL_LEVELS = [
266
+ "off",
267
+ "low",
268
+ "medium",
269
+ "high"
270
+ ];
271
+ /** The wire value a level sends unless its row says otherwise; `null` is the Off entry that sends nothing. */
272
+ function defaultValue(level) {
273
+ return level === "off" ? null : level;
274
+ }
275
+ /**
276
+ * Whether pi-ai accepts a stored value: a non-empty string, or nothing for Off.
277
+ * @param level - the declared level.
278
+ * @param wire - the value stored for it.
279
+ * @returns whether the adapter would resolve the entry.
280
+ */
281
+ function acceptedValue(level, wire) {
282
+ return typeof wire === "string" ? wire.length > 0 : wire === null && level === "off";
283
+ }
284
+ /**
285
+ * Read the declared levels from a row in their stored order, including a key
286
+ * the offered levels do not name, so an edit never drops it.
287
+ * @param model - model row as drafted.
288
+ * @returns the entries; empty for a valueless field, which pi-ai refuses, and
289
+ * `undefined` when the field is absent or `false`.
290
+ */
291
+ function readEfforts(model) {
292
+ const value = model["reasoningEfforts"];
293
+ if (value === null) return [];
294
+ if (typeof value !== "object" || Array.isArray(value)) return void 0;
295
+ return Object.entries(value);
296
+ }
297
+ /**
298
+ * Replace a row's declared levels, preserving every other field.
299
+ * @param model - model row as drafted.
300
+ * @param entries - the levels to write in row order, or `undefined` to remove the field.
301
+ * @returns the replacement row.
302
+ */
303
+ function withEfforts(model, entries) {
304
+ const next = { ...model };
305
+ if (entries === void 0) {
306
+ Reflect.deleteProperty(next, "reasoningEfforts");
307
+ return next;
308
+ }
309
+ next["reasoningEfforts"] = Object.fromEntries(entries);
310
+ return next;
311
+ }
312
+ /**
313
+ * Mirror the pi-ai refusals of a hand-declared `reasoningEfforts`, so a card
314
+ * names the row instead of failing at the write.
315
+ * @param value - drafted `models` value, or `undefined` while inherited.
316
+ * @returns the first refused row, or `undefined` when the adapter will accept every row.
317
+ */
318
+ function validateReasoningEfforts(value) {
319
+ for (const [index, model] of modelDrafts(value).entries()) {
320
+ const entries = readEfforts(model);
321
+ if (entries === void 0) continue;
322
+ if (entries.some(([level, wire]) => !acceptedValue(level, wire))) return {
323
+ index,
324
+ key: "modelReasoningValueRequired"
325
+ };
326
+ if (!entries.some(([level]) => level !== "off")) return {
327
+ index,
328
+ key: "modelReasoningNeedsLevel"
329
+ };
330
+ }
331
+ }
332
+ /**
333
+ * Edit the `reasoningEfforts` a hand-declared pi-ai model offers: a switch,
334
+ * then one row per level pairing the level with the value sent for it. Every
335
+ * row is read from the model, so a reused instance shows its new model.
336
+ * @param props - model declaration and row replacement action.
337
+ * @returns the reasoning-level group.
338
+ */
339
+ function ModelReasoningEfforts({ model, levels, position, disabled, t, onChange }) {
340
+ const entries = readEfforts(model);
341
+ const [typing, setTyping] = (0, react.useState)(void 0);
342
+ const label = `${t("modelReasoning")} ${String(position)}`;
343
+ const used = entries?.map(([level]) => level) ?? [];
344
+ const write = (next) => {
345
+ onChange(withEfforts(model, next));
346
+ };
347
+ const replaceAt = (current, index, entry) => current.map((existing, at) => at === index ? entry : existing);
348
+ const changeLevel = (current, index, from, wire, to) => {
349
+ write(replaceAt(current, index, [to, typeof wire === "string" && wire.length > 0 && wire !== from && from !== "off" && to !== "off" ? wire : defaultValue(to)]));
350
+ };
351
+ const addLevel = (current) => {
352
+ const highest = Math.max(-1, ...used.map((level) => levels.indexOf(level)));
353
+ const level = levels.find((candidate, index) => index > highest && !used.includes(candidate)) ?? levels.find((candidate) => !used.includes(candidate));
354
+ /* v8 ignore next -- the add button is disabled once every level has a row */
355
+ if (level === void 0) return;
356
+ write([...current, [level, defaultValue(level)]]);
357
+ };
358
+ const editValue = (current, index, level, text) => {
359
+ setTyping({
360
+ level,
361
+ text
362
+ });
363
+ const trimmed = text.trim();
364
+ write(replaceAt(current, index, [level, trimmed.length === 0 ? defaultValue(level) : trimmed]));
365
+ };
366
+ const leaveValue = (current, index, level, wire) => {
367
+ setTyping(void 0);
368
+ if (!acceptedValue(level, wire)) write(replaceAt(current, index, [level, defaultValue(level)]));
369
+ };
370
+ const choicesFor = (level) => [...levels.includes(level) ? [] : [level], ...levels.filter((choice) => choice === level || !used.includes(choice))];
371
+ const initialEntries = INITIAL_LEVELS.filter((level) => levels.includes(level)).map((level) => [level, defaultValue(level)]);
372
+ const refused = entries?.some(([level, wire]) => !acceptedValue(level, wire)) === true;
373
+ const missingLevel = entries !== void 0 && !used.some((level) => level !== "off");
374
+ return (0, react_jsx_runtime.jsxs)("div", {
375
+ className: ModelsSection_module_css_default["modelReasoning"],
376
+ role: "group",
377
+ "aria-label": label,
378
+ children: [(0, react_jsx_runtime.jsxs)("div", {
379
+ className: ModelsSection_module_css_default["modelReasoningHead"],
380
+ children: [(0, react_jsx_runtime.jsxs)("span", {
381
+ className: `${ModelsSection_module_css_default["modelFieldLabel"]} ${ModelsSection_module_css_default["modelReasoningLabel"]}`,
382
+ children: [t("modelReasoning"), (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Tooltip, {
383
+ label: t("modelReasoningHelpText"),
384
+ side: "right",
385
+ delayMs: 0,
386
+ focusDelayMs: 0,
387
+ portal: true,
388
+ openOnClick: true,
389
+ children: (0, react_jsx_runtime.jsx)("button", {
390
+ type: "button",
391
+ className: ModelsSection_module_css_default["helpButton"],
392
+ "aria-label": t("modelReasoningHelp"),
393
+ children: "?"
394
+ })
395
+ })]
396
+ }), (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Switch, {
397
+ checked: entries !== void 0,
398
+ label,
399
+ disabled,
400
+ onChange: (on) => {
401
+ write(on ? initialEntries : void 0);
402
+ }
403
+ })]
404
+ }), entries === void 0 ? null : (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [
405
+ entries.length > 0 ? (0, react_jsx_runtime.jsxs)("div", {
406
+ className: ModelsSection_module_css_default["modelReasoningRow"],
407
+ "aria-hidden": "true",
408
+ children: [(0, react_jsx_runtime.jsx)("span", {
409
+ className: ModelsSection_module_css_default["modelFieldLabel"],
410
+ children: t("modelReasoningLevel")
411
+ }), (0, react_jsx_runtime.jsx)("span", {
412
+ className: ModelsSection_module_css_default["modelFieldLabel"],
413
+ children: t("modelReasoningValue")
414
+ })]
415
+ }) : null,
416
+ entries.map(([level, wire], index) => (0, react_jsx_runtime.jsxs)("div", {
417
+ className: ModelsSection_module_css_default["modelReasoningRow"],
418
+ children: [
419
+ (0, react_jsx_runtime.jsx)("select", {
420
+ className: `${ModelsSection_module_css_default["input"]} ${ModelsSection_module_css_default["selectInput"]}`,
421
+ value: level,
422
+ "aria-label": `${t("modelReasoningLevel")} ${String(index + 1)}`,
423
+ disabled,
424
+ onChange: (event) => {
425
+ changeLevel(entries, index, level, wire, event.target.value);
426
+ },
427
+ children: choicesFor(level).map((choice) => (0, react_jsx_runtime.jsx)("option", {
428
+ value: choice,
429
+ children: choice
430
+ }, choice))
431
+ }),
432
+ (0, react_jsx_runtime.jsx)("input", {
433
+ className: `${ModelsSection_module_css_default["input"]} ${ModelsSection_module_css_default["modelReasoningValueInput"]}`,
434
+ type: "text",
435
+ value: typing?.level === level ? typing.text : typeof wire === "string" ? wire : "",
436
+ placeholder: level === "off" ? t("modelReasoningOffValuePlaceholder") : level,
437
+ "aria-label": `${level} ${t("modelReasoningValue")}`,
438
+ "aria-invalid": !acceptedValue(level, wire),
439
+ disabled: disabled || level === "off",
440
+ onChange: (event) => {
441
+ editValue(entries, index, level, event.target.value);
442
+ },
443
+ onBlur: () => {
444
+ leaveValue(entries, index, level, wire);
445
+ }
446
+ }),
447
+ (0, react_jsx_runtime.jsx)("button", {
448
+ type: "button",
449
+ className: `${ModelsSection_module_css_default["iconButton"]} ${ModelsSection_module_css_default["iconButtonDanger"]}`,
450
+ "aria-label": `${t("modelReasoningRemove")} ${level}`,
451
+ title: t("modelReasoningRemove"),
452
+ disabled,
453
+ onClick: () => {
454
+ write(entries.filter((_entry, at) => at !== index));
455
+ },
456
+ children: (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconTrashOutlineRegular, { size: 14 })
457
+ })
458
+ ]
459
+ }, index)),
460
+ refused ? (0, react_jsx_runtime.jsx)("p", {
461
+ className: ModelsSection_module_css_default["error"],
462
+ children: t("modelReasoningValueRequired")
463
+ }) : missingLevel ? (0, react_jsx_runtime.jsx)("p", {
464
+ className: ModelsSection_module_css_default["error"],
465
+ children: t("modelReasoningNeedsLevel")
466
+ }) : null,
467
+ (0, react_jsx_runtime.jsxs)("button", {
468
+ type: "button",
469
+ className: ModelsSection_module_css_default["addModelButton"],
470
+ disabled: disabled || levels.every((level) => used.includes(level)),
471
+ onClick: () => {
472
+ addLevel(entries);
473
+ },
474
+ children: [(0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconPlusOutlineRegular, { size: 14 }), t("modelReasoningAdd")]
475
+ })
476
+ ] })]
477
+ });
478
+ }
479
+ //#endregion
203
480
  //#region lib/types/client/ModelRow.js
204
481
  /**
205
482
  * Render consistent model identity, capacity, and input-type controls.
@@ -247,33 +524,44 @@ window.__ModuleLoader__.load({
247
524
  ]
248
525
  }), props.expanded ? (0, react_jsx_runtime.jsxs)("div", {
249
526
  className: ModelsSection_module_css_default["modelAdvanced"],
250
- children: [["contextWindow", "maxTokens"].map((field) => (0, react_jsx_runtime.jsxs)("label", {
251
- className: ModelsSection_module_css_default["modelField"],
252
- children: [(0, react_jsx_runtime.jsx)("span", {
253
- className: ModelsSection_module_css_default["modelFieldLabel"],
254
- children: t(field)
255
- }), (0, react_jsx_runtime.jsx)("input", {
256
- className: ModelsSection_module_css_default["input"],
257
- type: "text",
258
- inputMode: "numeric",
259
- value: props[field].value,
260
- placeholder: props[field].placeholder,
261
- "aria-label": `${t(field)} ${String(position)}`,
527
+ children: [
528
+ ["contextWindow", "maxTokens"].map((field) => (0, react_jsx_runtime.jsxs)("label", {
529
+ className: ModelsSection_module_css_default["modelField"],
530
+ children: [(0, react_jsx_runtime.jsx)("span", {
531
+ className: ModelsSection_module_css_default["modelFieldLabel"],
532
+ children: t(field)
533
+ }), (0, react_jsx_runtime.jsx)("input", {
534
+ className: ModelsSection_module_css_default["input"],
535
+ type: "text",
536
+ inputMode: "numeric",
537
+ value: props[field].value,
538
+ placeholder: props[field].placeholder,
539
+ "aria-label": `${t(field)} ${String(position)}`,
540
+ disabled,
541
+ onChange: (event) => {
542
+ props[field].onChange(event.target.value);
543
+ },
544
+ onBlur: props[field].onBlur
545
+ })]
546
+ }, field)),
547
+ (0, react_jsx_runtime.jsx)(ModelInputTypes, {
548
+ model,
549
+ field: props.inputField,
550
+ position,
551
+ fallback: props.inputFallback,
552
+ disabled: disabled || props.inputLoading === true,
553
+ t,
554
+ onChange: props.onChange
555
+ }),
556
+ props.reasoningLevels !== void 0 && props.reasoningLevels.length > 0 ? (0, react_jsx_runtime.jsx)(ModelReasoningEfforts, {
557
+ model,
558
+ levels: props.reasoningLevels,
559
+ position,
262
560
  disabled,
263
- onChange: (event) => {
264
- props[field].onChange(event.target.value);
265
- },
266
- onBlur: props[field].onBlur
267
- })]
268
- }, field)), (0, react_jsx_runtime.jsx)(ModelInputTypes, {
269
- model,
270
- field: props.inputField,
271
- position,
272
- fallback: props.inputFallback,
273
- disabled: disabled || props.inputLoading === true,
274
- t,
275
- onChange: props.onChange
276
- })]
561
+ t,
562
+ onChange: props.onChange
563
+ }) : null
564
+ ]
277
565
  }) : null]
278
566
  });
279
567
  }
@@ -770,6 +1058,7 @@ window.__ModuleLoader__.load({
770
1058
  inputField: "input",
771
1059
  inputFallback: inputDefaults.get(textOf(model, "id")) ?? props.defaultInput,
772
1060
  inputLoading: catalogProvider !== void 0 && catalog === void 0,
1061
+ reasoningLevels: props.reasoningLevels,
773
1062
  expanded: expanded.has(index),
774
1063
  disabled,
775
1064
  t,
@@ -914,6 +1203,9 @@ window.__ModuleLoader__.load({
914
1203
  settingsPath: [...entry.settingsPath],
915
1204
  active: active.has(entry.provider),
916
1205
  ...entry.declared === void 0 ? {} : { declared: entry.declared },
1206
+ ...entry.defaultBaseURL === void 0 ? {} : { defaultBaseURL: entry.defaultBaseURL },
1207
+ ...entry.baseURLEnv === void 0 ? {} : { baseURLEnv: entry.baseURLEnv },
1208
+ ...entry.nativeAuth === void 0 ? {} : { nativeAuth: entry.nativeAuth },
917
1209
  ...entry.error === void 0 ? {} : { error: entry.error }
918
1210
  }));
919
1211
  for (const provider of registered) {
@@ -957,6 +1249,26 @@ window.__ModuleLoader__.load({
957
1249
  if (list?.type !== "union" || list.list === void 0) return [];
958
1250
  return list.list.map((entry) => entry.value).filter((value) => typeof value === "string");
959
1251
  }
1252
+ /**
1253
+ * The reasoning levels a hand-declared route's models may declare, read out of
1254
+ * the owning namespace's own schema for the same reason as
1255
+ * {@link protocolChoices}: the levels the page offers and the keys the
1256
+ * adapter accepts in `reasoningEfforts` come from the same `Config`.
1257
+ * @param namespace - the namespace view whose schema declares the profile shape.
1258
+ * @param schema - settings schema operations.
1259
+ * @returns the levels in the schema's escalation order, or an empty list when the schema has none.
1260
+ */
1261
+ function reasoningLevelChoices(namespace, schema) {
1262
+ if (namespace === void 0) return [];
1263
+ const path = [
1264
+ "providers",
1265
+ PROBE_ROUTE,
1266
+ "models",
1267
+ "0",
1268
+ "reasoningEfforts"
1269
+ ];
1270
+ return (((schema.nodeAtPath(schema.rehydrate(namespace.schema), path)?.list ?? []).find((branch) => branch.type === "dict")?.sKey)?.list ?? []).map((entry) => entry.value).filter((value) => typeof value === "string");
1271
+ }
960
1272
  /** The credential reference a resolved profile names (its `apiKeyEnv` field). */
961
1273
  function apiKeyEnvOf(namespace, path, schema) {
962
1274
  if (namespace === void 0) return void 0;
@@ -1041,7 +1353,9 @@ window.__ModuleLoader__.load({
1041
1353
  }
1042
1354
  const mirrored = this.describeFace.getSnapshot();
1043
1355
  if (mirrored.view === void 0) {
1044
- this.failLoad(mirrored.error ?? "settings are unavailable in this browser");
1356
+ /* v8 ignore next -- SettingsDescribeFace.ensure settles with a view or the read's error */
1357
+ if (mirrored.error === null) throw new Error("settings describe settled with neither a view nor an error");
1358
+ this.failLoad(mirrored.error);
1045
1359
  return;
1046
1360
  }
1047
1361
  const providers = joinProviderDirectory(registered.value, declared.value);
@@ -1062,13 +1376,16 @@ window.__ModuleLoader__.load({
1062
1376
  const catalog = await this.ctx.remote.session.modelCatalog();
1063
1377
  for (const row of rows) if (row.entry.provider === "deepseek-account") row.accountAvailable = catalog.ok && catalog.value.groups.some((group) => group.id === "deepseek-account" && group.models.length > 0);
1064
1378
  }
1065
- const refs = [...new Set(rows.filter((row) => row.entry.provider !== "deepseek-account").map((row) => row.apiKeyEnv ?? deriveKeyRef(row.entry.provider)))];
1066
- let credentials = {};
1379
+ const refs = [...new Set(rows.filter((row) => row.entry.provider !== "deepseek-account").flatMap((row) => row.apiKeyEnv === void 0 ? [deriveKeyRef(row.entry.provider), ...row.entry.nativeAuth?.env ?? []] : [row.apiKeyEnv]))];
1380
+ const credentials = {};
1067
1381
  let credentialError = null;
1068
- if (refs.length > 0) {
1069
- const response = await this.ctx.remote.credentials.describe(refs);
1070
- if (response.ok) credentials = response.value;
1071
- else credentialError = response.error.message;
1382
+ for (let index = 0; index < refs.length; index += 64) {
1383
+ const response = await this.ctx.remote.credentials.describe(refs.slice(index, index + 64));
1384
+ if (response.ok) Object.assign(credentials, response.value);
1385
+ else {
1386
+ credentialError = response.error.message;
1387
+ break;
1388
+ }
1072
1389
  }
1073
1390
  if (generation !== this.generation) return;
1074
1391
  this.store.update((s) => {
@@ -1083,7 +1400,11 @@ window.__ModuleLoader__.load({
1083
1400
  return {
1084
1401
  ...row,
1085
1402
  ...named === void 0 ? {} : { credential: named },
1086
- ...derived === void 0 ? {} : { derivedCredential: derived }
1403
+ ...derived === void 0 ? {} : { derivedCredential: derived },
1404
+ ...credentialError === null ? { credentialChecks: Object.fromEntries((row.apiKeyEnv === void 0 ? row.entry.nativeAuth?.env ?? [] : [row.apiKeyEnv]).flatMap((ref) => {
1405
+ const info = credentials[ref];
1406
+ return info === void 0 ? [] : [[ref, info]];
1407
+ })) } : {}
1087
1408
  };
1088
1409
  });
1089
1410
  s.namespaces = namespaces;
@@ -1203,11 +1524,12 @@ window.__ModuleLoader__.load({
1203
1524
  * and at least one model — are required here rather than at load, so the
1204
1525
  * failure names the field while the user is still looking at it.
1205
1526
  *
1206
- * There is deliberately no reasoning-effort control, here or on the editor
1207
- * card: effort is a per-MODEL capability, and the models under one provider
1208
- * disagree about it, so a provider-scoped control can only be set to a value
1209
- * some of them reject. The composer's model picker offers each model its own
1210
- * levels instead.
1527
+ * There is deliberately no provider-scoped reasoning-effort control, here or
1528
+ * on the editor card: effort is a per-MODEL capability, and the models under
1529
+ * one provider disagree about it, so a provider-scoped control can only be set
1530
+ * to a value some of them reject. Each model row of a hand-declared route
1531
+ * declares its own `reasoningEfforts` instead, and the composer's model picker
1532
+ * offers each model those levels.
1211
1533
  */
1212
1534
  /** The settings namespace a hand-declared provider is written into. */
1213
1535
  const NS$1 = "llm-pi-ai";
@@ -1234,7 +1556,7 @@ window.__ModuleLoader__.load({
1234
1556
  * @returns the creation card.
1235
1557
  */
1236
1558
  function CustomProviderCard(props) {
1237
- const { taken, protocols, operations, t, onBusyChange } = props;
1559
+ const { taken, protocols, reasoningLevels, operations, t, onBusyChange } = props;
1238
1560
  const [openedAt] = (0, react.useState)(() => props.revision);
1239
1561
  const [route, setRoute] = (0, react.useState)("");
1240
1562
  const [displayName, setDisplayName] = (0, react.useState)("");
@@ -1265,7 +1587,7 @@ window.__ModuleLoader__.load({
1265
1587
  const routeTaken = taken.includes(route);
1266
1588
  const normalizedBaseURL = baseURL.trim();
1267
1589
  const baseUrlInvalid = baseURL.length > 0 && !isHttpUrl(normalizedBaseURL);
1268
- const modelFailure = validateDeepSeekModels(models);
1590
+ const modelFailure = validateDeepSeekModels(models) ?? validateReasoningEfforts(models);
1269
1591
  const keyFailure = apiKeyFailure(keyDraft);
1270
1592
  const keyValue = keyDraft.trim();
1271
1593
  const ready = route.length > 0 && !routeInvalid && !routeTaken && normalizedBaseURL.length > 0 && !baseUrlInvalid && models.length > 0 && modelFailure === void 0 && keyFailure === void 0;
@@ -1401,10 +1723,8 @@ window.__ModuleLoader__.load({
1401
1723
  className: ModelsSection_module_css_default["fieldLabel"],
1402
1724
  children: t("keyInput")
1403
1725
  }),
1404
- (0, react_jsx_runtime.jsx)("input", {
1405
- className: ModelsSection_module_css_default["input"],
1406
- type: "password",
1407
- autoComplete: "new-password",
1726
+ (0, react_jsx_runtime.jsx)(ApiKeyInput, {
1727
+ t,
1408
1728
  value: keyDraft,
1409
1729
  placeholder: t("keyPlaceholder"),
1410
1730
  "aria-label": t("keyInput"),
@@ -1422,6 +1742,7 @@ window.__ModuleLoader__.load({
1422
1742
  (0, react_jsx_runtime.jsx)(ModelListEditor, {
1423
1743
  models,
1424
1744
  onChange: setModels,
1745
+ reasoningLevels,
1425
1746
  probe: {
1426
1747
  settingsNs: NS$1,
1427
1748
  baseURL: normalizedBaseURL,
@@ -1536,7 +1857,6 @@ window.__ModuleLoader__.load({
1536
1857
  const { namespace, schema, settingsPath, operations, t } = props;
1537
1858
  const [draft, setDraft] = (0, react.useState)(() => draftAt(schema, namespace, settingsPath));
1538
1859
  const [keyDraft, setKeyDraft] = (0, react.useState)("");
1539
- const [keyState, setKeyState] = (0, react.useState)(void 0);
1540
1860
  const [busy, setBusy] = (0, react.useState)(false);
1541
1861
  const [listBusy, setListBusy] = (0, react.useState)(false);
1542
1862
  const { onBusyChange } = props;
@@ -1558,30 +1878,13 @@ window.__ModuleLoader__.load({
1558
1878
  ]);
1559
1879
  const fallback = schema.getPath(namespace.value, settingsPath);
1560
1880
  const disabled = props.readOnly || busy;
1561
- const accountProvider = props.provider === "deepseek-account";
1562
- const layout = accountProvider ? "deepseek" : layoutOf(namespace.ns);
1881
+ const layout = layoutOf(namespace.ns);
1563
1882
  const keyRef = refFor(schema, namespace, settingsPath, props.provider);
1564
1883
  const protocols = (0, react.useMemo)(() => layout === "pi-ai" ? protocolChoices(namespace, schema) : [], [
1565
1884
  layout,
1566
1885
  namespace,
1567
1886
  schema
1568
1887
  ]);
1569
- (0, react.useEffect)(() => {
1570
- if (accountProvider) return;
1571
- let stale = false;
1572
- setKeyState(void 0);
1573
- operations.describeCredential(keyRef).then((described) => {
1574
- if (stale) return;
1575
- setKeyState(described);
1576
- });
1577
- return () => {
1578
- stale = true;
1579
- };
1580
- }, [
1581
- operations,
1582
- keyRef,
1583
- accountProvider
1584
- ]);
1585
1888
  const stringAt = (source, key) => {
1586
1889
  const value = schema.getPath(source, [key]);
1587
1890
  return typeof value === "string" && value.trim().length > 0 ? value : void 0;
@@ -1590,7 +1893,15 @@ window.__ModuleLoader__.load({
1590
1893
  const value = next === void 0 || next.trim().length === 0 ? void 0 : next;
1591
1894
  setDraft((current) => value === void 0 ? schema.deletePath(current, [key]) : schema.setPath(current, [key], value));
1592
1895
  };
1593
- const modelFailure = validateDeepSeekModels(schema.getPath(draft, ["models"]));
1896
+ const reasoningLevels = (0, react.useMemo)(() => layout === "pi-ai" && props.declared === true ? reasoningLevelChoices(namespace, schema) : [], [
1897
+ layout,
1898
+ props.declared,
1899
+ namespace,
1900
+ schema
1901
+ ]);
1902
+ const editsReasoning = reasoningLevels.length > 0;
1903
+ const validateModels = (value) => validateDeepSeekModels(value) ?? (editsReasoning ? validateReasoningEfforts(value) : void 0);
1904
+ const modelFailure = validateModels(schema.getPath(draft, ["models"]));
1594
1905
  const keyFailure = apiKeyFailure(keyDraft);
1595
1906
  const keyValue = keyDraft.trim();
1596
1907
  const shownKeyFailure = (props.credentialRequired === true && keyDraft.length > 0 && keyValue.length === 0 ? "keyRequired" : void 0) ?? keyFailure;
@@ -1613,7 +1924,7 @@ window.__ModuleLoader__.load({
1613
1924
  const ns = namespace.ns;
1614
1925
  const next = layout === "pi-ai" && stringAt(draft, "apiKeyEnv") === void 0 && stringAt(fallback, "apiKeyEnv") === void 0 && keyValue.length > 0 ? schema.setPath(draft, ["apiKeyEnv"], keyRef) : draft;
1615
1926
  if (props.credentialOnly !== true) {
1616
- const failure = validateDeepSeekModels(schema.getPath(next, ["models"]));
1927
+ const failure = validateModels(schema.getPath(next, ["models"]));
1617
1928
  /* v8 ignore next 3 -- unreachable from the card: the same failure disables submit */
1618
1929
  if (failure !== void 0) return `${t("model")} ${String(failure.index + 1)}: ${t(failure.key)}`;
1619
1930
  }
@@ -1663,7 +1974,6 @@ window.__ModuleLoader__.load({
1663
1974
  props.t("settingsPathUnresolvable")
1664
1975
  ]
1665
1976
  });
1666
- const keyLocked = keyState?.writable === false;
1667
1977
  /**
1668
1978
  * The catalog beneath the user layer: what the composition entry pinned, or
1669
1979
  * else the schema default that `resolve` would supply. The effective value
@@ -1687,7 +1997,38 @@ window.__ModuleLoader__.load({
1687
1997
  const defaultContextWindow = schema.getPath(fallback, ["defaultContextWindow"]);
1688
1998
  const defaultMaxTokens = schema.getPath(fallback, ["maxTokens"]);
1689
1999
  const defaultInput = schema.getPath(fallback, ["defaultInput"]);
1690
- const keyPlaceholder = keyLocked ? t("keyEnvLocked") : keyState?.configured === true && props.credentialRequired !== true ? t("keyStored") : family === "pi-ai" ? t("keyPlaceholderNative") : t("keyPlaceholder");
2000
+ const baseURL = stringAt(fallback, "baseURL") ?? props.defaultBaseURL;
2001
+ const endpointEnv = props.baseURLEnv ?? [];
2002
+ const endpointHint = family === "deepseek" ? t("deepSeekEndpointHint") : baseURL === void 0 && endpointEnv.length > 0 ? t("baseUrlEnvironment").replace("{env}", () => endpointEnv.join(", ")) : void 0;
2003
+ const namedRef = stringAt(fallback, "apiKeyEnv");
2004
+ const nativeAuth = namedRef === void 0 ? props.nativeAuth : void 0;
2005
+ const authRefs = namedRef === void 0 ? (nativeAuth?.env ?? []).filter((ref) => !endpointEnv.includes(ref)) : [namedRef];
2006
+ const visibleRefs = authRefs.filter((ref) => !ref.toLowerCase().includes("oauth"));
2007
+ const keyHint = visibleRefs[0];
2008
+ const checkedRefs = authRefs.map((ref) => [ref, props.credentialChecks?.[ref] ?? (ref === namedRef ? props.credential : void 0)]);
2009
+ const detected = checkedRefs.find(([, info]) => info?.configured === true);
2010
+ const detectedRef = detected?.[0];
2011
+ const detectedVisibleRef = detectedRef === void 0 || !visibleRefs.includes(detectedRef) ? void 0 : detectedRef;
2012
+ const missingRefs = checkedRefs.length > 0 && checkedRefs.every(([, info]) => info?.configured === false);
2013
+ const savedCredential = detected?.[1]?.source === "file";
2014
+ const credentialHint = keyDraft.length > 0 || savedCredential || keyHint === void 0 || props.credentialRequired === true ? void 0 : t(detectedRef === void 0 ? missingRefs ? "keyFallbackMissing" : "keyFallbackUnchecked" : detectedVisibleRef === void 0 ? "keyFallbackDetectedHidden" : "keyFallbackDetected").replace("{hint}", () => detectedVisibleRef ?? keyHint);
2015
+ const keyHelp = visibleRefs.length === 0 ? void 0 : t("keyHelp").replace("{env}", () => visibleRefs.join(" / "));
2016
+ const authHelp = keyHelp === void 0 ? null : (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Tooltip, {
2017
+ label: keyHelp,
2018
+ side: "right",
2019
+ delayMs: 0,
2020
+ focusDelayMs: 0,
2021
+ portal: true,
2022
+ openOnClick: true,
2023
+ children: (0, react_jsx_runtime.jsx)("button", {
2024
+ type: "button",
2025
+ className: ModelsSection_module_css_default["helpButton"],
2026
+ "aria-label": t("authHelp"),
2027
+ children: "?"
2028
+ })
2029
+ });
2030
+ const keylessNativeAuth = nativeAuth?.env.length === 0 && nativeAuth.oauth;
2031
+ const keyPlaceholder = keyHint === void 0 || props.credentialRequired === true ? t("keyPlaceholder") : t(savedCredential ? "keyPlaceholderSaved" : "keyPlaceholderFallback").replace("{hint}", () => keyHint);
1691
2032
  /** What both family editors take: the rows, whose layer owns them, and the two writes. */
1692
2033
  const catalogProps = {
1693
2034
  models,
@@ -1701,33 +2042,32 @@ window.__ModuleLoader__.load({
1701
2042
  setDraft((current) => schema.deletePath(current, ["models"]));
1702
2043
  }
1703
2044
  };
1704
- if (accountProvider) return (0, react_jsx_runtime.jsx)(DeepSeekModelsEditor, {
1705
- ...catalogProps,
1706
- defaultContextWindow: typeof defaultContextWindow === "number" ? defaultContextWindow : void 0,
1707
- defaultMaxTokens: typeof defaultMaxTokens === "number" ? defaultMaxTokens : void 0
1708
- });
1709
- return (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [(0, react_jsx_runtime.jsxs)("div", {
2045
+ return (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [keylessNativeAuth ? null : (0, react_jsx_runtime.jsxs)("div", {
1710
2046
  className: ModelsSection_module_css_default["field"],
1711
2047
  children: [
1712
- (0, react_jsx_runtime.jsx)("span", {
2048
+ (0, react_jsx_runtime.jsxs)("span", {
1713
2049
  className: ModelsSection_module_css_default["fieldLabel"],
1714
- children: t("keyInput")
2050
+ children: [t("keyInput"), authHelp]
1715
2051
  }),
1716
- (0, react_jsx_runtime.jsx)("input", {
1717
- className: ModelsSection_module_css_default["input"],
1718
- type: "password",
1719
- autoComplete: "new-password",
2052
+ (0, react_jsx_runtime.jsx)(ApiKeyInput, {
2053
+ t,
1720
2054
  value: keyDraft,
1721
2055
  placeholder: keyPlaceholder,
1722
2056
  "aria-label": t("keyInput"),
1723
2057
  "aria-invalid": shownKeyFailure !== void 0,
2058
+ "aria-describedby": credentialHint === void 0 ? void 0 : `${props.provider}-credential-hint`,
1724
2059
  required: props.credentialRequired === true,
1725
2060
  autoFocus: props.autoFocusCredential === true,
1726
- disabled: disabled || keyLocked,
2061
+ disabled,
1727
2062
  onChange: (event) => {
1728
2063
  setKeyDraft(event.target.value);
1729
2064
  }
1730
2065
  }),
2066
+ credentialHint === void 0 ? null : (0, react_jsx_runtime.jsx)("p", {
2067
+ id: `${props.provider}-credential-hint`,
2068
+ className: ModelsSection_module_css_default[missingRefs ? "notice" : detectedRef === void 0 ? "advancedHint" : "savedNotice"],
2069
+ children: credentialHint
2070
+ }),
1731
2071
  shownKeyFailure === void 0 ? null : (0, react_jsx_runtime.jsx)("p", {
1732
2072
  className: ModelsSection_module_css_default["error"],
1733
2073
  children: t(shownKeyFailure)
@@ -1769,19 +2109,19 @@ window.__ModuleLoader__.load({
1769
2109
  className: ModelsSection_module_css_default["input"],
1770
2110
  type: "text",
1771
2111
  value: stringAt(draft, "baseURL") ?? "",
1772
- placeholder: family === "deepseek" ? t("deepSeekBaseUrl") : stringAt(fallback, "baseURL") ?? t("baseUrlDefault"),
1773
- "aria-describedby": family === "deepseek" ? `${props.provider}-endpoint-hint` : void 0,
2112
+ placeholder: family === "deepseek" ? t("deepSeekBaseUrl") : baseURL === void 0 ? t(endpointEnv.length > 0 ? "baseUrlConfigured" : "baseUrlDefault") : t("baseUrlPlaceholder").replace("{url}", () => baseURL),
2113
+ "aria-describedby": endpointHint === void 0 ? void 0 : `${props.provider}-endpoint-hint`,
1774
2114
  "aria-label": t("baseUrl"),
1775
2115
  disabled,
1776
2116
  onChange: (event) => {
1777
2117
  setField("baseURL", event.target.value === "" ? void 0 : event.target.value);
1778
2118
  }
1779
2119
  }),
1780
- family === "deepseek" ? (0, react_jsx_runtime.jsx)("span", {
2120
+ endpointHint === void 0 ? null : (0, react_jsx_runtime.jsx)("span", {
1781
2121
  id: `${props.provider}-endpoint-hint`,
1782
2122
  className: ModelsSection_module_css_default["advancedHint"],
1783
- children: t("deepSeekEndpointHint")
1784
- }) : null
2123
+ children: endpointHint
2124
+ })
1785
2125
  ]
1786
2126
  }),
1787
2127
  ownsIdentity ? (0, react_jsx_runtime.jsxs)("div", {
@@ -1813,6 +2153,7 @@ window.__ModuleLoader__.load({
1813
2153
  }) : (0, react_jsx_runtime.jsx)(ModelListEditor, {
1814
2154
  ...catalogProps,
1815
2155
  catalogProvider: props.declared === true ? void 0 : props.provider,
2156
+ reasoningLevels,
1816
2157
  defaultInput: Array.isArray(defaultInput) ? defaultInput : void 0,
1817
2158
  probe,
1818
2159
  probeBlocked: keyFailure,
@@ -1891,12 +2232,17 @@ window.__ModuleLoader__.load({
1891
2232
  * post-apply reload.
1892
2233
  */
1893
2234
  /** Render an editor for either the setup posture or an expanded provider row. */
1894
- function renderProviderEditor({ target, ...props }) {
2235
+ function renderProviderEditor({ target, row, ...props }) {
1895
2236
  return (0, react_jsx_runtime.jsx)(ProviderEditor, {
1896
2237
  provider: target.provider,
1897
2238
  displayName: target.displayName,
1898
2239
  settingsPath: target.settingsPath,
1899
2240
  ...target.declared === true ? { declared: true } : {},
2241
+ ...target.defaultBaseURL === void 0 ? {} : { defaultBaseURL: target.defaultBaseURL },
2242
+ ...target.baseURLEnv === void 0 ? {} : { baseURLEnv: target.baseURLEnv },
2243
+ ...target.nativeAuth === void 0 ? {} : { nativeAuth: target.nativeAuth },
2244
+ ...row.credential === void 0 ? {} : { credential: row.credential },
2245
+ ...row.credentialChecks === void 0 ? {} : { credentialChecks: row.credentialChecks },
1900
2246
  ...props
1901
2247
  });
1902
2248
  }
@@ -1956,7 +2302,10 @@ window.__ModuleLoader__.load({
1956
2302
  settingsNs: row.entry.settingsNs,
1957
2303
  settingsPath: row.entry.settingsPath,
1958
2304
  ...credentialRef === void 0 ? {} : { credentialRef },
1959
- ...row.entry.declared === true ? { declared: true } : {}
2305
+ ...row.entry.declared === true ? { declared: true } : {},
2306
+ ...row.entry.defaultBaseURL === void 0 ? {} : { defaultBaseURL: row.entry.defaultBaseURL },
2307
+ ...row.entry.baseURLEnv === void 0 ? {} : { baseURLEnv: row.entry.baseURLEnv },
2308
+ ...row.entry.nativeAuth === void 0 ? {} : { nativeAuth: row.entry.nativeAuth }
1960
2309
  };
1961
2310
  }
1962
2311
  /** Stable visible and accessible identity for one provider target. */
@@ -2117,6 +2466,7 @@ window.__ModuleLoader__.load({
2117
2466
  });
2118
2467
  const piAi = state.namespaces.get("llm-pi-ai");
2119
2468
  const protocols = protocolChoices(piAi, schema);
2469
+ const reasoningLevels = reasoningLevelChoices(piAi, schema);
2120
2470
  const catalogOffered = configurable.length > 0;
2121
2471
  const catalogEnabled = addable.length > 0;
2122
2472
  const customOffered = piAi !== void 0;
@@ -2178,6 +2528,7 @@ window.__ModuleLoader__.load({
2178
2528
  error,
2179
2529
  renderProviderEditor({
2180
2530
  target,
2531
+ row,
2181
2532
  namespace,
2182
2533
  schema,
2183
2534
  operations,
@@ -2213,6 +2564,13 @@ window.__ModuleLoader__.load({
2213
2564
  className: ModelsSection_module_css_default["rowTag"],
2214
2565
  children: t("customTag")
2215
2566
  }) : null,
2567
+ row.entry.provider === "deepseek-account" ? (0, react_jsx_runtime.jsxs)("span", {
2568
+ className: ModelsSection_module_css_default["accountStatus"],
2569
+ children: [(0, react_jsx_runtime.jsx)("span", {
2570
+ className: `${ModelsSection_module_css_default["credentialDot"]} ${ModelsSection_module_css_default["credentialDotConfigured"]}`,
2571
+ "aria-hidden": "true"
2572
+ }), t("accountSignedIn")]
2573
+ }) : null,
2216
2574
  credentialConfigured ? (0, react_jsx_runtime.jsx)("span", {
2217
2575
  className: `${ModelsSection_module_css_default["credentialDot"]} ${ModelsSection_module_css_default["credentialDotConfigured"]}`,
2218
2576
  role: "img",
@@ -2227,7 +2585,7 @@ window.__ModuleLoader__.load({
2227
2585
  ]
2228
2586
  }), (0, react_jsx_runtime.jsxs)("span", {
2229
2587
  className: ModelsSection_module_css_default["rowActions"],
2230
- children: [(0, react_jsx_runtime.jsx)("button", {
2588
+ children: [row.entry.provider === "deepseek-account" ? null : (0, react_jsx_runtime.jsx)("button", {
2231
2589
  type: "button",
2232
2590
  className: ModelsSection_module_css_default["secondaryButton"],
2233
2591
  "aria-label": providerCopy(t("editProvider"), target),
@@ -2262,6 +2620,7 @@ window.__ModuleLoader__.load({
2262
2620
  }, { entryKey: row.entry.settingsNs }),
2263
2621
  open ? renderProviderEditor({
2264
2622
  target,
2623
+ row,
2265
2624
  namespace,
2266
2625
  schema,
2267
2626
  operations,
@@ -2352,6 +2711,10 @@ window.__ModuleLoader__.load({
2352
2711
  schema,
2353
2712
  settingsPath: draft.target.settingsPath,
2354
2713
  operations,
2714
+ ...draft.target.defaultBaseURL === void 0 ? {} : { defaultBaseURL: draft.target.defaultBaseURL },
2715
+ ...draft.target.baseURLEnv === void 0 ? {} : { baseURLEnv: draft.target.baseURLEnv },
2716
+ ...draft.target.nativeAuth === void 0 ? {} : { nativeAuth: draft.target.nativeAuth },
2717
+ ...addRow?.credentialChecks === void 0 ? {} : { credentialChecks: addRow.credentialChecks },
2355
2718
  t,
2356
2719
  readOnly: !state.writable,
2357
2720
  onClose: (changed) => {
@@ -2377,6 +2740,7 @@ window.__ModuleLoader__.load({
2377
2740
  children: (0, react_jsx_runtime.jsx)(CustomProviderCard, {
2378
2741
  taken: state.rows.map((row) => row.entry.provider),
2379
2742
  protocols,
2743
+ reasoningLevels,
2380
2744
  revision: piAi.revision,
2381
2745
  operations,
2382
2746
  t,
@@ -2695,16 +3059,14 @@ window.__ModuleLoader__.load({
2695
3059
  //#endregion
2696
3060
  //#region lib/types/client/welcome-store.js
2697
3061
  /**
2698
- * Welcome-notice state derived from the welcome settings scope. The scope is
2699
- * the transport: a loopback browser follows the durable Host section, while a
2700
- * remote browser's memory-mode scope never answers and the acknowledgement
2701
- * stays process-local here.
3062
+ * Welcome-notice state derived from the welcome settings scope: the notice
3063
+ * follows the Host section and records its acknowledgement through it.
2702
3064
  */
2703
3065
  /* v8 ignore next 3 -- closed-union default only defends future source widening */
2704
3066
  function assertNever(_value) {
2705
3067
  throw new Error("unexpected welcome settings status");
2706
3068
  }
2707
- /** Coordinates durable Host acknowledgement or a process-local remote fallback. */
3069
+ /** Coordinates the durable Host acknowledgement. */
2708
3070
  var WelcomeNoticeStore = class {
2709
3071
  scope;
2710
3072
  /** uSES-safe state source shared by the registered welcome step. */
@@ -2713,13 +3075,8 @@ window.__ModuleLoader__.load({
2713
3075
  acknowledged: false,
2714
3076
  error: null
2715
3077
  });
2716
- localAcknowledged = false;
2717
3078
  saving = false;
2718
3079
  following;
2719
- /**
2720
- * @param scope - the welcome settings namespace scope; its memory mode is
2721
- * what keeps a remote browser process-local.
2722
- */
2723
3080
  constructor(scope) {
2724
3081
  this.scope = scope;
2725
3082
  }
@@ -2735,17 +3092,12 @@ window.__ModuleLoader__.load({
2735
3092
  return Promise.resolve();
2736
3093
  }
2737
3094
  /**
2738
- * Persist this copy version, or advance only this process for a remote
2739
- * browser. Success is judged against the state the write left behind, so a
2740
- * refused or failed write reports false after its recovery read settles.
2741
- * @returns true when the selected persistence mode holds the acknowledgement.
3095
+ * Persist this copy version through the scope. Success is judged against the
3096
+ * state the write left behind, so a refused or failed write reports false
3097
+ * after its recovery read settles.
3098
+ * @returns true when the Host holds the acknowledgement.
2742
3099
  */
2743
3100
  async acknowledge() {
2744
- if (this.scope.getSnapshot().mode === "memory") {
2745
- this.localAcknowledged = true;
2746
- this.derive();
2747
- return true;
2748
- }
2749
3101
  this.saving = true;
2750
3102
  this.store.update((state) => {
2751
3103
  state.status = "saving";
@@ -2772,14 +3124,6 @@ window.__ModuleLoader__.load({
2772
3124
  derive() {
2773
3125
  if (this.saving) return;
2774
3126
  const scope = this.scope.getSnapshot();
2775
- if (scope.mode === "memory") {
2776
- this.store.update((state) => {
2777
- state.status = "ready";
2778
- state.acknowledged = this.localAcknowledged;
2779
- state.error = null;
2780
- });
2781
- return;
2782
- }
2783
3127
  switch (scope.status) {
2784
3128
  case "loading":
2785
3129
  this.store.update((state) => {
@@ -2824,10 +3168,6 @@ window.__ModuleLoader__.load({
2824
3168
  */
2825
3169
  function createModelsOperations(ctx) {
2826
3170
  return {
2827
- describeCredential: async (ref) => {
2828
- const response = await ctx.remote.credentials.describe([ref]);
2829
- return response.ok ? response.value[ref] : void 0;
2830
- },
2831
3171
  storeCredential: async (ref, value) => {
2832
3172
  const response = await ctx.remote.credentials.set(ref, value);
2833
3173
  return response.ok ? void 0 : response.error.message;
@@ -2915,19 +3255,30 @@ window.__ModuleLoader__.load({
2915
3255
  savedProvider: "Saved {provider}.",
2916
3256
  credentialConfigured: "API key configured",
2917
3257
  credentialMissing: "API key missing",
3258
+ accountSignedIn: "Signed in",
2918
3259
  readOnly: "The settings document is read-only in this deployment.",
2919
3260
  loadFailed: "Loading the provider directory failed",
2920
3261
  conflict: "Someone else changed these settings while this card was open. Close it and reopen to edit the current values.",
2921
3262
  retry: "Retry",
2922
3263
  keyInput: "API key",
3264
+ keyReveal: "Show secret",
3265
+ keyHide: "Hide secret",
2923
3266
  keyPlaceholder: "Enter your API key",
2924
- keyPlaceholderNative: "Enter an API key, or leave blank to use environment authentication",
2925
- keyStored: "Configured — enter a new value to replace",
2926
- keyEnvLocked: "Provided by the launch environment (read-only)",
3267
+ keyPlaceholderFallback: "Leave blank to use env as auth ({hint})",
3268
+ keyPlaceholderSaved: "Leave blank to use saved credentials",
3269
+ keyFallbackMissing: "Env var not detected. Enter an API key, or configure {hint} in your env.",
3270
+ keyFallbackDetected: "Env var detected. ({hint})",
3271
+ keyFallbackDetectedHidden: "Env var detected.",
3272
+ keyFallbackUnchecked: "Environment credential status has not been confirmed.",
3273
+ keyHelp: "Saved credentials are used first. Environment fallbacks shown here, in order: {env}. Sources are launch environment, $cwd/.env, then $DSH_HOME/.env.",
3274
+ authHelp: "Authentication details",
2927
3275
  customized: "Customized settings",
2928
3276
  baseUrl: "Base URL",
2929
- baseUrlDefault: "Provider default",
2930
- deepSeekBaseUrl: "https://api.deepseek.com/anthropic",
3277
+ baseUrlDefault: "No default endpoint",
3278
+ baseUrlEnvironment: "Provider endpoint configuration: {env}",
3279
+ baseUrlConfigured: "Provider-configured endpoint",
3280
+ baseUrlPlaceholder: "{url}",
3281
+ deepSeekBaseUrl: "https://api.deepseek.com/anthropic (Default to use DEEPSEEK_BASE_URL)",
2931
3282
  deepSeekEndpointHint: "Use an API endpoint compatible with Anthropic Messages.",
2932
3283
  models: "Models",
2933
3284
  modelsInherited: "Using the adapter defaults",
@@ -2945,6 +3296,16 @@ window.__ModuleLoader__.load({
2945
3296
  modelInputTypes: "Input types",
2946
3297
  modelInputText: "Text",
2947
3298
  modelInputImage: "Image",
3299
+ modelReasoning: "Reasoning levels",
3300
+ modelReasoningLevel: "Level",
3301
+ modelReasoningValue: "API value",
3302
+ modelReasoningHelp: "About reasoning levels",
3303
+ modelReasoningHelpText: "The API value is sent in the request's reasoning-effort field, such as OpenAI's reasoning_effort. It defaults to the level name; where the model provider's API documentation specifies a different value, follow it. Off turns reasoning off and needs no value; a value already written in the configuration is kept and sent.",
3304
+ modelReasoningNeedsLevel: "Add at least one level besides Off, or turn reasoning levels off.",
3305
+ modelReasoningValueRequired: "Every level besides Off needs an API value, and no value can be empty.",
3306
+ modelReasoningAdd: "Add level",
3307
+ modelReasoningRemove: "Delete level",
3308
+ modelReasoningOffValuePlaceholder: "Turns reasoning off",
2948
3309
  addModel: "Add model",
2949
3310
  removeModel: "Delete model",
2950
3311
  modelsEmpty: "No models will be shown in the selector. Unlisted IDs can still be sent directly.",
@@ -3031,19 +3392,30 @@ window.__ModuleLoader__.load({
3031
3392
  savedProvider: "已保存 {provider}。",
3032
3393
  credentialConfigured: "API 密钥已配置",
3033
3394
  credentialMissing: "API 密钥缺失",
3395
+ accountSignedIn: "已登录",
3034
3396
  readOnly: "当前部署的设置文档为只读。",
3035
3397
  loadFailed: "加载提供商目录失败",
3036
3398
  conflict: "这张卡片打开期间,这些设置已被其他地方改动。请关闭后重新打开,在当前值上编辑。",
3037
3399
  retry: "重试",
3038
3400
  keyInput: "API 密钥",
3401
+ keyReveal: "显示密钥",
3402
+ keyHide: "隐藏密钥",
3039
3403
  keyPlaceholder: "输入 API 密钥",
3040
- keyPlaceholderNative: "输入 API 密钥,或留空使用环境认证",
3041
- keyStored: "已配置——输入新值可替换",
3042
- keyEnvLocked: "由启动环境提供(只读)",
3404
+ keyPlaceholderFallback: "留空使用环境认证({hint})",
3405
+ keyPlaceholderSaved: "留空使用已保存凭据",
3406
+ keyFallbackMissing: "未检测到环境变量。请填写 API 密钥,或设置环境变量 {hint}。",
3407
+ keyFallbackDetected: "已检测到环境变量({hint})",
3408
+ keyFallbackDetectedHidden: "已检测到环境变量",
3409
+ keyFallbackUnchecked: "环境凭据状态尚未确认",
3410
+ keyHelp: "优先使用已保存的凭据。此处显示的环境后备按以下顺序排列:{env}。来源依次为启动环境、$cwd/.env、$DSH_HOME/.env。",
3411
+ authHelp: "认证说明",
3043
3412
  customized: "自定义设置",
3044
3413
  baseUrl: "API 地址",
3045
- baseUrlDefault: "提供商默认",
3046
- deepSeekBaseUrl: "https://api.deepseek.com/anthropic",
3414
+ baseUrlDefault: "没有默认地址",
3415
+ baseUrlEnvironment: "提供方地址配置:{env}",
3416
+ baseUrlConfigured: "由提供方配置地址",
3417
+ baseUrlPlaceholder: "{url}",
3418
+ deepSeekBaseUrl: "https://api.deepseek.com/anthropic(默认使用环境 DEEPSEEK_BASE_URL)",
3047
3419
  deepSeekEndpointHint: "请填写兼容 Anthropic Messages 协议的 API 地址。",
3048
3420
  models: "模型目录",
3049
3421
  modelsInherited: "正在使用适配器默认模型",
@@ -3061,6 +3433,16 @@ window.__ModuleLoader__.load({
3061
3433
  modelInputTypes: "输入类型",
3062
3434
  modelInputText: "文本",
3063
3435
  modelInputImage: "图片",
3436
+ modelReasoning: "推理等级",
3437
+ modelReasoningLevel: "档位",
3438
+ modelReasoningValue: "API 参数值",
3439
+ modelReasoningHelp: "推理等级说明",
3440
+ modelReasoningHelpText: "API 参数值会写入请求的推理强度字段(如 OpenAI 的 reasoning_effort),默认与档位名相同;如有不同,以模型提供商的 API 文档为准。Off 表示关闭思考,不需要填写参数值;配置中已写入的值会保留并发送。",
3441
+ modelReasoningNeedsLevel: "至少添加一个 Off 以外的档位;不需要思考请关闭推理等级。",
3442
+ modelReasoningValueRequired: "Off 以外的档位都需要填写 API 参数值,且参数值不能为空字符串。",
3443
+ modelReasoningAdd: "添加档位",
3444
+ modelReasoningRemove: "删除档位",
3445
+ modelReasoningOffValuePlaceholder: "关闭思考",
3064
3446
  addModel: "添加模型",
3065
3447
  removeModel: "删除模型",
3066
3448
  modelsEmpty: "模型选择器中将不显示任何模型;目录外 ID 仍可直接发送。",