@flytedan/flytebot-design-system 0.20.0 → 0.21.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/index.d.cts CHANGED
@@ -2617,6 +2617,11 @@ declare function ProfilePage({ user: userProp, fields, notifications, extra, onC
2617
2617
  * FlytedeskBrand.tsx), so it is wrapped in its own `data-theme="dark"` scope
2618
2618
  * here to force the white variant against this page's permanently-dark
2619
2619
  * background, without affecting the (light) Card beneath it.
2620
+ *
2621
+ * `error`, when set, renders as a danger-tone `Banner` above the sign-in
2622
+ * button, with `role="alert"` so assistive tech announces it immediately —
2623
+ * e.g. app-kit's AK-19 sends the user back here with a plain message ("Your
2624
+ * sign-in took too long. Please try again.") instead of a raw error payload.
2620
2625
  */
2621
2626
  interface SignInContinueAs {
2622
2627
  /** The previously-signed-in user's display name, e.g. "Dana Reyes". */
@@ -2637,8 +2642,11 @@ interface SignInPageProps {
2637
2642
  * the page unloads. */
2638
2643
  onSignIn: () => void;
2639
2644
  continueAs?: SignInContinueAs;
2645
+ /** A plain-language message shown as a danger banner above the sign-in
2646
+ * button, e.g. after a failed silent resume. Omit for no banner. */
2647
+ error?: string;
2640
2648
  }
2641
- declare function SignInPage({ productName, onSignIn, continueAs }: SignInPageProps): React.JSX.Element;
2649
+ declare function SignInPage({ productName, onSignIn, continueAs, error }: SignInPageProps): React.JSX.Element;
2642
2650
 
2643
2651
  interface RoadmapTimelineProps {
2644
2652
  /** Called with a flag key when the reader clicks one — route it to your flag admin. */
package/dist/index.d.ts CHANGED
@@ -2617,6 +2617,11 @@ declare function ProfilePage({ user: userProp, fields, notifications, extra, onC
2617
2617
  * FlytedeskBrand.tsx), so it is wrapped in its own `data-theme="dark"` scope
2618
2618
  * here to force the white variant against this page's permanently-dark
2619
2619
  * background, without affecting the (light) Card beneath it.
2620
+ *
2621
+ * `error`, when set, renders as a danger-tone `Banner` above the sign-in
2622
+ * button, with `role="alert"` so assistive tech announces it immediately —
2623
+ * e.g. app-kit's AK-19 sends the user back here with a plain message ("Your
2624
+ * sign-in took too long. Please try again.") instead of a raw error payload.
2620
2625
  */
2621
2626
  interface SignInContinueAs {
2622
2627
  /** The previously-signed-in user's display name, e.g. "Dana Reyes". */
@@ -2637,8 +2642,11 @@ interface SignInPageProps {
2637
2642
  * the page unloads. */
2638
2643
  onSignIn: () => void;
2639
2644
  continueAs?: SignInContinueAs;
2645
+ /** A plain-language message shown as a danger banner above the sign-in
2646
+ * button, e.g. after a failed silent resume. Omit for no banner. */
2647
+ error?: string;
2640
2648
  }
2641
- declare function SignInPage({ productName, onSignIn, continueAs }: SignInPageProps): React.JSX.Element;
2649
+ declare function SignInPage({ productName, onSignIn, continueAs, error }: SignInPageProps): React.JSX.Element;
2642
2650
 
2643
2651
  interface RoadmapTimelineProps {
2644
2652
  /** Called with a flag key when the reader clicks one — route it to your flag admin. */
package/dist/index.js CHANGED
@@ -6379,7 +6379,7 @@ function ProfilePage({
6379
6379
  // src/components/platform/SignInPage.tsx
6380
6380
  import * as React42 from "react";
6381
6381
  import { Fragment as Fragment18, jsx as jsx67, jsxs as jsxs61 } from "react/jsx-runtime";
6382
- function SignInPage({ productName, onSignIn, continueAs }) {
6382
+ function SignInPage({ productName, onSignIn, continueAs, error }) {
6383
6383
  const [signingIn, setSigningIn] = React42.useState(false);
6384
6384
  const [resuming, setResuming] = React42.useState(false);
6385
6385
  function handleSignIn() {
@@ -6465,6 +6465,7 @@ function SignInPage({ productName, onSignIn, continueAs }) {
6465
6465
  /* @__PURE__ */ jsx67("h1", { className: "fd-h3", style: { color: "var(--navy)" }, children: productName }),
6466
6466
  /* @__PURE__ */ jsx67("p", { className: "fd-body-sm fd-muted", style: { marginTop: "var(--s-4)" }, children: continueAs ? "Your session timed out, but you're likely still signed in" : "Sign in with your flytedesk workspace account" })
6467
6467
  ] }),
6468
+ error ? /* @__PURE__ */ jsx67("div", { role: "alert", style: { width: "100%" }, children: /* @__PURE__ */ jsx67(Banner, { tone: "danger", title: error }) }) : null,
6468
6469
  continueAs ? /* @__PURE__ */ jsxs61(Fragment18, { children: [
6469
6470
  /* @__PURE__ */ jsx67(
6470
6471
  Button,