mirror of
https://gitlab.com/MrFry/qmining-data-editor
synced 2025-04-01 20:24:01 +02:00
Not forgetting search term on refresh, remove .ind parameter from data
This commit is contained in:
parent
760dfb0c4e
commit
3940800ace
2 changed files with 18 additions and 13 deletions
|
@ -5,7 +5,7 @@ import QuestionSearchResult from '../components/QuestionSearchResult.js'
|
|||
|
||||
import styles from './questionView.module.css'
|
||||
|
||||
export default function questionView (props) {
|
||||
export default function questionView(props) {
|
||||
const { data, onChange, deleteQuestion } = props
|
||||
const [searchTerm, setSearchTerm] = useState('')
|
||||
|
||||
|
@ -14,11 +14,13 @@ export default function questionView (props) {
|
|||
<div>
|
||||
<div className={styles.searchContainer}>
|
||||
<input
|
||||
placeholder='Keresés...'
|
||||
placeholder="Keresés..."
|
||||
className={styles.searchBar}
|
||||
type='text'
|
||||
type="text"
|
||||
value={searchTerm}
|
||||
onChange={(e) => { setSearchTerm(e.target.value) }}
|
||||
onChange={(e) => {
|
||||
setSearchTerm(e.target.value)
|
||||
}}
|
||||
/>
|
||||
<button
|
||||
onClick={() => {
|
||||
|
@ -26,7 +28,7 @@ export default function questionView (props) {
|
|||
}}
|
||||
className={styles.clearButton}
|
||||
>
|
||||
X
|
||||
X
|
||||
</button>
|
||||
</div>
|
||||
<hr />
|
||||
|
@ -41,8 +43,6 @@ export default function questionView (props) {
|
|||
</div>
|
||||
)
|
||||
} else {
|
||||
return (
|
||||
<LoadingIndicator />
|
||||
)
|
||||
return <LoadingIndicator />
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue