Add a new `hasInlineControls` option to `Image` component

Aperta
#164 4 commenti 1 reazione 1 assegnatario Vedi su GitHub

@ncoetzer ci sta già lavorando.

Dal 27/10/2022.

  • #172 di @ncoetzer — chiusa senza merge

Valutazione

Questa issue non è ancora stata valutata.

Descrizione

[Component] Image [Type] Enhancement Needs Design Feedback

There often are instances where we either need to have multiple images in one block or where the toolbar replaces flow isn't ideal. For those cases, it would be great to also offer an inline solution for replacing and or removing images.

The idea here would be to add a new optional property to the Image component which is a boolean to enable this additional behavior.

When this boolean is present the block will show inline controls when the block is currently selected. These controls should be absolutely positioned so that they don't create any sort of layout shift.

These controls should also take into account whether the image is marked as optional or not. If it is optional the remove button should also be shown inline. Otherwise only the replace button should be shown.

Lingua principale
TypeScript
Stelle
330
Fork
54
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di 10up/block-components

Tutte le issue di 10up/block-components

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.