Skip to content

Commit

Permalink
Merge pull request #4961 from KapuluruBhuvaneswariVspdbct/main
Browse files Browse the repository at this point in the history
  • Loading branch information
atmajaa authored Nov 10, 2024
2 parents 95f7174 + 3a03725 commit 878c200
Show file tree
Hide file tree
Showing 5 changed files with 312 additions and 0 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -240,6 +240,8 @@
│ │ ├── sciencea.html
│ │ ├── scienceq.html
│ │ ├── self-help.html
│ │ ├── selfa.html
│ │ ├── selfq.html
│ │ ├── settings.html
│ │ ├── social.html
│ │ ├── suspense-thriller.html
Expand Down
29 changes: 29 additions & 0 deletions assets/html/self-help.html
Original file line number Diff line number Diff line change
Expand Up @@ -1219,6 +1219,35 @@ <h1 class="heading">SelfHelp Books</h1>
<!-- Card Container -->

<h3>Explore each book further by clicking on the covers!</h3></div>

<style>
.butt{
margin-top:10px;
width:400px;
justify-content: center;
}
.buttt{
margin-top:10px;
width:400px;
justify-content: center;
}
a {
text-decoration: none; /* Default state */
}

a:hover {
text-decoration: none; /* Remove underline on hover */
}

</style>
<a href="selfq.html" onclick="lenis.scrollTo('#romanceq')" data-nav-link>
<button class="butt">Quiz</button>
</a>
<a href="selfa.html" onclick="lenis.scrollTo('#romancea')" data-nav-link>
<button class="buttt">Approach</button>
</a>


<div class="card-container" style="margin-top: -20px;">

<div class="card" onclick="this.classList.toggle('flip')">
Expand Down
93 changes: 93 additions & 0 deletions assets/html/selfa.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Approach to Reading Self-Help Books</title>
<style>
body {
font-family: Arial, sans-serif;
background-color: #eeacb7;
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
margin: 0;
}

.content-container {
background: white;
padding: 15px;
border-radius: 10px;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
width: 70%;
max-width: 800px;
text-align: center;
margin-top: 150px;
}

h2 {
margin-bottom: 15px;
}

h3 {
text-align: left;
margin-top: 20px;
}

p, ul {
text-align: left;
}

ul {
margin: 10px 0;
padding-left: 20px;
}

ul li {
margin: 8px 0;
}

button {
padding: 10px 20px;
margin-top: 20px;
cursor: pointer;
background-color: #006400;
color: white;
border: none;
border-radius: 5px;
font-size: 16px;
}

button:hover {
background-color: #004d00;
}
</style>
</head>
<body>

<div class="content-container">
<h2>How to Approach Reading Self-Help Books</h2>
<p>Self-help books offer insights and strategies for personal growth and improvement. Here are some tips for making the most of your reading:</p>
<ul>
<li><strong>Define Your Purpose:</strong> Know what areas you want to work on, such as productivity, mindset, or relationships. This will help you select books that meet your needs.</li>
<li><strong>Take Notes:</strong> Self-help books are often filled with actionable advice. Taking notes can help you remember key points and ideas to implement.</li>
<li><strong>Reflect and Apply:</strong> Don’t just read—pause and consider how each chapter’s lessons apply to your life, and commit to trying out the advice.</li>
<li><strong>Be Patient with the Process:</strong> Personal growth takes time. Be consistent in applying what you learn, and don’t rush the results.</li>
<li><strong>Revisit Your Favorites:</strong> Self-help books often offer new insights with each read. Revisiting them can reinforce ideas and provide fresh motivation.</li>
</ul>

<h3>Popular Self-Help Books</h3>
<ul>
<li><strong>Atomic Habits</strong> by James Clear – A guide to building good habits and breaking bad ones for a more productive life.</li>
<li><strong>The Power of Now</strong> by Eckhart Tolle – A book on mindfulness and living in the present moment.</li>
<li><strong>You Are a Badass</strong> by Jen Sincero – An uplifting book focused on boosting confidence and self-worth.</li>
<li><strong>The 7 Habits of Highly Effective People</strong> by Stephen Covey – A classic that covers timeless principles for success.</li>
<li><strong>Mindset: The New Psychology of Success</strong> by Carol S. Dweck – An exploration of the impact of having a growth mindset.</li>
</ul>

<button onclick="window.location.href='selfhelp.html';">Return to Home</button>
</div>

</body>
</html>
186 changes: 186 additions & 0 deletions assets/html/selfq.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,186 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Self-Help Books Quiz</title>
<style>
body {
font-family: Arial, sans-serif;
background-color: #ffc7d2;
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
margin: 0;
}

.quiz-container {
background: white;
padding: 20px;
border-radius: 10px;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
width: 300px;
text-align: center;
}

button {
padding: 10px 20px;
margin-top: 20px;
cursor: pointer;
background-color: #8e0013;
color: white;
border: none;
border-radius: 5px;
display: block;
width: 100%;
}

button:hover {
background-color: #004d00;
}

h4 {
margin: 10px 0;
}

.option {
margin: 5px 0;
}

.solution {
margin-top: 10px;
text-align: left;
}
</style>
</head>
<body>

<div class="quiz-container">
<h1>Self-Help Books Quiz</h1>
<div id="quiz-questions">
<!-- Questions will be inserted here -->
</div>
<button id="submit-button" onclick="submitQuiz()">Submit</button>
<div id="quiz-result" style="display: none;"></div>
<button id="home-button" style="display: none;" onclick="window.location.href='self-help.html';">Return to Home</button>
<button id="solutions-button" style="display: none;" onclick="showSolutions()">See Solutions</button>
</div>

<script>
const quizData = [
{
question: "Who wrote 'Atomic Habits'?",
options: ["James Clear", "Robin Sharma", "Stephen Covey", "Tony Robbins"],
answer: "James Clear"
},
{
question: "Which book emphasizes living in the present moment and letting go of the past?",
options: ["The Power of Now", "The 7 Habits of Highly Effective People", "Mindset: The Psychology of Success", "Atomic Habits"],
answer: "The Power of Now"
},
{
question: "In 'You Are a Badass', what does Jen Sincero encourage readers to trust?",
options: ["Their habits", "Their intuition", "Their financial skills", "Their external environment"],
answer: "Their intuition"
},
{
question: "Who is the author of 'The 7 Habits of Highly Effective People'?",
options: ["James Clear", "Jen Sincero", "Stephen Covey", "Carol Dweck"],
answer: "Stephen Covey"
},
{
question: "What concept does Carol Dweck's book 'Mindset' primarily focus on?",
options: ["Fixed and growth mindsets", "Atomic habits", "Emotional intelligence", "Power of now"],
answer: "Fixed and growth mindsets"
}
];

let currentQuestionIndex = 0;
let score = 0;

function loadQuestion() {
const questionElement = document.getElementById('quiz-questions');
questionElement.innerHTML = '';

const currentQuestion = quizData[currentQuestionIndex];
const questionText = document.createElement('h4');
questionText.innerText = currentQuestion.question;
questionElement.appendChild(questionText);

currentQuestion.options.forEach(option => {
const optionButton = document.createElement('button');
optionButton.classList.add('option');
optionButton.innerText = option;
optionButton.onclick = () => selectAnswer(option);
questionElement.appendChild(optionButton);
});
}

function selectAnswer(selectedOption) {
const currentQuestion = quizData[currentQuestionIndex];
if (selectedOption === currentQuestion.answer) {
score++;
}
currentQuestionIndex++;

if (currentQuestionIndex < quizData.length) {
loadQuestion();
} else {
showResult();
}
}

function showResult() {
const quizContainer = document.querySelector('.quiz-container');
quizContainer.innerHTML = `<h2>Your Score: ${score}/${quizData.length}</h2>`;

const homeButton = document.createElement('button');
homeButton.onclick = () => window.location.href = 'self-help.html';
homeButton.innerText = 'Return to Home';
quizContainer.appendChild(homeButton);

const solutionsButton = document.createElement('button');
solutionsButton.onclick = showSolutions;
solutionsButton.innerText = 'See Solutions';
quizContainer.appendChild(solutionsButton);
}

function showSolutions() {
const quizContainer = document.querySelector('.quiz-container');
quizContainer.innerHTML = '<h2>Quiz Solutions</h2>';

quizData.forEach((question, index) => {
const solutionElement = document.createElement('div');
solutionElement.classList.add('solution');

const questionText = document.createElement('h4');
questionText.innerText = `${index + 1}. ${question.question}`;
solutionElement.appendChild(questionText);

const correctAnswer = document.createElement('p');
correctAnswer.innerText = `Correct Answer: ${question.answer}`;
solutionElement.appendChild(correctAnswer);

quizContainer.appendChild(solutionElement);
});

const homeButton = document.createElement('button');
homeButton.onclick = () => window.location.href = 'self-help.html';
homeButton.innerText = 'Return to Home';
quizContainer.appendChild(homeButton);
}

function submitQuiz() {
if (currentQuestionIndex < quizData.length) {
alert("Please answer all questions before submitting!");
} else {
showResult();
}
}

document.addEventListener('DOMContentLoaded', loadQuestion);
</script>

</body>
</html>
2 changes: 2 additions & 0 deletions repo_structure.txt
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,8 @@
│ │ ├── sciencea.html
│ │ ├── scienceq.html
│ │ ├── self-help.html
│ │ ├── selfa.html
│ │ ├── selfq.html
│ │ ├── settings.html
│ │ ├── social.html
│ │ ├── suspense-thriller.html
Expand Down

0 comments on commit 878c200

Please sign in to comment.