feat: 替换 compare-table 为 list-grid 并新增 compare-binary 示例
This commit is contained in:
@@ -56,7 +56,7 @@ Choose the most appropriate template based on the content structure:
|
||||
- **Relationship**: `relation-sankey` (Sankey Diagram), `relation-circle` (Circular Relationship)
|
||||
|
||||
#### 3. Comparison & Analysis
|
||||
- **Comparison**: `compare-binary` (Binary Comparison), `compare-table` (Comparison Table)
|
||||
- **Comparison**: `compare-binary` (Binary Comparison), `list-grid` (Multi-item Grid Comparison)
|
||||
- **Analysis**: `compare-swot` (SWOT Analysis), `quadrant-quarter` (Quadrant Chart)
|
||||
|
||||
#### 4. Charts & Data
|
||||
@@ -79,7 +79,31 @@ data
|
||||
desc Description of B
|
||||
```
|
||||
|
||||
#### B. SWOT Analysis
|
||||
|
||||
#### B. Binary Comparison
|
||||
Use `items` for two sides and `children` for comparison points.
|
||||
|
||||
```infographic
|
||||
infographic compare-binary
|
||||
data
|
||||
title Advantages vs Disadvantages
|
||||
desc Compare two aspects side by side
|
||||
items
|
||||
- label Advantages
|
||||
children
|
||||
- label Strong R&D
|
||||
desc Leading technology and innovation capability
|
||||
- label High customer loyalty
|
||||
desc Repurchase rate over 60%
|
||||
- label Disadvantages
|
||||
children
|
||||
- label Weak brand exposure
|
||||
desc Insufficient marketing, low awareness
|
||||
- label Narrow channel coverage
|
||||
desc Limited online channels
|
||||
```
|
||||
|
||||
#### C. SWOT Analysis
|
||||
Use `children` to define the 4 quadrants (Strengths, Weaknesses, Opportunities, Threats).
|
||||
|
||||
```infographic
|
||||
@@ -106,7 +130,7 @@ data
|
||||
- label New Competitors
|
||||
```
|
||||
|
||||
#### C. Quadrant Chart
|
||||
#### D. Quadrant Chart
|
||||
Use `items` for quadrants and `illus` for icons.
|
||||
|
||||
```infographic
|
||||
@@ -499,7 +523,6 @@ SCRIPT_TEMPLATE_INFOGRAPHIC = """
|
||||
// Comparison & Analysis
|
||||
'compare-binary': 'compare-binary-horizontal-simple-vs',
|
||||
'compare-swot': 'compare-swot',
|
||||
'compare-table': 'compare-table-simple',
|
||||
'quadrant-quarter': 'quadrant-quarter-simple-card',
|
||||
|
||||
// Charts & Data
|
||||
|
||||
@@ -60,8 +60,8 @@ Infographic syntax is a Mermaid-like declarative syntax for describing infograph
|
||||
#### 3. Comparison & Analysis
|
||||
- **Binary Comparison (A vs B)** -> `compare-binary`
|
||||
- **SWOT Analysis** -> `compare-swot`
|
||||
- **Multi-item Comparison Table** -> `compare-table`
|
||||
- **Quadrant Analysis (Importance vs Urgency)** -> `quadrant-quarter`
|
||||
- **Multi-item Grid Comparison** -> `list-grid` (use for comparing multiple items)
|
||||
|
||||
#### 4. Charts & Data (Metric-heavy)
|
||||
- **Key Metrics / Data Cards** -> `statistic-card`
|
||||
@@ -111,6 +111,26 @@ data
|
||||
- label Mar
|
||||
value 1800
|
||||
|
||||
|
||||
#### Comparison (Binary Comparison)
|
||||
infographic compare-binary
|
||||
data
|
||||
title Advantages vs Disadvantages
|
||||
desc Compare two aspects side by side
|
||||
items
|
||||
- label Advantages
|
||||
children
|
||||
- label Strong R&D
|
||||
desc Leading technology and innovation capability
|
||||
- label High customer loyalty
|
||||
desc Repurchase rate over 60%
|
||||
- label Disadvantages
|
||||
children
|
||||
- label Weak brand exposure
|
||||
desc Insufficient marketing, low awareness
|
||||
- label Narrow channel coverage
|
||||
desc Limited online channels
|
||||
|
||||
#### Comparison (SWOT)
|
||||
infographic compare-swot
|
||||
data
|
||||
@@ -514,7 +534,6 @@ SCRIPT_TEMPLATE_INFOGRAPHIC = """
|
||||
// 对比与分析
|
||||
'compare-binary': 'compare-binary-horizontal-simple-vs',
|
||||
'compare-swot': 'compare-swot',
|
||||
'compare-table': 'compare-table-simple', // 暂无直接对应
|
||||
'quadrant-quarter': 'quadrant-quarter-simple-card',
|
||||
|
||||
// 图表与数据
|
||||
|
||||
Reference in New Issue
Block a user