bnstooltips 1.10.2 → 1.11.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.
@@ -2,4 +2,5 @@ import { Skill } from "../Utilities/ISkill";
2
2
  import { ITooltipWrapper } from "../Utilities/Models";
3
3
  export interface SkillTooltipWrapperProps extends ITooltipWrapper {
4
4
  data: Skill;
5
+ debug?: boolean;
5
6
  }
@@ -15,6 +15,8 @@ export interface Skill {
15
15
  Pvp: string;
16
16
  BreakValue: string;
17
17
  GcdGroup: number;
18
+ GcdDuration: number;
19
+ RealCooldown: number;
18
20
  CdRecycle: {
19
21
  Item1: string;
20
22
  Item2: number;
package/build/index.es.js CHANGED
@@ -7056,6 +7056,11 @@ function AddIds(subInfoGroups, skill) {
7056
7056
  "Gcd group: ",
7057
7057
  React.createElement(BlueColoredText, { text: skill.GcdGroup.toString() })));
7058
7058
  }
7059
+ if (skill.GcdDuration != null) {
7060
+ subInfoGroup.texts.push(React.createElement("div", null,
7061
+ "Gcd duration: ",
7062
+ React.createElement(BlueColoredText, { text: skill.GcdDuration.toString() })));
7063
+ }
7059
7064
  if (skill.CdRecycle != null) {
7060
7065
  subInfoGroup.texts.push(React.createElement("div", null,
7061
7066
  "Cd group: ",
@@ -7064,6 +7069,11 @@ function AddIds(subInfoGroups, skill) {
7064
7069
  "Cd id: ",
7065
7070
  React.createElement(BlueColoredText, { text: skill.CdRecycle.Item2.toString() })));
7066
7071
  }
7072
+ if (skill.RealCooldown != null) {
7073
+ subInfoGroup.texts.push(React.createElement("div", null,
7074
+ "Real cooldown: ",
7075
+ React.createElement(BlueColoredText, { text: skill.RealCooldown.toString() })));
7076
+ }
7067
7077
  subInfoGroups.push(subInfoGroup);
7068
7078
  }
7069
7079
  function AddRealCastConds(subInfoGroups, skill) {
@@ -7162,9 +7172,9 @@ var css_248z$3 = ".TooltipBase_bns_upgradeRed_color {\n color: #FF2818; }\n\n.T
7162
7172
  styleInject(css_248z$3);
7163
7173
 
7164
7174
  var SkillTooltipWrapper = function (_a) {
7165
- var data = _a.data, children = _a.children, _b = _a.interactive, interactive = _b === void 0 ? false : _b, _c = _a.placement, placement = _c === void 0 ? "right" : _c, _d = _a.followCursor, followCursor$1 = _d === void 0 ? false : _d, _e = _a.trigger, trigger = _e === void 0 ? "mouseenter focus" : _e, _f = _a.showArrow, showArrow = _f === void 0 ? true : _f;
7175
+ var data = _a.data, children = _a.children, _b = _a.interactive, interactive = _b === void 0 ? false : _b, _c = _a.placement, placement = _c === void 0 ? "right" : _c, _d = _a.followCursor, followCursor$1 = _d === void 0 ? false : _d, _e = _a.trigger, trigger = _e === void 0 ? "mouseenter focus" : _e, _f = _a.showArrow, showArrow = _f === void 0 ? true : _f, _g = _a.debug, debug = _g === void 0 ? false : _g;
7166
7176
  var spanRef = useRef(null);
7167
- var _g = useState(null), childRef = _g[0], setChildRef = _g[1];
7177
+ var _h = useState(null), childRef = _h[0], setChildRef = _h[1];
7168
7178
  /**
7169
7179
  * Mount the temporary span element.
7170
7180
  * retrieve and store the target element's reference.
@@ -7177,7 +7187,7 @@ var SkillTooltipWrapper = function (_a) {
7177
7187
  }, []);
7178
7188
  return (React.createElement(React.Fragment, null,
7179
7189
  children,
7180
- childRef ? (React.createElement(Tippy, { arrow: showArrow, trigger: trigger, plugins: [followCursor], followCursor: followCursor$1 && !interactive, appendTo: document.body, placement: placement, animation: "fade", interactive: interactive, content: React.createElement(SkillTooltip, { data: data, debug: false }), theme: "grade" + 4, reference: childRef })) : (React.createElement("span", { "data-testid": "TooltipWrapper", ref: spanRef, style: { display: "none" } }))));
7190
+ childRef ? (React.createElement(Tippy, { arrow: showArrow, trigger: trigger, plugins: [followCursor], followCursor: followCursor$1 && !interactive, appendTo: document.body, placement: placement, animation: "fade", interactive: interactive, content: React.createElement(SkillTooltip, { data: data, debug: debug }), theme: "grade" + 4, reference: childRef })) : (React.createElement("span", { "data-testid": "TooltipWrapper", ref: spanRef, style: { display: "none" } }))));
7181
7191
  };
7182
7192
 
7183
7193
  var ServerRegion;