Merge branch 'main' of github.com:ghostfolio/ghostfolio
All checks were successful
Docker image CD / build_and_push (push) Successful in 20m22s
All checks were successful
Docker image CD / build_and_push (push) Successful in 20m22s
This commit is contained in:
commit
e81bd4b51f
@ -12,10 +12,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||||||
- Added a new static portfolio analysis rule: _Regional Market Cluster Risk_ (Europe)
|
- Added a new static portfolio analysis rule: _Regional Market Cluster Risk_ (Europe)
|
||||||
- Added a link to _Duck.ai_ to the _Copy AI prompt to clipboard_ action on the analysis page (experimental)
|
- Added a link to _Duck.ai_ to the _Copy AI prompt to clipboard_ action on the analysis page (experimental)
|
||||||
- Extracted the tags selector to a reusable component used in the create or update activity dialog and holding detail dialog
|
- Extracted the tags selector to a reusable component used in the create or update activity dialog and holding detail dialog
|
||||||
|
- Added stories for the tags selector component
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
|
|
||||||
- Improved the caching of the portfolio snapshot in the portfolio calculator by expiring cache entries when a user changes tags in the holding detail dialog
|
- Improved the caching of the portfolio snapshot in the portfolio calculator by expiring cache entries when a user changes tags in the holding detail dialog
|
||||||
|
- Improved the error handling in the _CoinGecko_ service
|
||||||
- Improved the language localization for German (`de`)
|
- Improved the language localization for German (`de`)
|
||||||
- Upgraded `svgmap` from version `2.6.0` to `2.12.2`
|
- Upgraded `svgmap` from version `2.6.0` to `2.12.2`
|
||||||
|
|
||||||
|
@ -112,7 +112,7 @@ export class CoinGeckoService implements DataProviderInterface {
|
|||||||
[symbol: string]: { [date: string]: IDataProviderHistoricalResponse };
|
[symbol: string]: { [date: string]: IDataProviderHistoricalResponse };
|
||||||
}> {
|
}> {
|
||||||
try {
|
try {
|
||||||
const { prices } = await fetch(
|
const { error, prices, status } = await fetch(
|
||||||
`${
|
`${
|
||||||
this.apiUrl
|
this.apiUrl
|
||||||
}/coins/${symbol}/market_chart/range?vs_currency=${DEFAULT_CURRENCY.toLowerCase()}&from=${getUnixTime(
|
}/coins/${symbol}/market_chart/range?vs_currency=${DEFAULT_CURRENCY.toLowerCase()}&from=${getUnixTime(
|
||||||
@ -124,6 +124,14 @@ export class CoinGeckoService implements DataProviderInterface {
|
|||||||
}
|
}
|
||||||
).then((res) => res.json());
|
).then((res) => res.json());
|
||||||
|
|
||||||
|
if (error?.status) {
|
||||||
|
throw new Error(error.status.error_message);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (status) {
|
||||||
|
throw new Error(status.error_message);
|
||||||
|
}
|
||||||
|
|
||||||
const result: {
|
const result: {
|
||||||
[symbol: string]: { [date: string]: IDataProviderHistoricalResponse };
|
[symbol: string]: { [date: string]: IDataProviderHistoricalResponse };
|
||||||
} = {
|
} = {
|
||||||
|
@ -25,7 +25,7 @@ export const Large: Story = {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
export const NoLabel: Story = {
|
export const WithoutLabel: Story = {
|
||||||
args: {
|
args: {
|
||||||
showLabel: false
|
showLabel: false
|
||||||
}
|
}
|
||||||
|
@ -0,0 +1,62 @@
|
|||||||
|
import { CommonModule } from '@angular/common';
|
||||||
|
import { NoopAnimationsModule } from '@angular/platform-browser/animations';
|
||||||
|
import { Meta, moduleMetadata, StoryObj } from '@storybook/angular';
|
||||||
|
|
||||||
|
import { GfTagsSelectorComponent } from './tags-selector.component';
|
||||||
|
|
||||||
|
export default {
|
||||||
|
title: 'Tags Selector',
|
||||||
|
component: GfTagsSelectorComponent,
|
||||||
|
decorators: [
|
||||||
|
moduleMetadata({
|
||||||
|
imports: [CommonModule, NoopAnimationsModule]
|
||||||
|
})
|
||||||
|
]
|
||||||
|
} as Meta<GfTagsSelectorComponent>;
|
||||||
|
|
||||||
|
type Story = StoryObj<GfTagsSelectorComponent>;
|
||||||
|
|
||||||
|
const OPTIONS = [
|
||||||
|
{
|
||||||
|
id: '3ef7e6d9-4598-4eb2-b0e8-00e61cfc0ea6',
|
||||||
|
name: 'Gambling',
|
||||||
|
userId: 'c6a71541-d0e3-4e22-ae83-b5e5611b6695'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 'EMERGENCY_FUND',
|
||||||
|
name: 'Emergency Fund',
|
||||||
|
userId: null
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 'RETIREMENT_FUND',
|
||||||
|
name: 'Retirement Fund',
|
||||||
|
userId: null
|
||||||
|
}
|
||||||
|
];
|
||||||
|
|
||||||
|
export const Default: Story = {
|
||||||
|
args: {
|
||||||
|
tags: [
|
||||||
|
{
|
||||||
|
id: 'EMERGENCY_FUND',
|
||||||
|
name: 'Emergency Fund',
|
||||||
|
userId: null
|
||||||
|
}
|
||||||
|
],
|
||||||
|
tagsAvailable: OPTIONS
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
export const WithoutValue: Story = {
|
||||||
|
args: {
|
||||||
|
tags: [],
|
||||||
|
tagsAvailable: OPTIONS
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
export const WithoutOptions: Story = {
|
||||||
|
args: {
|
||||||
|
tags: [],
|
||||||
|
tagsAvailable: []
|
||||||
|
}
|
||||||
|
};
|
Loading…
x
Reference in New Issue
Block a user