Skip to content

Update buttons style #1122

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

Merged
merged 11 commits into from
Jul 8, 2022
Original file line number Diff line number Diff line change
Expand Up @@ -598,7 +598,7 @@ export class ArduinoFrontendContribution
'Color of the Arduino IDE foreground which is used for dialogs, such as the Select Board dialog.',
},
{
id: 'arduino.toolbar.background',
id: 'arduino.toolbar.button.background',
defaults: {
dark: 'button.background',
light: 'button.background',
Expand All @@ -608,7 +608,7 @@ export class ArduinoFrontendContribution
'Background color of the toolbar items. Such as Upload, Verify, etc.',
},
{
id: 'arduino.toolbar.hoverBackground',
id: 'arduino.toolbar.button.hoverBackground',
defaults: {
dark: 'button.hoverBackground',
light: 'button.foreground',
Expand Down
128 changes: 0 additions & 128 deletions arduino-ide-extension/src/browser/data/arduino.color-theme.json

This file was deleted.

5 changes: 3 additions & 2 deletions arduino-ide-extension/src/browser/data/dark.color-theme.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"colors": {
"list.highlightForeground": "#0ca1a6",
"list.activeSelectionForeground": "#dae3e3",
"list.activeSelectionBackground": "#434f54",
"list.activeSelectionBackground": "#0ca1a64d",
"list.inactiveSelectionForeground": "#dae3e3",
"list.inactiveSelectionBackground": "#434f54",
"list.hoverBackground": "#1f272a",
Expand Down Expand Up @@ -45,7 +45,8 @@
"arduino.foreground": "#edf1f1",
"arduino.output.foreground": "#ffffff",
"arduino.output.background": "#000000",
"arduino.toolbar.hoverBackground": "#dae3e3",
"arduino.toolbar.button.hoverBackground": "#dae3e3",
"arduino.toolbar.button.background": "#0ca1a6",
"sideBar.background": "#101618",
"sideBar.foreground": "#dae3e3",
"input.background": "#000000",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"colors": {
"list.highlightForeground": "#008184",
"list.activeSelectionForeground": "#4e5b61",
"list.activeSelectionBackground": "#dae3e3",
"list.activeSelectionBackground": "#00818433",
"list.inactiveSelectionForeground": "#4e5b61",
"list.inactiveSelectionBackground": "#dae3e3",
"list.hoverBackground": "#ecf1f1",
Expand All @@ -22,7 +22,7 @@
"menu.selectionBackground": "#dae3e3",
"menu.selectionForeground": "#212121",
"editorGroupHeader.tabsBackground": "#ecf1f1",
"button.background": "#7fcbcd",
"button.background": "#008184",
"button.foreground": "#f7f9f9",
"button.hoverBackground": "#005C5F",
"titleBar.activeBackground": "#006d70",
Expand All @@ -45,7 +45,8 @@
"arduino.foreground": "#edf1f1",
"arduino.output.foreground": "#ffffff",
"arduino.output.background": "#000000",
"arduino.toolbar.hoverBackground": "#f7f9f9",
"arduino.toolbar.button.hoverBackground": "#f7f9f9",
"arduino.toolbar.button.background": "#7fcbcd",
"sideBar.background": "#f7f9f9",
"sideBar.foreground": "#4e5b61",
"input.background": "#ffffff",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ export const CertificateUploaderComponent = ({
>
<button
type="button"
className="theia-button primary add-cert-btn"
className="theia-button secondary add-cert-btn"
onClick={() => {
showAdd ? setShowAdd(false) : setShowAdd(true);
}}
Expand Down
5 changes: 3 additions & 2 deletions arduino-ide-extension/src/browser/style/dialogs.css
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,8 @@
}

.p-Widget.dialogOverlay .dialogBlock .dialogContent .dialogSection .dialogRow:first-child {
margin-top: 0px;
margin-top: 0px;
height: 32px;
}

.fl1{
Expand All @@ -69,4 +70,4 @@

.fa.disabled {
opacity: .4;
}
}
5 changes: 5 additions & 0 deletions arduino-ide-extension/src/browser/style/fonts.css
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
@font-face {
font-family: 'Open Sans';
src: url('fonts/OpenSans-Bold-webfont.woff') format('woff');
}

@font-face {
font-family: 'FontAwesome';
src:
Expand Down
Binary file not shown.
Binary file not shown.
44 changes: 35 additions & 9 deletions arduino-ide-extension/src/browser/style/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -60,25 +60,51 @@
/* Overrule the default Theia CSS button styles. */
button.theia-button,
.theia-button {
border: 1px solid var(--theia-dropdown-border);
align-items: center;
display: flex;
font-family: 'Open Sans',sans-serif;
font-style: normal;
font-weight: 700;
font-size: 14px;
justify-content: center;
cursor: pointer;
letter-spacing: .01em;
line-height: 24px;
outline: none;
padding: 0 16px;
position: relative;
text-align: center;
text-decoration: none;
border-width: 2px;
border-radius: 32px;
text-transform: uppercase;
transition: none;
box-shadow: none;
}

button.theia-button:hover,
.theia-button:hover {
border: 1px solid var(--theia-focusBorder);
button.theia-button {
height: 28px;
max-width: none;
}

button.theia-button {
height: 31px;
.theia-button:active,
.theia-button:focus {
box-shadow: 0 0 0 2px var(--theia-focusBorder);
}

button.theia-button.secondary {
background-color: var(--theia-secondaryButton-background);
color: var(--theia-secondaryButton-foreground);
border: 2px solid var(--theia-secondaryButton-foreground);
}

button.theia-button.main {
button.theia-button[disabled], .theia-button[disabled] {
opacity: 0.5;
color: var(--theia-button-foreground);
background-color: var(--theia-button-background);
}

button.secondary[disabled], .theia-button.secondary[disabled] {
color: var(--theia-secondaryButton-foreground);
background-color: var(--theia-secondaryButton-background);
}

/* To make the progress-bar slightly thicker, and use the color from the status bar */
Expand Down
4 changes: 2 additions & 2 deletions arduino-ide-extension/src/browser/style/list-widget.css
Original file line number Diff line number Diff line change
Expand Up @@ -127,12 +127,12 @@ https://github.com/arduino/arduino-pro-ide/issues/82 */
}

.component-list-item:hover .footer > * {
display: block;
display: inline-block;
margin: 5px 0px 0px 10px;
}

.component-list-item:hover .footer > label {
display: block;
display: inline-block;
align-self: center;
margin: 5px 0px 0px 10px;
}
Expand Down
6 changes: 3 additions & 3 deletions arduino-ide-extension/src/browser/style/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@
align-items: center;
height: 24px;
width: 24px;
background: var(--theia-arduino-toolbar-background);
background: var(--theia-arduino-toolbar-button-background);
}

.p-TabBar-toolbar .item.arduino-tool-item.enabled:hover > div {
background: var(--theia-arduino-toolbar-hoverBackground);
background: var(--theia-arduino-toolbar-button-hoverBackground);
}

.arduino-verify-sketch--toolbar,
Expand Down Expand Up @@ -178,7 +178,7 @@
}

#arduino-open-sketch-control--toolbar--container {
background-color: var(--theia-arduino-toolbar-background);
background-color: var(--theia-arduino-toolbar-button-background);
border-radius: 1px;
}

Expand Down
2 changes: 1 addition & 1 deletion arduino-ide-extension/src/browser/style/sketchbook.css
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@

.active-sketch {
font-weight: 500;
background-color: var(--theia-button-disabledBackground) !important;
background-color: var(--theia-list-activeSelectionBackground) !important;
color: var(--theia-list-inactiveSelectionForeground) !important;

}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,9 @@ export class NotificationComponent extends TheiaNotificationComponent {
actions.map((action, index) => (
<button
key={messageId + `-action-${index}`}
className="theia-button"
className={`theia-button ${
index !== actions.length - 1 ? 'secondary' : ''
}`}
data-message-id={messageId}
data-action={action}
onClick={this.onAction}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,10 @@ export class ListItemRenderer<T extends ArduinoComponent> {
);
const onClickInstall = () => install(item);
const installButton = item.installable && (
<button className="theia-button install" onClick={onClickInstall}>
<button
className="theia-button secondary install"
onClick={onClickInstall}
>
{nls.localize('arduino/component/install', 'INSTALL')}
</button>
);
Expand Down Expand Up @@ -121,8 +124,8 @@ export class ListItemRenderer<T extends ArduinoComponent> {
</div>
<div className="info">{moreInfo}</div>
<div className="footer">
{installButton}
{versions}
{installButton}
</div>
</div>
);
Expand Down