Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Update Button.module.scss#373

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
vanshikak03 wants to merge1 commit intoalgorithm-visualizer:master
base:master
Choose a base branch
Loading
fromvanshikak03:vanshikak03-patch-1
Open
Changes fromall 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
50 changes: 31 additions & 19 deletionssrc/components/Button/Button.module.scss
View file
Open in desktop
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,34 @@
@import "~common/stylesheet/index";

// Variables for maintainability
$button-padding-horizontal: 12px;
$button-margin: 0;
$icon-margin-right: 4px;
$icon-size: 1.6em;
$icon-border-radius: 2px;
$hover-bg-color: $color-overlay;
$primary-hover-bg-color: $color-shadow;
$primary-active-box-shadow: 0px 0px 10px 3px #1a1a1a inset;
$disabled-opacity: 0.6;
$selected-hover-color: rgba($color-font, .8);
$confirming-color: $color-alert;

.button {
display: flex;
align-items: center;
cursor: pointer;
padding: 012px;
margin:0;
padding: 0$button-padding-horizontal;
margin:$button-margin;

.icon {
margin-right:4px;
margin-right:$icon-margin-right;

&.image {
width:1.6em;
height:1.6em;
width:$icon-size;
height:$icon-size;
background-position: center;
background-size: cover;
border-radius:2px;
border-radius:$icon-border-radius;
}
}

Expand All@@ -24,33 +37,32 @@

.icon {
margin-right: 0;
margin-left:4px;
margin-left:$icon-margin-right;
}
}

&.icon_only {
.icon {
margin-left: 0;
margin-right: 0;
margin: 0;
}
}

&:hover {
background-color: $color-overlay;
background-color: $hover-bg-color;
}

&.primary {
&:hover {
background-color: $color-shadow;
background-color: $primary-hover-bg-color;

&:active {
box-shadow:0px 0px 10px 3px #1a1a1a inset;
box-shadow:$primary-active-box-shadow;
}
}

&.active {
background-color: $color-shadow;
box-shadow:0px 0px 10px 3px #1a1a1a inset;
background-color: $primary-hover-bg-color;
box-shadow:$primary-active-box-shadow;
font-weight: bold;

.icon {
Expand All@@ -60,20 +72,20 @@
}

&.selected {
background-color: $color-shadow;
background-color: $primary-hover-bg-color;

&:hover {
color:rgba($color-font, .8);
color:$selected-hover-color;
}
}

&.disabled {
cursor: not-allowed;
background-color: $color-shadow;
opacity:0.6;
background-color: $primary-hover-bg-color;
opacity:$disabled-opacity;
}

&.confirming {
color: $color-alert;
color: $confirming-color;
}
}

[8]ページ先頭

©2009-2025 Movatter.jp