fix(core): unexpected response style of shared page (#6383)

This commit is contained in:
JimmFly
2024-03-29 05:29:54 +00:00
parent c7e10c2283
commit 2576a69eb6
3 changed files with 20 additions and 1 deletions
@@ -9,6 +9,18 @@ export const editor = style({
}, },
}, },
}, },
'@media': {
'screen and (max-width: 800px)': {
selectors: {
'&.is-public': {
vars: {
'--affine-editor-width': '100%',
'--affine-editor-side-padding': '24px',
},
},
},
},
},
}); });
globalStyle( globalStyle(
`${editor} .affine-page-viewport:not(.affine-embed-synced-doc-editor)`, `${editor} .affine-page-viewport:not(.affine-embed-synced-doc-editor)`,
@@ -104,7 +104,8 @@ const PageDetailEditorMain = memo(function PageDetailEditorMain({
return ( return (
<Editor <Editor
className={clsx(styles.editor, { className={clsx(styles.editor, {
'full-screen': appSettings.fullWidthLayout, 'full-screen': !isPublic && appSettings.fullWidthLayout,
'is-public': isPublic,
})} })}
style={ style={
{ {
@@ -14,6 +14,12 @@ export const footerContainer = style({
paddingLeft: cssVar('editorSidePadding'), paddingLeft: cssVar('editorSidePadding'),
paddingRight: cssVar('editorSidePadding'), paddingRight: cssVar('editorSidePadding'),
marginBottom: '200px', marginBottom: '200px',
'@media': {
'screen and (max-width: 800px)': {
paddingLeft: '24px',
paddingRight: '24px',
},
},
}); });
export const footer = style({ export const footer = style({
display: 'flex', display: 'flex',