@jelinek/ui 0.5.0 → 0.5.2

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
@@ -464,24 +464,53 @@ cascade that `pnpm test`'s jsdom environment structurally cannot check
464
464
  The `publish` job is separate and gated on a tag matching `ui-v*` — it
465
465
  does not run on ordinary merges to `master`, only when someone pushes a
466
466
  `ui-v*` tag, and it also depends on `verify` passing first. It publishes
467
- to **npmjs.org with `--access public`**, authenticating with the
468
- `NPM_TOKEN` repo secret (a granular token for the `jelinek` npm org — a
469
- different namespace from the GitHub org, which is named
470
- `JELINEK-nabytek-a-matrace`). No provenance (`--provenance`) is
471
- generated: npm rejects it for builds from a private repository.
472
-
473
- **That job does not currently work, and 0.3.0 was released by hand.** npm
474
- requires a second factor for every publish, and a granular token only
475
- satisfies that if "Bypass two-factor authentication (2FA)" was ticked
476
- *when the token was created* — the setting cannot be added to an existing
477
- token, and npm is in the middle of restricting bypass tokens outright
478
- (account changes Aug 2026, direct publishing Jan 2027). Without it the
479
- registry answers a `PUT` with a misleading `E404 Not Found` in CI, and a
480
- clearer `E403 … Two-factor authentication or granular access token with
481
- bypass 2fa enabled is required` locally.
482
-
483
- So the working release procedure is manual, from a machine that can reach
484
- a browser:
467
+ to **npmjs.org with `--access public`**.
468
+
469
+ ### Releasing
470
+
471
+ 1. Bump `version` in `svelte/package.json`, commit, push `master`.
472
+ 2. `git tag ui-v<version> && git push origin ui-v<version>`.
473
+ 3. `verify` runs, then `publish` — nothing else to do.
474
+
475
+ The tag is what records which commit a version came from, so push it even
476
+ if a release has to be finished by hand.
477
+
478
+ ### How the publish authenticates
479
+
480
+ **Trusted publishing (GitHub Actions OIDC), no secret.** The job asks
481
+ GitHub for an OIDC token and npm exchanges it for a short-lived publish
482
+ credential. Registered on npmjs under the package's *Trusted publisher*:
483
+ org `JELINEK-nabytek-a-matrace`, repo `brand-guide`, workflow filename
484
+ `ui.yml`, environment left empty. All three are checked on every publish
485
+ — **renaming `ui.yml`, or adding an `environment:` to the publish job,
486
+ breaks releases** until the publisher entry is edited to match.
487
+
488
+ Two consequences worth knowing:
489
+
490
+ - The job runs `npm publish`, not `pnpm publish`. The OIDC exchange lives
491
+ in the npm CLI (11.5.1+, which the job installs explicitly); pnpm would
492
+ look for an auth token, find none, and fail.
493
+ - Provenance stays off (`NPM_CONFIG_PROVENANCE=false`). npm can only
494
+ attest a build from a public repository and this one is private
495
+ (licensed fonts). Trusted publishing does not require provenance.
496
+
497
+ There is no `NPM_TOKEN` secret any more. It never worked: npm requires a
498
+ second factor for every publish, and a granular token only satisfies that
499
+ if "Bypass two-factor authentication (2FA)" was ticked *when the token was
500
+ created* — a setting that cannot be added afterwards, on a mechanism npm
501
+ is retiring outright (account changes Aug 2026, direct publishing Jan
502
+ 2027). Without it the registry answered a `PUT` with a misleading `E404
503
+ Not Found` in CI. 0.3.0 through 0.5.0 were released by hand because of it.
504
+
505
+ **0.5.1 was the first release published by CI**, which settles the doubt
506
+ this section used to carry: a private repository does not block trusted
507
+ publishing. Only the provenance attestation needs a public repo, and that
508
+ is opt-out, not a precondition.
509
+
510
+ ### Fallback: publishing by hand
511
+
512
+ If the job fails, the release is not stuck — publish from a machine that
513
+ can reach a browser:
485
514
 
486
515
  ```
487
516
  cd svelte && npm publish --access public --auth-type=web
@@ -490,13 +519,7 @@ cd svelte && npm publish --access public --auth-type=web
490
519
  That prints a `npmjs.com/auth/cli/…` URL; approving it there with a
491
520
  passkey (or an authenticator app) completes the publish. `--otp=<code>`
492
521
  works too, but only with an authenticator app — a passkey produces no
493
- code. Push the `ui-v*` tag anyway: `verify` still gates the release, and
494
- the tag is what records which commit a version came from.
495
-
496
- Fixing CI means either a bypass-enabled token while npm still issues
497
- them, or trusted publishing via GitHub Actions OIDC — the latter is
498
- untested here and may be unavailable for the same reason provenance is,
499
- namely that this repo is private.
522
+ code.
500
523
 
501
524
  ## Known design debt
502
525
 
@@ -107,8 +107,11 @@
107
107
  magenta: 'text-jelinek-magenta'
108
108
  };
109
109
 
110
+ // h-full so tiles in a CSS-grid row equalise: the grid stretches the
111
+ // wrapper, and the button must follow it — otherwise a two-line label
112
+ // makes one tile taller and its row neighbours look ragged.
110
113
  const BASE =
111
- 'w-full cursor-pointer rounded-card border-2 bg-surface text-left ' +
114
+ 'h-full w-full cursor-pointer rounded-card border-2 bg-surface text-left ' +
112
115
  'font-secondary font-light text-fg ' +
113
116
  'transition-[border-color,box-shadow] duration-[var(--dur-base)] ease-[var(--ease)]';
114
117
 
@@ -124,7 +127,7 @@
124
127
  const meterMax = $derived(meter?.max ?? 5);
125
128
  </script>
126
129
 
127
- <div class="relative">
130
+ <div class="relative h-full">
128
131
  <button type="button" onclick={handleClick} aria-pressed={selected} {disabled} {...rest} class={classes}>
129
132
  {#if image}
130
133
  <div class="relative">
@@ -143,8 +146,13 @@
143
146
  >
144
147
  {#if swatchLabel}
145
148
  <!-- Literal white + a soft shadow: the swatch is an arbitrary
146
- consumer colour, so no theme token can promise contrast. -->
147
- <span class="font-semibold text-white [text-shadow:0_1px_2px_rgba(0,0,0,0.35)]"
149
+ consumer colour, so no theme token can promise contrast.
150
+ `font-bold`, not `font-semibold`: GT Walsheim Pro ships
151
+ 300/400/500/700/900 and no 600, so semibold silently
152
+ renders as Medium 500 (e2e/font-faces.spec.ts caught it).
153
+ `font-semibold` is only legal on the logo subtitle, which
154
+ switches to Avenir Next, whose Demi *is* 600. -->
155
+ <span class="font-bold text-white [text-shadow:0_1px_2px_rgba(0,0,0,0.35)]"
148
156
  >{swatchLabel}</span
149
157
  >
150
158
  {/if}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jelinek/ui",
3
- "version": "0.5.0",
3
+ "version": "0.5.2",
4
4
  "description": "JELÍNEK Svelte 5 component kit, generated from the brand guide",
5
5
  "license": "UNLICENSED",
6
6
  "type": "module",