-
-
Notifications
You must be signed in to change notification settings - Fork 84
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enhancement: UX Improvements to the sidebar panel/tool window #705
Comments
This has been added for when working with previews. Originally, it wasn't added, but when you open a preview in VS Code, you go to a new view. When working with multiple articles, you might lose the context. So based on feedback, the filename has been added to the panel.
The problem is that only a couple of actions can be shown. The others will be hidden within the menu. As much as I like the idea, having these actions in the panel is still easier as they will always be at the same location, so the user doesn't have to open an additional menu to find other actions. |
(quick info — I passed the following message through GPT to help me in wording/redaction/convey my message more clearly. I am not yet that proficient in english to write good feedback without bloating my message needlessly >-<) Good point about alert fatigue. However, I have some concerns about the proposed solution and the updated mocks:
Regarding error fatigue:
As a final tangent: consider using the VS Code's built in "Problems" view and problem matcher to report and resolve the issues. |
And here is a mock. The details would need some working on. For example we could show a green tick badge when there are no problems to indicate "resolved issues" as in the feedback from the other guy. Or even better, instead of "problems" it would be "steps to do" and shown as 5/5 when everything is OK (hover over shows a list of the current 5 items) and if some errors are present, then it's presented as e.g. 3/5 and a warning icon. You could also merge the keyword frequency with the issues and make 6/6 where one of them is "keyword frequency too high/low" (because on the following mock there would be two icons - for issues and keywords - next to each other which may be still too much) |
Improved mock with "checks" for each keyword (colored frequency label to reconsider, white may look better). Also the badge with problems could be done in negative for better look, but is harder to draw for me in the mock. The tooltip when hovering over the "checks" badge could show a list with icons and items for each one, with green tick for completed item and yellow warning icon for item needing attention. |
Last mockup looks great 😊 and your thoughts about how the keyword section should behave make total sense. I'm not sure yet about the insights section, although it already looks way cleaner and structured. |
Looking lovely!!! For some minor adjustments, center the "checks" column header and center the badges in that column, both horizontally and vertically within the rows. You can see if using "Frequency" instead of "Freq." fits, there seems to be enough space in the header if the icons next to the frequency are present. I used shortened "Freq." in the mock when I removed the icons. |
Do labels and the checks badge hit the contrast ratio under dark theme? If not, consider doing white text on green/yellow background for the badges (and for frequency). What do you think about centering "Checks" and "Frequency" column haders? When it comes to frequency numbers it could be added to the checks with "Keyword frequency between x-y". On a second thought, depending only on the color of the label may not be a good idea from the accessibility standpoint, so the previous icon + black label for frequency could have been actually better. As for the badges (based on this source) maybe consider using some slight, dimmed colored background. Alternatively dark solid background and light text to hit the contrast ratio. And also now thanks to the tooltip the check names can be made more descriptive, like "present in the title" instead of some "title". And icons placed before the text to align them vertically and tidy it up a bit. |
|
I'm testing the current beta branch and it's looking good. Things I noticed for now (aside from some small bugs like resizable observer errors and frequency not updating):
I didn't see any centering issues when I tested locally, keywords indeed look fine. For a small adjustments I would use a 2:1 padding scale for X:Y padding in the padding for keyword and the checks badge, also making them slightly shorter in height and but wider. I checked out the beta branch locally to see for myself how it looks like, because I don't want to be only talking without doing something myself :) Also here is a reference for badges from some other product I found online which imo looks good (notice the heavier font weight, simplicity without borders and how they are wider than taller): Does VSCode has some design system? If not, then github's Primer is a good foundation that I think is very similar and fitting VSCode, so some elements could be copied from there. |
If you are interested here is the patch of changes I did to perform small tweaks (the patch would need revision, it makes some changes in place): Patch on top of 42fe1c2diff --git a/src/dashboardWebView/components/css-vscode-variables.css b/src/dashboardWebView/components/css-vscode-variables.css
index 6d5e566a..27ccb164 100644
--- a/src/dashboardWebView/components/css-vscode-variables.css
+++ b/src/dashboardWebView/components/css-vscode-variables.css
@@ -338,6 +338,7 @@
--vscode-statusBarItem-errorBackground: #611708;
--vscode-statusBarItem-errorForeground: #ffffff;
--vscode-statusBarItem-warningBackground: #725102;
+ --vscode-statusBarItem-warningText: #cdab11;
--vscode-statusBarItem-warningForeground: #ffffff;
--vscode-activityBar-background: #ddd6c1;
--vscode-activityBar-foreground: #584c27;
diff --git a/src/localization/localization.enum.ts b/src/localization/localization.enum.ts
index f4cac251..4173d25b 100644
--- a/src/localization/localization.enum.ts
+++ b/src/localization/localization.enum.ts
@@ -1613,7 +1613,7 @@ export enum LocalizationKey {
*/
panelSeoKeywordsDensity = 'panel.seoKeywords.density',
/**
- * Used in heading(s)
+ * Heading(s)
*/
panelSeoKeywordInfoValidInfoLabel = 'panel.seoKeywordInfo.validInfo.label',
/**
diff --git a/src/panelWebView/components/SeoKeywordInfo.tsx b/src/panelWebView/components/SeoKeywordInfo.tsx
index 871a5e01..d0e65fa7 100644
--- a/src/panelWebView/components/SeoKeywordInfo.tsx
+++ b/src/panelWebView/components/SeoKeywordInfo.tsx
@@ -42,11 +42,11 @@ const SeoKeywordInfo: React.FunctionComponent<ISeoKeywordInfoProps> = ({
const densityTitle = `${density.toFixed(2)}* %`;
if (density < 0.75) {
- return <span className='text-[12px] text-[var(--vscode-statusBarItem-warningBackground)]'>{densityTitle}</span>;
+ return <span className='text-[12px] text-[#cdab11]'>{densityTitle}</span>;
} else if (density >= 0.75 && density < 1.5) {
return <span className='text-[12px] text-[var(--vscode-charts-green)]'>{densityTitle}</span>;
} else {
- return <span className='text-[12px] text-[var(--vscode-statusBarItem-warningBackground)]'>{densityTitle}</span>;
+ return <span className='text-[12px] text-[#cdab11]'>{densityTitle}</span>;
}
};
@@ -116,7 +116,10 @@ const SeoKeywordInfo: React.FunctionComponent<ISeoKeywordInfoProps> = ({
return (
<div
- className={`inline-flex py-1 px-[4px] rounded-[3px] justify-center items-center text-[12px] leading-[16px] border border-solid ${isValid ? "text-[--vscode-charts-green] border-[--vscode-charts-green] bg-[--frontmatter-success-background]" : "text-[var(--vscode-statusBarItem-warningBackground)] border-[var(--vscode-statusBarItem-warningBackground)] bg-[--frontmatter-warning-background]"}`}
+ className={`inline-flex py-1 px-2 rounded-[3px] justify-center items-center text-[12px] leading-[16px] border border-solid
+ ${isValid
+ ? "text-[--vscode-charts-green] border-[--vscode-charts-green] bg-[--frontmatter-success-background]"
+ : "text-[#cdab11] border-[var(--vscode-statusBarItem-warningText)] bg-[--frontmatter-warning-background]"}`}
data-tooltip-id={`tooltip-checks-${keyword}`}
>
<ValidInfo isValid={isValid} />
@@ -137,7 +140,7 @@ const SeoKeywordInfo: React.FunctionComponent<ISeoKeywordInfoProps> = ({
<div className='flex h-full items-center'>
<Tag
value={keyword}
- className={`!w-full !justify-between !mx-0 !my-1 !px-2 !py-1`}
+ className={`!w-full !justify-between !mx-0 !my-1 !px-2 !py-0.5`}
onRemove={onRemove}
onCreate={() => void 0}
title={localize(LocalizationKey.panelTagsTagWarning, keyword)}
diff --git a/src/panelWebView/components/ValidInfo.tsx b/src/panelWebView/components/ValidInfo.tsx
index 8120aada..189ee025 100644
--- a/src/panelWebView/components/ValidInfo.tsx
+++ b/src/panelWebView/components/ValidInfo.tsx
@@ -15,11 +15,11 @@ const ValidInfo: React.FunctionComponent<IValidInfoProps> = ({
return (
<div className='inline-flex items-center h-full'>
{isValid ? (
- <CheckIcon className={`h-4 w-4 text-[var(--vscode-charts-green)] mr-2`} />
+ <CheckIcon className={`h-5 w-5 text-[var(--vscode-charts-green)] mr-2`} />
) : (
- <ExclamationTriangleIcon className={`h-4 w-4 text-[var(--vscode-statusBarItem-warningBackground)] mr-2`} />
+ <ExclamationTriangleIcon className={`h-5 w-5 text-[#cdab11] mr-2`} />
)}
- {label && <span className={className || ""}>{label}</span>}
+ {label && <span className={className || ""}><b>{label}</b></span>}
</div>
);
};
diff --git a/src/panelWebView/styles.css b/src/panelWebView/styles.css
index 355be5f5..b0e76cf9 100644
--- a/src/panelWebView/styles.css
+++ b/src/panelWebView/styles.css
@@ -897,6 +897,10 @@ vscode-divider {
.tag .tag__delete {
margin-left: 0.25rem;
+
+ & svg {
+ stroke-width: 3;
+ }
}
.tag .tag__delete:hover {
@@ -911,7 +915,8 @@ vscode-divider {
.tag .tag__value {
flex-grow: 1;
- white-space: nowrap;
+ white-space: pre-wrap;
+ font-weight: 600;
}
/* Slug field */ And the changes look like that: |
@T3sT3ro would you be able to create a PR for this? That way you become part of the contributors list. |
Yeah, I could try later today 👍 |
I was reviewing your code changes. You cannot add anything to the We need to work with the variables VS Code provides us. |
Oh, good, I also didn't get why it wasn't working in there. Is this list of classes up to date? What's it's source of truth? I tried looking for some "VSCode design system" but sadly there is none (and their webui project is closing down) |
I know, I've been discussing this in the community. We started a new community effort to recreate the components, as the fast foundation dependency was deprecated/removed. During the development, some members found another library: https://vscode-elements.github.io/ I always wanted to fix issues with the web components and event handling in React. There were some workarounds that I had implemented in the past, so I started another project. Which is a component library for React based on the original VS Code toolkit: https://www.npmjs.com/package/vscrui
The variables can be retrieved from the |
I have submitted the required adjustments, IMO they look good :) Now going back to the original issue and the issue I have with actions:
Their current design goes directly against the official VS Code UX guidelines:
IMO it should be done like it's done in other extensions — using panel toolbar and context menus, or with automatically registered tasks. |
Thanks, @T3sT3ro; I've merged your changes, and they will be available in the latest beta version. |
There are still items that need to be picked up in the future. Let us split these up into new issues so they are manageable and easier to track. |
Is your feature request related to a problem? Please describe.
The UI of sidebar could be improved for better readability and UX. Right now some elements/views are redundant, occupy much space (forcing user to scroll) and separate elements that should be grouped together.
Describe the solution you'd like
file-add
iconrocket
iconopen-preview
iconquote
, "Description":note
, "Slug":link
, "Content:book
, "Used in Headings": label 'H1' ortag
, "Keyword usage": percent sign,pulse
orsymbol-keyword
)...
view actions. They should have confirmation dialogs informing about overwriting global config for content-type.Additional context
A simple rendition of what I have in mind, generally.
The text was updated successfully, but these errors were encountered: