-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #71 from brown-ccv/documentation-tables
Documentation tables
- Loading branch information
Showing
52 changed files
with
333 additions
and
117 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
import React from "react" | ||
import Button from "./Button.tsx" | ||
|
||
interface DocumentationTableProps { | ||
allFiles: { | ||
data: { | ||
title: string | ||
cat: string | ||
file?: string | ||
archivo?: string | ||
description?: string | ||
version?: string | ||
codebookType?: string | ||
} | ||
}[] | ||
version?: boolean | ||
showHeader?: boolean | ||
} | ||
|
||
const DocumentationTable: React.FC<DocumentationTableProps> = ({ | ||
allFiles, | ||
version, | ||
showHeader, | ||
}) => { | ||
const files = allFiles.map((file) => { | ||
return { ...file.data } | ||
}) | ||
return ( | ||
<div className="w-full overflow-x-scroll no-scrollbar"> | ||
<table className="table-fixed border-spacing-4 w-full"> | ||
<thead className={showHeader ? "" : "collapse"}> | ||
<tr className="text-xl bg-neutral-100 text-left text-neutral-900"> | ||
<th className="w-1/4">File</th> | ||
<th>Description</th> | ||
{version && <th className="w-1/5">Field Season</th>} | ||
</tr> | ||
</thead> | ||
|
||
<tbody> | ||
{files.map(({ title, file, description, version, archivo }, i) => { | ||
return ( | ||
<tr key={i}> | ||
<td className="flex justify-between gap-2"> | ||
<p className="font-bold">{title}</p> | ||
<div className="flex gap-1"> | ||
( | ||
{file && ( | ||
<a | ||
className="text-secondary-blue-700 hover:text-secondary-blue-500" | ||
target="_blank" | ||
href={file} | ||
> | ||
en | ||
</a> | ||
)} | ||
{file && archivo && <p>/</p>} | ||
{archivo && ( | ||
<a | ||
className="text-secondary-blue-700 hover:text-secondary-blue-500" | ||
target="_blank" | ||
href={archivo} | ||
> | ||
es | ||
</a> | ||
)} | ||
) | ||
</div> | ||
</td> | ||
<td>{description}</td> | ||
{version && <td>{version}</td>} | ||
</tr> | ||
) | ||
})} | ||
</tbody> | ||
</table> | ||
</div> | ||
) | ||
} | ||
export default DocumentationTable |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
title: Appendix A | ||
description: Community Survey Year Codes | ||
file: src/content/data/files/appendix-a-sample-information-mmp174-.pdf | ||
cat: Appendices | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
title: Appendix B | ||
description: Place Codes in Mexico and the United States | ||
file: src/content/data/files/appendix-b-places-mmp174-.pdf | ||
cat: Appendices | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
title: Appendix C | ||
description: State Codes in Mexico and the United States | ||
file: src/content/data/files/appendix-c-states-mmp174-.pdf | ||
cat: Appendices | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
title: Appendix D | ||
description: Occupation Codes (English) | ||
file: src/content/data/files/appendix-d-occupations-mmp174-.pdf | ||
cat: Appendices | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
title: Appendix E | ||
description: Computation of Total U.S. Experience (English) | ||
file: src/content/data/files/appendix-e-computation-of-us-experience-mmp174-.pdf | ||
cat: Appendices | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
title: Appendix F | ||
description: Farm Codes in Canada | ||
file: src/content/data/files/appendix-f-canadian-farms-mmp174-.pdf | ||
cat: Appendices | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
title: Appendix G | ||
description: Community Data Inventory (English) | ||
file: src/content/data/files/comquest1999_eng.pdf | ||
cat: Appendices | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
title: Appendix H | ||
description: MMP Weights | ||
file: src/content/data/files/mmp-and-lamp-weights-2012.pdf | ||
cat: Appendices | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
--- | ||
title: CNMIG | ||
description: cross-sectional file containing information of the household-head - | ||
or another migrant when the household-head was not a migrant - who has | ||
migration experience to Canada. | ||
file: src/content/data/files/cnmig-codebook-mmp174-.pdf | ||
cat: Codebook | ||
codebookType: MMP Core | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
title: Commun 174 | ||
description: DTA file | ||
file: src/content/data/files/commun174.dta | ||
cat: Core | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
title: ENVIRONS | ||
description: Variable list and specifications | ||
file: src/content/data/files/environs-codebook-mmp134-.pdf | ||
cat: Codebook | ||
codebookType: State Level Supplementary | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
title: Ethnosurvey I | ||
description: Survey applied to communities interviewed from 1987 to 1997, and in 1982 | ||
version: 1987 - 1997 | ||
archivo: src/content/data/files/mmp-etnoencuesta-versión-1-aplicada-de-1987-a-1997.pdf | ||
cat: Questionnaire | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
--- | ||
title: Ethnosurvey II | ||
description: Survey applied to communities interviewed on 1998 and 1999 | ||
version: 1998 - 1999 | ||
file: src/content/data/files/mmp-ethnosurvey-version-ii-applied-in-1998-and-1999.pdf | ||
archivo: src/content/data/files/mmp-etnoencuesta-versión-2-aplicada-de-1998-a-1999.pdf | ||
cat: Questionnaire | ||
--- |
Oops, something went wrong.