Centered in the Kanban view

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • ChrisSka83
    Senior Member
    • Apr 2023
    • 197

    Centered in the Kanban view

    Hello everyone,

    would it somehow be possible to insert a center in the Kanban view in the layout settings?
    At the moment there is only left or right.
    I know you could insert a wysiwyg field, center it and then insert it.
    But I only wanted to insert an image now, because I create an image for tasks. This would look better centered than left or right.​

    Click image for larger version

Name:	image.png
Views:	137
Size:	57.4 KB
ID:	106306
  • shalmaxb
    Senior Member
    • Mar 2015
    • 1605

    #2
    perhaps you can add the option here: client/src/views/admin/layouts line 47
    and to make it update safe, copy that file to the client/custom/views/admin/layouts

    Comment

    • ChrisSka83
      Senior Member
      • Apr 2023
      • 197

      #3
      Unfortunately it does not work.
      I have the following code in line 47:
      options: ['left', 'right', 'center'],

      But the entry “Centered” does not appear at all.
      Cache and rebuild also done​

      Comment

      • rabii
        Active Community Member
        • Jun 2016
        • 1250

        #4
        That section is not customizable AFAK.
        Rabii
        Web Dev

        Comment

        • eymen-elkum
          Active Community Member
          • Nov 2014
          • 472

          #5
          Hi Chris,

          This is not supported unfortunately.

          There is a workaround using css, see the following css style:

          Code:
          div.list-kanban>div>table .item .field[data-name="parent"] {
              text-align: center;
          }​​
          parent was just an example of a field name, try to replace it with your own field name.

          Expected issue: if you have field with the same name with another entity will be affected with the style in kanban view.

          To add custom css follow this:

          CEO of Eblasoft
          EspoCRM Expert since 2014
          Full Stack Web Developer since 2008
          Creator of Numerous Successful Extensions & Projects​

          Comment


          • ChrisSka83
            ChrisSka83 commented
            Editing a comment
            Thank you
            that works great. I hadn't even thought of that idea.
            But would not be bad for others if this could be inserted centered there in the settings.

            Now I can remove my additional Wysiwyg field again.
            I hadn't thought of any other solution before.

          • eymen-elkum
            eymen-elkum commented
            Editing a comment
            You are welcome,

            Css with good selectors can solve many problems

            Anyway, I think this small feature must be implemented on the core.
        Working...