进行了一些小修复

This commit is contained in:
kate522 committed 2026-08-26 21:23:55 +08:00
1 parent 8111b17392
commit f143a111cd
3 files changed
+28 -61

No files matched your search

+3 -38
View File
@@ -1,24 +1,5 @@
/* Front-end article editor — follows the reference theme's newposts page. */ /* Front-end article editor — follows the reference theme's newposts page. */
.newposts-wrap { #aksrt-submit-form .zib-widget {
display: flex;
align-items: flex-start;
gap: 15px;
width: 100%;
margin: 20px 0 30px;
}
.newposts-wrap > .content-layout {
flex: 1 1 auto;
min-width: 0;
}
.newposts-wrap > .sidebar {
display: block;
flex: 0 0 300px;
width: 300px;
}
.newposts-wrap .zib-widget {
margin-bottom: 15px; margin-bottom: 15px;
padding: 15px; padding: 15px;
border-radius: var(--main-radius, 8px); border-radius: var(--main-radius, 8px);
@@ -516,33 +497,17 @@ body.aksrt-editor-media-open {
margin-right: 4px; margin-right: 4px;
} }
.newposts-wrap [hidden] { #aksrt-submit-form [hidden] {
display: none !important; display: none !important;
} }
.newposts-wrap .new-posts-submit {
display: inline-flex;
align-items: center;
justify-content: center;
white-space: nowrap;
}
@media (max-width: 991px) { @media (max-width: 991px) {
.newposts-wrap { body .newposts-wrap {
display: block;
float: none; float: none;
} }
.newposts-wrap > .sidebar {
width: 100%;
}
} }
@media (max-width: 767px) { @media (max-width: 767px) {
.newposts-wrap {
margin-top: 10px;
}
.newposts-wrap .zib-widget { .newposts-wrap .zib-widget {
border-radius: 0; border-radius: 0;
} }
+18 -18
View File
@@ -223,24 +223,24 @@ get_header();
} }
?> ?>
</div> </div>
<aside class="sidebar show-sidebar"> </div>
<?php \AKSRT\WidgetSystem\WidgetAreas::render('newposts_sidebar_top'); ?> <div class="sidebar show-sidebar">
<?php <?php \AKSRT\WidgetSystem\WidgetAreas::render('newposts_sidebar_top'); ?>
$terms = get_template_directory() . '/templates/parts/submit/sidebar-terms.php'; <?php
if (file_exists($terms)) { $terms = get_template_directory() . '/templates/parts/submit/sidebar-terms.php';
include $terms; if (file_exists($terms)) {
} include $terms;
$pay = get_template_directory() . '/templates/parts/submit/sidebar-pay.php'; }
if (file_exists($pay)) { $pay = get_template_directory() . '/templates/parts/submit/sidebar-pay.php';
include $pay; if (file_exists($pay)) {
} include $pay;
$actions = get_template_directory() . '/templates/parts/submit/sidebar-submit.php'; }
if (file_exists($actions)) { $actions = get_template_directory() . '/templates/parts/submit/sidebar-submit.php';
include $actions; if (file_exists($actions)) {
} include $actions;
?> }
<?php \AKSRT\WidgetSystem\WidgetAreas::render('newposts_sidebar_bottom'); ?> ?>
</aside> <?php \AKSRT\WidgetSystem\WidgetAreas::render('newposts_sidebar_bottom'); ?>
</div> </div>
</form> </form>
</main> </main>
@@ -43,7 +43,8 @@ test('front submit follows the reference newposts shell and cards', () => {
assert.match(page, /content-wrap newposts-wrap/); assert.match(page, /content-wrap newposts-wrap/);
assert.match(page, /class="content-layout"/); assert.match(page, /class="content-layout"/);
assert.match(page, /class="sidebar show-sidebar"/); assert.match(page, /<\/div>\s*<\/div>\s*<div class="sidebar show-sidebar">/);
assert.equal((page.match(/class="sidebar show-sidebar"/g) || []).length, 1);
assert.match(main, /zib-widget full-widget-sm editor-main-box/); assert.match(main, /zib-widget full-widget-sm editor-main-box/);
assert.match(main, /relative newposts-title/); assert.match(main, /relative newposts-title/);
assert.match(terms, /newpost-cat-drop drop-select dropdown dependency-box/); assert.match(terms, /newpost-cat-drop drop-select dropdown dependency-box/);
@@ -58,10 +59,11 @@ test('front submit follows the reference newposts shell and cards', () => {
assert.match(pay, /pay-dawnload-edit/); assert.match(pay, /pay-dawnload-edit/);
assert.match(submit, /separator muted-3-color theme-box/); assert.match(submit, /separator muted-3-color theme-box/);
assert.match(submit, /new-posts-submit/); assert.match(submit, /new-posts-submit/);
assert.match(submitCss, /\.newposts-wrap \.new-posts-submit\s*{[^}]*display:\s*inline-flex;[^}]*white-space:\s*nowrap;/); assert.match(mainCss, /\.but-average > \.but\s*{[^}]*flex:\s*auto;/);
assert.doesNotMatch(submitCss, /\.newposts-wrap \.but-average\s*>\s*\*\s*{[^}]*flex:\s*1 1 0;/); assert.match(mainCss, /body \.sidebar\.show-sidebar\s*{[^}]*display:\s*unset;[^}]*width:\s*100%;[^}]*margin-left:\s*0;/);
assert.match(mobileSubmitCss, /\.newposts-wrap\s*{[^}]*display:\s*block;/); assert.match(mobileSubmitCss, /body \.newposts-wrap\s*{[^}]*float:\s*none;/);
assert.match(mobileSubmitCss, /\.newposts-wrap > \.sidebar\s*{[^}]*width:\s*100%;/); assert.doesNotMatch(submitCss, /\.newposts-wrap\s*>\s*\.(?:content-layout|sidebar)/);
assert.doesNotMatch(submitCss, /\.newposts-wrap \.new-posts-submit/);
}); });
test('front submit paid resources use the reference modal editor and compact list', () => { test('front submit paid resources use the reference modal editor and compact list', () => {