{
  "$schema": "https://ai.syncfusion.com/schema/registry-item.json",
  "name": "gantt-exporting",
  "framework": "javascript",
  "type": "registry:component",
  "component": "Gantt",
  "variant": "exporting",
  "dependencies": [
    "@syncfusion/ej2-gantt"
  ],
  "description": "Gantt chart sample exporting project schedules to PDF and Excel formats.",
  "meta": {
    "essentialStudioRelease": "2026 Volume 3 (v35.1.37)",
    "license": "commercial-or-community",
    "licenseNote": "The Syncfusion package is licensed. The composition in this file is source you own and edit. See https://ai.syncfusion.com/licensing.md",
    "requiresLicenseKey": true,
    "requiresServerEndpoint": false,
    "platformIndex": "https://ai.syncfusion.com/javascript/llms.txt",
    "skillPack": "syncfusion/javascript-ui-components-skills",
    "docs": "https://ai.syncfusion.com/gallery/javascript/gantt-exporting.md"
  },
  "files": [
    {
      "target": "src/components/gantt-exporting/gantt.html",
      "content": "<div class=\"control-section\">\n    <div class=\"content-wrapper\">\n        <div id=\"container\">\n        </div>\n    </div>\n</div>\n<style>\n    .fluent2 #export,\n    .fluent2-dark #export,\n    .fluent2-highcontrast #export {\n        padding: 7px;\n    }\n</style>"
    },
    {
      "target": "src/components/gantt-exporting/gantt.ts",
      "content": "import { Gantt, ExcelExport, Selection, Toolbar, PdfExport, DayMarkers } from '@syncfusion/ej2-gantt';\nimport type { ClickEventArgs } from '@syncfusion/ej2-navigations';\nimport { editingData, editingResources } from '../datasource/gantt-data';\n/**\n * Exporting Gantt sample\n */\nGantt.Inject(Selection, Toolbar, ExcelExport, PdfExport, DayMarkers);\n\nexport function initExportingGantt(): void {\n    let gantt: Gantt = new Gantt(\n        {\n            dataSource: editingData,\n            dateFormat: 'MMM dd, y',\n            taskFields: {\n                id: 'TaskID',\n                name: 'TaskName',\n                startDate: 'StartDate',\n                endDate: 'EndDate',\n                duration: 'Duration',\n                progress: 'Progress',\n                dependency: 'Predecessor',\n                parentID: 'ParentId',\n                resourceInfo: 'resources'\n            },\n            columns: [\n                { field: 'TaskID', width: 80 },\n                { field: 'TaskName', width: 250 }\n            ],\n            splitterSettings: {\n                columnIndex: 2\n            },\n            allowExcelExport: true,\n            allowPdfExport: true,\n            toolbar: ['ExcelExport', 'CsvExport', 'PdfExport'],\n            toolbarClick: (args?: ClickEventArgs) => {\n                if (args.item.id === 'GanttExport_excelexport') {\n                    gantt.excelExport();\n                } else if (args.item.id === 'GanttExport_csvexport') {\n                    gantt.csvExport();\n                } else if (args.item.id === 'GanttExport_pdfexport') {\n                    gantt.pdfExport();\n                }\n            },\n            allowSelection: true,\n            gridLines: 'Both',\n            height: '650px',\n            rowHeight: 46,\n            taskbarHeight: 25,\n            treeColumnIndex: 1,\n            resourceFields: {\n                id: 'resourceId',\n                name: 'resourceName'\n            },\n            resources: editingResources,\n            highlightWeekends: true,\n            timelineSettings: {\n                topTier: {\n                    unit: 'Week',\n                    format: 'MMM dd, y'\n                },\n                bottomTier: {\n                    unit: 'Day'\n                }\n            },\n            labelSettings: {\n                leftLabel: 'TaskName'\n            },\n            projectStartDate: new Date('03/26/2025'),\n            projectEndDate: new Date('09/01/2025')\n        });\n    gantt.appendTo('#container');\n}\n"
    }
  ]
}