Uploaded image for project: 'Wicket'
  1. Wicket
  2. WICKET-4831 Append the feedback message CSS class instead of overriding it
  3. WICKET-4852

Do not set CSS class on the li > span element for a feedback message

    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 6.2.0
    • 7.0.0-M1
    • wicket
    • None

    Description

      In a mail discussion http://markmail.org/thread/glqn5n6lneh5fkjr has been proposed:

      Martin Grigorov:

      • <div> element should have class "feedbackPanel" (this is already the case)
      • <li> element(s) should have class that specifies the feedback
        message level (currently by default Wicket sets "feedbackPanelLEVEL",
        but this is configurable with
        org.apache.wicket.markup.html.panel.FeedbackPanel#getCSSClass(FeedbackMessage))
      • the <span> should not have class at all (currently it has the same
        class as the <li> element)
      • the styling should be done with CSS selectors (e.g.
        div.feedbackPanel; div.feedbackPanel li.alert-warn; div.feedbackPanel
        li.alert-warn span; ...)
      • if custom markup is needed then a custom FeedbackPanel is needed
        (one that extends from the default FeedbackPanel or a completely new
        one, it depends on the use case)

      Sven Meier:

      To ease extending of FeedbackPanel I'd suggest to delegate #newItem() of the
      nested MessageListView to a new protected method #newMessageItem() in
      FeedbackPanel. (Similar to DataTable#newRowItem())

      Since we cannot make these improvements for 6.x because it may break applications which depend on this behavior we will postpone them for Wicket 7.

      Attachments

        Activity

          People

            mgrigorov Martin Tzvetanov Grigorov
            mgrigorov Martin Tzvetanov Grigorov
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: