2020-02-14 13:08:45 -05:00
|
|
|
import { SIMPLE_BLOB_VIEWER, RICH_BLOB_VIEWER } from '~/blob/components/constants';
|
|
|
|
|
|
|
|
export const SimpleViewerMock = {
|
|
|
|
collapsed: false,
|
|
|
|
loadingPartialName: 'loading',
|
|
|
|
renderError: null,
|
|
|
|
tooLarge: false,
|
|
|
|
type: SIMPLE_BLOB_VIEWER,
|
|
|
|
fileType: 'text',
|
|
|
|
};
|
|
|
|
|
|
|
|
export const RichViewerMock = {
|
|
|
|
collapsed: false,
|
|
|
|
loadingPartialName: 'loading',
|
|
|
|
renderError: null,
|
|
|
|
tooLarge: false,
|
|
|
|
type: RICH_BLOB_VIEWER,
|
|
|
|
fileType: 'markdown',
|
|
|
|
};
|
|
|
|
|
2020-02-06 19:09:12 -05:00
|
|
|
export const Blob = {
|
|
|
|
binary: false,
|
|
|
|
name: 'dummy.md',
|
2020-04-29 17:09:31 -04:00
|
|
|
path: 'foo/bar/dummy.md',
|
2020-02-06 19:09:12 -05:00
|
|
|
rawPath: '/flightjs/flight/snippets/51/raw',
|
|
|
|
size: 75,
|
|
|
|
simpleViewer: {
|
2020-02-14 13:08:45 -05:00
|
|
|
...SimpleViewerMock,
|
2020-02-06 19:09:12 -05:00
|
|
|
},
|
|
|
|
richViewer: {
|
2020-02-14 13:08:45 -05:00
|
|
|
...RichViewerMock,
|
2020-02-06 19:09:12 -05:00
|
|
|
},
|
|
|
|
};
|
|
|
|
|
2020-06-30 20:09:02 -04:00
|
|
|
export const BinaryBlob = {
|
|
|
|
binary: true,
|
|
|
|
name: 'dummy.png',
|
|
|
|
path: 'foo/bar/dummy.png',
|
|
|
|
rawPath: '/flightjs/flight/snippets/51/raw',
|
|
|
|
size: 75,
|
|
|
|
simpleViewer: {
|
|
|
|
...SimpleViewerMock,
|
|
|
|
},
|
|
|
|
richViewer: {
|
|
|
|
...RichViewerMock,
|
|
|
|
},
|
|
|
|
};
|
|
|
|
|
2020-02-14 13:08:45 -05:00
|
|
|
export const RichBlobContentMock = {
|
2020-07-28 08:09:49 -04:00
|
|
|
path: 'foo.md',
|
2020-02-14 13:08:45 -05:00
|
|
|
richData: '<h1>Rich</h1>',
|
|
|
|
};
|
|
|
|
|
|
|
|
export const SimpleBlobContentMock = {
|
2020-07-28 08:09:49 -04:00
|
|
|
path: 'foo.js',
|
2020-02-14 13:08:45 -05:00
|
|
|
plainData: 'Plain',
|
|
|
|
};
|