90873: Add environment.standardBundles.bundle

This commit is contained in:
Alexandre Vryghem
2022-04-19 12:57:43 +02:00
parent 3ecb3c2209
commit 99aee55efa
5 changed files with 30 additions and 0 deletions

View File

@@ -228,6 +228,12 @@ themes:
rel: manifest rel: manifest
href: assets/dspace/images/favicons/manifest.webmanifest href: assets/dspace/images/favicons/manifest.webmanifest
# The default bundles that should always be displayed as suggestions when you upload a new bundle
standardBundles:
- bundle: ORIGINAL
- bundle: THUMBNAIL
- bundle: LICENSE
# Whether to enable media viewer for image and/or video Bitstreams (i.e. Bitstreams whose MIME type starts with 'image' or 'video'). # Whether to enable media viewer for image and/or video Bitstreams (i.e. Bitstreams whose MIME type starts with 'image' or 'video').
# For images, this enables a gallery viewer where you can zoom or page through images. # For images, this enables a gallery viewer where you can zoom or page through images.
# For videos, this enables embedded video streaming # For videos, this enables embedded video streaming

View File

@@ -14,6 +14,7 @@ import { AuthConfig } from './auth-config.interfaces';
import { UIServerConfig } from './ui-server-config.interface'; import { UIServerConfig } from './ui-server-config.interface';
import { MediaViewerConfig } from './media-viewer-config.interface'; import { MediaViewerConfig } from './media-viewer-config.interface';
import { BrowseByConfig } from './browse-by-config.interface'; import { BrowseByConfig } from './browse-by-config.interface';
import { StandardBundleConfig } from './standard-bundle-config.interface';
interface AppConfig extends Config { interface AppConfig extends Config {
ui: UIServerConfig; ui: UIServerConfig;
@@ -32,6 +33,7 @@ interface AppConfig extends Config {
collection: CollectionPageConfig; collection: CollectionPageConfig;
themes: ThemeConfig[]; themes: ThemeConfig[];
mediaViewer: MediaViewerConfig; mediaViewer: MediaViewerConfig;
standardBundles: StandardBundleConfig[];
} }
const APP_CONFIG = new InjectionToken<AppConfig>('APP_CONFIG'); const APP_CONFIG = new InjectionToken<AppConfig>('APP_CONFIG');

View File

@@ -299,6 +299,13 @@ export class DefaultAppConfig implements AppConfig {
] ]
}, },
]; ];
// The default bundles that should always be displayed when you edit or add a bundle even when no bundle has been
// added to the item yet.
standardBundles: [
{ bundle: 'ORIGINAL' },
{ bundle: 'THUMBNAIL' },
{ bundle: 'LICENSE' }
];
// Whether to enable media viewer for image and/or video Bitstreams (i.e. Bitstreams whose MIME type starts with "image" or "video"). // Whether to enable media viewer for image and/or video Bitstreams (i.e. Bitstreams whose MIME type starts with "image" or "video").
// For images, this enables a gallery viewer where you can zoom or page through images. // For images, this enables a gallery viewer where you can zoom or page through images.
// For videos, this enables embedded video streaming // For videos, this enables embedded video streaming

View File

@@ -0,0 +1,10 @@
import { Config } from './config.interface';
export interface StandardBundleConfig extends Config {
/**
* Used by {@link UploadBitstreamComponent}.
*/
bundle: string;
}

View File

@@ -224,6 +224,11 @@ export const environment: BuildConfig = {
name: 'base', name: 'base',
}, },
], ],
standardBundles: [
{ bundle: 'ORIGINAL' },
{ bundle: 'THUMBNAIL' },
{ bundle: 'LICENSE' }
],
mediaViewer: { mediaViewer: {
image: true, image: true,
video: true video: true