{"id":2651,"date":"2023-10-22T12:12:42","date_gmt":"2023-10-22T04:12:42","guid":{"rendered":"https:\/\/bookmark.tw\/?p=2651"},"modified":"2025-08-28T22:44:53","modified_gmt":"2025-08-28T14:44:53","slug":"your-life-attitude","status":"publish","type":"post","link":"https:\/\/xinliceyan.org\/zh\/your-life-attitude","title":{"rendered":"\u7ebf\u4e0a\u514d\u8d39\u6d4b\u9a8c\uff1a\u4e86\u89e3\u4f60\u7684\u4eba\u751f\u6001\u5ea6\uff0825\u9898\uff09"},"content":{"rendered":"<!-- \u5f15\u5165Bootstrap CSS -->\n<link href=\"https:\/\/cdnjs.cloudflare.com\/ajax\/libs\/bootstrap\/5.3.3\/css\/bootstrap.min.css\" rel=\"stylesheet\">\n<link href=\"https:\/\/cdnjs.cloudflare.com\/ajax\/libs\/bootstrap-icons\/1.11.3\/font\/bootstrap-icons.min.css\" rel=\"stylesheet\">\n\n<!-- \u6e2c\u9a57\u5bb9\u5668 -->\n<div class=\"container py-4\" id=\"lifeAttitudeQuiz9\">\n  \n  <!-- \u5f15\u5c0e\u9801 -->\n  <section id=\"quizintro9\" data-page=\"intro9\" class=\"row justify-content-center\">\n    <div class=\"col-12 col-lg-10\">\n      <header class=\"text-center mb-5\">\n        <h2 class=\"display-4 fw-bold text-primary mb-3\">\u77ad\u89e3\u4f60\u7684\u4eba\u751f\u614b\u5ea6<\/h2>\n        <p class=\"lead text-muted\">\u63a2\u7d22\u4f60\u5c0d\u751f\u6d3b\u7684\u614b\u5ea6\uff0c\u767c\u73fe\u771f\u5be6\u7684\u81ea\u5df1<\/p>\n      <\/header>\n      \n      <div class=\"row g-4 mb-5\">\n        <div class=\"col-md-4\">\n          <div class=\"card h-100 border-0 shadow-sm hover-lift\">\n            <div class=\"card-body text-center p-4\">\n              <div class=\"rounded-circle bg-primary bg-opacity-10 p-3 d-inline-flex mb-3\">\n                <i class=\"bi bi-clock-history fs-1 text-primary\"><\/i>\n              <\/div>\n              <h3 class=\"h5 fw-bold mb-3\">\u5feb\u901f\u8bc4\u4f30<\/h3>\n              <p class=\"text-muted mb-0\">\u50c5\u9700\u5e7e\u5206\u9418\uff0c\u7372\u5f97\u5168\u9762\u8a55\u4f30<\/p>\n            <\/div>\n          <\/div>\n        <\/div>\n        \n        <div class=\"col-md-4\">\n          <div class=\"card h-100 border-0 shadow-sm hover-lift\">\n            <div class=\"card-body text-center p-4\">\n              <div class=\"rounded-circle bg-success bg-opacity-10 p-3 d-inline-flex mb-3\">\n                <i class=\"bi bi-graph-up fs-1 text-success\"><\/i>\n              <\/div>\n              <h3 class=\"h5 fw-bold mb-3\">\u79d1\u5b66\u6d4b\u9a8c<\/h3>\n              <p class=\"text-muted mb-0\">\u57fa\u65bc\u5fc3\u7406\u5b78\u79d1\u5b78\u7814\u7a76<\/p>\n            <\/div>\n          <\/div>\n        <\/div>\n        \n        <div class=\"col-md-4\">\n          <div class=\"card h-100 border-0 shadow-sm hover-lift\">\n            <div class=\"card-body text-center p-4\">\n              <div class=\"rounded-circle bg-info bg-opacity-10 p-3 d-inline-flex mb-3\">\n                <i class=\"bi bi-lightbulb fs-1 text-info\"><\/i>\n              <\/div>\n              <h3 class=\"h5 fw-bold mb-3\">\u6df1\u5ea6\u6d1e\u5bdf<\/h3>\n              <p class=\"text-muted mb-0\">\u7372\u5f97\u8a73\u7d30\u5206\u6790\u8207\u5efa\u8b70<\/p>\n            <\/div>\n          <\/div>\n        <\/div>\n      <\/div>\n      \n      <article class=\"bg-light rounded-4 p-4 mb-5\">\n        <p class=\"mb-3\">\u5fc3\u7406\u5b66\u7814\u7a76\u53d1\u73b0\uff0c\u6211\u4eec\u7684\u6001\u5ea6\u901a\u5e38\u662f\u88ab\u5176\u4ed6\u4eba\u6ce8\u610f\u5230\uff0c\u800c\u4e0d\u662f\u6211\u4eec\u81ea\u5df1\u3002\u5728\u5f88\u591a\u60c5\u51b5\u4e0b\uff0c\u4e00\u4e2a\u4eba\u7684\u6001\u5ea6\u662f\u7531\u4ed6\u7684\u4e2a\u6027\u6240\u5f62\u6210\u7684\u4e00\u79cd\u81ea\u7136\u5c5e\u6027\u3002\u4f46\u662f\uff0c\u5b83\u6d89\u53ca\u7684\u8303\u56f4\u5f88\u5e7f\uff0c\u5e76\u4e14\u5f88\u96be\u5b9a\u4e49\u3002\u6ca1\u6709\u8c01\u4ece\u4e00\u51fa\u751f\u5c31\u6709\u6001\u5ea6\uff0c\u6001\u5ea6\u53ef\u4ee5\u901a\u8fc7\u5f88\u591a\u79cd\u65b9\u5f0f\u5f62\u6210\u3002<\/p>\n        \n        <p class=\"mb-3\">\u4e00\u4e2a\u4eba\u7684\u6001\u5ea6\u8fd8\u4f1a\u7531\u4e8e\u5177\u4f53\u60c5\u51b5\u548c\u5916\u754c\u56e0\u7d20\u7684\u53d8\u5316\u800c\u6539\u53d8\uff0c\u8fd9\u4e9b\u53d8\u5316\u53ef\u4ee5\u4ea7\u751f\u79ef\u6781\u7684\u3001\u597d\u7684\u6001\u5ea6\uff0c\u4e5f\u53ef\u80fd\u4ea7\u751f\u6d88\u6781\u7684\u3001\u574f\u7684\u6001\u5ea6\u3002\u6709\u65f6\uff0c\u6539\u53d8\u4e00\u4e2a\u4eba\u6001\u5ea6\u7684\u4f01\u56fe\u53ef\u4ee5\u751f\u6548\uff0c\u4f46\u6709\u65f6\u53ef\u80fd\u4f1a\u9002\u5f97\u5176\u53cd\uff0c\u81f4\u4f7f\u5176\u6001\u5ea6\u5411\u76f8\u53cd\u7684\u65b9\u5411\u8f6c\u53d8\u3002\u6211\u4eec\u5bf9\u81ea\u5df1\u7684\u6001\u5ea6\u4e86\u89e3\u5f97\u8d8a\u591a\uff0c\u6211\u4eec\u5c31\u6709\u66f4\u591a\u7684\u673a\u4f1a\u5c06\u81ea\u5df1\u7684\u6d88\u6781\u6001\u5ea6\u6539\u53d8\u4e3a\u79ef\u6781\u7684\u6001\u5ea6\u3002<\/p>\n        \n        <p class=\"mb-0\">\u901a\u904e\u614b\u5ea6\uff0c\u53ef\u4ee5\u8868\u73fe\u51fa\u4e00\u500b\u4eba\u7684\u50f9\u503c\uff0c\u5176\u4ed6\u4eba\u5c31\u53ef\u4ee5\u77e5\u9053\u4f60\u662f\u4ec0\u9ebc\u6a23\u7684\u4eba\u3002\u5982\u679c\u6c92\u6709\u4eba\u544a\u8a34\u4f60\uff0c\u4f60\u662f\u4ec0\u9ebc\u6a23\u7684\u4eba\uff0c\u90a3\u9ebc\u4ee5\u4e0b\u7684\u6e2c\u8a66\u53ef\u4ee5\u505a\u5230\u9019\u4e00\u9ede\u3002<\/p>\n      <\/article>\n      \n      <div class=\"text-center\">\n        <button class=\"btn btn-primary btn-lg px-5 py-3 rounded-pill shadow\" data-action=\"start-quiz\">\n          <span class=\"me-2\">\u5f00\u59cb\u6d4b\u9a8c<\/span>\n          <i class=\"bi bi-arrow-right-circle\"><\/i>\n        <\/button>\n      <\/div>\n    <\/div>\n  <\/section>\n\n  <!-- \u6e2c\u8a66\u9801 -->\n  <section id=\"quizmain9\" data-page=\"quiz9\" class=\"row justify-content-center d-none\">\n    <div class=\"col-12 col-lg-8\">\n      <header class=\"text-center mb-4\">\n        <h2 class=\"h1 fw-bold text-primary\">\u4eba\u751f\u614b\u5ea6\u6e2c\u9a57<\/h2>\n      <\/header>\n      \n      <div class=\"mb-4\">\n        <div class=\"d-flex justify-content-between align-items-center mb-2\">\n          <span class=\"text-muted fw-semibold\" data-element=\"progress-text\">\u95ee\u98981\/25<\/span>\n          <span class=\"text-muted fw-semibold\" data-element=\"progress-percent\">4%<\/span>\n        <\/div>\n        <div class=\"progress\" style=\"height: 8px;\">\n          <div class=\"progress-bar bg-gradient\" data-element=\"progress-bar\" style=\"width: 4%;\" role=\"progressbar\" aria-valuenow=\"4\" aria-valuemin=\"0\" aria-valuemax=\"100\"><\/div>\n        <\/div>\n      <\/div>\n      \n      <div class=\"card border-0 shadow-sm mb-4\">\n        <div class=\"card-body p-4\">\n          <h3 class=\"fw-bold mb-4\" data-element=\"question-text\" style=\"font-size: 22px;\">\u8f09\u5165\u4e2d&#8230;<\/h3>\n          <div data-element=\"options-container\">\n            <!-- \u9078\u9805\u5c07\u52d5\u614b\u751f\u6210 -->\n          <\/div>\n        <\/div>\n      <\/div>\n      \n      <div class=\"text-center\">\n        <button class=\"btn btn-outline-secondary px-4 py-2 d-none\" data-action=\"prev-question\">\n          <i class=\"bi bi-arrow-left me-2\"><\/i>\u4e0a\u4e00\u9898\n        <\/button>\n      <\/div>\n    <\/div>\n  <\/section>\n\n  <!-- \u7d50\u679c\u9801 -->\n  <section id=\"quizresult9\" data-page=\"result9\" class=\"row justify-content-center d-none\">\n    <div class=\"col-12 col-lg-10\">\n      <header class=\"text-center mb-5\">\n        <h2 class=\"display-5 fw-bold text-primary\">\u6d4b\u9a8c\u7ed3\u679c<\/h2>\n      <\/header>\n      \n      <div class=\"row mb-5\">\n        <div class=\"col-md-6 mb-4\">\n          <div class=\"card border-0 shadow-sm h-100\">\n            <div class=\"card-body text-center p-4\">\n              <h3 class=\"h5 fw-bold mb-3\">\u60a8\u7684\u4eba\u751f\u614b\u5ea6\u5f97\u5206<\/h3>\n              <div class=\"display-1 fw-bold text-primary mb-3\" data-element=\"total-score\">0<\/div>\n              <div style=\"max-width: 300px; height: 300px; margin: 0 auto;\">\n                <canvas id=\"scoreChart9\"><\/canvas>\n              <\/div>\n            <\/div>\n          <\/div>\n        <\/div>\n        \n        <div class=\"col-md-6 mb-4\">\n          <div class=\"card border-0 shadow-sm h-100\">\n            <div class=\"card-body p-4\">\n              <h3 class=\"h5 fw-bold mb-3 text-center\">\u591a\u7ef4\u5ea6\u5206\u6790<\/h3>\n              <div style=\"max-width: 350px; height: 350px; margin: 0 auto;\">\n                <canvas id=\"dimensionChart9\"><\/canvas>\n              <\/div>\n            <\/div>\n          <\/div>\n        <\/div>\n      <\/div>\n      \n      <div class=\"card border-0 shadow-sm mb-4\">\n        <div class=\"card-body p-4\" data-element=\"analysis\">\n          <!-- \u5206\u6790\u5167\u5bb9\u5c07\u52d5\u614b\u751f\u6210 -->\n        <\/div>\n      <\/div>\n      \n      <div class=\"card border-0 shadow-sm mb-5\">\n        <div class=\"card-body p-4\" data-element=\"advice\">\n          <!-- \u5efa\u8b70\u5167\u5bb9\u5c07\u52d5\u614b\u751f\u6210 -->\n        <\/div>\n      <\/div>\n      \n      <div class=\"text-center\">\n        <button class=\"btn btn-primary btn-lg px-5 py-3 rounded-pill shadow\" data-action=\"restart-quiz\">\n          <i class=\"bi bi-arrow-clockwise me-2\"><\/i>\n          \u91cd\u65b0\u6d4b\u8bd5\n        <\/button>\n      <\/div>\n    <\/div>\n  <\/section>\n<\/div>\n\n<!-- \u6a23\u5f0f\u90e8\u5206 -->\n<style>\n  #lifeAttitudeQuiz9 {\n    font-size: 18px;\n    color: #333;\n  }\n  \n  #lifeAttitudeQuiz9 .hover-lift {\n    transition: transform 0.3s ease, box-shadow 0.3s ease;\n  }\n  \n  #lifeAttitudeQuiz9 .hover-lift:hover {\n    transform: translateY(-5px);\n    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15) !important;\n  }\n  \n  #lifeAttitudeQuiz9 .option-card {\n    cursor: pointer;\n    transition: all 0.3s ease;\n    border: 2px solid #dee2e6;\n    background: #fff;\n  }\n  \n  #lifeAttitudeQuiz9 .option-card:hover {\n    border-color: #86b7fe;\n    background-color: #f8f9fa;\n  }\n  \n  #lifeAttitudeQuiz9 .option-card.selected {\n    border-color: #0d6efd;\n    background-color: #e7f1ff;\n  }\n  \n  #lifeAttitudeQuiz9 .option-indicator {\n    width: 24px;\n    height: 24px;\n    border: 2px solid #6c757d;\n    border-radius: 50%;\n    transition: all 0.3s ease;\n    flex-shrink: 0;\n  }\n  \n  #lifeAttitudeQuiz9 .option-card:hover .option-indicator {\n    border-color: #0d6efd;\n  }\n  \n  #lifeAttitudeQuiz9 .option-card.selected .option-indicator {\n    background-color: #0d6efd;\n    border-color: #0d6efd;\n  }\n  \n  #lifeAttitudeQuiz9 .option-card.selected .option-indicator::after {\n    content: '\u2713';\n    color: white;\n    display: block;\n    text-align: center;\n    line-height: 20px;\n    font-size: 14px;\n  }\n  \n  #lifeAttitudeQuiz9 .advice-item {\n    padding: 12px 16px;\n    background: #f8f9fa;\n    border-radius: 8px;\n    margin-bottom: 12px;\n    border-left: 4px solid #0d6efd;\n  }\n  \n  @media (max-width: 768px) {\n    #lifeAttitudeQuiz9 {\n      font-size: 16px;\n    }\n    \n    #lifeAttitudeQuiz9 h2 {\n      font-size: 1.75rem !important;\n    }\n    \n    #lifeAttitudeQuiz9 h3 {\n      font-size: 20px !important;\n    }\n  }\n<\/style>\n\n<!-- JavaScript\u90e8\u5206 -->\n<script src=\"https:\/\/cdnjs.cloudflare.com\/ajax\/libs\/Chart.js\/4.4.1\/chart.umd.min.js\"><\/script>\n<script>\n(function() {\n  'use strict';\n  \n  \/\/ \u6e2c\u9a57\u6578\u64da\n  const quizData = {\n    questions: [\n      \"\u6211\u70ba\u81ea\u5df1\u7684\u7956\u570b\u800c\u9a55\u50b2\u3002\",\n      \"\u4eba\u5011\u57fa\u672c\u4e0a\u662f\u6b63\u6d3e\u7684\u3002\",\n      \"\u6211\u5c0d\u81ea\u5df1\u4ee5\u53ca\u81ea\u5df1\u7684\u4fe1\u4ef0\u5341\u5206\u5766\u7387\u548c\u516c\u6b63\u3002\",\n      \"\u7576\u770b\u5230\u6709\u4e9b\u4eba\u56e0\u5faa\u5b88\u820a\u6642\uff0c\u6211\u975e\u5e38\u751f\u6c23\u3002\",\n      \"\u6211\u76e1\u91cf\u5c0d\u4efb\u4f55\u4eba\u90fd\u4e00\u8996\u540c\u4ec1\uff0c\u4e0d\u7ba1\u4ed6\u5011\u7684\u51fa\u8eab\u548c\u8eab\u4efd\u5982\u4f55\u3002\",\n      \"\u6211\u76f8\u4fe1\u57fa\u672c\u539f\u5247\uff1a\u9867\u5ba2\u6c38\u9060\u662f\u6b63\u78ba\u7684\u3002\",\n      \"\u6211\u5011\u5c0d\u4e16\u754c\u4ee5\u53ca\u4e16\u754c\u4e0a\u7684\u4eba\u77ad\u89e3\u5f97\u8d8a\u591a\uff0c\u90a3\u9ebc\u6211\u5011\u7684\u4e16\u754c\u5c07\u8b8a\u5f97\u66f4\u5b89\u5168\u3002\",\n      \"\u6211\u52aa\u529b\u53bb\u7406\u89e3\u5176\u4ed6\u4eba\u7684\u89c0\u9ede\u3002\",\n      \"\u6211\u5f9e\u4e0d\u6028\u5929\u5c24\u4eba\u3002\",\n      \"\u6211\u52aa\u529b\u5730\u8b93\u81ea\u5df1\u8655\u65bc\u826f\u597d\u7684\u7cbe\u795e\u72c0\u614b\u3002\",\n      \"\u7e3d\u7684\u4f86\u8aaa\uff0c\u4eba\u5011\u7e3d\u662f\u76e1\u529b\u8b93\u81ea\u5df1\u4ea4\u597d\u904b\u3002\",\n      \"\u80fd\u8b93\u6211\u6f88\u5e95\u76f8\u4fe1\u7684\u4eba\u5c48\u6307\u53ef\u6578\u3002\",\n      \"\u6211\u5f88\u5bb9\u6613\u5fd8\u8a18\u4e26\u4e14\u4e0d\u8a08\u8f03\u500b\u4eba\u6069\u6028\u3002\",\n      \"\u6211\u5e0c\u671b\u80fd\u77ad\u89e3\u5176\u4ed6\u4eba\u7684\u60f3\u6cd5\u3002\",\n      \"\u5982\u679c\u6211\u770b\u5230\u5546\u5e97\u88e1\u51fa\u552e\u904e\u671f\u7684\u98df\u54c1\uff0c\u6211\u6703\u544a\u8a34\u5e97\u4e3b\u7684\u3002\",\n      \"\u7236\u6bcd\u89aa\u65e9\u5c31\u61c9\u8a72\u6559\u6703\u5b69\u5b50\u660e\u767d\u662f\u975e\u3002\",\n      \"\u6211\u70ba\u7576\u4eca\u793e\u6703\u7684\u72af\u7f6a\u548c\u66b4\u529b\u60c5\u6cc1\u611f\u5230\u64d4\u6182\u3002\",\n      \"\u70ba\u4e86\u505a\u597d\u81ea\u5df1\u7684\u672c\u8077\u5de5\u4f5c\uff0c\u6211\u5168\u529b\u4ee5\u8d74\u3002\",\n      \"\u6211\u4e00\u76f4\u5728\u5c55\u671b\u4e26\u4e14\u8a08\u756b\u672a\u4f86\u3002\",\n      \"\u7576\u5176\u4ed6\u4eba\u559c\u6b61\u4e26\u4e14\u5c0a\u91cd\u6211\u6642\uff0c\u6211\u611f\u5230\u5f88\u9ad8\u8208\u3002\",\n      \"\u5728\u8d70\u8def\u6216\u8005\u7ad9\u7acb\u6642\uff0c\u6211\u5f88\u5c11\u5c07\u624b\u63d2\u5728\u515c\u91cc\u3002\",\n      \"\u6211\u6bd4\u6211\u8a8d\u8b58\u7684\u5927\u591a\u6578\u4eba\u66f4\u559c\u6b61\u5fae\u7b11\u3002\",\n      \"\u5728\u7d55\u5927\u591a\u6578\u6642\u5019\uff0c\u6211\u7e3d\u662f\u8b93\u81ea\u5df1\u7684\u623f\u5b50\u548c\u82b1\u5712\u4fdd\u6301\u6574\u6f54\u3002\",\n      \"\u6211\u559c\u6b61\u53d6\u6085\u5225\u4eba\u3002\",\n      \"\u5728\u7b2c\u4e00\u6b21\u8207\u964c\u751f\u4eba\u6703\u9762\u6642\uff0c\u6211\u7e3d\u662f\u76e1\u91cf\u907f\u514d\u4ee5\u8c8c\u53d6\u4eba\u3002\"\n    ],\n    options: [\n      { value: 5, text: \"\u975e\u5e38\u4e0d\u7b26\u5408\" },\n      { value: 4, text: \"\u4e0d\u7b26\u5408\" },\n      { value: 3, text: \"\u4e00\u822c\" },\n      { value: 2, text: \"\u7b26\u5408\" },\n      { value: 1, text: \"\u975e\u5e38\u7b26\u5408\" }\n    ],\n    dimensions: {\n      selfAwareness: { \n        name: \"\u81ea\u6211\u610f\u8b58\", \n        questions: [2, 8, 9, 12, 21],\n        color: 'rgba(75, 192, 192, 0.8)'\n      },\n      socialRelations: { \n        name: \"\u793e\u4ea4\u95dc\u4fc2\", \n        questions: [4, 7, 13, 19, 23, 24],\n        color: 'rgba(54, 162, 235, 0.8)'\n      },\n      worldView: { \n        name: \"\u4e16\u754c\u89c0\", \n        questions: [0, 1, 3, 5, 6, 10, 11, 16],\n        color: 'rgba(153, 102, 255, 0.8)'\n      },\n      responsibility: { \n        name: \"\u8cac\u4efb\u611f\", \n        questions: [14, 15, 17, 18, 20, 22],\n        color: 'rgba(255, 159, 64, 0.8)'\n      }\n    }\n  };\n  \n  \/\/ \u6e2c\u9a57\u7ba1\u7406\u985e\n  class LifeAttitudeQuiz {\n    constructor() {\n      this.currentQuestion = 0;\n      this.answers = [];\n      this.charts = {};\n      this.initElements();\n      this.initEventListeners();\n    }\n    \n    initElements() {\n      this.elements = {\n        container: document.getElementById('lifeAttitudeQuiz9'),\n        introSection: document.getElementById('quizintro9'),\n        quizSection: document.getElementById('quizmain9'),\n        resultSection: document.getElementById('quizresult9'),\n        progressBar: document.querySelector('[data-element=\"progress-bar\"]'),\n        progressText: document.querySelector('[data-element=\"progress-text\"]'),\n        progressPercent: document.querySelector('[data-element=\"progress-percent\"]'),\n        questionText: document.querySelector('[data-element=\"question-text\"]'),\n        optionsContainer: document.querySelector('[data-element=\"options-container\"]'),\n        totalScore: document.querySelector('[data-element=\"total-score\"]'),\n        analysis: document.querySelector('[data-element=\"analysis\"]'),\n        advice: document.querySelector('[data-element=\"advice\"]')\n      };\n    }\n    \n    initEventListeners() {\n      \/\/ \u958b\u59cb\u6e2c\u9a57\n      document.querySelector('[data-action=\"start-quiz\"]').addEventListener('click', () => this.startQuiz());\n      \n      \/\/ \u4e0a\u4e00\u984c\n      document.querySelector('[data-action=\"prev-question\"]').addEventListener('click', () => this.previousQuestion());\n      \n      \/\/ \u91cd\u65b0\u6e2c\u8a66\n      document.querySelector('[data-action=\"restart-quiz\"]').addEventListener('click', () => this.restartQuiz());\n    }\n    \n    startQuiz() {\n      this.currentQuestion = 0;\n      this.answers = [];\n      this.showSection('quiz');\n      this.displayQuestion();\n    }\n    \n    showSection(section) {\n      \/\/ \u96b1\u85cf\u6240\u6709\u90e8\u5206\n      this.elements.introSection.classList.add('d-none');\n      this.elements.quizSection.classList.add('d-none');\n      this.elements.resultSection.classList.add('d-none');\n      \n      \/\/ \u986f\u793a\u6307\u5b9a\u90e8\u5206\n      switch(section) {\n        case 'intro':\n          this.elements.introSection.classList.remove('d-none');\n          break;\n        case 'quiz':\n          this.elements.quizSection.classList.remove('d-none');\n          break;\n        case 'result':\n          this.elements.resultSection.classList.remove('d-none');\n          break;\n      }\n      \n      \/\/ \u6efe\u52d5\u5230\u9802\u90e8\n      window.scrollTo({ top: this.elements.container.offsetTop - 20, behavior: 'smooth' });\n    }\n    \n    displayQuestion() {\n      const question = quizData.questions[this.currentQuestion];\n      const progress = ((this.currentQuestion + 1) \/ quizData.questions.length) * 100;\n      \n      \/\/ \u66f4\u65b0\u9032\u5ea6\n      this.elements.progressBar.style.width = progress + '%';\n      this.elements.progressBar.setAttribute('aria-valuenow', progress);\n      this.elements.progressText.textContent = `\u554f\u984c ${this.currentQuestion + 1}\/${quizData.questions.length}`;\n      this.elements.progressPercent.textContent = Math.round(progress) + '%';\n      \n      \/\/ \u66f4\u65b0\u554f\u984c\n      this.elements.questionText.textContent = `${this.currentQuestion + 1}. ${question}`;\n      \n      \/\/ \u751f\u6210\u9078\u9805\n      this.elements.optionsContainer.innerHTML = '';\n      quizData.options.forEach((option, index) => {\n        const optionCard = document.createElement('div');\n        optionCard.className = 'option-card rounded-3 p-3 mb-3 d-flex align-items-center';\n        \n        \/\/ \u6aa2\u67e5\u662f\u5426\u5df2\u9078\u64c7\n        if (this.answers[this.currentQuestion] === option.value) {\n          optionCard.classList.add('selected');\n        }\n        \n        optionCard.innerHTML = `\n          <div class=\"option-indicator me-3\"><\/div>\n          <span style=\"font-size: 18px; color: #333;\">${option.text}<\/span>\n        `;\n        \n        optionCard.addEventListener('click', () => this.selectOption(option.value));\n        this.elements.optionsContainer.appendChild(optionCard);\n      });\n      \n      \/\/ \u66f4\u65b0\u4e0a\u4e00\u984c\u6309\u9215\n      const prevBtn = document.querySelector('[data-action=\"prev-question\"]');\n      if (this.currentQuestion === 0) {\n        prevBtn.classList.add('d-none');\n      } else {\n        prevBtn.classList.remove('d-none');\n      }\n    }\n    \n    selectOption(value) {\n      this.answers[this.currentQuestion] = value;\n      \n      \/\/ \u66f4\u65b0\u9078\u9805\u72c0\u614b\n      const options = this.elements.optionsContainer.querySelectorAll('.option-card');\n      options.forEach((option, index) => {\n        if (quizData.options[index].value === value) {\n          option.classList.add('selected');\n        } else {\n          option.classList.remove('selected');\n        }\n      });\n      \n      \/\/ \u5ef6\u9072\u9032\u5165\u4e0b\u4e00\u984c\n      setTimeout(() => {\n        if (this.currentQuestion < quizData.questions.length - 1) {\n          this.currentQuestion++;\n          this.displayQuestion();\n        } else {\n          this.showResults();\n        }\n      }, 300);\n    }\n    \n    previousQuestion() {\n      if (this.currentQuestion > 0) {\n        this.currentQuestion--;\n        this.displayQuestion();\n      }\n    }\n    \n    showResults() {\n      const totalScore = this.calculateTotalScore();\n      const dimensionScores = this.calculateDimensionScores();\n      \n      this.elements.totalScore.textContent = totalScore;\n      this.generateAnalysis(totalScore);\n      this.generateAdvice(dimensionScores);\n      \n      this.showSection('result');\n      \n      \/\/ \u5ef6\u9072\u5275\u5efa\u5716\u8868\u4ee5\u78ba\u4fdd\u5bb9\u5668\u53ef\u898b\n      setTimeout(() => {\n        this.createCharts(totalScore, dimensionScores);\n      }, 100);\n    }\n    \n    calculateTotalScore() {\n      return this.answers.reduce((sum, value) => sum + value, 0);\n    }\n    \n    calculateDimensionScores() {\n      const scores = {};\n      \n      Object.entries(quizData.dimensions).forEach(([key, dimension]) => {\n        let score = 0;\n        dimension.questions.forEach(qIndex => {\n          score += this.answers[qIndex] || 0;\n        });\n        const maxScore = dimension.questions.length * 5;\n        scores[key] = {\n          name: dimension.name,\n          score: score,\n          percentage: (score \/ maxScore) * 100,\n          color: dimension.color\n        };\n      });\n      \n      return scores;\n    }\n    \n    createCharts(totalScore, dimensionScores) {\n      \/\/ \u92b7\u6bc0\u73fe\u6709\u5716\u8868\n      Object.values(this.charts).forEach(chart => chart.destroy());\n      this.charts = {};\n      \n      \/\/ \u5275\u5efa\u7e3d\u5206\u5716\u8868\n      const scoreCtx = document.getElementById('scoreChart9').getContext('2d');\n      const percentage = (totalScore \/ 125) * 100;\n      \n      this.charts.score = new Chart(scoreCtx, {\n        type: 'doughnut',\n        data: {\n          labels: ['\u7a4d\u6975\u614b\u5ea6', '\u5f85\u6539\u9032'],\n          datasets: [{\n            data: [percentage, 100 - percentage],\n            backgroundColor: [\n              'rgba(34, 139, 34, 0.8)',\n              'rgba(220, 220, 220, 0.5)'\n            ],\n            borderWidth: 0\n          }]\n        },\n        options: {\n          responsive: true,\n          maintainAspectRatio: false,\n          plugins: {\n            legend: {\n              position: 'bottom',\n              labels: {\n                font: { size: 18 },\n                padding: 15\n              }\n            },\n            tooltip: {\n              callbacks: {\n                label: (context) => `${context.label}: ${Math.round(context.raw)}%`\n              },\n              titleFont: { size: 16 },\n              bodyFont: { size: 16 }\n            }\n          }\n        }\n      });\n      \n      \/\/ \u5275\u5efa\u7dad\u5ea6\u96f7\u9054\u5716\n      const dimensionCtx = document.getElementById('dimensionChart9').getContext('2d');\n      const labels = Object.values(dimensionScores).map(d => d.name);\n      const data = Object.values(dimensionScores).map(d => d.percentage);\n      \n      this.charts.dimension = new Chart(dimensionCtx, {\n        type: 'radar',\n        data: {\n          labels: labels,\n          datasets: [{\n            label: '\u60a8\u7684\u5206\u6578',\n            data: data,\n            backgroundColor: 'rgba(75, 192, 192, 0.2)',\n            borderColor: 'rgba(75, 192, 192, 1)',\n            pointBackgroundColor: 'rgba(75, 192, 192, 1)',\n            pointBorderColor: '#fff',\n            borderWidth: 2,\n            pointRadius: 5\n          }]\n        },\n        options: {\n          responsive: true,\n          maintainAspectRatio: false,\n          scales: {\n            r: {\n              min: 0,\n              max: 100,\n              ticks: {\n                stepSize: 20,\n                font: { size: 14 }\n              },\n              pointLabels: {\n                font: { size: 18, weight: 'bold' }\n              }\n            }\n          },\n          plugins: {\n            legend: { display: false },\n            tooltip: {\n              titleFont: { size: 16 },\n              bodyFont: { size: 16 }\n            }\n          }\n        }\n      });\n    }\n    \n    generateAnalysis(score) {\n      let analysisHTML = '';\n      \n      if (score < 65) {\n        analysisHTML = `\n          <h3 class=\"h4 fw-bold mb-3\">\u614b\u5ea6\u9700\u8981\u6539\u9032\uff08\u5f97\u5206\uff1a${score}\uff09<\/h3>\n          <p>\u4f60\u5728\u67d0\u4e9b\u65b9\u9762\u5b58\u5728\u614b\u5ea6\u554f\u984c\uff0c\u56e0\u6b64\uff0c\u6709\u91dd\u5c0d\u6027\u5730\u5206\u6790\u672c\u6e2c\u8a66\u984c\u4e2d\u7684\u67d0\u4e9b\u500b\u5225\u554f\u984c\uff0c\u5c24\u5176\u662f\u90a3\u4e9b\u5f97\u5206\u4f4e\u65bc3\u5206\u7684\u554f\u984c\uff0c\u5c07\u6703\u5f88\u6709\u50f9\u503c\u3002\u5728\u9019\u4e9b\u554f\u984c\u4e0a\uff0c\u4f60\u53ef\u80fd\u6709\u5fc5\u8981\u518d\u8003\u616e\u4e00\u4e0b\u81ea\u5df1\u7684\u614b\u5ea6\uff0c\u4e26\u4e14\u722d\u53d6\u6539\u9032\u3002<\/p>\n          <p>\u614b\u5ea6\u5728\u73fe\u4ee3\u751f\u6d3b\u4e2d\u6b63\u8b8a\u5f97\u8d8a\u4f86\u8d8a\u91cd\u8981\u3002\u614b\u5ea6\u53ef\u4ee5\u7528\u4f86\u7d44\u7e54\u6211\u5011\u6240\u7a4d\u7d2f\u7684\u6240\u6709\u77e5\u8b58\uff0c\u800c\u4e14\u4ee5\u9019\u7a2e\u65b9\u5f0f\u4f7f\u7528\u8cc7\u8a0a\u80fd\u5920\u5e6b\u52a9\u6211\u5011\u66f4\u597d\u5730\u7406\u89e3\u9019\u500b\u4e16\u754c\u3002<\/p>\n        `;\n      } else if (score < 90) {\n        analysisHTML = `\n          <h3 class=\"h4 fw-bold mb-3\">\u826f\u597d\u7684\u614b\u5ea6\uff08\u5f97\u5206\uff1a${score}\uff09<\/h3>\n          <p>\u4f60\u5728\u5927\u591a\u6578\u6642\u5019\u614b\u5ea6\u7aef\u6b63\uff0c\u4f46\u662f\u4f60\u4ecd\u7136\u53ef\u4ee5\u6709\u6240\u6539\u9032\u3002\u5118\u7ba1\u4f60\u4e0d\u5b58\u5728\u614b\u5ea6\u554f\u984c\uff0c\u4f46\u662f\u5982\u679c\u4f60\u80fd\u5920\u7d93\u5e38\u9032\u884c\u81ea\u6211\u5206\u6790\uff0c\u90a3\u5c07\u662f\u5f88\u6709\u76ca\u7684\u935b\u934a\u3002<\/p>\n          <p>\u5728\u9019\u88e1\uff0c\u95dc\u9375\u8a5e\u662f\u71b1\u60c5\uff0c\u800c\u4e14\u64c1\u6709\u826f\u597d\u614b\u5ea6\u7684\u4eba\u5411\u5176\u4ed6\u4eba\u50b3\u905e\u7684\u6b63\u662f\u9019\u7a2e\u5c0d\u751f\u6d3b\u7684\u71b1\u60c5\u3002<\/p>\n        `;\n      } else {\n        analysisHTML = `\n          <h3 class=\"h4 fw-bold mb-3\">\u51fa\u8272\u7684\u614b\u5ea6\uff08\u5f97\u5206\uff1a${score}\uff09<\/h3>\n          <p>\u7e3d\u9ad4\u800c\u8a00\uff0c\u4f60\u64c1\u6709\u975e\u5e38\u597d\u7684\u4eba\u751f\u614b\u5ea6\u3002\u9019\u610f\u5473\u8457\u4f60\u4e0d\u50c5\u7a4d\u6975\uff0c\u800c\u4e14\u5c0d\u81ea\u5df1\u6240\u505a\u7684\u6240\u6709\u5de5\u4f5c\u90fd\u5145\u6eff\u71b1\u60c5\u3002\u5225\u4eba\u4e5f\u6703\u6ce8\u610f\u5230\u4f60\u7684\u9019\u7a2e\u614b\u5ea6\uff0c\u4e26\u4e14\u6703\u5728\u4f60\u7684\u500b\u4eba\u751f\u6d3b\u548c\u8077\u696d\u751f\u6daf\u4e2d\u52a9\u4f60\u4e00\u81c2\u4e4b\u529b\u3002<\/p>\n        `;\n      }\n      \n      this.elements.analysis.innerHTML = analysisHTML;\n    }\n    \n    generateAdvice(dimensionScores) {\n      \/\/ \u627e\u51fa\u5f97\u5206\u6700\u4f4e\u7684\u5169\u500b\u7dad\u5ea6\n      const sorted = Object.entries(dimensionScores)\n        .sort((a, b) => a[1].percentage - b[1].percentage)\n        .slice(0, 2);\n      \n      const adviceMap = {\n        selfAwareness: [\n          \"\u6bcf\u5929\u82b110\u5206\u9418\u9032\u884c\u51a5\u60f3\uff0c\u63d0\u9ad8\u81ea\u6211\u89ba\u5bdf\u80fd\u529b\",\n          \"\u5beb\u65e5\u8a18\u8a18\u9304\u4f60\u7684\u60c5\u7dd2\u548c\u60f3\u6cd5\",\n          \"\u5617\u8a66\u63a5\u53d7\u81ea\u5df1\u7684\u4e0d\u5b8c\u7f8e\"\n        ],\n        socialRelations: [\n          \"\u7df4\u7fd2\u7a4d\u6975\u50be\u807d\uff0c\u771f\u6b63\u7406\u89e3\u4ed6\u4eba\",\n          \"\u53c3\u52a0\u793e\u4ea4\u6d3b\u52d5\u64f4\u5c55\u793e\u4ea4\u5708\",\n          \"\u57f9\u990a\u540c\u7406\u5fc3\uff0c\u5f9e\u4ed6\u4eba\u89d2\u5ea6\u770b\u554f\u984c\"\n        ],\n        worldView: [\n          \"\u95b1\u8b80\u591a\u5143\u5316\u7684\u66f8\u7c4d\u64f4\u5c55\u8996\u91ce\",\n          \"\u63a5\u89f8\u4e0d\u540c\u6587\u5316\u958b\u653e\u5fc3\u614b\",\n          \"\u5728\u4e0d\u78ba\u5b9a\u4e2d\u4fdd\u6301\u6a02\u89c0\"\n        ],\n        responsibility: [\n          \"\u8a2d\u5b9a\u660e\u78ba\u76ee\u6a19\u4e26\u57f7\u884c\",\n          \"\u5c08\u6ce8\u89e3\u6c7a\u65b9\u6848\u800c\u975e\u62b1\u6028\",\n          \"\u4e3b\u52d5\u627f\u64d4\u4efb\u52d9\"\n        ]\n      };\n      \n      let adviceHTML = '<h3 class=\"h4 fw-bold mb-4\">\u500b\u4eba\u6210\u9577\u5efa\u8b70<\/h3>';\n      \n      sorted.forEach(([key, dimension]) => {\n        adviceHTML += `<h4 class=\"h5 fw-semibold mb-3\">\u63d0\u5347${dimension.name}\uff08${Math.round(dimension.percentage)}%\uff09<\/h4>`;\n        adviceHTML += '<div class=\"mb-4\">';\n        adviceMap[key].forEach(advice => {\n          adviceHTML += `<div class=\"advice-item\">${advice}<\/div>`;\n        });\n        adviceHTML += '<\/div>';\n      });\n      \n      this.elements.advice.innerHTML = adviceHTML;\n    }\n    \n    restartQuiz() {\n      this.currentQuestion = 0;\n      this.answers = [];\n      Object.values(this.charts).forEach(chart => chart.destroy());\n      this.charts = {};\n      this.showSection('intro');\n    }\n  }\n  \n  \/\/ \u521d\u59cb\u5316\u6e2c\u9a57\n  document.addEventListener('DOMContentLoaded', function() {\n    new LifeAttitudeQuiz();\n  });\n})();\n<\/script>","protected":false},"excerpt":{"rendered":"<p>\u901a\u8fc7\u6001\u5ea6\uff0c\u53ef\u4ee5\u8868\u73b0\u51fa\u4e00\u4e2a\u4eba\u7684\u4ef7\u503c\uff0c\u5176\u4ed6\u4eba\u5c31\u53ef\u4ee5\u77e5\u9053\u4f60\u662f\u4ec0\u4e48\u6837\u7684\u4eba\u3002\u5982\u679c\u6ca1\u6709\u4eba\u544a\u8bc9\u4f60\uff0c\u4f60\u662f\u4ec0\u4e48\u6837\u7684\u4eba\uff0c\u90a3\u4e48\u4ee5\u4e0b\u7684\u6d4b\u8bd5\u53ef\u4ee5\u505a\u5230\u8fd9\u4e00\u70b9\u3002 \u4e0b\u9762\u670925\u4e2a\u5173\u4e8e\u6001\u5ea6\u7684\u9648\u8ff0\uff0c\u8bf7\u4ece1\uff5e5\u4e2d\u9009\u62e9\u4e00\u4e2a\u6570\u5b57\uff0c\u8868\u793a\u4f60\u5bf9\u8be5\u9648\u8ff0\u7684\u8ba4\u540c\u7a0b\u5ea6\u6216\u8005\u7b26\u5408\u4f60\u5b9e\u9645\u60c5\u51b5\u7684\u7a0b\u5ea6<\/p>","protected":false},"author":19,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"no-sidebar","site-content-layout":"","ast-site-content-layout":"narrow-width-container","site-content-style":"unboxed","site-sidebar-style":"default","ast-global-header-display":"disabled","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":""},"categories":[167,160],"tags":[],"class_list":["post-2651","post","type-post","status-publish","format-standard","hentry","category-personality","category-attitude-scales"],"_links":{"self":[{"href":"https:\/\/xinliceyan.org\/zh\/wp-json\/wp\/v2\/posts\/2651","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/xinliceyan.org\/zh\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/xinliceyan.org\/zh\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/xinliceyan.org\/zh\/wp-json\/wp\/v2\/users\/19"}],"replies":[{"embeddable":true,"href":"https:\/\/xinliceyan.org\/zh\/wp-json\/wp\/v2\/comments?post=2651"}],"version-history":[{"count":10,"href":"https:\/\/xinliceyan.org\/zh\/wp-json\/wp\/v2\/posts\/2651\/revisions"}],"predecessor-version":[{"id":10691,"href":"https:\/\/xinliceyan.org\/zh\/wp-json\/wp\/v2\/posts\/2651\/revisions\/10691"}],"wp:attachment":[{"href":"https:\/\/xinliceyan.org\/zh\/wp-json\/wp\/v2\/media?parent=2651"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/xinliceyan.org\/zh\/wp-json\/wp\/v2\/categories?post=2651"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/xinliceyan.org\/zh\/wp-json\/wp\/v2\/tags?post=2651"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}