server icon indicating copy to clipboard operation
server copied to clipboard

Fix background theming deletion and cypress admin theming tests

Open skjnldsv opened this issue 2 years ago • 6 comments

Leftover from https://github.com/nextcloud/server/pull/35666... Restore cypress proper testing specs... :face_exhaling:

  • [x] Also added a new test to increase coverage
  • [x] Fixed other found issues regarding user defaults not following the instance background if removed
  • [x] Adjusted some more testing
  • [x] Fixed proper cleanup of admin settings when undoing an image setting

Follwup:

  • Found some issues regarding how we override the #0082c9 colour with accessibility colour #006aa3. Will clarify with design team afterwards

skjnldsv avatar Dec 11 '22 11:12 skjnldsv

Failure related to https://github.com/nextcloud/server/pull/35547 It seems hasImage returns true despite the background being deleted https://github.com/nextcloud/server/blob/9597036b7280940c834c623de4bb1716cb6fcf4a/apps/theming/lib/Themes/CommonThemeTrait.php#L104

Investigating

skjnldsv avatar Dec 11 '22 14:12 skjnldsv

This actually goes deeper, this comes from https://github.com/nextcloud/server/pull/30624

Where we remove the check of the file existing, but to remove the background, we set the mime to 'backgroundColor'. So the mime config key is set but the file doesn't exists. Since we don't check the file anymore since 24, the theming always assume there is an available background defined even if we only disabled the background https://github.com/nextcloud/server/blob/2f7a1fca5f1e2a14bcda169b9e8e8da14e720f2c/apps/theming/src/components/admin/FileInputField.vue#L207-L210

skjnldsv avatar Dec 11 '22 15:12 skjnldsv

cypress failure ? or needs rebase / restart ?

PVince81 avatar Dec 16 '22 15:12 PVince81

cypress failure ? or needs rebase / restart ?

Need me to find time to dive into this again :see_no_evil: image

skjnldsv avatar Dec 16 '22 15:12 skjnldsv

@skjnldsv is this still relevant?

szaimen avatar Apr 13 '23 10:04 szaimen

Yes we should but I don't have time for this unfortunately :/

skjnldsv avatar Apr 13 '23 11:04 skjnldsv