@eccenca/gui-elements 25.0.0-featurecolorwheelinputcmem7327.0 → 25.0.0-featurecolorwheelinputcmem7327.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.
@@ -0,0 +1,114 @@
1
+ "use strict";
2
+ var __rest = (this && this.__rest) || function (s, e) {
3
+ var t = {};
4
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
5
+ t[p] = s[p];
6
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
7
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
8
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
9
+ t[p[i]] = s[p[i]];
10
+ }
11
+ return t;
12
+ };
13
+ var __importDefault = (this && this.__importDefault) || function (mod) {
14
+ return (mod && mod.__esModule) ? mod : { "default": mod };
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ exports.ColorField = void 0;
18
+ const react_1 = __importDefault(require("react"));
19
+ const classnames_1 = __importDefault(require("classnames"));
20
+ const common_1 = require("../../common");
21
+ const constants_1 = require("../../configuration/constants");
22
+ const ContextOverlay_1 = require("../ContextOverlay");
23
+ const Form_1 = require("../Form");
24
+ const RadioButton_1 = require("../RadioButton/RadioButton");
25
+ const Spacing_1 = require("../Separation/Spacing");
26
+ const Tag_1 = require("../Tag");
27
+ const TextField_1 = require("../TextField");
28
+ const Tooltip_1 = require("../Tooltip/Tooltip");
29
+ const Typography_1 = require("../Typography");
30
+ /**
31
+ * Color input field that provides resets from the configured color palette.
32
+ * Use `colorWeightFilter` and `paletteGroupFilter` to filter them.
33
+ */
34
+ const ColorField = (_a) => {
35
+ var { className = "", allowCustomColor = false, colorWeightFilter = [100, 300, 700, 900], paletteGroupFilter = ["layout"], defaultValue, value, onChange, fullWidth = false } = _a, otherTextFieldProps = __rest(_a, ["className", "allowCustomColor", "colorWeightFilter", "paletteGroupFilter", "defaultValue", "value", "onChange", "fullWidth"]);
36
+ const ref = react_1.default.useRef(null);
37
+ const [colorValue, setColorValue] = react_1.default.useState(defaultValue || value || "#000000");
38
+ let allowedPaletteColors, disableNativePicker, disabled;
39
+ const updateConfig = () => {
40
+ allowedPaletteColors = common_1.utils.getEnabledColorPropertiesFromPalette({
41
+ includePaletteGroup: paletteGroupFilter,
42
+ includeColorWeight: colorWeightFilter,
43
+ minimalColorDistance: 0, // we use all allowed colors, and do not check distances between them
44
+ });
45
+ disableNativePicker =
46
+ colorWeightFilter.length > 0 && paletteGroupFilter.length > 0 && allowedPaletteColors.length > 0;
47
+ disabled = (!disableNativePicker && !allowCustomColor) || otherTextFieldProps.disabled;
48
+ };
49
+ updateConfig();
50
+ react_1.default.useEffect(() => {
51
+ updateConfig();
52
+ }, [allowCustomColor, colorWeightFilter, paletteGroupFilter, otherTextFieldProps]);
53
+ react_1.default.useEffect(() => {
54
+ setColorValue(defaultValue || value || "#000000");
55
+ }, [defaultValue, value]);
56
+ const forwardOnChange = (forwardedEvent) => {
57
+ setColorValue(forwardedEvent.target.value);
58
+ if (onChange) {
59
+ onChange(forwardedEvent);
60
+ }
61
+ };
62
+ const colorInput = (react_1.default.createElement(TextField_1.TextField, Object.assign({ inputRef: ref, className: (0, classnames_1.default)(`${constants_1.CLASSPREFIX}-colorfield`, className, {
63
+ [`${constants_1.CLASSPREFIX}-colorfield--custom-picker`]: disableNativePicker,
64
+ }),
65
+ // we cannot use `color` type for the custom picker because we do not have control over it then
66
+ type: !disableNativePicker ? "color" : "text", readOnly: disableNativePicker, disabled: disabled, value: colorValue, fullWidth: fullWidth }, otherTextFieldProps, { onChange: !disableNativePicker
67
+ ? (e) => {
68
+ forwardOnChange(e);
69
+ }
70
+ : undefined, style: Object.assign(Object.assign({}, otherTextFieldProps.style), { [`--eccgui-colorfield-background`]: colorValue }) })));
71
+ return disableNativePicker && !disabled ? (react_1.default.createElement(ContextOverlay_1.ContextOverlay, { fill: fullWidth, content: react_1.default.createElement(Typography_1.WhiteSpaceContainer, { paddingTop: "small", paddingRight: "small", paddingBottom: "small", paddingLeft: "small", className: `${constants_1.CLASSPREFIX}-colorfield__picker` },
72
+ allowCustomColor && (react_1.default.createElement(react_1.default.Fragment, null,
73
+ react_1.default.createElement(TextField_1.TextField, { type: "color", value: colorValue, onChange: (e) => {
74
+ forwardOnChange(e);
75
+ } }),
76
+ react_1.default.createElement(Spacing_1.Spacing, { size: "small" }))),
77
+ react_1.default.createElement(Form_1.FieldSet, null,
78
+ react_1.default.createElement(Tag_1.TagList, { className: `${constants_1.CLASSPREFIX}-colorfield__palette ${constants_1.CLASSPREFIX}-colorfield__palette--${colorWeightFilter.length >= 3 ? colorWeightFilter.length * 2 : "8"}col` }, allowedPaletteColors.map((color, idx) => [
79
+ react_1.default.createElement(RadioButton_1.RadioButton, { className: `${constants_1.CLASSPREFIX}-colorfield__palette__color`, hideIndicator: true, value: color[1], onChange: (e) => {
80
+ forwardOnChange(e);
81
+ } },
82
+ react_1.default.createElement(Tooltip_1.Tooltip, { key: idx, content: color[0].replace(`${constants_1.CLASSPREFIX}-color-palette-`, "") },
83
+ react_1.default.createElement(Tag_1.Tag, { large: true, style: { [`--eccgui-colorfield-palette-color`]: color[1] } }, color[1]))),
84
+ // Looks like we cannot force some type of line break in the tag list via CSS only
85
+ (idx + 1) % (colorWeightFilter.length >= 3 ? colorWeightFilter.length * 2 : 8) ===
86
+ 0 && (react_1.default.createElement(react_1.default.Fragment, null,
87
+ react_1.default.createElement("br", { className: `${constants_1.CLASSPREFIX}-colorfield__palette-linebreak` }))),
88
+ ])))) }, colorInput)) : (colorInput);
89
+ };
90
+ exports.ColorField = ColorField;
91
+ /**
92
+ * Simple helper function that provide simple access to color hash calculation.
93
+ * Using the same default values for the color palette filter.
94
+ */
95
+ exports.ColorField.calculateColorHashValue = (text, options = {
96
+ allowCustomColor: false,
97
+ colorWeightFilter: [100, 300, 700, 900],
98
+ paletteGroupFilter: ["layout"],
99
+ }) => {
100
+ const hash = common_1.utils.textToColorHash({
101
+ text,
102
+ options: {
103
+ returnValidColorsDirectly: options.allowCustomColor,
104
+ enabledColors: common_1.utils.getEnabledColorsFromPalette({
105
+ includePaletteGroup: options.paletteGroupFilter,
106
+ includeColorWeight: options.colorWeightFilter,
107
+ minimalColorDistance: 0,
108
+ }),
109
+ },
110
+ });
111
+ return hash ? hash : undefined;
112
+ };
113
+ exports.default = exports.ColorField;
114
+ //# sourceMappingURL=ColorField.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ColorField.js","sourceRoot":"","sources":["../../../../src/components/ColorField/ColorField.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,kDAA6C;AAC7C,4DAAoC;AAEpC,yCAAqC;AAErC,6DAAsE;AACtE,sDAAmD;AACnD,kCAAmC;AACnC,4DAAyD;AACzD,mDAAgD;AAChD,gCAAsC;AACtC,4CAAyD;AACzD,gDAA6C;AAC7C,8CAAoD;AAiBpD;;;GAGG;AACI,MAAM,UAAU,GAAG,CAAC,EAUT,EAAE,EAAE;QAVK,EACvB,SAAS,GAAG,EAAE,EACd,gBAAgB,GAAG,KAAK,EACxB,iBAAiB,GAAG,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,EACxC,kBAAkB,GAAG,CAAC,QAAQ,CAAC,EAC/B,YAAY,EACZ,KAAK,EACL,QAAQ,EACR,SAAS,GAAG,KAAK,OAEH,EADX,mBAAmB,cATC,8HAU1B,CADyB;IAEtB,MAAM,GAAG,GAAG,eAAK,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC;IAC/B,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAG,eAAK,CAAC,QAAQ,CAAS,YAAY,IAAI,KAAK,IAAI,SAAS,CAAC,CAAC;IAE/F,IAAI,oBAAoB,EAAE,mBAAmB,EAAE,QAAQ,CAAC;IACxD,MAAM,YAAY,GAAG,GAAG,EAAE;QACtB,oBAAoB,GAAG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,gBAA2B;YAC9D,aAAa,EAAE,cAAK,CAAC,2BAA2B,CAAC;gBAC7C,mBAAmB,EAAE,OAAO,CAAC,kBAAkB;gBAC/C,kBAAkB,EAAE,OAAO,CAAC,iBAAiB;gBAC7C,oBAAoB,EAAE,CAAC;aAC1B,CAAC;SACL;KACJ,CAAC,CAAC;IAEH,OAAO,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,CAAC;AACnC,CAAC,CAAC;AAEF,kBAAe,kBAAU,CAAC"}
@@ -23,6 +23,7 @@ __exportStar(require("./Card"), exports);
23
23
  __exportStar(require("./Chat"), exports);
24
24
  __exportStar(require("./Checkbox/Checkbox"), exports);
25
25
  __exportStar(require("./CodeAutocompleteField"), exports);
26
+ __exportStar(require("./ColorField/ColorField"), exports);
26
27
  __exportStar(require("./ContentGroup/ContentGroup"), exports);
27
28
  __exportStar(require("./ContextOverlay"), exports);
28
29
  __exportStar(require("./DecoupledOverlay/DecoupledOverlay"), exports);
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,8CAA4B;AAC5B,gDAA8B;AAC9B,gDAA8B;AAC9B,+CAA6B;AAC7B,kDAAgC;AAChC,yCAAuB;AACvB,yCAAuB;AACvB,sDAAoC;AACpC,0DAAwC;AACxC,8DAA4C;AAC5C,mDAAiC;AACjC,sEAAoD;AACpD,wDAAsC;AACtC,2CAAyB;AACzB,mDAAiC;AACjC,yCAAuB;AACvB,yCAAuB;AACvB,8DAA4C;AAC5C,yCAAuB;AACvB,2CAAyB;AACzB,oEAAkD;AAClD,gDAA8B;AAC9B,8CAA4B;AAC5B,8CAA4B;AAC5B,yCAAuB;AACvB,sDAAoC;AACpC,iDAA+B;AAC/B,iDAA+B;AAC/B,0DAAwC;AACxC,gDAA8B;AAC9B,sDAAoC;AACpC,4DAA0C;AAC1C,kDAAgC;AAChC,uDAAqC;AACrC,uDAAqC;AACrC,sDAAoC;AACpC,oDAAkC;AAClC,2CAAyB;AACzB,8CAA4B;AAC5B,iDAA+B;AAC/B,kDAAgC;AAChC,0CAAwB;AACxB,yCAAuB;AACvB,wCAAsB;AACtB,8CAA4B;AAC5B,4DAA0C;AAC1C,4CAA0B;AAC1B,oDAAkC;AAClC,8CAA4B;AAC5B,+CAA6B;AAC7B,0DAAwC;AACxC,8CAA4B;AAE5B,+CAA6B"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,8CAA4B;AAC5B,gDAA8B;AAC9B,gDAA8B;AAC9B,+CAA6B;AAC7B,kDAAgC;AAChC,yCAAuB;AACvB,yCAAuB;AACvB,sDAAoC;AACpC,0DAAwC;AACxC,0DAAwC;AACxC,8DAA4C;AAC5C,mDAAiC;AACjC,sEAAoD;AACpD,wDAAsC;AACtC,2CAAyB;AACzB,mDAAiC;AACjC,yCAAuB;AACvB,yCAAuB;AACvB,8DAA4C;AAC5C,yCAAuB;AACvB,2CAAyB;AACzB,oEAAkD;AAClD,gDAA8B;AAC9B,8CAA4B;AAC5B,8CAA4B;AAC5B,yCAAuB;AACvB,sDAAoC;AACpC,iDAA+B;AAC/B,iDAA+B;AAC/B,0DAAwC;AACxC,gDAA8B;AAC9B,sDAAoC;AACpC,4DAA0C;AAC1C,kDAAgC;AAChC,uDAAqC;AACrC,uDAAqC;AACrC,sDAAoC;AACpC,oDAAkC;AAClC,2CAAyB;AACzB,8CAA4B;AAC5B,iDAA+B;AAC/B,kDAAgC;AAChC,0CAAwB;AACxB,yCAAuB;AACvB,wCAAsB;AACtB,8CAA4B;AAC5B,4DAA0C;AAC1C,4CAA0B;AAC1B,oDAAkC;AAClC,8CAA4B;AAC5B,+CAA6B;AAC7B,0DAAwC;AACxC,8CAA4B;AAE5B,+CAA6B"}
@@ -0,0 +1,139 @@
1
+ var __assign = (this && this.__assign) || function () {
2
+ __assign = Object.assign || function(t) {
3
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
4
+ s = arguments[i];
5
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
6
+ t[p] = s[p];
7
+ }
8
+ return t;
9
+ };
10
+ return __assign.apply(this, arguments);
11
+ };
12
+ var __rest = (this && this.__rest) || function (s, e) {
13
+ var t = {};
14
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
15
+ t[p] = s[p];
16
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
17
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
18
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
19
+ t[p[i]] = s[p[i]];
20
+ }
21
+ return t;
22
+ };
23
+ var __read = (this && this.__read) || function (o, n) {
24
+ var m = typeof Symbol === "function" && o[Symbol.iterator];
25
+ if (!m) return o;
26
+ var i = m.call(o), r, ar = [], e;
27
+ try {
28
+ while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
29
+ }
30
+ catch (error) { e = { error: error }; }
31
+ finally {
32
+ try {
33
+ if (r && !r.done && (m = i["return"])) m.call(i);
34
+ }
35
+ finally { if (e) throw e.error; }
36
+ }
37
+ return ar;
38
+ };
39
+ import React from "react";
40
+ import classNames from "classnames";
41
+ import { utils } from "../../common/index.js";
42
+ import { CLASSPREFIX as eccgui } from "../../configuration/constants.js";
43
+ import { ContextOverlay } from "../ContextOverlay/index.js";
44
+ import { FieldSet } from "../Form/index.js";
45
+ import { RadioButton } from "../RadioButton/RadioButton.js";
46
+ import { Spacing } from "../Separation/Spacing.js";
47
+ import { Tag, TagList } from "../Tag/index.js";
48
+ import { TextField } from "../TextField/index.js";
49
+ import { Tooltip } from "../Tooltip/Tooltip.js";
50
+ import { WhiteSpaceContainer } from "../Typography/index.js";
51
+ /**
52
+ * Color input field that provides resets from the configured color palette.
53
+ * Use `colorWeightFilter` and `paletteGroupFilter` to filter them.
54
+ */
55
+ export var ColorField = function (_a) {
56
+ var _b, _c;
57
+ var _d = _a.className, className = _d === void 0 ? "" : _d, _e = _a.allowCustomColor, allowCustomColor = _e === void 0 ? false : _e, _f = _a.colorWeightFilter, colorWeightFilter = _f === void 0 ? [100, 300, 700, 900] : _f, _g = _a.paletteGroupFilter, paletteGroupFilter = _g === void 0 ? ["layout"] : _g, defaultValue = _a.defaultValue, value = _a.value, onChange = _a.onChange, _h = _a.fullWidth, fullWidth = _h === void 0 ? false : _h, otherTextFieldProps = __rest(_a, ["className", "allowCustomColor", "colorWeightFilter", "paletteGroupFilter", "defaultValue", "value", "onChange", "fullWidth"]);
58
+ var ref = React.useRef(null);
59
+ var _j = __read(React.useState(defaultValue || value || "#000000"), 2), colorValue = _j[0], setColorValue = _j[1];
60
+ var allowedPaletteColors, disableNativePicker, disabled;
61
+ var updateConfig = function () {
62
+ allowedPaletteColors = utils.getEnabledColorPropertiesFromPalette({
63
+ includePaletteGroup: paletteGroupFilter,
64
+ includeColorWeight: colorWeightFilter,
65
+ minimalColorDistance: 0, // we use all allowed colors, and do not check distances between them
66
+ });
67
+ disableNativePicker =
68
+ colorWeightFilter.length > 0 && paletteGroupFilter.length > 0 && allowedPaletteColors.length > 0;
69
+ disabled = (!disableNativePicker && !allowCustomColor) || otherTextFieldProps.disabled;
70
+ };
71
+ updateConfig();
72
+ React.useEffect(function () {
73
+ updateConfig();
74
+ }, [allowCustomColor, colorWeightFilter, paletteGroupFilter, otherTextFieldProps]);
75
+ React.useEffect(function () {
76
+ setColorValue(defaultValue || value || "#000000");
77
+ }, [defaultValue, value]);
78
+ var forwardOnChange = function (forwardedEvent) {
79
+ setColorValue(forwardedEvent.target.value);
80
+ if (onChange) {
81
+ onChange(forwardedEvent);
82
+ }
83
+ };
84
+ var colorInput = (React.createElement(TextField, __assign({ inputRef: ref, className: classNames("".concat(eccgui, "-colorfield"), className, (_b = {},
85
+ _b["".concat(eccgui, "-colorfield--custom-picker")] = disableNativePicker,
86
+ _b)),
87
+ // we cannot use `color` type for the custom picker because we do not have control over it then
88
+ type: !disableNativePicker ? "color" : "text", readOnly: disableNativePicker, disabled: disabled, value: colorValue, fullWidth: fullWidth }, otherTextFieldProps, { onChange: !disableNativePicker
89
+ ? function (e) {
90
+ forwardOnChange(e);
91
+ }
92
+ : undefined, style: __assign(__assign({}, otherTextFieldProps.style), (_c = {}, _c["--eccgui-colorfield-background"] = colorValue, _c)) })));
93
+ return disableNativePicker && !disabled ? (React.createElement(ContextOverlay, { fill: fullWidth, content: React.createElement(WhiteSpaceContainer, { paddingTop: "small", paddingRight: "small", paddingBottom: "small", paddingLeft: "small", className: "".concat(eccgui, "-colorfield__picker") },
94
+ allowCustomColor && (React.createElement(React.Fragment, null,
95
+ React.createElement(TextField, { type: "color", value: colorValue, onChange: function (e) {
96
+ forwardOnChange(e);
97
+ } }),
98
+ React.createElement(Spacing, { size: "small" }))),
99
+ React.createElement(FieldSet, null,
100
+ React.createElement(TagList, { className: "".concat(eccgui, "-colorfield__palette ").concat(eccgui, "-colorfield__palette--").concat(colorWeightFilter.length >= 3 ? colorWeightFilter.length * 2 : "8", "col") }, allowedPaletteColors.map(function (color, idx) {
101
+ var _a;
102
+ return [
103
+ React.createElement(RadioButton, { className: "".concat(eccgui, "-colorfield__palette__color"), hideIndicator: true, value: color[1], onChange: function (e) {
104
+ forwardOnChange(e);
105
+ } },
106
+ React.createElement(Tooltip, { key: idx, content: color[0].replace("".concat(eccgui, "-color-palette-"), "") },
107
+ React.createElement(Tag, { large: true, style: (_a = {}, _a["--eccgui-colorfield-palette-color"] = color[1], _a) }, color[1]))),
108
+ // Looks like we cannot force some type of line break in the tag list via CSS only
109
+ (idx + 1) % (colorWeightFilter.length >= 3 ? colorWeightFilter.length * 2 : 8) ===
110
+ 0 && (React.createElement(React.Fragment, null,
111
+ React.createElement("br", { className: "".concat(eccgui, "-colorfield__palette-linebreak") }))),
112
+ ];
113
+ })))) }, colorInput)) : (colorInput);
114
+ };
115
+ /**
116
+ * Simple helper function that provide simple access to color hash calculation.
117
+ * Using the same default values for the color palette filter.
118
+ */
119
+ ColorField.calculateColorHashValue = function (text, options) {
120
+ if (options === void 0) { options = {
121
+ allowCustomColor: false,
122
+ colorWeightFilter: [100, 300, 700, 900],
123
+ paletteGroupFilter: ["layout"],
124
+ }; }
125
+ var hash = utils.textToColorHash({
126
+ text: text,
127
+ options: {
128
+ returnValidColorsDirectly: options.allowCustomColor,
129
+ enabledColors: utils.getEnabledColorsFromPalette({
130
+ includePaletteGroup: options.paletteGroupFilter,
131
+ includeColorWeight: options.colorWeightFilter,
132
+ minimalColorDistance: 0,
133
+ }),
134
+ },
135
+ });
136
+ return hash ? hash : undefined;
137
+ };
138
+ export default ColorField;
139
+ //# sourceMappingURL=ColorField.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ColorField.js","sourceRoot":"","sources":["../../../../src/components/ColorField/ColorField.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,KAAwB,MAAM,OAAO,CAAC;AAC7C,OAAO,UAAU,MAAM,YAAY,CAAC;AAEpC,OAAO,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AAErC,OAAO,EAAE,WAAW,IAAI,MAAM,EAAE,MAAM,+BAA+B,CAAC;AACtE,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AACnD,OAAO,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AACnC,OAAO,EAAE,WAAW,EAAE,MAAM,4BAA4B,CAAC;AACzD,OAAO,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAC;AAChD,OAAO,EAAE,GAAG,EAAE,OAAO,EAAE,MAAM,QAAQ,CAAC;AACtC,OAAO,EAAE,SAAS,EAAkB,MAAM,cAAc,CAAC;AACzD,OAAO,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAC;AAC7C,OAAO,EAAE,mBAAmB,EAAE,MAAM,eAAe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AC,CAAC,CAAC,CAAC,iBAAiB,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;4BAC1E,CAAC,IAAI,CACL;4BACI,4BAAI,SAAS,EAAE,UAAG,MAAM,mCAAgC,GAAI,CAC7D,CACN;qBACJ;gBAzBoE,CAyBpE,CAAC,CACI,CACH,CACO,IAGzB,UAAU,CACE,CACpB,CAAC,CAAC,CAAC,CACA,UAAU,CACb,CAAC;AACN,CAAC,CAAC;AAOF;;;GAGG;AACH,UAAU,CAAC,uBAAuB,GAAG,UACjC,IAAY,EACZ,OAIC;IAJD,wBAAA,EAAA;QACI,gBAAgB,EAAE,KAAK;QACvB,iBAAiB,EAAE,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC;QACvC,kBAAkB,EAAE,CAAC,QAAQ,CAAC;KACjC;IAED,IAAM,IAAI,GAAG,KAAK,CAAC,eAAe,CAAC;QAC/B,IAAI,MAAA;QACJ,OAAO,EAAE;YACL,yBAAyB,EAAE,OAAO,CAAC,gBAA2B;YAC9D,aAAa,EAAE,KAAK,CAAC,2BAA2B,CAAC;gBAC7C,mBAAmB,EAAE,OAAO,CAAC,kBAAkB;gBAC/C,kBAAkB,EAAE,OAAO,CAAC,iBAAiB;gBAC7C,oBAAoB,EAAE,CAAC;aAC1B,CAAC;SACL;KACJ,CAAC,CAAC;IAEH,OAAO,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,CAAC;AACnC,CAAC,CAAC;AAEF,eAAe,UAAU,CAAC"}
@@ -7,6 +7,7 @@ export * from "./Card/index.js";
7
7
  export * from "./Chat/index.js";
8
8
  export * from "./Checkbox/Checkbox.js";
9
9
  export * from "./CodeAutocompleteField/index.js";
10
+ export * from "./ColorField/ColorField.js";
10
11
  export * from "./ContentGroup/ContentGroup.js";
11
12
  export * from "./ContextOverlay/index.js";
12
13
  export * from "./DecoupledOverlay/DecoupledOverlay.js";
@@ -1 +1 @@
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AAC;AACpC,cAAc,mBAAmB,CAAC;AAClC,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iBAAiB,CAAC;AAChC,cAAc,SAAS,CAAC;AACxB,cAAc,QAAQ,CAAC;AACvB,cAAc,OAAO,CAAC;AACtB,cAAc,aAAa,CAAC;AAC5B,cAAc,2BAA2B,CAAC;AAC1C,cAAc,WAAW,CAAC;AAC1B,cAAc,mBAAmB,CAAC;AAClC,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,yBAAyB,CAAC;AACxC,cAAc,aAAa,CAAC;AAE5B,cAAc,cAAc,CAAC"}
@@ -0,0 +1,31 @@
1
+ import React from "react";
2
+ import { ColorWeight, PaletteGroup } from "../../common/utils/colorHash";
3
+ import { TextFieldProps } from "../TextField";
4
+ export interface ColorFieldProps extends Omit<TextFieldProps, "invisibleCharacterWarning"> {
5
+ /**
6
+ * Any color can be selected, not only from the configured color palette.
7
+ */
8
+ allowCustomColor?: boolean;
9
+ /**
10
+ * What color weights should be included in the set of allowed colors.
11
+ */
12
+ colorWeightFilter?: ColorWeight[];
13
+ /**
14
+ * What palette groups should be included in the set of allowed colors.
15
+ */
16
+ paletteGroupFilter?: PaletteGroup[];
17
+ }
18
+ /**
19
+ * Color input field that provides resets from the configured color palette.
20
+ * Use `colorWeightFilter` and `paletteGroupFilter` to filter them.
21
+ */
22
+ export declare const ColorField: {
23
+ ({ className, allowCustomColor, colorWeightFilter, paletteGroupFilter, defaultValue, value, onChange, fullWidth, ...otherTextFieldProps }: ColorFieldProps): React.JSX.Element;
24
+ /**
25
+ * Simple helper function that provide simple access to color hash calculation.
26
+ * Using the same default values for the color palette filter.
27
+ */
28
+ calculateColorHashValue(text: string, options?: calculateColorHashValueProps): string | undefined;
29
+ };
30
+ type calculateColorHashValueProps = Pick<ColorFieldProps, "allowCustomColor" | "colorWeightFilter" | "paletteGroupFilter">;
31
+ export default ColorField;
@@ -7,6 +7,7 @@ export * from "./Card";
7
7
  export * from "./Chat";
8
8
  export * from "./Checkbox/Checkbox";
9
9
  export * from "./CodeAutocompleteField";
10
+ export * from "./ColorField/ColorField";
10
11
  export * from "./ContentGroup/ContentGroup";
11
12
  export * from "./ContextOverlay";
12
13
  export * from "./DecoupledOverlay/DecoupledOverlay";
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@eccenca/gui-elements",
3
3
  "description": "GUI elements based on other libraries, usable in React application, written in Typescript.",
4
- "version": "25.0.0-featurecolorwheelinputcmem7327.0",
4
+ "version": "25.0.0-featurecolorwheelinputcmem7327.1",
5
5
  "license": "Apache-2.0",
6
6
  "homepage": "https://github.com/eccenca/gui-elements",
7
7
  "bugs": "https://github.com/eccenca/gui-elements/issues",
@@ -7,6 +7,7 @@ export * from "./Card";
7
7
  export * from "./Chat";
8
8
  export * from "./Checkbox/Checkbox";
9
9
  export * from "./CodeAutocompleteField";
10
+ export * from "./ColorField/ColorField";
10
11
  export * from "./ContentGroup/ContentGroup";
11
12
  export * from "./ContextOverlay";
12
13
  export * from "./DecoupledOverlay/DecoupledOverlay";