Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
lib
react-ag-qeditor
Commits
6c1501b1
Commit
6c1501b1
authored
Apr 17, 2026
by
Яков
Browse files
update image
parent
0b426860
Changes
2
Show whitespace changes
Inline
Side-by-side
package.json
View file @
6c1501b1
{
{
"name"
:
"react-ag-qeditor"
,
"name"
:
"react-ag-qeditor"
,
"version"
:
"1.1.3
6
"
,
"version"
:
"1.1.3
7
"
,
"description"
:
"WYSIWYG html editor"
,
"description"
:
"WYSIWYG html editor"
,
"author"
:
"atma"
,
"author"
:
"atma"
,
"license"
:
"
MIT
"
,
"license"
:
"
MIT
"
,
...
...
src/extensions/Image.jsx
View file @
6c1501b1
...
@@ -380,7 +380,13 @@ const ResizableImageTemplate = ({ node, updateAttributes, editor, getPos, select
...
@@ -380,7 +380,13 @@ const ResizableImageTemplate = ({ node, updateAttributes, editor, getPos, select
const
sharedMargin
=
{
marginTop
:
'
0.5rem
'
,
marginBottom
:
'
0.5rem
'
};
const
sharedMargin
=
{
marginTop
:
'
0.5rem
'
,
marginBottom
:
'
0.5rem
'
};
if
(
align
===
'
center
'
)
{
if
(
align
===
'
center
'
)
{
return
{
...
sharedMargin
,
display
:
'
block
'
,
lineHeight
:
0
};
// Используем float:left+width:100% чтобы не создавать block-in-inline внутри <p>
// (иначе параграф получает лишнюю высоту). textAlign:center центрирует внутренний inline-block.
return
{
...
sharedMargin
,
lineHeight
:
0
,
display
:
'
inline-block
'
,
float
:
'
left
'
,
clear
:
'
both
'
,
width
:
'
100%
'
,
textAlign
:
'
center
'
,
};
}
}
if
(
!
wrap
)
{
if
(
!
wrap
)
{
// no-wrap: float:left + width:100% — занимает всю строку, текст не может встать рядом.
// no-wrap: float:left + width:100% — занимает всю строку, текст не может встать рядом.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment