-
-
Notifications
You must be signed in to change notification settings - Fork 273
Enhancement: Roadmap page for the Overview section #1021
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
18 commits
Select commit
Hold shift + click to select a range
039245a
Roadmap page for the Overview section
rishabhknowss 2e7a428
added themes and fixed routing
rishabhknowss 0143dc3
build fix
rishabhknowss 105a2a3
Merge branch 'json-schema-org:main' into main
rishabhknowss 82bd10f
changes
rishabhknowss 1bb04d2
updated package.json
rishabhknowss a2a5c0e
fix build
rishabhknowss 58d9bc0
Merge branch 'json-schema-org:main' into main
rishabhknowss 990f457
added safelist
rishabhknowss 8abe995
Merge branch 'json-schema-org:main' into main
rishabhknowss ea16574
changes ui
rishabhknowss 7e3af91
fix build
rishabhknowss e5dcd32
Update components/Sidebar.tsx
rishabhknowss 174ded5
Update pages/overview/roadmap/index.page.tsx
rishabhknowss 952d6a8
updated ui
rishabhknowss 0d564c7
fixes purgeCSS
rishabhknowss 6d5e04e
Change roadmap position in sidebar
benjagm 69f971f
Fix formatting
benjagm File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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,138 @@ | ||
import React from 'react'; | ||
import { DocsHelp } from '~/components/DocsHelp'; | ||
import { getLayout } from '~/components/Sidebar'; | ||
import Head from 'next/head'; | ||
import { Headline1 } from '~/components/Headlines'; | ||
import { SectionContext } from '~/context'; | ||
import roadmap from '~/data/roadmap.json'; | ||
|
||
const statusColors = { | ||
'In Progress': 'bg-green-600 text-white dark:bg-green-500', | ||
Done: 'bg-purple-600 text-white dark:bg-purple-500', | ||
Planned: 'bg-blue-600 text-white dark:bg-blue-500', | ||
Paused: 'bg-red-600 text-white dark:bg-red-500', | ||
Deferred: 'bg-blue-600 text-white dark:bg-blue-500', | ||
Unknown: 'bg-gray-600 text-white dark:bg-gray-500', | ||
}; | ||
|
||
const effortColors = { | ||
Low: 'bg-green-600 text-white dark:bg-green-500', | ||
Medium: 'bg-yellow-600 text-white dark:bg-yellow-500', | ||
High: 'bg-red-600 text-white dark:bg-red-500', | ||
'Low-medium': 'bg-green-600 text-white dark:bg-green-500', | ||
Unknown: 'bg-gray-600 text-white dark:bg-gray-500', | ||
}; | ||
|
||
const impactColors = { | ||
Low: 'bg-red-600 text-white dark:bg-red-500', | ||
Medium: 'bg-yellow-600 text-white dark:bg-yellow-500', | ||
High: 'bg-green-600 text-white dark:bg-green-500', | ||
'Medium-high': 'bg-yellow-600 text-white dark:bg-yellow-500', | ||
'Low-medium': 'bg-red-600 text-white dark:bg-red-500', | ||
Unknown: 'bg-gray-600 text-white dark:bg-gray-500', | ||
}; | ||
|
||
export default function Roadmap() { | ||
const newTitle = 'JSON Schema Roadmap'; | ||
const markdownFile = '_indexPage'; | ||
|
||
return ( | ||
<SectionContext.Provider value='docs'> | ||
<Head> | ||
<title>{newTitle}</title> | ||
</Head> | ||
<Headline1>{newTitle}</Headline1> | ||
<div className='text-md'> | ||
Our "Roadmap" section displays our key objectives for the long term. | ||
While this roadmap provides a detailed outlook for the near future, | ||
please note that it might be subject to change. In fact, we are | ||
currently{' '} | ||
<a | ||
className='text-blue-600 underline' | ||
href='https://github.com/orgs/json-schema-org/discussions/813' | ||
> | ||
discussing | ||
</a>{' '} | ||
the new priorities for the next 24-month cycle, which will lead to | ||
relevant changes. Please consider joining the discussion to become an | ||
active part of JSON Schema's future! | ||
</div> | ||
<div className='text-gray-900 dark:text-white'> | ||
<div className='container mt-14 mx-auto px-4'> | ||
<div className='relative'> | ||
<div className='absolute left-0 top-0 bottom-0 w-0.5 bg-blue-600'></div> | ||
|
||
{roadmap.map((item) => { | ||
const status = | ||
item.fieldValues.nodes.find( | ||
(node) => node.field?.name === 'Status', | ||
)?.name || 'Unknown'; | ||
const category = | ||
item.fieldValues.nodes.find( | ||
(node) => node.field?.name === 'Category', | ||
)?.name || 'Uncategorized'; | ||
const effort = | ||
item.fieldValues.nodes.find( | ||
(node) => node.field?.name === 'Effort', | ||
)?.name || 'Unknown'; | ||
const impact = | ||
item.fieldValues.nodes.find( | ||
(node) => node.field?.name === 'Impact', | ||
)?.name || 'Unknown'; | ||
|
||
const effortClass = | ||
effortColors[effort as keyof typeof effortColors] || | ||
effortColors['Unknown']; | ||
const impactClass = | ||
impactColors[impact as keyof typeof impactColors] || | ||
impactColors['Unknown']; | ||
const statusClass = | ||
statusColors[status as keyof typeof statusColors] || | ||
statusColors['Unknown']; | ||
|
||
return ( | ||
<div key={item.id} className='relative z-10 mb-12 pl-8'> | ||
<div className='absolute -left-4 top-6 w-8 h-8 bg-blue-600 rounded-full z-10 flex items-center justify-center'> | ||
<div className='w-4 h-4 bg-white dark:bg-gray-800 rounded-full'></div> | ||
</div> | ||
|
||
<div className='bg-white dark:bg-gray-800 relative z-10 w-full rounded-lg overflow-hidden border border-gray-200 dark:border-gray-700 shadow-lg'> | ||
<div className='p-6'> | ||
<span className='inline-block px-3 py-1 text-sm font-semibold text-white bg-blue-600 rounded-full mb-4'> | ||
{category} | ||
</span> | ||
<h2 className='text-2xl font-bold mb-3'> | ||
{item.content.title} | ||
</h2> | ||
|
||
<div className='flex flex-wrap items-center gap-2 text-sm'> | ||
<span | ||
className={`px-2 py-1 rounded whitespace-nowrap ${effortClass}`} | ||
> | ||
Effort: {effort} | ||
</span> | ||
<span | ||
className={`px-2 py-1 rounded whitespace-nowrap ${impactClass}`} | ||
> | ||
Impact: {impact} | ||
</span> | ||
</div> | ||
</div> | ||
<div className={`px-6 py-3 ${statusClass}`}> | ||
<span className='text-sm font-semibold text-white uppercase'> | ||
{status} | ||
</span> | ||
</div> | ||
</div> | ||
</div> | ||
); | ||
})} | ||
</div> | ||
</div> | ||
</div> | ||
<DocsHelp markdownFile={markdownFile} /> | ||
</SectionContext.Provider> | ||
); | ||
} | ||
|
||
Roadmap.getLayout = getLayout; |
This file contains hidden or 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
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.