Files
ianitor/deploy/nixos/web.nix
T
mnovak c9aa55ec99 [web] Domi UI: the web UI on @domi/ui v1.0.4, vendored (CPAL-1.0), with the Built on Domi credit (PR #14, squashed)
@domi/ui v1.0.4 vendored unchanged in packages/domi-ui by domi-design's tools/vendor.mjs and used as workspace:*, so
the Nix build fetches nothing from Gitea (web.nix sources the folder; fetchPnpmDeps hash from the NixOS runner).
Its fonts, roles (data-domi-room="ianitor", the same hex) and controls replace Ianitor's copies: Button through
Ianitor's adapter (desktop sizes kept), every text field a TextField with its seal, Checkbox, Select, Segmented.
Ianitor's 22 role names renamed to --domi-*. <DomiCredit /> on every screen and in About, with the CPAL section 15
note beside the source link; the README names the vendored package. Disabled buttons are natively disabled.
2026-11-23 00:52:19 +01:00

47 lines
1.3 KiB
Nix

# SPDX-License-Identifier: CPAL-1.0
# Copyright (c) 2026 Marek Novák. Part of Ianitor, under the Common Public Attribution
# License 1.0: see LICENSE (its Exhibit A is this file's notice).
# The web UI (apps/web with packages/ui), built with pnpm from the lockfile. No outside
# requests at runtime: the fonts are bundled.
{ lib, stdenv, nodejs_22, pnpm_11, fetchPnpmDeps, pnpmConfigHook }:
stdenv.mkDerivation (finalAttrs: {
pname = "ianitor-web";
version = (lib.importJSON ../../apps/web/package.json).version;
src = lib.fileset.toSource {
root = ../..;
fileset = lib.fileset.unions [
../../package.json
../../pnpm-workspace.yaml
../../pnpm-lock.yaml
../../apps/web
../../packages/ui
# @domi/ui, vendored from domi-design at a tag (docs/domi-ui.md): nothing is fetched from Gitea.
../../packages/domi-ui
];
};
nativeBuildInputs = [ nodejs_22 pnpm_11 pnpmConfigHook ];
pnpmDeps = fetchPnpmDeps {
inherit (finalAttrs) pname version src;
pnpm = pnpm_11;
fetcherVersion = 4;
hash = "sha256-OqQxC6gewmnTxYD5jjDA6l8Lcm/JXxGmLQoyZcXpIh8=";
};
buildPhase = ''
runHook preBuild
pnpm --filter web build
runHook postBuild
'';
installPhase = ''
runHook preInstall
cp -r apps/web/dist $out
runHook postInstall
'';
})