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

chore: changes from dev into main #183

Merged
merged 24 commits into from
May 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
81c8ceb
chore: update ci to support dev branch
mpetrunic Feb 21, 2024
c0fe09d
feat: wallet account selector for substrate (#106)
Lykhoyda Mar 4, 2024
f3244c4
feat: Retry loading bridge routes (#136)
saadahmsiddiqui Mar 8, 2024
370882b
fix: typesafety when handling changed properties (#141)
mpetrunic Mar 13, 2024
13235bb
feat: Display Fee (#145)
saadahmsiddiqui Mar 27, 2024
46cb4ea
chore: Merge main into dev (#149)
Lykhoyda Apr 4, 2024
d285f95
feat: enable user to specify wallets (#161)
saadahmsiddiqui Apr 11, 2024
a3741d1
feat: substrate fungible transfer (#134)
wainola Apr 11, 2024
2b3276a
chore: optimize eslint (#165)
mpetrunic Apr 11, 2024
044797e
chore: bring changes from main to dev (#173)
wainola Apr 16, 2024
1fc3b22
feat: automatically add unknown source evm network into wallet (#162)
wainola Apr 16, 2024
21ceb18
feat: display amount to be received on destination (#168)
wainola Apr 18, 2024
7114f62
feat: display transfer gas cost estimation (#174)
saadahmsiddiqui Apr 22, 2024
ce7d774
chore: merge main with dev
wainola Apr 23, 2024
038eddb
Merge branch 'main' into chore/dev-into-main
mpetrunic Apr 23, 2024
f7d4a35
chore: pr review
wainola Apr 24, 2024
145dfb9
chore: restoring comment and adjusting property
wainola Apr 24, 2024
8f750e7
chore: removing duplicated
wainola Apr 24, 2024
34a203d
chore: changing place for if for consistency
wainola Apr 24, 2024
3114cad
chore: remove another duplicate
wainola Apr 24, 2024
3d9a527
chore: removing unnecesary retry since we do init in the line below
wainola Apr 24, 2024
075f2c5
chore: restoring function call
wainola Apr 24, 2024
cc60afc
chore: restoring if clause
wainola Apr 29, 2024
18227c8
chore: removing duplicate if clause
wainola Apr 30, 2024
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
3 changes: 3 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,8 @@
"project": ["'./packages/*/tsconfig.json'", "'./examples/*/tsconfig.json'"],
"ecmaVersion": 2020,
"sourceType": "module"
},
"rules": {
"import/no-cycle": ["error", {"ignoreExternal": true }]
}
}
4 changes: 1 addition & 3 deletions .github/workflows/cf-deploy-react.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,8 @@ on:
push:
branches:
- main
- dev
pull_request:
branches:
- main

jobs:
deploy:
Expand Down Expand Up @@ -33,5 +32,4 @@ jobs:
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
projectName: sygma-react-widget
directory: ./examples/react-widget-app/dist
branch: main
gitHubToken: ${{ secrets.GITHUB_TOKEN }}
4 changes: 1 addition & 3 deletions .github/workflows/cf-deploy-widget.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,8 @@ on:
push:
branches:
- main
- dev
pull_request:
branches:
- main

jobs:
deploy:
Expand Down Expand Up @@ -33,5 +32,4 @@ jobs:
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
projectName: sygma-widget
directory: ./packages/widget/dist
branch: main
gitHubToken: ${{ secrets.GITHUB_TOKEN }}
3 changes: 2 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ name: "ci / test"
on:
push:
branches:
- main # runs on push to master, add more branches if you use them
- main
- dev
pull_request:
branches:
- '**' # runs on update to pull request on any branch
Expand Down
157 changes: 157 additions & 0 deletions packages/widget/src/assets/icons/identicon.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,157 @@
import { html } from 'lit';

const identicon = html`
<svg
part="identicon"
width="49"
height="50"
viewBox="0 0 49 50"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<circle
cx="24.3483"
cy="24.3483"
r="23.9285"
transform="matrix(-1 0 0 1 48.9502 0.469238)"
fill="white"
stroke="#CBCBCB"
stroke-width="0.839598"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 28.0591 5.50659)"
fill="#95A6FF"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 35.043 9.61597)"
fill="#3B0D75"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 42.2329 13.7244)"
fill="#00FFE0"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 13.8838 13.7244)"
fill="#3F8AC0"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 21.0737 9.61597)"
fill="#D900EC"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 28.0591 13.5188)"
fill="#3F8AC0"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 35.043 17.6274)"
fill="#FF1593"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 42.2329 21.7358)"
fill="#95A6FF"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 13.8838 21.7358)"
fill="#95A6FF"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 21.0737 17.6274)"
fill="#3B0D75"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 28.0591 21.5303)"
fill="#00FFE0"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 35.043 25.6396)"
fill="#D900EC"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 42.2329 29.748)"
fill="#3B0D75"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 13.8838 29.748)"
fill="#3B0D75"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 21.0737 25.6396)"
fill="#FF1593"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 28.0591 29.543)"
fill="#FF1593"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 35.043 33.6511)"
fill="#95A6FF"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 21.0737 33.6511)"
fill="#95A6FF"
/>
<circle
cx="3.28694"
cy="3.28694"
r="3.28694"
transform="matrix(-1 0 0 1 28.0591 37.5547)"
fill="#3F8AC0"
/>
</svg>
`;

export default identicon;
8 changes: 7 additions & 1 deletion packages/widget/src/assets/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ import phalaNetworkIcon from './icons/phalaNetworkIcon';
import polygonNetworkIcon from './icons/polygonNetworkIcon';
import switchNetworkIcon from './icons/switchNetwork';
import sygmaLogo from './icons/sygmaLogo';
import identicon from './icons/identicon';
import plusIcon from './icons/plusIcon';
import greenCircleIcon from './icons/greenCircleIcon';

export const networkIconsMap = {
ethereum: ethereumIcon,
Expand All @@ -37,5 +40,8 @@ export {
noNetworkIcon,
chevronIcon,
greenMark,
loaderIcon
loaderIcon,
identicon,
plusIcon,
greenCircleIcon
};
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ export class AddressInput extends BaseComponent {
}

this.errorMessage = validateAddress(trimedValue, this.networkType);

this.onAddressChange(trimedValue);
};

Expand Down
2 changes: 2 additions & 0 deletions packages/widget/src/components/address-input/styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ export const styles = css`
flex-direction: column;
justify-content: center;
gap: 0.5rem;
margin-top: 1rem;
min-height: 7.75rem; // TOO: remove this hardcoded value
}

Expand Down Expand Up @@ -47,5 +48,6 @@ export const styles = css`
display: flex;
flex-direction: row;
justify-content: space-between;
margin-bottom: 0.25rem;
}
`;
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,7 @@ export const connectWalletStyles = css`
align-items: center;
}

.walletAddress,
.connectWalletButton {
.walletAddress {
font-size: 0.875rem;
font-weight: 500;
color: var(--zinc-700);
Expand All @@ -26,14 +25,25 @@ export const connectWalletStyles = css`
}

.connectWalletButton {
padding: 0.375rem 0.5rem;
display: flex;
align-items: center;
padding: 0.38rem 0.75rem;
border-radius: 2.5rem;
background-color: var(--zinc-100);
border: 1px solid var(--gray-100);
background: var(--zinc-800);
color: var(--zinc-200);
font-size: 0.875rem;
font-weight: 500;
outline: none;
border: none;
cursor: pointer;
}
transition: filter 0.3s ease;

&:hover {
filter: brightness(120%);
}

.connectWalletButton:hover {
background-image: linear-gradient(rgb(0 0 0/3%) 0 0);
svg {
margin-right: 0.5rem;
}
}
`;
Loading
Loading