enketo-express icon indicating copy to clipboard operation
enketo-express copied to clipboard

Improve performance of theme-switching

Open enketo-issue-mover opened this issue 6 years ago • 4 comments

From @MartijnR on July 31, 2015 16:56

Theme determination and stylesheet switching was implemented on the client for the future mobile app, but it causes too much screen flickering in the online-only views.

Since the API-set value always wins, we could at least serve the correct api-set stylesheet.

Ideally we would also store the form-defined style in the database (thereby duplicating the theme-determination logic on the client).

Copied from original issue: kobotoolbox/enketo-express#277

enketo-issue-mover avatar Oct 25 '18 23:10 enketo-issue-mover

From @MartijnR on July 31, 2015 20:28

This wouldn't work in the offline view, because the html served should be constant.

enketo-issue-mover avatar Oct 25 '18 23:10 enketo-issue-mover

From @MartijnR on July 31, 2015 20:40

also can't really work for previews.

Alternatively, we could load all theme stylesheets in preview and remove the applicable themes after theme determination on the client.

enketo-issue-mover avatar Oct 25 '18 23:10 enketo-issue-mover

From @MartijnR on September 18, 2015 22:6

The first thing we can do is check if the theme is already loaded. Even swapping with same theme seems to cause flickering!

enketo-issue-mover avatar Oct 25 '18 23:10 enketo-issue-mover

From @MartijnR on April 5, 2018 21:14

flickering to be addressed by https://github.com/kobotoolbox/enketo-express/issues/981.

This issue will be changed into improving theme-switching performance.

enketo-issue-mover avatar Oct 25 '18 23:10 enketo-issue-mover