`GenericContentMainArea`: optional close button rendered by the core

Abierto
#307 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
45/100
Tipo de issue
Nueva funcionalidad
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
react, typescript
Área
frontend

Línea de trabajo

Start from the reference implementation in external-video-player-graphql/component.tsx (the Styled.ExternalVideoCloseButton block) and compare it with the current GenericContentMainArea component and its GenericContentMainAreaProps. Read how the presenter flag reaches that content and how RTL and primary styling are handled, since the new closeButton option must reuse the same button and layering. Done means the prop is added, core renders the button only for the presenter (or behind an allowed flag) above plugin content, and no item re-creation is needed on presenter change.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

The external video player shows a close button in the top right corner of the content, for the presenter only:

// external-video-player-graphql/component.tsx
isPresenter ? (
  <Styled.ExternalVideoCloseButton
    color="primary" icon="close" size="sm" hideLabel
    onClick={stopExternalVideoShare}
    label={intl.formatMessage(intlMessages.closeExternalVideoLabel)}
  />
) : null

GenericContentMainArea only takes contentFunction, so a plugin has to draw its own button inside its content, copying the core styles (position: absolute; top: 0; right: 0, RTL handling, primary colors). It also has to re-render that content when the presenter changes, without recreating the item, which would put it back on top of the presentation area for everyone. The result can drift from the core look, and every plugin does it a little differently.

Proposal

Add an optional close button to GenericContentMainAreaProps, rendered by the core with the same component as the external video:

new GenericContentMainArea({
  contentFunction: (element) => { ... },
  closeButton: {
    label: 'Stop sharing website',   // aria-label / tooltip
    onClick: () => { /* remove the content */ },
  },
});

The core would show it only to the presenter, as for the external video, or the plugin could choose with an allowed flag. It should follow RTL and stay above the plugin content.

Lenguaje dominante
Sin datos de lenguaje
Estrellas
17
Forks
18
Métricas de merge de PR
Sin PR fusionados en 30 d

Preparar el entorno

  • Sin Dockerfile ni archivo de Docker Compose
  • Tiene una plantilla de pull request
  • Sin guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de bigbluebutton/bigbluebutton-html-plugin-sdk

Todos los issues de bigbluebutton/bigbluebutton-html-plugin-sdk

Issues similares

Más issues de Web Dev

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.