@minecraft/server-editor 0.1.0-beta.1.21.130-preview.24 → 0.1.0-beta.1.21.130-preview.26

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.
Files changed (2) hide show
  1. package/index.d.ts +38 -4
  2. package/package.json +3 -3
package/index.d.ts CHANGED
@@ -96,7 +96,7 @@ export enum BrushDirectionalPlacementMode {
96
96
  /**
97
97
  * The possible variants of a Button property item.
98
98
  */
99
- export declare enum ButtonPropertyItemVariant {
99
+ export declare enum ButtonVariant {
100
100
  Primary = 0,
101
101
  Secondary = 1,
102
102
  Confirmation = 2,
@@ -1474,7 +1474,7 @@ export type ListPaneButtonEntryParams = {
1474
1474
  onClick: (entry: IListPaneButtonEntry) => void;
1475
1475
  title?: LocalizedString;
1476
1476
  tooltip?: BasicTooltipContent;
1477
- variant?: ButtonPropertyItemVariant;
1477
+ variant?: ButtonVariant;
1478
1478
  icon?: string;
1479
1479
  enabled?: boolean;
1480
1480
  visible?: boolean;
@@ -4147,7 +4147,7 @@ export class Widget {
4147
4147
  */
4148
4148
  addClipboardComponent(
4149
4149
  componentName: string,
4150
- clipboardItem?: ClipboardItem,
4150
+ clipboardItem?: ClipboardItem | EditorStructure,
4151
4151
  options?: WidgetComponentClipboardOptions,
4152
4152
  ): WidgetComponentClipboard;
4153
4153
  /**
@@ -5627,6 +5627,12 @@ export interface IButtonPropertyItemOptions extends IPropertyItemOptionsBase {
5627
5627
  *
5628
5628
  */
5629
5629
  icon?: string;
5630
+ /**
5631
+ * @remarks
5632
+ * Shrinks button to icon size if button has an icon.
5633
+ *
5634
+ */
5635
+ shrinkToIcon?: boolean;
5630
5636
  /**
5631
5637
  * @remarks
5632
5638
  * Localized title of the property item.
@@ -5644,7 +5650,7 @@ export interface IButtonPropertyItemOptions extends IPropertyItemOptionsBase {
5644
5650
  * The variant for the button. By default it is Primary.
5645
5651
  *
5646
5652
  */
5647
- variant?: ButtonPropertyItemVariant;
5653
+ variant?: ButtonVariant;
5648
5654
  }
5649
5655
 
5650
5656
  /**
@@ -6159,6 +6165,13 @@ export interface IDropdownPropertyItemOptions extends IPropertyItemOptionsBase {
6159
6165
  *
6160
6166
  */
6161
6167
  hiddenLabel?: boolean;
6168
+ /**
6169
+ * @remarks
6170
+ * Determines how many entries can be displayed before
6171
+ * scrolling is enabled, based on available space.
6172
+ *
6173
+ */
6174
+ maxVisibleEntries?: number;
6162
6175
  /**
6163
6176
  * @remarks
6164
6177
  * This callback is called when UI control value is changed.
@@ -8438,6 +8451,14 @@ export interface ITextPropertyItem extends IPropertyItemBase {
8438
8451
  *
8439
8452
  */
8440
8453
  setTitle(title: LocalizedString | undefined): void;
8454
+ /**
8455
+ * @remarks
8456
+ * Updates tooltip description of property item.
8457
+ *
8458
+ * @param tooltip
8459
+ * New tooltip.
8460
+ */
8461
+ setTooltip(tooltip: BasicTooltipContent | undefined): void;
8441
8462
  }
8442
8463
 
8443
8464
  /**
@@ -8465,6 +8486,12 @@ export interface ITextPropertyItemOptions extends IPropertyItemOptionsBase {
8465
8486
  *
8466
8487
  */
8467
8488
  title?: LocalizedString;
8489
+ /**
8490
+ * @remarks
8491
+ * Tooltip description of the property item.
8492
+ *
8493
+ */
8494
+ tooltip?: BasicTooltipContent;
8468
8495
  }
8469
8496
 
8470
8497
  /**
@@ -8527,6 +8554,13 @@ export interface IToggleGroupPropertyItem extends IPropertyItemBase {
8527
8554
  * Properties of toggle group property item list entry
8528
8555
  */
8529
8556
  export interface IToggleGroupPropertyItemEntry {
8557
+ /**
8558
+ * @remarks
8559
+ * Optional enabled state of the entry. If undefined it will be
8560
+ * true.
8561
+ *
8562
+ */
8563
+ readonly enabled?: boolean;
8530
8564
  /**
8531
8565
  * @remarks
8532
8566
  * Optional icon of the dropdown entry.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@minecraft/server-editor",
3
- "version": "0.1.0-beta.1.21.130-preview.24",
3
+ "version": "0.1.0-beta.1.21.130-preview.26",
4
4
  "description": "",
5
5
  "contributors": [
6
6
  {
@@ -14,8 +14,8 @@
14
14
  ],
15
15
  "peerDependencies": {
16
16
  "@minecraft/common": "^1.0.0",
17
- "@minecraft/server": "^2.5.0-beta.1.21.130-preview.24",
18
- "@minecraft/vanilla-data": ">=1.20.70 || 1.21.130-preview.24"
17
+ "@minecraft/server": "^2.5.0-beta.1.21.130-preview.26",
18
+ "@minecraft/vanilla-data": ">=1.20.70 || 1.21.130-preview.26"
19
19
  },
20
20
  "license": "MIT"
21
21
  }