Closed iliyan-velichkov closed 2 weeks ago
Findings:
http://localhost/services/web/ide/
, the page loads correctly
Without opening the IDE: https://github.com/eclipse/dirigible/assets/5058839/2d9a46d6-9a10-42f3-9fe5-01ac7afd599e vs with opening the IDE first: https://github.com/eclipse/dirigible/assets/5058839/a4cc65c2-e086-4a72-8927-137d634a23d2
This is not a problem with forms or with incognito mode at all. It affects all views.
The "problem" is that in order to have proper theming, the theme
directive gets the theme config from local storage.
If there is no default config, it will get an empty object.
The default theme config is created in core-modules
by calling the theming
provider upon initial Dirigible load, not by the views.
And this is where the true "problem" is. Dirigible views are not meant to be viewed separately outside of Dirigible, so if you run them in a separate tab in a "clean" environment, the defaults will never be set.
If we want a view (in this case a form view) that uses Dirigibles UI, but is not a Dirigible view itself, to work outside of Dirigible, then we can inject the theming
provider in the Theme
factory inside components/resources/resources-core/src/main/resources/META-INF/dirigible/resources-core/ui/theming.js
.
Chrome Incognito mode
Video:
https://github.com/eclipse/dirigible/assets/5058839/2d9a46d6-9a10-42f3-9fe5-01ac7afd599e
vs
Safari:![image](https://github.com/eclipse/dirigible/assets/5058839/839b6a91-2e10-4562-9419-97fea368baad)