From 2553714128f7ae6f6348523ffe9cf54f71c6b88f Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Tue, 16 Jul 2024 10:39:18 -0400 Subject: [PATCH] weekly promotion of develop to main (#473) * Fixes git history (#429) (#430) * Landing page (#290) * Add new landing page * Use new landing page --------- * Ft: New `buildhub` app (#303) * renamed new folder to `buildhub` * added github job * added mainnet job * prettier update * set new and old --------- * Fix: builddao.testnet public key * small change to trigger build * small change to trigger build * fix: gateway reference in testnet * Fix notification issues (#304) * Fix notifications count not resetting * Supress console.logs * Fix black background on notifications page * Revert changes to post and comment * Remove console logs and navbar from viewer for now * Remove white bg * Added commit modal bypass for all (#313) * Added commit modal bypass for all * Removed injectedConfig * clean features * changelog --------- * App.js formatting fix * Fix: Propose UI stuck partway through process (#302) * Bug Fix 244 * "cleanup" * New modal design implementation * new-changes * refactored code * resolved comments * latest-changes * Initialize with essential routes (#312) * Initialize with essential routes * Move home to /page * Add navbar * Add footer to all pages * Fix fmt? * fix links --------- * Test button Fix (#315) * test-btn-fix * toggle gateway urls * New changes in design implemented * Network button implementation * rename vertical * fix codeowners * Projects feed new (#319) * Sidebar * Initialize Projects page * Add CSS file * Align projects page with new design * Rename to kebab case * Align card design with new figma * Add List view * 100vh height * New projects feed updates & organization (#320) * reorganizing * formatting * adds label * Shift to pascal case * Add state for projects view * Rename folder structure * Fix links * Resolve comments --------- * fix-network-links (#323) * Resource page new (#325) * Resources Page V0 * Resources Page V0 cleanup * Header Removed * Remaining Projects Routes (#328) * Project Routes * Refactor StarProjects * Use star app logic for handling starring projects * Resolve comments * Project-new (#329) * Remove "Error" from project-data helper * Added route to index page for Project * Created layout * Added this to store entire project details with it's layout * Added changes to index file * Added overview * Added Metadata * Added activity and updated links * Updated link to project details * Used recent falbackUrl * Added new fallbackUrl * Updated links back to "projects" * Added the rest of the pages and retructured project component * Rearranged folder structure * renamed routes to meet * Prettier * Fixed link to Metadata * Navigation new (#331) * Move navbar to new app and fix default route for sidebar * Navbar changes to adapt to new style * Revert some changes for now * Add activity page * Notifications Page (#336) * Notifications Page * Notifications Items fix * Comments Resolved * Tests for Login and Logout (#333) * test-btn-fix * toggle gateway urls * New changes in design implemented * Network button implementation * Login and Logout tests * Resource page new (#335) * Resources Page V0 * Resources Page V0 cleanup * Header Removed * Adding new resources * Move activity to new app pattern (#337) * Move create project to separate page, edit support and refactoring (#321) * moved create project to page, added roles and edit support * show success modal after project is created * fmt * rebased and added reusable view container * bug fixes * add logs * css update * update login container css * Fixed task editor and minor UI updates (#339) * fixed task editor * remove logs * fmt * Fix projects visibility on testnet (#342) * Fix projects visibility * fmt * Convert starredProjects to star (#346) * convert starredProjects to star * notify account * fmt --------- * sets new index (#344) * yarn.lock * update bos-workspace * downgrade to .20 * latest * bos-workspace no bos-cli * Add feed to project page (#356) * Add feed to project page * Change editor * resolve comments * Resolve comment * use config_index --------- * Fix search in projects (#359) * Project creation form fixes (#360) * Add indicators for required fields * Add prefix to inputfield * Align typeahead with our input field style * Resolve commits * Fix projects bugs (#364) * fix tags structure * added border and error state * add border to list card * add autocomplete to projects * fmt --------- * Add form bounty template * Image uploader module (#361) * test-btn-fix * toggle gateway urls * New changes in design implemented * Network button implementation * Login and Logout tests * Image Uploader module * Implemented Files component * run prettier format on commit (#369) * Responsiveness and Adding Missing Pages (#365) * Landing Page Update 3.0 * Responsiveness * Add Inspect and Profile Page to new app * Comments Resolved * update yarn * Fix red flashes, init to [] rather than {} and hide open roles (#370) * fix red flashes, init to [] rather than {} and hide open roles * fix formatting * Fix red flash (#371) * fix red flashes, init to [] rather than {} and hide open roles * fix formatting * default empty array * Move proposals related files and fix notification roles selector (#377) * move proposals related files * minor fixes * fix pre-commit command * Fixes authentication tests (#381) * remove Dummy * cleans up auth tests * fmt * Refactors Project Card (#382) * remove Dummy * cleans up auth tests * fmt * tests to validate navigation * combines and replaces two cards * fmt * Landing Page Refactor (#383) * Landing Page Update 4.0 * URL Update * fix links * fmt --------- * Upgrade the gateway to new app and some fixes (#386) * Upgrade the gateway to new app and some fixes * Fix project card * fmt * Update release-new-mainnet.yml * Login/Logout Page Update / Profile.Index Update (#389) * Landing Page Update 4.0 * URL Update * Login Logout Page Design Update * fix conflict * fix links for signin, signout --------- * fix landing page links (#394) * Defaults fallback for Object.keys (fix red flash on projects page) (#396) * increment * adds fallbacks * fmt * Ft: Project quick view (#388) * added canvas * add UI * css update * fix tests and add mobile responsiveness * fix potlock search (#397) * added changelog * Fix project creation w/ tests (#402) * init tests * fmt * rename test * fmt * clean test * formatting * working as-is test * fmt * fix upload image * fmt * complete editor tests * projects tests * fmt * remove unused * Add resources tests (#425) * Add resources tests * Resolve comments * Delete project (#417) * added delete project * Fix project creation w/ tests (#402) * init tests * fmt * rename test * fmt * clean test * formatting * working as-is test * fmt * fix upload image * fmt * complete editor tests * projects tests * fmt * remove unused * added delete project * added delete project test * add edit project test * fix tests * added delete project test * add edit project test * fix tests --------- * Landing page regression tests (#416) * test-btn-fix * toggle gateway urls * New changes in design implemented * Network button implementation * Login and Logout tests * Image Uploader module * Implemented Files component * lp-reg-tests * start project and explore projects changes in redirection * added the assertion for login and changed the structure * added wait * connect-btn-test-fix * added wait for create project title --------- * fix transfer proposal (#427) * Navbar reg tests (#424) * test-btn-fix * toggle gateway urls * New changes in design implemented * Network button implementation * Login and Logout tests * Image Uploader module * Implemented Files component * lp-reg-tests * start project and explore projects changes in redirection * added the assertion for login and changed the structure * added wait * connect-btn-test-fix * added wait for create project title * navbar-reg-tests * added page visiblity assertions * fixed source btn locator --------- * Fix overflow activity feed (#420) * Fix overflow activity feed * Sidebar style update * Move fix to CSS * increment version --------- Co-authored-by: Muhammad Saad Iqbal Co-authored-by: Zeeshan Ahmad Co-authored-by: Megha-Dev-19 <100185149+Megha-Dev-19@users.noreply.github.com> Co-authored-by: Jiku Godwill Nsanwi <65053264+Jikugodwill@users.noreply.github.com> Co-authored-by: Marpureddy Saswat <91129111+Eren-Yeaager@users.noreply.github.com> Co-authored-by: heroes-bounty[bot] <167169790+heroes-bounty[bot]@users.noreply.github.com> * Fixes git history (#429) * Landing page (#290) * Add new landing page * Use new landing page --------- Co-authored-by: Zeeshan Ahmad * Ft: New `buildhub` app (#303) * renamed new folder to `buildhub` * added github job * added mainnet job * prettier update * set new and old --------- Co-authored-by: Elliot Braem <16282460+elliotBraem@users.noreply.github.com> * Fix: builddao.testnet public key * small change to trigger build * small change to trigger build * fix: gateway reference in testnet * Fix notification issues (#304) * Fix notifications count not resetting * Supress console.logs * Fix black background on notifications page * Revert changes to post and comment * Remove console logs and navbar from viewer for now * Remove white bg * Added commit modal bypass for all (#313) * Added commit modal bypass for all * Removed injectedConfig * clean features * changelog --------- Co-authored-by: Elliot Braem <16282460+elliotBraem@users.noreply.github.com> * App.js formatting fix * Fix: Propose UI stuck partway through process (#302) * Bug Fix 244 * "cleanup" * New modal design implementation * new-changes * refactored code * resolved comments * latest-changes * Initialize with essential routes (#312) * Initialize with essential routes * Move home to /page * Add navbar * Add footer to all pages * Fix fmt? * fix links --------- Co-authored-by: Megha-Dev-19 <100185149+Megha-Dev-19@users.noreply.github.com> Co-authored-by: Elliot Braem <16282460+elliotBraem@users.noreply.github.com> * Test button Fix (#315) * test-btn-fix * toggle gateway urls * New changes in design implemented * Network button implementation * rename vertical * fix codeowners * Projects feed new (#319) * Sidebar * Initialize Projects page * Add CSS file * Align projects page with new design * Rename to kebab case * Align card design with new figma * Add List view * 100vh height * New projects feed updates & organization (#320) * reorganizing * formatting * adds label * Shift to pascal case * Add state for projects view * Rename folder structure * Fix links * Resolve comments --------- Co-authored-by: Elliot Braem <16282460+elliotBraem@users.noreply.github.com> * fix-network-links (#323) * Resource page new (#325) * Resources Page V0 * Resources Page V0 cleanup * Header Removed * Remaining Projects Routes (#328) * Project Routes * Refactor StarProjects * Use star app logic for handling starring projects * Resolve comments * Project-new (#329) * Remove "Error" from project-data helper * Added route to index page for Project * Created layout * Added this to store entire project details with it's layout * Added changes to index file * Added overview * Added Metadata * Added activity and updated links * Updated link to project details * Used recent falbackUrl * Added new fallbackUrl * Updated links back to "projects" * Added the rest of the pages and retructured project component * Rearranged folder structure * renamed routes to meet * Prettier * Fixed link to Metadata * Navigation new (#331) * Move navbar to new app and fix default route for sidebar * Navbar changes to adapt to new style * Revert some changes for now * Add activity page * Notifications Page (#336) * Notifications Page * Notifications Items fix * Comments Resolved * Tests for Login and Logout (#333) * test-btn-fix * toggle gateway urls * New changes in design implemented * Network button implementation * Login and Logout tests * Resource page new (#335) * Resources Page V0 * Resources Page V0 cleanup * Header Removed * Adding new resources * Move activity to new app pattern (#337) * Move create project to separate page, edit support and refactoring (#321) * moved create project to page, added roles and edit support * show success modal after project is created * fmt * rebased and added reusable view container * bug fixes * add logs * css update * update login container css * Fixed task editor and minor UI updates (#339) * fixed task editor * remove logs * fmt * Fix projects visibility on testnet (#342) * Fix projects visibility * fmt * Convert starredProjects to star (#346) * convert starredProjects to star * notify account * fmt --------- Co-authored-by: Megha-Dev-19 <100185149+Megha-Dev-19@users.noreply.github.com> * sets new index (#344) * yarn.lock * update bos-workspace * downgrade to .20 * latest * bos-workspace no bos-cli * Add feed to project page (#356) * Add feed to project page * Change editor * resolve comments * Resolve comment * use config_index --------- Co-authored-by: Megha <100185149+Megha-Dev-19@users.noreply.github.com> * Fix search in projects (#359) * Project creation form fixes (#360) * Add indicators for required fields * Add prefix to inputfield * Align typeahead with our input field style * Resolve commits * Fix projects bugs (#364) * fix tags structure * added border and error state * add border to list card * add autocomplete to projects * fmt --------- Co-authored-by: Elliot Braem <16282460+elliotBraem@users.noreply.github.com> * Add form bounty template * Image uploader module (#361) * test-btn-fix * toggle gateway urls * New changes in design implemented * Network button implementation * Login and Logout tests * Image Uploader module * Implemented Files component * run prettier format on commit (#369) * Responsiveness and Adding Missing Pages (#365) * Landing Page Update 3.0 * Responsiveness * Add Inspect and Profile Page to new app * Comments Resolved * update yarn * Fix red flashes, init to [] rather than {} and hide open roles (#370) * fix red flashes, init to [] rather than {} and hide open roles * fix formatting * Fix red flash (#371) * fix red flashes, init to [] rather than {} and hide open roles * fix formatting * default empty array * Move proposals related files and fix notification roles selector (#377) * move proposals related files * minor fixes * fix pre-commit command * Fixes authentication tests (#381) * remove Dummy * cleans up auth tests * fmt * Refactors Project Card (#382) * remove Dummy * cleans up auth tests * fmt * tests to validate navigation * combines and replaces two cards * fmt * Landing Page Refactor (#383) * Landing Page Update 4.0 * URL Update * fix links * fmt --------- Co-authored-by: Elliot Braem <16282460+elliotBraem@users.noreply.github.com> * Upgrade the gateway to new app and some fixes (#386) * Upgrade the gateway to new app and some fixes * Fix project card * fmt * Update release-new-mainnet.yml * Login/Logout Page Update / Profile.Index Update (#389) * Landing Page Update 4.0 * URL Update * Login Logout Page Design Update * fix conflict * fix links for signin, signout --------- Co-authored-by: Elliot Braem <16282460+elliotBraem@users.noreply.github.com> * fix landing page links (#394) * Defaults fallback for Object.keys (fix red flash on projects page) (#396) * increment * adds fallbacks * fmt * Ft: Project quick view (#388) * added canvas * add UI * css update * fix tests and add mobile responsiveness * fix potlock search (#397) * added changelog * Fix project creation w/ tests (#402) * init tests * fmt * rename test * fmt * clean test * formatting * working as-is test * fmt * fix upload image * fmt * complete editor tests * projects tests * fmt * remove unused * Add resources tests (#425) * Add resources tests * Resolve comments * Delete project (#417) * added delete project * Fix project creation w/ tests (#402) * init tests * fmt * rename test * fmt * clean test * formatting * working as-is test * fmt * fix upload image * fmt * complete editor tests * projects tests * fmt * remove unused * added delete project * added delete project test * add edit project test * fix tests * added delete project test * add edit project test * fix tests --------- Co-authored-by: Elliot Braem <16282460+elliotBraem@users.noreply.github.com> * Landing page regression tests (#416) * test-btn-fix * toggle gateway urls * New changes in design implemented * Network button implementation * Login and Logout tests * Image Uploader module * Implemented Files component * lp-reg-tests * start project and explore projects changes in redirection * added the assertion for login and changed the structure * added wait * connect-btn-test-fix * added wait for create project title --------- Co-authored-by: Elliot Braem <16282460+elliotBraem@users.noreply.github.com> * fix transfer proposal (#427) * Navbar reg tests (#424) * test-btn-fix * toggle gateway urls * New changes in design implemented * Network button implementation * Login and Logout tests * Image Uploader module * Implemented Files component * lp-reg-tests * start project and explore projects changes in redirection * added the assertion for login and changed the structure * added wait * connect-btn-test-fix * added wait for create project title * navbar-reg-tests * added page visiblity assertions * fixed source btn locator --------- Co-authored-by: Elliot Braem <16282460+elliotBraem@users.noreply.github.com> * Fix overflow activity feed (#420) * Fix overflow activity feed * Sidebar style update * Move fix to CSS * increment version --------- Co-authored-by: Muhammad Saad Iqbal Co-authored-by: Zeeshan Ahmad Co-authored-by: Megha-Dev-19 <100185149+Megha-Dev-19@users.noreply.github.com> Co-authored-by: Jiku Godwill Nsanwi <65053264+Jikugodwill@users.noreply.github.com> Co-authored-by: Marpureddy Saswat <91129111+Eren-Yeaager@users.noreply.github.com> Co-authored-by: heroes-bounty[bot] <167169790+heroes-bounty[bot]@users.noreply.github.com> * Fixes git history (#429) (#430) * Landing page (#290) * Add new landing page * Use new landing page --------- * Ft: New `buildhub` app (#303) * renamed new folder to `buildhub` * added github job * added mainnet job * prettier update * set new and old --------- * Fix: builddao.testnet public key * small change to trigger build * small change to trigger build * fix: gateway reference in testnet * Fix notification issues (#304) * Fix notifications count not resetting * Supress console.logs * Fix black background on notifications page * Revert changes to post and comment * Remove console logs and navbar from viewer for now * Remove white bg * Added commit modal bypass for all (#313) * Added commit modal bypass for all * Removed injectedConfig * clean features * changelog --------- * App.js formatting fix * Fix: Propose UI stuck partway through process (#302) * Bug Fix 244 * "cleanup" * New modal design implementation * new-changes * refactored code * resolved comments * latest-changes * Initialize with essential routes (#312) * Initialize with essential routes * Move home to /page * Add navbar * Add footer to all pages * Fix fmt? * fix links --------- * Test button Fix (#315) * test-btn-fix * toggle gateway urls * New changes in design implemented * Network button implementation * rename vertical * fix codeowners * Projects feed new (#319) * Sidebar * Initialize Projects page * Add CSS file * Align projects page with new design * Rename to kebab case * Align card design with new figma * Add List view * 100vh height * New projects feed updates & organization (#320) * reorganizing * formatting * adds label * Shift to pascal case * Add state for projects view * Rename folder structure * Fix links * Resolve comments --------- * fix-network-links (#323) * Resource page new (#325) * Resources Page V0 * Resources Page V0 cleanup * Header Removed * Remaining Projects Routes (#328) * Project Routes * Refactor StarProjects * Use star app logic for handling starring projects * Resolve comments * Project-new (#329) * Remove "Error" from project-data helper * Added route to index page for Project * Created layout * Added this to store entire project details with it's layout * Added changes to index file * Added overview * Added Metadata * Added activity and updated links * Updated link to project details * Used recent falbackUrl * Added new fallbackUrl * Updated links back to "projects" * Added the rest of the pages and retructured project component * Rearranged folder structure * renamed routes to meet * Prettier * Fixed link to Metadata * Navigation new (#331) * Move navbar to new app and fix default route for sidebar * Navbar changes to adapt to new style * Revert some changes for now * Add activity page * Notifications Page (#336) * Notifications Page * Notifications Items fix * Comments Resolved * Tests for Login and Logout (#333) * test-btn-fix * toggle gateway urls * New changes in design implemented * Network button implementation * Login and Logout tests * Resource page new (#335) * Resources Page V0 * Resources Page V0 cleanup * Header Removed * Adding new resources * Move activity to new app pattern (#337) * Move create project to separate page, edit support and refactoring (#321) * moved create project to page, added roles and edit support * show success modal after project is created * fmt * rebased and added reusable view container * bug fixes * add logs * css update * update login container css * Fixed task editor and minor UI updates (#339) * fixed task editor * remove logs * fmt * Fix projects visibility on testnet (#342) * Fix projects visibility * fmt * Convert starredProjects to star (#346) * convert starredProjects to star * notify account * fmt --------- * sets new index (#344) * yarn.lock * update bos-workspace * downgrade to .20 * latest * bos-workspace no bos-cli * Add feed to project page (#356) * Add feed to project page * Change editor * resolve comments * Resolve comment * use config_index --------- * Fix search in projects (#359) * Project creation form fixes (#360) * Add indicators for required fields * Add prefix to inputfield * Align typeahead with our input field style * Resolve commits * Fix projects bugs (#364) * fix tags structure * added border and error state * add border to list card * add autocomplete to projects * fmt --------- * Add form bounty template * Image uploader module (#361) * test-btn-fix * toggle gateway urls * New changes in design implemented * Network button implementation * Login and Logout tests * Image Uploader module * Implemented Files component * run prettier format on commit (#369) * Responsiveness and Adding Missing Pages (#365) * Landing Page Update 3.0 * Responsiveness * Add Inspect and Profile Page to new app * Comments Resolved * update yarn * Fix red flashes, init to [] rather than {} and hide open roles (#370) * fix red flashes, init to [] rather than {} and hide open roles * fix formatting * Fix red flash (#371) * fix red flashes, init to [] rather than {} and hide open roles * fix formatting * default empty array * Move proposals related files and fix notification roles selector (#377) * move proposals related files * minor fixes * fix pre-commit command * Fixes authentication tests (#381) * remove Dummy * cleans up auth tests * fmt * Refactors Project Card (#382) * remove Dummy * cleans up auth tests * fmt * tests to validate navigation * combines and replaces two cards * fmt * Landing Page Refactor (#383) * Landing Page Update 4.0 * URL Update * fix links * fmt --------- * Upgrade the gateway to new app and some fixes (#386) * Upgrade the gateway to new app and some fixes * Fix project card * fmt * Update release-new-mainnet.yml * Login/Logout Page Update / Profile.Index Update (#389) * Landing Page Update 4.0 * URL Update * Login Logout Page Design Update * fix conflict * fix links for signin, signout --------- * fix landing page links (#394) * Defaults fallback for Object.keys (fix red flash on projects page) (#396) * increment * adds fallbacks * fmt * Ft: Project quick view (#388) * added canvas * add UI * css update * fix tests and add mobile responsiveness * fix potlock search (#397) * added changelog * Fix project creation w/ tests (#402) * init tests * fmt * rename test * fmt * clean test * formatting * working as-is test * fmt * fix upload image * fmt * complete editor tests * projects tests * fmt * remove unused * Add resources tests (#425) * Add resources tests * Resolve comments * Delete project (#417) * added delete project * Fix project creation w/ tests (#402) * init tests * fmt * rename test * fmt * clean test * formatting * working as-is test * fmt * fix upload image * fmt * complete editor tests * projects tests * fmt * remove unused * added delete project * added delete project test * add edit project test * fix tests * added delete project test * add edit project test * fix tests --------- * Landing page regression tests (#416) * test-btn-fix * toggle gateway urls * New changes in design implemented * Network button implementation * Login and Logout tests * Image Uploader module * Implemented Files component * lp-reg-tests * start project and explore projects changes in redirection * added the assertion for login and changed the structure * added wait * connect-btn-test-fix * added wait for create project title --------- * fix transfer proposal (#427) * Navbar reg tests (#424) * test-btn-fix * toggle gateway urls * New changes in design implemented * Network button implementation * Login and Logout tests * Image Uploader module * Implemented Files component * lp-reg-tests * start project and explore projects changes in redirection * added the assertion for login and changed the structure * added wait * connect-btn-test-fix * added wait for create project title * navbar-reg-tests * added page visiblity assertions * fixed source btn locator --------- * Fix overflow activity feed (#420) * Fix overflow activity feed * Sidebar style update * Move fix to CSS * increment version --------- Co-authored-by: Muhammad Saad Iqbal Co-authored-by: Zeeshan Ahmad Co-authored-by: Megha-Dev-19 <100185149+Megha-Dev-19@users.noreply.github.com> Co-authored-by: Jiku Godwill Nsanwi <65053264+Jikugodwill@users.noreply.github.com> Co-authored-by: Marpureddy Saswat <91129111+Eren-Yeaager@users.noreply.github.com> Co-authored-by: heroes-bounty[bot] <167169790+heroes-bounty[bot]@users.noreply.github.com> * Added styles to handle fullscreen on near.social and properly display on near.org as well (#441) * Added styles to handle fullscreen on near.social and properly display on near.org as well * fix tests * Added fix for everthing gateway as well * fmt --------- Co-authored-by: Megha-Dev-19 <100185149+Megha-Dev-19@users.noreply.github.com> * fix: gateway url, swap * Fixes flaky tests (#453) * fixes images, resource, and redirects * fmt * editor test * fmt * fix title for activity feeds * Activity page tests (#454) * fixed nav tabs page viewing assertion * resolved all comments --------- Co-authored-by: Megha <100185149+Megha-Dev-19@users.noreply.github.com> * Fix failing tests, add share post link tests (#455) * fix failing tests, add share post link tests * fix tests * minor fixes * fix flakiness * show loader on create of a project (#461) * Hid project location and team size when it's empty (#463) * Hid project location when it's empty * hid teamSize if empty --------- Co-authored-by: Elliot Braem <16282460+elliotBraem@users.noreply.github.com> * added upload statuses (#464) * Added logic to handle various upload phases * Update apps/old/widget/components/UploadField.jsx Co-authored-by: Megha <100185149+Megha-Dev-19@users.noreply.github.com> * accepted variable name change --------- Co-authored-by: Megha <100185149+Megha-Dev-19@users.noreply.github.com> * Adds web4 contract (#457) * init * tests pass, init * tests pass * configures workflow * update web component * sets default workflow wd * upgrade versions * add network * adds metadata * fmt * updates contract for testnet social db * set title * linked to new app Index (#467) Co-authored-by: Elliot Braem <16282460+elliotBraem@users.noreply.github.com> * Fix task project ID for new project title (#471) * fix tests * Add NEAR Catalog Import (#474) * Fix alias errors * Load projects from NEAR Catalog * Add Search * Autofill details from selected project * Add Tests * caching * Add reuseable skeleton card * Use new skeleton card * Remove container from CatalogImport * Fix bg-error * Fix test * Add error test and improve structure * Remove timeout from test * Add mocking api calls to the testing cookbook * Move catalog project(s) fetching to lib * converts to asyncFetch * fixes return data for asyncFetch --------- Co-authored-by: Elliot Braem <16282460+elliotBraem@users.noreply.github.com> * fix formatting * fmt * fmt * rename workflows --------- Co-authored-by: Elliot Braem <16282460+elliotBraem@users.noreply.github.com> Co-authored-by: Muhammad Saad Iqbal Co-authored-by: Zeeshan Ahmad Co-authored-by: Megha-Dev-19 <100185149+Megha-Dev-19@users.noreply.github.com> Co-authored-by: Jiku Godwill Nsanwi <65053264+Jikugodwill@users.noreply.github.com> Co-authored-by: Marpureddy Saswat <91129111+Eren-Yeaager@users.noreply.github.com> Co-authored-by: heroes-bounty[bot] <167169790+heroes-bounty[bot]@users.noreply.github.com> --- .github/workflows/web4-deploy-production.yml | 2 +- .github/workflows/web4-deploy-staging.yml | 2 +- .github/workflows/web4-test.yml | 2 +- .github/workflows/web4-undeploy-staging.yml | 2 +- apps/new/widget/lib/projects.jsx | 22 + .../new/widget/page/projects/CardSkeleton.jsx | 125 +++ .../widget/page/projects/CatalogImport.jsx | 139 +++ .../page/projects/CatalogProjectCard.jsx | 102 +++ apps/new/widget/page/projects/Editor.jsx | 33 + .../page/projects/ImportAndCreateModal.jsx | 8 +- apps/new/widget/page/projects/Index.jsx | 8 + .../page/projects/PotlockProjectCard.jsx | 126 +-- .../components/buttons/UserDropdown.jsx | 2 +- apps/old/widget/components/post/Header.jsx | 2 +- .../widget/components/profile/ProfileLine.jsx | 2 +- playwright-tests/README.md | 21 +- playwright-tests/tests/editor.spec.js | 150 ++++ web4contract/src/lib.rs | 3 +- yarn.lock | 849 ++++++++++++------ 19 files changed, 1187 insertions(+), 413 deletions(-) create mode 100644 apps/new/widget/page/projects/CardSkeleton.jsx create mode 100644 apps/new/widget/page/projects/CatalogImport.jsx create mode 100644 apps/new/widget/page/projects/CatalogProjectCard.jsx diff --git a/.github/workflows/web4-deploy-production.yml b/.github/workflows/web4-deploy-production.yml index 6256051e..60c41176 100644 --- a/.github/workflows/web4-deploy-production.yml +++ b/.github/workflows/web4-deploy-production.yml @@ -1,4 +1,4 @@ -name: Deploy to production +name: Deploy web4 contract to production on: push: branches: [main] diff --git a/.github/workflows/web4-deploy-staging.yml b/.github/workflows/web4-deploy-staging.yml index 58a70249..9e03aba5 100644 --- a/.github/workflows/web4-deploy-staging.yml +++ b/.github/workflows/web4-deploy-staging.yml @@ -1,4 +1,4 @@ -name: Deploy to staging +name: Deploy web4 contract to staging on: pull_request: paths: diff --git a/.github/workflows/web4-test.yml b/.github/workflows/web4-test.yml index da1a9906..a2d5d479 100644 --- a/.github/workflows/web4-test.yml +++ b/.github/workflows/web4-test.yml @@ -1,4 +1,4 @@ -name: Test +name: Test web4 contract on: workflow_call: diff --git a/.github/workflows/web4-undeploy-staging.yml b/.github/workflows/web4-undeploy-staging.yml index 3b3f862c..bbb252f0 100644 --- a/.github/workflows/web4-undeploy-staging.yml +++ b/.github/workflows/web4-undeploy-staging.yml @@ -1,4 +1,4 @@ -name: Undeploy staging +name: Undeploy web4 contract from staging on: pull_request: types: [closed] diff --git a/apps/new/widget/lib/projects.jsx b/apps/new/widget/lib/projects.jsx index 13ba7bfa..4b9b4963 100644 --- a/apps/new/widget/lib/projects.jsx +++ b/apps/new/widget/lib/projects.jsx @@ -103,8 +103,30 @@ const getProjectIdFromPath = (id) => { return (id ?? "").split("/")[2] ?? null; }; +const fetchCatalogProjects = () => { + const indexer = "https://nearcatalog.xyz/wp-json/nearcatalog/v1"; + return asyncFetch(indexer + "/projects").then((response) => { + if (!response.body) { + return {}; + } + return response.body; + }); +}; + +const fetchCatalogProject = (id) => { + const indexer = "https://nearcatalog.xyz/wp-json/nearcatalog/v1"; + const query = ""; + query = fetch(indexer + "/project?pid=" + id); + if (!query.body) { + return {}; + } + return query.body.profile; +}; + return { fetchProjects, + fetchCatalogProjects, + fetchCatalogProject, getProjectMeta, getProjectIdFromPath, getTagsInArray, diff --git a/apps/new/widget/page/projects/CardSkeleton.jsx b/apps/new/widget/page/projects/CardSkeleton.jsx new file mode 100644 index 00000000..290c2f66 --- /dev/null +++ b/apps/new/widget/page/projects/CardSkeleton.jsx @@ -0,0 +1,125 @@ +const CardSkeletonContainer = styled.div` + @keyframes loadingSkeleton { + 0% { + opacity: 0.8; + } + 50% { + opacity: 0.3; + } + 100% { + opacity: 0.6; + } + } + + display: flex; + flex-direction: column; + height: 447px; + width: 100%; + max-width: 400px; + border-radius: 12px; + background: var(--bg-color, #23242b); + color: var(--text-color, #fff); + margin-left: auto; + margin-right: auto; + overflow: hidden; + animation-name: loadingSkeleton; + animation-duration: 1s; + animation-iteration-count: infinite; +`; + +const HeaderSkeleton = styled.div` + display: block; + width: 100%; + height: 168px; + background: #eee; +`; + +const ProfileImageSkeleton = styled.div` + background: #e0e0e0; + margin-left: 32px; + transform: translateY(148px); + width: 40px; + height: 40px; + position: absolute; + border-radius: 999px; +`; + +const TitleSkeleton = styled.div` + width: 120px; + height: 24px; + background: #eee; + margin-left: 24px; + margin-top: 24px; +`; + +const DescriptionSkeleton = styled.div` + width: 83%; + height: 48px; + background: #eee; + margin-left: 24px; + margin-top: 24px; +`; + +const TagSkeleton = styled.div` + background: #eee; + border-radius: 4px; + height: 34px; + width: 110px; + margin: 24px; +`; + +const FooterItemSkeleton = styled.div` + width: 150px; + height: 40px; + background: #eee; + + @media screen and (max-width: 390px) { + width: 100px; + } +`; + +const DonationsInfoContainerSkeleton = styled.div` + display: flex; + flex-direction: row; + justify-content: space-between; + align-items: center; + padding: 16px 24px; + width: 100%; + border-top: 1px #f0f0f0 solid; +`; + +const DonationsInfoItemSkeleton = styled.div` + display: flex; + flex-direction: row; + gap: 8px; + align-items: center; +`; + +const CardSkeleton = ({ variant }) => { + return varaint === "potlock" ? ( + + + + + + + + + + + + + + + + ) : ( + + + + + + + ); +}; + +return { CardSkeleton }; diff --git a/apps/new/widget/page/projects/CatalogImport.jsx b/apps/new/widget/page/projects/CatalogImport.jsx new file mode 100644 index 00000000..c30889eb --- /dev/null +++ b/apps/new/widget/page/projects/CatalogImport.jsx @@ -0,0 +1,139 @@ +const { Feed } = VM.require("${alias_devs}/widget/Feed") || { + Feed: () => <>, +}; + +const { CardSkeleton } = VM.require( + "${alias_new}/widget/page.projects.CardSkeleton", +) || { + CardSkeleton: () => <>, +}; + +const { fetchCatalogProjects } = VM.require( + "${alias_new}/widget/lib.projects", +) || { + fetchCatalogProjects: () => {}, +}; + +const projects = useCache(() => { + return fetchCatalogProjects(); +}, ["near-catalog-projects"]); + +const [filteredProjects, setFilteredProjects] = useState({}); + +useEffect(() => { + if (projects) { + setFilteredProjects(projects); + } +}, [projects]); + +const [searchTerm, setSearch] = useState(null); + +const Search = useMemo(() => { + return ( + { + setSearch(value); + + if (searchTerm === value) return; + if (searchTerm === "") return; + + const filtered = {}; + Object.keys(projects).forEach((projectId) => { + if ( + projects[projectId].profile.name + .toLowerCase() + .includes(value.toLowerCase()) + ) { + filtered[projectId] = projects[projectId]; + } + + if ( + projects[projectId].profile.tagline + .toLowerCase() + .includes(value.toLowerCase()) + ) { + filtered[projectId] = projects[projectId]; + } + + const tags = Object.values(projects[projectId].profile.tags); + if ( + tags.some((tag) => + tag.toLowerCase().includes(value.toLowerCase()), + ) + ) { + filtered[projectId] = projects[projectId]; + } + }); + setFilteredProjects(filtered); + }, + }} + /> + ); +}, [projects, searchTerm]); + +const ProjectsGrid = styled.div` + display: grid; + grid-template-columns: repeat(3, minmax(0, 1fr)); + gap: 1.5rem; + @media screen and (max-width: 768px) { + grid-template-columns: repeat(1, minmax(0, 1fr)); + } + max-width: 100%; +`; + +const [selectedProjectId, setSelectedProjectId] = useState(null); + +if (selectedProjectId) { + return ( + + ); +} + +return ( +
+ {Search} + {projects === null ? ( + <> +
+ Loading projects... +
+ + ) : ( + <> + {Object.keys(filteredProjects).length === 0 && ( +
+ {searchTerm + ? `No projects were found for your search query "${searchTerm}".` + : "Network issue: Couldn't fetch any projects, please try again later."} +
+ )} + + )} + ({ projectId }))} + Item={({ projectId }) => ( + } + props={{ + project: filteredProjects[projectId], + setSelectedProjectId: setSelectedProjectId, + }} + /> + )} + Layout={ProjectsGrid} + /> +
+); diff --git a/apps/new/widget/page/projects/CatalogProjectCard.jsx b/apps/new/widget/page/projects/CatalogProjectCard.jsx new file mode 100644 index 00000000..e26b3477 --- /dev/null +++ b/apps/new/widget/page/projects/CatalogProjectCard.jsx @@ -0,0 +1,102 @@ +const project = props.project; +if (!project) { + return "No Project Passed"; +} + +const MAX_DESCRIPTION_LENGTH = 80; + +const Card = styled.div` + display: flex; + flex-direction: column; + gap: 1rem; + border-radius: 1rem; + background: #23242b; + color: white; + transition: all 300ms; + height: 100%; + + &:hover { + transform: translateY(-0.5rem); + cursor: pointer; + } + + .image { + height: 168px; + border-radius: 16px 16px 0px 0px; + object-fit: cover; + } + + .info { + display: flex; + flex-direction: column; + padding: 16px 24px; + gap: 16px; + flex: 1; + } + + .title { + font-size: 16px; + font-weight: 600; + width: 100%; + } + + .description { + font-size: 14px; + font-weight: 400; + word-wrap: break-word; + } + + .tags { + display: flex; + gap: 8px; + flex-wrap: wrap; + } + + .tag { + box-shadow: 0px -0.699999988079071px 0px rgba(123, 123, 123, 0.36) inset; + padding: 4px 8px; + border-radius: 4px; + border: 1px solid rgba(123, 123, 123, 0.36); + } +`; + +const getImageSrc = (image) => { + const defaultImageUrl = + "https://ipfs.near.social/ipfs/bafkreih4i6kftb34wpdzcuvgafozxz6tk6u4f5kcr2gwvtvxikvwriteci"; + if (!image) return defaultImageUrl; + const { url, ipfs_cid } = image; + if (ipfs_cid) { + return ipfsUrlFromCid(ipfs_cid); + } else if (url) { + return url; + } + return defaultImageUrl; +}; + +return ( + props.setSelectedProjectId(project.slug)} + > + {project.profile.name} +
+
{project.profile.name}
+

+ {project.profile.tagline.length > MAX_DESCRIPTION_LENGTH + ? project.profile.tagline.slice(0, MAX_DESCRIPTION_LENGTH) + "..." + : project.profile.tagline} +

+
+ {Object.values(project.profile.tags).map((tag, index) => ( + + {tag} + + ))} +
+
+
+); diff --git a/apps/new/widget/page/projects/Editor.jsx b/apps/new/widget/page/projects/Editor.jsx index 4244812a..7958af39 100644 --- a/apps/new/widget/page/projects/Editor.jsx +++ b/apps/new/widget/page/projects/Editor.jsx @@ -30,6 +30,12 @@ const { getProjectMeta, getProjectIdFromPath } = VM.require( getProjectMeta: () => {}, }; +const { fetchCatalogProject } = VM.require( + "${alias_new}/widget/lib.projects", +) || { + fetchCatalogProject: () => {}, +}; + const { href } = VM.require("${alias_old}/widget/lib.url") || { href: () => {}, }; @@ -271,6 +277,33 @@ const handleTags = (tags) => { setTags(filtered); }; +// Handle NEAR Catalog Projects +const catalogProjectId = props.catalogProjectId; +const catalogProjectData = null; +if (catalogProjectId) { + catalogProjectData = fetchCatalogProject(catalogProjectId); +} +useEffect(() => { + if (catalogProjectData) { + const { website, github, telegram, twitter } = catalogProjectData.linktree; + const githubLink = github.split("/")[3]; + const telegramLink = telegram.split("/")[3]; + const twitterLink = twitter.split("/")[3]; + const tags = Object.values(catalogProjectData.tags || []).map((tag) => { + return removeWhiteSpace(tag); + }); + + setTitle(catalogProjectData.name); + setDescription(catalogProjectData.description); + setAvatar(catalogProjectData.image); + setWebsite(website); + setGitHub(githubLink); + setTelegram(telegramLink); + setTwitter(twitterLink); + setTags(tags); + } +}, [catalogProjectData]); + // Commenting roles code (to be added in v1) // const handleRoles = (roles) => { // let filtered = roles.map((role) => diff --git a/apps/new/widget/page/projects/ImportAndCreateModal.jsx b/apps/new/widget/page/projects/ImportAndCreateModal.jsx index 25884f4d..74b3d738 100644 --- a/apps/new/widget/page/projects/ImportAndCreateModal.jsx +++ b/apps/new/widget/page/projects/ImportAndCreateModal.jsx @@ -66,14 +66,18 @@ return ( src="https://ipfs.near.social/ipfs/bafkreidbfu7uxtr4is7wxileg3mrbajve6cgkfmrqemc6pxsr6nnczz7ly" tab="editor" /> - - +