@mijn-ui/react-select 0.4.1 → 0.4.2
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.js +21 -5
- package/dist/metafile-esm.json +1 -1
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -77,7 +77,7 @@ var SelectGroup = SelectPrimitive.Group;
|
|
|
77
77
|
var SelectValue = SelectPrimitive.Value;
|
|
78
78
|
var Select = ({ classNames, unstyled = false, ...props }) => {
|
|
79
79
|
const styles = selectStyles();
|
|
80
|
-
return /* @__PURE__ */ jsx(SelectProvider, { value: { unstyled, styles, classNames }, children: /* @__PURE__ */ jsx(SelectPrimitive.Root, { ...props }) });
|
|
80
|
+
return /* @__PURE__ */ jsx(SelectProvider, { value: { unstyled, styles, classNames }, children: /* @__PURE__ */ jsx(SelectPrimitive.Root, { "data-slot": "select", ...props }) });
|
|
81
81
|
};
|
|
82
82
|
var SelectTrigger = ({
|
|
83
83
|
hideIcon,
|
|
@@ -91,6 +91,7 @@ var SelectTrigger = ({
|
|
|
91
91
|
return /* @__PURE__ */ jsxs(
|
|
92
92
|
SelectPrimitive.Trigger,
|
|
93
93
|
{
|
|
94
|
+
"data-slot": "select-trigger",
|
|
94
95
|
className: trigger({
|
|
95
96
|
className: cn(classNames?.trigger, className)
|
|
96
97
|
}),
|
|
@@ -107,7 +108,15 @@ var SelectTriggerIcon = ({
|
|
|
107
108
|
asChild = true,
|
|
108
109
|
...props
|
|
109
110
|
}) => {
|
|
110
|
-
return /* @__PURE__ */ jsx(
|
|
111
|
+
return /* @__PURE__ */ jsx(
|
|
112
|
+
SelectPrimitive.Icon,
|
|
113
|
+
{
|
|
114
|
+
"data-slot": "select-trigger-icon",
|
|
115
|
+
asChild,
|
|
116
|
+
...props,
|
|
117
|
+
children: children ? children : /* @__PURE__ */ jsx(ChevronDownIcon, {})
|
|
118
|
+
}
|
|
119
|
+
);
|
|
111
120
|
};
|
|
112
121
|
var SelectScrollUpButton = ({
|
|
113
122
|
unstyled,
|
|
@@ -118,6 +127,7 @@ var SelectScrollUpButton = ({
|
|
|
118
127
|
return /* @__PURE__ */ jsx(
|
|
119
128
|
SelectPrimitive.ScrollUpButton,
|
|
120
129
|
{
|
|
130
|
+
"data-slot": "select-scroll-up-button",
|
|
121
131
|
className: scrollUpBtn({
|
|
122
132
|
className: cn(classNames?.scrollUpBtn, className)
|
|
123
133
|
}),
|
|
@@ -135,6 +145,7 @@ var SelectScrollDownButton = ({
|
|
|
135
145
|
return /* @__PURE__ */ jsx(
|
|
136
146
|
SelectPrimitive.ScrollDownButton,
|
|
137
147
|
{
|
|
148
|
+
"data-slot": "select-scroll-down-button",
|
|
138
149
|
className: scrollDownBtn({
|
|
139
150
|
className: cn(classNames?.scrollDownBtn, className)
|
|
140
151
|
}),
|
|
@@ -151,9 +162,10 @@ var SelectContent = ({
|
|
|
151
162
|
...props
|
|
152
163
|
}) => {
|
|
153
164
|
const { content, viewport, classNames } = useSelectStyles(unstyled);
|
|
154
|
-
return /* @__PURE__ */ jsx(SelectPrimitive.Portal, { children: /* @__PURE__ */ jsxs(
|
|
165
|
+
return /* @__PURE__ */ jsx(SelectPrimitive.Portal, { "data-slot": "select-portal", children: /* @__PURE__ */ jsxs(
|
|
155
166
|
SelectPrimitive.Content,
|
|
156
167
|
{
|
|
168
|
+
"data-slot": "select-content",
|
|
157
169
|
className: content({
|
|
158
170
|
className: cn(classNames?.content, className),
|
|
159
171
|
position
|
|
@@ -165,6 +177,7 @@ var SelectContent = ({
|
|
|
165
177
|
/* @__PURE__ */ jsx(
|
|
166
178
|
SelectPrimitive.Viewport,
|
|
167
179
|
{
|
|
180
|
+
"data-slot": "select-viewport",
|
|
168
181
|
className: viewport({
|
|
169
182
|
className: classNames?.viewport,
|
|
170
183
|
position
|
|
@@ -182,6 +195,7 @@ var SelectLabel = ({ unstyled, className, ...props }) => {
|
|
|
182
195
|
return /* @__PURE__ */ jsx(
|
|
183
196
|
SelectPrimitive.Label,
|
|
184
197
|
{
|
|
198
|
+
"data-slot": "select-label",
|
|
185
199
|
className: label({
|
|
186
200
|
className: cn(classNames?.label, className)
|
|
187
201
|
}),
|
|
@@ -199,19 +213,20 @@ var SelectItem = ({
|
|
|
199
213
|
return /* @__PURE__ */ jsxs(
|
|
200
214
|
SelectPrimitive.Item,
|
|
201
215
|
{
|
|
216
|
+
"data-slot": "select-item",
|
|
202
217
|
className: item({
|
|
203
218
|
className: cn(classNames?.item, className)
|
|
204
219
|
}),
|
|
205
220
|
...props,
|
|
206
221
|
children: [
|
|
207
|
-
/* @__PURE__ */ jsx(SelectPrimitive.ItemText, { children }),
|
|
222
|
+
/* @__PURE__ */ jsx(SelectPrimitive.ItemText, { "data-slot": "select-item-text", children }),
|
|
208
223
|
/* @__PURE__ */ jsx(
|
|
209
224
|
"span",
|
|
210
225
|
{
|
|
211
226
|
className: itemIndicator({
|
|
212
227
|
className: classNames?.itemIndicator
|
|
213
228
|
}),
|
|
214
|
-
children: /* @__PURE__ */ jsx(SelectPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(CheckIcon, {}) })
|
|
229
|
+
children: /* @__PURE__ */ jsx(SelectPrimitive.ItemIndicator, { "data-slot": "select-item-indicator", children: /* @__PURE__ */ jsx(CheckIcon, {}) })
|
|
215
230
|
}
|
|
216
231
|
)
|
|
217
232
|
]
|
|
@@ -227,6 +242,7 @@ var SelectSeparator = ({
|
|
|
227
242
|
return /* @__PURE__ */ jsx(
|
|
228
243
|
SelectPrimitive.Separator,
|
|
229
244
|
{
|
|
245
|
+
"data-slot": "select-separator",
|
|
230
246
|
className: separator({
|
|
231
247
|
className: cn(classNames?.separator, className)
|
|
232
248
|
}),
|
package/dist/metafile-esm.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"inputs":{"src/select.tsx":{"bytes":
|
|
1
|
+
{"inputs":{"src/select.tsx":{"bytes":11840,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@mijn-ui/react-core","kind":"import-statement","external":true},{"path":"@mijn-ui/shared-icons","kind":"import-statement","external":true},{"path":"@radix-ui/react-select","kind":"import-statement","external":true},{"path":"tailwind-variants","kind":"import-statement","external":true},{"path":"react/jsx-runtime","kind":"import-statement","external":true}],"format":"esm"},"src/index.ts":{"bytes":25,"imports":[{"path":"src/select.tsx","kind":"import-statement","original":"./select"}],"format":"esm"}},"outputs":{"dist/index.js":{"imports":[{"path":"@mijn-ui/react-core","kind":"import-statement","external":true},{"path":"@mijn-ui/shared-icons","kind":"import-statement","external":true},{"path":"@radix-ui/react-select","kind":"import-statement","external":true},{"path":"tailwind-variants","kind":"import-statement","external":true},{"path":"react/jsx-runtime","kind":"import-statement","external":true}],"exports":["Select","SelectContent","SelectGroup","SelectItem","SelectLabel","SelectScrollDownButton","SelectScrollUpButton","SelectSeparator","SelectTrigger","SelectTriggerIcon","SelectValue","selectStyles","useSelectStyles"],"entryPoint":"src/index.ts","inputs":{"src/select.tsx":{"bytesInOutput":7539},"src/index.ts":{"bytesInOutput":0}},"bytes":7811}}}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mijn-ui/react-select",
|
|
3
3
|
"author": "Htet Aung Lin<htetaunglin.coder@gmail.com>",
|
|
4
|
-
"version": "0.4.
|
|
4
|
+
"version": "0.4.2",
|
|
5
5
|
"homepage": "https://mijn-ui.vercel.app",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"type": "module",
|
|
@@ -20,8 +20,8 @@
|
|
|
20
20
|
"exports": "./dist/index.js",
|
|
21
21
|
"types": "./dist/index.d.ts",
|
|
22
22
|
"devDependencies": {
|
|
23
|
-
"react": "19.0.
|
|
24
|
-
"react-dom": "19.0.
|
|
23
|
+
"react": "19.0.1",
|
|
24
|
+
"react-dom": "19.0.1",
|
|
25
25
|
"@next/eslint-plugin-next": "^15.0.3",
|
|
26
26
|
"@types/react": "^19.0.0",
|
|
27
27
|
"@types/react-dom": "^19.0.0",
|