@oliasoft-open-source/react-ui-library 10.0.0-beta-19 → 10.0.0-beta-21
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/README.md +18 -19
- package/dist/global.css +1 -1
- package/dist/index.d.ts +1 -6
- package/dist/index.js +66 -71
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1400,7 +1400,6 @@ declare interface ISelectCell extends TCommonCell {
|
|
|
1400
1400
|
native?: boolean;
|
|
1401
1401
|
clearable?: boolean;
|
|
1402
1402
|
searchable?: boolean;
|
|
1403
|
-
deprecatedEventHandler?: boolean;
|
|
1404
1403
|
maxTooltipWidth?: TStringOrNumber;
|
|
1405
1404
|
autoLayerWidth?: boolean;
|
|
1406
1405
|
multi?: boolean;
|
|
@@ -1413,13 +1412,9 @@ export declare interface ISelectProps {
|
|
|
1413
1412
|
value?: any;
|
|
1414
1413
|
native?: boolean;
|
|
1415
1414
|
onChange?: TChangeEventHandler;
|
|
1416
|
-
/** @deprecated Use the standard onChange event shape instead. */
|
|
1417
|
-
deprecatedEventHandler?: boolean;
|
|
1418
1415
|
warning?: TStringOrNumber | ReactNode;
|
|
1419
1416
|
error?: TStringOrNumber | ReactNode;
|
|
1420
|
-
/** @deprecated Prefer leaving unset (defaults to true). */
|
|
1421
1417
|
checkNonExistentValues?: boolean;
|
|
1422
|
-
/** @deprecated Always closes on option action click. */
|
|
1423
1418
|
closeOnOptionActionClick?: boolean;
|
|
1424
1419
|
small?: boolean;
|
|
1425
1420
|
width?: TStringOrNumber | null;
|
|
@@ -1431,7 +1426,7 @@ export declare interface ISelectProps {
|
|
|
1431
1426
|
searchable?: boolean;
|
|
1432
1427
|
maxTooltipWidth?: TStringOrNumber;
|
|
1433
1428
|
autoLayerWidth?: boolean;
|
|
1434
|
-
|
|
1429
|
+
right?: boolean;
|
|
1435
1430
|
/* Excluded from this release type: groupOrder */
|
|
1436
1431
|
tabIndex?: number;
|
|
1437
1432
|
testId?: string;
|
package/dist/index.js
CHANGED
|
@@ -2972,37 +2972,37 @@ var Ro = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), zo =
|
|
|
2972
2972
|
})
|
|
2973
2973
|
});
|
|
2974
2974
|
}, Y = {
|
|
2975
|
-
inputInTable: "
|
|
2976
|
-
inputHover: "
|
|
2977
|
-
inputFocus: "
|
|
2978
|
-
controlFocusVisible: "
|
|
2979
|
-
inputError: "
|
|
2980
|
-
inputWarning: "
|
|
2981
|
-
inputDisabled: "
|
|
2982
|
-
hideScrollbars: "
|
|
2983
|
-
trigger: "
|
|
2984
|
-
input: "
|
|
2985
|
-
isInTable: "
|
|
2986
|
-
isOpen: "
|
|
2987
|
-
disabled: "
|
|
2988
|
-
toggle: "
|
|
2989
|
-
icons: "
|
|
2990
|
-
clearAll: "
|
|
2991
|
-
iconOpen: "
|
|
2992
|
-
small: "
|
|
2993
|
-
triggerInputContainer: "
|
|
2994
|
-
right: "
|
|
2995
|
-
multiOptions: "
|
|
2996
|
-
multiOption: "
|
|
2997
|
-
label: "
|
|
2998
|
-
closeMultiOption: "
|
|
2999
|
-
focus: "
|
|
3000
|
-
selectedSingleValue: "
|
|
3001
|
-
placeHolder: "
|
|
3002
|
-
groupOrderFirst: "
|
|
3003
|
-
groupOrderMiddle: "
|
|
3004
|
-
groupOrderLast: "
|
|
3005
|
-
detailedLabel: "
|
|
2975
|
+
inputInTable: "_inputInTable_13wru_1",
|
|
2976
|
+
inputHover: "_inputHover_13wru_13",
|
|
2977
|
+
inputFocus: "_inputFocus_13wru_18",
|
|
2978
|
+
controlFocusVisible: "_controlFocusVisible_13wru_25",
|
|
2979
|
+
inputError: "_inputError_13wru_29",
|
|
2980
|
+
inputWarning: "_inputWarning_13wru_30",
|
|
2981
|
+
inputDisabled: "_inputDisabled_13wru_65",
|
|
2982
|
+
hideScrollbars: "_hideScrollbars_13wru_71",
|
|
2983
|
+
trigger: "_trigger_13wru_81",
|
|
2984
|
+
input: "_input_13wru_1",
|
|
2985
|
+
isInTable: "_isInTable_13wru_97",
|
|
2986
|
+
isOpen: "_isOpen_13wru_118",
|
|
2987
|
+
disabled: "_disabled_13wru_161",
|
|
2988
|
+
toggle: "_toggle_13wru_167",
|
|
2989
|
+
icons: "_icons_13wru_176",
|
|
2990
|
+
clearAll: "_clearAll_13wru_184",
|
|
2991
|
+
iconOpen: "_iconOpen_13wru_185",
|
|
2992
|
+
small: "_small_13wru_196",
|
|
2993
|
+
triggerInputContainer: "_triggerInputContainer_13wru_208",
|
|
2994
|
+
right: "_right_13wru_217",
|
|
2995
|
+
multiOptions: "_multiOptions_13wru_233",
|
|
2996
|
+
multiOption: "_multiOption_13wru_233",
|
|
2997
|
+
label: "_label_13wru_261",
|
|
2998
|
+
closeMultiOption: "_closeMultiOption_13wru_264",
|
|
2999
|
+
focus: "_focus_13wru_275",
|
|
3000
|
+
selectedSingleValue: "_selectedSingleValue_13wru_279",
|
|
3001
|
+
placeHolder: "_placeHolder_13wru_280",
|
|
3002
|
+
groupOrderFirst: "_groupOrderFirst_13wru_319",
|
|
3003
|
+
groupOrderMiddle: "_groupOrderMiddle_13wru_320",
|
|
3004
|
+
groupOrderLast: "_groupOrderLast_13wru_324",
|
|
3005
|
+
detailedLabel: "_detailedLabel_13wru_329"
|
|
3006
3006
|
}, Rc = (e, t, n, r) => {
|
|
3007
3007
|
let i = [], a = [], o = 0;
|
|
3008
3008
|
return e.forEach((s, c) => {
|
|
@@ -3105,7 +3105,6 @@ var Ro = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), zo =
|
|
|
3105
3105
|
className: b(Y.trigger, f ? Y.isOpen : "", l ? Y.disabled : "", s ? Y.small : "", c ? Y.isInTable : "", y ? Y.right : "", O),
|
|
3106
3106
|
"data-error": i || null,
|
|
3107
3107
|
"data-warning": a || null,
|
|
3108
|
-
"data-testid": w,
|
|
3109
3108
|
children: [
|
|
3110
3109
|
/* @__PURE__ */ S(Bc, {
|
|
3111
3110
|
selectedOptions: k,
|
|
@@ -3122,7 +3121,9 @@ var Ro = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), zo =
|
|
|
3122
3121
|
/* @__PURE__ */ S(Vr, {
|
|
3123
3122
|
className: Y.toggle,
|
|
3124
3123
|
"aria-label": v || "Select",
|
|
3125
|
-
"data-testid": w
|
|
3124
|
+
"data-testid": w,
|
|
3125
|
+
"data-error": i || null,
|
|
3126
|
+
"data-warning": a || null
|
|
3126
3127
|
}),
|
|
3127
3128
|
/* @__PURE__ */ S("span", {
|
|
3128
3129
|
className: Y.icons,
|
|
@@ -3250,45 +3251,40 @@ var Ro = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), zo =
|
|
|
3250
3251
|
hasNonExistentValue: n && s !== void 0 ? Xc(o, s) : !1
|
|
3251
3252
|
};
|
|
3252
3253
|
}, Qc = (e) => {
|
|
3253
|
-
let { name: t = "", options: n = [], value: r, native: i = !1, onChange: a = yn,
|
|
3254
|
-
i && !
|
|
3255
|
-
let
|
|
3256
|
-
|
|
3257
|
-
|
|
3258
|
-
e
|
|
3259
|
-
|
|
3260
|
-
|
|
3261
|
-
|
|
3262
|
-
|
|
3263
|
-
|
|
3264
|
-
|
|
3265
|
-
value: r,
|
|
3266
|
-
label: h ? void 0 : n.label
|
|
3267
|
-
}
|
|
3268
|
-
});
|
|
3269
|
-
}
|
|
3254
|
+
let { name: t = "", options: n = [], value: r, native: i = !1, onChange: a = yn, warning: o, error: s, checkNonExistentValues: c = !0, closeOnOptionActionClick: l = !0, testId: u, disabled: d, multi: f, ...p } = e, { multi: m, options: h, selectedOptions: g, hasNonExistentValue: _ } = Zc(n, r, c), v = !m, y = i && v;
|
|
3255
|
+
i && !v && console.warn("Native select does not support provided props (see stories)");
|
|
3256
|
+
let b = "Value no longer available for re-selection", x = _ && !d ? o ? /* @__PURE__ */ C("div", { children: [/* @__PURE__ */ S("div", { children: b }), /* @__PURE__ */ S("div", { children: o })] }) : b : o, w = _ && s && !d ? /* @__PURE__ */ C("div", { children: [/* @__PURE__ */ S("div", { children: b }), /* @__PURE__ */ S("div", { children: s })] }) : s, T = (e, n) => {
|
|
3257
|
+
let r = m ? n : n.value;
|
|
3258
|
+
a({
|
|
3259
|
+
...e,
|
|
3260
|
+
target: {
|
|
3261
|
+
name: t,
|
|
3262
|
+
value: r,
|
|
3263
|
+
label: m ? void 0 : n.label
|
|
3264
|
+
}
|
|
3265
|
+
});
|
|
3270
3266
|
};
|
|
3271
|
-
return
|
|
3272
|
-
...
|
|
3273
|
-
options:
|
|
3274
|
-
selectedOption:
|
|
3275
|
-
onChange:
|
|
3276
|
-
hasNonExistentValue:
|
|
3277
|
-
warning:
|
|
3278
|
-
error:
|
|
3279
|
-
testId:
|
|
3280
|
-
disabled:
|
|
3267
|
+
return y ? /* @__PURE__ */ S(oc, {
|
|
3268
|
+
...p,
|
|
3269
|
+
options: h,
|
|
3270
|
+
selectedOption: g,
|
|
3271
|
+
onChange: T,
|
|
3272
|
+
hasNonExistentValue: _,
|
|
3273
|
+
warning: x,
|
|
3274
|
+
error: w,
|
|
3275
|
+
testId: u,
|
|
3276
|
+
disabled: d
|
|
3281
3277
|
}) : /* @__PURE__ */ S(Hc, {
|
|
3282
|
-
...
|
|
3283
|
-
options:
|
|
3284
|
-
selectedOptions:
|
|
3285
|
-
onChange:
|
|
3286
|
-
multi:
|
|
3287
|
-
warning:
|
|
3288
|
-
error:
|
|
3289
|
-
testId:
|
|
3290
|
-
disabled:
|
|
3291
|
-
closeOnOptionActionClick:
|
|
3278
|
+
...p,
|
|
3279
|
+
options: h,
|
|
3280
|
+
selectedOptions: g,
|
|
3281
|
+
onChange: T,
|
|
3282
|
+
multi: m,
|
|
3283
|
+
warning: x,
|
|
3284
|
+
error: w,
|
|
3285
|
+
testId: u,
|
|
3286
|
+
disabled: d,
|
|
3287
|
+
closeOnOptionActionClick: l
|
|
3292
3288
|
});
|
|
3293
3289
|
}, $c = (e, t) => t || e && e.reduce((e, t) => t != null && t.selected ? Number(t == null ? void 0 : t.value) : e, 10) || 10, el = (e, t) => {
|
|
3294
3290
|
if (!t || !e) return 10;
|
|
@@ -3636,7 +3632,6 @@ var Ro = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), zo =
|
|
|
3636
3632
|
native: e.native,
|
|
3637
3633
|
clearable: e.clearable,
|
|
3638
3634
|
searchable: e.searchable,
|
|
3639
|
-
deprecatedEventHandler: e.deprecatedEventHandler,
|
|
3640
3635
|
maxTooltipWidth: e.maxTooltipWidth,
|
|
3641
3636
|
width: "100%",
|
|
3642
3637
|
autoLayerWidth: e.autoLayerWidth,
|
package/package.json
CHANGED