Files
AFFiNE-Mirror/blocksuite/affine/blocks/embed/src/common/embed-note-content-styles.ts
L-Sun 7879e12718 fix(editor): comment style and creation issues (#13006)
#### PR Dependency Tree


* **PR #13006** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Style**
* Updated embedded note content to remove background color and underline
from inline comments for a cleaner appearance.

* **Bug Fixes**
* Improved comment functionality by ensuring comments are only added to
blocks without text content.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-07-03 10:08:00 +00:00

86 lines
2.7 KiB
TypeScript

import { css } from 'lit';
export const embedNoteContentStyles = css`
.affine-embed-doc-content-note-blocks affine-divider,
.affine-embed-doc-content-note-blocks affine-divider > * {
margin-top: 0px !important;
margin-bottom: 0px !important;
padding-top: 8px;
padding-bottom: 8px;
}
.affine-embed-doc-content-note-blocks affine-paragraph,
.affine-embed-doc-content-note-blocks affine-list {
margin-top: 4px !important;
margin-bottom: 4px !important;
padding: 0 2px;
}
.affine-embed-doc-content-note-blocks affine-paragraph *,
.affine-embed-doc-content-note-blocks affine-list * {
margin-top: 0px !important;
margin-bottom: 0px !important;
padding-top: 0;
padding-bottom: 0;
line-height: 20px;
font-size: var(--affine-font-xs);
font-weight: 400;
}
.affine-embed-doc-content-note-blocks affine-list .affine-list-block__prefix {
height: 20px;
}
.affine-embed-doc-content-note-blocks affine-paragraph .quote {
padding-left: 15px;
padding-top: 8px;
padding-bottom: 8px;
}
.affine-embed-doc-content-note-blocks affine-paragraph:has(.h1),
.affine-embed-doc-content-note-blocks affine-paragraph:has(.h2),
.affine-embed-doc-content-note-blocks affine-paragraph:has(.h3),
.affine-embed-doc-content-note-blocks affine-paragraph:has(.h4),
.affine-embed-doc-content-note-blocks affine-paragraph:has(.h5),
.affine-embed-doc-content-note-blocks affine-paragraph:has(.h6) {
margin-top: 6px !important;
margin-bottom: 4px !important;
padding: 0 2px;
}
.affine-embed-doc-content-note-blocks affine-paragraph:has(.h1) *,
.affine-embed-doc-content-note-blocks affine-paragraph:has(.h2) *,
.affine-embed-doc-content-note-blocks affine-paragraph:has(.h3) *,
.affine-embed-doc-content-note-blocks affine-paragraph:has(.h4) *,
.affine-embed-doc-content-note-blocks affine-paragraph:has(.h5) *,
.affine-embed-doc-content-note-blocks affine-paragraph:has(.h6) * {
margin-top: 0px !important;
margin-bottom: 0px !important;
padding-top: 0;
padding-bottom: 0;
line-height: 20px;
font-size: var(--affine-font-xs);
font-weight: 600;
}
.affine-embed-doc-content-note-blocks inline-comment {
background-color: unset !important;
border-bottom: unset !important;
}
.affine-embed-linked-doc-block.horizontal {
affine-paragraph,
affine-list {
margin-top: 0 !important;
margin-bottom: 0 !important;
max-height: 40px;
overflow: hidden;
display: flex;
}
affine-paragraph .quote {
padding-top: 4px;
padding-bottom: 4px;
height: 28px;
}
affine-paragraph .quote::after {
height: 20px;
margin-top: 4px !important;
margin-bottom: 4px !important;
}
}
`;