mirror of
https://github.com/freqtrade/frequi.git
synced 2024-11-21 23:53:52 +00:00
Improve some subtle bugs
This commit is contained in:
parent
81a445f44c
commit
1fdd72908c
|
@ -181,18 +181,18 @@ const isResizableLayout = computed(() =>
|
|||
['', 'sm', 'md', 'lg', 'xl'].includes(currentBreakpoint.value),
|
||||
);
|
||||
const isLayoutLocked = computed(() => {
|
||||
return layoutStore.layoutLocked || !isResizableLayout;
|
||||
return layoutStore.layoutLocked || !isResizableLayout.value;
|
||||
});
|
||||
|
||||
const gridLayoutData = computed((): GridItemData[] => {
|
||||
if (isResizableLayout) {
|
||||
if (isResizableLayout.value) {
|
||||
return layoutStore.dashboardLayout;
|
||||
}
|
||||
return [...layoutStore.getDashboardLayoutSm];
|
||||
});
|
||||
|
||||
const layoutUpdatedEvent = (newLayout) => {
|
||||
if (isResizableLayout) {
|
||||
if (isResizableLayout.value) {
|
||||
console.log('newlayout', newLayout);
|
||||
console.log('saving dashboard');
|
||||
layoutStore.dashboardLayout = newLayout;
|
||||
|
|
|
@ -177,10 +177,10 @@ const isResizableLayout = computed(() =>
|
|||
['', 'sm', 'md', 'lg', 'xl'].includes(currentBreakpoint.value),
|
||||
);
|
||||
const isLayoutLocked = computed(() => {
|
||||
return layoutStore.layoutLocked || !isResizableLayout;
|
||||
return layoutStore.layoutLocked || !isResizableLayout.value;
|
||||
});
|
||||
const gridLayoutData = computed((): GridItemData[] => {
|
||||
if (isResizableLayout) {
|
||||
if (isResizableLayout.value) {
|
||||
return layoutStore.tradingLayout;
|
||||
}
|
||||
return [...layoutStore.getTradingLayoutSm];
|
||||
|
|
|
@ -10,7 +10,7 @@ describe('formatters.ts', () => {
|
|||
expect(formatPriceCurrency(5123.551123, 'USDT', 3)).toEqual('5123.551 USDT');
|
||||
expect(formatPriceCurrency(5123.551123, 'USDT')).toEqual('5123.551 USDT');
|
||||
expect(formatPriceCurrency(5123.551123, 'USDT', 5)).toEqual('5123.55112 USDT');
|
||||
expect(formatPriceCurrency(5123.5511230000000001, 'USDT', 5)).toEqual('5123.55112 USDT');
|
||||
expect(formatPriceCurrency(5123.551123000001, 'USDT', 5)).toEqual('5123.55112 USDT');
|
||||
expect(formatPriceCurrency(0.00001, 'BTC', 5)).toEqual('0.00001 BTC');
|
||||
});
|
||||
|
||||
|
@ -18,7 +18,7 @@ describe('formatters.ts', () => {
|
|||
expect(formatPrice(5123.5123512)).toEqual('5123.5123512');
|
||||
expect(formatPrice(5123.5123512, 8)).toEqual('5123.5123512');
|
||||
expect(formatPrice(5123.5123512, 3)).toEqual('5123.512');
|
||||
expect(formatPrice(5123.51200000000000001, 8)).toEqual('5123.512');
|
||||
expect(formatPrice(5123.512000000001, 8)).toEqual('5123.512');
|
||||
expect(formatPrice(0.001, 3)).toEqual('0.001');
|
||||
expect(formatPrice(0.0019, 3)).toEqual('0.002');
|
||||
expect(formatPrice(2.701e-9, 3)).toEqual('0');
|
||||
|
|
Loading…
Reference in New Issue
Block a user