szymsza / degiro-statistics

Chromium extension to show interesting portfolio statistics at the website of broker Degiro
MIT License
2 stars 0 forks source link

New degiro style - not rendering #1

Open SonGokussj4 opened 2 years ago

SonGokussj4 commented 2 years ago

Hi, wanted to try your extension but it won't render on the newly styled Degiro. Image here

Any change for an update? Thanks

szymsza commented 2 years ago

Hi,

Thanks for reporting the problem. However, I am unable to reproduce the issue.

I assume the problem is that the table that the extension uses as a template is not present on your page for some reason. Could you help me verify this?

Firstly, document.querySelectorAll("[data-name=positions][data-empty=false]").length should give you the number of all relevant tables on the page. It should be greater than one.

Secondly, Array.from(document.querySelectorAll("[data-name=positions][data-empty=false]")).filter((i) => (typeof i.dataset === "object" && i.dataset.name === "positions" && i.dataset.empty === "false" && (!i.querySelector("tbody tr [data-field='value']") || !i.querySelector("tbody tr [data-field='totalPl']")))).length should give you the number of available template tables. It should be greater than one, but smaller than the first number.

Please let me know what is the result when you run these expressions in the browser console on Portfolio page.

Thank you for the cooperation.

SonGokussj4 commented 2 years ago

The first one gave me 2, the second one 1

Edit: Not sure why, but it gives me a different error now (image).