Show clipboard contents in multiple line paste warning dialog#8744
Conversation
| </data> | ||
| <data name="MultiLinePasteDialog.Content" xml:space="preserve"> | ||
| <value>You are about to paste text that contains multiple lines. If you paste this text into your shell, it may result in the unexpected execution of commands. Do you wish to continue?</value> | ||
| <data name="MultiLineWarningText.Text" xml:space="preserve"> |
There was a problem hiding this comment.
i wish we didn't have to change the key for this. I know why we have to, but this will trigger a re-localization for a string that is almost exactly the same.
|
Should we introduce a limit, say 10 lines, after which we insert a |
Hm I feel like since we have the scrollbar we don't need to truncate the content (and if the user does not want to see their large pastes they could just use the setting to disable multi line paste warnings) |
zadjii-msft
left a comment
There was a problem hiding this comment.
okay yea this seems good to me
| </TextBlock> | ||
| <ScrollViewer | ||
| Margin="0,8,0,0" | ||
| x:Name="ClipboardContentScrollViewer" |
There was a problem hiding this comment.
We don't need to name infrastructural components unless we refer to them in code 😄
There was a problem hiding this comment.
We actually refer to this one! To reset the scroll offset (the scroll offset does not reset automatically in between calls to open the dialog)
|
Hello @DHowett! Because this pull request has the p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me (
|
|
🎉 Handy links: |
…oft#8744) When we display a dialog to warn the user that they are doing a multi-line paste, we show the clipboard contents The contents are shown in a scroll viewer with a fixed maximum height. Closes microsoft#7997

When we display a dialog to warn the user that they are doing a
multi-line paste, we show the clipboard contents
The contents are shown in a scroll viewer with a fixed maximum height.
Closes #7997