@poly-x/react 0.1.0-alpha.4 → 0.1.0-alpha.5

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.cjs CHANGED
@@ -473,12 +473,11 @@ function SignIn(props) {
473
473
  } });
474
474
  }
475
475
  const picking = tenants !== null;
476
- const hasPanel = variant === "page" && Boolean(props.panel || props.logo || labels.tagline);
476
+ const hasPanel = variant === "page";
477
477
  const showHeaderLogo = Boolean(props.logo) && !hasPanel;
478
478
  const rootClass = [
479
479
  "polyx-signin",
480
480
  `polyx-signin--${variant}`,
481
- hasPanel && "polyx-signin--split",
482
481
  props.className
483
482
  ].filter(Boolean).join(" ");
484
483
  const step = picking ? "select_tenant" : mustSetPassword ? "set_password" : "credentials";
@@ -648,7 +647,7 @@ function SignIn(props) {
648
647
  if (variant === "page") return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
649
648
  className: rootClass,
650
649
  "data-polyx-signin": step,
651
- children: [hasPanel ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("aside", {
650
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("aside", {
652
651
  className: "polyx-signin__panel",
653
652
  children: props.panel ?? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [props.logo ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
654
653
  className: "polyx-signin__panel-logo",
@@ -657,7 +656,7 @@ function SignIn(props) {
657
656
  className: "polyx-signin__tagline",
658
657
  children: labels.tagline
659
658
  }) : null] })
660
- }) : null, /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
659
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
661
660
  className: "polyx-signin__main",
662
661
  children: card
663
662
  })]
package/dist/index.mjs CHANGED
@@ -472,12 +472,11 @@ function SignIn(props) {
472
472
  } });
473
473
  }
474
474
  const picking = tenants !== null;
475
- const hasPanel = variant === "page" && Boolean(props.panel || props.logo || labels.tagline);
475
+ const hasPanel = variant === "page";
476
476
  const showHeaderLogo = Boolean(props.logo) && !hasPanel;
477
477
  const rootClass = [
478
478
  "polyx-signin",
479
479
  `polyx-signin--${variant}`,
480
- hasPanel && "polyx-signin--split",
481
480
  props.className
482
481
  ].filter(Boolean).join(" ");
483
482
  const step = picking ? "select_tenant" : mustSetPassword ? "set_password" : "credentials";
@@ -647,7 +646,7 @@ function SignIn(props) {
647
646
  if (variant === "page") return /* @__PURE__ */ jsxs("div", {
648
647
  className: rootClass,
649
648
  "data-polyx-signin": step,
650
- children: [hasPanel ? /* @__PURE__ */ jsx("aside", {
649
+ children: [/* @__PURE__ */ jsx("aside", {
651
650
  className: "polyx-signin__panel",
652
651
  children: props.panel ?? /* @__PURE__ */ jsxs(Fragment, { children: [props.logo ? /* @__PURE__ */ jsx("div", {
653
652
  className: "polyx-signin__panel-logo",
@@ -656,7 +655,7 @@ function SignIn(props) {
656
655
  className: "polyx-signin__tagline",
657
656
  children: labels.tagline
658
657
  }) : null] })
659
- }) : null, /* @__PURE__ */ jsx("div", {
658
+ }), /* @__PURE__ */ jsx("div", {
660
659
  className: "polyx-signin__main",
661
660
  children: card
662
661
  })]
package/dist/styles.css CHANGED
@@ -25,7 +25,10 @@
25
25
  --polyx-ring: #a5b4fc;
26
26
  --polyx-danger: #dc2626;
27
27
  --polyx-danger-bg: #fef2f2;
28
- --polyx-page-bg: #fafafa;
28
+ --polyx-page-bg: #ffffff;
29
+ /* The `page` variant's left panel — a quiet surface, a shade off the form side. */
30
+ --polyx-panel-bg: #fafafa;
31
+ --polyx-panel-fg: #18181b;
29
32
 
30
33
  /* Shape + type */
31
34
  --polyx-radius: 0.75rem;
@@ -59,7 +62,9 @@
59
62
  --polyx-ring: #4f46e5;
60
63
  --polyx-danger: #f87171;
61
64
  --polyx-danger-bg: #2a1616;
62
- --polyx-page-bg: #09090b;
65
+ --polyx-page-bg: #18181b;
66
+ --polyx-panel-bg: #09090b;
67
+ --polyx-panel-fg: #fafafa;
63
68
  --polyx-shadow: 0 1px 3px rgb(0 0 0 / 0.4), 0 10px 30px rgb(0 0 0 / 0.35);
64
69
  }
65
70
  }
@@ -77,7 +82,9 @@
77
82
  --polyx-ring: #4f46e5;
78
83
  --polyx-danger: #f87171;
79
84
  --polyx-danger-bg: #2a1616;
80
- --polyx-page-bg: #09090b;
85
+ --polyx-page-bg: #18181b;
86
+ --polyx-panel-bg: #09090b;
87
+ --polyx-panel-fg: #fafafa;
81
88
  --polyx-shadow: 0 1px 3px rgb(0 0 0 / 0.4), 0 10px 30px rgb(0 0 0 / 0.35);
82
89
  }
83
90
 
@@ -92,7 +99,9 @@
92
99
  --polyx-ring: #a5b4fc;
93
100
  --polyx-danger: #dc2626;
94
101
  --polyx-danger-bg: #fef2f2;
95
- --polyx-page-bg: #fafafa;
102
+ --polyx-page-bg: #ffffff;
103
+ --polyx-panel-bg: #fafafa;
104
+ --polyx-panel-fg: #18181b;
96
105
  --polyx-shadow: 0 1px 3px rgb(0 0 0 / 0.06), 0 10px 30px rgb(0 0 0 / 0.07);
97
106
  }
98
107
 
@@ -115,10 +124,12 @@
115
124
  }
116
125
 
117
126
  /**
118
- * `page`: owns the viewport. With brand content (a `logo`, a `tagline`, or a
119
- * custom `panel`) it becomes a split layout brand panel beside the form on
120
- * wide screens, a slim brand band above it on narrow ones. With no brand content
121
- * there's nothing to put in a panel, so it stays a single centered column.
127
+ * `page`: owns the viewport a left/right split. The form sits on the right; the
128
+ * left is a quiet surface holding whatever the consumer gives it (a `logo`, a
129
+ * `tagline`, or a custom `panel`). Deliberately minimal: no gradient, no invented
130
+ * copy. An empty panel reads as intentional negative space, and never fights the
131
+ * host app's brand. Below 64rem the panel drops away entirely and the form takes
132
+ * the screen on its own.
122
133
  */
123
134
  .polyx-signin--page {
124
135
  display: grid;
@@ -126,55 +137,29 @@
126
137
  min-height: 100dvh;
127
138
  }
128
139
 
129
- .polyx-signin--page.polyx-signin--split {
130
- grid-template-rows: auto 1fr;
131
- }
132
-
133
140
  @media (min-width: 64rem) {
134
- .polyx-signin--page.polyx-signin--split {
135
- grid-template-columns: 1.1fr 1fr;
136
- grid-template-rows: 1fr;
141
+ .polyx-signin--page {
142
+ grid-template-columns: 1fr 1fr;
137
143
  }
138
144
  }
139
145
 
140
146
  .polyx-signin__panel {
141
- display: flex;
142
- position: relative;
143
- overflow: hidden;
144
- align-items: center;
145
- gap: 1rem;
146
- padding: 1.25rem 1.5rem;
147
- color: var(--polyx-brand-fg);
148
- background: linear-gradient(145deg, var(--polyx-brand), color-mix(in srgb, var(--polyx-brand) 55%, #000));
147
+ display: none;
148
+ flex-direction: column;
149
+ justify-content: space-between;
150
+ gap: 2rem;
151
+ padding: 3.5rem;
152
+ color: var(--polyx-panel-fg);
153
+ background: var(--polyx-panel-bg);
154
+ border-right: 1px solid var(--polyx-border);
149
155
  }
150
156
 
151
157
  @media (min-width: 64rem) {
152
158
  .polyx-signin__panel {
153
- flex-direction: column;
154
- align-items: flex-start;
155
- justify-content: space-between;
156
- gap: 2rem;
157
- padding: 3.5rem;
159
+ display: flex;
158
160
  }
159
161
  }
160
162
 
161
- /* Soft light-bloom so a bare brand panel still reads as designed, not as a flat fill. */
162
- .polyx-signin__panel::after {
163
- content: "";
164
- position: absolute;
165
- inset: 0;
166
- pointer-events: none;
167
- background:
168
- radial-gradient(circle at 82% 12%, rgb(255 255 255 / 0.18), transparent 45%),
169
- radial-gradient(circle at 12% 88%, rgb(255 255 255 / 0.1), transparent 42%);
170
- }
171
-
172
- .polyx-signin__panel-logo,
173
- .polyx-signin__tagline {
174
- position: relative;
175
- z-index: 1;
176
- }
177
-
178
163
  /* The tagline is the panel's headline — it only earns its space on wide screens. */
179
164
  .polyx-signin__tagline {
180
165
  display: none;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@poly-x/react",
3
- "version": "0.1.0-alpha.4",
3
+ "version": "0.1.0-alpha.5",
4
4
  "description": "PolyX SDK for React SPAs - provider, hooks, drop-in auth UI",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -27,7 +27,7 @@
27
27
  "module": "./dist/index.mjs",
28
28
  "types": "./dist/index.d.cts",
29
29
  "dependencies": {
30
- "@poly-x/core": "0.1.0-alpha.4"
30
+ "@poly-x/core": "0.1.0-alpha.5"
31
31
  },
32
32
  "peerDependencies": {
33
33
  "react": ">=18",