confluence-md-sync 0.5.1 → 0.5.2

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.
@@ -630,10 +630,11 @@ class Converter {
630
630
  let headerCount = 0;
631
631
  while (headerCount < grid.length && headerFlags[headerCount])
632
632
  headerCount++;
633
- if (headerCount === 0)
634
- headerCount = 1; // нет <th>-шапки первая строка как ключи
635
- if (headerCount >= grid.length)
636
- headerCount = 1; // не съедать всю таблицу
633
+ // Нет <th>-шапки (или вся таблица — заголовки): в записи разворачивать
634
+ // нечего первая строка данных стала бы «ключами» т.ч. картинка →
635
+ // ключ `**<img …>:**`). Такую таблицу отдаём как GFM.
636
+ if (headerCount === 0 || headerCount >= grid.length)
637
+ return this.readableTable(table);
637
638
  const header = grid[headerCount - 1];
638
639
  const titleCells = grid
639
640
  .slice(0, headerCount - 1)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "confluence-md-sync",
3
- "version": "0.5.1",
3
+ "version": "0.5.2",
4
4
  "description": "Publish Markdown to Confluence (Data Center & Cloud): idempotent page sync, attachment dedup, tables and a pluggable macro system",
5
5
  "keywords": [
6
6
  "confluence",