Merge pull request #1195 from pateljannat/issues-56
feat: load more in quiz list
This commit is contained in:
@@ -46,6 +46,11 @@
|
|||||||
</router-link>
|
</router-link>
|
||||||
</ListRows>
|
</ListRows>
|
||||||
</ListView>
|
</ListView>
|
||||||
|
<div class="flex justify-center my-5">
|
||||||
|
<Button v-if="quizzes.hasNextPage" @click="quizzes.next()">
|
||||||
|
{{ __('Load More') }}
|
||||||
|
</Button>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div
|
<div
|
||||||
v-else
|
v-else
|
||||||
@@ -67,13 +72,13 @@
|
|||||||
<script setup>
|
<script setup>
|
||||||
import {
|
import {
|
||||||
Breadcrumbs,
|
Breadcrumbs,
|
||||||
|
Button,
|
||||||
createListResource,
|
createListResource,
|
||||||
ListView,
|
ListView,
|
||||||
ListRows,
|
ListRows,
|
||||||
ListRow,
|
ListRow,
|
||||||
ListHeader,
|
ListHeader,
|
||||||
ListHeaderItem,
|
ListHeaderItem,
|
||||||
Button,
|
|
||||||
} from 'frappe-ui'
|
} from 'frappe-ui'
|
||||||
import { useRouter } from 'vue-router'
|
import { useRouter } from 'vue-router'
|
||||||
import { computed, inject, onMounted } from 'vue'
|
import { computed, inject, onMounted } from 'vue'
|
||||||
@@ -103,9 +108,6 @@ const quizzes = createListResource({
|
|||||||
auto: true,
|
auto: true,
|
||||||
cache: ['quizzes', user.data?.name],
|
cache: ['quizzes', user.data?.name],
|
||||||
orderBy: 'modified desc',
|
orderBy: 'modified desc',
|
||||||
onSuccess(data) {
|
|
||||||
data.forEach((row) => {})
|
|
||||||
},
|
|
||||||
})
|
})
|
||||||
|
|
||||||
const quizColumns = computed(() => {
|
const quizColumns = computed(() => {
|
||||||
|
|||||||
@@ -65,8 +65,6 @@ export class Markdown {
|
|||||||
} else if (previousLine && this.hasLink(previousLine)) {
|
} else if (previousLine && this.hasLink(previousLine)) {
|
||||||
const { text, url } = this.extractLink(previousLine)
|
const { text, url } = this.extractLink(previousLine)
|
||||||
const anchorTag = `<a href="${url}" target="_blank">${text}</a>`
|
const anchorTag = `<a href="${url}" target="_blank">${text}</a>`
|
||||||
console.log(previousLine.replace(/\[.+?\]\(.+?\)/, anchorTag))
|
|
||||||
debugger
|
|
||||||
this.convertBlock('paragraph', {
|
this.convertBlock('paragraph', {
|
||||||
text: previousLine.replace(/\[.+?\]\(.+?\)/, anchorTag),
|
text: previousLine.replace(/\[.+?\]\(.+?\)/, anchorTag),
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user