Skip to content

Commit

Permalink
Set TableHeaderColumnSpanHandling to true by default
Browse files Browse the repository at this point in the history
  • Loading branch information
mysticmind committed Jun 18, 2024
1 parent 9f17786 commit f06581c
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 11 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,15 @@ If you have used and benefitted from this library. Please feel free to buy me a
Install the package from NuGet using `Install-Package ReverseMarkdown` or clone the repository and built it yourself.

<!-- snippet: Usage -->
<a id='snippet-usage'></a>
<a id='snippet-Usage'></a>
```cs
var converter = new ReverseMarkdown.Converter();

string html = "This a sample <strong>paragraph</strong> from <a href=\"http://test.com\">my site</a>";

string result = converter.Convert(html);
```
<sup><a href='/src/ReverseMarkdown.Test/Snippets.cs#L11-L19' title='Snippet source file'>snippet source</a> | <a href='#snippet-usage' title='Start of snippet'>anchor</a></sup>
<sup><a href='/src/ReverseMarkdown.Test/Snippets.cs#L11-L19' title='Snippet source file'>snippet source</a> | <a href='#snippet-Usage' title='Start of snippet'>anchor</a></sup>
<!-- endSnippet -->

Will result in:
Expand All @@ -43,7 +43,7 @@ This a sample **paragraph** from [my site](http://test.com)
The conversion can be customized:

<!-- snippet: UsageWithConfig -->
<a id='snippet-usagewithconfig'></a>
<a id='snippet-UsageWithConfig'></a>
```cs
var config = new ReverseMarkdown.Config
{
Expand All @@ -59,7 +59,7 @@ var config = new ReverseMarkdown.Config

var converter = new ReverseMarkdown.Converter(config);
```
<sup><a href='/src/ReverseMarkdown.Test/Snippets.cs#L27-L43' title='Snippet source file'>snippet source</a> | <a href='#snippet-usagewithconfig' title='Start of snippet'>anchor</a></sup>
<sup><a href='/src/ReverseMarkdown.Test/Snippets.cs#L27-L43' title='Snippet source file'>snippet source</a> | <a href='#snippet-UsageWithConfig' title='Start of snippet'>anchor</a></sup>
<!-- endSnippet -->

## Configuration options
Expand Down
8 changes: 4 additions & 4 deletions README.source.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@ If you have used and benefitted from this library. Please feel free to buy me a
Install the package from NuGet using `Install-Package ReverseMarkdown` or clone the repository and build it yourself.

<!-- snippet: Usage -->
<a id='snippet-usage'></a>
<a id='snippet-Usage'></a>
```cs
var converter = new ReverseMarkdown.Converter();

string html = "This a sample <strong>paragraph</strong> from <a href=\"http://test.com\">my site</a>";

string result = converter.Convert(html);
```
<sup><a href='/src/ReverseMarkdown.Test/Snippets.cs#L11-L19' title='Snippet source file'>snippet source</a> | <a href='#snippet-usage' title='Start of snippet'>anchor</a></sup>
<sup><a href='/src/ReverseMarkdown.Test/Snippets.cs#L11-L19' title='Snippet source file'>snippet source</a> | <a href='#snippet-Usage' title='Start of snippet'>anchor</a></sup>
<!-- endSnippet -->

Will result in:
Expand All @@ -36,7 +36,7 @@ This a sample **paragraph** from [my site](http://test.com)
The conversion can also be customized:

<!-- snippet: UsageWithConfig -->
<a id='snippet-usagewithconfig'></a>
<a id='snippet-UsageWithConfig'></a>
```cs
var config = new ReverseMarkdown.Config
{
Expand All @@ -52,7 +52,7 @@ var config = new ReverseMarkdown.Config

var converter = new ReverseMarkdown.Converter(config);
```
<sup><a href='/src/ReverseMarkdown.Test/Snippets.cs#L27-L43' title='Snippet source file'>snippet source</a> | <a href='#snippet-usagewithconfig' title='Start of snippet'>anchor</a></sup>
<sup><a href='/src/ReverseMarkdown.Test/Snippets.cs#L27-L43' title='Snippet source file'>snippet source</a> | <a href='#snippet-UsageWithConfig' title='Start of snippet'>anchor</a></sup>
<!-- endSnippet -->

## Configuration options
Expand Down
3 changes: 1 addition & 2 deletions src/ReverseMarkdown.Test/ConverterTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1359,8 +1359,7 @@ public Task WhenTable_WithColSpan_TableHeaderColumnSpansHandling_ThenConvertToGF

var config = new Config
{
UnknownTags = Config.UnknownTagsOption.Bypass,
TableHeaderColumnSpanHandling = true
UnknownTags = Config.UnknownTagsOption.Bypass
};
return CheckConversion(html, config);
}
Expand Down
2 changes: 1 addition & 1 deletion src/ReverseMarkdown/Config.cs
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ public enum TableWithoutHeaderRowHandlingOption
/// <summary>
/// Set this flag to handle table header column with column spans
/// </summary>
public bool TableHeaderColumnSpanHandling { get; set; } = false;
public bool TableHeaderColumnSpanHandling { get; set; } = true;


/// <summary>
Expand Down

0 comments on commit f06581c

Please sign in to comment.