1 // Copyright (C) The Arvados Authors. All rights reserved.
3 // SPDX-License-Identifier: AGPL-3.0
5 import { PropertiesState, getProperty } from '~/store/properties/properties';
6 import { FileViewerList } from '~/models/file-viewers-config';
8 export const FILE_VIEWERS_PROPERTY_NAME = 'fileViewers';
10 export const DEFAULT_FILE_VIEWERS: FileViewerList = [];
11 export const getFileViewers = (state: PropertiesState) =>
12 getProperty<FileViewerList>(FILE_VIEWERS_PROPERTY_NAME)(state) || DEFAULT_FILE_VIEWERS;