customizing the untyped-item component

59 views
Skip to first unread message

bens...@gmail.com

unread,
Oct 8, 2024, 3:55:11 PM10/8/24
to DSpace Technical Support
dspace 7.6.2

using the custom theme.

 If I modify untyped-item.component.ts in dspace-angular-dspace-7.6.2/src/themes/custom/app/item-page/simple/item-types/untyped-item
 
    styleUrls: ['./untyped-item.component.scss'],
  //styleUrls: ['../../../../../../../app/item-page/simple/item-types/untyped-item/untyped-item.component.scss'],
   templateUrl: './untyped-item.component.html',
  //templateUrl: '../../../../../../../app/item-page/simple/item-types/untyped-item/untyped-item.component.html',
 
  It does not use the local copy of untyped-item.component.html. It is still using the one in
  dspace-angular-dspace-7.6.2/src/app/item-page/simple/item-types/untyped-item/
 
 
but if I modify footer.component.ts in  dspace-angular-dspace-7.6.2/src/themes/custom/app/footer

   styleUrls: ['./footer.component.scss'],
  //styleUrls: ['../../../../app/footer/footer.component.scss'],
  templateUrl: './footer.component.html'
  //templateUrl: '../../../../app/footer/footer.component.html'
 
 It works using the local copy of the footer.component.html

What am I missing to get it to work?

bens...@gmail.com

unread,
Oct 9, 2024, 3:33:36 PM10/9/24
to DSpace Technical Support
Something I noticed.
in the eager-themes module of dspace-angular-dspace-7.6.2/src/themes/custom

import { ItemPageModule } from '../../app/item-page/item-page.module';
import { UntypedItemComponent } from './app/item-page/simple/item-types/untyped-item/untyped-item.component';

So this is pointing to the custom themed version of untyped-item.component


but in the ../../app/item-page/item-page.module which would be /dspace-angular-dspace-7.6.2/src/app/item-page/item-page.module

import { UntypedItemComponent } from './simple/item-types/untyped-item/untyped-item.component';

this is pointing to the default app version of untyped-item.component

What happens when eager-themes imports one version but a component imports a different version?

Reply all
Reply to author
Forward
0 new messages