-
Notifications
You must be signed in to change notification settings - Fork 54
feat(desktop-app): tauri setup #1160
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
base: master
Are you sure you want to change the base?
Conversation
✅ Deploy Preview for cyb-xp ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
❌ Deploy Preview for rebyc failed. Why did it fail? →
|
…wnload and signing flow fixes
… feat/tauri-app
| DB_STORE_NAME, | ||
| onIndexedDbWrite | ||
| ); | ||
| if (!process.env.IS_TAURI) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe this flag better rename to IS_DESKTOP?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe
| @@ -1,3 +1,4 @@ | |||
| /* eslint-disable import/prefer-default-export */ | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
better use this with next line not global
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
my counter-offer is to disable this rule completely, it's more headache then benefit
| memo?: string | undefined; | ||
| } | ||
|
|
||
| export class SignerModalHandler { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe it can be context better? to use OOP less with react
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if it would be context it would be also redux (what's the difference to be honest?!)
it's done that way to make it possible to use it outside the react scope (literally in CybSignerClient)
| declare global { | ||
| interface Window { | ||
| store: Store; | ||
| clipboardData?: DataTransfer; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
clipboardData needed to specify?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
check it's usage, it will be clear
| ArrayType extends readonly (infer ElementType)[] ? ElementType : never; | ||
| declare global { | ||
| interface Window { | ||
| store: Store; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
| import { requestWithRetry } from './request-with-retry'; | ||
|
|
||
| /* eslint-disable import/prefer-default-export */ | ||
| export const getTxsWithRetry = async (txs: string) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not being used
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| /* eslint-disable import/prefer-default-export */ | ||
| import axios, { AxiosError, AxiosRequestConfig, AxiosResponse } from 'axios'; | ||
|
|
||
| export const requestWithRetry = async ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
and this
|
|
||
| let navigate: NavigateFunction; | ||
|
|
||
| export const setNavigate = (nav: NavigateFunction) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not using
src/utils/utils.ts
Outdated
| accountsKeplr, | ||
| }; | ||
|
|
||
| export const getMnemonic = () => localStorage.getItem('cyb:mnemonic'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
localStorageKeys
| const CompressionWebpackPlugin = require('compression-webpack-plugin'); | ||
| const commonConfig = require('./webpack.config.common'); | ||
|
|
||
| module.exports = merge(commonConfig, { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can production config be reused/merged?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree that's possible
matter of time as lots of other things
src/components/modal/Modal.tsx
Outdated
| [style] | ||
| ); | ||
|
|
||
| return isOpen ? ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
better (!isOpen) {
return null
}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree on early return
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
need some small fixes, but core is ok
… feat/tauri-app
… feat/tauri-app
…ixed on start_ipfs
… feat/tauri-app

yarn tauri devto start development modeyarn tauri buildproduces APP bundle and DMG undersrc-tauri/target/releasefolder