@xleddyl/443-components-vue 0.16.48 → 0.16.50

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/README.md CHANGED
@@ -714,7 +714,7 @@ A large dialog (60rem) with a section nav on the left and the content on the rig
714
714
 
715
715
  ### AuthLayout
716
716
 
717
- Two columns: on the left the brand at the top, then the title, the description and the form (aligned left, `--k-auth-width`, default 24rem), and the footer at the bottom. On the right an aside panel that shows from 960px (`:aside="false"` hides it). `breadcrumbs` replaces the title with a large trail (`Breadcrumbs size="lg"`), for a step of a flow. Props: `title`, `description`, `breadcrumbs`, `footer`, `brandName`, `brandSubtitle`, `brandIcon`, `brandLogo`, `brandTo`, `aside`, `asideTitle`, `asideDescription`, `themeSwitch`. Slots: default (form), `title`, `description`, `links` (under the form), `footer`, `brand`, `aside`, `corner`.
717
+ Two columns: on the left the brand at the top, then the title, the description and the form (aligned left, `--k-auth-width`, default 24rem), and the footer at the bottom. On the right an aside panel that shows from 960px (`:aside="false"` hides it). Its glow, orb and grid drift slowly on long loops and stand still with `prefers-reduced-motion`. `breadcrumbs` replaces the title with a large trail (`Breadcrumbs size="lg"`), for a step of a flow. Props: `title`, `description`, `breadcrumbs`, `footer`, `brandName`, `brandSubtitle`, `brandIcon`, `brandLogo`, `brandTo`, `aside`, `asideTitle`, `asideDescription`, `themeSwitch`. Slots: default (form), `title`, `description`, `links` (under the form), `footer`, `brand`, `aside`, `corner`.
718
718
 
719
719
  ### AuthLogin and AuthLogout
720
720
 
@@ -187,7 +187,7 @@ useResizeObserver(
187
187
  );
188
188
  watch(open, (value) => {
189
189
  if (!value) return;
190
- nextTick(() => focusFirst(sidebar.value));
190
+ nextTick(() => focusFirst(sidebar.value, { preventScroll: true }));
191
191
  });
192
192
  provide(SHELL_KEY, {
193
193
  sidebarId,
@@ -48,6 +48,7 @@
48
48
  <aside v-if="aside" class="k-auth-aside" :aria-label="asideText">
49
49
  <slot name="aside">
50
50
  <div class="k-auth-aside-art" aria-hidden="true">
51
+ <span class="k-auth-aside-glow" />
51
52
  <span class="k-auth-aside-orb" />
52
53
  <span class="k-auth-aside-grid" />
53
54
  </div>
@@ -2,5 +2,5 @@ export declare function activeElement(): HTMLElement | null;
2
2
  export declare function hasFocusWithin(element: Element | null | undefined): boolean;
3
3
  export declare function isFocusLost(container?: Element | null): boolean;
4
4
  export declare function focusStable(target: HTMLElement): void;
5
- export declare function focusFirst(container: Element | null | undefined): boolean;
5
+ export declare function focusFirst(container: Element | null | undefined, options?: FocusOptions): boolean;
6
6
  export declare function neighborFocusTarget(element: HTMLElement): HTMLElement | null;
@@ -31,9 +31,9 @@ export function focusStable(target) {
31
31
  if (!target.hasAttribute("tabindex")) target.setAttribute("tabindex", "-1");
32
32
  target.focus({ preventScroll: true });
33
33
  }
34
- export function focusFirst(container) {
34
+ export function focusFirst(container, options) {
35
35
  const first = container ? focusableWithin(container)[0] : void 0;
36
- first?.focus();
36
+ first?.focus(options);
37
37
  return Boolean(first);
38
38
  }
39
39
  export function neighborFocusTarget(element) {
@@ -147,17 +147,11 @@
147
147
  margin: 0.5rem 0.5rem 0.5rem 0;
148
148
  overflow: hidden;
149
149
  border-radius: var(--k-radius-xl);
150
- background:
151
- radial-gradient(
152
- 120% 90% at 100% 0%,
153
- color-mix(in oklab, var(--k-accent) 55%, white) 0%,
154
- transparent 55%
155
- ),
156
- linear-gradient(
157
- 160deg,
158
- var(--k-accent) 0%,
159
- color-mix(in oklab, var(--k-accent) 70%, black) 100%
160
- );
150
+ background: linear-gradient(
151
+ 160deg,
152
+ var(--k-accent) 0%,
153
+ color-mix(in oklab, var(--k-accent) 70%, black) 100%
154
+ );
161
155
  box-shadow: var(--k-shadow-xs);
162
156
  color: var(--k-accent-contrast);
163
157
  isolation: isolate;
@@ -169,14 +163,35 @@
169
163
  z-index: -1;
170
164
  }
171
165
 
166
+ .k-auth-aside-glow {
167
+ position: absolute;
168
+ inset: -25%;
169
+ background: radial-gradient(
170
+ 80% 60% at 83% 17%,
171
+ color-mix(in oklab, var(--k-accent) 55%, white) 0%,
172
+ transparent 55%
173
+ );
174
+ animation: k-auth-glow 28s ease-in-out infinite alternate;
175
+ will-change: transform;
176
+ }
177
+
172
178
  .k-auth-aside-grid {
173
179
  position: absolute;
174
180
  inset: 0;
181
+ overflow: hidden;
182
+ mask-image: radial-gradient(80% 70% at 70% 30%, black, transparent);
183
+ }
184
+
185
+ .k-auth-aside-grid::before {
186
+ position: absolute;
187
+ inset: -2.5rem 0 0 -2.5rem;
175
188
  background-image:
176
189
  linear-gradient(rgb(255 255 255 / 0.08) 1px, transparent 1px),
177
190
  linear-gradient(90deg, rgb(255 255 255 / 0.08) 1px, transparent 1px);
178
191
  background-size: 2.5rem 2.5rem;
179
- mask-image: radial-gradient(80% 70% at 70% 30%, black, transparent);
192
+ animation: k-auth-grid 48s linear infinite;
193
+ content: '';
194
+ will-change: transform;
180
195
  }
181
196
 
182
197
  .k-auth-aside-orb {
@@ -188,6 +203,66 @@
188
203
  border-radius: var(--k-radius-full);
189
204
  background: radial-gradient(circle at 30% 30%, rgb(255 255 255 / 0.5), transparent 65%);
190
205
  filter: blur(2px);
206
+ animation:
207
+ k-auth-orb 22s ease-in-out infinite alternate,
208
+ k-auth-orb-light 9s ease-in-out infinite alternate;
209
+ will-change: transform, opacity;
210
+ }
211
+
212
+ @keyframes k-auth-glow {
213
+ 0% {
214
+ transform: translate3d(0, 0, 0) scale(1) rotate(0deg);
215
+ }
216
+
217
+ 50% {
218
+ transform: translate3d(-6%, 5%, 0) scale(1.08) rotate(4deg);
219
+ }
220
+
221
+ 100% {
222
+ transform: translate3d(3%, 8%, 0) scale(1.03) rotate(-3deg);
223
+ }
224
+ }
225
+
226
+ @keyframes k-auth-orb {
227
+ 0% {
228
+ transform: translate3d(0, 0, 0) scale(1);
229
+ }
230
+
231
+ 33% {
232
+ transform: translate3d(-2.5rem, 1.5rem, 0) scale(1.05);
233
+ }
234
+
235
+ 66% {
236
+ transform: translate3d(1rem, 3rem, 0) scale(0.97);
237
+ }
238
+
239
+ 100% {
240
+ transform: translate3d(-1.5rem, -1rem, 0) scale(1.03);
241
+ }
242
+ }
243
+
244
+ @keyframes k-auth-orb-light {
245
+ from {
246
+ opacity: 0.75;
247
+ }
248
+
249
+ to {
250
+ opacity: 1;
251
+ }
252
+ }
253
+
254
+ @keyframes k-auth-grid {
255
+ to {
256
+ transform: translate3d(2.5rem, 2.5rem, 0);
257
+ }
258
+ }
259
+
260
+ @media (prefers-reduced-motion: reduce) {
261
+ .k-root .k-auth-aside-glow,
262
+ .k-root .k-auth-aside-orb,
263
+ .k-root .k-auth-aside-grid::before {
264
+ animation: none;
265
+ }
191
266
  }
192
267
 
193
268
  .k-auth-aside-content {
@@ -22,7 +22,7 @@
22
22
  flex: none;
23
23
  flex-direction: column;
24
24
  gap: 1px;
25
- width: 14rem;
25
+ width: 13.25rem;
26
26
  padding: 0.625rem;
27
27
  border-right: 1px solid var(--k-line);
28
28
  background: var(--k-subtle);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xleddyl/443-components-vue",
3
- "version": "0.16.48",
3
+ "version": "0.16.50",
4
4
  "description": "Compact, scoped dashboard components for Vue and Nuxt",
5
5
  "license": "MIT",
6
6
  "author": "Edoardo Alberti (https://github.com/xleddyl)",