src/Lists/OrderedList.cs
/// <summary>
/// Get the prefix for each list item based on the formatting options and current index.
/// </summary>
/// <param name="formatting"></param>
/// <param name="index"></param>
/// <returns></returns>
Get the prefix for each list item based on the formatting options and current index.
Get the prefix for each list item based on the formatting options and current index .
protected override string GetPrefix(MarkdownFormatting formatting, int index)
        {
            if (Lettered)
            {
                int value = StartingNumber + index;
                string result = "";
                if (value > 26)
                {
                    result += (char)('a' + value / 26 - 1);
                    result += (char)('a' + value % 26 - 1);
                }
                else
                {
                    result += (char)('a' + value - 1);
                }
                return formatting?.OrderedListUsesSequence == true || index == 0 ? $"{result}. " : "a. ";
            }
            else
            {
                int value = formatting?.OrderedListUsesSequence == true
                    ? StartingNumber + index
                    : index == 0
                        ? StartingNumber
                        : 1;
                return $"{value}. ";
            }
        }
protected override string GetPrefix ( MarkdownFormatting formatting , int index ) { if ( Lettered ) { int value = StartingNumber + index ; string result = " " ; if ( value > 26 ) { result += ( char ) ( ' ' + value / 26 - 1 ) ; result += ( char ) ( ' ' + value % 26 - 1 ) ; } else { result += ( char ) ( ' ' + value - 1 ) ; } return formatting ? . OrderedListUsesSequence == true || index == 0 ? $" { result } .  " : " " ; } else { int value = formatting ? . OrderedListUsesSequence == true ? StartingNumber + index : index == 0 ? StartingNumber : 1 ; return $" { value } .  " ; } }
Get the prefix for each list item based on the formatting options and current index.
Get the prefix for each list item based on the formatting options and current index .
None
formatting
MarkdownFormatting
None
index
int
None