Esta funcionalidade foi implementada?
https://github.com/primefaces/primefaces/issues/723
Dialog Framework Responsive
Sorry, but if it has already been implemented because it does not work? Am I putting some incorrect parameter?
Here are the parameters:
Images
https://ibb.co/cjFfFm
https://ibb.co/bDbWMR
Is there an example to follow?
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);
https://ibb.co/cjFfFm
https://ibb.co/bDbWMR
Is there an example to follow?
I solved using @media in CSS to change the "ui-dialog" class and so it worked.
In the dialog call
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;
}
}
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);
-
- Information
-
Who is online
Users browsing this forum: No registered users and 61 guests