From 460450c339901d1a5f5d70ad75e4c9091979e57a Mon Sep 17 00:00:00 2001 From: "DESKTOP-RQ919RC\\Pc" <1300399510@qq.com> Date: Tue, 25 Nov 2025 19:12:29 +0800 Subject: [PATCH] =?UTF-8?q?feat(editor):=20=E9=9B=86=E6=88=90=E5=AF=8C?= =?UTF-8?q?=E6=96=87=E6=9C=AC=E7=BC=96=E8=BE=91=E5=99=A8=E5=B9=B6=E4=BC=98?= =?UTF-8?q?=E5=8C=96=E5=93=8D=E5=BA=94=E5=BC=8F=E5=B8=83=E5=B1=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 1. 添加wangEditor富文本编辑器替换原有简易编辑器 2. 新增编辑器相关CSS样式和功能按钮 3. 优化详情页和编辑页的响应式布局 4. 调整评论区域样式结构 5. 添加移动端适配样式 --- component/bi/bi.js | 2 +- component/bi/bi.txt | 1 + css/details.css | 128 +- css/details.less | 188 +- css/editor.css | 27 + details.html | 121 +- edit.html | 130 +- img/between -icon.png | Bin 0 -> 261 bytes img/overstriking-icon.png | Bin 0 -> 1074 bytes js/details.js | 3 - js/edit.js | 170 +- js/editor.js | 24129 ++++++++++++++++++++++++++++++++++++ 12 files changed, 24728 insertions(+), 171 deletions(-) create mode 100644 css/editor.css create mode 100644 img/between -icon.png create mode 100644 img/overstriking-icon.png create mode 100644 js/editor.js diff --git a/component/bi/bi.js b/component/bi/bi.js index 0701493..a6e5584 100644 --- a/component/bi/bi.js +++ b/component/bi/bi.js @@ -1,6 +1,6 @@ // 1. 创建组件模板和样式(内置到 JS 中,无需外部 HTML/Template) const template = document.createElement("template"); -template.innerHTML = `
已获得
个寄托币
投币
你当前共有
寄托币 [挣币攻略]
作者设置了阅读限制,解锁所有内容仅需 寄托币
投币解锁
你共有 寄托币
你的寄托币不够,快去发帖挣币吧
攒币指南
`; +template.innerHTML = `
已获得
个寄托币
投币
你当前共有
寄托币 [挣币攻略]
作者设置了阅读限制,解锁所有内容仅需 寄托币
投币解锁
你共有 寄托币
你的寄托币不够,快去发帖挣币吧
攒币指南
`; // 2. 定义组件类 class BiCard extends HTMLElement { diff --git a/component/bi/bi.txt b/component/bi/bi.txt index 31c8bca..8655146 100644 --- a/component/bi/bi.txt +++ b/component/bi/bi.txt @@ -71,6 +71,7 @@ padding: 40px 30px 35px; position: relative; display: none; + max-width: calc(100vw - 10px); } .coins-area .coins-box .fork { diff --git a/css/details.css b/css/details.css index e53f527..90894a9 100644 --- a/css/details.css +++ b/css/details.css @@ -1,6 +1,7 @@ #details { - width: 1200px; + max-width: 1200px; margin: 0 auto; + min-width: 320px; } #details .matter { align-items: flex-start; @@ -338,6 +339,7 @@ } #details .matter .matter-left .related .list .item .text { width: 352px; + flex: 1; } #details .matter .sidebar-box { position: sticky; @@ -845,30 +847,29 @@ border-top: 1px dotted #ebebeb; } .answer-discuss .comments-box .comments-item .comments-header { - justify-content: space-between; margin-bottom: 9px; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-left { +.answer-discuss .comments-box .comments-item .comments-header { font-size: 13px; position: relative; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-left .comments-avatar { +.answer-discuss .comments-box .comments-item .comments-header .comments-avatar { width: 20px; height: 20px; margin-right: 10px; border-radius: 50%; cursor: pointer; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-left .comments-username { +.answer-discuss .comments-box .comments-item .comments-header .comments-username { color: #555; margin-right: 10px; cursor: pointer; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-left .comments-time { +.answer-discuss .comments-box .comments-item .comments-header .comments-time { color: #aaaaaa; margin-right: 8px; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-left .comments-identity { +.answer-discuss .comments-box .comments-item .comments-header .comments-identity { font-size: 12px; color: #7f7f7f; padding: 0 3px; @@ -877,18 +878,19 @@ border: 1px solid #d7d7d7; border-radius: 5px; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .menu-box { +.answer-discuss .comments-box .comments-item .comments-header .menu-box { position: relative; + margin-left: auto; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .menu-box:hover .operate-box { +.answer-discuss .comments-box .comments-item .comments-header .menu-box:hover .operate-box { display: block; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .menu-box .menu-icon { +.answer-discuss .comments-box .comments-item .comments-header .menu-box .menu-icon { width: 14px; height: 14px; cursor: pointer; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .menu-box .operate-box { +.answer-discuss .comments-box .comments-item .comments-header .menu-box .operate-box { display: none; flex-direction: column; position: absolute; @@ -903,13 +905,13 @@ background-color: #f6f6f6; border: 1px solid #d7d7d7; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .menu-box .operate-box .item { +.answer-discuss .comments-box .comments-item .comments-header .menu-box .operate-box .item { height: 24px; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .menu-box .operate-box .item:not(:last-of-type) { +.answer-discuss .comments-box .comments-item .comments-header .menu-box .operate-box .item:not(:last-of-type) { border-bottom: 1px solid #d7d7d7; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .menu-box .operate-box::after { +.answer-discuss .comments-box .comments-item .comments-header .menu-box .operate-box::after { content: ""; width: 58px; height: 36px; @@ -918,7 +920,7 @@ right: 0; z-index: -1; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .menu-box .report-box { +.answer-discuss .comments-box .comments-item .comments-header .menu-box .report-box { display: none; position: absolute; top: 24px; @@ -932,7 +934,7 @@ color: #7f7f7f; cursor: pointer; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .menu-box .report-box::after { +.answer-discuss .comments-box .comments-item .comments-header .menu-box .report-box::after { content: ""; width: 58px; height: 36px; @@ -940,23 +942,23 @@ top: -14px; right: 0; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .comment-icon { +.answer-discuss .comments-box .comments-item .comments-header .comment-icon { width: 14px; height: 13px; margin-left: 40px; cursor: pointer; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .like-box { +.answer-discuss .comments-box .comments-item .comments-header .like-box { font-size: 12px; color: #aaa; margin-left: 40px; cursor: pointer; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .like-box .like-icon { +.answer-discuss .comments-box .comments-item .comments-header .like-box .like-icon { width: 14px; height: 14px; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .like-box .like-quantity { +.answer-discuss .comments-box .comments-item .comments-header .like-box .like-quantity { margin-left: 6px; } .answer-discuss .comments-box .comments-item .comments-content { @@ -1251,3 +1253,89 @@ z-index: 1; background-color: rgba(0, 0, 0, 0.20392157); } +@media screen and (max-width: 850px) { + #details { + padding: 10px 10px 0; + } + #details .head-top { + display: none; + } + #details .head-navigation { + display: none; + } + #details .matter .matter-left { + margin-right: 0 !important; + } + #details .matter .matter-left .action-bar { + margin-right: 0 !important; + justify-content: space-around; + padding: 0 !important; + } + #details .matter .matter-left .action-bar .action-bar-item { + margin-right: 0 !important; + } + #details .matter .matter-left .related .related-head { + padding-left: 14px; + } + #details .matter .matter-left .related .list { + padding: 14px; + } + #details .matter .matter-left .related .list .item { + width: 100% !important; + } + #details .matter .matter-left .related .list .item:not(:last-child) { + margin-bottom: 7px; + } + #details .matter .matter-left .related .list .item .text { + width: calc(100vw - 100px); + } + #details .matter .sidebar-box { + display: none; + } + #details .answer-discuss { + padding: 15px; + } + #details .answer-discuss .input-box .picture-box { + width: calc(100vw - 68px); + } + #details .answer-discuss .input-box .bottom .operate .item .emoji-box { + position: fixed; + bottom: 0; + left: 0; + transform: translateX(0); + width: 100vw; + height: 300px; + top: auto; + overflow: auto; + border: none; + } + #details .answer-discuss .input-box .bottom .operate .item .emoji-box::after { + display: none; + } + #details .answer-discuss .comments-box .input-box .picture-box { + width: calc(100vw - 88px); + } + #details .answer-discuss .comments-box .comments-item .comments-header { + justify-content: inherit; + } + #details .answer-discuss .comments-box .comments-item .comments-header .menu-box { + margin-left: auto; + } + #details .answer-discuss .comments-box .comments-item .child-comments .input-box .picture-box { + width: calc(100vw - 128px); + } +} +@media screen and (max-width: 500px) { + #details .answer-discuss .comments-box .comments-item .comments-header { + font-size: 12px; + } + #details .answer-discuss .comments-box .comments-item .comments-header .comments-title { + height: 14px !important; + } +} +@media screen and (max-width: 450px) { + #details .answer-discuss .comments-box .comments-item .comments-header .comment-icon, + #details .answer-discuss .comments-box .comments-item .comments-header .like-box { + margin-left: 15px; + } +} diff --git a/css/details.less b/css/details.less index 608bfc0..21c37e8 100644 --- a/css/details.less +++ b/css/details.less @@ -1,6 +1,8 @@ #details { - width: 1200px; + // width: 1200px; + max-width: 1200px; margin: 0 auto; + min-width: 320px; .matter { align-items: flex-start; @@ -204,7 +206,7 @@ video { margin: 0 auto; } - + h2 { font-family: "PingFangSC-Semibold", "PingFang SC Semibold", "PingFang SC", sans-serif; font-weight: 650; @@ -393,6 +395,7 @@ .text { width: 352px; + flex: 1; } } } @@ -994,16 +997,16 @@ } .answer-discuss .comments-box .comments-item .comments-header { - justify-content: space-between; + // justify-content: space-between; margin-bottom: 9px; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-left { +.answer-discuss .comments-box .comments-item .comments-header { font-size: 13px; position: relative; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-left .comments-avatar { +.answer-discuss .comments-box .comments-item .comments-header .comments-avatar { width: 20px; height: 20px; margin-right: 10px; @@ -1011,18 +1014,18 @@ cursor: pointer; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-left .comments-username { +.answer-discuss .comments-box .comments-item .comments-header .comments-username { color: #555; margin-right: 10px; cursor: pointer; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-left .comments-time { +.answer-discuss .comments-box .comments-item .comments-header .comments-time { color: #aaaaaa; margin-right: 8px; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-left .comments-identity { +.answer-discuss .comments-box .comments-item .comments-header .comments-identity { font-size: 12px; color: #7f7f7f; padding: 0 3px; @@ -1032,21 +1035,22 @@ border-radius: 5px; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .menu-box { +.answer-discuss .comments-box .comments-item .comments-header .menu-box { position: relative; + margin-left: auto; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .menu-box:hover .operate-box { +.answer-discuss .comments-box .comments-item .comments-header .menu-box:hover .operate-box { display: block; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .menu-box .menu-icon { +.answer-discuss .comments-box .comments-item .comments-header .menu-box .menu-icon { width: 14px; height: 14px; cursor: pointer; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .menu-box .operate-box { +.answer-discuss .comments-box .comments-item .comments-header .menu-box .operate-box { display: none; flex-direction: column; position: absolute; @@ -1062,15 +1066,15 @@ border: 1px solid rgba(215, 215, 215, 1); } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .menu-box .operate-box .item { +.answer-discuss .comments-box .comments-item .comments-header .menu-box .operate-box .item { height: 24px; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .menu-box .operate-box .item:not(:last-of-type) { +.answer-discuss .comments-box .comments-item .comments-header .menu-box .operate-box .item:not(:last-of-type) { border-bottom: 1px solid rgba(215, 215, 215, 1); } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .menu-box .operate-box::after { +.answer-discuss .comments-box .comments-item .comments-header .menu-box .operate-box::after { content: ""; width: 58px; height: 36px; @@ -1080,7 +1084,7 @@ z-index: -1; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .menu-box .report-box { +.answer-discuss .comments-box .comments-item .comments-header .menu-box .report-box { display: none; position: absolute; top: 24px; @@ -1095,7 +1099,7 @@ cursor: pointer; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .menu-box .report-box::after { +.answer-discuss .comments-box .comments-item .comments-header .menu-box .report-box::after { content: ""; width: 58px; height: 36px; @@ -1104,26 +1108,26 @@ right: 0; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .comment-icon { +.answer-discuss .comments-box .comments-item .comments-header .comment-icon { width: 14px; height: 13px; margin-left: 40px; cursor: pointer; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .like-box { +.answer-discuss .comments-box .comments-item .comments-header .like-box { font-size: 12px; color: #aaa; margin-left: 40px; cursor: pointer; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .like-box .like-icon { +.answer-discuss .comments-box .comments-item .comments-header .like-box .like-icon { width: 14px; height: 14px; } -.answer-discuss .comments-box .comments-item .comments-header .comments-header-right .like-box .like-quantity { +.answer-discuss .comments-box .comments-item .comments-header .like-box .like-quantity { margin-left: 6px; } @@ -1458,3 +1462,145 @@ z-index: 1; background-color: rgba(0, 0, 0, 0.20392157); } + +// 媒体查询 最大宽度 850px 时 +@media screen and (max-width: 850px) { + #details { + padding: 10px 10px 0; + .head-top { + display: none; + } + + .head-navigation { + display: none; + } + + .matter { + .matter-left { + margin-right: 0 !important; + .action-bar { + margin-right: 0 !important; + justify-content: space-around; + padding: 0 !important; + + .action-bar-item { + margin-right: 0 !important; + } + } + + .related { + .related-head { + padding-left: 14px; + } + .list { + padding: 14px; + .item { + width: 100% !important; + &:not(:last-child) { + margin-bottom: 7px; + } + + .text { + width: calc(100vw - 100px); + } + } + } + } + } + .sidebar-box { + display: none; + } + } + .answer-discuss { + padding: 15px; + + .input-box { + .picture-box { + width: calc(100vw - 68px); + } + + .bottom { + .operate { + .item { + .emoji-box { + position: fixed; + bottom: 0; + left: 0; + transform: translateX(0); + width: 100vw; + height: 300px; + top: auto; + overflow: auto; + border: none; + + &::after { + display: none; + } + } + } + } + } + } + + .comments-box { + .input-box { + .picture-box { + width: calc(100vw - 88px); + } + } + + .comments-item { + .comments-header { + justify-content: inherit; + + .menu-box { + margin-left: auto; + } + } + + .child-comments { + .input-box { + .picture-box { + width: calc(100vw - 128px); + } + } + } + } + } + } + } +} + +@media screen and (max-width: 500px) { + #details { + .answer-discuss { + .comments-box { + .comments-item { + .comments-header { + font-size: 12px; + .comments-title { + height: 14px !important; + } + } + } + } + } + } +} + +@media screen and (max-width: 450px) { + #details { + .answer-discuss { + .comments-box { + .comments-item { + .comments-header { + .comment-icon, + .like-box { + margin-left: 15px; + } + } + } + } + } + } +} diff --git a/css/editor.css b/css/editor.css new file mode 100644 index 0000000..6d13c91 --- /dev/null +++ b/css/editor.css @@ -0,0 +1,27 @@ +:root, +:host { + --w-e-textarea-bg-color: #fff; + --w-e-textarea-color: #333; + --w-e-textarea-border-color: #ccc; + --w-e-textarea-slight-border-color: #e8e8e8; + --w-e-textarea-slight-color: #d4d4d4; + --w-e-textarea-slight-bg-color: #f5f2f0; + --w-e-textarea-selected-border-color: #B4D5FF; + --w-e-textarea-handler-bg-color: #4290f7; + --w-e-toolbar-color: #595959; + --w-e-toolbar-bg-color: #fff; + --w-e-toolbar-active-color: #333; + --w-e-toolbar-active-bg-color: #f1f1f1; + --w-e-toolbar-disabled-color: #999; + --w-e-toolbar-border-color: #e8e8e8; + --w-e-modal-button-bg-color: #fafafa; + --w-e-modal-button-border-color: #d9d9d9; +} + +.w-e-text-container *,.w-e-toolbar *{box-sizing:border-box;margin:0;outline:none;padding:0}.w-e-text-container blockquote,.w-e-text-container li,.w-e-text-container p,.w-e-text-container td,.w-e-text-container th,.w-e-toolbar *{line-height:1.5}.w-e-text-container{background-color:var(--w-e-textarea-bg-color);color:var(--w-e-textarea-color);height:100%;position:relative}.w-e-text-container .w-e-scroll{-webkit-overflow-scrolling:touch;height:100%}.w-e-text-container [data-slate-editor]{word-wrap:break-word;border-top:1px solid transparent;min-height:100%;outline:0;padding:0 10px;white-space:pre-wrap}.w-e-text-container [data-slate-editor] p{margin:15px 0}.w-e-text-container [data-slate-editor] h1,.w-e-text-container [data-slate-editor] h2,.w-e-text-container [data-slate-editor] h3,.w-e-text-container [data-slate-editor] h4,.w-e-text-container [data-slate-editor] h5{margin:20px 0}.w-e-text-container [data-slate-editor] img{cursor:default;display:inline!important;max-width:100%;min-height:20px;min-width:20px}.w-e-text-container [data-slate-editor] span{text-indent:0}.w-e-text-container [data-slate-editor] [data-selected=true]{box-shadow:0 0 0 2px var(--w-e-textarea-selected-border-color)}.w-e-text-placeholder{font-style:italic;left:10px;top:17px;width:90%}.w-e-max-length-info,.w-e-text-placeholder{color:var(--w-e-textarea-slight-color);pointer-events:none;position:absolute;-webkit-user-select:none;-moz-user-select:none;user-select:none}.w-e-max-length-info{bottom:.5em;right:1em}.w-e-bar{background-color:var(--w-e-toolbar-bg-color);color:var(--w-e-toolbar-color);font-size:14px;padding:0 5px}.w-e-bar svg{fill:var(--w-e-toolbar-color);height:14px;width:14px}.w-e-bar-show{display:flex}.w-e-bar-hidden{display:none}.w-e-hover-bar{border:1px solid var(--w-e-toolbar-border-color);border-radius:3px;box-shadow:0 2px 5px #0000001f;position:absolute}.w-e-toolbar{flex-wrap:wrap;position:relative}.w-e-bar-divider{background-color:var(--w-e-toolbar-border-color);display:inline-flex;height:40px;margin:0 5px;width:1px}.w-e-bar-item{display:flex;height:40px;padding:4px;position:relative;text-align:center}.w-e-bar-item,.w-e-bar-item button{align-items:center;justify-content:center}.w-e-bar-item button{background:transparent;border:none;color:var(--w-e-toolbar-color);cursor:pointer;display:inline-flex;height:32px;overflow:hidden;padding:0 8px;white-space:nowrap}.w-e-bar-item button:hover{background-color:var(--w-e-toolbar-active-bg-color);color:var(--w-e-toolbar-active-color)}.w-e-bar-item button .title{margin-left:5px}.w-e-bar-item .active{background-color:var(--w-e-toolbar-active-bg-color);color:var(--w-e-toolbar-active-color)}.w-e-bar-item .disabled{color:var(--w-e-toolbar-disabled-color);cursor:not-allowed}.w-e-bar-item .disabled svg{fill:var(--w-e-toolbar-disabled-color)}.w-e-bar-item .disabled:hover{background-color:var(--w-e-toolbar-bg-color);color:var(--w-e-toolbar-disabled-color)}.w-e-bar-item .disabled:hover svg{fill:var(--w-e-toolbar-disabled-color)}.w-e-menu-tooltip-v5:before{background-color:var(--w-e-toolbar-active-color);border-radius:5px;color:var(--w-e-toolbar-bg-color);content:attr(data-tooltip);font-size:.75em;opacity:0;padding:5px 10px;position:absolute;text-align:center;top:40px;transition:opacity .6s;visibility:hidden;white-space:pre;z-index:1}.w-e-menu-tooltip-v5:after{border:5px solid transparent;border-bottom:5px solid var(--w-e-toolbar-active-color);content:"";opacity:0;position:absolute;top:30px;transition:opacity .6s;visibility:hidden}.w-e-menu-tooltip-v5:hover:after,.w-e-menu-tooltip-v5:hover:before{opacity:1;visibility:visible}.w-e-menu-tooltip-v5.tooltip-right:before{left:100%;top:10px}.w-e-menu-tooltip-v5.tooltip-right:after{border-bottom-color:transparent;border-left-color:transparent;border-right-color:var(--w-e-toolbar-active-color);border-top-color:transparent;left:100%;margin-left:-10px;top:16px}.w-e-bar-item-group .w-e-bar-item-menus-container{background-color:var(--w-e-toolbar-bg-color);border:1px solid var(--w-e-toolbar-border-color);border-radius:3px;box-shadow:0 2px 10px #0000001f;display:none;left:0;margin-top:40px;position:absolute;top:0;z-index:1}.w-e-bar-item-group:hover .w-e-bar-item-menus-container{display:block}.w-e-select-list{background-color:var(--w-e-toolbar-bg-color);border:1px solid var(--w-e-toolbar-border-color);border-radius:3px;box-shadow:0 2px 10px #0000001f;left:0;margin-top:40px;max-height:350px;min-width:100px;overflow-y:auto;position:absolute;top:0;z-index:1}.w-e-select-list ul{line-height:1;list-style:none}.w-e-select-list ul .selected{background-color:var(--w-e-toolbar-active-bg-color)}.w-e-select-list ul li{cursor:pointer;padding:7px 0 7px 25px;position:relative;text-align:left;white-space:nowrap}.w-e-select-list ul li:hover{background-color:var(--w-e-toolbar-active-bg-color)}.w-e-select-list ul li svg{left:0;margin-left:5px;margin-top:-7px;position:absolute;top:50%}.w-e-bar-bottom .w-e-select-list{bottom:0;margin-bottom:40px;margin-top:0;top:inherit}.w-e-drop-panel{background-color:var(--w-e-toolbar-bg-color);border:1px solid var(--w-e-toolbar-border-color);border-radius:3px;box-shadow:0 2px 10px #0000001f;margin-top:40px;min-width:200px;padding:10px;position:absolute;top:0;z-index:1}.w-e-bar-bottom .w-e-drop-panel{bottom:0;margin-bottom:40px;margin-top:0;top:inherit}.w-e-modal{background-color:var(--w-e-toolbar-bg-color);border:1px solid var(--w-e-toolbar-border-color);border-radius:3px;box-shadow:0 2px 10px #0000001f;color:var(--w-e-toolbar-color);font-size:14px;min-height:40px;min-width:100px;padding:20px 15px 0;position:absolute;text-align:left;z-index:1}.w-e-modal .btn-close{cursor:pointer;line-height:1;padding:5px;position:absolute;right:8px;top:7px}.w-e-modal .btn-close svg{fill:var(--w-e-toolbar-color);height:10px;width:10px}.w-e-modal .babel-container{display:block;margin-bottom:15px}.w-e-modal .babel-container span{display:block;margin-bottom:10px}.w-e-modal .button-container{margin-bottom:15px}.w-e-modal button{background-color:var(--w-e-modal-button-bg-color);border:1px solid var(--w-e-modal-button-border-color);border-radius:4px;color:var(--w-e-toolbar-color);cursor:pointer;font-weight:400;height:32px;padding:4.5px 15px;text-align:center;touch-action:manipulation;transition:all .3s cubic-bezier(.645,.045,.355,1);-webkit-user-select:none;-moz-user-select:none;user-select:none;white-space:nowrap}.w-e-modal input[type=number],.w-e-modal input[type=text],.w-e-modal textarea{font-feature-settings:"tnum";background-color:var(--w-e-toolbar-bg-color);border:1px solid var(--w-e-modal-button-border-color);border-radius:4px;color:var(--w-e-toolbar-color);font-variant:tabular-nums;padding:4.5px 11px;transition:all .3s;width:100%}.w-e-modal textarea{min-height:60px}body .w-e-modal,body .w-e-modal *{box-sizing:border-box}.w-e-progress-bar{background-color:var(--w-e-textarea-handler-bg-color);height:1px;position:absolute;transition:width .3s;width:0}.w-e-full-screen-container{bottom:0!important;display:flex!important;flex-direction:column!important;height:100%!important;left:0!important;margin:0!important;padding:0!important;position:fixed;right:0!important;top:0!important;width:100%!important}.w-e-full-screen-container [data-w-e-textarea=true]{flex:1!important} +.w-e-text-container [data-slate-editor] code{background-color:var(--w-e-textarea-slight-bg-color);border-radius:3px;font-family:monospace;padding:3px}.w-e-panel-content-color{list-style:none;text-align:left;width:230px}.w-e-panel-content-color li{border:1px solid var(--w-e-toolbar-bg-color);border-radius:3px 3px;cursor:pointer;display:inline-block;padding:2px}.w-e-panel-content-color li:hover{border-color:var(--w-e-toolbar-color)}.w-e-panel-content-color li .color-block{border:1px solid var(--w-e-toolbar-border-color);border-radius:3px 3px;height:17px;width:17px}.w-e-panel-content-color .active{border-color:var(--w-e-toolbar-color)}.w-e-panel-content-color .clear{line-height:1.5;margin-bottom:5px;width:100%}.w-e-panel-content-color .clear svg{height:16px;margin-bottom:-4px;width:16px}.w-e-text-container [data-slate-editor] blockquote{background-color:var(--w-e-textarea-slight-bg-color);border-left:8px solid var(--w-e-textarea-selected-border-color);display:block;font-size:100%;line-height:1.5;margin:10px 0;padding:10px}.w-e-panel-content-emotion{font-size:20px;list-style:none;text-align:left;width:300px}.w-e-panel-content-emotion li{border-radius:3px 3px;cursor:pointer;display:inline-block;padding:0 5px}.w-e-panel-content-emotion li:hover{background-color:var(--w-e-textarea-slight-bg-color)}.w-e-textarea-divider{border-radius:3px;margin:20px auto;padding:20px}.w-e-textarea-divider hr{background-color:var(--w-e-textarea-border-color);border:0;display:block;height:1px}.w-e-text-container [data-slate-editor] pre>code{background-color:var(--w-e-textarea-slight-bg-color);border:1px solid var(--w-e-textarea-slight-border-color);border-radius:4px 4px;display:block;font-size:14px;padding:10px;text-indent:0}.w-e-text-container [data-slate-editor] .w-e-image-container{display:inline-block;margin:0 3px}.w-e-text-container [data-slate-editor] .w-e-image-container:hover{box-shadow:0 0 0 2px var(--w-e-textarea-selected-border-color)}.w-e-text-container [data-slate-editor] .w-e-selected-image-container{overflow:hidden;position:relative}.w-e-text-container [data-slate-editor] .w-e-selected-image-container .w-e-image-dragger{background-color:var(--w-e-textarea-handler-bg-color);height:7px;position:absolute;width:7px}.w-e-text-container [data-slate-editor] .w-e-selected-image-container .left-top{cursor:nwse-resize;left:0;top:0}.w-e-text-container [data-slate-editor] .w-e-selected-image-container .right-top{cursor:nesw-resize;right:0;top:0}.w-e-text-container [data-slate-editor] .w-e-selected-image-container .left-bottom{bottom:0;cursor:nesw-resize;left:0}.w-e-text-container [data-slate-editor] .w-e-selected-image-container .right-bottom{bottom:0;cursor:nwse-resize;right:0}.w-e-text-container [data-slate-editor] .w-e-selected-image-container:hover{box-shadow:none}.w-e-text-container [contenteditable=false] .w-e-image-container:hover{box-shadow:none} + +.w-e-text-container [data-slate-editor] .table-container{border:1px dashed var(--w-e-textarea-border-color);border-radius:5px;margin-top:10px;overflow-x:auto;padding:10px;width:100%}.w-e-text-container [data-slate-editor] table{border-collapse:collapse}.w-e-text-container [data-slate-editor] table td,.w-e-text-container [data-slate-editor] table th{border:1px solid var(--w-e-textarea-border-color);line-height:1.5;min-width:30px;padding:3px 5px;text-align:left}.w-e-text-container [data-slate-editor] table th{background-color:var(--w-e-textarea-slight-bg-color);font-weight:700;text-align:center}.w-e-panel-content-table{background-color:var(--w-e-toolbar-bg-color)}.w-e-panel-content-table table{border-collapse:collapse}.w-e-panel-content-table td{border:1px solid var(--w-e-toolbar-border-color);cursor:pointer;height:15px;padding:3px 5px;width:20px}.w-e-panel-content-table td.active{background-color:var(--w-e-toolbar-active-bg-color)} +.w-e-textarea-video-container{background-image:linear-gradient(45deg,#eee 25%,transparent 0,transparent 75%,#eee 0,#eee),linear-gradient(45deg,#eee 25%,#fff 0,#fff 75%,#eee 0,#eee);background-position:0 0,10px 10px;background-size:20px 20px;border:1px dashed var(--w-e-textarea-border-color);border-radius:5px;margin:10px auto 0;padding:10px 0;text-align:center} + +.w-e-text-container [data-slate-editor] pre>code{word-wrap:normal;font-family:Consolas,Monaco,Andale Mono,Ubuntu Mono,monospace;-webkit-hyphens:none;hyphens:none;line-height:1.5;margin:.5em 0;overflow:auto;padding:1em;-moz-tab-size:4;-o-tab-size:4;tab-size:4;text-align:left;text-shadow:0 1px #fff;white-space:pre;word-break:normal;word-spacing:normal}.w-e-text-container [data-slate-editor] pre>code .token.cdata,.w-e-text-container [data-slate-editor] pre>code .token.comment,.w-e-text-container [data-slate-editor] pre>code .token.doctype,.w-e-text-container [data-slate-editor] pre>code .token.prolog{color:#708090}.w-e-text-container [data-slate-editor] pre>code .token.punctuation{color:#999}.w-e-text-container [data-slate-editor] pre>code .token.namespace{opacity:.7}.w-e-text-container [data-slate-editor] pre>code .token.boolean,.w-e-text-container [data-slate-editor] pre>code .token.constant,.w-e-text-container [data-slate-editor] pre>code .token.deleted,.w-e-text-container [data-slate-editor] pre>code .token.number,.w-e-text-container [data-slate-editor] pre>code .token.property,.w-e-text-container [data-slate-editor] pre>code .token.symbol,.w-e-text-container [data-slate-editor] pre>code .token.tag{color:#905}.w-e-text-container [data-slate-editor] pre>code .token.attr-name,.w-e-text-container [data-slate-editor] pre>code .token.builtin,.w-e-text-container [data-slate-editor] pre>code .token.char,.w-e-text-container [data-slate-editor] pre>code .token.inserted,.w-e-text-container [data-slate-editor] pre>code .token.selector,.w-e-text-container [data-slate-editor] pre>code .token.string{color:#690}.w-e-text-container [data-slate-editor] pre>code .language-css .token.string,.w-e-text-container [data-slate-editor] pre>code .style .token.string,.w-e-text-container [data-slate-editor] pre>code .token.entity,.w-e-text-container [data-slate-editor] pre>code .token.operator,.w-e-text-container [data-slate-editor] pre>code .token.url{color:#9a6e3a}.w-e-text-container [data-slate-editor] pre>code .token.atrule,.w-e-text-container [data-slate-editor] pre>code .token.attr-value,.w-e-text-container [data-slate-editor] pre>code .token.keyword{color:#07a}.w-e-text-container [data-slate-editor] pre>code .token.class-name,.w-e-text-container [data-slate-editor] pre>code .token.function{color:#dd4a68}.w-e-text-container [data-slate-editor] pre>code .token.important,.w-e-text-container [data-slate-editor] pre>code .token.regex,.w-e-text-container [data-slate-editor] pre>code .token.variable{color:#e90}.w-e-text-container [data-slate-editor] pre>code .token.bold,.w-e-text-container [data-slate-editor] pre>code .token.important{font-weight:700}.w-e-text-container [data-slate-editor] pre>code .token.italic{font-style:italic}.w-e-text-container [data-slate-editor] pre>code .token.entity{cursor:help} \ No newline at end of file diff --git a/details.html b/details.html index e9f9cec..cb6d73b 100644 --- a/details.html +++ b/details.html @@ -18,7 +18,7 @@
-
fi88yrHXiDSj
+
qXi0yrL189WW
@@ -211,41 +211,38 @@
-
- -
{{ item.nickname || item.user["nickname"] || "匿名用户" }}
-
{{ item["timestamp"] }}
-
作者
- + +
{{ item.nickname || item.user["nickname"] || "匿名用户" }}
+
{{ item["timestamp"] }}
+
作者
+ -
- - - 发送信息 - - - - TA的主页 - -
+ + + -
- - - + +
@@ -285,39 +282,35 @@
-
- -
{{ ite.nickname || ite.user["nickname"] || "匿名用户" }}
-
{{ ite["timestamp"] }}
-
作者
- -
- - - 发送信息 - - - - TA的主页 - -
+ +
{{ ite.nickname || ite.user["nickname"] || "匿名用户" }}
+
{{ ite["timestamp"] }}
+
作者
+ + + -
- - - + +
diff --git a/edit.html b/edit.html index 27d94e0..44c7100 100644 --- a/edit.html +++ b/edit.html @@ -7,21 +7,40 @@ 发布帖子 - 轻论坛 + + + + + +
- - - +
发帖
发帖奖励 3 个寄托币/篇,每天最高奖励3篇
@@ -32,63 +51,68 @@
- +
{{ info?.title?.length ? titleLength - info?.title?.length : titleLength }}
+
- -
-
- 段落标题 - 段落标题 -
-
- 图片 - 图片 - -
-
- 视频 - 视频 - -
-
- 表情 - 表情 -
-
-
{{ emoji }}
-
-
-