Skip to content
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

HfNotes Component optimization done #1567

Merged
merged 2 commits into from
Aug 16, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions src/components/elements/HfNotes.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<template>
<p
class="my-4 border rounded-lg p-2 modal-text"
v-html="notes"
>
{{ notes }}
</p>
</template>

<script>
export default {
props: {
notes: String,
},
};
</script>

<style>
.modal-text {
font-size: 12px;
background: #f0f9ff;
Vishwas1 marked this conversation as resolved.
Show resolved Hide resolved
}
</style>
9 changes: 9 additions & 0 deletions src/utils/messages/admin/Notes.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
const LOTTERY_NOTES=`<b>Lottery</b> is the process of selecting winners of an event. Upon
clicking on "<b>Execute button</b>", the lottery process begins, which
may take sometime and screen may freeze. Once done, you will get
selected records in excel sheet. The winner selection is primarly based
on their "<b>score</b>" unless checked "<b>randomly</b>".`

module.exports={
LOTTERY_NOTES
}
20 changes: 5 additions & 15 deletions src/views/admin/Participants.vue
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,6 @@ label {
background-color: var(--button-bg-color);;
margin: 1px 0;
}
.modal-text {
font-size: 12px;
}
.projectSelector {
min-width: 220px;
max-width: 220px;
Expand Down Expand Up @@ -114,16 +111,7 @@ label {
></loading>

<b-modal hide-footer id="modal-1" title="Lottery">
<p
class="my-4 border rounded-lg p-2 modal-text"
style="background: #f0f9ff"
>
<b>Lottery</b> is the process of selecting winners of an event. Upon
clicking on "<b>Execute button</b>", the lottery process begins, which
may take sometime and screen may freeze. Once done, you will get
selected records in excel sheet. The winner selection is primarly based
on their "<b>score</b>" unless checked "<b>randomly</b>".
</p>
<hf-notes :notes="notes"></hf-notes>
<div class="d-flex mx-auto justify-content-between px-4">
<div class="bold">Total Records</div>
<div class="bold">{{ project.count }}</div>
Expand Down Expand Up @@ -259,10 +247,11 @@ import FileDownload from "js-file-download";
const issuedImgLink = require("../../assets/issued-icon.png");
import Messages from "../../utils/messages/admin/en";
import eventBus from "../../eventBus";

import HfNotes from '../../components/elements/HfNotes.vue';
const Notes = require("../../utils/messages/admin/Notes");
export default {
name: "Investor",
components: { Loading, Paginate },
components: { Loading, Paginate, HfNotes,Notes },
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why Notes is in component. ??

computed:{
buttonThemeCss() {
return {
Expand Down Expand Up @@ -403,6 +392,7 @@ computed:{
accessToken: localStorage.getItem("accessToken"),
isLoading: false,
fullPage: true,
notes:Notes.LOTTERY_NOTES
};
},

Expand Down