Skip to content

Commit

Permalink
Merge branch 'cyntler:main' into rerendering
Browse files Browse the repository at this point in the history
  • Loading branch information
hlouzek authored Jan 20, 2024
2 parents a1d29d7 + b9d9d28 commit 1be9e85
Show file tree
Hide file tree
Showing 7 changed files with 7,829 additions and 27,747 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ File viewer for React.
| txt | text/plain |
| xls | application/vnd.ms-excel |
| xlsx | application/vnd.openxmlformats-officedocument.spreadsheetml.sheet |
| mp4 | video/mp4 |

## Storybook Demo

Expand Down
35,550 changes: 7,806 additions & 27,744 deletions package-lock.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cyntler/react-doc-viewer",
"version": "1.14.0",
"version": "1.14.1",
"description": "File viewer for React.",
"author": "Matthew Mogford / Damian Cyntler",
"keywords": [
Expand Down
7 changes: 6 additions & 1 deletion src/DocViewer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,12 @@ const DocViewer = forwardRef<DocViewerRef, DocViewerProps>((props, ref) => {
<ThemeProvider
theme={theme ? { ...defaultTheme, ...theme } : defaultTheme}
>
<Container id="react-doc-viewer" data-testid="react-doc-viewer">
<Container
id="react-doc-viewer"
data-testid="react-doc-viewer"
className={props.className}
style={props.style}
>
<HeaderBar />
<ProxyRenderer />
</Container>
Expand Down
4 changes: 4 additions & 0 deletions src/i18n.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ import ar from "./locales/ar.json";
import sr from "./locales/sr.json";
import sr_cyr from "./locales/sr_cyr.json";
import ja from "./locales/ja.json";
import ru from "./locales/ru.json";
import se from "./locales/se.json";

export const locales = {
en,
Expand All @@ -22,6 +24,8 @@ export const locales = {
sr,
sr_cyr,
ja,
ru,
se
};

export type AvailableLanguages = keyof typeof locales;
Expand Down
2 changes: 1 addition & 1 deletion src/locales/ru.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"documentNavInfo": "Документ {{ currentFileNo }} of {{ allFilesCount }}",
"documentNavInfo": "Документ {{ currentFileNo }} из {{ allFilesCount }}",
"noRendererMessage": "Данный тип файла не поддерживается рендером: {{{ fileType }}}",
"downloadButtonLabel": "Скачать файл",
"brokenFile": "Ваш файл сломан. Пожалуйста, проверьте его на своём комьютере.",
Expand Down
10 changes: 10 additions & 0 deletions src/locales/se.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"documentNavInfo": "Dokument {{ currentFileNo }} av {{ allFilesCount }}",
"noRendererMessage": "Ingen renderare för filtypen: {{{ fileType }}}",
"downloadButtonLabel": "Ladda ner",
"brokenFile": "Filen är trasig. Var vänlig kontrollera den på din maskin.",
"msgPluginRecipients": "Mottagare",
"msgPluginSender": "Avsändare",
"pdfPluginLoading": "Laddar...",
"pdfPluginPageNumber": "Sida {{ currentPage }}/{{ allPagesCount }}"
}

0 comments on commit 1be9e85

Please sign in to comment.