Skip to content

Bug report: delimiter-precedes-last="always" not working #248

@zepinglee

Description

@zepinglee

The last delimiter with delimiter-precedes-last="always" attribute is missing when the last name is in the literal form.

Expected:

George Lakoff, and Mark Johnson
George Lakoff, and Mark Johnson

Actual result:

George Lakoff and Mark Johnson
George Lakoff, and Mark Johnson

Full fixture:

>>===== MODE =====>>
citation
<<===== MODE =====<<


>>===== RESULT =====>>
George Lakoff, and Mark Johnson
George Lakoff, and Mark Johnson
<<===== RESULT =====<<


>>===== CSL =====>>
<style xmlns="http://purl.org/net/xbiblio/csl" class="in-text" version="1.0">
  <info>
    <id />
    <title />
    <updated>2025-01-10T19:12:06+08:00</updated>
  </info>
  <macro name="author">
    <names variable="author">
      <name and="text" delimiter-precedes-last="always"/>
    </names>
  </macro>
  <citation>
    <layout>
      <text macro="author"/>
    </layout>
  </citation>
</style>
<<===== CSL =====<<


>>===== CITATION-ITEMS =====>>
[
    [
        {
            "id": "ITEM-1"
        }
    ],
    [
        {
            "id": "ITEM-2"
        }
    ]
]
<<===== CITATION-ITEMS =====<<


>>===== INPUT =====>>
[
    {
        "id": "ITEM-1",
        "type": "book",
        "author": [
            {
                "family": "Lakoff",
                "given": "George"
            },
            {
                "literal": "Mark Johnson"
            }
        ]
    },
    {
        "id": "ITEM-2",
        "type": "book",
        "author": [
            {
                "family": "Lakoff",
                "given": "George"
            },
            {
                "family": "Johnson",
                "given": "Mark"
            }
        ]
    }
]
<<===== INPUT =====<<


>>===== VERSION =====>>
1.0
<<===== VERSION =====<<

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions