@beinformed/ui 1.50.0 → 1.50.1
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/CHANGELOG.md +7 -0
- package/esm/models/content/ContentIndexModel.js +9 -4
- package/esm/models/content/ContentIndexModel.js.map +1 -1
- package/lib/models/content/ContentIndexModel.js +9 -4
- package/lib/models/content/ContentIndexModel.js.flow +7 -6
- package/lib/models/content/ContentIndexModel.js.map +1 -1
- package/package.json +1 -1
- package/src/models/content/ContentIndexModel.js +7 -6
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [commit-and-tag-version](https://github.com/absolute-version/commit-and-tag-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
## [1.50.1](https://git.beinformed.com/public/nl.beinformed.bi.layout.lib.ui/compare/v1.50.0...v1.50.1) (2024-07-08)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
* **content:** improve indication if filters on content index are active ([29c9fec](https://git.beinformed.com/public/nl.beinformed.bi.layout.lib.ui/commit/29c9fec3ed0c8663b5c3d6c95b0888fece168003))
|
|
11
|
+
|
|
5
12
|
## [1.50.0](https://git.beinformed.com/public/nl.beinformed.bi.layout.lib.ui/compare/v1.49.6...v1.50.0) (2024-07-08)
|
|
6
13
|
|
|
7
14
|
|
|
@@ -107,11 +107,16 @@ export default class ContentIndexModel extends ResourceModel {
|
|
|
107
107
|
return filterAttribute instanceof ChoiceAttributeModel && filterAttribute.options.length > 0;
|
|
108
108
|
}
|
|
109
109
|
|
|
110
|
+
/**
|
|
111
|
+
*/
|
|
112
|
+
hasFiltersSet() {
|
|
113
|
+
return this.filterCollection.some(filter => filter.isActive());
|
|
114
|
+
}
|
|
115
|
+
|
|
110
116
|
/**
|
|
111
117
|
*/
|
|
112
118
|
hasNoFiltersSet() {
|
|
113
|
-
|
|
114
|
-
return this.items.isEmpty && _filterInstanceProperty(_context2 = this.filterCollection).call(_context2, filter => filter.attribute?.inputvalue !== "").length === 0;
|
|
119
|
+
return !this.hasFiltersSet();
|
|
115
120
|
}
|
|
116
121
|
|
|
117
122
|
/**
|
|
@@ -120,8 +125,8 @@ export default class ContentIndexModel extends ResourceModel {
|
|
|
120
125
|
const filterAttribute = this.indexfilter?.attribute;
|
|
121
126
|
let firstChar = "#";
|
|
122
127
|
if (filterAttribute instanceof ChoiceAttributeModel) {
|
|
123
|
-
var
|
|
124
|
-
firstChar = _filterInstanceProperty(
|
|
128
|
+
var _context2;
|
|
129
|
+
firstChar = _filterInstanceProperty(_context2 = filterAttribute.options).call(_context2, option => option.code !== "0")[0].code;
|
|
125
130
|
}
|
|
126
131
|
return new Href(this.selfhref.path).addParameter("index", firstChar);
|
|
127
132
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ContentIndexModel.js","names":["ResourceModel","ResourceCollection","FilterCollection","ContentLinkModel","Href","ChoiceAttributeModel","ContentIndexModel","constructor","modularuiResponse","_context","_defineProperty","_filterCollection","_filterInstanceProperty","data","filter","contributions","dynamicschema","_content","collection","_embedded","_mapInstanceProperty","results","call","content","type","modelName","isApplicableModel","resourcetype","getInitialChildModelLinks","items","setChildModels","models","errors","selfhref","href","selflink","filterCollection","forEach","params","param","value","setParameter","name","removeParameter","label","getContribution","indexfilter","getFilterByAttributeKey","hasIndexFilter","filterAttribute","attribute","options","length","
|
|
1
|
+
{"version":3,"file":"ContentIndexModel.js","names":["ResourceModel","ResourceCollection","FilterCollection","ContentLinkModel","Href","ChoiceAttributeModel","ContentIndexModel","constructor","modularuiResponse","_context","_defineProperty","_filterCollection","_filterInstanceProperty","data","filter","contributions","dynamicschema","_content","collection","_embedded","_mapInstanceProperty","results","call","content","type","modelName","isApplicableModel","resourcetype","getInitialChildModelLinks","items","setChildModels","models","errors","selfhref","href","selflink","filterCollection","forEach","params","param","value","setParameter","name","removeParameter","label","getContribution","indexfilter","getFilterByAttributeKey","hasIndexFilter","filterAttribute","attribute","options","length","hasFiltersSet","some","isActive","hasNoFiltersSet","getFirstCharHref","firstChar","_context2","option","code","path","addParameter"],"sources":["../../../src/models/content/ContentIndexModel.js"],"sourcesContent":["// @flow\nimport ResourceModel from \"../base/ResourceModel\";\nimport ResourceCollection from \"../base/ResourceCollection\";\nimport FilterCollection from \"../filters/FilterCollection\";\nimport ContentLinkModel from \"./ContentLinkModel\";\nimport Href from \"../href/Href\";\nimport ChoiceAttributeModel from \"../attributes/ChoiceAttributeModel\";\n\nimport type { FilterType, ModularUIModel } from \"../types\";\nimport type { ModularUIResponse } from \"../../modularui\";\nimport type LinkModel from \"../links/LinkModel\";\nimport type ErrorResponse from \"../error/ErrorResponse\";\n\n/**\n * Get Index of concepts, to filter model catalog\n */\nexport default class ContentIndexModel extends ResourceModel {\n _filterCollection: FilterCollection;\n _content: ResourceCollection<ContentLinkModel>;\n\n /**\n */\n constructor(modularuiResponse: ModularUIResponse) {\n super(modularuiResponse);\n\n this._filterCollection = new FilterCollection(this.data.filter, {\n filter: this.contributions.filter,\n dynamicschema: this.data.dynamicschema,\n });\n\n this._content = new ResourceCollection();\n this._content.collection = this.data._embedded\n ? this.data._embedded.results.map(\n (content) => new ContentLinkModel(content.content),\n )\n : [];\n }\n\n /**\n */\n get type(): string {\n return \"ContentIndex\";\n }\n\n /**\n */\n static get modelName(): string {\n return \"ContentIndexModel\";\n }\n\n /**\n */\n static isApplicableModel(data: ModularUIResponse): boolean {\n return (\n data.contributions.resourcetype &&\n data.contributions.resourcetype === \"ContentSearch\"\n );\n }\n\n /**\n */\n getInitialChildModelLinks(): Array<LinkModel> {\n return this.items.getInitialChildModelLinks();\n }\n\n /**\n */\n setChildModels(models: Array<ModularUIModel>, errors: Array<ErrorResponse>) {\n this.items.setChildModels(models, errors);\n }\n\n /**\n * Getting the self link of this list\n */\n get selfhref(): Href {\n const href = new Href(this.selflink.href);\n\n this.filterCollection.forEach((filter) => {\n filter.params.forEach((param) => {\n if (param.value) {\n href.setParameter(param.name, param.value);\n } else {\n href.removeParameter(param.name);\n }\n });\n });\n\n return href;\n }\n\n /**\n */\n get label(): string {\n return this.getContribution(\"label\");\n }\n\n /**\n * Retrieve filters of conceptindex model\n */\n get filterCollection(): FilterCollection {\n return this._filterCollection;\n }\n\n /**\n * Get index filter\n */\n get indexfilter(): FilterType | null {\n return this._filterCollection.getFilterByAttributeKey(\"index\");\n }\n\n /**\n * Retrieve content collection\n */\n get items(): ResourceCollection<ContentLinkModel> {\n return this._content;\n }\n\n /**\n */\n hasIndexFilter(): boolean {\n const filterAttribute = this.indexfilter?.attribute;\n\n return (\n filterAttribute instanceof ChoiceAttributeModel &&\n filterAttribute.options.length > 0\n );\n }\n\n /**\n */\n hasFiltersSet(): boolean {\n return this.filterCollection.some((filter) => filter.isActive());\n }\n\n /**\n */\n hasNoFiltersSet(): boolean {\n return !this.hasFiltersSet();\n }\n\n /**\n */\n getFirstCharHref(): Href {\n const filterAttribute = this.indexfilter?.attribute;\n\n let firstChar = \"#\";\n if (filterAttribute instanceof ChoiceAttributeModel) {\n firstChar = filterAttribute.options.filter(\n (option) => option.code !== \"0\",\n )[0].code;\n }\n\n return new Href(this.selfhref.path).addParameter(\"index\", firstChar);\n }\n}\n"],"mappings":";;;AACA,OAAOA,aAAa,MAAM,uBAAuB;AACjD,OAAOC,kBAAkB,MAAM,4BAA4B;AAC3D,OAAOC,gBAAgB,MAAM,6BAA6B;AAC1D,OAAOC,gBAAgB,MAAM,oBAAoB;AACjD,OAAOC,IAAI,MAAM,cAAc;AAC/B,OAAOC,oBAAoB,MAAM,oCAAoC;AAOrE;AACA;AACA;AACA,eAAe,MAAMC,iBAAiB,SAASN,aAAa,CAAC;EAI3D;AACF;EACEO,WAAWA,CAACC,iBAAoC,EAAE;IAAA,IAAAC,QAAA;IAChD,KAAK,CAACD,iBAAiB,CAAC;IAACE,eAAA;IAAAA,eAAA;IAEzB,IAAI,CAACC,iBA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,WAAW,EAAEI,SAAS;IAEnD,IAAIQ,SAAS,GAAG,GAAG;IACnB,IAAIT,eAAe,YAAY5C,oBAAoB,EAAE;MAAA,IAAAsD,SAAA;MACnDD,SAAS,GAAG9C,uBAAA,CAAA+C,SAAA,GAAAV,eAAe,CAACE,OAAO,EAAA7B,IAAA,CAAAqC,SAAA,EAChCC,MAAM,IAAKA,MAAM,CAACC,IAAI,KAAK,GAC9B,CAAC,CAAC,CAAC,CAAC,CAACA,IAAI;IACX;IAEA,OAAO,IAAIzD,IAAI,CAAC,IAAI,CAAC6B,QAAQ,CAAC6B,IAAI,CAAC,CAACC,YAAY,CAAC,OAAO,EAAEL,SAAS,CAAC;EACtE;AACF","ignoreList":[]}
|
|
@@ -114,11 +114,16 @@ class ContentIndexModel extends _ResourceModel.default {
|
|
|
114
114
|
return filterAttribute instanceof _ChoiceAttributeModel.default && filterAttribute.options.length > 0;
|
|
115
115
|
}
|
|
116
116
|
|
|
117
|
+
/**
|
|
118
|
+
*/
|
|
119
|
+
hasFiltersSet() {
|
|
120
|
+
return this.filterCollection.some(filter => filter.isActive());
|
|
121
|
+
}
|
|
122
|
+
|
|
117
123
|
/**
|
|
118
124
|
*/
|
|
119
125
|
hasNoFiltersSet() {
|
|
120
|
-
|
|
121
|
-
return this.items.isEmpty && (0, _filter.default)(_context2 = this.filterCollection).call(_context2, filter => filter.attribute?.inputvalue !== "").length === 0;
|
|
126
|
+
return !this.hasFiltersSet();
|
|
122
127
|
}
|
|
123
128
|
|
|
124
129
|
/**
|
|
@@ -127,8 +132,8 @@ class ContentIndexModel extends _ResourceModel.default {
|
|
|
127
132
|
const filterAttribute = this.indexfilter?.attribute;
|
|
128
133
|
let firstChar = "#";
|
|
129
134
|
if (filterAttribute instanceof _ChoiceAttributeModel.default) {
|
|
130
|
-
var
|
|
131
|
-
firstChar = (0, _filter.default)(
|
|
135
|
+
var _context2;
|
|
136
|
+
firstChar = (0, _filter.default)(_context2 = filterAttribute.options).call(_context2, option => option.code !== "0")[0].code;
|
|
132
137
|
}
|
|
133
138
|
return new _Href.default(this.selfhref.path).addParameter("index", firstChar);
|
|
134
139
|
}
|
|
@@ -126,15 +126,16 @@ export default class ContentIndexModel extends ResourceModel {
|
|
|
126
126
|
);
|
|
127
127
|
}
|
|
128
128
|
|
|
129
|
+
/**
|
|
130
|
+
*/
|
|
131
|
+
hasFiltersSet(): boolean {
|
|
132
|
+
return this.filterCollection.some((filter) => filter.isActive());
|
|
133
|
+
}
|
|
134
|
+
|
|
129
135
|
/**
|
|
130
136
|
*/
|
|
131
137
|
hasNoFiltersSet(): boolean {
|
|
132
|
-
return (
|
|
133
|
-
this.items.isEmpty &&
|
|
134
|
-
this.filterCollection.filter(
|
|
135
|
-
(filter) => filter.attribute?.inputvalue !== "",
|
|
136
|
-
).length === 0
|
|
137
|
-
);
|
|
138
|
+
return !this.hasFiltersSet();
|
|
138
139
|
}
|
|
139
140
|
|
|
140
141
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ContentIndexModel.js","names":["_ResourceModel","_interopRequireDefault","require","_ResourceCollection","_FilterCollection","_ContentLinkModel","_Href","_ChoiceAttributeModel","ContentIndexModel","ResourceModel","constructor","modularuiResponse","_context","_defineProperty2","default","_filterCollection","FilterCollection","_filter","data","filter","contributions","dynamicschema","_content","ResourceCollection","collection","_embedded","_map","results","call","content","ContentLinkModel","type","modelName","isApplicableModel","resourcetype","getInitialChildModelLinks","items","setChildModels","models","errors","selfhref","href","Href","selflink","filterCollection","forEach","params","param","value","setParameter","name","removeParameter","label","getContribution","indexfilter","getFilterByAttributeKey","hasIndexFilter","filterAttribute","attribute","ChoiceAttributeModel","options","length","
|
|
1
|
+
{"version":3,"file":"ContentIndexModel.js","names":["_ResourceModel","_interopRequireDefault","require","_ResourceCollection","_FilterCollection","_ContentLinkModel","_Href","_ChoiceAttributeModel","ContentIndexModel","ResourceModel","constructor","modularuiResponse","_context","_defineProperty2","default","_filterCollection","FilterCollection","_filter","data","filter","contributions","dynamicschema","_content","ResourceCollection","collection","_embedded","_map","results","call","content","ContentLinkModel","type","modelName","isApplicableModel","resourcetype","getInitialChildModelLinks","items","setChildModels","models","errors","selfhref","href","Href","selflink","filterCollection","forEach","params","param","value","setParameter","name","removeParameter","label","getContribution","indexfilter","getFilterByAttributeKey","hasIndexFilter","filterAttribute","attribute","ChoiceAttributeModel","options","length","hasFiltersSet","some","isActive","hasNoFiltersSet","getFirstCharHref","firstChar","_context2","option","code","path","addParameter","exports"],"sources":["../../../src/models/content/ContentIndexModel.js"],"sourcesContent":["// @flow\nimport ResourceModel from \"../base/ResourceModel\";\nimport ResourceCollection from \"../base/ResourceCollection\";\nimport FilterCollection from \"../filters/FilterCollection\";\nimport ContentLinkModel from \"./ContentLinkModel\";\nimport Href from \"../href/Href\";\nimport ChoiceAttributeModel from \"../attributes/ChoiceAttributeModel\";\n\nimport type { FilterType, ModularUIModel } from \"../types\";\nimport type { ModularUIResponse } from \"../../modularui\";\nimport type LinkModel from \"../links/LinkModel\";\nimport type ErrorResponse from \"../error/ErrorResponse\";\n\n/**\n * Get Index of concepts, to filter model catalog\n */\nexport default class ContentIndexModel extends ResourceModel {\n _filterCollection: FilterCollection;\n _content: ResourceCollection<ContentLinkModel>;\n\n /**\n */\n constructor(modularuiResponse: ModularUIResponse) {\n super(modularuiResponse);\n\n this._filterCollection = new FilterCollection(this.data.filter, {\n filter: this.contributions.filter,\n dynamicschema: this.data.dynamicschema,\n });\n\n this._content = new ResourceCollection();\n this._content.collection = this.data._embedded\n ? this.data._embedded.results.map(\n (content) => new ContentLinkModel(content.content),\n )\n : [];\n }\n\n /**\n */\n get type(): string {\n return \"ContentIndex\";\n }\n\n /**\n */\n static get modelName(): string {\n return \"ContentIndexModel\";\n }\n\n /**\n */\n static isApplicableModel(data: ModularUIResponse): boolean {\n return (\n data.contributions.resourcetype &&\n data.contributions.resourcetype === \"ContentSearch\"\n );\n }\n\n /**\n */\n getInitialChildModelLinks(): Array<LinkModel> {\n return this.items.getInitialChildModelLinks();\n }\n\n /**\n */\n setChildModels(models: Array<ModularUIModel>, errors: Array<ErrorResponse>) {\n this.items.setChildModels(models, errors);\n }\n\n /**\n * Getting the self link of this list\n */\n get selfhref(): Href {\n const href = new Href(this.selflink.href);\n\n this.filterCollection.forEach((filter) => {\n filter.params.forEach((param) => {\n if (param.value) {\n href.setParameter(param.name, param.value);\n } else {\n href.removeParameter(param.name);\n }\n });\n });\n\n return href;\n }\n\n /**\n */\n get label(): string {\n return this.getContribution(\"label\");\n }\n\n /**\n * Retrieve filters of conceptindex model\n */\n get filterCollection(): FilterCollection {\n return this._filterCollection;\n }\n\n /**\n * Get index filter\n */\n get indexfilter(): FilterType | null {\n return this._filterCollection.getFilterByAttributeKey(\"index\");\n }\n\n /**\n * Retrieve content collection\n */\n get items(): ResourceCollection<ContentLinkModel> {\n return this._content;\n }\n\n /**\n */\n hasIndexFilter(): boolean {\n const filterAttribute = this.indexfilter?.attribute;\n\n return (\n filterAttribute instanceof ChoiceAttributeModel &&\n filterAttribute.options.length > 0\n );\n }\n\n /**\n */\n hasFiltersSet(): boolean {\n return this.filterCollection.some((filter) => filter.isActive());\n }\n\n /**\n */\n hasNoFiltersSet(): boolean {\n return !this.hasFiltersSet();\n }\n\n /**\n */\n getFirstCharHref(): Href {\n const filterAttribute = this.indexfilter?.attribute;\n\n let firstChar = \"#\";\n if (filterAttribute instanceof ChoiceAttributeModel) {\n firstChar = filterAttribute.options.filter(\n (option) => option.code !== \"0\",\n )[0].code;\n }\n\n return new Href(this.selfhref.path).addParameter(\"index\", firstChar);\n }\n}\n"],"mappings":";;;;;;;;;;AACA,IAAAA,cAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,mBAAA,GAAAF,sBAAA,CAAAC,OAAA;AACA,IAAAE,iBAAA,GAAAH,sBAAA,CAAAC,OAAA;AACA,IAAAG,iBAAA,GAAAJ,sBAAA,CAAAC,OAAA;AACA,IAAAI,KAAA,GAAAL,sBAAA,CA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,GAAG,CAAC;EAEtC;;EAEA;AACF;EACEC,aAAaA,CAAA,EAAY;IACvB,OAAO,IAAI,CAAClB,gBAAgB,CAACmB,IAAI,CAAE5C,MAAM,IAAKA,MAAM,CAAC6C,QAAQ,CAAC,CAAC,CAAC;EAClE;;EAEA;AACF;EACEC,eAAeA,CAAA,EAAY;IACzB,OAAO,CAAC,IAAI,CAACH,aAAa,CAAC,CAAC;EAC9B;;EAEA;AACF;EACEI,gBAAgBA,CAAA,EAAS;IACvB,MAAMT,eAAe,GAAG,IAAI,CAACH,WAAW,EAAEI,SAAS;IAEnD,IAAIS,SAAS,GAAG,GAAG;IACnB,IAAIV,eAAe,YAAYE,6BAAoB,EAAE;MAAA,IAAAS,SAAA;MACnDD,SAAS,GAAG,IAAAlD,OAAA,CAAAH,OAAA,EAAAsD,SAAA,GAAAX,eAAe,CAACG,OAAO,EAAAhC,IAAA,CAAAwC,SAAA,EAChCC,MAAM,IAAKA,MAAM,CAACC,IAAI,KAAK,GAC9B,CAAC,CAAC,CAAC,CAAC,CAACA,IAAI;IACX;IAEA,OAAO,IAAI5B,aAAI,CAAC,IAAI,CAACF,QAAQ,CAAC+B,IAAI,CAAC,CAACC,YAAY,CAAC,OAAO,EAAEL,SAAS,CAAC;EACtE;AACF;AAACM,OAAA,CAAA3D,OAAA,GAAAN,iBAAA","ignoreList":[]}
|
package/package.json
CHANGED
|
@@ -126,15 +126,16 @@ export default class ContentIndexModel extends ResourceModel {
|
|
|
126
126
|
);
|
|
127
127
|
}
|
|
128
128
|
|
|
129
|
+
/**
|
|
130
|
+
*/
|
|
131
|
+
hasFiltersSet(): boolean {
|
|
132
|
+
return this.filterCollection.some((filter) => filter.isActive());
|
|
133
|
+
}
|
|
134
|
+
|
|
129
135
|
/**
|
|
130
136
|
*/
|
|
131
137
|
hasNoFiltersSet(): boolean {
|
|
132
|
-
return (
|
|
133
|
-
this.items.isEmpty &&
|
|
134
|
-
this.filterCollection.filter(
|
|
135
|
-
(filter) => filter.attribute?.inputvalue !== "",
|
|
136
|
-
).length === 0
|
|
137
|
-
);
|
|
138
|
+
return !this.hasFiltersSet();
|
|
138
139
|
}
|
|
139
140
|
|
|
140
141
|
/**
|