feat: question approval progress bar on homepage#270
feat: question approval progress bar on homepage#270jengkhaw95 wants to merge 8 commits intocsdojo-defaang:mainfrom
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
…stion-approval-progress-bar-section
…ub.com/jengkhaw95/defaang into question-approval-progress-bar-section
|
Thank you @jengkhaw95. A few issues though:
What do you think of setting the initial goal to 10 questions? Then we can describe what will happen when we have 10 approved questions. Maybe something like - "All users with at least one approved question get access to all other questions"?
|
ykdojo
left a comment
There was a problem hiding this comment.
(described my feedback in my earlier comment)
|
Yes, it makes sense that we start with 10 approved questions. Currently, I don't have any idea about separating the landing page and the progress bar section. |
|
@jengkhaw95 any updates? |
|
One idea: what if we pulled the progress bar all the way to the bottom? That way, we can have a white background there, and show the progress bar in its own distinct section - just an idea though. |
|
Like this: #303 |

🛠️ Fixes Issue
Closes #262
➕ Changes Introduced
Added a component
QuestionApprovalProgressBarSectionand placed it on the homepage.Count of the approved questions is fetched in a
useEffect(on mount) using supabase client in theQuestionApprovalProgressBarSectioncomponent.📄 Note To Reviewers
Inline style (width) is used on the progress bar element as a dynamic class name like:

w-[{currentPercentage}]does not work in tailwindcss JIT mode. ReferenceImplementation of a multi-step progress bar could be introduced in the future, as soon as the steps are defined. (Might require further discussion)
📷 Screenshots
Mobile View

Desktop View
