@drincs/pixi-vn 0.5.5 → 0.5.7

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.
@@ -1,6 +1,6 @@
1
1
  export { default as CanvasEvent } from './CanvasEvent.mjs';
2
2
  export { default as CharacterBaseModel, CharacterBaseModelProps } from './CharacterBaseModel.mjs';
3
- export { default as ChoiceMenuOption, HistoryChoiceMenuOption } from './ChoiceMenuOption.mjs';
3
+ export { default as ChoiceMenuOption, ChoiceMenuOptionClose, HistoryChoiceMenuOption } from './ChoiceMenuOption.mjs';
4
4
  export { default as DialogueBaseModel } from './DialogueBaseModel.mjs';
5
5
  export { default as Label } from './Label.mjs';
6
6
  export { default as StoredClassModel } from './StoredClassModel.mjs';
@@ -1,6 +1,6 @@
1
1
  export { default as CanvasEvent } from './CanvasEvent.js';
2
2
  export { default as CharacterBaseModel, CharacterBaseModelProps } from './CharacterBaseModel.js';
3
- export { default as ChoiceMenuOption, HistoryChoiceMenuOption } from './ChoiceMenuOption.js';
3
+ export { default as ChoiceMenuOption, ChoiceMenuOptionClose, HistoryChoiceMenuOption } from './ChoiceMenuOption.js';
4
4
  export { default as DialogueBaseModel } from './DialogueBaseModel.js';
5
5
  export { default as Label } from './Label.js';
6
6
  export { default as StoredClassModel } from './StoredClassModel.js';
@@ -128,6 +128,12 @@ var Label = class {
128
128
  }
129
129
  };
130
130
 
131
+ // src/classes/CloseLabel.ts
132
+ var CLOSE_LABEL_ID = "__close-label-id__";
133
+ function newCloseLabel(choiseIndex) {
134
+ return new Label(CLOSE_LABEL_ID, [], void 0, choiseIndex);
135
+ }
136
+
131
137
  // src/decorators/LabelDecorator.ts
132
138
  var registeredLabels = {};
133
139
  function getLabelById(id) {
@@ -629,6 +635,9 @@ function geTickerInstanceByClassName(tickerName, args, duration, priority) {
629
635
  }
630
636
  }
631
637
 
638
+ // src/types/CloseType.ts
639
+ var Close = "close";
640
+
632
641
  // src/types/PauseType.ts
633
642
  var PauseValueType = "pause";
634
643
 
@@ -664,6 +673,26 @@ var ChoiceMenuOption = class {
664
673
  }
665
674
  }
666
675
  };
676
+ var ChoiceMenuOptionClose = class {
677
+ /**
678
+ * @param text Text to be displayed in the menu
679
+ */
680
+ constructor(text) {
681
+ /**
682
+ * Label to be opened when the option is selected
683
+ */
684
+ this.label = newCloseLabel();
685
+ /**
686
+ * Type of the label to be opened
687
+ */
688
+ this.type = Close;
689
+ /**
690
+ * Properties to be passed to the label
691
+ */
692
+ this.props = {};
693
+ this.text = text;
694
+ }
695
+ };
667
696
 
668
697
  // src/classes/ticker/TickerBase.ts
669
698
  var TickerBase = class {
@@ -1686,6 +1715,7 @@ var DialogueBaseModel = class {
1686
1715
  exports.CanvasEvent = CanvasEvent;
1687
1716
  exports.CharacterBaseModel = CharacterBaseModel2;
1688
1717
  exports.ChoiceMenuOption = ChoiceMenuOption;
1718
+ exports.ChoiceMenuOptionClose = ChoiceMenuOptionClose;
1689
1719
  exports.DialogueBaseModel = DialogueBaseModel;
1690
1720
  exports.Label = Label;
1691
1721
  exports.StoredClassModel = StoredClassModel;