mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2025-07-20 14:55:50 +00:00
changes to scss to make it look pretty
This commit is contained in:
parent
d411bf1da7
commit
2ebcca789a
1 changed files with 62 additions and 58 deletions
|
@ -21,6 +21,18 @@ $spring-brown: #34302D;
|
||||||
$spring-grey: #838789;
|
$spring-grey: #838789;
|
||||||
$spring-light-grey: #f1f1f1;
|
$spring-light-grey: #f1f1f1;
|
||||||
|
|
||||||
|
#Chatbox
|
||||||
|
$chatbox-bg-color: #f4f4f9;
|
||||||
|
$chatbox-border-color: #ddd;
|
||||||
|
$chatbox-header-color: #555;
|
||||||
|
$chatbox-user-bubble-color: #0084ff;
|
||||||
|
$chatbox-bot-bubble-color: #f1f1f1;
|
||||||
|
$chatbox-user-text-color: white;
|
||||||
|
$chatbox-bot-text-color: #333;
|
||||||
|
$chatbox-border-radius: 10px;
|
||||||
|
$chatbox-box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1);
|
||||||
|
|
||||||
|
|
||||||
$body-bg: $spring-light-grey;
|
$body-bg: $spring-light-grey;
|
||||||
$text-color: $spring-brown;
|
$text-color: $spring-brown;
|
||||||
$link-color: $spring-dark-green;
|
$link-color: $spring-dark-green;
|
||||||
|
@ -209,94 +221,86 @@ hr {
|
||||||
border-top: 1px dotted $spring-brown;
|
border-top: 1px dotted $spring-brown;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Chatbox container styling
|
||||||
.chatbox {
|
.chatbox {
|
||||||
position: fixed;
|
|
||||||
bottom: 0;
|
|
||||||
right: 0;
|
|
||||||
width: 300px;
|
width: 300px;
|
||||||
border-radius: 10px 10px 0 0;
|
border: 1px solid $chatbox-border-color;
|
||||||
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
|
background-color: $chatbox-bg-color;
|
||||||
|
border-radius: $chatbox-border-radius;
|
||||||
|
box-shadow: $chatbox-box-shadow;
|
||||||
|
position: fixed;
|
||||||
|
bottom: 10px;
|
||||||
|
right: 10px;
|
||||||
font-family: Arial, sans-serif;
|
font-family: Arial, sans-serif;
|
||||||
background-color: #f0f0f0;
|
font-size: 14px;
|
||||||
overflow: hidden;
|
|
||||||
|
|
||||||
&.minimized {
|
|
||||||
height: 40px;
|
|
||||||
}
|
|
||||||
|
|
||||||
&-header {
|
&-header {
|
||||||
background-color: $spring-green;
|
background-color: $chatbox-user-bubble-color;
|
||||||
color: white;
|
color: $chatbox-user-text-color;
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
cursor: pointer;
|
border-radius: $chatbox-border-radius $chatbox-border-radius 0 0;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
text-align: center;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
&-content {
|
&-content {
|
||||||
height: 400px;
|
max-height: 400px;
|
||||||
|
overflow-y: auto;
|
||||||
|
padding: 10px;
|
||||||
|
background-color: white;
|
||||||
|
border-bottom: 1px solid $chatbox-border-color;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
|
}
|
||||||
|
|
||||||
|
&-footer {
|
||||||
|
padding: 10px;
|
||||||
|
border-top: 1px solid $chatbox-border-color;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
background-color: white;
|
|
||||||
transition: height 0.3s ease;
|
input[type="text"] {
|
||||||
|
flex: 1;
|
||||||
|
padding: 5px;
|
||||||
|
border: 1px solid $chatbox-border-color;
|
||||||
|
border-radius: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
button {
|
||||||
|
padding: 5px 10px;
|
||||||
|
background-color: $chatbox-user-bubble-color;
|
||||||
|
color: $chatbox-user-text-color;
|
||||||
|
border: none;
|
||||||
|
border-radius: 5px;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
&-messages {
|
&-messages {
|
||||||
padding: 10px;
|
|
||||||
overflow-y: auto;
|
|
||||||
height: 90%;
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
gap: 10px;
|
|
||||||
|
|
||||||
.chat-bubble {
|
.chat-bubble {
|
||||||
padding: 10px;
|
max-width: 80%;
|
||||||
|
margin-bottom: 10px;
|
||||||
|
padding: 8px;
|
||||||
border-radius: 15px;
|
border-radius: 15px;
|
||||||
max-width: 70%;
|
position: relative;
|
||||||
word-wrap: break-word;
|
word-wrap: break-word;
|
||||||
|
|
||||||
&.user {
|
&.user {
|
||||||
background-color: $spring-brown;
|
background-color: $chatbox-user-bubble-color;
|
||||||
color: white;
|
color: $chatbox-user-text-color;
|
||||||
align-self: flex-end;
|
align-self: flex-end;
|
||||||
}
|
}
|
||||||
|
|
||||||
&.bot {
|
&.bot {
|
||||||
background-color: $spring-grey;
|
background-color: $chatbox-bot-bubble-color;
|
||||||
color: black;
|
color: $chatbox-bot-text-color;
|
||||||
align-self: flex-start;
|
align-self: flex-start;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
&-footer {
|
|
||||||
display: flex;
|
|
||||||
padding: 10px;
|
|
||||||
background-color: $spring-light-grey;
|
|
||||||
|
|
||||||
input {
|
|
||||||
flex: 1;
|
|
||||||
padding: 10px;
|
|
||||||
border-radius: 5px;
|
|
||||||
border: 1px solid $spring-brown;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
button {
|
|
||||||
margin-left: 10px;
|
|
||||||
padding: 10px 20px;
|
|
||||||
background-color: $spring-green;
|
|
||||||
color: white;
|
|
||||||
border: none;
|
|
||||||
border-radius: 5px;
|
|
||||||
cursor: pointer;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
background-color: darken($spring-green, 10%);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
@import "typography.scss";
|
@import "typography.scss";
|
||||||
|
|
Loading…
Reference in a new issue