Uploaded image for project: 'OpenOLAT'
  1. OpenOLAT
  2. OO-2896

Add visual hint about character count when characters are limited

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 12.0
    • Component/s: Framework
    • Labels:

      Description

      In some forms wer have limits how many characters can be entered. When typing, the user has no clue how many characters he actually entered, he just gets an error when he typed too much. 

      The problem gets worse as on the server the count includes the HTML markup while the user only sees the character he types. E.g. when adding a table, a lot of markup is added that count for the limit as well. 

      The goal of this issue is to improve the situation for the user and give him a glimpse on how much space his text uses. 

      The best solution seems to be to show the actual character count including the HTML markup. By adding a help bubble we probably can explain why this is not the same as the user visible character. 

      ToDo: 

      • Add this plugin https://gist.github.com/321zeno/f9105f7865b2b2f7097d (did some test locally and the plugin works well)
      • Change the plugin to count the markup as well, maybe don't trigger it after every keyup
      • Make it aware of the limit of the element and add a css class when the limit is reached (e.g.  char count text will get red)

       

      Alternatively we could count only user displayable texts and reserve the double amount of space on the database tables to be on the save side. 

       

       

       

       

        Attachments

          Activity

            People

            Assignee:
            srosse Stéphane Rossé
            Reporter:
            gnaegi Florian Gnägi
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 2 hours, 20 minutes
                2h 20m