Fix reminder background color

Signed-off-by: Egor Savkin <es@m-labs.hk>
This commit is contained in:
Egor Savkin 2024-01-23 16:30:27 +08:00
parent 9d5ed66985
commit 3366f80ed7
3 changed files with 5 additions and 5 deletions

File diff suppressed because one or more lines are too long

View File

@ -15,8 +15,8 @@ export function CardWarnings({crate_index, card_index}) {
placement="bottom" placement="bottom"
trigger={['click', 'hover', 'focus']} trigger={['click', 'hover', 'focus']}
overlay={ overlay={
({arrowProps, hasDoneInitialMeasure, show, ...props}) => ( ({arrowProps, hasDoneInitialMeasure, show, style, ...props}) => (
<div className="k-popup-warning" {...props}> <div className="k-popup-warning" style={{...style, backgroundColor: max_level.color}} {...props}>
{warnings.map((warning, _i) => { {warnings.map((warning, _i) => {
return ( return (
<p className="rule warning" key={`warnmsg_${card_index}_${warning.name}`}> <p className="rule warning" key={`warnmsg_${card_index}_${warning.name}`}>
@ -28,7 +28,7 @@ export function CardWarnings({crate_index, card_index}) {
} }
rootClose rootClose
> >
<img className="alert-warning" src={max_level.icon}/> <img className="alert-warning p-0" src={max_level.icon}/>
</OverlayTrigger> </OverlayTrigger>
) )
} }

View File

@ -9,7 +9,7 @@ import {item_occupied_counters, resource_counters} from "./count_resources";
import {useShopStore} from "./shop_store"; import {useShopStore} from "./shop_store";
export const Levels = { export const Levels = {
"reminder": {priority: 1, icon: '/images/shop/icon-reminder.svg', color: "black"}, "reminder": {priority: 1, icon: '/images/shop/icon-reminder.svg', color: "#0d3547"},
"warning": {priority: 2, icon: '/images/shop/icon-warning.svg', color: "#c75e5e"}, "warning": {priority: 2, icon: '/images/shop/icon-warning.svg', color: "#c75e5e"},
} }