@webority/ui-react 0.17.0 → 0.17.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.
|
@@ -12,9 +12,9 @@
|
|
|
12
12
|
* @param {string} [props.name]
|
|
13
13
|
* @param {string} [props.error] Error message, rendered below the control. Replaces the hint.
|
|
14
14
|
* @param {string} [props.hint] Helper text below the control. Hidden while an error is shown.
|
|
15
|
-
* @param {'
|
|
16
|
-
* pill
|
|
17
|
-
*
|
|
15
|
+
* @param {'round'|'pill'|'circle'} [props.shape] Track shape: `round` (default) is the sliding
|
|
16
|
+
* pill with truly circular ends; `pill` is the same sliding pill with squircle ends;
|
|
17
|
+
* `circle` is a compact round on/off button.
|
|
18
18
|
* @param {string} [props.className]
|
|
19
19
|
* @param {import('react').Ref<HTMLInputElement>} [ref]
|
|
20
20
|
*/
|
package/dist/ui-react.js
CHANGED
|
@@ -758,15 +758,16 @@ function Be({ children: e, variant: t = "primary", size: n = "md", type: r = "bu
|
|
|
758
758
|
o ? "w-100" : "",
|
|
759
759
|
i ? "is-loading" : "",
|
|
760
760
|
p
|
|
761
|
-
].filter(Boolean).join(" ");
|
|
761
|
+
].filter(Boolean).join(" "), _ = (m.as === void 0 || m.as === "button") && l === void 0 && m.to === void 0, v = _ ? {} : { role: void 0 };
|
|
762
762
|
return q(/* @__PURE__ */ D(g, {
|
|
763
|
-
type:
|
|
763
|
+
type: _ ? r : void 0,
|
|
764
764
|
href: l,
|
|
765
765
|
variant: Le[t] ?? "primary",
|
|
766
766
|
size: n === "md" ? void 0 : n,
|
|
767
767
|
disabled: a || i,
|
|
768
768
|
"aria-busy": i || void 0,
|
|
769
769
|
className: h || void 0,
|
|
770
|
+
...v,
|
|
770
771
|
...m,
|
|
771
772
|
children: [
|
|
772
773
|
i && /* @__PURE__ */ E("span", {
|
|
@@ -5166,7 +5167,7 @@ function vr(e, t) {
|
|
|
5166
5167
|
}
|
|
5167
5168
|
//#endregion
|
|
5168
5169
|
//#region src/components/AppSwitch.jsx
|
|
5169
|
-
var yr = i(function({ label: e, id: t, name: n, error: r, hint: i, shape: a = "
|
|
5170
|
+
var yr = i(function({ label: e, id: t, name: n, error: r, hint: i, shape: a = "round", className: o = "", ...s }, c) {
|
|
5170
5171
|
return W("AppSwitch", s), /* @__PURE__ */ E(vt, {
|
|
5171
5172
|
ref: c,
|
|
5172
5173
|
label: e,
|
|
@@ -5177,7 +5178,7 @@ var yr = i(function({ label: e, id: t, name: n, error: r, hint: i, shape: a = "p
|
|
|
5177
5178
|
className: o,
|
|
5178
5179
|
rest: s,
|
|
5179
5180
|
inputType: "checkbox",
|
|
5180
|
-
wrapperClass: `form-check form-switch${a === "circle" ? " form-switch-circle" : a === "
|
|
5181
|
+
wrapperClass: `form-check form-switch${a === "circle" ? " form-switch-circle" : a === "pill" ? " form-switch-pill" : ""}`
|
|
5181
5182
|
});
|
|
5182
5183
|
});
|
|
5183
5184
|
//#endregion
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@webority/ui-react",
|
|
3
|
-
"version": "0.17.
|
|
3
|
+
"version": "0.17.2",
|
|
4
4
|
"description": "Webority shared React component library — App* primitives on react-bootstrap + the @webority/theme design system.",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE",
|
|
6
6
|
"type": "module",
|
|
@@ -28,8 +28,8 @@
|
|
|
28
28
|
},
|
|
29
29
|
"sideEffects": false,
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@webority/
|
|
32
|
-
"@webority/
|
|
31
|
+
"@webority/theme": "0.17.2",
|
|
32
|
+
"@webority/ui-elements": "0.17.2"
|
|
33
33
|
},
|
|
34
34
|
"peerDependencies": {
|
|
35
35
|
"@webority/analytics": "^0.6.0",
|