@teipublisher/pb-components 1.24.19 → 1.27.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.
@@ -151,10 +151,6 @@
151
151
  "name": "data",
152
152
  "type": "object"
153
153
  },
154
- {
155
- "name": "collection",
156
- "type": "string"
157
- },
158
154
  {
159
155
  "name": "page",
160
156
  "type": "number"
@@ -163,6 +159,11 @@
163
159
  "name": "perPage",
164
160
  "type": "number"
165
161
  },
162
+ {
163
+ "name": "collection",
164
+ "type": "string",
165
+ "default": "\"default\""
166
+ },
166
167
  {
167
168
  "name": "subscribe",
168
169
  "description": "The name of the channel to subscribe to. Only events on a channel corresponding\nto this property are listened to.",
@@ -206,11 +207,6 @@
206
207
  "attribute": "data",
207
208
  "type": "object"
208
209
  },
209
- {
210
- "name": "collection",
211
- "attribute": "collection",
212
- "type": "string"
213
- },
214
210
  {
215
211
  "name": "page",
216
212
  "attribute": "page",
@@ -221,6 +217,12 @@
221
217
  "attribute": "perPage",
222
218
  "type": "number"
223
219
  },
220
+ {
221
+ "name": "collection",
222
+ "attribute": "collection",
223
+ "type": "string",
224
+ "default": "\"default\""
225
+ },
224
226
  {
225
227
  "name": "subscribe",
226
228
  "attribute": "subscribe",
@@ -290,6 +292,32 @@
290
292
  "name": "pagination",
291
293
  "description": "pagination area"
292
294
  }
295
+ ],
296
+ "cssParts": [
297
+ {
298
+ "name": "parent-link",
299
+ "description": "Link to parent collection"
300
+ },
301
+ {
302
+ "name": "collection-title",
303
+ "description": "Collection title"
304
+ },
305
+ {
306
+ "name": "title",
307
+ "description": "Member title"
308
+ },
309
+ {
310
+ "name": "author",
311
+ "description": "Author"
312
+ },
313
+ {
314
+ "name": "license",
315
+ "description": "License information"
316
+ },
317
+ {
318
+ "name": "link",
319
+ "description": "Links"
320
+ }
293
321
  ]
294
322
  },
295
323
  {
@@ -8895,6 +8923,190 @@
8895
8923
  }
8896
8924
  ]
8897
8925
  },
8926
+ {
8927
+ "name": "pb-table-column",
8928
+ "path": "./src/pb-table-column.js",
8929
+ "description": "Defines a column within `pb-table-grid`.",
8930
+ "attributes": [
8931
+ {
8932
+ "name": "label",
8933
+ "description": "Column heading to display",
8934
+ "type": "string",
8935
+ "default": "\"no-label\""
8936
+ },
8937
+ {
8938
+ "name": "property",
8939
+ "description": "Name of the JSON property containing the data",
8940
+ "type": "string"
8941
+ },
8942
+ {
8943
+ "name": "sort",
8944
+ "description": "Should the column support sorting?",
8945
+ "type": "boolean",
8946
+ "default": "false"
8947
+ },
8948
+ {
8949
+ "name": "width",
8950
+ "description": "Optional fixed width of the column (e.g. '200px' or '30%')",
8951
+ "type": "string"
8952
+ }
8953
+ ],
8954
+ "properties": [
8955
+ {
8956
+ "name": "label",
8957
+ "attribute": "label",
8958
+ "description": "Column heading to display",
8959
+ "type": "string",
8960
+ "default": "\"no-label\""
8961
+ },
8962
+ {
8963
+ "name": "property",
8964
+ "attribute": "property",
8965
+ "description": "Name of the JSON property containing the data",
8966
+ "type": "string"
8967
+ },
8968
+ {
8969
+ "name": "sort",
8970
+ "attribute": "sort",
8971
+ "description": "Should the column support sorting?",
8972
+ "type": "boolean",
8973
+ "default": "false"
8974
+ },
8975
+ {
8976
+ "name": "width",
8977
+ "attribute": "width",
8978
+ "description": "Optional fixed width of the column (e.g. '200px' or '30%')",
8979
+ "type": "string"
8980
+ }
8981
+ ]
8982
+ },
8983
+ {
8984
+ "name": "pb-table-grid",
8985
+ "path": "./src/pb-table-grid.js",
8986
+ "description": "A table grid based on [gridjs](https://gridjs.io/), which loads its data from a server endpoint\nspecified in `source`. If `source` is a relative URI, it will be resolved relative to the\nTEI Publisher endpoint.\n\nThe JSON data returned by the endpoint should be an object with two properties:\n\n* `count`: the overall number of rows available on the server\n* `results`: an array containing each record as an object\n\nThe parameters send to the server are as follows:\n\n\nParameter | Description\n---------|----------\nlimit | number of records to return for each page\nstart | start offset from which to return records\norder | the id of the column to sort by\ndir | sort direction: either 'asc' or 'desc'\nsearch | an optional search string entered by the user\n\nTable columns are configured via nested `<pb-table-column>` elements:\n\n```html\n<pb-table-column label=\"Name\" property=\"name\" sort width=\"33%\"></pb-table-column>\n<pb-table-column label=\"Born\" property=\"birth\"></pb-table-column>\n<pb-table-column label=\"Died\" property=\"death\"></pb-table-column>\n```",
8987
+ "attributes": [
8988
+ {
8989
+ "name": "source",
8990
+ "description": "URI of the server-side endpoint to retrieve data from.\nRelative URIs are resolved relative to the configured TEI Publisher endpoint.",
8991
+ "type": "string"
8992
+ },
8993
+ {
8994
+ "name": "css-path",
8995
+ "description": "Path to the gridjs theme CSS files.",
8996
+ "type": "string",
8997
+ "default": "\"../css/gridjs\""
8998
+ },
8999
+ {
9000
+ "name": "resizable",
9001
+ "description": "If specified, columns (without a fixed width) will be resizable.",
9002
+ "type": "boolean",
9003
+ "default": "false"
9004
+ },
9005
+ {
9006
+ "name": "search",
9007
+ "description": "If specified, enable server-side search.",
9008
+ "type": "boolean",
9009
+ "default": "false"
9010
+ },
9011
+ {
9012
+ "name": "subscribe",
9013
+ "description": "The name of the channel to subscribe to. Only events on a channel corresponding\nto this property are listened to.",
9014
+ "type": "string"
9015
+ },
9016
+ {
9017
+ "name": "subscribe-config",
9018
+ "description": "Configuration object to define a channel/event mapping. Every property\nin the object is interpreted as the name of a channel and its value should\nbe an array of event names to listen to.",
9019
+ "type": "object"
9020
+ },
9021
+ {
9022
+ "name": "emit",
9023
+ "description": "The name of the channel to send events to.",
9024
+ "type": "string"
9025
+ },
9026
+ {
9027
+ "name": "emit-config",
9028
+ "description": "Configuration object to define a channel/event mapping. Every property\nin the object is interpreted as the name of a channel and its value should\nbe an array of event names to be dispatched.",
9029
+ "type": "object"
9030
+ },
9031
+ {
9032
+ "name": "wait-for",
9033
+ "description": "A selector pointing to other components this component depends on.\nWhen method `wait` is called, it will wait until all referenced\ncomponents signal with a `pb-ready` event that they are ready and listening\nto events.",
9034
+ "type": "string"
9035
+ },
9036
+ {
9037
+ "name": "disabled",
9038
+ "description": "Common property to disable the functionality associated with a component.\n`pb-highlight` and `pb-popover` react to this.",
9039
+ "type": "boolean",
9040
+ "default": "false"
9041
+ }
9042
+ ],
9043
+ "properties": [
9044
+ {
9045
+ "name": "source",
9046
+ "attribute": "source",
9047
+ "description": "URI of the server-side endpoint to retrieve data from.\nRelative URIs are resolved relative to the configured TEI Publisher endpoint.",
9048
+ "type": "string"
9049
+ },
9050
+ {
9051
+ "name": "cssPath",
9052
+ "attribute": "css-path",
9053
+ "description": "Path to the gridjs theme CSS files.",
9054
+ "type": "string",
9055
+ "default": "\"../css/gridjs\""
9056
+ },
9057
+ {
9058
+ "name": "resizable",
9059
+ "attribute": "resizable",
9060
+ "description": "If specified, columns (without a fixed width) will be resizable.",
9061
+ "type": "boolean",
9062
+ "default": "false"
9063
+ },
9064
+ {
9065
+ "name": "search",
9066
+ "attribute": "search",
9067
+ "description": "If specified, enable server-side search.",
9068
+ "type": "boolean",
9069
+ "default": "false"
9070
+ },
9071
+ {
9072
+ "name": "subscribe",
9073
+ "attribute": "subscribe",
9074
+ "description": "The name of the channel to subscribe to. Only events on a channel corresponding\nto this property are listened to.",
9075
+ "type": "string"
9076
+ },
9077
+ {
9078
+ "name": "subscribeConfig",
9079
+ "attribute": "subscribe-config",
9080
+ "description": "Configuration object to define a channel/event mapping. Every property\nin the object is interpreted as the name of a channel and its value should\nbe an array of event names to listen to.",
9081
+ "type": "object"
9082
+ },
9083
+ {
9084
+ "name": "emit",
9085
+ "attribute": "emit",
9086
+ "description": "The name of the channel to send events to.",
9087
+ "type": "string"
9088
+ },
9089
+ {
9090
+ "name": "emitConfig",
9091
+ "attribute": "emit-config",
9092
+ "description": "Configuration object to define a channel/event mapping. Every property\nin the object is interpreted as the name of a channel and its value should\nbe an array of event names to be dispatched.",
9093
+ "type": "object"
9094
+ },
9095
+ {
9096
+ "name": "waitFor",
9097
+ "attribute": "wait-for",
9098
+ "description": "A selector pointing to other components this component depends on.\nWhen method `wait` is called, it will wait until all referenced\ncomponents signal with a `pb-ready` event that they are ready and listening\nto events.",
9099
+ "type": "string"
9100
+ },
9101
+ {
9102
+ "name": "disabled",
9103
+ "attribute": "disabled",
9104
+ "description": "Common property to disable the functionality associated with a component.\n`pb-highlight` and `pb-popover` react to this.",
9105
+ "type": "boolean",
9106
+ "default": "false"
9107
+ }
9108
+ ]
9109
+ },
8898
9110
  {
8899
9111
  "name": "pb-tabs",
8900
9112
  "path": "./src/pb-tabs.js",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@teipublisher/pb-components",
3
- "version": "1.24.19",
3
+ "version": "1.27.0",
4
4
  "description": "Collection of webcomponents underlying TEI Publisher",
5
5
  "repository": "https://github.com/eeditiones/tei-publisher-components.git",
6
6
  "main": "index.html",
@@ -68,6 +68,7 @@
68
68
  "@webcomponents/webcomponentsjs": "latest",
69
69
  "animejs": "^3.2.0",
70
70
  "codemirror": "^5.58.1",
71
+ "gridjs": "^5.0.2",
71
72
  "hotkeys-js": "^3.8.1",
72
73
  "i18next": "19.8.1",
73
74
  "i18next-browser-languagedetector": "^6.0.1",
package/pb-elements.json CHANGED
@@ -151,10 +151,6 @@
151
151
  "name": "data",
152
152
  "type": "object"
153
153
  },
154
- {
155
- "name": "collection",
156
- "type": "string"
157
- },
158
154
  {
159
155
  "name": "page",
160
156
  "type": "number"
@@ -163,6 +159,11 @@
163
159
  "name": "perPage",
164
160
  "type": "number"
165
161
  },
162
+ {
163
+ "name": "collection",
164
+ "type": "string",
165
+ "default": "\"default\""
166
+ },
166
167
  {
167
168
  "name": "subscribe",
168
169
  "description": "The name of the channel to subscribe to. Only events on a channel corresponding\nto this property are listened to.",
@@ -206,11 +207,6 @@
206
207
  "attribute": "data",
207
208
  "type": "object"
208
209
  },
209
- {
210
- "name": "collection",
211
- "attribute": "collection",
212
- "type": "string"
213
- },
214
210
  {
215
211
  "name": "page",
216
212
  "attribute": "page",
@@ -221,6 +217,12 @@
221
217
  "attribute": "perPage",
222
218
  "type": "number"
223
219
  },
220
+ {
221
+ "name": "collection",
222
+ "attribute": "collection",
223
+ "type": "string",
224
+ "default": "\"default\""
225
+ },
224
226
  {
225
227
  "name": "subscribe",
226
228
  "attribute": "subscribe",
@@ -290,6 +292,32 @@
290
292
  "name": "pagination",
291
293
  "description": "pagination area"
292
294
  }
295
+ ],
296
+ "cssParts": [
297
+ {
298
+ "name": "parent-link",
299
+ "description": "Link to parent collection"
300
+ },
301
+ {
302
+ "name": "collection-title",
303
+ "description": "Collection title"
304
+ },
305
+ {
306
+ "name": "title",
307
+ "description": "Member title"
308
+ },
309
+ {
310
+ "name": "author",
311
+ "description": "Author"
312
+ },
313
+ {
314
+ "name": "license",
315
+ "description": "License information"
316
+ },
317
+ {
318
+ "name": "link",
319
+ "description": "Links"
320
+ }
293
321
  ]
294
322
  },
295
323
  {
@@ -8895,6 +8923,190 @@
8895
8923
  }
8896
8924
  ]
8897
8925
  },
8926
+ {
8927
+ "name": "pb-table-column",
8928
+ "path": "./src/pb-table-column.js",
8929
+ "description": "Defines a column within `pb-table-grid`.",
8930
+ "attributes": [
8931
+ {
8932
+ "name": "label",
8933
+ "description": "Column heading to display",
8934
+ "type": "string",
8935
+ "default": "\"no-label\""
8936
+ },
8937
+ {
8938
+ "name": "property",
8939
+ "description": "Name of the JSON property containing the data",
8940
+ "type": "string"
8941
+ },
8942
+ {
8943
+ "name": "sort",
8944
+ "description": "Should the column support sorting?",
8945
+ "type": "boolean",
8946
+ "default": "false"
8947
+ },
8948
+ {
8949
+ "name": "width",
8950
+ "description": "Optional fixed width of the column (e.g. '200px' or '30%')",
8951
+ "type": "string"
8952
+ }
8953
+ ],
8954
+ "properties": [
8955
+ {
8956
+ "name": "label",
8957
+ "attribute": "label",
8958
+ "description": "Column heading to display",
8959
+ "type": "string",
8960
+ "default": "\"no-label\""
8961
+ },
8962
+ {
8963
+ "name": "property",
8964
+ "attribute": "property",
8965
+ "description": "Name of the JSON property containing the data",
8966
+ "type": "string"
8967
+ },
8968
+ {
8969
+ "name": "sort",
8970
+ "attribute": "sort",
8971
+ "description": "Should the column support sorting?",
8972
+ "type": "boolean",
8973
+ "default": "false"
8974
+ },
8975
+ {
8976
+ "name": "width",
8977
+ "attribute": "width",
8978
+ "description": "Optional fixed width of the column (e.g. '200px' or '30%')",
8979
+ "type": "string"
8980
+ }
8981
+ ]
8982
+ },
8983
+ {
8984
+ "name": "pb-table-grid",
8985
+ "path": "./src/pb-table-grid.js",
8986
+ "description": "A table grid based on [gridjs](https://gridjs.io/), which loads its data from a server endpoint\nspecified in `source`. If `source` is a relative URI, it will be resolved relative to the\nTEI Publisher endpoint.\n\nThe JSON data returned by the endpoint should be an object with two properties:\n\n* `count`: the overall number of rows available on the server\n* `results`: an array containing each record as an object\n\nThe parameters send to the server are as follows:\n\n\nParameter | Description\n---------|----------\nlimit | number of records to return for each page\nstart | start offset from which to return records\norder | the id of the column to sort by\ndir | sort direction: either 'asc' or 'desc'\nsearch | an optional search string entered by the user\n\nTable columns are configured via nested `<pb-table-column>` elements:\n\n```html\n<pb-table-column label=\"Name\" property=\"name\" sort width=\"33%\"></pb-table-column>\n<pb-table-column label=\"Born\" property=\"birth\"></pb-table-column>\n<pb-table-column label=\"Died\" property=\"death\"></pb-table-column>\n```",
8987
+ "attributes": [
8988
+ {
8989
+ "name": "source",
8990
+ "description": "URI of the server-side endpoint to retrieve data from.\nRelative URIs are resolved relative to the configured TEI Publisher endpoint.",
8991
+ "type": "string"
8992
+ },
8993
+ {
8994
+ "name": "css-path",
8995
+ "description": "Path to the gridjs theme CSS files.",
8996
+ "type": "string",
8997
+ "default": "\"../css/gridjs\""
8998
+ },
8999
+ {
9000
+ "name": "resizable",
9001
+ "description": "If specified, columns (without a fixed width) will be resizable.",
9002
+ "type": "boolean",
9003
+ "default": "false"
9004
+ },
9005
+ {
9006
+ "name": "search",
9007
+ "description": "If specified, enable server-side search.",
9008
+ "type": "boolean",
9009
+ "default": "false"
9010
+ },
9011
+ {
9012
+ "name": "subscribe",
9013
+ "description": "The name of the channel to subscribe to. Only events on a channel corresponding\nto this property are listened to.",
9014
+ "type": "string"
9015
+ },
9016
+ {
9017
+ "name": "subscribe-config",
9018
+ "description": "Configuration object to define a channel/event mapping. Every property\nin the object is interpreted as the name of a channel and its value should\nbe an array of event names to listen to.",
9019
+ "type": "object"
9020
+ },
9021
+ {
9022
+ "name": "emit",
9023
+ "description": "The name of the channel to send events to.",
9024
+ "type": "string"
9025
+ },
9026
+ {
9027
+ "name": "emit-config",
9028
+ "description": "Configuration object to define a channel/event mapping. Every property\nin the object is interpreted as the name of a channel and its value should\nbe an array of event names to be dispatched.",
9029
+ "type": "object"
9030
+ },
9031
+ {
9032
+ "name": "wait-for",
9033
+ "description": "A selector pointing to other components this component depends on.\nWhen method `wait` is called, it will wait until all referenced\ncomponents signal with a `pb-ready` event that they are ready and listening\nto events.",
9034
+ "type": "string"
9035
+ },
9036
+ {
9037
+ "name": "disabled",
9038
+ "description": "Common property to disable the functionality associated with a component.\n`pb-highlight` and `pb-popover` react to this.",
9039
+ "type": "boolean",
9040
+ "default": "false"
9041
+ }
9042
+ ],
9043
+ "properties": [
9044
+ {
9045
+ "name": "source",
9046
+ "attribute": "source",
9047
+ "description": "URI of the server-side endpoint to retrieve data from.\nRelative URIs are resolved relative to the configured TEI Publisher endpoint.",
9048
+ "type": "string"
9049
+ },
9050
+ {
9051
+ "name": "cssPath",
9052
+ "attribute": "css-path",
9053
+ "description": "Path to the gridjs theme CSS files.",
9054
+ "type": "string",
9055
+ "default": "\"../css/gridjs\""
9056
+ },
9057
+ {
9058
+ "name": "resizable",
9059
+ "attribute": "resizable",
9060
+ "description": "If specified, columns (without a fixed width) will be resizable.",
9061
+ "type": "boolean",
9062
+ "default": "false"
9063
+ },
9064
+ {
9065
+ "name": "search",
9066
+ "attribute": "search",
9067
+ "description": "If specified, enable server-side search.",
9068
+ "type": "boolean",
9069
+ "default": "false"
9070
+ },
9071
+ {
9072
+ "name": "subscribe",
9073
+ "attribute": "subscribe",
9074
+ "description": "The name of the channel to subscribe to. Only events on a channel corresponding\nto this property are listened to.",
9075
+ "type": "string"
9076
+ },
9077
+ {
9078
+ "name": "subscribeConfig",
9079
+ "attribute": "subscribe-config",
9080
+ "description": "Configuration object to define a channel/event mapping. Every property\nin the object is interpreted as the name of a channel and its value should\nbe an array of event names to listen to.",
9081
+ "type": "object"
9082
+ },
9083
+ {
9084
+ "name": "emit",
9085
+ "attribute": "emit",
9086
+ "description": "The name of the channel to send events to.",
9087
+ "type": "string"
9088
+ },
9089
+ {
9090
+ "name": "emitConfig",
9091
+ "attribute": "emit-config",
9092
+ "description": "Configuration object to define a channel/event mapping. Every property\nin the object is interpreted as the name of a channel and its value should\nbe an array of event names to be dispatched.",
9093
+ "type": "object"
9094
+ },
9095
+ {
9096
+ "name": "waitFor",
9097
+ "attribute": "wait-for",
9098
+ "description": "A selector pointing to other components this component depends on.\nWhen method `wait` is called, it will wait until all referenced\ncomponents signal with a `pb-ready` event that they are ready and listening\nto events.",
9099
+ "type": "string"
9100
+ },
9101
+ {
9102
+ "name": "disabled",
9103
+ "attribute": "disabled",
9104
+ "description": "Common property to disable the functionality associated with a component.\n`pb-highlight` and `pb-popover` react to this.",
9105
+ "type": "boolean",
9106
+ "default": "false"
9107
+ }
9108
+ ]
9109
+ },
8898
9110
  {
8899
9111
  "name": "pb-tabs",
8900
9112
  "path": "./src/pb-tabs.js",
@@ -3,6 +3,7 @@ import { GeoNames } from './geonames.js';
3
3
  import { Airtable } from './airtable.js';
4
4
  import { GND } from './gnd.js';
5
5
  import { KBGA } from './kbga.js';
6
+ import { GF } from './gf.js';
6
7
  import { Custom } from './custom.js';
7
8
 
8
9
  export function createConnectors(endpoint, root) {
@@ -23,6 +24,9 @@ export function createConnectors(endpoint, root) {
23
24
  case 'KBGA':
24
25
  instance = new KBGA(configElem);
25
26
  break;
27
+ case 'GF':
28
+ instance = new GF(configElem);
29
+ break;
26
30
  case 'Custom':
27
31
  instance = new Custom(endpoint, configElem);
28
32
  break;