Giter Site home page Giter Site logo

Comments (3)

C0rn3j avatar C0rn3j commented on May 25, 2024

@xet7
I found the culprit:

wekan/models/lists.js

Lines 341 to 343 in 902f86d

if (newColor === 'silver') {
newColor = null;
}

wekan/models/swimlanes.js

Lines 296 to 298 in 902f86d

if (newColor === 'silver') {
newColor = null;
}

Current status of colors -

Green:
image

Silver - hardcoded HTML - CSS makes the color unset, looks the same when color is set to #e4e4e4:
image

Null - identical to Silver, at least in this view:
image

White (broken):
image

Null UI when opening colors defaulting to white:

image

This is however broken, when opening the UI, white looks selected, but in reality isn't.
One has to click on it to be ACTUALLY selected, and then it applies, but it just looks broken and moves the text element as opposed to every other color.

Additionally, the CSS for white is broken, resulting in broken rendering:

image

Fixing the CSS by commenting out the extra border line looks like this:

image

# client/components/lists/lists.css
.list-header-white {
  border-bottom: 6px solid #fff;
#  border: 1px solid #eee;
}
.list-header-green {
  border-bottom: 6px solid #3cb500;
}
.list-header-yellow {
  border-bottom: 6px solid #fad900;
}

So there are actually multiple issues with List colors.

  1. Broken CSS for white List color - Fixed in #5400
  2. List refuses to be set to silver because it is the default color, which may be a fine idea, but this is not really obvious and the UI makes it even more confusing by both allowing to SET silver and UNSET color, both of which null out the color value - Fixed in #5401
  3. Because silver is null, default selected color when null is defined will be position 0, which is white, not silver
  4. Color selector does not actually have the element selected, so using Save upon just opening the dialogue is broken (made apparent by the 3rd issue)
  5. Because SETting silver actually unsets the color value, it confuses the poor programmer (me) who is trying to set Card colors to the same color as the List and not seeing it in the List data
  6. Since the CSS is unset in the case of null, some designs are breaking, for example:
    image
    Which is very apparent when it's the last List in the list

I suggest to actually set color to silver if user/API forces it via Save or Edit, and just have null be the default value as it is right now, which currently points to silver, but actually set it in CSS.
Perhaps someone would want to theme WeKan in the future, and not being able to change the now-different default to silver would impede them.
Dark Reader also does not seem to be enjoying the unset value:

Silver:

image

In which case it would be nice to actually set the color here too to #e4e4e4 (because it's not currently valid CSS) instead of relying on the background: CSS file itself fixed in #5400 but is not being applied yet

.list-header-silver {
  border-bottom: 6px solid unset;
}

from wekan.

xet7 avatar xet7 commented on May 25, 2024

Fixed at #5400

from wekan.

C0rn3j avatar C0rn3j commented on May 25, 2024

That unfortunately only fixed one of the six issues, please re-open.

from wekan.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.