Skip to content

Commit

Permalink
Fix missing lending protocol config for SKY (sync from oasis-borrow)
Browse files Browse the repository at this point in the history
  • Loading branch information
marcinciarka committed Sep 19, 2024
1 parent c1b0a48 commit 4dd6d59
Show file tree
Hide file tree
Showing 9 changed files with 227 additions and 0 deletions.
2 changes: 2 additions & 0 deletions apps/earn-protocol/helpers/lending-protocol.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ export enum LendingProtocol {
Maker = 'maker',
MorphoBlue = 'morphoblue',
SparkV3 = 'sparkv3',
Sky = 'sky',
}

export enum LendingProtocolLabel {
Expand All @@ -14,6 +15,7 @@ export enum LendingProtocolLabel {
maker = 'Maker',
morphoblue = 'Morpho Blue',
sparkv3 = 'Spark',
sky = 'Sky',
}

export type AaveLendingProtocol = LendingProtocol.AaveV2 | LendingProtocol.AaveV3
Expand Down
10 changes: 10 additions & 0 deletions apps/earn-protocol/helpers/lending-protocols-configs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import makerIcon from 'public/img/protocol_icons/maker_icon.svg'
import makerLogo from 'public/img/protocol_icons/maker_logo.svg'
import morphoBlueIcon from 'public/img/protocol_icons/morpho_blue_icon.svg'
import morphoBlueLogo from 'public/img/protocol_icons/morpho_blue_logo.svg'
import skyIcon from 'public/img/protocol_icons/sky.svg'
import sparkIcon from 'public/img/protocol_icons/spark_icon.svg'
import sparkLogo from 'public/img/protocol_icons/spark_logo.svg'

Expand Down Expand Up @@ -69,13 +70,22 @@ const sparkConfig: LendingProtocolConfig = {
logoScale: 1.2,
}

const skyConfig: LendingProtocolConfig = {
name: LendingProtocol.Sky,
label: LendingProtocolLabel.sky,
icon: skyIcon as string,
logo: skyIcon as string,
logoScale: 1.6,
}

const lendingProtocols = [
aaveV2Config,
aaveV3Config,
ajnaConfig,
makerConfig,
morphoBlueConfig,
sparkConfig,
skyConfig,
]

export const lendingProtocolsByName = keyBy(lendingProtocols, 'name')
98 changes: 98 additions & 0 deletions apps/earn-protocol/public/img/protocol_icons/sky.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 2 additions & 0 deletions apps/rays-dashboard/helpers/lending-protocol.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ export enum LendingProtocol {
Maker = 'maker',
MorphoBlue = 'morphoblue',
SparkV3 = 'sparkv3',
Sky = 'sky',
}

export enum LendingProtocolLabel {
Expand All @@ -14,6 +15,7 @@ export enum LendingProtocolLabel {
maker = 'Maker',
morphoblue = 'Morpho Blue',
sparkv3 = 'Spark',
sky = 'Sky',
}

export type AaveLendingProtocol = LendingProtocol.AaveV2 | LendingProtocol.AaveV3
Expand Down
10 changes: 10 additions & 0 deletions apps/rays-dashboard/helpers/lending-protocols-configs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import makerIcon from 'public/img/protocol_icons/maker_icon.svg'
import makerLogo from 'public/img/protocol_icons/maker_logo.svg'
import morphoBlueIcon from 'public/img/protocol_icons/morpho_blue_icon.svg'
import morphoBlueLogo from 'public/img/protocol_icons/morpho_blue_logo.svg'
import skyIcon from 'public/img/protocol_icons/sky.svg'
import sparkIcon from 'public/img/protocol_icons/spark_icon.svg'
import sparkLogo from 'public/img/protocol_icons/spark_logo.svg'

Expand Down Expand Up @@ -76,6 +77,14 @@ const sparkConfig: LendingProtocolConfig = {
logoScale: 1.2,
}

const skyConfig: LendingProtocolConfig = {
name: LendingProtocol.Sky,
label: LendingProtocolLabel.sky,
icon: skyIcon as string,
logo: skyIcon as string,
logoScale: 1.6,
}

const lendingProtocols = [
aaveV2Config,
aaveV3Config,
Expand All @@ -84,6 +93,7 @@ const lendingProtocols = [
makerConfig,
morphoBlueConfig,
sparkConfig,
skyConfig,
]

export const lendingProtocolsByName = keyBy(lendingProtocols, 'name')
98 changes: 98 additions & 0 deletions apps/rays-dashboard/public/img/protocol_icons/sky.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,11 @@
background-image: var(--gradient-protocol-spark);
}
}
&sky {
&::after {
background-image: var(--gradient-protocol-sky);
}
}
}

.navigationMenuDropdownContentListItemTitle {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ export type Styles = {
navigationMenuDropdownContentListItemTitleGradientajna: string
navigationMenuDropdownContentListItemTitleGradientmaker: string
navigationMenuDropdownContentListItemTitleGradientmorphoblue: string
navigationMenuDropdownContentListItemTitleGradientsky: string
navigationMenuDropdownContentListItemTitleGradientsparkv3: string
navigationMenuDropdownContentListItemWrapper: string
starTransition: string
Expand Down
1 change: 1 addition & 0 deletions packages/app-ui/src/styles/gradients.scss
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,5 @@
--gradient-protocol-maker: linear-gradient(135deg, #2dc1b1 0%, #139d8d 100%);
--gradient-protocol-morpho-blue: linear-gradient(92deg, #1859f2 0%, #00378a 89.02%);
--gradient-protocol-spark: linear-gradient(159deg, #f58013 12.26%, #f19d19 86.52%);
--gradient-protocol-sky: linear-gradient(159deg, #4a87fa 12.26%, #a294ee 86.52%);
}

0 comments on commit 4dd6d59

Please sign in to comment.