mirror of
https://gitlab.com/MrFry/qmining-page
synced 2025-04-01 20:23:44 +02:00
Merged subject browser / question searcher, showing questions count on subject browser
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
// TODO: add number next to it
|
||||
|
||||
import styles from './SubjectSelector.module.css'
|
||||
|
||||
export default function SubjectSelector (props) {
|
||||
const { activeSubjName, searchTerm, data, onSubjSelect } = props
|
||||
|
||||
@@ -19,7 +21,12 @@ export default function SubjectSelector (props) {
|
||||
key={i}
|
||||
onClick={() => onSubjSelect(subj.Name)}
|
||||
>
|
||||
{subj.Name}
|
||||
<span>
|
||||
{subj.Name}
|
||||
</span>
|
||||
<span className={styles.questionCount}>
|
||||
[ {subj.Questions.length} ]
|
||||
</span>
|
||||
</div>
|
||||
)
|
||||
})}
|
||||
|
@@ -9,7 +9,11 @@
|
||||
},
|
||||
"allQuestions": {
|
||||
"href": "/allQuestions",
|
||||
"text": "All question"
|
||||
"text": "Kérdés keresés"
|
||||
},
|
||||
"subjBrowser": {
|
||||
"href": "/subjectBrowser",
|
||||
"text": "Tárgyak"
|
||||
},
|
||||
"repos": {
|
||||
"href": "/repos",
|
||||
|
@@ -214,6 +214,9 @@ body {
|
||||
font-size: 18px;
|
||||
padding: 3px;
|
||||
cursor: pointer;
|
||||
float: 1;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
.activeSubjItem {
|
||||
|
Reference in New Issue
Block a user