diff --git a/e2e/document-renderer.playwright.ts b/e2e/document-renderer.playwright.ts index fea5c8d..0c8769b 100644 --- a/e2e/document-renderer.playwright.ts +++ b/e2e/document-renderer.playwright.ts @@ -279,8 +279,11 @@ test('§11-3 受控文档:规则来源、版本与不回退说明', async ({ b await expect(option.locator('.drw-profile-source')).toHaveText('模板规则') await expect(option.locator('.drw-profile-id')).toHaveText(TEMPLATE_PROFILE) await expect(option.locator('.drw-profile-ver')).toHaveText(`v${env('RBA_TEMPLATE_VERSION')}`) - await expect(option.locator('.ui-chip').first()).toHaveText('已验证') - await expect(option.locator('.drw-profile-reason')).toContainText('未发布') + // 44 个 DHF 专用规则均已发布(state=published、publicationAllowed=true):状态为已发布,可正式交付,无未发布原因。 + await expect(option.locator('.ui-chip').first()).toHaveText('已发布') + await expect(option.locator('.ui-chip', { hasText: '可正式交付' })).toBeVisible() + await expect(option.locator('input[type="radio"]')).toBeEnabled() + await expect(option.locator('.drw-profile-reason')).toHaveCount(0) await expect(rules.locator('.drw-notice')).toContainText('不会回退到项目或公司默认规则') await expect(rules.locator('.drw-failure-msg')).toContainText('不得回退到项目或公司默认规则') await expectReadableFailures(page) diff --git a/src/components/DocumentRenderWorkspace.tsx b/src/components/DocumentRenderWorkspace.tsx index c9b839d..2c90f79 100644 --- a/src/components/DocumentRenderWorkspace.tsx +++ b/src/components/DocumentRenderWorkspace.tsx @@ -13,7 +13,7 @@ import { DELIVERY_MODE_LABELS, DOC_TREE_LIMITS, MIND_MAP, REVISION_KIND_LABELS, annotatePayload, buildDocTree, controlledNotice, createRequestGuard, currentSubmissionId, decodeBase64, defaultProfileKey, diagnosticCountsByNode, diagnosticsSummaryText, downloadOptions, formatRenderTime, - groupDiagnostics, hasFacts, layoutMindMap, loadDeliveryDiagnostics, mergeDeliveries, moveSelection, + groupDiagnostics, hasFacts, layoutMindMap, loadDeliveryDiagnostics, locateDiagnostic, mergeDeliveries, moveSelection, nextOperation, nodeAnchorId, nodeFacts, normalizeDeliveries, normalizeDownload, normalizeProfiles, normalizeReviewView, partitionAnnotations, partitionRevisions, profileOptionViews, receiptStateView, renderScope, revisePayload, submissionIdOf, truncateMiddle, validateReviewText, visibleNodeIds, visibleOrder, walkDocTree, @@ -88,11 +88,11 @@ function DiagnosticGroupBody({ items, nodeTitle, onSelectNode }: { return (