Skip to content

Commit

Permalink
update settings-modal design
Browse files Browse the repository at this point in the history
Signed-off-by: Sajid Alam <[email protected]>
  • Loading branch information
SajidAlamQB committed Apr 24, 2024
1 parent 65acdf9 commit 3bfabab
Show file tree
Hide file tree
Showing 5 changed files with 32 additions and 26 deletions.
7 changes: 0 additions & 7 deletions src/components/settings-modal/settings-modal.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,13 +104,6 @@ const SettingsModal = ({
>
<div className="pipeline-settings-modal__content">
<div className="pipeline-settings-modal__group">
<div className="pipeline-settings-modal__header">
<div className="pipeline-settings-modal__name">Name</div>
<div className="pipeline-settings-modal__state">State</div>
<div className="pipeline-settings-modal__description">
Description
</div>
</div>
<SettingsModalRow
id="isPrettyName"
name={settingsConfig['isPrettyName'].name}
Expand Down
23 changes: 12 additions & 11 deletions src/components/settings-modal/settings-modal.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,17 @@
@use '../../styles/mixins' as mixins;

.kui-theme--light {
--color-modal-header-text: #{colors.$black-700};
--color-modal-header-text: #{colors.$black-0};
--color-upgrade-reminder-text: #{colors.$blue-300};
--color-modal-table-text: rgb(0 0 0 / 85%);
--color-modal-table-description: rgb(0 0 0 / 70%);
}

.kui-theme--dark {
--color-modal-header-text: #{colors.$black-0};
--color-modal-header-text: #{colors.$black-300};
--color-upgrade-reminder-text: #{colors.$yellow-300};
--color-modal-table-text: rgb(255 255 255 / 85%);
--color-modal-table-description: rgb(255 255 255 / 70%);
}

.pipeline-settings-modal {
Expand Down Expand Up @@ -45,32 +49,29 @@

.pipeline-settings-modal__column {
margin: 1.145em 0;
}

.pipeline-settings-modal__column,
.pipeline-settings-modal__header {
align-items: baseline;
display: flex;
flex-wrap: wrap;
font-size: 1.4em;
}

.pipeline-settings-modal__header {
margin-bottom: 10px;
color: var(--color-modal-header-text);
}

.pipeline-settings-modal__subtitle {
margin-bottom: 24px;
font-size: 1.8em;
}

.pipeline-settings-modal__name {
@include mixins.flexColumn(3);

color: var(--color-modal-table-text);
font-weight: 500;
}

.pipeline-settings-modal__description {
@include mixins.flexColumn(6);

color: var(--color-modal-table-description);
font-weight: 500;
}

.pipeline-settings-modal__state {
Expand Down
4 changes: 2 additions & 2 deletions src/components/ui/button/button.scss
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ $secondary-underline-offset-hover: 4px;

.kui-theme--light {
--color-button--border: #{colors.$black-900};
--color-button--border--disabled: #{colors.$grey-400};
--color-button--border--disabled: #{colors.$black-900};
--color-button__text--hover: #{colors.$white-600};
--color-button__text: #{colors.$black-800};
--color-secondary-active: #{colors.$white-100};
}

.kui-theme--dark {
--color-button--border: #{colors.$white-0};
--color-button--border--disabled: #{colors.$grey-900};
--color-button--border--disabled: rgb(255 255 255 / 30%);
--color-button__text--hover: #{colors.$black-800};
--color-button__text: #{colors.$white-600};
--color-secondary-active: #{colors.$slate-0};
Expand Down
5 changes: 3 additions & 2 deletions src/components/ui/modal/modal.scss
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@ $duration-visibility: 0.4s;
.kui-theme--light {
--color-modal-bg: #{colors.$black-700};
--color-modal-content: #{colors.$white-0};
--color-modal-title: #{colors.$black-800};
--color-modal-title: #{colors.$black-900};
--color-modal-description: #{colors.$black-700};
}

.kui-theme--dark {
--color-modal-bg: #{colors.$slate-900};
--color-modal-content: #{colors.$slate-0};
--color-modal-title: #{colors.$white-600};
--color-modal-title: #{colors.$white-0};
--color-modal-description: #{colors.$black-0};
}

Expand Down Expand Up @@ -85,6 +85,7 @@ $duration-visibility: 0.4s;
width: 100%;
color: var(--color-modal-title);
margin-bottom: $size-spacing;
font-weight: 500;
}

.modal__description {
Expand Down
19 changes: 15 additions & 4 deletions src/components/ui/toggle/toggle.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,20 @@

.kui-theme--light {
--color-toggle-on: #{colors.$blue-600};
--color-toggle-on-bar: #{colors.$ocean-0};
--color-toggle-off: #{colors.$slate-0};
--color-toggle-off-bar: #{colors.$grey-400};
--color-toggle-on-bar: #{colors.$blue-600};
--color-toggle-off: #{colors.$black-900};
--color-toggle-off-bar: #{colors.$black-900};
--color-toggle-on-label: #{colors.$blue-600};
--color-toggle-off-label: #{colors.$black-800};
}

.kui-theme--dark {
--color-toggle-on: #{colors.$blue-0};
--color-toggle-on-bar: #{colors.$blue-0};
--color-toggle-off: #{colors.$white-0};
--color-toggle-off-bar: #{colors.$black-400};
--color-toggle-off-bar: #{colors.$white-0};
--color-toggle-on-label: #{colors.$blue-0};
--color-toggle-off-label: #{colors.$white-600};
}

.pipeline-toggle {
Expand Down Expand Up @@ -40,6 +44,11 @@
padding: 0 0 0 2.8em;
cursor: pointer;
user-select: none;
color: var(--color-toggle-off-label);
}

.pipeline-toggle-input:checked + .pipeline-toggle-label {
color: var(--color-toggle-on-label);
}

.pipeline-toggle-label::before,
Expand All @@ -57,6 +66,7 @@
width: 1.7em;
height: 0.8em;
background-color: var(--color-toggle-off-bar);
opacity: 0.3;
border-radius: 0.5em;
transition: opacity 0.15s ease;
}
Expand All @@ -67,6 +77,7 @@
background-color: var(--color-toggle-off);
border-radius: 50%;
transition: opacity 0.15s ease, transform 0.15s ease;
color: var(--color-toggle-on-label);
}

[data-whatinput='keyboard'] input:focus + .pipeline-toggle-label::before {
Expand Down

0 comments on commit 3bfabab

Please sign in to comment.