SelectOneMenu vertical misalignment

UI Components for JSF
Post Reply
hquinonez
Posts: 7
Joined: 14 Dec 2017, 23:11

16 Aug 2018, 18:24

Text items of SelectOneMenu are displaying at bottom, I tried changing CSS vertical-align and padding-bottom, nothing happends.

As seen here:

Image

How can I solve it? Appreciate yor help.

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

16 Aug 2018, 18:44

Start by doing what the 'posting rules' state: post code. In MCVE format http://stackoverflow.com/help/mcve (and post version info)

hquinonez
Posts: 7
Joined: 14 Dec 2017, 23:11

16 Aug 2018, 21:34

This is the code:

Code: Select all

<p:selectOneMenu id="tipoDocumento"
	value="#{registroIdentidadController.datosRegistroTemporal.tipoDocumentoIdentidadId}"
	styleClass="form-control select2" required="true"
	validateClient="true" requiredMessage="Campo Requerido">
	<f:selectItem itemValue="#{null}" itemLabel="SELECCIONE"
		noSelectionOption="true" />
	<f:selectItems
		value="#{clasificadorController.CargarDatos('tipo_documento_identidad_id')}"
		var="c" itemLabel="#{c.descripcion}"
		itemValue="#{c.clasificadorId}" />
	<p:clientValidator event="change" />
</p:selectOneMenu>

hquinonez
Posts: 7
Joined: 14 Dec 2017, 23:11

16 Aug 2018, 22:35

Select2 is a adminLTE style of dropdown Select box.

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

17 Aug 2018, 11:05

what if you remove that...

hquinonez
Posts: 7
Joined: 14 Dec 2017, 23:11

17 Aug 2018, 16:49

I dit it.. same problem

I´m tried this CSS :

Code: Select all

	...
	display: inline-block;
	vertical-align: middle !important;
	position: relative;
	background-color: aliceblue;
	...
Other things like color change works fine, but about alignment nothing changed..

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

20 Aug 2018, 10:17

Still no 'mcve' here... Impossible to help!!! There are good reasons for an mcve. The component does not do this by itself... Reduce, reduce, reduce...

hquinonez
Posts: 7
Joined: 14 Dec 2017, 23:11

21 Aug 2018, 01:47

Solved!

Changing from p:Selectonemenu to h:Selectonemenu

Thanks.

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

24 Aug 2018, 13:35

That is not solving... That is like saying: "My car broke down, how can I repair it?" And next day stating: "I repaired it by buying a new one"....

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 22 guests