@redpanda-data/docs-extensions-and-macros 4.13.3 → 4.13.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@redpanda-data/docs-extensions-and-macros",
3
- "version": "4.13.3",
3
+ "version": "4.13.4",
4
4
  "description": "Antora extensions and macros developed for Redpanda documentation.",
5
5
  "keywords": [
6
6
  "antora",
@@ -397,8 +397,9 @@ function generatePRSummary(diffData, binaryAnalysis = null, draftedConnectors =
397
397
  lines.push('');
398
398
  cloudSupportedNew.forEach(c => {
399
399
  lines.push(`- **${c.name}** (${c.type}, ${c.status})`);
400
- if (c.description) {
401
- const shortDesc = truncateToSentence(c.description, 2);
400
+ const desc = c.summary || c.description;
401
+ if (desc) {
402
+ const shortDesc = truncateToSentence(desc, 2);
402
403
  lines.push(` - ${shortDesc}`);
403
404
  }
404
405
  });
@@ -410,8 +411,9 @@ function generatePRSummary(diffData, binaryAnalysis = null, draftedConnectors =
410
411
  lines.push('');
411
412
  selfHostedOnlyNew.forEach(c => {
412
413
  lines.push(`- **${c.name}** (${c.type}, ${c.status})`);
413
- if (c.description) {
414
- const shortDesc = truncateToSentence(c.description, 2);
414
+ const desc = c.summary || c.description;
415
+ if (desc) {
416
+ const shortDesc = truncateToSentence(desc, 2);
415
417
  lines.push(` - ${shortDesc}`);
416
418
  }
417
419
  });
@@ -421,8 +423,9 @@ function generatePRSummary(diffData, binaryAnalysis = null, draftedConnectors =
421
423
  // No cloud support info, just list all
422
424
  diffData.details.newComponents.forEach(c => {
423
425
  lines.push(`- **${c.name}** (${c.type}, ${c.status})`);
424
- if (c.description) {
425
- const shortDesc = truncateToSentence(c.description, 2);
426
+ const desc = c.summary || c.description;
427
+ if (desc) {
428
+ const shortDesc = truncateToSentence(desc, 2);
426
429
  lines.push(` - ${shortDesc}`);
427
430
  }
428
431
  });
@@ -189,8 +189,9 @@ function updateWhatsNew ({ dataDir, oldVersion, newVersion, binaryAnalysis }) {
189
189
  for (const comp of comps) {
190
190
  section += `** xref:guides:bloblang/functions.adoc#${comp.name}[\`${comp.name}\`]`
191
191
  if (comp.status && comp.status !== 'stable') section += ` (${comp.status})`
192
- if (comp.description) {
193
- section += `: ${capToTwoSentences(comp.description)}`
192
+ const desc = comp.summary || comp.description
193
+ if (desc) {
194
+ section += `: ${capToTwoSentences(desc)}`
194
195
  } else {
195
196
  section += `\n+\n// TODO: Add description for ${comp.name} function`
196
197
  }
@@ -201,8 +202,9 @@ function updateWhatsNew ({ dataDir, oldVersion, newVersion, binaryAnalysis }) {
201
202
  for (const comp of comps) {
202
203
  section += `** xref:guides:bloblang/methods.adoc#${comp.name}[\`${comp.name}\`]`
203
204
  if (comp.status && comp.status !== 'stable') section += ` (${comp.status})`
204
- if (comp.description) {
205
- section += `: ${capToTwoSentences(comp.description)}`
205
+ const desc = comp.summary || comp.description
206
+ if (desc) {
207
+ section += `: ${capToTwoSentences(desc)}`
206
208
  } else {
207
209
  section += `\n+\n// TODO: Add description for ${comp.name} method`
208
210
  }
@@ -267,7 +269,8 @@ function updateWhatsNew ({ dataDir, oldVersion, newVersion, binaryAnalysis }) {
267
269
 
268
270
  for (const comp of diff.details.deprecatedComponents) {
269
271
  const typeLabel = comp.type.charAt(0).toUpperCase() + comp.type.slice(1)
270
- const desc = comp.description ? capToTwoSentences(comp.description) : '-'
272
+ const descText = comp.summary || comp.description
273
+ const desc = descText ? capToTwoSentences(descText) : '-'
271
274
 
272
275
  if (comp.type === 'bloblang-functions') {
273
276
  section += `|xref:guides:bloblang/functions.adoc#${comp.name}[${comp.name}]\n`
@@ -913,6 +916,9 @@ async function handleRpcnConnectorDocs (options) {
913
916
  fs.unlinkSync(oldestPath)
914
917
  console.log(`🧹 Deleted old version from docs-data: ${oldestFile}`)
915
918
  }
919
+
920
+ // Reload newIndex after augmentation so diff generation uses augmented data
921
+ newIndex = JSON.parse(fs.readFileSync(dataFile, 'utf8'))
916
922
  } catch (err) {
917
923
  console.error(`Warning: Failed to augment data file: ${err.message}`)
918
924
  }