Skip to content

Commit

Permalink
Merge pull request #5198 from cowprotocol/main
Browse files Browse the repository at this point in the history
Main -> develop
  • Loading branch information
shoom3301 authored Dec 12, 2024
2 parents f36635c + afb9fff commit 1a9f2db
Show file tree
Hide file tree
Showing 9 changed files with 122 additions and 9 deletions.
4 changes: 2 additions & 2 deletions .release-please-manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"apps/widget-configurator": "1.10.0",
"libs/analytics": "1.9.0",
"libs/assets": "1.11.0",
"libs/common-const": "1.12.1",
"libs/common-const": "1.12.2",
"libs/common-hooks": "1.6.0",
"libs/common-utils": "1.8.0",
"libs/core": "1.5.0",
Expand All @@ -18,7 +18,7 @@
"libs/types": "1.5.0",
"libs/ui": "1.16.0",
"libs/wallet": "1.7.0",
"apps/cow-fi": "1.19.0",
"apps/cow-fi": "1.19.2",
"libs/wallet-provider": "1.0.0",
"libs/ui-utils": "1.1.0",
"libs/abis": "1.2.0",
Expand Down
14 changes: 14 additions & 0 deletions apps/cow-fi/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,19 @@
# Changelog

## [1.19.2](https://github.com/cowprotocol/cowswap/compare/cow-fi-v1.19.1...cow-fi-v1.19.2) (2024-12-12)


### Bug Fixes

* **cowfi:** reduce cms requests cache time to 5 min ([#5196](https://github.com/cowprotocol/cowswap/issues/5196)) ([8893f35](https://github.com/cowprotocol/cowswap/commit/8893f35e177f86eef15ad2790034b705cf91e349))

## [1.19.1](https://github.com/cowprotocol/cowswap/compare/cow-fi-v1.19.0...cow-fi-v1.19.1) (2024-12-12)


### Bug Fixes

* **cow-fi:** add info about base launch ([#5194](https://github.com/cowprotocol/cowswap/issues/5194)) ([6bd2015](https://github.com/cowprotocol/cowswap/commit/6bd20155a2211bba95e5cdd8dab2e108b4783a13))

## [1.19.0](https://github.com/cowprotocol/cowswap/compare/cow-fi-v1.18.0...cow-fi-v1.19.0) (2024-12-11)


Expand Down
40 changes: 39 additions & 1 deletion apps/cow-fi/app/(main)/legal/cowswap-terms/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ export default function Page() {

<BodyContent>
<p>
<strong>Last updated: September 2024</strong>
<strong>Last updated: December 2024</strong>
</p>
<p>
These Terms of Use (the &quot;Terms&quot;) govern your access to{' '}
Expand Down Expand Up @@ -679,6 +679,44 @@ export default function Page() {
modification to or deletion of a provision or part-provision under this clause shall not affect the
validity and enforceability of the rest of these Terms.
</p>{' '}
<h2 id="base-launch">COW Token Giveaway, Base Launch: Terms and Conditions</h2>
<h3 id="base-launch-introduction">1. Introduction</h3>
<p>By participating in the COW Token Giveaway, you agree to these Terms and Conditions.</p>
<h3 id="base-launch-eligibility">2. Eligibility</h3>
<p>
18+ years old. Not an employee or affiliate of the Organizer. Must have a valid compatible wallet. Must
follow CoW Protocol on X. Void where prohibited.
</p>
<h3 id="base-launch-giveaway-period">3. Giveaway Period</h3>
<p>From 2024-12-12 at the time of the post on the X Platform to 2024-12-31, at 11:59 PM UTC.</p>
<h3 id="base-launch-how-to-enter">4. How to Enter</h3>
<p>
Trade on Base using CoW Swap during the Giveaway Period. Quote Tweet the Giveaway announcement with your
trade's transaction hash. One entry per eligible transaction.
</p>
<h3 id="base-launch-prize">5. Prize</h3>
<p>
10,000 COW tokens distributed among randomly selected winners. The Organiser will determine the number of
winners and token allocation at its discretion.
</p>
<h3 id="base-launch-winner-selection">6. Winner Selection</h3>
<p>Random selection from eligible entries. Odds depend on the number of entries.</p>
<h3 id="base-launch-winner-notification">7. Winner Notification</h3>
<p>Winners announced on X within 15 days after the Giveaway Period.</p>
<h3 id="base-launch-publicblockchain">8. Public Blockchain</h3>
<p>
Blockchain transactions are public and immutable. Sharing your transaction hash may make your wallet and
transaction details public and related to your X account.
</p>
<h3 id="base-launch-general-conditions">9. General Conditions</h3>
<p>
Organisers can disqualify entries or modify/cancel the Giveaway. Not responsible for technical issues.
Subject to applicable laws. The organiser's decisions are final.
</p>
<h3 id="base-launch-limitation-of-liability">10. Limitation of Liability</h3>
<p>Organiser not liable for losses related to the Giveaway or prize. COW token value may fluctuate.</p>
<h3 id="base-launch-governing-law">11. Governing Law</h3>
<p>Governed by the laws of England and Wales</p>
</BodyContent>
</ArticleContent>
</ContainerCard>
Expand Down
2 changes: 1 addition & 1 deletion apps/cow-fi/next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ const nextConfig = {
headers: [
{
key: 'Cache-Control',
value: 'public, s-maxage=60, stale-while-revalidate=600',
value: 'public, s-maxage=60, stale-while-revalidate=300',
},
],
},
Expand Down
2 changes: 1 addition & 1 deletion apps/cow-fi/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cowprotocol/cow-fi",
"version": "1.19.0",
"version": "1.19.2",
"description": "CoW DAO website",
"main": "index.js",
"author": "",
Expand Down
4 changes: 2 additions & 2 deletions apps/cow-fi/services/cms/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import qs from 'qs'

import { toQueryParams } from 'util/queryParams'
import { getCmsClient } from '@cowprotocol/core'
import { DATA_CACHE_TIME_SECONDS } from '@/const/meta'

const PAGE_SIZE = 50
const CMS_CACHE_TIME = 5 * 60 // 5 min

type Schemas = components['schemas']
export type Article = Schemas['ArticleListResponseDataItem']
Expand All @@ -33,7 +33,7 @@ export const client = getCmsClient()

const clientAddons = {
// https://github.com/openapi-ts/openapi-typescript/issues/1569#issuecomment-1982247959
fetch: (request: unknown) => fetch(request as Request, { next: { revalidate: DATA_CACHE_TIME_SECONDS } }),
fetch: (request: unknown) => fetch(request as Request, { next: { revalidate: CMS_CACHE_TIME } }),
}

/**
Expand Down
7 changes: 7 additions & 0 deletions libs/common-const/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# Changelog

## [1.12.2](https://github.com/cowprotocol/cowswap/compare/common-const-v1.12.1...common-const-v1.12.2) (2024-12-12)


### Bug Fixes

* add more stablecoins in fees logic ([#5192](https://github.com/cowprotocol/cowswap/issues/5192)) ([79afa5c](https://github.com/cowprotocol/cowswap/commit/79afa5cb8018cd263b7820bdcb922998a4d80527))

## [1.12.1](https://github.com/cowprotocol/cowswap/compare/common-const-v1.12.0...common-const-v1.12.1) (2024-12-12)


Expand Down
2 changes: 1 addition & 1 deletion libs/common-const/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cowprotocol/common-const",
"version": "1.12.1",
"version": "1.12.2",
"main": "./index.js",
"types": "./index.d.ts",
"exports": {
Expand Down
56 changes: 55 additions & 1 deletion libs/common-const/src/tokens.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,51 @@ export const GNO_MAINNET = new TokenWithLogo(
'Gnosis',
)

const FRAX_MAINNET = new TokenWithLogo(
'https://assets.coingecko.com/coins/images/13422/thumb/frax_logo.png?1608476506',
SupportedChainId.MAINNET,
'0x853d955aCEf822Db058eb8505911ED77F175b99e',
18,
'FRAX',
'Frax',
)

const GUSD_MAINNET = new TokenWithLogo(
'https://assets.coingecko.com/coins/images/5992/thumb/gemini-dollar-gusd.png?1536745278',
SupportedChainId.MAINNET,
'0x056Fd409E1d7A124BD7017459dFEa2F387b6d5Cd',
2,
'GUSD',
'Gemini Dollar',
)

const LUSD_MAINNET = new TokenWithLogo(
'https://assets.coingecko.com/coins/images/14666/thumb/Group_3.png?1617631327',
SupportedChainId.MAINNET,
'5f98805A4E8be255a32880FDeC7F6728C6568bA0',
18,
'LUSD',
'Liquity USD',
)

const PYUSD_MAINNET = new TokenWithLogo(
'https://assets.coingecko.com/coins/images/31212/large/PYUSD_Logo_%282%29.png?1691458314',
SupportedChainId.MAINNET,
'0x6c3ea9036406852006290770BEdFcAbA0e23A0e8',
6,
'PYUSD',
'PayPal USD',
)

const sUSD_MAINNET = new TokenWithLogo(
'https://assets.coingecko.com/coins/images/5013/thumb/sUSD.png?1616150765',
SupportedChainId.MAINNET,
'0x57Ab1ec28D129707052df4dF418D58a2D46d5f51',
18,
'sUSD',
'Synth sUSD',
)

// Gnosis chain
export const XDAI_SYMBOL = 'XDAI'
export const XDAI_NAME = 'xDai'
Expand Down Expand Up @@ -455,7 +500,16 @@ const SDAI_GNOSIS_CHAIN_ADDRESS = '0xaf204776c7245bf4147c2612bf6e5972ee483701'
const GBPE_GNOSIS_CHAIN_ADDRESS = '0x5cb9073902f2035222b9749f8fb0c9bfe5527108'

// Not used for fees
const MAINNET_STABLECOINS = [USDC_MAINNET.address, USDT.address, DAI.address].map((t) => t.toLowerCase())
const MAINNET_STABLECOINS = [
USDC_MAINNET.address,
USDT.address,
DAI.address,
FRAX_MAINNET.address,
GUSD_MAINNET.address,
LUSD_MAINNET.address,
PYUSD_MAINNET.address,
sUSD_MAINNET.address,
].map((t) => t.toLowerCase())

// NOTE: whenever this list is updated, make sure to update the docs section regarding the volume fees
// https://github.com/cowprotocol/docs/blob/main/docs/governance/fees/fees.md?plain=1#L40
Expand Down

0 comments on commit 1a9f2db

Please sign in to comment.