@nation-a/ui 0.10.4 → 0.10.6
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.cjs +26 -11
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +26 -11
- package/dist/index.js.map +1 -1
- package/dist/types/components/Button/index.d.ts +2 -2
- package/dist/types/components/IconButton/index.d.ts +2 -2
- package/dist/types/components/Input/Input.stories.d.ts +1 -0
- package/dist/types/components/Input/index.d.ts +5 -2
- package/dist/types/components/Input/input.recipe.d.ts +1 -1
- package/dist/types/components/Tag/index.d.ts +2 -2
- package/dist/types/components/TextArea/index.d.ts +2 -2
- package/package.json +3 -2
package/dist/index.cjs
CHANGED
|
@@ -5748,7 +5748,7 @@ const Button = ({ loading, disabled, loadingText, children, color, variant, size
|
|
|
5748
5748
|
}
|
|
5749
5749
|
);
|
|
5750
5750
|
};
|
|
5751
|
-
const index$
|
|
5751
|
+
const index$4 = React.memo(withPolymorphicComponent(Button));
|
|
5752
5752
|
const textRecipe = cva({
|
|
5753
5753
|
base: {
|
|
5754
5754
|
color: "currentcolor"
|
|
@@ -6190,7 +6190,7 @@ const IconButton = React.forwardRef(
|
|
|
6190
6190
|
}
|
|
6191
6191
|
);
|
|
6192
6192
|
IconButton.displayName = "IconButton";
|
|
6193
|
-
const index = withPolymorphicComponent(IconButton);
|
|
6193
|
+
const index$3 = React.memo(withPolymorphicComponent(IconButton));
|
|
6194
6194
|
var updateQueue = makeQueue();
|
|
6195
6195
|
var raf = (fn) => schedule(fn, updateQueue);
|
|
6196
6196
|
var writeQueue = makeQueue();
|
|
@@ -10093,9 +10093,10 @@ const Tag = React.forwardRef(({ imageSrc, text, onDeleteClick, ...rest }, ref) =
|
|
|
10093
10093
|
] });
|
|
10094
10094
|
});
|
|
10095
10095
|
Tag.displayName = "Tag";
|
|
10096
|
+
const index$2 = React.memo(Tag);
|
|
10096
10097
|
const inputRecipe = sva({
|
|
10097
10098
|
className: "input",
|
|
10098
|
-
slots: ["inputContainer", "requiredStar", "description", "label", "textLengthIndicator"],
|
|
10099
|
+
slots: ["inputContainer", "requiredStar", "description", "label", "textLengthIndicator", "adornment"],
|
|
10099
10100
|
base: {
|
|
10100
10101
|
inputContainer: {
|
|
10101
10102
|
display: "flex",
|
|
@@ -10147,6 +10148,11 @@ const inputRecipe = sva({
|
|
|
10147
10148
|
textStyle: "label.sm",
|
|
10148
10149
|
color: "content.neutral.subtlest",
|
|
10149
10150
|
_groupDisabled: { color: "content.neutral.disabled" }
|
|
10151
|
+
},
|
|
10152
|
+
adornment: {
|
|
10153
|
+
display: "flex",
|
|
10154
|
+
alignItems: "center",
|
|
10155
|
+
justifyContent: "center"
|
|
10150
10156
|
}
|
|
10151
10157
|
},
|
|
10152
10158
|
variants: {
|
|
@@ -10297,6 +10303,8 @@ const Input = React.forwardRef(
|
|
|
10297
10303
|
onChange,
|
|
10298
10304
|
className,
|
|
10299
10305
|
css: css2,
|
|
10306
|
+
startAdornment,
|
|
10307
|
+
endAdornment,
|
|
10300
10308
|
...rest
|
|
10301
10309
|
}, ref) => {
|
|
10302
10310
|
const recipe = inputRecipe({
|
|
@@ -10340,15 +10348,21 @@ const Input = React.forwardRef(
|
|
|
10340
10348
|
);
|
|
10341
10349
|
return /* @__PURE__ */ jsxRuntime.jsxs(VStack2, { gap: 1, className: "group", "data-disabled": disabled || void 0, css: { width: "100%" }, children: [
|
|
10342
10350
|
/* @__PURE__ */ jsxRuntime.jsx(Label, { visible: !!(label && labelPosition === "outside"), children: label }),
|
|
10343
|
-
|
|
10344
|
-
|
|
10345
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
10351
|
+
" ",
|
|
10352
|
+
/* @__PURE__ */ jsxRuntime.jsxs(HStack$1, { className: cx(recipe.inputContainer, className), onClick: handleContainerClick, css: css2, children: [
|
|
10353
|
+
/* @__PURE__ */ jsxRuntime.jsx(Box$1, { className: recipe.adornment, children: startAdornment }),
|
|
10354
|
+
/* @__PURE__ */ jsxRuntime.jsxs(Stack2, { gap: 1, children: [
|
|
10355
|
+
/* @__PURE__ */ jsxRuntime.jsx(Label, { visible: !!(label && labelPosition === "inside"), children: label }),
|
|
10356
|
+
/* @__PURE__ */ jsxRuntime.jsx(styled.input, { ref: inputRef, disabled, onChange: handleInputChange, ...rest })
|
|
10357
|
+
] }),
|
|
10358
|
+
/* @__PURE__ */ jsxRuntime.jsx(Box$1, { className: recipe.adornment, children: endAdornment })
|
|
10346
10359
|
] }),
|
|
10347
10360
|
description && /* @__PURE__ */ jsxRuntime.jsx(Description2, { children: description })
|
|
10348
10361
|
] });
|
|
10349
10362
|
}
|
|
10350
10363
|
);
|
|
10351
10364
|
Input.displayName = "Input";
|
|
10365
|
+
const index$1 = React.memo(Input);
|
|
10352
10366
|
const Textarea = React.forwardRef(
|
|
10353
10367
|
({
|
|
10354
10368
|
value,
|
|
@@ -10427,6 +10441,7 @@ const Textarea = React.forwardRef(
|
|
|
10427
10441
|
}
|
|
10428
10442
|
);
|
|
10429
10443
|
Textarea.displayName = "Textarea";
|
|
10444
|
+
const index = React.memo(Textarea);
|
|
10430
10445
|
function definePreset(preset2) {
|
|
10431
10446
|
return preset2;
|
|
10432
10447
|
}
|
|
@@ -10993,22 +11008,22 @@ const ToastProvider = ({ children }) => {
|
|
|
10993
11008
|
};
|
|
10994
11009
|
exports.BottomSheet = BottomSheet;
|
|
10995
11010
|
exports.Box = Box2;
|
|
10996
|
-
exports.Button = index$
|
|
11011
|
+
exports.Button = index$4;
|
|
10997
11012
|
exports.Center = Center2;
|
|
10998
11013
|
exports.Dialog = Dialog;
|
|
10999
11014
|
exports.Flex = Flex2;
|
|
11000
11015
|
exports.Grid = Grid2;
|
|
11001
11016
|
exports.GridItem = GridItem2;
|
|
11002
11017
|
exports.HStack = HStack2;
|
|
11003
|
-
exports.IconButton = index;
|
|
11004
|
-
exports.Input =
|
|
11018
|
+
exports.IconButton = index$3;
|
|
11019
|
+
exports.Input = index$1;
|
|
11005
11020
|
exports.Navigation = Navigation;
|
|
11006
11021
|
exports.Portal = Portal;
|
|
11007
11022
|
exports.Spinner = Spinner;
|
|
11008
11023
|
exports.Stack = Stack2;
|
|
11009
|
-
exports.Tag =
|
|
11024
|
+
exports.Tag = index$2;
|
|
11010
11025
|
exports.Text = Text;
|
|
11011
|
-
exports.TextArea =
|
|
11026
|
+
exports.TextArea = index;
|
|
11012
11027
|
exports.ToastProvider = ToastProvider;
|
|
11013
11028
|
exports.VStack = VStack2;
|
|
11014
11029
|
exports.preset = preset;
|