You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: export.go
    path of file: ./repos/erda/internal/apps/dop/providers/issue/core/query/issueexcel/sheets/sheet_label
    
    the code of the file until where you have to start completion: // Copyright (c) 2021 Terminus, Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the
    
func (h *Handler) ExportSheet(data *vars.DataForFulfill) (*sheets.RowsForExport, error) {
	var lines excel.Rows
	// title: label id, label name, label detail (JSON)
	title := excel.Row{
		excel.NewTitleCell("label id"),
		excel.NewTitleCell("label name"),
		excel.NewTitleCell("label detail (json)"),
	}
	lines = append(lines, title)
	// data
	// collect labels from issues
	labelMap := make(map[int64]*pb.ProjectLabel)
	for _, issue := range data.ExportOnly.Issues {
		for _, label := range issue.LabelDetails {
			if _, ok := labelMap[label.Id]; !ok {
				labelMap[label.Id] = label
			}
		}
	}
	for _, label := range labelMap {
		labelInfo, err := json.Marshal(label)
		if err != nil {
			return nil, fmt.Errorf("failed to marshal label info, label id: %d, err: %v", label.Id, err)
		}
		lines = append(lines, excel.Row{
			excel.NewCell(strconv.FormatInt(label.Id, 10)),
			excel.NewCell(label.Name),
			excel.NewCell(string(labelInfo)),
		})
	}

	return sheets.NewRowsForExport(lines), nil
}