API Overview shows '-' (no description) when the description type is markdown
Description:
API Overview shows '-' (no description) when the description type is markdown. This gives an impression that the description is not defined.
However when type is changes to text for the same markdown text (## This is a simple API for Pizza Shack online pizza delivery store.), it is interpreted as markdown in the overview UI.
Steps to reproduce:
Affected Product Version:
Environment details (with versions):
- OS:
- Client:
- Env (Docker/K8s):
Optional Fields
Related Issues:
Suggested Labels:
Suggested Assignees:
Still valid issue
Related Issue: https://github.com/wso2/api-manager/issues/3526
Fix in Version 4.6.0
The issue has been resolved by removing the buggy type selector entirely and implementing unified markdown rendering.
Changes Made:
1. Description Type Selector Removed
- No more "Markdown" vs "Text" type selection
- Single description field for all APIs
2. Automatic Markdown Rendering via ReactMarkdown
File: portals/publisher/src/main/webapp/source/src/app/components/Apis/Details/NewOverview/MetaData.jsx
Line 23: Import ReactMarkdown
import ReactMarkdown from 'react-markdown';
Lines 100-122: Unified description rendering
<Typography component='p' variant='body1'>
{api.description && (
<ReactMarkdown>{capitalizeFirstLetter(api.description)}</ReactMarkdown>
)}
</Typography>
<Typography component='p' variant='body1' className={parentClasses.notConfigured}>
{!api.description && (
<FormattedMessage
id='Apis.Details.NewOverview.MetaData.description.not.set'
defaultMessage='-'
/>
)}
</Typography>
Key Changes:
- ✅ All descriptions now use ReactMarkdown component for rendering
- ✅ The "-" placeholder only shows when description is truly empty (correct behavior)
- ✅ No more type-based conditional logic
---
Current Behavior (4.6.0)
- No type selector - Users simply add content to the description field
- Automatic markdown detection - Any markdown syntax is automatically rendered
- Plain text support - Plain text without markdown syntax displays normally
- Consistent behavior - Works the same way for all APIs
🤖 Generated with [Claude Code](https://claude.ai/code)