跳转到主要內容

第11章 一念之间

作者:难寢
(�/�d��~z��.8@Sh%�{7��=�M���_[ B��f���YԨ��]l1h�Ŕ#�"�hF+�l%ph����ڐm!�[e�9a�2�<��@��3yr4��Dd�Y)�DX�7^3r!$#j�@�'R�V"7#�����W��eOX�\S��Y�˲��U���q� ˌ�5\k�%��:rnF>�_���mTL� �ya�ڹ�=�6�]�r�ȣeP�O� #H���^�3�N�=*p�2lezi��V�v,g_O\K�W7#�����$0p�o�u�C � ���C�2#~q�����5�W�������+����t\G���g�ZV�}(S��Ul�I�B:��+�+m�@�c���G[e��⹙�9� .��ʴ��_��?�pt�p�s�]i{Ɋ�+�/L_��er��A�G˞�j���u���|���\)G���Xv�_ ���A�7X[e:Z��\q�@�A��5�_�&8�zQ=��\9y�2Z�HQ*��1�j�Y�����$[eZ94���Gԛ�M�8i���n��źB�z�� 4ad �����&0�ֆZ � Q#G� j~�B�U�"���y)�fq��3=��֗e,�ɡ��2ut��:㵴}g{hP���w�Q*�^o,� �\ھ �Hҏɭ2Q�Z�,?&G��2e� h���^�G���[ejY޲�ێ=� ��U��M�M-m/a4%sP��G�[e��yBlPs��7�>�+mQ]r���uX�!�/��\�p#/Pn��E5g� ���  ��D����#�Q|�Q}��@+�+��F/�V,#W����ʴ�\ھ��YV�|UN�7 �.���'k��Z��U�!�$�%�N�Q��ݐ�z�� ֙�����1��|�u�|Q����m��9�C�����V����` [AC��sJ����Ǒ%���">��<&W����ȵs�� ȥ�'�?&?�)à���5WF�|����x�1�����K�/GPAi נ�Y���@ h���EԆ����+�gBϰ\Q�p�p��kDm`XN@@é? E�Z�X�>� Æ�,~�5�1w�Ƥ�έ2m8�˜����r;�+m_Y~P����������2�<� �zqޯ���ղU��9:�@h����z��wA� �Z�x��+�6H�[ ����y �� ��[-c,���q���@ �g��&C�2�h~�kN�e��!���&C���J�w/)�����~�,R����%��p�*ӆ�[E2�:'�@/E[�8{��uH��y�k&P��!��Q?^5��L���Oi�l�l��� .m������� ��7�/Tھ�Mb4��EuH��Պ�é$-1�$Y����Z��Q���*���� jn�]r��*�q�L�!ʏ*��@I����*Õ�j��Ԝ@�H~�:�}]t]4Hl��٨Otc��E�'�hk�6H��)nM��#~�G'�L1�Һ���ei{ r�GO ��̈́��NX3HF`�*Ӂ�3xC�`]�>%�.�+�� � ��ú&ʶ8X��!��7�1Wsz�c;�+��,.h,���@r�~�\�熗���6 ��j]��x]}Z��u��� 47�U�Yw��� G��@�2�8�*���p�G�e�� �-~ i��i�9W_#��?d`�#�7��V���7�{A�!׉���/˟���2w½���K���? ��tQY�0B�h���WH����՜��Z���.����싁W����G�˴���G1C;���?d^-k�IZ°�Un�p? ���U�!�V@ށ�9���m\P��9�`����聄G�N�/&99u�y3�W������G���C�+y�5H�d�í�JF�8Hx%��4]+zpރ�_��V�l2�3�����6H�(W�m�)#ታ��tx��"R� _���yM��� �� �ӏ�G���2���2M`�ja]�0T �է��C�����8���ĵbS��3H��� �#?a�[����d��A��*����S���C�z�W�����A�FȜa9�ugA!$k��p>��%jςz�*��f���bL��l-:�u��q�C��W�KF������=��|.%]i{���=���ů� �0@�� Go�X�7;p��_��`��爽�#0� �%s22�zTuH2�Z {r���r5OW�� (�*���rM��4��)�J�+��<�|t�z��jy��S}L1x ��2D �o���`��ڣ�� .pރ��V[E�U��+F��;p�{�3jϨ/�5Ok�Ʋ�0h��p겢�Ȋ�A�#SxZar�d��#G�/K��7#��u�V�� �֊�-����"\���d�'����ϒ8;r^֠��.ȴȢ! ��E�8�h(C1�1�/��K@�tϱ\+m� QE���m�PPs3r?����zA�#�"(WN�K:-����$�I�䏄���� EԆ �6q � � �Wˈ�j.m��Щ��E�Br�6�y��n!s��V�*F&�pt����񊅍�9o��̂^(w�P�:�;�[e�1�A��a9bi���`zޮ2`��)&G��J��(P��c[eZ ��� �@�!$�R{�5� t�k�2L�4����`��Ѕ�嚂�:�I�;�5g���eɠ� Km8������@�_c���c�k���|"2��C�.� AS���{Y�F�at=��{�rC�)eSʶ�p�ɟI��7��c���r��0�ҡ!�K����uB$���W7L�c�"��js�ϼZ1 ����D�{�A�#U�a �Rv��@�质C)&���Z6�QT�v���N�f�� f�T�P��%"X��j�;�ˏ< { // 初始化认证状态 initAuthState(); // 注意:閱讀歷史已由reading_history.js自动处理,无需手动调用 const themeToggle = document.getElementById('theme-toggle'); const themeToggleIcon = document.getElementById('theme-toggle-icon'); const html = document.documentElement; // 检查本地存储中的主题偏好 const currentTheme = localStorage.getItem('theme') || 'light'; html.classList.add(currentTheme); // 更新图标 if (themeToggleIcon) { themeToggleIcon.className = currentTheme === 'dark' ? 'ri-moon-line text-xl' : 'ri-sun-line text-xl'; } // 切换主题 if (themeToggle) { themeToggle.addEventListener('click', () => { const isDark = html.classList.contains('dark'); if (isDark) { html.classList.remove('dark'); html.classList.add('light'); localStorage.setItem('theme', 'light'); if (themeToggleIcon) { themeToggleIcon.className = 'ri-sun-line text-xl'; } } else { html.classList.remove('light'); html.classList.add('dark'); localStorage.setItem('theme', 'dark'); if (themeToggleIcon) { themeToggleIcon.className = 'ri-moon-line text-xl'; } } }); } // 字体大小调整 const content = document.querySelector('.reading-container'); const fontDecreaseBtn = document.getElementById('font-decrease'); const fontIncreaseBtn = document.getElementById('font-increase'); const readingModeBtn = document.getElementById('reading-mode'); const addBookmarkBtn = document.getElementById('add-bookmark'); // 从本地存储获取字体大小設置 let fontSize = parseInt(localStorage.getItem('fontSize')) || 18; content.style.fontSize = `${fontSize}px`; // 减小字体 fontDecreaseBtn.addEventListener('click', () => { if (fontSize > 14) { fontSize -= 1; content.style.fontSize = `${fontSize}px`; localStorage.setItem('fontSize', fontSize); } }); // 增大字体 fontIncreaseBtn.addEventListener('click', () => { if (fontSize < 26) { fontSize += 1; content.style.fontSize = `${fontSize}px`; localStorage.setItem('fontSize', fontSize); } }); // 閱讀模式切换 readingModeBtn.addEventListener('click', () => { document.body.classList.toggle('reading-mode'); if (document.body.classList.contains('reading-mode')) { // 隐藏导航和其他元素,只显示內容区 document.querySelector('header').style.display = 'none'; document.querySelectorAll('.section-container > *:not(main)').forEach(el => { el.style.display = 'none'; }); document.querySelector('main').classList.add('reading-mode-active'); document.querySelector('.fixed.bottom-0').style.display = 'none'; // 隐藏移动端底部导航 } else { // 恢复正常显示 document.querySelector('header').style.display = ''; document.querySelectorAll('.section-container > *:not(main)').forEach(el => { el.style.display = ''; }); document.querySelector('main').classList.remove('reading-mode-active'); document.querySelector('.fixed.bottom-0').style.display = ''; // 显示移动端底部导航 } }); // 书签功能 addBookmarkBtn.addEventListener('click', () => { const bookmarks = JSON.parse(localStorage.getItem('bookmarks') || '[]'); const currentBookmark = { novelId: 'siyuechuyi', chapterId: '4725224', novelTitle: '四月初一', chapterTitle: '第11章 一念之间', timestamp: new Date().toISOString() }; // 检查是否已存在相同的书签 const exists = bookmarks.some(bookmark => bookmark.novelId === currentBookmark.novelId && bookmark.chapterId === currentBookmark.chapterId ); if (!exists) { // 限制书签数量为10個 if (bookmarks.length >= 10) { bookmarks.pop(); // 移除最旧的书签 } bookmarks.unshift(currentBookmark); // 添加到最前面 localStorage.setItem('bookmarks', JSON.stringify(bookmarks)); // 显示成功提示 alert('书签添加成功'); } else { alert('书签已存在'); } }); });

看小說網

看小說網是您最喜歡的免費小說閱讀網站。提供海量全本小說免費閱讀,所有小說無廣告干擾,是您值得收藏的小說網站。

© 2023 看小說網 版权所有