Commit Graph
126 Commits
Author SHA1 Message Date
Kamran Ahmed 75edd1b4bc Restructure as a Turborepo monorepo
packages/driver is the library (still published as driver.js, with
repository.directory set); playground and docs move to apps/. One root
pnpm workspace and lockfile replace the three standalone projects, with
turbo orchestrating build/test/lint:package (apps depend on the library
build; local + CI caching via .turbo).

Apps keep importing the library from source for HMR — the aliases now
point at ../../packages/driver/src and each app gains a workspace:*
dependency so the task graph knows the edge. The dev-server fs scope
widens to the repo root accordingly.

Releases run from packages/driver (root `pnpm release` delegates). The
changelog still lives in the docs app, so the release scripts reach it
via ../../../apps/docs and the after:bump hook stages it explicitly —
release-it no longer sits above both directories.

The merged workspace settings keep sharp unbuilt on purpose (prebuilt
binaries; building from source needs node-gyp and fails) — the docs app
had this right and the playground setting was the accident. postcss and
postcss-scss were unreferenced devDependencies and are dropped; prettier
moves to the root as the only shared tool.
2026-07-16 19:45:23 +01:00
Kamran Ahmed d4c5182ee6 Migrate the package build to tsdown
One tool replaces four: both vite lib configs, vite-plugin-dts,
api-extractor and the terser postbuild. tsdown covers each of their jobs
natively — per-entry declaration bundling (from the actual lib entry, so
the vite-plugin-dts types-field footgun is structurally gone), oxc
minification, and CSS extraction with @import inlining via @tsdown/css.

The config keeps the two-isolated-builds decision as a config array: a
single multi-entry build would still split the shared popover primitive
into a common chunk and merge the stylesheets. Filenames, the exports
map and the CDN globals (window["driver"]["js"].driver, driverHints)
are unchanged; attw/publint stay green across node10/node16/bundler for
both entries.

Verified against the previous pipeline's output: identical file list,
identical driver.css rule set, hints.css differs only in Lightning CSS
keeping the inset shorthand our source already uses (baseline everywhere
driver.js supports), and every artifact's gzip size is equal or smaller.
Build drops from ~6.8s to ~2.2s — three TypeScript passes down to one
plus tsdown's per-entry declaration emit.

The postbuild shrinks to the two plain .d.ts copies node10 resolution
needs. vitest config moves to vitest.config.ts (vite itself is no longer
a direct dependency), and a local *.css module declaration replaces
vite/client's ambient types.
2026-07-16 18:59:15 +01:00
Kamran Ahmed 630adda553 Ship hints as the driver.js/hints entry
Two separate vite runs rather than one multi-entry build. Multi-entry
splits the shared popover primitive into a chunk, which would make the
tour bundle depend on a second file and cost every existing user bytes
for a feature they may never use; it also merged both stylesheets into
driver.css. Standing the entries alone keeps driver.css byte-identical
to master and the tour bundle within ~120 bytes of it, and lets hints be
used without the tour. Importing both duplicates the primitive (~2KB
gzip), which is safe because the copies only handle their own popovers.

The hints run writes to dist-hints/ and the postbuild folds it into
dist/. That indirection is not incidental: vite-plugin-dts takes its
entry from package.json's `types` field when bundling, not from the lib
entry, so pointing it at hints emits the tour's API under the hints name
and overwrites dist/driver.js.d.ts. api-extractor rolls up the hints
declarations from an explicit entry instead.

hints/package.json is a resolution shim for legacy node10, which predates
`exports`; attw is green across node10, node16 ESM/CJS and bundler for
both entries. sideEffects marks only CSS, so bundlers can drop unused
code from either entry.

Sizes (gzip): tour 6.7KB unchanged in CSS and ~6.8KB in JS, hints 4.2KB
JS + 0.4KB CSS standalone.
2026-07-15 04:27:53 +01:00
Kamran Ahmed b7d671c81e 1.7.0 2026-07-14 00:11:57 +01:00
Kamran Ahmed 1910fb2c30 Minify the ESM bundle with Terser in postbuild 2026-07-08 03:38:26 +01:00
Kamran Ahmed 2088df4a90 Switch release tooling from np to release-it
- Tag and commit use the unreleased version with no v prefix
- Move changelog Unreleased entries under the version on bump
- GitHub release notes are pulled from the changelog section
2026-06-25 18:07:16 +01:00
Kamran Ahmed 565757bfb0 1.6.0 2026-06-25 17:41:04 +01:00
Kamran Ahmed 39f3377176 Fix broken build and wrong x link 2026-06-25 13:06:43 +01:00
Kamran Ahmed 67b7450869 Update github link in package.json 2026-06-24 02:18:28 +01:00
Kamran Ahmed 310ddf9084 Bump version 1.5.0 2026-06-23 22:01:05 +01:00
Kamran Ahmed bf461234b8 Validate the package on publish/CI; fix dual-format types 2026-06-23 13:48:29 +01:00
Kamran Ahmed 498be73ba3 Modernize build and docs tooling 2026-06-23 13:48:29 +01:00
Kamran Ahmed 61c33f7a41 Add np for interactive releases 2026-06-23 09:48:04 +01:00
Kamran Ahmed 4fd1a55297 Add a jsdom test suite for the public API 2026-06-23 09:48:04 +01:00
Kamran Ahmed c324835cc8 Modernize tooling and add an Astro examples playground 2026-06-23 09:48:04 +01:00
Kamran Ahmed 061fb774fb Bump version 1.4.0 2025-11-18 22:21:52 +00:00
Kamran Ahmed e90b0d7bf0 Bump version 1.3.6 2025-05-13 09:38:12 +01:00
Kamran Ahmed f672f3fe95 Bump version 1.3.5 2025-02-03 17:34:30 +00:00
Ervan Prastyanto 4b9eebe570 Fix: package.json to correct sort default and require (#546) 2025-02-03 17:33:18 +00:00
Kamran Ahmed 6bd64db882 Fix CSS not importable in CSS file 2025-02-02 15:53:50 +00:00
Kamran Ahmed 8996e6aa41 Bump version 1.3.3 2025-02-02 15:42:10 +00:00
Kamran Ahmed 871a2103ab Bump version 1.3.2 2025-02-02 04:24:29 +00:00
Kamran Ahmed e65eaf383e Bump version 1.3.1 2023-11-10 18:12:28 +00:00
Rafael Heard 124a216bee add license to package.json (#432) 2023-09-27 21:35:52 +01:00
Kamran Ahmed d9dddec4d7 Upgrade dependencies 2023-09-04 11:21:47 +01:00
Kamran Ahmed 494e4503ba Bump version 1.3.0 2023-09-04 11:15:51 +01:00
Kamran Ahmed a952b08220 Bump version 1.2.1 2023-08-04 04:03:21 +01:00
Kamran Ahmed aef795e334 Bump version 1.2.0 2023-08-04 02:03:02 +01:00
ntnyq e986f9cc70 Add types exports path 2023-08-04 01:25:17 +01:00
Kamran Ahmed 529f19abbe Fixes #391 allowKeyboardControl option not working 2023-08-04 01:22:11 +01:00
Kamran Ahmed f3d28fac7f Bump version 1.1.0 2023-07-24 00:36:29 +01:00
Kamran Ahmed a8f769969c Bump version 1.0.5 2023-07-17 19:55:28 +01:00
Kamran Ahmed de338586e6 Add a way to configure steps 2023-07-06 08:27:31 +01:00
Kamran Ahmed 42aa4bee6a Rename onPopoverRendered to onPopoverRender 2023-07-05 14:20:06 +01:00
Kamran Ahmed 57bb1d0a1b Add keywords 2023-07-05 14:02:39 +01:00
Kamran Ahmed 1f0a0bb563 Add web and repo URLs to package.json 2023-07-05 14:00:09 +01:00
Kamran Ahmed e545e81990 Bump version 1.0.0 2023-07-05 12:59:02 +01:00
Kamran Ahmed 67d6fc897c 1.1.11-next.0 2023-07-03 14:23:00 +01:00
Kamran Ahmed 4368b97196 1.1.10-next.0 2023-07-03 03:34:38 +01:00
Kamran Ahmed f46ed15d42 1.1.9-next.0 2023-07-03 03:24:06 +01:00
Kamran Ahmed 3ddddd98e0 1.1.8-next.0 2023-07-03 02:20:27 +01:00
Kamran Ahmed 11f4e8d24d 1.1.7-next.0 2023-07-03 02:13:48 +01:00
Kamran Ahmed b17be9346e 1.1.6-next.0 2023-07-01 17:46:41 +01:00
Kamran Ahmed 76d4a2e060 1.1.5-next.0 2023-06-26 02:44:54 +01:00
Kamran Ahmed 194c4d47fc 1.1.4-next.0 2023-06-26 02:40:59 +01:00
Kamran Ahmed cbc2d83c0d 1.1.3-next.0 2023-06-26 02:32:18 +01:00
Kamran Ahmed d538d71e58 Rename CSS file to have same name 2023-06-26 02:32:11 +01:00
Kamran Ahmed 464f70bc57 1.1.2-next.0 2023-06-26 02:21:54 +01:00
Kamran Ahmed acbae00f95 Fix type definitions not found 2023-06-26 02:21:37 +01:00
Kamran Ahmed e9333a24cc 1.1.1-next.0 2023-06-26 01:58:53 +01:00