Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add capacitor #3

Open
wants to merge 15 commits into
base: master
Choose a base branch
from

Conversation

jaredgalanis
Copy link
Contributor

@jaredgalanis jaredgalanis commented Jul 1, 2020

  • adds capacitor and required plugins to get a mobile version of the app working
  • TODOs:
  • styling fixes on mobile
  • remove extraneous plugins
  • provide attribution for base64Decoder
  • do files need to be cleaned up in the local filesystem (no they are stored in a tmp dir which gets cleaned up)

Screen Shot 2020-07-01 at 5 01 23 PM

let result = await VoiceRecorder.stopRecording();
let byteArray = Base64Binary.decodeArrayBuffer(result.value.recordDataBase64);

this.args.uploadAudioVideo(byteArray);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jaredgalanis shouldn't this match the format from before where it's an object with blob as the key? this.args.uploadAudioVideo({ blob: e.data });

I think if we pass the same data format, we can ensure that it should draw the same.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So I tried passing instantiating a Blob with the ArrayBuffer that we get out of converting the base64 string with this in mind, but it didn't work unfortunately.

@@ -5,7 +5,7 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Wuf</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="viewport" content="width=device-width, initial-scale=1, viewport-fit=cover">
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What does this do? I haven't used it before.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is part of what allows the app to respect the safeareas of the notch in an iPhone X or 11.

- file upload was broken by a previous commit, need to pull the blob off a data object since that's what the file input provides
- remove stray import to fix test
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants