Skip to content
This repository was archived by the owner on Nov 10, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
deb0ad8
Bump new onboard.js version
matextrem Aug 31, 2020
5d7369d
Merge with dev
matextrem Sep 1, 2020
3a5a2d0
Merge branch 'development' of github.com:gnosis/safe-react into devel…
matextrem Sep 18, 2020
f99a18c
Merge branch 'development' of github.com:gnosis/safe-react into devel…
matextrem Sep 24, 2020
f335b89
Merge branch 'development' of github.com:gnosis/safe-react into devel…
matextrem Sep 29, 2020
b1c53f8
Merge branch 'development' of github.com:gnosis/safe-react into devel…
matextrem Oct 28, 2020
97f3e52
Merge branch 'development' of github.com:gnosis/safe-react into devel…
matextrem Nov 2, 2020
79bf102
Merge branch 'development' of github.com:gnosis/safe-react into devel…
matextrem Nov 5, 2020
433fe9b
Merge branch 'development' of github.com:gnosis/safe-react into devel…
matextrem Nov 11, 2020
878c32c
Collectibles utils
matextrem Dec 9, 2020
89a80bd
Merge branch 'development' of github.com:gnosis/safe-react into devel…
matextrem Dec 9, 2020
71bdd43
Merge pull request #1720 from gnosis/release/v2.17.0
Dec 14, 2020
71375f9
Fix wrong status on txs
matextrem Dec 14, 2020
0814eb5
Merge branch 'development' of github.com:gnosis/safe-react into devel…
matextrem Dec 14, 2020
7c19205
(Feature) - Expanded decoded data collapses automatically (#1731)
Agupane Dec 15, 2020
94d9ee4
Merge branch 'development' into release/v2.17.0
Dec 16, 2020
f475808
Merge pull request #1733 from gnosis/release/v2.17.0
Dec 16, 2020
f143721
Fix typo in ADD_OR_UPDATE_SAFE reducer (#1735)
Dec 16, 2020
62232e6
Prevent modal from closing on its own
matextrem Dec 18, 2020
8946ebc
Merge branch 'development' of github.com:gnosis/safe-react into fix/m…
matextrem Dec 18, 2020
2af0fb0
Update index.tsx
matextrem Dec 18, 2020
283e62e
Merge branch 'development' of github.com:gnosis/safe-react into devel…
matextrem Dec 22, 2020
6ffb736
Allow sort for value column
matextrem Dec 22, 2020
5008ee4
Merge pull request #1738 from gnosis/fix/modal-close
matextrem Dec 22, 2020
d1cbc1a
Merge branch 'development' into fix/balance-table-sort
matextrem Dec 22, 2020
a00539e
Fix token price function to be more generic
matextrem Dec 28, 2020
6369d87
Merge branch 'fix/balance-table-sort' of github.com:gnosis/safe-react…
matextrem Dec 28, 2020
b7fb603
Merge pull request #1745 from gnosis/fix/balance-table-sort
matextrem Jan 5, 2021
186fb34
Bump node-notifier from 8.0.0 to 8.0.1 (#1741)
dependabot[bot] Jan 12, 2021
09b4701
Bump axios from 0.21.0 to 0.21.1 (#1754)
dependabot[bot] Jan 12, 2021
f1ffb5d
(Fix) - Remove safe fix (#1744)
Agupane Jan 12, 2021
31be5b1
Feature/#1499 add mobile start (#1750)
alongoni Jan 12, 2021
618888e
Upgrade dependencies (#1767)
Jan 12, 2021
8a774f2
(Feature) - #1048 Tx will fail warning (#1675)
Agupane Jan 13, 2021
10f1891
(Fix) - Calculates gas for SpendingLimit transactions (#1773)
Agupane Jan 14, 2021
4c45daa
Fix useTxData refactor
Agupane Jan 15, 2021
cdbe4df
Cleanup erc20 amount calcs
Jan 15, 2021
0fb1824
Fix asset value column alignment (#1778)
alongoni Jan 15, 2021
ce43a97
(Fix) - #1783 Trezor gas estimation fail (#1788)
Agupane Jan 18, 2021
0d0acac
Adds TransactionFees modal to confirm safe app tx modal (#1789)
Agupane Jan 18, 2021
f79f377
(Feature) Disable gas estimation for WalletConnect (#1790)
Agupane Jan 18, 2021
0e1efc6
Set v2.18.0
Jan 19, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 23 additions & 33 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "safe-react",
"version": "2.17.0",
"version": "2.18.0",
"description": "Allowing crypto users manage funds in a safer way",
"website": "https://github.com/gnosis/safe-react#readme",
"bugs": {
Expand Down Expand Up @@ -67,7 +67,7 @@
},
"productName": "Safe Multisig",
"build": {
"appId": "io.gnosis.safe.macos",
"appId": "io.gnosis.safe",
"afterSign": "scripts/notarize.js",
"extends": null,
"productName": "Safe Multisig",
Expand Down Expand Up @@ -95,19 +95,10 @@
]
},
"files": [
"**/*",
"!src${/*}",
"!config${/*}",
"!contracts${/*}",
"!migrations${/*}",
"!flow-typed${/*}",
"!apps${/*}",
"!out${/*}",
"!.editorconfig",
"!.gitignore",
"!README.md",
"!yarn-error.log",
"!yarn.lock"
"build/",
"public",
"scripts",
"package.json"
],
"directories": {
"buildResources": "public/build"
Expand All @@ -134,12 +125,12 @@
"deleteAppDataOnUninstall": true
},
"linux": {
"category": "Finance",
"target": [
"AppImage",
"deb",
"zip"
],
"icon": "./public/build/safe.png"
]
},
"win": {
"target": [
Expand All @@ -165,21 +156,21 @@
]
},
"dependencies": {
"@gnosis.pm/safe-apps-sdk": "1.0.0-beta.4",
"@gnosis.pm/safe-apps-sdk": "1.0.2",
"@gnosis.pm/safe-apps-sdk-v1": "npm:@gnosis.pm/safe-apps-sdk@0.4.2",
"@gnosis.pm/safe-contracts": "1.1.1-dev.2",
"@gnosis.pm/safe-react-components": "https://github.com/gnosis/safe-react-components.git#bf3a84486b7353bd25447ddff39c406f6fafecc6",
"@gnosis.pm/util-contracts": "2.0.6",
"@ledgerhq/hw-transport-node-hid-singleton": "5.34.0",
"@ledgerhq/hw-transport-node-hid-singleton": "5.36.0",
"@material-ui/core": "^4.11.0",
"@material-ui/icons": "4.9.1",
"@material-ui/icons": "^4.11.0",
"@material-ui/lab": "4.0.0-alpha.56",
"@openzeppelin/contracts": "3.1.0",
"@sentry/react": "^5.28.0",
"@sentry/tracing": "^5.28.0",
"@truffle/contract": "4.2.30",
"@truffle/contract": "^4.3.0",
"async-sema": "^3.1.0",
"axios": "0.21.0",
"axios": "0.21.1",
"bignumber.js": "9.0.1",
"bnc-onboard": "^1.16.1",
"classnames": "^2.2.6",
Expand All @@ -190,7 +181,7 @@
"date-fns": "2.16.1",
"detect-port": "^1.3.0",
"electron-is-dev": "^1.2.0",
"electron-log": "4.3.0",
"electron-log": "^4.3.0",
"electron-settings": "^4.0.2",
"electron-updater": "4.3.5",
"eth-sig-util": "^2.5.3",
Expand All @@ -208,9 +199,10 @@
"lodash.memoize": "^4.1.2",
"material-ui-search-bar": "^1.0.0",
"notistack": "https://github.com/gnosis/notistack.git#v0.9.4",
"qrcode.react": "1.0.0",
"query-string": "6.13.7",
"qrcode.react": "1.0.1",
"query-string": "6.13.8",
"react": "16.13.1",
"react-device-detect": "^1.15.0",
"react-dom": "16.13.1",
"react-final-form": "^6.5.2",
"react-final-form-listeners": "^1.0.2",
Expand All @@ -225,7 +217,7 @@
"redux-actions": "^2.6.5",
"redux-thunk": "^2.3.0",
"reselect": "^4.0.0",
"semver": "7.3.2",
"semver": "^7.3.2",
"styled-components": "^5.2.1",
"web3": "1.2.11",
"web3-core": "^1.2.11",
Expand All @@ -240,8 +232,8 @@
"@storybook/addons": "^5.3.19",
"@storybook/preset-create-react-app": "^3.1.5",
"@storybook/react": "^5.3.19",
"@testing-library/jest-dom": "5.11.6",
"@testing-library/react": "11.2.2",
"@testing-library/jest-dom": "^5.11.6",
"@testing-library/react": "^11.2.2",
"@typechain/web3-v1": "^2.0.0",
"@types/history": "4.6.2",
"@types/jest": "^26.0.16",
Expand All @@ -254,29 +246,27 @@
"@types/styled-components": "^5.1.4",
"@typescript-eslint/eslint-plugin": "^4.6.0",
"@typescript-eslint/parser": "^4.6.0",
"autoprefixer": "9.8.6",
"cross-env": "^7.0.3",
"dotenv": "^8.2.0",
"dotenv-expand": "^5.1.0",
"electron": "^9.3.5",
"electron-builder": "22.9.1",
"electron-notarize": "1.0.0",
"eslint": "^7.11.0",
"eslint-config-prettier": "^6.14.0",
"eslint-config-prettier": "^7.0.0",
"eslint-plugin-import": "^2.22.1",
"eslint-plugin-jsx-a11y": "^6.3.1",
"eslint-plugin-prettier": "^3.1.4",
"eslint-plugin-react": "^7.21.5",
"eslint-plugin-sort-destructure-keys": "^1.3.5",
"ethereumjs-abi": "0.6.8",
"husky": "^4.3.0",
"lint-staged": "^10.5.2",
"patch-package": "^6.2.2",
"postinstall-postinstall": "^2.1.0",
"prettier": "^2.2.0",
"sass": "^1.29.0",
"typechain": "^4.0.0",
"typescript": "4.0.5",
"wait-on": "5.2.0"
"typescript": "4.1.3",
"wait-on": "5.2.1"
}
}
2 changes: 1 addition & 1 deletion public/electron.js
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ function createWindow(port = DEFAULT_PORT) {
allowRunningInsecureContent: true,
nativeWindowOpen: true, // need to be set in order to display modal
},
icon: electron.nativeImage.createFromPath(path.join(__dirname, './build/safe.png')),
icon: electron.nativeImage.createFromPath(path.join(__dirname, '/public/build/safe.png')),
})

mainWindow.once('ready-to-show', () => {
Expand Down
6 changes: 3 additions & 3 deletions src/components/App/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import ErrorIcon from 'src/assets/icons/error.svg'
import InfoIcon from 'src/assets/icons/info.svg'

import AppLayout from 'src/components/AppLayout'
import SafeListSidebarProvider, { SafeListSidebarContext } from 'src/components/SafeListSidebar'
import { SafeListSidebar, SafeListSidebarContext } from 'src/components/SafeListSidebar'
import CookiesBanner from 'src/components/CookiesBanner'
import Notifier from 'src/components/Notifier'
import Backdrop from 'src/components/layout/Backdrop'
Expand Down Expand Up @@ -159,9 +159,9 @@ const App: React.FC = ({ children }) => {
}

const WrapperAppWithSidebar: React.FC = ({ children }) => (
<SafeListSidebarProvider>
<SafeListSidebar>
<App>{children}</App>
</SafeListSidebarProvider>
</SafeListSidebar>
)

export default WrapperAppWithSidebar
134 changes: 134 additions & 0 deletions src/components/AppLayout/MobileNotSupported/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,134 @@
import { Button, Text, Card, Icon } from '@gnosis.pm/safe-react-components'
import { fade } from '@material-ui/core/styles/colorManipulator'
import styled from 'styled-components'
import React, { ReactElement } from 'react'
import { MobileView } from 'react-device-detect'

import Phone from 'src/components/AppLayout/MobileStart/assets/phone@2x.png'

const Overlay = styled.div`
display: block;
position: absolute;
bottom: 0;
width: 100vw;
height: 100vh;
background-color: ${({ theme }) => fade(theme.colors.overlay.color, 0.75)};
z-index: 2147483009; /* on top of Intercom Button */
`

const ModalApp = styled.div`
position: fixed;
display: flex;
justify-content: space-between;
bottom: 0;
width: 100vw;
height: 260px;
background-color: ${({ theme }) => theme.colors.background};
box-shadow: 1px 2px 10px rgba(40, 54, 61, 0.18);
z-index: 2147483004; /* on top of Intercom Button */
padding: 20px 16px 0 16px;
`

const StyledCard = styled(Card)`
background-color: #fdfdfd;
/* width: 45vw; */
min-width: 245px;
height: 220px;
padding: 24px 58px 24px 24px;
box-sizing: border-box;
box-shadow: none;
display: flex;
justify-content: space-around;
flex-direction: column;

@media (max-width: 340px) {
padding: 16px;
min-width: 215px;
}
`
const StyledImg = styled.img`
margin: 24px -81px 0 -58px;
z-index: 1;
width: 45%;
height: auto;
object-fit: cover;

@media (max-width: 340px) {
display: none;
}

@media (min-width: 430px) {
width: 30%;
}

@media (min-width: 720px) {
width: 25%;
}

@media (min-width: 800px) {
width: 20%;
}
`

const StyledCloseIcon = styled(Icon)`
margin: 0 34px;
width: 24px;
height: 24px;
display: flex;
align-items: center;
justify-content: center;

&:hover {
background: ${({ theme }) => theme.colors.separator};
border-radius: 16px;
padding: 4px;
box-sizing: border-box;
}

@media (max-width: 340px) {
margin: 8px 34px 0 16px;
}
`
const StyledButton = styled(Button)`
background-color: transparent;
min-width: 0;

:hover {
background-color: transparent;
}
`

const StyledLink = styled.a`
text-decoration: none;
`

type Props = {
onClose: () => void
}

export const MobileNotSupported = ({ onClose }: Props): ReactElement => {
return (
<MobileView>
<Overlay>
<ModalApp>
<StyledCard>
<Text size="lg">The Safe Multisig web app is not optimized for mobile.</Text>
<Text size="lg">Get the mobile app for a better experience.</Text>
<Button size="md" color="primary" variant="contained">
<StyledLink target="_blank" href="https://gnosis-safe.io/#mobile" rel="noopener noreferrer">
<Text color="white" size="xl">
Get the App
</Text>
</StyledLink>
</Button>
</StyledCard>

<StyledImg src={Phone} alt="Phone" />
<StyledButton size="md" variant="outlined" color="primary" onClick={onClose}>
<StyledCloseIcon size="md" type="cross" />
</StyledButton>
</ModalApp>
</Overlay>
</MobileView>
)
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
61 changes: 35 additions & 26 deletions src/components/AppLayout/index.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import React from 'react'
import React, { useState } from 'react'
import styled from 'styled-components'
import { ListItemType } from 'src/components/List'

import Header from './Header'
import Footer from './Footer'
import Sidebar from './Sidebar'
import { MobileNotSupported } from './MobileNotSupported'

const Container = styled.div`
height: 100vh;
Expand Down Expand Up @@ -85,30 +86,38 @@ const Layout: React.FC<Props> = ({
onNewTransactionClick,
children,
sidebarItems,
}): React.ReactElement => (
<Container>
<HeaderWrapper>
<Header />
</HeaderWrapper>
<BodyWrapper>
<SidebarWrapper>
<Sidebar
items={sidebarItems}
safeAddress={safeAddress}
safeName={safeName}
balance={balance}
granted={granted}
onToggleSafeList={onToggleSafeList}
onReceiveClick={onReceiveClick}
onNewTransactionClick={onNewTransactionClick}
/>
</SidebarWrapper>
<ContentWrapper>
<div>{children}</div>
<Footer />
</ContentWrapper>
</BodyWrapper>
</Container>
)
}): React.ReactElement => {
const [mobileNotSupportedClosed, setMobileNotSupportedClosed] = useState(false)

const closeMobileNotSupported = () => setMobileNotSupportedClosed(true)

return (
<Container>
<HeaderWrapper>
<Header />
</HeaderWrapper>
<BodyWrapper>
<SidebarWrapper>
<Sidebar
items={sidebarItems}
safeAddress={safeAddress}
safeName={safeName}
balance={balance}
granted={granted}
onToggleSafeList={onToggleSafeList}
onReceiveClick={onReceiveClick}
onNewTransactionClick={onNewTransactionClick}
/>
</SidebarWrapper>
<ContentWrapper>
<div>{children}</div>
<Footer />
</ContentWrapper>
</BodyWrapper>

{!mobileNotSupportedClosed && <MobileNotSupported onClose={closeMobileNotSupported} />}
</Container>
)
}

export default Layout
Loading