Skip to content
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

Style: Use new color system #3926

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 14 additions & 5 deletions src/components/betaflight-logo/BetaflightLogo.vue
Original file line number Diff line number Diff line change
Expand Up @@ -42,20 +42,23 @@ export default {
.logo {
height: 70px;
width: 240px;
background-image: url(../../images/light-wide-2.svg);
background-image: url(../../images/dark-wide-2.svg);
background-repeat: no-repeat;
background-position: left center;
background-size: contain;
position: relative;
margin-top: -25px;
}

.dark-theme .logo {
background-image: url(../../images/light-wide-2.svg);
}

.logo_text {
position: absolute;
left: 80px;
top: 49px;
color: #949494;
opacity: 0.5;
color: var(--text);
font-size: 10px;
min-width: 210px;
display: flex;
Expand All @@ -70,17 +73,20 @@ export default {
.logo {
height: 24px;
width: 150px;
background-image: url(../../images/light-wide-2-compact.svg);
background-image: url(../../images/dark-wide-2-compact.svg);
background-position: left center;
order: 2;
margin-top: 0;
}
.dark-theme .logo {
background-image: url(../../images/light-wide-2-compact.svg);
}
.logo_text {
display: none !important;
}
.tab_container .logo {
display: block;
background-image: url(../../images/light-wide-2.svg);
background-image: url(../../images/dark-wide-2.svg);
background-repeat: no-repeat;
background-position: center 20px;
background-position-x: 12px;
Expand All @@ -91,6 +97,9 @@ export default {
position: relative;
border-bottom: 1px solid rgba(0, 0, 0, 0.3);
}
.dark-theme .tab_container .logo {
background-image: url(../../images/light-wide-2.svg);
}
.tab_container .logo .logo_text {
display: flex !important;
left: 82px;
Expand Down
2 changes: 1 addition & 1 deletion src/components/data-flash/DataFlash.vue
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ export default {
border-radius: 2px;
width: 25%;
display: block;
background-color: var(--accent);
background-color: var(--primary-500);
}
.dataflash-contents_global div span {
position: absolute;
Expand Down
145 changes: 10 additions & 135 deletions src/components/port-picker/FirmwareVirtualOption.vue
Original file line number Diff line number Diff line change
Expand Up @@ -52,153 +52,28 @@ export default {
margin-top: 0px;
display: none;
}
.dropdown {
display: inline-block;
position: relative;
overflow: hidden;
height: 20px;
background: #fff;
background-image: -webkit-linear-gradient(
top,
transparent,
rgba(0, 0, 0, 0.06)
);
background-image: -moz-linear-gradient(
top,
transparent,
rgba(0, 0, 0, 0.06)
);
background-image: -o-linear-gradient(top, transparent, rgba(0, 0, 0, 0.06));
background-image: linear-gradient(
to bottom,
transparent,
rgba(0, 0, 0, 0.06)
);
-webkit-box-shadow: 0 1px 1px rgba(0, 0, 0, 0.08);
box-shadow: 0 1px 1px rgba(0, 0, 0, 0.08);
width: 99%;
margin-bottom: 7px;
border: 1px solid;
border-color: #ccc #ccc #ccc;
border-radius: 3px;
}

.dropdown:before,
.dropdown:after {
content: "";
position: absolute;
z-index: 2;
top: 7px;
right: 7px;
width: 0;
height: 0;
border: 4px dashed;
border-color: #888 transparent;
pointer-events: none;
}

.dropdown:before {
border-bottom-style: solid;
border-top: none;
margin-top: -2px;
}

.dropdown:after {
margin-top: 5px;
border-top-style: solid;
border-bottom: none;
}

.dropdown-select {
position: relative;
overflow: visible;
width: 100%;
margin-top: 0px;
padding: 1px 8px 6px 5px;
height: 23px;
line-height: 20px;
font-size: 12px;
color: #62717a;
text-shadow: 0 1px white;
/* Fallback for IE 8 */
background: #f2f2f2;
/* "transparent" doesn't work with Opera */
background: rgba(0, 0, 0, 0) !important;
border: 0;
border-radius: 0;
-webkit-appearance: none;
appearance: "none";
}

.dropdown-select:focus {
z-index: 3;
width: 90%;
color: #4fa619;
outline: 0px solid #49aff2;
outline: 0px solid -webkit-focus-ring-color;
outline-offset: 5px;
height: 25px;
}

.dropdown-select > option {
margin: 3px;
padding: 6px 8px;
text-shadow: none;
background: #f2f2f2;
border-radius: 3px;
cursor: pointer;
.dropdown-dark .dropdown-select {
color: var(--text);
width: calc(100% - 10px);
background: #444;
}

.dropdown-dark {
background: #636363; /* NEW2 */
background: #3e403f; /* NEW */
border-color: #111 #0a0a0a black;
background-image: -webkit-linear-gradient(
top,
transparent,
rgba(0, 0, 0, 0.4)
);
background-image: -moz-linear-gradient(
top,
transparent,
rgba(0, 0, 0, 0.4)
);
background-image: -o-linear-gradient(top, transparent, rgba(0, 0, 0, 0.4));
background-image: linear-gradient(
to bottom,
transparent,
rgba(0, 0, 0, 0.4)
);
-webkit-box-shadow: inset 0 1px rgba(255, 255, 255, 0.1),
0 1px 1px rgba(0, 0, 0, 0.2);
box-shadow: inset 0 1px rgba(255, 255, 255, 0.1),
0 1px 1px rgba(0, 0, 0, 0.2);
color: #a6a6a6;
text-shadow: 0px 1px rgba(0, 0, 0, 0.25);
background-color: var(--surface-300);
border: 1px solid var(--surface-500);
color: var(--text);
}

.dropdown-dark:before {
border-bottom-color: #aaa;
border-bottom-color: var(--surface-700);
}

.dropdown-dark:after {
border-top-color: #aaa;
}

.dropdown-dark .dropdown-select {
color: #a6a6a6;
text-shadow: 0 1px black;
width: calc(100% - 10px);
/* Fallback for IE 8 */
background: #444;
}

.dropdown-dark .dropdown-select:focus {
color: #fff;
border-top-color: var(--surface-700);
}

.dropdown-dark .dropdown-select > option {
background: #56ab1a;
text-shadow: 0 1px rgba(0, 0, 0, 0.4);
background: var(--surface-300);
}
</style>
4 changes: 2 additions & 2 deletions src/components/port-picker/PortOverrideOption.vue
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ export default {
background-color: #2b2b2b;
border-radius: 3px;
padding: 3px;
color: var(--subtleAccent);
color: var(--surface-500);
}
}

Expand All @@ -44,7 +44,7 @@ export default {
border-radius: 3px;
/* might be less */
padding: 2px;
color: var(--subtleAccent);
color: var(--surface-500);
}

#port-override {
Expand Down
47 changes: 9 additions & 38 deletions src/components/port-picker/PortsInput.vue
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ export default {
},
};
</script>
<style scoped>
<style scoped lang="less">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need lang="less"here? Don't think we are using any features from less in vue parts

#portsinput {
width: 220px;
margin-right: 15px;
Expand All @@ -104,63 +104,34 @@ export default {
}

.dropdown-dark .dropdown-select {
color: #a6a6a6;
text-shadow: 0 1px black;
color: var(--text);
width: calc(100% - 10px);
background: #444;
}

.dropdown-dark {
background: #636363; /* NEW2 */
background: #3e403f; /* NEW */
border-color: #111 #0a0a0a black;
background-image: -webkit-linear-gradient(
top,
transparent,
rgba(0, 0, 0, 0.4)
);
background-image: -moz-linear-gradient(
top,
transparent,
rgba(0, 0, 0, 0.4)
);
background-image: -o-linear-gradient(top, transparent, rgba(0, 0, 0, 0.4));
background-image: linear-gradient(
to bottom,
transparent,
rgba(0, 0, 0, 0.4)
);
-webkit-box-shadow: inset 0 1px rgba(255, 255, 255, 0.1),
0 1px 1px rgba(0, 0, 0, 0.2);
box-shadow: inset 0 1px rgba(255, 255, 255, 0.1),
0 1px 1px rgba(0, 0, 0, 0.2);
color: #a6a6a6;
text-shadow: 0px 1px rgba(0, 0, 0, 0.25);
background-color: var(--surface-300);
border: 1px solid var(--surface-500);
color: var(--text);
}

.dropdown-dark:before {
border-bottom-color: #aaa;
border-bottom-color: var(--surface-700);
}

.dropdown-dark:after {
border-top-color: #aaa;
border-top-color: var(--surface-700);
}

.dropdown-dark .dropdown-select {
color: #a6a6a6;
text-shadow: 0 1px black;
color: var(--text);
width: calc(100% - 10px);
/* Fallback for IE 8 */
background: #444;
}

.dropdown-dark .dropdown-select:focus {
color: #fff;
}

.dropdown-dark .dropdown-select > option {
background: #56ab1a;
text-shadow: 0 1px rgba(0, 0, 0, 0.4);
background: var(--surface-300);
}
#auto-connect-and-baud {
float: right;
Expand Down
2 changes: 1 addition & 1 deletion src/components/quad-status/BatteryIcon.vue
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ export default {

.quad-status-contents progress::-webkit-progress-bar {
height: 12px;
background-color: #eee;
background-color: var(--surface-300);
}

.quad-status-contents progress::-webkit-progress-value {
Expand Down
4 changes: 2 additions & 2 deletions src/components/quad-status/BottomStatusIcons.vue
Original file line number Diff line number Diff line change
Expand Up @@ -65,13 +65,13 @@ button {
border-radius: 4px;
background-color: #ccc;
color: #666;
border: 1px solid var(--subtleAccent);
border: 1px solid var(--surface-500);
font-weight: 600;
font-size: 10pt;
cursor: pointer;
}
button.active {
background-color: var(--accent);
background-color: var(--primary-500);
border: 1px solid #dba718;
color: #000;
}
Expand Down
Loading