diff --git a/web/cashtab/src/assets/styles/theme.js b/web/cashtab/src/assets/styles/theme.js --- a/web/cashtab/src/assets/styles/theme.js +++ b/web/cashtab/src/assets/styles/theme.js @@ -31,7 +31,7 @@ background: '#ffffff', color: '', boxShadow: - 'rgba(0, 0, 0, 0.01) 0px 0px 1px, rgba(0, 0, 0, 0.04) 0px 4px 8px,rgba(0, 0, 0, 0.04) 0px 16px 24px, rgba(0, 0, 0, 0.01) 0px 24px 32px', + 'rgb(136 172 243 / 25%) 0px 10px 30px,rgb(0 0 0 / 3%) 0px 1px 1px, rgb(0 51 167 / 10%) 0px 10px 20px', border: '#e9eaed', hoverBorder: '#231F20', }, @@ -57,7 +57,7 @@ copyBorderToken: '#FF21D0', background: '#fff', token: '#231F20', - shadow: 'rgba(0, 0, 0, 0.01) 0px 0px 1px, rgba(0, 0, 0, 0.04) 0px 4px 8px, rgba(0, 0, 0, 0.04) 0px 16px 24px, rgba(0, 0, 0, 0.01) 0px 24px 32px', + shadow: 'rgb(136 172 243 / 25%) 0px 10px 30px, rgb(0 0 0 / 3%) 0px 1px 1px, rgb(0 51 167 / 10%) 0px 10px 20px', }, buttons: { primary: { diff --git a/web/cashtab/src/components/App.js b/web/cashtab/src/components/App.js --- a/web/cashtab/src/components/App.js +++ b/web/cashtab/src/components/App.js @@ -81,14 +81,15 @@ const Footer = styled.div` z-index: 2; background-color: ${props => props.theme.footer.background}; - border-radius: 20px; + border-radius: 20px 20px 0 0; position: fixed; bottom: 0; width: 500px; + box-shadow: rgb(136 172 243 / 25%) 0px 10px 30px, + rgb(0 0 0 / 3%) 0px 1px 1px, rgb(0 51 167 / 10%) 0px 10px 20px; @media (max-width: 768px) { width: 100%; } - border-top: 1px solid ${props => props.theme.wallet.borders.color}; `; export const NavButton = styled.button` @@ -164,7 +165,6 @@ padding: 20px 0 30px; margin-bottom: 20px; justify-content: space-between; - border-bottom: 1px solid ${props => props.theme.wallet.borders.color}; a { color: ${props => props.theme.wallet.text.secondary}; diff --git a/web/cashtab/src/components/Common/QRCode.js b/web/cashtab/src/components/Common/QRCode.js --- a/web/cashtab/src/components/Common/QRCode.js +++ b/web/cashtab/src/components/Common/QRCode.js @@ -12,11 +12,10 @@ export const StyledRawQRCode = styled(RawQRCode)` cursor: pointer; - border-radius: 23px; + border-radius: 26px; background: ${props => props.theme.qr.background}; box-shadow: ${props => props.theme.qr.shadow}; margin-bottom: 10px; - border: 1px solid ${props => props.theme.wallet.borders.color}; path:first-child { fill: ${props => props.theme.qr.background}; } diff --git a/web/cashtab/src/components/Common/StyledCollapse.js b/web/cashtab/src/components/Common/StyledCollapse.js --- a/web/cashtab/src/components/Common/StyledCollapse.js +++ b/web/cashtab/src/components/Common/StyledCollapse.js @@ -51,3 +51,36 @@ } `} `; + +export const AdvancedCollapse = styled(Collapse)` + ${({ disabled = false, ...props }) => + disabled === true + ? ` + background: ${props.theme.buttons.secondary.background} !important; + .ant-collapse-header { + font-size: 18px; + font-weight: normal; + color: ${props.theme.buttons.secondary.color} !important; + svg { + color: ${props.theme.buttons.secondary.color} !important; + } + } + .ant-collapse-arrow { + font-size: 18px; + } + ` + : ` + background: ${props.theme.primary} !important; + .ant-collapse-header { + font-size: 18px; + font-weight: bold; + color: ${props.theme.contrast} !important; + svg { + color: ${props.theme.contrast} !important; + } + } + .ant-collapse-arrow { + font-size: 18px; + } + `} +`; diff --git a/web/cashtab/src/components/Configure/__tests__/__snapshots__/Configure.test.js.snap b/web/cashtab/src/components/Configure/__tests__/__snapshots__/Configure.test.js.snap --- a/web/cashtab/src/components/Configure/__tests__/__snapshots__/Configure.test.js.snap +++ b/web/cashtab/src/components/Configure/__tests__/__snapshots__/Configure.test.js.snap @@ -2,7 +2,7 @@ exports[`Configure with a wallet 1`] = `

@@ -342,7 +393,7 @@ exports[`Wallet with BCH balances and tokens 1`] = ` Array [
You currently have 0 XEC @@ -369,7 +420,7 @@ } >
= $ NaN USD
+
+
+
+
+ + + + Advanced +
+
+
+
@@ -681,14 +783,14 @@ exports[`Wallet with BCH balances and tokens and state field 1`] = ` Array [
0.06 XEC
,
$ NaN @@ -715,7 +817,7 @@ } >
= $ NaN USD
+
+
+
+
+ + + + Advanced +
+
+
+
@@ -1367,7 +1571,7 @@ exports[`Without wallet defined 1`] = ` Array [
You currently have 0 XEC @@ -1394,7 +1598,7 @@ } >
= $ NaN USD
+
+
+
+
+ + + + Advanced +
+
+
+
diff --git a/web/cashtab/src/components/Tokens/__tests__/__snapshots__/Tokens.test.js.snap b/web/cashtab/src/components/Tokens/__tests__/__snapshots__/Tokens.test.js.snap --- a/web/cashtab/src/components/Tokens/__tests__/__snapshots__/Tokens.test.js.snap +++ b/web/cashtab/src/components/Tokens/__tests__/__snapshots__/Tokens.test.js.snap @@ -3,14 +3,14 @@ exports[`Wallet with BCH balances 1`] = ` Array [
You need some XEC in your wallet to create tokens.
,
0 @@ -60,7 +60,7 @@
,

You need at least @@ -83,14 +83,14 @@ exports[`Wallet with BCH balances and tokens 1`] = ` Array [

You need some XEC in your wallet to create tokens.
,
0 @@ -140,7 +140,7 @@
,

You need at least @@ -163,14 +163,14 @@ exports[`Wallet with BCH balances and tokens and state field 1`] = ` Array [

0.06 XEC
,
$ NaN @@ -226,10 +226,10 @@ onClick={[Function]} >
identicon of tokenId bd1acc4c986de57af8d6d2a64aecad8c30ee80f37ae9d066d758923732ddc9ba
6.001 @@ -261,14 +261,14 @@ exports[`Wallet without BCH balance 1`] = ` Array [
You need some XEC in your wallet to create tokens.
,
0 @@ -318,7 +318,7 @@
,

You need at least @@ -341,14 +341,14 @@ exports[`Without wallet defined 1`] = ` Array [

You need some XEC in your wallet to create tokens.
,
0 @@ -398,7 +398,7 @@
,

You need at least diff --git a/web/cashtab/src/components/Wallet/TokenListItem.js b/web/cashtab/src/components/Wallet/TokenListItem.js --- a/web/cashtab/src/components/Wallet/TokenListItem.js +++ b/web/cashtab/src/components/Wallet/TokenListItem.js @@ -19,14 +19,17 @@ justify-content: space-between; align-items: center; padding: 15px 25px; - border-radius: 3px; + border-radius: 16px; background: ${props => props.theme.tokenListItem.background}; - margin-bottom: 3px; + margin-bottom: 10px; box-shadow: ${props => props.theme.tokenListItem.boxShadow}; border: 1px solid ${props => props.theme.tokenListItem.border}; :hover { - border-color: ${props => props.theme.tokenListItem.hoverBorder}; + transform: translateY(-2px); + box-shadow: rgb(136 172 243 / 25%) 0px 10px 30px, + rgb(0 0 0 / 3%) 0px 1px 1px, rgb(0 51 167 / 10%) 0px 10px 20px; + transition: all 0.8s cubic-bezier(0.075, 0.82, 0.165, 1) 0s; } `; diff --git a/web/cashtab/src/components/Wallet/Tx.js b/web/cashtab/src/components/Wallet/Tx.js --- a/web/cashtab/src/components/Wallet/Tx.js +++ b/web/cashtab/src/components/Wallet/Tx.js @@ -131,14 +131,16 @@ justify-content: space-between; align-items: center; padding: 15px 25px; - border-radius: 3px; + border-radius: 16px; background: ${props => props.theme.tokenListItem.background}; - margin-bottom: 3px; + margin-bottom: 12px; box-shadow: ${props => props.theme.tokenListItem.boxShadow}; - border: 1px solid ${props => props.theme.tokenListItem.border}; :hover { - border-color: ${props => props.theme.primary}; + transform: translateY(-2px); + box-shadow: rgb(136 172 243 / 25%) 0px 10px 30px, + rgb(0 0 0 / 3%) 0px 1px 1px, rgb(0 51 167 / 10%) 0px 10px 20px; + transition: all 0.8s cubic-bezier(0.075, 0.82, 0.165, 1) 0s; } @media screen and (max-width: 500px) { grid-template-columns: 24px 30% 50%; diff --git a/web/cashtab/src/components/Wallet/__tests__/__snapshots__/Wallet.test.js.snap b/web/cashtab/src/components/Wallet/__tests__/__snapshots__/Wallet.test.js.snap --- a/web/cashtab/src/components/Wallet/__tests__/__snapshots__/Wallet.test.js.snap +++ b/web/cashtab/src/components/Wallet/__tests__/__snapshots__/Wallet.test.js.snap @@ -66,7 +66,7 @@

{ try { if (!sendAmount) { @@ -904,6 +906,23 @@ ); throw error; } + + // Start of building the OP_RETURN output. + // only build the OP_RETURN output if the user supplied it + if ( + typeof optionalOpReturnMsg !== 'undefined' && + optionalOpReturnMsg.trim() !== '' + ) { + const script = [ + BCH.Script.opcodes.OP_RETURN, + Buffer.from('6d02', 'hex'), + Buffer.from(optionalOpReturnMsg), + ]; + const data = BCH.Script.encode(script); + transactionBuilder.addOutput(data, 0); + } + // End of building the OP_RETURN output. + let originalAmount = new BigNumber(0); let txFee = 0; for (let i = 0; i < utxos.length; i++) {