@beinformed/ui 1.52.0 → 1.52.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 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.52.1](https://git.beinformed.com/public/nl.beinformed.bi.layout.lib.ui/compare/v1.52.0...v1.52.1) (2024-08-23)
6
+
7
+
8
+ ### Bug Fixes
9
+
10
+ * **concept-type:** add name of concept type to the concept type model ([2610045](https://git.beinformed.com/public/nl.beinformed.bi.layout.lib.ui/commit/2610045ae6143381e28a5cc90de719f9ce0fcac4))
11
+
5
12
  ## [1.52.0](https://git.beinformed.com/public/nl.beinformed.bi.layout.lib.ui/compare/v1.51.0...v1.52.0) (2024-08-23)
6
13
 
7
14
 
@@ -4,6 +4,14 @@ import ResourceModel from "../base/ResourceModel";
4
4
  * Model for concept details, available through modelcatalog
5
5
  */
6
6
  class ConceptTypeDetailModel extends ResourceModel {
7
+ /**
8
+ * The name of the concept type consists of the functional id of the kmt and the functional id of the concept type separated by a #.<br>
9
+ * For example BEI_CaseManagement#Case
10
+ */
11
+ get name() {
12
+ return this.getData("name", "");
13
+ }
14
+
7
15
  /**
8
16
  */
9
17
  get type() {
@@ -1 +1 @@
1
- {"version":3,"file":"ConceptTypeDetailModel.js","names":["ResourceModel","ConceptTypeDetailModel","type","modelName","isApplicableModel","data","contributions","resourcetype","key","_id","label","getData","isCoreTaxonomy","icon","textColor","backgroundColor","borderColor","labelTypes","propertyTypes","textFragmentTypes","sectionReferenceTypes","conceptTypeHierarchy","links","getLinksByGroup","isOfConceptType","conceptTypeId","hasLinkByKey","hasLinkByHref","selfhref","equals","hasMetamodelIdInHierarchy","metamodelId","all","some","link","_context","_startsWithInstanceProperty","call"],"sources":["../../../src/models/concepts/ConceptTypeDetailModel.js"],"sourcesContent":["// @flow\nimport ResourceModel from \"../base/ResourceModel\";\n\nimport type ModularUIResponse from \"../../modularui/ModularUIResponse\";\nimport type LinkCollection from \"../links/LinkCollection\";\n\n/**\n * Model for concept details, available through modelcatalog\n */\nclass ConceptTypeDetailModel extends ResourceModel {\n /**\n */\n get type(): string {\n return \"ConceptTypeDetail\";\n }\n\n /**\n */\n static get modelName(): string {\n return \"ConceptTypeDetailModel\";\n }\n\n /**\n */\n static isApplicableModel(data: ModularUIResponse): boolean {\n return (\n data.contributions.resourcetype &&\n data.contributions.resourcetype === \"ConceptTypeDetail\"\n );\n }\n\n /**\n */\n get key(): string {\n return this.data._id;\n }\n\n /**\n * Get concept type label\n */\n get label(): string {\n return this.getData(\"label\", \"\");\n }\n\n /**\n */\n get isCoreTaxonomy(): boolean {\n return this.getData(\"coreTaxonomy\", \"false\") === \"true\";\n }\n\n /**\n * Get concept type icon\n */\n get icon(): string {\n return this.getData(\"icon\", \"\");\n }\n\n /**\n * Get concept type text color\n */\n get textColor(): string {\n return this.getData(\"textColor\", \"#000\");\n }\n\n /**\n * Get concept type background color\n */\n get backgroundColor(): string {\n return this.getData(\"backgroundColor\", \"#fff\");\n }\n\n /**\n * Get concept line color\n */\n get borderColor(): string {\n return this.getData(\"lineColor\", \"#000\");\n }\n\n /**\n * Get label types\n */\n get labelTypes(): ?Array<Object> {\n return this.data.labelTypes;\n }\n\n /**\n * Get propertyTypes\n */\n get propertyTypes(): Array<Object> {\n return this.getData(\"propertyTypes\", []);\n }\n\n /**\n * Get textFragmentTypes\n */\n get textFragmentTypes(): Array<Object> {\n return this.getData(\"textFragmentTypes\", []);\n }\n\n /**\n * Get sectionReferenceTypes\n */\n get sectionReferenceTypes(): Array<Object> {\n return this.getData(\"sectionReferenceTypes\", []);\n }\n\n /**\n */\n get conceptTypeHierarchy(): LinkCollection {\n return this.links.getLinksByGroup(\"conceptTypeHierarchy\");\n }\n\n /**\n */\n isOfConceptType(conceptTypeId: string): boolean {\n return (\n this.conceptTypeHierarchy?.hasLinkByKey(conceptTypeId) ||\n this.conceptTypeHierarchy?.hasLinkByHref(conceptTypeId) ||\n this.selfhref.equals(conceptTypeId)\n );\n }\n\n /**\n * Indicates if the given metamodel functional identifier exists in the hierarchy of concept types\n */\n hasMetamodelIdInHierarchy(metamodelId: string): boolean {\n return (\n this.conceptTypeHierarchy?.all.some((link) =>\n link.key.startsWith(metamodelId + \"#\"),\n ) || false\n );\n }\n}\n\nexport default ConceptTypeDetailModel;\n"],"mappings":";AACA,OAAOA,aAAa,MAAM,uBAAuB;AAKjD;AACA;AACA;AACA,MAAMC,sBAAsB,SAASD,aAAa,CAAC;EACjD;AACF;EACE,IAAIE,IAAIA,CAAA,EAAW;IACjB,OAAO,mBAAmB;EAC5B;;EAEA;AACF;EACE,WAAWC,SAASA,CAAA,EAAW;IAC7B,OAAO,wBAAwB;EACjC;;EAEA;AACF;EACE,OAAOC,iBAAiBA,CAACC,IAAuB,EAAW;IACzD,OACEA,IAAI,CAACC,aAAa,CAACC,YAAY,IAC/BF,IAAI,CAACC,aAAa,CAACC,YAAY,KAAK,mBAAmB;EAE3D;;EAEA;AACF;EACE,IAAIC,GAAGA,CAAA,EAAW;IAChB,OAAO,IAAI,CAACH,IAAI,CAACI,GAAG;EACtB;;EAEA;AACF;AACA;EACE,IAAIC,KAAKA,CAAA,EAAW;IAClB,OAAO,IAAI,CAACC,OAAO,CAAC,OAAO,EAAE,EAAE,CAAC;EAClC;;EAEA;AACF;EACE,IAAIC,cAAcA,CAAA,EAAY;IAC5B,OAAO,IAAI,CAACD,OAAO,CAAC,cAAc,EAAE,OAAO,CAAC,KAAK,MAAM;EACzD;;EAEA;AACF;AACA;EACE,IAAIE,IAAIA,CAAA,EAAW;IACjB,OAAO,IAAI,CAACF,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC;EACjC;;EAEA;AACF;AACA;EACE,IAAIG,SAASA,CAAA,EAAW;IACtB,OAAO,IAAI,CAACH,OAAO,CAAC,WAAW,EAAE,MA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A,GAAAD,IAAI,CAAC1B,GAAG,EAAA6B,IAAA,CAAAF,QAAA,EAAYJ,WAAW,GAAG,GAAG,CAAC;IAAA,CACxC,CAAC,IAAI,KAAK;EAEd;AACF;AAEA,eAAe9B,sBAAsB","ignoreList":[]}
1
+ {"version":3,"file":"ConceptTypeDetailModel.js","names":["ResourceModel","ConceptTypeDetailModel","name","getData","type","modelName","isApplicableModel","data","contributions","resourcetype","key","_id","label","isCoreTaxonomy","icon","textColor","backgroundColor","borderColor","labelTypes","propertyTypes","textFragmentTypes","sectionReferenceTypes","conceptTypeHierarchy","links","getLinksByGroup","isOfConceptType","conceptTypeId","hasLinkByKey","hasLinkByHref","selfhref","equals","hasMetamodelIdInHierarchy","metamodelId","all","some","link","_context","_startsWithInstanceProperty","call"],"sources":["../../../src/models/concepts/ConceptTypeDetailModel.js"],"sourcesContent":["// @flow\nimport ResourceModel from \"../base/ResourceModel\";\n\nimport type ModularUIResponse from \"../../modularui/ModularUIResponse\";\nimport type LinkCollection from \"../links/LinkCollection\";\n\n/**\n * Model for concept details, available through modelcatalog\n */\nclass ConceptTypeDetailModel extends ResourceModel {\n /**\n * The name of the concept type consists of the functional id of the kmt and the functional id of the concept type separated by a #.<br>\n * For example BEI_CaseManagement#Case\n */\n get name(): string {\n return this.getData(\"name\", \"\");\n }\n\n /**\n */\n get type(): string {\n return \"ConceptTypeDetail\";\n }\n\n /**\n */\n static get modelName(): string {\n return \"ConceptTypeDetailModel\";\n }\n\n /**\n */\n static isApplicableModel(data: ModularUIResponse): boolean {\n return (\n data.contributions.resourcetype &&\n data.contributions.resourcetype === \"ConceptTypeDetail\"\n );\n }\n\n /**\n */\n get key(): string {\n return this.data._id;\n }\n\n /**\n * Get concept type label\n */\n get label(): string {\n return this.getData(\"label\", \"\");\n }\n\n /**\n */\n get isCoreTaxonomy(): boolean {\n return this.getData(\"coreTaxonomy\", \"false\") === \"true\";\n }\n\n /**\n * Get concept type icon\n */\n get icon(): string {\n return this.getData(\"icon\", \"\");\n }\n\n /**\n * Get concept type text color\n */\n get textColor(): string {\n return this.getData(\"textColor\", \"#000\");\n }\n\n /**\n * Get concept type background color\n */\n get backgroundColor(): string {\n return this.getData(\"backgroundColor\", \"#fff\");\n }\n\n /**\n * Get concept line color\n */\n get borderColor(): string {\n return this.getData(\"lineColor\", \"#000\");\n }\n\n /**\n * Get label types\n */\n get labelTypes(): ?Array<Object> {\n return this.data.labelTypes;\n }\n\n /**\n * Get propertyTypes\n */\n get propertyTypes(): Array<Object> {\n return this.getData(\"propertyTypes\", []);\n }\n\n /**\n * Get textFragmentTypes\n */\n get textFragmentTypes(): Array<Object> {\n return this.getData(\"textFragmentTypes\", []);\n }\n\n /**\n * Get sectionReferenceTypes\n */\n get sectionReferenceTypes(): Array<Object> {\n return this.getData(\"sectionReferenceTypes\", []);\n }\n\n /**\n */\n get conceptTypeHierarchy(): LinkCollection {\n return this.links.getLinksByGroup(\"conceptTypeHierarchy\");\n }\n\n /**\n */\n isOfConceptType(conceptTypeId: string): boolean {\n return (\n this.conceptTypeHierarchy?.hasLinkByKey(conceptTypeId) ||\n this.conceptTypeHierarchy?.hasLinkByHref(conceptTypeId) ||\n this.selfhref.equals(conceptTypeId)\n );\n }\n\n /**\n * Indicates if the given metamodel functional identifier exists in the hierarchy of concept types\n */\n hasMetamodelIdInHierarchy(metamodelId: string): boolean {\n return (\n this.conceptTypeHierarchy?.all.some((link) =>\n link.key.startsWith(metamodelId + \"#\"),\n ) || false\n );\n }\n}\n\nexport default ConceptTypeDetailModel;\n"],"mappings":";AACA,OAAOA,aAAa,MAAM,uBAAuB;AAKjD;AACA;AACA;AACA,MAAMC,sBAAsB,SAASD,aAAa,CAAC;EACjD;AACF;AACA;AACA;EACE,IAAIE,IAAIA,CAAA,EAAW;IACjB,OAAO,IAAI,CAACC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC;EACjC;;EAEA;AACF;EACE,IAAIC,IAAIA,CAAA,EAAW;IACjB,OAAO,mBAAmB;EAC5B;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C;;EAEA;AACF;AACA;EACE,IAAIiB,iBAAiBA,CAAA,EAAkB;IACrC,OAAO,IAAI,CAACjB,OAAO,CAAC,mBAAmB,EAAE,EAAE,CAAC;EAC9C;;EAEA;AACF;AACA;EACE,IAAIkB,qBAAqBA,CAAA,EAAkB;IACzC,OAAO,IAAI,CAAClB,OAAO,CAAC,uBAAuB,EAAE,EAAE,CAAC;EAClD;;EAEA;AACF;EACE,IAAImB,oBAAoBA,CAAA,EAAmB;IACzC,OAAO,IAAI,CAACC,KAAK,CAACC,eAAe,CAAC,sBAAsB,CAAC;EAC3D;;EAEA;AACF;EACEC,eAAeA,CAACC,aAAqB,EAAW;IAC9C,OACE,IAAI,CAACJ,oBAAoB,EAAEK,YAAY,CAACD,aAAa,CAAC,IACtD,IAAI,CAACJ,oBAAoB,EAAEM,aAAa,CAACF,aAAa,CAAC,IACvD,IAAI,CAACG,QAAQ,CAACC,MAAM,CAACJ,aAAa,CAAC;EAEvC;;EAEA;AACF;AACA;EACEK,yBAAyBA,CAACC,WAAmB,EAAW;IACtD,OACE,IAAI,CAACV,oBAAoB,EAAEW,GAAG,CAACC,IAAI,CAAEC,IAAI;MAAA,IAAAC,QAAA;MAAA,OACvCC,2BAAA,CAAAD,QAAA,GAAAD,IAAI,CAACzB,GAAG,EAAA4B,IAAA,CAAAF,QAAA,EAAYJ,WAAW,GAAG,GAAG,CAAC;IAAA,CACxC,CAAC,IAAI,KAAK;EAEd;AACF;AAEA,eAAe/B,sBAAsB","ignoreList":[]}
@@ -11,6 +11,14 @@ var _ResourceModel = _interopRequireDefault(require("../base/ResourceModel"));
11
11
  * Model for concept details, available through modelcatalog
12
12
  */
13
13
  class ConceptTypeDetailModel extends _ResourceModel.default {
14
+ /**
15
+ * The name of the concept type consists of the functional id of the kmt and the functional id of the concept type separated by a #.<br>
16
+ * For example BEI_CaseManagement#Case
17
+ */
18
+ get name() {
19
+ return this.getData("name", "");
20
+ }
21
+
14
22
  /**
15
23
  */
16
24
  get type() {
@@ -8,6 +8,14 @@ import type LinkCollection from "../links/LinkCollection";
8
8
  * Model for concept details, available through modelcatalog
9
9
  */
10
10
  class ConceptTypeDetailModel extends ResourceModel {
11
+ /**
12
+ * The name of the concept type consists of the functional id of the kmt and the functional id of the concept type separated by a #.<br>
13
+ * For example BEI_CaseManagement#Case
14
+ */
15
+ get name(): string {
16
+ return this.getData("name", "");
17
+ }
18
+
11
19
  /**
12
20
  */
13
21
  get type(): string {
@@ -1 +1 @@
1
- {"version":3,"file":"ConceptTypeDetailModel.js","names":["_ResourceModel","_interopRequireDefault","require","ConceptTypeDetailModel","ResourceModel","type","modelName","isApplicableModel","data","contributions","resourcetype","key","_id","label","getData","isCoreTaxonomy","icon","textColor","backgroundColor","borderColor","labelTypes","propertyTypes","textFragmentTypes","sectionReferenceTypes","conceptTypeHierarchy","links","getLinksByGroup","isOfConceptType","conceptTypeId","hasLinkByKey","hasLinkByHref","selfhref","equals","hasMetamodelIdInHierarchy","metamodelId","all","some","link","_context","_startsWith","default","call","_default","exports"],"sources":["../../../src/models/concepts/ConceptTypeDetailModel.js"],"sourcesContent":["// @flow\nimport ResourceModel from \"../base/ResourceModel\";\n\nimport type ModularUIResponse from \"../../modularui/ModularUIResponse\";\nimport type LinkCollection from \"../links/LinkCollection\";\n\n/**\n * Model for concept details, available through modelcatalog\n */\nclass ConceptTypeDetailModel extends ResourceModel {\n /**\n */\n get type(): string {\n return \"ConceptTypeDetail\";\n }\n\n /**\n */\n static get modelName(): string {\n return \"ConceptTypeDetailModel\";\n }\n\n /**\n */\n static isApplicableModel(data: ModularUIResponse): boolean {\n return (\n data.contributions.resourcetype &&\n data.contributions.resourcetype === \"ConceptTypeDetail\"\n );\n }\n\n /**\n */\n get key(): string {\n return this.data._id;\n }\n\n /**\n * Get concept type label\n */\n get label(): string {\n return this.getData(\"label\", \"\");\n }\n\n /**\n */\n get isCoreTaxonomy(): boolean {\n return this.getData(\"coreTaxonomy\", \"false\") === \"true\";\n }\n\n /**\n * Get concept type icon\n */\n get icon(): string {\n return this.getData(\"icon\", \"\");\n }\n\n /**\n * Get concept type text color\n */\n get textColor(): string {\n return this.getData(\"textColor\", \"#000\");\n }\n\n /**\n * Get concept type background color\n */\n get backgroundColor(): string {\n return this.getData(\"backgroundColor\", \"#fff\");\n }\n\n /**\n * Get concept line color\n */\n get borderColor(): string {\n return this.getData(\"lineColor\", \"#000\");\n }\n\n /**\n * Get label types\n */\n get labelTypes(): ?Array<Object> {\n return this.data.labelTypes;\n }\n\n /**\n * Get propertyTypes\n */\n get propertyTypes(): Array<Object> {\n return this.getData(\"propertyTypes\", []);\n }\n\n /**\n * Get textFragmentTypes\n */\n get textFragmentTypes(): Array<Object> {\n return this.getData(\"textFragmentTypes\", []);\n }\n\n /**\n * Get sectionReferenceTypes\n */\n get sectionReferenceTypes(): Array<Object> {\n return this.getData(\"sectionReferenceTypes\", []);\n }\n\n /**\n */\n get conceptTypeHierarchy(): LinkCollection {\n return this.links.getLinksByGroup(\"conceptTypeHierarchy\");\n }\n\n /**\n */\n isOfConceptType(conceptTypeId: string): boolean {\n return (\n this.conceptTypeHierarchy?.hasLinkByKey(conceptTypeId) ||\n this.conceptTypeHierarchy?.hasLinkByHref(conceptTypeId) ||\n this.selfhref.equals(conceptTypeId)\n );\n }\n\n /**\n * Indicates if the given metamodel functional identifier exists in the hierarchy of concept types\n */\n hasMetamodelIdInHierarchy(metamodelId: string): boolean {\n return (\n this.conceptTypeHierarchy?.all.some((link) =>\n link.key.startsWith(metamodelId + \"#\"),\n ) || false\n );\n }\n}\n\nexport default ConceptTypeDetailModel;\n"],"mappings":";;;;;;;;AACA,IAAAA,cAAA,GAAAC,sBAAA,CAAAC,OAAA;AAKA;AACA;AACA;AACA,MAAMC,sBAAsB,SAASC,sBAAa,CAAC;EACjD;AACF;EACE,IAAIC,IAAIA,CAAA,EAAW;IACjB,OAAO,mBAAmB;EAC5B;;EAEA;AACF;EACE,WAAWC,SAASA,CAAA,EAAW;IAC7B,OAAO,wBAAw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AAO,IAAI,CAACR,OAAO,CAAC,mBAAmB,EAAE,EAAE,CAAC;EAC9C;;EAEA;AACF;AACA;EACE,IAAIS,qBAAqBA,CAAA,EAAkB;IACzC,OAAO,IAAI,CAACT,OAAO,CAAC,uBAAuB,EAAE,EAAE,CAAC;EAClD;;EAEA;AACF;EACE,IAAIU,oBAAoBA,CAAA,EAAmB;IACzC,OAAO,IAAI,CAACC,KAAK,CAACC,eAAe,CAAC,sBAAsB,CAAC;EAC3D;;EAEA;AACF;EACEC,eAAeA,CAACC,aAAqB,EAAW;IAC9C,OACE,IAAI,CAACJ,oBAAoB,EAAEK,YAAY,CAACD,aAAa,CAAC,IACtD,IAAI,CAACJ,oBAAoB,EAAEM,aAAa,CAACF,aAAa,CAAC,IACvD,IAAI,CAACG,QAAQ,CAACC,MAAM,CAACJ,aAAa,CAAC;EAEvC;;EAEA;AACF;AACA;EACEK,yBAAyBA,CAACC,WAAmB,EAAW;IACtD,OACE,IAAI,CAACV,oBAAoB,EAAEW,GAAG,CAACC,IAAI,CAAEC,IAAI;MAAA,IAAAC,QAAA;MAAA,OACvC,IAAAC,WAAA,CAAAC,OAAA,EAAAF,QAAA,GAAAD,IAAI,CAAC1B,GAAG,EAAA8B,IAAA,CAAAH,QAAA,EAAYJ,WAAW,GAAG,GAAG,CAAC;IAAA,CACxC,CAAC,IAAI,KAAK;EAEd;AACF;AAAC,IAAAQ,QAAA,GAAAC,OAAA,CAAAH,OAAA,GAEcrC,sBAAsB","ignoreList":[]}
1
+ {"version":3,"file":"ConceptTypeDetailModel.js","names":["_ResourceModel","_interopRequireDefault","require","ConceptTypeDetailModel","ResourceModel","name","getData","type","modelName","isApplicableModel","data","contributions","resourcetype","key","_id","label","isCoreTaxonomy","icon","textColor","backgroundColor","borderColor","labelTypes","propertyTypes","textFragmentTypes","sectionReferenceTypes","conceptTypeHierarchy","links","getLinksByGroup","isOfConceptType","conceptTypeId","hasLinkByKey","hasLinkByHref","selfhref","equals","hasMetamodelIdInHierarchy","metamodelId","all","some","link","_context","_startsWith","default","call","_default","exports"],"sources":["../../../src/models/concepts/ConceptTypeDetailModel.js"],"sourcesContent":["// @flow\nimport ResourceModel from \"../base/ResourceModel\";\n\nimport type ModularUIResponse from \"../../modularui/ModularUIResponse\";\nimport type LinkCollection from \"../links/LinkCollection\";\n\n/**\n * Model for concept details, available through modelcatalog\n */\nclass ConceptTypeDetailModel extends ResourceModel {\n /**\n * The name of the concept type consists of the functional id of the kmt and the functional id of the concept type separated by a #.<br>\n * For example BEI_CaseManagement#Case\n */\n get name(): string {\n return this.getData(\"name\", \"\");\n }\n\n /**\n */\n get type(): string {\n return \"ConceptTypeDetail\";\n }\n\n /**\n */\n static get modelName(): string {\n return \"ConceptTypeDetailModel\";\n }\n\n /**\n */\n static isApplicableModel(data: ModularUIResponse): boolean {\n return (\n data.contributions.resourcetype &&\n data.contributions.resourcetype === \"ConceptTypeDetail\"\n );\n }\n\n /**\n */\n get key(): string {\n return this.data._id;\n }\n\n /**\n * Get concept type label\n */\n get label(): string {\n return this.getData(\"label\", \"\");\n }\n\n /**\n */\n get isCoreTaxonomy(): boolean {\n return this.getData(\"coreTaxonomy\", \"false\") === \"true\";\n }\n\n /**\n * Get concept type icon\n */\n get icon(): string {\n return this.getData(\"icon\", \"\");\n }\n\n /**\n * Get concept type text color\n */\n get textColor(): string {\n return this.getData(\"textColor\", \"#000\");\n }\n\n /**\n * Get concept type background color\n */\n get backgroundColor(): string {\n return this.getData(\"backgroundColor\", \"#fff\");\n }\n\n /**\n * Get concept line color\n */\n get borderColor(): string {\n return this.getData(\"lineColor\", \"#000\");\n }\n\n /**\n * Get label types\n */\n get labelTypes(): ?Array<Object> {\n return this.data.labelTypes;\n }\n\n /**\n * Get propertyTypes\n */\n get propertyTypes(): Array<Object> {\n return this.getData(\"propertyTypes\", []);\n }\n\n /**\n * Get textFragmentTypes\n */\n get textFragmentTypes(): Array<Object> {\n return this.getData(\"textFragmentTypes\", []);\n }\n\n /**\n * Get sectionReferenceTypes\n */\n get sectionReferenceTypes(): Array<Object> {\n return this.getData(\"sectionReferenceTypes\", []);\n }\n\n /**\n */\n get conceptTypeHierarchy(): LinkCollection {\n return this.links.getLinksByGroup(\"conceptTypeHierarchy\");\n }\n\n /**\n */\n isOfConceptType(conceptTypeId: string): boolean {\n return (\n this.conceptTypeHierarchy?.hasLinkByKey(conceptTypeId) ||\n this.conceptTypeHierarchy?.hasLinkByHref(conceptTypeId) ||\n this.selfhref.equals(conceptTypeId)\n );\n }\n\n /**\n * Indicates if the given metamodel functional identifier exists in the hierarchy of concept types\n */\n hasMetamodelIdInHierarchy(metamodelId: string): boolean {\n return (\n this.conceptTypeHierarchy?.all.some((link) =>\n link.key.startsWith(metamodelId + \"#\"),\n ) || false\n );\n }\n}\n\nexport default ConceptTypeDetailModel;\n"],"mappings":";;;;;;;;AACA,IAAAA,cAAA,GAAAC,sBAAA,CAAAC,OAAA;AAKA;AACA;AACA;AACA,MAAMC,sBAAsB,SAASC,sBAAa,CAAC;EACjD;AACF;AACA;AACA;EACE,IAAIC,IAAIA,CAAA,EAAW;IACjB,OAAO,IAAI,CAACC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC;EACjC;;EAEA;AACF;EACE,IAAIC,IAAIA,CAAA,EAAW;IACjB,OAAO,mBAAmB;EAC5B;;EAEA;AACF;EACE,WAAWC,SAASA,CAAA,EAAW;IAC7B,OAAO,wBAAwB;EACjC;;EAEA;AACF;EACE,OAAOC,iBAAiBA,CAACC,IAAuB,EAAW;IACzD,OACEA,IAAI,CAACC,aAAa,CAACC,YAAY,IAC/BF,IAAI,CAACC,aAAa,CAACC,YAAY,KAAK,mBAAmB;EAE3D;;EAEA;AACF;EACE,IAAIC,GAAGA,CAAA,EAAW;IAChB,OAAO,IAAI,CAACH,IAAI,CAACI,GAAG;EACtB;;EAEA;AACF;AACA;EACE,IAAIC,KAAKA,CAAA,EAAW;IAClB,OAAO,IAAI,CAACT,OAAO,CAAC,OAAO,EAAE,EAAE,CAA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IAAI,CAACJ,oBAAoB,EAAEK,YAAY,CAACD,aAAa,CAAC,IACtD,IAAI,CAACJ,oBAAoB,EAAEM,aAAa,CAACF,aAAa,CAAC,IACvD,IAAI,CAACG,QAAQ,CAACC,MAAM,CAACJ,aAAa,CAAC;EAEvC;;EAEA;AACF;AACA;EACEK,yBAAyBA,CAACC,WAAmB,EAAW;IACtD,OACE,IAAI,CAACV,oBAAoB,EAAEW,GAAG,CAACC,IAAI,CAAEC,IAAI;MAAA,IAAAC,QAAA;MAAA,OACvC,IAAAC,WAAA,CAAAC,OAAA,EAAAF,QAAA,GAAAD,IAAI,CAACzB,GAAG,EAAA6B,IAAA,CAAAH,QAAA,EAAYJ,WAAW,GAAG,GAAG,CAAC;IAAA,CACxC,CAAC,IAAI,KAAK;EAEd;AACF;AAAC,IAAAQ,QAAA,GAAAC,OAAA,CAAAH,OAAA,GAEctC,sBAAsB","ignoreList":[]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@beinformed/ui",
3
- "version": "1.52.0",
3
+ "version": "1.52.1",
4
4
  "description": "Toolbox for be informed javascript layouts",
5
5
  "license": "SEE LICENSE IN LICENSE.md",
6
6
  "bugs": "http://support.beinformed.com",
@@ -8,6 +8,14 @@ import type LinkCollection from "../links/LinkCollection";
8
8
  * Model for concept details, available through modelcatalog
9
9
  */
10
10
  class ConceptTypeDetailModel extends ResourceModel {
11
+ /**
12
+ * The name of the concept type consists of the functional id of the kmt and the functional id of the concept type separated by a #.<br>
13
+ * For example BEI_CaseManagement#Case
14
+ */
15
+ get name(): string {
16
+ return this.getData("name", "");
17
+ }
18
+
11
19
  /**
12
20
  */
13
21
  get type(): string {