Zadbaj o dobrą organizację dzięki kolekcji
Zapisuj i kategoryzuj treści zgodnie ze swoimi preferencjami.
blockly > MenuOption
Pojedyncza opcja w menu. Może to być litera ciągły separator
dla elementu rozdzielacza menu lub tablica dla zwykłych elementów menu akcji. W tym drugim przypadku pierwszy element to wartość zrozumiała dla człowieka (tekst, obiekt ImageProperties lub element HTML), a drugi to wartość neutralna pod względem języka.
Podpis:
export type MenuOption = [string | ImageProperties | HTMLElement, string] | 'separator';
Materiały dodatkowe: ImageProperties
O ile nie stwierdzono inaczej, treść tej strony jest objęta licencją Creative Commons – uznanie autorstwa 4.0, a fragmenty kodu są dostępne na licencji Apache 2.0. Szczegółowe informacje na ten temat zawierają zasady dotyczące witryny Google Developers. Java jest zastrzeżonym znakiem towarowym firmy Oracle i jej podmiotów stowarzyszonych.
Ostatnia aktualizacja: 2025-07-25 UTC.
[null,null,["Ostatnia aktualizacja: 2025-07-25 UTC."],[],["The `MenuOption` type defines a single option within a dropdown menu. It's structured as a tuple, with two elements. The first element is the human-readable representation of the option, which can be either a string or an image. The second element is a language-neutral string value associated with that option. This type is used within the Blockly system.\n"]]