This commit is contained in:
karyamanswasta
2025-08-27 03:20:49 +07:00
parent 6127415e37
commit f58b40c70d
14 changed files with 2127 additions and 1071 deletions

View File

@@ -1,149 +1,556 @@
/* SetPaymentQr.module.css */
/* MaterialList.module.css */
.container {
width: 100%;
min-height: 47vh;
background-color: white;
padding: 20px;
border-radius: 8px;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
text-align: center;
width: 100%;
background-color: #ffffff;
border-radius: 16px;
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
padding: 0;
margin-bottom: 24px;
transition: all 0.3s ease;
position: relative;
z-index: 200; /* Menaikkan z-index agar berada di atas cartbar */
max-height: 70vh; /* Membatasi tinggi maksimum */
overflow-y: auto; /* Memungkinkan scrolling vertikal */
}
.container:hover {
box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
}
.header {
padding: 24px;
border-bottom: 1px solid #e6e6e6;
display: flex;
justify-content: space-between;
align-items: center;
position: sticky;
top: 0;
background-color: #ffffff;
z-index: 201; /* Memastikan header berada di atas container */
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
}
.title {
margin: 0;
font-weight: 700;
font-size: 24px;
color: #333;
}
.addButton {
background-color: #28a745;
color: white;
border: none;
border-radius: 12px;
padding: 12px 24px;
font-size: 16px;
font-weight: 600;
cursor: pointer;
transition: all 0.2s ease;
display: flex;
align-items: center;
gap: 8px;
box-shadow: 0 2px 6px rgba(40, 167, 69, 0.2);
position: relative;
z-index: 202; /* Memastikan tombol berada di atas header */
}
.addButton:hover {
background-color: #218838;
transform: translateY(-2px);
box-shadow: 0 4px 10px rgba(40, 167, 69, 0.3);
}
.addButton:disabled {
background-color: #a1a1a1;
cursor: not-allowed;
transform: none;
box-shadow: none;
}
.content {
padding: 24px;
position: relative;
z-index: 200;
}
/* Materials List Styles */
.materialsList {
display: flex;
flex-direction: column;
gap: 12px;
}
.materialCard {
background: #ffffff;
border-radius: 12px;
box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
transition: all 0.2s ease;
border: 1px solid #eee;
position: relative;
z-index: 200;
}
.materialCard:hover {
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
border-color: #28a745;
}
.materialSummary {
display: flex;
justify-content: space-between;
align-items: center;
padding: 16px 20px;
cursor: pointer;
position: relative;
z-index: 201;
}
.materialName {
font-size: 16px;
font-weight: 600;
color: #333;
margin: 0;
flex: 1;
}
.materialStock {
font-size: 14px;
color: #666;
margin: 0 16px 0 0;
}
.expandIcon {
font-size: 18px;
color: #28a745;
transition: transform 0.2s ease;
}
.expandIcon.expanded {
transform: rotate(180deg);
}
/* Material Detail Styles */
.materialDetail {
padding: 0 20px 20px 20px;
border-top: 1px solid #eee;
background: #f9f9f9;
border-radius: 0 0 12px 12px;
position: relative;
z-index: 200;
}
.detailGrid {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 16px;
margin-bottom: 20px;
}
.detailItem {
background: #ffffff;
padding: 16px;
border-radius: 10px;
box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}
.detailLabel {
font-size: 13px;
color: #666;
margin-bottom: 4px;
}
.detailValue {
font-size: 18px;
font-weight: 600;
color: #333;
}
.detailActions {
display: flex;
gap: 12px;
margin-top: 16px;
}
.detailButton {
flex: 1;
padding: 12px 16px;
border-radius: 10px;
border: none;
font-size: 14px;
font-weight: 600;
cursor: pointer;
transition: all 0.2s ease;
display: flex;
align-items: center;
justify-content: center;
gap: 8px;
}
.updateButton {
background-color: #28a745;
color: white;
box-shadow: 0 2px 6px rgba(40, 167, 69, 0.2);
}
.updateButton:hover {
background-color: #218838;
box-shadow: 0 4px 10px rgba(40, 167, 69, 0.3);
}
.deleteButton {
background-color: #dc3545;
color: white;
box-shadow: 0 2px 6px rgba(220, 53, 69, 0.2);
}
.deleteButton:hover {
background-color: #c82333;
box-shadow: 0 4px 10px rgba(220, 53, 69, 0.3);
}
/* Stock Update Form */
.stockUpdateForm {
background: #ffffff;
border-radius: 12px;
padding: 20px;
margin-top: 20px;
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
position: relative;
z-index: 201;
}
.formTitle {
font-size: 18px;
font-weight: 600;
color: #333;
margin: 0 0 20px 0;
}
.quantityControls {
display: flex;
align-items: center;
gap: 16px;
margin-bottom: 20px;
}
.quantityButton {
width: 40px;
height: 40px;
border-radius: 50%;
border: 1px solid #ddd;
background: #ffffff;
font-size: 20px;
font-weight: 700;
cursor: pointer;
display: flex;
align-items: center;
justify-content: center;
transition: all 0.2s ease;
}
.quantityButton:hover {
border-color: #28a745;
background: #f0f8f1;
color: #28a745;
}
.quantityDisplay {
font-size: 20px;
font-weight: 600;
min-width: 80px;
text-align: center;
}
.formGroup {
margin-bottom: 20px;
}
.formLabel {
display: block;
margin-bottom: 8px;
font-weight: 500;
color: #333;
font-size: 14px;
}
.formInput {
width: 100%;
padding: 12px 16px;
border-radius: 10px;
border: 1px solid #ddd;
font-size: 16px;
transition: all 0.2s ease;
background: #ffffff;
}
.formInput:focus {
outline: none;
border-color: #28a745;
box-shadow: 0 0 0 3px rgba(40, 167, 69, 0.1);
}
.formActions {
display: flex;
gap: 12px;
}
.formButton {
flex: 1;
padding: 14px 16px;
border-radius: 10px;
border: none;
font-size: 16px;
font-weight: 600;
cursor: pointer;
transition: all 0.2s ease;
display: flex;
align-items: center;
justify-content: center;
}
.saveButton {
background-color: #28a745;
color: white;
box-shadow: 0 2px 6px rgba(40, 167, 69, 0.2);
}
.saveButton:hover {
background-color: #218838;
box-shadow: 0 4px 10px rgba(40, 167, 69, 0.3);
}
.cancelButton {
background-color: #f0f0f0;
color: #333;
box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}
.cancelButton:hover {
background-color: #e0e0e0;
box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}
/* Add Material Form */
.addMaterialForm {
background: #f8f9fa;
border-radius: 12px;
padding: 24px;
margin-top: 24px;
position: relative;
z-index: 201;
}
.formSection {
margin-bottom: 24px;
}
.sectionTitle {
font-size: 18px;
font-weight: 600;
color: #333;
margin: 0 0 20px 0;
padding-bottom: 12px;
border-bottom: 1px solid #e6e6e6;
}
.formGrid {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 20px;
}
.fullWidth {
grid-column: 1 / -1;
}
/* Empty State */
.emptyState {
text-align: center;
padding: 60px 20px;
color: #999;
}
.emptyStateIcon {
font-size: 48px;
margin-bottom: 16px;
color: #ccc;
}
.emptyStateText {
font-size: 18px;
margin-bottom: 24px;
color: #666;
}
/* History Section */
.historySection {
margin-top: 24px;
border-top: 1px solid #e6e6e6;
padding-top: 20px;
}
.historyTitle {
font-size: 18px;
font-weight: 600;
color: #333;
margin: 0 0 16px 0;
display: flex;
align-items: center;
gap: 12px;
cursor: pointer;
}
.historyTitle:hover {
color: #28a745;
}
.historyItems {
display: flex;
flex-direction: column;
gap: 12px;
max-height: 250px;
overflow-y: auto;
padding-right: 8px;
}
.historyItems::-webkit-scrollbar {
width: 6px;
}
.historyItems::-webkit-scrollbar-track {
background: #f1f1f1;
border-radius: 10px;
}
.historyItems::-webkit-scrollbar-thumb {
background: #c1c1c1;
border-radius: 10px;
}
.historyItem {
display: flex;
align-items: center;
gap: 16px;
padding: 12px 16px;
background: #ffffff;
border-radius: 10px;
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}
.historyIcon {
width: 36px;
height: 36px;
background: #b9b9b9;
border-radius: 8px;
display: flex;
align-items: center;
justify-content: center;
color: white;
font-size: 16px;
}
.historyContent {
flex: 1;
}
.historyDate {
font-size: 13px;
font-weight: 600;
color: #333;
margin: 0 0 2px 0;
}
.historyDetails {
font-size: 13px;
color: #666;
margin: 0;
}
.sortControls {
display: flex;
justify-content: flex-end;
margin-bottom: 12px;
}
.sortButton {
background: #f0f0f0;
border: none;
border-radius: 20px;
padding: 6px 14px;
font-size: 13px;
color: #555;
cursor: pointer;
transition: all 0.2s ease;
display: flex;
align-items: center;
gap: 6px;
}
.sortButton:hover {
background: #e0e0e0;
}
/* Loading State */
.loading {
text-align: center;
padding: 40px;
color: #666;
}
.loadingSpinner {
font-size: 32px;
margin-bottom: 16px;
animation: spin 1s linear infinite;
}
@keyframes spin {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg); }
}
/* Responsive Design */
@media (max-width: 768px) {
.header {
padding: 16px;
flex-direction: column;
gap: 16px;
align-items: stretch;
}
.title {
margin-bottom: 20px;
font-weight: bold;
.content {
padding: 16px;
}
.uploadMessage {
font-weight: 600;
text-align: left;
.detailGrid {
grid-template-columns: 1fr;
gap: 12px;
}
.changeButtonEnabled {
padding-right: 10px;
background-color: green;
border-radius: 30px;
color: white;
font-weight: 700;
height: 36px;
line-height: 36px;
padding-left: 10px;
padding-height: 10px;
.formGrid {
grid-template-columns: 1fr;
gap: 16px;
}
.changeButtonDisabled {
padding-right: 10px;
background-color: #a1a1a1;
border-radius: 30px;
color: white;
font-weight: 700;
height: 36px;
line-height: 36px;
padding-left: 10px;
padding-height: 10px;
.historyItems {
max-height: 200px;
}
.resultMessage {
margin-top: -13px;
text-align: left;
display: flex;
justify-content: space-between;
.materialSummary {
padding: 14px 16px;
}
.resultMessage input {
padding-left: 8px;
width: 180px;
.materialName {
font-size: 15px;
}
.stokContainer {
display: flex;
justify-content: space-evenly;
align-items: center;
margin-top: -20px;
margin-bottom: -15px;
text-align: left;
.materialStock {
font-size: 13px;
margin-right: 12px;
}
.buttonContainer {
margin-top: 11px;
text-align: left;
.container {
max-height: 75vh; /* Menaikkan tinggi maksimum pada mobile */
}
.stockButton {
padding: 10px 20px;
font-size: 3.5vw;
background-color: #28a745;
color: #fff;
border: none;
border-radius: 30px;
cursor: pointer;
transition: background-color 0.3s;
}
.saveButton {
width: 100%;
padding: 10px 20px;
font-size: 3.5vw;
background-color: #28a745;
color: #fff;
border: none;
border-radius: 30px;
cursor: pointer;
transition: background-color 0.3s;
}
.switchContainer {
margin-top: 20px;
text-align: left;
}
.historyTab {
text-align: left;
}
.historyContainer {
text-align: left;
max-height: 15vh;
overflow-y: auto;
}
.description {
display: flex;
margin: 10px 0;
font-size: 14px;
color: #666;
}
.unit {
margin-top: 11px;
width: 100%;
height: 31px;
}
.sorter {
border: 1px solid #c3c3c3;
padding: 5px;
border-radius: 10px;
display: flex;
justify-content: space-between;
margin-top: -10px;
margin-bottom: 10px;
}
.mutationCard {
display: flex;
margin-bottom: 7px;
margin-top: 7px;
}
.mutationTitle {
margin-left: 5px;
}
.mutationTitle h4 {
margin: 0;
}
.mutationTitle p {
margin: 0;
}
}