Skip to content

TagSpaces is an offline, open source, document manager with tagging support

chore: improving audio recording

Ilian Sapundshiev050f93793c99
diff --git a/app/app.html b/app/app.html
index 6f981c2a5..a5697e1f5 100644
--- a/app/app.html
+++ b/app/app.html
@@ -4,7 +4,7 @@
<title>TagSpaces Desktop</title>
<meta
http-equiv="Content-Security-Policy"
- content="connect-src files: *; default-src 'self' ; object-src 'none' ; script-src 'self' 'unsafe-inline' ; style-src 'self' 'unsafe-inline' data: blob: ; media-src *; img-src * blob: data: content:;"
+ content="connect-src files: *; default-src 'self' ; object-src 'none' ; script-src 'self' 'unsafe-inline' ; style-src 'self' 'unsafe-inline' data: blob: ; media-src * blob: ; img-src * blob: data: content:;"
/>
<meta charset="utf-8" />
<meta name="format-detection" content="telephone=yes" />
diff --git a/app/appd.html b/app/appd.html
index d1809c5b3..ae542148a 100644
--- a/app/appd.html
+++ b/app/appd.html
@@ -4,7 +4,7 @@
<title>TagSpaces Desktop Dev</title>
<meta
http-equiv="Content-Security-Policy"
- content="connect-src files: *; default-src 'self' ; object-src 'none' ; font-src http://localhost:1212 'self'; script-src http://localhost:1212 'self' 'unsafe-inline' 'unsafe-eval'; style-src 'self' 'unsafe-inline' data: blob: ; media-src *; img-src * blob: data: content:;"
+ content="connect-src files: *; default-src 'self' ; object-src 'none' ; font-src http://localhost:1212 'self'; script-src http://localhost:1212 'self' 'unsafe-inline' 'unsafe-eval'; style-src 'self' 'unsafe-inline' data: blob: ; media-src * blob: ; img-src * blob: data: content:;"
/>
<meta charset="utf-8" />
<meta name="format-detection" content="telephone=yes" />
diff --git a/app/components/CommonIcons.tsx b/app/components/CommonIcons.tsx
index 4cd31bb9c..91a7ebd04 100644
--- a/app/components/CommonIcons.tsx
+++ b/app/components/CommonIcons.tsx
@@ -111,3 +111,19 @@ export { default as MoreMenuIcon } from '@mui/icons-material/MoreVert';
export { default as RevisionIcon } from '@mui/icons-material/Restore';
export { default as DescriptionIcon } from '@mui/icons-material/Subject';
+
+export { default as AudioRecordIcon } from '@mui/icons-material/KeyboardVoice';
+
+export { default as NewFileIcon } from '@mui/icons-material/InsertDriveFile';
+
+export { default as NewFolderIcon } from '@mui/icons-material/CreateNewFolder';
+
+export { default as AddExistingFileIcon } from '@mui/icons-material/ExitToApp';
+
+export { default as RecordIcon } from '@mui/icons-material/FiberManualRecord';
+
+export { default as StopIcon } from '@mui/icons-material/Stop';
+
+export { default as PauseIcon } from '@mui/icons-material/Pause';
+
+export { default as SaveIcon } from '@mui/icons-material/Save';
diff --git a/app/components/EntryContainer.tsx b/app/components/EntryContainer.tsx
index c6fb22dae..8fa8832c6 100644
--- a/app/components/EntryContainer.tsx
+++ b/app/components/EntryContainer.tsx
@@ -30,8 +30,6 @@ import fscreen from 'fscreen';
import Button from '@mui/material/Button';
import LoadingButton from '@mui/lab/LoadingButton';
import Tooltip from '-/components/Tooltip';
-import EditIcon from '@mui/icons-material/Edit';
-import SaveIcon from '@mui/icons-material/Save';
import Box from '@mui/material/Box';
import ButtonGroup from '@mui/material/ButtonGroup';
import { CancelIcon, CloseEditIcon } from '-/components/CommonIcons';
@@ -70,6 +68,7 @@ import { useCurrentLocationContext } from '-/hooks/useCurrentLocationContext';
import { useNotificationContext } from '-/hooks/useNotificationContext';
import { toFsEntry } from '-/services/utils-io';
import { usePlatformFacadeContext } from '-/hooks/usePlatformFacadeContext';
+import { SaveIcon, EditIcon } from '-/components/CommonIcons';
//const defaultSplitSize = '7.86%'; // '7.2%'; // 103;
// const bufferedSplitResize = buffer({
diff --git a/app/components/dialogs/NewAudioDialog.tsx b/app/components/dialogs/NewAudioDialog.tsx
index 0cfb5debe..b88b02472 100644
--- a/app/components/dialogs/NewAudioDialog.tsx
+++ b/app/components/dialogs/NewAudioDialog.tsx
@@ -25,7 +25,6 @@ import DraggablePaper from '-/components/DraggablePaper';
import DialogCloseButton from '-/components/dialogs/DialogCloseButton';
import { useTheme } from '@mui/material/styles';
import useMediaQuery from '@mui/material/useMediaQuery';
-import TargetPath from '-/components/dialogs/components/TargetPath';
import { TargetPathContextProvider } from '-/components/dialogs/hooks/TargetPathContextProvider';
import { useTranslation } from 'react-i18next';
import { Pro } from '-/pro';
@@ -55,7 +54,7 @@ function NewAudioDialog(props: Props) {
scroll="paper"
>
<DialogTitle style={{ cursor: 'move' }} id="draggable-dialog-title">
- {t('core:createAudio')}
+ {t('core:audioRecorder')}
<DialogCloseButton testId="closeCreateDialogTID" onClose={onClose} />
</DialogTitle>
<DialogContent
@@ -68,7 +67,6 @@ function NewAudioDialog(props: Props) {
data-tid="keyboardShortCutsDialog"
>
<CreateAudio onClose={onClose} />
- <TargetPath />
</DialogContent>
</Dialog>
</TargetPathContextProvider>
diff --git a/app/locales/en/core.json b/app/locales/en/core.json
index eee38f05f..2389be803 100644
--- a/app/locales/en/core.json
+++ b/app/locales/en/core.json
@@ -806,5 +806,11 @@
"details": "Details",
"editDisabled": "Editing the description is disabled while editing the current file",
"togglePreviewSize": "Toggle file preview size",
+ "newAudioRecording": "New Audio Recording",
+ "audioRecorder": "Audio Recorder",
+ "startRecording": "Start recording",
+ "pauseRecording": "Pause recording",
+ "resumeRecording": "Resume recording",
+ "stopRecording": "Stop recording",
"-": "-"
}
diff --git a/app/perspectives/common/DirectoryMenuItems.tsx b/app/perspectives/common/DirectoryMenuItems.tsx
index 6038239cb..f5114f7d2 100644
--- a/app/perspectives/common/DirectoryMenuItems.tsx
+++ b/app/perspectives/common/DirectoryMenuItems.tsx
@@ -1,6 +1,6 @@
+import React from 'react';
import MenuItem from '@mui/material/MenuItem';
import ListItemIcon from '@mui/material/ListItemIcon';
-import AudioFileIcon from '@mui/icons-material/AudioFile';
import OpenFolderIcon from '@mui/icons-material/SubdirectoryArrowLeft';
import MoveCopy from '@mui/icons-material/FileCopy';
import ListItemText from '@mui/material/ListItemText';
@@ -10,9 +10,6 @@ import AppConfig from '-/AppConfig';
import OpenFolderNativelyIcon from '@mui/icons-material/Launch';
import AddRemoveTags from '@mui/icons-material/Loyalty';
import Divider from '@mui/material/Divider';
-import NewFileIcon from '@mui/icons-material/InsertDriveFile';
-import NewFolderIcon from '@mui/icons-material/CreateNewFolder';
-import AddExistingFileIcon from '@mui/icons-material/ExitToApp';
import { Pro } from '-/pro';
import ImageIcon from '@mui/icons-material/Image';
import ImportTagsIcon from '@mui/icons-material/FindInPage';
@@ -23,9 +20,12 @@ import {
ReloadIcon,
OpenNewWindowIcon,
DeleteIcon,
- LinkIcon
+ LinkIcon,
+ AudioRecordIcon,
+ NewFileIcon,
+ NewFolderIcon,
+ AddExistingFileIcon
} from '-/components/CommonIcons';
-import React from 'react';
import { TS } from '-/tagspaces.namespace';
export function getDirectoryMenuItems(
@@ -223,9 +223,16 @@ export function getDirectoryMenuItems(
}}
>
<ListItemIcon>
- <AudioFileIcon />
+ <AudioRecordIcon />
</ListItemIcon>
- <ListItemText primary={t('core:newAudioFile')} />
+ <ListItemText
+ primary={
+ <>
+ {t('core:newAudioRecording')}
+ {Pro ? <BetaLabel /> : <ProLabel />}
+ </>
+ }
+ />
</MenuItem>
);
}
diff --git a/web/index.html b/web/index.html
index 5d5643a9d..83756063f 100644
--- a/web/index.html
+++ b/web/index.html
@@ -14,7 +14,7 @@
content="width=device-width,initial-scale=1,maximum-scale=1,minimum-scale=1,user-scalable=no"
/>
<meta name="theme-color" content="#1DD19F">
- <meta name="description" content="PWA for TagSpaces Pro">
+ <meta name="description" content="PWA for TagSpaces">
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
<meta name="mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-capable" content="yes">