{"id":31585342,"url":"https://github.com/nuvtools/nuvtools-report","last_synced_at":"2026-01-29T00:19:35.925Z","repository":{"id":190997493,"uuid":"612404333","full_name":"nuvtools/nuvtools-report","owner":"nuvtools","description":"Report base library to support PDF and Sheet infrastructure libraries.","archived":false,"fork":false,"pushed_at":"2025-09-30T14:52:11.000Z","size":25,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-10-06T01:48:05.791Z","etag":null,"topics":["csv","excel","exporter","pdf"],"latest_commit_sha":null,"homepage":"https://nuv.tools","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nuvtools.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2023-03-10T21:52:22.000Z","updated_at":"2025-09-30T14:52:15.000Z","dependencies_parsed_at":null,"dependency_job_id":"70dec6e3-7086-42af-a0e1-3835469ecb3f","html_url":"https://github.com/nuvtools/nuvtools-report","commit_stats":null,"previous_names":["nuvtools/nuvtools-report"],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/nuvtools/nuvtools-report","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nuvtools%2Fnuvtools-report","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nuvtools%2Fnuvtools-report/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nuvtools%2Fnuvtools-report/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nuvtools%2Fnuvtools-report/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nuvtools","download_url":"https://codeload.github.com/nuvtools/nuvtools-report/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nuvtools%2Fnuvtools-report/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28857546,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-28T22:56:21.783Z","status":"ssl_error","status_checked_at":"2026-01-28T22:56:00.861Z","response_time":57,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["csv","excel","exporter","pdf"],"created_at":"2025-10-06T01:47:20.042Z","updated_at":"2026-01-29T00:19:35.919Z","avatar_url":"https://github.com/nuvtools.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# NuvTools.Report\n\n[![NuGet](https://img.shields.io/nuget/v/NuvTools.Report.svg)](https://www.nuget.org/packages/NuvTools.Report/)\n[![License](https://img.shields.io/github/license/nuvtools/nuvtools-report.svg)](LICENSE)\n\nA .NET library suite for generating reports in PDF, Excel, and CSV formats. Build structured table-based reports with styling, company branding, and reflection-based data binding. Targets .NET 8, .NET 9, and .NET 10.\n\n## Libraries\n\n| Library | Description | NuGet |\n|---------|-------------|-------|\n| **NuvTools.Report** | Core report model infrastructure with document-table hierarchy | [![NuGet](https://img.shields.io/nuget/v/NuvTools.Report.svg)](https://www.nuget.org/packages/NuvTools.Report/) |\n| **NuvTools.Report.Pdf** | PDF generation using QuestPDF and PDFsharp | [![NuGet](https://img.shields.io/nuget/v/NuvTools.Report.Pdf.svg)](https://www.nuget.org/packages/NuvTools.Report.Pdf/) |\n| **NuvTools.Report.Sheet** | Excel and CSV generation using ClosedXML | [![NuGet](https://img.shields.io/nuget/v/NuvTools.Report.Sheet.svg)](https://www.nuget.org/packages/NuvTools.Report.Sheet/) |\n\n## Installation\n\n```bash\n# For PDF export\ndotnet add package NuvTools.Report.Pdf\n\n# For Excel/CSV export\ndotnet add package NuvTools.Report.Sheet\n\n# Or install the base library only\ndotnet add package NuvTools.Report\n```\n\n## Features\n\n- Multiple export formats: PDF (landscape A4), Excel (.xlsx), CSV\n- Automatic data binding from object collections via reflection\n- Customizable colors, fonts, and formatting\n- Company branding with logos, names, and URLs in headers\n- Metadata support: titles, filter descriptions, issue dates, user info\n- Base64-encoded output for API transmission\n- Multi-table documents with separate worksheets/pages\n- DateTime formatting with custom format strings\n- PDF merging utility\n\n## Architecture\n\nThe library uses a document-table-component hierarchy:\n\n```\nDocument\n└── Tables (List\u003cTable\u003e)\n    ├── Info (metadata: name, title, company info, issue date/user)\n    ├── Style (formatting: colors, fonts)\n    └── Content (Body)\n        ├── Header\n        │   └── Columns (List\u003cColumn\u003e)\n        └── Rows (List\u003cRow\u003e)\n            └── Cells (List\u003cCell\u003e)\n```\n\n## Usage\n\n### PDF Export\n\n```csharp\nusing NuvTools.Report.Table.Models;\nusing NuvTools.Report.Table.Models.Components;\nusing NuvTools.Report.Pdf.Table;\n\n// Define columns\nvar columns = new List\u003cColumn\u003e\n{\n    new Column { Name = \"Id\", Label = \"ID\", Order = 1, Format = \"\" },\n    new Column { Name = \"Name\", Label = \"Product Name\", Order = 2, Format = \"\" },\n    new Column { Name = \"Price\", Label = \"Price\", Order = 3, Format = \"C2\" },\n    new Column { Name = \"Date\", Label = \"Date\", Order = 4, Format = \"yyyy-MM-dd\" }\n};\n\n// Create a table\nvar table = new Table\n{\n    Info = new Info\n    {\n        Name = \"Products\",\n        Title = \"Product Catalog\",\n        CompanyAbbreviation = \"ACME Corp\",\n        CompanyUrl = \"https://acme.com\",\n        FilterDescription = \"All Products\",\n        IssueDate = DateTime.Now,\n        IssueUser = \"john.doe\"\n    },\n    Style = new Style\n    {\n        BackgroundHeaderColor = \"#003366\",\n        FontHeaderColor = \"#FFFFFF\"\n    },\n    Content = new Body()\n};\n\n// Populate rows from objects using reflection\ntable.SetRows(columns, products);\n\n// Create document and export\nvar document = new Document\n{\n    BackgroundDocumentHeaderColor = \"#003366\",\n    Tables = [table]\n};\n\nstring pdfBase64 = document.ExportFirstSheetToPdf();\nList\u003cstring\u003e allPdfs = document.ExportSheetToPdf();\n```\n\n### Excel Export\n\n```csharp\nusing NuvTools.Report.Sheet.Extensions;\n\nstring excelBase64 = document.ExportToExcel();\n\nbyte[] excelBytes = Convert.FromBase64String(excelBase64);\nFile.WriteAllBytes(\"report.xlsx\", excelBytes);\n```\n\n### CSV Export\n\n```csharp\nusing NuvTools.Report.Sheet.Extensions;\n\nList\u003cstring\u003e csvFiles = document.ExportToCsv();\nstring csvBase64 = document.ExportFirstSheetToCsv();\n```\n\n### PDF Merging\n\n```csharp\nusing NuvTools.Report.Pdf.Util;\n\nbyte[] mergedPdf = PdfUtil.Merge([pdf1Bytes, pdf2Bytes]);\n```\n\n## Dependencies\n\n### NuvTools.Report.Pdf\n- QuestPDF [2025.12.3,2026.1.0)\n- PDFsharp [6.2.4,6.3.0)\n\n### NuvTools.Report.Sheet\n- ClosedXML [0.105.0,0.106.0)\n\n## Building\n\nThis solution uses the `.slnx` (XML-based solution) format.\n\n```bash\ndotnet build NuvTools.Report.slnx\ndotnet build NuvTools.Report.slnx -c Release\n```\n\n## Project Structure\n\n```\nnuvtools-report/\n├── src/\n│   ├── NuvTools.Report/\n│   ├── NuvTools.Report.Pdf/\n│   └── NuvTools.Report.Sheet/\n├── NuvTools.Report.slnx\n└── README.md\n```\n\n## License\n\nThis project requires license acceptance. See the [LICENSE](LICENSE) file for details.\n\n## Links\n\n- [Website](https://nuvtools.com)\n- [GitHub Repository](https://github.com/nuvtools/nuvtools-report)\n- [NuGet Packages](https://www.nuget.org/profiles/NuvTools)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnuvtools%2Fnuvtools-report","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnuvtools%2Fnuvtools-report","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnuvtools%2Fnuvtools-report/lists"}