Commit a6254ed2 authored by Miguel Angel Reina Ortega's avatar Miguel Angel Reina Ortega
Browse files

Fix to render links in grid tables

parent f0357e37
Loading
Loading
Loading
Loading
+11 −11
Original line number Diff line number Diff line
@@ -585,7 +585,7 @@ def generateHtmlTableWithSpans(gridTable:str) -> str:
		raise RuntimeError(f'HTML TABLE COULD NOT BE GENERATED FROM MARKDOWN GRID TABLE:\n{str(e)}')
		
	# Generate table HTML...
	html = '<table>\n'
	html = '<table markdown="1">\n'
	hasHeader = False

	for row in gridHeader:
@@ -595,9 +595,9 @@ def generateHtmlTableWithSpans(gridTable:str) -> str:
				break

	if hasHeader:
		html += '    <thead>\n'
		html += '<thead markdown="1">\n'
		for row in gridHeader:
			html += "        <tr>\n"
			html += '<tr markdown="1">\n'
			for cell in row:
				if cell.rowspan == 0 or cell.colspan == 0:
					continue
@@ -615,14 +615,14 @@ def generateHtmlTableWithSpans(gridTable:str) -> str:

					rowspan = f' rowspan="{cell.rowspan}"' if cell.rowspan > 1 else ''
					colspan = f' colspan="{cell.colspan}"' if cell.colspan > 1 else ''
					html +=   f'            <th{rowspan}{colspan} {cell.alignment}>{cell.content}</th>\n'
					html +=   f'<th{rowspan}{colspan} {cell.alignment} markdown="1">{cell.content}</th>\n'
			html += '</tr>\n'
		html += '</thead>\n'


	html += '    <tbody>\n'
	html += '<tbody markdown="1">\n'
	for row in gridBody:
		html += '        <tr>\n'
		html += '<tr markdown="1">\n'
		for cell in row:
			if cell.rowspan == 0 or cell.colspan == 0:
				continue
@@ -640,7 +640,7 @@ def generateHtmlTableWithSpans(gridTable:str) -> str:

				rowspan = f' rowspan="{cell.rowspan}"' if cell.rowspan > 1 else ''
				colspan = f' colspan="{cell.colspan}"' if cell.colspan > 1 else ''
				html +=   f'            <td{rowspan}{colspan} {cell.alignment}>{cell.content}</td>\n'
				html +=   f'<td{rowspan}{colspan} {cell.alignment} markdown="1">{cell.content}</td>\n'
		html += '</tr>\n'

	html += '</tbody>\n'