mirror of
https://github.com/RoboSats/robosats.git
synced 2025-09-13 00:56:22 +00:00
@ -102,7 +102,7 @@ const DepthChart: React.FC<DepthChartProps> = ({
|
|||||||
const prices: number[] = enrichedOrders.map((order) => order?.base_price ?? 0);
|
const prices: number[] = enrichedOrders.map((order) => order?.base_price ?? 0);
|
||||||
|
|
||||||
const medianValue = ~~matchMedian(prices);
|
const medianValue = ~~matchMedian(prices);
|
||||||
const maxValue = prices.sort((a, b) => b - a).slice(0, 1)[0] ?? 1500;
|
const maxValue = prices.sort((a, b) => b - a).slice(0, 1)[0] ?? 0;
|
||||||
const maxRange = maxValue - medianValue;
|
const maxRange = maxValue - medianValue;
|
||||||
const rangeSteps = maxRange / 10;
|
const rangeSteps = maxRange / 10;
|
||||||
|
|
||||||
@ -261,11 +261,21 @@ const DepthChart: React.FC<DepthChartProps> = ({
|
|||||||
|
|
||||||
const formatAxisX = (value: number): string => {
|
const formatAxisX = (value: number): string => {
|
||||||
if (xType === 'base_price') {
|
if (xType === 'base_price') {
|
||||||
return value.toString();
|
let formatted = value;
|
||||||
|
if (value > 1000000) {
|
||||||
|
formatted = formatted / 1000000;
|
||||||
|
return `${formatted}M`;
|
||||||
|
} else if (value > 1000) {
|
||||||
|
formatted = formatted / 1000;
|
||||||
|
return `${formatted}K`;
|
||||||
|
} else {
|
||||||
|
return value.toString();
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
return `${value}%`;
|
||||||
}
|
}
|
||||||
return `${value}%`;
|
|
||||||
};
|
};
|
||||||
const formatAxisY = (value: number): string => `${value}BTC`;
|
const formatAxisY = (value: number): string => `${value}₿`;
|
||||||
const handleOnClick: PointMouseHandler = (point: Point) => {
|
const handleOnClick: PointMouseHandler = (point: Point) => {
|
||||||
onOrderClicked(point.data?.order?.id, point.data?.order?.coordinatorShortAlias);
|
onOrderClicked(point.data?.order?.id, point.data?.order?.coordinatorShortAlias);
|
||||||
};
|
};
|
||||||
@ -361,10 +371,7 @@ const DepthChart: React.FC<DepthChartProps> = ({
|
|||||||
</Grid>
|
</Grid>
|
||||||
</Grid>
|
</Grid>
|
||||||
</Grid>
|
</Grid>
|
||||||
<Grid
|
<Grid container style={{ height: `${height * 0.9}em`, width: '100%', padding: '1em' }}>
|
||||||
container
|
|
||||||
style={{ height: `${height * 0.825}em`, width: '100%', padding: '1em' }}
|
|
||||||
>
|
|
||||||
<ResponsiveLine
|
<ResponsiveLine
|
||||||
data={series}
|
data={series}
|
||||||
enableArea={true}
|
enableArea={true}
|
||||||
@ -384,7 +391,7 @@ const DepthChart: React.FC<DepthChartProps> = ({
|
|||||||
format: formatAxisX,
|
format: formatAxisX,
|
||||||
}}
|
}}
|
||||||
margin={{
|
margin={{
|
||||||
left: 4.64 * em,
|
left: 3 * em,
|
||||||
right: 0.714 * em,
|
right: 0.714 * em,
|
||||||
bottom:
|
bottom:
|
||||||
xType === 'base_price'
|
xType === 'base_price'
|
||||||
|
|||||||
@ -439,7 +439,6 @@ const AutocompletePayments: React.FC<AutocompletePaymentsProps> = (props) => {
|
|||||||
{value.length > 0 && !props.multiple ? null : (
|
{value.length > 0 && !props.multiple ? null : (
|
||||||
<input
|
<input
|
||||||
ref={filterInputRef}
|
ref={filterInputRef}
|
||||||
autoFocus={true}
|
|
||||||
style={
|
style={
|
||||||
props.isFilter
|
props.isFilter
|
||||||
? {
|
? {
|
||||||
|
|||||||
@ -86,9 +86,11 @@ const EncryptedChat: React.FC<Props> = ({
|
|||||||
|
|
||||||
const wrappedEvent = nip17.wrapEvent(slot?.nostrSecKey, recipient, content);
|
const wrappedEvent = nip17.wrapEvent(slot?.nostrSecKey, recipient, content);
|
||||||
|
|
||||||
const oneMonth = 2419200;
|
const fourteenDays = 14 * 24 * 60 * 60;
|
||||||
|
const randomSeconds = Math.floor(Math.random() * fourteenDays);
|
||||||
|
const expirationTime = Math.floor(Date.now() / 1000) + fourteenDays + randomSeconds;
|
||||||
|
|
||||||
wrappedEvent.tags.push(['expiration', (wrappedEvent.created_at + oneMonth).toString()]);
|
wrappedEvent.tags.push(['expiration', expirationTime.toString()]);
|
||||||
|
|
||||||
federation.roboPool.sendEvent(wrappedEvent);
|
federation.roboPool.sendEvent(wrappedEvent);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
|
|||||||
@ -9,12 +9,12 @@ RoboSats v0.8.1-alpha is now out! :rocket:
|
|||||||
|
|
||||||
# Android
|
# Android
|
||||||
|
|
||||||
**[Click to download universal RoboSats APK for Android](https://github.com/RoboSats/robosats/releases/download/v0.8.1-alpha/robosats-v0.8.1.alpha-universal.apk)**
|
**[Click to download universal RoboSats APK for Android](https://github.com/RoboSats/robosats/releases/download/v0.8.1-alpha/robosats-v0.8.1.alpha-universal.short_sha.apk)**
|
||||||
Smaller bundles for each CPU architecture available in the attachments.
|
Smaller bundles for each CPU architecture available in the attachments.
|
||||||
|
|
||||||
### Verify the app using GPG:
|
### Verify the app using GPG:
|
||||||
|
|
||||||
1. [Download the ascii armored signature](https://github.com/Reckless-Satoshi/robosats/releases/download/v0.8.1-alpha/robosats-v0.8.1.alpha-universal.${{ steps.short-sha.outputs.short_sha }}.apk.asc)
|
1. [Download the ascii armored signature](https://github.com/Reckless-Satoshi/robosats/releases/download/v0.8.1-alpha/robosats-v0.8.1.alpha-universal.short_sha.apk.asc)
|
||||||
|
|
||||||
2. Run this command on a directory that contains the apk file and and the ascii armored signature.
|
2. Run this command on a directory that contains the apk file and and the ascii armored signature.
|
||||||
`gpg --verify robosats-v0.8.1.alpha-universal.apk.asc`
|
`gpg --verify robosats-v0.8.1.alpha-universal.apk.asc`
|
||||||
@ -28,17 +28,17 @@ Additionally, you can download it from [Izzysoft repository](https://apt.izzysof
|
|||||||
**Download the Desktop App zip file**
|
**Download the Desktop App zip file**
|
||||||
Find the zip file that suits with your operative system:
|
Find the zip file that suits with your operative system:
|
||||||
|
|
||||||
- [Windows](https://github.com/RoboSats/robosats/releases/download/v0.8.1-alpha/robosats-desktop-v0.8.1.alpha-win32-ia32.${{ steps.short-sha.outputs.short_sha }}.zip)
|
- [Windows](https://github.com/RoboSats/robosats/releases/download/v0.8.1-alpha/robosats-desktop-v0.8.1.alpha-win32-ia32.short_sha.zip)
|
||||||
- [Mac](https://github.com/RoboSats/robosats/releases/download/v0.8.1-alpha/robosats-desktop-v0.8.1.alpha-mac-darwin-x64.${{ steps.short-sha.outputs.short_sha }}.zip)
|
- [Mac](https://github.com/RoboSats/robosats/releases/download/v0.8.1-alpha/robosats-desktop-v0.8.1.alpha-mac-darwin-x64.short_sha.zip)
|
||||||
- [Linux](https://github.com/RoboSats/robosats/releases/download/v0.8.1-alpha/robosats-desktop-v0.8.1.alpha-linux-x64.${{ steps.short-sha.outputs.short_sha }}.zip)
|
- [Linux](https://github.com/RoboSats/robosats/releases/download/v0.8.1-alpha/robosats-desktop-v0.8.1.alpha-linux-x64.short_sha.zip)
|
||||||
|
|
||||||
### Verify the app using GPG:
|
### Verify the app using GPG:
|
||||||
|
|
||||||
1. Download the ascii armored signature:
|
1. Download the ascii armored signature:
|
||||||
|
|
||||||
- [Windows](https://github.com/RoboSats/robosats/releases/download/v0.8.1-alpha/robosats-desktop-v0.8.1.alpha-win32-ia32.${{ steps.short-sha.outputs.short_sha }}.zip.asc)
|
- [Windows](https://github.com/RoboSats/robosats/releases/download/v0.8.1-alpha/robosats-desktop-v0.8.1.alpha-win32-ia32.short_sha.zip.asc)
|
||||||
- [Mac](https://github.com/RoboSats/robosats/releases/download/v0.8.1-alpha/robosats-desktop-v0.8.1.alpha-mac-darwin-x64.${{ steps.short-sha.outputs.short_sha }}.zip.asc)
|
- [Mac](https://github.com/RoboSats/robosats/releases/download/v0.8.1-alpha/robosats-desktop-v0.8.1.alpha-mac-darwin-x64.short_sha.zip.asc)
|
||||||
- [Linux](https://github.com/RoboSats/robosats/releases/download/v0.8.1-alpha/robosats-desktop-v0.8.1.alpha-linux-x64.${{ steps.short-sha.outputs.short_sha }}.zip.asc)
|
- [Linux](https://github.com/RoboSats/robosats/releases/download/v0.8.1-alpha/robosats-desktop-v0.8.1.alpha-linux-x64.short_sha.zip.asc)
|
||||||
|
|
||||||
3. Run this command on a directory that contains the apk file and and the ascii armored signature.
|
3. Run this command on a directory that contains the apk file and and the ascii armored signature.
|
||||||
`gpg --verify robosats-v0.8.1.alpha-....asc`
|
`gpg --verify robosats-v0.8.1.alpha-....asc`
|
||||||
|
|||||||
Reference in New Issue
Block a user