Skip to content

Chore/open source repositioning#2

Merged
eliazv merged 4 commits into
masterfrom
chore/open-source-repositioning
Jun 20, 2026
Merged

Chore/open source repositioning#2
eliazv merged 4 commits into
masterfrom
chore/open-source-repositioning

Conversation

@eliazv

@eliazv eliazv commented Jun 20, 2026

Copy link
Copy Markdown
Owner

No description provided.

eliazv and others added 4 commits June 20, 2026 14:09
Switch lockfile and scripts/CI to pnpm. Pin ioredis to 5.10.1 via
pnpm.overrides (bullmq pulled a second copy that conflicted on types),
pin stripe to 20.3.1 exact (newer patch breaks the apiVersion literal
type), and declare dotenv/tsx explicitly since pnpm's isolated
node_modules no longer hoists them by accident like npm did.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Add a "perché esiste" section anchored on the real Italian e-invoicing
pain point, a docs index, and a note that Shopify/WooCommerce clients
exist in code but stay disabled until the Stripe flow is solid. Also
fix root layout.tsx metadata/JSON-LD, which still advertised a paid
SaaS with fake pricing tiers and SDI auto-filing guarantees —
contradicting the open source disclaimer-first landing page.

Add CLAUDE.md so future sessions know: pnpm only, what belongs in
docs/ vs private/ (gitignored scratch/strategy notes), and the pinned
dependency quirks from the pnpm migration.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…up lint

Add GET /api/invoices/export?format=csv|json — the most-requested gap
per the project roadmap (raw data for the accountant/gestionale, no
provider lock-in). Fix the invoices dashboard reading data.invoices/
data.total when the API actually returns data.data/data.pagination.total,
which meant the table always rendered empty regardless of real data.

Resolve the 29 pre-existing lint errors blocking CI: escape JSX entities,
type the two `any` usages in the dashboard, fix a use-before-declared
hook in the accountant page, and annotate three fetch-on-mount effects
that trip the newer react-hooks/set-state-in-effect rule with no real
alternative. Also rewrite the Terms page billing section, which still
described paid SaaS tiers FiscLink doesn't have — it's free, self-hosted,
MIT.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Replace the hand-rolled dashboard chrome (fixed <aside>, ad-hoc nav,
divs styled as cards/tables) with shadcn/ui primitives ported from the
kiranism next-shadcn-dashboard-starter structure: collapsible Sidebar
with cookie-persisted state, Card/Table/Badge/Button for the dashboard
home and invoices list, and a Vercel-style neutral theme (oklch tokens,
light/dark via next-themes) instead of one-off hex colors.

Icons map to lucide-react (already a dependency) instead of pulling in
@tabler/icons-react; dropped Wiloo's kbar command palette, TanStack
Query, and Supabase auth — merchant identity and logout reuse the
existing /api/settings and /api/auth/logout endpoints. Settings,
reports and onboarding pages are unchanged for now and keep their
current styling.

Removed the unused next-auth dependency — auth is the existing custom
JWT/jose flow in middleware.ts, next-auth was never wired to it.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings June 20, 2026 12:55

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR repackages the project as an open-source, self-hosted tool (vs SaaS positioning), refreshes the dashboard UI with a new sidebar/layout system, and updates tooling/docs to standardize on pnpm and a shadcn-style component stack.

Changes:

  • Introduces a shadcn-style UI component set (Radix + CVA) plus sidebar/layout primitives and theme support.
  • Updates marketing/legal pages and site metadata to reflect “open source + self-hosted” positioning.
  • Adds invoice export (CSV/JSON) and migrates scripts/CI/docs from npm to pnpm.

Reviewed changes

Copilot reviewed 61 out of 64 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
src/lib/utils.ts Adds cn() utility (clsx + tailwind-merge) used across new UI components.
src/hooks/use-mobile.tsx Adds useIsMobile() hook used by the sidebar for responsive behavior.
src/config/nav-config.ts Introduces centralized nav group/item configuration for the sidebar.
src/components/ui/tooltip.tsx New tooltip wrapper components built on Radix Tooltip.
src/components/ui/tabs.tsx New tabs wrapper components built on Radix Tabs.
src/components/ui/table.tsx New table wrappers with consistent styling and slots.
src/components/ui/spinner.tsx New spinner component (Loader icon) used by Button loading state.
src/components/ui/skeleton.tsx New skeleton loading component.
src/components/ui/sidebar.tsx Large new sidebar system: provider/context, desktop+mobile modes, menu primitives.
src/components/ui/sheet.tsx New sheet (drawer) components built on Radix Dialog.
src/components/ui/separator.tsx New separator component built on Radix Separator.
src/components/ui/select.tsx New select components built on Radix Select.
src/components/ui/scroll-area.tsx New scroll-area wrappers built on Radix ScrollArea.
src/components/ui/label.tsx New label component built on Radix Label.
src/components/ui/input.tsx New styled input component used across dashboard pages.
src/components/ui/dropdown-menu.tsx New dropdown menu components built on Radix DropdownMenu.
src/components/ui/collapsible.tsx New collapsible wrappers built on Radix Collapsible.
src/components/ui/checkbox.tsx New checkbox component built on Radix Checkbox.
src/components/ui/card.tsx New card components for dashboard layout and stat blocks.
src/components/ui/button.tsx New button component with variants and loading state (Spinner).
src/components/ui/badge.tsx New badge component used for statuses and UI labels.
src/components/ui/avatar.tsx New avatar components built on Radix Avatar.
src/components/ui/alert.tsx New alert component with variants for messaging.
src/components/layout/theme-provider.tsx Adds NextThemes provider wrapper for theme/class management.
src/components/layout/header.tsx New sticky dashboard header integrating sidebar trigger and separator.
src/components/layout/app-sidebar.tsx New app sidebar UI (nav + theme toggle + account dropdown).
src/app/terms/page.tsx Updates Terms copy to open-source/self-hosted positioning; escapes apostrophes for JSX.
src/app/privacy/page.tsx Escapes apostrophes/quotes for JSX and keeps copy consistent.
src/app/page.tsx Escapes apostrophes in public landing copy.
src/app/layout.tsx Updates metadata/JSON-LD for open-source positioning; wraps app in ThemeProvider; adds suppressHydrationWarning.
src/app/globals.css Migrates to Tailwind v4-style theme tokens, dark mode variables, and base layer styles; adds tw-animate-css.
src/app/dashboard/settings/page.tsx Adds eslint disable comment for effect calling load functions.
src/app/dashboard/page.tsx Refactors dashboard UI to Card/Button/Badge components and refreshed styling.
src/app/dashboard/nav-client.tsx Removes legacy nav implementation in favor of new sidebar system.
src/app/dashboard/merchant-badge-client.tsx Removes legacy merchant badge component (account UI moved into sidebar dropdown).
src/app/dashboard/layout.tsx Replaces legacy dashboard shell with new SidebarProvider/AppSidebar/Header layout and cookie-based open state.
src/app/dashboard/invoices/page.tsx Refactors invoices page UI to new components; adds export links; aligns to new API response shape.
src/app/api/invoices/route.ts Removes stale TODO comment (no functional changes).
src/app/api/invoices/export/route.ts Adds new export endpoint for invoices in CSV/JSON (authenticated via middleware-injected merchant header).
src/app/accountant/[token]/page.tsx Refactors data fetching with useCallback + updated effect dependencies.
scripts/dev-start.sh Switches dev script commands from npm/npx to pnpm/pnpm exec.
scripts/dev-start.ps1 Switches dev script commands from npm/npx to pnpm/pnpm exec (PowerShell).
README.md Updates README for OSS positioning, adds badges, updates setup instructions to pnpm, links docs.
package.json Declares pnpm packageManager, adds Radix/shadcn deps, adds pnpm scripts/overrides, pins Stripe version.
docs/TEST_GUIDE.md Updates commands from npm/npx to pnpm/pnpm exec.
docs/technical_status/TODO2.md Removes internal scratch/todo document from docs.
docs/technical_status/TODO.md Removes large internal operational doc from docs.
docs/technical_status/STATUS_REPORT.md Removes internal status report from docs.
docs/SETUP.md Updates setup/deploy commands to pnpm and adjusts prerequisites.
docs/research/ricerca-deep.md Removes internal research dump from docs.
docs/research/analisi-v3.md Removes internal analysis dump from docs.
docs/research/analisi-v2.md Removes internal analysis dump from docs.
docs/research/analisi-ricerca.md Removes internal analysis dump from docs.
docs/DEPLOY.md Updates deploy instructions/commands to pnpm.
docs/commercial_strategy/TERMS_OF_SERVICE.md Removes internal commercial ToS draft from docs.
docs/commercial_strategy/REPORT_MISSION.md Removes internal commercial mission report from docs.
docs/commercial_strategy/costi.md Removes internal cost notes from docs.
docs/commercial_strategy/COMMERCIAL_STRATEGY.md Removes internal commercial strategy doc from docs.
docs/AI_CONTEXT.md Updates dev commands to pnpm equivalents.
CLAUDE.md Adds contributor/agent context doc clarifying OSS positioning, pnpm conventions, and guardrails.
.gitignore Adds /private to ignore internal notes/strategy dumps.
.github/workflows/ci.yml Migrates CI to pnpm (setup + cache + install + scripts).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +1 to +6
import { Loader2 } from "lucide-react";

import { cn } from "@/lib/utils";

function Spinner({ className, ...props }: React.ComponentProps<"svg">) {
return (
Comment on lines +1 to +2
import { cn } from "@/lib/utils";

Comment on lines +1 to +4
"use client";

import * as CollapsiblePrimitive from "@radix-ui/react-collapsible";

@eliazv eliazv merged commit 9212f4e into master Jun 20, 2026
2 checks passed
@eliazv eliazv deleted the chore/open-source-repositioning branch June 20, 2026 13:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants