feat: add soap wizard foundation

This commit is contained in:
a.tolmachev
2026-04-07 17:09:01 +03:00
parent 78dc5ebc37
commit d8981f8a75
7 changed files with 475 additions and 9 deletions
+23 -3
View File
@@ -12,7 +12,7 @@
<!-- Protocol selection cards -->
<div class="protocol-grid">
<div class="protocol-card rest selected" role="radio" aria-checked="true" tabindex="0">
<div class="protocol-card rest selected" data-protocol="rest" role="radio" aria-checked="true" tabindex="0">
<div class="protocol-card-check">
<svg viewBox="0 0 12 12"><polyline points="1.5,6 4.5,9 10.5,3"/></svg>
</div>
@@ -34,7 +34,7 @@
</div>
</div>
<div class="protocol-card graphql" role="radio" aria-checked="false" tabindex="0">
<div class="protocol-card graphql" data-protocol="graphql" role="radio" aria-checked="false" tabindex="0">
<div class="protocol-card-check">
<svg viewBox="0 0 12 12"><polyline points="1.5,6 4.5,9 10.5,3"/></svg>
</div>
@@ -57,7 +57,7 @@
</div>
</div>
<div class="protocol-card grpc" role="radio" aria-checked="false" tabindex="0">
<div class="protocol-card grpc" data-protocol="grpc" role="radio" aria-checked="false" tabindex="0">
<div class="protocol-card-check">
<svg viewBox="0 0 12 12"><polyline points="1.5,6 4.5,9 10.5,3"/></svg>
</div>
@@ -76,6 +76,26 @@
</div>
</div>
<div class="protocol-card soap" data-protocol="soap" role="radio" aria-checked="false" tabindex="0">
<div class="protocol-card-check">
<svg viewBox="0 0 12 12"><polyline points="1.5,6 4.5,9 10.5,3"/></svg>
</div>
<div class="protocol-icon-wrap">
<svg width="22" height="22" viewBox="0 0 24 24" fill="none" stroke="#f59e0b" stroke-width="1.8" stroke-linecap="round" stroke-linejoin="round">
<path d="M4 5h16v14H4z"/>
<path d="M8 5V3h8v2"/>
<path d="M7 10h10M7 14h6"/>
</svg>
</div>
<div class="protocol-card-name" data-i18n="wizard.step1.soap_name">SOAP</div>
<div class="protocol-card-tagline" data-i18n="wizard.step1.soap_tagline">Enterprise WSDL/XSD service contracts normalized into MCP tools with structured XML mapping.</div>
<div class="protocol-card-tags">
<span class="protocol-tag">WSDL</span>
<span class="protocol-tag">XML</span>
<span class="protocol-tag" data-i18n="wizard.step1.unary">Unary</span>
</div>
</div>
</div><!-- /protocol-grid -->
+101
View File
@@ -0,0 +1,101 @@
<div id="step-panel-3-soap" class="step-pane">
<div class="step-panel-header">
<div class="step-panel-eyebrow">
<div class="step-panel-eyebrow-line"></div>
<span data-i18n-html="wizard.step_of">Step 3 of 5</span>
</div>
<h1 class="step-panel-title" data-i18n="wizard.step3.soap.title">WSDL and SOAP binding</h1>
<p class="step-panel-subtitle" data-i18n="wizard.step3.soap.subtitle">Upload the WSDL/XSD bundle, inspect services and choose the exact service, port and operation that Crank should expose as an MCP tool.</p>
</div>
<div class="config-card" style="margin-bottom: 20px;">
<div class="config-card-header">
<div class="config-card-header-icon">
<svg width="13" height="13" viewBox="0 0 16 16" fill="none" stroke="var(--text-secondary)" stroke-width="1.7" stroke-linecap="round" stroke-linejoin="round">
<path d="M3.5 2.5h6l3 3v8a1 1 0 0 1-1 1h-8a1 1 0 0 1-1-1v-10a1 1 0 0 1 1-1z"/>
<path d="M9.5 2.5v3h3"/>
</svg>
</div>
<div>
<div class="config-card-title" data-i18n="wizard.step3.soap.wsdl_title">Contract files</div>
<div class="config-card-subtitle" data-i18n="wizard.step3.soap.wsdl_subtitle">WSDL is required. Supporting XSD files are optional and can be uploaded before discovery.</div>
</div>
<span class="config-card-optional" style="color:var(--error,#f87171);" data-i18n="wizard.required">Required</span>
</div>
<div class="config-card-body" style="gap: 16px;">
<div class="form-row">
<input id="wizard-soap-wsdl-input" type="file" accept=".wsdl,.xml,text/xml,application/wsdl+xml" style="display:none">
<button id="wizard-select-soap-wsdl" class="btn-ghost-sm" type="button" data-i18n="wizard.step3.soap.choose_wsdl">Choose WSDL</button>
<span id="wizard-soap-wsdl-name" style="color: var(--text-muted); font-size: 12px;" data-i18n="wizard.step3.soap.no_wsdl">No WSDL selected</span>
</div>
<div class="form-row">
<input id="wizard-soap-xsd-input" type="file" accept=".xsd,.xml,text/xml,application/xml" style="display:none">
<button id="wizard-select-soap-xsd" class="btn-ghost-sm" type="button" data-i18n="wizard.step3.soap.choose_xsd">Choose XSD</button>
<span id="wizard-soap-xsd-name" style="color: var(--text-muted); font-size: 12px;" data-i18n="wizard.step3.soap.no_xsd">No XSD selected</span>
</div>
<div class="form-row">
<button id="wizard-upload-soap-contracts" class="btn-primary-sm" type="button" data-i18n="wizard.step3.soap.upload_discover">Upload and inspect services</button>
</div>
<div class="form-hint" id="wizard-soap-services-summary"></div>
<div id="wizard-soap-services-list" style="display:grid; gap: 10px;"></div>
</div>
</div>
<div class="config-card" style="margin-bottom: 20px;">
<div class="config-card-header">
<div class="config-card-header-icon">
<svg width="13" height="13" viewBox="0 0 16 16" fill="none" stroke="var(--text-secondary)" stroke-width="1.7" stroke-linecap="round" stroke-linejoin="round">
<path d="M2.5 5.5h11M5.5 2.5v3M10.5 2.5v3M4 8.5h8v5H4z"/>
</svg>
</div>
<div>
<div class="config-card-title" data-i18n="wizard.step3.soap.binding_title">Selected binding</div>
<div class="config-card-subtitle" data-i18n="wizard.step3.soap.binding_subtitle">The chosen service, port and operation become the target binding for this operation draft.</div>
</div>
<span class="config-card-optional" data-i18n="wizard.optional">Optional</span>
</div>
<div class="config-card-body">
<div class="form-row">
<div class="form-group">
<label class="form-label" data-i18n="wizard.step3.soap.service_name">Service</label>
<input id="soap-service-name" class="form-input input-mono" type="text" placeholder="LeadService">
</div>
<div class="form-group">
<label class="form-label" data-i18n="wizard.step3.soap.port_name">Port</label>
<input id="soap-port-name" class="form-input input-mono" type="text" placeholder="LeadPort">
</div>
</div>
<div class="form-row">
<div class="form-group">
<label class="form-label" data-i18n="wizard.step3.soap.operation_name">Operation</label>
<input id="soap-operation-name" class="form-input input-mono" type="text" placeholder="CreateLead">
</div>
<div class="form-group">
<label class="form-label" data-i18n="wizard.step3.soap.version">SOAP version</label>
<select id="soap-version" class="form-select">
<option value="soap_11">SOAP 1.1</option>
<option value="soap_12">SOAP 1.2</option>
</select>
</div>
</div>
<div class="form-row">
<div class="form-group">
<label class="form-label" data-i18n="wizard.step3.soap.action">SOAPAction</label>
<input id="soap-action" class="form-input input-mono" type="text" placeholder="urn:createLead">
</div>
<div class="form-group">
<label class="form-label" data-i18n="wizard.step3.soap.binding_style">Binding style</label>
<select id="soap-binding-style" class="form-select">
<option value="document_literal" data-i18n="wizard.step3.soap.binding.document_literal">Document literal</option>
<option value="rpc_literal" data-i18n="wizard.step3.soap.binding.rpc_literal">RPC literal</option>
</select>
</div>
</div>
<div class="form-group">
<label class="form-label" data-i18n="wizard.step3.soap.endpoint_override">Endpoint override</label>
<input id="soap-endpoint-override" class="form-input input-mono" type="text" placeholder="https://soap.example.com/lead">
<div class="form-hint" data-i18n="wizard.step3.soap.endpoint_override_hint">Defaults to the upstream base URL from step 2. Override only when the binding address differs from the selected upstream.</div>
</div>
</div>
</div>
</div>