@neverblink/ohi 0.18.1 → 0.18.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -1,5 +1,7 @@
1
1
  export { CatalogClient, CatalogException } from "./catalog.js";
2
2
  export { decodePublication } from "./publication.js";
3
+ export { ohiReleasePage } from "./pages.js";
4
+ export type { Release } from "./pages.js";
3
5
  export { decodeLock, encodeLock, LockException } from "./lock.js";
4
6
  export type { Lock, ArtifactSelection, LockedFile } from "./generated_lock.js";
5
7
  export type * from "./generated_lock_error.js";
package/dist/index.js CHANGED
@@ -1,3 +1,4 @@
1
1
  export { CatalogClient, CatalogException } from "./catalog.js";
2
2
  export { decodePublication } from "./publication.js";
3
+ export { ohiReleasePage } from "./pages.js";
3
4
  export { decodeLock, encodeLock, LockException } from "./lock.js";
@@ -0,0 +1,8 @@
1
+ /** Fields that identify one release, as found on a `Publication` or a `SearchHit`. */
2
+ export type Release = {
3
+ namespace: string;
4
+ name: string;
5
+ version: string;
6
+ };
7
+ /** Page of one release on ohi.dev, such as https://ohi.dev/o/w3c/sosa@2017. */
8
+ export declare function ohiReleasePage(release: Release): string;
package/dist/pages.js ADDED
@@ -0,0 +1,4 @@
1
+ /** Page of one release on ohi.dev, such as https://ohi.dev/o/w3c/sosa@2017. */
2
+ export function ohiReleasePage(release) {
3
+ return `https://ohi.dev/o/${encodeURIComponent(release.namespace)}/${encodeURIComponent(release.name)}@${encodeURIComponent(release.version)}`;
4
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@neverblink/ohi",
3
- "version": "0.18.1",
3
+ "version": "0.18.2",
4
4
  "description": "Search ontologies on ohi.dev, inspect their metadata and download their files.",
5
5
  "license": "Apache-2.0",
6
6
  "homepage": "https://ohi.dev/docs/reference/sdks/",