sanity-plugin-taxonomy-manager 2.2.2 → 2.3.0

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/README.md CHANGED
@@ -152,32 +152,6 @@ export const structure = (S) =>
152
152
  ```
153
153
  1. Tag resources with concepts and then integrate into search indexing, filtering, navigation, and semantic web services.
154
154
 
155
- ### Semantic Relationships
156
-
157
- The concept editor includes filtering and validation to help you create consistent SKOS vocabularies:
158
-
159
- **SKOS Broader and Related Concepts**
160
- Adding the same concept to Broader and Related fields is not allowed, and the editor validates disjunction of Related concepts with Broader Transitive up to five hierarchical levels in either direction.
161
-
162
- **Preferred, Alternative, and Hidden Labels**
163
- Preferred Labels are validated for uniqueness across concepts, and Preferred, Alternative, and Hidden are validated to prevent duplicates and overlap.
164
-
165
- **Scope Notes, Definition, and Examples**
166
- Standard optional SKOS documentation fields are included by default.
167
-
168
- **Support for Single or Multiple Taxonomy Schemes (or none)**
169
- For cases where more than one taxonomy is needed, multiple [SKOS Concept Schemes](https://www.w3.org/TR/skos-reference/#schemes) are supported. Schemes can be used to configure filtered views of concepts in Sanity Structure Builder and can be used to scope values for reference arrays.
170
-
171
- <!-- Concept Scheme views show a hierarchical list (Tree View) of the concepts included in a given scheme. This list allows for easy visualization of Top Concepts, polyhierarchy (concepts that appear in more than one place in the hierarchy), and "Orphan" terms (top level concepts not denoted as a "Top Concept"). -->
172
-
173
- ## SKOS Overview
174
-
175
- > The [Simple Knowledge Organization System (SKOS)](https://www.w3.org/TR/skos-reference/) is a common data model for sharing and linking knowledge organization systems via the Web.
176
- >
177
- > Many knowledge organization systems, such as thesauri, taxonomies, classification schemes and subject heading systems, share a similar structure, and are used in similar applications. SKOS captures much of this similarity and makes it explicit, to enable data and technology sharing across diverse applications.
178
- >
179
- > The SKOS data model provides a standard, low-cost migration path for porting existing knowledge organization systems to the Semantic Web. SKOS also provides a lightweight, intuitive language for developing and sharing new knowledge organization systems. It may be used on its own, or in combination with formal knowledge representation languages such as the Web Ontology language (OWL).
180
-
181
155
  ## License
182
156
 
183
157
  MIT © Andy Fitzgerald
package/lib/index.d.ts CHANGED
@@ -2,41 +2,47 @@
2
2
 
3
3
  import {Plugin as Plugin_2} from 'sanity'
4
4
 
5
- export declare function branchFilter(options: Options_2): branchFilterResult
5
+ export declare function branchFilter(options: BranchOptions): BranchFilterResult
6
6
 
7
- /**
8
- * Pluggable Function for Filtering to a Top Concept Branch within a SKOS Concept Scheme
9
- */
10
- declare type branchFilterResult = {
7
+ declare type BranchFilterResult = {
11
8
  filter: string
12
- params: {
13
- schemeId: string
14
- branchId: string
15
- }
9
+ params: BranchOptions
16
10
  }
17
11
 
18
- declare type Options = {
12
+ /**
13
+ * Pluggable Function for Filtering to a Top Concept Branch within a SKOS Concept Scheme
14
+ */
15
+ declare type BranchOptions = {
19
16
  schemeId: string
17
+ branchId: string
20
18
  }
21
19
 
22
- declare type Options_2 = {
23
- schemeId: string
24
- branchId: string
20
+ declare interface Options {
21
+ baseUri?: string
25
22
  }
26
23
 
27
- export declare function schemeFilter(options: Options): SchemeFilterResult
24
+ export declare function schemeFilter(options: SchemeOptions): SchemeFilterResult
25
+
26
+ declare type SchemeFilterResult = {
27
+ filter: string
28
+ params: SchemeOptions
29
+ }
28
30
 
29
31
  /**
30
32
  * Pluggable Function for Filtering to a Single SKOS Concept Scheme
31
33
  */
32
- declare type SchemeFilterResult = {
33
- filter: string
34
- params: {
35
- schemeId: string
36
- }
34
+ declare type SchemeOptions = {
35
+ schemeId: string
37
36
  }
38
37
 
39
- export declare const taxonomyManager: Plugin_2<any>
38
+ /**
39
+ * Defines a Sanity plugin for managing taxonomies.
40
+ * @param options - Optional configuration options for the plugin.
41
+ * @param options.baseUri - The base URI to use for SKOS concepts and concept schemes.
42
+ * baseURI should follow an IANA http/s scheme and should terminate with either a / or #.
43
+ * @returns A Sanity plugin object.
44
+ */
45
+ export declare const taxonomyManager: Plugin_2<Options | undefined>
40
46
 
41
47
  export declare const TreeView: ({document}: {document: any}) => JSX.Element
42
48