-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
8c1ffeb
commit d416e3e
Showing
244 changed files
with
10,028 additions
and
16,052 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
name: Deploy 'every.near' App Components to Mainnet | ||
|
||
on: | ||
push: | ||
branches: [main] | ||
|
||
jobs: | ||
deploy-mainnet: | ||
uses: nearbuilders/bos-workspace/.github/workflows/deploy.yml@main | ||
with: | ||
bw-legacy: false | ||
deploy-env: "mainnet" | ||
app-name: "core" | ||
deploy-account-address: every.near | ||
signer-account-address: every.near | ||
signer-public-key: | ||
secrets: | ||
SIGNER_PRIVATE_KEY: ${{ secrets.EVERY_CORE_SIGNER_PRIVATE_KEY_MAINNET }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
name: Deploy 'every.near' App Components to Testnet | ||
|
||
on: | ||
push: | ||
branches: [develop] | ||
|
||
jobs: | ||
deploy-mainnet: | ||
uses: nearbuilders/bos-workspace/.github/workflows/deploy.yml@main | ||
with: | ||
bw-legacy: false | ||
deploy-env: "testnet" | ||
app-name: "core" | ||
deploy-account-address: allthethings.testnet | ||
signer-account-address: allthethings.testnet | ||
signer-public-key: | ||
secrets: | ||
SIGNER_PRIVATE_KEY: ${{ secrets.EVERY_CORE_SIGNER_PRIVATE_KEY_TESTNET }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
name: Deploy 'every.video.near' App Components to Mainnet | ||
|
||
on: | ||
push: | ||
branches: [main] | ||
|
||
jobs: | ||
deploy-mainnet: | ||
uses: nearbuilders/bos-workspace/.github/workflows/deploy.yml@main | ||
with: | ||
bw-legacy: false | ||
deploy-env: "mainnet" | ||
app-name: "video" | ||
deploy-account-address: video.every.near | ||
signer-account-address: video.every.near | ||
signer-public-key: ed25519:4u1tcYqemMsr84btLphGq5wnUKgPSGgTH1ft8tFPhozB | ||
secrets: | ||
SIGNER_PRIVATE_KEY: ${{ secrets.EVERY_VIDEO_SIGNER_PRIVATE_KEY_MAINNET }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
name: Deploy 'every.video.near' App Components to Testnet | ||
|
||
on: | ||
push: | ||
branches: [main] | ||
|
||
jobs: | ||
deploy-mainnet: | ||
uses: nearbuilders/bos-workspace/.github/workflows/deploy.yml@main | ||
with: | ||
bw-legacy: false | ||
deploy-env: "testnet" | ||
app-name: "video" | ||
deploy-account-address: video.allthethings.testnet | ||
signer-account-address: video.allthethings.testnet | ||
signer-public-key: | ||
secrets: | ||
SIGNER_PRIVATE_KEY: ${{ secrets.EVERY_VIDEO_SIGNER_PRIVATE_KEY_TESTNET }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,9 @@ | ||
node_modules | ||
.vscode | ||
.DS_Store | ||
/node_modules | ||
/build | ||
|
||
/build | ||
/dist | ||
tree.json | ||
|
||
test-results |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
node_modules/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"printWidth": 100, | ||
"tabWidth": 2, | ||
"singleQuote": false, | ||
"trailingComma": "es5", | ||
"semi": true | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,15 @@ | ||
# sdks.near | ||
# every.near | ||
|
||
## Setup & Development | ||
## Getting started | ||
|
||
Install packages: | ||
1. Install packages | ||
|
||
```cmd | ||
yarn | ||
yarn install | ||
``` | ||
|
||
Start development version: | ||
2. Start dev environment | ||
|
||
```cmd | ||
yarn dev | ||
``` | ||
|
||
This will start both a local gateway (http://127.0.0.1:4040) and http server for loading your local components. | ||
|
||
Optionally, to open local widgets in existing, supported gateways: | ||
|
||
1. Visit either of the following sites: | ||
|
||
- https://near.org/flags | ||
- https://everything.dev/flags | ||
|
||
2. Paste the Bos Loader Http URL (http://127.0.0.1:4040/api/loader) | ||
yarn run dev | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"mob": "mob.near", | ||
"near": "near" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"mob": "mike.testnet", | ||
"near": "discom.testnet" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
{ | ||
"account": "every.near", | ||
"aliases": ["../../aliases.mainnet.json"], | ||
"overrides": { | ||
"testnet": { | ||
"account": "allthethings.testnet", | ||
"aliases": ["../../aliases.testnet.json"] | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"every.near": {} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
const { Avatar } = VM.require("${config_account}/widget/components.ui.avatar"); | ||
const { AvatarGroup } = VM.require("${config_account}/widget/components.ui.avatar-group"); | ||
const { Badge } = VM.require("${config_account}/widget/components.ui.badge"); | ||
const { Button } = VM.require("${config_account}/widget/components.ui.button"); | ||
const { Chip } = VM.require("${config_account}/widget/components.ui.chip"); | ||
const { Container } = VM.require("${config_account}/widget/components.ui.container"); | ||
const { Logo } = VM.require("${config_account}/widget/components.ui.logo"); | ||
const { Tag } = VM.require("${config_account}/widget/components.ui.tag"); | ||
return { | ||
Avatar, | ||
AvatarGroup, | ||
Badge, | ||
Button, | ||
Chip, | ||
Container, | ||
Logo, | ||
Tag, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
const { Chip } = VM.require("${config_account}/widget/components") || { | ||
Chip: () => <></>, | ||
}; | ||
|
||
const items = props.items ?? []; | ||
const onSelect = props.onSelect ?? (() => {}); | ||
|
||
const [selectedItems, setSelectedItems] = useState([]); | ||
|
||
const handleClick = (item) => { | ||
if (props.multiple) { | ||
if (!selectedItems.includes(item)) { | ||
setSelectedItems((prev) => [...prev, item]); | ||
} else if (selectedItems.includes(item)) { | ||
setSelectedItems((prev) => prev.filter((i) => i !== item)); | ||
} | ||
} else { | ||
if (selectedItems !== item) { | ||
setSelectedItems(item); | ||
} else if (selectedItems === item) { | ||
setSelectedItems(null); | ||
} | ||
} | ||
}; | ||
|
||
useEffect(() => { | ||
onSelect(selectedItems); | ||
}, [selectedItems, onSelect]); | ||
|
||
if (items.length === 0) { | ||
return <div>No items passed</div>; | ||
} | ||
|
||
const duplicates = items.filter((item, index) => items.indexOf(item) !== index); | ||
if (duplicates.length > 0) { | ||
return <div>Duplicate Items Found</div>; | ||
} | ||
|
||
return ( | ||
<div className="d-flex align-items-center gap-2 flex-wrap"> | ||
{items.map((item) => ( | ||
<Chip | ||
key={item} | ||
selected={props.multiple ? selectedItems.includes(item) : selectedItems === item} | ||
onClick={() => handleClick(item)} | ||
size={props.size} | ||
multiple={props.multiple} | ||
> | ||
{item} | ||
</Chip> | ||
))} | ||
</div> | ||
); |
Oops, something went wrong.