Dialog Framework Responsive

UI Components for JSF
Post Reply
Rafaelfr1
Posts: 32
Joined: 09 Mar 2015, 16:03

20 Oct 2017, 17:37

Esta funcionalidade foi implementada?

https://github.com/primefaces/primefaces/issues/723

kukeltje
Expert Member
Posts: 9605
Joined: 17 Jun 2010, 13:34
Location: Netherlands

21 Oct 2017, 15:01

English please... And did you actually check the issue? It has a RED 'closed' and two version numbers (6.0.20 and 6.1.2) so what do you think?

Rafaelfr1
Posts: 32
Joined: 09 Mar 2015, 16:03

21 Oct 2017, 17:59

Sorry, but if it has already been implemented because it does not work? Am I putting some incorrect parameter?

Here are the parameters:

Code: Select all

  Map<String, Object> opcoes = new HashMap<>();
        opcoes.put("modal", true);
        opcoes.put("resizable", true);
        opcoes.put("responsive", true);
        opcoes.put("width", 950);
        opcoes.put("draggable", true);
        opcoes.put("height", 471);
        opcoes.put("contentWidth", "100%");
        opcoes.put("contentHeight", "100%");
        opcoes.put("headerElement", "customheader");

RequestContext.getCurrentInstance().openDialog("/menu/selecao.xhtml", opcoes, null);
Images

https://ibb.co/cjFfFm

https://ibb.co/bDbWMR

Is there an example to follow?

Rafaelfr1
Posts: 32
Joined: 09 Mar 2015, 16:03

21 Oct 2017, 18:07

Datatable is as reflow = "true"

Rafaelfr1
Posts: 32
Joined: 09 Mar 2015, 16:03

23 Oct 2017, 18:07

I solved using @media in CSS to change the "ui-dialog" class and so it worked.

Code: Select all

@media (min-width: 960px) {
  / * ui-Dialog * /
     body .ui-dialog {
         width: 950px! important;
     }
}


@media (min-width: 640px) and (max-width: 960px) {
     / * ui-Dialog * /
     body .ui-dialog {
         width: 557px! important;
     }
}

@media (min-width: 480px) and (max-width: 640px) {
/ * ui-Dialog * /
     body .ui-dialog {
         width: 360px! important;
     }
}
In the dialog call

Code: Select all

        Map<String, Object> opcoes = new HashMap<>();
        opcoes.put("modal", true);
        opcoes.put("resizable", true);
        opcoes.put("responsive", true);
//        opcoes.put("width", 950);
        opcoes.put("draggable", true);
        opcoes.put("height", 550);
        opcoes.put("contentWidth", "100%");
        opcoes.put("contentHeight", "100%");
        opcoes.put("headerElement", "customheader");

        RequestContext.getCurrentInstance().openDialog("/menu/selecao.xhtml", opcoes, null);

kukeltje
Expert Member
Posts: 9605
Joined: 17 Jun 2010, 13:34
Location: Netherlands

23 Oct 2017, 21:22

You nowhere state version info, so you might be running a version where it is not implemented yet!!!

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 36 guests