@xenosystem/components 0.5.0 → 0.6.0
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/auth/index.d.ts +3 -1
- package/dist/auth/index.js +3 -3
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
package/dist/auth/index.d.ts
CHANGED
|
@@ -44,8 +44,10 @@ interface SignInFormProps {
|
|
|
44
44
|
animate?: boolean;
|
|
45
45
|
/** Diagnostic hook the panel sets to its phase; carried to the DOM as `data-phase`. */
|
|
46
46
|
phase?: string;
|
|
47
|
+
/** One callback for every action (a declaration binds this once); an action's own `onClick` still wins. */
|
|
48
|
+
onAction?: (id: string) => void;
|
|
47
49
|
}
|
|
48
|
-
declare function SignInForm({ tag, title, body, actions, note, warning, identity, animate, phase }: SignInFormProps): react.JSX.Element;
|
|
50
|
+
declare function SignInForm({ tag, title, body, actions, note, warning, identity, animate, phase, onAction }: SignInFormProps): react.JSX.Element;
|
|
49
51
|
/** The licence plates are the same form with a tag; kept as a name so a panel reads honestly. */
|
|
50
52
|
declare const LicencePlate: typeof SignInForm;
|
|
51
53
|
|
package/dist/auth/index.js
CHANGED
|
@@ -19,7 +19,7 @@ var CSS = `
|
|
|
19
19
|
.xc-auth[data-aspect=square] .xc-brand svg,.xc-auth__head .xc-brand svg{width:20px;height:20px}
|
|
20
20
|
.xc-brand__word{font-size:13px;font-weight:700;letter-spacing:.2em;text-transform:uppercase}
|
|
21
21
|
.xc-auth[data-aspect=square] .xc-brand__word,.xc-auth__head .xc-brand__word{font-size:11px}
|
|
22
|
-
.xc-hero__h1{font-size:3.5rem;font-weight:700;line-height:1.1;letter-spacing:-.02em;max-width:32rem}
|
|
22
|
+
.xc-hero__h1{font-size:3.5rem;font-weight:700;line-height:1.1;letter-spacing:-.02em;max-width:32rem;white-space:pre-line}
|
|
23
23
|
.xc-auth[data-aspect=square] .xc-hero__h1{font-size:2rem}
|
|
24
24
|
.xc-hero__lead{margin-top:16px;max-width:24rem;font-size:16px;line-height:1.6}
|
|
25
25
|
.xc-hero__stats{display:flex;align-items:center;gap:32px}
|
|
@@ -134,7 +134,7 @@ function AuthHero({ headline, lead, stats, imageSrc, compact }) {
|
|
|
134
134
|
import { useEffect, useState } from "react";
|
|
135
135
|
import { Button } from "@xenosystem/elements-react";
|
|
136
136
|
import { jsx as jsx3, jsxs as jsxs3 } from "react/jsx-runtime";
|
|
137
|
-
function SignInForm({ tag, title, body, actions, note, warning, identity, animate = true, phase }) {
|
|
137
|
+
function SignInForm({ tag, title, body, actions, note, warning, identity, animate = true, phase, onAction }) {
|
|
138
138
|
useAuthStyles();
|
|
139
139
|
const [visible, setVisible] = useState(!animate);
|
|
140
140
|
useEffect(() => {
|
|
@@ -146,7 +146,7 @@ function SignInForm({ tag, title, body, actions, note, warning, identity, animat
|
|
|
146
146
|
tag && /* @__PURE__ */ jsx3("span", { className: "xc-form__tag", children: tag }),
|
|
147
147
|
/* @__PURE__ */ jsx3("h2", { className: "xc-form__h2", children: title }),
|
|
148
148
|
/* @__PURE__ */ jsx3("p", { className: "xc-form__sub", children: body }),
|
|
149
|
-
actions.length > 0 && /* @__PURE__ */ jsx3("div", { className: "xc-form__actions", children: actions.map((a) => /* @__PURE__ */ jsx3(Button, { variant: a.variant ?? "secondary", size: "lg", disabled: a.disabled, onClick: a.onClick, "data-intent": a.id, children: a.label }, a.id)) }),
|
|
149
|
+
actions.length > 0 && /* @__PURE__ */ jsx3("div", { className: "xc-form__actions", children: actions.map((a) => /* @__PURE__ */ jsx3(Button, { variant: a.variant ?? "secondary", size: "lg", disabled: a.disabled, onClick: a.onClick ?? (onAction ? () => onAction(a.id) : void 0), "data-intent": a.id, children: a.label }, a.id)) }),
|
|
150
150
|
note && /* @__PURE__ */ jsx3("p", { className: "xc-form__note", children: note }),
|
|
151
151
|
warning && /* @__PURE__ */ jsx3("p", { className: "xc-form__warn", children: warning }),
|
|
152
152
|
identity && /* @__PURE__ */ jsxs3("p", { className: "xc-form__who", children: [
|
package/dist/index.d.ts
CHANGED
|
@@ -3,6 +3,6 @@
|
|
|
3
3
|
* Families are subpaths: `@xenosystem/components/auth`, `/navigation`, `/feedback`, `/data`.
|
|
4
4
|
* This root re-exports nothing on purpose: import the family you use, so a bundle carries only it.
|
|
5
5
|
*/
|
|
6
|
-
declare const COMPONENTS_VERSION = "0.
|
|
6
|
+
declare const COMPONENTS_VERSION = "0.6.0";
|
|
7
7
|
|
|
8
8
|
export { COMPONENTS_VERSION };
|
package/dist/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xenosystem/components",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.6.0",
|
|
4
4
|
"description": "XENO Components — rung 2 of the front ladder: molecules composed from @xenosystem/elements, with no host contract. Families as subpaths: /auth, /navigation, /feedback, /data.",
|
|
5
5
|
"license": "UNLICENSED",
|
|
6
6
|
"type": "module",
|