funda-ui 4.2.255 → 4.2.445
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/CascadingSelect/index.js +1 -1
- package/EventCalendar/index.css +3 -0
- package/EventCalendar/index.d.ts +4 -1
- package/EventCalendar/index.js +16 -4
- package/EventCalendarTimeline/index.css +17 -0
- package/EventCalendarTimeline/index.d.ts +9 -2
- package/EventCalendarTimeline/index.js +77 -22
- package/LiveSearch/index.css +12 -0
- package/LiveSearch/index.js +1 -1
- package/ModalDialog/index.js +1 -1
- package/MultilevelDropdownMenu/index.css +2 -2
- package/MultilevelDropdownMenu/index.js +54 -46
- package/MultipleSelect/index.css +35 -26
- package/MultipleSelect/index.d.ts +3 -0
- package/MultipleSelect/index.js +366 -134
- package/NativeSelect/index.js +75 -47
- package/Pagination/index.d.ts +2 -0
- package/Pagination/index.js +25 -21
- package/Radio/index.js +14 -6
- package/RangeSlider/index.css +1 -0
- package/Select/index.css +5 -0
- package/Select/index.d.ts +1 -0
- package/Select/index.js +31 -11
- package/Tabs/index.js +13 -2
- package/Tree/index.js +90 -56
- package/lib/cjs/CascadingSelect/index.js +1 -1
- package/lib/cjs/EventCalendar/index.d.ts +4 -1
- package/lib/cjs/EventCalendar/index.js +16 -4
- package/lib/cjs/EventCalendarTimeline/index.d.ts +9 -2
- package/lib/cjs/EventCalendarTimeline/index.js +77 -22
- package/lib/cjs/LiveSearch/index.js +1 -1
- package/lib/cjs/ModalDialog/index.js +1 -1
- package/lib/cjs/MultilevelDropdownMenu/index.js +54 -46
- package/lib/cjs/MultipleSelect/index.d.ts +3 -0
- package/lib/cjs/MultipleSelect/index.js +366 -134
- package/lib/cjs/NativeSelect/index.js +75 -47
- package/lib/cjs/Pagination/index.d.ts +2 -0
- package/lib/cjs/Pagination/index.js +25 -21
- package/lib/cjs/Radio/index.js +14 -6
- package/lib/cjs/Select/index.d.ts +1 -0
- package/lib/cjs/Select/index.js +31 -11
- package/lib/cjs/Tabs/index.js +13 -2
- package/lib/cjs/Tree/index.js +90 -56
- package/lib/css/EventCalendar/index.css +3 -0
- package/lib/css/EventCalendarTimeline/index.css +17 -0
- package/lib/css/LiveSearch/index.css +12 -0
- package/lib/css/MultilevelDropdownMenu/index.css +2 -2
- package/lib/css/MultipleSelect/index.css +35 -26
- package/lib/css/RangeSlider/index.css +1 -0
- package/lib/css/Select/index.css +5 -0
- package/lib/esm/CascadingSelect/index.tsx +1 -1
- package/lib/esm/EventCalendar/index.scss +2 -0
- package/lib/esm/EventCalendar/index.tsx +23 -6
- package/lib/esm/EventCalendarTimeline/index.scss +24 -1
- package/lib/esm/EventCalendarTimeline/index.tsx +195 -118
- package/lib/esm/LiveSearch/index.scss +14 -1
- package/lib/esm/LiveSearch/index.tsx +1 -1
- package/lib/esm/ModalDialog/index.tsx +1 -1
- package/lib/esm/MultilevelDropdownMenu/{MenuList.tsx → ItemList.tsx} +52 -45
- package/lib/esm/MultilevelDropdownMenu/index.scss +2 -2
- package/lib/esm/MultilevelDropdownMenu/index.tsx +12 -4
- package/lib/esm/MultipleSelect/ItemList.tsx +300 -0
- package/lib/esm/MultipleSelect/index.scss +61 -30
- package/lib/esm/MultipleSelect/index.tsx +56 -87
- package/lib/esm/MultipleSelect/multiple-select-utils/func.ts +29 -0
- package/lib/esm/NativeSelect/index.tsx +4 -18
- package/lib/esm/NativeSelect/native-select-utils/func.ts +40 -0
- package/lib/esm/Pagination/index.tsx +31 -22
- package/lib/esm/Radio/index.tsx +19 -6
- package/lib/esm/RangeSlider/index.scss +2 -0
- package/lib/esm/Select/index.scss +6 -1
- package/lib/esm/Select/index.tsx +70 -54
- package/lib/esm/Table/Table.tsx +2 -0
- package/lib/esm/Tabs/Tabs.tsx +19 -4
- package/lib/esm/Tree/TreeList.tsx +61 -54
- package/lib/esm/Tree/index.tsx +4 -0
- package/package.json +1 -1
package/NativeSelect/index.js
CHANGED
|
@@ -4186,14 +4186,57 @@ var __webpack_exports__ = {};
|
|
|
4186
4186
|
// This entry need to be wrapped in an IIFE because it need to be in strict mode.
|
|
4187
4187
|
(() => {
|
|
4188
4188
|
"use strict";
|
|
4189
|
+
// ESM COMPAT FLAG
|
|
4189
4190
|
__webpack_require__.r(__webpack_exports__);
|
|
4190
|
-
|
|
4191
|
-
|
|
4192
|
-
|
|
4193
|
-
|
|
4194
|
-
|
|
4195
|
-
|
|
4196
|
-
|
|
4191
|
+
|
|
4192
|
+
// EXPORTS
|
|
4193
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
4194
|
+
"default": () => (/* binding */ src)
|
|
4195
|
+
});
|
|
4196
|
+
|
|
4197
|
+
// EXTERNAL MODULE: external {"root":"React","commonjs2":"react","commonjs":"react","amd":"react"}
|
|
4198
|
+
var external_root_React_commonjs2_react_commonjs_react_amd_react_ = __webpack_require__(787);
|
|
4199
|
+
var external_root_React_commonjs2_react_commonjs_react_amd_react_default = /*#__PURE__*/__webpack_require__.n(external_root_React_commonjs2_react_commonjs_react_amd_react_);
|
|
4200
|
+
;// CONCATENATED MODULE: ./src/native-select-utils/func.ts
|
|
4201
|
+
/**
|
|
4202
|
+
* Format indent value
|
|
4203
|
+
* @param {String|Array} inputData
|
|
4204
|
+
* @param {String} placeholder
|
|
4205
|
+
* @returns {String|Array}
|
|
4206
|
+
*/
|
|
4207
|
+
function formatIndentVal(inputData, placeholder) {
|
|
4208
|
+
var reVar = new RegExp(placeholder, 'g');
|
|
4209
|
+
if (Array.isArray(inputData)) {
|
|
4210
|
+
return inputData.map(function (s) {
|
|
4211
|
+
return String(s).replace(reVar, '').replace(/\ /ig, '');
|
|
4212
|
+
});
|
|
4213
|
+
} else {
|
|
4214
|
+
var _txt = typeof inputData === 'string' ? inputData : inputData.toString();
|
|
4215
|
+
return _txt.replace(reVar, '').replace(/\ /ig, '');
|
|
4216
|
+
}
|
|
4217
|
+
}
|
|
4218
|
+
|
|
4219
|
+
/**
|
|
4220
|
+
* Flat options
|
|
4221
|
+
* @param {Array}allData
|
|
4222
|
+
* @returns {Array}
|
|
4223
|
+
*/
|
|
4224
|
+
function optionsFlat(allData) {
|
|
4225
|
+
var flatItems = [];
|
|
4226
|
+
allData.forEach(function (item) {
|
|
4227
|
+
if (typeof item.optgroup !== 'undefined') {
|
|
4228
|
+
item.optgroup.forEach(function (opt) {
|
|
4229
|
+
flatItems.push(opt);
|
|
4230
|
+
});
|
|
4231
|
+
} else {
|
|
4232
|
+
flatItems.push(item);
|
|
4233
|
+
}
|
|
4234
|
+
});
|
|
4235
|
+
return flatItems;
|
|
4236
|
+
}
|
|
4237
|
+
// EXTERNAL MODULE: ../Utils/dist/cjs/index.js
|
|
4238
|
+
var cjs = __webpack_require__(456);
|
|
4239
|
+
;// CONCATENATED MODULE: ./src/index.tsx
|
|
4197
4240
|
var _excluded = ["wrapperClassName", "disabled", "required", "value", "label", "name", "id", "options", "hierarchical", "indentation", "doubleIndent", "style", "tabIndex", "fetchFuncAsync", "fetchFuncMethod", "fetchFuncMethodParams", "fetchCallback", "onFetch", "onChange", "onBlur", "onFocus"];
|
|
4198
4241
|
function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return exports; }; var exports = {}, Op = Object.prototype, hasOwn = Op.hasOwnProperty, defineProperty = Object.defineProperty || function (obj, key, desc) { obj[key] = desc.value; }, $Symbol = "function" == typeof Symbol ? Symbol : {}, iteratorSymbol = $Symbol.iterator || "@@iterator", asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator", toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag"; function define(obj, key, value) { return Object.defineProperty(obj, key, { value: value, enumerable: !0, configurable: !0, writable: !0 }), obj[key]; } try { define({}, ""); } catch (err) { define = function define(obj, key, value) { return obj[key] = value; }; } function wrap(innerFn, outerFn, self, tryLocsList) { var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator, generator = Object.create(protoGenerator.prototype), context = new Context(tryLocsList || []); return defineProperty(generator, "_invoke", { value: makeInvokeMethod(innerFn, self, context) }), generator; } function tryCatch(fn, obj, arg) { try { return { type: "normal", arg: fn.call(obj, arg) }; } catch (err) { return { type: "throw", arg: err }; } } exports.wrap = wrap; var ContinueSentinel = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var IteratorPrototype = {}; define(IteratorPrototype, iteratorSymbol, function () { return this; }); var getProto = Object.getPrototypeOf, NativeIteratorPrototype = getProto && getProto(getProto(values([]))); NativeIteratorPrototype && NativeIteratorPrototype !== Op && hasOwn.call(NativeIteratorPrototype, iteratorSymbol) && (IteratorPrototype = NativeIteratorPrototype); var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(IteratorPrototype); function defineIteratorMethods(prototype) { ["next", "throw", "return"].forEach(function (method) { define(prototype, method, function (arg) { return this._invoke(method, arg); }); }); } function AsyncIterator(generator, PromiseImpl) { function invoke(method, arg, resolve, reject) { var record = tryCatch(generator[method], generator, arg); if ("throw" !== record.type) { var result = record.arg, value = result.value; return value && "object" == _typeof(value) && hasOwn.call(value, "__await") ? PromiseImpl.resolve(value.__await).then(function (value) { invoke("next", value, resolve, reject); }, function (err) { invoke("throw", err, resolve, reject); }) : PromiseImpl.resolve(value).then(function (unwrapped) { result.value = unwrapped, resolve(result); }, function (error) { return invoke("throw", error, resolve, reject); }); } reject(record.arg); } var previousPromise; defineProperty(this, "_invoke", { value: function value(method, arg) { function callInvokeWithMethodAndArg() { return new PromiseImpl(function (resolve, reject) { invoke(method, arg, resolve, reject); }); } return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(innerFn, self, context) { var state = "suspendedStart"; return function (method, arg) { if ("executing" === state) throw new Error("Generator is already running"); if ("completed" === state) { if ("throw" === method) throw arg; return doneResult(); } for (context.method = method, context.arg = arg;;) { var delegate = context.delegate; if (delegate) { var delegateResult = maybeInvokeDelegate(delegate, context); if (delegateResult) { if (delegateResult === ContinueSentinel) continue; return delegateResult; } } if ("next" === context.method) context.sent = context._sent = context.arg;else if ("throw" === context.method) { if ("suspendedStart" === state) throw state = "completed", context.arg; context.dispatchException(context.arg); } else "return" === context.method && context.abrupt("return", context.arg); state = "executing"; var record = tryCatch(innerFn, self, context); if ("normal" === record.type) { if (state = context.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel) continue; return { value: record.arg, done: context.done }; } "throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg); } }; } function maybeInvokeDelegate(delegate, context) { var methodName = context.method, method = delegate.iterator[methodName]; if (undefined === method) return context.delegate = null, "throw" === methodName && delegate.iterator["return"] && (context.method = "return", context.arg = undefined, maybeInvokeDelegate(delegate, context), "throw" === context.method) || "return" !== methodName && (context.method = "throw", context.arg = new TypeError("The iterator does not provide a '" + methodName + "' method")), ContinueSentinel; var record = tryCatch(method, delegate.iterator, context.arg); if ("throw" === record.type) return context.method = "throw", context.arg = record.arg, context.delegate = null, ContinueSentinel; var info = record.arg; return info ? info.done ? (context[delegate.resultName] = info.value, context.next = delegate.nextLoc, "return" !== context.method && (context.method = "next", context.arg = undefined), context.delegate = null, ContinueSentinel) : info : (context.method = "throw", context.arg = new TypeError("iterator result is not an object"), context.delegate = null, ContinueSentinel); } function pushTryEntry(locs) { var entry = { tryLoc: locs[0] }; 1 in locs && (entry.catchLoc = locs[1]), 2 in locs && (entry.finallyLoc = locs[2], entry.afterLoc = locs[3]), this.tryEntries.push(entry); } function resetTryEntry(entry) { var record = entry.completion || {}; record.type = "normal", delete record.arg, entry.completion = record; } function Context(tryLocsList) { this.tryEntries = [{ tryLoc: "root" }], tryLocsList.forEach(pushTryEntry, this), this.reset(!0); } function values(iterable) { if (iterable) { var iteratorMethod = iterable[iteratorSymbol]; if (iteratorMethod) return iteratorMethod.call(iterable); if ("function" == typeof iterable.next) return iterable; if (!isNaN(iterable.length)) { var i = -1, next = function next() { for (; ++i < iterable.length;) if (hasOwn.call(iterable, i)) return next.value = iterable[i], next.done = !1, next; return next.value = undefined, next.done = !0, next; }; return next.next = next; } } return { next: doneResult }; } function doneResult() { return { value: undefined, done: !0 }; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, defineProperty(Gp, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), defineProperty(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"), exports.isGeneratorFunction = function (genFun) { var ctor = "function" == typeof genFun && genFun.constructor; return !!ctor && (ctor === GeneratorFunction || "GeneratorFunction" === (ctor.displayName || ctor.name)); }, exports.mark = function (genFun) { return Object.setPrototypeOf ? Object.setPrototypeOf(genFun, GeneratorFunctionPrototype) : (genFun.__proto__ = GeneratorFunctionPrototype, define(genFun, toStringTagSymbol, "GeneratorFunction")), genFun.prototype = Object.create(Gp), genFun; }, exports.awrap = function (arg) { return { __await: arg }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () { return this; }), exports.AsyncIterator = AsyncIterator, exports.async = function (innerFn, outerFn, self, tryLocsList, PromiseImpl) { void 0 === PromiseImpl && (PromiseImpl = Promise); var iter = new AsyncIterator(wrap(innerFn, outerFn, self, tryLocsList), PromiseImpl); return exports.isGeneratorFunction(outerFn) ? iter : iter.next().then(function (result) { return result.done ? result.value : iter.next(); }); }, defineIteratorMethods(Gp), define(Gp, toStringTagSymbol, "Generator"), define(Gp, iteratorSymbol, function () { return this; }), define(Gp, "toString", function () { return "[object Generator]"; }), exports.keys = function (val) { var object = Object(val), keys = []; for (var key in object) keys.push(key); return keys.reverse(), function next() { for (; keys.length;) { var key = keys.pop(); if (key in object) return next.value = key, next.done = !1, next; } return next.done = !0, next; }; }, exports.values = values, Context.prototype = { constructor: Context, reset: function reset(skipTempReset) { if (this.prev = 0, this.next = 0, this.sent = this._sent = undefined, this.done = !1, this.delegate = null, this.method = "next", this.arg = undefined, this.tryEntries.forEach(resetTryEntry), !skipTempReset) for (var name in this) "t" === name.charAt(0) && hasOwn.call(this, name) && !isNaN(+name.slice(1)) && (this[name] = undefined); }, stop: function stop() { this.done = !0; var rootRecord = this.tryEntries[0].completion; if ("throw" === rootRecord.type) throw rootRecord.arg; return this.rval; }, dispatchException: function dispatchException(exception) { if (this.done) throw exception; var context = this; function handle(loc, caught) { return record.type = "throw", record.arg = exception, context.next = loc, caught && (context.method = "next", context.arg = undefined), !!caught; } for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i], record = entry.completion; if ("root" === entry.tryLoc) return handle("end"); if (entry.tryLoc <= this.prev) { var hasCatch = hasOwn.call(entry, "catchLoc"), hasFinally = hasOwn.call(entry, "finallyLoc"); if (hasCatch && hasFinally) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } else if (hasCatch) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); } else { if (!hasFinally) throw new Error("try statement without catch or finally"); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } } } }, abrupt: function abrupt(type, arg) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc <= this.prev && hasOwn.call(entry, "finallyLoc") && this.prev < entry.finallyLoc) { var finallyEntry = entry; break; } } finallyEntry && ("break" === type || "continue" === type) && finallyEntry.tryLoc <= arg && arg <= finallyEntry.finallyLoc && (finallyEntry = null); var record = finallyEntry ? finallyEntry.completion : {}; return record.type = type, record.arg = arg, finallyEntry ? (this.method = "next", this.next = finallyEntry.finallyLoc, ContinueSentinel) : this.complete(record); }, complete: function complete(record, afterLoc) { if ("throw" === record.type) throw record.arg; return "break" === record.type || "continue" === record.type ? this.next = record.arg : "return" === record.type ? (this.rval = this.arg = record.arg, this.method = "return", this.next = "end") : "normal" === record.type && afterLoc && (this.next = afterLoc), ContinueSentinel; }, finish: function finish(finallyLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.finallyLoc === finallyLoc) return this.complete(entry.completion, entry.afterLoc), resetTryEntry(entry), ContinueSentinel; } }, "catch": function _catch(tryLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc === tryLoc) { var record = entry.completion; if ("throw" === record.type) { var thrown = record.arg; resetTryEntry(entry); } return thrown; } } throw new Error("illegal catch attempt"); }, delegateYield: function delegateYield(iterable, resultName, nextLoc) { return this.delegate = { iterator: values(iterable), resultName: resultName, nextLoc: nextLoc }, "next" === this.method && (this.arg = undefined), ContinueSentinel; } }, exports; }
|
|
4199
4242
|
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
|
|
@@ -4214,7 +4257,8 @@ function _objectWithoutProperties(source, excluded) { if (source == null) return
|
|
|
4214
4257
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
4215
4258
|
|
|
4216
4259
|
|
|
4217
|
-
|
|
4260
|
+
|
|
4261
|
+
var NativeSelect = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_react_amd_react_.forwardRef)(function (props, externalRef) {
|
|
4218
4262
|
var wrapperClassName = props.wrapperClassName,
|
|
4219
4263
|
disabled = props.disabled,
|
|
4220
4264
|
required = props.required,
|
|
@@ -4239,36 +4283,31 @@ var NativeSelect = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef
|
|
|
4239
4283
|
attributes = _objectWithoutProperties(props, _excluded);
|
|
4240
4284
|
var INDENT_PLACEHOLDER = doubleIndent ? " " : " ";
|
|
4241
4285
|
var INDENT_LAST_PLACEHOLDER = "".concat(typeof indentation !== 'undefined' && indentation !== '' ? "".concat(indentation, " ") : '');
|
|
4242
|
-
var uniqueID = (0,
|
|
4286
|
+
var uniqueID = (0,cjs.useComId)();
|
|
4243
4287
|
var idRes = id || uniqueID;
|
|
4244
|
-
var rootRef = (0,
|
|
4245
|
-
var selectRef = (0,
|
|
4246
|
-
var optionsRes = options ? (0,
|
|
4288
|
+
var rootRef = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useRef)(null);
|
|
4289
|
+
var selectRef = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useRef)(null);
|
|
4290
|
+
var optionsRes = options ? (0,cjs.isJSON)(options) ? JSON.parse(options) : options : '';
|
|
4247
4291
|
|
|
4248
4292
|
// return a array of options
|
|
4249
4293
|
var optionsDataInit = optionsRes;
|
|
4250
4294
|
|
|
4251
4295
|
//
|
|
4252
|
-
var _useState = (0,
|
|
4296
|
+
var _useState = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useState)(optionsDataInit),
|
|
4253
4297
|
_useState2 = _slicedToArray(_useState, 2),
|
|
4254
4298
|
dataInit = _useState2[0],
|
|
4255
4299
|
setDataInit = _useState2[1];
|
|
4256
|
-
var _useState3 = (0,
|
|
4300
|
+
var _useState3 = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useState)(false),
|
|
4257
4301
|
_useState4 = _slicedToArray(_useState3, 2),
|
|
4258
4302
|
hasErr = _useState4[0],
|
|
4259
4303
|
setHasErr = _useState4[1];
|
|
4260
|
-
var _useState5 = (0,
|
|
4304
|
+
var _useState5 = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useState)(''),
|
|
4261
4305
|
_useState6 = _slicedToArray(_useState5, 2),
|
|
4262
4306
|
controlValue = _useState6[0],
|
|
4263
4307
|
setControlValue = _useState6[1];
|
|
4264
4308
|
function fetchData(_x2) {
|
|
4265
4309
|
return _fetchData.apply(this, arguments);
|
|
4266
|
-
}
|
|
4267
|
-
/**
|
|
4268
|
-
* Format indent value
|
|
4269
|
-
* @param {String|Array} str
|
|
4270
|
-
* @returns {String|Array}
|
|
4271
|
-
*/
|
|
4310
|
+
} //
|
|
4272
4311
|
function _fetchData() {
|
|
4273
4312
|
_fetchData = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(params) {
|
|
4274
4313
|
var response, _ORGIN_DATA;
|
|
@@ -4304,12 +4343,12 @@ var NativeSelect = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef
|
|
|
4304
4343
|
|
|
4305
4344
|
// Set hierarchical categories ( with sub-categories )
|
|
4306
4345
|
if (hierarchical) {
|
|
4307
|
-
_ORGIN_DATA = (0,
|
|
4308
|
-
(0,
|
|
4346
|
+
_ORGIN_DATA = (0,cjs.addTreeDepth)(_ORGIN_DATA);
|
|
4347
|
+
(0,cjs.addTreeIndent)(_ORGIN_DATA, INDENT_PLACEHOLDER, INDENT_LAST_PLACEHOLDER, 'label');
|
|
4309
4348
|
}
|
|
4310
4349
|
|
|
4311
4350
|
// remove Duplicate objects from JSON Array
|
|
4312
|
-
_ORGIN_DATA = (0,
|
|
4351
|
+
_ORGIN_DATA = (0,cjs.removeArrDuplicateItems)(_ORGIN_DATA, 'value');
|
|
4313
4352
|
|
|
4314
4353
|
//
|
|
4315
4354
|
setDataInit(_ORGIN_DATA); // data must be initialized
|
|
@@ -4322,7 +4361,7 @@ var NativeSelect = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef
|
|
|
4322
4361
|
setControlValue(value); // value must be initialized
|
|
4323
4362
|
|
|
4324
4363
|
// remove Duplicate objects from JSON Array
|
|
4325
|
-
optionsDataInit = (0,
|
|
4364
|
+
optionsDataInit = (0,cjs.removeArrDuplicateItems)(optionsDataInit, 'value');
|
|
4326
4365
|
|
|
4327
4366
|
//
|
|
4328
4367
|
setDataInit(optionsDataInit); // data must be initialized
|
|
@@ -4338,18 +4377,6 @@ var NativeSelect = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef
|
|
|
4338
4377
|
}));
|
|
4339
4378
|
return _fetchData.apply(this, arguments);
|
|
4340
4379
|
}
|
|
4341
|
-
function formatIndentVal(str) {
|
|
4342
|
-
var reVar = new RegExp(INDENT_LAST_PLACEHOLDER, 'g');
|
|
4343
|
-
if (Array.isArray(str)) {
|
|
4344
|
-
return str.map(function (s) {
|
|
4345
|
-
return s.replace(reVar, '').replace(/\ /ig, '');
|
|
4346
|
-
});
|
|
4347
|
-
} else {
|
|
4348
|
-
return str.replace(reVar, '').replace(/\ /ig, '');
|
|
4349
|
-
}
|
|
4350
|
-
}
|
|
4351
|
-
|
|
4352
|
-
//
|
|
4353
4380
|
function handleFocus(event) {
|
|
4354
4381
|
var _rootRef$current;
|
|
4355
4382
|
(_rootRef$current = rootRef.current) === null || _rootRef$current === void 0 ? void 0 : _rootRef$current.classList.add('focus');
|
|
@@ -4371,7 +4398,8 @@ var NativeSelect = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef
|
|
|
4371
4398
|
|
|
4372
4399
|
//
|
|
4373
4400
|
if (typeof onChange === 'function') {
|
|
4374
|
-
|
|
4401
|
+
console.log('---', event.target.selectedIndex);
|
|
4402
|
+
onChange(event, optionsFlat(dataInit)[event.target.selectedIndex].value, optionsFlat(dataInit)[event.target.selectedIndex], event.target.selectedIndex);
|
|
4375
4403
|
event.target.blur();
|
|
4376
4404
|
}
|
|
4377
4405
|
}
|
|
@@ -4388,12 +4416,12 @@ var NativeSelect = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef
|
|
|
4388
4416
|
// Generate list of options
|
|
4389
4417
|
var selectOptionsList = Array.isArray(dataInit) ? dataInit.map(function (item, index) {
|
|
4390
4418
|
if (typeof item.optgroup !== 'undefined') {
|
|
4391
|
-
return /*#__PURE__*/
|
|
4419
|
+
return /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("optgroup", {
|
|
4392
4420
|
key: 'optgroup-' + index,
|
|
4393
4421
|
label: item.label
|
|
4394
4422
|
}, item.optgroup.map(function (opt, optIndex) {
|
|
4395
4423
|
var _disabled = typeof opt.disabled === 'undefined' ? false : opt.disabled;
|
|
4396
|
-
return /*#__PURE__*/
|
|
4424
|
+
return /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("option", {
|
|
4397
4425
|
key: 'option-' + optIndex,
|
|
4398
4426
|
value: opt.value,
|
|
4399
4427
|
dangerouslySetInnerHTML: {
|
|
@@ -4404,7 +4432,7 @@ var NativeSelect = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef
|
|
|
4404
4432
|
}));
|
|
4405
4433
|
} else {
|
|
4406
4434
|
var _disabled = typeof item.disabled === 'undefined' ? false : item.disabled;
|
|
4407
|
-
return /*#__PURE__*/
|
|
4435
|
+
return /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("option", {
|
|
4408
4436
|
key: 'option-' + index,
|
|
4409
4437
|
value: item.value,
|
|
4410
4438
|
dangerouslySetInnerHTML: {
|
|
@@ -4414,25 +4442,25 @@ var NativeSelect = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef
|
|
|
4414
4442
|
});
|
|
4415
4443
|
}
|
|
4416
4444
|
}) : null;
|
|
4417
|
-
(0,
|
|
4445
|
+
(0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useEffect)(function () {
|
|
4418
4446
|
// data init
|
|
4419
4447
|
//--------------
|
|
4420
4448
|
var _params = fetchFuncMethodParams || [];
|
|
4421
4449
|
fetchData(_params.join(','));
|
|
4422
4450
|
}, [value, options]);
|
|
4423
|
-
return /*#__PURE__*/
|
|
4451
|
+
return /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement((external_root_React_commonjs2_react_commonjs_react_amd_react_default()).Fragment, null, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("div", {
|
|
4424
4452
|
className: wrapperClassName || wrapperClassName === '' ? wrapperClassName : "mb-3 position-relative",
|
|
4425
4453
|
ref: rootRef
|
|
4426
|
-
}, label ? /*#__PURE__*/
|
|
4454
|
+
}, label ? /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement((external_root_React_commonjs2_react_commonjs_react_amd_react_default()).Fragment, null, typeof label === 'string' ? /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("label", {
|
|
4427
4455
|
htmlFor: idRes,
|
|
4428
4456
|
className: "form-label",
|
|
4429
4457
|
dangerouslySetInnerHTML: {
|
|
4430
4458
|
__html: "".concat(label)
|
|
4431
4459
|
}
|
|
4432
|
-
}) : /*#__PURE__*/
|
|
4460
|
+
}) : /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("label", {
|
|
4433
4461
|
htmlFor: idRes,
|
|
4434
4462
|
className: "form-label"
|
|
4435
|
-
}, label)) : null, /*#__PURE__*/
|
|
4463
|
+
}, label)) : null, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("select", _extends({
|
|
4436
4464
|
ref: function ref(node) {
|
|
4437
4465
|
selectRef.current = node;
|
|
4438
4466
|
if (typeof externalRef === 'function') {
|
|
@@ -4455,7 +4483,7 @@ var NativeSelect = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef
|
|
|
4455
4483
|
style: style
|
|
4456
4484
|
}, attributes), !hasErr ? selectOptionsList : null)));
|
|
4457
4485
|
});
|
|
4458
|
-
/* harmony default export */ const
|
|
4486
|
+
/* harmony default export */ const src = (NativeSelect);
|
|
4459
4487
|
})();
|
|
4460
4488
|
|
|
4461
4489
|
/******/ return __webpack_exports__;
|
package/Pagination/index.d.ts
CHANGED
|
@@ -4,6 +4,8 @@ declare type PaginationProps = {
|
|
|
4
4
|
wrapperClassName?: string;
|
|
5
5
|
/** The class name of the navigation */
|
|
6
6
|
navClassName?: string;
|
|
7
|
+
/** The class name of each item */
|
|
8
|
+
navItemClassName?: string;
|
|
7
9
|
/** An API URL Path. Use `{page}` characters to place a placeholder. such as `/mypage/{page}` */
|
|
8
10
|
apiUrl: string;
|
|
9
11
|
/** The range of pages displayed */
|
package/Pagination/index.js
CHANGED
|
@@ -169,6 +169,7 @@ function paginationNavigators(visibleNavigators, totalPages, activePage) {
|
|
|
169
169
|
var Pagination = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_react_amd_react_.forwardRef)(function (props, externalRef) {
|
|
170
170
|
var wrapperClassName = props.wrapperClassName,
|
|
171
171
|
navClassName = props.navClassName,
|
|
172
|
+
navItemClassName = props.navItemClassName,
|
|
172
173
|
apiUrl = props.apiUrl,
|
|
173
174
|
pageRangeDisplayed = props.pageRangeDisplayed,
|
|
174
175
|
activePage = props.activePage,
|
|
@@ -189,6 +190,8 @@ var Pagination = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_re
|
|
|
189
190
|
symmetry = props.symmetry,
|
|
190
191
|
style = props.style,
|
|
191
192
|
onChange = props.onChange;
|
|
193
|
+
var rootRef = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useRef)(null);
|
|
194
|
+
var visibleNavigators = pageRangeDisplayed ? pageRangeDisplayed : 3;
|
|
192
195
|
|
|
193
196
|
// exposes the following methods
|
|
194
197
|
(0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useImperativeHandle)(externalRef, function () {
|
|
@@ -214,8 +217,7 @@ var Pagination = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_re
|
|
|
214
217
|
});
|
|
215
218
|
}
|
|
216
219
|
};
|
|
217
|
-
}, [externalRef, activePage]);
|
|
218
|
-
var visibleNavigators = pageRangeDisplayed ? pageRangeDisplayed : 3;
|
|
220
|
+
}, [externalRef, totalPages, activePage]);
|
|
219
221
|
var alignClassName = '';
|
|
220
222
|
switch (align) {
|
|
221
223
|
case 'left':
|
|
@@ -228,12 +230,13 @@ var Pagination = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_re
|
|
|
228
230
|
alignClassName = ' justify-content-center';
|
|
229
231
|
break;
|
|
230
232
|
}
|
|
231
|
-
var
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
233
|
+
var _activeClassName = activeClassName || 'active',
|
|
234
|
+
_previousClassName = previousClassName || 'prev',
|
|
235
|
+
_nextClassName = nextClassName || 'next',
|
|
236
|
+
_firstClassName = firstClassName || 'first',
|
|
237
|
+
_lastClassName = lastClassName || 'last',
|
|
238
|
+
_disabledClassName = disabledClassName || 'disabled',
|
|
239
|
+
_itemClassName = navItemClassName || 'page-item',
|
|
237
240
|
_onlyPrevNextButtons = typeof onlyPrevNext === 'undefined' ? false : onlyPrevNext,
|
|
238
241
|
_symmetry = typeof symmetry === 'undefined' ? false : symmetry;
|
|
239
242
|
|
|
@@ -258,11 +261,11 @@ var Pagination = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_re
|
|
|
258
261
|
_ellipsisEnabled = true;
|
|
259
262
|
return /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("li", {
|
|
260
263
|
key: i,
|
|
261
|
-
className: activePage === item ? "
|
|
264
|
+
className: activePage === item ? "".concat(_itemClassName, " ").concat(_activeClassName) : "".concat(_itemClassName)
|
|
262
265
|
}, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("a", {
|
|
263
266
|
className: "page-link",
|
|
264
267
|
"data-page": item,
|
|
265
|
-
href: apiUrl.replace('{page}', item),
|
|
268
|
+
href: apiUrl === null || apiUrl === void 0 ? void 0 : apiUrl.replace('{page}', item),
|
|
266
269
|
onClick: function onClick(e) {
|
|
267
270
|
e.preventDefault();
|
|
268
271
|
onChange === null || onChange === void 0 ? void 0 : onChange(Number(item), Number(totalPages));
|
|
@@ -296,30 +299,31 @@ var Pagination = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_re
|
|
|
296
299
|
}
|
|
297
300
|
}
|
|
298
301
|
return /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement((external_root_React_commonjs2_react_commonjs_react_amd_react_default()).Fragment, null, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("nav", {
|
|
302
|
+
ref: rootRef,
|
|
299
303
|
className: wrapperClassName || wrapperClassName === '' ? wrapperClassName : "mb-3 position-relative",
|
|
300
304
|
style: style
|
|
301
305
|
}, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("ul", {
|
|
302
306
|
className: navClassName || navClassName === '' ? "".concat(navClassName, " ").concat(alignClassName) : "pagination ".concat(alignClassName)
|
|
303
307
|
}, firstLabel ? /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("li", {
|
|
304
|
-
className: activePage > 1 ? "
|
|
308
|
+
className: activePage > 1 ? "".concat(_itemClassName, " ").concat(_firstClassName) : "".concat(_itemClassName, " ").concat(_firstClassName, " ").concat(_disabledClassName)
|
|
305
309
|
}, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("a", {
|
|
306
310
|
tabIndex: activePage > 1 ? 0 : -1,
|
|
307
311
|
"aria-disabled": activePage > 1 ? 'false' : 'true',
|
|
308
312
|
className: "page-link",
|
|
309
313
|
"data-page": 1,
|
|
310
|
-
href: apiUrl.replace('{page}', '1'),
|
|
314
|
+
href: apiUrl === null || apiUrl === void 0 ? void 0 : apiUrl.replace('{page}', '1'),
|
|
311
315
|
onClick: function onClick(e) {
|
|
312
316
|
e.preventDefault();
|
|
313
317
|
handleClick('first');
|
|
314
318
|
}
|
|
315
319
|
}, firstLabel || null)) : '', previousLabel ? /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("li", {
|
|
316
|
-
className: activePage > 1 ? "
|
|
320
|
+
className: activePage > 1 ? "".concat(_itemClassName, " ").concat(_previousClassName) : "".concat(_itemClassName, " ").concat(_previousClassName, " ").concat(_disabledClassName)
|
|
317
321
|
}, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("a", {
|
|
318
322
|
tabIndex: activePage > 1 ? 0 : -1,
|
|
319
323
|
"aria-disabled": activePage > 1 ? 'false' : 'true',
|
|
320
324
|
className: "page-link",
|
|
321
325
|
"data-page": activePage - 1,
|
|
322
|
-
href: apiUrl.replace('{page}', activePage - 1),
|
|
326
|
+
href: apiUrl === null || apiUrl === void 0 ? void 0 : apiUrl.replace('{page}', activePage - 1),
|
|
323
327
|
onClick: function onClick(e) {
|
|
324
328
|
e.preventDefault();
|
|
325
329
|
handleClick('prev');
|
|
@@ -328,11 +332,11 @@ var Pagination = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_re
|
|
|
328
332
|
if (item > 0 && item <= totalPages && !_onlyPrevNextButtons) {
|
|
329
333
|
return /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("li", {
|
|
330
334
|
key: i,
|
|
331
|
-
className: activePage === item ? "
|
|
335
|
+
className: activePage === item ? "".concat(_itemClassName, " ").concat(_activeClassName) : "".concat(_itemClassName)
|
|
332
336
|
}, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("a", {
|
|
333
337
|
className: "page-link",
|
|
334
338
|
"data-page": item,
|
|
335
|
-
href: apiUrl.replace('{page}', item),
|
|
339
|
+
href: apiUrl === null || apiUrl === void 0 ? void 0 : apiUrl.replace('{page}', item),
|
|
336
340
|
onClick: function onClick(e) {
|
|
337
341
|
e.preventDefault();
|
|
338
342
|
onChange === null || onChange === void 0 ? void 0 : onChange(Number(item), Number(totalPages));
|
|
@@ -340,29 +344,29 @@ var Pagination = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_re
|
|
|
340
344
|
}, item));
|
|
341
345
|
}
|
|
342
346
|
}), _ellipsis !== '' && _ellipsisEnabled ? /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement((external_root_React_commonjs2_react_commonjs_react_amd_react_default()).Fragment, null, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("li", {
|
|
343
|
-
className:
|
|
347
|
+
className: _itemClassName
|
|
344
348
|
}, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("span", {
|
|
345
349
|
className: "page-link"
|
|
346
350
|
}, _ellipsis))) : '', _ellipsisElements, nextLabel ? /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("li", {
|
|
347
|
-
className: activePage < totalPages ? "
|
|
351
|
+
className: activePage < totalPages ? "".concat(_itemClassName, " ").concat(_nextClassName) : "".concat(_itemClassName, " ").concat(_nextClassName, " ").concat(_disabledClassName)
|
|
348
352
|
}, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("a", {
|
|
349
353
|
tabIndex: activePage < totalPages ? 0 : -1,
|
|
350
354
|
"aria-disabled": activePage < totalPages ? 'false' : 'true',
|
|
351
355
|
className: "page-link",
|
|
352
356
|
"data-page": activePage + 1,
|
|
353
|
-
href: apiUrl.replace('{page}', activePage + 1),
|
|
357
|
+
href: apiUrl === null || apiUrl === void 0 ? void 0 : apiUrl.replace('{page}', activePage + 1),
|
|
354
358
|
onClick: function onClick(e) {
|
|
355
359
|
e.preventDefault();
|
|
356
360
|
handleClick('next');
|
|
357
361
|
}
|
|
358
362
|
}, nextLabel || null)) : '', lastLabel ? /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("li", {
|
|
359
|
-
className: activePage < totalPages ? "
|
|
363
|
+
className: activePage < totalPages ? "".concat(_itemClassName, " ").concat(_lastClassName) : "".concat(_itemClassName, " ").concat(_lastClassName, " ").concat(_disabledClassName)
|
|
360
364
|
}, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("a", {
|
|
361
365
|
tabIndex: activePage < totalPages ? 0 : -1,
|
|
362
366
|
"aria-disabled": activePage < totalPages ? 'false' : 'true',
|
|
363
367
|
className: "page-link",
|
|
364
368
|
"data-page": totalPages,
|
|
365
|
-
href: apiUrl.replace('{page}', totalPages),
|
|
369
|
+
href: apiUrl === null || apiUrl === void 0 ? void 0 : apiUrl.replace('{page}', totalPages),
|
|
366
370
|
onClick: function onClick(e) {
|
|
367
371
|
e.preventDefault();
|
|
368
372
|
handleClick('last');
|
package/Radio/index.js
CHANGED
|
@@ -4517,10 +4517,18 @@ var Radio = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef)(funct
|
|
|
4517
4517
|
}
|
|
4518
4518
|
return Array.isArray(dataInit) ? dataInit.map(function (item, index) {
|
|
4519
4519
|
var requiredVal = index === 0 ? required || null : null;
|
|
4520
|
+
var _formatItem = {};
|
|
4521
|
+
Object.keys(item).forEach(function (key) {
|
|
4522
|
+
if (key !== 'extends') _formatItem[key] = item[key];
|
|
4523
|
+
});
|
|
4520
4524
|
var _groupEl = function _groupEl() {
|
|
4521
4525
|
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
|
|
4522
4526
|
className: "radio-group__label ".concat(groupLabelClassName || '')
|
|
4523
4527
|
}, item.label), item.optgroup.map(function (opt, optIndex) {
|
|
4528
|
+
var _formatOpt = {};
|
|
4529
|
+
Object.keys(item).forEach(function (key) {
|
|
4530
|
+
if (key !== 'extends') _formatOpt[key] = item[key];
|
|
4531
|
+
});
|
|
4524
4532
|
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
|
|
4525
4533
|
key: 'option-' + optIndex,
|
|
4526
4534
|
className: "".concat(inline ? "form-check form-check-inline" : "form-check", " ").concat(controlValue == opt.value ? itemSelectedClassName || 'item-selected' : '')
|
|
@@ -4540,7 +4548,7 @@ var Radio = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef)(funct
|
|
|
4540
4548
|
"data-list-item-label": "".concat(typeof opt.listItemLabel === 'undefined' ? '' : opt.listItemLabel),
|
|
4541
4549
|
"data-value": opt.value,
|
|
4542
4550
|
"data-disabled": disabled || (typeof opt.disabled !== 'undefined' ? "".concat(opt.disabled) : 'false'),
|
|
4543
|
-
"data-optiondata": JSON.stringify(
|
|
4551
|
+
"data-optiondata": JSON.stringify(_formatOpt),
|
|
4544
4552
|
value: "".concat(opt.value),
|
|
4545
4553
|
required: requiredVal,
|
|
4546
4554
|
disabled: disabled || (typeof opt.disabled !== 'undefined' ? opt.disabled : null),
|
|
@@ -4577,7 +4585,7 @@ var Radio = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef)(funct
|
|
|
4577
4585
|
"data-list-item-label": "".concat(typeof item.listItemLabel === 'undefined' ? '' : item.listItemLabel),
|
|
4578
4586
|
"data-value": item.value,
|
|
4579
4587
|
"data-disabled": disabled || (typeof item.disabled !== 'undefined' ? "".concat(item.disabled) : 'false'),
|
|
4580
|
-
"data-optiondata": JSON.stringify(
|
|
4588
|
+
"data-optiondata": JSON.stringify(_formatItem),
|
|
4581
4589
|
value: "".concat(item.value),
|
|
4582
4590
|
required: requiredVal,
|
|
4583
4591
|
disabled: disabled || (typeof item.disabled !== 'undefined' ? item.disabled : null),
|
|
@@ -4609,14 +4617,14 @@ var Radio = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef)(funct
|
|
|
4609
4617
|
colSpan: 1,
|
|
4610
4618
|
className: "radio-group__wrapper ".concat(groupWrapperClassName || '', " ").concat(tableLayoutCellClassName || ''),
|
|
4611
4619
|
key: 'optgroup-' + index,
|
|
4612
|
-
"data-optiondata": JSON.stringify(
|
|
4620
|
+
"data-optiondata": JSON.stringify(_formatItem)
|
|
4613
4621
|
}, _groupEl());
|
|
4614
4622
|
} else {
|
|
4615
4623
|
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("td", {
|
|
4616
4624
|
colSpan: 1,
|
|
4617
4625
|
className: "".concat(inline ? "form-check form-check-inline" : "form-check", " ").concat(controlValue == item.value ? itemSelectedClassName || 'item-selected' : '', " ").concat(tableLayoutCellClassName || ''),
|
|
4618
4626
|
key: 'option-' + index,
|
|
4619
|
-
"data-optiondata": JSON.stringify(
|
|
4627
|
+
"data-optiondata": JSON.stringify(_formatItem)
|
|
4620
4628
|
}, _normalEl());
|
|
4621
4629
|
}
|
|
4622
4630
|
/* /TABLE LAYOUT */
|
|
@@ -4625,13 +4633,13 @@ var Radio = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef)(funct
|
|
|
4625
4633
|
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
|
|
4626
4634
|
className: "radio-group__wrapper ".concat(groupWrapperClassName || ''),
|
|
4627
4635
|
key: 'optgroup-' + index,
|
|
4628
|
-
"data-optiondata": JSON.stringify(
|
|
4636
|
+
"data-optiondata": JSON.stringify(_formatItem)
|
|
4629
4637
|
}, _groupEl());
|
|
4630
4638
|
} else {
|
|
4631
4639
|
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
|
|
4632
4640
|
className: "".concat(inline ? "form-check form-check-inline" : "form-check", " ").concat(controlValue == item.value ? itemSelectedClassName || 'item-selected' : ''),
|
|
4633
4641
|
key: 'option-' + index,
|
|
4634
|
-
"data-optiondata": JSON.stringify(
|
|
4642
|
+
"data-optiondata": JSON.stringify(_formatItem)
|
|
4635
4643
|
}, _normalEl());
|
|
4636
4644
|
}
|
|
4637
4645
|
}
|
package/RangeSlider/index.css
CHANGED
package/Select/index.css
CHANGED
|
@@ -14,6 +14,7 @@
|
|
|
14
14
|
--cus-sel-searchbtn-hover-fill: #333;
|
|
15
15
|
--cus-sel-removebtn-fill: #000;
|
|
16
16
|
--cus-sel-removebtn-hover-fill: #f00;
|
|
17
|
+
position: relative; /* Required */
|
|
17
18
|
/*------ Placeholder for input ------*/
|
|
18
19
|
/*------ Arrow ------*/
|
|
19
20
|
/*------ Clean ------*/
|
|
@@ -220,6 +221,10 @@
|
|
|
220
221
|
box-shadow: none;
|
|
221
222
|
}
|
|
222
223
|
.custom-select__wrapper .custom-select-multi__control-searchbtn {
|
|
224
|
+
position: absolute;
|
|
225
|
+
right: 0;
|
|
226
|
+
top: 50%;
|
|
227
|
+
transform: translateY(-50%);
|
|
223
228
|
z-index: 5;
|
|
224
229
|
pointer-events: auto;
|
|
225
230
|
}
|
package/Select/index.d.ts
CHANGED
|
@@ -39,6 +39,7 @@ declare type SelectProps = {
|
|
|
39
39
|
controlExClassName?: string;
|
|
40
40
|
exceededSidePosOffset?: number;
|
|
41
41
|
multiSelect?: MultiSelectConfig;
|
|
42
|
+
multiSelectEntireAreaTrigger?: boolean;
|
|
42
43
|
multiSelectSelectedItemOnlyStatus?: multiSelectSelectedItemOnlyStatusConfig;
|
|
43
44
|
renderSelectedValue?: (selectedData: MultiSelectControlValConfig, removeFunc: (e: React.MouseEvent) => void) => void;
|
|
44
45
|
cleanTrigger?: CleanTriggerConfig;
|