Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

268
Vistas
Page break inside <p> tag when content overflow happen

p {
  width: 350px;
}
<p>
  <span class="c-1">Span-1 content goes here..</span> | <span class="c-2">Span-2 content goes here..</span>
</p>

View:

Span-1 content goes here.. | Span-2 content goes here..

This works fine, when the 1st span tag's content is less, But when the content increases need a line break like and have to hide the separator (i,e | ).

Span-1 more and more content goes here..
Span-2 content goes..

What's the better way to achieve this ??

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

Couldn't you do this via using a display: none/block media query on a br element?

.br { display: none; }

@media screen and (min-width: 768px) {
  .br{ display: block; }
}
<p>
  <span>Yo this is a</span>
  <br class="br">
  <span>full sentence</span>
</p>

about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda