@wayward/types 2.13.0-beta.dev.20230403.1 → 2.13.0-beta.dev.20230404.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -34,10 +34,14 @@ export interface IDropdownData<OptionId = string | number> {
|
|
|
34
34
|
}
|
|
35
35
|
export default class Dropdown<O = string | number> extends Component implements IRefreshableValue<IDropdownData<O>> {
|
|
36
36
|
event: IEventEmitter<this, IDropdownEvents<O>>;
|
|
37
|
-
|
|
37
|
+
private using?;
|
|
38
|
+
private readonly _options;
|
|
39
|
+
get options(): Map<O, Button>;
|
|
38
40
|
readonly inputButton: InputButton;
|
|
39
|
-
protected
|
|
40
|
-
private
|
|
41
|
+
protected _optionsWrapper: Component;
|
|
42
|
+
private get optionsWrapper();
|
|
43
|
+
private readonly _optionsWrapperWrapper;
|
|
44
|
+
private get optionsWrapperWrapper();
|
|
41
45
|
private refreshMethod;
|
|
42
46
|
private visibleOptions;
|
|
43
47
|
private defaultOption?;
|
|
@@ -49,6 +53,7 @@ export default class Dropdown<O = string | number> extends Component implements
|
|
|
49
53
|
private hovered;
|
|
50
54
|
private shouldRetainLastFilter;
|
|
51
55
|
constructor();
|
|
56
|
+
use(dropdown?: Dropdown<O>): this;
|
|
52
57
|
retainLastFilter(retainLastFilter?: boolean): this;
|
|
53
58
|
open(): void;
|
|
54
59
|
close(input?: InputButton): boolean;
|
|
@@ -12,7 +12,9 @@ import { ItemType, ItemTypeGroup } from "game/item/IItem";
|
|
|
12
12
|
import type { IDropdownOption } from "ui/component/Dropdown";
|
|
13
13
|
import GroupDropdown from "ui/component/GroupDropdown";
|
|
14
14
|
export default class ItemDropdown<OTHER_OPTIONS extends string = never> extends GroupDropdown<typeof ItemType, OTHER_OPTIONS, ItemTypeGroup, Exclude<ItemType, ItemType.None>> {
|
|
15
|
-
|
|
15
|
+
private canRefresh;
|
|
16
|
+
constructor(defaultOption: OTHER_OPTIONS | Exclude<ItemType, ItemType.None>, options?: Iterable<IDropdownOption<OTHER_OPTIONS>>, inherit?: boolean);
|
|
17
|
+
refresh(): this;
|
|
16
18
|
protected filterEnum(value: ItemType): boolean;
|
|
17
19
|
protected getGroupName(group: ItemTypeGroup): string;
|
|
18
20
|
protected isInGroup(item: ItemType, group: ItemTypeGroup): boolean;
|
package/package.json
CHANGED