You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

313 lines
5.3 KiB
CSS

/* Global styles */
body,
html {
margin: 0;
padding: 0;
height: 100%;
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
background-color: #e5e7eb;
color: #333;
}
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
#app {
display: flex;
flex-direction: column;
height: 100vh;
overflow: hidden;
}
#main {
display: flex;
flex: 1;
height: calc(100vh - 60px);
}
#header {
flex-shrink: 0;
width: 100%;
height: 60px;
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
color: #fff;
display: flex;
align-items: center;
justify-content: space-between;
padding: 0 20px;
}
#header > h1 {
font-size: 20px;
}
.panel-title {
width: 90%;
margin: 0 5%;
padding: 10px 0;
border-bottom: 2px solid #667eea;
}
/* Components panel */
#components-panel {
position: relative;
flex: 1;
background-color: #fff;
border-right: 1px solid #e0e0e0;
display: flex;
flex-direction: column;
}
.components-list {
flex: 1;
padding: 10px;
overflow-y: auto;
display: flex;
flex-direction: row;
flex-wrap: wrap;
align-content: flex-start;
gap: 10px;
}
.component-item {
width: calc(50% - 5px);
height: 80px;
border-radius: 8px;
cursor: pointer;
display: flex;
align-items: center;
justify-content: center;
}
.component-item .grid-stack-item-content,
.grid-stack-item .grid-stack-item-content {
width: 100%;
height: 100%;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
}
#canvas-panel .grid-stack-item-content {
height: auto;
}
#components-panel .grid-stack-item {
background-color: #fff;
border: 1px solid #e0e0e0;
}
.component-item i,
.grid-stack-item i {
font-size: 18px;
margin-bottom: 5px;
color: #007bff;
}
.component-item span,
.grid-stack-item span {
font-size: 14px;
}
.action-btn {
position: relative;
width: 100%;
height: 50px;
display: flex;
align-items: center;
justify-content: center;
padding: 0 10px;
}
.action-btn .trash-container,
.action-btn .save-container {
width: 46%;
height: 40px;
margin: 0 2%;
border-radius: 8px;
display: flex;
align-items: center;
justify-content: center;
background: rgb(0, 123, 255, 0.6);
color: #fff;
font-size: 14px;
cursor: pointer;
}
.save-container {
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
}
.action-btn .trash-container > span,
.action-btn .save-container > span {
margin-left: 5px;
}
/* Canvas panel */
#canvas-panel {
flex: 4;
height: 100%;
background-color: #fff;
position: relative;
overflow-y: auto;
padding: 10px;
display: flex;
align-items: center;
justify-content: center;
}
.grid-stack {
background-color: #e2e2e2;
border-radius: 8px;
width: 960px;
}
.grid-stack-item-content {
cursor: pointer;
background: #fff;
}
#canvas-panel .grid-stack-item-content {
border-radius: 8px;
border: 1px solid #e0e0e0;
}
.global-save-button-container {
position: absolute;
top: 20px;
right: 20px;
z-index: 99;
}
.global-save-button {
padding: 10px 20px;
background-color: #28a745;
color: #fff;
border: none;
border-radius: 5px;
cursor: pointer;
font-size: 16px;
transition: background-color 0.3s;
}
.global-save-button:hover {
background-color: #218838;
}
/* Props panel */
#props-panel {
flex: 1;
background-color: #fff;
overflow-y: auto;
border-left: 1px solid #e0e0e0;
display: flex;
flex-direction: column;
}
form {
padding: 10px;
display: flex;
flex-direction: column;
flex: 1;
overflow-y: auto;
}
.form-item {
margin-bottom: 20px;
}
.form-item label {
display: block;
margin-bottom: 8px;
font-weight: 600;
color: #555;
}
.form-item input,
.form-item textarea {
width: 100%;
padding: 10px;
border: 1px solid #ccc;
border-radius: 5px;
box-sizing: border-box;
transition: border-color 0.3s;
}
.form-item input:focus,
.form-item textarea:focus {
outline: none;
border-color: #007bff;
}
.form-item select {
width: 100%;
}
.form-actions {
display: flex;
justify-content: space-between;
margin-top: 30px;
}
.form-actions button {
padding: 10px 15px;
border: none;
border-radius: 5px;
cursor: pointer;
font-size: 14px;
transition: background-color 0.3s;
flex: 1;
margin: 0 5px;
}
.save-button {
background-color: #007bff;
color: #fff;
}
.save-button:hover {
background-color: #0056b3;
}
.delete-button {
background-color: #dc3545;
color: #fff;
}
.delete-button:hover {
background-color: #c82333;
}
/* Scrollbar styles */
::-webkit-scrollbar {
width: 5px;
}
::-webkit-scrollbar-track {
background: #f1f1f1;
}
::-webkit-scrollbar-thumb {
background: #ccc;
border-radius: 5px;
}
::-webkit-scrollbar-thumb:hover {
background: #aaa;
}
/* Responsive layout */
@media (max-width: 1200px) {
#components-panel {
grid-template-columns: 1fr;
}
}
.wait-box {
display: flex;
flex: 1;
align-items: center;
justify-content: center;
width: 100%;
height: 100%;
}
.show {
display: block;
}
.hidden {
display: none;
}