lettura icon indicating copy to clipboard operation
lettura copied to clipboard

fix: colour scheme not persisting & incorrect initialization

Open neil-lobo opened this issue 9 months ago • 0 comments

Fixed Issues:

  1. After changing your colour scheme and restarting the application, your colour scheme would not persist.
  2. The selection ring around the currently selected colour scheme was being incorrectly applied
  3. Initialization of colour scheme was incorrect

Cause 1:

After the client sends a POST request to this endpoint https://github.com/zhanglun/lettura/blob/7a66c923b1b9f7604d9a96b9556817ddcdb9b6ad/src-tauri/src/server/handlers/common.rs#L16-L20 the payload is deserialized incorrectly due to missing field color_scheme in the UserConfig struct: https://github.com/zhanglun/lettura/blob/7a66c923b1b9f7604d9a96b9556817ddcdb9b6ad/src-tauri/src/core/config.rs#L56-L68 resulting in colour scheme information not being saved.

neil-lobo avatar Apr 26 '24 03:04 neil-lobo