@teselagen/ui 0.7.17 → 0.7.18
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.
- package/TgHtmlSelect/index.d.ts +5 -0
- package/index.cjs.js +17 -8
- package/index.d.ts +1 -0
- package/index.es.js +18 -9
- package/package.json +1 -1
- package/src/TgHtmlSelect/index.js +20 -0
- package/src/index.js +1 -0
package/index.cjs.js
CHANGED
|
@@ -69637,6 +69637,14 @@ function AdvancedOptions({
|
|
|
69637
69637
|
), isOpen && /* @__PURE__ */ React$1.createElement("div", { style: { marginTop: 10 } }, content2 || children));
|
|
69638
69638
|
}
|
|
69639
69639
|
__name(AdvancedOptions, "AdvancedOptions");
|
|
69640
|
+
const TgHTMLSelect = /* @__PURE__ */ __name((_K) => {
|
|
69641
|
+
var _L = _K, { disabled } = _L, rest = __objRest(_L, ["disabled"]);
|
|
69642
|
+
if (disabled) {
|
|
69643
|
+
const opt = rest.options.find((o2) => o2.value === rest.value);
|
|
69644
|
+
return /* @__PURE__ */ React$1.createElement("div", __spreadProps(__spreadValues({}, rest), { className: classNames("bp3-html-select", rest.className) }), opt.label);
|
|
69645
|
+
}
|
|
69646
|
+
return /* @__PURE__ */ React$1.createElement(core.HTMLSelect, __spreadValues({}, rest));
|
|
69647
|
+
}, "TgHTMLSelect");
|
|
69640
69648
|
const defaultMessagge = "Are you sure you want to leave? There are unsaved changes.";
|
|
69641
69649
|
const warnBeforeLeave = /* @__PURE__ */ __name((e) => {
|
|
69642
69650
|
if (window.Cypress) {
|
|
@@ -69667,14 +69675,14 @@ function BlueprintError({ error }) {
|
|
|
69667
69675
|
return /* @__PURE__ */ React$1.createElement("div", { className: classNames(core.Classes.FORM_GROUP, core.Classes.INTENT_DANGER) }, /* @__PURE__ */ React$1.createElement("div", { className: classNames(core.Classes.FORM_HELPER_TEXT, "preserve-newline") }, error));
|
|
69668
69676
|
}
|
|
69669
69677
|
__name(BlueprintError, "BlueprintError");
|
|
69670
|
-
function DropdownButton(
|
|
69671
|
-
var
|
|
69678
|
+
function DropdownButton(_M) {
|
|
69679
|
+
var _N = _M, {
|
|
69672
69680
|
disabled,
|
|
69673
69681
|
menu,
|
|
69674
69682
|
noRightIcon,
|
|
69675
69683
|
popoverProps,
|
|
69676
69684
|
className
|
|
69677
|
-
} =
|
|
69685
|
+
} = _N, rest = __objRest(_N, [
|
|
69678
69686
|
"disabled",
|
|
69679
69687
|
"menu",
|
|
69680
69688
|
"noRightIcon",
|
|
@@ -73355,14 +73363,14 @@ const EnhancedMenuItem = compose(
|
|
|
73355
73363
|
}
|
|
73356
73364
|
}),
|
|
73357
73365
|
branch(({ navTo }) => navTo, withRouter)
|
|
73358
|
-
)(function(
|
|
73359
|
-
var
|
|
73366
|
+
)(function(_O) {
|
|
73367
|
+
var _P = _O, {
|
|
73360
73368
|
navTo,
|
|
73361
73369
|
context,
|
|
73362
73370
|
staticContext,
|
|
73363
73371
|
didMount,
|
|
73364
73372
|
willUnmount
|
|
73365
|
-
} =
|
|
73373
|
+
} = _P, props = __objRest(_P, [
|
|
73366
73374
|
"navTo",
|
|
73367
73375
|
"context",
|
|
73368
73376
|
"staticContext",
|
|
@@ -73586,8 +73594,8 @@ function doesSearchValMatchText(searchVal, justText) {
|
|
|
73586
73594
|
);
|
|
73587
73595
|
}
|
|
73588
73596
|
__name(doesSearchValMatchText, "doesSearchValMatchText");
|
|
73589
|
-
const MenuItemWithTooltip = /* @__PURE__ */ __name((
|
|
73590
|
-
var
|
|
73597
|
+
const MenuItemWithTooltip = /* @__PURE__ */ __name((_Q) => {
|
|
73598
|
+
var _R = _Q, { tooltip } = _R, rest = __objRest(_R, ["tooltip"]);
|
|
73591
73599
|
let out = /* @__PURE__ */ React$1.createElement(core.MenuItem, __spreadValues({}, rest));
|
|
73592
73600
|
if (tooltip) {
|
|
73593
73601
|
out = /* @__PURE__ */ React$1.createElement(core.Tooltip, { content: tooltip }, out);
|
|
@@ -76025,6 +76033,7 @@ exports.SuggestField = SuggestField;
|
|
|
76025
76033
|
exports.SwitchField = SwitchField;
|
|
76026
76034
|
exports.TableFormTrackerContext = TableFormTrackerContext;
|
|
76027
76035
|
exports.TextareaField = TextareaField;
|
|
76036
|
+
exports.TgHTMLSelect = TgHTMLSelect;
|
|
76028
76037
|
exports.TgSelect = TgSelect$1;
|
|
76029
76038
|
exports.Timeline = Timeline;
|
|
76030
76039
|
exports.TimelineEvent = TimelineEvent;
|
package/index.d.ts
CHANGED
|
@@ -22,6 +22,7 @@ export { default as Loading } from './Loading';
|
|
|
22
22
|
export { throwFormError } from './throwFormError';
|
|
23
23
|
export { default as AdvancedOptions } from './AdvancedOptions';
|
|
24
24
|
export { default as TgSelect } from './TgSelect';
|
|
25
|
+
export { default as TgHTMLSelect } from './TgHtmlSelect';
|
|
25
26
|
export { default as wrapDialog } from './wrapDialog';
|
|
26
27
|
export { default as PromptUnsavedChanges } from './PromptUnsavedChanges';
|
|
27
28
|
export { default as BlueprintError } from './BlueprintError';
|
package/index.es.js
CHANGED
|
@@ -58,7 +58,7 @@ var __async = (__this, __arguments, generator) => {
|
|
|
58
58
|
};
|
|
59
59
|
import * as React$1 from "react";
|
|
60
60
|
import React__default, { useState, useEffect, forwardRef, useImperativeHandle, Fragment, useMemo, useRef, useReducer, useCallback, createElement, Component, useLayoutEffect, createContext, memo, useContext, isValidElement, PureComponent } from "react";
|
|
61
|
-
import { Icon, Classes, Button, Intent, MenuItem, Keys, Tag, Popover, Tooltip, Spinner, InputGroup, Checkbox, Switch, TextArea, EditableText, NumericInput, RadioGroup, Position, FormGroup, Menu, Toaster, MenuDivider, useHotkeys, ContextMenu, Callout, Dialog, Card, Tabs, Tab, Colors, Overlay, KeyCombo, ProgressBar } from "@blueprintjs/core";
|
|
61
|
+
import { Icon, Classes, Button, Intent, MenuItem, Keys, Tag, Popover, Tooltip, Spinner, InputGroup, Checkbox, Switch, TextArea, EditableText, NumericInput, RadioGroup, Position, FormGroup, Menu, Toaster, MenuDivider, useHotkeys, ContextMenu, Callout, Dialog, Card, Tabs, Tab, Colors, HTMLSelect, Overlay, KeyCombo, ProgressBar } from "@blueprintjs/core";
|
|
62
62
|
import { formValueSelector, initialize, change, Field, reduxForm, SubmissionError, destroy, touch, FormName, Fields } from "redux-form";
|
|
63
63
|
import require$$2$1, { unstable_batchedUpdates, createPortal, flushSync } from "react-dom";
|
|
64
64
|
import { connect, useDispatch, useSelector, useStore } from "react-redux";
|
|
@@ -69619,6 +69619,14 @@ function AdvancedOptions({
|
|
|
69619
69619
|
), isOpen && /* @__PURE__ */ React__default.createElement("div", { style: { marginTop: 10 } }, content2 || children));
|
|
69620
69620
|
}
|
|
69621
69621
|
__name(AdvancedOptions, "AdvancedOptions");
|
|
69622
|
+
const TgHTMLSelect = /* @__PURE__ */ __name((_K) => {
|
|
69623
|
+
var _L = _K, { disabled } = _L, rest = __objRest(_L, ["disabled"]);
|
|
69624
|
+
if (disabled) {
|
|
69625
|
+
const opt = rest.options.find((o2) => o2.value === rest.value);
|
|
69626
|
+
return /* @__PURE__ */ React__default.createElement("div", __spreadProps(__spreadValues({}, rest), { className: classNames("bp3-html-select", rest.className) }), opt.label);
|
|
69627
|
+
}
|
|
69628
|
+
return /* @__PURE__ */ React__default.createElement(HTMLSelect, __spreadValues({}, rest));
|
|
69629
|
+
}, "TgHTMLSelect");
|
|
69622
69630
|
const defaultMessagge = "Are you sure you want to leave? There are unsaved changes.";
|
|
69623
69631
|
const warnBeforeLeave = /* @__PURE__ */ __name((e) => {
|
|
69624
69632
|
if (window.Cypress) {
|
|
@@ -69649,14 +69657,14 @@ function BlueprintError({ error }) {
|
|
|
69649
69657
|
return /* @__PURE__ */ React__default.createElement("div", { className: classNames(Classes.FORM_GROUP, Classes.INTENT_DANGER) }, /* @__PURE__ */ React__default.createElement("div", { className: classNames(Classes.FORM_HELPER_TEXT, "preserve-newline") }, error));
|
|
69650
69658
|
}
|
|
69651
69659
|
__name(BlueprintError, "BlueprintError");
|
|
69652
|
-
function DropdownButton(
|
|
69653
|
-
var
|
|
69660
|
+
function DropdownButton(_M) {
|
|
69661
|
+
var _N = _M, {
|
|
69654
69662
|
disabled,
|
|
69655
69663
|
menu,
|
|
69656
69664
|
noRightIcon,
|
|
69657
69665
|
popoverProps,
|
|
69658
69666
|
className
|
|
69659
|
-
} =
|
|
69667
|
+
} = _N, rest = __objRest(_N, [
|
|
69660
69668
|
"disabled",
|
|
69661
69669
|
"menu",
|
|
69662
69670
|
"noRightIcon",
|
|
@@ -73337,14 +73345,14 @@ const EnhancedMenuItem = compose(
|
|
|
73337
73345
|
}
|
|
73338
73346
|
}),
|
|
73339
73347
|
branch(({ navTo }) => navTo, withRouter)
|
|
73340
|
-
)(function(
|
|
73341
|
-
var
|
|
73348
|
+
)(function(_O) {
|
|
73349
|
+
var _P = _O, {
|
|
73342
73350
|
navTo,
|
|
73343
73351
|
context,
|
|
73344
73352
|
staticContext,
|
|
73345
73353
|
didMount,
|
|
73346
73354
|
willUnmount
|
|
73347
|
-
} =
|
|
73355
|
+
} = _P, props = __objRest(_P, [
|
|
73348
73356
|
"navTo",
|
|
73349
73357
|
"context",
|
|
73350
73358
|
"staticContext",
|
|
@@ -73568,8 +73576,8 @@ function doesSearchValMatchText(searchVal, justText) {
|
|
|
73568
73576
|
);
|
|
73569
73577
|
}
|
|
73570
73578
|
__name(doesSearchValMatchText, "doesSearchValMatchText");
|
|
73571
|
-
const MenuItemWithTooltip = /* @__PURE__ */ __name((
|
|
73572
|
-
var
|
|
73579
|
+
const MenuItemWithTooltip = /* @__PURE__ */ __name((_Q) => {
|
|
73580
|
+
var _R = _Q, { tooltip } = _R, rest = __objRest(_R, ["tooltip"]);
|
|
73573
73581
|
let out = /* @__PURE__ */ React__default.createElement(MenuItem, __spreadValues({}, rest));
|
|
73574
73582
|
if (tooltip) {
|
|
73575
73583
|
out = /* @__PURE__ */ React__default.createElement(Tooltip, { content: tooltip }, out);
|
|
@@ -76008,6 +76016,7 @@ export {
|
|
|
76008
76016
|
SwitchField,
|
|
76009
76017
|
TableFormTrackerContext,
|
|
76010
76018
|
TextareaField,
|
|
76019
|
+
TgHTMLSelect,
|
|
76011
76020
|
TgSelect$1 as TgSelect,
|
|
76012
76021
|
Timeline,
|
|
76013
76022
|
TimelineEvent,
|
package/package.json
CHANGED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { HTMLSelect } from "@blueprintjs/core";
|
|
2
|
+
import React from "react";
|
|
3
|
+
import classNames from "classnames";
|
|
4
|
+
|
|
5
|
+
// so far this component just makes the styling of the disabled html select
|
|
6
|
+
// look like a regular html select with the selected option displayed
|
|
7
|
+
// (instead of greyed out and without the ability to have tooltips working)
|
|
8
|
+
const TgHTMLSelect = ({ disabled, ...rest }) => {
|
|
9
|
+
if (disabled) {
|
|
10
|
+
const opt = rest.options.find(o => o.value === rest.value);
|
|
11
|
+
return (
|
|
12
|
+
<div {...rest} className={classNames("bp3-html-select", rest.className)}>
|
|
13
|
+
{opt.label}
|
|
14
|
+
</div>
|
|
15
|
+
);
|
|
16
|
+
}
|
|
17
|
+
return <HTMLSelect {...rest}></HTMLSelect>;
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
export default TgHTMLSelect;
|
package/src/index.js
CHANGED
|
@@ -30,6 +30,7 @@ export { default as Loading } from "./Loading";
|
|
|
30
30
|
export { throwFormError } from "./throwFormError";
|
|
31
31
|
export { default as AdvancedOptions } from "./AdvancedOptions";
|
|
32
32
|
export { default as TgSelect } from "./TgSelect";
|
|
33
|
+
export { default as TgHTMLSelect } from "./TgHtmlSelect";
|
|
33
34
|
export { default as wrapDialog } from "./wrapDialog";
|
|
34
35
|
export { default as PromptUnsavedChanges } from "./PromptUnsavedChanges";
|
|
35
36
|
export { default as BlueprintError } from "./BlueprintError";
|