@citeproc-rs/wasm
Advanced tools
Comparing version 0.0.0-canary-289a710 to 0.0.0-canary-6024e27
@@ -7,4 +7,7 @@ /* tslint:disable */ | ||
export function driver_setStyle(a: number, b: number, c: number): number; | ||
export function driver_resetReferences(a: number, b: number, c: number): void; | ||
export function driver_setReferences(a: number, b: number, c: number): void; | ||
export function driver_insertReference(a: number, b: number): void; | ||
export function driver_removeReference(a: number, b: number, c: number): void; | ||
export function driver_includeUncited(a: number, b: number): void; | ||
export function driver_toFetch(a: number): number; | ||
@@ -15,2 +18,3 @@ export function driver_insertCluster(a: number, b: number): void; | ||
export function driver_builtCluster(a: number, b: number): number; | ||
export function driver_previewCitationCluster(a: number, b: number, c: number, d: number, e: number, f: number, g: number): number; | ||
export function driver_makeBibliography(a: number): number; | ||
@@ -17,0 +21,0 @@ export function driver_bibliographyMeta(a: number): number; |
@@ -34,3 +34,3 @@ /* tslint:disable */ | ||
suppression?: "InText" | "Rest" | null; | ||
} & CiteLocator; | ||
} & Partial<CiteLocator>; | ||
@@ -89,5 +89,5 @@ export type ClusterNumber = { | ||
type IncludeUncited = "None" | "All" | { Specific: string[] }; | ||
/** | ||
@@ -118,3 +118,10 @@ */ | ||
/** | ||
* Completely overwrites the references library. | ||
* This **will** delete references that are not in the provided list. | ||
* @param {any[]} refs | ||
*/ | ||
resetReferences(refs: any[]): void; | ||
/** | ||
* Inserts or overwrites references as a batch operation. | ||
* This **will not** delete references that are not in the provided list. | ||
* @param {any[]} refs | ||
@@ -126,6 +133,19 @@ */ | ||
* | ||
* * `refr` is a Reference object. | ||
* @param {Reference} refr | ||
*/ | ||
insertReference(refr: Reference): void; | ||
/** | ||
* Removes a reference by id. If it is cited, any cites will be dangling. It will also | ||
* disappear from the bibliography. | ||
* @param {string} id | ||
*/ | ||
removeReference(id: string): void; | ||
/** | ||
* Sets the references to be included in the bibliography despite not being directly cited. | ||
* | ||
* * `refr` is a | ||
* @param {any} refr | ||
* @param {IncludeUncited} uncited | ||
*/ | ||
insertReference(refr: any): void; | ||
includeUncited(uncited: IncludeUncited): void; | ||
/** | ||
@@ -165,4 +185,18 @@ * Gets a list of locales in use by the references currently loaded. | ||
/** | ||
* Previews a formatted citation cluster, in a particular position. | ||
* | ||
* - `cites`: The cites to go in the cluster | ||
* - `positions`: An array of `ClusterPosition`s as in set_cluster_order, but with a single | ||
* cluster's id set to zero. The cluster with id=0 is the position to preview the cite. It | ||
* can replace another cluster, or be inserted before/after/between existing clusters, in | ||
* any location you can think of. | ||
* @param {any[]} cites | ||
* @param {any[]} positions | ||
* @param {string} format | ||
* @returns {any} | ||
*/ | ||
previewCitationCluster(cites: any[], positions: any[], format: string): any; | ||
/** | ||
* @returns {any} | ||
*/ | ||
makeBibliography(): any; | ||
@@ -220,5 +254,5 @@ /** | ||
* May error without having set_cluster_ids, but with some set_cluster_note_number-s executed. | ||
* @param {any[]} pieces | ||
* @param {any[]} positions | ||
*/ | ||
setClusterOrder(pieces: any[]): void; | ||
setClusterOrder(positions: any[]): void; | ||
/** | ||
@@ -232,5 +266,5 @@ * Retrieve any clusters that have been touched since last time `batchedUpdates` was | ||
* * returns an `UpdateSummary` | ||
* @returns {any} | ||
* @returns {UpdateSummary} | ||
*/ | ||
batchedUpdates(): any; | ||
batchedUpdates(): UpdateSummary; | ||
/** | ||
@@ -237,0 +271,0 @@ * Drains the `batchedUpdates` queue manually. Use it to avoid serializing an unneeded |
@@ -138,3 +138,3 @@ let imports = {}; | ||
} | ||
function __wbg_adapter_59(arg0, arg1, arg2, arg3) { | ||
function __wbg_adapter_63(arg0, arg1, arg2, arg3) { | ||
wasm.wasm_bindgen__convert__closures__invoke2_mut__h19f62226ce422262(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3)); | ||
@@ -193,3 +193,14 @@ } | ||
/** | ||
* Completely overwrites the references library. | ||
* This **will** delete references that are not in the provided list. | ||
* @param {any[]} refs | ||
*/ | ||
resetReferences(refs) { | ||
var ptr0 = passArrayJsValueToWasm0(refs, wasm.__wbindgen_malloc); | ||
var len0 = WASM_VECTOR_LEN; | ||
wasm.driver_resetReferences(this.ptr, ptr0, len0); | ||
} | ||
/** | ||
* Inserts or overwrites references as a batch operation. | ||
* This **will not** delete references that are not in the provided list. | ||
* @param {any[]} refs | ||
@@ -205,4 +216,4 @@ */ | ||
* | ||
* * `refr` is a | ||
* @param {any} refr | ||
* * `refr` is a Reference object. | ||
* @param {Reference} refr | ||
*/ | ||
@@ -213,2 +224,21 @@ insertReference(refr) { | ||
/** | ||
* Removes a reference by id. If it is cited, any cites will be dangling. It will also | ||
* disappear from the bibliography. | ||
* @param {string} id | ||
*/ | ||
removeReference(id) { | ||
var ptr0 = passStringToWasm0(id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); | ||
var len0 = WASM_VECTOR_LEN; | ||
wasm.driver_removeReference(this.ptr, ptr0, len0); | ||
} | ||
/** | ||
* Sets the references to be included in the bibliography despite not being directly cited. | ||
* | ||
* * `refr` is a | ||
* @param {IncludeUncited} uncited | ||
*/ | ||
includeUncited(uncited) { | ||
wasm.driver_includeUncited(this.ptr, addHeapObject(uncited)); | ||
} | ||
/** | ||
* Gets a list of locales in use by the references currently loaded. | ||
@@ -261,4 +291,27 @@ * | ||
/** | ||
* Previews a formatted citation cluster, in a particular position. | ||
* | ||
* - `cites`: The cites to go in the cluster | ||
* - `positions`: An array of `ClusterPosition`s as in set_cluster_order, but with a single | ||
* cluster's id set to zero. The cluster with id=0 is the position to preview the cite. It | ||
* can replace another cluster, or be inserted before/after/between existing clusters, in | ||
* any location you can think of. | ||
* @param {any[]} cites | ||
* @param {any[]} positions | ||
* @param {string} format | ||
* @returns {any} | ||
*/ | ||
previewCitationCluster(cites, positions, format) { | ||
var ptr0 = passArrayJsValueToWasm0(cites, wasm.__wbindgen_malloc); | ||
var len0 = WASM_VECTOR_LEN; | ||
var ptr1 = passArrayJsValueToWasm0(positions, wasm.__wbindgen_malloc); | ||
var len1 = WASM_VECTOR_LEN; | ||
var ptr2 = passStringToWasm0(format, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); | ||
var len2 = WASM_VECTOR_LEN; | ||
var ret = wasm.driver_previewCitationCluster(this.ptr, ptr0, len0, ptr1, len1, ptr2, len2); | ||
return takeObject(ret); | ||
} | ||
/** | ||
* @returns {any} | ||
*/ | ||
makeBibliography() { | ||
@@ -326,6 +379,6 @@ var ret = wasm.driver_makeBibliography(this.ptr); | ||
* May error without having set_cluster_ids, but with some set_cluster_note_number-s executed. | ||
* @param {any[]} pieces | ||
* @param {any[]} positions | ||
*/ | ||
setClusterOrder(pieces) { | ||
var ptr0 = passArrayJsValueToWasm0(pieces, wasm.__wbindgen_malloc); | ||
setClusterOrder(positions) { | ||
var ptr0 = passArrayJsValueToWasm0(positions, wasm.__wbindgen_malloc); | ||
var len0 = WASM_VECTOR_LEN; | ||
@@ -342,3 +395,3 @@ wasm.driver_setClusterOrder(this.ptr, ptr0, len0); | ||
* * returns an `UpdateSummary` | ||
* @returns {any} | ||
* @returns {UpdateSummary} | ||
*/ | ||
@@ -368,22 +421,2 @@ batchedUpdates() { | ||
module.exports.__wbg_debug_4885c3f7d6f044a3 = function(arg0, arg1) { | ||
console.debug(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
module.exports.__wbg_log_bee3ea1a89f334d8 = function(arg0, arg1) { | ||
console.log(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
module.exports.__wbg_info_0547ff9513f2019b = function(arg0, arg1) { | ||
console.info(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
module.exports.__wbg_warn_a478dea6e6e05394 = function(arg0, arg1) { | ||
console.warn(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
module.exports.__wbg_error_72e88ba6901b6eee = function(arg0, arg1) { | ||
console.error(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
module.exports.__wbindgen_object_drop_ref = function(arg0) { | ||
@@ -416,2 +449,27 @@ takeObject(arg0); | ||
module.exports.__wbg_debug_4885c3f7d6f044a3 = function(arg0, arg1) { | ||
console.debug(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
module.exports.__wbg_log_bee3ea1a89f334d8 = function(arg0, arg1) { | ||
console.log(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
module.exports.__wbg_info_0547ff9513f2019b = function(arg0, arg1) { | ||
console.info(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
module.exports.__wbg_warn_a478dea6e6e05394 = function(arg0, arg1) { | ||
console.warn(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
module.exports.__wbg_error_72e88ba6901b6eee = function(arg0, arg1) { | ||
console.error(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
module.exports.__wbindgen_json_parse = function(arg0, arg1) { | ||
var ret = JSON.parse(getStringFromWasm0(arg0, arg1)); | ||
return addHeapObject(ret); | ||
}; | ||
module.exports.__wbindgen_cb_drop = function(arg0) { | ||
@@ -427,7 +485,2 @@ const obj = takeObject(arg0).original; | ||
module.exports.__wbindgen_json_parse = function(arg0, arg1) { | ||
var ret = JSON.parse(getStringFromWasm0(arg0, arg1)); | ||
return addHeapObject(ret); | ||
}; | ||
module.exports.__wbg_new_59cb74e423758ede = function() { | ||
@@ -471,3 +524,3 @@ var ret = new Error(); | ||
try { | ||
return __wbg_adapter_59(a, state0.b, arg0, arg1); | ||
return __wbg_adapter_63(a, state0.b, arg0, arg1); | ||
} finally { | ||
@@ -516,4 +569,4 @@ state0.a = a; | ||
module.exports.__wbindgen_closure_wrapper1070 = function(arg0, arg1, arg2) { | ||
var ret = makeMutClosure(arg0, arg1, 190, __wbg_adapter_18); | ||
module.exports.__wbindgen_closure_wrapper839 = function(arg0, arg1, arg2) { | ||
var ret = makeMutClosure(arg0, arg1, 197, __wbg_adapter_18); | ||
return addHeapObject(ret); | ||
@@ -520,0 +573,0 @@ }; |
@@ -7,4 +7,7 @@ /* tslint:disable */ | ||
export function driver_setStyle(a: number, b: number, c: number): number; | ||
export function driver_resetReferences(a: number, b: number, c: number): void; | ||
export function driver_setReferences(a: number, b: number, c: number): void; | ||
export function driver_insertReference(a: number, b: number): void; | ||
export function driver_removeReference(a: number, b: number, c: number): void; | ||
export function driver_includeUncited(a: number, b: number): void; | ||
export function driver_toFetch(a: number): number; | ||
@@ -15,2 +18,3 @@ export function driver_insertCluster(a: number, b: number): void; | ||
export function driver_builtCluster(a: number, b: number): number; | ||
export function driver_previewCitationCluster(a: number, b: number, c: number, d: number, e: number, f: number, g: number): number; | ||
export function driver_makeBibliography(a: number): number; | ||
@@ -17,0 +21,0 @@ export function driver_bibliographyMeta(a: number): number; |
@@ -175,3 +175,3 @@ import * as wasm from './citeproc_rs_wasm_bg.wasm'; | ||
} | ||
function __wbg_adapter_59(arg0, arg1, arg2, arg3) { | ||
function __wbg_adapter_63(arg0, arg1, arg2, arg3) { | ||
wasm.wasm_bindgen__convert__closures__invoke2_mut__h19f62226ce422262(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3)); | ||
@@ -230,3 +230,14 @@ } | ||
/** | ||
* Completely overwrites the references library. | ||
* This **will** delete references that are not in the provided list. | ||
* @param {any[]} refs | ||
*/ | ||
resetReferences(refs) { | ||
var ptr0 = passArrayJsValueToWasm0(refs, wasm.__wbindgen_malloc); | ||
var len0 = WASM_VECTOR_LEN; | ||
wasm.driver_resetReferences(this.ptr, ptr0, len0); | ||
} | ||
/** | ||
* Inserts or overwrites references as a batch operation. | ||
* This **will not** delete references that are not in the provided list. | ||
* @param {any[]} refs | ||
@@ -242,4 +253,4 @@ */ | ||
* | ||
* * `refr` is a | ||
* @param {any} refr | ||
* * `refr` is a Reference object. | ||
* @param {Reference} refr | ||
*/ | ||
@@ -250,2 +261,21 @@ insertReference(refr) { | ||
/** | ||
* Removes a reference by id. If it is cited, any cites will be dangling. It will also | ||
* disappear from the bibliography. | ||
* @param {string} id | ||
*/ | ||
removeReference(id) { | ||
var ptr0 = passStringToWasm0(id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); | ||
var len0 = WASM_VECTOR_LEN; | ||
wasm.driver_removeReference(this.ptr, ptr0, len0); | ||
} | ||
/** | ||
* Sets the references to be included in the bibliography despite not being directly cited. | ||
* | ||
* * `refr` is a | ||
* @param {IncludeUncited} uncited | ||
*/ | ||
includeUncited(uncited) { | ||
wasm.driver_includeUncited(this.ptr, addHeapObject(uncited)); | ||
} | ||
/** | ||
* Gets a list of locales in use by the references currently loaded. | ||
@@ -298,4 +328,27 @@ * | ||
/** | ||
* Previews a formatted citation cluster, in a particular position. | ||
* | ||
* - `cites`: The cites to go in the cluster | ||
* - `positions`: An array of `ClusterPosition`s as in set_cluster_order, but with a single | ||
* cluster's id set to zero. The cluster with id=0 is the position to preview the cite. It | ||
* can replace another cluster, or be inserted before/after/between existing clusters, in | ||
* any location you can think of. | ||
* @param {any[]} cites | ||
* @param {any[]} positions | ||
* @param {string} format | ||
* @returns {any} | ||
*/ | ||
previewCitationCluster(cites, positions, format) { | ||
var ptr0 = passArrayJsValueToWasm0(cites, wasm.__wbindgen_malloc); | ||
var len0 = WASM_VECTOR_LEN; | ||
var ptr1 = passArrayJsValueToWasm0(positions, wasm.__wbindgen_malloc); | ||
var len1 = WASM_VECTOR_LEN; | ||
var ptr2 = passStringToWasm0(format, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); | ||
var len2 = WASM_VECTOR_LEN; | ||
var ret = wasm.driver_previewCitationCluster(this.ptr, ptr0, len0, ptr1, len1, ptr2, len2); | ||
return takeObject(ret); | ||
} | ||
/** | ||
* @returns {any} | ||
*/ | ||
makeBibliography() { | ||
@@ -363,6 +416,6 @@ var ret = wasm.driver_makeBibliography(this.ptr); | ||
* May error without having set_cluster_ids, but with some set_cluster_note_number-s executed. | ||
* @param {any[]} pieces | ||
* @param {any[]} positions | ||
*/ | ||
setClusterOrder(pieces) { | ||
var ptr0 = passArrayJsValueToWasm0(pieces, wasm.__wbindgen_malloc); | ||
setClusterOrder(positions) { | ||
var ptr0 = passArrayJsValueToWasm0(positions, wasm.__wbindgen_malloc); | ||
var len0 = WASM_VECTOR_LEN; | ||
@@ -379,3 +432,3 @@ wasm.driver_setClusterOrder(this.ptr, ptr0, len0); | ||
* * returns an `UpdateSummary` | ||
* @returns {any} | ||
* @returns {UpdateSummary} | ||
*/ | ||
@@ -404,22 +457,2 @@ batchedUpdates() { | ||
export const __wbg_debug_4885c3f7d6f044a3 = function(arg0, arg1) { | ||
console.debug(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
export const __wbg_log_bee3ea1a89f334d8 = function(arg0, arg1) { | ||
console.log(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
export const __wbg_info_0547ff9513f2019b = function(arg0, arg1) { | ||
console.info(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
export const __wbg_warn_a478dea6e6e05394 = function(arg0, arg1) { | ||
console.warn(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
export const __wbg_error_72e88ba6901b6eee = function(arg0, arg1) { | ||
console.error(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
export const __wbindgen_object_drop_ref = function(arg0) { | ||
@@ -452,2 +485,27 @@ takeObject(arg0); | ||
export const __wbg_debug_4885c3f7d6f044a3 = function(arg0, arg1) { | ||
console.debug(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
export const __wbg_log_bee3ea1a89f334d8 = function(arg0, arg1) { | ||
console.log(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
export const __wbg_info_0547ff9513f2019b = function(arg0, arg1) { | ||
console.info(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
export const __wbg_warn_a478dea6e6e05394 = function(arg0, arg1) { | ||
console.warn(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
export const __wbg_error_72e88ba6901b6eee = function(arg0, arg1) { | ||
console.error(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
export const __wbindgen_json_parse = function(arg0, arg1) { | ||
var ret = JSON.parse(getStringFromWasm0(arg0, arg1)); | ||
return addHeapObject(ret); | ||
}; | ||
export const __wbindgen_cb_drop = function(arg0) { | ||
@@ -463,7 +521,2 @@ const obj = takeObject(arg0).original; | ||
export const __wbindgen_json_parse = function(arg0, arg1) { | ||
var ret = JSON.parse(getStringFromWasm0(arg0, arg1)); | ||
return addHeapObject(ret); | ||
}; | ||
export const __wbg_new_59cb74e423758ede = function() { | ||
@@ -507,3 +560,3 @@ var ret = new Error(); | ||
try { | ||
return __wbg_adapter_59(a, state0.b, arg0, arg1); | ||
return __wbg_adapter_63(a, state0.b, arg0, arg1); | ||
} finally { | ||
@@ -552,6 +605,6 @@ state0.a = a; | ||
export const __wbindgen_closure_wrapper1070 = function(arg0, arg1, arg2) { | ||
var ret = makeMutClosure(arg0, arg1, 190, __wbg_adapter_18); | ||
export const __wbindgen_closure_wrapper839 = function(arg0, arg1, arg2) { | ||
var ret = makeMutClosure(arg0, arg1, 197, __wbg_adapter_18); | ||
return addHeapObject(ret); | ||
}; | ||
@@ -34,3 +34,3 @@ /* tslint:disable */ | ||
suppression?: "InText" | "Rest" | null; | ||
} & CiteLocator; | ||
} & Partial<CiteLocator>; | ||
@@ -89,5 +89,5 @@ export type ClusterNumber = { | ||
type IncludeUncited = "None" | "All" | { Specific: string[] }; | ||
/** | ||
@@ -118,3 +118,10 @@ */ | ||
/** | ||
* Completely overwrites the references library. | ||
* This **will** delete references that are not in the provided list. | ||
* @param {any[]} refs | ||
*/ | ||
resetReferences(refs: any[]): void; | ||
/** | ||
* Inserts or overwrites references as a batch operation. | ||
* This **will not** delete references that are not in the provided list. | ||
* @param {any[]} refs | ||
@@ -126,6 +133,19 @@ */ | ||
* | ||
* * `refr` is a Reference object. | ||
* @param {Reference} refr | ||
*/ | ||
insertReference(refr: Reference): void; | ||
/** | ||
* Removes a reference by id. If it is cited, any cites will be dangling. It will also | ||
* disappear from the bibliography. | ||
* @param {string} id | ||
*/ | ||
removeReference(id: string): void; | ||
/** | ||
* Sets the references to be included in the bibliography despite not being directly cited. | ||
* | ||
* * `refr` is a | ||
* @param {any} refr | ||
* @param {IncludeUncited} uncited | ||
*/ | ||
insertReference(refr: any): void; | ||
includeUncited(uncited: IncludeUncited): void; | ||
/** | ||
@@ -165,4 +185,18 @@ * Gets a list of locales in use by the references currently loaded. | ||
/** | ||
* Previews a formatted citation cluster, in a particular position. | ||
* | ||
* - `cites`: The cites to go in the cluster | ||
* - `positions`: An array of `ClusterPosition`s as in set_cluster_order, but with a single | ||
* cluster's id set to zero. The cluster with id=0 is the position to preview the cite. It | ||
* can replace another cluster, or be inserted before/after/between existing clusters, in | ||
* any location you can think of. | ||
* @param {any[]} cites | ||
* @param {any[]} positions | ||
* @param {string} format | ||
* @returns {any} | ||
*/ | ||
previewCitationCluster(cites: any[], positions: any[], format: string): any; | ||
/** | ||
* @returns {any} | ||
*/ | ||
makeBibliography(): any; | ||
@@ -220,5 +254,5 @@ /** | ||
* May error without having set_cluster_ids, but with some set_cluster_note_number-s executed. | ||
* @param {any[]} pieces | ||
* @param {any[]} positions | ||
*/ | ||
setClusterOrder(pieces: any[]): void; | ||
setClusterOrder(positions: any[]): void; | ||
/** | ||
@@ -232,5 +266,5 @@ * Retrieve any clusters that have been touched since last time `batchedUpdates` was | ||
* * returns an `UpdateSummary` | ||
* @returns {any} | ||
* @returns {UpdateSummary} | ||
*/ | ||
batchedUpdates(): any; | ||
batchedUpdates(): UpdateSummary; | ||
/** | ||
@@ -237,0 +271,0 @@ * Drains the `batchedUpdates` queue manually. Use it to avoid serializing an unneeded |
@@ -7,4 +7,7 @@ /* tslint:disable */ | ||
export function driver_setStyle(a: number, b: number, c: number): number; | ||
export function driver_resetReferences(a: number, b: number, c: number): void; | ||
export function driver_setReferences(a: number, b: number, c: number): void; | ||
export function driver_insertReference(a: number, b: number): void; | ||
export function driver_removeReference(a: number, b: number, c: number): void; | ||
export function driver_includeUncited(a: number, b: number): void; | ||
export function driver_toFetch(a: number): number; | ||
@@ -15,2 +18,3 @@ export function driver_insertCluster(a: number, b: number): void; | ||
export function driver_builtCluster(a: number, b: number): number; | ||
export function driver_previewCitationCluster(a: number, b: number, c: number, d: number, e: number, f: number, g: number): number; | ||
export function driver_makeBibliography(a: number): number; | ||
@@ -17,0 +21,0 @@ export function driver_bibliographyMeta(a: number): number; |
@@ -34,3 +34,3 @@ /* tslint:disable */ | ||
suppression?: "InText" | "Rest" | null; | ||
} & CiteLocator; | ||
} & Partial<CiteLocator>; | ||
@@ -89,5 +89,5 @@ export type ClusterNumber = { | ||
type IncludeUncited = "None" | "All" | { Specific: string[] }; | ||
/** | ||
@@ -118,3 +118,10 @@ */ | ||
/** | ||
* Completely overwrites the references library. | ||
* This **will** delete references that are not in the provided list. | ||
* @param {any[]} refs | ||
*/ | ||
resetReferences(refs: any[]): void; | ||
/** | ||
* Inserts or overwrites references as a batch operation. | ||
* This **will not** delete references that are not in the provided list. | ||
* @param {any[]} refs | ||
@@ -126,6 +133,19 @@ */ | ||
* | ||
* * `refr` is a Reference object. | ||
* @param {Reference} refr | ||
*/ | ||
insertReference(refr: Reference): void; | ||
/** | ||
* Removes a reference by id. If it is cited, any cites will be dangling. It will also | ||
* disappear from the bibliography. | ||
* @param {string} id | ||
*/ | ||
removeReference(id: string): void; | ||
/** | ||
* Sets the references to be included in the bibliography despite not being directly cited. | ||
* | ||
* * `refr` is a | ||
* @param {any} refr | ||
* @param {IncludeUncited} uncited | ||
*/ | ||
insertReference(refr: any): void; | ||
includeUncited(uncited: IncludeUncited): void; | ||
/** | ||
@@ -165,4 +185,18 @@ * Gets a list of locales in use by the references currently loaded. | ||
/** | ||
* Previews a formatted citation cluster, in a particular position. | ||
* | ||
* - `cites`: The cites to go in the cluster | ||
* - `positions`: An array of `ClusterPosition`s as in set_cluster_order, but with a single | ||
* cluster's id set to zero. The cluster with id=0 is the position to preview the cite. It | ||
* can replace another cluster, or be inserted before/after/between existing clusters, in | ||
* any location you can think of. | ||
* @param {any[]} cites | ||
* @param {any[]} positions | ||
* @param {string} format | ||
* @returns {any} | ||
*/ | ||
previewCitationCluster(cites: any[], positions: any[], format: string): any; | ||
/** | ||
* @returns {any} | ||
*/ | ||
makeBibliography(): any; | ||
@@ -220,5 +254,5 @@ /** | ||
* May error without having set_cluster_ids, but with some set_cluster_note_number-s executed. | ||
* @param {any[]} pieces | ||
* @param {any[]} positions | ||
*/ | ||
setClusterOrder(pieces: any[]): void; | ||
setClusterOrder(positions: any[]): void; | ||
/** | ||
@@ -232,5 +266,5 @@ * Retrieve any clusters that have been touched since last time `batchedUpdates` was | ||
* * returns an `UpdateSummary` | ||
* @returns {any} | ||
* @returns {UpdateSummary} | ||
*/ | ||
batchedUpdates(): any; | ||
batchedUpdates(): UpdateSummary; | ||
/** | ||
@@ -256,4 +290,7 @@ * Drains the `batchedUpdates` queue manually. Use it to avoid serializing an unneeded | ||
readonly driver_setStyle: (a: number, b: number, c: number) => number; | ||
readonly driver_resetReferences: (a: number, b: number, c: number) => void; | ||
readonly driver_setReferences: (a: number, b: number, c: number) => void; | ||
readonly driver_insertReference: (a: number, b: number) => void; | ||
readonly driver_removeReference: (a: number, b: number, c: number) => void; | ||
readonly driver_includeUncited: (a: number, b: number) => void; | ||
readonly driver_toFetch: (a: number) => number; | ||
@@ -264,2 +301,3 @@ readonly driver_insertCluster: (a: number, b: number) => void; | ||
readonly driver_builtCluster: (a: number, b: number) => number; | ||
readonly driver_previewCitationCluster: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => number; | ||
readonly driver_makeBibliography: (a: number) => number; | ||
@@ -266,0 +304,0 @@ readonly driver_bibliographyMeta: (a: number) => number; |
@@ -172,3 +172,3 @@ | ||
} | ||
function __wbg_adapter_59(arg0, arg1, arg2, arg3) { | ||
function __wbg_adapter_63(arg0, arg1, arg2, arg3) { | ||
wasm.wasm_bindgen__convert__closures__invoke2_mut__h19f62226ce422262(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3)); | ||
@@ -227,3 +227,14 @@ } | ||
/** | ||
* Completely overwrites the references library. | ||
* This **will** delete references that are not in the provided list. | ||
* @param {any[]} refs | ||
*/ | ||
resetReferences(refs) { | ||
var ptr0 = passArrayJsValueToWasm0(refs, wasm.__wbindgen_malloc); | ||
var len0 = WASM_VECTOR_LEN; | ||
wasm.driver_resetReferences(this.ptr, ptr0, len0); | ||
} | ||
/** | ||
* Inserts or overwrites references as a batch operation. | ||
* This **will not** delete references that are not in the provided list. | ||
* @param {any[]} refs | ||
@@ -239,4 +250,4 @@ */ | ||
* | ||
* * `refr` is a | ||
* @param {any} refr | ||
* * `refr` is a Reference object. | ||
* @param {Reference} refr | ||
*/ | ||
@@ -247,2 +258,21 @@ insertReference(refr) { | ||
/** | ||
* Removes a reference by id. If it is cited, any cites will be dangling. It will also | ||
* disappear from the bibliography. | ||
* @param {string} id | ||
*/ | ||
removeReference(id) { | ||
var ptr0 = passStringToWasm0(id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); | ||
var len0 = WASM_VECTOR_LEN; | ||
wasm.driver_removeReference(this.ptr, ptr0, len0); | ||
} | ||
/** | ||
* Sets the references to be included in the bibliography despite not being directly cited. | ||
* | ||
* * `refr` is a | ||
* @param {IncludeUncited} uncited | ||
*/ | ||
includeUncited(uncited) { | ||
wasm.driver_includeUncited(this.ptr, addHeapObject(uncited)); | ||
} | ||
/** | ||
* Gets a list of locales in use by the references currently loaded. | ||
@@ -295,4 +325,27 @@ * | ||
/** | ||
* Previews a formatted citation cluster, in a particular position. | ||
* | ||
* - `cites`: The cites to go in the cluster | ||
* - `positions`: An array of `ClusterPosition`s as in set_cluster_order, but with a single | ||
* cluster's id set to zero. The cluster with id=0 is the position to preview the cite. It | ||
* can replace another cluster, or be inserted before/after/between existing clusters, in | ||
* any location you can think of. | ||
* @param {any[]} cites | ||
* @param {any[]} positions | ||
* @param {string} format | ||
* @returns {any} | ||
*/ | ||
previewCitationCluster(cites, positions, format) { | ||
var ptr0 = passArrayJsValueToWasm0(cites, wasm.__wbindgen_malloc); | ||
var len0 = WASM_VECTOR_LEN; | ||
var ptr1 = passArrayJsValueToWasm0(positions, wasm.__wbindgen_malloc); | ||
var len1 = WASM_VECTOR_LEN; | ||
var ptr2 = passStringToWasm0(format, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); | ||
var len2 = WASM_VECTOR_LEN; | ||
var ret = wasm.driver_previewCitationCluster(this.ptr, ptr0, len0, ptr1, len1, ptr2, len2); | ||
return takeObject(ret); | ||
} | ||
/** | ||
* @returns {any} | ||
*/ | ||
makeBibliography() { | ||
@@ -360,6 +413,6 @@ var ret = wasm.driver_makeBibliography(this.ptr); | ||
* May error without having set_cluster_ids, but with some set_cluster_note_number-s executed. | ||
* @param {any[]} pieces | ||
* @param {any[]} positions | ||
*/ | ||
setClusterOrder(pieces) { | ||
var ptr0 = passArrayJsValueToWasm0(pieces, wasm.__wbindgen_malloc); | ||
setClusterOrder(positions) { | ||
var ptr0 = passArrayJsValueToWasm0(positions, wasm.__wbindgen_malloc); | ||
var len0 = WASM_VECTOR_LEN; | ||
@@ -376,3 +429,3 @@ wasm.driver_setClusterOrder(this.ptr, ptr0, len0); | ||
* * returns an `UpdateSummary` | ||
* @returns {any} | ||
* @returns {UpdateSummary} | ||
*/ | ||
@@ -440,17 +493,2 @@ batchedUpdates() { | ||
imports.wbg = {}; | ||
imports.wbg.__wbg_debug_4885c3f7d6f044a3 = function(arg0, arg1) { | ||
console.debug(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
imports.wbg.__wbg_log_bee3ea1a89f334d8 = function(arg0, arg1) { | ||
console.log(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
imports.wbg.__wbg_info_0547ff9513f2019b = function(arg0, arg1) { | ||
console.info(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
imports.wbg.__wbg_warn_a478dea6e6e05394 = function(arg0, arg1) { | ||
console.warn(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
imports.wbg.__wbg_error_72e88ba6901b6eee = function(arg0, arg1) { | ||
console.error(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
imports.wbg.__wbindgen_object_drop_ref = function(arg0) { | ||
@@ -478,2 +516,21 @@ takeObject(arg0); | ||
}; | ||
imports.wbg.__wbg_debug_4885c3f7d6f044a3 = function(arg0, arg1) { | ||
console.debug(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
imports.wbg.__wbg_log_bee3ea1a89f334d8 = function(arg0, arg1) { | ||
console.log(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
imports.wbg.__wbg_info_0547ff9513f2019b = function(arg0, arg1) { | ||
console.info(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
imports.wbg.__wbg_warn_a478dea6e6e05394 = function(arg0, arg1) { | ||
console.warn(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
imports.wbg.__wbg_error_72e88ba6901b6eee = function(arg0, arg1) { | ||
console.error(getStringFromWasm0(arg0, arg1)); | ||
}; | ||
imports.wbg.__wbindgen_json_parse = function(arg0, arg1) { | ||
var ret = JSON.parse(getStringFromWasm0(arg0, arg1)); | ||
return addHeapObject(ret); | ||
}; | ||
imports.wbg.__wbindgen_cb_drop = function(arg0) { | ||
@@ -488,6 +545,2 @@ const obj = takeObject(arg0).original; | ||
}; | ||
imports.wbg.__wbindgen_json_parse = function(arg0, arg1) { | ||
var ret = JSON.parse(getStringFromWasm0(arg0, arg1)); | ||
return addHeapObject(ret); | ||
}; | ||
imports.wbg.__wbg_new_59cb74e423758ede = function() { | ||
@@ -526,3 +579,3 @@ var ret = new Error(); | ||
try { | ||
return __wbg_adapter_59(a, state0.b, arg0, arg1); | ||
return __wbg_adapter_63(a, state0.b, arg0, arg1); | ||
} finally { | ||
@@ -564,4 +617,4 @@ state0.a = a; | ||
}; | ||
imports.wbg.__wbindgen_closure_wrapper1070 = function(arg0, arg1, arg2) { | ||
var ret = makeMutClosure(arg0, arg1, 190, __wbg_adapter_18); | ||
imports.wbg.__wbindgen_closure_wrapper839 = function(arg0, arg1, arg2) { | ||
var ret = makeMutClosure(arg0, arg1, 197, __wbg_adapter_18); | ||
return addHeapObject(ret); | ||
@@ -568,0 +621,0 @@ }; |
@@ -7,3 +7,3 @@ { | ||
"description": "citeproc-rs, compiled to WebAssembly", | ||
"version": "0.0.0-canary-289a710", | ||
"version": "0.0.0-canary-6024e27", | ||
"license": "MPL-2.0", | ||
@@ -10,0 +10,0 @@ "repository": { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
2519
11763153