User:Bargioni/UseAsRef

UseAsRef is a User script written in collaboration with User:Epìdosis. It allows you to add references to statements on the basis of external IDs and, from the second version, also on the basis of other properties (described by source (P1343), official website (P856), official blog (P1581), curriculum vitae (P8214), terms of service URL (P7014), privacy policy URL (P7101), described at URL (P973), Academia.edu profile URL (P5715), full work available at URL (P953), exact match (P2888), online catalog (P8768)).

The first version (User:Bargioni/UseAsRef 1.0.js) was released in February 2021, the second version (User:Bargioni/UseAsRef.js) in October 2021.

InstallationEdit

To use this gadget add the following code to your common.js page:

importScript( 'User:Bargioni/UseAsRef.js' );

FunctioningEdit

  1. add to the item all the statements that will need a reference and all the IDs or other properties (see list above) you want to use as reference
  2. reload the item
  3. click on the "copy this as ref" icon in the property you want to use as reference; you will see a notification of the action and the icon of the copied ID will have a green boundary; if you copy many properties in a row, the gadget will consider the last one copied (only the one with the green boundary)
  4. click on the "paste copied ref" icon in the statement(s) you want to reference; you will see a notification of the edit(s) and the icon(s) of the referenced statement(s) will have a red boundary; you cannot paste the reference into a statement you are editing
  5. if you want to use another property as reference, click on its "copy this as ref" icon and then click on the "paste copied ref" icons in the statements you want to reference
  6. in order to see all references added, you can reload the item

The functioning is also showed in two Youtube videos: the first shows the functioning with external IDs; the second gives a general presentation of the gadget and shows the functioning with other statements.

Hints and caveatsEdit

ReferencesEdit

  1. At the moment about 60% of external IDs have P9073. Please see the following queries:

See alsoEdit