@geckoui/geckoui 2.0.1 → 2.0.3
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/dist/index.d.mts +2 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +3 -3
- package/dist/index.mjs +3 -3
- package/dist/styles.css +4 -9
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -3110,6 +3110,8 @@ interface BaseSelectProps extends PropsWithChildren, SelectButtonProps {
|
|
|
3110
3110
|
disabled?: boolean;
|
|
3111
3111
|
/**
|
|
3112
3112
|
* Whether to show the input for filtering the options
|
|
3113
|
+
* `true` or `"dropdown"`: a search box at the top of the menu
|
|
3114
|
+
* `"inline"`: typed straight into the button
|
|
3113
3115
|
* Default is false
|
|
3114
3116
|
* */
|
|
3115
3117
|
filterable?: boolean | "inline" | "dropdown";
|
package/dist/index.d.ts
CHANGED
|
@@ -3110,6 +3110,8 @@ interface BaseSelectProps extends PropsWithChildren, SelectButtonProps {
|
|
|
3110
3110
|
disabled?: boolean;
|
|
3111
3111
|
/**
|
|
3112
3112
|
* Whether to show the input for filtering the options
|
|
3113
|
+
* `true` or `"dropdown"`: a search box at the top of the menu
|
|
3114
|
+
* `"inline"`: typed straight into the button
|
|
3113
3115
|
* Default is false
|
|
3114
3116
|
* */
|
|
3115
3117
|
filterable?: boolean | "inline" | "dropdown";
|
package/dist/index.js
CHANGED
|
@@ -6635,7 +6635,7 @@ function SelectButton(_a) {
|
|
|
6635
6635
|
if (trigger) {
|
|
6636
6636
|
return trigger;
|
|
6637
6637
|
}
|
|
6638
|
-
const filterable = _filterable ===
|
|
6638
|
+
const filterable = _filterable === "inline";
|
|
6639
6639
|
return /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(
|
|
6640
6640
|
"div",
|
|
6641
6641
|
__spreadProps(__spreadValues(__spreadProps(__spreadValues({
|
|
@@ -6740,7 +6740,7 @@ function SelectButtonContent() {
|
|
|
6740
6740
|
closeMenu,
|
|
6741
6741
|
disabled
|
|
6742
6742
|
} = useSelect();
|
|
6743
|
-
const filterable = _filterable ===
|
|
6743
|
+
const filterable = _filterable === "inline";
|
|
6744
6744
|
const { preventDefault, attachPreventDefault } = usePreventDefault_default();
|
|
6745
6745
|
if (multiple && Array.isArray(value) && !!(value == null ? void 0 : value.length)) {
|
|
6746
6746
|
const selectedOptions = sortMultiSelectValue(value, options).map((o) => {
|
|
@@ -6919,7 +6919,7 @@ var SelectMenu = (_a) => {
|
|
|
6919
6919
|
if (!open || disabled) {
|
|
6920
6920
|
return null;
|
|
6921
6921
|
}
|
|
6922
|
-
const hasDropdownSearch = filterable === "dropdown";
|
|
6922
|
+
const hasDropdownSearch = filterable === true || filterable === "dropdown";
|
|
6923
6923
|
return /* @__PURE__ */ (0, import_jsx_runtime65.jsxs)(
|
|
6924
6924
|
"div",
|
|
6925
6925
|
__spreadProps(__spreadValues({
|
package/dist/index.mjs
CHANGED
|
@@ -6501,7 +6501,7 @@ function SelectButton(_a) {
|
|
|
6501
6501
|
if (trigger) {
|
|
6502
6502
|
return trigger;
|
|
6503
6503
|
}
|
|
6504
|
-
const filterable = _filterable ===
|
|
6504
|
+
const filterable = _filterable === "inline";
|
|
6505
6505
|
return /* @__PURE__ */ jsxs30(
|
|
6506
6506
|
"div",
|
|
6507
6507
|
__spreadProps(__spreadValues(__spreadProps(__spreadValues({
|
|
@@ -6606,7 +6606,7 @@ function SelectButtonContent() {
|
|
|
6606
6606
|
closeMenu,
|
|
6607
6607
|
disabled
|
|
6608
6608
|
} = useSelect();
|
|
6609
|
-
const filterable = _filterable ===
|
|
6609
|
+
const filterable = _filterable === "inline";
|
|
6610
6610
|
const { preventDefault, attachPreventDefault } = usePreventDefault_default();
|
|
6611
6611
|
if (multiple && Array.isArray(value) && !!(value == null ? void 0 : value.length)) {
|
|
6612
6612
|
const selectedOptions = sortMultiSelectValue(value, options).map((o) => {
|
|
@@ -6785,7 +6785,7 @@ var SelectMenu = (_a) => {
|
|
|
6785
6785
|
if (!open || disabled) {
|
|
6786
6786
|
return null;
|
|
6787
6787
|
}
|
|
6788
|
-
const hasDropdownSearch = filterable === "dropdown";
|
|
6788
|
+
const hasDropdownSearch = filterable === true || filterable === "dropdown";
|
|
6789
6789
|
return /* @__PURE__ */ jsxs31(
|
|
6790
6790
|
"div",
|
|
6791
6791
|
__spreadProps(__spreadValues({
|
package/dist/styles.css
CHANGED
|
@@ -1696,15 +1696,8 @@
|
|
|
1696
1696
|
transition-property: none;
|
|
1697
1697
|
transition-delay: 0ms;
|
|
1698
1698
|
}
|
|
1699
|
-
.GeckoUIDrawer__drawer[data-state=open]
|
|
1700
|
-
|
|
1701
|
-
--tw-translate-y: calc(var(--spacing, 0.25rem) * 0);
|
|
1702
|
-
translate: var(--tw-translate-x) var(--tw-translate-y);
|
|
1703
|
-
}
|
|
1704
|
-
.GeckoUIDrawer__drawer[data-state=open][data-placement=right],
|
|
1705
|
-
.GeckoUIDrawer__drawer[data-state=open][data-placement=left] {
|
|
1706
|
-
--tw-translate-x: calc(var(--spacing, 0.25rem) * 0);
|
|
1707
|
-
translate: var(--tw-translate-x) var(--tw-translate-y);
|
|
1699
|
+
.GeckoUIDrawer__drawer[data-state=open] {
|
|
1700
|
+
translate: none;
|
|
1708
1701
|
}
|
|
1709
1702
|
.GeckoUIDrawer__drawer[data-state=closed][data-placement=right] {
|
|
1710
1703
|
--tw-translate-x: 100%;
|
|
@@ -5399,7 +5392,9 @@
|
|
|
5399
5392
|
}
|
|
5400
5393
|
.GeckoUISelectButton__search__input[data-initial] {
|
|
5401
5394
|
position: absolute;
|
|
5395
|
+
right: calc(var(--spacing, 0.25rem) * 3);
|
|
5402
5396
|
left: calc(var(--spacing, 0.25rem) * 3);
|
|
5397
|
+
width: auto;
|
|
5403
5398
|
}
|
|
5404
5399
|
.GeckoUISelectButton__search__input[data-readonly] {
|
|
5405
5400
|
width: 0;
|