Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Juristische Zitierweise (Stüber) #3618

Merged
merged 3 commits into from
Aug 14, 2018

Conversation

zuphilip
Copy link
Member

  • chapter: fix mismatched use of title instead of container-title
  • chapter: add first page besides pages from locator, similar to journal article,
    e.g. Knemeyer, in: von Mutius, FG für von Unruh, S. 209 (209).
  • use non-breakable space between locator and label
  • encyclopedia-aricles: fix problem when title is missing
  • prefer short-title in footnote citations
  • wegpage: add date in bibliography with prefix "Stand: "

- chapter: fix mismatched use of title instead of container-title
- chapter: add first page besides pages from locator, similar to journal article,
e.g. Knemeyer, in: von Mutius, FG für von Unruh, S. 209 (209).
- use non-breakable space between locator and label
- encyclopedia-aricles: fix problem when title is missing
- prefer short-title in footnote citations
- wegpage: add date in bibliography with prefix "Stand: "
@csl-bot
Copy link

csl-bot commented Jul 21, 2018

Awesome! You just created a pull request to the Citation Styles Language styles repository. One of our human volunteers will try to get in touch soon (usually within a week). In the meantime, I will run some automated checks. You should be notified of the results in a few minutes.

If you haven't done so yet, please make sure your style validates and follows all our other Style Requirements.

To update this pull request, visit the "Files changed" tab above, and click on the pencil icon (see below) in the top-right corner of your style to start editing.

If you have any questions, please leave a comment and we'll get back to you. While we usually respond in English, feel free to write in whatever language you're most comfortable.

@@ -60,7 +60,7 @@
<names variable="editor">
<name form="short" delimiter="/" initialize-with=""/>
</names>
<text variable="title"/>
<text variable="container-title" form="short"/>
Copy link
Member Author

@zuphilip zuphilip Jul 21, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added manually a container-title-short in one example of the csl-editor but this did not show up here. Is that forbidden for a chapter?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, CSL 1.0.1 puts no restrictions on which fields can be used with which item types. Might be some kind of bug in the editor. (if it's not too much work, it might help if you could give the exact steps to reproduce this problem)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay, I created an item of type chapter in Zotero and export it to CSL JSON, added there the field container-title-short with a value and then import that (without the outermost parenthesis for a set) into the CSL editor, where I don't see any effect of the short container title.

I used this CSL-JSON data

{
	"id": "http://zotero.org/users/96641/items/TFNFUVLI",
	"type": "chapter",
	"title": "Endnotes",
	"container-title": "The World is Open",
	"container-title-short": "TWO",
	"publisher": "Wiley-Blackwell",
	"page": "427-467",
	"source": "Wiley Online Library",
	"URL": "https://onlinelibrary.wiley.com/doi/abs/10.1002/9781118269381.notes",
	"ISBN": "978-1-118-26938-1",
	"note": "DOI: 10.1002/9781118269381.notes",
	"language": "en",
	"issued": {
		"date-parts": [
			[
				"2012"
			]
		]
	},
	"accessed": {
		"date-parts": [
			[
				"2018",
				7,
				2
			]
		]
	}
}

Any idea?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems to work fine for me. I loaded this JSON into the visual editor, and edited the style to use

<text variable="container-title-short"/>

which prints "TWO" for the bibliography:


screen shot 2018-08-11 at 01 04 20

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay, and what happens if you take instead

<text variable="container-title" form="short"/>

?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems like a similar situation to what we had with "shortTitle" and "title-short". I can raise the issue with Frank.

That would be great. Thank you!

Anything we should do in this PR or can it be merged now?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Anything we should do in this PR or can it be merged now?

Well, <text variable="container-title" form="short"/> and <text variable="container-title-short"/> are both correct CSL in this case. And as Zotero currently doesn't offer a variable for chapters (https://aurimasv.github.io/z2csl/typeMap.xml#map-bookSection), it doesn't really matter which one we pick here.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do both variants use container-title if the short form is not present?

Do you suggest to switch the form here? Maybe I am missing something else here...?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do both variants use container-title if the short form is not present?

I think only the form="short" call has fallback to the "long" form if unavailable. See http://docs.citationstyles.org/en/1.0.1/specification.html#text. Pretty sure the CSL specification is silent on fallback for "container-title-short".

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay. How do you want to finish this PR then? (I would like to complete this soon as I have promised to some PhD candidates here...)

@csl-bot
Copy link

csl-bot commented Jul 21, 2018

😃 Your submission passed all our automated tests.

@@ -40,7 +40,7 @@
</names>
</macro>
<macro name="locator-with-label">
<group delimiter=" ">
<group delimiter="&amp;#160;">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did you add these non-breaking spaces by hand? And did you actually test the style? This doesn't look correct.

&amp; is the ampersand, and is followed by plain text "#160;". To get a non-breaking space, only use &#160;.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@zuphilip, bump.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added them by hand in the CSL editor and they still look fine within the editor:

csl-editor-nonbreaking-space
It might simply be that exporting the style from there is then escaping it wrongly.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay, I checked and it is also in the Code editor wrongly escaped. I will fix these issues w/o the editor.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe copy and pasting the non-breaking space character into the delimiter field works. But yeah, it looks like the code escapes the ampersand sign.

@@ -111,14 +111,22 @@
<group delimiter=", ">
<text macro="author-note"/>
<text macro="inbook"/>
<text macro="locator-with-label"/>
<group delimiter=" ">
<group delimiter="&amp;#160;">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same issue here.

@@ -247,6 +255,7 @@
<group delimiter=", ">
<text macro="author"/>
<text variable="title"/>
<date form="text" variable="issued" prefix="Stand: "/>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just curious, what does the "Stand" label mean?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Stand would roughly translates to "as it stands as of [date]" so it's somewhat similar to accessed on, but not quite (which is why I assume zuphilip is using it with the issued date)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"Stand" is IMO a data which represents the version/edition of that work, and yes @adam3smith is right that I therefore choose here the variable issued. However, websites are only used rarely in law publications.

@adam3smith adam3smith added the waiting The ticket/pull request is awaiting input from the contributor/depositor label Aug 4, 2018
@csl-bot
Copy link

csl-bot commented Aug 7, 2018

😃 Your submission passed all our automated tests.

@adam3smith adam3smith removed the waiting The ticket/pull request is awaiting input from the contributor/depositor label Aug 7, 2018
@zuphilip
Copy link
Member Author

zuphilip commented Aug 7, 2018

Okay, I updated the style according to your remarks @rmzelle . That should be fine now.

@csl-bot
Copy link

csl-bot commented Aug 11, 2018

😃 Your submission passed all our automated tests.

@rmzelle rmzelle merged commit 4ee024a into citation-style-language:master Aug 14, 2018
@rmzelle
Copy link
Member

rmzelle commented Aug 14, 2018

Thanks!

@zuphilip
Copy link
Member Author

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants