Scheudled post show more (#29226)
* Added show more to long draft adn scheduled post * Added show more to long draft adn scheduled post * Fixed layout * Updated snapshots
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
b0ee1627f0
Коммит
da937b0598
@@ -116,6 +116,30 @@ exports[`components/drafts/panel/panel_body should have called handleFormattedTe
|
|||||||
</ProfilePopoverController>
|
</ProfilePopoverController>
|
||||||
</ProfilePicture>
|
</ProfilePicture>
|
||||||
</div>
|
</div>
|
||||||
|
<div
|
||||||
|
className="DraftPanelBody__post_body"
|
||||||
|
>
|
||||||
|
<Connect(ShowMore)
|
||||||
|
text="message"
|
||||||
|
>
|
||||||
|
<ShowMore
|
||||||
|
compactDisplay={false}
|
||||||
|
dispatch={[Function]}
|
||||||
|
isRHSExpanded={false}
|
||||||
|
isRHSOpen={false}
|
||||||
|
text="message"
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
className="post-message post-message--collapsed"
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
className="post-message__text-container"
|
||||||
|
style={
|
||||||
|
Object {
|
||||||
|
"maxHeight": 600,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
>
|
||||||
<div
|
<div
|
||||||
className="post__content"
|
className="post__content"
|
||||||
onClick={[Function]}
|
onClick={[Function]}
|
||||||
@@ -193,6 +217,11 @@ exports[`components/drafts/panel/panel_body should have called handleFormattedTe
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
</ShowMore>
|
||||||
|
</Connect(ShowMore)>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</PanelBody>
|
</PanelBody>
|
||||||
</Provider>
|
</Provider>
|
||||||
`;
|
`;
|
||||||
@@ -313,6 +342,30 @@ exports[`components/drafts/panel/panel_body should match snapshot 1`] = `
|
|||||||
</ProfilePopoverController>
|
</ProfilePopoverController>
|
||||||
</ProfilePicture>
|
</ProfilePicture>
|
||||||
</div>
|
</div>
|
||||||
|
<div
|
||||||
|
className="DraftPanelBody__post_body"
|
||||||
|
>
|
||||||
|
<Connect(ShowMore)
|
||||||
|
text="message"
|
||||||
|
>
|
||||||
|
<ShowMore
|
||||||
|
compactDisplay={false}
|
||||||
|
dispatch={[Function]}
|
||||||
|
isRHSExpanded={false}
|
||||||
|
isRHSOpen={false}
|
||||||
|
text="message"
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
className="post-message post-message--collapsed"
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
className="post-message__text-container"
|
||||||
|
style={
|
||||||
|
Object {
|
||||||
|
"maxHeight": 600,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
>
|
||||||
<div
|
<div
|
||||||
className="post__content"
|
className="post__content"
|
||||||
onClick={[Function]}
|
onClick={[Function]}
|
||||||
@@ -390,6 +443,11 @@ exports[`components/drafts/panel/panel_body should match snapshot 1`] = `
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
</ShowMore>
|
||||||
|
</Connect(ShowMore)>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</PanelBody>
|
</PanelBody>
|
||||||
</Provider>
|
</Provider>
|
||||||
`;
|
`;
|
||||||
@@ -516,6 +574,30 @@ exports[`components/drafts/panel/panel_body should match snapshot for priority 1
|
|||||||
</ProfilePopoverController>
|
</ProfilePopoverController>
|
||||||
</ProfilePicture>
|
</ProfilePicture>
|
||||||
</div>
|
</div>
|
||||||
|
<div
|
||||||
|
className="DraftPanelBody__post_body"
|
||||||
|
>
|
||||||
|
<Connect(ShowMore)
|
||||||
|
text="message"
|
||||||
|
>
|
||||||
|
<ShowMore
|
||||||
|
compactDisplay={false}
|
||||||
|
dispatch={[Function]}
|
||||||
|
isRHSExpanded={false}
|
||||||
|
isRHSOpen={false}
|
||||||
|
text="message"
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
className="post-message post-message--collapsed"
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
className="post-message__text-container"
|
||||||
|
style={
|
||||||
|
Object {
|
||||||
|
"maxHeight": 600,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
>
|
||||||
<div
|
<div
|
||||||
className="post__content"
|
className="post__content"
|
||||||
onClick={[Function]}
|
onClick={[Function]}
|
||||||
@@ -655,6 +737,11 @@ exports[`components/drafts/panel/panel_body should match snapshot for priority 1
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
</ShowMore>
|
||||||
|
</Connect(ShowMore)>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</PanelBody>
|
</PanelBody>
|
||||||
</Provider>
|
</Provider>
|
||||||
`;
|
`;
|
||||||
@@ -781,6 +868,30 @@ exports[`components/drafts/panel/panel_body should match snapshot for requested_
|
|||||||
</ProfilePopoverController>
|
</ProfilePopoverController>
|
||||||
</ProfilePicture>
|
</ProfilePicture>
|
||||||
</div>
|
</div>
|
||||||
|
<div
|
||||||
|
className="DraftPanelBody__post_body"
|
||||||
|
>
|
||||||
|
<Connect(ShowMore)
|
||||||
|
text="message"
|
||||||
|
>
|
||||||
|
<ShowMore
|
||||||
|
compactDisplay={false}
|
||||||
|
dispatch={[Function]}
|
||||||
|
isRHSExpanded={false}
|
||||||
|
isRHSOpen={false}
|
||||||
|
text="message"
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
className="post-message post-message--collapsed"
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
className="post-message__text-container"
|
||||||
|
style={
|
||||||
|
Object {
|
||||||
|
"maxHeight": 600,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
>
|
||||||
<div
|
<div
|
||||||
className="post__content"
|
className="post__content"
|
||||||
onClick={[Function]}
|
onClick={[Function]}
|
||||||
@@ -991,6 +1102,11 @@ exports[`components/drafts/panel/panel_body should match snapshot for requested_
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
</ShowMore>
|
||||||
|
</Connect(ShowMore)>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</PanelBody>
|
</PanelBody>
|
||||||
</Provider>
|
</Provider>
|
||||||
`;
|
`;
|
||||||
|
|||||||
@@ -70,6 +70,12 @@ describe('components/drafts/panel/panel_body', () => {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
views: {
|
||||||
|
rhs: {
|
||||||
|
isSidebarExpanded: false,
|
||||||
|
isSidebarOpen: false,
|
||||||
|
},
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
it('should match snapshot', () => {
|
it('should match snapshot', () => {
|
||||||
|
|||||||
@@ -12,6 +12,7 @@ import {getCurrentRelativeTeamUrl} from 'mattermost-redux/selectors/entities/tea
|
|||||||
import PriorityLabels from 'components/advanced_text_editor/priority_labels';
|
import PriorityLabels from 'components/advanced_text_editor/priority_labels';
|
||||||
import FilePreview from 'components/file_preview';
|
import FilePreview from 'components/file_preview';
|
||||||
import Markdown from 'components/markdown';
|
import Markdown from 'components/markdown';
|
||||||
|
import ShowMore from 'components/post_view/show_more';
|
||||||
import ProfilePicture from 'components/profile_picture';
|
import ProfilePicture from 'components/profile_picture';
|
||||||
|
|
||||||
import {imageURLForUser, handleFormattedTextClick} from 'utils/utils';
|
import {imageURLForUser, handleFormattedTextClick} from 'utils/utils';
|
||||||
@@ -66,6 +67,10 @@ function PanelBody({
|
|||||||
src={imageURLForUser(userId)}
|
src={imageURLForUser(userId)}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
<div className='DraftPanelBody__post_body'>
|
||||||
|
<ShowMore
|
||||||
|
text={message}
|
||||||
|
>
|
||||||
<div
|
<div
|
||||||
onClick={handleClick}
|
onClick={handleClick}
|
||||||
className='post__content'
|
className='post__content'
|
||||||
@@ -90,6 +95,9 @@ function PanelBody({
|
|||||||
message={message}
|
message={message}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</ShowMore>
|
||||||
{(fileInfos.length > 0 || uploadsInProgress?.length > 0) && (
|
{(fileInfos.length > 0 || uploadsInProgress?.length > 0) && (
|
||||||
<FilePreview
|
<FilePreview
|
||||||
fileInfos={fileInfos}
|
fileInfos={fileInfos}
|
||||||
@@ -98,7 +106,6 @@ function PanelBody({
|
|||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user