os-js / osjs-client

OS.js Client Module
https://manual.os-js.org/
Other
30 stars 30 forks source link

Alert message display is not the same in different browsers #212

Closed maryam4s26 closed 5 months ago

maryam4s26 commented 6 months ago

Hi @andersevenrud. I have an error in the server, but the Alert message display is not the same in different browsers.

Error in server: image

in google chrome: image

in firefox: image

in Microsoft Edge image_2024_01_08T19_32_14_780Z

in safari: image

andersevenrud commented 6 months ago

The actual stack could vary between browser engines depending on how they read the sourcemaps, however this should not affect the actual error message.

So this must be a problem with how the dialog builds the displayed error:

https://github.com/os-js/osjs-dialogs/blob/bf88b9300fbe7fbc268748041a7e9306bc173a28/src/dialogs/alert.js#L85-L92

This maybe should display error.message in addition to error.stack directly.

andersevenrud commented 6 months ago

If you're up for a small quest, feel free to look into this one and submit a PR :)

maryam4s26 commented 6 months ago

Sure. thank you :D

andersevenrud commented 5 months ago

This was fixed and released with @osjs/dialogs@3.2.2