diff --git a/docs/_sass/minimal-mistakes/skins/_robosats.scss b/docs/_sass/minimal-mistakes/skins/_robosats.scss index b2a98c31..2ba71171 100644 --- a/docs/_sass/minimal-mistakes/skins/_robosats.scss +++ b/docs/_sass/minimal-mistakes/skins/_robosats.scss @@ -5,7 +5,7 @@ /* Colors */ $background-color: #ffffff !default; $text-color: #2c2c2c !default; -$muted-text-color: #393e46 !default; +$muted-text-color: hsl(217, 10%, 25%) !default; $primary-color: #1976d2 !default; $primary-light-color: #42a5f5 !default; $primary-dark-color: #1565c0 !default; diff --git a/frontend/src/components/BookTable/BookControl.tsx b/frontend/src/components/BookTable/BookControl.tsx index e6e72020..afa1d682 100644 --- a/frontend/src/components/BookTable/BookControl.tsx +++ b/frontend/src/components/BookTable/BookControl.tsx @@ -22,6 +22,8 @@ import CheckBoxOutlineBlankIcon from '@mui/icons-material/CheckBoxOutlineBlank'; import SwapCalls from '@mui/icons-material/SwapCalls'; import { FederationContext, type UseFederationStoreType } from '../../contexts/FederationContext'; import RobotAvatar from '../RobotAvatar'; +import RoboSats from '../Icons/RoboSats'; +import RoboSatsNoText from '../Icons/RoboSatsNoText'; interface BookControlProps { width: number; @@ -350,6 +352,11 @@ const BookControl = ({ + +
+ +
+
{federation .getCoordinators() .filter((coord) => coord.enabled) diff --git a/frontend/src/utils/filterOrders.ts b/frontend/src/utils/filterOrders.ts index a6baf29d..dab9cace 100644 --- a/frontend/src/utils/filterOrders.ts +++ b/frontend/src/utils/filterOrders.ts @@ -1,4 +1,4 @@ -import { type PublicOrder, type Favorites, type Federation } from '../models'; +import { type PublicOrder, type Favorites, type Federation, Coordinator } from '../models'; import thirdParties from '../../static/thirdparties.json'; interface AmountFilter { @@ -28,9 +28,16 @@ const filterByPayment = function (order: PublicOrder, paymentMethods: any[]): bo } }; -const filterByHost = function (order: PublicOrder, shortAlias: string): boolean { +const filterByHost = function ( + order: PublicOrder, + shortAlias: string, + federation: Federation, +): boolean { if (shortAlias === 'any') { return true; + } else if (shortAlias == 'robosats') { + const coordinator = federation.getCoordinator(order.coordinatorShortAlias ?? ''); + return coordinator?.federated ?? false; } else { return order.coordinatorShortAlias === shortAlias; } @@ -84,8 +91,7 @@ const filterOrders = function ({ const paymentMethodChecks = paymentMethods.length > 0 ? filterByPayment(order, paymentMethods) : true; const amountChecks = amountFilter !== null ? filterByAmount(order, amountFilter) : true; - const hostChecks = - baseFilter.coordinator !== 'any' ? filterByHost(order, baseFilter.coordinator) : true; + const hostChecks = filterByHost(order, baseFilter.coordinator, federation); return ( coordinatorCheck && typeChecks &&