enable markdown for other metadata fields

20 views
Skip to first unread message

Alex B

unread,
Mar 13, 2024, 7:46:43 AMMar 13
to DSpace Developers
Dear colleagues,
when trying to create your own sub component for "dc.title" following the example of ItemPageAbstractFieldComponent, 

Error: src/app/item-page/simple/field-components/specific-field/item-page-field.component.html:2:3 - error NG8001: 'ds-metadata-values' is not a known element:
1. If 'ds-metadata-values' is an Angular component, then verify that it is part of this module.
2. If 'ds-metadata-values' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.

  2   <ds-metadata-values
      ~~~~~~~~~~~~~~~~~~~
  3     [mdValues]="item?.allMetadata(fields)"
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
...
  8     [browseDefinition]="browseDefinition|async"
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  9   ></ds-metadata-values>
    ~~~

  src/app/item-page/simple/field-components/specific-field/title/item-page-title-field.component.ts:11:16
    11   templateUrl: '../item-page-field.component.html'
                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Error occurs in the template of component ItemPageTitleFieldComponent.


Error: src/app/item-page/simple/field-components/specific-field/item-page-field.component.html:3:5 - error NG8002: Can't bind to 'mdValues' since it isn't a known property of 'ds-metadata-values'.
1. If 'ds-metadata-values' is an Angular component and it has 'mdValues' input, then verify that it is part of this module.
2. If 'ds-metadata-values' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
3. To allow any property add 'NO_ERRORS_SCHEMA' to the '@NgModule.schemas' of this component.

3     [mdValues]="item?.allMetadata(fields)"
      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

  src/app/item-page/simple/field-components/specific-field/title/item-page-title-field.component.ts:11:16
    11   templateUrl: '../item-page-field.component.html'
                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Error occurs in the template of component ItemPageTitleFieldComponent.


Error: src/app/item-page/simple/field-components/specific-field/item-page-field.component.html:4:5 - error NG8002: Can't bind to 'separator' since it isn't a known property of 'ds-metadata-values'.
1. If 'ds-metadata-values' is an Angular component and it has 'separator' input, then verify that it is part of this module.
2. If 'ds-metadata-values' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
3. To allow any property add 'NO_ERRORS_SCHEMA' to the '@NgModule.schemas' of this component.

4     [separator]="separator"
      ~~~~~~~~~~~~~~~~~~~~~~~

  src/app/item-page/simple/field-components/specific-field/title/item-page-title-field.component.ts:11:16
    11   templateUrl: '../item-page-field.component.html'
                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Error occurs in the template of component ItemPageTitleFieldComponent.


Error: src/app/item-page/simple/field-components/specific-field/item-page-field.component.html:5:5 - error NG8002: Can't bind to 'label' since it isn't a known property of 'ds-metadata-values'.
1. If 'ds-metadata-values' is an Angular component and it has 'label' input, then verify that it is part of this module.
2. If 'ds-metadata-values' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
3. To allow any property add 'NO_ERRORS_SCHEMA' to the '@NgModule.schemas' of this component.

5     [label]="label"
      ~~~~~~~~~~~~~~~

  src/app/item-page/simple/field-components/specific-field/title/item-page-title-field.component.ts:11:16
    11   templateUrl: '../item-page-field.component.html'
                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Error occurs in the template of component ItemPageTitleFieldComponent.


Error: src/app/item-page/simple/field-components/specific-field/item-page-field.component.html:6:5 - error NG8002: Can't bind to 'enableMarkdown' since it isn't a known property of 'ds-metadata-values'.
1. If 'ds-metadata-values' is an Angular component and it has 'enableMarkdown' input, then verify that it is part of this module.
2. If 'ds-metadata-values' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
3. To allow any property add 'NO_ERRORS_SCHEMA' to the '@NgModule.schemas' of this component.

6     [enableMarkdown]="enableMarkdown"
      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

  src/app/item-page/simple/field-components/specific-field/title/item-page-title-field.component.ts:11:16
    11   templateUrl: '../item-page-field.component.html'
                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Error occurs in the template of component ItemPageTitleFieldComponent.


Error: src/app/item-page/simple/field-components/specific-field/item-page-field.component.html:7:5 - error NG8002: Can't bind to 'urlRegex' since it isn't a known property of 'ds-metadata-values'.
1. If 'ds-metadata-values' is an Angular component and it has 'urlRegex' input, then verify that it is part of this module.
2. If 'ds-metadata-values' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
3. To allow any property add 'NO_ERRORS_SCHEMA' to the '@NgModule.schemas' of this component.

7     [urlRegex]="urlRegex"
      ~~~~~~~~~~~~~~~~~~~~~

  src/app/item-page/simple/field-components/specific-field/title/item-page-title-field.component.ts:11:16
    11   templateUrl: '../item-page-field.component.html'
                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Error occurs in the template of component ItemPageTitleFieldComponent.


Error: src/app/item-page/simple/field-components/specific-field/item-page-field.component.html:8:5 - error NG8002: Can't bind to 'browseDefinition' since it isn't a known property of 'ds-metadata-values'.
1. If 'ds-metadata-values' is an Angular component and it has 'browseDefinition' input, then verify that it is part of this module.
2. If 'ds-metadata-values' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
3. To allow any property add 'NO_ERRORS_SCHEMA' to the '@NgModule.schemas' of this component.

8     [browseDefinition]="browseDefinition|async"
      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

  src/app/item-page/simple/field-components/specific-field/title/item-page-title-field.component.ts:11:16
    11   templateUrl: '../item-page-field.component.html'
                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Error occurs in the template of component ItemPageTitleFieldComponent.

Please tell me how to fix these errors?

Best regards,
Alex

Reply all
Reply to author
Forward
0 new messages