1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-09 02:42:47 +00:00

change default thumbnail size (#6710)

* change default thumbnail size

* change py test file

* change thumbnail image size
This commit is contained in:
Michael An
2024-09-05 14:56:52 +08:00
committed by GitHub
parent eaf2114643
commit fba6f9735e
19 changed files with 56 additions and 43 deletions

View File

@@ -1,6 +1,6 @@
import React, { Fragment } from 'react';
import PropTypes from 'prop-types';
import { siteRoot, gettext, username, enableSeadoc } from '../../utils/constants';
import { siteRoot, gettext, username, enableSeadoc, thumbnailSizeForOriginal } from '../../utils/constants';
import { Utils } from '../../utils/utils';
import TextTranslation from '../../utils/text-translation';
import URLDecorator from '../../utils/url-decorator';
@@ -182,12 +182,12 @@ class DirentListView extends React.Component {
const name = item.name;
const repoID = this.props.repoID;
const path = Utils.encodePath(Utils.joinPath(this.props.path, name));
const src = `${siteRoot}repo/${repoID}/raw${path}`;
return {
'name': name,
'url': `${siteRoot}lib/${repoID}/file${path}`,
'src': src
'thumbnail': `${siteRoot}thumbnail/${repoID}/${thumbnailSizeForOriginal}${path}`,
'src': `${siteRoot}repo/${repoID}/raw${path}`,
};
};