diff --git a/src/AI/Agent/AgentCreate.jsx b/src/AI/Agent/AgentCreate.jsx index a31787b7..8c6276f5 100644 --- a/src/AI/Agent/AgentCreate.jsx +++ b/src/AI/Agent/AgentCreate.jsx @@ -1,9 +1,3 @@ -const { typeMatch } = VM.require("devhub.near/widget/core.lib.struct"); - -if (!typeMatch) { - return

Loading modules...

; -} - const { data, onSubmit, onCancel } = props; const onSubmitDefault = (formValues) => { const { name, ...rest } = formValues; @@ -77,7 +71,7 @@ const AgentInputsPartialSchema = { // }, component: { inputProps: { - min: 2, + min: 0, max: 255, placeholder: "The component used to run the agent, default is near/widget/AI.Agent.AgentChat", required: false, @@ -121,7 +115,14 @@ const AgentInputsPartialSchema = { }; const agentInputsValidator = (formValues) => - typeMatch(formValues) && Object.values(formValues).every((value) => typeof value === "string" && value.length > 0); + formValues !== null && + typeof formValues === "object" && + !Array.isArray(formValues) && + Object.keys(AgentInputsPartialSchema).every((key) => { + const val = AgentInputsPartialSchema[key]; + const required = val?.inputProps?.required; + return !required || typeof formValues[key] === "string"; + }); return ( Math.abs(new Date(a.event.start_at) - new Date()) - Math.abs(new Date(b.event.start_at) - new Date()), -)[0].event; +const featuredEvent = + eventsList.length > 0 && + [...eventsList].sort( + (a, b) => Math.abs(new Date(a.event.start_at) - new Date()) - Math.abs(new Date(b.event.start_at) - new Date()), + )[0].event; return ( @@ -226,32 +228,34 @@ return ( -
- - - - Upcoming Event - - + {featuredEvent && ( +
+ + + + Upcoming Event + + - - -
+ +
+
+ )}
@@ -273,30 +277,51 @@ return ( )} - - {eventsList.map(({ event }) => { - const startAt = convertData(event?.start_at); - const endAt = convertData(event?.end_at); - const location = formatLocation(event.geo_address_json); - return ( - - ); - })} - + {eventsList.length > 0 ? ( + + {eventsList.map(({ event }) => { + const startAt = convertData(event?.start_at); + const endAt = convertData(event?.end_at); + const location = formatLocation(event.geo_address_json); + return ( + + ); + })} + + ) : ( + + + There are no upcoming events at the moment. + + + Subscribe to our Luma calendar to stay up to date with our events. + + + + )}
diff --git a/src/NearOrg/CookieDetails.jsx b/src/NearOrg/CookieDetails.jsx index 871d9d5f..20f82141 100644 --- a/src/NearOrg/CookieDetails.jsx +++ b/src/NearOrg/CookieDetails.jsx @@ -5,6 +5,7 @@ const firstPartyCookies = `| Identifer | Purpose | | rl_session | product analytics | Rudderstack | .near.org | [Link](https://cookiedatabase.org/?lang=en&s=rl_session) | 1 year | Stores the session-related information including the ID. | | rl_page_init_referring_domain | product analytics | Rudderstack | .near.org | [Link](https://cookiedatabase.org/?lang=en&s=rl_page_init_referring_domain) | 1 year | to store referring website. | | rl_page_init_referrer | product analytics | Rudderstack | .near.org | [Link](https://cookiedatabase.org/?lang=en&s=rl_page_init_referrer) | 1 year | to store referring website. | +| user-country-code | product analytics | Discovery Domain | .near.org | n/a | 1 year | to store a visitor's country code | `; const thirdPartyCookies = `| Identifer | Purpose | Provider | Domain | Duration | diff --git a/src/NearOrg/CookiePrompt.jsx b/src/NearOrg/CookiePrompt.jsx index 4fdf159b..8fac71bb 100644 --- a/src/NearOrg/CookiePrompt.jsx +++ b/src/NearOrg/CookiePrompt.jsx @@ -65,7 +65,7 @@ if (state.cookieAcceptance) { const onAccept = ({ all, onlyRequired }) => { State.update({ cookieAcceptance: true }); State.update({ isDialogOpen: false }); - return ; + return ; }; const onCustomize = () => { diff --git a/src/NearOrg/FoundersPage.jsx b/src/NearOrg/FoundersPage.jsx index 14ca4095..26ef5f5d 100644 --- a/src/NearOrg/FoundersPage.jsx +++ b/src/NearOrg/FoundersPage.jsx @@ -119,7 +119,7 @@ const Pattern = styled.div` `; const PatternContent = styled.div` - padding: 1rem; + padding: 2rem 4rem; max-width: 496px; margin: 0 auto; background-color: var(--background-color); @@ -148,8 +148,19 @@ const IconCircle = styled.div` `; const TextLink = styled("Link")` - color: inherit; - text-decoration: underline; + font: var(--text-base); + font-weight: 600; + line-height: 150%; + color: var(--white); + background: transparent; + text-decoration: none; + padding: 16px 24px; + border-radius: 50px; + border: 1px solid var(--green10); + + &:hover { + text-decoration: none; + } `; const Resource = ({ name, description, icon, url, target }) => ( @@ -231,13 +242,19 @@ const ecosystemCommunityResources = [ }, ]; +function returnIpfsImage(cfid) { + return { + ipfs_cid: cfid, + }; +} + return (
- +

FounderHub

@@ -246,8 +263,8 @@ return (
- - + +

Welcome to NEAR, the best place to build Web3 projects

From idea to launch, the NEAR FounderHub guides you every step of the way. Get the tailored resources, @@ -260,17 +277,15 @@ return (

Self-Serve Resources

+ + Tap into our curated resources: proven templates, expert insights, and a vibrant founder network. +
{selfServeResources.map((item) => ( ))} - - - Tap into our curated resources: proven templates, expert insights, and a vibrant founder network. - -
@@ -278,42 +293,59 @@ return (

Ecosystem Community Resources

+ + Find your place within the ecosystem — your community is near. +
{ecosystemCommunityResources.map((item) => ( ))} - - - Find your place within the ecosystem: whether it's by joining our selective accelerator program, - getting involved with our builder groups or hanging out at a live event, your community is near. - -
-

Accelerate your Web3 journey

- - HZN3 applications are{" "} - - open. - - Over 50 projects have been accelerated through HZN, our equity-free accelerator and gone on to raise over - $10M in external capital. Get the equity-free education, mentorship, and a network to take your project to - the next level. - +

Accelerate your Web3 journey

+ + + + HZN3 applications are open + + + Over 50 projects have been accelerated through HZN, our equity-free accelerator and gone on to raise + over $10M in external capital. Get the equity-free education, mentorship, and a network to take your + project to the next level. + + + + Apply Now + + + + ), + image: returnIpfsImage("bafkreib55qq67nbthwpkzqx2upjnecwnrutpo3q26zjqt3wz3n5iw4o6da"), + imageSide: "left", + alt: "The HZN logo.", + }} + />
-
+
- Get in touch with us to provide any feedback or ask for specific support + Get in touch + + + Reach out to us to provide your feedback or to ask for specific support.
- - );