@cloudtower/eagle 0.34.7 → 0.34.9

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,5 +1,6 @@
1
1
  import { formatPercent } from '../../utils/tower.js';
2
2
  import React__default, { useMemo } from 'react';
3
+ import cs from 'classnames';
3
4
 
4
5
  var __defProp = Object.defineProperty;
5
6
  var __getOwnPropSymbols = Object.getOwnPropertySymbols;
@@ -63,10 +64,11 @@ const BarItem = props => {
63
64
  };
64
65
  const BarChart = ({
65
66
  data,
66
- total
67
+ total,
68
+ className
67
69
  }) => {
68
70
  return /* @__PURE__ */React__default.createElement("div", {
69
- className: StackBar
71
+ className: cs(StackBar, className)
70
72
  }, (data || []).map((item, index) => {
71
73
  const {
72
74
  value,
@@ -1,15 +1,33 @@
1
1
  import { cx } from '@linaria/core';
2
+ import { SmallDialog } from '../../../core/SmallDialog/SmallDialog.js';
2
3
  import { Typo } from '../../../core/Typo/index.js';
3
4
  import React__default from 'react';
4
- import { SmallDialog } from '../../../core/SmallDialog/SmallDialog.js';
5
5
  import { RejectDialogType } from './RejectDialog.type.js';
6
6
  import useParrotTranslation from '../../../hooks/useParrotTranslation.js';
7
7
 
8
+ var __defProp = Object.defineProperty;
9
+ var __getOwnPropSymbols = Object.getOwnPropertySymbols;
10
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
11
+ var __propIsEnum = Object.prototype.propertyIsEnumerable;
12
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, {
13
+ enumerable: true,
14
+ configurable: true,
15
+ writable: true,
16
+ value
17
+ }) : obj[key] = value;
18
+ var __spreadValues = (a, b) => {
19
+ for (var prop in b || (b = {})) if (__hasOwnProp.call(b, prop)) __defNormalProp(a, prop, b[prop]);
20
+ if (__getOwnPropSymbols) for (var prop of __getOwnPropSymbols(b)) {
21
+ if (__propIsEnum.call(b, prop)) __defNormalProp(a, prop, b[prop]);
22
+ }
23
+ return a;
24
+ };
8
25
  const ContentList = "E_c1ss4prm";
9
26
  const MultiRejectContentList = "E_ms3tlei";
10
27
  const Description = "E_du44iy7";
11
- const SecondaryDesc = "E_s1qmhanr";
12
- const Divider = "E_drje1h0";
28
+ const PartialDescription = "E_p1qmhanr";
29
+ const SecondaryDesc = "E_srje1h0";
30
+ const Divider = "E_di3zi7v";
13
31
  const SingleRejectContent = ({
14
32
  content
15
33
  }) => {
@@ -43,9 +61,11 @@ const RejectDialog = props => {
43
61
  const {
44
62
  title,
45
63
  cancelText,
64
+ beforeDescription,
46
65
  description,
47
66
  className,
48
- footerClassName
67
+ footerClassName,
68
+ okButtonProps
49
69
  } = props;
50
70
  const renderContent = () => {
51
71
  switch (props.type) {
@@ -60,7 +80,7 @@ const RejectDialog = props => {
60
80
  }, props.secondaryDesc), props.type === RejectDialogType.Part && /* @__PURE__ */React__default.createElement(React__default.Fragment, null, /* @__PURE__ */React__default.createElement("div", {
61
81
  className: Divider
62
82
  }), /* @__PURE__ */React__default.createElement("div", {
63
- className: cx(Description, Typo.Label.l3_regular)
83
+ className: cx(PartialDescription, Typo.Label.l3_regular)
64
84
  }, props.partialDescription)), /* @__PURE__ */React__default.createElement(MultiRejectContent, {
65
85
  content: props.content,
66
86
  resourceIcon: props.resourceIcon
@@ -75,13 +95,13 @@ const RejectDialog = props => {
75
95
  showOk: props.type === RejectDialogType.Part,
76
96
  okText: props.type === RejectDialogType.Part ? props.okText : void 0,
77
97
  onOk: props.type === RejectDialogType.Part ? props.onOk : void 0,
78
- okButtonProps: {
98
+ okButtonProps: __spreadValues({
79
99
  danger: props.type === RejectDialogType.Part
80
- },
100
+ }, okButtonProps),
81
101
  onCancel: props.onCancel,
82
102
  className,
83
103
  footerClassName
84
- }, description && /* @__PURE__ */React__default.createElement("div", {
104
+ }, beforeDescription, description && /* @__PURE__ */React__default.createElement("div", {
85
105
  className: cx(Description, Typo.Label.l3_regular)
86
106
  }, description), renderContent());
87
107
  };
@@ -0,0 +1,61 @@
1
+ import { cx } from '@linaria/core';
2
+ import Tooltip from '../../core/Tooltip/index.js';
3
+ import React__default from 'react';
4
+
5
+ var __defProp = Object.defineProperty;
6
+ var __getOwnPropSymbols = Object.getOwnPropertySymbols;
7
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
8
+ var __propIsEnum = Object.prototype.propertyIsEnumerable;
9
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, {
10
+ enumerable: true,
11
+ configurable: true,
12
+ writable: true,
13
+ value
14
+ }) : obj[key] = value;
15
+ var __spreadValues = (a, b) => {
16
+ for (var prop in b || (b = {})) if (__hasOwnProp.call(b, prop)) __defNormalProp(a, prop, b[prop]);
17
+ if (__getOwnPropSymbols) for (var prop of __getOwnPropSymbols(b)) {
18
+ if (__propIsEnum.call(b, prop)) __defNormalProp(a, prop, b[prop]);
19
+ }
20
+ return a;
21
+ };
22
+ var __objRest = (source, exclude) => {
23
+ var target = {};
24
+ for (var prop in source) if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
25
+ if (source != null && __getOwnPropSymbols) for (var prop of __getOwnPropSymbols(source)) {
26
+ if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop)) target[prop] = source[prop];
27
+ }
28
+ return target;
29
+ };
30
+ const UnderlineTooltipStyle = "E_u15heuvq";
31
+ const UnderlineTooltip = props => {
32
+ const _a = props,
33
+ {
34
+ style = "dashed",
35
+ color = "rgba(107, 128, 167, 0.6)",
36
+ width = "1px",
37
+ contentColor,
38
+ customContentColor,
39
+ link,
40
+ underlineContentClassName,
41
+ title,
42
+ children,
43
+ className
44
+ } = _a,
45
+ rest = __objRest(_a, ["style", "color", "width", "contentColor", "customContentColor", "link", "underlineContentClassName", "title", "children", "className"]);
46
+ return /* @__PURE__ */React__default.createElement(Tooltip, __spreadValues({
47
+ className: cx(UnderlineTooltipStyle, className),
48
+ title: title || children
49
+ }, rest), /* @__PURE__ */React__default.createElement("span", {
50
+ className: cx("content", !customContentColor && contentColor, link && "link", underlineContentClassName),
51
+ style: {
52
+ borderBottomColor: color,
53
+ borderBottomStyle: style,
54
+ borderBottomWidth: width,
55
+ color: customContentColor
56
+ }
57
+ }, children));
58
+ };
59
+ var UnderlineTooltip$1 = UnderlineTooltip;
60
+
61
+ export { UnderlineTooltipStyle, UnderlineTooltip$1 as default };
package/dist/esm/index.js CHANGED
@@ -136,6 +136,7 @@ export { default as DeprecatedDonutChart } from './coreX/DeprecatedDonutChart/in
136
136
  export { default as DropdownTransition } from './coreX/DropdownTransition/index.js';
137
137
  export { default as GoBackButton } from './coreX/GoBackButton/index.js';
138
138
  export { default as I18nNameTag } from './coreX/I18nNameTag/index.js';
139
+ export { default as KubeConfigModal } from './coreX/KubeConfigModal/index.js';
139
140
  export { default as NamesTooltip } from './coreX/NamesTooltip/index.js';
140
141
  export { default as OverflowTooltip } from './coreX/OverflowTooltip/index.js';
141
142
  export { default as SidebarSubtitle } from './coreX/SidebarSubtitle/index.js';
@@ -144,8 +145,8 @@ export { default as SortableList } from './coreX/SortableList/index.js';
144
145
  export { default as SummaryTable, SummaryTableRow } from './coreX/SummaryTable/index.js';
145
146
  export { default as SwitchWithText } from './coreX/SwitchWithText/index.js';
146
147
  export { default as TabMenu } from './coreX/TabMenu/index.js';
148
+ export { default as UnderlineTooltip, UnderlineTooltipStyle } from './coreX/UnderlineTootip/index.js';
147
149
  export { default as UnitWithChart, UnitWrapper } from './coreX/UnitWithChart/index.js';
148
- export { default as KubeConfigModal } from './coreX/KubeConfigModal/index.js';
149
150
  export { CheckPointItem, CheckPointList } from './coreX/CheckPointList/index.js';
150
151
  export { getCalendarTitle } from './coreX/common/getCalendarTitle.js';
151
152
  export { default as AbsoluteDate } from './coreX/DateRangePicker/AbsoluteDate.js';