feat: 构建品牌视图与三栏页面编辑工作台
This commit is contained in:
1 parent
a2932b1134
commit
860d9266fe
7 files changed
+128
-20
No files matched your search
@@ -570,8 +570,8 @@ export function PresentationEditor({
|
||||
/>
|
||||
)}
|
||||
</Space>
|
||||
<Row className="presentation-editor__workspace" gutter={[24, 24]} align="top">
|
||||
<Col className="presentation-editor__preview" xs={24} lg={12}>
|
||||
<div className="presentation-editor__workspace">
|
||||
<div className="presentation-editor__preview">
|
||||
<Typography.Title level={5}>页面预览</Typography.Title>
|
||||
{selectedPage === "detail" && draftWorkspace?.offerings.length ? (
|
||||
<Select
|
||||
@@ -600,11 +600,21 @@ export function PresentationEditor({
|
||||
targets={visibleTargets}
|
||||
onTargetSelected={handleTargetSelected}
|
||||
/>
|
||||
</div>
|
||||
<aside className="presentation-editor__outline" aria-label="页面区域">
|
||||
<Typography.Title level={5}>页面区域</Typography.Title>
|
||||
<Typography.Paragraph type="secondary">选择区域,编辑对应内容</Typography.Paragraph>
|
||||
{visibleTargets.length ? (
|
||||
<Space className="presentation-editor__regions" wrap style={{ marginTop: 16 }}>
|
||||
{visibleTargets.map((target) => (
|
||||
<Button
|
||||
key={target.key}
|
||||
className={
|
||||
visibleTargets.some((parent) => parent.children?.includes(target.key))
|
||||
? "is-child-region"
|
||||
: ""
|
||||
}
|
||||
aria-pressed={activeTarget === target.key}
|
||||
type={activeTarget === target.key ? "primary" : "default"}
|
||||
onClick={() => {
|
||||
const recordId =
|
||||
@@ -628,8 +638,11 @@ export function PresentationEditor({
|
||||
))}
|
||||
</Space>
|
||||
) : null}
|
||||
</Col>
|
||||
<Col className="presentation-editor__inspector" xs={24} lg={12}>
|
||||
{!visibleTargets.length ? (
|
||||
<Typography.Text type="secondary">此页为动态预览</Typography.Text>
|
||||
) : null}
|
||||
</aside>
|
||||
<div className="presentation-editor__inspector">
|
||||
<Typography.Title level={5}>
|
||||
{selectedTarget?.label ?? pageTitle(selectedPage ?? "home")}
|
||||
</Typography.Title>
|
||||
@@ -865,8 +878,8 @@ export function PresentationEditor({
|
||||
</Space>
|
||||
</Form>
|
||||
)}
|
||||
</Col>
|
||||
</Row>
|
||||
</div>
|
||||
</div>
|
||||
</>
|
||||
) : null}
|
||||
</section>
|
||||
|
||||
Reference in new issue
Block a user