@uniformdev/design-system 20.74.6-alpha.2 → 20.74.7-alpha.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/esm/index.js +42 -19
- package/dist/index.d.mts +10 -0
- package/dist/index.d.ts +10 -0
- package/dist/index.js +42 -19
- package/package.json +4 -4
package/dist/esm/index.js
CHANGED
|
@@ -5730,11 +5730,6 @@ function fieldsetContainer(invert) {
|
|
|
5730
5730
|
border: 1px solid var(--gray-300);
|
|
5731
5731
|
|
|
5732
5732
|
padding: var(--spacing-base);
|
|
5733
|
-
|
|
5734
|
-
// auto apply margins to child elements
|
|
5735
|
-
> *:not(legend) {
|
|
5736
|
-
margin-top: var(--spacing-base);
|
|
5737
|
-
}
|
|
5738
5733
|
`;
|
|
5739
5734
|
return invert ? [
|
|
5740
5735
|
css33`
|
|
@@ -5758,16 +5753,24 @@ var fieldsetLegend = css33`
|
|
|
5758
5753
|
margin-bottom: var(--spacing-base);
|
|
5759
5754
|
float: left; // allows the legend to be inside the fieldset and not sat on the border line
|
|
5760
5755
|
`;
|
|
5756
|
+
var fieldsetAction = css33`
|
|
5757
|
+
float: right;
|
|
5758
|
+
margin-bottom: var(--spacing-base);
|
|
5759
|
+
margin-left: var(--spacing-sm);
|
|
5760
|
+
`;
|
|
5761
5761
|
var fieldsetBody = css33`
|
|
5762
|
-
|
|
5762
|
+
// Clears both so an actionButton floated right cannot spill into the fields.
|
|
5763
|
+
clear: both;
|
|
5764
|
+
margin-top: var(--spacing-base);
|
|
5763
5765
|
`;
|
|
5764
5766
|
|
|
5765
5767
|
// src/components/Input/Fieldset.tsx
|
|
5766
5768
|
import { jsx as jsx37, jsxs as jsxs24 } from "@emotion/react/jsx-runtime";
|
|
5767
5769
|
var Fieldset = React10.forwardRef(
|
|
5768
|
-
({ legend, disabled: disabled2, children, invert, ...props }, ref) => {
|
|
5770
|
+
({ legend, disabled: disabled2, children, invert, actionButton, ...props }, ref) => {
|
|
5769
5771
|
return /* @__PURE__ */ jsxs24("fieldset", { css: fieldsetContainer(Boolean(invert)), ref, disabled: disabled2, ...props, children: [
|
|
5770
5772
|
legend,
|
|
5773
|
+
actionButton ? /* @__PURE__ */ jsx37("div", { css: fieldsetAction, children: actionButton }) : null,
|
|
5771
5774
|
/* @__PURE__ */ jsx37("div", { css: fieldsetBody, children })
|
|
5772
5775
|
] });
|
|
5773
5776
|
}
|
|
@@ -7702,18 +7705,38 @@ var Link = React13.forwardRef(
|
|
|
7702
7705
|
);
|
|
7703
7706
|
Link.displayName = "Link";
|
|
7704
7707
|
var LinkWithRef = React13.forwardRef(
|
|
7705
|
-
({
|
|
7706
|
-
LinkManager,
|
|
7707
|
-
|
|
7708
|
-
|
|
7709
|
-
|
|
7710
|
-
|
|
7711
|
-
|
|
7712
|
-
|
|
7713
|
-
|
|
7714
|
-
|
|
7715
|
-
|
|
7716
|
-
|
|
7708
|
+
({
|
|
7709
|
+
linkManagerComponent: LinkManager,
|
|
7710
|
+
href,
|
|
7711
|
+
as,
|
|
7712
|
+
onClick,
|
|
7713
|
+
external,
|
|
7714
|
+
linkColor = "default",
|
|
7715
|
+
children,
|
|
7716
|
+
text,
|
|
7717
|
+
...props
|
|
7718
|
+
}, ref) => {
|
|
7719
|
+
const externalAttrs = external ? {
|
|
7720
|
+
target: "_blank",
|
|
7721
|
+
rel: "noreferrer noopener"
|
|
7722
|
+
} : {};
|
|
7723
|
+
return /* @__PURE__ */ jsxs37(
|
|
7724
|
+
LinkManager,
|
|
7725
|
+
{
|
|
7726
|
+
...props,
|
|
7727
|
+
...externalAttrs,
|
|
7728
|
+
as,
|
|
7729
|
+
href,
|
|
7730
|
+
ref,
|
|
7731
|
+
css: [link, textColor[linkColor]],
|
|
7732
|
+
onClick,
|
|
7733
|
+
children: [
|
|
7734
|
+
text != null ? text : children,
|
|
7735
|
+
external ? /* @__PURE__ */ jsx55(Icon, { icon: CgExternal, iconColor: "currentColor", size: 20 }) : null
|
|
7736
|
+
]
|
|
7737
|
+
}
|
|
7738
|
+
);
|
|
7739
|
+
}
|
|
7717
7740
|
);
|
|
7718
7741
|
LinkWithRef.displayName = "LinkWithRef";
|
|
7719
7742
|
|
package/dist/index.d.mts
CHANGED
|
@@ -2252,6 +2252,11 @@ type FieldsetProps = React$1.HTMLAttributes<HTMLFieldSetElement> & {
|
|
|
2252
2252
|
legend: React$1.ReactElement;
|
|
2253
2253
|
/** sets the disabled value and sets child inputs disabled */
|
|
2254
2254
|
disabled?: boolean;
|
|
2255
|
+
/**
|
|
2256
|
+
* Optional control rendered on the legend's row, aligned to the right edge. Use it for an action that
|
|
2257
|
+
* applies to the group as a whole (remove, reset). Give it an accessible name: it sits inside the
|
|
2258
|
+
* fieldset, so it is also disabled along with the fields when `disabled` is set.
|
|
2259
|
+
*/
|
|
2255
2260
|
actionButton?: React$1.ReactElement;
|
|
2256
2261
|
children: React$1.ReactNode;
|
|
2257
2262
|
/** Inverts the background to white for use on forms that already have a gray background */
|
|
@@ -2263,6 +2268,11 @@ declare const Fieldset: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes
|
|
|
2263
2268
|
legend: React$1.ReactElement;
|
|
2264
2269
|
/** sets the disabled value and sets child inputs disabled */
|
|
2265
2270
|
disabled?: boolean;
|
|
2271
|
+
/**
|
|
2272
|
+
* Optional control rendered on the legend's row, aligned to the right edge. Use it for an action that
|
|
2273
|
+
* applies to the group as a whole (remove, reset). Give it an accessible name: it sits inside the
|
|
2274
|
+
* fieldset, so it is also disabled along with the fields when `disabled` is set.
|
|
2275
|
+
*/
|
|
2266
2276
|
actionButton?: React$1.ReactElement;
|
|
2267
2277
|
children: React$1.ReactNode;
|
|
2268
2278
|
/** Inverts the background to white for use on forms that already have a gray background */
|
package/dist/index.d.ts
CHANGED
|
@@ -2252,6 +2252,11 @@ type FieldsetProps = React$1.HTMLAttributes<HTMLFieldSetElement> & {
|
|
|
2252
2252
|
legend: React$1.ReactElement;
|
|
2253
2253
|
/** sets the disabled value and sets child inputs disabled */
|
|
2254
2254
|
disabled?: boolean;
|
|
2255
|
+
/**
|
|
2256
|
+
* Optional control rendered on the legend's row, aligned to the right edge. Use it for an action that
|
|
2257
|
+
* applies to the group as a whole (remove, reset). Give it an accessible name: it sits inside the
|
|
2258
|
+
* fieldset, so it is also disabled along with the fields when `disabled` is set.
|
|
2259
|
+
*/
|
|
2255
2260
|
actionButton?: React$1.ReactElement;
|
|
2256
2261
|
children: React$1.ReactNode;
|
|
2257
2262
|
/** Inverts the background to white for use on forms that already have a gray background */
|
|
@@ -2263,6 +2268,11 @@ declare const Fieldset: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes
|
|
|
2263
2268
|
legend: React$1.ReactElement;
|
|
2264
2269
|
/** sets the disabled value and sets child inputs disabled */
|
|
2265
2270
|
disabled?: boolean;
|
|
2271
|
+
/**
|
|
2272
|
+
* Optional control rendered on the legend's row, aligned to the right edge. Use it for an action that
|
|
2273
|
+
* applies to the group as a whole (remove, reset). Give it an accessible name: it sits inside the
|
|
2274
|
+
* fieldset, so it is also disabled along with the fields when `disabled` is set.
|
|
2275
|
+
*/
|
|
2266
2276
|
actionButton?: React$1.ReactElement;
|
|
2267
2277
|
children: React$1.ReactNode;
|
|
2268
2278
|
/** Inverts the background to white for use on forms that already have a gray background */
|
package/dist/index.js
CHANGED
|
@@ -7559,11 +7559,6 @@ function fieldsetContainer(invert) {
|
|
|
7559
7559
|
border: 1px solid var(--gray-300);
|
|
7560
7560
|
|
|
7561
7561
|
padding: var(--spacing-base);
|
|
7562
|
-
|
|
7563
|
-
// auto apply margins to child elements
|
|
7564
|
-
> *:not(legend) {
|
|
7565
|
-
margin-top: var(--spacing-base);
|
|
7566
|
-
}
|
|
7567
7562
|
`;
|
|
7568
7563
|
return invert ? [
|
|
7569
7564
|
import_react48.css`
|
|
@@ -7587,16 +7582,24 @@ var fieldsetLegend = import_react48.css`
|
|
|
7587
7582
|
margin-bottom: var(--spacing-base);
|
|
7588
7583
|
float: left; // allows the legend to be inside the fieldset and not sat on the border line
|
|
7589
7584
|
`;
|
|
7585
|
+
var fieldsetAction = import_react48.css`
|
|
7586
|
+
float: right;
|
|
7587
|
+
margin-bottom: var(--spacing-base);
|
|
7588
|
+
margin-left: var(--spacing-sm);
|
|
7589
|
+
`;
|
|
7590
7590
|
var fieldsetBody = import_react48.css`
|
|
7591
|
-
|
|
7591
|
+
// Clears both so an actionButton floated right cannot spill into the fields.
|
|
7592
|
+
clear: both;
|
|
7593
|
+
margin-top: var(--spacing-base);
|
|
7592
7594
|
`;
|
|
7593
7595
|
|
|
7594
7596
|
// src/components/Input/Fieldset.tsx
|
|
7595
7597
|
var import_jsx_runtime37 = require("@emotion/react/jsx-runtime");
|
|
7596
7598
|
var Fieldset = React10.forwardRef(
|
|
7597
|
-
({ legend, disabled: disabled2, children, invert, ...props }, ref) => {
|
|
7599
|
+
({ legend, disabled: disabled2, children, invert, actionButton, ...props }, ref) => {
|
|
7598
7600
|
return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("fieldset", { css: fieldsetContainer(Boolean(invert)), ref, disabled: disabled2, ...props, children: [
|
|
7599
7601
|
legend,
|
|
7602
|
+
actionButton ? /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("div", { css: fieldsetAction, children: actionButton }) : null,
|
|
7600
7603
|
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)("div", { css: fieldsetBody, children })
|
|
7601
7604
|
] });
|
|
7602
7605
|
}
|
|
@@ -9547,18 +9550,38 @@ var Link = React13.forwardRef(
|
|
|
9547
9550
|
);
|
|
9548
9551
|
Link.displayName = "Link";
|
|
9549
9552
|
var LinkWithRef = React13.forwardRef(
|
|
9550
|
-
({
|
|
9551
|
-
LinkManager,
|
|
9552
|
-
|
|
9553
|
-
|
|
9554
|
-
|
|
9555
|
-
|
|
9556
|
-
|
|
9557
|
-
|
|
9558
|
-
|
|
9559
|
-
|
|
9560
|
-
|
|
9561
|
-
|
|
9553
|
+
({
|
|
9554
|
+
linkManagerComponent: LinkManager,
|
|
9555
|
+
href,
|
|
9556
|
+
as,
|
|
9557
|
+
onClick,
|
|
9558
|
+
external,
|
|
9559
|
+
linkColor = "default",
|
|
9560
|
+
children,
|
|
9561
|
+
text,
|
|
9562
|
+
...props
|
|
9563
|
+
}, ref) => {
|
|
9564
|
+
const externalAttrs = external ? {
|
|
9565
|
+
target: "_blank",
|
|
9566
|
+
rel: "noreferrer noopener"
|
|
9567
|
+
} : {};
|
|
9568
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(
|
|
9569
|
+
LinkManager,
|
|
9570
|
+
{
|
|
9571
|
+
...props,
|
|
9572
|
+
...externalAttrs,
|
|
9573
|
+
as,
|
|
9574
|
+
href,
|
|
9575
|
+
ref,
|
|
9576
|
+
css: [link, textColor[linkColor]],
|
|
9577
|
+
onClick,
|
|
9578
|
+
children: [
|
|
9579
|
+
text != null ? text : children,
|
|
9580
|
+
external ? /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(Icon, { icon: import_CgExternal2.CgExternal, iconColor: "currentColor", size: 20 }) : null
|
|
9581
|
+
]
|
|
9582
|
+
}
|
|
9583
|
+
);
|
|
9584
|
+
}
|
|
9562
9585
|
);
|
|
9563
9586
|
LinkWithRef.displayName = "LinkWithRef";
|
|
9564
9587
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uniformdev/design-system",
|
|
3
|
-
"version": "20.74.
|
|
3
|
+
"version": "20.74.7-alpha.3+f1d91835fc",
|
|
4
4
|
"description": "Uniform design system components",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
6
6
|
"exports": {
|
|
@@ -34,8 +34,8 @@
|
|
|
34
34
|
"@storybook/react-vite": "10.4.6",
|
|
35
35
|
"@types/react": "19.2.17",
|
|
36
36
|
"@types/react-dom": "19.2.3",
|
|
37
|
-
"@uniformdev/canvas": "^20.74.
|
|
38
|
-
"@uniformdev/richtext": "^20.74.
|
|
37
|
+
"@uniformdev/canvas": "^20.74.7-alpha.3+f1d91835fc",
|
|
38
|
+
"@uniformdev/richtext": "^20.74.7-alpha.3+f1d91835fc",
|
|
39
39
|
"autoprefixer": "10.5.0",
|
|
40
40
|
"hygen": "6.2.11",
|
|
41
41
|
"jsdom": "29.1.1",
|
|
@@ -82,5 +82,5 @@
|
|
|
82
82
|
"publishConfig": {
|
|
83
83
|
"access": "public"
|
|
84
84
|
},
|
|
85
|
-
"gitHead": "
|
|
85
|
+
"gitHead": "f1d91835fca9645311dde0f546008b1bfc98fbdf"
|
|
86
86
|
}
|