@boxyhq/react-ui
Advanced tools
Comparing version 0.0.15 to 0.0.16
@@ -1,2 +0,2 @@ | ||
(function(){"use strict";try{if(typeof document!="undefined"){var e=document.createElement("style");e.appendChild(document.createTextNode("._form_d2w4e_1{display:flex;flex-direction:column;max-width:28rem}._label_d2w4e_7{margin-bottom:.375rem}._input_d2w4e_11{font-family:inherit;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:#fff;border-radius:.375rem;border-width:1px;border-color:#ebedf0;border-style:solid;line-height:1.5rem;padding:.5rem .75rem;font-size:1rem;margin-top:1px;outline:none;margin-bottom:1rem}._input_d2w4e_11:focus{--bc: 0 0% 20%;outline:2px solid hsla(var(--bc) / .2);outline-offset:2px}._button_d2w4e_33{cursor:pointer;font-family:inherit;background-image:none;border-radius:.25rem;padding:.5rem 1rem;background-color:#25c2a0;color:#fff;border:none}._button_d2w4e_33:focus-visible{--p: 167deg 68% 45%;outline:2px solid hsl(var(--p));outline-offset:2px}._button_d2w4e_33:active{transform:scale(.95)}")),document.head.appendChild(e)}}catch(o){console.error("vite-plugin-css-injected-by-js",o)}})(); | ||
(function(){"use strict";try{if(typeof document!="undefined"){var e=document.createElement("style");e.appendChild(document.createTextNode("._form_1p3jn_1{display:flex;flex-direction:column;max-width:28rem}._label_1p3jn_7{margin-bottom:.375rem}._input_1p3jn_11{font-family:inherit;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:#fff;border-radius:.375rem;border-width:1px;border-color:#ebedf0;border-style:solid;line-height:1.5rem;padding:.5rem .75rem;font-size:1rem;margin-top:1px;outline:none;margin-bottom:1rem}._input_1p3jn_11:focus{--bc: 0 0% 20%;outline:2px solid hsla(var(--bc) / .2);outline-offset:2px}._button_1p3jn_33{cursor:pointer;font-family:inherit;background-image:none;border-radius:.25rem;padding:.5rem 1rem;background-color:#25c2a0;color:#fff;border:none}._button_1p3jn_33:focus-visible{--p: 167deg 68% 45%;outline:2px solid hsl(var(--p));outline-offset:2px}._button_1p3jn_33:active:hover,._button_1p3jn_33:active:focus{transform:scale(.95)}")),document.head.appendChild(e)}}catch(o){console.error("vite-plugin-css-injected-by-js",o)}})(); | ||
import Ye, { useState as H, useEffect as vr } from "react"; | ||
@@ -25,6 +25,6 @@ var M = {}, pr = { | ||
De = 1; | ||
var l = Ye, b = Symbol.for("react.element"), _ = Symbol.for("react.fragment"), y = Object.prototype.hasOwnProperty, j = l.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, h = { key: !0, ref: !0, __self: !0, __source: !0 }; | ||
var l = Ye, b = Symbol.for("react.element"), _ = Symbol.for("react.fragment"), y = Object.prototype.hasOwnProperty, x = l.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, h = { key: !0, ref: !0, __self: !0, __source: !0 }; | ||
function c(E, d, S) { | ||
var p, m = {}, T = null, P = null; | ||
S !== void 0 && (T = "" + S), d.key !== void 0 && (T = "" + d.key), d.ref !== void 0 && (P = d.ref); | ||
var p, m = {}, T = null, w = null; | ||
S !== void 0 && (T = "" + S), d.key !== void 0 && (T = "" + d.key), d.ref !== void 0 && (w = d.ref); | ||
for (p in d) | ||
@@ -35,3 +35,3 @@ y.call(d, p) && !h.hasOwnProperty(p) && (m[p] = d[p]); | ||
m[p] === void 0 && (m[p] = d[p]); | ||
return { $$typeof: b, type: E, key: T, ref: P, props: m, _owner: j.current }; | ||
return { $$typeof: b, type: E, key: T, ref: w, props: m, _owner: x.current }; | ||
} | ||
@@ -53,3 +53,3 @@ return W.Fragment = _, W.jsx = c, W.jsxs = c, W; | ||
return Ie || (Ie = 1, process.env.NODE_ENV !== "production" && function() { | ||
var l = Ye, b = Symbol.for("react.element"), _ = Symbol.for("react.portal"), y = Symbol.for("react.fragment"), j = Symbol.for("react.strict_mode"), h = Symbol.for("react.profiler"), c = Symbol.for("react.provider"), E = Symbol.for("react.context"), d = Symbol.for("react.forward_ref"), S = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), m = Symbol.for("react.memo"), T = Symbol.for("react.lazy"), P = Symbol.for("react.offscreen"), L = Symbol.iterator, X = "@@iterator"; | ||
var l = Ye, b = Symbol.for("react.element"), _ = Symbol.for("react.portal"), y = Symbol.for("react.fragment"), x = Symbol.for("react.strict_mode"), h = Symbol.for("react.profiler"), c = Symbol.for("react.provider"), E = Symbol.for("react.context"), d = Symbol.for("react.forward_ref"), S = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), m = Symbol.for("react.memo"), T = Symbol.for("react.lazy"), w = Symbol.for("react.offscreen"), L = Symbol.iterator, X = "@@iterator"; | ||
function U(e) { | ||
@@ -61,3 +61,3 @@ if (e === null || typeof e != "object") | ||
} | ||
var w = l.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED; | ||
var P = l.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED; | ||
function v(e) { | ||
@@ -72,3 +72,3 @@ { | ||
{ | ||
var n = w.ReactDebugCurrentFrame, i = n.getStackAddendum(); | ||
var n = P.ReactDebugCurrentFrame, i = n.getStackAddendum(); | ||
i !== "" && (r += "%s", t = t.concat([i])); | ||
@@ -84,3 +84,3 @@ var u = t.map(function(o) { | ||
function Le(e) { | ||
return !!(typeof e == "string" || typeof e == "function" || e === y || e === h || Me || e === j || e === S || e === p || I || e === P || Z || Q || D || typeof e == "object" && e !== null && (e.$$typeof === T || e.$$typeof === m || e.$$typeof === c || e.$$typeof === E || e.$$typeof === d || e.$$typeof === le || e.getModuleId !== void 0)); | ||
return !!(typeof e == "string" || typeof e == "function" || e === y || e === h || Me || e === x || e === S || e === p || I || e === w || Z || Q || D || typeof e == "object" && e !== null && (e.$$typeof === T || e.$$typeof === m || e.$$typeof === c || e.$$typeof === E || e.$$typeof === d || e.$$typeof === le || e.getModuleId !== void 0)); | ||
} | ||
@@ -111,3 +111,3 @@ function Ue(e, r, t) { | ||
return "Profiler"; | ||
case j: | ||
case x: | ||
return "StrictMode"; | ||
@@ -143,3 +143,3 @@ case S: | ||
} | ||
var x = Object.assign, A = 0, ce, de, ve, pe, be, ge, he; | ||
var j = Object.assign, A = 0, ce, de, ve, pe, be, ge, he; | ||
function _e() { | ||
@@ -180,21 +180,21 @@ } | ||
Object.defineProperties(console, { | ||
log: x({}, e, { | ||
log: j({}, e, { | ||
value: ce | ||
}), | ||
info: x({}, e, { | ||
info: j({}, e, { | ||
value: de | ||
}), | ||
warn: x({}, e, { | ||
warn: j({}, e, { | ||
value: ve | ||
}), | ||
error: x({}, e, { | ||
error: j({}, e, { | ||
value: pe | ||
}), | ||
group: x({}, e, { | ||
group: j({}, e, { | ||
value: be | ||
}), | ||
groupCollapsed: x({}, e, { | ||
groupCollapsed: j({}, e, { | ||
value: ge | ||
}), | ||
groupEnd: x({}, e, { | ||
groupEnd: j({}, e, { | ||
value: he | ||
@@ -207,3 +207,3 @@ }) | ||
} | ||
var ee = w.ReactCurrentDispatcher, re; | ||
var ee = P.ReactCurrentDispatcher, re; | ||
function V(e, r, t) { | ||
@@ -334,3 +334,3 @@ { | ||
} | ||
var G = Object.prototype.hasOwnProperty, Re = {}, me = w.ReactDebugCurrentFrame; | ||
var G = Object.prototype.hasOwnProperty, Re = {}, me = P.ReactDebugCurrentFrame; | ||
function J(e) { | ||
@@ -386,3 +386,3 @@ if (e) { | ||
} | ||
var $ = w.ReactCurrentOwner, Xe = { | ||
var $ = P.ReactCurrentOwner, Xe = { | ||
key: !0, | ||
@@ -482,3 +482,3 @@ ref: !0, | ||
} | ||
var oe = w.ReactCurrentOwner, Ce = w.ReactDebugCurrentFrame; | ||
var oe = P.ReactCurrentOwner, Ce = P.ReactDebugCurrentFrame; | ||
function k(e) { | ||
@@ -496,3 +496,3 @@ if (e) { | ||
} | ||
function we() { | ||
function Pe() { | ||
{ | ||
@@ -520,6 +520,6 @@ if (oe.current) { | ||
} | ||
var Pe = {}; | ||
var we = {}; | ||
function ir(e) { | ||
{ | ||
var r = we(); | ||
var r = Pe(); | ||
if (!r) { | ||
@@ -534,3 +534,3 @@ var t = typeof e == "string" ? e : e.displayName || e.name; | ||
} | ||
function xe(e, r) { | ||
function je(e, r) { | ||
{ | ||
@@ -541,5 +541,5 @@ if (!e._store || e._store.validated || e.key != null) | ||
var t = ir(r); | ||
if (Pe[t]) | ||
if (we[t]) | ||
return; | ||
Pe[t] = !0; | ||
we[t] = !0; | ||
var n = ""; | ||
@@ -549,3 +549,3 @@ e && e._owner && e._owner !== oe.current && (n = " It was passed a child from " + O(e._owner.type) + "."), k(e), v('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', t, n), k(null); | ||
} | ||
function je(e, r) { | ||
function xe(e, r) { | ||
{ | ||
@@ -557,3 +557,3 @@ if (typeof e != "object") | ||
var n = e[t]; | ||
ue(n) && xe(n, r); | ||
ue(n) && je(n, r); | ||
} | ||
@@ -566,3 +566,3 @@ else if (ue(e)) | ||
for (var u = i.call(e), o; !(o = u.next()).done; ) | ||
ue(o.value) && xe(o.value, r); | ||
ue(o.value) && je(o.value, r); | ||
} | ||
@@ -613,3 +613,3 @@ } | ||
var g = or(i); | ||
g ? a += g : a += we(); | ||
g ? a += g : a += Pe(); | ||
var f; | ||
@@ -627,3 +627,3 @@ e === null ? f = "null" : ne(e) ? f = "array" : e !== void 0 && e.$$typeof === b ? (f = "<" + (O(e.type) || "Unknown") + " />", a = " Did you accidentally export a JSX literal instead of a component?") : f = typeof e, v("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", f, a); | ||
for (var F = 0; F < R.length; F++) | ||
je(R[F], e); | ||
xe(R[F], e); | ||
Object.freeze && Object.freeze(R); | ||
@@ -633,3 +633,3 @@ } else | ||
else | ||
je(R, e); | ||
xe(R, e); | ||
} | ||
@@ -660,3 +660,3 @@ return e === y ? fr(s) : ur(s), s; | ||
}, [l, b]), _; | ||
}, N = (l = !1, b = "", _) => l ? b : `${_} ${b}`, Er = "_form_d2w4e_1", Rr = "_label_d2w4e_7", mr = "_input_d2w4e_11", yr = "_button_d2w4e_33", K = { | ||
}, N = (l = !1, b = "", _) => l ? b : `${_} ${b}`, Er = "_form_1p3jn_1", Rr = "_label_1p3jn_7", mr = "_input_1p3jn_11", yr = "_button_1p3jn_33", K = { | ||
form: Er, | ||
@@ -671,3 +671,3 @@ label: Rr, | ||
placeholder: y = "", | ||
buttonText: j = "Sign-in with SSO", | ||
buttonText: x = "Sign-in with SSO", | ||
styles: h, | ||
@@ -677,5 +677,5 @@ classNames: c, | ||
}) => { | ||
const d = $e(We, "input"), S = $e(We, "span"), [p, m] = H(""), [T, P] = H(""), L = (D) => { | ||
P(""), m(D.currentTarget.value); | ||
}, [X, U] = H(!1), w = async (D) => { | ||
const d = $e(We, "input"), S = $e(We, "span"), [p, m] = H(""), [T, w] = H(""), L = (D) => { | ||
w(""), m(D.currentTarget.value); | ||
}, [X, U] = H(!1), P = async (D) => { | ||
D.preventDefault(), U(!0); | ||
@@ -685,3 +685,3 @@ const { | ||
} = await b(p || l) || { error: {} }; | ||
U(!1), typeof I == "string" && I && P(I); | ||
U(!1), typeof I == "string" && I && w(I); | ||
}, v = !!T, Z = !l ? /* @__PURE__ */ Ae(hr, { children: [ | ||
@@ -719,6 +719,6 @@ /* @__PURE__ */ z( | ||
type: "button", | ||
onClick: w, | ||
onClick: P, | ||
style: h == null ? void 0 : h.button, | ||
className: N(E, c == null ? void 0 : c.button, K.button), | ||
children: j | ||
children: x | ||
} | ||
@@ -725,0 +725,0 @@ ) |
{ | ||
"name": "@boxyhq/react-ui", | ||
"description": "React UI components from BoxyHQ", | ||
"version": "0.0.15", | ||
"version": "0.0.16", | ||
"type": "module", | ||
@@ -6,0 +6,0 @@ "keywords": [ |
Sorry, the diff of this file is not supported yet
46114